Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Problem with switch workspace
Problem with switch workspace [message #510641] Thu, 28 January 2010 02:56 Go to next message
David CHAUTARD is currently offline David CHAUTARD
Messages: 102
Registered: July 2009
Senior Member
Hello,

I manage my switch workspace like IDEApplication. And when I switch workspace, my RCP restarts with the new selected workspace.

Nevertheless, when I exit and launch my RCP, it starts with the default workspace, and not the last used.

How can I manage my selection workspace to modify this behaviour?
Thanks for your help,
David.

[Updated on: Thu, 28 January 2010 05:40]

Report message to a moderator

Re: Problem with switch workspace [message #510966 is a reply to message #510641] Fri, 29 January 2010 05:42 Go to previous messageGo to next message
David CHAUTARD is currently offline David CHAUTARD
Messages: 102
Registered: July 2009
Senior Member
Hello,
I find a solution to my problem.

I add the following line to my config.ini file :
osgi.instance.area=@noDefault


It open the SHOW_WORKSPACE_SELECTION_DIALOG, to select the workspace, and suggest the default workspace which is also defined in this file with :
osgi.instance.area.default=./workspace


David.
Re: Problem with switch workspace [message #511428 is a reply to message #510966] Mon, 01 February 2010 10:28 Go to previous messageGo to next message
David CHAUTARD is currently offline David CHAUTARD
Messages: 102
Registered: July 2009
Senior Member
Hello,

I think this behaviour is an Eclipse bug. Because the default workspace should be only used if no workspace is set. And the RCP always considers that no workspace is setted, even if we have switched to a new workspace.

Is there a bug about this?

David.

[Updated on: Mon, 01 February 2010 10:28]

Report message to a moderator

Re: Problem with switch workspace [message #511656 is a reply to message #511428] Tue, 02 February 2010 08:02 Go to previous messageGo to next message
David CHAUTARD is currently offline David CHAUTARD
Messages: 102
Registered: July 2009
Senior Member
I create a bug for this problem : https://bugs.eclipse.org/bugs/show_bug.cgi?id=301518

David.
Re: Problem with switch workspace [message #512308 is a reply to message #511656] Thu, 04 February 2010 11:17 Go to previous messageGo to next message
Amit  is currently offline Amit
Messages: 7
Registered: February 2010
Junior Member
Hi David,
I am following up for this bug. I have having exact same trouble.
Could you please let me know where should I modify this code for workaround you suggested.
osgi.instance.area=@noDefault
Also can we do that programatically?
Thanks
Amit

[Updated on: Thu, 04 February 2010 11:19]

Report message to a moderator

Re: Problem with switch workspace [message #512338 is a reply to message #512308] Thu, 04 February 2010 12:25 Go to previous message
Amit  is currently offline Amit
Messages: 7
Registered: February 2010
Junior Member
Hi Devid
I noticed two things

1) following is my org.eclipse.ui.ide.prefs
#Wed Feb 03 15:38:09 CST 2010
RECENT_WORKSPACES_PROTOCOL=3
MAX_RECENT_WORKSPACES=5
SHOW_WORKSPACE_SELECTION_DIALOG=true
eclipse.preferences.version=1
RECENT_WORKSPACES=C\:\\Temp
CruiseControl\\OARS-win32.win32.x86\\oars\\w1\nC\:\\Temp
CruiseControl\\OARS-win32.win32.x86\\oars\\we

Here show workspace selection dialog is true but it dose not show the dialog
when the application starts. Even that could solve the issue.

2) As per your suggestion
I add the following line to my config.ini file :
osgi.instance.area=@noDefault

but when I treied to start the application it gave me following error

MESSAGE An error occurred while automatically activating bundle
org.eclipse.core.resources (29).
!STACK 0
org.osgi.framework.BundleException: Exception in
org.eclipse.core.resources.ResourcesPlugin.start() of bundle
org.eclipse.core.resources.
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.s tartActivator(BundleContextImpl.java:1018)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.s tart(BundleContextImpl.java:974)
at
org.eclipse.osgi.framework.internal.core.BundleHost.startWor ker(BundleHost.java:346)
at
org.eclipse.osgi.framework.internal.core.AbstractBundle.star t(AbstractBundle.java:260)
at
org.eclipse.osgi.framework.util.SecureAction.start(SecureAct ion.java:400)
at
org.eclipse.core.runtime.internal.adaptor.EclipseLazyStarter .postFindLocalClass(EclipseLazyStarter.java:111)
at
org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLoc alClass(ClasspathManager.java:417)
at

Thanks
Amit
Previous Topic:status line message not always visible
Next Topic:automatically add svn revision number on bundle export
Goto Forum:
  


Current Time: Fri Jul 25 21:14:01 EDT 2014

Powered by FUDForum. Page generated in 0.09161 seconds