162 lines
5.9 KiB
XML
162 lines
5.9 KiB
XML
<?xml version="1.0" encoding="utf-8"?><!--
|
|
Copyright (C) 2013 The Android Open Source Project
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.
|
|
You may obtain a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
See the License for the specific language governing permissions and
|
|
limitations under the License.
|
|
-->
|
|
|
|
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
|
android:id="@+id/item_root"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:background="@drawable/list_item_background"
|
|
android:foreground="?android:attr/selectableItemBackground"
|
|
android:clickable="true"
|
|
android:focusable="true"
|
|
android:orientation="vertical">
|
|
|
|
<LinearLayout
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:baselineAligned="false"
|
|
android:gravity="center_vertical"
|
|
android:minHeight="@dimen/list_item_height"
|
|
android:orientation="horizontal">
|
|
|
|
<FrameLayout
|
|
android:id="@+id/icon"
|
|
android:pointerIcon="hand"
|
|
android:layout_width="@dimen/list_item_width"
|
|
android:layout_height="@dimen/list_item_height"
|
|
android:paddingBottom="@dimen/list_item_icon_padding"
|
|
android:paddingTop="@dimen/list_item_icon_padding"
|
|
android:paddingEnd="16dp"
|
|
android:paddingStart="@dimen/list_item_padding">
|
|
|
|
<com.google.android.material.card.MaterialCardView
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
app:cardBackgroundColor="@android:color/transparent"
|
|
app:cardElevation="0dp">
|
|
|
|
<ImageView
|
|
android:id="@+id/icon_mime"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_gravity="center"
|
|
android:contentDescription="@null"
|
|
android:scaleType="centerInside" />
|
|
|
|
<ImageView
|
|
android:id="@+id/icon_thumb"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
android:contentDescription="@null"
|
|
android:scaleType="centerCrop" />
|
|
|
|
<ImageView
|
|
android:id="@+id/icon_check"
|
|
android:layout_width="@dimen/check_icon_size"
|
|
android:layout_height="@dimen/check_icon_size"
|
|
android:layout_gravity="center"
|
|
android:alpha="0"
|
|
android:contentDescription="@null"
|
|
android:scaleType="fitCenter"
|
|
android:src="@drawable/ic_check_circle" />
|
|
|
|
</com.google.android.material.card.MaterialCardView>
|
|
|
|
</FrameLayout>
|
|
|
|
<LinearLayout
|
|
android:layout_width="0dp"
|
|
android:layout_height="wrap_content"
|
|
android:layout_weight="1"
|
|
android:orientation="vertical"
|
|
android:layout_gravity="center_vertical"
|
|
android:layout_marginEnd="@dimen/list_item_padding">
|
|
|
|
<LinearLayout
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="0dp"
|
|
android:layout_weight="1">
|
|
|
|
<ImageView
|
|
android:id="@+id/icon_briefcase"
|
|
android:layout_height="@dimen/briefcase_icon_size"
|
|
android:layout_width="@dimen/briefcase_icon_size"
|
|
android:layout_marginEnd="@dimen/briefcase_icon_margin"
|
|
android:layout_gravity="center_vertical"
|
|
android:src="@drawable/ic_briefcase"
|
|
android:contentDescription="@string/a11y_work" />
|
|
|
|
<TextView
|
|
android:id="@android:id/title"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:ellipsize="end"
|
|
android:singleLine="true"
|
|
android:textAlignment="viewStart"
|
|
android:textAppearance="?android:attr/textAppearanceListItem" />
|
|
|
|
</LinearLayout>
|
|
|
|
<LinearLayout
|
|
android:id="@+id/line2"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:baselineAligned="false"
|
|
android:layout_marginTop="4dp"
|
|
android:gravity="center_vertical"
|
|
android:orientation="horizontal">
|
|
|
|
<TextView
|
|
android:id="@+id/metadata"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:ellipsize="end"
|
|
android:singleLine="true"
|
|
android:textAppearance="@style/ItemCaptionText" />
|
|
|
|
</LinearLayout>
|
|
|
|
</LinearLayout>
|
|
|
|
<FrameLayout
|
|
android:id="@+id/preview_icon"
|
|
android:layout_width="@dimen/list_item_width"
|
|
android:layout_height="@dimen/list_item_height"
|
|
android:padding="@dimen/list_item_icon_padding"
|
|
android:focusable="true"
|
|
android:clickable="true">
|
|
|
|
<ImageView
|
|
android:layout_width="@dimen/check_icon_size"
|
|
android:layout_height="@dimen/check_icon_size"
|
|
android:layout_gravity="center"
|
|
android:scaleType="fitCenter"
|
|
android:tint="?android:attr/colorControlNormal"
|
|
android:src="@drawable/ic_zoom_out" />
|
|
|
|
</FrameLayout>
|
|
|
|
</LinearLayout>
|
|
|
|
<View
|
|
android:layout_width="match_parent"
|
|
android:layout_height="1dp"
|
|
android:layout_marginStart="72dp"
|
|
android:layout_marginEnd="8dp"
|
|
android:background="?android:strokeColor" />
|
|
|
|
</LinearLayout> |