在AndroidManifest.xml中
<activity
android:name=".main.tab1.VlcPlayerActivity"
android:configChanges="orientation|screenSize"
android:hardwareAccelerated="true" />
<activity
在VlcPlayerActivity中
if (mIsFullScreen) {
getWindow().addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_SENSOR_LANDSCAPE);
llBottom.setVisibility(View.GONE);
} else {
getWindow().clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);
llBottom.setVisibility(View.VISIBLE);
}