Merge "Fix 3148496: Update LockScreen layouts on large device"
diff --git a/res/layout-xlarge/date_time_settings_setupwizard.xml b/res/layout-xlarge/date_time_settings_setupwizard.xml
index b690742..de2065b 100644
--- a/res/layout-xlarge/date_time_settings_setupwizard.xml
+++ b/res/layout-xlarge/date_time_settings_setupwizard.xml
@@ -127,6 +127,7 @@
         </RelativeLayout>
     </LinearLayout>
 
+    <!-- TODO: remove this button when we are sure it is needless -->
     <Button
         android:id="@+id/skip_button"
         android:layout_width="250dip"
@@ -135,7 +136,8 @@
         android:layout_toLeftOf="@+id/next_button"
         android:layout_marginRight="20dip"
         android:textSize="24dip"
-        android:text="@string/skip_label"/>
+        android:text="@string/skip_label"
+        android:visibility="gone" />
 
     <Button
         android:id="@+id/next_button"
diff --git a/res/values/strings.xml b/res/values/strings.xml
index fb6cb06..0e42816 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -1456,9 +1456,6 @@
     <!-- SD card & phone storage settings item title that will result in the phone unmounting the SD card.  This will be done before the user phyiscally removes the SD card from the phone.  Kind of like the "Safely remove" on some operating systems.   -->
     <string name="sd_eject_summary" product="default">Unmount the SD card so you can safely remove it</string>
     <!-- SD card & phone storage settings item title for toggling PTP mode on and off.  When PTP mode is on the device will appear on the USB bus as a PTP camera device instead of an MTP music player.   -->
-    <string name="ptp_mode">Enable PTP mode</string>
-    <!-- SD card & phone storage settings item summary for toggling PTP mode on and off.  When PTP mode is on the device will appear on the USB bus as a PTP camera device instead of an MTP music player.   -->
-    <string name="ptp_mode_summary">Appear on USB as a PTP camera device instead of an MTP device</string>
 
     <!-- SD card & phone storage settings item summary that is displayed when no SD card is inserted.  This version of the string can probably never come up on current hardware. [CHAR LIMIT=25] -->
     <string name="sd_insert_summary" product="nosdcard">Insert USB storage for mounting</string>
diff --git a/res/xml/device_info_memory.xml b/res/xml/device_info_memory.xml
index 0c05213..030dfa6 100644
--- a/res/xml/device_info_memory.xml
+++ b/res/xml/device_info_memory.xml
@@ -53,9 +53,6 @@
             android:icon="@color/memory_avail"
             android:title="@string/memory_available"
             android:summary="00"/>
-        <CheckBoxPreference android:key="ptp_mode_toggle"
-            android:title="@string/ptp_mode"
-            android:summary="@string/ptp_mode_summary"/>
     </PreferenceCategory>
 
 </PreferenceScreen>
diff --git a/src/com/android/settings/DateTimeSettingsSetupWizard.java b/src/com/android/settings/DateTimeSettingsSetupWizard.java
index ad529f9..73cba03 100644
--- a/src/com/android/settings/DateTimeSettingsSetupWizard.java
+++ b/src/com/android/settings/DateTimeSettingsSetupWizard.java
@@ -20,6 +20,7 @@
 import android.app.AlarmManager;
 import android.content.Context;
 import android.content.Intent;
+import android.content.pm.ActivityInfo;
 import android.content.res.Configuration;
 import android.os.Bundle;
 import android.provider.Settings;
@@ -91,6 +92,8 @@
         mAutoTimeZoneButton.setText(autoTimeZoneEnabled ? R.string.zone_auto_summaryOn :
                 R.string.zone_auto_summaryOff);*/
 
+        setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE);
+
         final TimeZone tz = TimeZone.getDefault();
         mSelectedTimeZone = tz;
         mTimeZoneButton = (Button)findViewById(R.id.time_zone_button);
diff --git a/src/com/android/settings/deviceinfo/Memory.java b/src/com/android/settings/deviceinfo/Memory.java
index df81b6d..4ef08d1 100644
--- a/src/com/android/settings/deviceinfo/Memory.java
+++ b/src/com/android/settings/deviceinfo/Memory.java
@@ -51,11 +51,9 @@
 import android.os.storage.IMountService;
 import android.os.storage.StorageEventListener;
 import android.os.storage.StorageManager;
-import android.preference.CheckBoxPreference;
 import android.preference.Preference;
 import android.preference.PreferenceGroup;
 import android.preference.PreferenceScreen;
-import android.provider.Settings;
 import android.text.format.Formatter;
 import android.util.Log;
 import android.widget.Toast;
@@ -78,8 +76,6 @@
 
     private static final String MEMORY_SD_GROUP = "memory_sd";
 
-    private static final String PTP_MODE_TOGGLE = "ptp_mode_toggle";
-
     private static final String MEMORY_INTERNAL_SIZE = "memory_internal_size";
 
     private static final String MEMORY_INTERNAL_AVAIL = "memory_internal_avail";
@@ -122,8 +118,6 @@
     private boolean mMeasured = false;
 
     boolean mSdMountToggleAdded = true;
-
-    private CheckBoxPreference mPtpModeToggle;
     
     // Access using getMountService()
     private IMountService mMountService = null;
@@ -391,16 +385,6 @@
             mSdMountPreferenceGroup.removePreference(mSdMountToggle);
         }
 
-        mPtpModeToggle = (CheckBoxPreference)findPreference(PTP_MODE_TOGGLE);
-        if (UsbManager.isFunctionSupported(UsbManager.USB_FUNCTION_MTP)) {
-            mPtpModeToggle.setChecked(Settings.System.getInt(
-                    getContentResolver(),
-                    Settings.System.USE_PTP_INTERFACE, 0) != 0);
-        } else {
-            // hide the PTP mode toggle checkbox if MTP is not supported
-            getPreferenceScreen().removePreference(mPtpModeToggle);
-        }
-
         mInternalSize = findPreference(MEMORY_INTERNAL_SIZE);
         mInternalAvail = findPreference(MEMORY_INTERNAL_AVAIL);
         mInternalMediaUsage = findPreference(MEMORY_INTERNAL_MEDIA);
@@ -485,11 +469,6 @@
             intent.setClass(getActivity(), com.android.settings.MediaFormat.class);
             startActivity(intent);
             return true;
-        } else if (preference == mPtpModeToggle) {
-            Settings.System.putInt(getContentResolver(),
-                    Settings.System.USE_PTP_INTERFACE,
-                    mPtpModeToggle.isChecked() ? 1 : 0);
-            return true;
         }
 
         return false;