diff options
author | Charles Kerr <charles.kerr@canonical.com> | 2012-04-23 13:27:00 -0500 |
---|---|---|
committer | Charles Kerr <charles.kerr@canonical.com> | 2012-04-23 13:27:00 -0500 |
commit | 0841ca9eeff11ca2c1b8ffb51392ce6192e5dea2 (patch) | |
tree | e9e9b200d1f9840ef7171d571feac6347814f2ff | |
parent | 6984728ec8b7d32962a413288dd52f09d5d4e64b (diff) | |
parent | a8e3ae7fc4119e6ff87247369b9c2d6b46632cd5 (diff) | |
download | libdbusmenu-0841ca9eeff11ca2c1b8ffb51392ce6192e5dea2.tar.gz libdbusmenu-0841ca9eeff11ca2c1b8ffb51392ce6192e5dea2.tar.bz2 libdbusmenu-0841ca9eeff11ca2c1b8ffb51392ce6192e5dea2.zip |
merge lp:~ted/dbusmenu/lp982656 to set the widget for the accelerator even if there isn't a mnemonic.
-rw-r--r-- | libdbusmenu-gtk/genericmenuitem.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/libdbusmenu-gtk/genericmenuitem.c b/libdbusmenu-gtk/genericmenuitem.c index 81d67fe..348a972 100644 --- a/libdbusmenu-gtk/genericmenuitem.c +++ b/libdbusmenu-gtk/genericmenuitem.c @@ -335,10 +335,10 @@ set_label (GtkMenuItem * menu_item, const gchar * in_label) labelw = GTK_LABEL(gtk_accel_label_new(local_label)); gtk_label_set_use_markup(GTK_LABEL(labelw), TRUE); gtk_misc_set_alignment(GTK_MISC(labelw), 0.0, 0.5); + gtk_accel_label_set_accel_widget(GTK_ACCEL_LABEL(labelw), GTK_WIDGET(menu_item)); if (has_mnemonic(in_label, FALSE)) { gtk_label_set_use_underline(GTK_LABEL(labelw), TRUE); - gtk_accel_label_set_accel_widget(GTK_ACCEL_LABEL(labelw), GTK_WIDGET(menu_item)); gtk_label_set_markup_with_mnemonic(labelw, local_label); } else { gchar * sanitized = sanitize_label(local_label); @@ -365,7 +365,6 @@ set_label (GtkMenuItem * menu_item, const gchar * in_label) } else { if (has_mnemonic(in_label, FALSE)) { gtk_label_set_use_underline(GTK_LABEL(labelw), TRUE); - gtk_accel_label_set_accel_widget(GTK_ACCEL_LABEL(labelw), GTK_WIDGET(menu_item)); gtk_label_set_markup_with_mnemonic(labelw, local_label); } else { gchar * sanitized = sanitize_label(local_label); |