Code example for VideoView

Methods: getCurrentPositionisPlaying

0
     */ 
    @Override 
    public void onSaveInstanceState(Bundle outState) {
        super.onSaveInstanceState(outState);
        Log_OC.e(TAG, "ACTIVITY\t\tonSaveInstanceState");
        outState.putInt(PreviewVideoActivity.EXTRA_START_POSITION, mVideoPlayer.getCurrentPosition());
        outState.putBoolean(PreviewVideoActivity.EXTRA_AUTOPLAY , mVideoPlayer.isPlaying());
    } 
 
     
    @Override 
    public void onBackPressed() { 
        Log_OC.e(TAG, "ACTIVTIY\t\tonBackPressed");
        Intent i = new Intent();
        i.putExtra(EXTRA_AUTOPLAY, mVideoPlayer.isPlaying());
        i.putExtra(EXTRA_START_POSITION, mVideoPlayer.getCurrentPosition());
        setResult(RESULT_OK, i);
        super.onBackPressed(); 
    }