From e1465795188cb8df41757e9519a542d740a3223a Mon Sep 17 00:00:00 2001 From: Jens Granseuer Date: Sun, 9 Dec 2007 15:36:10 +0000 Subject: [PATCH] don't try to map invisible widgets, e.g. the button icon when running with 2007-12-09 Jens Granseuer * theme-thumbnail.c: (hbox_foreach): don't try to map invisible widgets, e.g. the button icon when running with gtk-button-images=0 (bug #461298) svn path=/trunk/; revision=8322 --- capplets/common/ChangeLog | 6 ++++++ capplets/common/theme-thumbnail.c | 10 ++++++---- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/capplets/common/ChangeLog b/capplets/common/ChangeLog index dfab03c3a..9f6e3c917 100644 --- a/capplets/common/ChangeLog +++ b/capplets/common/ChangeLog @@ -1,3 +1,9 @@ +2007-12-09 Jens Granseuer + + * theme-thumbnail.c: (hbox_foreach): don't try to map invisible + widgets, e.g. the button icon when running with gtk-button-images=0 + (bug #461298) + 2007-12-09 Jens Granseuer * theme-thumbnail.c: (create_meta_theme_pixbuf): free metacity theme diff --git a/capplets/common/theme-thumbnail.c b/capplets/common/theme-thumbnail.c index 9a269f67e..f9ef482f0 100644 --- a/capplets/common/theme-thumbnail.c +++ b/capplets/common/theme-thumbnail.c @@ -121,10 +121,12 @@ static void hbox_foreach (GtkWidget *widget, gpointer data) { - gtk_widget_realize (widget); - gtk_widget_map (widget); - gtk_widget_ensure_style (widget); - fake_expose_widget (widget, (GdkPixmap *) data, NULL); + if (GTK_WIDGET_VISIBLE (widget)) { + gtk_widget_realize (widget); + gtk_widget_map (widget); + gtk_widget_ensure_style (widget); + fake_expose_widget (widget, (GdkPixmap *) data, NULL); + } } static GdkPixbuf *