mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-20 11:18:21 +00:00
Moving icon generation out of ShortcutInfo constructor so that it
can be created on the UI thread Change-Id: If84e52041eb4ab20807f5cfd4b7f31d7b5f381ed
This commit is contained in:
@@ -25,6 +25,7 @@ import com.android.launcher3.LauncherModel;
|
||||
import com.android.launcher3.LauncherSettings;
|
||||
import com.android.launcher3.ShortcutInfo;
|
||||
import com.android.launcher3.compat.UserManagerCompat;
|
||||
import com.android.launcher3.graphics.LauncherIcons;
|
||||
import com.android.launcher3.shortcuts.DeepShortcutManager;
|
||||
import com.android.launcher3.shortcuts.ShortcutInfoCompat;
|
||||
import com.android.launcher3.shortcuts.ShortcutKey;
|
||||
@@ -85,6 +86,7 @@ public class UserLockStateChangedTask extends ExtendedModelTask {
|
||||
}
|
||||
si.isDisabled &= ~ShortcutInfo.FLAG_DISABLED_LOCKED_USER;
|
||||
si.updateFromDeepShortcutInfo(shortcut, context);
|
||||
si.iconBitmap = LauncherIcons.createShortcutIcon(shortcut, context);
|
||||
} else {
|
||||
si.isDisabled |= ShortcutInfo.FLAG_DISABLED_LOCKED_USER;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user