1
0
Fork 0
fenix/app/src/main/res/layout/fragment_tab_tray.xml

103 lines
4.9 KiB
XML

<?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/. -->
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:mozac="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:id="@+id/tab_tray_empty_view"
android:layout_width="0dp"
android:layout_height="0dp"
android:gravity="center"
android:text="@string/no_open_tabs_description"
android:textColor="?secondaryText"
android:textSize="16sp"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<mozilla.components.concept.tabstray.TabsTray
android:id="@+id/tabsTray"
android:layout_width="match_parent"
android:layout_height="0dp"
app:layout_constraintBottom_toTopOf="@+id/save_to_collection_button"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
mozac:tabsTrayItemBackgroundColor="?tabTrayItemBackground"
mozac:tabsTrayItemTextColor="?tabTrayItemText"
mozac:tabsTraySelectedItemBackgroundColor="?tabTrayItemSelectedBackground"
mozac:tabsTraySelectedItemTextColor="?tabTrayItemSelectedText" />
<include
layout="@layout/save_to_collection_button"
android:id="@+id/save_to_collection_button"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingStart="16dp"
android:paddingEnd="16dp"
app:layout_constraintBottom_toTopOf="@id/bottomBarShadow"
app:layout_constraintTop_toBottomOf="@+id/tabsTray" />
<View
android:id="@+id/bottomBarShadow"
android:layout_width="0dp"
android:layout_height="1dp"
android:background="@color/bottom_bar_shadow"
app:layout_constraintBottom_toTopOf="@id/tab_tray_controls"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent" />
<View
android:id="@+id/tab_tray_controls"
android:layout_width="0dp"
android:layout_height="48dp"
android:background="?bottomBarBackground"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent" />
<ImageButton
android:id="@+id/private_browsing_button"
android:layout_width="@dimen/glyph_button_height"
android:layout_height="@dimen/glyph_button_height"
android:background="?android:attr/selectableItemBackgroundBorderless"
android:contentDescription="@string/content_description_private_browsing_button"
app:srcCompat="@drawable/private_browsing_button"
app:layout_constraintTop_toTopOf="@id/tab_tray_controls"
app:layout_constraintBottom_toBottomOf="@+id/tab_tray_controls"
app:layout_constraintEnd_toStartOf="@+id/tab_tray_go_home"
app:layout_constraintStart_toStartOf="@id/tab_tray_controls" />
<ImageButton
android:id="@+id/tab_tray_go_home"
android:layout_width="@dimen/glyph_button_height"
android:layout_height="@dimen/glyph_button_height"
android:background="?android:attr/selectableItemBackgroundBorderless"
android:contentDescription="@string/tab_tray_menu_home"
app:srcCompat="@drawable/ic_home"
app:layout_constraintTop_toTopOf="@id/tab_tray_controls"
app:layout_constraintBottom_toBottomOf="@+id/tab_tray_controls"
app:layout_constraintEnd_toStartOf="@+id/tab_tray_open_new_tab"
app:layout_constraintStart_toEndOf="@+id/private_browsing_button" />
<ImageButton
android:id="@+id/tab_tray_open_new_tab"
android:layout_width="@dimen/glyph_button_height"
android:layout_height="@dimen/glyph_button_height"
android:background="?android:attr/selectableItemBackgroundBorderless"
android:contentDescription="@string/tab_tray_menu_open_new_tab"
app:srcCompat="@drawable/ic_new"
app:layout_constraintTop_toTopOf="@id/tab_tray_controls"
app:layout_constraintBottom_toBottomOf="@+id/tab_tray_controls"
app:layout_constraintEnd_toEndOf="@+id/tab_tray_controls"
app:layout_constraintStart_toEndOf="@+id/tab_tray_go_home" />
</androidx.constraintlayout.widget.ConstraintLayout>