mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-03-02 17:06:49 +00:00
Merge changes I35fe528b,Ia612c1b5 into udc-dev
* changes: Don't close AFVs when opening Taskbar folder. Keep persistent Taskbar visible over Taskbar All Apps.
This commit is contained in:
committed by
Android (Google) Code Review
commit
0b53332c31
@@ -24,6 +24,7 @@ import static android.view.WindowManager.LayoutParams.TYPE_NAVIGATION_BAR_PANEL;
|
||||
|
||||
import static com.android.launcher3.AbstractFloatingView.TYPE_ALL;
|
||||
import static com.android.launcher3.AbstractFloatingView.TYPE_REBIND_SAFE;
|
||||
import static com.android.launcher3.AbstractFloatingView.TYPE_TASKBAR_OVERLAY_PROXY;
|
||||
import static com.android.launcher3.Utilities.isRunningInTestHarness;
|
||||
import static com.android.launcher3.logging.StatsLogManager.LauncherEvent.LAUNCHER_FOLDER_OPEN;
|
||||
import static com.android.launcher3.taskbar.TaskbarAutohideSuspendController.FLAG_AUTOHIDE_SUSPEND_DRAGGING;
|
||||
@@ -661,7 +662,10 @@ public class TaskbarActivityContext extends BaseTaskbarContext {
|
||||
void onDragEndOrViewRemoved() {
|
||||
boolean isDragInProgress = mControllers.taskbarDragController.isSystemDragInProgress();
|
||||
|
||||
if (!isDragInProgress && !AbstractFloatingView.hasOpenView(this, TYPE_ALL)) {
|
||||
// Overlay AFVs are in a separate window and do not require Taskbar to be fullscreen.
|
||||
if (!isDragInProgress
|
||||
&& !AbstractFloatingView.hasOpenView(
|
||||
this, TYPE_ALL & ~TYPE_TASKBAR_OVERLAY_PROXY)) {
|
||||
// Reverts Taskbar window to its original size
|
||||
setTaskbarWindowFullscreen(false);
|
||||
}
|
||||
@@ -773,6 +777,7 @@ public class TaskbarActivityContext extends BaseTaskbarContext {
|
||||
}
|
||||
|
||||
protected void onTaskbarIconClicked(View view) {
|
||||
boolean shouldCloseAllOpenViews = true;
|
||||
Object tag = view.getTag();
|
||||
if (tag instanceof Task) {
|
||||
Task task = (Task) tag;
|
||||
@@ -780,6 +785,7 @@ public class TaskbarActivityContext extends BaseTaskbarContext {
|
||||
ActivityOptions.makeBasic());
|
||||
mControllers.taskbarStashController.updateAndAnimateTransientTaskbar(true);
|
||||
} else if (tag instanceof FolderInfo) {
|
||||
shouldCloseAllOpenViews = false;
|
||||
FolderIcon folderIcon = (FolderIcon) view;
|
||||
Folder folder = folderIcon.getFolder();
|
||||
|
||||
@@ -876,7 +882,9 @@ public class TaskbarActivityContext extends BaseTaskbarContext {
|
||||
Log.e(TAG, "Unknown type clicked: " + tag);
|
||||
}
|
||||
|
||||
AbstractFloatingView.closeAllOpenViews(this);
|
||||
if (shouldCloseAllOpenViews) {
|
||||
AbstractFloatingView.closeAllOpenViews(this);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user