Application.jsfl为程序入口,导入其他jsfl
【Common.jsfl】 function trace() { fl.trace(Array.prototype.join.call(arguments, " ")); }
【Application.jsfl】 var JSFL_PATH = fl.scriptURI.substr(0,fl.scriptURI.lastIndexOf("/")+1); var included = {}; function include(file) { if (included[file]) { return; } included[file] = true; fl.runScript(JSFL_PATH + file + ".jsfl"); } include("Common"); trace("Common lib included");
JSFL 获取当前脚本路径,执行其他脚本,布布扣,bubuko.com
原文:http://www.cnblogs.com/kenkofox/p/3816750.html