diff options
author | Campbell Barton <ideasman42@gmail.com> | 2020-03-12 17:19:22 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2020-03-12 17:29:06 +0300 |
commit | 5929dd7129f6e8d41a79a5e01dd8b18f5369d1a8 (patch) | |
tree | d8787b4e4ef02d48a585fa96241f069bd034da1b /source/blender/windowmanager | |
parent | 85ea7dfc546932dcd804417231824d2e8b842b27 (diff) |
Fix T73212: Gizmo's are still interactive when behind nodes
Diffstat (limited to 'source/blender/windowmanager')
-rw-r--r-- | source/blender/windowmanager/intern/wm_event_system.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/source/blender/windowmanager/intern/wm_event_system.c b/source/blender/windowmanager/intern/wm_event_system.c index a2d254bba94..c7556ec7516 100644 --- a/source/blender/windowmanager/intern/wm_event_system.c +++ b/source/blender/windowmanager/intern/wm_event_system.c @@ -2512,6 +2512,18 @@ static int wm_handlers_do_gizmo_handler(bContext *C, BLI_assert(gzmap != NULL); wmGizmo *gz = wm_gizmomap_highlight_get(gzmap); + /* Needed so UI blocks over gizmos don't let events fall through to the gizmos, + * noticeable for the node editor - where dragging on a node should move it, see: T73212. */ + if (region->type->clip_gizmo_events_by_ui) { + if (UI_region_block_find_mouse_over(region, &event->x, true)) { + if (gz != NULL) { + WM_tooltip_clear(C, CTX_wm_window(C)); + wm_gizmomap_highlight_set(gzmap, C, NULL, 0); + } + return action; + } + } + if (region->gizmo_map != handler->gizmo_map) { WM_gizmomap_tag_refresh(handler->gizmo_map); } |