Fix compositor backdrop gizmo refresh problem when toggling sidebar

The backdrop image gizmo was not following the backdrop image, it
needs to be refreshed whenever the view changes. The region init
callback is executed whenever the region size changes, so that should be
a reliable place to do that.

Reported as part of T87591.
This commit is contained in:
Julian Eisel 2021-07-08 13:05:33 +02:00
parent 4c8a8950cf
commit c304807099
1 changed files with 4 additions and 0 deletions

View File

@ -651,6 +651,10 @@ static void node_main_region_init(wmWindowManager *wm, ARegion *region)
lb = WM_dropboxmap_find("Node Editor", SPACE_NODE, RGN_TYPE_WINDOW);
WM_event_add_dropbox_handler(&region->handlers, lb);
/* The backdrop image gizmo needs to change together with the view. So always refresh gizmos on
* region size changes. */
WM_gizmomap_tag_refresh(region->gizmo_map);
}
static void node_main_region_draw(const bContext *C, ARegion *region)