QML UI: add callback to run after app is fully initialized

And then use that to check for pending Intents on Android.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2018-08-09 07:12:32 -07:00
parent b85098d401
commit fbf94d4a7b
3 changed files with 14 additions and 0 deletions

View file

@ -636,6 +636,7 @@ if you have network connectivity and want to sync your data to cloud storage."),
diveList.opacity = 1
rootItem.opacity = 1
pageStack.defaultColumnWidth = Kirigami.Units.gridUnit * 28
manager.appInitialized()
}
/* TODO: Verify where opacity went to.
Behavior on opacity {

View file

@ -1856,3 +1856,15 @@ void QMLManager::showDownloadPage(QString deviceString)
m_pluggedInDeviceName = strdup(qPrintable(name));
emit pluggedInDeviceNameChanged();
}
#if defined(Q_OS_ANDROID)
// implemented in core/android.cpp
void checkPendingIntents();
#endif
void QMLManager::appInitialized()
{
#if defined(Q_OS_ANDROID)
checkPendingIntents();
#endif
}

View file

@ -144,6 +144,7 @@ public:
#endif
public slots:
void appInitialized();
void applicationStateChanged(Qt::ApplicationState state);
void savePreferences();
void saveCloudCredentials();