define("share/assert/js/appcontext",["./path"],function(require,exports){var a=require("./path"),b={};b.RunningPlatform={PC:"PC",CEF:"CEF",Android:"Android",Web:"Web"},b.containerOffset={width:0,height:0},b.zoomRate={x:1,y:1},b.strokeBase64Arr=[],b.newBlankSlides=[],b.isCurNewBlankSlide=!1,b.isSingleWidgetPlayMode=!1,b.singleWidgetType="",b.singleWidgetPath="",b.singleWidgetRouteAddress="",b.rightClicked=null,b.selectedCopyTarget=null,b.oldAnimationInfo=null,b.pasteTimes=0,b.packageName="lotuspackage",b.setPackageName=function(a){a&&(b.packageName=a)},b.packagePath="",b.getBinPath=function(){var b=a.resolve("./"),c=b.substr(0,b.lastIndexOf(":\\")),d=c.toUpperCase();return b=b.replace(c,d)},b.getCurSlidePackPath=function(){return b.packagePath},b.setCurSlidePackPath=function(c,d){c=a.toPosix(c),b.packagePath=d?c.substr(0,c.lastIndexOf("/")):c},b.getTmpPackPath=function(){return a.join(b.getBinPath(),"tmp")},b.getPackageJsonPath=function(){return a.join(b.getCurSlidePackPath(),"/manifest.json")},b.getPackageThumbPath=function(){return a.join(b.getCurSlidePackPath(),"/thumbnail.jpg")},b.getDefaultImagePath=function(){return a.join(this.getBinPath(),"/share/assert/images")},b.getDefaultTemplate=function(){return a.join(this.getBinPath(),"/template")},b.getExerciseExamplePath=function(){return a.join(this.getBinPath(),"/template/exerciseExample/slides/1.sco")},b.joinPath=function(){return a.join.apply(this,arguments)},b.getSVGPath=function(){return this.joinPath(this.getBinPath(),"editor/assert/svg")},b.pluginPath=function(){var a=this.getBinPath();return a=a.substr(0,a.lastIndexOf("\\")+1)},"PC"===RunningPlatform&&b.setCurSlidePackPath(a.join(b.getBinPath(),b.packageName),!1),"Android"===RunningPlatform&&b.setCurSlidePackPath(b.packageName,!1),b.getFontWidth=function(a,b){var c=document.getElementById("__getwidth");return null==c&&(c=document.createElement("span"),c.id="__getwidth",document.body.appendChild(c),c.style.visibility="hidden",c.style.whiteSpace="nowrap"),c.innerText=b,c.style.fontSize=a+"px",c.offsetWidth},b.clone=function(a){if("object"!=typeof a)return a;if(null==a)return a;var c=new Object;for(var d in a)c[d]=b.clone(a[d]);return c},exports.AppContext=b}),define("share/assert/js/path",[],function(require,exports){function a(a,b){for(var c=0,d=a.length-1;d>=0;d--){var e=a[d];"."===e?a.splice(d,1):".."===e?(a.splice(d,1),c++):c&&(a.splice(d,1),c--)}if(b)for(;c--;c)a.unshift("..");return a}var b=/^(http:\/)([^\/])/i,c=/^(file:\/)([^\/])/i,d=/^(\/?)([\s\S]+\/(?!$)|\/)?((?:\.{1,2}$|[\s\S]+?)?(\.[^.\/]*)?)$/,e=function(a){var b=d.exec(a);return[b[1]||"",b[2]||"",b[3]||"",b[4]||""]};exports.resolve=function(){for(var b="",c=!1,d=arguments.length-1;d>=-1&&!c;d--){var e="";"PC"===RunningPlatform&&(e=d>=0?arguments[d]:process.cwd()),"Android"===RunningPlatform&&(e=d>=0?arguments[d]:"./"),"string"==typeof e&&e&&(b=e+"/"+b,c="/"===e.charAt(0))}return b=a(b.split("/").filter(function(a){return!!a}),!c).join("/"),(c?"/":"")+b||"."},exports.normalize=function(d){var e="/"===d.charAt(0),f="/"===d.substr(-1);return d=a(d.split("/").filter(function(a){return!!a}),!e).join("/"),d||e||(d="."),d&&f&&(d+="/"),d=(e?"/":"")+d,d=d.replace(b,"$1/$2"),d=d.replace(c,"$1//$2")},exports.join=function(){var a=Array.prototype.slice.call(arguments,0);return exports.toPosix(exports.normalize(a.filter(function(a){return a&&"string"==typeof a}).join("/")))},exports.relative=function(a,b){function c(a){for(var b=0;b<a.length&&""===a[b];b++);for(var c=a.length-1;c>=0&&""===a[c];c--);return b>c?[]:a.slice(b,c-b+1)}a=exports.resolve(a).substr(1),b=exports.resolve(b).substr(1);for(var d=c(a.split("/")),e=c(b.split("/")),f=Math.min(d.length,e.length),g=f,h=0;f>h;h++)if(d[h]!==e[h]){g=h;break}for(var i=[],h=g;h<d.length;h++)i.push("..");return i=i.concat(e.slice(g)),i.join("/")},exports.dirname=function(a){var b=e(a),c=b[0],d=b[1];return c||d?(d&&(d=d.substr(0,d.length-1)),c+d):"."},exports.basename=function(a,b){var c=e(a)[2];return b&&c.substr(-1*b.length)===b&&(c=c.substr(0,c.length-b.length)),c},exports.extname=function(a){return e(a)[3]},exports.filename=function(a){return e(a)[2]},exports.toPosix=function(a){return/^[a-zA-Z]\:\\/.test(a)&&(a=a.replace(/\\/g,"/")),a},exports.toWindows=function(a){return a.replace(/\//g,"\\\\")},exports.trimPosix=function(a){return a.replace(/\bfile:(\/+)/g,"")},exports.sep="/",exports.delimiter=":"});