diff --git a/CHANGELOG.md b/CHANGELOG.md index 92f0108f4..229e845f8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -30,6 +30,7 @@ - Minor: Added quotation marks in the permitted/blocked Automod messages for clarity. (#3654) - Minor: Added Quick Switcher item to open a channel in a new popup window. (#3828) - Minor: Added information about the user's operating system in the About page. (#3663) +- Minor: Added option to hide inline whispers in streamer mode (#4076) - Minor: Adjusted large stream thumbnail to 16:9 (#3655) - Minor: Prevented user from entering incorrect characters in Live Notifications channels list. (#3715, #3730) - Minor: Sorted usernames in /vips message to be case-insensitive. (#3696) diff --git a/src/controllers/commands/CommandController.cpp b/src/controllers/commands/CommandController.cpp index a8ffba1a1..8a403810b 100644 --- a/src/controllers/commands/CommandController.cpp +++ b/src/controllers/commands/CommandController.cpp @@ -26,6 +26,7 @@ #include "util/IncognitoBrowser.hpp" #include "util/Qt.hpp" #include "util/StreamLink.hpp" +#include "util/StreamerMode.hpp" #include "util/Twitch.hpp" #include "widgets/Window.hpp" #include "widgets/dialogs/ReplyThreadPopup.hpp" @@ -171,7 +172,9 @@ bool appendWhisperMessageWordsLocally(const QStringList &words) auto overrideFlags = boost::optional(messagexD->flags); overrideFlags->set(MessageFlag::DoNotLog); - if (getSettings()->inlineWhispers) + if (getSettings()->inlineWhispers && + !(getSettings()->streamerModeSuppressInlineWhispers && + isInStreamerMode())) { app->twitch->forEachChannel( [&messagexD, overrideFlags](ChannelPtr _channel) { diff --git a/src/providers/twitch/IrcMessageHandler.cpp b/src/providers/twitch/IrcMessageHandler.cpp index af39b3f47..e539cc2d6 100644 --- a/src/providers/twitch/IrcMessageHandler.cpp +++ b/src/providers/twitch/IrcMessageHandler.cpp @@ -15,6 +15,7 @@ #include "util/FormatTime.hpp" #include "util/Helpers.hpp" #include "util/IrcHelpers.hpp" +#include "util/StreamerMode.hpp" #include @@ -800,7 +801,9 @@ void IrcMessageHandler::handleWhisperMessage(Communi::IrcMessage *message) overrideFlags->set(MessageFlag::DoNotTriggerNotification); overrideFlags->set(MessageFlag::DoNotLog); - if (getSettings()->inlineWhispers) + if (getSettings()->inlineWhispers && + !(getSettings()->streamerModeSuppressInlineWhispers && + isInStreamerMode())) { getApp()->twitch->forEachChannel( [&_message, overrideFlags](ChannelPtr channel) { diff --git a/src/singletons/Settings.hpp b/src/singletons/Settings.hpp index 7eaa6b543..2970cc8fa 100644 --- a/src/singletons/Settings.hpp +++ b/src/singletons/Settings.hpp @@ -246,6 +246,8 @@ public: BoolSetting streamerModeMuteMentions = {"/streamerMode/muteMentions", true}; BoolSetting streamerModeSuppressLiveNotifications = { "/streamerMode/supressLiveNotifications", false}; + BoolSetting streamerModeSuppressInlineWhispers = { + "/streamerMode/suppressInlineWhispers", true}; /// Ignored Phrases QStringSetting ignoredPhraseReplace = {"/ignore/ignoredPhraseReplace", diff --git a/src/widgets/settingspages/GeneralPage.cpp b/src/widgets/settingspages/GeneralPage.cpp index f8dbaccf2..e3e121925 100644 --- a/src/widgets/settingspages/GeneralPage.cpp +++ b/src/widgets/settingspages/GeneralPage.cpp @@ -413,6 +413,8 @@ void GeneralPage::initLayout(GeneralPageView &layout) layout.addCheckbox("Mute mention sounds", s.streamerModeMuteMentions); layout.addCheckbox("Suppress Live Notifications", s.streamerModeSuppressLiveNotifications); + layout.addCheckbox("Suppress Inline Whispers", + s.streamerModeSuppressInlineWhispers); layout.addTitle("Link Previews"); layout.addDescription(