summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaulK <contact@paulk.fr>2011-06-08 23:17:43 +0200
committerPaulK <contact@paulk.fr>2011-06-08 23:17:43 +0200
commit0817e4634116b7c8e574f9b72693c2b50098a508 (patch)
treeddef257044101d2ee21d1a1eaedc5593ca9bb7ee
parent15d0c624ed38452f5b16cbea7c7be59b5a11b52a (diff)
downloadframeworks_base-replicant-2.2.zip
frameworks_base-replicant-2.2.tar.gz
frameworks_base-replicant-2.2.tar.bz2
Allow MOBILE_DATA to have a configuration value so it can be used to disable data by default.replicant-2.2
-rw-r--r--packages/SettingsProvider/res/values/defaults.xml1
-rw-r--r--packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java6
2 files changed, 6 insertions, 1 deletions
diff --git a/packages/SettingsProvider/res/values/defaults.xml b/packages/SettingsProvider/res/values/defaults.xml
index 8349fe6..186f22a 100644
--- a/packages/SettingsProvider/res/values/defaults.xml
+++ b/packages/SettingsProvider/res/values/defaults.xml
@@ -43,6 +43,7 @@
<!-- 0 == mobile, 1 == wifi. -->
<integer name="def_network_preference">1</integer>
<bool name="def_usb_mass_storage_enabled">true</bool>
+ <bool name="def_mobile_data">false</bool>
<bool name="def_wifi_on">false</bool>
<bool name="def_networks_available_notification_on">true</bool>
diff --git a/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java b/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
index dab7601..62eee27 100644
--- a/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
+++ b/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
@@ -257,6 +257,7 @@ public class DatabaseHelper extends SQLiteOpenHelper {
Settings.Secure.WIFI_NETWORKS_AVAILABLE_NOTIFICATION_ON,
Settings.Secure.WIFI_NETWORKS_AVAILABLE_REPEAT_DELAY,
Settings.Secure.WIFI_NUM_OPEN_NETWORKS_KEPT,
+ Settings.Secure.MOBILE_DATA,
Settings.Secure.WIFI_ON,
Settings.Secure.WIFI_WATCHDOG_ACCEPTABLE_PACKET_LOSS_PERCENTAGE,
Settings.Secure.WIFI_WATCHDOG_AP_COUNT,
@@ -1118,7 +1119,10 @@ public class DatabaseHelper extends SQLiteOpenHelper {
loadBooleanSetting(stmt, Settings.Secure.USB_MASS_STORAGE_ENABLED,
R.bool.def_usb_mass_storage_enabled);
-
+
+ loadBooleanSetting(stmt, Settings.Secure.MOBILE_DATA,
+ R.bool.def_mobile_data);
+
loadBooleanSetting(stmt, Settings.Secure.WIFI_ON,
R.bool.def_wifi_on);
loadBooleanSetting(stmt, Settings.Secure.WIFI_NETWORKS_AVAILABLE_NOTIFICATION_ON,