Gtk: use mnemonics in menu

This commit is contained in:
zvon 2020-04-01 15:55:37 +02:00
parent ae2c015fad
commit adf4a11874
4 changed files with 51 additions and 36 deletions

31
cs.po
View File

@ -53,6 +53,9 @@ msgstr "Je toto správný název seriálu?"
msgid "Insert the correct show name:"
msgstr "Zadejte správný název seriálu:"
msgid "_Database"
msgstr "_Databáze"
msgid "Database"
msgstr "Databáze"
@ -302,26 +305,26 @@ msgstr "Pole pro adresář je prázdné"
msgid "Rename confirmation"
msgstr "Potvrzení přejmenování"
msgid "File"
msgstr "Soubor"
msgid "_File"
msgstr "_Soubor"
msgid "Exit"
msgstr "Ukončit"
msgid "_Exit"
msgstr "_Ukončit"
msgid "Update database"
msgstr "Aktualizovat databázi"
msgid "_Update database"
msgstr "_Aktualizovat databázi"
msgid "Refresh database"
msgstr "Obnovit databázi"
msgid "_Refresh database"
msgstr "_Obnovit databázi"
msgid "Clean database"
msgstr "Vyčistit databázi"
msgid "_Clean database"
msgstr "_Vyčistit databázi"
msgid "Manage database"
msgstr "Spravovat databázi"
msgid "_Manage database"
msgstr "_Spravovat databázi"
msgid "Change pattern"
msgstr "Změnit vzor"
msgid "Change _pattern"
msgstr "_Změnit vzor"
msgid "Process"
msgstr "Zpracovat"

View File

@ -53,6 +53,9 @@ msgstr "Is this the right show name?"
msgid "Insert the correct show name:"
msgstr "Insert the correct show name:"
msgid "_Database"
msgstr "_Database"
msgid "Database"
msgstr "Database"
@ -302,26 +305,26 @@ msgstr "Directory field is empty"
msgid "Rename confirmation"
msgstr "Rename confirmation"
msgid "File"
msgstr "File"
msgid "_File"
msgstr "_File"
msgid "Exit"
msgstr "Exit"
msgid "_Exit"
msgstr "_Exit"
msgid "Update database"
msgstr "Update database"
msgid "_Update database"
msgstr "_Update database"
msgid "Refresh database"
msgstr "Refresh database"
msgid "_Refresh database"
msgstr "_Refresh database"
msgid "Clean database"
msgstr "Clean database"
msgid "_Clean database"
msgstr "_Clean database"
msgid "Manage database"
msgstr "Manage database"
msgid "_Manage database"
msgstr "_Manage database"
msgid "Change pattern"
msgstr "Change pattern"
msgid "Change _pattern"
msgstr "Change _pattern"
msgid "Process"
msgstr "Process"

View File

@ -245,6 +245,7 @@ MainWindow::MainWindow( const Glib::RefPtr< Gtk::Application > &ptr )
box->pack_start( *button_quit, false, true );
auto *item = new Gtk::MenuItem();
item->set_use_underline(true);
auto *submenu = new Gtk::Menu();
menu->append( *item );
@ -255,6 +256,7 @@ MainWindow::MainWindow( const Glib::RefPtr< Gtk::Application > &ptr )
// Exit item for File menu
item = new Gtk::MenuItem();
item->set_use_underline(true);
item->set_label( _( EXIT ) );
item->signal_activate().connect(
@ -264,6 +266,7 @@ MainWindow::MainWindow( const Glib::RefPtr< Gtk::Application > &ptr )
// Database menu
item = new Gtk::MenuItem();
item->set_use_underline(true);
submenu = new Gtk::Menu();
item->set_label( _( DATABASE ) );
@ -272,6 +275,7 @@ MainWindow::MainWindow( const Glib::RefPtr< Gtk::Application > &ptr )
// Update database
item = new Gtk::MenuItem();
item->set_use_underline(true);
item->set_label( _( UPDATE_DB ) );
item->signal_activate().connect(
sigc::mem_fun( *this, &MainWindow::dbUpdate ) );
@ -280,6 +284,7 @@ MainWindow::MainWindow( const Glib::RefPtr< Gtk::Application > &ptr )
// Refresh database
item = new Gtk::MenuItem();
item->set_use_underline(true);
item->set_label( _( REFRESH_DB ) );
item->signal_activate().connect(
sigc::mem_fun( *this, &MainWindow::dbRefresh ) );
@ -288,6 +293,7 @@ MainWindow::MainWindow( const Glib::RefPtr< Gtk::Application > &ptr )
// Clean database
item = new Gtk::MenuItem();
item->set_use_underline(true);
item->set_label( _( CLEAN_DB ) );
item->signal_activate().connect(
sigc::mem_fun( *this, &MainWindow::dbClean ) );
@ -296,6 +302,7 @@ MainWindow::MainWindow( const Glib::RefPtr< Gtk::Application > &ptr )
// Manage database
item = new Gtk::MenuItem();
item->set_use_underline(true);
item->set_label( _( MANAGE_DB ) );
item->signal_activate().connect(
sigc::mem_fun( *this, &MainWindow::dbManage ) );
@ -303,6 +310,7 @@ MainWindow::MainWindow( const Glib::RefPtr< Gtk::Application > &ptr )
submenu->append( *item );
item = new Gtk::MenuItem();
item->set_use_underline(true);
item->set_label( _( CHANGE_DB_PATTERN ) );
item->signal_activate().connect(
sigc::mem_fun( *this, &MainWindow::dbPattern ) );

View File

@ -11,7 +11,8 @@
#define SHOW_CONFIRM "Is this the right show name?"
#define SHOW_REENTER "Insert the correct show name:"
#define DATABASE "Database"
#define DATABASE "_Database"
#define GUI_WINDOW_DATABASE "Database"
#define GUI_WINDOW_PROGRESS "Progress"
#define GUI_WINDOW_SEARCH "Select show"
#define GUI_WINDOW_SEASON "Choose seasons"
@ -107,13 +108,13 @@
#define PATTERN_ESC_SEQ "Pattern escape sequences"
#define DIR_EMPTY "Directory field is empty"
#define RENAME_CONFIRM "Rename confirmation"
#define ID_FILE "File"
#define EXIT "Exit"
#define UPDATE_DB "Update database"
#define REFRESH_DB "Refresh database"
#define CLEAN_DB "Clean database"
#define MANAGE_DB "Manage database"
#define CHANGE_DB_PATTERN "Change pattern"
#define ID_FILE "_File"
#define EXIT "_Exit"
#define UPDATE_DB "_Update database"
#define REFRESH_DB "_Refresh database"
#define CLEAN_DB "_Clean database"
#define MANAGE_DB "_Manage database"
#define CHANGE_DB_PATTERN "Change _pattern"
#define PROCESS "Process"
#define CHOOSE_DIR "Choose directory"
#define PATTERN_HELP "Pattern help"