feat: add sound and flash alert for automod caught messages (#5026)
Co-authored-by: Rasmus Karlsson <rasmus.karlsson@pajlada.com>
This commit is contained in:
@@ -8,6 +8,8 @@
|
||||
#include <QColor>
|
||||
#include <QUrl>
|
||||
|
||||
#include <optional>
|
||||
|
||||
namespace chatterino {
|
||||
|
||||
class Badge;
|
||||
@@ -57,6 +59,9 @@ protected:
|
||||
|
||||
// parseHighlights only updates the visual state of the message, but leaves the playing of alerts and sounds to the triggerHighlights function
|
||||
virtual void parseHighlights();
|
||||
static void triggerHighlights(const QString &channelName, bool playSound,
|
||||
const std::optional<QUrl> &customSoundUrl,
|
||||
bool windowAlert);
|
||||
|
||||
void appendChannelName();
|
||||
|
||||
@@ -72,8 +77,7 @@ protected:
|
||||
|
||||
bool highlightAlert_ = false;
|
||||
bool highlightSound_ = false;
|
||||
|
||||
QUrl highlightSoundUrl_;
|
||||
std::optional<QUrl> highlightSoundCustomUrl_{};
|
||||
};
|
||||
|
||||
} // namespace chatterino
|
||||
|
||||
Reference in New Issue
Block a user