Listen to LauncherUserInfo config changes and hide/unhide private space

entrypoint accordingly

Flag: android.multiuser.add_launcher_user_config

Bug: 346553745
Test: Manual - verified on device
Test: atest LauncherAppsTests

Change-Id: I202c4c76af4f96d5b3226daffcfebc2f9b9703b1
This commit is contained in:
Olivier Nshimiye committed 2024-11-13 21:35:05 +00:00
1 parent be17fb8a63
commit 39dee43e12
7 files changed
+80 -24

No files matched your search

@@ -188,7 +188,9 @@ public class LauncherAppState implements SafeCloseable {
mOnTerminateCallback.add(() ->
settingsCache.unregister(NOTIFICATION_BADGING_URI, notificationLister));
// Register an observer to notify Launcher about Private Space settings toggle.
registerPrivateSpaceHideWhenLockListener(settingsCache);
if (!android.multiuser.Flags.addLauncherUserConfig()) {
registerPrivateSpaceHideWhenLockListener(settingsCache);
}
}
public LauncherAppState(Context context, @Nullable String iconCacheFileName) {