2020-08-04 17:35:08 +00:00
|
|
|
<?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/. -->
|
2020-08-06 22:49:01 +00:00
|
|
|
<androidx.constraintlayout.widget.ConstraintLayout
|
|
|
|
xmlns:android="http://schemas.android.com/apk/res/android"
|
|
|
|
android:id="@+id/search_wrapper"
|
2020-08-04 17:35:08 +00:00
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="match_parent"
|
2020-08-05 19:40:43 +00:00
|
|
|
android:fitsSystemWindows="true"
|
2020-08-07 00:21:52 +00:00
|
|
|
android:background="?attr/scrimBackground"
|
2020-08-04 17:35:08 +00:00
|
|
|
xmlns:app="http://schemas.android.com/apk/res-auto">
|
2020-08-05 19:40:43 +00:00
|
|
|
<mozilla.components.browser.toolbar.BrowserToolbar
|
|
|
|
android:id="@+id/toolbar"
|
|
|
|
android:layout_width="0dp"
|
|
|
|
android:layout_height="@dimen/browser_toolbar_height"
|
|
|
|
android:background="@drawable/toolbar_background_top"
|
|
|
|
android:clickable="true"
|
|
|
|
android:focusable="true"
|
|
|
|
android:focusableInTouchMode="true"
|
|
|
|
app:layout_scrollFlags="scroll|enterAlways|snap|exitUntilCollapsed"
|
|
|
|
app:browserToolbarClearColor="?primaryText"
|
|
|
|
app:browserToolbarInsecureColor="?primaryText"
|
|
|
|
app:browserToolbarMenuColor="?primaryText"
|
|
|
|
app:browserToolbarProgressBarGravity="bottom"
|
|
|
|
app:browserToolbarSecureColor="?primaryText"
|
|
|
|
app:browserToolbarTrackingProtectionAndSecurityIndicatorSeparatorColor="?toolbarDivider"
|
|
|
|
app:layout_constraintEnd_toEndOf="parent"
|
2020-08-04 17:35:08 +00:00
|
|
|
app:layout_constraintStart_toStartOf="parent"
|
2020-08-05 19:40:43 +00:00
|
|
|
app:layout_constraintTop_toTopOf="parent"/>
|
2020-08-07 00:21:52 +00:00
|
|
|
<mozilla.components.browser.awesomebar.BrowserAwesomeBar
|
|
|
|
xmlns:mozac="http://schemas.android.com/apk/res-auto"
|
2020-08-17 18:14:17 +00:00
|
|
|
android:id="@+id/awesome_bar"
|
2020-08-05 19:40:43 +00:00
|
|
|
android:layout_width="0dp"
|
|
|
|
android:layout_height="0dp"
|
2020-08-07 00:21:52 +00:00
|
|
|
android:fadingEdge="horizontal"
|
|
|
|
android:fadingEdgeLength="40dp"
|
|
|
|
android:nestedScrollingEnabled="false"
|
|
|
|
android:requiresFadingEdge="vertical"
|
|
|
|
android:background="?attr/foundation"
|
|
|
|
android:visibility="invisible"
|
2020-08-17 18:14:17 +00:00
|
|
|
app:layout_constraintBottom_toTopOf="@+id/pill_wrapper"
|
2020-08-04 17:35:08 +00:00
|
|
|
app:layout_constraintEnd_toEndOf="parent"
|
2020-08-05 19:40:43 +00:00
|
|
|
app:layout_constraintStart_toStartOf="parent"
|
2020-09-11 18:55:59 +00:00
|
|
|
app:layout_constraintTop_toBottomOf="@id/top_barrier"
|
2020-08-07 00:21:52 +00:00
|
|
|
mozac:awesomeBarDescriptionTextColor="?secondaryText"
|
|
|
|
mozac:awesomeBarTitleTextColor="?primaryText" />
|
2020-08-24 17:50:23 +00:00
|
|
|
|
|
|
|
<ViewStub
|
2020-08-25 02:44:21 +00:00
|
|
|
android:id="@+id/search_suggestions_hint"
|
2020-08-24 17:50:23 +00:00
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="wrap_content"
|
2020-08-25 02:44:21 +00:00
|
|
|
android:inflatedId="@id/search_suggestions_hint"
|
|
|
|
android:layout="@layout/search_suggestions_hint"
|
2020-08-24 17:50:23 +00:00
|
|
|
app:layout_constraintEnd_toEndOf="parent"
|
|
|
|
app:layout_constraintStart_toStartOf="parent"
|
2020-09-11 18:55:59 +00:00
|
|
|
app:layout_constraintTop_toBottomOf="@id/toolbar" />
|
|
|
|
|
|
|
|
<androidx.constraintlayout.widget.Barrier
|
|
|
|
android:id="@+id/top_barrier"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
app:barrierDirection="bottom"
|
|
|
|
app:constraint_referenced_ids="search_suggestions_hint"/>
|
|
|
|
|
2020-08-24 17:50:23 +00:00
|
|
|
|
|
|
|
<View
|
2020-08-25 02:44:21 +00:00
|
|
|
android:id="@+id/search_suggestions_hint_divider"
|
2020-08-24 17:50:23 +00:00
|
|
|
android:layout_width="match_parent"
|
|
|
|
android:layout_height="1dp"
|
|
|
|
android:background="?neutralFaded"
|
|
|
|
android:visibility="gone"
|
2020-08-25 02:44:21 +00:00
|
|
|
app:layout_constraintBottom_toBottomOf="@id/search_suggestions_hint"
|
2020-08-24 17:50:23 +00:00
|
|
|
app:layout_constraintEnd_toEndOf="parent"
|
|
|
|
app:layout_constraintStart_toStartOf="parent" />
|
2020-08-24 20:21:28 +00:00
|
|
|
|
|
|
|
<androidx.constraintlayout.widget.ConstraintLayout
|
|
|
|
android:id="@+id/fill_link_from_clipboard"
|
|
|
|
android:layout_width="0dp"
|
|
|
|
android:layout_height="@dimen/search_fragment_clipboard_item_height"
|
|
|
|
android:paddingStart="@dimen/search_fragment_clipboard_item_horizontal_margin"
|
|
|
|
android:paddingEnd="@dimen/search_fragment_clipboard_item_horizontal_margin"
|
|
|
|
android:background="?foundation"
|
|
|
|
android:clickable="true"
|
|
|
|
android:focusable="true"
|
|
|
|
android:visibility="gone"
|
|
|
|
app:layout_constraintEnd_toEndOf="parent"
|
|
|
|
app:layout_constraintStart_toStartOf="parent"
|
|
|
|
app:layout_constraintTop_toBottomOf="@+id/toolbar">
|
|
|
|
|
|
|
|
<ImageView
|
|
|
|
android:id="@+id/link_icon"
|
|
|
|
android:layout_width="wrap_content"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:importantForAccessibility="no"
|
|
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
|
|
app:layout_constraintStart_toStartOf="parent"
|
|
|
|
app:layout_constraintTop_toTopOf="parent"
|
|
|
|
app:srcCompat="@drawable/ic_link" />
|
|
|
|
|
|
|
|
<TextView
|
|
|
|
android:id="@+id/clipboard_title"
|
|
|
|
style="@style/SearchClipboardTitleStyle"
|
|
|
|
android:layout_width="0dp"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
android:layout_marginStart="@dimen/search_fragment_clipboard_item_title_margin_start"
|
|
|
|
android:text="@string/awesomebar_clipboard_title"
|
|
|
|
app:layout_constraintBottom_toTopOf="@id/clipboard_url"
|
|
|
|
app:layout_constraintEnd_toEndOf="parent"
|
|
|
|
app:layout_constraintStart_toEndOf="@id/link_icon"
|
|
|
|
app:layout_constraintTop_toTopOf="parent"
|
|
|
|
app:layout_constraintVertical_chainStyle="packed" />
|
|
|
|
|
|
|
|
<TextView
|
|
|
|
android:id="@+id/clipboard_url"
|
|
|
|
style="@style/SearchClipboardUrlStyle"
|
|
|
|
android:layout_width="0dp"
|
|
|
|
android:layout_height="wrap_content"
|
|
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
|
|
app:layout_constraintEnd_toEndOf="parent"
|
|
|
|
app:layout_constraintStart_toStartOf="@id/clipboard_title"
|
|
|
|
app:layout_constraintTop_toBottomOf="@id/clipboard_title"
|
|
|
|
app:layout_constraintVertical_chainStyle="packed" />
|
|
|
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
|
|
|
2020-08-17 18:14:17 +00:00
|
|
|
<LinearLayout
|
|
|
|
android:id="@+id/pill_wrapper"
|
|
|
|
android:layout_width="0dp"
|
|
|
|
android:layout_height="@dimen/search_fragment_pill_height"
|
|
|
|
android:background="?foundation"
|
|
|
|
android:orientation="horizontal"
|
|
|
|
android:paddingStart="@dimen/search_fragment_pill_padding_start"
|
|
|
|
android:paddingTop="@dimen/search_fragment_pill_padding_vertical"
|
|
|
|
android:paddingEnd="@dimen/search_fragment_pill_padding_end"
|
|
|
|
android:paddingBottom="@dimen/search_fragment_pill_padding_vertical"
|
|
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
|
|
app:layout_constraintEnd_toEndOf="parent"
|
|
|
|
app:layout_constraintStart_toStartOf="parent">
|
|
|
|
|
|
|
|
<ToggleButton
|
2020-08-20 17:13:19 +00:00
|
|
|
android:id="@+id/qr_scan_button"
|
2020-08-17 18:14:17 +00:00
|
|
|
style="@style/search_pill"
|
|
|
|
android:layout_marginEnd="@dimen/search_fragment_scan_button_margin_end"
|
|
|
|
android:textOff="@string/search_scan_button"
|
|
|
|
android:textOn="@string/search_scan_button"
|
|
|
|
app:drawableStartCompat="@drawable/ic_qr" />
|
|
|
|
|
|
|
|
<ToggleButton
|
|
|
|
android:id="@+id/search_engines_shortcut_button"
|
|
|
|
style="@style/search_pill"
|
|
|
|
android:textOff="@string/search_engine_button"
|
|
|
|
android:textOn="@string/search_engine_button"
|
|
|
|
app:drawableStartCompat="@drawable/ic_search" />
|
|
|
|
</LinearLayout>
|
2020-08-04 17:35:08 +00:00
|
|
|
</androidx.constraintlayout.widget.ConstraintLayout>
|