Using the Eclipse Properties View with a GLSP Diagram #806
-
Hello, I have a project which is based on the java-emf-eclipse project template (https://github.com/eclipse-glsp/glsp-examples/tree/master/project-templates/java-emf-eclipse). When I select an element (a task in the example project), I want the Properties View in Eclipse to be populated with properties (e.g. the name of the task). I found this tutorial quite helpful to give me a rough understanding of how it works: https://www.eclipse.org/articles/Article-Properties-View/properties-view.html However, I just can't put the pieces together to make it work with my GLSP diagram. I am assuming there is an easy way to achieve what I'm looking for, since properties are an integral part of many diagrams. Any help would be greatly appreciated. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 7 replies
-
Hi @Ginxss, Currently there is no default integration with the Eclipse Properties View but I think the general workflow would be something like this:
I hope this gets you started. |
Beta Was this translation helpful? Give feedback.
Hi @Ginxss,
Currently there is no default integration with the Eclipse Properties View but I think the general workflow would be something like this:
Ensure that you can retrieve the selection from your GLSP diagram. You have several options to do this: Register a custom action handler for the SelectAction that then sends the selection to the server using a new ServerSelectAction, listen to the existing selection service and then send the new custom action or override the selection service to achieve the same result. Probably having a custom action handler is the least intrusive for this but maybe you already have a customization in your project.
On the server side, register a ServerS…