1<?xml version="1.0" encoding="utf-8"?><!-- Copyright (C) 2022 The Android Open Source Project 2 3 Licensed under the Apache License, Version 2.0 (the "License"); 4 you may not use this file except in compliance with the License. 5 You may obtain a copy of the License at 6 7 http://www.apache.org/licenses/LICENSE-2.0 8 9 Unless required by applicable law or agreed to in writing, software 10 distributed under the License is distributed on an "AS IS" BASIS, 11 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 See the License for the specific language governing permissions and 13 limitations under the License. 14--> 15<com.android.launcher3.widget.picker.WidgetsTwoPaneSheet 16 xmlns:android="http://schemas.android.com/apk/res/android" 17 xmlns:tools="http://schemas.android.com/tools" 18 android:layout_width="match_parent" 19 android:layout_height="match_parent" 20 android:orientation="vertical" 21 android:theme="?attr/widgetsTheme"> 22 23 <com.android.launcher3.views.SpringRelativeLayout 24 android:id="@+id/container" 25 android:layout_width="match_parent" 26 android:layout_height="match_parent" 27 android:focusable="true" 28 android:importantForAccessibility="no"> 29 30 <View 31 android:id="@+id/collapse_handle" 32 android:layout_width="@dimen/bottom_sheet_handle_width" 33 android:layout_height="@dimen/bottom_sheet_handle_height" 34 android:layout_marginTop="@dimen/bottom_sheet_handle_margin" 35 android:layout_centerHorizontal="true" 36 android:background="@drawable/widget_picker_collapse_handle"/> 37 38 <TextView 39 android:id="@+id/title" 40 android:layout_width="match_parent" 41 android:layout_height="wrap_content" 42 android:layout_marginTop="24dp" 43 android:gravity="center_horizontal" 44 android:layout_below="@id/collapse_handle" 45 android:paddingHorizontal="@dimen/widget_list_horizontal_margin_two_pane" 46 android:text="@string/widget_button_text" 47 android:textColor="?attr/widgetPickerTitleColor" 48 android:textSize="24sp" /> 49 50 <TextView 51 android:id="@+id/no_widgets_text" 52 style="@style/PrimaryHeadline" 53 android:layout_width="match_parent" 54 android:layout_height="match_parent" 55 android:gravity="center" 56 android:textSize="18sp" 57 android:visibility="gone" 58 tools:text="@string/no_widgets_available" /> 59 60 <LinearLayout 61 android:id="@+id/linear_layout_container" 62 android:layout_width="match_parent" 63 android:layout_height="match_parent" 64 android:layout_below="@id/title"> 65 66 <FrameLayout 67 android:id="@+id/recycler_view_container" 68 android:layout_width="0dp" 69 android:layout_height="match_parent" 70 android:clipChildren="false" 71 android:clipToPadding="false" 72 android:paddingBottom="24dp" 73 android:layout_gravity="start" 74 android:layout_weight="0.33"> 75 <TextView 76 android:id="@+id/fast_scroller_popup" 77 style="@style/FastScrollerPopup" 78 android:layout_marginEnd="@dimen/fastscroll_popup_margin" /> 79 80 <!-- Fast scroller popup --> 81 <com.android.launcher3.views.RecyclerViewFastScroller 82 android:id="@+id/fast_scroller" 83 android:layout_width="@dimen/fastscroll_width" 84 android:layout_height="match_parent" 85 android:layout_marginEnd="@dimen/fastscroll_end_margin" /> 86 87 <com.android.launcher3.widget.picker.WidgetsRecyclerView 88 android:id="@+id/search_widgets_list_view" 89 android:layout_width="match_parent" 90 android:layout_height="wrap_content" 91 android:clipToPadding="false" 92 android:paddingHorizontal="@dimen/widget_list_horizontal_margin_two_pane" 93 android:visibility="gone" /> 94 </FrameLayout> 95 96 <FrameLayout 97 android:layout_width="0dp" 98 android:layout_height="match_parent" 99 android:layout_weight="0.67"> 100 <FrameLayout 101 android:id="@+id/right_pane_container" 102 android:layout_width="match_parent" 103 android:layout_height="match_parent" 104 android:layout_marginVertical="@dimen/widget_picker_vertical_margin_right_pane" 105 android:layout_marginEnd="@dimen/widget_list_horizontal_margin_two_pane" 106 android:gravity="end" 107 android:layout_gravity="end" 108 android:orientation="horizontal"> 109 <ScrollView 110 android:id="@+id/right_pane_scroll_view" 111 android:layout_width="match_parent" 112 android:layout_height="match_parent" 113 android:background="@drawable/widgets_surface_background" 114 android:scrollbarThumbVertical="@drawable/widget_picker_preview_pane_scroll_thumb" 115 android:clipToOutline="true" 116 android:fillViewport="true"> 117 <LinearLayout 118 android:orientation="vertical" 119 android:layout_width="match_parent" 120 android:layout_height="wrap_content" 121 android:gravity="center_vertical" 122 android:clipToOutline="true" 123 android:paddingBottom="36dp" 124 android:background="@drawable/widgets_surface_background" 125 android:importantForAccessibility="yes" 126 android:id="@+id/right_pane"> 127 <!-- Shown when there are recommendations to display --> 128 <LinearLayout 129 android:id="@+id/widget_recommendations_container" 130 android:layout_width="match_parent" 131 android:layout_height="match_parent" 132 android:background="@drawable/widgets_surface_background" 133 android:orientation="vertical" 134 android:visibility="gone"> 135 <include layout="@layout/widget_recommendations" /> 136 </LinearLayout> 137 </LinearLayout> 138 </ScrollView> 139 </FrameLayout> 140 </FrameLayout> 141 </LinearLayout> 142 </com.android.launcher3.views.SpringRelativeLayout> 143</com.android.launcher3.widget.picker.WidgetsTwoPaneSheet> 144