I have a VideoView
in one of my Activities
and if I try to press the back Button
it doesn\'t take me to the previous Activity
From CommansWare
Based on the source code, this should work:
- Extend MediaController (for the purposes of this answer, call it RonnieMediaController)
- Override dispatchKeyEvent() in RonnieMediaController
- Before chaining to the superclass, check for KeyEvent.KEYCODE_BACK, and if that is encountered, tell your activity to finish()
- Use RonnieMediaController instead of MediaController with your VideoView
Personally, I'd just leave it alone, as with this change your user cannot make a RonnieMediaController disappear on demand.
Here is the link to the original post.