Skip to content

Commit

Permalink
Update FullScreenVideoWebView.java
Browse files Browse the repository at this point in the history
  • Loading branch information
RachitShah02 authored Oct 28, 2019
1 parent 4726847 commit 5e38d96
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public void onHideCustomView() {
((FrameLayout) ((Activity) context).getWindow().getDecorView()).removeView(this.mCustomView);
this.mCustomView = null;
((Activity) context).getWindow().getDecorView().setSystemUiVisibility(this.mOriginalSystemUiVisibility);
((Activity) context).setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);
((Activity) context).setRequestedOrientation(orientation);
this.mCustomViewCallback.onCustomViewHidden();
this.mCustomViewCallback = null;
}
Expand All @@ -66,10 +66,10 @@ public void onShowCustomView(View paramView, CustomViewCallback paramCustomViewC
}
this.mCustomView = paramView;
this.mOriginalSystemUiVisibility = ((Activity) context).getWindow().getDecorView().getSystemUiVisibility();
((Activity) context).setRequestedOrientation(orientation);
((Activity) context).setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE);
this.mCustomViewCallback = paramCustomViewCallback;
((FrameLayout) ((Activity) context).getWindow().getDecorView()).addView(this.mCustomView, new FrameLayout.LayoutParams(-1, -1));
((Activity) context).getWindow().getDecorView().setSystemUiVisibility(3846);
((Activity) context).getWindow().getDecorView().setSystemUiVisibility(3846 | View.SYSTEM_UI_FLAG_LAYOUT_STABLE);
}
}
}

0 comments on commit 5e38d96

Please sign in to comment.