Page 1 of 1

Attempt to create custom drag&drop

Posted: Wed May 03, 2006 08:55
by vinny_the_true
Hi there,

The drag&drop functionality available in CEGUI through CEGUI::DragContainer doesn't fit my requirements, so I added drag&drop functionnality to one of my own widget type.

I made it to avoid any functional change during the drag, no change in windows hierarchy or anything like that (I discovered by doing this that there is childing update when setting always on top...).

So far so good except that I can't get my widget over already "always on topped" other widgets (especially those placed higher in the hierarchy), like ScrollablePane Scrollbars. This remains my last problem, in other cases, it seems the behavior is right.


Here is what I set on the widget when "being dragged" state changes :

Code: Select all

   void setDragging( bool bState )
   {
      getParent()->setMutedState( bState );
      setClippedByParent( !bState );
      setModalState( bState );

      //setAlwaysOnTop( bState );
      //setEnabled( !bState );
   }


A also noticed that even if I set the "alwaysOnTop" flag, my problem with Scrollbars remains unchanged.

Posted: Wed May 03, 2006 17:31
by lindquist
alwaysOnTop is only relative to siblings.

Posted: Thu May 04, 2006 13:36
by vinny_the_true
ok, should be cool to add this comment to the setAlwaysOnTop documentation.

If I understand you well, there is nothing in CEGUI that can do a true alwaysOnTop feature, then ? Can you see another way to do something like that ?

Posted: Sun May 28, 2006 16:48
by lindquist
you can disable zorderchange. if you do this while the window is truely on top it will stay there