belongs to Maven artifact com.android.support:support-fragment:28.0.0-alpha1
DialogFragment
public
class
DialogFragment
extends Fragment
implements
DialogInterface.OnCancelListener,
DialogInterface.OnDismissListener
java.lang.Object | ||
↳ | android.support.v4.app.Fragment | |
↳ | android.support.v4.app.DialogFragment |
![]() |
![]() |
Static library support version of the framework's DialogFragment
.
Used to write apps that run on platforms prior to Android 3.0. When running
on Android 3.0 or above, this implementation is still used; it does not try
to switch to the framework's implementation. See the framework SDK
documentation for a class overview.
Summary
Constants | |
---|---|
int |
STYLE_NORMAL
Style for |
int |
STYLE_NO_FRAME
Style for |
int |
STYLE_NO_INPUT
Style for |
int |
STYLE_NO_TITLE
Style for |
Public constructors | |
---|---|
DialogFragment()
|
Public methods | |
---|---|
void
|
dismiss()
Dismiss the fragment and its dialog. |
void
|
dismissAllowingStateLoss()
Version of |
Dialog
|
getDialog()
|
boolean
|
getShowsDialog()
Return the current value of |
int
|
getTheme()
|
boolean
|
isCancelable()
Return the current value of |
void
|
onActivityCreated(Bundle savedInstanceState)
Called when the fragment's activity has been created and this fragment's view hierarchy instantiated. |
void
|
onAttach(Context context)
Called when a fragment is first attached to its context. |
void
|
onCancel(DialogInterface dialog)
|
void
|
onCreate(Bundle savedInstanceState)
Called to do initial creation of a fragment. |
Dialog
|
onCreateDialog(Bundle savedInstanceState)
Override to build your own custom Dialog container. |
void
|
onDestroyView()
Remove dialog. |
void
|
onDetach()
Called when the fragment is no longer attached to its activity. |
void
|
onDismiss(DialogInterface dialog)
|
LayoutInflater
|
onGetLayoutInflater(Bundle savedInstanceState)
Returns the LayoutInflater used to inflate Views of this Fragment. |
void
|
onSaveInstanceState(Bundle outState)
Called to ask the fragment to save its current dynamic state, so it can later be reconstructed in a new instance of its process is restarted. |
void
|
onStart()
Called when the Fragment is visible to the user. |
void
|
onStop()
Called when the Fragment is no longer started. |
void
|
setCancelable(boolean cancelable)
Control whether the shown Dialog is cancelable. |
void
|
setShowsDialog(boolean showsDialog)
Controls whether this fragment should be shown in a dialog. |
void
|
setStyle(int style, int theme)
Call to customize the basic appearance and behavior of the fragment's dialog. |
int
|
show(FragmentTransaction transaction, String tag)
Display the dialog, adding the fragment using an existing transaction
and then |
void
|
show(FragmentManager manager, String tag)
Display the dialog, adding the fragment to the given FragmentManager. |
void
|
showNow(FragmentManager manager, String tag)
Display the dialog, immediately adding the fragment to the given FragmentManager. |
Inherited methods | |
---|---|
![]()
android.support.v4.app.Fragment
|