Merge "Migrate to the new ro property for headless multiuser check." into qt-dev

am: 5d230c1462

Change-Id: Ieecb5a6f48643244cd10777d716fd45287310f26
This commit is contained in:
Ying Zheng
2019-04-15 18:05:00 -07:00
committed by android-build-merger

View File

@@ -18,11 +18,10 @@ package com.android.server;
import android.bluetooth.BluetoothAdapter; import android.bluetooth.BluetoothAdapter;
import android.content.Context; import android.content.Context;
import android.os.SystemProperties;
import com.android.internal.os.RoSystemProperties;
class BluetoothService extends SystemService { class BluetoothService extends SystemService {
private static final String HEADLESS_SYSTEM_USER = "android.car.systemuser.headless";
private BluetoothManagerService mBluetoothManagerService; private BluetoothManagerService mBluetoothManagerService;
private boolean mInitialized = false; private boolean mInitialized = false;
@@ -48,7 +47,7 @@ class BluetoothService extends SystemService {
publishBinderService(BluetoothAdapter.BLUETOOTH_MANAGER_SERVICE, publishBinderService(BluetoothAdapter.BLUETOOTH_MANAGER_SERVICE,
mBluetoothManagerService); mBluetoothManagerService);
} else if (phase == SystemService.PHASE_ACTIVITY_MANAGER_READY && } else if (phase == SystemService.PHASE_ACTIVITY_MANAGER_READY &&
!SystemProperties.getBoolean(HEADLESS_SYSTEM_USER, false)) { !RoSystemProperties.MULTIUSER_HEADLESS_SYSTEM_USER) {
initialize(); initialize();
} }
} }