Reputation: 9535
I use a popupwindow in my activity that i would like to dimiss, but i see the following documentation about the dimiss() method for popup windows:
public void dismiss () Since: API Level 1
Dispose of the popup window. This method can be invoked only after showAsDropDown(android.view.View) has been executed. Failing that, calling this method will have no effect. See Also
* showAsDropDown(android.view.View)
If I don't want to show the popup with showAsDropDown how else can u remove it from the main view?
Upvotes: 0
Views: 603
Reputation: 98501
dismiss() will work as long as the PopupWindow is shown on screen.
Upvotes: 2