diff options
| author | 2018-01-09 22:09:53 +0000 | |
|---|---|---|
| committer | 2018-01-09 22:09:53 +0000 | |
| commit | 1b119a3cc7d30a7018cb3ef9cfa33db68bd230af (patch) | |
| tree | 633cce5965fa477718de8aebd3196068f41a6737 | |
| parent | b68ba8e15c7479559540499399f04a262a26c627 (diff) | |
| parent | cb5daff589a61c116da8a546dc6b3bb565fb15e9 (diff) | |
Merge "Disable airplane mode quick settings when disallow_airplane_mode is set."
| -rw-r--r-- | packages/SystemUI/src/com/android/systemui/qs/tiles/AirplaneModeTile.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/AirplaneModeTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/AirplaneModeTile.java index bef1aff571f3..9883da6f3a35 100644 --- a/packages/SystemUI/src/com/android/systemui/qs/tiles/AirplaneModeTile.java +++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/AirplaneModeTile.java @@ -21,6 +21,7 @@ import android.content.Context; import android.content.Intent; import android.content.IntentFilter; import android.net.ConnectivityManager; +import android.os.UserManager; import android.provider.Settings; import android.provider.Settings.Global; import android.service.quicksettings.Tile; @@ -82,6 +83,7 @@ public class AirplaneModeTile extends QSTileImpl<BooleanState> { @Override protected void handleUpdateState(BooleanState state, Object arg) { + checkIfRestrictionEnforcedByAdminOnly(state, UserManager.DISALLOW_AIRPLANE_MODE); final int value = arg instanceof Integer ? (Integer)arg : mSetting.getValue(); final boolean airplaneMode = value != 0; state.value = airplaneMode; |