• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<?xml version="1.0" encoding="utf-8"?>
2<!--
3  ~ Copyright (C) 2023 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<androidx.constraintlayout.widget.ConstraintLayout
19    xmlns:android="http://schemas.android.com/apk/res/android"
20    xmlns:androidprv="http://schemas.android.com/apk/prv/res/android"
21    xmlns:app="http://schemas.android.com/apk/res-auto"
22    android:layout_width="match_parent"
23    android:layout_height="wrap_content"
24    android:paddingHorizontal="@dimen/chooser_edge_margin_normal"
25    android:layout_marginBottom="@dimen/chooser_view_spacing"
26>
27    <TextView
28        android:id="@+id/headline"
29        android:layout_width="wrap_content"
30        android:layout_height="wrap_content"
31        android:visibility="invisible"
32        app:layout_constraintStart_toStartOf="parent"
33        app:layout_constraintEnd_toStartOf="@id/barrier"
34        app:layout_constraintHorizontal_bias="0.0"
35        app:layout_constrainedWidth="true"
36        style="@style/TextAppearance.ChooserDefault"
37        android:fontFamily="@androidprv:string/config_headlineFontFamily"
38        android:textSize="18sp"
39        />
40
41    <androidx.constraintlayout.widget.Barrier
42        android:id="@+id/barrier"
43        android:layout_width="wrap_content"
44        android:layout_height="wrap_content"
45        app:barrierDirection="start"
46        app:constraint_referenced_ids="reselection_action,include_text_action" />
47
48    <TextView
49        android:id="@+id/reselection_action"
50        android:layout_width="wrap_content"
51        android:layout_height="wrap_content"
52        android:maxWidth="@dimen/modify_share_text_toggle_max_width"
53        app:layout_constraintEnd_toEndOf="parent"
54        android:maxLines="2"
55        android:ellipsize="end"
56        android:visibility="gone"
57        android:paddingTop="3dp"
58        style="@style/TextAppearance.ChooserDefault"
59        android:drawableEnd="@drawable/chevron_right"
60        />
61
62    <!-- This is only relevant for image+text preview, but needs to be in this layout so it can
63         stay at the top if there's no reselection action. -->
64    <CheckBox
65        android:id="@+id/include_text_action"
66        android:layout_width="wrap_content"
67        android:layout_height="wrap_content"
68        android:maxWidth="@dimen/modify_share_text_toggle_max_width"
69        android:layout_marginTop="16dp"
70        app:layout_goneMarginTop="0dp"
71        app:layout_constraintEnd_toEndOf="parent"
72        app:layout_constraintTop_toBottomOf="@id/reselection_action"
73        android:layout_alignWithParentIfMissing="true"
74        android:textColor="?androidprv:attr/materialColorOnSurface"
75        android:visibility="gone" />
76
77</androidx.constraintlayout.widget.ConstraintLayout>
78