Forum Archive

Disabling "emergency exit" gesture for fullscreen script with no titlebar?

shinyformica

Presenting a view with style = "full_screen" and hide_title_bar = True will enable that special two-finger-swipe "emergency exit" gesture, which will force the view to close.

Is there a way to disable that gesture? For my script, I actually may have situations where two fingers will swipe down fast enough to cause that emergency exit to close the presented view. It would be a rare event, thankfully, but it is possible, so I'd like to turn it off altogether.

mikael

@shinyformica, Gestures has a disable_swipe_to_close method, and a replace_close_gesture if you want to use some other gesture instead.

shinyformica

@mikael sweet! Didn't realize the magnificent Gestures module already had exactly what I needed.