1<!--
2  ~ Copyright (C) 2021 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<!-- Have the wrapper frame layout match the parent height so that we get a larger touch area for
17     the chip. -->
18<FrameLayout
19    xmlns:android="http://schemas.android.com/apk/res/android"
20    android:id="@+id/ongoing_call_chip"
21    android:layout_width="wrap_content"
22    android:layout_height="match_parent"
23    android:layout_gravity="center_vertical|start"
24    android:layout_marginStart="5dp"
25>
26    <com.android.systemui.statusbar.phone.ongoingcall.OngoingCallBackgroundContainer
27        android:id="@+id/ongoing_call_chip_background"
28        android:layout_width="wrap_content"
29        android:layout_height="@dimen/ongoing_appops_chip_height"
30        android:layout_gravity="center_vertical"
31        android:gravity="center"
32        android:background="@drawable/ongoing_call_chip_bg"
33        android:paddingStart="@dimen/ongoing_call_chip_side_padding"
34        android:paddingEnd="@dimen/ongoing_call_chip_side_padding"
35        android:contentDescription="@string/ongoing_phone_call_content_description"
36        android:minWidth="@dimen/min_clickable_item_size"
37    >
38
39        <ImageView
40            android:src="@*android:drawable/ic_phone"
41            android:layout_width="@dimen/ongoing_call_chip_icon_size"
42            android:layout_height="@dimen/ongoing_call_chip_icon_size"
43            android:tint="?android:attr/colorPrimary"
44        />
45
46        <com.android.systemui.statusbar.phone.ongoingcall.OngoingCallChronometer
47            android:id="@+id/ongoing_call_chip_time"
48            android:layout_width="wrap_content"
49            android:layout_height="wrap_content"
50            android:singleLine="true"
51            android:gravity="center|start"
52            android:paddingStart="@dimen/ongoing_call_chip_icon_text_padding"
53            android:textAppearance="@android:style/TextAppearance.Material.Small"
54            android:fontFamily="@*android:string/config_headlineFontFamily"
55            android:textColor="?android:attr/colorPrimary"
56        />
57
58    </com.android.systemui.statusbar.phone.ongoingcall.OngoingCallBackgroundContainer>
59</FrameLayout>
60