[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.platform] Workspace save participation

Hi,

I tried to follow the Eclipse Help for participating with a RCP application 
in the workbench saving.

 http://help.eclipse.org/help33/index.jsp?topic=/org.eclipse.platform.doc.isv/guide/resAdv_saving.htmIn my RCP application I adjusted the start method in the class Activator (please see below for the coding). Here I register the classMyWorkspaceSaveParticipant. I checked the class SaveManager and can see thatit is registered.But during shutdown the saving method  in MyWorkspaceSaveParticipant is notcalled.Do I have to do do something else, e.g. set the changed status of my pluginsomewhere?Best regards, Larspublic void start(BundleContext context) throws Exception {super.start(context);plugin = this;saveParticipant = new MyWorkspaceSaveParticipant(plugin);ISavedState lastState = ResourcesPlugin.getWorkspace().addSaveParticipant(plugin, saveParticipant);if (lastState == null)return;IPath location = lastState.lookup(new Path("save"));if (location == null)return;// the plugin instance should read any important state from the file.File f = getStateLocation().append(location).toFile();readStateFrom(f);}