Bug 1366671 - Part 1: Duplicate empty screen resoueces for Photon. r?walkingice draft
authorJing-wei Wu <topwu.tw@gmail.com>
Thu, 27 Jul 2017 16:18:02 +0800
changeset 621013 ead37737624b9139aa86d3c8c4d724436258c8e7
parent 621007 44f84266b56ca82114744201b2694ff7bb167f4e
child 621014 5c320dfb00956e1bf9c65d866ae88cd6792c4bfa
push id72226
push userbmo:topwu.tw@gmail.com
push dateFri, 04 Aug 2017 07:05:10 +0000
reviewerswalkingice
bugs1366671
milestone57.0a1
Bug 1366671 - Part 1: Duplicate empty screen resoueces for Photon. r?walkingice MozReview-Commit-ID: FkkDIQ85Qxp
mobile/android/app/src/australis/res/layout/preference_search_tip.xml
mobile/android/app/src/australis/res/layout/private_tabs_panel.xml
mobile/android/app/src/main/res/layout/preference_search_tip.xml
mobile/android/app/src/main/res/layout/private_tabs_panel.xml
mobile/android/app/src/photon/res/layout/preference_search_tip.xml
mobile/android/app/src/photon/res/layout/private_tabs_panel.xml
rename from mobile/android/app/src/main/res/layout/preference_search_tip.xml
rename to mobile/android/app/src/australis/res/layout/preference_search_tip.xml
rename from mobile/android/app/src/main/res/layout/private_tabs_panel.xml
rename to mobile/android/app/src/australis/res/layout/private_tabs_panel.xml
new file mode 100644
--- /dev/null
+++ b/mobile/android/app/src/photon/res/layout/preference_search_tip.xml
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- This Source Code Form is subject to the terms of the Mozilla Public
+   - License, v. 2.0. If a copy of the MPL was not distributed with this
+   - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
+
+<!-- Ignore UseCompoundDrawables because they caused a regression in bug 1208790. -->
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+              xmlns:tools="http://schemas.android.com/tools"
+              tools:ignore="UseCompoundDrawables"
+              android:orientation="horizontal"
+              android:layout_width="match_parent"
+              android:layout_height="match_parent"
+              android:paddingRight="?android:attr/scrollbarSize">
+
+    <TextView android:id="@+id/label_search_hint"
+              android:layout_height="wrap_content"
+              android:layout_width="0dp"
+              android:text="@string/pref_search_hint"
+              android:layout_marginTop="5dip"
+              android:layout_marginBottom="6dip"
+              android:layout_marginLeft="15dip"
+              android:layout_marginRight="6dip"
+              android:paddingTop="8dp"
+              android:paddingBottom="8dp"
+              android:paddingRight="6dip"
+              android:layout_weight="1"/>
+
+    <ImageView android:layout_height="wrap_content"
+               android:layout_width="wrap_content"
+               android:paddingRight="8dp"
+               android:paddingTop="12dip"
+               android:src="@drawable/tip_addsearch"/>
+
+</LinearLayout>
new file mode 100644
--- /dev/null
+++ b/mobile/android/app/src/photon/res/layout/private_tabs_panel.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- This Source Code Form is subject to the terms of the Mozilla Public
+   - License, v. 2.0. If a copy of the MPL was not distributed with this
+   - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
+
+<merge xmlns:android="http://schemas.android.com/apk/res/android"
+       xmlns:gecko="http://schemas.android.com/apk/res-auto">
+
+    <ImageView android:id="@+id/private_tabs_empty"
+               android:layout_height="wrap_content"
+               android:layout_width="wrap_content"
+               android:src="@drawable/private_masq"
+               android:layout_gravity="center"/>
+
+    <!-- Note: for an unknown reason, scrolling in the TabsLayout
+         does not work unless it is laid out after the empty view. -->
+    <view class="org.mozilla.gecko.tabs.TabsPanel$TabsLayout"
+          android:id="@+id/private_tabs_layout"
+          style="@style/TabsLayout"
+          android:layout_width="match_parent"
+          android:layout_height="match_parent"
+          gecko:tabs="tabs_private"/>
+
+</merge>