Merge pull request #2093 from Cacodemon345/patch-53

Fix compile error
This commit is contained in:
Miran Grča
2022-02-10 15:33:03 +01:00
committed by GitHub
2 changed files with 2 additions and 2 deletions

View File

@@ -124,7 +124,7 @@ MainWindow::MainWindow(QWidget *parent) :
this->setWindowFlag(Qt::WindowMaximizeButtonHint, vid_resize == 1);
QString vmname(vm_name);
if (vmname.last(1) == "\"" || vmname.last(1) == "'") vmname.truncate(vmname.size() - 1);
if (vmname.at(vmname.size() - 1) == '"' || vmname.at(vmname.size() - 1) == '\'') vmname.truncate(vmname.size() - 1);
this->setWindowTitle(QString("%1 - %2 %3").arg(vmname, EMU_NAME, EMU_VERSION_FULL));
connect(this, &MainWindow::showMessageForNonQtThread, this, &MainWindow::showMessage_, Qt::BlockingQueuedConnection);

View File

@@ -122,7 +122,7 @@ void ProgSettings::accept()
update_mouse_msg();
main_window->ui->retranslateUi(main_window);
QString vmname(vm_name);
if (vmname.last(1) == "\"" || vmname.last(1) == "'") vmname.truncate(vmname.size() - 1);
if (vmname.at(vmnames.size() - 1) == "\"" || vmname.at(vmnames.size() - 1) == "'") vmname.truncate(vmname.size() - 1);
main_window->setWindowTitle(QString("%1 - %2 %3").arg(vmname, EMU_NAME, EMU_VERSION_FULL));
QString msg = main_window->status->getMessage();
main_window->status.reset(new MachineStatus(main_window));