Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 368192 - Need to persist information in a window but only contributions have a persisted state map
Summary: Need to persist information in a window but only contributions have a persist...
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.2   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 320478 366042
  Show dependency tree
 
Reported: 2012-01-09 14:50 EST by Remy Suen CLA
Modified: 2012-01-30 10:24 EST (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Remy Suen CLA 2012-01-09 14:50:15 EST
I wanted to the workbench window's input for bug 366042 but then realized that this was not possible in the current version of our model.
Comment 1 Eric Moffatt CLA 2012-01-09 15:52:00 EST
This seems to be something we could expect EAP users to want as well. 

Currently, 'persistentData' is an attribute of MContribution in order to allow contributions to store their internal state (a la a View's memento). If we allow this we should likely bite the bullet and make this a generally available feature (i.e. allow it not just for MWindows but for everything).

I can see two aproaches:

1) Move the current 'persistentData' attribute under ApplicationElement (I was going to say MUIEelment but MAddons are *not* MUIElements but do need persistent state).

2) Provide PersistentData as a mix-in and decide who needs it.

Right now I'm leaning towards 1) for symmetry's sake.
Comment 2 Kai Toedter CLA 2012-01-10 01:53:05 EST
+1 for 1)
Comment 3 Thomas Schindl CLA 2012-01-10 03:15:05 EST
+1 for number 1)
Comment 4 Lars Vogel CLA 2012-01-12 00:16:06 EST
+1 for 1)
Comment 5 Dean Roberts CLA 2012-01-30 10:24:23 EST
Moved persistedState from Contribution to ApplicationElement as discussed.

As expected, persisted workbench state appears to be reconstituted in new location fine without any required migration code in reconciler.

Commit is http://git.eclipse.org/c/platform/eclipse.platform.ui.git/commit/?id=ed0b857cf059faf90e52ea5e208fa4ce9628093a