Focus on Shortcut Container with Double Click [message #201777] |
Wed, 13 August 2008 06:01 |
Eclipse User |
|
|
|
Hi,
I've got a GMF editor working with shortcuts, all generated by GMF. What
I'd like to be able to do is when the user double clicks on one of the
shortcut elements, it opens the diagram that contains the shortcut
element. i.e.:
[#one]
element A links --> B1 (shortcut)
when double clicking B1 (shortcut) it should display:
[#two]
elements B1, B2, ...
For a model such as:
root
one
A
link to: B1
two
B1
B2 ...
Is this possible to generate with just GMF? Or what would be the best
way to approach this?
I've been looking at three possible manual options:
1. Overriding getOpenCommand() in the OpenDiagramEditPolicy to somehow
find the target element 'two' and load this instead
2. Add the appropriate HintedDiagramLinkStyle to the B node type to
reference the 'two' class -- how would I do this?
3. Creating a new editPolicyProvider through plugin.xml, but finding
this difficult as there are no online examples of extending the
editPolicyProvider extension point.
Any help would be appreciated, thanks :)
Jevon
|
|
|
Powered by
FUDForum. Page generated in 0.02878 seconds