Drag&drop from GeUserArea [SOLVED]
-
On 17/11/2013 at 10:01, xxxxxxxx wrote:
Thanks, but it's very annoying to can't do it. I hope any devs can give a hand for that. I have developped a custom browser over GeUserArea but i cannot drag&drop; materials from to any where.
-
On 17/11/2013 at 10:05, xxxxxxxx wrote:
i forgot to say, as you know GeUserArea can detect the dropped materials...
this for getting:case BFM_DRAGRECEIVE: { String string, str; LONG type = 0; void \*object = NULL; C4DAtomGoal \*bl = NULL; GetDragObject(msg,&type,&object); if (type==DRAGTYPE_ATOMARRAY && ((AtomArray\* )object)->GetCount()==1 && ((AtomArray\* )object)->GetIndex(0)) { bl = (C4DAtomGoal\* )((AtomArray\* )object)->GetIndex(0); if (bl->IsInstanceOf(Mmaterial)) { str += "Mmaterial"; } }
-
On 17/11/2013 at 11:07, xxxxxxxx wrote:
^Thanks for posting that code khor.
I didn't have that one in my notes.-ScottA
-
On 17/11/2013 at 13:03, xxxxxxxx wrote:
you're welcome. If it helps i can completed last part as:
case BFM_DRAGRECEIVE: { String string, str; LONG type = 0; void \*object = NULL; C4DAtomGoal \*bl = NULL; GetDragObject(msg,&type,&object); if (type==DRAGTYPE_ATOMARRAY && ((AtomArray\* )object)->GetCount()==1 && ((AtomArray\* )object)->GetIndex(0)) { bl = (C4DAtomGoal\* )((AtomArray\* )object)->GetIndex(0); if (bl->IsInstanceOf(Mmaterial)) { str += "Mmaterial"; } } else str = str+"unknown object"; if (msg.GetLong(BFM_DRAG_FINISHED)) info("Dropped..."+str); return SetDragDestination(MOUSE_POINT_HAND); break; }
-
On 17/11/2013 at 13:54, xxxxxxxx wrote:
Thanks again.
That handles dragging things ** to** the UA nicely.
Now we just need someone to post how to handle dragging from the UA.-ScottA
-
On 18/11/2013 at 15:40, xxxxxxxx wrote:
i found a hacked way for drag from a GeUserArea to another GeUserArea. I'm testing now .
But still really need help for native method -
On 23/03/2015 at 02:45, xxxxxxxx wrote:
Hello khor, did you find a solution to start a drag from a User Area? I need to do this as well, and I
have doubts it will be possible from Python if even from C++. -
On 23/03/2015 at 07:59, xxxxxxxx wrote:
Hi,
I'm not sure I'm getting this right, but in order to start a mouse drag from a GeUserArea you simply call HandleMouseDrag from GeUserArea class.
I don't think the function exists in Python. Or if it does, it's at least undocumented. -
On 23/03/2015 at 08:12, xxxxxxxx wrote:
Hi Andreas,
thanks, seems like I missed this method. Maybe I can work around this method missing from
with a C++ Plugin somehow. -
On 23/03/2015 at 08:22, xxxxxxxx wrote:
Just verified, HandleMouseDrag is not available in Python.