I have been struggling with this problem for WEEKS now and can't solve it. I have an flash AIR app (creative cloud, AIR 3.8) which is very simple: all it does is load external SWF movies on the click of a start button. It works FINE in test/PC but when I publish to device, the external swfs do not load.
HEre is the code on the main timeline that calls the external swfs:
//start button
start_button_TRI_coelophysis.addEventListener(MouseEvent.CLICK,
fl_ClickToLoadUnloadSWF_01_3,false,0,true);
import fl.display.ProLoader;
import flash.events.Event;
var fl_ProLoader_01:ProLoader;
var fl_ToLoad_01:Boolean = true;
function fl_ClickToLoadUnloadSWF_01_3(event:MouseEvent):void
{
if(fl_ToLoad_01)
{
fl_ProLoader_01 = new ProLoader();
fl_ProLoader_01.load(new URLRequest("dinofilms/triassic_coelophysis.swf"));
fl_ProLoader_01.contentLoaderInfo.addEventListener(Event.COMPLETE,onComplete_01)
addChild(fl_ProLoader_01);
fl_ProLoader_01.x = 0;
fl_ProLoader_01.y = 144;
}
else
{
if(fl_ProLoader_01!=null) {
removeChild(fl_ProLoader_01);
fl_ProLoader_01.unloadAndStop();
fl_ProLoader_01 = null;
}
}
fl_ToLoad_01 = !fl_ToLoad_01;
}
function onComplete_01(e:Event):void {
e.currentTarget.content.addEventListener(Event.ENTER_FRAME,OEF_01);
}
function OEF_01(e:Event):void {
if(e.currentTarget.currentFrame==e.currentTarget.totalFrames) {
e.currentTarget.stop();
e.currentTarget.removeEventListener(Event.ENTER_FRAME,OEF_01);
removeChild(fl_ProLoader_01);
fl_ProLoader_01.unloadAndStop();
fl_ProLoader_01 = null;
}
}
I am calling about 30 different movies on 30 different frames, so that's why I am using tags like "proLoader_01" so I don't duplicate them. All the external swfs are of course listed in the included files too.