diff options
author | Emmanuele Bassi <ebassi@gnome.org> | 2014-08-21 15:56:12 +0100 |
---|---|---|
committer | Emmanuele Bassi <ebassi@gnome.org> | 2014-08-21 15:56:12 +0100 |
commit | 2ea6219691573420cb6b7f5afffd5c512036b33f (patch) | |
tree | 7c3b96c13356f04c8375a1dddd28452b0e1f19d3 /clutter-gtk | |
parent | f0d77ec24a27b56a332e4634fe03d6ea880a0805 (diff) | |
download | clutter-gtk-2ea6219691573420cb6b7f5afffd5c512036b33f.tar.gz |
texture: Ignore deprecation warnings
The whole GtkClutterTexture class should be deprecated, and replaced by
a GtkClutterPixbuf class that implements the ClutterContent interface.
Diffstat (limited to 'clutter-gtk')
-rw-r--r-- | clutter-gtk/gtk-clutter-texture.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/clutter-gtk/gtk-clutter-texture.c b/clutter-gtk/gtk-clutter-texture.c index 9d46e20..e9c271c 100644 --- a/clutter-gtk/gtk-clutter-texture.c +++ b/clutter-gtk/gtk-clutter-texture.c @@ -30,6 +30,7 @@ #include "config.h" +#define CLUTTER_DISABLE_DEPRECATION_WARNINGS #include "gtk-clutter-texture.h" #include <glib/gi18n-lib.h> @@ -125,7 +126,10 @@ gtk_clutter_texture_set_from_stock (GtkClutterTexture *texture, g_return_val_if_fail (stock_id != NULL, FALSE); g_return_val_if_fail ((icon_size > GTK_ICON_SIZE_INVALID) || (icon_size == -1), FALSE); + G_GNUC_BEGIN_IGNORE_DEPRECATIONS pixbuf = gtk_widget_render_icon_pixbuf (widget, stock_id, icon_size); + G_GNUC_END_IGNORE_DEPRECATIONS + if (pixbuf == NULL) { g_set_error (error, @@ -190,11 +194,13 @@ gtk_clutter_texture_set_from_icon_name (GtkClutterTexture *texture, icon_theme = gtk_icon_theme_get_default (); } + G_GNUC_BEGIN_IGNORE_DEPRECATIONS if (icon_size == -1 || !gtk_icon_size_lookup_for_settings (settings, icon_size, &width, &height)) { width = height = 48; } + G_GNUC_END_IGNORE_DEPRECATIONS pixbuf = gtk_icon_theme_load_icon (icon_theme, icon_name, |