-1

I'm developing app which have some Buttons. Now for UX perspective I want to show touch or taps on click of that.

These can be achieved by selectors for buttons that I know Other than is In all android mobiles within developer options showtouch/showtap options is available. These can be set programmatically but once If I set all applications will enable this option.

Can I restrict this option only to my app?

If yes can I customize this for better UI?

Thanks in Advance.

Any links/code related this will be helpful.

Manju
  • 720
  • 9
  • 23

1 Answers1

0

You can't do this using something external from your App. There is nothing to do that.

The only solution could be to create a transparent View as an "Overlay" and show it for few milliseconds on the specific point where the Touch event has occurred. Obliviously you have to show that Overlay View only when required by your UI and leave the display free-from-overlays when your App is not in foreground/use.

A special Permission is required for Overlay View starting from Marshmallow 6.x and should be prompted to the user that could accept or denied it.

emandt
  • 2,547
  • 2
  • 16
  • 20