aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/designer
diff options
context:
space:
mode:
authorEike Ziller <eike.ziller@qt.io>2020-06-02 09:10:40 +0200
committerEike Ziller <eike.ziller@qt.io>2020-06-02 11:44:53 +0000
commit5b364de1685e5bee5953e23da2552b5db4455a74 (patch)
tree13f505553880048143feea6678dbd09e31558599 /src/plugins/designer
parent26d46fc19dccb3b599dcd24f2a3701b7c4e25d2b (diff)
Use dialogParent() instead of mainWindow()
There are very few reasons to use mainWindow() directly. Especially for modal dialogs, using dialogParent() is important, since that guarantees the stacking order in case of other dialogs currently being open. Change-Id: I7ad2c23c5034b43195eb35cfe405932a7ea003e6 Reviewed-by: hjk <hjk@qt.io>
Diffstat (limited to 'src/plugins/designer')
-rw-r--r--src/plugins/designer/formeditorw.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/designer/formeditorw.cpp b/src/plugins/designer/formeditorw.cpp
index 2e673033ae..0076d62134 100644
--- a/src/plugins/designer/formeditorw.cpp
+++ b/src/plugins/designer/formeditorw.cpp
@@ -706,7 +706,7 @@ void FormEditorData::saveSettings(QSettings *s)
void FormEditorData::critical(const QString &errorMessage)
{
- QMessageBox::critical(ICore::mainWindow(), tr("Designer"), errorMessage);
+ QMessageBox::critical(ICore::dialogParent(), tr("Designer"), errorMessage);
}
// Apply the command shortcut to the action and connects to the command's keySequenceChanged signal