Moved the "Clear history" menu item caption from MainWindow (Database > Recent Databases > Clear history) to the string resources. As a result it is no longer hardcoded and can be translated.

This commit is contained in:
Vladimir Svyatski 2017-04-18 16:04:32 +03:00 committed by Jonathan White
parent 70bd598ead
commit 52a264cc2b
3 changed files with 10 additions and 2 deletions

View File

@ -1287,6 +1287,10 @@ This is a one-way migration. You won't be able to open the imported databas
<source>Password Generator</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Clear history</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>OptionDialog</name>

View File

@ -1291,6 +1291,10 @@ This is a one-way migration. You won&apos;t be able to open the imported databas
<source>Password Generator</source>
<translation>Генератор паролей</translation>
</message>
<message>
<source>Clear history</source>
<translation>Очистить историю</translation>
</message>
</context>
<context>
<name>OptionDialog</name>
@ -1789,4 +1793,4 @@ give it a unique name to identify and accept it.</source>
<translation>имена файлов открываемого хранилища паролей (*.kdbx)</translation>
</message>
</context>
</TS>
</TS>

View File

@ -130,7 +130,7 @@ MainWindow::MainWindow()
m_ui->toolBar->setVisible(showToolbar);
connect(m_ui->toolBar, SIGNAL(visibilityChanged(bool)), this, SLOT(saveToolbarState(bool)));
m_clearHistoryAction = new QAction("Clear history", m_ui->menuFile);
m_clearHistoryAction = new QAction(tr("Clear history"), m_ui->menuFile);
m_lastDatabasesActions = new QActionGroup(m_ui->menuRecentDatabases);
connect(m_clearHistoryAction, SIGNAL(triggered()), this, SLOT(clearLastDatabases()));
connect(m_lastDatabasesActions, SIGNAL(triggered(QAction*)), this, SLOT(openRecentDatabase(QAction*)));