Skip to main content



      Home
Home » Modeling » Graphiti » Listeners on Shape(Adding listeners to shape)
Listeners on Shape [message #1775791] Mon, 06 November 2017 07:41 Go to next message
Eclipse UserFriend
Hi All,

I am trying to implement a feature that make a certain shape show/update display when selected and return to its original shape when loses its focus (should not make editor dirty).
Is there a way to add listeners to Graphiti Shape or is there more appropriate way of implementing this.
By the way, i am using IPatterns.

Thanks,
Ken
Re: Listeners on Shape [message #1776016 is a reply to message #1775791] Thu, 09 November 2017 06:13 Go to previous messageGo to next message
Eclipse UserFriend
Ken,

Graphiti does not offer to register listeners on shapes. The only notification on selection we sent out is a call to getSelection method of the tool behavior provider to change the shape you want to select. Not sure if that helps in your case.

Michael
Re: Listeners on Shape [message #1776026 is a reply to message #1776016] Thu, 09 November 2017 08:18 Go to previous messageGo to next message
Eclipse UserFriend
Hi Michael,

The getSelection method from ToolBehaviorProvider is called even on mouse hover.
Is there a method that is notified when the shape was only selected and deselected?
Any idea?

Thanks,
Ken
Re: Listeners on Shape [message #1776038 is a reply to message #1776026] Thu, 09 November 2017 10:20 Go to previous message
Eclipse UserFriend
Sorry Ken, there is no other hook that I can think of for that.

Michael
Previous Topic:How to initialize the diagram with some shapes
Next Topic:Graphiti Diagram
Goto Forum:
  


Current Time: Sun Mar 16 06:42:45 EDT 2025

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

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

Back to the top