mirror of
https://github.com/Relintai/sdl2_frt.git
synced 2025-01-17 14:47:19 +01:00
Android: un-needed transition to Pause state.
- Don't need to go into Pause state, since onPause() has been called before. - Don't need to call nativePause is SDLThread is already ended
This commit is contained in:
parent
8dd915507e
commit
61d37de099
@ -390,9 +390,6 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
mNextNativeState = NativeState.PAUSED;
|
|
||||||
SDLActivity.handleNativeState();
|
|
||||||
|
|
||||||
// Send a quit message to the application
|
// Send a quit message to the application
|
||||||
SDLActivity.mExitCalledFromJava = true;
|
SDLActivity.mExitCalledFromJava = true;
|
||||||
SDLActivity.nativeQuit();
|
SDLActivity.nativeQuit();
|
||||||
@ -483,9 +480,12 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
|||||||
|
|
||||||
// Try a transition to paused state
|
// Try a transition to paused state
|
||||||
if (mNextNativeState == NativeState.PAUSED) {
|
if (mNextNativeState == NativeState.PAUSED) {
|
||||||
|
if (mSDLThread != null) {
|
||||||
nativePause();
|
nativePause();
|
||||||
if (mSurface != null)
|
}
|
||||||
|
if (mSurface != null) {
|
||||||
mSurface.handlePause();
|
mSurface.handlePause();
|
||||||
|
}
|
||||||
mCurrentNativeState = mNextNativeState;
|
mCurrentNativeState = mNextNativeState;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user