2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 22:46:10 +00:00

Added ability to provide custom text to subscribe button.

This commit is contained in:
23rd
2022-07-06 18:14:32 +03:00
committed by John Preston
parent afb336ed41
commit 2a3d72ad2e
3 changed files with 36 additions and 19 deletions

View File

@@ -1482,7 +1482,11 @@ void PreviewBox(
}) | rpl::flatten_latest();
auto button = descriptor.fromSettings
? object_ptr<Ui::GradientButton>::fromRaw(
Settings::CreateSubscribeButton(controller, box, computeRef))
Settings::CreateSubscribeButton({
controller,
box,
computeRef,
}))
: CreateUnlockButton(box, std::move(unlock));
button->resizeToWidth(width);
if (!descriptor.fromSettings) {