QT模态对话框
来源:互联网 发布:proteus单片机仿真使用 编辑:程序博客网 时间:2024/06/05 03:03
- MyQDialogSubclass dialog;
- // Various bits of initialization
- if (dialog.exec() == QDialog::Accept) { // HERE!!!
- // Set new values or do extra work
- // based on results.
- }
- class MyDialog : public QDialog
- {
- public:
- QString name;
- };
- // ....
- MyDialog d;
- if(d.exec() == QDialog::Accept) {
- QString name = d.name;
- // do something with name...
- }
- QDialog::show(): 非模态
- QDialog::exec(): 模态
- QDialog::open(): 窗口模态
- if(!messageBox) {
- messageBox = new QMessageBox("SDI",
- "The document has been modified. \n"
- "Do you want to save your changes?",
- QMessageBox::Warning,
- QMessageBox::Yes | QMessageBox::Default,
- QMessageBox::No,
- QMessageBox::Cancel | QMessageBox::Escape,
- this);
- connect(messageBox, SIGNAL(finished(int)), SLOT(handleDialogClose(int)));
- }
- messageBox->open();
0 0
- QT 模态对话框
- QT模态对话框
- QT模态对话框及非模态对话框
- QT 模态对话框和非模态对话框
- QT 模态对话框和非模态对话框
- QT模态对话框及非模态对话框
- Qt - 模态对话框与非模态对话框
- QT模态对话框及非模态对话框
- QT模态对话框和非模态对话框
- QT模态对话框及非模态对话框
- Qt模态对话框和非模态对话框
- Qt 模态对话框 非模态对话框
- QT模态对话框与非模态对话框
- QT模态对话框及非模态对话框
- QT模态对话框用法
- QT new模态对话框
- Qt的模态对话框和非模态对话框
- QT的模态对话框与非模态对话框用法
- 2.17 数组循环移位
- cocoapods应用第一部分-xcode创建.framework相关
- Emgucv 直方图相关,以后整理
- fatal error C1020: 意外的 #endif
- Objective-C 苹果开发文档 10 Conventions
- QT模态对话框
- 九度oj 1140
- Eclipse提示Found 3 versions of android-support-v4.jar in the dependency list解决方法
- Measure(0,0)到底发生了什么
- CI中奇葩而有趣的坑
- ConcurrentHashMap源码-转载
- Python os.path 模块介绍
- iOS中Block介绍(一)基础
- String.intern()-字符串常量池