diff options
author | Gilles Debunne <debunne@google.com> | 2011-07-18 17:46:54 -0700 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2011-07-18 17:46:54 -0700 |
commit | 1840494bdafaf4d95722f25caada8cf28c074f49 (patch) | |
tree | 85dad2e4c5854294cd5d6e729f93a1bf0714b159 | |
parent | b8370359a7ba9bddb6c71efc78156b7d259c9507 (diff) | |
parent | dfc2637ebaee6e7467b0340ec652c29f6b5734ff (diff) | |
download | packages_apps_settings-1840494bdafaf4d95722f25caada8cf28c074f49.zip packages_apps_settings-1840494bdafaf4d95722f25caada8cf28c074f49.tar.gz packages_apps_settings-1840494bdafaf4d95722f25caada8cf28c074f49.tar.bz2 |
Merge "Removed summary text and categories in Wireless settings"
-rw-r--r-- | res/values/strings.xml | 45 | ||||
-rw-r--r-- | res/xml/wireless_settings.xml | 29 | ||||
-rw-r--r-- | src/com/android/settings/AirplaneModeEnabler.java | 11 | ||||
-rw-r--r-- | src/com/android/settings/WirelessSettings.java | 7 | ||||
-rw-r--r-- | src/com/android/settings/nfc/NfcEnabler.java | 6 |
5 files changed, 9 insertions, 89 deletions
diff --git a/res/values/strings.xml b/res/values/strings.xml index c53aaf4..515a3de 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -349,8 +349,6 @@ <!-- HTTP proxy settings title --> <string name="proxy_settings_title">Proxy settings</string> - <!-- HTTP proxy settings summary --> - <string name="proxy_settings_summary">Set the global HTTP proxy and exclusion lists</string> <!-- HTTP proxy settings. Button to clear the proxy box. --> <string name="proxy_clear_text">Clear</string> <!-- HTTP proxy settings. The port number label. --> @@ -541,12 +539,6 @@ <string name="settings_shortcut">Select settings shortcut</string> <!-- Wireless controls settings screen, setting check box label --> <string name="airplane_mode">Airplane mode</string> - <!-- Wireless controls settings screen, setting option summary text --> - <string name="airplane_mode_summary">Disable all wireless connections</string> - <!-- Wireless controls settings screen, setting option summary text as airplane mode is being enabled (so it is disabling all wireless connections) --> - <string name="airplane_mode_turning_on">Disabling wireless connections\u2026</string> - <!-- Wireless controls settings screen, setting option summary text as airplane mode is being disabled (so it is re-enabling all the wireless conenctions) --> - <string name="airplane_mode_turning_off">Enabling wireless connections\u2026</string> <!-- Main Settings screen settings title for things like airplane mode, tethering, NFC, VPN. This will take you to another screen with those settings. --> <string name="radio_controls_title">More\u2026</string> <!-- Wireless Settings screen title for things like Wi-Fi, bluetooth, airplane mode. --> @@ -1095,9 +1087,6 @@ <!-- NFC settings --> <!-- Used in the 1st-level settings screen to turn on NFC --> <string name="nfc_quick_toggle_title">NFC</string> - <!-- Used in the 1st-level settings screen as the turn-on summary --> - <string name="nfc_quick_toggle_summary">Use Near Field Communication to read and exchange tags</string> - <string name="nfc_toggle_error" msgid="8998642457947607263">An error occurred.</string> <!-- Wi-Fi Settings --> <skip /> <!-- Used in the 1st-level settings screen to turn on Wi-Fi --> @@ -1939,32 +1928,6 @@ <!-- Tethering controls, item title to go into the tethering settings when USB, Bluetooth and Wifi tethering are available [CHAR LIMIT=25]--> <string name="tether_settings_title_all">Tethering & portable hotspot</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings --> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when only USB tethering is available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_usb" product="tablet">Share your tablet\'s mobile data connection via USB</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when only USB tethering is available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_usb" product="default">Share your phone\'s mobile data connection via USB</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when only Wifi tethering is available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_wifi">Share your mobile data connection as a portable Wi-Fi hotspot</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when only Bluetooth tethering is available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_bluetooth">Share your mobile data connection via Bluetooth</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when USB and Wifi tethering are available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_usb_wifi" product="tablet">Share your tablet\'s mobile data connection via USB or as a portable Wi-Fi hotspot</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when USB and Wifi tethering are available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_usb_wifi" product="default">Share your phone\'s mobile data connection via USB or as a portable Wi-Fi hotspot</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when USB and Bluetooth tethering are available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_usb_bluetooth" product="tablet">Share your tablet\'s mobile data connection via USB or Bluetooth</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when USB and Bluetooth tethering are available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_usb_bluetooth" product="default">Share your phone\'s mobile data connection via USB or Bluetooth</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when Bluetooth and Wifi tethering are available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_wifi_bluetooth" product="tablet">Share your tablet\'s mobile data connection via Bluetooth or as a portable Wi-Fi hotspot</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when Bluetooth and Wifi tethering are available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_wifi_bluetooth" product="default">Share your phone\'s mobile data connection via Bluetooth or as a portable Wi-Fi hotspot</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when USB, Wifi, and Bluetooth tethering are available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_all" product="tablet">Share your tablet\'s mobile data connection via USB, Wi-Fi, or Bluetooth</string> - <!-- Tethering controls, the item summary for the user to go into the tethering settings when USB, Wifi, and Bluetooth tethering are available [CHAR LIMIT=100]--> - <string name="tether_settings_summary_all" product="default">Share your phone\'s mobile data connection via USB, Wi-Fi, or Bluetooth</string> - <!-- USB Tethering options --> <string name="usb_title">USB</string> <string name="usb_tethering_button_text">USB tethering</string> @@ -2008,14 +1971,8 @@ <!-- Tethering help button - calls up a web view with general tethering info --> <string name="tethering_help_button_text">Help</string> - <!-- Wireless controls, header for the general category (airplane mode, VPN, NFC, tethering...) [CHAR LIMIT=40]--> - <string name="wireless_category_general">General</string> - <!-- Wireless controls, header for the mobile networks category (4G/ network operator...) [CHAR LIMIT=40]--> - <string name="wireless_category_mobile_networks">Mobile networks</string> <!-- Wireless controls, item title to go into the network settings --> <string name="network_settings_title">Mobile networks</string> - <!-- Wireless controls, the item summary for the user to go into the network settings --> - <string name="network_settings_summary">Set options for roaming, networks, APNs</string> <!-- Security & location settings screen, section header for settings relating to location --> <string name="location_title">My Location</string> @@ -3015,8 +2972,6 @@ found in the list of installed applications.</string> <!-- Title of preference to enter the VPN settings activity --> <string name="vpn_settings_title">VPN settings</string> - <!-- Summary of preference to enter the VPN settings activity --> - <string name="vpn_settings_summary">Set up & manage Virtual Private Networks (VPNs)</string> <!-- Title of preference group for credential storage settings [CHAR LIMIT=30] --> <string name="credentials_title">Credential storage</string> diff --git a/res/xml/wireless_settings.xml b/res/xml/wireless_settings.xml index 0488e02..605ddb9 100644 --- a/res/xml/wireless_settings.xml +++ b/res/xml/wireless_settings.xml @@ -17,43 +17,30 @@ <PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android" android:title="@string/wireless_networks_settings_title"> - <PreferenceCategory - android:title="@string/wireless_category_general" /> - <CheckBoxPreference android:key="toggle_airplane" android:title="@string/airplane_mode" - android:summary="@string/airplane_mode_summary" android:persistent="false" android:disableDependentsState="true" /> - <CheckBoxPreference - android:key="toggle_nfc" - android:title="@string/nfc_quick_toggle_title" - android:summary="@string/nfc_quick_toggle_summary" - android:persistent="false" /> - <PreferenceScreen android:fragment="com.android.settings.vpn2.VpnSettings" android:key="vpn_settings" - android:title="@string/vpn_settings_title" - android:summary="@string/vpn_settings_summary" > - </PreferenceScreen> + android:title="@string/vpn_settings_title" /> <PreferenceScreen android:fragment="com.android.settings.TetherSettings" android:key="tether_settings" - android:title="@string/tether_settings_title_all" - android:summary="@string/tether_settings_summary_all"> - </PreferenceScreen> + android:title="@string/tether_settings_title_all" /> - <PreferenceCategory - android:title="@string/wireless_category_mobile_networks" /> + <CheckBoxPreference + android:key="toggle_nfc" + android:title="@string/nfc_quick_toggle_title" + android:persistent="false" /> <PreferenceScreen android:key="mobile_network_settings" android:title="@string/network_settings_title" - android:summary="@string/network_settings_summary" android:dependency="toggle_airplane"> <intent android:action="android.intent.action.MAIN" @@ -64,8 +51,6 @@ <PreferenceScreen android:fragment="com.android.settings.ProxySelector" android:key="proxy_settings" - android:title="@string/proxy_settings_title" - android:summary="@string/proxy_settings_summary" > - </PreferenceScreen> + android:title="@string/proxy_settings_title" /> </PreferenceScreen> diff --git a/src/com/android/settings/AirplaneModeEnabler.java b/src/com/android/settings/AirplaneModeEnabler.java index 00c416f..94ba5a1 100644 --- a/src/com/android/settings/AirplaneModeEnabler.java +++ b/src/com/android/settings/AirplaneModeEnabler.java @@ -16,8 +16,6 @@ package com.android.settings; -import com.android.internal.telephony.PhoneStateIntentReceiver; - import android.content.Context; import android.content.Intent; import android.database.ContentObserver; @@ -27,8 +25,8 @@ import android.os.SystemProperties; import android.preference.CheckBoxPreference; import android.preference.Preference; import android.provider.Settings; -import android.telephony.ServiceState; +import com.android.internal.telephony.PhoneStateIntentReceiver; import com.android.internal.telephony.TelephonyProperties; public class AirplaneModeEnabler implements Preference.OnPreferenceChangeListener { @@ -93,10 +91,6 @@ public class AirplaneModeEnabler implements Preference.OnPreferenceChangeListene } private void setAirplaneModeOn(boolean enabling) { - - mCheckBoxPref.setSummary(enabling ? R.string.airplane_mode_turning_on - : R.string.airplane_mode_turning_off); - // Change the system setting Settings.System.putInt(mContext.getContentResolver(), Settings.System.AIRPLANE_MODE_ON, enabling ? 1 : 0); @@ -118,10 +112,7 @@ public class AirplaneModeEnabler implements Preference.OnPreferenceChangeListene * - mobile does not send failure notification, fail on timeout. */ private void onAirplaneModeChanged() { - boolean airplaneModeEnabled = isAirplaneModeOn(mContext); mCheckBoxPref.setChecked(isAirplaneModeOn(mContext)); - mCheckBoxPref.setSummary(airplaneModeEnabled ? null : - mContext.getString(R.string.airplane_mode_summary)); } /** diff --git a/src/com/android/settings/WirelessSettings.java b/src/com/android/settings/WirelessSettings.java index d09fcc5..5560a03 100644 --- a/src/com/android/settings/WirelessSettings.java +++ b/src/com/android/settings/WirelessSettings.java @@ -139,25 +139,18 @@ public class WirelessSettings extends SettingsPreferenceFragment { Preference p = findPreference(KEY_TETHER_SETTINGS); if (wifiAvailable && usbAvailable && bluetoothAvailable) { p.setTitle(R.string.tether_settings_title_all); - p.setSummary(R.string.tether_settings_summary_all); } else if (wifiAvailable && usbAvailable) { p.setTitle(R.string.tether_settings_title_all); - p.setSummary(R.string.tether_settings_summary_usb_wifi); } else if (wifiAvailable && bluetoothAvailable) { p.setTitle(R.string.tether_settings_title_all); - p.setSummary(R.string.tether_settings_summary_wifi_bluetooth); } else if (wifiAvailable) { p.setTitle(R.string.tether_settings_title_wifi); - p.setSummary(R.string.tether_settings_summary_wifi); } else if (usbAvailable && bluetoothAvailable) { p.setTitle(R.string.tether_settings_title_usb_bluetooth); - p.setSummary(R.string.tether_settings_summary_usb_bluetooth); } else if (usbAvailable) { p.setTitle(R.string.tether_settings_title_usb); - p.setSummary(R.string.tether_settings_summary_usb); } else { p.setTitle(R.string.tether_settings_title_bluetooth); - p.setSummary(R.string.tether_settings_summary_bluetooth); } } } diff --git a/src/com/android/settings/nfc/NfcEnabler.java b/src/com/android/settings/nfc/NfcEnabler.java index d1cec13..dba1329 100644 --- a/src/com/android/settings/nfc/NfcEnabler.java +++ b/src/com/android/settings/nfc/NfcEnabler.java @@ -16,8 +16,6 @@ package com.android.settings.nfc; -import com.android.settings.R; - import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; @@ -26,7 +24,6 @@ import android.nfc.NfcAdapter; import android.os.Handler; import android.preference.CheckBoxPreference; import android.preference.Preference; -import android.provider.Settings; import android.util.Log; /** @@ -98,6 +95,7 @@ public class NfcEnabler implements Preference.OnPreferenceChangeListener { // Start async update of the NFC adapter state, as the API is // unfortunately blocking... new Thread("toggleNFC") { + @Override public void run() { Log.d(TAG, "Setting NFC enabled state to: " + desiredState); boolean success = false; @@ -118,7 +116,6 @@ public class NfcEnabler implements Preference.OnPreferenceChangeListener { mHandler.post(new Runnable() { public void run() { mCheckbox.setEnabled(true); - mCheckbox.setSummary(R.string.nfc_toggle_error); } }); } @@ -130,6 +127,5 @@ public class NfcEnabler implements Preference.OnPreferenceChangeListener { private void handleNfcStateChanged(boolean newState) { mCheckbox.setChecked(newState); mCheckbox.setEnabled(true); - mCheckbox.setSummary(R.string.nfc_quick_toggle_summary); } } |