aboutsummaryrefslogtreecommitdiff
path: root/src/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/General/hotkey/hotkeymanager_x11.cpp5
-rw-r--r--src/plugins/General/hotkey/settingsdialog.cpp2
2 files changed, 5 insertions, 2 deletions
diff --git a/src/plugins/General/hotkey/hotkeymanager_x11.cpp b/src/plugins/General/hotkey/hotkeymanager_x11.cpp
index 1e9f8ff22..21e3bdab8 100644
--- a/src/plugins/General/hotkey/hotkeymanager_x11.cpp
+++ b/src/plugins/General/hotkey/hotkeymanager_x11.cpp
@@ -84,7 +84,7 @@ HotkeyManager::HotkeyManager(QObject *parent) : QObject(parent)
WId rootWindow = QX11Info::appRootWindow();
QSettings settings(Qmmp::configFile(), QSettings::IniFormat); //load settings
settings.beginGroup("Hotkey");
- for (int i = Hotkey::PLAY, j = 0; i <= Hotkey::JUMP_TO_TRACK; ++i, ++j)
+ for (int i = Hotkey::PLAY, j = 0; i <= Hotkey::VOLUME_MUTE; ++i, ++j)
{
quint32 key = settings.value(QString("key_%1").arg(i), Hotkey::defaultKey(i)).toUInt();
quint32 mod = settings.value(QString("modifiers_%1").arg(i), 0).toUInt();
@@ -193,6 +193,9 @@ bool HotkeyManager::eventFilter(QObject* o, QEvent* e)
case Hotkey::JUMP_TO_TRACK:
UiHelper::instance()->jumpToTrack();
break;
+ case Hotkey::VOLUME_MUTE:
+ SoundCore::instance()->setMuted(!SoundCore::instance()->isMuted());
+ break;
}
qApp->processEvents();
diff --git a/src/plugins/General/hotkey/settingsdialog.cpp b/src/plugins/General/hotkey/settingsdialog.cpp
index 29d351cb4..abb2c6893 100644
--- a/src/plugins/General/hotkey/settingsdialog.cpp
+++ b/src/plugins/General/hotkey/settingsdialog.cpp
@@ -49,7 +49,7 @@ SettingsDialog::SettingsDialog(QWidget *parent)
QSettings settings(Qmmp::configFile(), QSettings::IniFormat);
settings.beginGroup("Hotkey");
- for (int i = Hotkey::PLAY, j = 0; i <= Hotkey::JUMP_TO_TRACK; ++i, ++j)
+ for (int i = Hotkey::PLAY, j = 0; i <= Hotkey::VOLUME_MUTE; ++i, ++j)
{
Hotkey *hotkey = new Hotkey;
hotkey->action = i;