Commit a2f149f5 authored by ajith.v's avatar ajith.v Committed by Commit bot

Force to exit full screen video upon receiving ESCAPE key event

Currently ESCAPE key event is not handled correctly while playing
full screen video. Now exiting full screen video when receives
ESCAPE key event to match desktop behavior.

BUG=614185

Review-Url: https://codereview.chromium.org/2124003004
Cr-Commit-Position: refs/heads/master@{#407151}
parent dd06babf
......@@ -70,6 +70,10 @@ public class KeyboardShortcuts {
activity.onMenuOrKeyboardAction(R.id.show_menu, false);
}
return true;
case KeyEvent.KEYCODE_ESCAPE:
if (event.getAction() == KeyEvent.ACTION_DOWN && event.getRepeatCount() == 0) {
return activity.exitFullscreenIfShowing();
}
case KeyEvent.KEYCODE_TV:
case KeyEvent.KEYCODE_GUIDE:
case KeyEvent.KEYCODE_DVR:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment