Executing feature on object select [message #1808603] |
Thu, 27 June 2019 16:40  |
Eclipse User |
|
|
|
When I switch selection from one object to another I'd like to execute a feature to show Properties View. For this I employ CustomFeature that does this and also implements hasDoneChanges() to return false so that editor does not get dirty. This works, but in such a away that I need to select object and then select again for DefaultToolBehaviorProvider.getSingleClickFeature() to fire. From user perspective this is action of two clicks: select and the click.
DefaultToolBehaviorProvider.getSelection() looks like a good place to call my single click feature, but is it the right way to do it and if it how can I generate ICustomContext to call my feature?
|
|
|
Re: Executing feature on object select [message #1808684 is a reply to message #1808603] |
Fri, 28 June 2019 14:10   |
Eclipse User |
|
|
|
Alex,
hm, providing property sheets using a Graphiti feature sounds rather complicated to me. Not sure if there is a specific reason for you to go that way. Have you seen the property sheets example in the tutorial project. There we provide a tabbed property sheet for EClasses that is hooked in vie the plugin.xml extension mechanism.
Does that help?
Michael
|
|
|
Re: Executing feature on object select [message #1808689 is a reply to message #1808684] |
Fri, 28 June 2019 15:25   |
Eclipse User |
|
|
|
Thanks Michael.
Yes I've referenced the examples when implementing property sheets for my diagram objects. What does not work, and what I am trying to implement is force focus on Properties View. So if current view in focus is Console View and user clicks on, let's say EClass object as in tutorial, then Properties View should gain focus on EClass object selection.
Thanks,
Alex
|
|
|
|
Powered by
FUDForum. Page generated in 0.03910 seconds