widgets: Close Layer Effects popover when changing images

Resolves #11347

In multi-window mode, it is possible to change images without
causing the layer effects popover to close. This results in the prior
image's layer effects being shown over the new image, which is
confusing. This patch causes the popover to automatically close
when the image is changed to prevent this problem.
This commit is contained in:
Alx Sa 2024-04-19 01:58:56 +00:00
parent 9653e50e5f
commit 97d6aa5904

View file

@ -1418,6 +1418,8 @@ gimp_item_tree_view_real_set_image (GimpItemTreeView *view,
view->priv->effects_drawable = NULL;
view->priv->effects_filter = NULL;
view->priv->filters_active_changed_handler = NULL;
if (view->priv->effects_popover)
gtk_widget_set_visible (view->priv->effects_popover, FALSE);
if (view->priv->image)
{