diff options
author | Matthias Clasen <mclasen@redhat.com> | 2017-11-14 19:43:13 -0500 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2017-11-15 14:22:17 -0500 |
commit | dbfaa9910705a35d3017f1e8e65a9cf52e2f7d9b (patch) | |
tree | a76a5be1cac5ef746c431a00e8b79a93b63f3e10 /gtk/gtksidebarrow.c | |
parent | 049cc6aa013601c4e662c38df408f8956b155f0a (diff) | |
download | gtk+-dbfaa9910705a35d3017f1e8e65a9cf52e2f7d9b.tar.gz |
image: Remove icon-size argument from icon setters
Instead, add a function gtk_image_set_icon_size() for the cases where
overriding the icon size is necessary.
Treat icon sizes the same way as pixel sizes, too. So gtk_image_clear()
no longer unsets the icon size.
Diffstat (limited to 'gtk/gtksidebarrow.c')
-rw-r--r-- | gtk/gtksidebarrow.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/gtk/gtksidebarrow.c b/gtk/gtksidebarrow.c index 26bce9b3b6..0634e5012a 100644 --- a/gtk/gtksidebarrow.c +++ b/gtk/gtksidebarrow.c @@ -225,9 +225,7 @@ gtk_sidebar_row_set_property (GObject *object, if (object != NULL) { self->start_icon = g_object_ref (object); - gtk_image_set_from_gicon (GTK_IMAGE (self->start_icon_widget), - self->start_icon, - GTK_ICON_SIZE_MENU); + gtk_image_set_from_gicon (GTK_IMAGE (self->start_icon_widget), self->start_icon); } else { @@ -243,9 +241,7 @@ gtk_sidebar_row_set_property (GObject *object, if (object != NULL) { self->end_icon = g_object_ref (object); - gtk_image_set_from_gicon (GTK_IMAGE (self->end_icon_widget), - self->end_icon, - GTK_ICON_SIZE_MENU); + gtk_image_set_from_gicon (GTK_IMAGE (self->end_icon_widget), self->end_icon); gtk_widget_show (self->end_icon_widget); } else @@ -411,8 +407,7 @@ gtk_sidebar_row_set_start_icon (GtkSidebarRow *self, { g_set_object (&self->start_icon, icon); if (self->start_icon != NULL) - gtk_image_set_from_gicon (GTK_IMAGE (self->start_icon_widget), self->start_icon, - GTK_ICON_SIZE_MENU); + gtk_image_set_from_gicon (GTK_IMAGE (self->start_icon_widget), self->start_icon); else gtk_image_clear (GTK_IMAGE (self->start_icon_widget)); @@ -430,8 +425,7 @@ gtk_sidebar_row_set_end_icon (GtkSidebarRow *self, { g_set_object (&self->end_icon, icon); if (self->end_icon != NULL) - gtk_image_set_from_gicon (GTK_IMAGE (self->end_icon_widget), self->end_icon, - GTK_ICON_SIZE_MENU); + gtk_image_set_from_gicon (GTK_IMAGE (self->end_icon_widget), self->end_icon); else if (self->end_icon_widget != NULL) gtk_image_clear (GTK_IMAGE (self->end_icon_widget)); |