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

Commit 28c48f93 authored by Adam Cohen's avatar Adam Cohen Committed by Android Git Automerger
Browse files

am 5eed5d8c: Ensure that hotseat callout only occurs when appropriate

* commit '5eed5d8c':
  Ensure that hotseat callout only occurs when appropriate
parents 40b3830a 5eed5d8c
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -4434,6 +4434,9 @@ public class Launcher extends Activity
        }
    }

    protected boolean shouldClingFocusHotseatApp() {
        return false;
    }
    protected String getFirstRunClingSearchBarHint() {
        return "";
    }
+7 −15
Original line number Diff line number Diff line
@@ -264,12 +264,7 @@ class LauncherClings {
                WORKSPACE_CLING_DISMISSED_KEY, false)) {
            Cling c = initCling(R.id.workspace_cling, 0, false, true);
            c.updateWorkspaceBubblePosition();

            try {
                // We only enable the focused hotseat app if we are preinstalled
                PackageManager pm = mLauncher.getPackageManager();
                ApplicationInfo ai = pm.getApplicationInfo(mLauncher.getPackageName(), 0);
                if ((ai.flags & ApplicationInfo.FLAG_SYSTEM) != 0) {
            if (mLauncher.shouldClingFocusHotseatApp()) {
                // Set the focused hotseat app
                c.setFocusedHotseatApp(mLauncher.getFirstRunFocusedHotseatAppDrawableId(),
                    mLauncher.getFirstRunFocusedHotseatAppRank(),
@@ -277,9 +272,6 @@ class LauncherClings {
                    mLauncher.getFirstRunFocusedHotseatAppBubbleTitle(),
                    mLauncher.getFirstRunFocusedHotseatAppBubbleDescription());
            }
            } catch (PackageManager.NameNotFoundException e) {
                e.printStackTrace();
            }
        } else {
            removeCling(R.id.workspace_cling);
        }