correct current Intent for android

This commit is contained in:
volzhs 2016-06-21 03:32:44 +09:00
parent 3668768463
commit 780fa60072
1 changed files with 13 additions and 1 deletions

View File

@ -115,6 +115,16 @@ public class Godot extends Activity implements SensorEventListener, IDownloaderC
private int mState; private int mState;
private boolean keep_screen_on=true; private boolean keep_screen_on=true;
static private Intent mCurrentIntent;
@Override public void onNewIntent(Intent intent) {
mCurrentIntent = intent;
}
static public Intent getCurrentIntent() {
return mCurrentIntent;
}
private void setState(int newState) { private void setState(int newState) {
if (mState != newState) { if (mState != newState) {
mState = newState; mState = newState;
@ -545,6 +555,8 @@ public class Godot extends Activity implements SensorEventListener, IDownloaderC
} }
} }
mCurrentIntent = getIntent();
initializeGodot(); initializeGodot();