Showing the changes to interface/src/Application.cpp (1 of 4 files). Show all
Unified · Split
| @@ -579,15 +579,15 @@ Application::Application(int& argc, char** argv, QElapsedTimer& startupTimer, bo · 578 unmodified lines | ||
| 579 | 579 | |
| 580 | 580 | |
| 581 | 581 | bool wantsSandboxRunning = shouldRunServer(); |
| 582 | − bool determinedSandboxState = false; | |
| 583 | − bool sandboxRunning = false; | |
| 582 | + static bool determinedSandboxState = false; | |
| 583 | + static bool sandboxRunning = false; | |
| 584 | 584 | SandboxUtils sandboxUtils; |
| 585 | 585 | sandboxUtils.ifLocalSandboxRunningElse([&]() { |
| 586 | − qDebug() << "Home sandbox appears to be running....."; | |
| 586 | + qCDebug(interfaceapp) << "Home sandbox appears to be running....."; | |
| 587 | 587 | determinedSandboxState = true; |
| 588 | 588 | sandboxRunning = true; |
| 589 | 589 | }, [&]() { |
| 590 | − qDebug() << "Home sandbox does not appear to be running...."; | |
| 590 | + qCDebug(interfaceapp) << "Home sandbox does not appear to be running...."; | |
| 591 | 591 | determinedSandboxState = true; |
| 592 | 592 | sandboxRunning = false; |
| 593 | 593 | if (wantsSandboxRunning) { |
| @@ -1292,7 +1292,7 @@ Application::Application(int& argc, char** argv, QElapsedTimer& startupTimer, bo · 698 unmodified lines | ||
| 1292 | 1292 | // Get sandbox content set version, if available |
| 1293 | 1293 | auto acDirPath = PathUtils::getRootDataDirectory() + BuildInfo::MODIFIED_ORGANIZATION + "/assignment-client/"; |
| 1294 | 1294 | auto contentVersionPath = acDirPath + "content-version.txt"; |
| 1295 | − qDebug() << "Checking " << contentVersionPath << " for content version"; | |
| 1295 | + qCDebug(interfaceapp) << "Checking " << contentVersionPath << " for content version"; | |
| 1296 | 1296 | auto contentVersion = 0; |
| 1297 | 1297 | QFile contentVersionFile(contentVersionPath); |
| 1298 | 1298 | if (contentVersionFile.open(QIODevice::ReadOnly | QIODevice::Text)) { |
| @@ -1300,7 +1300,7 @@ Application::Application(int& argc, char** argv, QElapsedTimer& startupTimer, bo · 1 unmodified line | ||
| 1300 | 1300 | // toInt() returns 0 if the conversion fails, so we don't need to specifically check for failure |
| 1301 | 1301 | contentVersion = line.toInt(); |
| 1302 | 1302 | } |
| 1303 | − qDebug() << "Server content version: " << contentVersion; | |
| 1303 | + qCDebug(interfaceapp) << "Server content version: " << contentVersion; | |
| 1304 | 1304 | |
| 1305 | 1305 | bool hasTutorialContent = contentVersion >= 1; |
| 1306 | 1306 | |
| @@ -1310,10 +1310,10 @@ Application::Application(int& argc, char** argv, QElapsedTimer& startupTimer, bo · 3 unmodified lines | ||
| 1310 | 1310 | |
| 1311 | 1311 | bool shouldGoToTutorial = hasHMDAndHandControllers && hasTutorialContent && !tutorialComplete.get(); |
| 1312 | 1312 | |
| 1313 | − qDebug() << "Has HMD + Hand Controllers: " << hasHMDAndHandControllers << ", current plugin: " << _displayPlugin->getName(); | |
| 1314 | − qDebug() << "Has tutorial content: " << hasTutorialContent; | |
| 1315 | − qDebug() << "Tutorial complete: " << tutorialComplete.get(); | |
| 1316 | − qDebug() << "Should go to tutorial: " << shouldGoToTutorial; | |
| 1313 | + qCDebug(interfaceapp) << "Has HMD + Hand Controllers: " << hasHMDAndHandControllers << ", current plugin: " << _displayPlugin->getName(); | |
| 1314 | + qCDebug(interfaceapp) << "Has tutorial content: " << hasTutorialContent; | |
| 1315 | + qCDebug(interfaceapp) << "Tutorial complete: " << tutorialComplete.get(); | |
| 1316 | + qCDebug(interfaceapp) << "Should go to tutorial: " << shouldGoToTutorial; | |
| 1317 | 1317 | |
| 1318 | 1318 | // when --url in command line, teleport to location |
| 1319 | 1319 | const QString HIFI_URL_COMMAND_LINE_KEY = "--url"; |
| @@ -1327,10 +1327,10 @@ Application::Application(int& argc, char** argv, QElapsedTimer& startupTimer, bo · 7 unmodified lines | ||
| 1327 | 1327 | |
| 1328 | 1328 | if (shouldGoToTutorial) { |
| 1329 | 1329 | sandboxUtils.ifLocalSandboxRunningElse([=]() { |
| 1330 | − qDebug() << "Home sandbox appears to be running, going to Home."; | |
| 1330 | + qCDebug(interfaceapp) << "Home sandbox appears to be running, going to Home."; | |
| 1331 | 1331 | DependencyManager::get<AddressManager>()->goToLocalSandbox(TUTORIAL_PATH); |
| 1332 | 1332 | }, [=]() { |
| 1333 | − qDebug() << "Home sandbox does not appear to be running, going to Entry."; | |
| 1333 | + qCDebug(interfaceapp) << "Home sandbox does not appear to be running, going to Entry."; | |
| 1334 | 1334 | if (firstRun.get()) { |
| 1335 | 1335 | showHelp(); |
| 1336 | 1336 | } |
| @@ -1352,17 +1352,17 @@ Application::Application(int& argc, char** argv, QElapsedTimer& startupTimer, bo · 15 unmodified lines | ||
| 1352 | 1352 | if (isFirstRun) { |
| 1353 | 1353 | if (hasHMDAndHandControllers) { |
| 1354 | 1354 | sandboxUtils.ifLocalSandboxRunningElse([=]() { |
| 1355 | − qDebug() << "Home sandbox appears to be running, going to Home."; | |
| 1355 | + qCDebug(interfaceapp) << "Home sandbox appears to be running, going to Home."; | |
| 1356 | 1356 | DependencyManager::get<AddressManager>()->goToLocalSandbox(); |
| 1357 | 1357 | }, [=]() { |
| 1358 | − qDebug() << "Home sandbox does not appear to be running, going to Entry."; | |
| 1358 | + qCDebug(interfaceapp) << "Home sandbox does not appear to be running, going to Entry."; | |
| 1359 | 1359 | DependencyManager::get<AddressManager>()->goToEntry(); |
| 1360 | 1360 | }); |
| 1361 | 1361 | } else { |
| 1362 | 1362 | DependencyManager::get<AddressManager>()->goToEntry(); |
| 1363 | 1363 | } |
| 1364 | 1364 | } else { |
| 1365 | − qDebug() << "Not first run... going to" << qPrintable(addressLookupString.isEmpty() ? QString("previous location") : addressLookupString); | |
| 1365 | + qCDebug(interfaceapp) << "Not first run... going to" << qPrintable(addressLookupString.isEmpty() ? QString("previous location") : addressLookupString); | |
| 1366 | 1366 | DependencyManager::get<AddressManager>()->loadSettings(addressLookupString); |
| 1367 | 1367 | } |
| 1368 | 1368 | } |