-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hide zero and infinity values in peer list only when that setting is set to Always
#22205
Conversation
…set to `Always` Closes qbittorrent#21998.
@@ -420,7 +420,8 @@ void PeerListWidget::loadPeers(const BitTorrent::Torrent *torrent) | |||
for (auto i = m_peerItems.cbegin(); i != m_peerItems.cend(); ++i) | |||
existingPeers.insert(i.key()); | |||
|
|||
const bool hideZeroValues = Preferences::instance()->getHideZeroValues(); | |||
const Preferences *pref = Preferences::instance(); | |||
const bool hideZeroValues = (pref->getHideZeroValues() && (pref->getHideZeroComboValues() == 0)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would be nice to refactor it further in order to have single accessor using enum
type.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would be nice to refactor it further in order to have single accessor using
enum
type.
Unfortunately i don't know what this means.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would be nice to refactor it further in order to have single accessor using
enum
type.Unfortunately i don't know what this means.
This is more of a note for myself...
@thalieht |
…set to `Always` PR qbittorrent#22205. Closes qbittorrent#21998.
Closes #21998.