How to prevent user from clicking Navigation buttons in Android -


i have encountered problem user exit application accidentally. know android preventing block use of these buttons, because should able exit app somehow creating app blind , visually impaired people , implement special exit app won't close when using it.

here things gathered:

  • i can block onbackpressed() function , prevent going back.

  • i can't use onkeyevent() since won't grab home click

  • good example mx player can "lock" screen draws on whole screen, preventing user click on anything.

ok, grab same thing mx player, except, user, still have interaction screen.

i tried using immersive full screen google has introduced full screen apps, whenever user slides finger on screen, navigation menu popus up. can keep hidden @ times? also, can prevent slide status bar display buttons? have full control of how user moving finger on screen.

so if go mx player solution - drawing on screen. can create canvas doesn't have focus , it's there prevent clicks on buttons?

any appreciated. thanks.


Comments