When there is a button at the bottom of the screen and clicking on it triggers a Popup, the Popup is not fully displayed. In some extreme cases, the Popup is even invisible. I have confirmed that this issue is caused by setting the Popup height to WRAP_CONTENT.
when I specified the exact height for the Popup, the issue was resolved. (I manually measured the height of each item in the RecyclerView).
popup.width = fixedWidth
popup.height = **measureHeightOfChildrenCompat(maxHeight)** + context.dip(4) // Doesn't work on API 21 without this.
popup.showAsDropDown(anchor, 0, 0, gravity)
When there is a button at the bottom of the screen and clicking on it triggers a Popup, the Popup is not fully displayed. In some extreme cases, the Popup is even invisible. I have confirmed that this issue is caused by setting the Popup height to WRAP_CONTENT.
when I specified the exact height for the Popup, the issue was resolved. (I manually measured the height of each item in the RecyclerView).