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

Adjust privacy edit boxes to the mockup.

This commit is contained in:
John Preston
2022-02-13 16:30:43 +03:00
parent c5d7889ac9
commit 6daa267329
47 changed files with 460 additions and 292 deletions

View File

@@ -43,7 +43,9 @@ void AddOption(
const auto button = AddButton(
container,
rpl::single(name),
option.relevant() ? st::settingsButton : st::settingsOptionDisabled
(option.relevant()
? st::settingsButtonNoIcon
: st::settingsOptionDisabled)
)->toggleOn(toggles->events_starting_with(option.value()));
const auto restarter = (option.relevant() && option.restartRequired())
@@ -68,7 +70,7 @@ void AddOption(
}
option.set(toggled);
if (restarter) {
restarter->callOnce(st::settingsButton.toggle.duration);
restarter->callOnce(st::settingsButtonNoIcon.toggle.duration);
}
}, container->lifetime());
@@ -104,7 +106,7 @@ void SetupExperimental(
reset = AddButton(
inner,
tr::lng_settings_experimental_restore(),
st::settingsButton);
st::settingsButtonNoIcon);
reset->addClickHandler([=] {
base::options::reset();
wrap->hide(anim::type::normal);