fix: only hide messages from restricted users, not all suspicious users (#6049)
it's probably best to leave this setting solo'd out as restricted users so monitored users can get their own behaviour in their own setting later
This commit is contained in:
+1
-1
@@ -18,7 +18,7 @@
|
|||||||
- Minor: Overlay windows now inherit the global zoom level and can be zoomed independently. (#6016)
|
- Minor: Overlay windows now inherit the global zoom level and can be zoomed independently. (#6016)
|
||||||
- Minor: The `/watching` channel is now supported on all platforms. (#6031, #6043)
|
- Minor: The `/watching` channel is now supported on all platforms. (#6031, #6043)
|
||||||
- Minor: The font weight of chat messages can now be changed. (#6037)
|
- Minor: The font weight of chat messages can now be changed. (#6037)
|
||||||
- Minor: Messages from suspicious users can now be hidden when in streamer mode. This is enabled by default. (#6042)
|
- Minor: Messages from restricted users can now be hidden when in streamer mode. This is enabled by default. (#6042, #6049)
|
||||||
- Bugfix: Fixed a potential way to escape the Lua Plugin sandbox. (#5846)
|
- Bugfix: Fixed a potential way to escape the Lua Plugin sandbox. (#5846)
|
||||||
- Bugfix: Fixed a crash relating to Lua HTTP. (#5800)
|
- Bugfix: Fixed a crash relating to Lua HTTP. (#5800)
|
||||||
- Bugfix: Fixed a crash that could occur on Linux and macOS when clicking "Install" from the update prompt. (#5818)
|
- Bugfix: Fixed a crash that could occur on Linux and macOS when clicking "Install" from the update prompt. (#5818)
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ public:
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool shouldHideSuspiciousUsers() const override
|
bool shouldHideRestrictedUsers() const override
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -166,13 +166,12 @@ void MessageLayout::actuallyLayout(const MessageLayoutContext &ctx)
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this->message_->flags.hasAny(MessageFlag::RestrictedMessage,
|
if (this->message_->flags.has(MessageFlag::RestrictedMessage))
|
||||||
MessageFlag::MonitoredMessage))
|
|
||||||
{
|
{
|
||||||
if (getApp()->getStreamerMode()->shouldHideSuspiciousUsers())
|
if (getApp()->getStreamerMode()->shouldHideRestrictedUsers())
|
||||||
{
|
{
|
||||||
// Message is being hidden because the source is a
|
// Message is being hidden because the source is a
|
||||||
// restricted or monitored user
|
// restricted user
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -362,8 +362,8 @@ public:
|
|||||||
"/streamerMode/hideViewerCountAndDuration", false};
|
"/streamerMode/hideViewerCountAndDuration", false};
|
||||||
BoolSetting streamerModeHideModActions = {"/streamerMode/hideModActions",
|
BoolSetting streamerModeHideModActions = {"/streamerMode/hideModActions",
|
||||||
true};
|
true};
|
||||||
BoolSetting streamerModeHideSuspiciousUsers = {
|
BoolSetting streamerModeHideRestrictedUsers = {
|
||||||
"/streamerMode/hideSuspiciousUsers",
|
"/streamerMode/hideRestrictedUsers",
|
||||||
true,
|
true,
|
||||||
};
|
};
|
||||||
BoolSetting streamerModeMuteMentions = {"/streamerMode/muteMentions", true};
|
BoolSetting streamerModeMuteMentions = {"/streamerMode/muteMentions", true};
|
||||||
|
|||||||
@@ -207,9 +207,9 @@ bool StreamerMode::shouldHideModActions() const
|
|||||||
return getSettings()->streamerModeHideModActions && this->isEnabled();
|
return getSettings()->streamerModeHideModActions && this->isEnabled();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool StreamerMode::shouldHideSuspiciousUsers() const
|
bool StreamerMode::shouldHideRestrictedUsers() const
|
||||||
{
|
{
|
||||||
return getSettings()->streamerModeHideSuspiciousUsers && this->isEnabled();
|
return getSettings()->streamerModeHideRestrictedUsers && this->isEnabled();
|
||||||
}
|
}
|
||||||
|
|
||||||
void StreamerMode::start()
|
void StreamerMode::start()
|
||||||
|
|||||||
@@ -23,8 +23,8 @@ public:
|
|||||||
/// Returns true if streamer mode is enabled & the settings to hide mod actions is enabled
|
/// Returns true if streamer mode is enabled & the settings to hide mod actions is enabled
|
||||||
[[nodiscard]] virtual bool shouldHideModActions() const = 0;
|
[[nodiscard]] virtual bool shouldHideModActions() const = 0;
|
||||||
|
|
||||||
/// Returns true if streamer mode is enabled & the settings to hide messages from suspicious users is enabled
|
/// Returns true if streamer mode is enabled & the settings to hide messages from restricted users is enabled
|
||||||
[[nodiscard]] virtual bool shouldHideSuspiciousUsers() const = 0;
|
[[nodiscard]] virtual bool shouldHideRestrictedUsers() const = 0;
|
||||||
|
|
||||||
virtual void start() = 0;
|
virtual void start() = 0;
|
||||||
|
|
||||||
@@ -46,7 +46,7 @@ public:
|
|||||||
bool isEnabled() const override;
|
bool isEnabled() const override;
|
||||||
|
|
||||||
bool shouldHideModActions() const override;
|
bool shouldHideModActions() const override;
|
||||||
bool shouldHideSuspiciousUsers() const override;
|
bool shouldHideRestrictedUsers() const override;
|
||||||
|
|
||||||
void start() override;
|
void start() override;
|
||||||
|
|
||||||
|
|||||||
@@ -148,7 +148,7 @@ WindowManager::WindowManager(const Paths &paths, Settings &settings,
|
|||||||
this->forceLayoutChannelViewsListener.add(
|
this->forceLayoutChannelViewsListener.add(
|
||||||
settings.streamerModeHideModActions);
|
settings.streamerModeHideModActions);
|
||||||
this->forceLayoutChannelViewsListener.add(
|
this->forceLayoutChannelViewsListener.add(
|
||||||
settings.streamerModeHideSuspiciousUsers);
|
settings.streamerModeHideRestrictedUsers);
|
||||||
|
|
||||||
this->layoutChannelViewsListener.add(settings.timestampFormat);
|
this->layoutChannelViewsListener.add(settings.timestampFormat);
|
||||||
this->layoutChannelViewsListener.add(fonts.fontChanged);
|
this->layoutChannelViewsListener.add(fonts.fontChanged);
|
||||||
|
|||||||
@@ -733,10 +733,10 @@ void GeneralPage::initLayout(GeneralPageView &layout)
|
|||||||
"Hide moderation actions", s.streamerModeHideModActions, false,
|
"Hide moderation actions", s.streamerModeHideModActions, false,
|
||||||
"Hide bans, timeouts, and automod messages from appearing in chat.");
|
"Hide bans, timeouts, and automod messages from appearing in chat.");
|
||||||
|
|
||||||
SettingWidget::checkbox("Hide messages from suspicious users",
|
SettingWidget::checkbox("Hide messages from restricted users",
|
||||||
s.streamerModeHideSuspiciousUsers)
|
s.streamerModeHideRestrictedUsers)
|
||||||
->setTooltip("Suspicious users are users who are marked as either "
|
->setTooltip("Restricted users can be marked by you, your moderators, "
|
||||||
"restricted or monitored by you or Twitch's AutoMod")
|
"or Twitch's AutoMod")
|
||||||
->addTo(layout);
|
->addTo(layout);
|
||||||
|
|
||||||
layout.addCheckbox(
|
layout.addCheckbox(
|
||||||
|
|||||||
Reference in New Issue
Block a user