Remove Airplane Mode setting if it's a stationary device

Bug: 8051556
Change-Id: I3a1d5d58573b8967ce40ccf8b76e24152fff6fb6
This commit is contained in:
Jaewan Kim
2013-04-19 13:40:23 +09:00
committed by Android (Google) Code Review
parent 8429e55492
commit 2e41e3db43

View File

@@ -161,6 +161,11 @@ public class WirelessSettings extends SettingsPreferenceFragment {
removePreference(KEY_MOBILE_NETWORK_SETTINGS);
}
// Remove Airplane Mode settings if it's a stationary device such as a TV.
if (getActivity().getPackageManager().hasSystemFeature(PackageManager.FEATURE_TELEVISION)) {
removePreference(KEY_TOGGLE_AIRPLANE);
}
// Enable Proxy selector settings if allowed.
Preference mGlobalProxy = findPreference(KEY_PROXY_SETTINGS);
DevicePolicyManager mDPM = (DevicePolicyManager)