Commit: f1f33ba7be2d6c1c1f79c1f833543948f9b3bb79
Author: Bastien Montagne
Date:   Mon Jun 9 15:31:27 2014 +0200
https://developer.blender.org/rBf1f33ba7be2d6c1c1f79c1f833543948f9b3bb79

Fix T40549: box selection starting point in the file requester.

We need to 'reset' mouse coordinates to the one it was when the gesture 
handling started,
else org coords are where the tweak event is created, which gives a noticeable 
gap
(several pixels) and unwanted behavior like the one retported about file box 
selection.

===================================================================

M       source/blender/windowmanager/intern/wm_operators.c

===================================================================

diff --git a/source/blender/windowmanager/intern/wm_operators.c 
b/source/blender/windowmanager/intern/wm_operators.c
index a735326..13245e9 100644
--- a/source/blender/windowmanager/intern/wm_operators.c
+++ b/source/blender/windowmanager/intern/wm_operators.c
@@ -3241,6 +3241,9 @@ static void tweak_gesture_modal(bContext *C, const 
wmEvent *event)
                                wmEvent tevent;
 
                                wm_event_init_from_window(window, &tevent);
+                               /* We want to get coord from start of drag, not 
from point where it becomes a tweak event, see T40549 */
+                               tevent.x = rect->xmin + sx;
+                               tevent.y = rect->ymin + sy;
                                if (gesture->event_type == LEFTMOUSE)
                                        tevent.type = EVT_TWEAK_L;
                                else if (gesture->event_type == RIGHTMOUSE)

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to