I have searched on this. However not a single solution worked.
PopupWindow is set, the only thing I would love to happen is when I click outside the popup it should get dismiss or cancel.
I have searched on this. However not a single solution worked.
PopupWindow is set, the only thing I would love to happen is when I click outside the popup it should get dismiss or cancel.
You should add this function with pop up setOutsideTouchable
call's parameter to true:
pw = new PopupWindow(getApplicationContext());
pw.setOutsideTouchable(true);
hopefully it will serve your purpose
popupWindow.setOutsideTouchable(true);
popupWindow.setBackgroundDrawable(getResources().getDrawable(R.id.something));