Google is committed to advancing racial equity for Black communities. See how.


open class WearableNavigationDrawerView : WearableDrawerView
   ↳ android.view.View
   ↳ android.view.ViewGroup
   ↳ android.widget.FrameLayout
   ↳ androidx.wear.widget.drawer.WearableDrawerView
   ↳ androidx.wear.widget.drawer.WearableNavigationDrawerView

Ease of use class for creating a Wearable navigation drawer. This can be used with to create a drawer for users to easily navigate a wearable app.

There are two ways this information may be presented: as a single page and as multiple pages. The single page navigation drawer will display 1-7 items to the user representing different navigation verticals. If more than 7 items are provided to a single page navigation drawer, the navigation drawer will be displayed as empty. The multiple page navigation drawer will display 1 or more pages to the user, each representing different navigation verticals.

The developer may specify which style to use with the app:navigationStyle custom attribute. If not specified, singlePage will be used as the default.


Nested classes

Listener which is notified when the user selects an item.


Adapter for specifying the contents of WearableNavigationDrawer.

static Int

Multi-page navigation drawer style.

static Int

Single page navigation drawer style.

Inherited constants
Public constructors
<init>(context: Context!)

<init>(context: Context!, attrs: AttributeSet!)

<init>(context: Context!, attrs: AttributeSet!, defStyleAttr: Int)

<init>(context: Context!, attrs: AttributeSet!, defStyleAttr: Int, defStyleRes: Int)

Public methods
open Unit

Add an OnItemSelectedListener that will be notified when the user selects an item.

open Boolean

open Int

Returns the style this drawer is using, either SINGLE_PAGE or MULTI_PAGE.

open Unit

open Unit

open Boolean

open Unit

Remove an OnItemSelectedListener.

open Unit

Set a WearableNavigationDrawerAdapter that will supply data for this drawer.

open Unit
setCurrentItem(index: Int, smoothScrollTo: Boolean)

Changes which index is selected.

Inherited functions