From a216984f5db59375d906fbf1b4f9ca7b4b0b3cc3 Mon Sep 17 00:00:00 2001 From: monsta Date: Wed, 27 Jan 2016 18:07:08 +0300 Subject: common: use gtk_icon_theme_load_icon in both GTK+ builds --- capplets/common/theme-thumbnail.c | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) (limited to 'capplets/common') diff --git a/capplets/common/theme-thumbnail.c b/capplets/common/theme-thumbnail.c index 537e25c8..4376ef0f 100644 --- a/capplets/common/theme-thumbnail.c +++ b/capplets/common/theme-thumbnail.c @@ -224,23 +224,16 @@ create_folder_icon (char *icon_theme_name) #endif } - g_object_unref (icon_theme); - g_free (example_icon_name); - - /* render the icon to the thumbnail */ if (folder_icon == NULL) { - GtkWidget *dummy; - dummy = gtk_label_new (""); - - folder_icon = gtk_widget_render_icon (dummy, - GTK_STOCK_MISSING_IMAGE, - GTK_ICON_SIZE_DIALOG, - NULL); - - gtk_widget_destroy (dummy); + folder_icon = gtk_icon_theme_load_icon (icon_theme, + "image-missing", + 48, 0, NULL); } + g_object_unref (icon_theme); + g_free (example_icon_name); + return folder_icon; } -- cgit v1.2.1