有时候我没可能需要在点击按钮进行一些检测,但是并不想关闭次对话框(系统默认点击任何一个按钮则关闭对话框),处理方法如下:在点击事件下添加如下代码: try { Field field = dialog.getClass() .getSuperclass().getDeclaredField( "mShowing"); field.setAccessible(true); // 将mShowing变量设为false,表示对话框已关闭 field.set(dialog, false); d
<wxPython in Action>chap 9 笔记 1. Modal Dialog(模式对话框) A modal dialog blocks other widgets from receiving user events until it is closed; in other words, it places the user in dialog mode for the duration of its existence. 模式对话框阻塞了别的窗口部件接收用户事件,直到该模式对话