info-bar: Don't use icons in buttons
This commit is contained in:
parent
30e996eaea
commit
3496c88947
|
@ -90,20 +90,6 @@ set_contents (GtkWidget *area,
|
||||||
gtk_container_add (GTK_CONTAINER (content_area), contents);
|
gtk_container_add (GTK_CONTAINER (content_area), contents);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
info_bar_add_button_with_text (GtkInfoBar *info_bar,
|
|
||||||
const gchar *text,
|
|
||||||
const gchar *icon_name,
|
|
||||||
gint response_id)
|
|
||||||
{
|
|
||||||
GtkWidget *button;
|
|
||||||
GtkWidget *image;
|
|
||||||
|
|
||||||
button = gtk_info_bar_add_button (info_bar, text, response_id);
|
|
||||||
image = gtk_image_new_from_icon_name (icon_name, GTK_ICON_SIZE_BUTTON);
|
|
||||||
gtk_button_set_image (GTK_BUTTON (button), image);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
set_info_bar_text_and_icon (GtkWidget *info_bar,
|
set_info_bar_text_and_icon (GtkWidget *info_bar,
|
||||||
const gchar *icon_name,
|
const gchar *icon_name,
|
||||||
|
@ -169,8 +155,7 @@ create_io_loading_error_info_bar (const gchar *primary_text,
|
||||||
|
|
||||||
if (recoverable_error)
|
if (recoverable_error)
|
||||||
{
|
{
|
||||||
info_bar_add_button_with_text (GTK_INFO_BAR (info_bar), _("_Retry"),
|
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("_Retry"), GTK_RESPONSE_OK);
|
||||||
"view-refresh-symbolic", GTK_RESPONSE_OK);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return info_bar;
|
return info_bar;
|
||||||
|
@ -406,8 +391,7 @@ create_conversion_error_info_bar (const gchar *primary_text,
|
||||||
|
|
||||||
info_bar = gtk_info_bar_new ();
|
info_bar = gtk_info_bar_new ();
|
||||||
|
|
||||||
info_bar_add_button_with_text (GTK_INFO_BAR (info_bar), _("_Retry"),
|
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("_Retry"), GTK_RESPONSE_OK);
|
||||||
"edit-redo-symbolic", GTK_RESPONSE_OK);
|
|
||||||
|
|
||||||
if (edit_anyway)
|
if (edit_anyway)
|
||||||
{
|
{
|
||||||
|
@ -759,8 +743,7 @@ xed_externally_modified_saving_error_info_bar_new (GFile *location,
|
||||||
|
|
||||||
info_bar = gtk_info_bar_new ();
|
info_bar = gtk_info_bar_new ();
|
||||||
|
|
||||||
info_bar_add_button_with_text (GTK_INFO_BAR (info_bar), _("S_ave Anyway"),
|
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("S_ave Anyway"), GTK_RESPONSE_YES);
|
||||||
"document-save-symbolic", GTK_RESPONSE_YES);
|
|
||||||
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("D_on't Save"), GTK_RESPONSE_CANCEL);
|
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("D_on't Save"), GTK_RESPONSE_CANCEL);
|
||||||
gtk_info_bar_set_message_type (GTK_INFO_BAR (info_bar), GTK_MESSAGE_WARNING);
|
gtk_info_bar_set_message_type (GTK_INFO_BAR (info_bar), GTK_MESSAGE_WARNING);
|
||||||
|
|
||||||
|
@ -848,8 +831,7 @@ xed_no_backup_saving_error_info_bar_new (GFile *location,
|
||||||
|
|
||||||
info_bar = gtk_info_bar_new ();
|
info_bar = gtk_info_bar_new ();
|
||||||
|
|
||||||
info_bar_add_button_with_text (GTK_INFO_BAR (info_bar), _("S_ave Anyway"),
|
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("S_ave Anyway"), GTK_RESPONSE_YES);
|
||||||
"document-save-symbolic", GTK_RESPONSE_YES);
|
|
||||||
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("D_on't Save"), GTK_RESPONSE_CANCEL);
|
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("D_on't Save"), GTK_RESPONSE_CANCEL);
|
||||||
gtk_info_bar_set_message_type (GTK_INFO_BAR (info_bar), GTK_MESSAGE_WARNING);
|
gtk_info_bar_set_message_type (GTK_INFO_BAR (info_bar), GTK_MESSAGE_WARNING);
|
||||||
|
|
||||||
|
@ -1069,8 +1051,7 @@ xed_externally_modified_info_bar_new (GFile *location,
|
||||||
|
|
||||||
info_bar = gtk_info_bar_new ();
|
info_bar = gtk_info_bar_new ();
|
||||||
|
|
||||||
info_bar_add_button_with_text (GTK_INFO_BAR (info_bar), _("_Reload"),
|
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("_Reload"), GTK_RESPONSE_OK);
|
||||||
"view-refresh-symbolic", GTK_RESPONSE_OK);
|
|
||||||
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("_Cancel"), GTK_RESPONSE_CANCEL);
|
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("_Cancel"), GTK_RESPONSE_CANCEL);
|
||||||
gtk_info_bar_set_message_type (GTK_INFO_BAR (info_bar), GTK_MESSAGE_WARNING);
|
gtk_info_bar_set_message_type (GTK_INFO_BAR (info_bar), GTK_MESSAGE_WARNING);
|
||||||
|
|
||||||
|
@ -1112,8 +1093,7 @@ xed_invalid_character_info_bar_new (GFile *location)
|
||||||
|
|
||||||
info_bar = gtk_info_bar_new ();
|
info_bar = gtk_info_bar_new ();
|
||||||
|
|
||||||
info_bar_add_button_with_text (GTK_INFO_BAR (info_bar), _("S_ave Anyway"),
|
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar), _("S_ave Anyway"), GTK_RESPONSE_YES);
|
||||||
"document_save-symbolic", GTK_RESPONSE_YES);
|
|
||||||
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar),
|
gtk_info_bar_add_button (GTK_INFO_BAR (info_bar),
|
||||||
_("D_on't Save"),
|
_("D_on't Save"),
|
||||||
GTK_RESPONSE_CANCEL);
|
GTK_RESPONSE_CANCEL);
|
||||||
|
|
Loading…
Reference in New Issue