update settingsCache

This commit is contained in:
RickyRister 2024-12-05 05:35:10 -08:00
parent e4cfe08113
commit e0cd2d435a
4 changed files with 19 additions and 0 deletions

View file

@ -245,6 +245,7 @@ SettingsCache::SettingsCache()
minPlayersForMultiColumnLayout = settings->value("interface/min_players_multicolumn", 4).toInt(); minPlayersForMultiColumnLayout = settings->value("interface/min_players_multicolumn", 4).toInt();
tapAnimation = settings->value("cards/tapanimation", true).toBool(); tapAnimation = settings->value("cards/tapanimation", true).toBool();
openDeckInNewTab = settings->value("editor/openDeckInNewTab", false).toBool(); openDeckInNewTab = settings->value("editor/openDeckInNewTab", false).toBool();
rewindBufferingMs = settings->value("replay/rewindBufferingMs", 200).toBool();
chatMention = settings->value("chat/mention", true).toBool(); chatMention = settings->value("chat/mention", true).toBool();
chatMentionCompleter = settings->value("chat/mentioncompleter", true).toBool(); chatMentionCompleter = settings->value("chat/mentioncompleter", true).toBool();
chatMentionForeground = settings->value("chat/mentionforeground", true).toBool(); chatMentionForeground = settings->value("chat/mentionforeground", true).toBool();
@ -545,6 +546,12 @@ void SettingsCache::setOpenDeckInNewTab(QT_STATE_CHANGED_T _openDeckInNewTab)
settings->setValue("editor/openDeckInNewTab", openDeckInNewTab); settings->setValue("editor/openDeckInNewTab", openDeckInNewTab);
} }
void SettingsCache::setRewindBufferingMs(int _rewindBufferingMs)
{
rewindBufferingMs = _rewindBufferingMs;
settings->setValue("replay/rewindBufferingMs", rewindBufferingMs);
}
void SettingsCache::setChatMention(QT_STATE_CHANGED_T _chatMention) void SettingsCache::setChatMention(QT_STATE_CHANGED_T _chatMention)
{ {
chatMention = static_cast<bool>(_chatMention); chatMention = static_cast<bool>(_chatMention);

View file

@ -103,6 +103,7 @@ private:
int minPlayersForMultiColumnLayout; int minPlayersForMultiColumnLayout;
bool tapAnimation; bool tapAnimation;
bool openDeckInNewTab; bool openDeckInNewTab;
int rewindBufferingMs;
bool chatMention; bool chatMention;
bool chatMentionCompleter; bool chatMentionCompleter;
QString chatMentionColor; QString chatMentionColor;
@ -312,6 +313,10 @@ public:
{ {
return openDeckInNewTab; return openDeckInNewTab;
} }
int getRewindBufferingMs() const
{
return rewindBufferingMs;
}
bool getChatMention() const bool getChatMention() const
{ {
return chatMention; return chatMention;
@ -566,6 +571,7 @@ public slots:
void setMinPlayersForMultiColumnLayout(int _minPlayersForMultiColumnLayout); void setMinPlayersForMultiColumnLayout(int _minPlayersForMultiColumnLayout);
void setTapAnimation(QT_STATE_CHANGED_T _tapAnimation); void setTapAnimation(QT_STATE_CHANGED_T _tapAnimation);
void setOpenDeckInNewTab(QT_STATE_CHANGED_T _openDeckInNewTab); void setOpenDeckInNewTab(QT_STATE_CHANGED_T _openDeckInNewTab);
void setRewindBufferingMs(int _rewindBufferingMs);
void setChatMention(QT_STATE_CHANGED_T _chatMention); void setChatMention(QT_STATE_CHANGED_T _chatMention);
void setChatMentionCompleter(QT_STATE_CHANGED_T _chatMentionCompleter); void setChatMentionCompleter(QT_STATE_CHANGED_T _chatMentionCompleter);
void setChatMentionForeground(QT_STATE_CHANGED_T _chatMentionForeground); void setChatMentionForeground(QT_STATE_CHANGED_T _chatMentionForeground);

View file

@ -166,6 +166,9 @@ void SettingsCache::setTapAnimation(QT_STATE_CHANGED_T /* _tapAnimation */)
void SettingsCache::setOpenDeckInNewTab(QT_STATE_CHANGED_T /* _openDeckInNewTab */) void SettingsCache::setOpenDeckInNewTab(QT_STATE_CHANGED_T /* _openDeckInNewTab */)
{ {
} }
void SettingsCache::setRewindBufferingMs(int /* _rewindBufferingMs */)
{
}
void SettingsCache::setChatMention(QT_STATE_CHANGED_T /* _chatMention */) void SettingsCache::setChatMention(QT_STATE_CHANGED_T /* _chatMention */)
{ {
} }

View file

@ -170,6 +170,9 @@ void SettingsCache::setTapAnimation(QT_STATE_CHANGED_T /* _tapAnimation */)
void SettingsCache::setOpenDeckInNewTab(QT_STATE_CHANGED_T /* _openDeckInNewTab */) void SettingsCache::setOpenDeckInNewTab(QT_STATE_CHANGED_T /* _openDeckInNewTab */)
{ {
} }
void SettingsCache::setRewindBufferingMs(int /* _rewindBufferingMs */)
{
}
void SettingsCache::setChatMention(QT_STATE_CHANGED_T /* _chatMention */) void SettingsCache::setChatMention(QT_STATE_CHANGED_T /* _chatMention */)
{ {
} }