Fix slide animations with new layer rounding.

This commit is contained in:
John Preston
2022-02-23 13:53:27 +03:00
parent 1a664edd39
commit ffd65e1fe4
11 changed files with 67 additions and 60 deletions
@@ -38,6 +38,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
#include "styles/style_info.h"
#include "styles/style_profile.h"
#include "styles/style_menu_icons.h"
#include "styles/style_layers.h"
namespace Info {
namespace {
@@ -855,7 +856,9 @@ void WrapWidget::showNewContent(
&& newContent->hasTopBarShadow();
animationParams.oldContentCache = grabForShowAnimation(
animationParams);
animationParams.withFade = (wrap() == Wrap::Layer);
const auto layer = (wrap() == Wrap::Layer);
animationParams.withFade = layer;
animationParams.topSkip = layer ? st::boxRadius : 0;
}
if (saveToStack) {
auto item = StackItem();