xref: /aosp_15_r20/frameworks/base/packages/SystemUI/res/layout/app_clips_screenshot.xml (revision d57664e9bc4670b3ecf6748a746a57c557b6bc9e)
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<androidx.constraintlayout.widget.ConstraintLayout
18    xmlns:android="http://schemas.android.com/apk/res/android"
19    xmlns:androidprv="http://schemas.android.com/apk/prv/res/android"
20    xmlns:app="http://schemas.android.com/apk/res-auto"
21    xmlns:tools="http://schemas.android.com/tools"
22    android:background="@null"
23    android:id="@+id/root"
24    android:layout_width="match_parent"
25    android:layout_height="match_parent">
26
27    <Button
28        android:id="@+id/save"
29        style="@android:style/Widget.DeviceDefault.Button.Colored"
30        android:layout_width="wrap_content"
31        android:layout_height="48dp"
32        android:layout_marginStart="8dp"
33        android:background="@drawable/overlay_button_background"
34        android:backgroundTint="?androidprv:attr/materialColorPrimary"
35        android:paddingHorizontal="24dp"
36        android:text="@string/app_clips_save_add_to_note"
37        android:textColor="?androidprv:attr/materialColorOnPrimary"
38        app:layout_constraintBottom_toTopOf="@id/preview"
39        app:layout_constraintStart_toStartOf="parent"
40        app:layout_constraintTop_toTopOf="parent" />
41
42    <Button
43        android:id="@+id/cancel"
44        style="@android:style/Widget.DeviceDefault.Button.Colored"
45        android:layout_width="wrap_content"
46        android:layout_height="48dp"
47        android:layout_marginStart="8dp"
48        android:background="@drawable/overlay_button_background"
49        android:paddingHorizontal="24dp"
50        android:text="@android:string/cancel"
51        android:textColor="?android:textColorSecondary"
52        app:layout_constraintBottom_toTopOf="@id/preview"
53        app:layout_constraintStart_toEndOf="@id/save"
54        app:layout_constraintTop_toTopOf="parent" />
55
56    <CheckBox
57        android:id="@+id/backlinks_include_data"
58        android:layout_width="wrap_content"
59        android:layout_height="48dp"
60        android:layout_marginStart="16dp"
61        android:button="@drawable/checkbox_circle_shape"
62        android:checked="true"
63        android:text="@string/backlinks_include_link"
64        android:textColor="?androidprv:attr/materialColorOnBackground"
65        android:visibility="gone"
66        app:layout_constraintBottom_toTopOf="@id/preview"
67        app:layout_constraintStart_toEndOf="@id/cancel"
68        app:layout_constraintTop_toTopOf="parent" />
69
70    <TextView
71        android:id="@+id/backlinks_data"
72        android:layout_width="wrap_content"
73        android:layout_height="48dp"
74        android:layout_marginStart="16dp"
75        android:background="@drawable/backlinks_rounded_rectangle"
76        android:drawablePadding="4dp"
77        android:gravity="center"
78        android:paddingHorizontal="8dp"
79        android:textColor="?android:textColorSecondary"
80        android:visibility="gone"
81        app:layout_constraintBottom_toTopOf="@id/preview"
82        app:layout_constraintStart_toEndOf="@id/backlinks_include_data"
83        app:layout_constraintTop_toTopOf="parent" />
84
85    <TextView
86        android:id="@+id/backlinks_cross_profile_error"
87        android:layout_width="wrap_content"
88        android:layout_height="48dp"
89        android:layout_marginStart="8dp"
90        android:drawablePadding="4dp"
91        android:drawableStart="@drawable/ic_info_outline"
92        android:drawableTint="?androidprv:attr/materialColorOnBackground"
93        android:gravity="center"
94        android:paddingHorizontal="8dp"
95        android:text="@string/backlinks_cross_profile_error"
96        android:textColor="?androidprv:attr/materialColorOnBackground"
97        android:visibility="gone"
98        app:layout_constraintBottom_toTopOf="@id/preview"
99        app:layout_constraintStart_toEndOf="@id/backlinks_data"
100        app:layout_constraintTop_toTopOf="parent" />
101
102    <ImageView
103        android:id="@+id/preview"
104        android:layout_width="0px"
105        android:layout_height="0px"
106        android:paddingHorizontal="48dp"
107        android:paddingTop="8dp"
108        android:paddingBottom="42dp"
109        android:contentDescription="@string/screenshot_preview_description"
110        app:layout_constrainedHeight="true"
111        app:layout_constrainedWidth="true"
112        app:layout_constraintTop_toBottomOf="@id/save"
113        app:layout_constraintEnd_toEndOf="parent"
114        app:layout_constraintStart_toStartOf="parent"
115        app:layout_constraintBottom_toBottomOf="parent"
116        tools:background="?android:colorBackground"
117        tools:minHeight="100dp"
118        tools:minWidth="100dp" />
119
120    <com.android.systemui.screenshot.scroll.CropView
121        android:id="@+id/crop_view"
122        android:layout_width="0px"
123        android:layout_height="0px"
124        android:paddingTop="8dp"
125        android:paddingBottom="42dp"
126        app:layout_constrainedHeight="true"
127        app:layout_constrainedWidth="true"
128        app:layout_constraintTop_toTopOf="@id/preview"
129        app:layout_constraintEnd_toEndOf="parent"
130        app:layout_constraintStart_toStartOf="parent"
131        app:layout_constraintBottom_toBottomOf="parent"
132        app:handleThickness="@dimen/screenshot_crop_handle_thickness"
133        app:handleColor="?android:attr/colorAccent"
134        app:scrimColor="?android:colorBackgroundFloating"
135        app:scrimAlpha="128"
136        app:containerBackgroundColor="?android:colorBackgroundFloating"
137        tools:background="?android:colorBackground"
138        tools:minHeight="100dp"
139        tools:minWidth="100dp" />
140</androidx.constraintlayout.widget.ConstraintLayout>
141