DDContainer: how to abort drag or cancel drop?

sglorz

09-02-2011 21:53:48

Hi,

In my integration process of MyGUI in Construct, I have some issues with DDContainer.

In start drag and request drop you set the _result var to tell MyGUI that the operation can go on or is aborted.

In my Construct plugin, when I receive such event, I transmit it to Construct then the plugin lost the control => I can't inform MyGUI if the start drag or request drop is ok or not.

I have two questions:
1/ Is it possible to cancel a drag or a drop? If yes, I could always set result to true and add a command to let the user cancelling drag or drop.
2/ Is there another way to handle this? I could create my own DDContainer but I'd rather not.

sglorz

10-02-2011 20:29:17

I've found an "evil" solution: :twisted:

MyGUI::InputManager::getInstance().injectMouseRelease(0, 0, MyGUI::MouseButton::Left);

if you find any better way, please tell me so.

my.name

14-02-2011 18:47:39

widget->_resetContainer();

sglorz

15-02-2011 08:27:15

Thank you! I should have looked deeper ;)