mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Allowed to display of hundreds digit in unread badge of filters.
This commit is contained in:
parent
4e8e096fdb
commit
a405794a03
2 changed files with 2 additions and 2 deletions
|
@ -174,7 +174,7 @@ QImage ChatsFiltersTabs::cacheUnreadCount(int count, bool muted) const {
|
||||||
QImage::Format_ARGB32_Premultiplied);
|
QImage::Format_ARGB32_Premultiplied);
|
||||||
image.setDevicePixelRatio(style::DevicePixelRatio());
|
image.setDevicePixelRatio(style::DevicePixelRatio());
|
||||||
image.fill(Qt::transparent);
|
image.fill(Qt::transparent);
|
||||||
const auto string = (count > 99)
|
const auto string = (count > 999)
|
||||||
? _unreadMaxString
|
? _unreadMaxString
|
||||||
: QString::number(count);
|
: QString::number(count);
|
||||||
{
|
{
|
||||||
|
|
|
@ -283,7 +283,7 @@ base::unique_qptr<Ui::SideBarButton> FiltersMenu::prepareButton(
|
||||||
- (includeMuted ? 0 : muted);
|
- (includeMuted ? 0 : muted);
|
||||||
const auto string = !count
|
const auto string = !count
|
||||||
? QString()
|
? QString()
|
||||||
: (count > 99)
|
: (count > 999)
|
||||||
? "99+"
|
? "99+"
|
||||||
: QString::number(count);
|
: QString::number(count);
|
||||||
raw->setBadge(string, includeMuted && (count == muted));
|
raw->setBadge(string, includeMuted && (count == muted));
|
||||||
|
|
Loading…
Add table
Reference in a new issue