Loading quickstep/src/com/android/launcher3/model/QuickstepModelDelegate.java +5 −6 Original line number Diff line number Diff line Loading @@ -84,7 +84,7 @@ public class QuickstepModelDelegate extends ModelDelegate implements OnIDPChange private final InvariantDeviceProfile mIDP; private final AppEventProducer mAppEventProducer; private boolean mActive = false; protected boolean mActive = false; public QuickstepModelDelegate(Context context) { mAppEventProducer = new AppEventProducer(context, this::onAppTargetEvent); Loading Loading @@ -200,7 +200,6 @@ public class QuickstepModelDelegate extends ModelDelegate implements OnIDPChange .setPredictedTargetCount(mIDP.numHotseatIcons) .setExtras(convertDataModelToAppTargetBundle(context, mDataModel)) .build())); } private void registerPredictor(PredictorState state, AppPredictor predictor) { Loading Loading @@ -236,14 +235,14 @@ public class QuickstepModelDelegate extends ModelDelegate implements OnIDPChange static class PredictorState { public final FixedContainerItems items; public final PersistedItemArray storage; public final PersistedItemArray<ItemInfo> storage; public AppPredictor predictor; private List<AppTarget> mLastTargets; PredictorState(int container, String storageName) { items = new FixedContainerItems(container); storage = new PersistedItemArray(storageName); storage = new PersistedItemArray<>(storageName); mLastTargets = Collections.emptyList(); } Loading @@ -255,7 +254,7 @@ public class QuickstepModelDelegate extends ModelDelegate implements OnIDPChange } /** * Sets the new targets and returns true if it was different than before. * Sets the new targets and returns true if it was the same as before. */ boolean setTargets(List<AppTarget> newTargets) { List<AppTarget> oldTargets = mLastTargets; Loading Loading @@ -289,7 +288,7 @@ public class QuickstepModelDelegate extends ModelDelegate implements OnIDPChange return true; } private static class WorkspaceItemFactory implements PersistedItemArray.ItemFactory { private static class WorkspaceItemFactory implements PersistedItemArray.ItemFactory<ItemInfo> { private final LauncherAppState mAppState; private final UserManagerState mUMS; Loading src/com/android/launcher3/LauncherSettings.java +34 −26 Original line number Diff line number Diff line Loading @@ -74,6 +74,37 @@ public class LauncherSettings { */ public static final int ITEM_TYPE_SHORTCUT = 1; /** * The favorite is a user created folder */ public static final int ITEM_TYPE_FOLDER = 2; /** * The favorite is a widget */ public static final int ITEM_TYPE_APPWIDGET = 4; /** * The favorite is a custom widget provided by the launcher */ public static final int ITEM_TYPE_CUSTOM_APPWIDGET = 5; /** * The gesture is an application created deep shortcut */ public static final int ITEM_TYPE_DEEP_SHORTCUT = 6; /** * Type of the item is recents task. * TODO(hyunyoungs): move constants not related to Favorites DB to a better location. */ public static final int ITEM_TYPE_TASK = 7; /** * The item is QSB */ public static final int ITEM_TYPE_QSB = 8; /** * The icon package name in Intent.ShortcutIconResource * <P>Type: TEXT</P> Loading Loading @@ -170,6 +201,7 @@ public class LauncherSettings { public static final int CONTAINER_SHORTCUTS = -107; public static final int CONTAINER_SETTINGS = -108; public static final int CONTAINER_TASKSWITCHER = -109; public static final int CONTAINER_QSB = -110; // Represents any of the extended containers implemented in non-AOSP variants. public static final int EXTENDED_CONTAINERS = -200; Loading @@ -195,6 +227,8 @@ public class LauncherSettings { case ITEM_TYPE_APPWIDGET: return "WIDGET"; case ITEM_TYPE_CUSTOM_APPWIDGET: return "CUSTOMWIDGET"; case ITEM_TYPE_DEEP_SHORTCUT: return "DEEPSHORTCUT"; case ITEM_TYPE_TASK: return "TASK"; case ITEM_TYPE_QSB: return "QSB"; default: return String.valueOf(type); } } Loading Loading @@ -239,32 +273,6 @@ public class LauncherSettings { */ public static final String PROFILE_ID = "profileId"; /** * The favorite is a user created folder */ public static final int ITEM_TYPE_FOLDER = 2; /** * The favorite is a widget */ public static final int ITEM_TYPE_APPWIDGET = 4; /** * The favorite is a custom widget provided by the launcher */ public static final int ITEM_TYPE_CUSTOM_APPWIDGET = 5; /** * The gesture is an application created deep shortcut */ public static final int ITEM_TYPE_DEEP_SHORTCUT = 6; /** * Type of the item is recents task. * TODO(hyunyoungs): move constants not related to Favorites DB to a better location. */ public static final int ITEM_TYPE_TASK = 7; /** * The appWidgetId of the widget * Loading src_plugins/com/android/systemui/plugins/BcSmartspaceDataPlugin.java +1 −1 Original line number Diff line number Diff line Loading @@ -39,6 +39,6 @@ public interface BcSmartspaceDataPlugin extends Plugin { /** Provides Smartspace data to registered listeners. */ interface SmartspaceTargetListener { /** Each Parcelable is a SmartspaceTarget that represents a card. */ void onSmartspaceTargetsUpdated(List<Parcelable> targets); void onSmartspaceTargetsUpdated(List<? extends Parcelable> targets); } } Loading
quickstep/src/com/android/launcher3/model/QuickstepModelDelegate.java +5 −6 Original line number Diff line number Diff line Loading @@ -84,7 +84,7 @@ public class QuickstepModelDelegate extends ModelDelegate implements OnIDPChange private final InvariantDeviceProfile mIDP; private final AppEventProducer mAppEventProducer; private boolean mActive = false; protected boolean mActive = false; public QuickstepModelDelegate(Context context) { mAppEventProducer = new AppEventProducer(context, this::onAppTargetEvent); Loading Loading @@ -200,7 +200,6 @@ public class QuickstepModelDelegate extends ModelDelegate implements OnIDPChange .setPredictedTargetCount(mIDP.numHotseatIcons) .setExtras(convertDataModelToAppTargetBundle(context, mDataModel)) .build())); } private void registerPredictor(PredictorState state, AppPredictor predictor) { Loading Loading @@ -236,14 +235,14 @@ public class QuickstepModelDelegate extends ModelDelegate implements OnIDPChange static class PredictorState { public final FixedContainerItems items; public final PersistedItemArray storage; public final PersistedItemArray<ItemInfo> storage; public AppPredictor predictor; private List<AppTarget> mLastTargets; PredictorState(int container, String storageName) { items = new FixedContainerItems(container); storage = new PersistedItemArray(storageName); storage = new PersistedItemArray<>(storageName); mLastTargets = Collections.emptyList(); } Loading @@ -255,7 +254,7 @@ public class QuickstepModelDelegate extends ModelDelegate implements OnIDPChange } /** * Sets the new targets and returns true if it was different than before. * Sets the new targets and returns true if it was the same as before. */ boolean setTargets(List<AppTarget> newTargets) { List<AppTarget> oldTargets = mLastTargets; Loading Loading @@ -289,7 +288,7 @@ public class QuickstepModelDelegate extends ModelDelegate implements OnIDPChange return true; } private static class WorkspaceItemFactory implements PersistedItemArray.ItemFactory { private static class WorkspaceItemFactory implements PersistedItemArray.ItemFactory<ItemInfo> { private final LauncherAppState mAppState; private final UserManagerState mUMS; Loading
src/com/android/launcher3/LauncherSettings.java +34 −26 Original line number Diff line number Diff line Loading @@ -74,6 +74,37 @@ public class LauncherSettings { */ public static final int ITEM_TYPE_SHORTCUT = 1; /** * The favorite is a user created folder */ public static final int ITEM_TYPE_FOLDER = 2; /** * The favorite is a widget */ public static final int ITEM_TYPE_APPWIDGET = 4; /** * The favorite is a custom widget provided by the launcher */ public static final int ITEM_TYPE_CUSTOM_APPWIDGET = 5; /** * The gesture is an application created deep shortcut */ public static final int ITEM_TYPE_DEEP_SHORTCUT = 6; /** * Type of the item is recents task. * TODO(hyunyoungs): move constants not related to Favorites DB to a better location. */ public static final int ITEM_TYPE_TASK = 7; /** * The item is QSB */ public static final int ITEM_TYPE_QSB = 8; /** * The icon package name in Intent.ShortcutIconResource * <P>Type: TEXT</P> Loading Loading @@ -170,6 +201,7 @@ public class LauncherSettings { public static final int CONTAINER_SHORTCUTS = -107; public static final int CONTAINER_SETTINGS = -108; public static final int CONTAINER_TASKSWITCHER = -109; public static final int CONTAINER_QSB = -110; // Represents any of the extended containers implemented in non-AOSP variants. public static final int EXTENDED_CONTAINERS = -200; Loading @@ -195,6 +227,8 @@ public class LauncherSettings { case ITEM_TYPE_APPWIDGET: return "WIDGET"; case ITEM_TYPE_CUSTOM_APPWIDGET: return "CUSTOMWIDGET"; case ITEM_TYPE_DEEP_SHORTCUT: return "DEEPSHORTCUT"; case ITEM_TYPE_TASK: return "TASK"; case ITEM_TYPE_QSB: return "QSB"; default: return String.valueOf(type); } } Loading Loading @@ -239,32 +273,6 @@ public class LauncherSettings { */ public static final String PROFILE_ID = "profileId"; /** * The favorite is a user created folder */ public static final int ITEM_TYPE_FOLDER = 2; /** * The favorite is a widget */ public static final int ITEM_TYPE_APPWIDGET = 4; /** * The favorite is a custom widget provided by the launcher */ public static final int ITEM_TYPE_CUSTOM_APPWIDGET = 5; /** * The gesture is an application created deep shortcut */ public static final int ITEM_TYPE_DEEP_SHORTCUT = 6; /** * Type of the item is recents task. * TODO(hyunyoungs): move constants not related to Favorites DB to a better location. */ public static final int ITEM_TYPE_TASK = 7; /** * The appWidgetId of the widget * Loading
src_plugins/com/android/systemui/plugins/BcSmartspaceDataPlugin.java +1 −1 Original line number Diff line number Diff line Loading @@ -39,6 +39,6 @@ public interface BcSmartspaceDataPlugin extends Plugin { /** Provides Smartspace data to registered listeners. */ interface SmartspaceTargetListener { /** Each Parcelable is a SmartspaceTarget that represents a card. */ void onSmartspaceTargetsUpdated(List<Parcelable> targets); void onSmartspaceTargetsUpdated(List<? extends Parcelable> targets); } }