Skip to content

Commit 9130db2

Browse files
authored
📌 Allow extended_image v10 (#690)
Resolves #689
1 parent c0432c1 commit 9130db2

File tree

13 files changed

+58
-34
lines changed

13 files changed

+58
-34
lines changed

.github/workflows/runnable.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,11 @@ jobs:
8888
java-version: '17'
8989
- uses: flutter-actions/setup-flutter@v4
9090
with:
91+
cache: true
9192
channel: stable
9293
version: ${{ matrix.flutter-version == 'min' && env.MINIMUM_FLUTTER_VERSION || 'latest' }}
9394
- run: dart --version
9495
- run: flutter --version
9596
- run: flutter pub get
96-
- run: cd example; flutter build apk --debug
97+
- run: flutter build apk --debug
98+
working-directory: ${{ github.workspace }}/example

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,12 @@ that can be found in the LICENSE file. -->
1111

1212
*None.*
1313

14+
## 9.5.1
15+
16+
### Improvements
17+
18+
- Allow `extended_image` v10.
19+
1420
## 9.5.0
1521

1622
### New features

example/android/app/build.gradle

Lines changed: 27 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2,43 +2,50 @@ plugins {
22
id "com.android.application"
33
id "kotlin-android"
44
id "kotlin-kapt"
5+
// The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
56
id "dev.flutter.flutter-gradle-plugin"
67
}
78

8-
def localProperties = new Properties()
9-
def localPropertiesFile = rootProject.file('local.properties')
10-
if (localPropertiesFile.exists()) {
11-
localPropertiesFile.withReader('UTF-8') { reader ->
12-
localProperties.load(reader)
13-
}
9+
def flutterVersionCode = null
10+
def flutterVersionName = null
11+
if (flutter.hasProperty('versionCode')) {
12+
flutterVersionCode = flutter.versionCode
1413
}
15-
16-
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
17-
if (flutterVersionCode == null) {
18-
flutterVersionCode = '1'
14+
if (flutter.hasProperty('versionName')) {
15+
flutterVersionName = flutter.versionName
1916
}
2017

21-
def flutterVersionName = localProperties.getProperty('flutter.versionName')
22-
if (flutterVersionName == null) {
23-
flutterVersionName = '1.0'
18+
if (flutterVersionCode == null || flutterVersionName == null) {
19+
def localProperties = new Properties()
20+
rootProject.file('local.properties').withReader('UTF-8') { reader ->
21+
localProperties.load(reader)
22+
}
23+
24+
if (flutterVersionCode == null) {
25+
flutterVersionCode = localProperties.getProperty('flutter.versionCode')
26+
}
27+
if (flutterVersionName == null) {
28+
flutterVersionName = localProperties.getProperty('flutter.versionName')
29+
}
2430
}
2531

2632
android {
2733
namespace "com.fluttercandies.wechatAssetsPickerExample"
2834
compileSdk flutter.compileSdkVersion
29-
30-
sourceSets {
31-
main.java.srcDirs += 'src/main/kotlin'
32-
}
35+
ndkVersion flutter.ndkVersion
3336

3437
defaultConfig {
35-
applicationId "com.fluttercandies.wechatAssetsPickerExample"
36-
minSdkVersion 21
37-
targetSdkVersion flutter.targetSdkVersion
38+
applicationId = "com.fluttercandies.wechatAssetsPickerExample"
39+
minSdk 21
40+
targetSdk flutter.targetSdkVersion
3841
versionCode flutterVersionCode.toInteger()
3942
versionName flutterVersionName
4043
}
4144

45+
sourceSets {
46+
main.java.srcDirs += 'src/main/kotlin'
47+
}
48+
4249
kotlinOptions {
4350
jvmTarget = '17'
4451
}

example/android/gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
org.gradle.jvmargs=-Xmx1536M
1+
org.gradle.jvmargs=-Xmx4G -XX:MaxMetaspaceSize=2G -XX:+HeapDumpOnOutOfMemoryError
22
android.useAndroidX=true
33
android.enableJetifier=true

example/android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
33
zipStoreBase=GRADLE_USER_HOME
44
zipStorePath=wrapper/dists
5-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-bin.zip
5+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-bin.zip

example/android/settings.gradle

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,9 @@ pluginManagement {
55
def flutterSdkPath = properties.getProperty("flutter.sdk")
66
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
77
return flutterSdkPath
8-
}
9-
settings.ext.flutterSdkPath = flutterSdkPath()
8+
}()
109

11-
includeBuild("${settings.ext.flutterSdkPath}/packages/flutter_tools/gradle")
10+
includeBuild("$flutterSdkPath/packages/flutter_tools/gradle")
1211

1312
repositories {
1413
google()
@@ -19,8 +18,9 @@ pluginManagement {
1918

2019
plugins {
2120
id "dev.flutter.flutter-plugin-loader" version "1.0.0"
22-
id "com.android.application" version "8.2.2" apply false
23-
id "org.jetbrains.kotlin.android" version "1.9.21" apply false
21+
id "com.android.application" version "8.9.1" apply false
22+
id "com.android.library" version "8.9.1" apply false
23+
id "org.jetbrains.kotlin.android" version "2.1.20" apply false
2424
}
2525

2626
include ":app"

example/ios/Runner.xcodeproj/project.pbxproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@
266266
);
267267
runOnlyForDeploymentPostprocessing = 0;
268268
shellPath = /bin/sh;
269-
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build";
269+
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build\n";
270270
};
271271
/* End PBXShellScriptBuildPhase section */
272272

example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
buildConfiguration = "Debug"
2727
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
2828
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
29+
customLLDBInitFile = "$(SRCROOT)/Flutter/ephemeral/flutter_lldbinit"
2930
shouldUseLaunchSchemeArgsEnv = "YES">
3031
<MacroExpansion>
3132
<BuildableReference
@@ -54,11 +55,13 @@
5455
buildConfiguration = "Debug"
5556
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
5657
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
58+
customLLDBInitFile = "$(SRCROOT)/Flutter/ephemeral/flutter_lldbinit"
5759
launchStyle = "0"
5860
useCustomWorkingDirectory = "NO"
5961
ignoresPersistentStateOnLaunch = "NO"
6062
debugDocumentVersioning = "YES"
6163
debugServiceExtension = "internal"
64+
enableGPUValidationMode = "1"
6265
allowLocationSimulation = "YES">
6366
<BuildableProductRunnable
6467
runnableDebuggingMode = "0">

example/ios/Runner/Info.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
<key>CFBundleInfoDictionaryVersion</key>
1616
<string>6.0</string>
1717
<key>CFBundleName</key>
18-
<string>com.fluttercandies.wechatAssetsPickerExample</string>
18+
<string>flutter_wechat_assets_picker_example</string>
1919
<key>CFBundlePackageType</key>
2020
<string>APPL</string>
2121
<key>CFBundleShortVersionString</key>

example/macos/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@
5959
ignoresPersistentStateOnLaunch = "NO"
6060
debugDocumentVersioning = "YES"
6161
debugServiceExtension = "internal"
62+
enableGPUValidationMode = "1"
6263
allowLocationSimulation = "YES">
6364
<BuildableProductRunnable
6465
runnableDebuggingMode = "0">
Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
11
import Cocoa
22
import FlutterMacOS
33

4-
@NSApplicationMain
4+
@main
55
class AppDelegate: FlutterAppDelegate {
66
override func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool {
77
return true
88
}
9+
10+
override func applicationSupportsSecureRestorableState(_ app: NSApplication) -> Bool {
11+
return true
12+
}
913
}

example/pubspec.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: wechat_assets_picker_demo
22
description: The demo project for the wechat_assets_picker package.
3-
version: 9.5.0+65
3+
version: 9.5.1+66
44
publish_to: none
55

66
environment:
@@ -28,5 +28,6 @@ dev_dependencies:
2828

2929
flutter:
3030
uses-material-design: true
31+
generate: true
3132
assets:
3233
- assets/

pubspec.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: wechat_assets_picker
2-
version: 9.5.0
2+
version: 9.5.1
33
description: |
44
An image picker (also with videos and audio)
55
for Flutter projects based on WeChat's UI,
@@ -24,7 +24,7 @@ dependencies:
2424

2525
wechat_picker_library: ^1.0.5
2626

27-
extended_image: '>=8.3.0 <10.0.0'
27+
extended_image: '>=8.3.0 <11.0.0'
2828
photo_manager: ^3.5.0
2929
photo_manager_image_provider: ^2.2.0
3030
provider: ^6.0.5

0 commit comments

Comments
 (0)