closeAll method

Future<void> closeAll()

Tell all the modals to close in reverse order.

Implementation

Future<void> closeAll() async {
  for (var modal in _stack.reversed.toList()) {
    await modal.close();
  }
}