@Override
 protected void onStop() {
   super.onStop();
   if (player != null) {
     player.release();
     player = null;
   }
   videoRenderer = null;
   shutterView.setVisibility(View.VISIBLE);
 }
 @Override
 public void onVisibleBehindCanceled() {
   super.onVisibleBehindCanceled();
   if (player != null) {
     player.release();
     player = null;
   }
   videoRenderer = null;
   shutterView.setVisibility(View.VISIBLE);
 }
Beispiel #3
0
  public void release() {
    if (builderCallback != null) {
      builderCallback.cancel();
      builderCallback = null;
    }

    rendererBuildingState = RenderBuildingState.IDLE;
    surface = null;
    player.release();
  }
 @Override
 public void onPause() {
   super.onPause();
   if (mPlayer != null) {
     mPlayer.stop();
     mPlayerPosition = mPlayer.getCurrentPosition();
     mPlayer.release();
     mPlayer = null;
   }
   mCallback = null;
   mVideoRenderer = null;
   mShutter.setVisibility(View.VISIBLE);
 }
 @Override
 protected void onStop() {
   super.onStop();
   mExoPlayer.release();
   timer.cancel();
 }
Beispiel #6
0
 public void release() {
   rendererBuilder.cancel();
   rendererBuildingState = RENDERER_BUILDING_STATE_IDLE;
   surface = null;
   player.release();
 }