Bug 109932 Should not access resources plug-in on ide startup
20050819 As we are hitting the resources plug-in too early by adding a resource listener on startUp. This then eagerly sets the preference location which occurs before the preference chooser comes up. As a result running with -data noDefault results in an error. Moving this to preShutdown and postStartup of the advisor sorts this out.
bundles/org.eclipse.ui.ide/src/org/eclipse/ui/internal/ide/IDEWorkbenchAdvisor.java
}
        workbenchAdvisor = this;
    }
    /* (non-Javadoc)
     * @see org.eclipse.ui.application.WorkbenchAdvisor#initialize
     */
    public void initialize(IWorkbenchConfigurer configurer) {
        
        configurer.setSaveAndRestore(true);
        
        exceptionHandler = new IDEExceptionHandler(configurer);
        
        WorkbenchAdapterBuilder.registerAdapters();
        
        String[] cmdLineArgs = Platform.getCommandLineArgs();
         
        
        for (int i = 0; i < cmdLineArgs.length; i++) {
            if ("-showlocation".equalsIgnoreCase(cmdLineArgs[i])) { 
            	String name = null;
            	if (cmdLineArgs.length > i + 1)
            		name = cmdLineArgs[i+1];
            	if (name != null && name.indexOf("-") == -1)		
            		workspaceLocation = name;
            	else
            		workspaceLocation = Platform.getLocation().toOSString();
                break;
            }
        }