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

Commit 673f917d authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "WallpaperManagerCompat should target correct platform Also replace...

Merge "WallpaperManagerCompat should target correct platform Also replace Utilities.isAtLeastO() to static final constant. Bug: 65544683" into ub-launcher3-dorval-polish2
parents a41ebf0c e24cb63b
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -123,7 +123,7 @@ public class IconCache {
    }

    private Drawable getFullResDefaultActivityIcon() {
        return getFullResIcon(Resources.getSystem(), Utilities.isAtLeastO() ?
        return getFullResIcon(Resources.getSystem(), Utilities.ATLEAST_OREO ?
                android.R.drawable.sym_def_app_icon : android.R.mipmap.sym_def_app_icon);
    }

+2 −2
Original line number Diff line number Diff line
@@ -1132,7 +1132,7 @@ public class Launcher extends BaseActivity
            // On O and above we there is always some setting present settings (add icon to
            // home screen or icon badging). On earlier APIs we will have the allow rotation
            // setting, on devices with a locked orientation,
            return Utilities.isAtLeastO() || !getResources().getBoolean(R.bool.allow_rotation);
            return Utilities.ATLEAST_OREO || !getResources().getBoolean(R.bool.allow_rotation);
        }
    }

@@ -1414,7 +1414,7 @@ public class Launcher extends BaseActivity
        CellLayout layout = getCellLayout(container, screenId);

        ShortcutInfo info = null;
        if (Utilities.isAtLeastO()) {
        if (Utilities.ATLEAST_OREO) {
            info = LauncherAppsCompatVO.createShortcutInfoFromPinItemRequest(
                    this, LauncherAppsCompatVO.getPinItemRequest(data), 0);
        }
+1 −1
Original line number Diff line number Diff line
@@ -92,7 +92,7 @@ public class LauncherAppWidgetHostView extends AppWidgetHostView
        setAccessibilityDelegate(Launcher.getLauncher(context).getAccessibilityDelegate());
        setBackgroundResource(R.drawable.widget_internal_focus_bg);

        if (Utilities.isAtLeastO()) {
        if (Utilities.ATLEAST_OREO) {
            setExecutor(Utilities.THREAD_POOL_EXECUTOR);
        }
    }
+2 −2
Original line number Diff line number Diff line
@@ -59,7 +59,7 @@ public class SessionCommitReceiver extends BroadcastReceiver {

    @Override
    public void onReceive(Context context, Intent intent) {
        if (!isEnabled(context) || !Utilities.isAtLeastO()) {
        if (!isEnabled(context) || !Utilities.ATLEAST_OREO) {
            // User has decided to not add icons on homescreen.
            return;
        }
@@ -92,7 +92,7 @@ public class SessionCommitReceiver extends BroadcastReceiver {
    }

    public static void applyDefaultUserPrefs(final Context context) {
        if (!Utilities.isAtLeastO()) {
        if (!Utilities.ATLEAST_OREO) {
            return;
        }
        SharedPreferences prefs = Utilities.getPrefs(context);
+1 −1
Original line number Diff line number Diff line
@@ -94,7 +94,7 @@ public class SettingsActivity extends Activity {

            ButtonPreference iconBadgingPref =
                    (ButtonPreference) findPreference(ICON_BADGING_PREFERENCE_KEY);
            if (!Utilities.isAtLeastO()) {
            if (!Utilities.ATLEAST_OREO) {
                getPreferenceScreen().removePreference(
                        findPreference(SessionCommitReceiver.ADD_ICON_PREFERENCE_KEY));
                getPreferenceScreen().removePreference(iconBadgingPref);
Loading