Community
Participate
Working Groups
Currently cloneable snippets are part of MApplicationElement. This is too far up the model inheritance hierarchy. It should likely be moved to a better place, or become a first class citizen.
I would suggest that cloneable snippets be a map instead of a list. It seems that cloneableSnippets are id based and a map would make finding, deleting and insuring singulatiry easier.
While making the current list a Map makes perfect sense to me EMF doesn't...;-). For some reason (still unclear after hunting around a bit) I can't use the EMAP<K,V> type since it appears that it's not serializable (even though both the key (EString) and value (MUIElement) are). For now I'll do the following: - Make a new mix-in type 'SnippetContainer' with one feature 'snippets' which is a list of MUIElements. - Remove the current 'clonableSnippets' feature in ApplicationElement (this was the issue...not *all* elements need to contain snippets) - Inherit the new SnippetContainer class in both MWindow and MApplication.
Committed in >20110902. Updated the model and the relevant model service methods. Also updated the new Perspective Switcher code and added a 'findSnippet' model service API (since we apparently can't use a map).
Fixes by the previous commit