1<?xml version="1.0" encoding="utf-8"?> 2<!-- 3/* 4* Copyright 2012, The Android Open Source Project 5* 6* Licensed under the Apache License, Version 2.0 (the "License"); 7* you may not use this file except in compliance with the License. 8* You may obtain a copy of the License at 9* 10* http://www.apache.org/licenses/LICENSE-2.0 11* 12* Unless required by applicable law or agreed to in writing, software 13* distributed under the License is distributed on an "AS IS" BASIS, 14* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15* See the License for the specific language governing permissions and 16* limitations under the License. 17*/ 18--> 19<com.android.intentresolver.widget.ResolverDrawerLayout 20 xmlns:android="http://schemas.android.com/apk/res/android" 21 xmlns:androidprv="http://schemas.android.com/apk/prv/res/android" 22 xmlns:app="http://schemas.android.com/apk/res-auto" 23 android:layout_width="match_parent" 24 android:layout_height="match_parent" 25 android:maxWidth="@dimen/resolver_max_width" 26 app:maxCollapsedHeight="@dimen/resolver_max_collapsed_height" 27 app:maxCollapsedHeightSmall="56dp" 28 android:id="@androidprv:id/contentPanel"> 29 30 <RelativeLayout 31 android:id="@androidprv:id/title_container" 32 android:layout_width="match_parent" 33 android:layout_height="wrap_content" 34 app:layout_alwaysShow="true" 35 android:elevation="@dimen/resolver_elevation" 36 android:paddingTop="@dimen/resolver_small_margin" 37 android:paddingStart="@dimen/resolver_edge_margin" 38 android:paddingEnd="@dimen/resolver_edge_margin" 39 android:paddingBottom="@dimen/resolver_title_padding_bottom" 40 android:background="@drawable/bottomsheet_background"> 41 42 <TextView 43 android:id="@androidprv:id/profile_button" 44 android:layout_width="wrap_content" 45 android:layout_height="48dp" 46 android:layout_marginEnd="8dp" 47 android:visibility="gone" 48 style="?android:attr/borderlessButtonStyle" 49 android:textAppearance="?android:attr/textAppearanceButton" 50 android:textColor="?android:attr/colorAccent" 51 android:gravity="center_vertical" 52 android:layout_alignParentTop="true" 53 android:layout_alignParentEnd="true" 54 android:singleLine="true" /> 55 56 <TextView 57 android:id="@android:id/title" 58 android:layout_width="match_parent" 59 android:layout_height="wrap_content" 60 android:layout_below="@androidprv:id/profile_button" 61 android:layout_alignParentStart="true" 62 android:textColor="?android:attr/textColorPrimary" 63 android:fontFamily="@androidprv:string/config_headlineFontFamilyMedium" 64 android:textSize="16sp" 65 android:gravity="start|center_vertical" /> 66 </RelativeLayout> 67 68 <View 69 android:id="@androidprv:id/divider" 70 app:layout_alwaysShow="true" 71 android:layout_width="match_parent" 72 android:layout_height="1dp" 73 android:background="?android:attr/colorBackground" 74 android:foreground="?android:attr/dividerVertical" /> 75 76 <FrameLayout 77 android:id="@androidprv:id/stub" 78 android:visibility="gone" 79 android:layout_width="match_parent" 80 android:layout_height="wrap_content" 81 android:background="?android:attr/colorBackground"/> 82 83 <TabHost 84 android:id="@androidprv:id/profile_tabhost" 85 android:layout_width="match_parent" 86 android:layout_height="wrap_content" 87 android:layout_alignParentTop="true" 88 android:layout_centerHorizontal="true" 89 android:accessibilityTraversalAfter="@android:id/title" 90 android:background="?android:attr/colorBackground"> 91 <LinearLayout 92 android:orientation="vertical" 93 android:layout_width="match_parent" 94 android:layout_height="wrap_content"> 95 <!-- horizontal padding = 8dp content padding - 4dp margin that tab buttons have. --> 96 <TabWidget 97 android:id="@android:id/tabs" 98 android:layout_width="match_parent" 99 android:layout_height="wrap_content" 100 android:tabStripEnabled="false" 101 android:paddingHorizontal="4dp" 102 android:visibility="gone" /> 103 <FrameLayout 104 android:id="@android:id/tabcontent" 105 android:layout_width="match_parent" 106 android:layout_height="wrap_content"> 107 <com.android.intentresolver.ResolverViewPager 108 android:id="@androidprv:id/profile_pager" 109 android:layout_width="match_parent" 110 android:layout_height="wrap_content" /> 111 </FrameLayout> 112 </LinearLayout> 113 </TabHost> 114 <LinearLayout 115 android:id="@androidprv:id/button_bar_container" 116 android:layout_width="match_parent" 117 android:layout_height="wrap_content" 118 app:layout_alwaysShow="true" 119 android:orientation="vertical" 120 android:background="?android:attr/colorBackground" 121 app:layout_ignoreOffset="true"> 122 <View 123 android:id="@androidprv:id/resolver_button_bar_divider" 124 android:layout_width="match_parent" 125 android:layout_height="1dp" 126 android:background="?android:attr/colorBackground" 127 android:foreground="?android:attr/dividerVertical" /> 128 <LinearLayout 129 android:id="@androidprv:id/button_bar" 130 android:visibility="gone" 131 style="?android:attr/buttonBarStyle" 132 android:layout_width="match_parent" 133 android:layout_height="wrap_content" 134 app:layout_ignoreOffset="true" 135 app:layout_hasNestedScrollIndicator="true" 136 android:gravity="end|center_vertical" 137 android:orientation="horizontal" 138 android:layoutDirection="locale" 139 android:measureWithLargestChild="true" 140 android:paddingTop="@dimen/resolver_button_bar_spacing" 141 android:paddingBottom="@dimen/resolver_button_bar_spacing" 142 android:paddingStart="@dimen/resolver_edge_margin" 143 android:paddingEnd="@dimen/resolver_small_margin" 144 android:elevation="@dimen/resolver_elevation"> 145 146 <Button 147 android:id="@androidprv:id/button_once" 148 android:layout_width="wrap_content" 149 android:layout_gravity="start" 150 android:maxLines="2" 151 style="?android:attr/buttonBarButtonStyle" 152 android:fontFamily="@androidprv:string/config_headlineFontFamilyMedium" 153 android:layout_height="wrap_content" 154 android:textAllCaps="false" 155 android:enabled="false" 156 android:text="@string/activity_resolver_use_once" 157 android:onClick="onButtonClick" /> 158 159 <Button 160 android:id="@androidprv:id/button_always" 161 android:layout_width="wrap_content" 162 android:layout_gravity="end" 163 android:maxLines="2" 164 style="?android:attr/buttonBarButtonStyle" 165 android:fontFamily="@androidprv:string/config_headlineFontFamilyMedium" 166 android:textAllCaps="false" 167 android:layout_height="wrap_content" 168 android:enabled="false" 169 android:text="@string/activity_resolver_use_always" 170 android:onClick="onButtonClick" /> 171 </LinearLayout> 172 </LinearLayout> 173</com.android.intentresolver.widget.ResolverDrawerLayout> 174