xml文件根布局是相对布局时,点击外部不会消失,改为线性布局则正常,为什么?(在webview中)

private void showPopWindow() {
View v = LayoutInflater.from(this).inflate(R.layout.popupwindow,null);
mPopupWindow = new PopupWindow(v, ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT,true);
mPopupWindow.setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_ADJUST_RESIZE);

    ColorDrawable cd = new ColorDrawable(0x000000);
    mPopupWindow.setBackgroundDrawable(cd);

    mPopupWindow.setFocusable(true);
    mPopupWindow.setTouchable(true);
    mPopupWindow.setOutsideTouchable(true);
    mPopupWindow.setAnimationStyle(R.style.popupAnimation);

    mPopupWindow.showAtLocation(mRootView, Gravity.BOTTOM,0,0);
    mPopupWindow.setOnDismissListener(new PopupWindow.OnDismissListener() {

        @Override
        public void onDismiss() {
            hidePrompt();
        }
    });
    setListener(v);
}