Loading packages/SystemUI/tests/utils/src/com/android/systemui/statusbar/policy/FakeDeviceProvisionedController.kt +10 −2 Original line number Diff line number Diff line Loading @@ -39,8 +39,16 @@ class FakeDeviceProvisionedController : DeviceProvisionedController { callbacks.toSet().forEach { it.onUserSwitched() } } fun setUserSetup(userId: Int) { fun setUserSetup(userId: Int, isSetup: Boolean = true) { if (isSetup) { usersSetup.add(userId) } else { usersSetup.remove(userId) } callbacks.toSet().forEach { it.onUserSetupChanged() } } fun setCurrentUserSetup(isSetup: Boolean) { setUserSetup(currentUser, isSetup) } } Loading
packages/SystemUI/tests/utils/src/com/android/systemui/statusbar/policy/FakeDeviceProvisionedController.kt +10 −2 Original line number Diff line number Diff line Loading @@ -39,8 +39,16 @@ class FakeDeviceProvisionedController : DeviceProvisionedController { callbacks.toSet().forEach { it.onUserSwitched() } } fun setUserSetup(userId: Int) { fun setUserSetup(userId: Int, isSetup: Boolean = true) { if (isSetup) { usersSetup.add(userId) } else { usersSetup.remove(userId) } callbacks.toSet().forEach { it.onUserSetupChanged() } } fun setCurrentUserSetup(isSetup: Boolean) { setUserSetup(currentUser, isSetup) } }