Android.App.Dialog Class
Base class for Dialogs.

See Also: Dialog Members

Syntax

[Android.Runtime.Register("android/app/Dialog", DoNotGenerateAcw=true)]
public class Dialog : Java.Lang.Object, Android.Content.IDialogInterface, Android.Views.KeyEvent.ICallback, Android.Views.View.IOnCreateContextMenuListener, Android.Views.Window.ICallback, IDisposable

Remarks

Base class for Dialogs.

Note: Activities provide a facility to manage the creation, saving and restoring of dialogs. See Activity.OnCreateDialog(int), Activity.OnPrepareDialog(int, Android.App.Dialog), Activity.ShowDialog(int), and Activity.DismissDialog(int). If these methods are used, Dialog.OwnerActivity will return the Activity that managed this dialog.

Often you will want to have a Dialog display on top of the current input method, because there is no reason for it to accept text. You can do this by setting the Android.Views.WindowManagerLayoutParams.FLAG_ALT_FOCUSABLE_IM window flag (assuming your Dialog takes input focus, as it the default) with the following code:

java Example

 getWindow().setFlags(WindowManager.LayoutParams.FLAG_ALT_FOCUSABLE_IM,
         WindowManager.LayoutParams.FLAG_ALT_FOCUSABLE_IM);

Developer Guides

For more information about creating dialogs, read the Dialogs developer guide.

[Android Documentation]

Requirements

Namespace: Android.App
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 1