diff options
author | Cosimo Cecchi <cosimoc@gnome.org> | 2011-11-30 19:46:31 -0500 |
---|---|---|
committer | Cosimo Cecchi <cosimoc@gnome.org> | 2011-11-30 19:47:52 -0500 |
commit | 58b1f24d6d8dab4b844cd8cba3d5888f1deb0510 (patch) | |
tree | c2f7df94776ac5c755f8e6b27a90de77153f25fb /gtk/gtkimage.c | |
parent | 0c682272708f36600fe7000197781277db8c4d77 (diff) | |
download | gtk+-58b1f24d6d8dab4b844cd8cba3d5888f1deb0510.tar.gz |
image: use the default icon size if no icon size is provided
If no icon size is provided (e.g. when setting icon-name or stock-id
using the GObject property directly), use the default icon size. This
matches the previous GtkImage behavior.
Diffstat (limited to 'gtk/gtkimage.c')
-rw-r--r-- | gtk/gtkimage.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gtk/gtkimage.c b/gtk/gtkimage.c index 5f392deebb..2f12541b47 100644 --- a/gtk/gtkimage.c +++ b/gtk/gtkimage.c @@ -380,6 +380,9 @@ gtk_image_set_property (GObject *object, GtkImagePrivate *priv = image->priv; GtkIconSize icon_size = _gtk_icon_helper_get_icon_size (priv->icon_helper); + if (icon_size == GTK_ICON_SIZE_INVALID) + icon_size = DEFAULT_ICON_SIZE; + switch (prop_id) { case PROP_PIXBUF: |