DialogProperties


Properties used to customize the behavior of a Dialog.

Summary

Public constructors

DialogProperties(
    dismissOnBackPress: Boolean,
    dismissOnClickOutside: Boolean,
    usePlatformDefaultWidth: Boolean
)
Cmn
android
DialogProperties(
    dismissOnBackPress: Boolean,
    dismissOnClickOutside: Boolean,
    securePolicy: SecureFlagPolicy,
    usePlatformDefaultWidth: Boolean,
    decorFitsSystemWindows: Boolean
)
android

Public functions

open operator Boolean
equals(other: Any?)
android
open Int
android

Public properties

Boolean

Sets WindowCompat.setDecorFitsSystemWindows value.

android
Boolean

whether the popup can be dismissed by pressing the back or escape buttons on Android or the escape key on desktop.

Cmn
android
Boolean

whether the dialog can be dismissed by clicking outside the dialog's bounds.

Cmn
android
SecureFlagPolicy

Policy for setting WindowManager.LayoutParams.FLAG_SECURE on the dialog's window.

android
Boolean

Whether the width of the dialog's content should be limited to the platform default, which is smaller than the screen width.

Cmn
android

Public constructors

DialogProperties

DialogProperties(
    dismissOnBackPress: Boolean = true,
    dismissOnClickOutside: Boolean = true,
    usePlatformDefaultWidth: Boolean = true
)

DialogProperties

DialogProperties(
    dismissOnBackPress: Boolean = true,
    dismissOnClickOutside: Boolean = true,
    securePolicy: SecureFlagPolicy = SecureFlagPolicy.Inherit,
    usePlatformDefaultWidth: Boolean = true,
    decorFitsSystemWindows: Boolean = true
)

Public functions

equals

open operator fun equals(other: Any?): Boolean

hashCode

open fun hashCode(): Int

Public properties

decorFitsSystemWindows

val decorFitsSystemWindowsBoolean

Sets WindowCompat.setDecorFitsSystemWindows value. Set to false to use WindowInsets. If false, the soft input mode will be changed to WindowManager.LayoutParams.SOFT_INPUT_ADJUST_RESIZE and android:windowIsFloating is set to false when decorFitsSystemWindows is false. When targetSdk>= Build.VERSION_CODES.VANILLA_ICE_CREAM, decorFitsSystemWindows can only be false and this property doesn't have any effect.

dismissOnBackPress

val dismissOnBackPressBoolean

whether the popup can be dismissed by pressing the back or escape buttons on Android or the escape key on desktop. If true, pressing the back button will call onDismissRequest.

dismissOnClickOutside

val dismissOnClickOutsideBoolean

whether the dialog can be dismissed by clicking outside the dialog's bounds. If true, clicking outside the dialog will call onDismissRequest.

securePolicy

val securePolicySecureFlagPolicy

Policy for setting WindowManager.LayoutParams.FLAG_SECURE on the dialog's window.

usePlatformDefaultWidth

val usePlatformDefaultWidthBoolean

Whether the width of the dialog's content should be limited to the platform default, which is smaller than the screen width. Might be used only as named argument.