1 <?xml version="1.0" encoding="utf-8"?> 2 3 <!-- 4 ~ Copyright (C) 2013 The Android Open Source Project 5 ~ 6 ~ Licensed under the Apache License, Version 2.0 (the "License"); 7 ~ you may not use this file except in compliance with the License. 8 ~ You may obtain a copy of the License at 9 ~ 10 ~ http://www.apache.org/licenses/LICENSE-2.0 11 ~ 12 ~ Unless required by applicable law or agreed to in writing, software 13 ~ distributed under the License is distributed on an "AS IS" BASIS, 14 ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 ~ See the License for the specific language governing permissions and 16 ~ limitations under the License 17 --> 18 19 <!-- "Call Banner" for primary call, the foregound or ringing call. The "call banner" is a block 20 of info about a single call, including the contact name, phone number, call time counter, and 21 other status info. This info is shown as a "banner" overlaid across the top of contact photo. 22 --> 23 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 24 android:id="@+id/primary_call_banner" 25 android:layout_width="match_parent" 26 android:layout_height="wrap_content" 27 android:orientation="vertical" 28 android:minHeight="@dimen/call_banner_height" 29 android:paddingStart="@dimen/call_banner_side_padding" 30 android:paddingEnd="@dimen/call_banner_side_padding" 31 android:clipChildren="false" 32 android:clipToPadding="false" 33 android:animateLayoutChanges="true" 34 android:gravity="center"> 35 36 <LinearLayout android:id="@+id/callStateButton" 37 android:layout_width="match_parent" 38 android:layout_height="wrap_content" 39 android:orientation="horizontal" 40 android:clipChildren="false" 41 android:clipToPadding="false"> 42 43 <!-- Subscription provider or WiFi calling icon displayed to the left of the label --> 44 <ImageView android:id="@+id/callStateIcon" 45 android:layout_width="16dp" 46 android:layout_height="16dp" 47 android:layout_marginEnd="4dp" 48 android:baselineAlignBottom="true" 49 android:tint="@color/incall_accent_color" 50 android:alpha="0.0" 51 android:scaleType="centerInside" 52 android:visibility="gone" /> 53 54 <ImageView android:id="@+id/videoCallIcon" 55 android:src="@drawable/ic_toolbar_video" 56 android:layout_width="16dp" 57 android:layout_height="16dp" 58 android:layout_marginEnd="4dp" 59 android:baselineAlignBottom="true" 60 android:tint="@color/incall_accent_color" 61 android:scaleType="centerInside" 62 android:visibility="gone" /> 63 64 <TextView android:id="@+id/callStateLabel" 65 android:layout_width="match_parent" 66 android:layout_height="wrap_content" 67 android:textAppearance="?android:attr/textAppearanceLarge" 68 android:textColor="@color/incall_accent_color" 69 android:textSize="@dimen/call_status_text_size" 70 android:alpha="0.7" 71 android:singleLine="true" 72 android:gravity="start" 73 android:ellipsize="end" /> 74 </LinearLayout> 75 76 <!-- Name (or the phone number, if we don't have a name to display). --> 77 <com.android.phone.common.widget.ResizingTextTextView android:id="@+id/name" 78 xmlns:ex="http://schemas.android.com/apk/res-auto" 79 android:layout_width="match_parent" 80 android:layout_height="wrap_content" 81 android:layout_marginTop="-5dp" 82 android:fontFamily="sans-serif-light" 83 android:textAppearance="?android:attr/textAppearanceLarge" 84 android:textSize="@dimen/call_name_text_size" 85 android:singleLine="true" 86 ex:resizing_text_min_size="@dimen/call_name_text_min_size" /> 87 88 89 <LinearLayout 90 android:layout_width="match_parent" 91 android:layout_height="wrap_content" 92 android:orientation="horizontal" 93 android:clipChildren="false" 94 android:clipToPadding="false"> 95 96 <!-- Label (like "Mobile" or "Work", if present) and phone number, side by side --> 97 <LinearLayout android:id="@+id/labelAndNumber" 98 android:layout_width="0dp" 99 android:layout_height="wrap_content" 100 android:layout_weight="1" 101 android:orientation="horizontal"> 102 103 <TextView android:id="@+id/label" 104 android:layout_width="wrap_content" 105 android:layout_height="wrap_content" 106 android:textAppearance="?android:attr/textAppearanceSmall" 107 android:textColor="@color/incall_call_banner_subtext_color" 108 android:textSize="@dimen/call_label_text_size" 109 android:singleLine="true" 110 android:textDirection="ltr" /> 111 112 <TextView android:id="@+id/phoneNumber" 113 android:layout_width="match_parent" 114 android:layout_height="wrap_content" 115 android:layout_marginStart="6dp" 116 android:textAppearance="?android:attr/textAppearanceSmall" 117 android:textColor="@color/incall_call_banner_subtext_color" 118 android:textSize="@dimen/call_label_text_size" 119 android:singleLine="true" /> 120 121 </LinearLayout> 122 123 <!-- Elapsed time indication for a call in progress. --> 124 <TextView android:id="@+id/elapsedTime" 125 android:layout_width="wrap_content" 126 android:layout_height="wrap_content" 127 android:layout_centerVertical="true" 128 android:textAppearance="?android:attr/textAppearanceSmall" 129 android:textColor="@color/incall_call_banner_subtext_color" 130 android:textSize="@dimen/call_label_text_size" 131 android:singleLine="true" 132 android:visibility="gone" /> 133 134 </LinearLayout> 135 136 <!-- Call type indication: a special label and/or branding 137 for certain kinds of calls (like "SIP call" for a SIP call.) --> 138 <TextView android:id="@+id/callTypeLabel" 139 android:layout_width="wrap_content" 140 android:layout_height="wrap_content" 141 android:textAppearance="?android:attr/textAppearanceSmall" 142 android:textColor="@color/incall_call_banner_text_color" 143 android:maxLines="1" 144 android:ellipsize="end" /> 145 146 </LinearLayout> <!-- End of call_banner --> 147