mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-09-05 00:55:12 +00:00
Use objects instead of pointers for corners.
Also don't change mask corner images when color theme is changed. This prevents race condition in mask corner images access, because the GIF frame readers access mask corner images from other threads.
This commit is contained in:
@@ -265,7 +265,7 @@ void TabbedPanel::startShowAnimation() {
|
||||
auto inner = rect().marginsRemoved(st::emojiPanMargins);
|
||||
_showAnimation->setFinalImage(std::move(image), QRect(inner.topLeft() * cIntRetinaFactor(), inner.size() * cIntRetinaFactor()));
|
||||
auto corners = App::cornersMask(ImageRoundRadius::Small);
|
||||
_showAnimation->setCornerMasks(QImage(*corners[0]), QImage(*corners[1]), QImage(*corners[2]), QImage(*corners[3]));
|
||||
_showAnimation->setCornerMasks(corners[0], corners[1], corners[2], corners[3]);
|
||||
_showAnimation->start();
|
||||
}
|
||||
hideChildren();
|
||||
|
Reference in New Issue
Block a user