次の方法で共有


DialogFragment.Show Method

Definition

Overloads

Show(FragmentManager, String)

Display the dialog, adding the fragment to the given FragmentManager.

Show(FragmentTransaction, String)

Display the dialog, adding the fragment using an existing transaction and then committing the transaction.

Show(FragmentManager, String)

Display the dialog, adding the fragment to the given FragmentManager.

[Android.Runtime.Register("show", "(Landroid/app/FragmentManager;Ljava/lang/String;)V", "GetShow_Landroid_app_FragmentManager_Ljava_lang_String_Handler")]
public virtual void Show (Android.App.FragmentManager? manager, string? tag);
[<Android.Runtime.Register("show", "(Landroid/app/FragmentManager;Ljava/lang/String;)V", "GetShow_Landroid_app_FragmentManager_Ljava_lang_String_Handler")>]
abstract member Show : Android.App.FragmentManager * string -> unit
override this.Show : Android.App.FragmentManager * string -> unit

Parameters

manager
FragmentManager

The FragmentManager this fragment will be added to.

tag
String

The tag for this fragment, as per FragmentTransaction#add(Fragment, String) FragmentTransaction.add.

Attributes

Remarks

Display the dialog, adding the fragment to the given FragmentManager. This is a convenience for explicitly creating a transaction, adding the fragment to it with the given tag, and committing it. This does <em>not</em> add the transaction to the back stack. When the fragment is dismissed, a new transaction will be executed to remove it from the activity.

Java documentation for android.app.DialogFragment.show(android.app.FragmentManager, java.lang.String).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Show(FragmentTransaction, String)

Display the dialog, adding the fragment using an existing transaction and then committing the transaction.

[Android.Runtime.Register("show", "(Landroid/app/FragmentTransaction;Ljava/lang/String;)I", "GetShow_Landroid_app_FragmentTransaction_Ljava_lang_String_Handler")]
public virtual int Show (Android.App.FragmentTransaction? transaction, string? tag);
[<Android.Runtime.Register("show", "(Landroid/app/FragmentTransaction;Ljava/lang/String;)I", "GetShow_Landroid_app_FragmentTransaction_Ljava_lang_String_Handler")>]
abstract member Show : Android.App.FragmentTransaction * string -> int
override this.Show : Android.App.FragmentTransaction * string -> int

Parameters

transaction
FragmentTransaction

An existing transaction in which to add the fragment.

tag
String

The tag for this fragment, as per FragmentTransaction#add(Fragment, String) FragmentTransaction.add.

Returns

Returns the identifier of the committed transaction, as per FragmentTransaction#commit() FragmentTransaction.commit().

Attributes

Remarks

Display the dialog, adding the fragment using an existing transaction and then committing the transaction.

Java documentation for android.app.DialogFragment.show(android.app.FragmentTransaction, java.lang.String).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to