Added provision to switch the PageIndicator in specific Launchers

Please see the related CL in LauncherLilyGoogle where pagination is
implemented as persistent dots.

Bug: b/218187058
Test: manually test thet Launcher3 features work correctly
Change-Id: Ic20aa92249b1bbe3c4ab7810683b54648a181722
This commit is contained in:
Shikha Malhotra
2022-03-27 21:02:21 +00:00
parent 1eb1140129
commit 0f2e1b6714
4 changed files with 33 additions and 8 deletions

View File

@@ -92,7 +92,7 @@ import com.android.launcher3.model.data.ItemInfo;
import com.android.launcher3.model.data.LauncherAppWidgetInfo;
import com.android.launcher3.model.data.SearchActionItemInfo;
import com.android.launcher3.model.data.WorkspaceItemInfo;
import com.android.launcher3.pageindicators.WorkspacePageIndicator;
import com.android.launcher3.pageindicators.PageIndicator;
import com.android.launcher3.popup.PopupContainerWithArrow;
import com.android.launcher3.statemanager.StateManager;
import com.android.launcher3.statemanager.StateManager.StateHandler;
@@ -134,8 +134,9 @@ import java.util.stream.Collectors;
* The workspace is a wide area with a wallpaper and a finite number of pages.
* Each page contains a number of icons, folders or widgets the user can
* interact with. A workspace is meant to be used with a fixed width only.
* @param <T> Class that extends View and PageIndicator
*/
public class Workspace extends PagedView<WorkspacePageIndicator>
public class Workspace<T extends View & PageIndicator> extends PagedView<T>
implements DropTarget, DragSource, View.OnTouchListener,
DragController.DragListener, Insettable, StateHandler<LauncherState>,
WorkspaceLayoutManager, LauncherBindableItemsContainer {