1<?xml version="1.0" encoding="utf-8"?> 2<!-- Copyright (C) 2019 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<ScrollView 18 xmlns:android="http://schemas.android.com/apk/res/android" 19 xmlns:settings="http://schemas.android.com/apk/res-auto" 20 android:layout_width="match_parent" 21 android:layout_height="match_parent"> 22 23 <LinearLayout 24 android:layout_width="match_parent" 25 android:layout_height="wrap_content" 26 android:paddingStart="?android:attr/listPreferredItemPaddingStart" 27 android:paddingEnd="?android:attr/listPreferredItemPaddingEnd" 28 android:orientation="vertical"> 29 30 <LinearLayout 31 android:layout_width="match_parent" 32 android:layout_height="wrap_content" 33 android:focusable="true" 34 android:orientation="vertical"> 35 36 <TextView 37 android:id="@+id/charge" 38 android:layout_width="match_parent" 39 android:layout_height="wrap_content" 40 android:textAppearance="?android:attr/textAppearanceLarge" 41 android:textSize="36sp" 42 android:textColor="?android:attr/colorAccent"/> 43 44 <TextView 45 android:id="@+id/estimation" 46 android:layout_width="match_parent" 47 android:layout_height="wrap_content" 48 android:paddingBottom="8dp" 49 android:textAppearance="?android:attr/textAppearanceMedium" 50 android:textColor="?android:attr/textColorSecondary"/> 51 52 <com.android.car.developeroptions.widget.UsageView 53 android:id="@+id/battery_usage" 54 android:layout_width="match_parent" 55 android:layout_height="141dp" 56 settings:sideLabels="@array/battery_labels" 57 android:colorAccent="?android:attr/colorAccent" 58 android:gravity="end" 59 settings:textColor="?android:attr/textColorSecondary"/> 60 </LinearLayout> 61 62 <View 63 android:layout_width="match_parent" 64 android:layout_height="1dp" 65 android:layout_marginTop="2dp" 66 android:background="?android:attr/listDivider"/> 67 68 <LinearLayout 69 android:layout_width="match_parent" 70 android:layout_height="match_parent" 71 android:orientation="vertical"> 72 73 <include android:id="@+id/cell_network_group" 74 layout="@layout/battery_active_view" /> 75 76 <include android:id="@+id/camera_group" 77 layout="@layout/battery_active_view" /> 78 79 <include android:id="@+id/flashlight_group" 80 layout="@layout/battery_active_view" /> 81 82 <include android:id="@+id/gps_group" 83 layout="@layout/battery_active_view" /> 84 85 <include android:id="@+id/wifi_group" 86 layout="@layout/battery_active_view" /> 87 88 <include android:id="@+id/cpu_group" 89 layout="@layout/battery_active_view" /> 90 91 <include android:id="@+id/screen_on_group" 92 layout="@layout/battery_active_view" /> 93 94 <include android:id="@+id/charging_group" 95 layout="@layout/battery_active_view" /> 96 97 </LinearLayout> 98 99 </LinearLayout> 100 101</ScrollView> 102