You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This bug report was migrated from our old Bugzilla tracker.
Reported in version: HG 2.0 Reported for operating system, platform: Android (All), Other
Comments on the original bug report:
On 2018-02-25 16:57:24 +0000, Olli Kallioinen wrote:
I've gathered that nowadays hiding the Android navigation is done by providing the SDL_WINDOW_FULLSCREEN flag when creating the window.
This works OK on my actual Android device, but when I try the same app on the emulator, It keeps hiding and showing the navigation/title bars again and again in a loop.
The Android version I have on the emulator is showing a hint screen to the user about fullscreen mode (how to disable it) and I believe that might be causing the problem. I don't get this hint popup on my actual device.
The emulator I was using was Android 7.1.1 (API level 25).
I can investigate more a bit later if you are not able to reproduce this easily.
On 2018-02-25 17:44:10 +0000, Sam Lantinga wrote:
It sounds like Android doesn't know your application can handle screen size changes.
Can you check to make sure your app has these set for your activity in AndroidManifest.xml?
android:configChanges="keyboard|keyboardHidden|orientation|screenSize"
On 2018-02-25 19:37:04 +0000, Olli Kallioinen wrote:
Yep, I have those set. I'll try to investigate a bit too.
Seems that the hint popup gives an onWindowFocusChanged() event that causes a call to handleNativeState() that calls nativePause().
Then pause is calling: SDL_OnWindowMinimized() that again calls: SDL_UpdateFullscreenMode() maybe that causes the loop.
I'm relatively sure that if you have an Android version that shows this fullscreen hint popup (I don't remember seeing it on older versions). You could reproduce the problem. Although I'm not sure what the logic is for showing the popup, maybe it is only shown on the first run of the program.
On 2018-02-26 10:51:20 +0000, Olli Kallioinen wrote:
Probably a related issue on an Android device that has a software navigation bar (not hardware buttons):
start app so that it's fullscreen
swipe (twice) from the top to bring up the notifications
press back
Expected behavior:
The app return to focus in fullscreen mode
Actual behavior:
sometimes the navigation buttons are not hidden automatically, and even when they are, the navigation bar does not animate away smoothly but jerks a bit. Probably there are again some extra window state events that restart the animation or sometimes prevent it depending on the event timing.
(I was using the same project that I linked above on a nexus 4)
On 2018-02-27 11:48:31 +0000, Olli Kallioinen wrote:
I did a bit more testing with a few different versions of Android. Mostly with the emulator as I only have one device here (actually the device is a nexus 5 with android 6.0.1 and not nexus 4 like I said before).
emulator with API 19 [4.4.2]: working ok
nexus 5 with API 23 [6.0.1]: hiding notifications bugged (see earlier comment)
emulator with API 24 [7.0.0]: infinitely looping fullscreen mode (the original issue)
emulator with API 25 [7.1.1]: working ok
I also tried my test app with an emulator with API level 16. While I didn't see the earlier problems, my test app started with the navigation bar visible, but after switching to another program and back the bar was hidden until touching anywhere on the screen when the bar becomes visible again.
This API level does not support the newer immersive mode and it seems that SDL is using the older mode where, if the navigation bar is hidden, the bar will pop back if the screen is touched anywhere.
*** I don't think that behavior is useful for games, so I think it would be better to not hide the navigation bar at all for API < 19 ***
The text was updated successfully, but these errors were encountered:
This bug report was migrated from our old Bugzilla tracker.
Reported in version: HG 2.0
Reported for operating system, platform: Android (All), Other
Comments on the original bug report:
On 2018-02-25 16:57:24 +0000, Olli Kallioinen wrote:
On 2018-02-25 17:44:10 +0000, Sam Lantinga wrote:
On 2018-02-25 19:37:04 +0000, Olli Kallioinen wrote:
On 2018-02-25 20:13:10 +0000, Olli Kallioinen wrote:
On 2018-02-26 10:51:20 +0000, Olli Kallioinen wrote:
On 2018-02-27 11:48:31 +0000, Olli Kallioinen wrote:
The text was updated successfully, but these errors were encountered: