showLoading method

void showLoading()

Implementation

void showLoading() {
  Size size = MediaQuery.of(context).size;
  double height = size.height;
  double width = size.width;
  showDialog<void>(
    barrierDismissible: false,
    context: context,
    useSafeArea: false,
    builder: (BuildContext _) =>
        widget.loadingWidget ??
        SizedBox(
          width: width,
          height: height,
          child: Center(
            child: CircularProgressIndicator(
              color: Colors.white.withOpacity(0.8),
            ),
          ),
        ),
    useRootNavigator: false,
  );
}