Drag and drop in GeUserArea
-
I have been looking at the documentation and available samples in the SDK (R19) related to drag and drop.
From that I have managed to implement the detection of items being drag-n-dropped into a user area of my dialog.However, I have not been able to provide support for all type of items.
Material, Objects, etc ... are not an issue. They all are handled via the DRAGTYPE_ATOMARRAY and the GetDragObject(msg, &type, &object) function provides the items via the "object" variable.
As such I am able to retrieve the names of the items (and other stuff).When I am dragging commands (DRAGTYPE_COMMAND), the obtained "object" variable is nullptr.
So, I can detect that a command was drag-n-dropped, but I cannot detect which one.
Am I overlooking something, or is there some limitation? -
Hello,
the command ID is stored in the message BaseContainer. It is stored using the ID BFM_DRAG_DATA_NEW.
You find an example showing how to handle
DRAGTYPE_COMMAND
in the Drag and Drop section of of the GUI and Interaction Messages Manual.best wishes,
Sebastian -
Thanks for the info.
Looking back at the R19 documentation, no examples are provided, while the documention you link to does contain source code samples.
Thanks for the updated documentation links. Will check it out.Edit: works like a charm. Thanks.
-
Oops, seems like the R19 docs are missing code snippets. Thanks for informing us!
-
The C++ SDK Docs for Cinema 4D R19 SP3 have been updated and are available for
download
[URL-REMOVED] again. Sorry, for the inconvenience caused.
[URL-REMOVED] @maxon: This section contained a non-resolving link which has been removed.
-
@a_block Thanks for the update. Much appreciated!