Home | History | Annotate | Download | only in layout
      1 <?xml version="1.0" encoding="utf-8"?>
      2 <!--
      3   Copyright (C) 2016 The Android Open Source Project
      4 
      5   Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file
      6   except in compliance with the License. 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 distributed under the
     11   License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
     12   KIND, either express or implied. See the License for the specific language governing
     13   permissions and limitations under the License.
     14   -->
     15 <LinearLayout
     16     xmlns:android="http://schemas.android.com/apk/res/android"
     17     android:orientation="vertical"
     18     android:layout_width="match_parent"
     19     android:layout_height="wrap_content"
     20     android:minHeight="?android:attr/listPreferredItemHeightSmall"
     21     android:paddingStart="?android:attr/listPreferredItemPaddingStart"
     22     android:paddingEnd="?android:attr/listPreferredItemPaddingEnd"
     23     android:background="?android:attr/selectableItemBackgroundBorderless"
     24     android:gravity="center_horizontal"
     25     android:clipToPadding="false">
     26 
     27     <FrameLayout
     28         android:layout_width="wrap_content"
     29         android:layout_height="wrap_content">
     30 
     31         <ImageView
     32             android:id="@android:id/icon"
     33             android:layout_width="wrap_content"
     34             android:layout_height="wrap_content"
     35             android:padding="10dp"
     36             android:scaleType="fitCenter" />
     37 
     38         <LinearLayout
     39             android:id="@+id/contextGroup"
     40             android:layout_width="match_parent"
     41             android:layout_height="wrap_content"
     42             android:visibility="invisible"
     43             android:layout_gravity="bottom">
     44 
     45             <ImageView
     46                 android:id="@android:id/shareText"
     47                 android:layout_width="40dp"
     48                 android:layout_height="40dp"
     49                 android:padding="8dp"
     50                 android:src="@drawable/ic_share"
     51                 android:scaleType="fitCenter"
     52                 android:background="#40000000"/>
     53 
     54             <Space
     55                 android:layout_width="0dp"
     56                 android:layout_height="0dp"
     57                 android:layout_weight="1" />
     58 
     59             <ImageView
     60                 android:id="@android:id/closeButton"
     61                 android:layout_width="40dp"
     62                 android:layout_height="40dp"
     63                 android:padding="4dp"
     64                 android:src="@drawable/ic_close"
     65                 android:scaleType="fitCenter"
     66                 android:background="#40000000"/>
     67 
     68         </LinearLayout>
     69 
     70     </FrameLayout>
     71 
     72     <TextView
     73         android:id="@android:id/title"
     74         android:layout_width="wrap_content"
     75         android:layout_height="wrap_content"
     76         android:textAppearance="?android:attr/textAppearanceListItem"
     77         android:gravity="center"/>
     78 </LinearLayout>
     79 
     80