2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 06:26:18 +00:00

Added api support for global TTL settings.

This commit is contained in:
23rd
2022-11-29 16:53:40 +03:00
parent c481d48865
commit 97fa92de0b
4 changed files with 66 additions and 32 deletions

View File

@@ -520,10 +520,8 @@ void SetupSelfDestruction(
session->api().selfDestruct().reload();
}, container->lifetime());
const auto label = [&] {
return session->api().selfDestruct().days(
) | rpl::map(
SelfDestructionBox::DaysLabel
);
return session->api().selfDestruct().daysAccountTTL(
) | rpl::map(SelfDestructionBox::DaysLabel);
};
AddButtonWithLabel(
@@ -535,7 +533,7 @@ void SetupSelfDestruction(
controller->show(Box<SelfDestructionBox>(
session,
SelfDestructionBox::Type::Account,
session->api().selfDestruct().days()));
session->api().selfDestruct().daysAccountTTL()));
});
AddSkip(container);