Highlight parsing is now done after Ignores have been respected.
In the same commit, because I misunderstood the original issue, I also split out the parsing of the highlights and triggering of the highlight sounds/alerts into separate functions. Fixes #1160 I also re-enabled the "sound url changer" that was commented out in an earlier commit. Fixes #1170
This commit is contained in:
@@ -79,6 +79,7 @@ std::vector<MessagePtr> IrcMessageHandler::parsePrivMessage(
|
||||
if (!builder.isIgnored())
|
||||
{
|
||||
builtMessages.emplace_back(builder.build());
|
||||
builder.triggerHighlights();
|
||||
}
|
||||
return builtMessages;
|
||||
}
|
||||
@@ -130,6 +131,7 @@ void IrcMessageHandler::addMessage(Communi::IrcMessage *_message,
|
||||
}
|
||||
|
||||
auto msg = builder.build();
|
||||
builder.triggerHighlights();
|
||||
auto highlighted = msg->flags.has(MessageFlag::Highlighted);
|
||||
|
||||
if (!isSub)
|
||||
@@ -357,6 +359,7 @@ void IrcMessageHandler::handleWhisperMessage(Communi::IrcMessage *message)
|
||||
{
|
||||
builder->flags.set(MessageFlag::Whisper);
|
||||
MessagePtr _message = builder.build();
|
||||
builder.triggerHighlights();
|
||||
|
||||
app->twitch.server->lastUserThatWhisperedMe.set(builder.userName);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user