Skip to content

Commit

Permalink
feat: Gson 2.11.0
Browse files Browse the repository at this point in the history
  • Loading branch information
koji-1009 committed Oct 30, 2024
1 parent 15fe930 commit 8f262ab
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 31 deletions.
2 changes: 0 additions & 2 deletions flutter_local_notifications/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -319,8 +319,6 @@ Developers should also be across Google's requirements on using full-screen inte

### Release build configuration

Before creating the release build of your app (which is the default setting when building an APK or app bundle) you will need to customise your ProGuard configuration file as per this [link](https://developer.android.com/studio/build/shrink-code#keep-code). Rules specific to the GSON dependency being used by the plugin will need to be added. These rules can be found [here](https://github.com/google/gson/blob/master/examples/android-proguard-example/proguard.cfg). Whilst the example app has a Proguard rules (`proguard-rules.pro`) [here](https://github.com/MaikuB/flutter_local_notifications/blob/master/flutter_local_notifications/example/android/app/proguard-rules.pro), it is recommended that developers refer to the rules on the GSON repository in case they get updated over time.

⚠️ Ensure that you have configured the resources that should be kept so that resources like your notification icons aren't discarded by the R8 compiler by following the instructions [here](https://developer.android.com/studio/build/shrink-code#keep-resources). If you have chosen to use `@mipmap/ic_launcher` as the notification icon (against the official Android guidance), be sure to include this in the `keep.xml` file. If you fail to do this, notifications might be broken. In the worst case they will never show, instead silently failing when the system looks for a resource that has been removed. If they do still show, you might not see the icon you specified. The configuration used by the example app can be found [here](https://github.com/MaikuB/flutter_local_notifications/blob/master/flutter_local_notifications/example/android/app/src/main/res/raw/keep.xml) where it is specifying that all drawable resources should be kept, as well as the file used to play a custom notification sound (sound file is located [here](https://github.com/MaikuB/flutter_local_notifications/blob/master/flutter_local_notifications/example/android/app/src/main/res/raw/slow_spring_board.mp3)).

## 🔧 iOS setup
Expand Down
4 changes: 2 additions & 2 deletions flutter_local_notifications/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ android {

defaultConfig {
multiDexEnabled true
minSdkVersion 19
minSdkVersion 21
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}

Expand All @@ -45,7 +45,7 @@ dependencies {
coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:1.2.2'
implementation "androidx.core:core:1.3.0"
implementation "androidx.media:media:1.1.0"
implementation "com.google.code.gson:gson:2.8.9"
implementation "com.google.code.gson:gson:2.11.0"

testImplementation 'junit:junit:4.12'
testImplementation 'org.mockito:mockito-core:3.10.0'
Expand Down
27 changes: 0 additions & 27 deletions flutter_local_notifications/example/android/app/proguard-rules.pro

This file was deleted.

0 comments on commit 8f262ab

Please sign in to comment.