Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse 4 » Can not change Workspace after upgrade from 4.7 -> 4.9(Platform.getInstanceLocation() always returns default location)
Can not change Workspace after upgrade from 4.7 -> 4.9 [message #1803817] Mon, 11 March 2019 13:00
Nico Wünschmann is currently offline Nico WünschmannFriend
Messages: 1
Registered: March 2019
Junior Member
Hello,

in my pure e4 application (eclipse plattform 4.7,) i used successful following code in my LifeCycleManager to let the user specify his workspace after first start:

@PostContextCreate
private void postContextCreate(IApplicationContext applicationContext, Display display, StatusReporter statusReporter) {
 logger.info("LifeCycleManager.postContextCreate()");
 // check if workspace directory has been set
 Location instanceLocation = Platform.getInstanceLocation();
 if (!instanceLocation.isSet()) {
  //open SwitchWorkspaceDialog and let the user choose the workspace path
  ...
  //set the new workspace
  instanceLocation.set(new File(directory).toURI().toURL(), false);
 }
}


After upgrading to 4.9,
Platform.getInstanceLocation.isSet()
always returns true and therefore the user cant choose his own workspace. The default workspace location is always set to /MyRCPApplication/workspace/.

I deleted all existing workspaces and tried it also on a clean system.

Is it a bug or is there another way in 4.9 to change the workspace?

Thanks
Nico
Previous Topic:Threading model questions for Eclipse builder developer
Next Topic:problem to export from eclipse 64 to 32 with delta pack
Goto Forum:
  


Current Time: Sun Dec 15 03:06:20 GMT 2019

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

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

Back to the top