fix: don't post contents of unknown commands to chat (#6272)
This commit is contained in:
@@ -283,6 +283,21 @@ void Settings::disableSave()
|
||||
this->disableSaving = true;
|
||||
}
|
||||
|
||||
bool Settings::shouldSendHelixChat() const
|
||||
{
|
||||
switch (this->chatSendProtocol.getEnum())
|
||||
{
|
||||
case ChatSendProtocol::Helix:
|
||||
return true;
|
||||
case ChatSendProtocol::Default:
|
||||
case ChatSendProtocol::IRC:
|
||||
return false;
|
||||
default:
|
||||
assert(false && "Invalid chat protocol value");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
float Settings::getClampedUiScale() const
|
||||
{
|
||||
return std::clamp(this->uiScale.getValue(), 0.2F, 10.F);
|
||||
|
||||
@@ -145,6 +145,9 @@ public:
|
||||
|
||||
void disableSave();
|
||||
|
||||
/// Returns true if chat messages should be sent over Helix
|
||||
bool shouldSendHelixChat() const;
|
||||
|
||||
FloatSetting uiScale = {"/appearance/uiScale2", 1};
|
||||
BoolSetting windowTopMost = {"/appearance/windowAlwaysOnTop", false};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user