1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (C) 2007 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:id="@+id/call_log_list_item"
19    android:layout_width="match_parent"
20    android:layout_height="wrap_content"
21    android:orientation="vertical">
22
23    <!-- Day group heading. Used to show a "today", "yesterday", "last week" or "other" heading
24         above a group of call log entries. -->
25    <TextView
26        android:id="@+id/call_log_day_group_label"
27        android:layout_width="wrap_content"
28        android:layout_height="wrap_content"
29        android:layout_gravity="start"
30        android:layout_marginStart="@dimen/call_log_start_margin"
31        android:layout_marginEnd="@dimen/call_log_outer_margin"
32        android:fontFamily="sans-serif-medium"
33        android:textColor="?attr/call_log_secondary_text_color"
34        android:textSize="@dimen/call_log_secondary_text_size"
35        android:paddingTop="@dimen/call_log_day_group_padding_top"
36        android:paddingBottom="@dimen/call_log_day_group_padding_bottom" />
37
38    <!-- Linear layout to separate the primary area containing the contact badge and caller
39         information and the secondary action (call details / play voicemail). -->
40    <LinearLayout
41        android:id="@+id/call_log_row"
42        android:layout_width="match_parent"
43        android:layout_height="wrap_content"
44        android:baselineAligned="false"
45        android:orientation="vertical"
46        android:gravity="center_vertical" >
47
48        <!-- Primary area containing the contact badge and caller information -->
49        <LinearLayout
50            android:id="@+id/primary_action_view"
51            android:background="@drawable/call_log_background"
52            android:layout_width="match_parent"
53            android:layout_height="wrap_content"
54            android:paddingStart="@dimen/call_log_start_margin"
55            android:paddingEnd="@dimen/call_log_outer_margin"
56            android:paddingTop="@dimen/call_log_outer_margin"
57            android:paddingBottom="@dimen/call_log_outer_margin"
58            android:orientation="horizontal"
59            android:gravity="center_vertical"
60            android:focusable="true"
61            android:nextFocusRight="@+id/call_back_action"
62            android:nextFocusLeft="@+id/quick_contact_photo" >
63            <QuickContactBadge
64                android:id="@+id/quick_contact_photo"
65                android:layout_width="@dimen/contact_photo_size"
66                android:layout_height="@dimen/contact_photo_size"
67                android:paddingTop="2dp"
68                android:nextFocusRight="@id/primary_action_view"
69                android:layout_gravity="top"
70                android:focusable="true"
71                />
72            <LinearLayout
73                android:layout_width="0dp"
74                android:layout_height="wrap_content"
75                android:layout_weight="1"
76                android:orientation="vertical"
77                android:gravity="center_vertical"
78                android:layout_marginStart="@dimen/call_log_start_margin"
79                >
80                <TextView
81                    android:id="@+id/name"
82                    android:layout_width="wrap_content"
83                    android:layout_height="wrap_content"
84                    android:layout_marginBottom="@dimen/call_log_name_margin_bottom"
85                    android:layout_marginEnd="@dimen/call_log_icon_margin"
86                    android:textColor="?attr/call_log_primary_text_color"
87                    android:textSize="@dimen/call_log_primary_text_size"
88                    android:singleLine="true"
89                    />
90                <TextView
91                    android:id="@+id/voicemail_transcription"
92                    android:layout_width="wrap_content"
93                    android:layout_height="wrap_content"
94                    android:layout_marginEnd="@dimen/call_log_icon_margin"
95                    android:textColor="?attr/call_log_secondary_text_color"
96                    android:textSize="@dimen/call_log_secondary_text_size"
97                    android:singleLine="true"
98                    android:ellipsize="marquee"
99                    android:visibility="gone"
100                    />
101                <LinearLayout
102                    android:id="@+id/call_type"
103                    android:layout_width="wrap_content"
104                    android:layout_height="wrap_content"
105                    android:orientation="horizontal"
106                    >
107                    <view
108                        class="com.android.dialer.calllog.CallTypeIconsView"
109                        android:id="@+id/call_type_icons"
110                        android:layout_width="wrap_content"
111                        android:layout_height="wrap_content"
112                        android:layout_marginEnd="@dimen/call_log_icon_margin"
113                        android:layout_gravity="center_vertical"
114                        />
115                    <TextView
116                        android:id="@+id/call_location_and_date"
117                        android:layout_width="wrap_content"
118                        android:layout_height="wrap_content"
119                        android:layout_marginEnd="@dimen/call_log_icon_margin"
120                        android:layout_gravity="center_vertical"
121                        android:textColor="?attr/call_log_secondary_text_color"
122                        android:textSize="@dimen/call_log_secondary_text_size"
123                        android:singleLine="true"
124                        />
125                </LinearLayout>
126                <TextView
127                    android:id="@+id/call_account_label"
128                    android:layout_width="wrap_content"
129                    android:layout_height="wrap_content"
130                    android:layout_marginEnd="@dimen/call_log_icon_margin"
131                    android:textColor="?attr/call_log_secondary_text_color"
132                    android:textSize="@dimen/call_log_secondary_text_size"
133                    android:visibility="gone"
134                    android:singleLine="true"
135                    />
136            </LinearLayout>
137            <ImageView
138                android:id="@+id/call_indicator_icon"
139                android:layout_width="wrap_content"
140                android:layout_height="wrap_content"
141                android:layout_gravity="center_vertical"
142                android:layout_marginEnd="@dimen/call_log_icon_margin"
143                android:src="@drawable/ic_card_phone"
144                android:tint="@color/recent_call_log_item_phone_icon_tint"
145                android:alpha="0.3"
146                android:importantForAccessibility="no"
147                android:visibility="gone"
148                />
149        </LinearLayout>
150
151        <!-- Viewstub with additional expandable actions for a call log entry -->
152        <ViewStub android:id="@+id/call_log_entry_actions_stub"
153                  android:inflatedId="@+id/call_log_entry_actions"
154                  android:layout="@layout/call_log_list_item_actions"
155                  android:layout_width="match_parent"
156                  android:layout_height="wrap_content"/>
157    </LinearLayout>
158    <!-- Displays the extra link section -->
159    <ViewStub android:id="@+id/link_stub"
160              android:layout="@layout/call_log_list_item_extra"
161              android:layout_width="match_parent"
162              android:layout_height="wrap_content"/>
163</LinearLayout>
164