Merge "Require listener to be set for CarTelemetryManager APIs" into sc-v2-dev
diff --git a/car_product/car_ui_portrait/apps/CarUiPortraitSystemUI/res/layout/car_bottom_system_bar.xml b/car_product/car_ui_portrait/apps/CarUiPortraitSystemUI/res/layout/car_bottom_system_bar.xml
index 69c3d30..b5dcecb 100644
--- a/car_product/car_ui_portrait/apps/CarUiPortraitSystemUI/res/layout/car_bottom_system_bar.xml
+++ b/car_product/car_ui_portrait/apps/CarUiPortraitSystemUI/res/layout/car_bottom_system_bar.xml
@@ -48,7 +48,7 @@
android:gravity="center"
android:layoutDirection="ltr">
- <com.android.systemui.car.systembar.CarSystemBarButton
+ <com.android.systemui.car.systembar.DisplayAreaButton
android:id="@+id/grid_nav"
style="@style/SystemBarButton"
systemui:componentNames="com.android.car.carlauncher/.AppGridActivity"
@@ -58,7 +58,7 @@
systemui:intent="intent:#Intent;component=com.android.car.carlauncher/.AppGridActivity;launchFlags=0x24000000;end"
systemui:clearBackStack="true"/>
- <com.android.systemui.car.systembar.CarSystemBarButton
+ <com.android.systemui.car.systembar.DisplayAreaButton
android:id="@+id/standalone_notifications"
style="@style/SystemBarButton"
systemui:componentNames="com.android.car.notification/.CarNotificationCenterActivity"
@@ -69,7 +69,7 @@
systemui:intent="intent:#Intent;component=com.android.car.notification/.CarNotificationCenterActivity;launchFlags=0x24000000;end"
systemui:longIntent="intent:#Intent;component=com.android.car.bugreport/.BugReportActivity;end"/>
- <com.android.systemui.car.systembar.CarSystemBarButton
+ <com.android.systemui.car.systembar.HvacButton
android:id="@+id/hvac"
style="@style/SystemBarButton"
systemui:icon="@drawable/car_ic_hvac"
diff --git a/car_product/car_ui_portrait/apps/CarUiPortraitSystemUI/res/layout/car_top_system_bar.xml b/car_product/car_ui_portrait/apps/CarUiPortraitSystemUI/res/layout/car_top_system_bar.xml
index e30ec45..83b759b 100644
--- a/car_product/car_ui_portrait/apps/CarUiPortraitSystemUI/res/layout/car_top_system_bar.xml
+++ b/car_product/car_ui_portrait/apps/CarUiPortraitSystemUI/res/layout/car_top_system_bar.xml
@@ -64,22 +64,35 @@
android:textAppearance="@style/TextAppearance.SystemBar.Clock"
systemui:amPmStyle="normal"/>
- <com.android.systemui.car.systembar.CarSystemBarButton
- android:id="@+id/system_icon_area"
+ <LinearLayout
android:layout_width="wrap_content"
android:layout_height="match_parent"
- android:layout_marginEnd="@dimen/car_padding_3"
android:layout_gravity="end"
- android:gravity="end"
- systemui:intent="intent:#Intent;component=com.android.car.settings/.common.CarSettingActivities$HomepageActivity;launchFlags=0x24000000;end">
+ android:orientation="horizontal"
+ android:gravity="end">
- <com.android.systemui.statusbar.phone.StatusIconContainer
- android:id="@+id/statusIcons"
- android:layout_width="match_parent"
+ <include layout="@layout/mic_privacy_chip"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:layout_gravity="center_vertical"/>
+
+ <com.android.systemui.car.systembar.CarSystemBarButton
+ android:id="@+id/system_icon_area"
+ android:layout_width="wrap_content"
android:layout_height="match_parent"
- android:scaleType="fitCenter"
- android:gravity="center"
- android:orientation="horizontal"
- />
- </com.android.systemui.car.systembar.CarSystemBarButton>
-</com.android.systemui.car.systembar.CarSystemBarView>
\ No newline at end of file
+ android:layout_marginEnd="@dimen/car_padding_3"
+ android:layout_gravity="end"
+ android:gravity="end"
+ systemui:intent="intent:#Intent;component=com.android.car.settings/.common.CarSettingActivities$HomepageActivity;launchFlags=0x24000000;end">
+
+ <com.android.systemui.statusbar.phone.StatusIconContainer
+ android:id="@+id/statusIcons"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:scaleType="fitCenter"
+ android:gravity="center"
+ android:orientation="horizontal"/>
+
+ </com.android.systemui.car.systembar.CarSystemBarButton>
+ </LinearLayout>
+</com.android.systemui.car.systembar.CarSystemBarView>
diff --git a/car_product/car_ui_portrait/apps/CarUiPortraitSystemUI/src/com/android/systemui/car/systembar/DisplayAreaButton.java b/car_product/car_ui_portrait/apps/CarUiPortraitSystemUI/src/com/android/systemui/car/systembar/DisplayAreaButton.java
new file mode 100644
index 0000000..1412903
--- /dev/null
+++ b/car_product/car_ui_portrait/apps/CarUiPortraitSystemUI/src/com/android/systemui/car/systembar/DisplayAreaButton.java
@@ -0,0 +1,56 @@
+/*
+ * Copyright (C) 2021 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.systemui.car.systembar;
+
+import android.content.BroadcastReceiver;
+import android.content.Context;
+import android.content.Intent;
+import android.content.IntentFilter;
+import android.util.AttributeSet;
+
+/** A CarSystemBarButton that controls a display area. */
+public class DisplayAreaButton extends CarSystemBarButton {
+
+ // TODO(b/194334719): Remove when display area logic is moved into systemui
+ private static final String DISPLAY_AREA_VISIBILITY_CHANGED =
+ "com.android.car.carlauncher.displayarea.DISPLAY_AREA_VISIBILITY_CHANGED";
+ private static final String INTENT_EXTRA_IS_DISPLAY_AREA_VISIBLE =
+ "EXTRA_IS_DISPLAY_AREA_VISIBLE";
+
+ /**
+ * A broadcast receiver to listen when the display area is closed via swipe.
+ * When the display area logic is moved from launcher into system ui, the DisplayAreaButton
+ * should be notified of changes in the panel's visibility directly, rather than using a
+ * broadcast.
+ */
+ private final BroadcastReceiver mBroadcastReceiver = new BroadcastReceiver() {
+ @Override
+ public void onReceive(Context context, Intent intent) {
+ boolean isDisplayAreaVisible = intent.getBooleanExtra(
+ INTENT_EXTRA_IS_DISPLAY_AREA_VISIBLE, /* defaultValue= */ true);
+ if (getSelected() && !isDisplayAreaVisible) {
+ context.getMainExecutor().execute(() -> setSelected(/* selected= */ false));
+ }
+ }
+ };
+
+ public DisplayAreaButton(Context context, AttributeSet attrs) {
+ super(context, attrs);
+ context.registerReceiver(mBroadcastReceiver,
+ new IntentFilter(DISPLAY_AREA_VISIBILITY_CHANGED));
+ }
+}
diff --git a/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/layout/incall_dialpad_fragment.xml b/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/layout/incall_dialpad_fragment.xml
new file mode 100644
index 0000000..e7b31ed
--- /dev/null
+++ b/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/layout/incall_dialpad_fragment.xml
@@ -0,0 +1,56 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2021 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<RelativeLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
+
+ <TextView
+ android:id="@+id/title"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:focusable="true"
+ android:singleLine="true"
+ android:layout_centerHorizontal="true"
+ android:layout_alignParentTop="true"/>
+
+ <Chronometer
+ android:id="@+id/call_state"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:focusable="true"
+ android:singleLine="true"
+ android:layout_marginTop="40dp"
+ android:layout_centerHorizontal="true"
+ android:layout_below="@id/title"/>
+
+ <com.android.car.ui.FocusArea
+ android:id="@+id/dialpad_focus_area"
+ android:layout_height="456dp"
+ android:layout_width="416dp"
+ android:layout_marginBottom="171dp"
+ android:layout_centerHorizontal="true"
+ android:layout_alignParentBottom="true">
+
+ <fragment
+ android:id="@+id/dialpad_fragment"
+ android:name="com.android.car.dialer.ui.dialpad.KeypadFragment"
+ android:layout_height="wrap_content"
+ android:layout_width="wrap_content"/>
+
+ </com.android.car.ui.FocusArea>
+</RelativeLayout>
\ No newline at end of file
diff --git a/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/layout/ongoing_call_fragment.xml b/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/layout/ongoing_call_fragment.xml
new file mode 100644
index 0000000..0e76d6b
--- /dev/null
+++ b/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/layout/ongoing_call_fragment.xml
@@ -0,0 +1,55 @@
+<!--
+ ~ Copyright (C) 2021 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<LinearLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
+
+ <com.android.car.apps.common.BackgroundImageView
+ android:id="@+id/background_image"
+ android:layout_width="0dp"
+ android:layout_height="0dp"/>
+
+ <RelativeLayout
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:background="@android:color/transparent">
+
+ <fragment
+ android:name="com.android.car.dialer.ui.dialpad.InCallDialpadFragment"
+ android:id="@+id/incall_dialpad_fragment"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"/>
+
+ <LinearLayout
+ android:layout_width="0dp"
+ android:layout_height="0dp">
+
+ <include
+ layout="@layout/user_profile_large"
+ android:id="@+id/user_profile_container"/>
+
+ </LinearLayout>
+
+ <fragment
+ android:id="@+id/onhold_user_profile"
+ android:name="com.android.car.dialer.ui.activecall.OnHoldCallUserProfileFragment"
+ android:layout_width="match_parent"
+ android:layout_height="0dp"/>
+
+ </RelativeLayout>
+
+</LinearLayout>
diff --git a/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/layout/user_profile_large.xml b/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/layout/user_profile_large.xml
new file mode 100644
index 0000000..f59ee9e
--- /dev/null
+++ b/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/layout/user_profile_large.xml
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2021 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<LinearLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:gravity="start|center_vertical"
+ android:orientation="horizontal">
+ <ImageView
+ android:id="@+id/user_profile_avatar"
+ android:layout_width="196dp"
+ android:layout_height="196dp"
+ android:scaleType="fitCenter"/>
+
+ <LinearLayout
+ android:layout_height="wrap_content"
+ android:layout_width="fill_parent"
+ android:orientation="vertical">
+ <TextView
+ android:id="@+id/user_profile_title"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:singleLine="true"/>
+ <TextView
+ android:id="@+id/user_profile_phone_number"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:singleLine="true"/>
+
+ <!-- A textView without a fixed width will call requestLayout() every time its text is changed -->
+ <!-- So we have to make this Chronometer match_parent to avoid redrawing the whole screen -->
+ <Chronometer
+ android:id="@+id/user_profile_call_state"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:singleLine="true"/>
+ </LinearLayout>
+</LinearLayout>
\ No newline at end of file
diff --git a/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/values/configs.xml b/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/values/configs.xml
index 2f28c76..39e81f6 100644
--- a/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/values/configs.xml
+++ b/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/values/configs.xml
@@ -17,4 +17,6 @@
<resources>
<integer name="config_dialed_number_gravity">1</integer>
+
+ <bool name="config_always_show_incall_dialpad">true</bool>
</resources>
\ No newline at end of file
diff --git a/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/xml/overlays.xml b/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/xml/overlays.xml
index 848c5eb..2064bc4 100644
--- a/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/xml/overlays.xml
+++ b/car_product/car_ui_portrait/rro/CarUiPortraitDialerRRO/res/xml/overlays.xml
@@ -42,10 +42,22 @@
<item target="id/error_icon" value="@id/error_icon" />
<item target="id/error_string" value="@id/error_string" />
<item target="id/connect_bluetooth_button" value="@id/connect_bluetooth_button" />
+ <item target="id/background_image" value="@id/background_image" />
+ <item target="id/incall_dialpad_fragment" value="@id/incall_dialpad_fragment" />
+ <item target="id/user_profile_container" value="@id/user_profile_container" />
+ <item target="id/onhold_user_profile" value="@id/onhold_user_profile" />
+ <item target="id/user_profile_avatar" value="@id/user_profile_avatar" />
+ <item target="id/user_profile_title" value="@id/user_profile_title" />
+ <item target="id/user_profile_phone_number" value="@id/user_profile_phone_number" />
+ <item target="id/user_profile_call_state" value="@id/user_profile_call_state" />
+ <item target="id/call_state" value="@id/call_state" />
+ <item target="id/dialpad_focus_area" value="@id/dialpad_focus_area" />
<item target="color/divider_color" value="@color/divider_color" />
<item target="color/hero_button_background_color" value="@color/hero_button_background_color" />
+ <item target="bool/config_always_show_incall_dialpad" value="@bool/config_always_show_incall_dialpad" />
+
<item target="integer/config_dialed_number_gravity" value="@integer/config_dialed_number_gravity" />
<item target="layout/dialpad_fragment_with_type_down" value="@layout/dialpad_fragment_with_type_down"/>
@@ -53,6 +65,9 @@
<item target="layout/type_down_list_item" value="@layout/type_down_list_item"/>
<item target="layout/restricted_dialing_mode_label" value="@layout/restricted_dialing_mode_label"/>
<item target="layout/no_hfp" value="@layout/no_hfp"/>
+ <item target="layout/ongoing_call_fragment" value="@layout/ongoing_call_fragment"/>
+ <item target="layout/user_profile_large" value="@layout/user_profile_large"/>
+ <item target="layout/incall_dialpad_fragment" value="@layout/incall_dialpad_fragment"/>
<item target="style/KeypadButtonStyle" value="@style/KeypadButtonStyle"/>
<item target="style/TextAppearance.DialNumber" value="@style/TextAppearance.DialNumber"/>
diff --git a/car_product/car_ui_portrait/rro/CarUiPortraitLauncherRRO/res/values/config.xml b/car_product/car_ui_portrait/rro/CarUiPortraitLauncherRRO/res/values/config.xml
index 059f7b1..d049e9b 100644
--- a/car_product/car_ui_portrait/rro/CarUiPortraitLauncherRRO/res/values/config.xml
+++ b/car_product/car_ui_portrait/rro/CarUiPortraitLauncherRRO/res/values/config.xml
@@ -33,5 +33,8 @@
<item>com.google.android.gms/.auth.uiflows.common.UnpackingRedirectActivity</item>
<item>com.google.android.gms/.auth.auto.SignInMethodActivity</item>
<item>com.google.android.gms/.auth.uiflows.minutemaid.MinuteMaidActivity</item>
+ <item>android.car.cluster/android.car.cluster.FakeFreeNavigationActivity</item>
+ <item>android.car.cluster/android.car.cluster.MainClusterActivity</item>
+ <item>android.car.usb.handler/android.car.usb.handler.UsbHostManagementActivity</item>
</string-array>
</resources>
diff --git a/car_product/car_ui_portrait/rro/CarUiPortraitNotificationRRO/res/layout/headsup_container_bottom.xml b/car_product/car_ui_portrait/rro/CarUiPortraitNotificationRRO/res/layout/headsup_container_bottom.xml
index 3cff34a..66f7085 100644
--- a/car_product/car_ui_portrait/rro/CarUiPortraitNotificationRRO/res/layout/headsup_container_bottom.xml
+++ b/car_product/car_ui_portrait/rro/CarUiPortraitNotificationRRO/res/layout/headsup_container_bottom.xml
@@ -15,17 +15,16 @@
~ limitations under the License.
-->
-<RelativeLayout
+<FrameLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/notification_headsup"
android:layout_width="match_parent"
- android:layout_height="match_parent">
+ android:layout_height="wrap_content">
<com.android.car.notification.headsup.HeadsUpContainerView
android:id="@+id/headsup_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_alignParentBottom="true"
android:layout_marginBottom="@dimen/headsup_notification_bottom_margin"/>
-</RelativeLayout>
\ No newline at end of file
+</FrameLayout>
\ No newline at end of file
diff --git a/car_product/car_ui_portrait/rro/android/res/color/overview_background.xml b/car_product/car_ui_portrait/rro/android/res/color/overview_background.xml
new file mode 100644
index 0000000..1e98723
--- /dev/null
+++ b/car_product/car_ui_portrait/rro/android/res/color/overview_background.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2021 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/transparent" />
+</selector>
\ No newline at end of file
diff --git a/car_product/car_ui_portrait/rro/android/res/color/overview_background_dark.xml b/car_product/car_ui_portrait/rro/android/res/color/overview_background_dark.xml
new file mode 100644
index 0000000..1e98723
--- /dev/null
+++ b/car_product/car_ui_portrait/rro/android/res/color/overview_background_dark.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2021 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+ <item android:color="@android:color/transparent" />
+</selector>
\ No newline at end of file
diff --git a/cpp/watchdog/server/Android.bp b/cpp/watchdog/server/Android.bp
index c8d07b4..5aeebb2 100644
--- a/cpp/watchdog/server/Android.bp
+++ b/cpp/watchdog/server/Android.bp
@@ -30,16 +30,15 @@
"system/libbase/include",
],
shared_libs: [
- "android.automotive.watchdog-V3-cpp",
- "android.automotive.watchdog.internal-cpp",
- "android.automotive.watchdog.internal-cpp",
- "android.automotive.watchdog-V3-cpp",
- "android.hardware.automotive.vehicle@2.0",
"libbase",
"libbinder",
"liblog",
"libutils",
],
+ static_libs: [
+ "android.automotive.watchdog.internal-cpp",
+ "android.automotive.watchdog-V3-cpp",
+ ],
header_libs: [
"libgtest_prod_headers",
],
@@ -54,6 +53,7 @@
"carwatchdogd_defaults",
],
shared_libs: [
+ "android.hardware.automotive.vehicle@2.0",
"libcutils",
],
export_include_dirs: [
@@ -67,7 +67,6 @@
"libcutils",
"libprocessgroup",
"libtinyxml2",
- "libwatchdog_package_info_resolver",
],
}
@@ -90,8 +89,12 @@
"src/UidProcStatsCollector.cpp",
"src/UidStatsCollector.cpp",
],
+ shared_libs: [
+ "android.hardware.automotive.vehicle@2.0",
+ ],
whole_static_libs: [
"libwatchdog_properties",
+ "libwatchdog_package_info_resolver",
],
export_include_dirs: [
"src",
@@ -140,7 +143,10 @@
"libwatchdog_binder_mediator",
"libwatchdog_perf_service",
"libwatchdog_process_service",
+ ],
+ whole_static_libs: [
"libwatchdog_package_info_resolver",
+ "android.hardware.automotive.vehicle@2.0",
],
data: [":watchdog_test_xml_files"],
}
@@ -161,6 +167,9 @@
"carwatchdogd_defaults",
"libwatchdog_process_service_defaults"
],
+ shared_libs: [
+ "android.hardware.automotive.vehicle@2.0",
+ ],
}
cc_library {
@@ -176,6 +185,9 @@
"src/WatchdogServiceHelper.cpp",
],
shared_libs: [
+ "android.hardware.automotive.vehicle@2.0",
+ ],
+ static_libs: [
"libwatchdog_perf_service",
"libwatchdog_process_service",
],
@@ -197,10 +209,15 @@
],
init_rc: ["carwatchdogd.rc"],
shared_libs: [
- "libwatchdog_binder_mediator",
- "libwatchdog_perf_service",
- "libwatchdog_process_service",
- "libwatchdog_package_info_resolver",
+ "android.hardware.automotive.vehicle@2.0",
+ ],
+ static_libs: [
+ "libwatchdog_binder_mediator",
+ "libwatchdog_perf_service",
+ "libwatchdog_process_service",
+ ],
+ whole_static_libs: [
+ "libwatchdog_package_info_resolver",
],
vintf_fragments: ["carwatchdogd.xml"],
required: [
diff --git a/packages/CarDeveloperOptions/res/values/themes.xml b/packages/CarDeveloperOptions/res/values/themes.xml
index 691afd3..73bf8d8 100644
--- a/packages/CarDeveloperOptions/res/values/themes.xml
+++ b/packages/CarDeveloperOptions/res/values/themes.xml
@@ -47,6 +47,16 @@
<style name="Theme.CarDeveloperOptions" parent="@style/Theme.CarUi.WithToolbar">
<item name="alertDialogTheme">@style/Theme.AlertDialog</item>
<item name="switchBarTheme">@style/ThemeOverlay.SwitchBar.Settings</item>
+ <item name="preferenceTheme">@style/CarDeveloperOptionsPreferenceTheme</item>
+ </style>
+
+ <style name="CarDeveloperOptionsPreferenceTheme" parent="@style/CarUiPreferenceTheme">
+ <item name="preferenceFragmentCompatStyle">@style/CarDeveloperOptionsPreferenceFragment</item>
+ <item name="preferenceFragmentStyle">@style/CarDeveloperOptionsPreferenceFragment</item>
+ </style>
+
+ <style name="CarDeveloperOptionsPreferenceFragment" parent="@style/PreferenceFragment.CarUi">
+ <item name="android:layout">@layout/preference_list_fragment</item>
</style>
</resources>
\ No newline at end of file
diff --git a/packages/CarDeveloperOptions/src/com/android/car/developeroptions/CarDevelopmentSettingsDashboardFragment.java b/packages/CarDeveloperOptions/src/com/android/car/developeroptions/CarDevelopmentSettingsDashboardFragment.java
index ef007b4..d74b8ea 100644
--- a/packages/CarDeveloperOptions/src/com/android/car/developeroptions/CarDevelopmentSettingsDashboardFragment.java
+++ b/packages/CarDeveloperOptions/src/com/android/car/developeroptions/CarDevelopmentSettingsDashboardFragment.java
@@ -23,16 +23,12 @@
import android.content.Context;
import android.content.pm.PackageManager;
import android.os.Bundle;
-import android.view.LayoutInflater;
-import android.view.ViewGroup;
import androidx.annotation.XmlRes;
import androidx.preference.Preference;
import androidx.preference.PreferenceCategory;
import androidx.preference.SwitchPreference;
-import androidx.recyclerview.widget.RecyclerView;
-import com.android.car.ui.recyclerview.CarUiRecyclerView;
import com.android.car.ui.toolbar.MenuItem;
import com.android.car.ui.toolbar.Toolbar;
import com.android.car.ui.toolbar.ToolbarController;
@@ -127,20 +123,6 @@
}
}
- @Override
- public RecyclerView onCreateRecyclerView(LayoutInflater inflater, ViewGroup parent,
- Bundle savedInstanceState) {
- Object carUiRecyclerView = parent.findViewById(R.id.recycler_view);
- RecyclerView recyclerView = (carUiRecyclerView instanceof CarUiRecyclerView)
- ? ((CarUiRecyclerView) carUiRecyclerView).getRecyclerView()
- : (RecyclerView) carUiRecyclerView;
- if (recyclerView != null) {
- return recyclerView;
- } else {
- return super.onCreateRecyclerView(inflater, parent, savedInstanceState);
- }
- }
-
protected ToolbarController getToolbar() {
return requireToolbar(requireActivity());
}
diff --git a/service/AndroidManifest.xml b/service/AndroidManifest.xml
index 9cf986d..ffe96c4 100644
--- a/service/AndroidManifest.xml
+++ b/service/AndroidManifest.xml
@@ -902,7 +902,6 @@
<uses-permission android:name="android.permission.CALL_PHONE"/>
<uses-permission android:name="android.permission.DEVICE_POWER"/>
- <uses-permission android:name="android.permission.GRANT_RUNTIME_PERMISSIONS"/>
<uses-permission android:name="android.permission.INTERACT_ACROSS_USERS_FULL"/>
<uses-permission android:name="android.permission.MANAGE_ACTIVITY_STACKS"/>
<uses-permission android:name="android.permission.MODIFY_AUDIO_ROUTING"/>