mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
Merge branch 'master' of https://github.com/fourtf/chatterino2
This commit is contained in:
commit
e65a5948fe
1 changed files with 10 additions and 12 deletions
|
@ -85,19 +85,17 @@ void ChatWidgetHeader::updateChannelText()
|
||||||
auto channel = this->chatWidget->getChannel();
|
auto channel = this->chatWidget->getChannel();
|
||||||
|
|
||||||
twitch::TwitchChannel *twitchChannel = dynamic_cast<twitch::TwitchChannel *>(channel.get());
|
twitch::TwitchChannel *twitchChannel = dynamic_cast<twitch::TwitchChannel *>(channel.get());
|
||||||
|
|
||||||
if (channel->isEmpty()) {
|
if (twitchChannel != nullptr && twitchChannel->isLive) {
|
||||||
this->channelNameLabel.setText(QString::fromStdString(channelName) + " (live)");
|
this->channelNameLabel.setText(QString::fromStdString(channelName) + " (live)");
|
||||||
if (twitchChannel != nullptr) {
|
this->setToolTip("<style>.center { text-align: center; }</style>"
|
||||||
this->setToolTip("<style>.center { text-align: center; }</style>"
|
"<p class = \"center\">" +
|
||||||
"<p class = \"center\">" +
|
twitchChannel->streamStatus + "<br><br>" +
|
||||||
twitchChannel->streamStatus + "<br><br>" +
|
twitchChannel->streamGame + "<br>"
|
||||||
twitchChannel->streamGame + "<br>"
|
"Live for " +
|
||||||
"Live for " +
|
twitchChannel->streamUptime + " with " +
|
||||||
twitchChannel->streamUptime + " with " +
|
twitchChannel->streamViewerCount + " viewers"
|
||||||
twitchChannel->streamViewerCount + " viewers"
|
"</p>");
|
||||||
"</p>");
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
this->channelNameLabel.setText(QString::fromStdString(channelName));
|
this->channelNameLabel.setText(QString::fromStdString(channelName));
|
||||||
this->setToolTip("");
|
this->setToolTip("");
|
||||||
|
|
Loading…
Reference in a new issue