@Ghazascanner
_2019runbot
Ghazascanner File Manager
server :Linux phosweb008 3.10.0-1160.el7.x86_64 #1 SMP Mon Oct 19 16:18:59 UTC 2020 x86_64
Current Path :
/
homepage
/
v-mt
/
mt-static
/
js
/
flash
/
Path :
Upload File :
New :
File
Dir
//homepage/v-mt/mt-static/js/flash/FlashProxy.js
/** * The FlashProxy object is what proxies function calls between JavaScript and Flash. * It handles all argument serialization issues. */ /** * Instantiates a new FlashProxy object. Pass in a uniqueID and the name (including the path) * of the Flash proxy SWF. The ID is the same ID that needs to be passed into your Flash content as lcId. */ function FlashProxy(uid, proxySwfName) { this.uid = uid; this.proxySwfName = proxySwfName; this.flashSerializer = new FlashSerializer(false); } /** * Call a function in your Flash content. Arguments should be: * 1. ActionScript function name to call, * 2. any number of additional arguments of type object, * array, string, number, boolean, date, null, or undefined. */ FlashProxy.prototype.call = function() { if (arguments.length == 0) { throw new Exception("Flash Proxy Exception", "The first argument should be the function name followed by any number of additional arguments."); } var qs = 'lcId=' + escape(this.uid) + '&functionName=' + escape(arguments[0]); if (arguments.length > 1) { var justArgs = new Array(); for (var i = 1; i < arguments.length; ++i) { justArgs.push(arguments[i]); } qs += ('&' + this.flashSerializer.serialize(justArgs)); } var divName = '_flash_proxy_' + this.uid; if(!document.getElementById(divName)) { var newTarget = document.createElement("div"); newTarget.id = divName; document.body.appendChild(newTarget); } var target = document.getElementById(divName); var ft = new FlashTag(this.proxySwfName, 1, 1); ft.setVersion('6,0,65,0'); ft.setFlashvars(qs); target.innerHTML = ft.toString(); } /** * This is the function that proxies function calls from Flash to JavaScript. * It is called implicitly. */ FlashProxy.callJS = function() { var functionToCall = eval(arguments[0]); var argArray = new Array(); for (var i = 1; i < arguments.length; ++i) { argArray.push(arguments[i]); } functionToCall.apply(functionToCall, argArray); }