cordova-plugin-media 3.0.1 is installed, but Media constructor is not defined.
var media = new Media(src, mediaSuccess, [mediaError], [mediaStatus]);
produces "Uncaught reference error: Media is not defined"
I am testing on Android 6 phone. Any ideas why this plugin does not provide Media constructor?
This bit me a couple of days ago. Use window.Media() instead.
Related
Is anyone know how to call JS function from dart ?
I followed steps which linked below.
Firstly, appear this error.
"Error: Not found: 'dart:js' import 'dart:js';"
I followed previous answer which comment this line from js.dart and fixed it.
[export 'dart:js' show allowInterop, allowInteropCaptureThis;].
But now I got another error below.
No top-level method 'callJsFunc' declared. Receiver: top-level Tried calling: callJsFunc()
Is anyone know how to fix this error ?
text
I tried other Flutter SDK version (latest one and 3.0.5) but got same error.
flutter uses dart not javascript.
so... actually you require a separate javascript engine if you want to use javascript with flutter and that can be done with dart ffi unless you are building a web app with flutter.
However, there is a library called flutter_js and you can use it if you need to run javascript.
On the other hand, if you are interested in using embeddable Javascript engine with your flutter project by yourself.
you should check this link out where it shows how to use ffi for attaching an embeddable Javascript engine called Duktape
I am learning SwiftUI, from scratch and trying to show a Image from a URL, I am using the built in AsyncImage method, yet I get this error with no context.
Cannot call value of non-function type 'module<AsyncImage>', Googling didn't help and I am following the exact same code line-by-line from a article I am following..
Here's some more details from the diagnostics popup, I received.
cannot call value of non-function type 'module'
SchemeBuildError: Failed to build the scheme "AsyncImage"
cannot call value of non-function type 'module'
Compile ContentView.swift (x86_64):
/Users/fayaz/Learn/AsyncImage/AsyncImage/ContentView.swift:14:9:
error: cannot call value of non-function type 'module'
AsyncImage(url: URL(string: imageUrl))
^
Here's my setup.
Macos BigSur v11.0.1
Xcode Version 12.5
Your project seems to be called AsyncImage, so without knowing all the other objects in your project its hard to know whether there would be some naming conflict.
However, your main issue is that AsyncImage is iOS 15+. That means currently, your version of Xcode (you said 12.5) doesn't support it. You would need to install Xcode 13 for the latest API. That would however require an Apple Developer account (can't remember whether the free version allows access to beta software though).
i added the cordova-notification plugin into intel-xdk appication, when try to show the indicator i get this error:
Uncaught TypeError: Cannot read property 'showBusyIndicator' of undefined
this is the code:
$(document).on("change","#sel_produttori", function(evt)
{
intel.xdk.notification.showBusyIndicator();
});
maybe it is strange the plugin is listed in the first window but not in the second one.
Many of the 'intel.xdk' plugins have been or are being deprecated in favor of their standard core Cordova counterparts. I would recommend using that instead.
The problem you're running into appears to be that you've included the standard Cordova notification plugin, but you're trying to access the intel.xdk notification plugin, which is not included and therefore doesn't exist in your app.
It looks like the corresponding method on the standard Cordova Notification plugin was deprecated some time back and isn't there anymore. You might want to try a plugin like this:
https://github.com/filfat-Studios-AB/cordova-plugin-spinnerdialog
It seems to work for me but, as always, use at your own risk.
I'm doing a project for iOS in Unity and all works fine, but I'd like to also build for Web Player for testing purposes. The problem is once I switch platform to Web Player I get the following errors.
Assets/Main.cs(50,45): error CS0117: `System.IO.File' does not contain a definition for `ReadAllText'
Assets/Main.cs(51,29): error CS1502: The best overloaded method match for `SimpleJSON.JSON.Parse(string)' has some invalid arguments
Assets/Main.cs(51,29): error CS1503: Argument `#1' cannot convert `object' expression to type `string'
Obviously it's about unsupported API in Web Player, but how do I get around that?
You need to use "Platform Dependent Compilation" http://docs.unity3d.com/Manual/PlatformDependentCompilation.html
And include any platform specific code in relevant ifs, elifs and endifs.
#if !UNITY_WEBPLAYER
using System.IO.File;
#endif
I've being trying to implement a native File picker on BlackBerry 10 today, I linked it against the required Library -lbbcascadespickers
Included <bb/cascades/pickers/FilePicker> that links to the FilePicker.hpp class and all seems fine, but when I try to create a new File picker it says "error: 'FilePicker' was not declared in this scope"
Code is as follows:
FilePicker* filePicker = new FilePicker();
filePicker->setType(FileType::Picture);
filePicker->setTitle("Select Picture");
filePicker->setMode(FilePickerMode::Picker);
filePicker->open();
// Connect the fileSelected() signal with the slot.
QObject::connect(filePicker,
SIGNAL(fileSelected(const QStringList&)),
this,
SLOT(onFileSelected(const QStringList&)));
// Connect the canceled() signal with the slot.
QObject::connect(filePicker,
SIGNAL(canceled()),
this,
SLOT(onCanceled()));
I'm brand new to BlackBerry development so don't really know what to do, I've cleaned the project and built it many times but it won't play.
I was going by the example on BlackBerry's website:
https://developer.blackberry.com/native/reference/cascades/bb_cascades_pickers__filepicker.html
I wanted to open it from QML (I'm using Qt Quick and not BB components)
If anyone can help it will be deeply appreciated
The compiler can't find FilePicker. So either use a using to tell the compiler where to look:
using namespace bb::cascades::pickers;
or fully qualify the name of the class:
bb::cascades::pickers::FilePicker* filePicker = new FilePicker();