Skip to content

Instantly share code, notes, and snippets.

@peterblazejewicz
Created July 27, 2011 08:58
Show Gist options
  • Save peterblazejewicz/1108962 to your computer and use it in GitHub Desktop.
Save peterblazejewicz/1108962 to your computer and use it in GitHub Desktop.
pathForFlash helper - converts to FILE protocol and full path URI
function pathForFlash(path:String):String
{
// in ZINC runtime convert paths to URI FIle protocol
// for content loading via Flash native features
if(mdm.Application && mdm.Application.filename.length)
{
return "file://"+mdm.Application.path.split("\\").join("/")+path;
};
return path;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment