| 348 | } |
| 349 | |
| 350 | void LauncherWindow::play() |
| 351 | { |
| 352 | saveConfig(); |
| 353 | this->currentFramework.reset(); |
| 354 | |
| 355 | #ifdef _WIN32 |
| 356 | QString path = "OpenApoc.exe"; |
| 357 | #else |
| 358 | QString path = QCoreApplication::applicationDirPath() + "/OpenApoc"; |
| 359 | #endif |
| 360 | |
| 361 | LogWarning("Running \"%s\"", path.toStdString()); |
| 362 | const auto ret = QProcess::startDetached(path, {}); |
| 363 | if (!ret) |
| 364 | { |
| 365 | LogError("Failed to start OpenApoc process"); |
| 366 | } |
| 367 | this->exit(); |
| 368 | } |
| 369 | |
| 370 | void LauncherWindow::browseCDFile() |
| 371 | { |