Removed total views from the usercard (#3792)

This commit is contained in:
matt 2022-06-05 15:51:18 -05:00 committed by GitHub
parent 7ccf60111d
commit d29243a2a5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 2 additions and 10 deletions

View file

@ -20,6 +20,7 @@
- Minor: Added `/requests` command. Usage: `/requests [channel]`. Opens the channel points requests queue for the provided channel or the current channel if no input is provided. (#3746)
- Minor: Added ability to execute commands on chat messages using the message context menu. (#3738, #3765)
- Minor: Added `/copy` command. Usage: `/copy <text>`. Copies provided text to clipboard - can be useful with custom commands. (#3763)
- Minor: Removed total views from the usercard, as Twitch no longer updates the number. (#3792)
- Bugfix: Fixed viewers list search not working when used before loading finishes. (#3774)
- Bugfix: Fixed live notifications for usernames containing uppercase characters. (#3646)
- Bugfix: Fixed live notifications not getting updated for closed streams going offline. (#3678)

View file

@ -27,7 +27,6 @@ struct HelixUser {
QString createdAt;
QString description;
QString profileImageUrl;
int viewCount;
explicit HelixUser(QJsonObject jsonObject)
: id(jsonObject.value("id").toString())
@ -36,7 +35,6 @@ struct HelixUser {
, createdAt(jsonObject.value("created_at").toString())
, description(jsonObject.value("description").toString())
, profileImageUrl(jsonObject.value("profile_image_url").toString())
, viewCount(jsonObject.value("view_count").toInt())
{
}
};

View file

@ -12,7 +12,7 @@ URL: https://dev.twitch.tv/docs/api/reference#get-users
Used in:
- `UserInfoPopup` to get ID, viewCount, displayName, createdAt of username we clicked
- `UserInfoPopup` to get ID, displayName, createdAt of username we clicked
- `CommandController` to power any commands that need to get a user ID
- `Toasts` to get the profile picture of a streamer who just went live
- `TwitchAccount` block and unblock features to translate user name to user ID

View file

@ -35,7 +35,6 @@
#include <QNetworkAccessManager>
#include <QNetworkReply>
const QString TEXT_VIEWS("Views: %1");
const QString TEXT_FOLLOWERS("Followers: %1");
const QString TEXT_CREATED("Created: %1");
const QString TEXT_TITLE("%1's Usercard - #%2");
@ -358,8 +357,6 @@ UserInfoPopup::UserInfoPopup(bool closeAutomatically, QWidget *parent)
}
// items on the left
vbox.emplace<Label>(TEXT_VIEWS.arg(""))
.assign(&this->ui_.viewCountLabel);
vbox.emplace<Label>(TEXT_FOLLOWERS.arg(""))
.assign(&this->ui_.followerCountLabel);
vbox.emplace<Label>(TEXT_CREATED.arg(""))
@ -780,7 +777,6 @@ void UserInfoPopup::updateUserData()
// this can occur when the account doesn't exist.
this->ui_.followerCountLabel->setText(
TEXT_FOLLOWERS.arg(TEXT_UNAVAILABLE));
this->ui_.viewCountLabel->setText(TEXT_VIEWS.arg(TEXT_UNAVAILABLE));
this->ui_.createdDateLabel->setText(TEXT_CREATED.arg(TEXT_UNAVAILABLE));
this->ui_.nameLabel->setText(this->userName_);
@ -817,8 +813,6 @@ void UserInfoPopup::updateUserData()
this->setWindowTitle(TEXT_TITLE.arg(
user.displayName, this->underlyingChannel_->getName()));
this->ui_.viewCountLabel->setText(
TEXT_VIEWS.arg(localizeNumbers(user.viewCount)));
this->ui_.createdDateLabel->setText(
TEXT_CREATED.arg(user.createdAt.section("T", 0, 0)));
this->ui_.userIDLabel->setText(TEXT_USER_ID + user.id);

View file

@ -76,7 +76,6 @@ private:
Label *nameLabel = nullptr;
Label *localizedNameLabel = nullptr;
Label *viewCountLabel = nullptr;
Label *followerCountLabel = nullptr;
Label *createdDateLabel = nullptr;
Label *userIDLabel = nullptr;