diff --git a/src/com/android/launcher3/Workspace.java b/src/com/android/launcher3/Workspace.java index 58209c3176..14fb3fc59c 100644 --- a/src/com/android/launcher3/Workspace.java +++ b/src/com/android/launcher3/Workspace.java @@ -1930,7 +1930,8 @@ public class Workspace extends PagedView // Find a page that has enough space to place this widget (after rearranging/resizing). // Start at the current page and search right (on LTR) until finding a page with enough // space. Since an empty screen is the furthest right, a page must be found. - for (int pageIndex = getCurrentPage(); pageIndex <= getPageCount(); pageIndex++) { + int currentPageInOverview = getPageNearestToCenterOfScreen(); + for (int pageIndex = currentPageInOverview; pageIndex < getPageCount(); pageIndex++) { CellLayout page = (CellLayout) getPageAt(pageIndex); if (page.hasReorderSolution(info)) { setCurrentPage(pageIndex);