Showing the changes to interface/src/Application.cpp (1 of 10 files). Show all
Unified · Split
| @@ -480,6 +480,12 @@ bool setupEssentials(int& argc, char** argv, bool runningMarkerExisted) { · 479 unmodified lines | |||
| 480 | static const auto SUPPRESS_SETTINGS_RESET = "--suppress-settings-reset"; | 480 | static const auto SUPPRESS_SETTINGS_RESET = "--suppress-settings-reset"; |
| 481 | bool suppressPrompt = cmdOptionExists(argc, const_cast<const char**>(argv), SUPPRESS_SETTINGS_RESET); | 481 | bool suppressPrompt = cmdOptionExists(argc, const_cast<const char**>(argv), SUPPRESS_SETTINGS_RESET); |
| 482 | bool previousSessionCrashed = CrashHandler::checkForResetSettings(runningMarkerExisted, suppressPrompt); | 482 | bool previousSessionCrashed = CrashHandler::checkForResetSettings(runningMarkerExisted, suppressPrompt); |
| 483 | // get dir to use for cache | ||
| 484 | static const auto CACHE_SWITCH = "--cache"; | ||
| 485 | QString cacheDir = getCmdOption(argc, const_cast<const char**>(argv), CACHE_SWITCH); | ||
| 486 | if (!cacheDir.isEmpty()) { | ||
| 487 | qApp->setProperty(hifi::properties::APP_LOCAL_DATA_PATH, cacheDir); | ||
| 488 | } | ||
| 483 | 489 | ||
| 484 | Setting::init(); | 490 | Setting::init(); |
| 485 | 491 | ||
| @@ -1218,8 +1224,8 @@ Application::Application(int& argc, char** argv, QElapsedTimer& startupTimer, bo · 732 unmodified lines | |||
| 1218 | settingsTimer->stop(); | 1224 | settingsTimer->stop(); |
| 1219 | // Delete it (this will trigger the thread destruction | 1225 | // Delete it (this will trigger the thread destruction |
| 1220 | settingsTimer->deleteLater(); | 1226 | settingsTimer->deleteLater(); |
| 1221 | // Mark the settings thread as finished, so we know we can safely save in the main application | 1227 | // Mark the settings thread as finished, so we know we can safely save in the main application |
| 1222 | // shutdown code | 1228 | // shutdown code |
| 1223 | _settingsGuard.trigger(); | 1229 | _settingsGuard.trigger(); |
| 1224 | }); | 1230 | }); |
| 1225 | 1231 | ||