History

Merge branch 'master' into menu-updates

vladest committed 8 years ago

Commit 5127cb02 parents a9930d5 aca261a48 files · +1483 −770Browse files

Showing the changes to interface/src/Application.cpp (1 of 48 files). Show all

Unified · Split

interface/src/Application.cpp+15−6
@@ -853,7 +853,11 @@ bool setupEssentials(int& argc, char** argv, bool runningMarkerExisted) { · 852 unmodified lines
853853 DependencyManager::set<Cursor::Manager>();
854854 DependencyManager::set<VirtualPad::Manager>();
855855 DependencyManager::set<DesktopPreviewProvider>();
856+#if defined(Q_OS_ANDROID)
857+ DependencyManager::set<AccountManager>(); // use the default user agent getter
858+#else
856859 DependencyManager::set<AccountManager>(std::bind(&Application::getUserAgent, qApp));
860+#endif
857861 DependencyManager::set<StatTracker>();
858862 DependencyManager::set<ScriptEngines>(ScriptEngine::CLIENT_SCRIPT);
859863 DependencyManager::set<ScriptInitializerMixin, NativeScriptInitializers>();
@@ -2254,6 +2258,11 @@ Application::Application(int& argc, char** argv, QElapsedTimer& startupTimer, bo · 1394 unmodified lines
22542258 _pendingRenderEvent = false;
22552259
22562260 qCDebug(interfaceapp) << "Metaverse session ID is" << uuidStringWithoutCurlyBraces(accountManager->getSessionID());
2261+
2262+#if defined(Q_OS_ANDROID)
2263+ AndroidHelper::instance().init();
2264+ AndroidHelper::instance().notifyLoadComplete();
2265+#endif
22572266 }
22582267
22592268 void Application::updateVerboseLogging() {
@@ -8247,17 +8256,17 @@ void Application::openAndroidActivity(const QString& activityName) { · 5987 unmodified lines
82478256 void Application::enterBackground() {
82488257 QMetaObject::invokeMethod(DependencyManager::get<AudioClient>().data(),
82498258 "stop", Qt::BlockingQueuedConnection);
8250− //GC: commenting it out until we fix it
8251− //getActiveDisplayPlugin()->deactivate();
8259+ if (getActiveDisplayPlugin()->isActive()) {
8260+ getActiveDisplayPlugin()->deactivate();
8261+ }
82528262 }
8263+
82538264 void Application::enterForeground() {
82548265 QMetaObject::invokeMethod(DependencyManager::get<AudioClient>().data(),
82558266 "start", Qt::BlockingQueuedConnection);
8256− //GC: commenting it out until we fix it
8257− /*if (!getActiveDisplayPlugin() || !getActiveDisplayPlugin()->activate()) {
8267+ if (!getActiveDisplayPlugin() || getActiveDisplayPlugin()->isActive() || !getActiveDisplayPlugin()->activate()) {
82588268 qWarning() << "Could not re-activate display plugin";
8259− }*/
8260−
8269+ }
82618270 }
82628271 #endif
82638272

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t