Handling label and icon from SessionInfo.
> The ShortcutInfo stores state as bit flags and not as ints
> Intents of auto-install shortcut are automatically updated
upon installation
> Icons/titles for active sessions are cached in IconCache
Change-Id: I2047849f67d4a8aaf2bc346b58110325bb4807d4
diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java
index 83f813d..32fed34 100644
--- a/src/com/android/launcher3/Launcher.java
+++ b/src/com/android/launcher3/Launcher.java
@@ -2600,9 +2600,11 @@
}
// Check for abandoned promise
- if (shortcut.isAbandoned() && v instanceof BubbleTextView) {
+ if ((v instanceof BubbleTextView)
+ && shortcut.isPromise()
+ && !shortcut.hasStatusFlag(ShortcutInfo.FLAG_INSTALL_SESSION_ACTIVE)) {
showBrokenAppInstallDialog(
- shortcut.getRestoredIntent().getComponent().getPackageName(),
+ shortcut.getTargetComponent().getPackageName(),
new DialogInterface.OnClickListener() {
public void onClick(DialogInterface dialog, int id) {
startAppShortcutOrInfoActivity(v);