From e4532fe2a8b6fa9175acb19460d34e7e83062079 Mon Sep 17 00:00:00 2001 From: Michael Natterer Date: Fri, 12 Nov 2010 20:18:03 +0100 Subject: [PATCH] app: call gimp_canvas_item_begin,end_change() around passe partout changes Also remove the "highlight" member from the GimpDisplayShell struct. --- app/display/gimpdisplayshell.c | 10 ++++------ app/display/gimpdisplayshell.h | 1 - 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/app/display/gimpdisplayshell.c b/app/display/gimpdisplayshell.c index efeb97cd51..2e0973c5b0 100644 --- a/app/display/gimpdisplayshell.c +++ b/app/display/gimpdisplayshell.c @@ -787,12 +787,6 @@ gimp_display_shell_dispose (GObject *object) shell->checkerboard = NULL; } - if (shell->highlight) - { - g_slice_free (GdkRectangle, shell->highlight); - shell->highlight = NULL; - } - if (shell->mask) { g_object_unref (shell->mask); @@ -1761,6 +1755,8 @@ gimp_display_shell_set_highlight (GimpDisplayShell *shell, { g_return_if_fail (GIMP_IS_DISPLAY_SHELL (shell)); + gimp_canvas_item_begin_change (shell->passe_partout); + if (highlight) { g_object_set (shell->passe_partout, @@ -1775,6 +1771,8 @@ gimp_display_shell_set_highlight (GimpDisplayShell *shell, { gimp_canvas_item_set_visible (shell->passe_partout, FALSE); } + + gimp_canvas_item_end_change (shell->passe_partout); } /** diff --git a/app/display/gimpdisplayshell.h b/app/display/gimpdisplayshell.h index b186be0011..bf97b002fb 100644 --- a/app/display/gimpdisplayshell.h +++ b/app/display/gimpdisplayshell.h @@ -195,7 +195,6 @@ struct _GimpDisplayShell gboolean button_press_before_focus; - GdkRectangle *highlight; /* in image coordinates, can be NULL */ GimpDrawable *mask; GimpRGB mask_color;