From 7bd4c5d096a48c7488774a9e0cc7f1f41e5b1e82 Mon Sep 17 00:00:00 2001 From: Guillaume Desmottes Date: Fri, 27 Aug 2010 15:55:13 +0200 Subject: fix accelerator conflict with the Apply button (#623164) --- libempathy-gtk/empathy-account-widget.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'libempathy-gtk/empathy-account-widget.c') diff --git a/libempathy-gtk/empathy-account-widget.c b/libempathy-gtk/empathy-account-widget.c index 3f49cbc18..9696f48d8 100644 --- a/libempathy-gtk/empathy-account-widget.c +++ b/libempathy-gtk/empathy-account-widget.c @@ -1466,10 +1466,17 @@ static void set_apply_button (EmpathyAccountWidget *self) { EmpathyAccountWidgetPriv *priv = GET_PRIV (self); + GtkWidget *image; - gtk_button_set_image (GTK_BUTTON (priv->apply_button), NULL); - gtk_button_set_use_stock (GTK_BUTTON (priv->apply_button), TRUE); - gtk_button_set_label (GTK_BUTTON (priv->apply_button), GTK_STOCK_APPLY); + /* We can't use the stock button as its accelerator ('A') clashes with the + * Add button. */ + gtk_button_set_use_stock (GTK_BUTTON (priv->apply_button), FALSE); + + gtk_button_set_label (GTK_BUTTON (priv->apply_button), _("A_pply")); + gtk_button_set_use_underline (GTK_BUTTON (priv->apply_button), TRUE); + + image = gtk_image_new_from_stock (GTK_STOCK_APPLY, GTK_ICON_SIZE_BUTTON); + gtk_button_set_image (GTK_BUTTON (priv->apply_button), image); } static void -- cgit v1.2.3