The second Android 11 Developer Preview is now available, test it out and share your feedback.

ScaffoldState

@Model class ScaffoldState
kotlin.Any
   ↳ androidx.ui.material.ScaffoldState

State for Scaffold composable component.

Contains basic screen state, e.g. Drawer configuration.

Summary

Public constructors

<init>(drawerState: DrawerState = DrawerState.Closed, isDrawerGesturesEnabled: Boolean = true)

State for Scaffold composable component.

Properties

DrawerState

the state of the Drawer in Scaffold.

Boolean

whether or not drawer can be interacted with via gestures

Public constructors

<init>

ScaffoldState(
    drawerState: DrawerState = DrawerState.Closed,
    isDrawerGesturesEnabled: Boolean = true)

State for Scaffold composable component.

Contains basic screen state, e.g. Drawer configuration.

Parameters
drawerState: DrawerState = DrawerState.Closed the state of the Drawer in Scaffold. Change it to open/close Drawer programmatically.
isDrawerGesturesEnabled: Boolean = true whether or not drawer can be interacted with via gestures

Properties

drawerState

var drawerState: DrawerState

the state of the Drawer in Scaffold. Change it to open/close Drawer programmatically.

isDrawerGesturesEnabled

var isDrawerGesturesEnabled: Boolean

whether or not drawer can be interacted with via gestures