1<!-- 2 Copyright (C) 2013 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<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 17 android:layout_width="match_parent" 18 android:layout_height="wrap_content" 19 android:paddingBottom="6dp" 20 android:paddingTop="6dp" 21 android:paddingStart="?android:attr/listPreferredItemPaddingStart" 22 android:paddingEnd="?android:attr/listPreferredItemPaddingEnd" 23 android:orientation="vertical" 24 android:background="?android:attr/selectableItemBackground" 25 > 26 27 <RelativeLayout 28 android:layout_width="match_parent" 29 android:layout_height="wrap_content" 30 > 31 32 <ImageView 33 android:id="@+id/icon" 34 android:layout_width="@*android:dimen/status_bar_icon_size" 35 android:layout_height="@*android:dimen/status_bar_icon_size" 36 android:layout_centerVertical="true" 37 android:layout_toEndOf="@+id/pkgicon" 38 android:layout_marginStart="0dp" 39 android:layout_marginEnd="8dp" 40 android:contentDescription="@null" 41 android:adjustViewBounds="true" 42 android:tint="?android:attr/textColorPrimary" 43 android:maxHeight="@*android:dimen/status_bar_icon_size" 44 android:maxWidth="@*android:dimen/status_bar_icon_size" 45 android:scaleType="fitCenter" /> 46 47 <TextView 48 android:id="@+id/pkgname" 49 android:layout_width="wrap_content" 50 android:layout_height="wrap_content" 51 android:layout_centerVertical="true" 52 android:layout_toEndOf="@id/icon" 53 android:ellipsize="end" 54 android:singleLine="true" 55 android:textColor="?android:attr/textColorPrimary" 56 android:textAppearance="?android:attr/textAppearanceSmall" 57 android:textStyle="bold" 58 android:textAlignment="viewStart" /> 59 60 <ImageView 61 android:id="@+id/alerted_icon" 62 android:layout_width="@*android:dimen/status_bar_icon_size" 63 android:layout_height="@*android:dimen/status_bar_icon_size" 64 android:layout_centerVertical="true" 65 android:layout_marginStart="6dp" 66 android:paddingTop="1dp" 67 android:scaleType="fitCenter" 68 android:visibility="gone" 69 android:layout_toEndOf="@id/pkgname" 70 android:tint="?android:attr/textColorSecondary" 71 android:src="@drawable/ic_notifications_alert" 72 /> 73 74 <ImageView 75 android:id="@+id/profile_badge" 76 android:layout_width="@*android:dimen/status_bar_icon_size" 77 android:layout_height="@*android:dimen/status_bar_icon_size" 78 android:layout_centerVertical="true" 79 android:layout_marginEnd="6dp" 80 android:paddingTop="1dp" 81 android:scaleType="fitCenter" 82 android:visibility="gone" 83 android:layout_toStartOf="@id/timestamp" 84 /> 85 86 <DateTimeView 87 android:id="@+id/timestamp" 88 android:layout_width="wrap_content" 89 android:layout_height="wrap_content" 90 android:paddingTop="13dp" 91 android:paddingBottom="13dp" 92 android:layout_alignBottom="@android:id/widget_frame" 93 android:layout_alignParentEnd="true" 94 android:layout_alignTop="@android:id/widget_frame" 95 android:layout_centerVertical="true" 96 android:ellipsize="end" 97 android:singleLine="true" 98 android:textColor="?android:attr/textColorPrimary" 99 android:textAppearance="?android:attr/textAppearanceSmall" 100 android:textAlignment="viewEnd" 101 /> 102 </RelativeLayout> 103 104 <LinearLayout 105 android:layout_width="match_parent" 106 android:layout_height="wrap_content" 107 android:orientation="vertical" 108 android:layout_marginStart="30dp" 109 android:layout_marginBottom="6dp" 110 > 111 112 <TextView 113 android:id="@+id/title" 114 android:layout_width="match_parent" 115 android:layout_height="wrap_content" 116 android:layout_gravity="left|center_vertical" 117 android:ellipsize="end" 118 android:singleLine="true" 119 android:textColor="?android:attr/textColorPrimary" 120 android:textAlignment="viewStart" 121 /> 122 123 <TextView 124 android:id="@+id/text" 125 android:layout_width="match_parent" 126 android:layout_height="wrap_content" 127 android:layout_gravity="left|center_vertical" 128 android:ellipsize="end" 129 android:singleLine="true" 130 android:textColor="?android:attr/textColorPrimary" 131 android:textAppearance="?android:attr/textAppearanceSmall" 132 android:textAlignment="viewStart" 133 /> 134 135 </LinearLayout> 136 137 <LinearLayout 138 android:id="@+id/extra" 139 android:layout_width="match_parent" 140 android:layout_height="wrap_content" 141 android:orientation="vertical" 142 > 143 <TextView 144 android:id="@+id/notification_extra" 145 android:layout_width="match_parent" 146 android:layout_height="wrap_content" 147 android:orientation="horizontal" 148 android:layout_marginStart="30dp" 149 android:singleLine="false" 150 android:textColor="?android:attr/textColorPrimary" 151 android:textSize="10sp" 152 android:fontFamily="monospace" 153 android:textAlignment="viewStart" 154 /> 155 <TextView 156 android:id="@+id/ranking_extra" 157 android:layout_width="match_parent" 158 android:layout_height="wrap_content" 159 android:orientation="horizontal" 160 android:layout_marginStart="30dp" 161 android:layout_marginBottom="6dp" 162 android:singleLine="false" 163 android:textColor="?android:attr/textColorPrimary" 164 android:textSize="10sp" 165 android:fontFamily="monospace" 166 android:textAlignment="viewStart" 167 /> 168 </LinearLayout> 169 170</LinearLayout> 171