2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-30 22:25:12 +00:00

Removed NotificationsDemoIsShown global variable from facades.

This commit is contained in:
23rd
2021-05-26 01:22:55 +03:00
parent 54dd63d61a
commit d2c8780c0f
6 changed files with 12 additions and 13 deletions

View File

@@ -131,9 +131,14 @@ void Manager::settingsChanged(ChangeType change) {
showNextFromQueue();
}
}
} else if (change == ChangeType::DemoIsShown) {
auto demoIsShown = Global::NotificationsDemoIsShown();
_demoMasterOpacity.start([this] { demoMasterOpacityCallback(); }, demoIsShown ? 1. : 0., demoIsShown ? 0. : 1., st::notifyFastAnim);
} else if ((change == ChangeType::DemoIsShown)
|| (change == ChangeType::DemoIsHidden)) {
_demoIsShown = (change == ChangeType::DemoIsShown);
_demoMasterOpacity.start(
[=] { demoMasterOpacityCallback(); },
_demoIsShown ? 1. : 0.,
_demoIsShown ? 0. : 1.,
st::notifyFastAnim);
}
}
@@ -147,7 +152,7 @@ void Manager::demoMasterOpacityCallback() {
}
float64 Manager::demoMasterOpacity() const {
return _demoMasterOpacity.value(Global::NotificationsDemoIsShown() ? 0. : 1.);
return _demoMasterOpacity.value(_demoIsShown ? 0. : 1.);
}
void Manager::checkLastInput() {