blob: 5f83f45958e94b869c3dadf772424c78ecb8df76 [file] [log] [blame]
Matt Pietal22231792020-01-23 09:51:09 -05001<?xml version="1.0" encoding="utf-8"?>
2<!--
3 Copyright (C) 2020 The Android Open Source Project
4
5 Licensed under the Apache License, Version 2.0 (the "License");
6 you may not use this file except in compliance with the License.
7 You may obtain a copy of the License at
8
9 http://www.apache.org/licenses/LICENSE-2.0
10
11 Unless required by applicable law or agreed to in writing, software
12 distributed under the License is distributed on an "AS IS" BASIS,
13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 See the License for the specific language governing permissions and
15 limitations under the License.
16-->
17<androidx.constraintlayout.widget.ConstraintLayout
18 xmlns:android="http://schemas.android.com/apk/res/android"
19 xmlns:app="http://schemas.android.com/apk/res-auto"
20 android:layout_width="0dp"
21 android:layout_weight="1"
22 android:layout_height="@dimen/control_height"
23 android:padding="@dimen/control_padding"
Matt Pietal31ec9f22020-03-12 09:02:17 -040024 android:clickable="false"
Matt Pietal22231792020-01-23 09:51:09 -050025 android:focusable="true"
Matt Pietal31ec9f22020-03-12 09:02:17 -040026 android:screenReaderFocusable="true"
Lucas Dupin6843f572020-04-13 14:42:43 -070027 android:stateListAnimator="@anim/control_state_list_animator"
Fabian Kozynski5fc5f6b2020-02-03 15:21:14 -050028 android:layout_marginLeft="@dimen/control_base_item_margin"
29 android:layout_marginRight="@dimen/control_base_item_margin"
Matt Pietal22231792020-01-23 09:51:09 -050030 android:background="@drawable/control_background">
31
32 <ImageView
33 android:id="@+id/icon"
Matt Pietalf8cc0fa2020-03-26 08:48:50 -040034 android:layout_width="@dimen/control_icon_size"
35 android:layout_height="@dimen/control_icon_size"
Matt Pietal8f8953e2020-03-05 08:32:28 -050036 android:paddingTop="@dimen/control_padding_adjustment"
Matt Pietal31ec9f22020-03-12 09:02:17 -040037 android:clickable="false"
38 android:focusable="false"
Matt Pietal22231792020-01-23 09:51:09 -050039 app:layout_constraintStart_toStartOf="parent"
40 app:layout_constraintTop_toTopOf="parent" />
41
42 <TextView
43 android:id="@+id/status"
Matt Pietal5f478c72020-04-01 15:53:54 -040044 android:layout_width="0dp"
Matt Pietal22231792020-01-23 09:51:09 -050045 android:layout_height="wrap_content"
Fabian Kozynski5fc5f6b2020-02-03 15:21:14 -050046 android:textAppearance="@style/TextAppearance.Control.Status"
Matt Pietal8f8953e2020-03-05 08:32:28 -050047 android:paddingTop="@dimen/control_padding_adjustment"
Fabian Kozynski5fc5f6b2020-02-03 15:21:14 -050048 android:paddingStart="@dimen/control_status_padding"
Matt Pietal269a7b42020-04-10 10:46:02 -040049 android:screenReaderFocusable="false"
50 android:clickable="false"
Matt Pietal31ec9f22020-03-12 09:02:17 -040051 android:focusable="false"
Matt Pietal5f478c72020-04-01 15:53:54 -040052 android:singleLine="true"
53 android:ellipsize="marquee"
54 android:marqueeRepeatLimit = "marquee_forever"
Fabian Kozynski7c9aa462020-06-09 10:27:14 -040055 android:textDirection="locale"
Matt Pietal5f478c72020-04-01 15:53:54 -040056 app:layout_constraintEnd_toEndOf="parent"
Matt Pietal22231792020-01-23 09:51:09 -050057 app:layout_constraintBottom_toBottomOf="@+id/icon"
58 app:layout_constraintStart_toEndOf="@+id/icon" />
59
Matt Pietal22231792020-01-23 09:51:09 -050060 <TextView
61 android:id="@+id/title"
Fabian Kozynski9b972e82020-03-26 14:33:11 -040062 android:layout_width="match_parent"
Matt Pietal22231792020-01-23 09:51:09 -050063 android:layout_height="wrap_content"
Fabian Kozynski5fc5f6b2020-02-03 15:21:14 -050064 android:textAppearance="@style/TextAppearance.Control.Title"
Matt Pietal8f8953e2020-03-05 08:32:28 -050065 android:paddingLeft="@dimen/control_padding_adjustment"
66 android:paddingRight="@dimen/control_padding_adjustment"
Matt Pietal31ec9f22020-03-12 09:02:17 -040067 android:clickable="false"
68 android:focusable="false"
Matt Pietal85878262020-03-18 15:34:46 -040069 android:maxLines="1"
70 android:ellipsize="end"
Fabian Kozynski7c9aa462020-06-09 10:27:14 -040071 android:textDirection="locale"
Fabian Kozynski9b972e82020-03-26 14:33:11 -040072 app:layout_constraintStart_toStartOf="parent"
73 app:layout_constraintEnd_toEndOf="parent"
74 app:layout_constraintBottom_toTopOf="@id/barrier"/>
75
76 <androidx.constraintlayout.widget.Barrier
77 android:id="@+id/barrier"
78 android:layout_width="wrap_content"
79 android:layout_height="wrap_content"
80 app:barrierDirection="top"
81 app:constraint_referenced_ids="subtitle,favorite" />
Matt Pietal22231792020-01-23 09:51:09 -050082
83 <TextView
84 android:id="@+id/subtitle"
Fabian Kozynski9b972e82020-03-26 14:33:11 -040085 android:layout_width="0dp"
Matt Pietal22231792020-01-23 09:51:09 -050086 android:layout_height="wrap_content"
Fabian Kozynski5fc5f6b2020-02-03 15:21:14 -050087 android:textAppearance="@style/TextAppearance.Control.Subtitle"
Matt Pietal8f8953e2020-03-05 08:32:28 -050088 android:paddingLeft="@dimen/control_padding_adjustment"
89 android:paddingRight="@dimen/control_padding_adjustment"
90 android:paddingBottom="@dimen/control_padding_adjustment"
Matt Pietal31ec9f22020-03-12 09:02:17 -040091 android:clickable="false"
92 android:focusable="false"
Matt Pietal85878262020-03-18 15:34:46 -040093 android:maxLines="1"
94 android:ellipsize="end"
Fabian Kozynski7c9aa462020-06-09 10:27:14 -040095 android:textDirection="locale"
Fabian Kozynski9b972e82020-03-26 14:33:11 -040096 app:layout_constraintStart_toStartOf="parent"
97 app:layout_constraintEnd_toStartOf="@id/favorite"
Fabian Kozynskibac43882020-04-24 15:24:59 -040098 app:layout_constraintTop_toTopOf="@id/favorite"
Fabian Kozynski9b972e82020-03-26 14:33:11 -040099 />
Fabian Kozynski5fc5f6b2020-02-03 15:21:14 -0500100
Fabian Kozynski9b972e82020-03-26 14:33:11 -0400101 <CheckBox
102 android:id="@+id/favorite"
Fabian Kozynskibac43882020-04-24 15:24:59 -0400103 android:visibility="invisible"
Fabian Kozynski6936cd12020-04-30 12:14:03 -0400104 android:layout_width="@dimen/controls_management_checkbox_size"
105 android:layout_height="@dimen/controls_management_checkbox_size"
106 android:minHeight="0dp"
107 android:minWidth="0dp"
108 android:gravity="center"
Fabian Kozynskiaa1e5482020-04-02 11:22:01 -0400109 android:background="@android:color/transparent"
110 android:clickable="false"
111 android:selectable="false"
112 android:importantForAccessibility="no"
Fabian Kozynski9b972e82020-03-26 14:33:11 -0400113 app:layout_constraintStart_toEndOf="@id/subtitle"
Fabian Kozynski5fc5f6b2020-02-03 15:21:14 -0500114 app:layout_constraintEnd_toEndOf="parent"
Fabian Kozynski9b972e82020-03-26 14:33:11 -0400115 app:layout_constraintBottom_toBottomOf="parent"/>
Fabian Kozynski443149b2020-02-28 14:14:32 -0500116
Matt Pietal22231792020-01-23 09:51:09 -0500117</androidx.constraintlayout.widget.ConstraintLayout>