Loading packages/SystemUI/src/com/android/systemui/pip/phone/PipMenuActivity.java +9 −0 Original line number Diff line number Diff line Loading @@ -268,7 +268,10 @@ public class PipMenuActivity extends Activity { mMenuContainerAnimator.addUpdateListener(mMenuBgUpdateListener); mMenuContainerAnimator.start(); } else { // If we are already visible, then just start the delayed dismiss and unregister any // existing input consumers from the previous drag repostDelayedFinish(POST_INTERACTION_DISMISS_DELAY); notifyUnregisterInputConsumer(); } } Loading Loading @@ -416,6 +419,12 @@ public class PipMenuActivity extends Activity { sendMessage(m, "Could not notify controller to register input consumer"); } private void notifyUnregisterInputConsumer() { Message m = Message.obtain(); m.what = PipMenuActivityController.MESSAGE_UNREGISTER_INPUT_CONSUMER; sendMessage(m, "Could not notify controller to unregister input consumer"); } private void notifyMenuVisibility(boolean visible) { mMenuVisible = visible; Message m = Message.obtain(); Loading packages/SystemUI/src/com/android/systemui/pip/phone/PipMenuActivityController.java +5 −0 Original line number Diff line number Diff line Loading @@ -63,6 +63,7 @@ public class PipMenuActivityController { public static final int MESSAGE_DISMISS_PIP = 103; public static final int MESSAGE_UPDATE_ACTIVITY_CALLBACK = 104; public static final int MESSAGE_REGISTER_INPUT_CONSUMER = 105; public static final int MESSAGE_UNREGISTER_INPUT_CONSUMER = 106; /** * A listener interface to receive notification on changes in PIP. Loading Loading @@ -135,6 +136,10 @@ public class PipMenuActivityController { mInputConsumerController.registerInputConsumer(); break; } case MESSAGE_UNREGISTER_INPUT_CONSUMER: { mInputConsumerController.unregisterInputConsumer(); break; } case MESSAGE_UPDATE_ACTIVITY_CALLBACK: { mToActivityMessenger = msg.replyTo; mStartActivityRequested = false; Loading packages/SystemUI/src/com/android/systemui/pip/phone/PipTouchHandler.java +4 −4 Original line number Diff line number Diff line Loading @@ -504,8 +504,8 @@ public class PipTouchHandler { return false; } try { if (ENABLE_DISMISS_DRAG_TO_TARGET) { try { mHandler.removeCallbacks(mShowDismissAffordance); PointF vel = mTouchState.getVelocity(); final float velocity = PointF.length(vel.x, vel.y); Loading @@ -520,10 +520,10 @@ public class PipTouchHandler { return true; } } } } finally { mDismissViewController.destroyDismissTarget(); } } if (touchState.isDragging()) { final boolean onLeft = mMotionHelper.getBounds().left < mMovementBounds.centerX(); Loading Loading
packages/SystemUI/src/com/android/systemui/pip/phone/PipMenuActivity.java +9 −0 Original line number Diff line number Diff line Loading @@ -268,7 +268,10 @@ public class PipMenuActivity extends Activity { mMenuContainerAnimator.addUpdateListener(mMenuBgUpdateListener); mMenuContainerAnimator.start(); } else { // If we are already visible, then just start the delayed dismiss and unregister any // existing input consumers from the previous drag repostDelayedFinish(POST_INTERACTION_DISMISS_DELAY); notifyUnregisterInputConsumer(); } } Loading Loading @@ -416,6 +419,12 @@ public class PipMenuActivity extends Activity { sendMessage(m, "Could not notify controller to register input consumer"); } private void notifyUnregisterInputConsumer() { Message m = Message.obtain(); m.what = PipMenuActivityController.MESSAGE_UNREGISTER_INPUT_CONSUMER; sendMessage(m, "Could not notify controller to unregister input consumer"); } private void notifyMenuVisibility(boolean visible) { mMenuVisible = visible; Message m = Message.obtain(); Loading
packages/SystemUI/src/com/android/systemui/pip/phone/PipMenuActivityController.java +5 −0 Original line number Diff line number Diff line Loading @@ -63,6 +63,7 @@ public class PipMenuActivityController { public static final int MESSAGE_DISMISS_PIP = 103; public static final int MESSAGE_UPDATE_ACTIVITY_CALLBACK = 104; public static final int MESSAGE_REGISTER_INPUT_CONSUMER = 105; public static final int MESSAGE_UNREGISTER_INPUT_CONSUMER = 106; /** * A listener interface to receive notification on changes in PIP. Loading Loading @@ -135,6 +136,10 @@ public class PipMenuActivityController { mInputConsumerController.registerInputConsumer(); break; } case MESSAGE_UNREGISTER_INPUT_CONSUMER: { mInputConsumerController.unregisterInputConsumer(); break; } case MESSAGE_UPDATE_ACTIVITY_CALLBACK: { mToActivityMessenger = msg.replyTo; mStartActivityRequested = false; Loading
packages/SystemUI/src/com/android/systemui/pip/phone/PipTouchHandler.java +4 −4 Original line number Diff line number Diff line Loading @@ -504,8 +504,8 @@ public class PipTouchHandler { return false; } try { if (ENABLE_DISMISS_DRAG_TO_TARGET) { try { mHandler.removeCallbacks(mShowDismissAffordance); PointF vel = mTouchState.getVelocity(); final float velocity = PointF.length(vel.x, vel.y); Loading @@ -520,10 +520,10 @@ public class PipTouchHandler { return true; } } } } finally { mDismissViewController.destroyDismissTarget(); } } if (touchState.isDragging()) { final boolean onLeft = mMotionHelper.getBounds().left < mMovementBounds.centerX(); Loading