Loading libs/WindowManager/Shell/src/com/android/wm/shell/windowdecor/CaptionWindowDecorViewModel.java +1 −1 Original line number Diff line number Diff line Loading @@ -522,7 +522,7 @@ public class CaptionWindowDecorViewModel implements WindowDecorViewModel, FocusT e.getDisplayId(), e.getRawX(dragPointerIdx), e.getRawY(dragPointerIdx)); DragPositioningCallbackUtility.snapTaskBoundsIfNecessary(newTaskBounds, mWindowDecorByTaskId.get(mTaskId).calculateValidDragArea()); mWindowDecorByTaskId.get(mTaskId).getValidDragArea()); if (newTaskBounds != taskInfo.configuration.windowConfiguration.getBounds()) { final WindowContainerTransaction wct = new WindowContainerTransaction(); wct.setBounds(taskInfo.token, newTaskBounds); Loading libs/WindowManager/Shell/src/com/android/wm/shell/windowdecor/CaptionWindowDecoration.java +0 −1 Original line number Diff line number Diff line Loading @@ -131,7 +131,6 @@ public class CaptionWindowDecoration extends WindowDecoration<WindowDecorLinearL mDragPositioningCallback = dragPositioningCallback; } @Override @NonNull Rect calculateValidDragArea() { final Context displayContext = mDisplayController.getDisplayContext(mTaskInfo.displayId); Loading libs/WindowManager/Shell/src/com/android/wm/shell/windowdecor/CarWindowDecoration.java +0 −6 Original line number Diff line number Diff line Loading @@ -121,12 +121,6 @@ public class CarWindowDecoration extends WindowDecoration<WindowDecorLinearLayou } } @Override @NonNull Rect calculateValidDragArea() { return new Rect(); } @Override int getCaptionViewId() { return R.id.caption; Loading libs/WindowManager/Shell/src/com/android/wm/shell/windowdecor/DesktopModeTouchEventListener.java +1 −1 Original line number Diff line number Diff line Loading @@ -672,7 +672,7 @@ public class DesktopModeTouchEventListener // Tasks bounds haven't actually been updated (only its leash), so pass to // DesktopTasksController to allow secondary transformations (i.e. snap resizing // or transforming to fullscreen) before setting new task bounds. final Rect validDragArea = decoration.calculateValidDragArea(); final Rect validDragArea = decoration.getValidDragArea(); final boolean needDragIndicatorCleanup = mDesktopTasksController.onDragPositioningEnd( taskInfo, decoration.getTaskSurface(), e.getDisplayId(), Loading libs/WindowManager/Shell/src/com/android/wm/shell/windowdecor/DesktopModeWindowDecorViewModel.java +5 −3 Original line number Diff line number Diff line Loading @@ -494,14 +494,16 @@ public class DesktopModeWindowDecorViewModel implements WindowDecorViewModel, } // Check if display has been rotated between portrait & landscape if (displayId == taskInfo.displayId && taskInfo.isFreeform() && (fromRotation % 2 != toRotation % 2)) { if (displayId == taskInfo.displayId && (fromRotation % 2 != toRotation % 2)) { final Rect validDragArea = decoration.getValidDragArea(); // If not draggable, return if (validDragArea == null) return; // Check if the task bounds on the rotated display will be out of bounds. // If so, then update task bounds to be within reachable area. final Rect taskBounds = new Rect( taskInfo.configuration.windowConfiguration.getBounds()); if (DragPositioningCallbackUtility.snapTaskBoundsIfNecessary( taskBounds, decoration.calculateValidDragArea())) { taskBounds, validDragArea)) { t.setBounds(taskInfo.token, taskBounds); } } Loading Loading
libs/WindowManager/Shell/src/com/android/wm/shell/windowdecor/CaptionWindowDecorViewModel.java +1 −1 Original line number Diff line number Diff line Loading @@ -522,7 +522,7 @@ public class CaptionWindowDecorViewModel implements WindowDecorViewModel, FocusT e.getDisplayId(), e.getRawX(dragPointerIdx), e.getRawY(dragPointerIdx)); DragPositioningCallbackUtility.snapTaskBoundsIfNecessary(newTaskBounds, mWindowDecorByTaskId.get(mTaskId).calculateValidDragArea()); mWindowDecorByTaskId.get(mTaskId).getValidDragArea()); if (newTaskBounds != taskInfo.configuration.windowConfiguration.getBounds()) { final WindowContainerTransaction wct = new WindowContainerTransaction(); wct.setBounds(taskInfo.token, newTaskBounds); Loading
libs/WindowManager/Shell/src/com/android/wm/shell/windowdecor/CaptionWindowDecoration.java +0 −1 Original line number Diff line number Diff line Loading @@ -131,7 +131,6 @@ public class CaptionWindowDecoration extends WindowDecoration<WindowDecorLinearL mDragPositioningCallback = dragPositioningCallback; } @Override @NonNull Rect calculateValidDragArea() { final Context displayContext = mDisplayController.getDisplayContext(mTaskInfo.displayId); Loading
libs/WindowManager/Shell/src/com/android/wm/shell/windowdecor/CarWindowDecoration.java +0 −6 Original line number Diff line number Diff line Loading @@ -121,12 +121,6 @@ public class CarWindowDecoration extends WindowDecoration<WindowDecorLinearLayou } } @Override @NonNull Rect calculateValidDragArea() { return new Rect(); } @Override int getCaptionViewId() { return R.id.caption; Loading
libs/WindowManager/Shell/src/com/android/wm/shell/windowdecor/DesktopModeTouchEventListener.java +1 −1 Original line number Diff line number Diff line Loading @@ -672,7 +672,7 @@ public class DesktopModeTouchEventListener // Tasks bounds haven't actually been updated (only its leash), so pass to // DesktopTasksController to allow secondary transformations (i.e. snap resizing // or transforming to fullscreen) before setting new task bounds. final Rect validDragArea = decoration.calculateValidDragArea(); final Rect validDragArea = decoration.getValidDragArea(); final boolean needDragIndicatorCleanup = mDesktopTasksController.onDragPositioningEnd( taskInfo, decoration.getTaskSurface(), e.getDisplayId(), Loading
libs/WindowManager/Shell/src/com/android/wm/shell/windowdecor/DesktopModeWindowDecorViewModel.java +5 −3 Original line number Diff line number Diff line Loading @@ -494,14 +494,16 @@ public class DesktopModeWindowDecorViewModel implements WindowDecorViewModel, } // Check if display has been rotated between portrait & landscape if (displayId == taskInfo.displayId && taskInfo.isFreeform() && (fromRotation % 2 != toRotation % 2)) { if (displayId == taskInfo.displayId && (fromRotation % 2 != toRotation % 2)) { final Rect validDragArea = decoration.getValidDragArea(); // If not draggable, return if (validDragArea == null) return; // Check if the task bounds on the rotated display will be out of bounds. // If so, then update task bounds to be within reachable area. final Rect taskBounds = new Rect( taskInfo.configuration.windowConfiguration.getBounds()); if (DragPositioningCallbackUtility.snapTaskBoundsIfNecessary( taskBounds, decoration.calculateValidDragArea())) { taskBounds, validDragArea)) { t.setBounds(taskInfo.token, taskBounds); } } Loading