2
votes

I want to enable "show touches" in Settings of Android device. Here is the link, which show us the way to access "touch settings", but I didn't find there the way to access "show touches". How to programmatically check, get and set touch settings in android phones?

Help me, please!

2
There shouldn't be a way to do this, except perhaps on rooted devices. None of the developer options should be programmatically controllable. - CommonsWare
I mean how to do it on rooted devices. I use some apps (for Root only) and they could enable/disable "show touches" - TOP
I found what I wanted - TOP
Sunshinetpu please share that... - brunodles
@BrunodeLima Please see my new answer - TOP

2 Answers

4
votes

Here is the solution I found:

To enable show touches:

Settings.System.putInt(context.getContentResolver(),
                "show_touches", 1);

To disable show touches:

Settings.System.putInt(context.getContentResolver(),
                "show_touches", 0);

Remember to add android.permission.WRITE_SETTINGSto your Manifest.

0
votes

if still not works Use solution Given By Top And Change Target Version to 22 in Manifest File. it will work fine Thanks for Answer TOP.