]> gitweb.stoutner.com Git - PrivacyBrowserAndroid.git/blobdiff - app/src/main/java/com/stoutner/privacybrowser/activities/MainWebViewActivity.java
Disable the navigation and bookmarks drawers in full screen video mode. https:/...
[PrivacyBrowserAndroid.git] / app / src / main / java / com / stoutner / privacybrowser / activities / MainWebViewActivity.java
index 26a6a403a68256af7eb0bdfac55acc56edb545ca..07126c9881fd045ea0aedc4fd826231b8a3c521d 100644 (file)
@@ -996,6 +996,9 @@ public class MainWebViewActivity extends AppCompatActivity implements CreateBook
                 // Set `rootCoordinatorLayout` to fill the entire screen.
                 rootCoordinatorLayout.setFitsSystemWindows(false);
 
+                // Disable the sliding drawers.
+                drawerLayout.setDrawerLockMode(DrawerLayout.LOCK_MODE_LOCKED_CLOSED);
+
                 // Add `view` to `fullScreenVideoFrameLayout` and display it on the screen.
                 fullScreenVideoFrameLayout.addView(view);
                 fullScreenVideoFrameLayout.setVisibility(View.VISIBLE);
@@ -1008,6 +1011,9 @@ public class MainWebViewActivity extends AppCompatActivity implements CreateBook
                 fullScreenVideoFrameLayout.removeAllViews();
                 fullScreenVideoFrameLayout.setVisibility(View.GONE);
 
+                // Enable the sliding drawers.
+                drawerLayout.setDrawerLockMode(DrawerLayout.LOCK_MODE_UNLOCKED);
+
                 // Add the translucent status flag.  This also resets `drawerLayout's` `View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN`.
                 getWindow().addFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS);