mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-03-04 01:46:49 +00:00
Ensure the reorder test runs on the foldable devices
It moves some classes form the Nexus package into the launcher package so it can be used in both projects. It also adds more test for foldables and test multiple grids for each test. Bug: 289584301 Fix: 291346193 Test: ReorderWidgets Change-Id: I04db5f685d0344b8a3f3d42b429bbde061b3d8ea
This commit is contained in:
@@ -42,8 +42,8 @@ public class CellLayoutTestUtils {
|
||||
params.getCellX(), params.getCellY(),
|
||||
launcher.getWorkspace().getIdForScreen(cellLayout), CONTAINER_DESKTOP);
|
||||
int screenId = pos.screenId;
|
||||
if (screenId >= boards.size() - 1) {
|
||||
boards.add(new CellLayoutBoard());
|
||||
if (screenId > boards.size() - 1) {
|
||||
boards.add(new CellLayoutBoard(cellLayout.getCountX(), cellLayout.getCountY()));
|
||||
}
|
||||
CellLayoutBoard board = boards.get(screenId);
|
||||
// is icon
|
||||
@@ -51,7 +51,7 @@ public class CellLayoutTestUtils {
|
||||
board.addIcon(pos.cellX, pos.cellY);
|
||||
} else {
|
||||
// is widget
|
||||
board.addWidget(params.getCellX(), params.getCellY(), params.cellHSpan,
|
||||
board.addWidget(pos.cellX, pos.cellY, params.cellHSpan,
|
||||
params.cellVSpan);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user