Skip to main content



      Home
Home » Eclipse Projects » Sirius » I want to get mouse event information (Mouse down/Up).
I want to get mouse event information (Mouse down/Up). [message #1767358] Wed, 05 July 2017 03:46 Go to next message
Eclipse UserFriend
Hello.

I attach an image for explaining my situation.

index.php/fa/29850/0/

Left side is a sample instance diagram and right one is its metamodel.

When a user has created two problems (in this case, A and B) and want to connect the two elements from B to A using a contribution element (this case, C), I want to get the source (i.e., B) and the target (i.e., A) information from mouse down and up events.
Is there any way to do it?

Thank you so much in advance.

Best regards,
Grace
Re: I want to get mouse event information (Mouse down/Up). [message #1767708 is a reply to message #1767358] Mon, 10 July 2017 03:54 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

It seems you need an Element-Based Edge [1] to represent the contribution elements and a edge creation tool [2].

For the edge mapping, with domain class Contribution, after setting the source and target mappings to your "Problem" mapping, you can use feature:contribType as source finder expression and feature:target as target finder expression. Do not forget to define the semantic candidate expression with an expression to retrieve the Contributions elements from the diagram semantic target.

Then you can define an edge creation tool referencing your mapping, in the tool operation you wll have to create the Contribution element and to set the contribType and target.

Regards,

Maxime


[1] https://www.eclipse.org/sirius/doc/specifier/diagrams/Diagrams.html#edges
[2] https://www.eclipse.org/sirius/doc/specifier/diagrams/Diagrams.html#edge_tools
Re: I want to get mouse event information (Mouse down/Up). [message #1767710 is a reply to message #1767708] Mon, 10 July 2017 04:05 Go to previous messageGo to next message
Eclipse UserFriend
Hi again,

From the title of your post "I want to get mouse event information (Mouse down/Up)", it seems that my previous answer might not be adapted.

In Sirius, you have the possibility to define the double click behavior with the corresponding tool, but if your need to get mouse event you will have to look into GEF capabilities and maybe provide your own drag tracker, edit policies, etc

Regards
Re: I want to get mouse event information (Mouse down/Up). [message #1768940 is a reply to message #1767710] Tue, 25 July 2017 03:11 Go to previous message
Eclipse UserFriend
Thank you so much for your help.
I could solve the problem.

Best regards,
Grace
Previous Topic:Add multi-touch gestures to Sirius
Next Topic:Validation Quick Fixes using external Java Actions
Goto Forum:
  


Current Time: Mon Jul 07 21:16:18 EDT 2025

Powered by FUDForum. Page generated in 0.03387 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top