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>2020-01-17 10:58:50 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-01-17 10:58:50 +0300
commit6b7e5b35bcbfbd603573bff5761347d4bf0bda2a (patch)
treefd08eef0ec379005dabea35d813482dfb575f67e /source/blender/windowmanager/gizmo
parent192940e8c2c86613e4cdca82ad772aa210fc96e0 (diff)
Fix T73135: Gizmos flicker when changing viewport options
Diffstat (limited to 'source/blender/windowmanager/gizmo')
-rw-r--r--source/blender/windowmanager/gizmo/intern/wm_gizmo_group.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source/blender/windowmanager/gizmo/intern/wm_gizmo_group.c b/source/blender/windowmanager/gizmo/intern/wm_gizmo_group.c
index 73bee883cf8..14657bfa6bd 100644
--- a/source/blender/windowmanager/gizmo/intern/wm_gizmo_group.c
+++ b/source/blender/windowmanager/gizmo/intern/wm_gizmo_group.c
@@ -33,6 +33,7 @@
#include "BLI_buffer.h"
#include "BLI_listbase.h"
+#include "BLI_rect.h"
#include "BLI_string.h"
#include "BKE_context.h"
@@ -1154,7 +1155,10 @@ void WM_gizmo_group_refresh(const bContext *C, wmGizmoGroup *gzgroup)
wmGizmo *gz = wm_gizmomap_highlight_get(gzmap);
if (!gz || gz->parent_gzgroup != gzgroup) {
wmWindow *win = CTX_wm_window(C);
- if (win->tweak) {
+ ARegion *ar = CTX_wm_region(C);
+ BLI_assert(ar->gizmo_map == gzmap);
+ /* Check if the tweak event originated from this region. */
+ if ((win->tweak != NULL) && BLI_rcti_compare(&ar->winrct, &win->tweak->winrct)) {
/* We need to run refresh again. */
gzgroup->init_flag &= ~WM_GIZMOGROUP_INIT_REFRESH;
WM_gizmomap_tag_refresh_drawstep(gzmap, WM_gizmomap_drawstep_from_gizmo_group(gzgroup));