PreferenceDialogFragmentCompat
abstract class PreferenceDialogFragmentCompat : DialogFragment, OnClickListener
kotlin.Any | |||
↳ | androidx.fragment.app.Fragment | ||
↳ | androidx.fragment.app.DialogFragment | ||
↳ | androidx.preference.PreferenceDialogFragmentCompat |
Abstract base class which presents a dialog associated with a DialogPreference
. Since the preference object may not be available during fragment re-creation, the necessary information for displaying the dialog is read once during the initial call to #onCreate(Bundle) and saved/restored in the saved instance state. Custom subclasses should also follow this pattern.
Summary
Constants | |
---|---|
static String |
Inherited constants | |
---|---|
Public constructors | |
---|---|
<init>() Abstract base class which presents a dialog associated with a |
Public methods | |
---|---|
open DialogPreference! |
Get the preference that requested this dialog. |
open Unit |
onClick(dialog: DialogInterface!, which: Int) |
open Unit | |
open Dialog |
onCreateDialog(savedInstanceState: Bundle?) |
abstract Unit |
onDialogClosed(positiveResult: Boolean) |
open Unit |
onDismiss(@NonNull dialog: DialogInterface) |
open Unit |
onSaveInstanceState(@NonNull outState: Bundle) |
Protected methods | |
---|---|
open Unit |
onBindDialogView(view: View!) Binds views in the content view of the dialog to data. |
open View! |
onCreateDialogView(context: Context!) Creates the content view for the dialog (if a custom content view is required). |
open Unit |
onPrepareDialogBuilder(builder: AlertDialog.Builder!) Prepares the dialog builder to be shown when the preference is clicked. |
Inherited functions | |
---|---|