-
Notifications
You must be signed in to change notification settings - Fork 140
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: upgrade FGP & compatible with flutter 3.29.0 (#542)
This pull request includes several changes to the Android project setup and dependencies, as well as some code refactoring in the `GlobalMethodHandler` class. The most important changes are grouped by theme and summarized below: ### Android Project Setup: Upgrade to latest Flutter Gradle plugins configuration: https://docs.flutter.dev/release/breaking-changes/flutter-gradle-plugin-apply ### Dependency Updates: * [`example/pubspec.yaml`](diffhunk://#diff-565b0869896732da3b937c64bc8fd5f0ca37ea1f629d579c29fc70e0f1e3e48eL20-R20): Updated the `path_provider` dependency version from `2.0.15` to `2.1.5`. * Set minimum supported Flutter version to 3.22.0 ### Code Refactoring: * [`maplibre_gl/android/src/main/java/org/maplibre/maplibregl/GlobalMethodHandler.java`](diffhunk://#diff-9c836abc6c8048cf093a291198c86b17f16530e99328202318c54f9fe1c65c40L29-L37): Removed the `registrar` field and related code, updating the constructor and `openTilesDbFile` method to use `flutterAssets` instead. [[1]](diffhunk://#diff-9c836abc6c8048cf093a291198c86b17f16530e99328202318c54f9fe1c65c40L29-L37) [[2]](diffhunk://#diff-9c836abc6c8048cf093a291198c86b17f16530e99328202318c54f9fe1c65c40L155-R149) --------- Co-authored-by: thanhdt-vietmap <[email protected]> Co-authored-by: Joscha <[email protected]>
- Loading branch information
1 parent
0128d1c
commit 21e45e2
Showing
13 changed files
with
53 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
#Wed Feb 19 16:20:21 ICT 2025 | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.9-bin.zip | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2-bin.zip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,25 @@ | ||
include ':app' | ||
pluginManagement { | ||
def flutterSdkPath = { | ||
def properties = new Properties() | ||
file("local.properties").withInputStream { properties.load(it) } | ||
def flutterSdkPath = properties.getProperty("flutter.sdk") | ||
assert flutterSdkPath != null, "flutter.sdk not set in local.properties" | ||
return flutterSdkPath | ||
}() | ||
|
||
def localPropertiesFile = new File(rootProject.projectDir, "local.properties") | ||
def properties = new Properties() | ||
includeBuild("$flutterSdkPath/packages/flutter_tools/gradle") | ||
|
||
assert localPropertiesFile.exists() | ||
localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) } | ||
repositories { | ||
google() | ||
mavenCentral() | ||
gradlePluginPortal() | ||
} | ||
} | ||
|
||
def flutterSdkPath = properties.getProperty("flutter.sdk") | ||
assert flutterSdkPath != null, "flutter.sdk not set in local.properties" | ||
apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle" | ||
plugins { | ||
id "dev.flutter.flutter-plugin-loader" version "1.0.0" | ||
id "com.android.application" version "8.2.2" apply false | ||
id "org.jetbrains.kotlin.android" version "2.0.20" apply false | ||
} | ||
|
||
include ":app" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,6 @@ | ||
include: ../analysis_options.yaml | ||
include: ../analysis_options.yaml | ||
|
||
analyzer: | ||
errors: | ||
deprecated_member_use: ignore | ||
deprecated_member_use_from_same_package: ignore |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters