Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c444e086 authored by Ben Reich's avatar Ben Reich Committed by Android (Google) Code Review
Browse files

Merge "Respect is_launcher_enabled on PRE_BOOT_COMPLETED for FEATURE_PC" into main

parents ec686c19 4b7083c4
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -95,8 +95,11 @@ public class PreBootReceiver extends BroadcastReceiver {
        if (resId != 0) {
            final ComponentName component = new ComponentName(packageName, className);
            boolean enabled = overlayRes.getBoolean(resId);
            if (VersionUtils.isAtLeastS() && CONFIG_IS_LAUNCHER_ENABLED.equals(config)) {
                enabled = false; // Do not allow LauncherActivity to be enabled for S+.
            if (VersionUtils.isAtLeastS() && !pm.hasSystemFeature(PackageManager.FEATURE_PC)
                    && CONFIG_IS_LAUNCHER_ENABLED.equals(config)) {
                // Devices using S+ that don't support the `FEATURE_PC` system feature should not
                // show Files in the launcher.
                enabled = false;
            }
            if (DEBUG) {
                Log.i(TAG,