Loading libs/WindowManager/Shell/res/values/config.xml +3 −0 Original line number Diff line number Diff line Loading @@ -30,6 +30,9 @@ <!-- Allow PIP to resize to a slightly bigger state upon touch/showing the menu --> <bool name="config_pipEnableResizeForMenu">true</bool> <!-- Allow PIP to resize via dragging the corner of PiP. --> <bool name="config_pipEnableDragCornerResize">false</bool> <!-- Allow PIP to enable round corner, see also R.dimen.pip_corner_radius --> <bool name="config_pipEnableRoundCorner">false</bool> Loading libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipResizeGestureHandler.java +6 −0 Original line number Diff line number Diff line Loading @@ -103,6 +103,7 @@ public class PipResizeGestureHandler { private boolean mIsAttached; private boolean mIsEnabled; private boolean mEnablePinchResize; private boolean mEnableDragCornerResize; private boolean mIsSysUiStateValid; private boolean mThresholdCrossed; private boolean mOngoingPinchToResize = false; Loading Loading @@ -174,6 +175,7 @@ public class PipResizeGestureHandler { private void reloadResources() { final Resources res = mContext.getResources(); mDelta = res.getDimensionPixelSize(R.dimen.pip_resize_edge_size); mEnableDragCornerResize = res.getBoolean(R.bool.config_pipEnableDragCornerResize); mTouchSlop = ViewConfiguration.get(mContext).getScaledTouchSlop(); } Loading Loading @@ -267,6 +269,10 @@ public class PipResizeGestureHandler { * |_|_| |_|_| */ public boolean isWithinDragResizeRegion(int x, int y) { if (!mEnableDragCornerResize) { return false; } final Rect currentPipBounds = mPipBoundsState.getBounds(); if (currentPipBounds == null) { return false; Loading Loading
libs/WindowManager/Shell/res/values/config.xml +3 −0 Original line number Diff line number Diff line Loading @@ -30,6 +30,9 @@ <!-- Allow PIP to resize to a slightly bigger state upon touch/showing the menu --> <bool name="config_pipEnableResizeForMenu">true</bool> <!-- Allow PIP to resize via dragging the corner of PiP. --> <bool name="config_pipEnableDragCornerResize">false</bool> <!-- Allow PIP to enable round corner, see also R.dimen.pip_corner_radius --> <bool name="config_pipEnableRoundCorner">false</bool> Loading
libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipResizeGestureHandler.java +6 −0 Original line number Diff line number Diff line Loading @@ -103,6 +103,7 @@ public class PipResizeGestureHandler { private boolean mIsAttached; private boolean mIsEnabled; private boolean mEnablePinchResize; private boolean mEnableDragCornerResize; private boolean mIsSysUiStateValid; private boolean mThresholdCrossed; private boolean mOngoingPinchToResize = false; Loading Loading @@ -174,6 +175,7 @@ public class PipResizeGestureHandler { private void reloadResources() { final Resources res = mContext.getResources(); mDelta = res.getDimensionPixelSize(R.dimen.pip_resize_edge_size); mEnableDragCornerResize = res.getBoolean(R.bool.config_pipEnableDragCornerResize); mTouchSlop = ViewConfiguration.get(mContext).getScaledTouchSlop(); } Loading Loading @@ -267,6 +269,10 @@ public class PipResizeGestureHandler { * |_|_| |_|_| */ public boolean isWithinDragResizeRegion(int x, int y) { if (!mEnableDragCornerResize) { return false; } final Rect currentPipBounds = mPipBoundsState.getBounds(); if (currentPipBounds == null) { return false; Loading