Closed zwacky closed 7 years ago
@zwacky thanks for using snackbar plugin, currently at work after finish will try to repro on 4.2.2 and inform you, but it should work fine!
@zwacky Can you test if it works fine on other device? Also could you please upload a sample of your app where the plugin doesn't work. Thanks!
it does work fine on other devices (nexus 5+).
i just used the window.cordova.plugins.snackbar(...)
directly in the console in both devices.
tried on genymotion, Samsung Galaxy S4 - 4.2.2 - API 17.
@zwacky I used Genymotion Samsung Galaxy S4 - 4.2.2 -API 17 and it's working fine. Could you please paste the code where you add the snackbar. Or app sample even better!
I use window.cordova.plugins.snackbar('Test', 'SHORT', 'DISMISS');
from the console and it doesn't show up.
on a nexus 5 emulator though it does.
@zwacky Could you please what debug tool do you use, I just tried and still works fine even with:
window.cordova.plugins.snackbar('Test', 'SHORT', 'DISMISS');
that is weird... i'm using chrome dev tools, along with xwalk 15
i have a same problem i'm using the snackbar plugin like that function ajaxError() cordova.plugins.snackbar('Pas de connexion internet', 'INDEFINITE', 'Réessayez', function(){ var cloneRecursive; if(activeView === "pfluxrss") { cloneRecursive = new GetRssFlux(headerName,urlToFluxRss,fillPanel); } else if(activeView === "pweather") { cloneRecursive = new GetWeather(url, loader); }
});
} And somewhere else in the code when the ajax request return an error i calling ajaxError(); when i'm doing that my app crashed both on cordova app and crosswalk cordova app i have an android 5.1
@ishigo1987 if it's crashing, then it's another issue. for me it simply was ignored.
I also had crashes before, but could resolve them. you may wanna start adb logcat
and see what causes the error.
how to use adb logcat?i'm using intel xdk to build the app and i'm very newbie with the log file on android
i think that i need to download android studio before you can use adb logcat is it true?
only the android SDK is needed - which you have, since you build the android app on your machine.
just type adb logcat
into your command line. if that doesn't work, you'd need to adjust your system environment paths to include android SDK directory. google that for your platform, if you need assistance with it.
ok copy thank you
@ishigo1987 you must replace the DefaultTheme with the AppCompat Theme in Manifest file manually:
@echonox I use intel xdk, accordancing with their documentation it is not possible to directly manipulate the manifest file (as it is in the cloud) .on needs to be able to manipulate create a fake plugin and add the information in plugin.xml below here is the content of my plugin.xml. But it does not work. can you tell me please where I am wrong? <?xml version="1.0" encoding="UTF-8"?>
@ishigo1987 That is the reason that it must be edited manually I know that we can modify the Manifest file via plugin, but the problem is that cordova isn't replacing the theme instead it adds a new line to the manifest file which ends up in an error.
A workaround for your problem: You could build the app with Intel XDK get the APK and then with 7zip edit the manifest file replace the line and pack the manifest file back to the apk with 7zip
I open the Manifest but it is encrypted. please do you know how I can do to decrypt the Manifest File?
@ishigo1987 Intel XDK announced they are abandoning the project, sorry but can't do anything regarding this issue
no problem @echonox i leave intel xdk since a decade lol
hey there on a Galaxy S4 (4.2.2) there is no snackbar shown and no errors in logcat and console.
is there an API requirement? if no, maybe a
isAvailable()
function is useful?cheers