Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2021-04-13 14:33:52 +0300
committerCampbell Barton <ideasman42@gmail.com>2021-04-13 14:36:38 +0300
commit1534da457efcd52d06b2a9c8a488fe26224974b5 (patch)
tree5a09517482a12053d602a470384996104958911b /source/blender/windowmanager/intern
parent2f367db2cc638e47aa1c6644082070c290a8532d (diff)
Fix snap gizmo flickering while dragging
Ignore click-drag for non-mouse button drag events Alternative to fix issue detailed in D10886.
Diffstat (limited to 'source/blender/windowmanager/intern')
-rw-r--r--source/blender/windowmanager/intern/wm_event_query.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/blender/windowmanager/intern/wm_event_query.c b/source/blender/windowmanager/intern/wm_event_query.c
index 9b9be6bb497..3efff20f107 100644
--- a/source/blender/windowmanager/intern/wm_event_query.c
+++ b/source/blender/windowmanager/intern/wm_event_query.c
@@ -265,6 +265,11 @@ bool WM_event_is_last_mousemove(const wmEvent *event)
return true;
}
+bool WM_event_is_mouse_drag(const wmEvent *event)
+{
+ return ISTWEAK(event->type) || (ISMOUSE_BUTTON(event->type) && (event->val == KM_CLICK_DRAG));
+}
+
/** \} */
/* -------------------------------------------------------------------- */