2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 14:38:15 +00:00

Move ChatTheme to td_ui.

This commit is contained in:
John Preston
2021-08-26 18:02:21 +03:00
parent 3cd0f9d189
commit 0a1e84ddb2
37 changed files with 353 additions and 244 deletions

View File

@@ -12,6 +12,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
#include "ui/text/text_options.h"
#include "ui/image/image_prepare.h"
#include "ui/emoji_config.h"
#include "ui/chat/chat_theme.h"
#include "styles/style_widgets.h"
#include "styles/style_window.h"
#include "styles/style_media_view.h"
@@ -456,7 +457,9 @@ void Generator::paintHistoryBackground() {
PainterHighQualityEnabler hq(*_p);
auto fill = QSize(_topBar.width(), _body.height());
const auto rects = ComputeBackgroundRects(fill, background.size());
const auto rects = Ui::ComputeChatBackgroundRects(
fill,
background.size());
auto to = rects.to;
to.moveTop(to.top() + fromy);
to.moveTopLeft(to.topLeft() + _history.topLeft());