feat(ios):照片loading
This commit is contained in:
@@ -22,6 +22,7 @@ class UploadImagesTool {
|
||||
int? max,
|
||||
bool? isVideo,
|
||||
Widget? isAddOtherWidget,
|
||||
bool? isShowLoading,
|
||||
}) async {
|
||||
await chooseCamera(
|
||||
context: context,
|
||||
@@ -34,6 +35,7 @@ class UploadImagesTool {
|
||||
signature: signature ?? '',
|
||||
isVideo: isVideo,
|
||||
isAddOtherWidget: isAddOtherWidget,
|
||||
isShowLoading: isShowLoading,
|
||||
chooseImages: (list) => chooseImagesTap?.call(list),
|
||||
);
|
||||
}
|
||||
@@ -95,6 +97,7 @@ class UploadImagesTool {
|
||||
Function? chooseImages,
|
||||
bool? isVideo,
|
||||
Widget? isAddOtherWidget,
|
||||
bool? isShowLoading,
|
||||
}) async {
|
||||
//
|
||||
showCupertinoModalPopup(
|
||||
@@ -201,6 +204,7 @@ class UploadImagesTool {
|
||||
policy: policy ?? '',
|
||||
callback: callback ?? '',
|
||||
signature: signature ?? '',
|
||||
isShowLoading: isShowLoading,
|
||||
chooseImages: (list) =>
|
||||
chooseImages?.call(list),
|
||||
);
|
||||
@@ -258,6 +262,7 @@ class UploadImagesTool {
|
||||
String? ossHost,
|
||||
int? max,
|
||||
bool? isVideo,
|
||||
bool? isShowLoading,
|
||||
}) async {
|
||||
if (isVideo == true) {
|
||||
XFile? video = await ImagePicker().pickVideo(source: ImageSource.gallery);
|
||||
@@ -285,6 +290,7 @@ class UploadImagesTool {
|
||||
policy: policy ?? '',
|
||||
callback: callback ?? '',
|
||||
signature: signature ?? '',
|
||||
isShowLoading: isShowLoading,
|
||||
);
|
||||
list.add(path);
|
||||
}
|
||||
@@ -327,6 +333,7 @@ class UploadImagesTool {
|
||||
String? signature,
|
||||
String? ossDirectory,
|
||||
String? ossHost,
|
||||
bool? isShowLoading,
|
||||
}) async {
|
||||
String string = await UploadOss.upload(
|
||||
path,
|
||||
@@ -337,6 +344,7 @@ class UploadImagesTool {
|
||||
policy: policy ?? '',
|
||||
callback: callback ?? '',
|
||||
signature: signature ?? '',
|
||||
isShowLoading: isShowLoading,
|
||||
);
|
||||
return string;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user