Skip to content

Instantly share code, notes, and snippets.

@redleafar
Created February 25, 2017 01:17
Show Gist options
  • Select an option

  • Save redleafar/835816f7d64b388db6c1c158f5539860 to your computer and use it in GitHub Desktop.

Select an option

Save redleafar/835816f7d64b388db6c1c158f5539860 to your computer and use it in GitHub Desktop.
Add footer to NavigationDrawer
@jiahaoliuliu

Copy link
Copy Markdown

Same comment here. If the content of the menu is shorter than the list, this will work. But when the content of the menu is longer than the list and the user has to scroll, the footer will appear overlapping on the menu

@iamspathan

Copy link
Copy Markdown

@jiahaoliuliu Same condition here

@pintuag

pintuag commented Jan 12, 2021

Copy link
Copy Markdown

facing the same issue.

@AashriyaTechnology

Copy link
Copy Markdown

facing the same issue.

@shantanu-saha-europcar

shantanu-saha-europcar commented Oct 11, 2022

Copy link
Copy Markdown

Add some fake menu to avoid menu overlap

<menu xmlns:android="http://schemas.android.com/apk/res/android">
    <group>
        <item
            android:id="@+id/nav_item_1"
            android:icon="@drawable/ic_nav_item_1"
            android:title="Nav Item 1" />
        <item
            android:id="@+id/nav_item_2"
            android:icon="@drawable/ic_nav_item_2"
            android:title="Nav Item 2" />
        <item
            android:id="@+id/nav_item_3"
            android:icon="@drawable/ic_nav_item_3"
            android:title="Nav Item 3" />
        <item
            android:id="@+id/nav_item_4"
            android:icon="@drawable/ic_nav_item_4"
            android:title="Nav Item 4" />
        <item
            android:id="@+id/footer_spacer_1"
            android:checkable="false"
            android:enabled="false"
            android:orderInCategory="200"
            android:title="" />
        <item
            android:id="@+id/footer_spacer_2"
            android:checkable="false"
            android:enabled="false"
            android:orderInCategory="200"
            android:title="" />
    </group>
</menu>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment