Hey,
i have a problem with my jsx script using a external swf as gui.
My flash doenst seems to have a as external interface the script(?).
Basicly my question is, whats needed to call a function from swf in the jsx script?
JSX Script:
Code: Select allvar destinationPath = "P:\\Hendrik\\Projekte\\mopas\\entwuerfe\\icons\\vector\\neu";
var prefix = "ic_";
var res =
"dialog { \
fp: FlashPlayer { preferredSize: [364, 100] }, \
}";
var w = new Window (res,"Android Icon Generator");
w.margins = [0,0,0,0];
w.onShow = function () {
var myJSXPath = whereAmI();
var mySWFFile = myJSXPath + "/android-icon-generator.swf"
var movieToPlay = new File (mySWFFile);
try {
this.fp.loadMovie (movieToPlay);
this.fp.playMovie ();
this.fp.getData = getData;
} catch (e) {
alert ("Load Movie function failed: " + e);
}
}
w.show();
SWF File:
Code: Select allimport flash.external.*;
stop();
var pfad, aktion;
_start.addEventListener(MouseEvent.CLICK, function() {
pfad = _pfad.text;
if(pfad == '')
{
gotoAndStop(3);
}
else
{
if(ExternalInterface.available)
ExternalInterface.call("getData");
}
});
Thanks in advance.