So basically i have a class that inherits from QMainWindow
and there's a toolbar action in my mainwindow that calls another small window where the user puts in some info, i want the mainwindow inaccessible ie you shouldn't be able to click on it or interact with it unless you finish what you're doing on that small window or you close the small window. setWindowFlags(Qt::WindowStaysOnTopHint);
only makes the small window be on top, but i can still access the MainWindow.
Looks like all i needed was the setWindowModality(Qt::ApplicationModal);
method
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.