Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » Autobuild on the startup of a plugin
Autobuild on the startup of a plugin [message #157163] Fri, 14 November 2003 21:55
Del Myers is currently offline Del MyersFriend
Messages: 69
Registered: July 2009
Member
I know I'll get into a lot of trouble for this because a lot of people
really like autobuild. But if you could help me out anyway, that would be
awesome :-).

I have a plugin that needs to turn off the workspaces's autobuild the first
time (and only the first time) that it is loaded. I have this right now:


public void startup() throws CoreException {
super.startup();
IPreferenceStore store = getPreferenceStore();
IPreferenceStore workbenchPS = getWorkbench().getPreferenceStore();
//this is set to true in the initializeDefaultPreferences
boolean firstLoad = store.getBoolean(FIRST_LOAD);
setActionSets = false;
if (firstLoad) {
log("first load");
IWorkspace workspace = getWorkspace();
IWorkspaceDescription workspaceDesc = workspace.getDescription();
//shut off auto-building, only on the
//first time that the plugin is run
workspaceDesc.setAutoBuilding(false);
workspace.setDescription(workspaceDesc);
workbenchPS.setValue("AUTO_BUILD", false);

//to ensure that auto-building is turned off at most one time,
//set a value in the preference store to say that no subsequent
//calls to startup() will be the first load of this plugin.

store.setValue(FIRST_LOAD, false);

}
}

When I install this plugin as a part of a feature that I am deploying, all
of the code to turn off autobuilding runs, but autobuilding is not turned
off. Does anyone have any idea why this may be? Would there be something
else in the Eclipse platform that is turning on autobuild?

Del
Previous Topic:IPluginContentWizard help
Next Topic:How do you start a non-GUI Plugin?
Goto Forum:
  


Current Time: Mon Dec 30 16:45:09 GMT 2024

Powered by FUDForum. Page generated in 0.02558 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top