With the game running in Android 4.4's Fullscreen Immersive Mode, the user swipes from the edge of the screen to show the notification / status bar & the Menu buttons bar
However, these swipes are also passed to the game underneath as downward swipes
Is there an official / clean way to ignore those swipes other than hard-coding a specific are of the screen to ignore down swipes from?
Non-sticky (normal) immersive mode — A user can exit immersive mode, by swiping in the system bars. Sticky immersive mode — A user can temporarily exit immersive mode by swiping in the system bars. Immersive mode is automatically re-entered after a short time (few seconds).
Some content is best experienced fullscreen without any indicators on the status bar or the navigation bar. Some examples are videos, games, image galleries, books, and slides in a presentation. This is referred to as immersive mode.
In K, there is no way to do this. The system receives motion events in parallel to your application, not before. This avoids introducing latency and gives apps/games the ability to implement gestures using these events.
Bear in mind that even if a gesture starts near the edge, it may not end up meeting the requirements for an edge swipe by the time the gesture ends. You may want to look at the gesture definition in AOSP if you are trying to avoid it.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With