feat: seperate watchstreak highlights from sub highlights (#6571)
Co-authored-by: pajlada <rasmus.karlsson@pajlada.com>
This commit is contained in:
@@ -396,6 +396,12 @@ void MessageLayout::updateBuffer(QPixmap *buffer,
|
||||
backgroundColor,
|
||||
*ctx.colorProvider.color(ColorType::FirstMessageHighlight));
|
||||
}
|
||||
else if (this->message_->flags.has(MessageFlag::WatchStreak) &&
|
||||
ctx.preferences.enableWatchStreakHighlight)
|
||||
{
|
||||
backgroundColor = blendColors(
|
||||
backgroundColor, *ctx.colorProvider.color(ColorType::WatchStreak));
|
||||
}
|
||||
else if ((this->message_->flags.has(MessageFlag::Highlighted) ||
|
||||
this->message_->flags.has(MessageFlag::HighlightedWhisper)) &&
|
||||
!this->flags.has(MessageLayoutFlag::IgnoreHighlights))
|
||||
|
||||
@@ -70,6 +70,12 @@ void MessagePreferences::connectSettings(Settings *settings,
|
||||
},
|
||||
holder);
|
||||
|
||||
settings->enableWatchStreakHighlight.connect(
|
||||
[this](const auto &newValue) {
|
||||
this->enableWatchStreakHighlight = newValue;
|
||||
},
|
||||
holder);
|
||||
|
||||
settings->enableAutomodHighlight.connect(
|
||||
[this](const auto &newValue) {
|
||||
this->enableAutomodHighlight = newValue;
|
||||
|
||||
@@ -50,6 +50,7 @@ struct MessagePreferences {
|
||||
bool enableElevatedMessageHighlight{};
|
||||
bool enableFirstMessageHighlight{};
|
||||
bool enableSubHighlight{};
|
||||
bool enableWatchStreakHighlight{};
|
||||
bool enableAutomodHighlight{};
|
||||
|
||||
bool alternateMessages{};
|
||||
|
||||
Reference in New Issue
Block a user