loading static method

void loading({
  1. bool tapClose = false,
})

Implementation

static void loading({bool tapClose = false}) {
  if (loadingOE != null) {
    return;
  }
  var child = Container(
      child: tapClose
          ? InkWell(
              child: Center(child: CircularProgressIndicator()),
              onTap: () => loaded(),
            )
          : Center(
              child: CircularProgressIndicator(),
            ),
      decoration: new BoxDecoration(
        color: Colors.transparent,
      ));
  loadingOE = OverlayEntry(builder: (c) => child);

  Overlay.of(Cry.context)!.insert(loadingOE!);
}