Modify AIRPLANE_MODE_ON on Android 4.2 (and above)

android, sdk, settings

Solution

I know you explicitly ask for a solution without rooting, but if you have a rooted device there is at least the (kind of) official solution to move your app into folder `/system/app`. Then it is possible to write into `Settings.Global`:

Settings.Global.putInt(context.getContentResolver(), Global.AIRPLANE_MODE_ON, mode ? 1 : 0);

Have a look of how to toggle airplane mode for 4.2 and how to move your app into `/system/app` here. I use this for my toggle widget Mini Status (source code link).

Problem

Since the sdk version 4.2 it seems like it's no longer possible to modify airplane-mode on devices since google has moved this setting to Settings.Global which is read-only. Has anyone been able to bypass this without and kind of rooting? My apps primary function is to enable airplane-mode when the screen is turned off, and this stopped working since 4.2. Just want to double check that my assessment is correct and that my app is dead starting from android 4.2 and above. References: http://developer.android.com/reference/android/provider/Settings.Global.html#AIRPLANE_MODE_ON

Original source