Fixed verified badges

Refactor more underscores into this->
This commit is contained in:
Rasmus Karlsson
2017-06-13 22:03:29 +02:00
parent 59d383c161
commit e7282b5097
8 changed files with 64 additions and 35 deletions
+14 -15
View File
@@ -21,67 +21,66 @@ namespace chatterino {
namespace messages {
Message::Message(const QString &text)
: _text(text)
, _words()
: text(text)
{
_words.push_back(
this->words.push_back(
Word(text, Word::Text, ColorScheme::getInstance().SystemMessageColor, text, QString()));
}
Message::Message(const QString &text, const std::vector<Word> &words)
: _text(text)
, _words(words)
: text(text)
, words(words)
{
}
bool Message::getCanHighlightTab() const
{
return _highlightTab;
return this->highlightTab;
}
const QString &Message::getTimeoutUser() const
{
return _timeoutUser;
return this->timeoutUser;
}
int Message::getTimeoutCount() const
{
return _timeoutCount;
return this->timeoutCount;
}
const QString &Message::getUserName() const
{
return _userName;
return this->userName;
}
const QString &Message::getDisplayName() const
{
return _displayName;
return this->displayName;
}
const QString &Message::getContent() const
{
return _content;
return this->content;
}
const std::chrono::time_point<std::chrono::system_clock> &Message::getParseTime() const
{
return _parseTime;
return this->parseTime;
}
std::vector<Word> &Message::getWords()
{
return _words;
return this->words;
}
bool Message::isDisabled() const
{
return _isDisabled;
return this->disabled;
}
const QString &Message::getId() const
{
return _id;
return this->id;
}
} // namespace messages
+11 -11
View File
@@ -37,7 +37,7 @@ public:
bool isDisabled() const;
const QString &getId() const;
const QString _text;
const QString text;
private:
static LazyLoadedImage *badgeStaff;
@@ -50,18 +50,18 @@ private:
static QRegularExpression *cheerRegex;
bool _highlightTab = false;
QString _timeoutUser = "";
int _timeoutCount = 0;
bool _isDisabled = false;
std::chrono::time_point<std::chrono::system_clock> _parseTime;
bool highlightTab = false;
QString timeoutUser = "";
int timeoutCount = 0;
bool disabled = false;
std::chrono::time_point<std::chrono::system_clock> parseTime;
QString _userName = "";
QString _displayName = "";
QString _content;
QString _id = "";
QString userName = "";
QString displayName = "";
QString content;
QString id = "";
std::vector<Word> _words;
std::vector<Word> words;
};
} // namespace messages
+8 -7
View File
@@ -44,17 +44,18 @@ public:
BadgePremium = (1 << 20),
BadgeChatterino = (1 << 21),
BadgeCheer = (1 << 22),
BadgeVerified = (1 << 23),
Badges = BadgeStaff | BadgeAdmin | BadgeGlobalMod | BadgeModerator | BadgeTurbo |
BadgeBroadcaster | BadgePremium | BadgeChatterino | BadgeCheer,
BadgeBroadcaster | BadgePremium | BadgeChatterino | BadgeCheer | BadgeVerified,
Username = (1 << 23),
BitsAmount = (1 << 24),
Username = (1 << 24),
BitsAmount = (1 << 25),
ButtonBan = (1 << 25),
ButtonTimeout = (1 << 26),
ButtonBan = (1 << 26),
ButtonTimeout = (1 << 27),
EmojiImage = (1 << 27),
EmojiText = (1 << 28),
EmojiImage = (1 << 28),
EmojiText = (1 << 29),
Default = TimestampNoSeconds | Badges | Username | BitsStatic | FfzEmoteImage |
BttvEmoteImage | BttvGifEmoteImage | TwitchEmoteImage | BitsAmount | Text |