Step 2 in 7" support for tablets.

This is a cherry-pick of f872876699a22d90bc39f7efaac5b21e224e7c82 :
- Use new recommended sw600dp instead of w600dp to avoid having the
"personality" change on configuration change
- remove the use of xlarge/large for specializing values since the
framework team discourages any use of the buckets (and have also changed
the ordering so that they take lower priority)

Change-Id: I645bfb7cddcda8b53569af927f6fa23180e73e1f
diff --git a/CleanSpec.mk b/CleanSpec.mk
index 133cf33..8050442 100644
--- a/CleanSpec.mk
+++ b/CleanSpec.mk
@@ -55,6 +55,8 @@
 $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/com.android.emailcommon_intermediates)
 $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/com.android.emailcommon_intermediates)
 $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/com.android.emailcommon_intermediates)
+$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/APPS/Email_intermediates)
+$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/APPS/EmailGoogle_intermediates)
 
 # ************************************************
 # NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST
diff --git a/res/layout-w600dp-land/account_setup_basics.xml b/res/layout-sw600dp-land/account_setup_basics.xml
similarity index 100%
rename from res/layout-w600dp-land/account_setup_basics.xml
rename to res/layout-sw600dp-land/account_setup_basics.xml
diff --git a/res/layout-w600dp-land/account_setup_exchange.xml b/res/layout-sw600dp-land/account_setup_exchange.xml
similarity index 100%
rename from res/layout-w600dp-land/account_setup_exchange.xml
rename to res/layout-sw600dp-land/account_setup_exchange.xml
diff --git a/res/layout-w600dp-land/account_setup_incoming.xml b/res/layout-sw600dp-land/account_setup_incoming.xml
similarity index 100%
rename from res/layout-w600dp-land/account_setup_incoming.xml
rename to res/layout-sw600dp-land/account_setup_incoming.xml
diff --git a/res/layout-w600dp-land/account_setup_names.xml b/res/layout-sw600dp-land/account_setup_names.xml
similarity index 100%
rename from res/layout-w600dp-land/account_setup_names.xml
rename to res/layout-sw600dp-land/account_setup_names.xml
diff --git a/res/layout-w600dp-land/account_setup_options.xml b/res/layout-sw600dp-land/account_setup_options.xml
similarity index 100%
rename from res/layout-w600dp-land/account_setup_options.xml
rename to res/layout-sw600dp-land/account_setup_options.xml
diff --git a/res/layout-w600dp-land/account_setup_outgoing.xml b/res/layout-sw600dp-land/account_setup_outgoing.xml
similarity index 100%
rename from res/layout-w600dp-land/account_setup_outgoing.xml
rename to res/layout-sw600dp-land/account_setup_outgoing.xml
diff --git a/res/layout-w600dp-port/account_setup_basics.xml b/res/layout-sw600dp-port/account_setup_basics.xml
similarity index 100%
rename from res/layout-w600dp-port/account_setup_basics.xml
rename to res/layout-sw600dp-port/account_setup_basics.xml
diff --git a/res/layout-w600dp-port/account_setup_exchange.xml b/res/layout-sw600dp-port/account_setup_exchange.xml
similarity index 100%
rename from res/layout-w600dp-port/account_setup_exchange.xml
rename to res/layout-sw600dp-port/account_setup_exchange.xml
diff --git a/res/layout-w600dp-port/account_setup_incoming.xml b/res/layout-sw600dp-port/account_setup_incoming.xml
similarity index 100%
rename from res/layout-w600dp-port/account_setup_incoming.xml
rename to res/layout-sw600dp-port/account_setup_incoming.xml
diff --git a/res/layout-w600dp-port/account_setup_names.xml b/res/layout-sw600dp-port/account_setup_names.xml
similarity index 100%
rename from res/layout-w600dp-port/account_setup_names.xml
rename to res/layout-sw600dp-port/account_setup_names.xml
diff --git a/res/layout-w600dp-port/account_setup_options.xml b/res/layout-sw600dp-port/account_setup_options.xml
similarity index 100%
rename from res/layout-w600dp-port/account_setup_options.xml
rename to res/layout-sw600dp-port/account_setup_options.xml
diff --git a/res/layout-w600dp-port/account_setup_outgoing.xml b/res/layout-sw600dp-port/account_setup_outgoing.xml
similarity index 100%
rename from res/layout-w600dp-port/account_setup_outgoing.xml
rename to res/layout-sw600dp-port/account_setup_outgoing.xml
diff --git a/res/layout-w600dp/account_setup_account_type.xml b/res/layout-sw600dp/account_setup_account_type.xml
similarity index 100%
rename from res/layout-w600dp/account_setup_account_type.xml
rename to res/layout-sw600dp/account_setup_account_type.xml
diff --git a/res/layout-w600dp/account_setup_basics_common.xml b/res/layout-sw600dp/account_setup_basics_common.xml
similarity index 100%
rename from res/layout-w600dp/account_setup_basics_common.xml
rename to res/layout-sw600dp/account_setup_basics_common.xml
diff --git a/res/layout-w600dp/account_setup_exchange_fragment.xml b/res/layout-sw600dp/account_setup_exchange_fragment.xml
similarity index 100%
rename from res/layout-w600dp/account_setup_exchange_fragment.xml
rename to res/layout-sw600dp/account_setup_exchange_fragment.xml
diff --git a/res/layout-w600dp/account_setup_incoming_fragment.xml b/res/layout-sw600dp/account_setup_incoming_fragment.xml
similarity index 100%
rename from res/layout-w600dp/account_setup_incoming_fragment.xml
rename to res/layout-sw600dp/account_setup_incoming_fragment.xml
diff --git a/res/layout-w600dp/account_setup_names_common.xml b/res/layout-sw600dp/account_setup_names_common.xml
similarity index 100%
rename from res/layout-w600dp/account_setup_names_common.xml
rename to res/layout-sw600dp/account_setup_names_common.xml
diff --git a/res/layout-w600dp/account_setup_options_common.xml b/res/layout-sw600dp/account_setup_options_common.xml
similarity index 100%
rename from res/layout-w600dp/account_setup_options_common.xml
rename to res/layout-sw600dp/account_setup_options_common.xml
diff --git a/res/layout-w600dp/account_setup_outgoing_fragment.xml b/res/layout-sw600dp/account_setup_outgoing_fragment.xml
similarity index 100%
rename from res/layout-w600dp/account_setup_outgoing_fragment.xml
rename to res/layout-sw600dp/account_setup_outgoing_fragment.xml
diff --git a/res/layout-w600dp/message_compose.xml b/res/layout-sw600dp/message_compose.xml
similarity index 100%
rename from res/layout-w600dp/message_compose.xml
rename to res/layout-sw600dp/message_compose.xml
diff --git a/res/layout-w600dp/message_compose_attachment.xml b/res/layout-sw600dp/message_compose_attachment.xml
similarity index 100%
rename from res/layout-w600dp/message_compose_attachment.xml
rename to res/layout-sw600dp/message_compose_attachment.xml
diff --git a/res/layout-w600dp/message_view_attachment.xml b/res/layout-sw600dp/message_view_attachment.xml
similarity index 100%
rename from res/layout-w600dp/message_view_attachment.xml
rename to res/layout-sw600dp/message_view_attachment.xml
diff --git a/res/layout-w600dp/message_view_fragment.xml b/res/layout-sw600dp/message_view_fragment.xml
similarity index 100%
rename from res/layout-w600dp/message_view_fragment.xml
rename to res/layout-sw600dp/message_view_fragment.xml
diff --git a/res/layout-w600dp/message_view_invitation.xml b/res/layout-sw600dp/message_view_invitation.xml
similarity index 100%
rename from res/layout-w600dp/message_view_invitation.xml
rename to res/layout-sw600dp/message_view_invitation.xml
diff --git a/res/layout-w600dp/three_pane.xml b/res/layout-sw600dp/three_pane.xml
similarity index 100%
rename from res/layout-w600dp/three_pane.xml
rename to res/layout-sw600dp/three_pane.xml
diff --git a/res/layout-xlarge-land/three_pane.xml b/res/layout-sw800dp-land/three_pane.xml
similarity index 100%
rename from res/layout-xlarge-land/three_pane.xml
rename to res/layout-sw800dp-land/three_pane.xml
diff --git a/res/values-large-land/dimen.xml b/res/values-large-land/dimen.xml
deleted file mode 100644
index 6c4194c..0000000
--- a/res/values-large-land/dimen.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2011 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<!-- large, landscape -->
-<resources>
-    <!-- Account Setup Activities -->
-    <dimen name="setup_padding_top">16dip</dimen>
-    <dimen name="setup_padding_left">64dip</dimen>
-    <dimen name="setup_padding_right">64dip</dimen>
-</resources>
-
diff --git a/res/values-large-port/styles.xml b/res/values-large-port/styles.xml
deleted file mode 100644
index 2c5fab4..0000000
--- a/res/values-large-port/styles.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
-     Licensed under the Apache License, Version 2.0 (the "License");
-     you may not use this file except in compliance with the License.
-     You may obtain a copy of the License at
-
-          http://www.apache.org/licenses/LICENSE-2.0
-
-     Unless required by applicable law or agreed to in writing, software
-     distributed under the License is distributed on an "AS IS" BASIS,
-     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-     See the License for the specific language governing permissions and
-     limitations under the License.
--->
-
-<resources>
-    <style name="accountSetupTypePrevious" parent="@style/accountSetupButton">
-        <item name="android:layout_alignParentBottom">true</item>
-        <item name="android:layout_alignParentLeft">true</item>
-        <item name="android:layout_marginBottom">48dip</item>
-        <item name="android:layout_marginLeft">48dip</item>
-    </style>
-</resources>
-
-
diff --git a/res/values-w600dp-land/dimensions.xml b/res/values-sw600dp-land/dimensions.xml
similarity index 91%
rename from res/values-w600dp-land/dimensions.xml
rename to res/values-sw600dp-land/dimensions.xml
index a91f4eb..d9907dd 100644
--- a/res/values-w600dp-land/dimensions.xml
+++ b/res/values-sw600dp-land/dimensions.xml
@@ -18,8 +18,6 @@
 <resources>
     <dimen name="message_compose_field_label_width">120dip</dimen>
 
-    <!-- XL activity dimensions -->
-
     <!-- width of mailbox list -->
     <dimen name="mailbox_list_width">304dip</dimen>
     <!-- width of the message list, on the message list + message view mode. -->
@@ -35,6 +33,7 @@
 
     <!-- Account Setup Activities -->
     <dimen name="setup_padding_top">16dip</dimen>
-    <dimen name="setup_padding_left">128dip</dimen>
-    <dimen name="setup_padding_right">128dip</dimen>
+    <dimen name="setup_padding_left">64dip</dimen>
+    <dimen name="setup_padding_right">64dip</dimen>
+
 </resources>
diff --git a/res/values-w600dp-land/styles.xml b/res/values-sw600dp-land/styles.xml
similarity index 100%
rename from res/values-w600dp-land/styles.xml
rename to res/values-sw600dp-land/styles.xml
diff --git a/res/values-w600dp-port/dimensions.xml b/res/values-sw600dp-port/dimensions.xml
similarity index 100%
rename from res/values-w600dp-port/dimensions.xml
rename to res/values-sw600dp-port/dimensions.xml
diff --git a/res/values-w600dp-port/styles.xml b/res/values-sw600dp-port/styles.xml
similarity index 74%
rename from res/values-w600dp-port/styles.xml
rename to res/values-sw600dp-port/styles.xml
index 8030b0f..68f9ec3 100644
--- a/res/values-w600dp-port/styles.xml
+++ b/res/values-sw600dp-port/styles.xml
@@ -23,4 +23,12 @@
         <item name="android:layout_marginLeft">16dip</item>
         <item name="android:layout_marginRight">16dip</item>
     </style>
+
+    <style name="accountSetupTypePrevious" parent="@style/accountSetupButton">
+        <item name="android:layout_alignParentBottom">true</item>
+        <item name="android:layout_alignParentLeft">true</item>
+        <item name="android:layout_marginBottom">48dip</item>
+        <item name="android:layout_marginLeft">48dip</item>
+    </style>
+
 </resources>
diff --git a/res/values-w600dp/bools.xml b/res/values-sw600dp/bools.xml
similarity index 100%
rename from res/values-w600dp/bools.xml
rename to res/values-sw600dp/bools.xml
diff --git a/res/values-w600dp/colors.xml b/res/values-sw600dp/colors.xml
similarity index 100%
rename from res/values-w600dp/colors.xml
rename to res/values-sw600dp/colors.xml
diff --git a/res/values-w600dp/dimensions.xml b/res/values-sw600dp/dimensions.xml
similarity index 100%
rename from res/values-w600dp/dimensions.xml
rename to res/values-sw600dp/dimensions.xml
diff --git a/res/values-w600dp/styles.xml b/res/values-sw600dp/styles.xml
similarity index 100%
rename from res/values-w600dp/styles.xml
rename to res/values-sw600dp/styles.xml
diff --git a/res/values-xlarge-land/dimen.xml b/res/values-sw800dp-land/dimen.xml
similarity index 100%
rename from res/values-xlarge-land/dimen.xml
rename to res/values-sw800dp-land/dimen.xml
diff --git a/res/values-w600dp-port/styles.xml b/res/values-sw800dp-port/styles.xml
similarity index 72%
copy from res/values-w600dp-port/styles.xml
copy to res/values-sw800dp-port/styles.xml
index 8030b0f..8a61b9f 100644
--- a/res/values-w600dp-port/styles.xml
+++ b/res/values-sw800dp-port/styles.xml
@@ -17,10 +17,11 @@
 <!-- tablet, portrait -->
 
 <resources>
-    <!-- Use fixed margin in portrait -->
-    <style name="message_compose_scroll">
-        <item name="android:layout_width">match_parent</item>
-        <item name="android:layout_marginLeft">16dip</item>
-        <item name="android:layout_marginRight">16dip</item>
+    <!-- Override previous button in really large tablets -->
+    <style name="accountSetupTypePrevious" parent="@style/accountSetupButton">
+        <item name="android:layout_toRightOf">@+id/main_content"</item>
+        <item name="android:layout_alignParentRight">true</item>
     </style>
+
 </resources>
+