Make sure the fragment/ compose views are part of tablet as well.
Fixes b/6988015 RTE when user selects compose new message on Nakasi/JZO40(Gmail_apk#434730)
Change-Id: Id8153e2875f88a3f3c3935a4b3a8b56345c857cc
diff --git a/res/layout-sw600dp/compose.xml b/res/layout-sw600dp/compose.xml
index e2f60b9..bad1099 100644
--- a/res/layout-sw600dp/compose.xml
+++ b/res/layout-sw600dp/compose.xml
@@ -15,91 +15,103 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
-<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
- android:id="@+id/compose_parent_layout"
+<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_height="match_parent"
- android:layout_width="match_parent"
- android:fillViewport="true">
-
- <LinearLayout
- android:id="@+id/compose_scrollview"
- android:orientation="vertical"
- android:layout_width="@dimen/compose_scrollview_width"
+ android:layout_width="match_parent">
+ <RelativeLayout
+ android:id="@+id/wait"
+ android:visibility="gone"
+ android:layout_width="match_parent"
android:layout_height="match_parent"
- android:paddingTop="8dip"
- android:background="@android:color/white"
- android:layout_gravity="center_horizontal">
+ android:gravity="center"
+ android:layout_gravity="center"/>
+ <ScrollView
+ android:layout_height="match_parent"
+ android:layout_width="match_parent"
+ android:fillViewport="true"
+ android:id="@+id/compose"
+ android:visibility="gone">
<LinearLayout
- android:id="@+id/content"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:animateLayoutChanges="true"
+ android:id="@+id/compose_scrollview"
android:orientation="vertical"
- android:paddingLeft="@dimen/compose_area_left_padding">
+ android:layout_width="@dimen/compose_scrollview_width"
+ android:layout_height="match_parent"
+ android:paddingTop="8dip"
+ android:background="@android:color/white"
+ android:layout_gravity="center_horizontal">
<LinearLayout
- android:orientation="horizontal"
+ android:id="@+id/content"
android:layout_width="match_parent"
- android:layout_height="wrap_content">
+ android:layout_height="match_parent"
+ android:animateLayoutChanges="true"
+ android:orientation="vertical"
+ android:paddingLeft="@dimen/compose_area_left_padding">
- <!-- For the to, cc, bcc, and subject -->
- <LinearLayout android:id="@+id/wrapper"
- android:orientation="vertical"
- android:layout_width="wrap_content"
- android:layout_weight="1"
+ <LinearLayout
+ android:orientation="horizontal"
+ android:layout_width="match_parent"
android:layout_height="wrap_content">
- <include layout="@layout/compose_from"/>
+ <!-- For the to, cc, bcc, and subject -->
+ <LinearLayout android:id="@+id/wrapper"
+ android:orientation="vertical"
+ android:layout_width="wrap_content"
+ android:layout_weight="1"
+ android:layout_height="wrap_content">
- <include layout="@layout/compose_recipients"/>
+ <include layout="@layout/compose_from"/>
+
+ <include layout="@layout/compose_recipients"/>
+
+ </LinearLayout>
+
+ <include layout="@layout/compose_buttons"/>
</LinearLayout>
- <include layout="@layout/compose_buttons"/>
+ <!-- Attachments -->
+ <com.android.mail.compose.AttachmentsView android:id="@+id/attachments"
+ android:layout_height="wrap_content"
+ android:layout_width="match_parent"
+ android:orientation="vertical"
+ android:layout_marginTop="8dip"
+ android:layout_marginRight="@dimen/compose_area_right_padding"
+ android:animateLayoutChanges="true"
+ android:paddingTop="2dip"
+ android:paddingBottom="0dip"
+ android:paddingLeft="0dip"
+ android:visibility="gone" >
+ <include layout="@layout/compose_attachments" />
+ </com.android.mail.compose.AttachmentsView>
+
+ <!-- Compose Area -->
+ <FrameLayout android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_marginRight="@dimen/compose_area_right_padding">
+
+ <include layout="@layout/compose_body"/>
+
+ </FrameLayout>
+
+ <!-- Quoted text -->
+ <com.android.mail.compose.QuotedTextView android:id="@+id/quoted_text_view"
+ android:layout_height="wrap_content"
+ android:layout_width="match_parent"
+ android:visibility="gone"
+ android:layout_marginRight="@dimen/compose_area_right_padding" />
+
+ <FrameLayout
+ android:id="@+id/composearea_tap_trap_bottom"
+ android:layout_weight="1"
+ android:layout_height="0dip"
+ android:layout_width="match_parent"
+ android:clickable="true"/>
</LinearLayout>
- <!-- Attachments -->
- <com.android.mail.compose.AttachmentsView android:id="@+id/attachments"
- android:layout_height="wrap_content"
- android:layout_width="match_parent"
- android:orientation="vertical"
- android:layout_marginTop="8dip"
- android:layout_marginRight="@dimen/compose_area_right_padding"
- android:animateLayoutChanges="true"
- android:paddingTop="2dip"
- android:paddingBottom="0dip"
- android:paddingLeft="0dip"
- android:visibility="gone" >
- <include layout="@layout/compose_attachments" />
- </com.android.mail.compose.AttachmentsView>
-
- <!-- Compose Area -->
- <FrameLayout android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_marginRight="@dimen/compose_area_right_padding">
-
- <include layout="@layout/compose_body"/>
-
- </FrameLayout>
-
- <!-- Quoted text -->
- <com.android.mail.compose.QuotedTextView android:id="@+id/quoted_text_view"
- android:layout_height="wrap_content"
- android:layout_width="match_parent"
- android:visibility="gone"
- android:layout_marginRight="@dimen/compose_area_right_padding" />
-
- <FrameLayout
- android:id="@+id/composearea_tap_trap_bottom"
- android:layout_weight="1"
- android:layout_height="0dip"
- android:layout_width="match_parent"
- android:clickable="true"/>
-
</LinearLayout>
- </LinearLayout>
-
-</ScrollView>
+ </ScrollView>
+</FrameLayout>