1
mirror of https://invent.kde.org/network/falkon.git synced 2024-11-11 01:22:10 +01:00

Fix UI strings with plural forms

Otherwise those strings can not be extracted.
This commit is contained in:
Luigi Toscano 2017-09-26 01:37:46 +02:00
parent 11d73bd26a
commit 3c67be06b9
3 changed files with 11 additions and 1 deletions

View File

@ -1348,6 +1348,8 @@ void BrowserWindow::closeEvent(QCloseEvent* event)
if (askOnClose && m_tabWidget->normalTabsCount() > 1) {
CheckBoxDialog dialog(QMessageBox::Yes | QMessageBox::No, this);
//~ singular There is still %n open tab and your session won't be stored.\nAre you sure you want to close this window?
//~ plural There are still %n open tabs and your session won't be stored.\nAre you sure you want to close this window?
dialog.setText(tr("There are still %n open tabs and your session won't be stored.\nAre you sure you want to close this window?", "", m_tabWidget->count()));
dialog.setCheckBoxText(tr("Don't ask again"));
dialog.setWindowTitle(tr("There are still open tabs"));

View File

@ -185,12 +185,18 @@ QString DownloadItem::remaingTimeToString(QTime time)
return tr("few seconds");
}
else if (time < QTime(0, 1)) {
//~ singular %n second
//~ plural %n seconds
return tr("%n seconds", "", time.second());
}
else if (time < QTime(1, 0)) {
//~ singular %n minute
//~ plural %n minutes
return tr("%n minutes", "", time.minute());
}
else {
//~ singular %n hour
//~ plural %n hours
return tr("%n hours", "", time.hour());
}
}

View File

@ -457,6 +457,8 @@ void TabWidget::closeTab(int index)
if (m_menuTabs->isVisible()) {
QAction* labelAction = m_menuTabs->actions().last();
//~ singular Currently you have %n opened tab
//~ plural Currently you have %n opened tabs
labelAction->setText(tr("Currently you have %n opened tab(s)", "", count() - 1));
}