1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

feat(widget): Disable sound notification for busy status

Fix #2893.

BREAKING CHANGE: Disabling notification sound for `busy` status.
This commit is contained in:
Diadlo 2016-05-12 00:44:52 +03:00
parent 3c21b7e151
commit e7785ab4c2
No known key found for this signature in database
GPG Key ID: 5AF9F2E29107C727

View File

@ -1294,7 +1294,9 @@ bool Widget::newMessageAlert(QWidget* currentWindow, bool isActive, bool sound,
currentWindow->activateWindow(); currentWindow->activateWindow();
} }
if (Settings::getInstance().getNotifySound() && sound) bool isBusy = Nexus::getCore()->getStatus() == Status::Busy;
if (Settings::getInstance().getNotifySound() && sound && !isBusy)
Audio::getInstance().playMono16Sound(QStringLiteral(":/audio/notification.pcm")); Audio::getInstance().playMono16Sound(QStringLiteral(":/audio/notification.pcm"));
} }