Added interface for highlights to Application (#3808)

This commit is contained in:
Kasia
2022-06-09 16:37:52 +02:00
committed by GitHub
parent 9219647b6a
commit 683701623a
4 changed files with 17 additions and 1 deletions
+5
View File
@@ -46,6 +46,7 @@ public:
virtual WindowManager *getWindows() = 0;
virtual Toasts *getToasts() = 0;
virtual CommandController *getCommands() = 0;
virtual HighlightController *getHighlights() = 0;
virtual NotificationController *getNotifications() = 0;
virtual TwitchIrcServer *getTwitch() = 0;
virtual ChatterinoBadges *getChatterinoBadges() = 0;
@@ -124,6 +125,10 @@ public:
{
return this->notifications;
}
HighlightController *getHighlights() override
{
return this->highlights;
}
TwitchIrcServer *getTwitch() override
{
return this->twitch;
+1 -1
View File
@@ -155,7 +155,7 @@ void SharedMessageBuilder::parseHighlights()
}
auto badges = SharedMessageBuilder::parseBadgeTag(this->tags);
auto [highlighted, highlightResult] = getApp()->highlights->check(
auto [highlighted, highlightResult] = getIApp()->getHighlights()->check(
this->args, badges, this->ircMessage->nick(), this->originalMessage_);
if (!highlighted)