upgrade deps

Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-09-18 17:05:00 +08:00
parent cef7e478f5
commit fef6a8c22a
7 changed files with 22 additions and 37 deletions

View File

@@ -177,7 +177,6 @@
<activity <activity
android:name="com.yalantis.ucrop.UCropActivity" android:name="com.yalantis.ucrop.UCropActivity"
android:screenOrientation="portrait"
android:theme="@style/Ucrop.CropTheme"/> android:theme="@style/Ucrop.CropTheme"/>
<receiver <receiver

View File

@@ -1,8 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<style name="Ucrop.CropTheme" parent="Theme.AppCompat.Light.NoActionBar">
<item name="android:windowLightStatusBar">true</item>
<item name="android:fitsSystemWindows">true</item>
<item name="android:windowOptOutEdgeToEdgeEnforcement">true</item>
</style>
</resources>

View File

@@ -148,18 +148,17 @@ abstract class CommonRichTextPubPageState<T extends CommonRichTextPubPage>
} }
Future<void> onCropImage(int index) async { Future<void> onCropImage(int index) async {
final theme = Theme.of(context); late final colorScheme = ColorScheme.of(context);
CroppedFile? croppedFile = await ImageCropper().cropImage( CroppedFile? croppedFile = await ImageCropper().cropImage(
sourcePath: pathList[index], sourcePath: pathList[index],
uiSettings: [ uiSettings: [
AndroidUiSettings( AndroidUiSettings(
toolbarTitle: '裁剪', toolbarTitle: '裁剪',
toolbarColor: theme.colorScheme.secondaryContainer, toolbarColor: colorScheme.secondaryContainer,
toolbarWidgetColor: theme.colorScheme.onSecondaryContainer, toolbarWidgetColor: colorScheme.onSecondaryContainer,
), statusBarLight: colorScheme.brightness.isLight,
IOSUiSettings(
title: '裁剪',
), ),
IOSUiSettings(title: '裁剪'),
], ],
); );
if (croppedFile != null) { if (croppedFile != null) {

View File

@@ -2,6 +2,7 @@ import 'package:PiliPlus/common/widgets/loading_widget/loading_widget.dart';
import 'package:PiliPlus/http/fav.dart'; import 'package:PiliPlus/http/fav.dart';
import 'package:PiliPlus/http/msg.dart'; import 'package:PiliPlus/http/msg.dart';
import 'package:PiliPlus/models_new/fav/fav_folder/list.dart'; import 'package:PiliPlus/models_new/fav/fav_folder/list.dart';
import 'package:PiliPlus/utils/extension.dart';
import 'package:PiliPlus/utils/fav_utils.dart'; import 'package:PiliPlus/utils/fav_utils.dart';
import 'package:PiliPlus/utils/image_utils.dart'; import 'package:PiliPlus/utils/image_utils.dart';
import 'package:cached_network_image/cached_network_image.dart'; import 'package:cached_network_image/cached_network_image.dart';
@@ -121,21 +122,18 @@ class _CreateFavPageState extends State<CreateFavPage> {
toolbarTitle: '裁剪', toolbarTitle: '裁剪',
toolbarColor: theme.colorScheme.secondaryContainer, toolbarColor: theme.colorScheme.secondaryContainer,
toolbarWidgetColor: theme.colorScheme.onSecondaryContainer, toolbarWidgetColor: theme.colorScheme.onSecondaryContainer,
aspectRatioPresets: [ statusBarLight: theme.colorScheme.brightness.isLight,
CropAspectRatioPreset.ratio16x9, aspectRatioPresets: [CropAspectRatioPreset.ratio16x9],
],
lockAspectRatio: true, lockAspectRatio: true,
hideBottomControls: true, hideBottomControls: true,
initAspectRatio: CropAspectRatioPreset.ratio16x9, initAspectRatio: CropAspectRatioPreset.ratio16x9,
), ),
IOSUiSettings( IOSUiSettings(
title: '裁剪', title: '裁剪',
aspectRatioPresets: [ // aspectRatioPresets: [CropAspectRatioPreset.ratio16x9],
CropAspectRatioPreset.ratio16x9, // aspectRatioLockEnabled: false,
], // resetAspectRatioEnabled: false,
aspectRatioLockEnabled: false, // aspectRatioPickerButtonHidden: true,
resetAspectRatioEnabled: false,
aspectRatioPickerButtonHidden: true,
), ),
], ],
); );

View File

@@ -495,9 +495,8 @@ class _EditProfilePageState extends State<EditProfilePage> {
toolbarTitle: '裁剪', toolbarTitle: '裁剪',
toolbarColor: theme.colorScheme.secondaryContainer, toolbarColor: theme.colorScheme.secondaryContainer,
toolbarWidgetColor: theme.colorScheme.onSecondaryContainer, toolbarWidgetColor: theme.colorScheme.onSecondaryContainer,
aspectRatioPresets: [ statusBarLight: theme.colorScheme.brightness.isLight,
CropAspectRatioPresetCustom(), aspectRatioPresets: [CropAspectRatioPresetCustom()],
],
lockAspectRatio: true, lockAspectRatio: true,
hideBottomControls: true, hideBottomControls: true,
cropStyle: CropStyle.circle, cropStyle: CropStyle.circle,
@@ -505,9 +504,7 @@ class _EditProfilePageState extends State<EditProfilePage> {
), ),
IOSUiSettings( IOSUiSettings(
title: '裁剪', title: '裁剪',
aspectRatioPresets: [ aspectRatioPresets: [CropAspectRatioPresetCustom()],
CropAspectRatioPresetCustom(),
],
cropStyle: CropStyle.circle, cropStyle: CropStyle.circle,
aspectRatioLockEnabled: true, aspectRatioLockEnabled: true,
resetAspectRatioEnabled: false, resetAspectRatioEnabled: false,

View File

@@ -912,10 +912,10 @@ packages:
dependency: "direct main" dependency: "direct main"
description: description:
name: image_cropper name: image_cropper
sha256: "4e9c96c029eb5a23798da1b6af39787f964da6ffc78fd8447c140542a9f7c6fc" sha256: d104cc1f90b0d38ac309f7ec240b8f55f2c6e76d1bfae05e23917bfea631e725
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "9.1.0" version: "10.0.0+1"
image_cropper_for_web: image_cropper_for_web:
dependency: transitive dependency: transitive
description: description:
@@ -928,10 +928,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: image_cropper_platform_interface name: image_cropper_platform_interface
sha256: "6ca6b81769abff9a4dcc3bbd3d75f5dfa9de6b870ae9613c8cd237333a4283af" sha256: "2d8db8f4b638e448fa89a1e77cd8f053b4547472bd3ae073169e86626d03afef"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "7.1.0" version: "7.2.0"
image_picker: image_picker:
dependency: "direct main" dependency: "direct main"
description: description:
@@ -1387,10 +1387,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: pool name: pool
sha256: "20fe868b6314b322ea036ba325e6fc0711a22948856475e2c2b6306e8ab39c2a" sha256: "978783255c543aa3586a1b3c21f6e9d720eb315376a915872c61ef8b5c20177d"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.5.1" version: "1.5.2"
posix: posix:
dependency: transitive dependency: transitive
description: description:

View File

@@ -187,7 +187,7 @@ dependencies:
intl: ^0.20.2 intl: ^0.20.2
archive: ^4.0.0 archive: ^4.0.0
flutter_svg: ^2.0.14 flutter_svg: ^2.0.14
image_cropper: ^9.1.0 image_cropper: ^10.0.0+1
#解压直播消息 #解压直播消息
brotli: ^0.6.0 brotli: ^0.6.0
expandable: ^5.0.1 expandable: ^5.0.1