Dnd in diagram editor fires two event each call canAdd [message #698311] |
Tue, 19 July 2011 08:54 |
Joerg Reichert Messages: 80 Registered: July 2009 Location: Leipzig |
Member |
|
|
Hello,
I have implemented a tree viewer for my model so I can drag and drop nodes from that viewer to the diagram editor. The feature provider extracts the model element from the tree node and returns the responsible Add feature. This works so far. Then I added a dialog popping up when the dragged model element is not allowed to be add. This is done in the canAdd method of the Add feature. But this dialog twice as the canAdd method is called twice, once by the dragEnter event and a second time by the dragOver event. Is there any reason why the dragEnter event calls the canAdd method? How can this be adapted?
Regards,
Joerg
--
Need professional support for Xtext and EMF?
Go to: http://xtext.itemis.com
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03760 seconds