Hide window swapping behind a flag

am: 6885598

* commit '6885598ba09b18038e61f268231aa53ed08ef44c':
  Hide window swapping behind a flag
This commit is contained in:
Jorim Jaggi
2016-03-26 02:01:19 +00:00
committed by android-build-merger

View File

@@ -83,6 +83,7 @@ public class DividerView extends FrameLayout implements OnTouchListener,
private static final String TAG = "DividerView";
private static final int TASK_POSITION_SAME = Integer.MAX_VALUE;
private static final boolean SWAPPING_ENABLED = false;
/**
* How much the background gets scaled when we are in the minimized dock state.
@@ -213,12 +214,14 @@ public class DividerView extends FrameLayout implements OnTouchListener,
mGestureDetector = new GestureDetector(mContext, new SimpleOnGestureListener() {
@Override
public boolean onSingleTapUp(MotionEvent e) {
updateDockSide();
SystemServicesProxy ssp = Recents.getSystemServices();
if (mDockSide != WindowManager.DOCKED_INVALID
&& !ssp.isRecentsTopMost(ssp.getTopMostTask(), null /* isTopHome */)) {
mWindowManagerProxy.swapTasks();
return true;
if (SWAPPING_ENABLED) {
updateDockSide();
SystemServicesProxy ssp = Recents.getSystemServices();
if (mDockSide != WindowManager.DOCKED_INVALID
&& !ssp.isRecentsTopMost(ssp.getTopMostTask(), null /* isTopHome */)) {
mWindowManagerProxy.swapTasks();
return true;
}
}
return false;
}