summaryrefslogtreecommitdiffhomepage
path: root/gui
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2015-12-06 06:20:56 +0100
committerStanislaw Halik <sthalik@misaki.pl>2015-12-06 06:20:56 +0100
commitda8ec5c60841a926874c9ef2c4fed0078d47ebc8 (patch)
treea556b0730adb9c821b998a2a744248b27e2468c4 /gui
parent2de0b6427d8d768771cf22686c1c3b65f15e2f40 (diff)
gui/settings: set parent, otherwise not modal
Diffstat (limited to 'gui')
-rw-r--r--gui/options-dialog.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/gui/options-dialog.cpp b/gui/options-dialog.cpp
index a7efdb75..e1324ccc 100644
--- a/gui/options-dialog.cpp
+++ b/gui/options-dialog.cpp
@@ -96,7 +96,7 @@ void OptionsDialog::bind_key(key_opts& kopts, QLabel* label)
kopts.button = -1;
kopts.guid = "";
kopts.keycode = "";
- QDialog d;
+ QDialog d(this);
auto l = new QHBoxLayout;
l->setMargin(0);
KeyboardListener k;
@@ -104,6 +104,7 @@ void OptionsDialog::bind_key(key_opts& kopts, QLabel* label)
d.setLayout(l);
d.setFixedSize(QSize(500, 300));
d.setWindowFlags(Qt::Dialog);
+ d.setWindowModality(Qt::ApplicationModal);
connect(&k, &KeyboardListener::key_pressed, [&] (QKeySequence s) -> void {
kopts.keycode = s.toString(QKeySequence::PortableText);
kopts.guid = "";