Skip to content Skip to sidebar Skip to footer

How To Do Something Like Drop Down Navigation In Android (since It Looks Like It Has Become Deprecated?)

Edit: I also asked a related question here: Android: How can I navigate from one 'detail' to another 'detail', while having the 'Up' button go back to the 'Master' list? How do I

Solution 1:

With the API 21 the method setNavigationMode(ActionBar.NAVIGATION_MODE_LIST) is deprecated.

The best way to work with a spinner is to use a Toolbar like this:

<android.support.v7.widget.Toolbar
    android:id="@+id/toolbar_actionbar"
    android:layout_height="?attr/actionBarSize"
    android:layout_width="match_parent"
    android:background="?attr/colorPrimary">

<Spinner
        android:id="@+id/spinner_toolbar"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content" />

You can find an example in the Google IO 2014

Post a Comment for "How To Do Something Like Drop Down Navigation In Android (since It Looks Like It Has Become Deprecated?)"