|
|
|
@ -121,9 +121,9 @@ Launcher::FirstRunDialogResult Launcher::MainDialog::showFirstRunDialog()
|
|
|
|
|
if (!create_directories(userConfigDir))
|
|
|
|
|
{
|
|
|
|
|
cfgError(tr("Error opening OpenMW configuration file"),
|
|
|
|
|
tr("<br><b>Could not create directory %0</b><br><br> \
|
|
|
|
|
Please make sure you have the right permissions \
|
|
|
|
|
and try again.<br>")
|
|
|
|
|
tr("<br><b>Could not create directory %0</b><br><br>"
|
|
|
|
|
"Please make sure you have the right permissions "
|
|
|
|
|
"and try again.<br>")
|
|
|
|
|
.arg(Files::pathToQString(canonical(userConfigDir))));
|
|
|
|
|
return FirstRunDialogResultFailure;
|
|
|
|
|
}
|
|
|
|
@ -136,10 +136,10 @@ Launcher::FirstRunDialogResult Launcher::MainDialog::showFirstRunDialog()
|
|
|
|
|
msgBox.setIcon(QMessageBox::Question);
|
|
|
|
|
msgBox.setStandardButtons(QMessageBox::NoButton);
|
|
|
|
|
msgBox.setText(
|
|
|
|
|
tr("<html><head/><body><p><b>Welcome to OpenMW!</b></p> \
|
|
|
|
|
<p>It is recommended to run the Installation Wizard.</p> \
|
|
|
|
|
<p>The Wizard will let you select an existing Morrowind installation, \
|
|
|
|
|
or install Morrowind for OpenMW to use.</p></body></html>"));
|
|
|
|
|
tr("<html><head/><body><p><b>Welcome to OpenMW!</b></p>"
|
|
|
|
|
"<p>It is recommended to run the Installation Wizard.</p>"
|
|
|
|
|
"<p>The Wizard will let you select an existing Morrowind installation, "
|
|
|
|
|
"or install Morrowind for OpenMW to use.</p></body></html>"));
|
|
|
|
|
|
|
|
|
|
QAbstractButton* wizardButton
|
|
|
|
|
= msgBox.addButton(tr("Run &Installation Wizard"), QMessageBox::AcceptRole); // ActionRole doesn't work?!
|
|
|
|
@ -297,9 +297,9 @@ bool Launcher::MainDialog::setupLauncherSettings()
|
|
|
|
|
if (!file.open(QIODevice::ReadOnly | QIODevice::Text))
|
|
|
|
|
{
|
|
|
|
|
cfgError(tr("Error opening OpenMW configuration file"),
|
|
|
|
|
tr("<br><b>Could not open %0 for reading:</b><br><br>%1<br><br> \
|
|
|
|
|
Please make sure you have the right permissions \
|
|
|
|
|
and try again.<br>")
|
|
|
|
|
tr("<br><b>Could not open %0 for reading:</b><br><br>%1<br><br>"
|
|
|
|
|
"Please make sure you have the right permissions "
|
|
|
|
|
"and try again.<br>")
|
|
|
|
|
.arg(file.fileName())
|
|
|
|
|
.arg(file.errorString()));
|
|
|
|
|
return false;
|
|
|
|
@ -327,9 +327,9 @@ bool Launcher::MainDialog::setupGameSettings()
|
|
|
|
|
if (!file.open(QIODevice::ReadOnly | QIODevice::Text))
|
|
|
|
|
{
|
|
|
|
|
cfgError(tr("Error opening OpenMW configuration file"),
|
|
|
|
|
tr("<br><b>Could not open %0 for reading</b><br><br> \
|
|
|
|
|
Please make sure you have the right permissions \
|
|
|
|
|
and try again.<br>")
|
|
|
|
|
tr("<br><b>Could not open %0 for reading</b><br><br>"
|
|
|
|
|
"Please make sure you have the right permissions "
|
|
|
|
|
"and try again.<br>")
|
|
|
|
|
.arg(file.fileName()));
|
|
|
|
|
return {};
|
|
|
|
|
}
|
|
|
|
@ -388,8 +388,8 @@ bool Launcher::MainDialog::setupGameData()
|
|
|
|
|
msgBox.setIcon(QMessageBox::Warning);
|
|
|
|
|
msgBox.setStandardButtons(QMessageBox::NoButton);
|
|
|
|
|
msgBox.setText(
|
|
|
|
|
tr("<br><b>Could not find the Data Files location</b><br><br> \
|
|
|
|
|
The directory containing the data files was not found."));
|
|
|
|
|
tr("<br><b>Could not find the Data Files location</b><br><br>"
|
|
|
|
|
"The directory containing the data files was not found."));
|
|
|
|
|
|
|
|
|
|
QAbstractButton* wizardButton = msgBox.addButton(tr("Run &Installation Wizard..."), QMessageBox::ActionRole);
|
|
|
|
|
QAbstractButton* skipButton = msgBox.addButton(tr("Skip"), QMessageBox::RejectRole);
|
|
|
|
@ -419,8 +419,8 @@ bool Launcher::MainDialog::setupGraphicsSettings()
|
|
|
|
|
catch (std::exception& e)
|
|
|
|
|
{
|
|
|
|
|
cfgError(tr("Error reading OpenMW configuration files"),
|
|
|
|
|
tr("<br>The problem may be due to an incomplete installation of OpenMW.<br> \
|
|
|
|
|
Reinstalling OpenMW may resolve the problem.<br>")
|
|
|
|
|
tr("<br>The problem may be due to an incomplete installation of OpenMW.<br>"
|
|
|
|
|
"Reinstalling OpenMW may resolve the problem.<br>")
|
|
|
|
|
+ e.what());
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
@ -460,9 +460,9 @@ bool Launcher::MainDialog::writeSettings()
|
|
|
|
|
if (!create_directories(userPath))
|
|
|
|
|
{
|
|
|
|
|
cfgError(tr("Error creating OpenMW configuration directory"),
|
|
|
|
|
tr("<br><b>Could not create %0</b><br><br> \
|
|
|
|
|
Please make sure you have the right permissions \
|
|
|
|
|
and try again.<br>")
|
|
|
|
|
tr("<br><b>Could not create %0</b><br><br>"
|
|
|
|
|
"Please make sure you have the right permissions "
|
|
|
|
|
"and try again.<br>")
|
|
|
|
|
.arg(Files::pathToQString(userPath)));
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
@ -479,9 +479,9 @@ bool Launcher::MainDialog::writeSettings()
|
|
|
|
|
{
|
|
|
|
|
// File cannot be opened or created
|
|
|
|
|
cfgError(tr("Error writing OpenMW configuration file"),
|
|
|
|
|
tr("<br><b>Could not open or create %0 for writing</b><br><br> \
|
|
|
|
|
Please make sure you have the right permissions \
|
|
|
|
|
and try again.<br>")
|
|
|
|
|
tr("<br><b>Could not open or create %0 for writing</b><br><br>"
|
|
|
|
|
"Please make sure you have the right permissions "
|
|
|
|
|
"and try again.<br>")
|
|
|
|
|
.arg(file.fileName()));
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
@ -510,9 +510,9 @@ bool Launcher::MainDialog::writeSettings()
|
|
|
|
|
{
|
|
|
|
|
// File cannot be opened or created
|
|
|
|
|
cfgError(tr("Error writing Launcher configuration file"),
|
|
|
|
|
tr("<br><b>Could not open or create %0 for writing</b><br><br> \
|
|
|
|
|
Please make sure you have the right permissions \
|
|
|
|
|
and try again.<br>")
|
|
|
|
|
tr("<br><b>Could not open or create %0 for writing</b><br><br>"
|
|
|
|
|
"Please make sure you have the right permissions "
|
|
|
|
|
"and try again.<br>")
|
|
|
|
|
.arg(file.fileName()));
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
@ -562,8 +562,8 @@ void Launcher::MainDialog::play()
|
|
|
|
|
msgBox.setIcon(QMessageBox::Warning);
|
|
|
|
|
msgBox.setStandardButtons(QMessageBox::Ok);
|
|
|
|
|
msgBox.setText(
|
|
|
|
|
tr("<br><b>You do not have a game file selected.</b><br><br> \
|
|
|
|
|
OpenMW will not start without a game file selected.<br>"));
|
|
|
|
|
tr("<br><b>You do not have a game file selected.</b><br><br>"
|
|
|
|
|
"OpenMW will not start without a game file selected.<br>"));
|
|
|
|
|
msgBox.exec();
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|