1<?xml version="1.0" encoding="utf-8"?>
2<!--
3  ~ Copyright (C) 2022 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<com.android.intentresolver.widget.ResolverDrawerLayout
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    android:layout_width="match_parent"
22    android:layout_height="match_parent"
23    android:maxWidth="@dimen/resolver_max_width"
24    app:maxCollapsedHeight="@dimen/resolver_max_collapsed_height"
25    app:maxCollapsedHeightSmall="56dp"
26    android:id="@androidprv:id/contentPanel">
27
28    <RelativeLayout
29        android:layout_width="match_parent"
30        android:layout_height="wrap_content"
31        app:layout_alwaysShow="true"
32        android:elevation="@dimen/resolver_elevation"
33        android:paddingTop="24dp"
34        android:paddingStart="@dimen/resolver_edge_margin"
35        android:paddingEnd="@dimen/resolver_edge_margin"
36        android:paddingBottom="@dimen/resolver_title_padding_bottom"
37        android:background="@drawable/bottomsheet_background">
38
39        <ImageView
40            android:id="@android:id/icon"
41            android:layout_width="48dp"
42            android:layout_height="48dp"
43            android:layout_alignParentTop="true"
44            android:layout_centerHorizontal="true"
45            android:scaleType="fitCenter"
46        />
47
48        <TextView
49            android:id="@androidprv:id/open_cross_profile"
50            android:layout_width="wrap_content"
51            android:layout_height="wrap_content"
52            android:paddingTop="16dp"
53            android:layout_below="@android:id/icon"
54            android:layout_centerHorizontal="true"
55            android:textSize="24sp"
56            android:lineHeight="32sp"
57            android:gravity="center"
58            android:textColor="?android:textColorPrimary"
59        />
60    </RelativeLayout>
61
62    <LinearLayout
63        android:id="@androidprv:id/button_bar_container"
64        android:layout_width="match_parent"
65        android:layout_height="wrap_content"
66        app:layout_alwaysShow="true"
67        android:paddingTop="32dp"
68        android:paddingBottom="@dimen/resolver_button_bar_spacing"
69        android:orientation="vertical"
70        android:background="?android:attr/colorBackground"
71        app:layout_ignoreOffset="true">
72        <RelativeLayout
73            style="?android:attr/buttonBarStyle"
74            android:layout_width="match_parent"
75            android:layout_height="wrap_content"
76            app:layout_ignoreOffset="true"
77            app:layout_hasNestedScrollIndicator="true"
78            android:gravity="end|center_vertical"
79            android:orientation="horizontal"
80            android:layoutDirection="locale"
81            android:measureWithLargestChild="true"
82            android:paddingHorizontal="16dp"
83            android:paddingBottom="2dp"
84            android:elevation="@dimen/resolver_elevation">
85
86            <Button
87                android:id="@androidprv:id/use_same_profile_browser"
88                android:layout_width="wrap_content"
89                android:layout_height="wrap_content"
90                android:layout_alignParentStart="true"
91                android:maxLines="2"
92                android:background="@drawable/resolver_outlined_button_bg"
93                style="?android:attr/borderlessButtonStyle"
94                android:paddingHorizontal="16dp"
95                android:fontFamily="@androidprv:string/config_headlineFontFamilyMedium"
96                android:textAllCaps="false"
97                android:text="@string/activity_resolver_use_once"
98            />
99
100            <Button
101                android:id="@androidprv:id/button_open"
102                android:layout_width="wrap_content"
103                android:layout_height="wrap_content"
104                android:layout_alignParentEnd="true"
105                android:maxLines="2"
106                android:paddingHorizontal="16dp"
107                android:background="@drawable/resolver_button_bg"
108                style="?android:attr/borderlessButtonStyle"
109                android:fontFamily="@androidprv:string/config_headlineFontFamilyMedium"
110                android:textAllCaps="false"
111                android:textColor="@androidprv:color/resolver_button_text"
112                android:text="@string/whichViewApplicationLabel"
113            />
114        </RelativeLayout>
115    </LinearLayout>
116</com.android.intentresolver.widget.ResolverDrawerLayout>
117