Graph node properties Follow
I'm creating a diagram (Graph API).
How to add click listener for the node or show some dialog on node double click (better way)?
I need "node properties dialog" functionality: user can click on a node and edit the node name and other node properties in the dialog (instead inplace editing).
Please sign in to leave a comment.
I found the BasicGraphPresentationModel.editNode() method.
The method is called on double click. Seems, it's that I need.
Can I show a dialog in the method, update the edited properties and then return from the method (return from the method on edit complete / cancel)?
Do I need to notify the model about changes in this case?
Are there any plugin examples that do this?
Hi, Alex
the best way is to override "editNode(N node)" method of your PresentationModel
(getCustomNodeCellEditor() method could return null)
Serega.
I have to invoke builder.updateGraph() or builder.queueUpdate() if your data
model doesn't synchronized
>> Do I need to notify the model about changes in this case?
>>
Apechatka: )) "You have to..." : )))
I suggest you take a look at Spring, Seam and Hibernate plugins for some example code
http://svn.jetbrains.org/idea/Trunk/bundled/