overlay show checker
Erkapos opened this issue · comments
is there a way to check if overlay is currently showing because i want to achieve a code like this
if(overlay is shown ?){
hide overlay here
}
you can use the onboarding reference gotten by key or Onboarding.of(context), then use the exposed controller.
onboarding.controller.isVisible;
Or extend it with an extension
extension VisibilityOnboarding on OnboardingState {
bool isVisible() {
return controller.isVisible;
}
}
ok ok thank you very much, it works