Multiple game breakers on Android
Lingomat opened this issue · comments
Plugin basically doesn't work using with events. AudioInputCapture.java has this in initialize and start:
String fileUrlString = args.getString(5);
if (fileUrlString != null) {
this.fileUrl = new URI(fileUrlString);
// ensure it's a file URL
new File(this.fileUrl);
}
I don't know much about Java but that's clear broken. This seems to work:
if (!args.isNull(5)) {
String fileUrlString = args.getString(5);
this.fileUrl = new URI(fileUrlString);
// ensure it's a file URL
new File(this.fileUrl);
}
I'd PR it but even with the fix the window audioinput event only fires once and not repeatedly as expected.
Thanks for the suggestion, it's part of the fix, which I've just pushed to https://github.com/nzilbb/cordova-plugin-audioinput
A pull request has been created.
Ooo, thanks for that. Your PR makes other changes which looks like it might address the fire-once thing too? I guess I should try figure out how to debug java so I can contribute directly when possible.
Confirmed, works great.
The PR has been merged. Thanks for the quick fix @robertfromont and thanks for telling us about the problem @Lingomat