mirror of
https://github.com/subsurface/subsurface.git
synced 2025-01-19 14:25:27 +00:00
Android: add callback to Java code to check pending Intents
If we get launched by an intent, we need to delay processing that Intent until after the app is initialized. This is the helper function we'll use for that. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
5a9c8f3a5e
commit
b85098d401
1 changed files with 12 additions and 0 deletions
|
@ -239,3 +239,15 @@ bool subsurface_user_is_root()
|
|||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/* called from QML manager */
|
||||
void checkPendingIntents()
|
||||
{
|
||||
QAndroidJniObject activity = QtAndroid::androidActivity();
|
||||
if(activity.isValid()) {
|
||||
activity.callMethod<void>("checkPendingIntents");
|
||||
qDebug() << "checkPendingIntents ";
|
||||
return;
|
||||
}
|
||||
qDebug() << "checkPendingIntents: Activity not valid";
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue