| Persist state per workbench page in IDEApplication? [message #285413] |
Mon, 16 May 2005 13:56 |
Eclipse User |
|
|
|
The navigation history (org.eclipse.ui.internal.NavigationHistory)
persists state per workbench page. The call to restoreState() is
initiated via WorkbenchPage.restoreState() which is in turn indirectly
called by from IDEWorkbenchAdvisor.openWindows() via
Workbench.restoreState().
I am looking at code in eclipse 3.0.1 but believe that things didn't
change in 3.1.
The knowledge about the Navigation History state is “hardwired” into the
IDE applications’ workbench page code.
I was trying to implement something similar by reacting to a
IWindowListener.windowClosed(IWorkbenchWindow wwin) established via
PlatformUI.getWorkbench().addWindowListener(). However the workbench
windows don’t seem to have an ID that could be used to associate the
state. The same problem seems to hold for workbench pages as well.
One potential solution would be if one could contribute to the workbench
state in .metadata\.plugins\org.eclipse.ui.workbench\workbench.xml.
However I didn’t find any hooks for doing that.
Is there a way to associate state with a workbench window or page?
Thanks
Henrich
|
|
|
Powered by
FUDForum. Page generated in 0.03584 seconds