forked from EddyVerbruggen/Toast-PhoneGap-Plugin
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix for API 30 / Android 11 by removing deprecated API calls.
Resolves EddyVerbruggen#136
- Loading branch information
Showing
1 changed file
with
38 additions
and
105 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
7a61201
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @dpa99c ,
Getting error on cordova build android
FAILURE: Build failed with an exception.
Execution failed for task ':app:compileDebugJavaWithJavac'.
Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
Get more help at https://help.gradle.org
Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.5/userguide/command_line_interface.html#sec:command_line_warnings
BUILD FAILED in 5s
31 actionable tasks: 6 executed, 25 up-to-date
Command failed with exit code 1: /platforms/android/gradlew cdvBuildDebug -b /platforms/android/build.gradle
$ cordova platforms ls
Installed platforms:
android 9.1.0
ios 6.2.0
Available platforms:
browser ^6.0.0
electron ^1.0.0
osx ^6.0.0
$ cordova -v
10.0.0
$ cordova plugins ls
cordova-custom-config 5.1.0 "cordova-custom-config"
cordova-play-services-version-adapter 1.0.2 "Cordova/Ionic Google Play Services Versions Incompatibility Adapter"
cordova-plugin-app-version 0.1.12 "AppVersion"
cordova-plugin-appavailability 0.4.2 "AppAvailability"
cordova-plugin-camera 5.0.2 "Camera"
cordova-plugin-crop 0.3.1 "CropPlugin"
cordova-plugin-device 2.0.3 "Device"
cordova-plugin-dialogs 2.0.2 "Notification"
cordova-plugin-doubledummysolver 2.0.0 "Double Dummy Solver"
cordova-plugin-file 6.0.2 "File"
cordova-plugin-globalization 1.11.0 "Globalization"
cordova-plugin-inappbrowser 4.1.0 "InAppBrowser"
cordova-plugin-insomnia 4.3.0 "Insomnia (prevent screen sleep)"
cordova-plugin-network-information 2.0.2 "Network Information"
cordova-plugin-purchase 9.0.0 "Purchase"
cordova-plugin-splashscreen 6.0.0 "Splashscreen"
cordova-plugin-statusbar 2.4.3 "StatusBar"
cordova-plugin-vibration 3.1.1 "Vibration"
cordova-plugin-webviewcolor 2.2.0 "WebView background color plugin"
cordova-plugin-whitelist 1.3.4 "Whitelist"
cordova-plugin-x-socialsharing 5.6.8 "SocialSharing"
cordova-plugin-x-toast 2.7.2 "Toast"
cordova-support-android-plugin 1.0.2 "cordova-support-android-plugin"
cordova-support-google-services 1.1.0 "cordova-support-google-services"
es6-promise-plugin 4.2.2 "Promise"
phonegap-plugin-multidex 1.0.0 "Multidex"
phonegap-plugin-push 2.2.3 "PushPlugin"
7a61201
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I needed add this(if) to work API less 30
if (Build.VERSION.SDK_INT >= 30) {
toast.addCallback(new android.widget.Toast.Callback() {
public void onToastShown() {
}
Great Job