blob: b169ec89320afee72970401f6dd5947be23fb851 [file] [log] [blame]
Jeff Sharkey54e55b72013-06-30 20:02:59 -07001<?xml version="1.0" encoding="utf-8"?>
Ben Kwaddc3d212016-01-07 18:50:34 -08002<!--
3 Copyright (C) 2013 The Android Open Source Project
Jeff Sharkey54e55b72013-06-30 20:02:59 -07004
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
Ben Kwad7915d22015-10-26 11:54:41 -070018<com.android.documentsui.ListItem xmlns:android="http://schemas.android.com/apk/res/android"
Jeff Sharkey54e55b72013-06-30 20:02:59 -070019 android:layout_width="match_parent"
20 android:layout_height="wrap_content"
Ben Kwad27906e2015-11-10 21:02:47 -080021 android:background="@color/item_doc_background"
Ben Kwaddc3d212016-01-07 18:50:34 -080022 android:focusable="true"
23 android:orientation="horizontal" >
Ben Kwad27906e2015-11-10 21:02:47 -080024
Ben Kwabd964562015-10-14 08:00:27 -070025 <View
26 android:id="@+id/focus_indicator"
27 android:layout_width="4dp"
28 android:layout_height="match_parent" />
Jeff Sharkey54e55b72013-06-30 20:02:59 -070029
Jeff Sharkeyb156f4b2013-08-06 16:26:14 -070030 <LinearLayout
Jeff Sharkey69631482014-07-27 21:01:45 -070031 android:layout_width="match_parent"
Jeff Sharkeyb156f4b2013-08-06 16:26:14 -070032 android:layout_height="wrap_content"
Ben Kwaddc3d212016-01-07 18:50:34 -080033 android:baselineAligned="false"
Jeff Sharkey69631482014-07-27 21:01:45 -070034 android:gravity="center_vertical"
Ben Kwaddc3d212016-01-07 18:50:34 -080035 android:minHeight="@dimen/list_item_height"
Jeff Sharkey69631482014-07-27 21:01:45 -070036 android:orientation="horizontal"
Ben Kwaddc3d212016-01-07 18:50:34 -080037 android:paddingEnd="@dimen/list_item_padding"
38 android:paddingStart="@dimen/list_item_padding" >
Jeff Sharkey54e55b72013-06-30 20:02:59 -070039
Jeff Sharkey69631482014-07-27 21:01:45 -070040 <FrameLayout
41 android:id="@android:id/icon"
Ben Kwaddc3d212016-01-07 18:50:34 -080042 android:layout_width="@dimen/list_item_thumbnail_size"
43 android:layout_height="@dimen/list_item_thumbnail_size"
44 android:layout_marginEnd="16dp" >
Jeff Sharkey28c05ee2013-09-06 13:22:09 -070045
Jeff Sharkeyb156f4b2013-08-06 16:26:14 -070046 <ImageView
Jeff Sharkey69631482014-07-27 21:01:45 -070047 android:id="@+id/icon_mime"
48 android:layout_width="wrap_content"
Ben Kwaddc3d212016-01-07 18:50:34 -080049 android:layout_height="wrap_content"
50 android:layout_gravity="center"
51 android:contentDescription="@null"
52 android:scaleType="centerInside" />
Jeff Sharkeyb156f4b2013-08-06 16:26:14 -070053
Jeff Sharkey69631482014-07-27 21:01:45 -070054 <ImageView
55 android:id="@+id/icon_thumb"
56 android:layout_width="match_parent"
57 android:layout_height="match_parent"
Ben Kwaddc3d212016-01-07 18:50:34 -080058 android:contentDescription="@null"
59 android:scaleType="centerCrop" />
Jeff Sharkey69631482014-07-27 21:01:45 -070060
Ben Kwaddc3d212016-01-07 18:50:34 -080061 <ImageView
62 android:id="@+id/icon_check"
63 android:layout_width="@dimen/check_icon_size"
64 android:layout_height="@dimen/check_icon_size"
65 android:layout_gravity="center"
66 android:alpha="0"
67 android:contentDescription="@null"
68 android:scaleType="fitCenter"
69 android:src="@drawable/ic_check_circle" />
Jeff Sharkey69631482014-07-27 21:01:45 -070070 </FrameLayout>
Jeff Sharkey28c05ee2013-09-06 13:22:09 -070071
72 <LinearLayout
Jeff Sharkey69631482014-07-27 21:01:45 -070073 android:layout_width="0dp"
Jeff Sharkey28c05ee2013-09-06 13:22:09 -070074 android:layout_height="wrap_content"
Jeff Sharkey69631482014-07-27 21:01:45 -070075 android:layout_weight="1"
Ben Kwaddc3d212016-01-07 18:50:34 -080076 android:orientation="vertical" >
Jeff Sharkey28c05ee2013-09-06 13:22:09 -070077
Ben Kwaddc3d212016-01-07 18:50:34 -080078 <TextView
79 android:id="@android:id/title"
80 android:layout_width="wrap_content"
81 android:layout_height="0dp"
82 android:layout_weight="1"
Steve McKayda48a9a2016-02-24 12:57:06 -080083 android:ellipsize="end"
Ben Kwaddc3d212016-01-07 18:50:34 -080084 android:singleLine="true"
85 android:textAlignment="viewStart"
86 android:textAppearance="@android:style/TextAppearance.Material.Subhead"
87 android:textColor="?android:attr/textColorPrimary" />
Jeff Sharkey69631482014-07-27 21:01:45 -070088
89 <LinearLayout
90 android:id="@+id/line2"
91 android:layout_width="match_parent"
Jeff Sharkeyb156f4b2013-08-06 16:26:14 -070092 android:layout_height="wrap_content"
Ben Kwaddc3d212016-01-07 18:50:34 -080093 android:baselineAligned="false"
Jeff Sharkey69631482014-07-27 21:01:45 -070094 android:gravity="center_vertical"
Ben Kwaddc3d212016-01-07 18:50:34 -080095 android:orientation="horizontal" >
Jeff Sharkey69631482014-07-27 21:01:45 -070096
97 <TextView
98 android:id="@+id/date"
99 android:layout_width="90dp"
100 android:layout_height="wrap_content"
Jeff Sharkey69631482014-07-27 21:01:45 -0700101 android:ellipsize="end"
Ben Kwaddc3d212016-01-07 18:50:34 -0800102 android:singleLine="true"
Jeff Sharkey69631482014-07-27 21:01:45 -0700103 android:textAlignment="viewStart"
104 android:textAppearance="@android:style/TextAppearance.Material.Body1"
105 android:textColor="?android:attr/textColorSecondary" />
106
107 <TextView
108 android:id="@+id/size"
109 android:layout_width="90dp"
110 android:layout_height="wrap_content"
111 android:layout_marginStart="8dp"
Jeff Sharkey69631482014-07-27 21:01:45 -0700112 android:ellipsize="end"
Ben Kwaddc3d212016-01-07 18:50:34 -0800113 android:singleLine="true"
Jeff Sharkey69631482014-07-27 21:01:45 -0700114 android:textAlignment="viewStart"
115 android:textAppearance="@android:style/TextAppearance.Material.Body1"
116 android:textColor="?android:attr/textColorSecondary" />
117
118 <TextView
119 android:id="@android:id/summary"
120 android:layout_width="0dp"
121 android:layout_height="wrap_content"
Jeff Sharkey69631482014-07-27 21:01:45 -0700122 android:layout_marginStart="8dp"
Ben Kwaddc3d212016-01-07 18:50:34 -0800123 android:layout_weight="1"
Jeff Sharkey69631482014-07-27 21:01:45 -0700124 android:ellipsize="end"
Ben Kwaddc3d212016-01-07 18:50:34 -0800125 android:singleLine="true"
Jeff Sharkey69631482014-07-27 21:01:45 -0700126 android:textAlignment="viewStart"
127 android:textAppearance="@android:style/TextAppearance.Material.Body1"
128 android:textColor="?android:attr/textColorSecondary" />
Jeff Sharkey69631482014-07-27 21:01:45 -0700129 </LinearLayout>
Jeff Sharkeyb156f4b2013-08-06 16:26:14 -0700130 </LinearLayout>
Jeff Sharkeyb156f4b2013-08-06 16:26:14 -0700131 </LinearLayout>
132
Ben Kwad7915d22015-10-26 11:54:41 -0700133</com.android.documentsui.ListItem>