| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113 |
- import 'package:clean/module/main/main_view.dart';
- import 'package:clean/resource/assets.gen.dart';
- import 'package:clean/resource/colors.gen.dart';
- import 'package:flutter/Material.dart';
- import 'package:flutter/cupertino.dart';
- import 'package:flutter_screenutil/flutter_screenutil.dart';
- import 'package:flutter_smart_dialog/flutter_smart_dialog.dart';
- import 'package:lottie/lottie.dart';
- import 'package:get/get.dart';
- import 'package:clean/router/app_pages.dart';
- void photoDeleteFinishDialog( { Function? onDismiss}) {
- const tag = 'photoDeleteFinishDialog';
- // 300ms后关闭弹窗
- Future.delayed(Duration(seconds: 3), () {
- SmartDialog.dismiss(tag: tag);
- if (onDismiss != null) {
- onDismiss();
- }
- // // 回到首页
- // Get.until((route) => Get. currentRoute ==RoutePath.mainTab);
- });
- SmartDialog.show(
- tag: tag,
- backType: SmartBackType.block,
- clickMaskDismiss: false,
- maskColor: ColorName.black,
- builder: (_) {
- return Container(
- height: double.infinity,
- width: double.infinity,
- child: Stack(
- children: [
- Positioned(
- left: 0,
- right: 0,
- child: Column(
- children: [
- Column(
- crossAxisAlignment: CrossAxisAlignment.center,
- mainAxisAlignment: MainAxisAlignment.center,
- children: [
- Lottie.asset(
- Assets.anim.animFireworks,
- height: 351.h,
- repeat: false,
- ),
- Text(
- 'Perfect!',
- textAlign: TextAlign.center,
- style: TextStyle(
- color: Colors.white,
- fontSize: 32.sp,
- fontWeight: FontWeight.w700,
- ),
- ),
- SizedBox(height: 16.h),
- SizedBox(
- child: Row(
- mainAxisAlignment: MainAxisAlignment.center,
- children: [
- Container(
- clipBehavior: Clip.antiAlias,
- decoration: BoxDecoration(),
- child: Assets
- .images.iconPreviewSwiperEndFirework
- .image(
- width: 40.w,
- height: 40.w,
- ),
- ),
- SizedBox(width: 4.w),
- Text(
- 'Photos Removed',
- textAlign: TextAlign.center,
- style: TextStyle(
- color: Colors.white.withValues(alpha: 0.8),
- fontSize: 16.sp,
- fontWeight: FontWeight.w400,
- ),
- ),
- SizedBox(width: 4.w),
- Container(
- clipBehavior: Clip.antiAlias,
- decoration: BoxDecoration(),
- child: Assets
- .images.iconPreviewSwiperEndFirework
- .image(
- width: 40.w,
- height: 40.w,
- ),
- ),
- ],
- ),
- ),
- ],
- ),
- ],
- )),
- IgnorePointer(
- child: Assets.images.bgPhotoSelectedPreviewFinish.image(
- width: 360.w,
- ),
- ),
- ],
- ),
- );
- });
- }
|