blob: d47fa4f4e9e70a42c8924779c4e699e4f0836b52 [file] [log] [blame]
Jeff Sharkey46165b52013-07-31 20:53:22 -07001<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (C) 2013 The Android Open Source Project
3
4 Licensed under the Apache License, Version 2.0 (the "License");
5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at
7
8 http://www.apache.org/licenses/LICENSE-2.0
9
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
15-->
16
Steve McKayd0805062016-09-15 14:30:38 -070017<com.android.documentsui.sidebar.RootItemView
Garfield, Tan57facaf72016-05-27 15:02:35 -070018 xmlns:android="http://schemas.android.com/apk/res/android"
Jeff Sharkey46165b52013-07-31 20:53:22 -070019 android:layout_width="match_parent"
20 android:layout_height="wrap_content"
Jeff Sharkeye6fcceb2014-07-28 16:38:52 -070021 android:minHeight="48dp"
Jon Manndea54912017-02-16 15:11:57 -080022 android:paddingStart="25dp"
Jeff Sharkey46165b52013-07-31 20:53:22 -070023 android:gravity="center_vertical"
Jeff Sharkey42d26792013-09-06 13:22:09 -070024 android:orientation="horizontal"
Garfield, Tan57facaf72016-05-27 15:02:35 -070025 android:baselineAligned="false"
26 android:background="@drawable/root_item_background">
Jeff Sharkey46165b52013-07-31 20:53:22 -070027
Jeff Sharkeye6fcceb2014-07-28 16:38:52 -070028 <FrameLayout
Jeff Sharkey42d26792013-09-06 13:22:09 -070029 android:layout_width="@dimen/icon_size"
30 android:layout_height="@dimen/icon_size"
Jeff Sharkey7e544612014-08-29 15:38:27 -070031 android:duplicateParentState="true">
Jeff Sharkeye6fcceb2014-07-28 16:38:52 -070032
33 <ImageView
34 android:id="@android:id/icon"
35 android:layout_width="@dimen/root_icon_size"
36 android:layout_height="match_parent"
37 android:scaleType="centerInside"
Jeff Sharkey7e544612014-08-29 15:38:27 -070038 android:contentDescription="@null"
39 android:duplicateParentState="true" />
Jeff Sharkeye6fcceb2014-07-28 16:38:52 -070040
41 </FrameLayout>
Jeff Sharkey46165b52013-07-31 20:53:22 -070042
43 <LinearLayout
44 android:layout_width="match_parent"
45 android:layout_height="wrap_content"
Jon Manndea54912017-02-16 15:11:57 -080046 android:paddingStart="16dp"
Jeff Sharkeye6fcceb2014-07-28 16:38:52 -070047 android:paddingTop="8dp"
48 android:paddingBottom="8dp"
Ben Lin5668b862016-06-28 17:12:52 -070049 android:orientation="vertical"
50 android:layout_weight="1">
Jeff Sharkey46165b52013-07-31 20:53:22 -070051
52 <TextView
53 android:id="@android:id/title"
54 android:layout_width="match_parent"
55 android:layout_height="wrap_content"
56 android:singleLine="true"
Jeff Sharkey6a9bf982013-10-07 11:39:07 -070057 android:ellipsize="end"
Jeff Sharkey5e1884d2013-09-10 17:56:39 -070058 android:textAlignment="viewStart"
Jon Manndea54912017-02-16 15:11:57 -080059 android:fontFamily="sans-serif-medium"
60 android:textSize="14sp"
Jeff Sharkey7e544612014-08-29 15:38:27 -070061 android:textColor="@color/item_root_primary_text" />
Jeff Sharkey46165b52013-07-31 20:53:22 -070062
63 <TextView
64 android:id="@android:id/summary"
65 android:layout_width="match_parent"
66 android:layout_height="wrap_content"
67 android:singleLine="true"
Jeff Sharkey6a9bf982013-10-07 11:39:07 -070068 android:ellipsize="end"
Jeff Sharkey5e1884d2013-09-10 17:56:39 -070069 android:textAlignment="viewStart"
Jon Manndea54912017-02-16 15:11:57 -080070 android:fontFamily="sans-serif-medium"
71 android:textSize="13sp"
72 android:textColor="@color/root_details_color" />
Jeff Sharkey46165b52013-07-31 20:53:22 -070073
74 </LinearLayout>
75
Jon Manndea54912017-02-16 15:11:57 -080076 <FrameLayout
Ben Lin5668b862016-06-28 17:12:52 -070077 android:layout_width="@dimen/icon_size"
78 android:layout_height="@dimen/icon_size"
79 android:duplicateParentState="true">
80
81 <ImageView
Ben Lin821727a2016-07-08 10:49:53 -070082 android:id="@+id/eject_icon"
Ben Lin5668b862016-06-28 17:12:52 -070083 android:layout_width="@dimen/root_icon_size"
84 android:layout_height="match_parent"
85 android:scaleType="centerInside"
86 android:contentDescription="@string/menu_eject_root"
87 android:visibility="gone" />
88
89 </FrameLayout>
90
Steve McKayd0805062016-09-15 14:30:38 -070091</com.android.documentsui.sidebar.RootItemView>