[haiku-commits] r42221 - haiku/trunk/src/kits/tracker

  • From: anevilyak@xxxxxxxxx
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Sat, 18 Jun 2011 00:56:11 +0200 (CEST)

Author: anevilyak
Date: 2011-06-18 00:56:11 +0200 (Sat, 18 Jun 2011)
New Revision: 42221
Changeset: https://dev.haiku-os.org/changeset/42221
Ticket: https://dev.haiku-os.org/ticket/7705

Modified:
   haiku/trunk/src/kits/tracker/PoseView.cpp
Log:
Fix regression introduced by r41892: DragStart() was called at the wrong time,
leading the drag message to contain nothing more than an empty B_MOUSE_IDLE
message. This broke several other cases of drag and drop which relied on it
containing the dragged refs. Fixes #7705.



Modified: haiku/trunk/src/kits/tracker/PoseView.cpp
===================================================================
--- haiku/trunk/src/kits/tracker/PoseView.cpp   2011-06-17 21:30:32 UTC (rev 
42220)
+++ haiku/trunk/src/kits/tracker/PoseView.cpp   2011-06-17 22:56:11 UTC (rev 
42221)
@@ -6716,6 +6716,9 @@
        if (!window)
                return;
 
+       if (!window->Dragging())
+               window->DragStart(message);
+
        switch (moveCode) {
                case B_INSIDE_VIEW:
                case B_ENTERED_VIEW:
@@ -6789,7 +6792,6 @@
                return;
 
        if (fDropTarget != NULL) {
-               window->DragStart(message);
                FrameForPose(fDropTarget, true, &fStartFrame);
                ShowContextMenu(where);
        } else


Other related posts: