Adding broadcast receiver to handle SESSION_COMMIT broadcast
> Disabling Install shortcut broadcast for O and above
> Adding a preference to control automatic icon addition on homescreen
> Adding icons on homescreen for new installs based on the above preference
Bug: 32920609
Bug: 27967412
Change-Id: I92e5cb7c841fb445dc8bc058d975f212ee54f8d1
diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java
index f9e6f4b..5e08c2a 100644
--- a/src/com/android/launcher3/Launcher.java
+++ b/src/com/android/launcher3/Launcher.java
@@ -1152,9 +1152,10 @@
if (mLauncherCallbacks != null) {
return mLauncherCallbacks.hasSettings();
} else {
- // On devices with a locked orientation, we will at least have the allow rotation
- // setting.
- return !getResources().getBoolean(R.bool.allow_rotation);
+ // 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);
}
}