From 94a356994ef1b07418e9cbc7732e0d6aa5ed139d Mon Sep 17 00:00:00 2001 From: wuxinglong Date: Fri, 14 Nov 2025 09:51:16 +0800 Subject: [PATCH] =?UTF-8?q?feat=EF=BC=9A=E9=A2=84=E8=A7=88=E5=9B=BE?= =?UTF-8?q?=E7=89=87=E7=BB=84=E4=BB=B6=E6=96=B0=E5=A2=9E=E7=BC=96=E8=BE=91?= =?UTF-8?q?=E6=8C=89=E9=92=AE=E5=8F=8A=E4=BA=8B=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- example/lib/main.dart | 1 - lib/upload_image/look_images_widget.dart | 8 ++++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/example/lib/main.dart b/example/lib/main.dart index 8e8b759..e99774e 100644 --- a/example/lib/main.dart +++ b/example/lib/main.dart @@ -121,7 +121,6 @@ class _MyHomePageState extends State { ), ), ); - print(editedImage); } } diff --git a/lib/upload_image/look_images_widget.dart b/lib/upload_image/look_images_widget.dart index 563b862..1a2e76d 100644 --- a/lib/upload_image/look_images_widget.dart +++ b/lib/upload_image/look_images_widget.dart @@ -7,6 +7,7 @@ class LookImagesTool { static lookImages({ required List listData, int? currentPage, + Function? editCallback, }) async { showDialog( context: Get.context!, @@ -15,6 +16,7 @@ class LookImagesTool { return LookImagesWidget( listData: listData, currentPage: currentPage, + editCallback: editCallback, ); }); } @@ -23,11 +25,13 @@ class LookImagesTool { class LookImagesWidget extends StatefulWidget { final List listData; final int? currentPage; + final Function? editCallback; const LookImagesWidget({ super.key, required this.listData, this.currentPage, + this.editCallback, }); @override @@ -77,6 +81,10 @@ class _LookImagesWidgetState extends State { left: 15, top: 50, child: GestureDetector(onTap: () => Get.back(), child: Icon(Icons.arrow_back_ios, color: Colors.white))), + Positioned( + right: 15, + top: 50, + child: GestureDetector(onTap: () => widget.editCallback?.call(), child: Icon(Icons.edit, color: Colors.white))), //图片张数指示器 Positioned( left: 0,