I have created a android application where I have created a popup screen. But when I am pressing the back button, popup is not getting closed.
I have tried with onBackPressed(). It is not working.
Can someone tell me what to do.
Regards,
Shankar
What you need to do is call setBackgroundDrawable on your PopupWindow after you initialize it. Something like:
myPopup.setBackgroundDrawable(new BitmapDrawable());
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With