mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-17 17:48:20 +00:00
Merge "Enable a11y scrolling with item drag" into ub-launcher3-qt-future-dev
This commit is contained in:
@@ -1275,6 +1275,10 @@ public class Workspace extends PagedView<WorkspacePageIndicator>
|
||||
return !mLauncher.isInState(NORMAL);
|
||||
}
|
||||
|
||||
private boolean workspaceInScrollableState() {
|
||||
return mLauncher.isInState(SPRING_LOADED) || !workspaceInModalState();
|
||||
}
|
||||
|
||||
/** Returns whether a drag should be allowed to be started from the current workspace state. */
|
||||
public boolean workspaceIconsCanBeDragged() {
|
||||
return mLauncher.getStateManager().getState().workspaceIconsCanBeDragged;
|
||||
@@ -2879,7 +2883,7 @@ public class Workspace extends PagedView<WorkspacePageIndicator>
|
||||
@Override
|
||||
public boolean scrollLeft() {
|
||||
boolean result = false;
|
||||
if (!workspaceInModalState() && !mIsSwitchingState) {
|
||||
if (!mIsSwitchingState && workspaceInScrollableState()) {
|
||||
result = super.scrollLeft();
|
||||
}
|
||||
Folder openFolder = Folder.getOpen(mLauncher);
|
||||
@@ -2892,7 +2896,7 @@ public class Workspace extends PagedView<WorkspacePageIndicator>
|
||||
@Override
|
||||
public boolean scrollRight() {
|
||||
boolean result = false;
|
||||
if (!workspaceInModalState() && !mIsSwitchingState) {
|
||||
if (!mIsSwitchingState && workspaceInScrollableState()) {
|
||||
result = super.scrollRight();
|
||||
}
|
||||
Folder openFolder = Folder.getOpen(mLauncher);
|
||||
|
||||
Reference in New Issue
Block a user