mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-28 15:56:49 +00:00
Integrating suggested app by handling new status flags for shortcut items.
Guarded via feature flag SUGGESTED_APP. Bug: 62483883 Change-Id: I7e0c8a9875bc37c435aa4316b44322a628cd4826
This commit is contained in:
@@ -184,7 +184,7 @@ public class BubbleTextView extends TextView implements ItemInfoUpdateReceiver {
|
||||
public void applyFromShortcutInfo(ShortcutInfo info, boolean promiseStateChanged) {
|
||||
applyIconAndLabel(info.iconBitmap, info);
|
||||
setTag(info);
|
||||
if (promiseStateChanged || info.isPromise()) {
|
||||
if (promiseStateChanged || (info.hasPromiseIconUi())) {
|
||||
applyPromiseState(promiseStateChanged);
|
||||
}
|
||||
|
||||
@@ -481,7 +481,7 @@ public class BubbleTextView extends TextView implements ItemInfoUpdateReceiver {
|
||||
public void applyPromiseState(boolean promiseStateChanged) {
|
||||
if (getTag() instanceof ShortcutInfo) {
|
||||
ShortcutInfo info = (ShortcutInfo) getTag();
|
||||
final boolean isPromise = info.isPromise();
|
||||
final boolean isPromise = info.hasPromiseIconUi();
|
||||
final int progressLevel = isPromise ?
|
||||
((info.hasStatusFlag(ShortcutInfo.FLAG_INSTALL_SESSION_ACTIVE) ?
|
||||
info.getInstallProgress() : 0)) : 100;
|
||||
|
||||
Reference in New Issue
Block a user