mirror of
https://github.com/Qz3rK/tdesktop.git
synced 2026-07-03 14:15:08 +02:00
Slightly optimized repaint for userpic and gifts in profile top bar.
This commit is contained in:
@@ -1356,9 +1356,17 @@ void TopBar::paintEvent(QPaintEvent *e) {
|
||||
if (_patternEmoji && _patternEmoji->ready()) {
|
||||
paintAnimatedPattern(p, rect(), geometry);
|
||||
}
|
||||
paintPinnedToTopGifts(p, rect(), geometry);
|
||||
paintUserpic(p, geometry);
|
||||
paintStoryOutline(p, geometry);
|
||||
|
||||
const auto clipBounds = e->region().boundingRect();
|
||||
if (clipBounds.bottom() >= geometry.top()
|
||||
&& clipBounds.top() <= geometry.bottom()) {
|
||||
paintPinnedToTopGifts(p, rect(), geometry);
|
||||
}
|
||||
|
||||
if (clipBounds.intersects(geometry)) {
|
||||
paintUserpic(p, geometry);
|
||||
paintStoryOutline(p, geometry);
|
||||
}
|
||||
}
|
||||
|
||||
void TopBar::setupButtons(
|
||||
|
||||
Reference in New Issue
Block a user