1 <?xml version="1.0" encoding="utf-8"?> 2 <!-- Copyright (C) 2010 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 <RelativeLayout 18 xmlns:android="http://schemas.android.com/apk/res/android" 19 android:id="@+id/widget_message" 20 android:layout_width="match_parent" 21 android:layout_height="64sp" 22 android:background="@drawable/conversation_unread_selector" 23 > 24 <ImageView 25 android:id="@+id/color_chip" 26 android:layout_width="32dip" 27 android:layout_height="4dip" 28 android:layout_marginRight="16dip" 29 android:layout_alignParentTop="true" 30 android:layout_alignParentRight="true" 31 android:visibility="visible" 32 /> 33 <LinearLayout 34 android:layout_width="match_parent" 35 android:layout_height="wrap_content" 36 android:layout_marginLeft="16dip" 37 android:layout_marginRight="16dip" 38 android:layout_centerVertical="true" 39 android:orientation="vertical" 40 > 41 <LinearLayout 42 android:layout_width="match_parent" 43 android:layout_height="wrap_content" 44 android:orientation="horizontal" 45 > 46 <TextView 47 android:id="@+id/widget_from" 48 style="@style/widget_list_item" 49 android:layout_width="wrap_content" 50 android:layout_height="wrap_content" 51 android:layout_weight="1" 52 android:paddingRight="16dip" 53 android:singleLine="true" /> 54 <!-- Use negative margins to align attachment icon with text --> 55 <ImageView 56 android:id="@+id/widget_invite" 57 android:layout_width="wrap_content" 58 android:layout_height="wrap_content" 59 android:layout_marginTop="-4sp" 60 android:src="@drawable/ic_badge_invite_holo_light" /> 61 <ImageView 62 android:id="@+id/widget_attachment" 63 android:layout_width="wrap_content" 64 android:layout_height="wrap_content" 65 android:layout_marginTop="-4sp" 66 android:src="@drawable/ic_attachment_holo_light" /> 67 <TextView 68 android:id="@+id/widget_date" 69 style="@style/widget_list_item" 70 android:layout_width="wrap_content" 71 android:layout_height="wrap_content" /> 72 </LinearLayout> 73 <TextView 74 android:id="@+id/widget_subject" 75 android:layout_width="match_parent" 76 android:layout_height="wrap_content" 77 style="@style/widget_list_item" 78 android:layout_marginTop="-4sp" 79 android:maxLines="2"/> 80 </LinearLayout> 81 </RelativeLayout> 82