OSDN Git Service

Merge changes from topic "am-b95e3cad-9610-4d9b-96a8-a82f585400e6" into oc-dev am...
[android-x86/packages-apps-Settings.git] / res / layout / storage_item.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <!-- Copyright (C) 2015 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
17 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
18               android:layout_width="match_parent"
19               android:layout_height="wrap_content"
20               android:orientation="vertical"
21               android:minHeight="?android:attr/listPreferredItemHeightSmall"
22               android:gravity="center_vertical"
23               android:paddingEnd="?android:attr/listPreferredItemPaddingEnd"
24               android:paddingTop="14dp"
25               android:paddingBottom="14dp"
26               android:background="?android:attr/selectableItemBackground"
27               android:clipToPadding="false">
28
29     <LinearLayout
30         android:layout_width="match_parent"
31         android:layout_height="wrap_content"
32         android:gravity="center_vertical"
33         android:orientation="horizontal"
34         android:clipToPadding="false"
35         android:paddingStart="?android:attr/listPreferredItemPaddingStart">
36
37         <LinearLayout
38             android:id="@+id/icon_frame"
39             style="@style/preference_icon_frame"
40             android:layout_width="wrap_content"
41             android:layout_height="wrap_content"
42             android:gravity="start|center_vertical"
43             android:orientation="horizontal"
44             android:paddingEnd="12dp"
45             android:paddingTop="4dp"
46             android:paddingBottom="4dp">
47             <com.android.internal.widget.PreferenceImageView
48                 android:id="@android:id/icon"
49                 android:layout_width="wrap_content"
50                 android:layout_height="wrap_content"
51                 android:maxWidth="24dp"
52                 android:maxHeight="24dp"/>
53         </LinearLayout>
54
55         <RelativeLayout
56             android:layout_width="match_parent"
57             android:layout_height="wrap_content"
58             android:gravity="center_vertical" >
59
60             <TextView
61                 android:id="@android:id/title"
62                 android:layout_width="wrap_content"
63                 android:layout_height="wrap_content"
64                 android:singleLine="true"
65                 android:textAppearance="@android:style/TextAppearance.Material.Subhead"
66                 android:textAlignment="viewStart"
67                 android:ellipsize="marquee"
68                 android:fadingEdge="horizontal" />
69
70             <TextView
71                 android:id="@android:id/summary"
72                 android:layout_width="wrap_content"
73                 android:layout_height="wrap_content"
74                 android:textAlignment="viewStart"
75                 android:textAppearance="@android:style/TextAppearance.Material.Body1"
76                 android:textColor="?android:attr/textColorSecondaryNoDisable"
77                 android:maxLines="10"
78                 android:layout_alignParentEnd="true"/>
79
80             <ProgressBar
81                 android:id="@android:id/progress"
82                 android:layout_width="match_parent"
83                 android:layout_height="8dp"
84                 android:layout_marginTop="12dp"
85                 android:layout_marginBottom="4dp"
86                 android:max="100"
87                 android:layout_below="@android:id/title"
88                 android:layout_alignStart="@android:id/title"
89                 style="?android:attr/progressBarStyleHorizontal" />
90         </RelativeLayout>
91     </LinearLayout>
92 </LinearLayout>