diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2014-06-09 17:31:27 +0400 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2014-06-09 17:31:27 +0400 |
commit | f1f33ba7be2d6c1c1f79c1f833543948f9b3bb79 (patch) | |
tree | 9a7ba15a3a45699d88e266cbd39a3e5fc90aff88 /source | |
parent | 0ae8ce3ab1d8295266c8cda60f3446249b4416ab (diff) |
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.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/windowmanager/intern/wm_operators.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c index a73532680c5..13245e936f9 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) |