Merge "Fix the build."
diff --git a/docs/html/resources/articles/speech-input.jd b/docs/html/resources/articles/speech-input.jd
index d42bd59..736087e 100644
--- a/docs/html/resources/articles/speech-input.jd
+++ b/docs/html/resources/articles/speech-input.jd
@@ -8,8 +8,9 @@
 on. </p>
 
 <p>Speech input adds another dimension to staying in touch.
-Google's Voice Search application, which is pre-installed on many Android devices,
-provides powerful features like "search by voice" and voice shortcuts like "Navigate to." Further
+Google's Voice Search application, which is pre-installed on many Android devices
+and available in Android Market, provides powerful features like "search by voice"
+and Voice Actions like "Navigate to." Further
 enhancing the voice experience, Android 2.1 introduces a <a
 href="http://www.youtube.com/watch?v=laOlkD8LmZw">
 voice-enabled keyboard</a>, which makes it even easier
@@ -66,9 +67,7 @@
 "Speak
 now" dialog and streaming audio to Google's servers -- the same servers used
 when a user taps the microphone button on the search widget or the voice-enabled
-keyboard. Voice Search is installed on all the major
-US devices, and it's also available on Market. You can check whether Voice
-Search is installed in 
+keyboard. You can check whether Voice Search is installed in 
 <strong>Settings > Applications > Manage applications</strong>. </p>
 
 <p> One important tip: for speech input to be as accurate as possible, it's
@@ -84,9 +83,12 @@
 model to improve dictation accuracy for the voice keyboard,
 while the "web search" model is used when users want to search by voice. </p> 
 
-<p> Google's servers currently support English, Mandarin Chinese, and Japanese. 
+<p> Google's servers support many languages for voice input, with more arriving
+regularly. You can use the
+{@link android.speech.RecognizerIntent#ACTION_GET_LANGUAGE_DETAILS}
+broadcast intent to query for the list of supported languages.
 The web search model is available in all three languages, while free-form has
 primarily been optimized for English. As we work hard to support more models in
 more languages, and to improve the accuracy of the speech recognition technology
 we use in our products, Android developers who integrate speech capabilities
-directly into their applications can reap the benefits as well. </p>
\ No newline at end of file
+directly into their applications can reap the benefits as well. </p>
diff --git a/docs/html/resources/resources-data.js b/docs/html/resources/resources-data.js
index 03a5c02..7751c82 100644
--- a/docs/html/resources/resources-data.js
+++ b/docs/html/resources/resources-data.js
@@ -231,6 +231,16 @@
     }
   },
   {
+    tags: ['article', 'input', 'search', 'ui'],
+    path: 'articles/speech-input.html',
+    title: {
+      en: 'Speech Input'
+    },
+    description: {
+      en: 'This articles describes the basics of integrating speech recognition into Android applications.'
+    }
+  },
+  {
     tags: ['article', 'ui'],
     path: 'articles/touch-mode.html',
     title: {
diff --git a/telephony/java/com/android/internal/telephony/DataConnectionTracker.java b/telephony/java/com/android/internal/telephony/DataConnectionTracker.java
index 43f3b95..b7ac879 100644
--- a/telephony/java/com/android/internal/telephony/DataConnectionTracker.java
+++ b/telephony/java/com/android/internal/telephony/DataConnectionTracker.java
@@ -31,6 +31,7 @@
 import android.os.Handler;
 import android.os.Message;
 import android.os.Messenger;
+import android.os.SystemProperties;
 import android.preference.PreferenceManager;
 import android.provider.Settings;
 import android.provider.Settings.SettingNotFoundException;
@@ -219,6 +220,8 @@
     protected static final String FAIL_DATA_SETUP_FAIL_CAUSE = "fail_data_setup_fail_cause";
     protected FailCause mFailDataSetupFailCause = FailCause.ERROR_UNSPECIFIED;
 
+    protected static final String DEFALUT_DATA_ON_BOOT_PROP = "net.def_data_on_boot";
+
     // member variables
     protected PhoneBase mPhone;
     protected Activity mActivity = Activity.NONE;
@@ -384,13 +387,15 @@
 
         // This preference tells us 1) initial condition for "dataEnabled",
         // and 2) whether the RIL will setup the baseband to auto-PS attach.
-        SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(mPhone.getContext());
-        dataEnabled[APN_DEFAULT_ID] =
-                !sp.getBoolean(PhoneBase.DATA_DISABLED_ON_BOOT_KEY, false);
+
+        dataEnabled[APN_DEFAULT_ID] = SystemProperties.getBoolean(DEFALUT_DATA_ON_BOOT_PROP,
+                                                                  true);
         if (dataEnabled[APN_DEFAULT_ID]) {
             enabledCount++;
         }
-        mAutoAttachOnCreation = dataEnabled[APN_DEFAULT_ID];
+
+        SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(mPhone.getContext());
+        mAutoAttachOnCreation = sp.getBoolean(PhoneBase.DATA_DISABLED_ON_BOOT_KEY, false);
     }
 
     public void dispose() {
diff --git a/telephony/java/com/android/internal/telephony/cdma/CdmaLteServiceStateTracker.java b/telephony/java/com/android/internal/telephony/cdma/CdmaLteServiceStateTracker.java
index 32c5d75..d79f0a1e 100644
--- a/telephony/java/com/android/internal/telephony/cdma/CdmaLteServiceStateTracker.java
+++ b/telephony/java/com/android/internal/telephony/cdma/CdmaLteServiceStateTracker.java
@@ -290,13 +290,6 @@
         newSS.setStateOutOfService();
         mLteSS.setStateOutOfService();
 
-        // TODO: 4G Tech Handoff
-        // if (has4gHandoff) {
-        // Message msg = phone.mDataConnectionTracker.obtainMessage(
-        // DataConnectionTracker.EVENT_4G_TECHNOLOGY_CHANGE);
-        // phone.mDataConnectionTracker.sendMessage(msg);
-        // }
-
         if ((hasMultiApnSupport)
                 && (phone.mDataConnectionTracker instanceof CdmaDataConnectionTracker)) {
             if (DBG) log("GsmDataConnectionTracker Created");
@@ -390,8 +383,7 @@
             mDetachedRegistrants.notifyRegistrants();
         }
 
-        if ((hasCdmaDataConnectionChanged || hasNetworkTypeChanged)
-                && (phone.mDataConnectionTracker instanceof CdmaDataConnectionTracker)) {
+        if ((hasCdmaDataConnectionChanged || hasNetworkTypeChanged)) {
             phone.notifyDataConnection();
         }
 
diff --git a/telephony/java/com/android/internal/telephony/gsm/GsmDataConnectionTracker.java b/telephony/java/com/android/internal/telephony/gsm/GsmDataConnectionTracker.java
index 91b150a..e61af31 100644
--- a/telephony/java/com/android/internal/telephony/gsm/GsmDataConnectionTracker.java
+++ b/telephony/java/com/android/internal/telephony/gsm/GsmDataConnectionTracker.java
@@ -22,7 +22,6 @@
 import android.content.ContentValues;
 import android.content.Context;
 import android.content.Intent;
-import android.content.SharedPreferences;
 import android.database.ContentObserver;
 import android.database.Cursor;
 import android.net.ConnectivityManager;
@@ -270,8 +269,7 @@
     }
 
     protected void initApnContextsAndDataConnection() {
-        SharedPreferences sp = PreferenceManager.getDefaultSharedPreferences(mPhone.getContext());
-        boolean defaultEnabled = !sp.getBoolean(PhoneBase.DATA_DISABLED_ON_BOOT_KEY, false);
+        boolean defaultEnabled = SystemProperties.getBoolean(DEFALUT_DATA_ON_BOOT_PROP, true);
         // Load device network attributes from resources
         String[] networkConfigStrings = mPhone.getContext().getResources().getStringArray(
                 com.android.internal.R.array.networkAttributes);
@@ -585,7 +583,7 @@
         boolean desiredPowerState = mPhone.getServiceStateTracker().getDesiredPowerState();
 
         boolean allowed =
-                    gprsState == ServiceState.STATE_IN_SERVICE &&
+                    (gprsState == ServiceState.STATE_IN_SERVICE || mAutoAttachOnCreation) &&
                     mPhone.mIccRecords.getRecordsLoaded() &&
                     mPhone.getState() == Phone.State.IDLE &&
                     mInternalDataEnabled &&
@@ -594,7 +592,7 @@
                     desiredPowerState;
         if (!allowed && DBG) {
             String reason = "";
-            if (!(gprsState == ServiceState.STATE_IN_SERVICE)) {
+            if (!((gprsState == ServiceState.STATE_IN_SERVICE) || mAutoAttachOnCreation)) {
                 reason += " - gprs= " + gprsState;
             }
             if (!mPhone.mIccRecords.getRecordsLoaded()) reason += " - SIM not loaded";