mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-19 02:38:20 +00:00
Fix LauncherProvider newScreenId issue
Remove maxScreenId from LauncherProvider and whenever we need a new screenId, query the database to calculate a new screenId. Also converted and refactored AddWorkspaceItemsTaskTest and added some extra test cases. Test: manual & AddWorkspaceItemsTaskTest.kt Bug: 199160559 Change-Id: I185f6823fed171d778af0130497f5ffaf89c0a70
This commit is contained in:
@@ -16,7 +16,6 @@
|
||||
package com.android.launcher3.model;
|
||||
|
||||
import static com.android.launcher3.WorkspaceLayoutManager.FIRST_SCREEN_ID;
|
||||
import static com.android.launcher3.WorkspaceLayoutManager.SECOND_SCREEN_ID;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.content.pm.LauncherActivityInfo;
|
||||
@@ -300,11 +299,6 @@ public class AddWorkspaceItemsTask extends BaseModelUpdateTask {
|
||||
IntSet screensToExclude = new IntSet();
|
||||
if (FeatureFlags.QSB_ON_FIRST_SCREEN) {
|
||||
screensToExclude.add(FIRST_SCREEN_ID);
|
||||
|
||||
// On split display we don't want to add the new items onto the second screen.
|
||||
if (app.getInvariantDeviceProfile().isSplitDisplay) {
|
||||
screensToExclude.add(SECOND_SCREEN_ID);
|
||||
}
|
||||
}
|
||||
|
||||
for (int screen = 0; screen < screenCount; screen++) {
|
||||
|
||||
Reference in New Issue
Block a user