summaryrefslogtreecommitdiffstats
path: root/gui
diff options
context:
space:
mode:
authorStiepen22 <stiepen22@gmx.de>2013-09-08 18:13:09 +0200
committerStiepen22 <stiepen22@gmx.de>2013-09-08 18:13:09 +0200
commit31e5a0fe6d75e124bc772faafcef2618e16c3dbf (patch)
treea49f2cd2669423fb185baaa6fed78370c3ae3e45 /gui
parentcbf3238f0e4d761ff34c9469f1ec88bd937152a5 (diff)
downloadMultiMC-31e5a0fe6d75e124bc772faafcef2618e16c3dbf.tar
MultiMC-31e5a0fe6d75e124bc772faafcef2618e16c3dbf.tar.gz
MultiMC-31e5a0fe6d75e124bc772faafcef2618e16c3dbf.tar.lz
MultiMC-31e5a0fe6d75e124bc772faafcef2618e16c3dbf.tar.xz
MultiMC-31e5a0fe6d75e124bc772faafcef2618e16c3dbf.zip
Changed all strings displayed to end user to use qts localization system
Diffstat (limited to 'gui')
-rw-r--r--gui/EditNotesDialog.cpp2
-rw-r--r--gui/IconPickerDialog.cpp9
-rw-r--r--gui/LegacyModEditDialog.cpp12
-rw-r--r--gui/OneSixModEditDialog.cpp4
-rw-r--r--gui/consolewindow.cpp3
-rw-r--r--gui/logindialog.cpp8
-rw-r--r--gui/lwjglselectdialog.cpp2
-rw-r--r--gui/mainwindow.cpp4
-rw-r--r--gui/settingsdialog.cpp12
9 files changed, 32 insertions, 24 deletions
diff --git a/gui/EditNotesDialog.cpp b/gui/EditNotesDialog.cpp
index 6cc389f6..5b90ef53 100644
--- a/gui/EditNotesDialog.cpp
+++ b/gui/EditNotesDialog.cpp
@@ -12,7 +12,7 @@ EditNotesDialog::EditNotesDialog( QString notes, QString name, QWidget* parent )
{
ui->setupUi(this);
ui->noteEditor->setText(notes);
- setWindowTitle("Edit notes of " + m_instance_name);
+ setWindowTitle(tr("Edit notes of %1").arg(m_instance_name));
//connect(ui->closeButton, SIGNAL(clicked()), SLOT(close()));
}
diff --git a/gui/IconPickerDialog.cpp b/gui/IconPickerDialog.cpp
index 2dd80292..f3947d21 100644
--- a/gui/IconPickerDialog.cpp
+++ b/gui/IconPickerDialog.cpp
@@ -41,8 +41,8 @@ IconPickerDialog::IconPickerDialog(QWidget *parent) :
contentsWidget->setModel(MMC->icons());
- auto buttonAdd = ui->buttonBox->addButton("Add Icon",QDialogButtonBox::ResetRole);
- auto buttonRemove = ui->buttonBox->addButton("Remove Icon",QDialogButtonBox::ResetRole);
+ auto buttonAdd = ui->buttonBox->addButton(tr("Add Icon"),QDialogButtonBox::ResetRole);
+ auto buttonRemove = ui->buttonBox->addButton(tr("Remove Icon"),QDialogButtonBox::ResetRole);
connect(buttonAdd,SIGNAL(clicked(bool)),SLOT(addNewIcon()));
@@ -87,7 +87,10 @@ bool IconPickerDialog::eventFilter ( QObject* obj, QEvent* evt)
void IconPickerDialog::addNewIcon()
{
- QStringList fileNames = QFileDialog::getOpenFileNames(this, "Select Icons", QString(), "Icons (*.png *.jpg *.jpeg)");
+ //: The title of the select icons open file dialog
+ QString selectIcons = tr("Select Icons");
+ //: The type of icon files
+ QStringList fileNames = QFileDialog::getOpenFileNames(this, selectIcons, QString(), tr("Icons") + "(*.png *.jpg *.jpeg)");
MMC->icons()->installIcons(fileNames);
}
diff --git a/gui/LegacyModEditDialog.cpp b/gui/LegacyModEditDialog.cpp
index 616fc050..c336f837 100644
--- a/gui/LegacyModEditDialog.cpp
+++ b/gui/LegacyModEditDialog.cpp
@@ -183,7 +183,8 @@ bool LegacyModEditDialog::eventFilter ( QObject* obj, QEvent* ev )
void LegacyModEditDialog::on_addCoreBtn_clicked()
{
- QStringList fileNames = QFileDialog::getOpenFileNames(this, "Select Core Mods");
+ //: Title of core mod selection dialog
+ QStringList fileNames = QFileDialog::getOpenFileNames(this, tr("Select Core Mods"));
for(auto filename:fileNames)
{
m_coremods->stopWatching();
@@ -197,7 +198,8 @@ void LegacyModEditDialog::on_addForgeBtn_clicked()
}
void LegacyModEditDialog::on_addJarBtn_clicked()
{
- QStringList fileNames = QFileDialog::getOpenFileNames(this, "Select Jar Mods");
+ //: Title of jar mod selection dialog
+ QStringList fileNames = QFileDialog::getOpenFileNames(this, tr("Select Jar Mods"));
for(auto filename:fileNames)
{
m_jarmods->stopWatching();
@@ -207,7 +209,8 @@ void LegacyModEditDialog::on_addJarBtn_clicked()
}
void LegacyModEditDialog::on_addModBtn_clicked()
{
- QStringList fileNames = QFileDialog::getOpenFileNames(this, "Select Loader Mods");
+ //: Title of regular mod selection dialog
+ QStringList fileNames = QFileDialog::getOpenFileNames(this, tr("Select Loader Mods"));
for(auto filename:fileNames)
{
m_mods->stopWatching();
@@ -217,7 +220,8 @@ void LegacyModEditDialog::on_addModBtn_clicked()
}
void LegacyModEditDialog::on_addTexPackBtn_clicked()
{
- QStringList fileNames = QFileDialog::getOpenFileNames(this, "Select Texture Packs");
+ //: Title of texture pack selection dialog
+ QStringList fileNames = QFileDialog::getOpenFileNames(this, tr("Select Texture Packs"));
for(auto filename:fileNames)
{
m_texturepacks->stopWatching();
diff --git a/gui/OneSixModEditDialog.cpp b/gui/OneSixModEditDialog.cpp
index 8e738fa1..15ff09a5 100644
--- a/gui/OneSixModEditDialog.cpp
+++ b/gui/OneSixModEditDialog.cpp
@@ -112,7 +112,7 @@ void OneSixModEditDialog::on_buttonBox_rejected()
void OneSixModEditDialog::on_addModBtn_clicked()
{
- QStringList fileNames = QFileDialog::getOpenFileNames(this, "Select Loader Mods");
+ QStringList fileNames = QFileDialog::getOpenFileNames(this, QApplication::translate("LegacyModEditDialog", "Select Loader Mods");
for(auto filename:fileNames)
{
m_mods->stopWatching();
@@ -139,7 +139,7 @@ void OneSixModEditDialog::on_viewModBtn_clicked()
void OneSixModEditDialog::on_addResPackBtn_clicked()
{
- QStringList fileNames = QFileDialog::getOpenFileNames(this, "Select Resource Packs");
+ QStringList fileNames = QFileDialog::getOpenFileNames(this, QApplication::translate("LegacyModEditDialog", "Select Resource Packs"));
for(auto filename:fileNames)
{
m_resourcepacks->stopWatching();
diff --git a/gui/consolewindow.cpp b/gui/consolewindow.cpp
index 8ea90d45..392eb50d 100644
--- a/gui/consolewindow.cpp
+++ b/gui/consolewindow.cpp
@@ -89,7 +89,8 @@ void ConsoleWindow::on_btnKillMinecraft_clicked()
{
ui->btnKillMinecraft->setEnabled(false);
QMessageBox r_u_sure;
- r_u_sure.setText("Kill Minecraft?");
+ //: Main question of the kill confirmation dialog
+ r_u_sure.setText(tr("Kill Minecraft?"));
r_u_sure.setInformativeText("This can cause the instance to get corrupted and should only be used if Minecraft is frozen for some reason");
r_u_sure.setStandardButtons(QMessageBox::Yes | QMessageBox::No);
r_u_sure.setDefaultButton(QMessageBox::Yes);
diff --git a/gui/logindialog.cpp b/gui/logindialog.cpp
index a4dad1c1..37e30c85 100644
--- a/gui/logindialog.cpp
+++ b/gui/logindialog.cpp
@@ -24,8 +24,8 @@ LoginDialog::LoginDialog(QWidget *parent, const QString& loginErrMsg) :
{
ui->setupUi(this);
- //TODO: make translateable
- offlineButton = new QPushButton("Offline Once");
+ //: Use offline mode one time
+ offlineButton = new QPushButton(tr("Offline Once"));
ui->loginButtonBox->addButton(offlineButton, QDialogButtonBox::ActionRole);
@@ -33,8 +33,8 @@ LoginDialog::LoginDialog(QWidget *parent, const QString& loginErrMsg) :
isOnline_ = true;
onlineForced = false;
- //FIXME: translateable?
- ui->usernameTextBox->lineEdit()->setPlaceholderText(QApplication::translate("LoginDialog", "Name", 0));
+ //: The username during login (placeholder)
+ ui->usernameTextBox->lineEdit()->setPlaceholderText(tr("Name"));
connect(ui->usernameTextBox, SIGNAL(currentTextChanged(QString)), this, SLOT(userTextChanged(QString)));
connect(ui->forgetButton, SIGNAL(clicked(bool)), this, SLOT(forgetCurrentUser()));
diff --git a/gui/lwjglselectdialog.cpp b/gui/lwjglselectdialog.cpp
index 9de92754..c3215b7b 100644
--- a/gui/lwjglselectdialog.cpp
+++ b/gui/lwjglselectdialog.cpp
@@ -54,7 +54,7 @@ void LWJGLSelectDialog::loadingStateUpdated(bool loading)
setEnabled(!loading);
if (loading)
{
- ui->labelStatus->setText("Loading LWJGL version list...");
+ ui->labelStatus->setText(tr("Loading LWJGL version list..."));
ui->labelStatus->setStyleSheet("QLabel { color: black; }");
}
ui->labelStatus->setVisible(loading);
diff --git a/gui/mainwindow.cpp b/gui/mainwindow.cpp
index 7ddc66a9..747df047 100644
--- a/gui/mainwindow.cpp
+++ b/gui/mainwindow.cpp
@@ -587,7 +587,7 @@ void MainWindow::on_actionMakeDesktopShortcut_triggered()
Util::createShortCut ( Util::getDesktopDir(), QApplication::instance()->applicationFilePath(), QStringList() << "-dl" << QDir::currentPath() << "test", name, "application-x-octet-stream" );
- QMessageBox::warning ( this, "Not useful", "A Dummy Shortcut was created. it will not do anything productive" );
+ QMessageBox::warning ( this, tr("Not useful"), tr("A Dummy Shortcut was created. it will not do anything productive") );
}
// BrowserDialog
@@ -658,7 +658,7 @@ void MainWindow::selectionBad()
QString iconKey = "infinity";
statusBar()->clearMessage();
ui->instanceToolBar->setEnabled(false);
- renameButton->setText("Rename Instance");
+ renameButton->setText(tr("Rename Instance"));
auto ico = MMC->icons()->getIcon(iconKey);
ui->actionChangeInstIcon->setIcon(ico);
}
diff --git a/gui/settingsdialog.cpp b/gui/settingsdialog.cpp
index a1fbb8e7..a5283b36 100644
--- a/gui/settingsdialog.cpp
+++ b/gui/settingsdialog.cpp
@@ -49,7 +49,7 @@ void SettingsDialog::updateCheckboxStuff()
void SettingsDialog::on_instDirBrowseBtn_clicked()
{
- QString dir = QFileDialog::getExistingDirectory(this, "Instance Directory",
+ QString dir = QFileDialog::getExistingDirectory(this, tr("Instance Directory"),
ui->instDirTextBox->text());
if (!dir.isEmpty())
ui->instDirTextBox->setText(dir);
@@ -57,7 +57,7 @@ void SettingsDialog::on_instDirBrowseBtn_clicked()
void SettingsDialog::on_modsDirBrowseBtn_clicked()
{
- QString dir = QFileDialog::getExistingDirectory(this, "Mods Directory",
+ QString dir = QFileDialog::getExistingDirectory(this, tr("Mods Directory"),
ui->modsDirTextBox->text());
if (!dir.isEmpty())
ui->modsDirTextBox->setText(dir);
@@ -65,7 +65,7 @@ void SettingsDialog::on_modsDirBrowseBtn_clicked()
void SettingsDialog::on_lwjglDirBrowseBtn_clicked()
{
- QString dir = QFileDialog::getExistingDirectory(this, "LWJGL Directory",
+ QString dir = QFileDialog::getExistingDirectory(this, tr("LWJGL Directory"),
ui->lwjglDirTextBox->text());
if (!dir.isEmpty())
ui->lwjglDirTextBox->setText(dir);
@@ -99,9 +99,9 @@ void SettingsDialog::applySettings(SettingsObject *s)
}
else if (!s->get("UseDevBuilds").toBool())
{
- int response = QMessageBox::question(this, "Development builds",
- "Development builds contain experimental features "
- "and may be unstable. Are you sure you want to enable them?");
+ int response = QMessageBox::question(this, tr("Development builds"),
+ tr("Development builds contain experimental features "
+ "and may be unstable. Are you sure you want to enable them?"));
if (response == QMessageBox::Yes)
{
s->set("UseDevBuilds", true);