Share via


ListPopupWindow Class

Definition

A ListPopupWindow anchors itself to a host view and displays a list of choices.

[Android.Runtime.Register("android/widget/ListPopupWindow", DoNotGenerateAcw=true)]
public class ListPopupWindow : Java.Lang.Object
[<Android.Runtime.Register("android/widget/ListPopupWindow", DoNotGenerateAcw=true)>]
type ListPopupWindow = class
    inherit Object
Inheritance
ListPopupWindow
Attributes

Remarks

A ListPopupWindow anchors itself to a host view and displays a list of choices.

ListPopupWindow contains a number of tricky behaviors surrounding positioning, scrolling parents to fit the dropdown, interacting sanely with the IME if present, and others.

Java documentation for android.widget.ListPopupWindow.

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.

Constructors

ListPopupWindow(Context, IAttributeSet, Int32, Int32)

Create a new, empty popup window capable of displaying items from a ListAdapter.

ListPopupWindow(Context, IAttributeSet, Int32)

Create a new, empty popup window capable of displaying items from a ListAdapter.

ListPopupWindow(Context, IAttributeSet)

Create a new, empty popup window capable of displaying items from a ListAdapter.

ListPopupWindow(Context)

Create a new, empty popup window capable of displaying items from a ListAdapter.

ListPopupWindow(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

Fields

MatchParent

Alias for ViewGroup.LayoutParams#MATCH_PARENT.

PositionPromptAbove
Obsolete.

The provided prompt view should appear above list content.

PositionPromptBelow
Obsolete.

The provided prompt view should appear below list content.

WrapContent

Alias for ViewGroup.LayoutParams#WRAP_CONTENT.

Properties

AnchorView

Returns the view that will be used to anchor this popup. -or- Sets the popup's anchor view.

AnimationStyle

Returns the animation style that will be used when the popup window is shown or dismissed. -or- Set an animation style to use when the popup window is shown or dismissed.

Background
Class

Returns the runtime class of this Object.

(Inherited from Object)
EpicenterBounds

Returns bounds which are used as a popup's epicenter of the enter and exit transitions. -or- Specifies the anchor-relative bounds of the popup's transition epicenter.

Handle

The handle to the underlying Android instance.

(Inherited from Object)
Height

Sets the height of the popup window in pixels.

HorizontalOffset

Set the horizontal offset of this popup from its anchor view in pixels.

InputMethodMode

Return the current value in #setInputMethodMode(int). -or- Control how the popup operates with an input method: one of #INPUT_METHOD_FROM_FOCUSABLE, #INPUT_METHOD_NEEDED, or #INPUT_METHOD_NOT_NEEDED.

IsInputMethodNotNeeded
IsShowing
JniIdentityHashCode (Inherited from Object)
JniPeerMembers
ListView
Modal

Returns whether the popup window will be modal when shown. -or- Set whether this window should be modal when shown.

PeerReference (Inherited from Object)
PromptPosition

Set where the optional prompt view should appear.

SelectedItem
SelectedItemId
SelectedItemPosition
SelectedView
SoftInputMode

Returns the current value in #setSoftInputMode(int). -or- Sets the operating mode for the soft input area.

ThresholdClass

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

ThresholdType

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

VerticalOffset

Set the vertical offset of this popup from its anchor view in pixels.

Width

Sets the width of the popup window in pixels.

Methods

ClearListSelection()

Clear any current list selection.

Clone()

Creates and returns a copy of this object.

(Inherited from Object)
CreateDragToOpenListener(View)

Returns an OnTouchListener that can be added to the source view to implement drag-to-open behavior.

Dismiss()

Dismiss the popup window.

Dispose() (Inherited from Object)
Dispose(Boolean) (Inherited from Object)
Equals(Object)

Indicates whether some other object is "equal to" this one.

(Inherited from Object)
GetHashCode()

Returns a hash code value for the object.

(Inherited from Object)
JavaFinalize()

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.

(Inherited from Object)
Notify()

Wakes up a single thread that is waiting on this object's monitor.

(Inherited from Object)
NotifyAll()

Wakes up all threads that are waiting on this object's monitor.

(Inherited from Object)
OnKeyDown(Keycode, KeyEvent)

Filter key down events.

OnKeyPreIme(Keycode, KeyEvent)

Filter pre-IME key events.

OnKeyUp(Keycode, KeyEvent)

Filter key up events.

PerformItemClick(Int32)

Perform an item click operation on the specified list adapter position.

PostShow()

Post a #show() call to the UI thread.

SetAdapter(IListAdapter)

Sets the adapter that provides the data and the views to represent the data in this popup window.

SetBackgroundDrawable(Drawable)

Sets a drawable to be the background for the popup window.

SetContentWidth(Int32)

Sets the width of the popup window by the size of its content.

SetDropDownGravity(GravityFlags)

Set the gravity of the dropdown list.

SetHandle(IntPtr, JniHandleOwnership)

Sets the Handle property.

(Inherited from Object)
SetListSelector(Drawable)

Sets a drawable to use as the list item selector.

SetOnDismissListener(PopupWindow+IOnDismissListener)

Set a listener to receive a callback when the popup is dismissed.

SetOnItemClickListener(AdapterView+IOnItemClickListener)

Sets a listener to receive events when a list item is clicked.

SetOnItemSelectedListener(AdapterView+IOnItemSelectedListener)

Sets a listener to receive events when a list item is selected.

SetPromptView(View)

Set a view to act as a user prompt for this popup window.

SetSelection(Int32)

Set the selected position of the list.

SetWindowLayoutType(WindowManagerTypes)

Set the layout type for this popup window.

Show()

Show the popup list.

ToArray<T>() (Inherited from Object)
ToString()

Returns a string representation of the object.

(Inherited from Object)
UnregisterFromRuntime() (Inherited from Object)
Wait()

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>.

(Inherited from Object)
Wait(Int64, Int32)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)
Wait(Int64)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)

Events

DismissEvent
ItemClick
ItemSelected
NothingSelected

Explicit Interface Implementations

IJavaPeerable.Disposed() (Inherited from Object)
IJavaPeerable.DisposeUnlessReferenced() (Inherited from Object)
IJavaPeerable.Finalized() (Inherited from Object)
IJavaPeerable.JniManagedPeerState (Inherited from Object)
IJavaPeerable.SetJniIdentityHashCode(Int32) (Inherited from Object)
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) (Inherited from Object)
IJavaPeerable.SetPeerReference(JniObjectReference) (Inherited from Object)

Extension Methods

JavaCast<TResult>(IJavaObject)

Performs an Android runtime-checked type conversion.

JavaCast<TResult>(IJavaObject)
GetJniTypeName(IJavaPeerable)

Applies to