[Bf-blender-cvs] [88660d67a4c] blender-v2.91-release: WM: ensure is_repeat isn't set for mouse-move events

Campbell Barton noreply at git.blender.org
Thu Oct 22 03:01:05 CEST 2020


Commit: 88660d67a4c5e88e7b7b7304b66e4d893affed91
Author: Campbell Barton
Date:   Thu Oct 22 11:53:24 2020 +1100
Branches: blender-v2.91-release
https://developer.blender.org/rB88660d67a4c5e88e7b7b7304b66e4d893affed91

WM: ensure is_repeat isn't set for mouse-move events

Follow up to d782bad62dc53373bb28811c0672da81924371d6

Also clear this for simulated events.

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

M	source/blender/makesrna/intern/rna_wm_api.c
M	source/blender/windowmanager/intern/wm_event_system.c

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

diff --git a/source/blender/makesrna/intern/rna_wm_api.c b/source/blender/makesrna/intern/rna_wm_api.c
index 47d5e9b6313..2cabc89feee 100644
--- a/source/blender/makesrna/intern/rna_wm_api.c
+++ b/source/blender/makesrna/intern/rna_wm_api.c
@@ -632,6 +632,7 @@ static wmEvent *rna_Window_event_add_simulate(wmWindow *win,
   wmEvent e = *win->eventstate;
   e.type = type;
   e.val = value;
+  e.is_repeat = false;
   e.x = x;
   e.y = y;
   /* Note: KM_MOD_FIRST, KM_MOD_SECOND aren't used anywhere, set as bools */
diff --git a/source/blender/windowmanager/intern/wm_event_system.c b/source/blender/windowmanager/intern/wm_event_system.c
index e6ec68f706c..faec579a7c3 100644
--- a/source/blender/windowmanager/intern/wm_event_system.c
+++ b/source/blender/windowmanager/intern/wm_event_system.c
@@ -3402,6 +3402,7 @@ void wm_event_do_handlers(bContext *C)
       tevent.type = MOUSEMOVE;
       tevent.prevx = tevent.x;
       tevent.prevy = tevent.y;
+      tevent.is_repeat = false;
       wm_event_add(win, &tevent);
       win->addmousemove = 0;
     }



More information about the Bf-blender-cvs mailing list