mirror of
https://github.com/Docile-Alligator/Infinity-For-Reddit.git
synced 2026-02-04 23:25:29 +00:00
Fix the navigation drawer being drawn under the system bar on Android 15+.
This commit is contained in:
@ -270,6 +270,8 @@ public class MainActivity extends BaseActivity implements SortTypeSelectionCallb
|
||||
| WindowInsetsCompat.Type.displayCutout()
|
||||
);
|
||||
|
||||
binding.navigationViewMainActivity.setPadding(allInsets.left, 0, 0, 0);
|
||||
|
||||
if (navigationWrapper.navigationRailView == null) {
|
||||
if (navigationWrapper.bottomAppBar.getVisibility() != View.VISIBLE) {
|
||||
setMargins(navigationWrapper.floatingActionButton,
|
||||
@ -328,6 +330,8 @@ public class MainActivity extends BaseActivity implements SortTypeSelectionCallb
|
||||
allInsets.right,
|
||||
BaseActivity.IGNORE_MARGIN);
|
||||
|
||||
binding.navDrawerRecyclerViewMainActivity.setPadding(0, 0, 0, allInsets.bottom);
|
||||
|
||||
return WindowInsetsCompat.CONSUMED;
|
||||
}
|
||||
});
|
||||
|
||||
@ -14,10 +14,10 @@
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
<com.google.android.material.navigation.NavigationView
|
||||
android:id="@+id/navigation_view_main_activity"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="start"
|
||||
android:id="@+id/navigation_view_main_activity">
|
||||
android:layout_gravity="start">
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
android:id="@+id/nav_drawer_recycler_view_main_activity"
|
||||
|
||||
Reference in New Issue
Block a user