BottomSheetDialog

Base class for android.app.Dialogs styled as a bottom sheet.

Edge to edge window flags are automatically applied if the navigationBarColor is transparent or translucent and enableEdgeToEdge is true. These can be set in the theme that is passed to the constructor, or will be taken from the theme of the context (ie. your application or activity theme).

In edge to edge mode, padding will be added automatically to the top when sliding under the status bar. Padding can be applied automatically to the left, right, or bottom if any of `paddingBottomSystemWindowInsets`, `paddingLeftSystemWindowInsets`, or `paddingRightSystemWindowInsets` are set to true in the style.

For more information, see the component developer guidance and design guidelines.

Constructors

Link copied to clipboard
constructor(@NonNull context: Context)
constructor(@NonNull context: Context, @StyleRes theme: Int)

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
open fun cancel()
This function can be called from a few different use cases, including Swiping the dialog down or calling `dismiss()` from a `BottomSheetDialogFragment`, tapping outside a dialog, etc...
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun setCancelable(cancelable: Boolean)
Link copied to clipboard
Link copied to clipboard
open fun setContentView(view: View)
open fun setContentView(@LayoutRes layoutResId: Int)
open fun setContentView(view: View, params: ViewGroup.LayoutParams)
Link copied to clipboard
open fun setLightStatusBar(@NonNull view: View, isLight: Boolean)