diff options
author | Matthias Clasen <mclasen@redhat.com> | 2014-06-17 22:06:08 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2014-06-20 01:17:44 -0400 |
commit | 36be12578ca252d3f48ead0d2bfaba6b09b8dd60 (patch) | |
tree | 3f30584bf7969528f9d99944b43c4a355b8d046d /gtk/deprecated/gtkiconfactory.c | |
parent | ea8afd29376ce63c3b18637c813be962c61fbe1c (diff) | |
download | gtk+-36be12578ca252d3f48ead0d2bfaba6b09b8dd60.tar.gz |
Drop the builtin icon cache
We don't need it anymore, now that the non-standard stock icons
are using resources.
Diffstat (limited to 'gtk/deprecated/gtkiconfactory.c')
-rw-r--r-- | gtk/deprecated/gtkiconfactory.c | 19 |
1 files changed, 4 insertions, 15 deletions
diff --git a/gtk/deprecated/gtkiconfactory.c b/gtk/deprecated/gtkiconfactory.c index 47bf9cc760..1169d6d6b6 100644 --- a/gtk/deprecated/gtkiconfactory.c +++ b/gtk/deprecated/gtkiconfactory.c @@ -1454,8 +1454,6 @@ find_and_render_icon_source (GtkIconSet *icon_set, return pixbuf; } -extern GtkIconCache *_builtin_cache; - static GdkPixbuf* render_fallback_image (GtkStyleContext *context, GtkTextDirection direction, @@ -1467,21 +1465,12 @@ render_fallback_image (GtkStyleContext *context, if (fallback_source.type == GTK_ICON_SOURCE_EMPTY) { - gint index; - GdkPixbuf *pixbuf; - - _gtk_icon_theme_ensure_builtin_cache (); - - index = _gtk_icon_cache_get_directory_index (_builtin_cache, "24"); - pixbuf = _gtk_icon_cache_get_icon (_builtin_cache, "image-missing", index); - - g_return_val_if_fail(pixbuf != NULL, NULL); - - gtk_icon_source_set_pixbuf (&fallback_source, pixbuf); - g_object_unref (pixbuf); + fallback_source.type = GTK_ICON_SOURCE_STATIC_ICON_NAME; + fallback_source.source.icon_name = (gchar *)"image-missing"; + fallback_source.direction = GTK_TEXT_DIR_NONE; } - return gtk_render_icon_pixbuf (context, &fallback_source, size); + return render_icon_name_pixbuf (&fallback_source, context, size, 1); } static GdkPixbuf* |