diff options
| author | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2018-07-08 15:38:38 +0000 |
|---|---|---|
| committer | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2018-07-08 15:38:38 +0000 |
| commit | 5bb83a0078a5182a51e3a7764b30fb363096286a (patch) | |
| tree | ba5c0c490a1d422a302342c34fe6757defb07359 /src/plugins/General | |
| parent | a64bdac272a1f37474576b33a7d72988e3efe80d (diff) | |
| download | qmmp-5bb83a0078a5182a51e3a7764b30fb363096286a.tar.gz qmmp-5bb83a0078a5182a51e3a7764b30fb363096286a.tar.bz2 qmmp-5bb83a0078a5182a51e3a7764b30fb363096286a.zip | |
disable global shortcuts while configuration
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@8120 90c681e8-e032-0410-971d-27865f9a5e38
Diffstat (limited to 'src/plugins/General')
| -rw-r--r-- | src/plugins/General/hotkey/hotkeyfactory.cpp | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/plugins/General/hotkey/hotkeyfactory.cpp b/src/plugins/General/hotkey/hotkeyfactory.cpp index 7c0c176de..72c3ed9ab 100644 --- a/src/plugins/General/hotkey/hotkeyfactory.cpp +++ b/src/plugins/General/hotkey/hotkeyfactory.cpp @@ -1,5 +1,5 @@ /*************************************************************************** - * Copyright (C) 2009-2012 by Ilya Kotov * + * Copyright (C) 2009-2018 by Ilya Kotov * * forkotov02@ya.ru * * * * This program is free software; you can redistribute it and/or modify * @@ -18,9 +18,9 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * ***************************************************************************/ - #include <QMessageBox> #include <qmmp/qmmp.h> +#include <qmmpui/general.h> #include "settingsdialog.h" #include "hotkeymanager.h" #include "hotkeyfactory.h" @@ -43,7 +43,13 @@ QObject *HotkeyFactory::create(QObject *parent) QDialog *HotkeyFactory::createConfigDialog(QWidget *parent) { - return new SettingsDialog(parent); + SettingsDialog *dialog = new SettingsDialog(parent); + if(General::isEnabled(this)) + { + General::setEnabled(this, false); + connect(dialog, &QDialog::finished, [this] { General::setEnabled(this); }); + } + return dialog; } void HotkeyFactory::showAbout(QWidget *parent) |
