1<?xml version="1.0" encoding="utf-8"?>
2<!--
3    Copyright 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
18<com.android.systemui.statusbar.notification.row.PartialConversationInfo
19    xmlns:android="http://schemas.android.com/apk/res/android"
20    android:id="@+id/notification_guts"
21    android:layout_width="match_parent"
22    android:layout_height="wrap_content"
23    android:focusable="true"
24    android:clipChildren="false"
25    android:clipToPadding="true"
26    android:orientation="vertical"
27    android:paddingStart="@dimen/notification_shade_content_margin_horizontal">
28
29    <!-- Package Info -->
30    <LinearLayout
31        android:id="@+id/header"
32        android:layout_width="match_parent"
33        android:layout_height="wrap_content"
34        android:gravity="center_vertical"
35        android:clipChildren="false"
36        android:paddingTop="@dimen/notification_guts_header_top_padding"
37        android:clipToPadding="true">
38        <ImageView
39            android:id="@+id/icon"
40            android:layout_width="@dimen/notification_guts_conversation_icon_size"
41            android:layout_height="@dimen/notification_guts_conversation_icon_size"
42            android:layout_centerVertical="true"
43            android:layout_alignParentStart="true"
44            android:layout_marginEnd="15dp" />
45        <LinearLayout
46            android:id="@+id/names"
47            android:layout_weight="1"
48            android:layout_width="0dp"
49            android:orientation="vertical"
50            android:layout_height="wrap_content"
51            android:minHeight="@dimen/notification_guts_conversation_icon_size"
52            android:layout_centerVertical="true"
53            android:gravity="center_vertical"
54            android:layout_alignEnd="@id/conversation_icon"
55            android:layout_toEndOf="@id/conversation_icon">
56            <TextView
57                android:id="@+id/name"
58                android:layout_width="match_parent"
59                android:layout_height="wrap_content"
60                android:ellipsize="end"
61                android:textDirection="locale"
62                style="@style/TextAppearance.NotificationImportanceChannel"/>
63            <TextView
64                android:id="@+id/delegate_name"
65                android:layout_width="match_parent"
66                android:layout_height="wrap_content"
67                android:layout_centerVertical="true"
68                style="@style/TextAppearance.NotificationImportanceHeader"
69                android:layout_marginStart="2dp"
70                android:layout_marginEnd="2dp"
71                android:ellipsize="end"
72                android:textDirection="locale"
73                android:text="@string/notification_delegate_header"
74                android:maxLines="1" />
75
76        </LinearLayout>
77
78        <!-- end aligned fields -->
79        <ImageButton
80            android:id="@+id/info"
81            android:layout_width="@dimen/notification_importance_toggle_size"
82            android:layout_height="@dimen/notification_importance_toggle_size"
83            android:layout_centerVertical="true"
84            android:contentDescription="@string/notification_more_settings"
85            android:background="@drawable/ripple_drawable_20dp"
86            android:src="@drawable/ic_settings"
87            android:tint="?android:attr/colorAccent"
88            android:layout_alignParentEnd="true"/>
89
90    </LinearLayout>
91
92    <LinearLayout
93        android:id="@+id/inline_controls"
94        android:layout_width="match_parent"
95        android:layout_height="wrap_content"
96        android:paddingEnd="@dimen/notification_shade_content_margin_horizontal"
97        android:layout_marginTop="@dimen/notification_guts_option_vertical_padding"
98        android:clipChildren="false"
99        android:clipToPadding="false"
100        android:orientation="vertical">
101
102        <com.android.systemui.statusbar.notification.row.ButtonLinearLayout
103            android:id="@+id/settings_link"
104            android:layout_width="match_parent"
105            android:layout_height="wrap_content"
106            android:padding="@dimen/notification_importance_button_padding"
107            android:clickable="true"
108            android:focusable="true"
109            android:background="@drawable/notification_guts_priority_button_bg"
110            android:orientation="vertical">
111
112            <LinearLayout
113                android:layout_width="match_parent"
114                android:layout_height="wrap_content"
115                android:clipChildren="false"
116                android:clipToPadding="false"
117                android:layout_centerVertical="true"
118                android:orientation="horizontal">
119                <ImageView
120                    android:layout_height="match_parent"
121                    android:layout_width="wrap_content"
122                    android:contentDescription="@null"
123                    android:src="@drawable/ic_info"
124                    android:layout_centerVertical="true"
125                    android:tint="?android:attr/textColorPrimary"
126                    android:layout_marginEnd="8dp"/>
127                <TextView
128                    android:id="@+id/non_configurable_text"
129                    android:layout_width="match_parent"
130                    android:layout_height="wrap_content"
131                    android:layout_centerVertical="true"
132                    android:textDirection="locale"
133                    style="@style/TextAppearance.NotificationImportanceChannelGroup" />
134            </LinearLayout>
135        </com.android.systemui.statusbar.notification.row.ButtonLinearLayout>
136
137        <RelativeLayout
138            android:id="@+id/bottom_buttons"
139            android:layout_width="match_parent"
140            android:layout_height="60dp"
141            android:gravity="center_vertical"
142            android:paddingStart="4dp"
143            android:paddingEnd="4dp"
144            >
145            <TextView
146                android:id="@+id/turn_off_notifications"
147                android:text="@string/inline_turn_off_notifications"
148                android:layout_width="wrap_content"
149                android:layout_height="wrap_content"
150                android:layout_alignParentStart="true"
151                android:gravity="start|center_vertical"
152                android:minWidth="@dimen/notification_importance_toggle_size"
153                android:minHeight="@dimen/notification_importance_toggle_size"
154                android:maxWidth="200dp"
155                style="@style/TextAppearance.NotificationInfo.Button"/>
156            <TextView
157                android:id="@+id/done"
158                android:text="@string/inline_done_button"
159                android:layout_width="wrap_content"
160                android:layout_height="wrap_content"
161                android:layout_alignParentEnd="true"
162                android:gravity="end|center_vertical"
163                android:minWidth="@dimen/notification_importance_toggle_size"
164                android:minHeight="@dimen/notification_importance_toggle_size"
165                android:maxWidth="125dp"
166                style="@style/TextAppearance.NotificationInfo.Button"/>
167        </RelativeLayout>
168
169    </LinearLayout>
170</com.android.systemui.statusbar.notification.row.PartialConversationInfo>
171