Apply suggestions from code review

Co-authored-by: seth <getchoo@tuta.io>
Signed-off-by: Alexandru Ionut Tripon <alexandru.tripon97@gmail.com>
This commit is contained in:
Alexandru Ionut Tripon 2024-06-25 15:33:11 +03:00 committed by GitHub
parent 4e9e7212a6
commit 555c4a7c59
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 6 additions and 6 deletions

View File

@ -61,7 +61,7 @@ void ManifestDownloadTask::executeTask()
QJsonParseError parse_error{}; QJsonParseError parse_error{};
QJsonDocument doc = QJsonDocument::fromJson(*files, &parse_error); QJsonDocument doc = QJsonDocument::fromJson(*files, &parse_error);
if (parse_error.error != QJsonParseError::NoError) { if (parse_error.error != QJsonParseError::NoError) {
qWarning() << "Error while parsing JSON response at " << parse_error.offset << " reason: " << parse_error.errorString(); qWarning() << "Error while parsing JSON response at " << parse_error.offset << ". Reason: " << parse_error.errorString();
qWarning() << *files; qWarning() << *files;
emitFailed(parse_error.errorString()); emitFailed(parse_error.errorString());
return; return;

View File

@ -56,7 +56,7 @@ void VerifyJavaInstall::executeTask()
if (javaArchitecture == "32" && maxMemAlloc > 2048) { if (javaArchitecture == "32" && maxMemAlloc > 2048) {
emit logLine(tr("Max memory allocation exceeds the supported value.\n" emit logLine(tr("Max memory allocation exceeds the supported value.\n"
"The selected java is 32-bit and doesn't support more than 2048MiB of RAM.\n" "The selected installation of Java is 32-bit and doesn't support more than 2048MiB of RAM.\n"
"The instance may not start due to this."), "The instance may not start due to this."),
MessageLevel::Error); MessageLevel::Error);
} }

View File

@ -161,8 +161,8 @@ void JavaPage::on_javaDetectBtn_clicked()
ui->javaPathTextBox->setText(java->path); ui->javaPathTextBox->setText(java->path);
if (!java->is_64bit && APPLICATION->settings()->get("MaxMemAlloc").toInt() > 2048) { if (!java->is_64bit && APPLICATION->settings()->get("MaxMemAlloc").toInt() > 2048) {
CustomMessageBox::selectable(this, tr("Confirm Selection"), CustomMessageBox::selectable(this, tr("Confirm Selection"),
tr("You selected a 32 bit java version.\n" tr("You selected a 32-bit version of Java.\n"
"This means that will not support more than 2048MiB of RAM.\n" "This installation does not support more than 2048MiB of RAM.\n"
"Please make sure that the maximum memory value is lower."), "Please make sure that the maximum memory value is lower."),
QMessageBox::Warning, QMessageBox::Ok, QMessageBox::Ok) QMessageBox::Warning, QMessageBox::Ok, QMessageBox::Ok)
->exec(); ->exec();

View File

@ -418,8 +418,8 @@ void InstanceSettingsPage::on_javaDetectBtn_clicked()
if (!java->is_64bit && m_settings->get("MaxMemAlloc").toInt() > 2048) { if (!java->is_64bit && m_settings->get("MaxMemAlloc").toInt() > 2048) {
CustomMessageBox::selectable(this, tr("Confirm Selection"), CustomMessageBox::selectable(this, tr("Confirm Selection"),
tr("You selected a 32 bit java version.\n" tr("You selected a 32-bit version of Java.\n"
"This means that will not support more than 2048MiB of RAM.\n" "This installation does not support more than 2048MiB of RAM.\n"
"Please make sure that the maximum memory value is lower."), "Please make sure that the maximum memory value is lower."),
QMessageBox::Warning, QMessageBox::Ok, QMessageBox::Ok) QMessageBox::Warning, QMessageBox::Ok, QMessageBox::Ok)
->exec(); ->exec();