diff options
-rw-r--r-- | src/trg-menu-bar.c | 41 |
1 files changed, 21 insertions, 20 deletions
diff --git a/src/trg-menu-bar.c b/src/trg-menu-bar.c index 674b012..606b590 100644 --- a/src/trg-menu-bar.c +++ b/src/trg-menu-bar.c @@ -193,6 +193,7 @@ GtkWidget *trg_menu_bar_item_new(GtkMenuShell * shell, char *text, gtk_image_menu_item_set_always_show_image(GTK_IMAGE_MENU_ITEM (item), TRUE); + gtk_menu_item_set_use_underline(GTK_MENU_ITEM(item), TRUE); gtk_menu_item_set_label(GTK_MENU_ITEM(item), text); gtk_widget_set_sensitive(item, sensitive); @@ -203,7 +204,7 @@ GtkWidget *trg_menu_bar_item_new(GtkMenuShell * shell, char *text, static GtkWidget *trg_menu_bar_view_menu_new(TrgMenuBarPrivate * priv) { - GtkWidget *view = gtk_menu_item_new_with_label("View"); + GtkWidget *view = gtk_menu_item_new_with_mnemonic("_View"); GtkWidget *viewMenu = gtk_menu_new(); gtk_menu_item_set_submenu(GTK_MENU_ITEM(view), viewMenu); @@ -213,11 +214,11 @@ static GtkWidget *trg_menu_bar_view_menu_new(TrgMenuBarPrivate * priv) (priv->mb_view_states), TRUE); priv->mb_view_notebook = - gtk_check_menu_item_new_with_label("Torrent details"); + gtk_check_menu_item_new_with_mnemonic("Torrent _details"); gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM (priv->mb_view_notebook), TRUE); - priv->mb_view_stats = gtk_menu_item_new_with_label("Statistics"); + priv->mb_view_stats = gtk_menu_item_new_with_mnemonic("_Statistics"); gtk_menu_shell_append(GTK_MENU_SHELL(viewMenu), priv->mb_view_states); gtk_menu_shell_append(GTK_MENU_SHELL(viewMenu), @@ -230,18 +231,18 @@ static GtkWidget *trg_menu_bar_view_menu_new(TrgMenuBarPrivate * priv) static GtkWidget *trg_menu_bar_options_menu_new(TrgMenuBarPrivate * priv) { - GtkWidget *opts = gtk_menu_item_new_with_label("Options"); + GtkWidget *opts = gtk_menu_item_new_with_mnemonic("_Options"); GtkWidget *optsMenu = gtk_menu_new(); gtk_menu_item_set_submenu(GTK_MENU_ITEM(opts), optsMenu); priv->mb_local_prefs = trg_menu_bar_item_new(GTK_MENU_SHELL(optsMenu), - "Local Preferences", + "_Local Preferences", GTK_STOCK_PREFERENCES, TRUE); priv->mb_remote_prefs = trg_menu_bar_item_new(GTK_MENU_SHELL(optsMenu), - "Remote Preferences", + "_Remote Preferences", GTK_STOCK_NETWORK, FALSE); return opts; @@ -250,24 +251,24 @@ GtkWidget *trg_menu_bar_options_menu_new(TrgMenuBarPrivate * priv) static GtkWidget *trg_menu_bar_file_file_menu_new(TrgMenuBarPrivate * priv) { - GtkWidget *file = gtk_menu_item_new_with_label("File"); + GtkWidget *file = gtk_menu_item_new_with_mnemonic("_File"); GtkWidget *fileMenu = gtk_menu_new(); gtk_menu_item_set_submenu(GTK_MENU_ITEM(file), fileMenu); priv->mb_connect = - trg_menu_bar_item_new(GTK_MENU_SHELL(fileMenu), "Connect", + trg_menu_bar_item_new(GTK_MENU_SHELL(fileMenu), "_Connect", GTK_STOCK_CONNECT, TRUE); priv->mb_disconnect = - trg_menu_bar_item_new(GTK_MENU_SHELL(fileMenu), "Disconnect", + trg_menu_bar_item_new(GTK_MENU_SHELL(fileMenu), "_Disconnect", GTK_STOCK_DISCONNECT, FALSE); priv->mb_add = - trg_menu_bar_item_new(GTK_MENU_SHELL(fileMenu), "Add", + trg_menu_bar_item_new(GTK_MENU_SHELL(fileMenu), "_Add", GTK_STOCK_ADD, FALSE); priv->mb_add_url = - trg_menu_bar_item_new(GTK_MENU_SHELL(fileMenu), "Add from URL", + trg_menu_bar_item_new(GTK_MENU_SHELL(fileMenu), "Add from _URL", GTK_STOCK_ADD, FALSE); - priv->mb_quit = trg_menu_bar_item_new(GTK_MENU_SHELL(fileMenu), "Quit", + priv->mb_quit = trg_menu_bar_item_new(GTK_MENU_SHELL(fileMenu), "_Quit", GTK_STOCK_QUIT, TRUE); return file; @@ -276,7 +277,7 @@ GtkWidget *trg_menu_bar_file_file_menu_new(TrgMenuBarPrivate * priv) static GtkWidget *trg_menu_bar_torrent_menu_new(TrgMenuBarPrivate * priv) { - GtkWidget *torrent = gtk_menu_item_new_with_label("Torrent"); + GtkWidget *torrent = gtk_menu_item_new_with_mnemonic("_Torrent"); GtkWidget *torrentMenu = gtk_menu_new(); gtk_menu_item_set_submenu(GTK_MENU_ITEM(torrent), torrentMenu); @@ -284,19 +285,19 @@ GtkWidget *trg_menu_bar_torrent_menu_new(TrgMenuBarPrivate * priv) trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "Properties", GTK_STOCK_PROPERTIES, FALSE); priv->mb_resume = - trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "Resume", + trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "_Resume", GTK_STOCK_MEDIA_PLAY, FALSE); priv->mb_pause = - trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "Pause", + trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "_Pause", GTK_STOCK_MEDIA_PAUSE, FALSE); priv->mb_verify = - trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "Verify", + trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "_Verify", GTK_STOCK_REFRESH, FALSE); priv->mb_reannounce = - trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "Re-announce", + trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "Re-_announce", GTK_STOCK_REFRESH, FALSE); priv->mb_move = - trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "Move", + trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "_Move", GTK_STOCK_HARDDISK, FALSE); priv->mb_remove = trg_menu_bar_item_new(GTK_MENU_SHELL(torrentMenu), "Remove", @@ -314,13 +315,13 @@ GtkWidget *trg_menu_bar_help_menu_new(TrgMenuBar * menuBar) { TrgMenuBarPrivate *priv = TRG_MENU_BAR_GET_PRIVATE(menuBar); - GtkWidget *help = gtk_menu_item_new_with_label("Help"); + GtkWidget *help = gtk_menu_item_new_with_mnemonic("_Help"); GtkWidget *helpMenu = gtk_menu_new(); gtk_menu_item_set_submenu(GTK_MENU_ITEM(help), helpMenu); gtk_menu_shell_append(GTK_MENU_SHELL(menuBar), help); priv->mb_about = - trg_menu_bar_item_new(GTK_MENU_SHELL(helpMenu), "About", + trg_menu_bar_item_new(GTK_MENU_SHELL(helpMenu), "_About", GTK_STOCK_ABOUT, TRUE); return helpMenu; |