如何在 android 中的布局底部显示弹出窗口 window 并且还应该能够访问其他视图

How to show popup window at bottom of the layout in android and aslo should able to access other views

在 activity 中,如果我单击列表视图项,我将在列表视图下方显示警告对话框.... 即使在弹出窗口 window 之后,我仍然能够滚动列表视图..

您可以将您的视图放在 window 管理器中。将显示警报视图,同时您也可以访问您的列表视图。

WindowManager windowManager = (WindowManager) context.getSystemService(Context.WINDOW_SERVICE);
WindowManager.LayoutParams params = new WindowManager.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT,
                    ViewGroup.LayoutParams.MATCH_PARENT,
                    WindowManager.LayoutParams.TYPE_PHONE,
                    WindowManager.LayoutParams.FLAG_TURN_SCREEN_ON,
                    PixelFormat.TRANSLUCENT);
params.gravity = Gravity.CENTER_HORIZONTAL | Gravity.BOTTOM;

windowManager.addView(yourPopupView, params);