mirror of
https://github.com/MatsuriDayo/nekoray.git
synced 2025-12-17 12:34:37 +03:00
fix restart
This commit is contained in:
@@ -627,7 +627,9 @@ void MainWindow::on_menu_exit_triggered() {
|
||||
QProcess::startDetached("./updater", QStringList{});
|
||||
} else if (exit_reason == 2) {
|
||||
QDir::setCurrent(QApplication::applicationDirPath());
|
||||
QProcess::startDetached(qEnvironmentVariable("NKR_FROM_LAUNCHER") == "1" ? "./launcher" : QApplication::applicationFilePath(), QStringList{});
|
||||
auto arguments = NekoRay::dataStore->argv;
|
||||
if (arguments.length() > 0) arguments.removeFirst();
|
||||
QProcess::startDetached(qEnvironmentVariable("NKR_FROM_LAUNCHER") == "1" ? "./launcher" : QApplication::applicationFilePath(), arguments);
|
||||
}
|
||||
tray->hide();
|
||||
QCoreApplication::quit();
|
||||
|
||||
Reference in New Issue
Block a user