Commit 45cfb405 authored by Matthias Clasen's avatar Matthias Clasen

GtkModelButton: Don't show both text and icon

The intention was that ::iconic indicates which representation is
preferred (text or icon). We fall back to the other representation
if one is missing.
parent d51c9e03
......@@ -205,7 +205,7 @@ update_visibility (GtkModelButton *button)
has_icon = gtk_image_get_storage_type (GTK_IMAGE (button->image)) != GTK_IMAGE_EMPTY;
has_text = gtk_label_get_text (GTK_LABEL (button->label))[0] != '\0';
gtk_widget_set_visible (button->image, has_icon);
gtk_widget_set_visible (button->image, has_icon && (button->iconic || !has_text));
gtk_widget_set_visible (button->label, has_text && (!button->iconic || !has_icon));
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment