How can I enable screen overlay permission by default while install application.
Now I facing some problem, when capture image asking run time permission some device not allow the permission it open screen overlay settings dialog. at user point of view, they don't know why the dialog showing and what they do.
when open the overlay settings screen some of applications automatically enable the screen overlay permission.
Below I use the code.
if (!Settings.canDrawOverlays(this)) {
Intent myIntent = new Intent(Settings.ACTION_MANAGE_OVERLAY_PERMISSION);
startActivityForResult(myIntent, 101);
}
This code directly open the overlay settings screen. their showing list of all application.
My requirement is showing permission specific application or enable overlay permission with out user interaction.
do needfull...
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…