Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to detect if "developer settings" are enabled on the device? [closed]

Tags:

android

I want to detect if "developer settings" are enabled on the device.

I found nothing to solve this problem ...

like image 343
Julien Attard Avatar asked Jan 08 '23 01:01

Julien Attard


1 Answers

Try this

int devOptions = Settings.Secure.getInt(this.getContentResolver(), Settings.Global.DEVELOPMENT_SETTINGS_ENABLED , 0);

if developer options are enabled the value will be 1, otherwise it will be 0

like image 144
Vasileios Pallas Avatar answered Apr 06 '23 15:04

Vasileios Pallas