diff --git a/Gruntfile.js b/Gruntfile.js index 4f6b96f0d..69a15d267 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -216,8 +216,8 @@ module.exports = function(grunt) { .replace(/^[ \t]*var\s+\S+\s*=\s*require\((['"]).*?\1\);/gm, '') .replace(/^[ \t]*(if\s+\(NODE\)\s*|)module\.exports\s*=\s*\S+;/gm, '') .replace(/\/\*\*\s*\*\s*@fileoverview[\s\S]*?\*\/\s*/g, '') - .replace(/[ \t]*if\s*\(NODE\)\s*(\{[^}]*}|[^\n]*)(\n|$)/gm, '') - .replace(/[ \t]*if\s*\(typeof\s+module\s*!==\s*(['"])undefined\1\)\s*(\{[^}]*}|[^\n]*)(\n|$)/gm, '') + .replace(/[ \t]*if\s*\(NODE\)\s*({[^}]*}|[^\n]*)(\n|$)/gm, '') + .replace(/[ \t]*if\s*\(typeof\s+module\s*!==\s*(['"])undefined\1\)\s*({[^}]*}|[^\n]*)(\n|$)/gm, '') .replace(/[ \t]*[A-Za-z_][A-Za-z0-9_.]*\.assert\([^\n]*\);[^\n]*/g, ''); } } @@ -234,8 +234,8 @@ module.exports = function(grunt) { .replace(/^[ \t]*var\s+\S+\s*=\s*require\((['"]).*?\1\);/gm, '') .replace(/^[ \t]*(if\s+\(NODE\)\s*|)module\.exports\s*=\s*\S+;/gm, '') .replace(/\/\*\*\s*\*\s*@fileoverview[\s\S]*?\*\/\s*/g, '') - .replace(/[ \t]*if\s*\(NODE\)\s*(\{[^}]*}|[^\n]*)(\n|$)/gm, '') - .replace(/[ \t]*if\s*\(typeof\s+module\s*!==\s*(['"])undefined\1\)\s*(\{[^}]*}|[^\n]*)(\n|$)/gm, '') + .replace(/[ \t]*if\s*\(NODE\)\s*({[^}]*}|[^\n]*)(\n|$)/gm, '') + .replace(/[ \t]*if\s*\(typeof\s+module\s*!==\s*(['"])undefined\1\)\s*({[^}]*}|[^\n]*)(\n|$)/gm, '') .replace(/[ \t]*[A-Za-z_][A-Za-z0-9_.]*\.assert\([^\n]*\);[^\n]*/g, ''); } } @@ -252,8 +252,8 @@ module.exports = function(grunt) { .replace(/^[ \t]*var\s+\S+\s*=\s*require\((['"]).*?\1\);/gm, '') .replace(/^[ \t]*(if\s+\(NODE\)\s*|)module\.exports\s*=\s*\S+;/gm, '') .replace(/\/\*\*\s*\*\s*@fileoverview[\s\S]*?\*\/\s*/g, '') - .replace(/[ \t]*if\s*\(NODE\)\s*(\{[^}]*}|[^\n]*)(\n|$)/gm, '') - .replace(/[ \t]*if\s*\(typeof\s+module\s*!==\s*(['"])undefined\1\)\s*(\{[^}]*}|[^\n]*)(\n|$)/gm, '') + .replace(/[ \t]*if\s*\(NODE\)\s*({[^}]*}|[^\n]*)(\n|$)/gm, '') + .replace(/[ \t]*if\s*\(typeof\s+module\s*!==\s*(['"])undefined\1\)\s*({[^}]*}|[^\n]*)(\n|$)/gm, '') .replace(/[ \t]*[A-Za-z_][A-Za-z0-9_.]*\.assert\([^\n]*\);[^\n]*/g, ''); } } @@ -270,8 +270,8 @@ module.exports = function(grunt) { .replace(/^[ \t]*var\s+\S+\s*=\s*require\((['"]).*?\1\);/gm, '') .replace(/^[ \t]*(if\s+\(NODE\)\s*|)module\.exports\s*=\s*\S+;/gm, '') .replace(/\/\*\*\s*\*\s*@fileoverview[\s\S]*?\*\/\s*/g, '') - .replace(/[ \t]*if\s*\(NODE\)\s*(\{[^}]*}|[^\n]*)(\n|$)/gm, '') - .replace(/[ \t]*if\s*\(typeof\s+module\s*!==\s*(['"])undefined\1\)\s*(\{[^}]*}|[^\n]*)(\n|$)/gm, '') + .replace(/[ \t]*if\s*\(NODE\)\s*({[^}]*}|[^\n]*)(\n|$)/gm, '') + .replace(/[ \t]*if\s*\(typeof\s+module\s*!==\s*(['"])undefined\1\)\s*({[^}]*}|[^\n]*)(\n|$)/gm, '') .replace(/[ \t]*[A-Za-z_][A-Za-z0-9_.]*\.assert\([^\n]*\);[^\n]*/g, ''); } } @@ -288,8 +288,8 @@ module.exports = function(grunt) { .replace(/^[ \t]*var\s+\S+\s*=\s*require\((['"]).*?\1\);/gm, '') .replace(/^[ \t]*(if\s+\(NODE\)\s*|)module\.exports\s*=\s*\S+;/gm, '') .replace(/\/\*\*\s*\*\s*@fileoverview[\s\S]*?\*\/\s*/g, '') - .replace(/[ \t]*if\s*\(NODE\)\s*(\{[^}]*}|[^\n]*)(\n|$)/gm, '') - .replace(/[ \t]*if\s*\(typeof\s+module\s*!==\s*(['"])undefined\1\)\s*(\{[^}]*}|[^\n]*)(\n|$)/gm, '') + .replace(/[ \t]*if\s*\(NODE\)\s*({[^}]*}|[^\n]*)(\n|$)/gm, '') + .replace(/[ \t]*if\s*\(typeof\s+module\s*!==\s*(['"])undefined\1\)\s*({[^}]*}|[^\n]*)(\n|$)/gm, '') .replace(/[ \t]*[A-Za-z_][A-Za-z0-9_.]*\.assert\([^\n]*\);[^\n]*/g, ''); } } diff --git a/README.md b/README.md index ba31be258..0f9ec1934 100644 --- a/README.md +++ b/README.md @@ -213,9 +213,9 @@ To ensure consistent compilation results, a copy of the Closure Compiler has bee commands to confirm that everything is working properly: java -version - + which should report a version >= 1.7; eg: - + java version "1.7.0_67" Java(TM) SE Runtime Environment (build 1.7.0_67-b01) Java HotSpot(TM) 64-Bit Server VM (build 24.65-b04, mixed mode) @@ -223,7 +223,7 @@ which should report a version >= 1.7; eg: Then run: java -jar bin/compiler.jar --version - + which should report: Closure Compiler (http://github.com/google/closure-compiler) diff --git a/apps/pcx86/1981/visicalc/README.md b/apps/pcx86/1981/visicalc/README.md index 02da3c89d..c767017a1 100644 --- a/apps/pcx86/1981/visicalc/README.md +++ b/apps/pcx86/1981/visicalc/README.md @@ -5,7 +5,7 @@ permalink: /apps/pcx86/1981/visicalc/ machines: - id: ibm5150-visicalc type: pcx86 - config: /devices/pcx86/machine/5150/mda/64kb/machine.xml + config: /devices/pcx86/machine/5150/mda/64kb/debugger/machine.xml resume: 1 state: /apps/pcx86/1981/visicalc/state.json autoMount: diff --git a/apps/pcx86/1981/visicalc/manifest.xml b/apps/pcx86/1981/visicalc/manifest.xml index 27cd175d8..1b128d91a 100644 --- a/apps/pcx86/1981/visicalc/manifest.xml +++ b/apps/pcx86/1981/visicalc/manifest.xml @@ -1,5 +1,5 @@ - + VisiCalc diff --git a/apps/pcx86/1982/esuite/manifest.xml b/apps/pcx86/1982/esuite/manifest.xml index 3c3a88a72..b290d5e44 100644 --- a/apps/pcx86/1982/esuite/manifest.xml +++ b/apps/pcx86/1982/esuite/manifest.xml @@ -1,5 +1,5 @@ - + Executive Suite diff --git a/apps/pcx86/1982/ratbas/manifest.xml b/apps/pcx86/1982/ratbas/manifest.xml index 504070644..f70825992 100644 --- a/apps/pcx86/1982/ratbas/manifest.xml +++ b/apps/pcx86/1982/ratbas/manifest.xml @@ -1,5 +1,5 @@ - + RatBas 2.13 diff --git a/apps/pcx86/1983/adventmath/manifest.xml b/apps/pcx86/1983/adventmath/manifest.xml index 2fabb33df..c2ba62f6a 100644 --- a/apps/pcx86/1983/adventmath/manifest.xml +++ b/apps/pcx86/1983/adventmath/manifest.xml @@ -1,5 +1,5 @@ - + Adventures in Math 1.00 diff --git a/apps/pcx86/1985/rogue/manifest.xml b/apps/pcx86/1985/rogue/manifest.xml index 8787130c6..b8701acb4 100644 --- a/apps/pcx86/1985/rogue/manifest.xml +++ b/apps/pcx86/1985/rogue/manifest.xml @@ -1,5 +1,5 @@ - + Rogue 1.49 diff --git a/apps/pcx86/1987/thinktank/manifest.xml b/apps/pcx86/1987/thinktank/manifest.xml index 360ae81bc..76358e304 100644 --- a/apps/pcx86/1987/thinktank/manifest.xml +++ b/apps/pcx86/1987/thinktank/manifest.xml @@ -1,5 +1,5 @@ - + ThinkTank 2.41NP diff --git a/apps/pcx86/1988/moria/manifest.xml b/apps/pcx86/1988/moria/manifest.xml index 08e4861fc..ad3cebb70 100644 --- a/apps/pcx86/1988/moria/manifest.xml +++ b/apps/pcx86/1988/moria/manifest.xml @@ -1,5 +1,5 @@ - + The Dungeons of Moria 4.872 diff --git a/apps/pcx86/1992/moria/manifest.xml b/apps/pcx86/1992/moria/manifest.xml index 19785c007..68317adac 100644 --- a/apps/pcx86/1992/moria/manifest.xml +++ b/apps/pcx86/1992/moria/manifest.xml @@ -1,5 +1,5 @@ - + The Dungeons of Moria 5.5 diff --git a/apps/pcx86/examples/components.xsl b/apps/pcx86/examples/components.xsl index 3c1f21052..a117e3835 100644 --- a/apps/pcx86/examples/components.xsl +++ b/apps/pcx86/examples/components.xsl @@ -14,12 +14,12 @@ pcjs pcx86 PCx86 - 1.37.0 + 1.37.1 www.pcjs.org #FAEBD7 - + diff --git a/apps/pcx86/examples/examples.zip b/apps/pcx86/examples/examples.zip index 591beebde..f3ac3c1be 100644 Binary files a/apps/pcx86/examples/examples.zip and b/apps/pcx86/examples/examples.zip differ diff --git a/apps/pcx86/examples/pcx86-dbg.js b/apps/pcx86/examples/pcx86-dbg.js index 023df10c6..5ce5e8330 100644 --- a/apps/pcx86/examples/pcx86-dbg.js +++ b/apps/pcx86/examples/pcx86-dbg.js @@ -44,12 +44,12 @@ http://pcjs.org/modules/shared/lib/save.js (C) Jeff Parsons 2012-2017 */ var l,aa,ba="function"==typeof Object.create?Object.create:function(a){function b(){}b.prototype=a;return new b},ca;if("function"==typeof Object.setPrototypeOf)ca=Object.setPrototypeOf;else{var da;a:{var ea={Hd:!0},fa={};try{fa.__proto__=ea;da=fa.Hd;break a}catch(a){}da=!1}ca=da?function(a,b){a.__proto__=b;if(a.__proto__!==b)throw new TypeError(a+" is not extensible");return a}:null}var ha=ca; -function ia(a,b){a.prototype=ba(b.prototype);a.prototype.constructor=a;if(ha)ha(a,b);else for(var c in b)if("prototype"!=c)if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);d&&Object.defineProperty(a,c,d)}else a[c]=b[c];a.qq=b.prototype} +function ia(a,b){a.prototype=ba(b.prototype);a.prototype.constructor=a;if(ha)ha(a,b);else for(var c in b)if("prototype"!=c)if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);d&&Object.defineProperty(a,c,d)}else a[c]=b[c];a.rq=b.prototype} var ja="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ka="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global&&null!=global?global:this;function la(a,b){if(b){var c=ka;a=a.split(".");for(var d=0;da?-b:b}});la("Math.sign",function(a){return a?a:function(a){a=Number(a);return 0===a||isNaN(a)?a:0":62,"?":63,"@":64,ee:65,oi:66,pi:67,ri:68,E:69,si:70,ti:71,ui:72,vi:73,wi:74,xi:75,yi:76,zi:77,Ai:78,Bi:79,Ci:80,Q:81,Di:82,Ei:83,Fi:84,Gi:85,Hi:86,Ii:87,Ji:88,Ki:89,Yf:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Hd:97,nl:98,pl:99,d:100,e:101,yl:102,zl:103,Al:104,Bl:105,Vm:106,k:107,Xm:108,cn:109,n:110,nn:111,p:112,q:113,r:114,Ro:115,t:116,Vo:117, -Wo:118,Xo:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Tp:127},na={};na[173]=n["-"];na[186]=n[";"];na[187]=n["="];na[189]=n["-"];na[188]=n[","];na[190]=n["."];na[191]=n["/"];na[192]=n["`"];na[219]=n["["];na[220]=n["\\"];na[221]=n["]"];na[222]=n["'"];var pa={};pa[n["1"]]=n["!"];pa[n["2"]]=n["@"];pa[n["3"]]=n["#"];pa[n["4"]]=n.$;pa[n["5"]]=n["%"];pa[n["6"]]=n["^"];pa[n["7"]]=n["&"];pa[n["8"]]=n["*"];pa[n["9"]]=n["("];pa[n["0"]]=n[")"];pa[186]=n[":"];pa[187]=n["+"];pa[188]=n["<"];pa[189]=n._; +var ma={163840:[40,1,8,,254],184320:[40,1,9,,252],327680:[40,2,8,,255],368640:[40,2,9,,253],737280:[80,2,9,,249],1228800:[80,2,15,,249],1474560:[80,2,18,,240],2949120:[80,2,36,,240],10653696:[306,4,17],21411840:[615,4,17],256256:[77,1,26,128],2494464:[203,2,12,512],5242880:[256,2,40,256],10485760:[512,2,40,256]},n={tp:0,vp:1,wp:2,al:3,xp:4,yp:5,zp:6,Ap:7,Bp:8,Cp:9,Dp:10,Ep:11,Fp:12,Gp:13,Hp:14,Ip:15,Jp:16,Kp:17,Lp:18,Mp:19,Np:20,Op:21,Pp:22,Qp:23,Rp:24,Sp:25,Tp:26," ":32,"!":33,'"':34,"#":35,$:36, +"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,ee:65,pi:66,ri:67,si:68,E:69,ti:70,ui:71,vi:72,wi:73,xi:74,yi:75,zi:76,Ai:77,Bi:78,Ci:79,Di:80,Q:81,Ei:82,Fi:83,Gi:84,Hi:85,Ii:86,Ji:87,Ki:88,Li:89,Zf:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Hd:97,ol:98,ql:99,d:100,e:101,zl:102,Al:103,Bl:104,Cl:105,Wm:106,k:107,Xm:108,cn:109,n:110,on:111,p:112,q:113,r:114,So:115,t:116,Wo:117, +Xo:118,Yo:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Up:127},na={};na[173]=n["-"];na[186]=n[";"];na[187]=n["="];na[189]=n["-"];na[188]=n[","];na[190]=n["."];na[191]=n["/"];na[192]=n["`"];na[219]=n["["];na[220]=n["\\"];na[221]=n["]"];na[222]=n["'"];var pa={};pa[n["1"]]=n["!"];pa[n["2"]]=n["@"];pa[n["3"]]=n["#"];pa[n["4"]]=n.$;pa[n["5"]]=n["%"];pa[n["6"]]=n["^"];pa[n["7"]]=n["&"];pa[n["8"]]=n["*"];pa[n["9"]]=n["("];pa[n["0"]]=n[")"];pa[186]=n[":"];pa[187]=n["+"];pa[188]=n["<"];pa[189]=n._; pa[190]=n[">"];pa[191]=n["?"];pa[192]=n["~"];pa[219]=n["{"];pa[220]=n["|"];pa[221]=n["}"];pa[222]=n['"'];pa[173]=n._;pa[61]=n["+"];pa[59]=n[":"]; function qa(a,b){if(a){b||(b=10);var c,d=0=b&&(c=a.match(/(-?[0-9]+)B([0-9]*)/))&& (a=c[1],e=35-((c[2]||35)&255));c=a;if(((d=b)&&10!=d?16==d?null!==c.match(/^-?[0-9a-f]+$/i):8==d?null!==c.match(/^-?[0-7]+$/):2==d&&null!==c.match(/^-?[01]+$/):null!==c.match(/^-?[0-9]+$/))&&!isNaN(f=parseInt(a,b))){e&&(0>f&&(f+=Math.pow(2,36)),f=0a?this.ye=this.id:(this.de=this.id.substr(0,a),this.ye=this.id.substr(a+1));this.Z={ready:!1,lf:!1,Wg:!1,nf:!1,ac:!1,we:!1,error:!1};this.kg=null;this.Z.error=!1;this.dc=c||0;this.ca=this.G=this.oa=this.na=null;qb.push(this)} +bb(Ua("iOS")?"onpagehide":Ua("Opera")?"onunload":"onbeforeunload",function(){fb(db.exit)});function pb(a,b,c){this.type=a;b||(b={id:"",name:""});this.id=b.id||"";this.name=b.name;this.uj=b.comment;this.Jk=b;this.exports={};this.ma=this.bindings={};a=this.id.indexOf(".");0>a?this.ye=this.id:(this.de=this.id.substr(0,a),this.ye=this.id.substr(a+1));this.aa={ready:!1,mf:!1,Xg:!1,pf:!1,ac:!1,we:!1,error:!1};this.lg=null;this.aa.error=!1;this.dc=c||0;this.ca=this.G=this.oa=this.na=null;qb.push(this)} function rb(a,b,c){sb[a]&&b&&(sb[a][b]=c)}function kb(a){window&&window.alert(a)}function tb(a){var b=!1;window&&(b=window.confirm(a));return b}function ub(a,b){a.value+=b;b=a.value;8192e?d+=b+"\n":d=d.substr(0,e)+c+d.substr(e+b.length);8192Math.abs(a.B-b)?1:2),1==a.H?b=a.B:2==a.H&&(d=a.A));a.A=d;a.B=b;if(0<=d&&d>d.shift;d=g*a.oa.B;f=(g+f.lq)*a.oa.B-1;0f&&(d=f);c=d;break a}c=-1}if(-1!==c&&(c&=-16,c!=a.N)){b=c;if(a.context&&a.K&&a.L){e=ic-jc;f=a.K.width;a.L.fillStyle=kc;a.L.fillRect(0,e,f,jc);d=e+lc;g=a.K;var h=a.L,k,m=null.style.color,p=a.ka=10;a.D=p;a.J=d;a.ea=a.ba=lc;k||(k=a.U||a.ba+"px "+mc);a.aa=a.U=k;g&&(a.P=g);h&&(a.I=h,a.V=m||"white");a.M=a.P.width/24|0;if(null==b)nc(a,"Mouse over memory to dump");else for(nc(a,q(b,8,!0),null,0,1),k=1;16>=k;k++){d="";for(g=1;8>=g;g++)h=a.oa,m=b++,h=h.aa[(m&h.C)>>>h.A].ae(m&h.D,m),nc(a,q(h,2),null,1), -d+=32<=h&&128>h?String.fromCharCode(h):".";nc(a,d,null,0,1)}a.context.drawImage(a.K,0,e,f,jc,a.ra,a.ta,a.la,a.qa)}a.N=c}}}function nc(a,b,c,d,e){a.I.font=a.aa;a.I.fillStyle=a.V;a.I.fillText(b,a.D,a.J);a.D+=a.M;null!=c&&(16!=a.pa?b=c.toString():(b=8>a.fa?"0x":"",b+=q(c,a.fa)),a.I.fillText(b,a.D,a.J),a.D+=a.M);d&&(a.D+=a.M*d);e&&(a.D=a.ka,a.J+=(a.ea+2)*(e||1))} +log:536870912,warn:1073741824,halt:-2147483648};function $b(a){pb.call(this,"Panel",a);this.li=this.A=this.B=this.H=-1}ia($b,pb);l=$b.prototype;l.tc=function(a,b,c,d){this.na=a;this.oa=b;this.G=c;this.ca=d;this.C=ac(a,"Keyboard")};l.Eb=function(a,b,c,d){return this.na&&this.na.Eb(a,b,c,d)||this.G&&this.G.Eb(a,b,c,d)||this.C&&this.C.Eb(a,b,c,d)||this.ca&&this.ca.Eb(a,b,c,d)?!0:pb.prototype.Eb.call(this,a,b,c,d)};l.$b=function(a,b){b||bc();return!0};l.Zb=function(){return!0}; +l.Xd=function(a,b){a.button||(this.H=b?0:-1,dc(this,a,b))};l.sf=function(a){dc(this,a)}; +function dc(a,b,c){var d=ec/null.offsetWidth,e=fc/null.offsetHeight,f=null.getBoundingClientRect();d=(b.clientX-f.left)*d|0;b=(b.clientY-f.top)*e|0;null==c&&(a.H||(a.H=Math.abs(a.A-d)>Math.abs(a.B-b)?1:2),1==a.H?b=a.B:2==a.H&&(d=a.A));a.A=d;a.B=b;if(0<=d&&d>d.shift;d=g*a.oa.B;f=(g+f.mq)*a.oa.B-1;0f&&(d=f);c=d;break a}c=-1}if(-1!==c&&(c&=-16,c!=a.N)){b=c;if(a.context&&a.K&&a.L){e=ic-jc;f=a.K.width;a.L.fillStyle=kc;a.L.fillRect(0,e,f,jc);d=e+lc;g=a.K;var h=a.L,k,m=null.style.color,p=a.ka=10;a.D=p;a.J=d;a.ea=a.ba=lc;k||(k=a.U||a.ba+"px "+mc);a.Z=a.U=k;g&&(a.P=g);h&&(a.I=h,a.V=m||"white");a.M=a.P.width/24|0;if(null==b)nc(a,"Mouse over memory to dump");else for(nc(a,q(b,8,!0),null,0,1),k=1;16>=k;k++){d="";for(g=1;8>=g;g++)h=a.oa,m=b++,h=h.Z[(m&h.C)>>>h.A].ae(m&h.D,m),nc(a,q(h,2),null,1),d+= +32<=h&&128>h?String.fromCharCode(h):".";nc(a,d,null,0,1)}a.context.drawImage(a.K,0,e,f,jc,a.ra,a.ta,a.la,a.qa)}a.N=c}}}function nc(a,b,c,d,e){a.I.font=a.Z;a.I.fillStyle=a.V;a.I.fillText(b,a.D,a.J);a.D+=a.M;null!=c&&(16!=a.pa?b=c.toString():(b=8>a.fa?"0x":"",b+=q(c,a.fa)),a.I.fillText(b,a.D,a.J),a.D+=a.M);d&&(a.D+=a.M*d);e&&(a.D=a.ka,a.J+=(a.ea+2)*(e||1))} function bc(){for(var a=!1,b=zb(document,"pcx86","panel"),c=0;c>2,ic=fc,kc="black",jc=fc>>1;cb(bc); -function oc(a,b,c){pb.call(this,"Bus",a);this.G=b;this.ca=c;this.I=a.busWidth||20;this.ba=Math.pow(2,this.I);this.N=this.C=this.ba-1|0;this.A=32==this.I||20>=this.I?12:24>=this.I?14:15;this.B=1<>2;this.D=this.B-1;this.M=this.ba/this.B|0;this.P=this.M-1;this.F=[];this.H=[];this.K=this.L=!1;this.V=[];this.U=[];a=new w;pc(a,this.ca);this.aa=Array(this.M);for(b=0;b>>a.A;0g&&(p=g);if(k&&k.size){if(k.type==d&&k.controller==e){if(f+g<=k.za)return k.xe+=k.za-f,k.za=f,!0;if(f>=k.za+k.xe){p=k.size-(f-m);p>g&&(p=g);k.xe=f-k.za+p;f=m+a.B;g-=p;h++;continue}}return sc(a,tc,f,g)}f=new w(f,p,a.B,d,e);pc(f,a.ca,k);a.aa[h++]=f;f=m+a.B;g-=p}return 0>=g?(uc(a.G),a.G.Z.Xa||(e=c/1024|0,a.status((e?e+"Kb ":c+" bytes ")+wc[d]+" at "+q(b))),!0):sc(a,xc,b,c)} -function qc(a,b){32==a.I?b?a.J&&(yc(a,1048576,1048576,a.J),a.J=null):a.J||(a.J=zc(a,1048576,1048576),yc(a,1048576,1048576,zc(a,0,1048576))):20>>this.A;0>>a.A;0>>=a.A;0>>a.A;0>>this.A].Cc(a&this.D,a)};function Lc(a,b){var c=b&a.D,d=(b&a.C)>>>a.A;return c!=a.D?a.aa[d].Jf(c,b):a.aa[d++].ae(c,b)|a.aa[d&a.P].ae(0,b+1)<<8} -l.ub=function(a,b){this.aa[(a&this.C)>>>this.A].Ec(a&this.D,b&255,a)};function Mc(a,b,c){var d=b&a.D,e=(b&a.C)>>>a.A;d!=a.D?a.aa[e].mi(d,c&65535,b):(a.aa[e++].af(d,c&255,b),a.aa[e&a.P].af(0,c>>8&255,b+1))} -function Nc(a,b){var c=0,d=[],e=!a.J&&a.N==a.C;e||qc(a,!0);for(var f=0;f=this.I?12:24>=this.I?14:15;this.B=1<>2;this.D=this.B-1;this.M=this.ba/this.B|0;this.P=this.M-1;this.F=[];this.H=[];this.K=this.L=!1;this.V=[];this.U=[];a=new w;pc(a,this.ca);this.Z=Array(this.M);for(b=0;b>>a.A;0g&&(p=g);if(k&&k.size){if(k.type==d&&k.controller==e){if(f+g<=k.za)return k.xe+=k.za-f,k.za=f,!0;if(f>=k.za+k.xe){p=k.size-(f-m);p>g&&(p=g);k.xe=f-k.za+p;f=m+a.B;g-=p;h++;continue}}return sc(a,tc,f,g)}f=new w(f,p,a.B,d,e);pc(f,a.ca,k);a.Z[h++]=f;f=m+a.B;g-=p}return 0>=g?(uc(a.G),a.G.aa.Xa||(e=c/1024|0,a.status((e?e+"Kb ":c+" bytes ")+wc[d]+" at "+q(b))),!0):sc(a,xc,b,c)} +function qc(a,b){32==a.I?b?a.J&&(yc(a,1048576,1048576,a.J),a.J=null):a.J||(a.J=zc(a,1048576,1048576),yc(a,1048576,1048576,zc(a,0,1048576))):20>>this.A;0>>a.A;0>>=a.A;0>>a.A;0>>this.A].Cc(a&this.D,a)};function Lc(a,b){var c=b&a.D,d=(b&a.C)>>>a.A;return c!=a.D?a.Z[d].Kf(c,b):a.Z[d++].ae(c,b)|a.Z[d&a.P].ae(0,b+1)<<8} +l.ub=function(a,b){this.Z[(a&this.C)>>>this.A].Ec(a&this.D,b&255,a)};function Mc(a,b,c){var d=b&a.D,e=(b&a.C)>>>a.A;d!=a.D?a.Z[e].oi(d,c&65535,b):(a.Z[e++].bf(d,c&255,b),a.Z[e&a.P].bf(0,c>>8&255,b+1))} +function Nc(a,b){var c=0,d=[],e=!a.J&&a.N==a.C;e||qc(a,!0);for(var f=0;f>>=f;if(void 0!==g){if(g[0])g[0](b,k,e);a.ca&&a.L!=g[1]&&Wc(a.ca,b,k)}else a.ca&&(Ub(a.ca,a,b,k,e),a.L&&Wc(a.ca,b,k));f+=h<<3;b+=h;c-=h}}function sc(a,b,c,d,e){b="Memory block error ("+b+": "+q(c)+","+q(d)+")";e?a.ca?a.ca.message(b):a.log(b):kb(b);return!1}var hc,Xc={mn:20,count:8,kq:1,type:3},Yc=0,Zc;for(Zc in Xc){var $c=Xc[Zc];Xc[Zc]={dn:(1<<$c)-1<>>=f;if(void 0!==g){if(g[0])g[0](b,k,e);a.ca&&a.L!=g[1]&&Wc(a.ca,b,k)}else a.ca&&(Ub(a.ca,a,b,k,e),a.L&&Wc(a.ca,b,k));f+=h<<3;b+=h;c-=h}}function sc(a,b,c,d,e){b="Memory block error ("+b+": "+q(c)+","+q(d)+")";e?a.ca?a.ca.message(b):a.log(b):kb(b);return!1}var hc,Xc={nn:20,count:8,lq:1,type:3},Yc=0,Zc;for(Zc in Xc){var $c=Xc[Zc];Xc[Zc]={dn:(1<<$c)-1<>1),this.W=new Int32Array(this.I,0,c>>2),Cc(this,Hc?Ic:Jc);else{this.W=Array(c>>2);for(e=0;e>2),a=0;a>8,c)};l.ki=function(a,b,c){this.Ec(a++,b&255,c++);this.Ec(a++,b>>8&255,c++);this.Ec(a++,b>>16&255,c++);this.Ec(a,b>>>24,c)};l.Ao=function(a){return this.W[a>>2]>>>((a&3)<<3)&255}; -l.Mo=function(a){var b=a>>2;a=(a&3)<<3;var c=this.W[b]>>a;return 24>a?c&65535:c&255|(this.W[b+1]&255)<<8};l.Go=function(a){var b=a>>2;a=(a&3)<<3;var c=this.W[b];a&&(c=c>>>a|this.W[b+1]<<32-a);return c};l.bp=function(a,b){var c=a>>2;a=(a&3)<<3;this.W[c]=this.W[c]&~(255<>2;a=(a&3)<<3;24>a?this.W[c]=this.W[c]&~(65535<>8);this.Oa=!0}; -l.ip=function(a,b){var c=a>>2;if(a=(a&3)<<3){var d=-1<>>32-a}else this.W[c]=b;this.Oa=!0};l.zo=function(a,b){this.ca&&null!=this.za&&nd(this.ca,this.za+a)||this.C&&od(this.C,b,1,!1);return this.ae(a,b)};l.Lo=function(a,b){this.ca&&null!=this.za&&nd(this.ca,this.za+a,2)||this.C&&od(this.C,b,2,!1);return this.Jf(a,b)};l.Fo=function(a,b){this.ca&&null!=this.za&&nd(this.ca,this.za+a,4)||this.C&&od(this.C,b,4,!1);return this.di(a,b)}; -l.ap=function(a,b,c){this.ca&&null!=this.za&&pd(this.ca,this.za+a)||this.C&&od(this.C,c,1,!0);this.D?this.bf(0,b,c):this.af(a,b,c)};l.np=function(a,b,c){this.ca&&null!=this.za&&pd(this.ca,this.za+a,2)||this.C&&od(this.C,c,2,!0);this.D?this.bf(0,b,c):this.mi(a,b,c)};l.hp=function(a,b,c){this.ca&&null!=this.za&&pd(this.ca,this.za+a,4)||this.C&&od(this.C,c,4,!0);this.D?this.bf(0,b,c):this.K(a,b,c)};l.Co=function(a,b){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.F;return this.td.Cc(a,b)}; -l.Oo=function(a,b){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.F;return this.td.If(a,b)};l.Io=function(a,b){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.F;return this.td.Nd(a,b)};l.ep=function(a,b,c){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.J;this.td.Ec(a,b,c)};l.qp=function(a,b,c){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.J;this.td.Nf(a,b,c)};l.kp=function(a,b,c){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.J;this.td.Mf(a,b,c)}; -l.Do=function(a,b){return qd(this.C,b,!1).Cc(a,b)};l.Po=function(a,b){return qd(this.C,b,!1).If(a,b)};l.Jo=function(a,b){return qd(this.C,b,!1).Nd(a,b)};l.fp=function(a,b,c){qd(this.C,c,!0).Ec(a,b,c)};l.rp=function(a,b,c){qd(this.C,c,!0).Nf(a,b,c)};l.lp=function(a,b,c){qd(this.C,c,!0).Mf(a,b,c)};l.yo=function(a){return this.Qa[a]};l.Kk=function(a){return this.Qa[a]};l.Bo=function(a){this.pb.W[this.A]|=32;this.qb.W[this.B]|=32;this.Cc=this.Kk;return this.Qa[a]}; -l.Ko=function(a){return this.H.getUint16(a,!0)};l.Pk=function(a){return a&1?this.Qa[a]|this.Qa[a+1]<<8:this.Td[a>>1]};l.No=function(a){this.pb.W[this.A]|=32;this.qb.W[this.B]|=32;this.If=this.Pk;return a&1?this.Qa[a]|this.Qa[a+1]<<8:this.Td[a>>1]};l.Eo=function(a){return this.H.getInt32(a,!0)};l.Mk=function(a){return a&3?this.Qa[a]|this.Qa[a+1]<<8|this.Qa[a+2]<<16|this.Qa[a+3]<<24:this.W[a>>2]}; -l.Ho=function(a){this.pb.W[this.A]|=32;this.qb.W[this.B]|=32;this.Nd=this.Mk;return a&3?this.Qa[a]|this.Qa[a+1]<<8|this.Qa[a+2]<<16|this.Qa[a+3]<<24:this.W[a>>2]};l.$o=function(a,b){this.Qa[a]=b;this.Oa=!0};l.Xk=function(a,b){this.Qa[a]=b;this.Oa=!0};l.cp=function(a,b){this.Qa[a]=b;this.pb.W[this.A]|=32;this.qb.W[this.B]|=96;this.Ec=this.Xk;this.td.Oa=!0};l.mp=function(a,b){this.H.setUint16(a,b,!0);this.Oa=!0};l.Zk=function(a,b){a&1?(this.Qa[a]=b,this.Qa[a+1]=b>>8):this.Td[a>>1]=b;this.Oa=!0}; -l.pp=function(a,b){a&1?(this.Qa[a]=b,this.Qa[a+1]=b>>8):this.Td[a>>1]=b;this.pb.W[this.A]|=32;this.qb.W[this.B]|=96;this.Nf=this.Zk;this.td.Oa=!0};l.gp=function(a,b){this.H.setInt32(a,b,!0);this.Oa=!0};l.Yk=function(a,b){a&3?(this.Qa[a]=b,this.Qa[a+1]=b>>8,this.Qa[a+2]=b>>16,this.Qa[a+3]=b>>24):this.W[a>>2]=b;this.Oa=!0}; -l.jp=function(a,b){a&3?(this.Qa[a]=b,this.Qa[a+1]=b>>8,this.Qa[a+2]=b>>16,this.Qa[a+3]=b>>24):this.W[a>>2]=b;this.pb.W[this.A]|=32;this.qb.W[this.B]|=96;this.Mf=this.Yk;this.td.Oa=!0};function wd(a){Vb&&!Hc&&(a=a<<24|a<<8&16711680|a>>8&65280|a>>>24);return a} -var dd=0,Gc=2,ed=5,gd=6,wc="NONE RAM ROM VIDEO H/W UNPAGED PAGED".split(" "),cd=0,id=[],Kc=[w.prototype.Ao,w.prototype.bp,w.prototype.Mo,w.prototype.op,w.prototype.Go,w.prototype.ip],ld=[w.prototype.zo,w.prototype.ap,w.prototype.Lo,w.prototype.np,w.prototype.Fo,w.prototype.hp],hd=[w.prototype.Co,w.prototype.ep,w.prototype.Oo,w.prototype.qp,w.prototype.Io,w.prototype.kp],fd=[w.prototype.Do,w.prototype.fp,w.prototype.Po,w.prototype.rp,w.prototype.Jo,w.prototype.lp]; -if(Vb)var Jc=[w.prototype.yo,w.prototype.$o,w.prototype.Ko,w.prototype.mp,w.prototype.Eo,w.prototype.gp],Ic=[w.prototype.Kk,w.prototype.Xk,w.prototype.Pk,w.prototype.Zk,w.prototype.Mk,w.prototype.Yk],xd=[w.prototype.Bo,w.prototype.cp,w.prototype.No,w.prototype.pp,w.prototype.Ho,w.prototype.jp]; -function yd(a,b){pb.call(this,"CPU",a,1);b=a.cycles||b;var c=a.multiplier||1;this.Y={};this.Y.Yd=b;this.Y.Bj=this.Y.nh=this.Y.Ad=c;this.Y.ng=Math.round(this.Y.Yd/1E4)/100;this.Y.Kd=this.Y.pe=this.Y.ng*this.Y.Ad;this.Z.ii=this.Z.Xa=this.Z.Of=!1;this.Z.he=a.autoStart;this.Z.gj=!1;this.Z.He=!1;this.Y.tf=this.Y.Re=0;this.Y.vf=a.csStart;this.Y.Qe=a.csInterval;this.Y.Se=a.csStop;this.qa=[];this.tj=this.Qo.bind(this)}ia(yd,pb);l=yd.prototype; -l.tc=function(a,b,c,d){this.na=a;this.oa=b;this.ca=d;for(b=0;b=a.Y.Re&&(a.Y.Re+=a.Y.Qe,c=!0);0<=a.Y.Se&&a.Y.Se<=Jd(a)&&(a.Y.Qe=a.Y.Se=-1,Ed(a),Gd(a),c=!0);c&&a.O(Jd(a)+" cycles: checksum="+q(a.Y.tf))}} -l.Eb=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.ma[b]=c;a=!0;break;case "run":this.ma[b]=c;c.onclick=function(){var a=d.Z.Xa,b;if(b=d.na)if(b=d.na,b.Z.we&&(b.Z.we=!1,b.Z.nf&&!b.Z.ac&&b.Ve(Kd)),b.Z.ac)b=!0;else{var c=null,h,k=Bb(b.id);for(h=0;ha.Y.Ad)b=a.Y.Ad;a.Y.Aj=Math.round(1E3/Cd);a.Y.hn=Math.floor(a.Y.Yd/Cd*b);a.Y.nh=b} -function Jd(a,b){var c=a.Fd+a.md+a.ld-a.A;b&&1a.Y.ng&&(c=Math.round(c/a.Y.Ad));return c}function Dd(a){a.Fd=a.md=a.ld=a.A=0;Ed(a);Ld(a,a.Y.Bj)} -function Ld(a,b,c){var d=!0;if(void 0!==b){0b[1])&&(c=a.Y.Yd*a.Y.nh/1E3*c|0,a.Z.Xa&&(c+=Qd(a)),b[1]=c)}function Rd(a){for(var b=[],c=0;cthis.Y.Aj&&(this.Y.xd+=a,this.Y.xd>this.Y.sf&&(this.Y.xd=this.Y.sf))}try{this.Z.Of=!1;do{for(var b,c=this.Z.He?1:this.Y.Yd*this.Y.nh|0,d=this.qa.length-1;0<=d;d--){var e=this.qa[d];0>e[1]||c>e[1]&&(c=e[1])}b=c;if(this.V){Td(this.V);var f=this.V;a=b;var g=f.qa[0];if(g.me){var h=(Jd(f.G,f.M)-g.hd)/f.Ea|0,k=Ud(f,0)-h;g.mode==Vd&&(k-=h);var m=k*f.Ea|0;g.mode==Vd&& -(m>>=1);a>m&&(a=m)}b=a;var p=this.V;a=b;if(p.A&&p.A[Wd]&Xd){var v=p.aa-Jd(p.G,p.M);0v&&(a=v)}b=a}try{this.Hg(b)}catch(J){if("number"!=typeof J)throw J;}a=b=Qd(this);for(var u=this.qa.length-1;0<=u;u--){var A=this.qa[u];0>A[1]||(A[1]-=a,0>=A[1]&&(A[1]=-1,A[3](),0<=A[2]&&Pd(this,u,A[2])))}Id(this,b)}while(this.Z.Xa&&!this.Z.Of)}catch(J){Gd(this);Fd(this);this.na&&this.na.stop(La(),Jd(this));Mb(this,J.stack||J.message);return}if(this.Z.Xa){b=setTimeout;c=this.tj;this.Y.qe=La();d=this.Y.Aj;this.Y.pg&& -(d=Math.round(d*this.Y.pg/this.Y.hn));d-=this.Y.qe-this.Y.sf;if(e=this.Y.qe-this.Y.xd)this.Y.Kd=Math.round(this.md/(10*e))/100,864E5<=e&&(this.Fd=0,this.V&&Td(this.V,!0),Ld(this));0>d?(-1E3>d&&(this.Y.xd-=d),d=0):this.Y.Kd>>0)+b>this.Nb&&(8088>=this.Lb.da?this.Lb.M|=8:x.call(this.Lb,13));return this.ua+a|0};l.Zi=function(a,b){return(a>>>0)+b<=this.Nb?this.ua+a|0:this.eg()};l.rl=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.eg()};l.eg=function(){x.call(this.Lb,13,0);return-1}; -l.aj=function(a,b){return(a>>>0)+b<=this.Nb?this.ua+a|0:this.gg()};l.sl=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.gg()};l.gg=function(){x.call(this.Lb,13,0);return-1};function he(a,b,c,d,e){a.T=b;a.ua=d;a.Sa=e;a.Nb=(e>>>0)+1;a.ob=c;a.type=c&7936;a.ext=c>>16&192;a.Ob=(b&4?a.Lb.Gb.ua:a.Lb.Kb)+(b&65528)|0;a.id>>0)+1;a.ob=e;a.type=e&7936;a.ext=0;a.Ob=b;a.id>>0)+1,a.ob=a.A.ob,a.type=a.A.type,a.ext=a.A.ext,a.Ob=a.A.Ob,a.A.T=-1,be(a,!0,!0,!1),a.ua;a.A.T=-1;var f=e.ja(b+0),g=e.ja(b+4),h=g&7936,k=e.ja(b+2)|(g&255)<<16,m=e.ja(b+6),p=c&65528;if(80386<=e.da){var v=f;k|=(m&65280)<<16;f|=(m&15)<<16;m&128&&(f=f<<12|4095)}switch(a.id){case ke:var u=a.C;a.Me=!1;if(u&&c==de&&a.B.length){var A=a.B[a.Gf-1];if(A&&!A())return-1}var J=c&3,H=(g&24576)>>13;A=-1;p||b>=e.Kb&& -b=a.Cb&&(J>a.Cb&&(A=le(e),me(e,le(e),!0),ne(e,A),a.Me=!0),A=0);else{if(256==h||2304==h)return oe(a,c,u)?a.ua:-1;if(1024==h){A=2;var G=0;Jh||2048==(h&2560))return x.call(e,13,c&65532),-1;if(!(g&32768))return x.call(e,11,c&65532),-1}break;case ge:if(!p||4096>h||512!=(h&2560))return x.call(e,13,c&65532),-1;if(!(g&32768))return x.call(e, -12,c&65532),-1;break;case ie:u=h&-513;if(!p||256!=u&&2304!=u)return x.call(e,13,c&65532),-1;2304==u&&(a.Pi=k+e.ja(k+102)|0,a.ll=k+a.Sa|0);break;case fe:if(!(h&4096)&&768>>0)+1,a.ob=g,a.type=h,a.ext=m,a.Ob=b,be(a,!0,!0,!1));return k} +function w(a,b,c,d,e,f){this.id=cd+=2;this.W=null;this.G=0;this.za=a;this.xe=b;this.size=c||0;this.type=d||dd;this.D=d==Gc;this.controller=null;this.C=f;pc(this);this.Oa=this.mj=!1;if(c)if(e)this.controller=e,a=e.rj(a),this.W=a[0],this.G=a[1],Cc(this,e.bh());else if(Vb)this.I=new ArrayBuffer(c),this.H=new DataView(this.I,0,c),this.Qa=new Uint8Array(this.I,0,c),this.Td=new Uint16Array(this.I,0,c>>1),this.W=new Int32Array(this.I,0,c>>2),Cc(this,Hc?Ic:Jc);else{this.W=Array(c>>2);for(e=0;e>2),a=0;a>8,c)};l.mi=function(a,b,c){this.Ec(a++,b&255,c++);this.Ec(a++,b>>8&255,c++);this.Ec(a++,b>>16&255,c++);this.Ec(a,b>>>24,c)};l.Bo=function(a){return this.W[a>>2]>>>((a&3)<<3)&255}; +l.No=function(a){var b=a>>2;a=(a&3)<<3;var c=this.W[b]>>a;return 24>a?c&65535:c&255|(this.W[b+1]&255)<<8};l.Ho=function(a){var b=a>>2;a=(a&3)<<3;var c=this.W[b];a&&(c=c>>>a|this.W[b+1]<<32-a);return c};l.cp=function(a,b){var c=a>>2;a=(a&3)<<3;this.W[c]=this.W[c]&~(255<>2;a=(a&3)<<3;24>a?this.W[c]=this.W[c]&~(65535<>8);this.Oa=!0}; +l.jp=function(a,b){var c=a>>2;if(a=(a&3)<<3){var d=-1<>>32-a}else this.W[c]=b;this.Oa=!0};l.Ao=function(a,b){this.ca&&null!=this.za&&nd(this.ca,this.za+a)||this.C&&od(this.C,b,1,!1);return this.ae(a,b)};l.Mo=function(a,b){this.ca&&null!=this.za&&nd(this.ca,this.za+a,2)||this.C&&od(this.C,b,2,!1);return this.Kf(a,b)};l.Go=function(a,b){this.ca&&null!=this.za&&nd(this.ca,this.za+a,4)||this.C&&od(this.C,b,4,!1);return this.fi(a,b)}; +l.bp=function(a,b,c){this.ca&&null!=this.za&&pd(this.ca,this.za+a)||this.C&&od(this.C,c,1,!0);this.D?this.cf(0,b,c):this.bf(a,b,c)};l.op=function(a,b,c){this.ca&&null!=this.za&&pd(this.ca,this.za+a,2)||this.C&&od(this.C,c,2,!0);this.D?this.cf(0,b,c):this.oi(a,b,c)};l.ip=function(a,b,c){this.ca&&null!=this.za&&pd(this.ca,this.za+a,4)||this.C&&od(this.C,c,4,!0);this.D?this.cf(0,b,c):this.K(a,b,c)};l.Do=function(a,b){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.F;return this.td.Cc(a,b)}; +l.Po=function(a,b){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.F;return this.td.Jf(a,b)};l.Jo=function(a,b){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.F;return this.td.Nd(a,b)};l.fp=function(a,b,c){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.J;this.td.Ec(a,b,c)};l.rp=function(a,b,c){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.J;this.td.Of(a,b,c)};l.lp=function(a,b,c){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.J;this.td.Nf(a,b,c)}; +l.Eo=function(a,b){return qd(this.C,b,!1).Cc(a,b)};l.Qo=function(a,b){return qd(this.C,b,!1).Jf(a,b)};l.Ko=function(a,b){return qd(this.C,b,!1).Nd(a,b)};l.gp=function(a,b,c){qd(this.C,c,!0).Ec(a,b,c)};l.sp=function(a,b,c){qd(this.C,c,!0).Of(a,b,c)};l.mp=function(a,b,c){qd(this.C,c,!0).Nf(a,b,c)};l.zo=function(a){return this.Qa[a]};l.Lk=function(a){return this.Qa[a]};l.Co=function(a){this.pb.W[this.A]|=32;this.qb.W[this.B]|=32;this.Cc=this.Lk;return this.Qa[a]}; +l.Lo=function(a){return this.H.getUint16(a,!0)};l.Qk=function(a){return a&1?this.Qa[a]|this.Qa[a+1]<<8:this.Td[a>>1]};l.Oo=function(a){this.pb.W[this.A]|=32;this.qb.W[this.B]|=32;this.Jf=this.Qk;return a&1?this.Qa[a]|this.Qa[a+1]<<8:this.Td[a>>1]};l.Fo=function(a){return this.H.getInt32(a,!0)};l.Nk=function(a){return a&3?this.Qa[a]|this.Qa[a+1]<<8|this.Qa[a+2]<<16|this.Qa[a+3]<<24:this.W[a>>2]}; +l.Io=function(a){this.pb.W[this.A]|=32;this.qb.W[this.B]|=32;this.Nd=this.Nk;return a&3?this.Qa[a]|this.Qa[a+1]<<8|this.Qa[a+2]<<16|this.Qa[a+3]<<24:this.W[a>>2]};l.ap=function(a,b){this.Qa[a]=b;this.Oa=!0};l.Yk=function(a,b){this.Qa[a]=b;this.Oa=!0};l.ep=function(a,b){this.Qa[a]=b;this.pb.W[this.A]|=32;this.qb.W[this.B]|=96;this.Ec=this.Yk;this.td.Oa=!0};l.np=function(a,b){this.H.setUint16(a,b,!0);this.Oa=!0};l.$k=function(a,b){a&1?(this.Qa[a]=b,this.Qa[a+1]=b>>8):this.Td[a>>1]=b;this.Oa=!0}; +l.qp=function(a,b){a&1?(this.Qa[a]=b,this.Qa[a+1]=b>>8):this.Td[a>>1]=b;this.pb.W[this.A]|=32;this.qb.W[this.B]|=96;this.Of=this.$k;this.td.Oa=!0};l.hp=function(a,b){this.H.setInt32(a,b,!0);this.Oa=!0};l.Zk=function(a,b){a&3?(this.Qa[a]=b,this.Qa[a+1]=b>>8,this.Qa[a+2]=b>>16,this.Qa[a+3]=b>>24):this.W[a>>2]=b;this.Oa=!0}; +l.kp=function(a,b){a&3?(this.Qa[a]=b,this.Qa[a+1]=b>>8,this.Qa[a+2]=b>>16,this.Qa[a+3]=b>>24):this.W[a>>2]=b;this.pb.W[this.A]|=32;this.qb.W[this.B]|=96;this.Nf=this.Zk;this.td.Oa=!0};function wd(a){Vb&&!Hc&&(a=a<<24|a<<8&16711680|a>>8&65280|a>>>24);return a} +var dd=0,Gc=2,ed=5,gd=6,wc="NONE RAM ROM VIDEO H/W UNPAGED PAGED".split(" "),cd=0,id=[],Kc=[w.prototype.Bo,w.prototype.cp,w.prototype.No,w.prototype.pp,w.prototype.Ho,w.prototype.jp],ld=[w.prototype.Ao,w.prototype.bp,w.prototype.Mo,w.prototype.op,w.prototype.Go,w.prototype.ip],hd=[w.prototype.Do,w.prototype.fp,w.prototype.Po,w.prototype.rp,w.prototype.Jo,w.prototype.lp],fd=[w.prototype.Eo,w.prototype.gp,w.prototype.Qo,w.prototype.sp,w.prototype.Ko,w.prototype.mp]; +if(Vb)var Jc=[w.prototype.zo,w.prototype.ap,w.prototype.Lo,w.prototype.np,w.prototype.Fo,w.prototype.hp],Ic=[w.prototype.Lk,w.prototype.Yk,w.prototype.Qk,w.prototype.$k,w.prototype.Nk,w.prototype.Zk],xd=[w.prototype.Co,w.prototype.ep,w.prototype.Oo,w.prototype.qp,w.prototype.Io,w.prototype.kp]; +function yd(a,b){pb.call(this,"CPU",a,1);b=a.cycles||b;var c=a.multiplier||1;this.Y={};this.Y.Yd=b;this.Y.lh=Math.round(1E3/zd);this.Y.Cj=this.Y.ph=this.Y.Ad=c;this.Y.og=Math.round(this.Y.Yd/1E4)/100;this.Y.Kd=this.Y.pe=this.Y.og*this.Y.Ad;this.aa.ki=this.aa.Xa=this.aa.Pf=!1;this.aa.he=a.autoStart;this.aa.hj=!1;this.aa.Ie=!1;this.Y.uf=this.Y.Se=0;this.Y.wf=a.csStart;this.Y.Re=a.csInterval;this.Y.Te=a.csStop;this.qa=[];this.Rd=0;this.wj=this.Ro.bind(this)}ia(yd,pb);l=yd.prototype; +l.tc=function(a,b,c,d){this.na=a;this.oa=b;this.ca=d;for(b=0;b=a.Y.Se&&(a.Y.Se+=a.Y.Re,c=!0);0<=a.Y.Te&&a.Y.Te<=Jd(a)&&(a.Y.Re=a.Y.Te=-1,Ed(a),Gd(a),c=!0);c&&a.O(Jd(a)+" cycles: checksum="+q(a.Y.uf))}} +l.Eb=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.ma[b]=c;a=!0;break;case "run":this.ma[b]=c;c.onclick=function(){var a=d.aa.Xa,b;if(b=d.na)if(b=d.na,b.aa.we&&(b.aa.we=!1,b.aa.pf&&!b.aa.ac&&b.We(Kd)),b.aa.ac)b=!0;else{var c=null,h,k=Bb(b.id);for(h=0;ha.Y.Ad)b=a.Y.Ad;a.Y.jn=Math.floor(a.Y.Yd/zd*b);a.Y.ph=b} +function Jd(a,b){var c=a.Fd+a.md+a.ld-a.A;b&&1a.Y.og&&(c=Math.round(c/a.Y.Ad));return c}function Dd(a){a.Fd=a.md=a.ld=a.A=0;Ed(a);Ld(a,a.Y.Cj)} +function Ld(a,b,c){var d=!0;if(void 0!==b){0b[1])&&(c=a.Y.Yd*a.Y.ph/1E3*c|0,a.aa.Xa&&(c+=Qd(a)),b[1]=c)}function Rd(a){for(var b=[],c=0;cthis.Y.lh&&(this.Y.xd+=a,this.Y.xd>this.Y.tf&&(this.Y.xd=this.Y.tf))}try{this.aa.Pf=!1;do{for(var b,c=this.aa.Ie?1:this.Y.Yd*this.Y.ph|0,d=this.qa.length-1;0<=d;d--){var e=this.qa[d];0>e[1]||c>e[1]&&(c=e[1])}b=c;if(this.V){Td(this.V);var f=this.V;a=b;var g=f.qa[0];if(g.me){var h=(Jd(f.G,f.M)-g.hd)/f.Ea|0,k=Ud(f,0)-h;g.mode==Vd&&(k-=h);var m=k*f.Ea| +0;g.mode==Vd&&(m>>=1);a>m&&(a=m)}b=a;var p=this.V;a=b;if(p.A&&p.A[Wd]&Xd){var v=p.Z-Jd(p.G,p.M);0v&&(a=v)}b=a}try{this.Jg(b)}catch(J){if("number"!=typeof J)throw J;}a=b=Qd(this);for(var u=this.qa.length-1;0<=u;u--){var A=this.qa[u];0>A[1]||(A[1]-=a,0>=A[1]&&(A[1]=-1,A[3](),0<=A[2]&&Pd(this,u,A[2])))}Id(this,b)}while(this.aa.Xa&&!this.aa.Pf)}catch(J){Gd(this);Fd(this);this.na&&this.na.stop(La(),Jd(this));Mb(this,J.stack||J.message);return}if(this.aa.Xa){b=setTimeout;c=this.wj;this.Y.qe=La(); +d=this.Y.lh;this.Y.qg&&(d=Math.round(d*this.Y.qg/this.Y.jn));d-=this.Y.qe-this.Y.tf;if(e=this.Y.qe-this.Y.xd)this.Y.Kd=Math.round(this.md/(10*e))/100,864E5<=e&&(this.Fd=0,this.V&&Td(this.V,!0),Ld(this));0>d?(-1E3>d&&(this.Y.xd-=d),d=0):this.Y.Kd>>0)+b>this.Nb&&(8088>=this.Lb.da?this.Lb.M|=8:x.call(this.Lb,13));return this.ua+a|0};l.$i=function(a,b){return(a>>>0)+b<=this.Nb?this.ua+a|0:this.fg()};l.sl=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.fg()};l.fg=function(){x.call(this.Lb,13,0);return-1}; +l.bj=function(a,b){return(a>>>0)+b<=this.Nb?this.ua+a|0:this.hg()};l.tl=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.hg()};l.hg=function(){x.call(this.Lb,13,0);return-1};function he(a,b,c,d,e){a.T=b;a.ua=d;a.Sa=e;a.Nb=(e>>>0)+1;a.ob=c;a.type=c&7936;a.ext=c>>16&192;a.Ob=(b&4?a.Lb.Gb.ua:a.Lb.Kb)+(b&65528)|0;a.id>>0)+1;a.ob=e;a.type=e&7936;a.ext=0;a.Ob=b;a.id>>0)+1,a.ob=a.A.ob,a.type=a.A.type,a.ext=a.A.ext,a.Ob=a.A.Ob,a.A.T=-1,be(a,!0,!0,!1),a.ua;a.A.T=-1;var f=e.ja(b+0),g=e.ja(b+4),h=g&7936,k=e.ja(b+2)|(g&255)<<16,m=e.ja(b+6),p=c&65528;if(80386<=e.da){var v=f;k|=(m&65280)<<16;f|=(m&15)<<16;m&128&&(f=f<<12|4095)}switch(a.id){case ke:var u=a.C;a.Ne=!1;if(u&&c==de&&a.B.length){var A=a.B[a.Hf-1];if(A&&!A())return-1}var J=c&3,H=(g&24576)>>13;A=-1;p||b>=e.Kb&& +b=a.Cb&&(J>a.Cb&&(A=le(e),me(e,le(e),!0),ne(e,A),a.Ne=!0),A=0);else{if(256==h||2304==h)return oe(a,c,u)?a.ua:-1;if(1024==h){A=2;var G=0;Jh||2048==(h&2560))return x.call(e,13,c&65532),-1;if(!(g&32768))return x.call(e,11,c&65532),-1}break;case ge:if(!p||4096>h||512!=(h&2560))return x.call(e,13,c&65532),-1;if(!(g&32768))return x.call(e, +12,c&65532),-1;break;case ie:u=h&-513;if(!p||256!=u&&2304!=u)return x.call(e,13,c&65532),-1;2304==u&&(a.Qi=k+e.ja(k+102)|0,a.ml=k+a.Sa|0);break;case fe:if(!(h&4096)&&768>>0)+1,a.ob=g,a.type=h,a.ext=m,a.Ob=b,be(a,!0,!0,!1));return k} function oe(a,b,c){var d=a.Lb,e=a.Cb,f=d.ka.T,g=d.ka.ua;if(!c){if(!(d.ka.type&512))return x.call(d,13,b&65532),!1;d.ib(d.ka.Ob+4,d.ka.ob&=-513)}if(-1===d.ka.load(b))return!1;var h=d.ka.ua;if(!1!==c){if(d.ka.type&512)return x.call(d,13,b&65532),!1;d.ib(d.ka.Ob+4,d.ka.ob|=512)}d.ka.type=d.ka.type&-513|d.ka.ob&512;256==d.ka.type||768==d.ka.type?(d.ib(g+14,z(d)),d.ib(g+16,xe(d)),d.ib(g+18,d.D),d.ib(g+20,d.I),d.ib(g+22,d.L),d.ib(g+24,d.H),d.ib(g+26,y(d)),d.ib(g+28,d.N),d.ib(g+30,d.K),d.ib(g+32,d.J),d.ib(g+ 34,d.pa.T),d.ib(g+36,d.ba.T),d.ib(g+38,d.U.T),d.ib(g+40,d.Fa.T),d.Gb.load(d.ja(h+42)),ye(d,d.ja(h+16)|(c?16384:0)),d.D=d.ja(h+18),d.I=d.ja(h+20),d.L=d.ja(h+22),d.H=d.ja(h+24),d.N=d.ja(h+28),d.K=d.ja(h+30),d.J=d.ja(h+32),d.pa.load(d.ja(h+34)),d.Fa.load(d.ja(h+40)),ze(d,d.ja(h+14),d.ja(h+36)),b=38,g=26,a.Cb>>0)+1)}; -function be(a,b,c,d){void 0===c&&(c=!!(a.Lb.ra&1));a.ed=!1;if(c)if(a.load=a.mg,a.yj=a.an,a.Bb=a.Zi,a.Ub=a.aj,void 0===d&&(d=!!(a.Lb.P&131072)),d)a.load=a.H,a.Bb=a.D,a.Ub=a.F,a.Cb=a.qc=3,a.X=2,a.R=a.xa=65535,a.Sa=65535,a.Nb=a.Sa+1,a.Lc=a.X,a.Ob=-1,a.Me=!1;else{if(!(a.T&-4))a.Bb=a.eg,a.Ub=a.gg;else if(a.type&4096){6144==(a.type&6656)&&(a.Bb=a.eg);if(a.type&2048||!(a.type&512))a.Ub=a.gg;1024==(a.type&3072)&&(a.Bb==a.Zi&&(a.Bb=a.rl),a.Ub==a.aj&&(a.Ub=a.sl),a.ed=!0);b&&a.id>13,80386>a.Lb.da||!(a.ext&64)?(a.X=2,a.R=65535):(a.X=4,a.R=-1),a.Lc=a.X,a.xa=a.R)}else a.load=a.jh,a.yj=a.bn,a.Bb=a.fg,a.Ub=a.fg,a.Cb=a.qc=0,a.Ob=-1,a.Me=!1}var ke=1,we=2,ge=3,ie=4,fe=6,de=1; -function Ae(a){var b=+a.model||8088;switch(b){default:var c=4772727;break;case 80286:c=6E6;break;case 80386:c=16E6}yd.call(this,a,c);this.da=b;a=a.stepping;this.Qd=b+(a?qa(a,16):0);this.Oi=61442;this.Pd=1792;this.ni=28672;this.Pf=4;this.Ra=255;this.B=80286<=this.da?Xb:Wb;this.wa=Be;this.Yi=Ce;this.ej=De;this.ij=Ee;if(80186<=this.da&&(this.wa=Be.slice(),this.Yi=Ce.slice(),this.ej=De.slice(),this.Ra=31,this.wa[15]=Ie,this.wa[96]=Je,this.wa[97]=Ke,this.wa[98]=Le,this.wa[99]=Ie,this.wa[100]=Ie,this.wa[101]= -Ie,this.wa[102]=Ie,this.wa[103]=Ie,this.wa[104]=Me,this.wa[105]=Ne,this.wa[106]=Oe,this.wa[107]=Pe,this.wa[108]=Qe,this.wa[109]=Re,this.wa[110]=Se,this.wa[111]=Te,this.wa[192]=Ue,this.wa[193]=Ve,this.wa[200]=We,this.wa[201]=Xe,this.wa[241]=Ye,this.Yi[7]=Ze,this.ej[7]=Ze,80286<=this.da)){this.Oi=2;this.Pd|=28672;this.Pf=0;this.wa[15]=$e;this.qd=af.slice();for(b=0;b=this.Qd&&(this.qd[166]=mf,this.qd[167]=nf)}}this.Sf=[];this.Tf=[];this.Vf=0;Dd(this);this.Z.complete=this.Z.fj=!1;this.oj=0;this.sc=this.aa=[];this.lb=this.Jg=this.Fb=this.Qf=this.cf=this.df=this.bd=0;of(this)}ia(Ae,yd);function pf(a,b,c,d){md((d?a.sc:a.aa)[b>>>a.lb],c);d&&uc(a)} -function qf(a){var b;if(a.aa===a.sc){a.aa=Array(a.Qf);a.Uf=new w(null,0,0,ed,null,a);pc(a.Uf,a.ca);for(b=0;b>>20,f=a.sc[(a.wc+e&a.df)>>>a.lb],g=f.Nd(e);if(!(g&1))return d||sf.call(a,b,!1,c),a.ef;if(!(g&4)&&3==a.Pa)return d||sf.call(a,b,!0,c),a.ef;var h=(b&4190208)>>>10;g=a.sc[((g&-4096)+h&a.df)>>>a.lb];var k=g.Nd(h);if(!(k&1))return d||sf.call(a,b,!1,c),a.ef;if(!(k&4)&&3==a.Pa)return d||sf.call(a,b,!0,c),a.ef;c=a.sc[((k&-4096)+(b&4095)&a.df)>>>a.lb];if(d)return c;d=b>>>a.lb;k=a.aa[d];b&=-4096;if(0>2;b.qb=g;b.B=h>>2;Vb&&Hc&&c.W&&!c.controller&&!c.Ee&&!c.Fe?(b.Qa=c.Qa,b.Td=c.Td,b.W=c.W,Cc(b,xd)):(b.F=c?wd(32):0,b.J=c?wd(96):0,Cc(b,hd));pc(b,a.ca,k);a.aa[d]=b;a.Rf.push(d);return b}function tf(a){a.aa!==a.sc&&(a.aa=a.sc,a.Uf=null,a.Rf=null,a.ef=null)}l=Ae.prototype;l.reset=function(){of(this);Dd(this);this.Z.error=!1}; -function zf(a,b){switch(b){case 0:var c=a.D;break;case 1:c=a.I;break;case 2:c=a.L;break;case 3:c=a.H;break;case 4:c=y(a);break;case 5:c=a.N;break;case 6:c=a.K;break;case 7:c=a.J}return c}function Af(a,b,c){switch(b){case 0:a.D=c;break;case 1:a.I=c;break;case 2:a.L=c;break;case 3:a.H=c;break;case 4:ne(a,c);break;case 5:a.N=c;break;case 6:a.K=c;break;case 7:a.J=c}} -function of(a){a.D=0;a.H=0;a.I=0;a.L=0;a.Ac=0;a.N=0;a.K=0;a.J=0;a.vc=!1;a.Ea=a.cb=0;a.Wm=[0,0];a.Ym=[0,0];a.Aa=0;a.nj=0;a.fa=0;a.ra=65520;a.Qb=0;a.$c=1023;a.P=a.lc=0;a.Sd=a.ff=a.Rd=a.ze=0;a.Sc=-1;a.nd=a.Tc=-1;a.od=a.ta=-1;a.ba=new Zd(a,ke,"CS");a.Fa=new Zd(a,we,"DS");a.pa=new Zd(a,we,"ES");a.U=new Zd(a,ge,"SS");ne(a,0);me(a,0);if(80386<=a.da){switch(a.Qd){case 80562:case 80563:a.L=771;break;case 80578:a.L=772;break;case 80594:a.L=773;break;case 80595:case 80596:a.L=776}a.ra=16;a.Kg=0;a.pd=0;a.wc= -0;a.Rb=[0,0,0,0,null,null,0,0];a.Xf=[null,null,null,null,null,null,0,0];a.Ka=new Zd(a,we,"FS");a.La=new Zd(a,we,"GS");tf(a)}a.Ng=new Zd(a,0,"NULL");a.Ga=a.Fa;a.Sb=a.U;a.M=a.ha=0;a.C=a.F=-1;a.Ia=a.Ng;a.ab=0;if(80286>a.da)ze(a,0,65535);else{a.Kb=0;a.Jc=65535;a.Gb=new Zd(a,5,"LDT",!0);a.ka=new Zd(a,ie,"TSS",!0);a.zb=new Zd(a,fe,"VER",!0);ze(a,65520,61440);var b=z(a);var c=a.ba;var d=-65536;80386>c.Lb.da&&(d&=16777215);c=c.ua=d;a.ea=c+b|0;a.Lg=(c>>>0)+(a.ba.Sa>>>0)+1}ye(a,0);pe(a)} +function be(a,b,c,d){void 0===c&&(c=!!(a.Lb.ra&1));a.ed=!1;if(c)if(a.load=a.ng,a.Aj=a.an,a.Bb=a.$i,a.Ub=a.bj,void 0===d&&(d=!!(a.Lb.P&131072)),d)a.load=a.H,a.Bb=a.D,a.Ub=a.F,a.Cb=a.qc=3,a.X=2,a.R=a.xa=65535,a.Sa=65535,a.Nb=a.Sa+1,a.Lc=a.X,a.Ob=-1,a.Ne=!1;else{if(!(a.T&-4))a.Bb=a.fg,a.Ub=a.hg;else if(a.type&4096){6144==(a.type&6656)&&(a.Bb=a.fg);if(a.type&2048||!(a.type&512))a.Ub=a.hg;1024==(a.type&3072)&&(a.Bb==a.$i&&(a.Bb=a.sl),a.Ub==a.bj&&(a.Ub=a.tl),a.ed=!0);b&&a.id>13,80386>a.Lb.da||!(a.ext&64)?(a.X=2,a.R=65535):(a.X=4,a.R=-1),a.Lc=a.X,a.xa=a.R)}else a.load=a.kh,a.Aj=a.bn,a.Bb=a.gg,a.Ub=a.gg,a.Cb=a.qc=0,a.Ob=-1,a.Ne=!1}var ke=1,we=2,ge=3,ie=4,fe=6,de=1; +function Ae(a){var b=+a.model||8088;switch(b){default:var c=4772727;break;case 80286:c=6E6;break;case 80386:c=16E6}yd.call(this,a,c);this.da=b;a=a.stepping;this.Qd=b+(a?qa(a,16):0);this.Xi=61442;this.Pd=1792;this.Pi=28672;this.Qf=4;this.Ra=255;this.B=80286<=this.da?Xb:Wb;this.wa=Be;this.fj=Ce;this.jj=De;this.oj=Ee;if(80186<=this.da&&(this.wa=Be.slice(),this.fj=Ce.slice(),this.jj=De.slice(),this.Ra=31,this.wa[15]=Ie,this.wa[96]=Je,this.wa[97]=Ke,this.wa[98]=Le,this.wa[99]=Ie,this.wa[100]=Ie,this.wa[101]= +Ie,this.wa[102]=Ie,this.wa[103]=Ie,this.wa[104]=Me,this.wa[105]=Ne,this.wa[106]=Oe,this.wa[107]=Pe,this.wa[108]=Qe,this.wa[109]=Re,this.wa[110]=Se,this.wa[111]=Te,this.wa[192]=Ue,this.wa[193]=Ve,this.wa[200]=We,this.wa[201]=Xe,this.wa[241]=Ye,this.fj[7]=Ze,this.jj[7]=Ze,80286<=this.da)){this.Xi=2;this.Pd|=28672;this.Qf=0;this.wa[15]=$e;this.qd=af.slice();for(b=0;b=this.Qd&&(this.qd[166]=jf,this.qd[167]=nf)}}this.Tf=[];this.Uf=[];this.Wf=0;Dd(this);this.aa.complete=this.aa.gj=!1;this.sj=0;this.sc=this.Z=[];this.lb=this.Lg=this.Fb=this.Rf=this.df=this.ef=this.bd=0;of(this)}ia(Ae,yd);function pf(a,b,c,d){md((d?a.sc:a.Z)[b>>>a.lb],c);d&&uc(a)} +function qf(a){var b;if(a.Z===a.sc){a.Z=Array(a.Rf);a.Vf=new w(null,0,0,ed,null,a);pc(a.Vf,a.ca);for(b=0;b>>20,f=a.sc[(a.wc+e&a.ef)>>>a.lb],g=f.Nd(e);if(!(g&1))return d||sf.call(a,b,!1,c),a.ff;if(!(g&4)&&3==a.Pa)return d||sf.call(a,b,!0,c),a.ff;var h=(b&4190208)>>>10;g=a.sc[((g&-4096)+h&a.ef)>>>a.lb];var k=g.Nd(h);if(!(k&1))return d||sf.call(a,b,!1,c),a.ff;if(!(k&4)&&3==a.Pa)return d||sf.call(a,b,!0,c),a.ff;c=a.sc[((k&-4096)+(b&4095)&a.ef)>>>a.lb];if(d)return c;d=b>>>a.lb;k=a.Z[d];b&=-4096;if(0>2;b.qb=g;b.B=h>>2;Vb&&Hc&&c.W&&!c.controller&&!c.Fe&&!c.Ge?(b.Qa=c.Qa,b.Td=c.Td,b.W=c.W,Cc(b,xd)):(b.F=c?wd(32):0,b.J=c?wd(96):0,Cc(b,hd));pc(b,a.ca,k);a.Z[d]=b;a.Sf.push(d);return b}function tf(a){a.Z!==a.sc&&(a.Z=a.sc,a.Vf=null,a.Sf=null,a.ff=null)}l=Ae.prototype;l.reset=function(){of(this);Dd(this);this.aa.error=!1}; +function uf(a,b){switch(b){case 0:var c=a.D;break;case 1:c=a.I;break;case 2:c=a.L;break;case 3:c=a.H;break;case 4:c=y(a);break;case 5:c=a.N;break;case 6:c=a.K;break;case 7:c=a.J}return c}function vf(a,b,c){switch(b){case 0:a.D=c;break;case 1:a.I=c;break;case 2:a.L=c;break;case 3:a.H=c;break;case 4:ne(a,c);break;case 5:a.N=c;break;case 6:a.K=c;break;case 7:a.J=c}} +function of(a){a.D=0;a.H=0;a.I=0;a.L=0;a.Ac=0;a.N=0;a.K=0;a.J=0;a.vc=!1;a.Ea=a.cb=0;a.Ym=[0,0];a.en=[0,0];a.Aa=0;a.pj=0;a.fa=0;a.ra=65520;a.Qb=0;a.$c=1023;a.P=a.lc=0;a.ze=a.gf=a.Sd=a.Ae=0;a.Sc=-1;a.nd=a.Tc=-1;a.od=a.ta=-1;a.ba=new Zd(a,ke,"CS");a.Fa=new Zd(a,we,"DS");a.pa=new Zd(a,we,"ES");a.U=new Zd(a,ge,"SS");ne(a,0);me(a,0);if(80386<=a.da){switch(a.Qd){case 80562:case 80563:a.L=771;break;case 80578:a.L=772;break;case 80594:a.L=773;break;case 80595:case 80596:a.L=776}a.ra=16;a.Mg=0;a.pd=0;a.wc= +0;a.Rb=[0,0,0,0,null,null,0,0];a.Yf=[null,null,null,null,null,null,0,0];a.Ka=new Zd(a,we,"FS");a.La=new Zd(a,we,"GS");tf(a)}a.Ig=new Zd(a,0,"NULL");a.Ga=a.Fa;a.Sb=a.U;a.M=a.ha=0;a.C=a.F=-1;a.Ia=a.Ig;a.ab=0;if(80286>a.da)ze(a,0,65535);else{a.Kb=0;a.Jc=65535;a.Gb=new Zd(a,5,"LDT",!0);a.ka=new Zd(a,ie,"TSS",!0);a.zb=new Zd(a,fe,"VER",!0);ze(a,65520,61440);var b=z(a);var c=a.ba;var d=-65536;80386>c.Lb.da&&(d&=16777215);c=c.ua=d;a.ea=c+b|0;a.Ng=(c>>>0)+(a.ba.Sa>>>0)+1}ye(a,0);pe(a)} function Bf(a){2==a.Lc?(a.Vb=a.ja,a.kc=Cf,a.uc=Df,a.kd=Ef,2==a.X?(a.la=Ff,a.Ba=Gf,a.mb=Hf):(a.la=If,a.Ba=Jf,a.mb=Kf)):(a.Vb=a.ia,a.kc=Lf,a.uc=Mf,a.kd=Nf,2==a.X?(a.la=Of,a.Ba=Pf,a.mb=Qf):(a.la=Rf,a.Ba=Sf,a.mb=Tf))}function qe(a,b){a.X!=b&&(a.ha|=1024,a.X=b,a.R=2==b?65535:-1,Uf(a))}function Uf(a){2==a.X?(a.Hb=32768,a.nb=a.ja,a.fc=a.ib,2==a.Lc?(a.la=Ff,a.Ba=Gf,a.mb=Hf):(a.la=Of,a.Ba=Pf,a.mb=Qf)):(a.Hb=-2147483648,a.nb=a.ia,a.fc=a.eb,2==a.Lc?(a.la=If,a.Ba=Jf,a.mb=Kf):(a.la=Rf,a.Ba=Sf,a.mb=Tf))} -function Vf(a){a.Lc=a.ba.Lc;a.xa=a.ba.xa;Bf(a);a.X=a.ba.X;a.R=a.ba.R;Uf(a);a.ha&=-3073}l.pj=function(){var a=this.D+this.H+this.I+this.L+y(this)+this.N+this.K+this.J|0;return a=a+z(this)+this.ba.T+this.Fa.T+this.U.T+this.pa.T+xe(this)|0};function Wf(a,b,c){void 0===a.Sf[b]&&(a.Sf[b]=[]);a.Sf[b].push(c)}function Xf(a,b,c){c&&(null==a.Tf[b]&&a.Vf++,a.Tf[b]=c)}function Yf(a,b){var c=a.Tf[b];null!=c&&(c(--a.Vf),delete a.Tf[b])} -function Zf(a,b){for(var c=a.Rb[7],d=c>>16,e=0;4>e;e++){if(c&3){var f=!!(d&1),g=a.Rb[e];g&=~(d>>2&3);b?a.aa[g>>>a.lb].rd(g&a.Fb,f,a):md(a.aa[g>>>a.lb],f)}c>>=2;d>>=4}}function od(a,b,c,d){if(!(a.M&8192)&&a.Rb[7]&255){c--;var e=a.Rb[7],f=e>>16;d=d?1:0==d?3:0;for(var g=0;4>g;g++){if(e&3&&(f&3)==d){var h=f>>2;if(b+c>=a.Rb[g]&&b<=a.Rb[g]+h){a.Rb[6]|=1<>=2;f>>=4}}} -function pe(a,b,c){void 0===b&&(b=!!(a.ra&1));void 0===c&&(c=!!(a.P&131072));a.ij=b&&!c?$f:Ee;be(a.ba,!1,b,c);be(a.Fa,!1,b,c);be(a.U,!1,b,c);be(a.pa,!1,b,c);80386<=a.da&&(be(a.Ka,!1,b,c),be(a.La,!1,b,c));Vf(a)} -l.save=function(a){var b=new ag(this);b.set(0,[this.D,this.H,this.I,this.L,y(this),this.N,this.K,this.J]);var c=z(this),d=this.ba.save(),e=this.Fa.save(),f=this.U.save(),g=this.pa.save();if(null!=this.Kb){var h=[this.ra,this.Kb,this.Jc,this.Qb,this.$c,this.Gb.save(),this.ka.save(),this.lc];80386<=this.da&&(h.push(this.Kg),h.push(this.pd),h.push(this.wc),h.push(this.Rb),h.push(this.Xf))}else h=null;c=[c,d,e,f,g,h,xe(this)];80386<=this.da&&(c.push(this.Ka.save()),c.push(this.La.save()));b.set(1,c); +function Vf(a){a.Lc=a.ba.Lc;a.xa=a.ba.xa;Bf(a);a.X=a.ba.X;a.R=a.ba.R;Uf(a);a.ha&=-3073}l.qj=function(){var a=this.D+this.H+this.I+this.L+y(this)+this.N+this.K+this.J|0;return a=a+z(this)+this.ba.T+this.Fa.T+this.U.T+this.pa.T+xe(this)|0};function Wf(a,b,c){void 0===a.Tf[b]&&(a.Tf[b]=[]);a.Tf[b].push(c)}function Xf(a,b,c){c&&(null==a.Uf[b]&&a.Wf++,a.Uf[b]=c)}function Yf(a,b){var c=a.Uf[b];null!=c&&(c(--a.Wf),delete a.Uf[b])} +function Zf(a,b){for(var c=a.Rb[7],d=c>>16,e=0;4>e;e++){if(c&3){var f=!!(d&1),g=a.Rb[e];g&=~(d>>2&3);b?a.Z[g>>>a.lb].rd(g&a.Fb,f,a):md(a.Z[g>>>a.lb],f)}c>>=2;d>>=4}}function od(a,b,c,d){if(!(a.M&8192)&&a.Rb[7]&255){c--;var e=a.Rb[7],f=e>>16;d=d?1:0==d?3:0;for(var g=0;4>g;g++){if(e&3&&(f&3)==d){var h=f>>2;if(b+c>=a.Rb[g]&&b<=a.Rb[g]+h){a.Rb[6]|=1<>=2;f>>=4}}} +function pe(a,b,c){void 0===b&&(b=!!(a.ra&1));void 0===c&&(c=!!(a.P&131072));a.oj=b&&!c?$f:Ee;be(a.ba,!1,b,c);be(a.Fa,!1,b,c);be(a.U,!1,b,c);be(a.pa,!1,b,c);80386<=a.da&&(be(a.Ka,!1,b,c),be(a.La,!1,b,c));Vf(a)} +l.save=function(a){var b=new ag(this);b.set(0,[this.D,this.H,this.I,this.L,y(this),this.N,this.K,this.J]);var c=z(this),d=this.ba.save(),e=this.Fa.save(),f=this.U.save(),g=this.pa.save();if(null!=this.Kb){var h=[this.ra,this.Kb,this.Jc,this.Qb,this.$c,this.Gb.save(),this.ka.save(),this.lc];80386<=this.da&&(h.push(this.Mg),h.push(this.pd),h.push(this.wc),h.push(this.Rb),h.push(this.Yf))}else h=null;c=[c,d,e,f,g,h,xe(this)];80386<=this.da&&(c.push(this.Ka.save()),c.push(this.La.save()));b.set(1,c); b.set(2,[this.Ga.hc,this.Sb.hc,this.M,this.ha,this.ab,this.C,this.F]);b.set(3,[0,this.Fd,this.Y.Ad,a,Rd(this)]);b.set(4,Nc(this.oa,!!(this.ra&-2147483648)));return b.data()}; -l.restore=function(a){var b=a[0];this.D=b[0];this.H=b[1];this.I=b[2];this.L=b[3];var c=b[4];this.N=b[5];this.K=b[6];this.J=b[7];b=a[1];this.ba.restore(b[1]);this.Fa.restore(b[2]);this.U.restore(b[3]);this.pa.restore(b[4]);var d=b[5];d&&d.length&&(this.ra=d[0],this.Kb=d[1],this.Jc=d[2],this.Qb=d[3],this.$c=d[4],this.Gb.restore(d[5]),this.ka.restore(d[6]),this.lc=d[7],80386<=this.da&&(this.Kg=d[8],this.pd=d[9],this.wc=d[10],this.Rb=d[11],this.Xf=d[12]),pe(this));ye(this,b[6]);d=!1;a:{var e=this.oa; -var f=a[4],g;for(g=0;g>>0)+(a.ba.Sa>>>0)+1;a.Pa=a.ba.Cb;Vf(a)} -function ze(a,b,c,d){var e=a.ba;e.Gf=b;e.C=d;b=e.load(c);return-1!==b?(dg(a,b+(a.ba.Gf&a.ba.R)),a.ba.Me):null}function eg(a,b){var c=(a.ea>>>0)+b;c>a.Lg&&(8088>=a.da?(c=a.ba.ua+(c-a.Lg&a.R),2==b&&(a.M|=8)):x.call(a,13,0));return c|0}function fg(a){a.ea=a.od}function y(a){return a.Ac&~a.U.xa|a.Ca-a.U.ua}function ne(a,b){a.Ac=b;a.Ca=a.U.ua+(b&a.U.xa)|0} -function gg(a,b,c,d,e,f){if(63!=(e&63)&&e!=a.resultType){var g=(e^a.resultType)&a.resultType;g&&(g&1&&hg(a),g&2&&ig(a),g&4&&jg(a),g&8&&kg(a),g&16&&lg(a),g&32&&mg(a))}f?(a.Sd=d,a.Rd=b):(a.Sd=b,a.Rd=d);a.ff=c;a.ze=d;a.resultType=e}function ng(a,b,c,d,e){a.resultType=c|26;a.ze=b;d?og(a):pg(a);e?qg(a):rg(a);return b}function sg(a,b,c,d){c&d?og(a):pg(a);(b^c)&d?qg(a):rg(a)}function tg(a){return hg(a)?1:0} -function hg(a){a.resultType&1&&(a.P&=-2,(a.Sd^(a.Sd^a.ff)&(a.ff^a.Rd))&a.resultType&-2147450752&&(a.P|=1),a.resultType&=-2);return a.P&1}function ig(a){a.resultType&2&&(a.P&=-5,38505>>((a.ze^a.ze>>4)&15)&1&&(a.P|=4),a.resultType&=-3);return a.P&4}function jg(a){a.resultType&4&&(a.P&=-17,(a.Rd^a.Sd^a.ff)&16&&(a.P|=16),a.resultType&=-5);return a.P&16}function kg(a){a.resultType&8&&(a.P&=-65,a.ze&((a.resultType&-2147450752)-1|a.resultType&-2147450752)||(a.P|=64),a.resultType&=-9);return a.P&64} -function lg(a){a.resultType&16&&(a.P&=-129,a.ze&a.resultType&-2147450752&&(a.P|=128),a.resultType&=-17);return a.P&128}function mg(a){a.resultType&32&&(a.P&=-2049,(a.Sd^a.Rd)&(a.ff^a.Rd)&a.resultType&-2147450752&&(a.P|=2048),a.resultType&=-33);return a.P&2048}function pg(a){a.resultType&=-2;a.P&=-2}function ug(a){a.resultType&=-5;a.P&=-17}function vg(a){a.resultType&=-9;a.P&=-65}function rg(a){a.resultType&=-33;a.P&=-2049}function og(a){a.resultType&=-2;a.P|=1} -function wg(a){a.resultType&=-5;a.P|=16}function xg(a){a.resultType&=-9;a.P|=64}function qg(a){a.resultType&=-33;a.P|=2048}function xe(a){return a.P&-2262|hg(a)|ig(a)|jg(a)|kg(a)|lg(a)|mg(a)}function yg(a,b){b|=a.ra&1|65520;a.ra=a.ra&-65536|b&65535;a.ra&1&&pe(a,!0)}function ye(a,b,c){a.ra&1||(b&=~a.ni);void 0===c&&(c=a.Pa);c?b=b&-12289|a.P&12288:a.lc=(b&12288)>>12;c>a.lc&&(b=b&-513|a.P&512);a.resultType=128;a.P=a.P&~(a.Pd|2261)|b&(a.Pd|2261)|a.Oi;a.P&256&&(a.ab|=2,a.M|=4)} -function zg(a,b,c,d){var e=0;if(a.ra&1&&(a.Pa>a.lc||a.P&131072)&&a.ka.Pi){var f=a.ka.Pi+(b>>>3);for(e=(1<>>=8,f++}return e?(r(a,256)&&Tb(a,"checkIOPM("+wa(b)+","+c+","+(d?"input":"output")+"): trapped",!0,!0),x.call(a,13,0),!1):!0} -l.Eb=function(a,b,c){switch(b){case "EAX":case "EBX":case "ECX":case "EDX":case "ESP":case "EBP":case "ESI":case "EDI":case "EIP":case "AX":case "BX":case "CX":case "DX":case "SP":case "BP":case "SI":case "DI":case "IP":case "PC":case "CS":case "DS":case "SS":case "ES":case "FS":case "GS":case "CR0":case "CR2":case "CR3":case "PS":case "C":case "P":case "A":case "Z":case "S":case "T":case "I":case "D":case "V":this.ma[b]=c;this.oj++;a=!0;break;default:a=yd.prototype.Eb.call(this,a,b,c)}return a}; -function Ag(a,b,c,d){var e=(d?a.sc:a.aa)[(b&a.bd)>>>a.lb];e&&e.type==ed&&(e=qd(a,b,!1,!0));if(e){var f=b&a.Fb;if(!c||1==c)return e.ae(f,b);if(2==c)return f>>this.lb].Cc(a&this.Fb,a)}; -l.ja=function(a){var b=a&this.Fb,c=(a&this.bd)>>>this.lb;this.A-=this.B.vg;if(b>>this.lb;if(b>>this.lb].Ec(a&this.Fb,b&255,a)}; -l.ib=function(a,b){var c=a&this.Fb,d=(a&this.bd)>>>this.lb;this.A-=this.B.vg;c>8&255,a+1))};l.eb=function(a,b){var c=a&this.Fb,d=(a&this.bd)>>>this.lb;this.A-=this.B.vg;if(c>>=8}}; -function Bg(a,b,c){a.Ia=b;a.vb=c&a.xa;a.C=b.Bb(a.vb,1);return a.M&1?0:a.ya(a.C)}function D(a,b){return Bg(a,a.Ga,b)}function Cg(a,b){return Bg(a,a.Sb,b)}function Dg(a,b,c){a.Ia=b;a.vb=c&a.xa;a.C=b.Bb(a.vb,a.X);if(a.M&9){if(a.M&1)return 0;a=a.ya(a.C)|a.ya(b.Bb(0,1))<<8}else a=a.nb(a.C);return a}function E(a,b){a.Ia=a.Ga;a.vb=b&a.xa;a.C=a.Ia.Bb(a.vb,2);if(a.M&9){if(a.M&1)return 0;b=a.ya(a.C)|a.ya(a.Ia.Bb(0,1))<<8;a.M&=-9}else b=a.ja(a.C);return b} +l.restore=function(a){var b=a[0];this.D=b[0];this.H=b[1];this.I=b[2];this.L=b[3];var c=b[4];this.N=b[5];this.K=b[6];this.J=b[7];b=a[1];this.ba.restore(b[1]);this.Fa.restore(b[2]);this.U.restore(b[3]);this.pa.restore(b[4]);var d=b[5];d&&d.length&&(this.ra=d[0],this.Kb=d[1],this.Jc=d[2],this.Qb=d[3],this.$c=d[4],this.Gb.restore(d[5]),this.ka.restore(d[6]),this.lc=d[7],80386<=this.da&&(this.Mg=d[8],this.pd=d[9],this.wc=d[10],this.Rb=d[11],this.Yf=d[12]),pe(this));ye(this,b[6]);d=!1;a:{var e=this.oa; +var f=a[4],g;for(g=0;g>>0)+(a.ba.Sa>>>0)+1;a.Pa=a.ba.Cb;Vf(a)} +function ze(a,b,c,d){var e=a.ba;e.Hf=b;e.C=d;b=e.load(c);return-1!==b?(dg(a,b+(a.ba.Hf&a.ba.R)),a.ba.Ne):null}function eg(a,b){var c=(a.ea>>>0)+b;c>a.Ng&&(8088>=a.da?(c=a.ba.ua+(c-a.Ng&a.R),2==b&&(a.M|=8)):x.call(a,13,0));return c|0}function fg(a){a.ea=a.od}function y(a){return a.Ac&~a.U.xa|a.Ca-a.U.ua}function ne(a,b){a.Ac=b;a.Ca=a.U.ua+(b&a.U.xa)|0} +function gg(a,b,c,d,e,f){if(63!=(e&63)&&e!=a.resultType){var g=(e^a.resultType)&a.resultType;g&&(g&1&&hg(a),g&2&&ig(a),g&4&&jg(a),g&8&&kg(a),g&16&&lg(a),g&32&&mg(a))}f?(a.ze=d,a.Sd=b):(a.ze=b,a.Sd=d);a.gf=c;a.Ae=d;a.resultType=e}function ng(a,b,c,d,e){a.resultType=c|26;a.Ae=b;d?og(a):pg(a);e?qg(a):rg(a);return b}function sg(a,b,c,d){c&d?og(a):pg(a);(b^c)&d?qg(a):rg(a)}function tg(a){return hg(a)?1:0} +function hg(a){a.resultType&1&&(a.P&=-2,(a.ze^(a.ze^a.gf)&(a.gf^a.Sd))&a.resultType&-2147450752&&(a.P|=1),a.resultType&=-2);return a.P&1}function ig(a){a.resultType&2&&(a.P&=-5,38505>>((a.Ae^a.Ae>>4)&15)&1&&(a.P|=4),a.resultType&=-3);return a.P&4}function jg(a){a.resultType&4&&(a.P&=-17,(a.Sd^a.ze^a.gf)&16&&(a.P|=16),a.resultType&=-5);return a.P&16}function kg(a){a.resultType&8&&(a.P&=-65,a.Ae&((a.resultType&-2147450752)-1|a.resultType&-2147450752)||(a.P|=64),a.resultType&=-9);return a.P&64} +function lg(a){a.resultType&16&&(a.P&=-129,a.Ae&a.resultType&-2147450752&&(a.P|=128),a.resultType&=-17);return a.P&128}function mg(a){a.resultType&32&&(a.P&=-2049,(a.ze^a.Sd)&(a.gf^a.Sd)&a.resultType&-2147450752&&(a.P|=2048),a.resultType&=-33);return a.P&2048}function pg(a){a.resultType&=-2;a.P&=-2}function ug(a){a.resultType&=-5;a.P&=-17}function vg(a){a.resultType&=-9;a.P&=-65}function rg(a){a.resultType&=-33;a.P&=-2049}function og(a){a.resultType&=-2;a.P|=1} +function wg(a){a.resultType&=-5;a.P|=16}function xg(a){a.resultType&=-9;a.P|=64}function qg(a){a.resultType&=-33;a.P|=2048}function xe(a){return a.P&-2262|hg(a)|ig(a)|jg(a)|kg(a)|lg(a)|mg(a)}function yg(a,b){b|=a.ra&1|65520;a.ra=a.ra&-65536|b&65535;a.ra&1&&pe(a,!0)}function ye(a,b,c){a.ra&1||(b&=~a.Pi);void 0===c&&(c=a.Pa);c?b=b&-12289|a.P&12288:a.lc=(b&12288)>>12;c>a.lc&&(b=b&-513|a.P&512);a.resultType=128;a.P=a.P&~(a.Pd|2261)|b&(a.Pd|2261)|a.Xi;a.P&256&&(a.ab|=2,a.M|=4)} +function zg(a,b,c,d){var e=0;if(a.ra&1&&(a.Pa>a.lc||a.P&131072)&&a.ka.Qi){var f=a.ka.Qi+(b>>>3);for(e=(1<>>=8,f++}return e?(r(a,256)&&Tb(a,"checkIOPM("+wa(b)+","+c+","+(d?"input":"output")+"): trapped",!0,!0),x.call(a,13,0),!1):!0} +l.Eb=function(a,b,c){switch(b){case "EAX":case "EBX":case "ECX":case "EDX":case "ESP":case "EBP":case "ESI":case "EDI":case "EIP":case "AX":case "BX":case "CX":case "DX":case "SP":case "BP":case "SI":case "DI":case "IP":case "PC":case "CS":case "DS":case "SS":case "ES":case "FS":case "GS":case "CR0":case "CR2":case "CR3":case "PS":case "C":case "P":case "A":case "Z":case "S":case "T":case "I":case "D":case "V":this.ma[b]=c;this.sj++;a=!0;break;default:a=yd.prototype.Eb.call(this,a,b,c)}return a}; +function Ag(a,b,c,d){var e=(d?a.sc:a.Z)[(b&a.bd)>>>a.lb];e&&e.type==ed&&(e=qd(a,b,!1,!0));if(e){var f=b&a.Fb;if(!c||1==c)return e.ae(f,b);if(2==c)return f>>this.lb].Cc(a&this.Fb,a)}; +l.ja=function(a){var b=a&this.Fb,c=(a&this.bd)>>>this.lb;this.A-=this.B.wg;if(b>>this.lb;if(b>>this.lb].Ec(a&this.Fb,b&255,a)}; +l.ib=function(a,b){var c=a&this.Fb,d=(a&this.bd)>>>this.lb;this.A-=this.B.wg;c>8&255,a+1))};l.eb=function(a,b){var c=a&this.Fb,d=(a&this.bd)>>>this.lb;this.A-=this.B.wg;if(c>>=8}};function Bg(a,b,c){a.Ia=b;a.vb=c&a.xa;a.C=b.Bb(a.vb,1);return a.M&1?0:a.ya(a.C)} +function D(a,b){return Bg(a,a.Ga,b)}function Cg(a,b){return Bg(a,a.Sb,b)}function Dg(a,b,c){a.Ia=b;a.vb=c&a.xa;a.C=b.Bb(a.vb,a.X);if(a.M&9){if(a.M&1)return 0;a=a.ya(a.C)|a.ya(b.Bb(0,1))<<8}else a=a.nb(a.C);return a}function E(a,b){a.Ia=a.Ga;a.vb=b&a.xa;a.C=a.Ia.Bb(a.vb,2);if(a.M&9){if(a.M&1)return 0;b=a.ya(a.C)|a.ya(a.Ia.Bb(0,1))<<8;a.M&=-9}else b=a.ja(a.C);return b} function Eg(a,b){a.Ia=a.Sb;a.vb=b&a.xa;a.C=a.Ia.Bb(a.vb,2);if(a.M&9){if(a.M&1)return 0;b=a.ya(a.C)|a.ya(a.Ia.Bb(0,1))<<8;a.M&=-9}else b=a.ja(a.C);return b}function F(a,b){a.Ia=a.Ga;a.vb=b&a.xa;a.C=a.Ia.Bb(a.vb,4);return a.M&1?0:a.ia(a.C)}function Hg(a,b){a.Ia=a.Sb;a.vb=b&a.xa;a.C=a.Ia.Bb(a.vb,4);return a.M&1?0:a.ia(a.C)}function Ig(a,b){a.M&2||a.ub(a.Ia.Ub(a.vb,1),b)}function Jg(a,b){if(!(a.M&2)){var c=a.Ia.Ub(a.vb,2);a.M&8?(a.ub(c,b),a.ub(a.Ia.Ub(0,1),b>>8),a.M&=-9):a.ib(c,b)}} function Kg(a,b){a.M&2||a.eb(a.Ia.Ub(a.vb,4),b)}function re(a,b,c){c=b.Bb(c,a.X);a.M&8?(b=a.ya(c)|a.ya(b.Bb(0,1))<<8,a.M&=-9):b=a.nb(c);return b}function Lg(a,b,c,d){c=b.Ub(c,a.X);a.M&8?(a.ub(c,d),a.ub(b.Ub(0,1),d>>8),a.M&=-9):a.fc(c,d)}l.sa=function(){var a=eg(this,1),b=this.ya(this.ea);this.ea=a;return b};function Mg(a){var b=eg(a,2);if(a.M&8){var c=a.ya(a.ea)|a.ya(b-1)<<8;a.M&=-9}else c=a.ja(a.ea);a.ea=b;return c} function K(a){var b=eg(a,a.Lc);if(a.M&8){var c=a.ya(a.ea)|a.ya(b-1)<<8;a.M&=-9}else c=a.Vb(a.ea);a.ea=b;return c}l.Ha=function(){var a=eg(this,this.X);if(this.M&8){var b=this.ya(this.ea)|this.ya(a-1)<<8;this.M&=-9}else b=this.nb(this.ea);this.ea=a;return b};l.S=function(){var a=eg(this,1),b=this.ya(this.ea)<<24>>24;this.ea=a;return b}; -function le(a){var b=a.nb(a.Ca);a.Ca=a.Ca+a.X|0;var c=(a.Mg>>>0)-(a.Ca>>>0);0>c&&(8088>=a.da?(ne(a,a.Ca-a.U.ua&a.U.xa),-1>c&&(b=b&255|a.ya(a.Ca-1)<<8)):-1>c?x.call(a,12,0):(!a.U.ed&&a.U.Sa==a.U.xa||a.U.ed&&!a.U.Sa)&&ne(a,a.Ca-a.U.ua&a.U.xa));return b}function ve(a,b){se(a,b,a.X)} -function se(a,b,c,d){d=void 0===d?c:d;var e=a.Ca-c|0,f=(e>>>0)-(a.vj>>>0);if(0>f){if(8088>=a.da&&-1==f){a.ub(e+1,b>>8);ne(a,e-a.U.ua&a.U.xa);a.ub(a.Ca,b);return}if(!a.U.ed&&a.U.Sa==a.U.xa||a.U.ed&&!a.U.Sa){if(f>-c){x.call(a,12,0);return}ne(a,e-a.U.ua&a.U.xa);e=a.Ca}else{x.call(a,12,0);return}}switch(d){case 1:a.ub(e,b);break;case 2:a.ib(e,b);break;case 4:a.eb(e,b)}a.Ca=e} -function Ng(a,b,c){var d=4;1==b.length&&(d=1,c=c?1:0);if(80386>a.da)2this.da?0:1;for(var e=0;2>e;e++){switch(d){case 0:if(this.ab&1&&this.P&512){var f=Pg(this.V);if(-1<=f&&(this.ab&=-2,0<=f)){this.ab&=-5;Qg.call(this, -f);d=!0;break a}}break;case 1:if(this.ab&2){this.ab&=-3;80386<=this.da&&(this.Rb[6]|=16384);Qg.call(this,1);d=!0;break a}}d=1-d}}d=!1}if(d&&!a){this.O("interrupt dispatched");this.M=0;break}if(this.ab&4){this.M=this.A=0;break}}if(b){if(Rg(this.ca,this.ea,c)){Gd(this);break}c=1}this.M=0;this.wa[this.sa()].call(this)}while(0>>0)-(a.Ca>>>0);0>c&&(8088>=a.da?(ne(a,a.Ca-a.U.ua&a.U.xa),-1>c&&(b=b&255|a.ya(a.Ca-1)<<8)):-1>c?x.call(a,12,0):(!a.U.ed&&a.U.Sa==a.U.xa||a.U.ed&&!a.U.Sa)&&ne(a,a.Ca-a.U.ua&a.U.xa));return b}function ve(a,b){se(a,b,a.X)} +function se(a,b,c,d){d=void 0===d?c:d;var e=a.Ca-c|0,f=(e>>>0)-(a.xj>>>0);if(0>f){if(8088>=a.da&&-1==f){a.ub(e+1,b>>8);ne(a,e-a.U.ua&a.U.xa);a.ub(a.Ca,b);return}if(!a.U.ed&&a.U.Sa==a.U.xa||a.U.ed&&!a.U.Sa){if(f>-c){x.call(a,12,0);return}ne(a,e-a.U.ua&a.U.xa);e=a.Ca}else{x.call(a,12,0);return}}switch(d){case 1:a.ub(e,b);break;case 2:a.ib(e,b);break;case 4:a.eb(e,b)}a.Ca=e} +function Ng(a,b,c){var d=4;1==b.length&&(d=1,c=c?1:0);if(80386>a.da)2this.da?0:1;for(var e=0;2>e;e++){switch(d){case 0:if(this.ab&1&&this.P&512){var f=Pg(this.V);if(-1<=f&&(this.ab&=-2,0<=f)){this.ab&=-5; +Qg.call(this,f);d=!0;break a}}break;case 1:if(this.ab&2){this.ab&=-3;80386<=this.da&&(this.Rb[6]|=16384);Qg.call(this,1);d=!0;break a}}d=1-d}}d=!1}if(d&&!a){this.O("interrupt dispatched");this.M=0;break}if(this.ab&4){this.M=this.A=0;break}}if(b){if(Rg(this.ca,this.ea,c)){Gd(this);break}c=1}this.M=0;this.wa[this.sa()].call(this)}while(0>11;Wg(this);Xg(this,a[b++]);for(c=0;c=Yg&&Zg(a,lh))}function Wg(a){a.ga&=-129;a.ga&~a.bc&63&&(a.ga|=128);if(a.ga&128&&!(a.bc&128))return a=a.V,a.da>=Yg?mh(a,lh):a.fa&nh||Qg.call(a.G,2),!0;a=a.V;a.da>=Yg&&Zg(a,lh);return!1}function oh(a,b){80387<=a.da||(b&=-65);a.ga|=b;return Wg(a)} function Ug(a){return a.ga|a.B<<11}function ph(a,b){return isFinite(b)?!0:!oh(a,Infinity===b?8:16)}function qh(a,b,c){var d=null;null!=b&&null!=c&&(d=b+c,ph(a,d)||(d=null));return d}function rh(a,b,c){var d=null;null!=b&&null!=c&&(d=b-c,ph(a,d)||(d=null));return d}function sh(a,b,c){var d=null;null!=b&&null!=c&&(d=b*c,ph(a,d)||(d=null));return d}function th(a,b,c){var d=null;null==b||null==c||!c&&oh(a,2)||(d=b/c,ph(a,d)||(d=null));return d} function uh(a,b,c){if(null!=b&&null!=c){var d=0;isNaN(b)||isNaN(c)?d=17664:(b-=c,0>b?d=256:0===b&&(d=16384));a.ga=a.ga&-18177|d;return!0}return!1}function vh(a,b,c){if(null==b)return null;var d=a.bc&3072;0==d?(d=Math.round(b),.5===d-b&&d%2&&d--):d=1024==d||3072==d&&0=c){if(oh(a,1))return null;d=-c}else if(d<-c){if(oh(a,1))return null;d=-c}a.H[0]=d|0;2147483648d&&(a.H[1]=-1))}return d} -function wh(a,b){var c=3;a.C&1<=c;c<<=1)3!=(b&3)&&(a.C|=c),b>>=2}function xh(a){var b=a.B+0&7;return a.C&1<>16}function Ch(a){return a.G.ia(a.G.C)}function Dh(a){a.ha[0]=a.G.ia(a.G.C);return a.aa[0]}function Eh(a){a.H[0]=a.G.ia(a.G.C);a.H[1]=a.G.ia(a.G.C+4);return a.K[0]} -function Fh(a){a.D[0]=a.G.ia(a.G.C);a.D[1]=a.G.ia(a.G.C+4);a.D[2]=a.G.ja(a.G.C+8);return a.D}l.hi=function(){this.G.eb(this.G.C,this.H[0])};l.Wk=function(){this.G.eb(this.G.C,this.H[0]);this.G.eb(this.G.C+4,this.H[1])};function Gh(a){a.G.eb(a.G.C,a.D[0]);a.G.eb(a.G.C+4,a.D[1]);a.G.ib(a.G.C+8,a.D[2])}function Hh(a,b){var c=b[1],d=(b[2]&32768)>>4,e=b[2]&32767;b=b[0]>>>11|c<<21;c=c>>11&1048575;32767==e?e=2047:e&&(e+=-15360,0>=e&&(e=2047,b=c=0));a.H[0]=b;a.H[1]=c|(d|e)<<20;return a.K[0]} +function wh(a,b){var c=3;a.C&1<=c;c<<=1)3!=(b&3)&&(a.C|=c),b>>=2}function xh(a){var b=a.B+0&7;return a.C&1<>16}function Ch(a){return a.G.ia(a.G.C)}function Dh(a){a.ha[0]=a.G.ia(a.G.C);return a.Z[0]}function Eh(a){a.H[0]=a.G.ia(a.G.C);a.H[1]=a.G.ia(a.G.C+4);return a.K[0]} +function Fh(a){a.D[0]=a.G.ia(a.G.C);a.D[1]=a.G.ia(a.G.C+4);a.D[2]=a.G.ja(a.G.C+8);return a.D}l.ji=function(){this.G.eb(this.G.C,this.H[0])};l.Xk=function(){this.G.eb(this.G.C,this.H[0]);this.G.eb(this.G.C+4,this.H[1])};function Gh(a){a.G.eb(a.G.C,a.D[0]);a.G.eb(a.G.C+4,a.D[1]);a.G.ib(a.G.C+8,a.D[2])}function Hh(a,b){var c=b[1],d=(b[2]&32768)>>4,e=b[2]&32767;b=b[0]>>>11|c<<21;c=c>>11&1048575;32767==e?e=2047:e&&(e+=-15360,0>=e&&(e=2047,b=c=0));a.H[0]=b;a.H[1]=c|(d|e)<<20;return a.K[0]} function Ah(a,b,c){var d=c>>20&2047,e=2147483648|(c&1048575)<<11|b>>>21;2047==d?d=32767:d?d+=15360:e&=2147483647;a.D[0]=b<<11;a.D[1]=e;a.D[2]=c>>16&32768|d;return a.D}function Ih(a,b){for(var c=0,d=1;b--;)c+=(a&15)*d,d*=10,a>>=4;return c}function Jh(a,b){for(var c=0,d=0;b--;)c|=a%10<>11;Wg(a);Xg(a,c.nb(b+=c.X));!(c.ra&1)||c.P&131072?(a.I=c.nb(b+=c.X),d=c.nb(b+=c.X),a.P=d&2047,a.I|=(d&-4096)<<4,a.M=-1,a.J=c.nb(b+=c.X),a.J|=(c.nb(b+=c.X)&-4096)<<4,a.N=-1):(a.I=c.nb(b+=c.X),d=c.nb(b+=c.X),a.M=d&65535,a.P=d>>16&2047,a.J=c.nb(b+=c.X),a.N=c.nb(b+=c.X)&65535);return b+c.X} @@ -218,43 +218,43 @@ var gi=Math.log(10)/Math.LN2,hi=Math.LOG2E,ii=Math.PI,ji=Math.log(2)/Math.LN10,k 0,-L(this,0))},65:function(){M(this,0,Math.abs(L(this,0)))},68:function(){uh(this,L(this,0),0)},69:function(){this.ga&=-18177;this.L[((this.B+0&7)<<1)+1]&-2147483648&&(this.ga|=512);if(3==wh(this,this.B))this.ga|=16640;else{var a=L(this,0);this.ga=isNaN(a)?this.ga|256:0===a?this.ga|16384:Infinity===a||-Infinity===a?this.ga|1280:this.ga|1024}},80:function(){Lh(this,1)},81:function(){Lh(this,gi)},82:function(){Lh(this,hi)},83:function(){Lh(this,ii)},84:function(){Lh(this,ji)},85:function(){Lh(this, ki)},86:function(){Lh(this,0)},96:function(){M(this,0,Math.pow(2,L(this,0))-1)},97:function(){M(this,1,L(this,1)*Math.log(L(this,0))/Math.LN2)&&Kh(this)},98:function(){M(this,0,Math.tan(L(this,0)))&&Lh(this,1)},99:function(){M(this,1,Math.atan2(L(this,1),L(this,0)))&&Kh(this)},100:function(){var a=L(this,0);null!=a&&(this.K[0]=a,M(this,0,(this.H[1]>>20&2047)-1023),this.H[1]=(this.H[1]|1072693248)&-1073741825,Lh(this,this.K[0]))},102:function(){this.B=this.B-1&7;this.ga&=-513},103:function(){this.B= this.B+1&7;this.ga&=-513},112:function(){M(this,0,L(this,0)%L(this,1))},113:function(){M(this,1,L(this,1)*Math.log(L(this,0)+1)/Math.LN2)&&Kh(this)},114:function(){var a=L(this,0),b=null;if(0<=a||!oh(this,1))b=Math.sqrt(a),ph(this,b)||(b=null);M(this,0,b)},116:function(){M(this,0,vh(this,L(this,0),li))},117:function(){var a=L(this,0),b=L(this,1);null!=a&&null!=b&&M(this,0,a*Math.pow(2,0>>0);Lh(this,a)},6:function(){var a=vh(this,Kh(this));null!=a&&(this.D[0]=Jh(a,8),this.D[1]=Jh(a/1E8,8),this.D[2]=Jh(a/1E16,2),0>a&&(this.D[2]|=32768),Gh(this))},7:function(){null!=vh(this,L(this,0),li)&&(this.Wk(),Kh(this))},48:function(){Th.call(this);Kh(this)},49:fi,50:ai,51:ai,52:di}},ni=[Oh,Uh,Vh,Wh,Xh,Yh,bi,Zh,ci,di];cb(function(){for(var a=zb(document,"pcx86","fpu"),b=0;b>>0);Lh(this,a)},6:function(){var a=vh(this,Kh(this));null!=a&&(this.D[0]=Jh(a,8),this.D[1]=Jh(a/1E8,8),this.D[2]=Jh(a/1E16,2),0>a&&(this.D[2]|=32768),Gh(this))},7:function(){null!=vh(this,L(this,0),li)&&(this.Xk(),Kh(this))},48:function(){Th.call(this);Kh(this)},49:fi,50:ai,51:ai,52:di}},ni=[Oh,Uh,Vh,Wh,Xh,Yh,bi,Zh,ci,di];cb(function(){for(var a=zb(document,"pcx86","fpu"),b=0;b>16,c=c<<16>>16,d=d<<16>>16);this.A-=this.B.Ej;(bd)&&x.call(this,5);this.M|=2;return a}function wi(a,b){var c=0;if(b){vg(this);for(var d=1;d&this.R;){if(b&d){a=c;break}d<<=1;c++}}else xg(this);this.A-=11+3*c;return a}function xi(a,b){var c=0;if(b){vg(this);for(var d=2==this.X?15:31,e=1<>>=1;c++;d--}}else xg(this);this.A-=11+3*c;return a} +function vi(a){if(-1===this.C)return x.call(this,6),a;var b=a,c=this.nb(this.C),d=this.nb(this.C+this.X);2==this.X&&(b=a<<16>>16,c=c<<16>>16,d=d<<16>>16);this.A-=this.B.Fj;(bd)&&x.call(this,5);this.M|=2;return a}function wi(a,b){var c=0;if(b){vg(this);for(var d=1;d&this.R;){if(b&d){a=c;break}d<<=1;c++}}else xg(this);this.A-=11+3*c;return a}function xi(a,b){var c=0;if(b){vg(this);for(var d=2==this.X?15:31,e=1<>>=1;c++;d--}}else xg(this);this.A-=11+3*c;return a} function yi(a,b){a&1<<(b&(2==this.X?15:31))?og(this):pg(this);this.A-=-1===this.C?3:6;this.M|=2;return a}function zi(a,b){b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=-1===this.C?6:8;return a^b}function Ai(a,b){b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=-1===this.C?6:8;return a&~b}function Bi(a,b){b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=-1===this.C?6:8;return a|b} function Ci(a,b){if(-1===this.C)return yi.call(this,a,b);var c=this.X<<3;if(b>=c||b<-c)a=Dg(this,this.Ia,this.vb+(b>>(2==this.X?4:5))*this.X);b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=6;this.M|=2;return a}function Di(a,b){if(-1===this.C)return zi.call(this,a,b);var c=this.X<<3;if(b>=c||b<-c)a=Dg(this,this.Ia,this.vb+(b>>(2==this.X?4:5))*this.X);b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=8;return a^b} function Ei(a,b){if(-1===this.C)return Ai.call(this,a,b);var c=this.X<<3;if(b>=c||b<-c)a=Dg(this,this.Ia,this.vb+(b>>(2==this.X?4:5))*this.X);b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=8;return a&~b}function Fi(a,b){if(-1===this.C)return Bi.call(this,a,b);var c=this.X<<3;if(b>=c||b<-c)a=Dg(this,this.Ia,this.vb+(b>>(2==this.X?4:5))*this.X);b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=8;return a|b} -function Gi(a,b){gg(this,a,b,a-b|0,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.vh:this.B.Mb;this.M|=2;return a}function Hi(a,b){gg(this,a,b,a-b|0,this.Hb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.vh:this.B.Mb;this.M|=2;return a} -function Ii(a){if(this.Kc){var b=this.Kc,c=this.nj,d=this.fa,e=d>>3&7;b.A=d&7;var f=(3>(d>>6&3)?0:48)+e;(217==c||219==c)&&52<=f&&(f=e<<4|b.A);if(e=mi[c][f]){if(0>ni.indexOf(e)){f=b.G;var g=f.od;8087==b.da&&(f.ha&16&&g++,f.ha&32&&g++);b.M=f.ba.T;b.I=g-f.ba.ua;-1!==f.C&&(b.N=f.Ia.T,b.J=f.C-f.Ia.ua);b.P=(c&7)<<8|d}e.call(b)}}this.A-=-1===this.C?2:8;return a}function Ji(a){if(80186>this.da)return Ki.call(this,a);x.call(this,13,0);return a}function Ze(a){x.call(this,6);return a} +function Gi(a,b){gg(this,a,b,a-b|0,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.xh:this.B.Mb;this.M|=2;return a}function Hi(a,b){gg(this,a,b,a-b|0,this.Hb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.xh:this.B.Mb;this.M|=2;return a} +function Ii(a){if(this.Kc){var b=this.Kc,c=this.pj,d=this.fa,e=d>>3&7;b.A=d&7;var f=(3>(d>>6&3)?0:48)+e;(217==c||219==c)&&52<=f&&(f=e<<4|b.A);if(e=mi[c][f]){if(0>ni.indexOf(e)){f=b.G;var g=f.od;8087==b.da&&(f.ha&16&&g++,f.ha&32&&g++);b.M=f.ba.T;b.I=g-f.ba.ua;-1!==f.C&&(b.N=f.Ia.T,b.J=f.C-f.Ia.ua);b.P=(c&7)<<8|d}e.call(b)}}this.A-=-1===this.C?2:8;return a}function Ji(a){if(80186>this.da)return Ki.call(this,a);x.call(this,13,0);return a}function Ze(a){x.call(this,6);return a} function Ki(a){bf.call(this);return a}function Li(a,b){a=Mi.call(this,this.S(),b);80386>this.da&&(this.A-=12);return a}function Ni(a,b){a=this.Ha();a=2==this.X?Mi.call(this,a,b):Oi.call(this,a,b);80386>this.da&&(this.A-=12);return a}function Pi(a,b){var c=!1;0>b&&(b=-b|0,c=!c);0>a&&(a=-a|0,c=!c);Qi.call(this,a,b);c&&(this.Ea=~this.Ea+1|0,this.cb=~this.cb+(this.Ea?0:1)|0)} function Mi(a,b){a=(a<<16>>16)*(b<<16>>16)|0;32767a?(og(this),qg(this)):(pg(this),rg(this));this.A-=-1===this.C?9:12;return a&65535}function Oi(a,b){Pi.call(this,a,b);this.cb!=this.Ea>>31?(og(this),qg(this)):(pg(this),rg(this));this.A-=-1===this.C?9:12;return this.Ea}function Ri(a,b){this.A-=14+(-1===this.C?0:2);vg(this);-1!==this.zb.load(b)&&this.zb.qc>=this.Pa&&this.zb.qc>=(b&3)&&(xg(this),a=this.zb.ob&-256,2=this.Pa)&&this.zb.qc>=(b&3))return xg(this),this.zb.Sa;vg(this);return a}function Yi(a,b){if(-1===this.C)return bf.call(this),a;me(this,this.ja(this.C+this.X));this.A-=this.B.Ue;return b} -function Zi(a,b){this.A-=-1===this.F?-1===this.C?this.B.nk:this.B.mk:this.B.kk;return b}function $i(a,b){switch(this.fa>>3&7){case 4:this.Aa=this.D;break;case 5:this.Aa=this.I;break;case 6:this.Aa=this.L;break;case 7:this.Aa=this.H}return b}function aj(a,b){return b} +function Si(a,b){if(-1===this.C)return bf.call(this),a;te(this,this.ja(this.C+this.X));this.A-=this.B.Ve;return b}function Ti(){this.A-=this.B.hk;return this.C}function Ui(a,b){if(-1===this.C)return bf.call(this),a;ue(this,this.ja(this.C+this.X));this.A-=this.B.Ve;return b}function Vi(a,b){if(-1===this.C)return bf.call(this),a;a=this.ja(this.C+this.X);this.Ka.load(a);this.A-=this.B.Ve;return b} +function Wi(a,b){if(-1===this.C)return bf.call(this),a;a=this.ja(this.C+this.X);this.La.load(a);this.A-=this.B.Ve;return b}function Xi(a,b){this.A-=14+(-1===this.C?0:2);if(b&65528&&-1!==this.zb.load(b)&&(7168==(this.zb.ob&7168)||this.zb.qc>=this.Pa)&&this.zb.qc>=(b&3))return xg(this),this.zb.Sa;vg(this);return a}function Yi(a,b){if(-1===this.C)return bf.call(this),a;me(this,this.ja(this.C+this.X));this.A-=this.B.Ve;return b} +function Zi(a,b){this.A-=-1===this.F?-1===this.C?this.B.pk:this.B.nk:this.B.lk;return b}function $i(a,b){switch(this.fa>>3&7){case 4:this.Aa=this.D;break;case 5:this.Aa=this.I;break;case 6:this.Aa=this.L;break;case 7:this.Aa=this.H}return b}function aj(a,b){return b} function bj(a,b){a=this.fa>>3&7;switch(a){case 0:this.Aa=this.D;break;case 2:this.Aa=this.L;break;case 3:this.Aa=this.H;break;default:if(80286==this.da||80386==this.da&&4!=a&&5!=a)x.call(this,6);else switch(a){case 1:this.Aa=this.I;break;case 4:this.Aa=y(this);break;case 5:this.Aa=this.N;break;case 6:this.Aa=this.K;break;case 7:this.Aa=this.J}}return Zi.call(this,0,b)} function cj(a,b){switch(this.fa>>3&7){case 0:b=this.pa.T;break;case 1:b=this.ba.T;break;case 2:b=this.U.T;break;case 3:b=this.Fa.T;break;case 4:if(80386<=this.da){b=this.Ka.T;break}x.call(this,6);b=a;break;case 5:if(80386<=this.da){b=this.La.T;break}default:x.call(this,6),b=a}-1!==this.F&&qe(this,2);return Zi.call(this,0,b)} function Qi(a,b){if(a&-65536||b&-65536){var c=b&65535;b>>>=16;var d=a&65535;a>>>=16;var e=c*d;d=(e>>>16)+b*d;var f=d>>>16;d=(d&65535)+c*a;this.Ea=d<<16|e&65535;this.cb=f+((d>>>16)+b*a)|0}else this.Ea=a*b|0,this.cb=0}function dj(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return ng(this,a|b,128)}function ej(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return ng(this,a|b,this.Hb)&this.R} function fj(a,b){var c=a-b-tg(this)|0;gg(this,a,b,c,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return c&255}function gj(a,b){var c=a-b-tg(this)|0;gg(this,a,b,c,this.Hb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return c&this.R}function hj(){return mg(this)?1:0}function rj(){return hg(this)?1:0}function sj(){return hg(this)?0:1}function tj(){return kg(this)?1:0}function uj(){return kg(this)?0:1}function vj(){return hg(this)||kg(this)?1:0} function wj(){return hg(this)||kg(this)?0:1}function xj(){return lg(this)?1:0}function yj(){return lg(this)?0:1}function zj(){return ig(this)?1:0}function Aj(){return ig(this)?0:1}function Bj(){return!lg(this)!=!mg(this)?1:0}function Cj(){return!lg(this)!=!mg(this)?0:1}function Dj(){return kg(this)||!lg(this)!=!mg(this)?1:0}function Ej(){return kg(this)||!lg(this)!=!mg(this)?0:1}function Fj(a,b){return Gj.call(this,a,b,this.sa())}function Hj(a,b){return Ij.call(this,a,b,this.sa())} function Jj(a,b){return Gj.call(this,a,b,this.I&31)}function Kj(a,b){return Ij.call(this,a,b,this.I&31)}function Lj(a,b){return Mj.call(this,a,b,this.sa())}function Nj(a,b){return Oj.call(this,a,b,this.sa())}function Pj(a,b){return Mj.call(this,a,b,this.I&31)}function Qj(a,b){return Oj.call(this,a,b,this.I&31)}function Rj(a,b){var c=a-b|0;gg(this,a,b,c,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return c&255} -function Sj(a,b){var c=a-b|0;gg(this,a,b,c,this.Hb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return c&this.R}function Tj(a,b){ng(this,a&b,128);this.A-=-1===this.F?-1===this.C?this.B.Xh:this.B.Cf:this.B.Cf;this.M|=2;return a}function Uj(a,b){ng(this,a&b,this.Hb);this.A-=-1===this.F?-1===this.C?this.B.Xh:this.B.Cf:this.B.Cf;this.M|=2;return a}function Vj(a,b){var c=this.D&this.R,d=(1<<(this.I&31))-1;return a&~(d<>(this.D&this.R)&(1<<(this.I&31))-1&this.R}function Xj(a,b){if(-1===this.C){switch(this.fa&7){case 0:this.D=this.D&-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.H=this.H&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.H=this.H&-65281|a<<8}this.A-=this.B.Zh}else this.F=this.C,Ig(this,a),this.A-=this.B.Yh;return b} -function Yj(a,b){if(-1===this.C){switch(this.fa&7){case 0:this.D=this.D&~this.R|a;break;case 1:this.I=this.I&~this.R|a;break;case 2:this.L=this.L&~this.R|a;break;case 3:this.H=this.H&~this.R|a;break;case 4:ne(this,y(this)&~this.R|a);break;case 5:this.N=this.H&~this.R|a;break;case 6:this.K=this.K&~this.R|a;break;case 7:this.J=this.J&~this.R|a}this.A-=this.B.Zh}else{this.F=this.C;if(!(this.M&2)){var c=this.Ia.Ub(this.vb,this.X);this.M&8?(this.ub(c,a),this.ub(this.Ia.Ub(0,1),a>>8),this.M&=-9):this.fc(c, -a)}this.A-=this.B.Yh}return b}function Zj(a,b){a^=b;ng(this,a,128);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return a}function ak(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return ng(this,a^b,this.Hb)&this.R}function bk(a,b){var c=a[1]-b[1];c||(c=a[0]-b[0]);return c}function ck(a){var b=a-1|0;gg(this,a,1,b,this.Hb|62,!0);this.A-=2;return a&~this.R|b&this.R} -function dk(a,b,c){c>>>=0;if(!c||c<=b>>>0)return!1;var d=0,e=1,f=this.Wm;f[0]=c>>>0;f[1]=0;c=this.Ym;c[0]=a>>>0;for(c[1]=b>>>0;0>>=0,a[1]++),e+=e;do 0<=bk(c,f)&&(a=c,b=f,a[0]-=b[0],a[1]-=b[1],0>a[0]&&(a[0]>>>=0,a[1]--),d+=e),a=f,a[0]>>>=1,a[1]&1&&(a[0]=(a[0]|2147483648)>>>0),a[1]>>>=1,e/=2;while(1<=e);this.Ea=d;this.cb=c[0];return!0}function ek(a){var b=a+1|0;gg(this,a,1,b,this.Hb|62);this.A-=2;return a&~this.R|b&this.R} +function Sj(a,b){var c=a-b|0;gg(this,a,b,c,this.Hb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return c&this.R}function Tj(a,b){ng(this,a&b,128);this.A-=-1===this.F?-1===this.C?this.B.Zh:this.B.Df:this.B.Df;this.M|=2;return a}function Uj(a,b){ng(this,a&b,this.Hb);this.A-=-1===this.F?-1===this.C?this.B.Zh:this.B.Df:this.B.Df;this.M|=2;return a}function Vj(a,b){var c=this.D&this.R,d=(1<<(this.I&31))-1;return a&~(d<>(this.D&this.R)&(1<<(this.I&31))-1&this.R}function Xj(a,b){if(-1===this.C){switch(this.fa&7){case 0:this.D=this.D&-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.H=this.H&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.H=this.H&-65281|a<<8}this.A-=this.B.ai}else this.F=this.C,Ig(this,a),this.A-=this.B.$h;return b} +function Yj(a,b){if(-1===this.C){switch(this.fa&7){case 0:this.D=this.D&~this.R|a;break;case 1:this.I=this.I&~this.R|a;break;case 2:this.L=this.L&~this.R|a;break;case 3:this.H=this.H&~this.R|a;break;case 4:ne(this,y(this)&~this.R|a);break;case 5:this.N=this.H&~this.R|a;break;case 6:this.K=this.K&~this.R|a;break;case 7:this.J=this.J&~this.R|a}this.A-=this.B.ai}else{this.F=this.C;if(!(this.M&2)){var c=this.Ia.Ub(this.vb,this.X);this.M&8?(this.ub(c,a),this.ub(this.Ia.Ub(0,1),a>>8),this.M&=-9):this.fc(c, +a)}this.A-=this.B.$h}return b}function Zj(a,b){a^=b;ng(this,a,128);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return a}function ak(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return ng(this,a^b,this.Hb)&this.R}function bk(a,b){var c=a[1]-b[1];c||(c=a[0]-b[0]);return c}function ck(a){var b=a-1|0;gg(this,a,1,b,this.Hb|62,!0);this.A-=2;return a&~this.R|b&this.R} +function dk(a,b,c){c>>>=0;if(!c||c<=b>>>0)return!1;var d=0,e=1,f=this.Ym;f[0]=c>>>0;f[1]=0;c=this.en;c[0]=a>>>0;for(c[1]=b>>>0;0>>=0,a[1]++),e+=e;do 0<=bk(c,f)&&(a=c,b=f,a[0]-=b[0],a[1]-=b[1],0>a[0]&&(a[0]>>>=0,a[1]--),d+=e),a=f,a[0]>>>=1,a[1]&1&&(a[0]=(a[0]|2147483648)>>>0),a[1]>>>=1,e/=2;while(1<=e);this.Ea=d;this.cb=c[0];return!0}function ek(a){var b=a+1|0;gg(this,a,1,b,this.Hb|62);this.A-=2;return a&~this.R|b&this.R} function fk(a){this.ra=a;pe(this);this.ra&-2147483648?qf(this):tf(this)}function gk(a){this.M|=1;this.uc.call(this,a);this.A-=-1===this.C?4:5}function Gj(a,b,c){if(c){16>>16-c)&65535;ng(this,a,32768,d&32768)}return a}function Ij(a,b,c){if(c){var d=a<>>32-c;ng(this,a,-2147483648,d&-2147483648)}return a}function Mj(a,b,c){if(c){16>>c-1;a=(d>>>1|b<<16-c)&65535;ng(this,a,32768,d&1)}return a} -function Oj(a,b,c){if(c){var d=a>>>c-1;a=d>>>1|b<<32-c;ng(this,a,-2147483648,d&1)}return a}function hk(){this.A-=-1===this.C?2:this.B.Bk;return 1}function ik(){var a=this.I&255;this.A-=(-1===this.C?this.B.Qh:this.B.Ph)+(a<this.Sc?(-1!=this.nd&&(this.nd!==this.ba.T&&(this.ba.Cb=this.nd&3,cg(this,this.nd)),this.nd=-1),this.od!==this.ea&&dg(this,this.od),-1!=this.Tc&&(this.Tc!==this.U.T&&me(this,this.Tc),this.Tc=-1),-1!==this.ta&&(this.ta!==this.Ca&&ne(this,this.Ac&~this.U.xa|this.ta-this.U.ua),this.ta=-1)):8!=this.Sc?(b=0,a=8):(b=0,a=-1,of(this),e=d=!1)):dg(this,this.od);var f=a,g=b,h=32,k=Ag(this,this.ea);204!=k||this.$c||(d=!1);this.P&131072&&(6== -f&&99==k||13==f&&205==k)&&(d=!1);!1===d&&(h|=1);983040<=this.ea&&1048575>=this.ea&&(d=!1);r(this,h|-2147483648)&&(d=!0);if(r(this,h)||d){var m=this.Z.Xa;f="Fault "+va(f)+(null!=g?" ("+wa(g)+")":"")+" on opcode "+va(k);d&&m&&(f+=" (blocked)");this.ca?(Tb(this,f,d||h,!0),d&&(d=m,rk(this.ca))):(this.Da(f),Gd(this))}if(d&&e)throw-1;if(e)throw this.Sc=a,nk.call(this,a,b,c),this.od=this.ea,this.M=1==a?this.M|8192:this.M|4096,a;} +function Oj(a,b,c){if(c){var d=a>>>c-1;a=d>>>1|b<<32-c;ng(this,a,-2147483648,d&1)}return a}function hk(){this.A-=-1===this.C?2:this.B.Ck;return 1}function ik(){var a=this.I&255;this.A-=(-1===this.C?this.B.Sh:this.B.Rh)+(a<this.Sc?(-1!=this.nd&&(this.nd!==this.ba.T&&(this.ba.Cb=this.nd&3,cg(this,this.nd)),this.nd=-1),this.od!==this.ea&&dg(this,this.od),-1!=this.Tc&&(this.Tc!==this.U.T&&me(this,this.Tc),this.Tc=-1),-1!==this.ta&&(this.ta!==this.Ca&&ne(this,this.Ac&~this.U.xa|this.ta-this.U.ua),this.ta=-1)):8!=this.Sc?(b=0,a=8):(b=0,a=-1,of(this),e=d=!1)):dg(this,this.od);var f=a,g=b,h=32,k=Ag(this,this.ea);204!=k||this.$c||(d=!1);this.P&131072&&(6== +f&&99==k||13==f&&205==k)&&(d=!1);!1===d&&(h|=1);983040<=this.ea&&1048575>=this.ea&&(d=!1);r(this,h|-2147483648)&&(d=!0);if(r(this,h)||d){var m=this.aa.Xa;f="Fault "+va(f)+(null!=g?" ("+wa(g)+")":"")+" on opcode "+va(k);d&&m&&(f+=" (blocked)");this.ca?(Tb(this,f,d||h,!0),d&&(d=m,rk(this.ca))):(this.Da(f),Gd(this))}if(d&&e)throw-1;if(e)throw this.Sc=a,nk.call(this,a,b,c),this.od=this.ea,this.M=1==a?this.M|8192:this.M|4096,a;} function sf(a,b,c){this.pd=a;a=0;b&&(a|=1);c&&(a|=2);3==this.Pa&&(a|=4);x.call(this,14,a)}function pk(a){var b=a.ob&7680;a.T&65528&&(6144==b||7168==b||7168>b&&a.qc>3&7].call(this,d,b.call(this));switch(c){case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.H=a;break;case 196:ne(this,a);break;case 197:this.N=a;break;case 198:this.K=a;break;case 199:this.J=a;break;default:Kg(this,a)}} function sk(a){var b=this.sa(),c=b>>6;switch(b>>3&7){case 0:var d=this.D;break;case 1:d=this.I;break;case 2:d=this.L;break;case 3:d=this.H;break;case 4:d=0;break;case 5:d=this.N;break;case 6:d=this.K;break;case 7:d=this.J}switch(b&7){case 0:var e=this.D;break;case 1:e=this.I;break;case 2:e=this.L;break;case 3:e=this.H;break;case 4:e=y(this);this.Ga=this.Sb;break;case 5:a?(e=this.N,this.Ga=this.Sb):e=K(this);break;case 6:e=this.K;break;case 7:e=this.J}return(d<>3&7){case 0:var a=this.D;this.D=this.Aa;ue(this,a);break;case 1:a=this.I; +Yk,this.Ha);this.A-=-1===this.F?1:this.B.vg},Jk,function(){this.mb.call(this,Yk,this.S);this.A-=-1===this.F?1:this.B.vg},function(){this.uc.call(this,Tj)},function(){this.Ba.call(this,Uj)},function(){this.kc.call(this,Xj)},function(){this.la.call(this,Yj)},Lk,Mk,Nk,Ok,function(){this.M|=1;this.Ba.call(this,cj)},function(){this.M|=1;this.Ga=this.Sb=this.Ig;this.la.call(this,Ti)},function(){this.la.call(this,bj);switch(this.fa>>3&7){case 0:var a=this.D;this.D=this.Aa;ue(this,a);break;case 1:a=this.I; this.I=this.Aa;cg(this,a);break;case 2:a=this.L;this.L=this.Aa;me(this,a);break;case 3:a=this.H;this.H=this.Aa;te(this,a);break;case 4:a=y(this);ne(this,this.Aa);80386<=this.da?this.Ka.load(a):ue(this,a);break;case 5:a=this.N;this.N=this.Aa;80386<=this.da?this.La.load(a):cg(this,a);break;case 6:a=this.K;this.K=this.Aa;me(this,a);break;case 7:a=this.J,this.J=this.Aa,te(this,a)}},function(){this.M|=1;this.ta=this.Ca;this.Aa=le(this);this.mb.call(this,Zk,lk);this.ta=-1},function(){this.A-=3},function(){var a= this.D;this.D=this.D&~this.R|this.I&this.R;this.I=this.I&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.L&this.R;this.L=this.L&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.H&this.R;this.H=this.H&~this.R|a&this.R;this.A-=3},function(){var a=this.D,b=y(this);this.D=this.D&~this.R|b&this.R;ne(this,b&~this.R|a&this.R);this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.N&this.R;this.N=this.N&~this.R|a&this.R;this.A-=3},function(){var a= -this.D;this.D=this.D&~this.R|this.K&this.R;this.K=this.K&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.J&this.R;this.J=this.J&~this.R|a&this.R;this.A-=3},function(){this.D=2==this.X?this.D&-65536|this.D<<24>>24&65535:this.D<<16>>16;this.A-=2},function(){this.L=2==this.X?this.L&-65536|(this.D&32768?65535:0):this.D&-2147483648?-1:0;this.A-=this.B.Gj},function(){mk.call(this,this.Ha(),Mg(this));this.A-=this.B.Jj},function(){this.A-=3},function(){var a=xe(this);a&131072&& +this.D;this.D=this.D&~this.R|this.K&this.R;this.K=this.K&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.J&this.R;this.J=this.J&~this.R|a&this.R;this.A-=3},function(){this.D=2==this.X?this.D&-65536|this.D<<24>>24&65535:this.D<<16>>16;this.A-=2},function(){this.L=2==this.X?this.L&-65536|(this.D&32768?65535:0):this.D&-2147483648?-1:0;this.A-=this.B.Hj},function(){mk.call(this,this.Ha(),Mg(this));this.A-=this.B.Kj},function(){this.A-=3},function(){var a=xe(this);a&131072&& 3>this.lc?x.call(this,13,0):(ve(this,a&-196609),this.A-=this.B.Ic)},function(){if(this.P&131072&&3>this.lc)x.call(this,13,0);else{var a=le(this);a=a&65535|this.P&-65536;ye(this,a);this.A-=this.B.nc}},function(){var a=this.D>>8&255;a&1?og(this):pg(this);a&4?(this.resultType&=-3,this.P|=4):(this.resultType&=-3,this.P&=-5);a&16?wg(this):ug(this);a&64?xg(this):vg(this);a&128?(this.resultType&=-17,this.P|=128):(this.resultType&=-17,this.P&=-129);this.A-=this.B.Yb},function(){this.D=this.D&-65281|(xe(this)& -213)<<8;this.A-=this.B.Yb},function(){var a=this.D&-256;var b=K(this);b=this.ya(this.Ga.Bb(b,1));this.D=a|b;this.A-=this.B.Fh},function(){this.D=this.D&~this.R|re(this,this.Ga,K(this));this.A-=this.B.Fh},function(){var a=K(this),b=this.D;this.ub(this.Ga.Ub(a,1),b);this.A-=this.B.Gh},function(){Lg(this,this.Ga,K(this),this.D);this.A-=this.B.Gh},function(){var a=1,b=0,c=this.xa,d=this.B.Hh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Jh,this.ha&256||(this.A-=this.B.Ih));if(a--){var e=this.ya(this.Ga.Bb(this.K& -c,1));this.ub(this.pa.Ub(this.J&c,1),e);e=this.P&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d;this.I=this.I&~c|this.I-b&c;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Hh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Jh,this.ha&256||(this.A-=this.B.Ih));if(a--){Lg(this,this.pa,this.J&c,re(this,this.Ga,this.K&c));var e=this.P&1024?-this.X:this.X;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d;this.I=this.I&~c|this.I-b&c;a&&(fg(this), -this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.sh;this.ha&192&&(a=this.I&c,b=1,d=this.B.uh,this.ha&256||(this.A-=this.B.th));if(a--){var e=Bg(this,this.Ga,this.K),f=Bg(this,this.pa,this.J);this.F=this.C;Gi.call(this,e,f);e=this.P&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.sh;this.ha&192&&(a=this.I&c,b=1,d=this.B.uh,this.ha&256|| -(this.A-=this.B.th));if(a--){var e=Dg(this,this.Ga,this.K&c),f=Dg(this,this.pa,this.J&c);this.F=this.C;Hi.call(this,e,f);e=this.P&1024?-this.X:this.X;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this),this.M|=256)}},function(){ng(this,this.D&this.sa(),128);this.A-=this.B.re},function(){ng(this,this.D&this.Ha(),this.Hb);this.A-=this.B.re},function(){var a=1,b=0,c=this.xa,d=this.B.Sh;this.ha&192&&(a=this.I&c,b= -1,d=this.B.Uh,this.ha&256||(this.A-=this.B.Th));if(a--){var e=this.D;this.ub(this.pa.Ub(this.J&c,1),e);this.I=this.I&~c|this.I-b&c;80546<=this.Qd&&80564>=this.Qd&&!(this.ha&2048)!=(103!=this.ya(this.ea))&&(c^=-65536);this.J=this.J&~c|this.J+(this.P&1024?-1:1)&c;this.A-=d;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Sh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Uh,this.ha&256||(this.A-=this.B.Th));a--&&(Lg(this,this.pa,this.J&c,this.D),this.J=this.J&~c|this.J+(this.P&1024?-this.X: -this.X)&c,this.I=this.I&~c|this.I-b&c,this.A-=d,a&&(fg(this),this.M|=256))},function(){var a=1,b=0,c=this.xa,d=this.B.zh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Bh,this.ha&256||(this.A-=this.B.Ah));if(a--){var e=this.ya(this.Ga.Bb(this.K&c,1));this.D=this.D&-256|e;this.K=this.K&~c|this.K+(this.P&1024?-1:1)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.zh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Bh,this.ha&256||(this.A-=this.B.Ah));if(a--){var e= -re(this,this.Ga,this.K&c);this.D=this.D&~this.R|e;this.K=this.K&~c|this.K+(this.P&1024?-this.X:this.X)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Mh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Oh,this.ha&256||(this.A-=this.B.Nh));if(a--){var e=this.D&255,f=Bg(this,this.pa,this.J);this.F=this.C;Gi.call(this,e,f);this.J=this.J&~c|this.J+(this.P&1024?-1:1)&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this), -this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Mh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Oh,this.ha&256||(this.A-=this.B.Nh));if(a--){var e=this.D&this.R,f=Dg(this,this.pa,this.J&c);this.F=this.C;Hi.call(this,e,f);this.J=this.J&~c|this.J+(this.P&1024?-this.X:this.X)&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this),this.M|=256)}},function(){this.D=this.D&-256|this.sa();this.A-=this.B.Yb},function(){this.I=this.I&-256|this.sa();this.A-=this.B.Yb},function(){this.L= +213)<<8;this.A-=this.B.Yb},function(){var a=this.D&-256;var b=K(this);b=this.ya(this.Ga.Bb(b,1));this.D=a|b;this.A-=this.B.Hh},function(){this.D=this.D&~this.R|re(this,this.Ga,K(this));this.A-=this.B.Hh},function(){var a=K(this),b=this.D;this.ub(this.Ga.Ub(a,1),b);this.A-=this.B.Ih},function(){Lg(this,this.Ga,K(this),this.D);this.A-=this.B.Ih},function(){var a=1,b=0,c=this.xa,d=this.B.Jh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Lh,this.ha&256||(this.A-=this.B.Kh));if(a--){var e=this.ya(this.Ga.Bb(this.K& +c,1));this.ub(this.pa.Ub(this.J&c,1),e);e=this.P&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d;this.I=this.I&~c|this.I-b&c;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Jh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Lh,this.ha&256||(this.A-=this.B.Kh));if(a--){Lg(this,this.pa,this.J&c,re(this,this.Ga,this.K&c));var e=this.P&1024?-this.X:this.X;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d;this.I=this.I&~c|this.I-b&c;a&&(fg(this), +this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.uh;this.ha&192&&(a=this.I&c,b=1,d=this.B.wh,this.ha&256||(this.A-=this.B.vh));if(a--){var e=Bg(this,this.Ga,this.K),f=Bg(this,this.pa,this.J);this.F=this.C;Gi.call(this,e,f);e=this.P&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.uh;this.ha&192&&(a=this.I&c,b=1,d=this.B.wh,this.ha&256|| +(this.A-=this.B.vh));if(a--){var e=Dg(this,this.Ga,this.K&c),f=Dg(this,this.pa,this.J&c);this.F=this.C;Hi.call(this,e,f);e=this.P&1024?-this.X:this.X;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this),this.M|=256)}},function(){ng(this,this.D&this.sa(),128);this.A-=this.B.re},function(){ng(this,this.D&this.Ha(),this.Hb);this.A-=this.B.re},function(){var a=1,b=0,c=this.xa,d=this.B.Uh;this.ha&192&&(a=this.I&c,b= +1,d=this.B.Wh,this.ha&256||(this.A-=this.B.Vh));if(a--){var e=this.D;this.ub(this.pa.Ub(this.J&c,1),e);this.I=this.I&~c|this.I-b&c;80546<=this.Qd&&80564>=this.Qd&&!(this.ha&2048)!=(103!=this.ya(this.ea))&&(c^=-65536);this.J=this.J&~c|this.J+(this.P&1024?-1:1)&c;this.A-=d;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Uh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Wh,this.ha&256||(this.A-=this.B.Vh));a--&&(Lg(this,this.pa,this.J&c,this.D),this.J=this.J&~c|this.J+(this.P&1024?-this.X: +this.X)&c,this.I=this.I&~c|this.I-b&c,this.A-=d,a&&(fg(this),this.M|=256))},function(){var a=1,b=0,c=this.xa,d=this.B.Bh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Dh,this.ha&256||(this.A-=this.B.Ch));if(a--){var e=this.ya(this.Ga.Bb(this.K&c,1));this.D=this.D&-256|e;this.K=this.K&~c|this.K+(this.P&1024?-1:1)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Bh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Dh,this.ha&256||(this.A-=this.B.Ch));if(a--){var e= +re(this,this.Ga,this.K&c);this.D=this.D&~this.R|e;this.K=this.K&~c|this.K+(this.P&1024?-this.X:this.X)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Oh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Qh,this.ha&256||(this.A-=this.B.Ph));if(a--){var e=this.D&255,f=Bg(this,this.pa,this.J);this.F=this.C;Gi.call(this,e,f);this.J=this.J&~c|this.J+(this.P&1024?-1:1)&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this), +this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Oh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Qh,this.ha&256||(this.A-=this.B.Ph));if(a--){var e=this.D&this.R,f=Dg(this,this.pa,this.J&c);this.F=this.C;Hi.call(this,e,f);this.J=this.J&~c|this.J+(this.P&1024?-this.X:this.X)&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this),this.M|=256)}},function(){this.D=this.D&-256|this.sa();this.A-=this.B.Yb},function(){this.I=this.I&-256|this.sa();this.A-=this.B.Yb},function(){this.L= this.L&-256|this.sa();this.A-=this.B.Yb},function(){this.H=this.H&-256|this.sa();this.A-=this.B.Yb},function(){this.D=this.D&-65281|this.sa()<<8;this.A-=this.B.Yb},function(){this.I=this.I&-65281|this.sa()<<8;this.A-=this.B.Yb},function(){this.L=this.L&-65281|this.sa()<<8;this.A-=this.B.Yb},function(){this.H=this.H&-65281|this.sa()<<8;this.A-=this.B.Yb},function(){this.D=this.D&~this.R|this.Ha();this.A-=this.B.Yb},function(){this.I=this.I&~this.R|this.Ha();this.A-=this.B.Yb},function(){this.L=this.L& ~this.R|this.Ha();this.A-=this.B.Yb},function(){this.H=this.H&~this.R|this.Ha();this.A-=this.B.Yb},function(){ne(this,y(this)&~this.R|this.Ha());this.A-=this.B.Yb},function(){this.N=this.N&~this.R|this.Ha();this.A-=this.B.Yb},function(){this.K=this.K&~this.R|this.Ha();this.A-=this.B.Yb},function(){this.J=this.J&~this.R|this.Ha();this.A-=this.B.Yb},Sk,Tk,Sk,Tk,function(){this.la.call(this,Ui)},function(){this.la.call(this,Si)},function(){this.M|=1;this.kd.call(this,$k,this.sa)},function(){this.M|= -1;this.mb.call(this,$k,this.Ha)},Uk,Vk,Uk,Vk,function(){if(this.P&131072&&3>this.lc)x.call(this,13,0);else{var a=this.B.$j;this.Sc=-1;nk.call(this,3,null,a)}},function(){var a=this.sa();if(this.P&131072&&3>this.lc)x.call(this,13,0);else{a:{var b=this.Sf[a];if(void 0!==b)for(var c=0;cthis.lc)x.call(this,13,0);else{var a= -this.B.ak;this.Sc=-1;nk.call(this,4,null,a)}else this.A-=this.B.bk},function(){if(this.P&131072&&3>this.lc)x.call(this,13,0);else{this.Tc=this.U.T;this.ta=this.Ca;this.A-=this.B.Yj;if(this.ra&1&&this.P&16384){var a=this.ja(this.ka.ua+0);oe(this.ba,a,!1)}else{a=this.Pa;var b=le(this),c=le(this),d=le(this);if(this.P&131072)d=d&131071|this.P&-131072;else if(d&131072){var e=le(this),f=le(this),g=le(this),h=le(this),k=le(this),m=le(this);pe(this,!0,!0);me(this,f);ne(this,e);ue(this,g);te(this,h);this.Ka.load(k); -this.La.load(m)}null!=ze(this,b,c,!1)&&(ye(this,d,a),this.Vf&&Yf(this,this.ea))}this.Tc=this.ta=-1}},function(){this.kd.call(this,Pk,hk)},function(){this.mb.call(this,2==this.X?Qk:Rk,hk)},function(){this.kd.call(this,Pk,ik)},function(){this.mb.call(this,2==this.X?Qk:Rk,ik)},function(){var a=this.sa();if(a){var b=this.D&255;this.D=this.D&-65536|b/a<<8|b%a;ng(this,this.D,128);this.A-=this.B.Dj}else qk.call(this)},function(){var a=this.D&255,b=(this.D>>8&255)*this.sa()|0,c=a+b|0;this.D=this.D&-65536| -c&255;gg(this,a,b,c,191);this.A-=this.B.Cj},function(){this.D=this.D&-256|(hg(this)?255:0);this.A-=2},function(){this.D=this.D&-256|Bg(this,this.Ga,this.H+(this.D&255));this.A-=this.B.Ck},function(){Wk.call(this,216)},function(){Wk.call(this,217)},function(){Wk.call(this,218)},function(){Wk.call(this,219)},function(){Wk.call(this,220)},function(){Wk.call(this,221)},function(){Wk.call(this,222)},function(){Wk.call(this,223)},function(){var a=this.S(),b=this.I-1&this.xa;this.I=this.I&~this.xa|b;b&& -!kg(this)?(C(this,z(this)+a),this.A-=this.B.ik):this.A-=this.B.Ch},function(){var a=this.S(),b=this.I-1&this.xa;this.I=this.I&~this.xa|b;b&&kg(this)?(C(this,z(this)+a),this.A-=this.B.Dh):this.A-=this.B.Eh},function(){var a=this.S(),b=this.I-1&this.xa;this.I=this.I&~this.xa|b;b?(C(this,z(this)+a),this.A-=this.B.hk):this.A-=this.B.Ch},function(){var a=this.S();this.I&this.xa?this.A-=this.B.Eh:(C(this,z(this)+a),this.A-=this.B.Dh)},function(){var a=this.sa();zg(this,a,1,!0)&&(this.D=this.D&-256|Qc(this.oa, -a,1,this.ea-2)&255,this.A-=this.B.xh)},function(){var a=this.sa();zg(this,a,this.X,!0)&&(this.D=this.D&~this.R|Qc(this.oa,a,this.X,this.ea-2)&this.R,this.A-=this.B.xh)},function(){var a=this.sa();zg(this,a,1,!1)&&(Vc(this.oa,a,1,this.D&255,this.ea-2),this.A-=this.B.Lh)},function(){var a=this.sa();zg(this,a,this.X,!1)&&(Vc(this.oa,a,this.X,this.D&this.R,this.ea-2),this.A-=this.B.Lh)},function(){var a=this.Ha(),b=z(this);a=b+a;ve(this,b);C(this,a);this.A-=this.B.Hj},function(){var a=this.Ha();C(this, -z(this)+a);this.A-=this.B.yh},function(){ze(this,this.Ha(),Mg(this));this.A-=this.B.dk},function(){var a=this.S();C(this,z(this)+a);this.A-=this.B.yh},function(){var a=this.L&65535;zg(this,a,1,!0)&&(this.D=this.D&-256|Qc(this.oa,a,1,this.ea-1)&255,this.A-=this.B.wh)},function(){var a=this.L&65535;zg(this,a,this.X,!0)&&(this.D=this.D&~this.R|Qc(this.oa,a,this.X,this.ea-1)&this.R,this.A-=this.B.wh)},function(){var a=this.L&65535;zg(this,a,1,!1)&&(Vc(this.oa,a,1,this.D&255,this.ea-1),this.A-=this.B.Kh)}, -function(){var a=this.L&65535;zg(this,a,2,!1)&&(Vc(this.oa,a,this.X,this.D&this.R,this.ea-1),this.A-=this.B.Kh)},Xk,Xk,function(){this.M|=132;this.A-=this.B.Zc},function(){this.M|=68;this.A-=this.B.Zc},function(){this.P&131072?x.call(this,13,0):(this.ab|=4,this.A-=2,this.ca&&r(this,-2147483648)?(fg(this),rk(this.ca)):this.P&512||(this.ca&&fg(this),Gd(this)))},function(){hg(this)?pg(this):og(this);this.A-=2},function(){this.vc=!1;this.kd.call(this,bl,kk);this.vc&&(this.D=this.D&~this.R|this.Ea&this.R)}, -function(){this.vc=!1;this.mb.call(this,cl,kk);this.vc&&(this.D=this.D&~this.R|this.Ea&this.R,this.L=this.L&~this.R|this.cb&this.R)},function(){pg(this);this.A-=2},function(){og(this);this.A-=2},function(){this.Pa>this.lc?x.call(this,13,0):(this.P&=-513,this.A-=this.B.Fj)},function(){this.Pa>this.lc?x.call(this,13,0):(this.P|=512,this.M|=4,this.A-=2)},function(){this.P&=-1025;this.A-=2},function(){this.P|=1024;this.A-=2},function(){this.kd.call(this,Ce,kk)},function(){this.mb.call(this,De,kk)}],Kk= -[qi,dj,oi,fj,si,Rj,Zj,Gi],Yk=[ri,ej,pi,gj,ti,Sj,ak,Hi],Zk=[function(a,b){this.A-=-1===this.F?this.B.nc:this.B.uk;return b},Ji,Ji,Ji,Ji,Ji,Ji,Ji],$k=[function(a,b){this.A-=-1===this.F?this.B.lk:this.B.jk;return b},Ki,Ki,Ki,Ki,Ki,Ki,Ki],Pk=[function(a,b){var c=a;if(b&=this.Ra){if(b&=7){var d=a<>8-b)&255}else d=a<<7;sg(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ra){if(b&=7){var d=a<<8-b;c=(a>>>b|d)&255}else d=a;sg(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ra){var d= +1;this.mb.call(this,$k,this.Ha)},Uk,Vk,Uk,Vk,function(){if(this.P&131072&&3>this.lc)x.call(this,13,0);else{var a=this.B.ak;this.Sc=-1;nk.call(this,3,null,a)}},function(){var a=this.sa();if(this.P&131072&&3>this.lc)x.call(this,13,0);else{a:{var b=this.Tf[a];if(void 0!==b)for(var c=0;cthis.lc)x.call(this,13,0);else{var a= +this.B.bk;this.Sc=-1;nk.call(this,4,null,a)}else this.A-=this.B.ck},function(){if(this.P&131072&&3>this.lc)x.call(this,13,0);else{this.Tc=this.U.T;this.ta=this.Ca;this.A-=this.B.Zj;if(this.ra&1&&this.P&16384){var a=this.ja(this.ka.ua+0);oe(this.ba,a,!1)}else{a=this.Pa;var b=le(this),c=le(this),d=le(this);if(this.P&131072)d=d&131071|this.P&-131072;else if(d&131072){var e=le(this),f=le(this),g=le(this),h=le(this),k=le(this),m=le(this);pe(this,!0,!0);me(this,f);ne(this,e);ue(this,g);te(this,h);this.Ka.load(k); +this.La.load(m)}null!=ze(this,b,c,!1)&&(ye(this,d,a),this.Wf&&Yf(this,this.ea))}this.Tc=this.ta=-1}},function(){this.kd.call(this,Pk,hk)},function(){this.mb.call(this,2==this.X?Qk:Rk,hk)},function(){this.kd.call(this,Pk,ik)},function(){this.mb.call(this,2==this.X?Qk:Rk,ik)},function(){var a=this.sa();if(a){var b=this.D&255;this.D=this.D&-65536|b/a<<8|b%a;ng(this,this.D,128);this.A-=this.B.Ej}else qk.call(this)},function(){var a=this.D&255,b=(this.D>>8&255)*this.sa()|0,c=a+b|0;this.D=this.D&-65536| +c&255;gg(this,a,b,c,191);this.A-=this.B.Dj},function(){this.D=this.D&-256|(hg(this)?255:0);this.A-=2},function(){this.D=this.D&-256|Bg(this,this.Ga,this.H+(this.D&255));this.A-=this.B.Dk},function(){Wk.call(this,216)},function(){Wk.call(this,217)},function(){Wk.call(this,218)},function(){Wk.call(this,219)},function(){Wk.call(this,220)},function(){Wk.call(this,221)},function(){Wk.call(this,222)},function(){Wk.call(this,223)},function(){var a=this.S(),b=this.I-1&this.xa;this.I=this.I&~this.xa|b;b&& +!kg(this)?(C(this,z(this)+a),this.A-=this.B.jk):this.A-=this.B.Eh},function(){var a=this.S(),b=this.I-1&this.xa;this.I=this.I&~this.xa|b;b&&kg(this)?(C(this,z(this)+a),this.A-=this.B.Fh):this.A-=this.B.Gh},function(){var a=this.S(),b=this.I-1&this.xa;this.I=this.I&~this.xa|b;b?(C(this,z(this)+a),this.A-=this.B.ik):this.A-=this.B.Eh},function(){var a=this.S();this.I&this.xa?this.A-=this.B.Gh:(C(this,z(this)+a),this.A-=this.B.Fh)},function(){var a=this.sa();zg(this,a,1,!0)&&(this.D=this.D&-256|Qc(this.oa, +a,1,this.ea-2)&255,this.A-=this.B.zh)},function(){var a=this.sa();zg(this,a,this.X,!0)&&(this.D=this.D&~this.R|Qc(this.oa,a,this.X,this.ea-2)&this.R,this.A-=this.B.zh)},function(){var a=this.sa();zg(this,a,1,!1)&&(Vc(this.oa,a,1,this.D&255,this.ea-2),this.A-=this.B.Nh)},function(){var a=this.sa();zg(this,a,this.X,!1)&&(Vc(this.oa,a,this.X,this.D&this.R,this.ea-2),this.A-=this.B.Nh)},function(){var a=this.Ha(),b=z(this);a=b+a;ve(this,b);C(this,a);this.A-=this.B.Ij},function(){var a=this.Ha();C(this, +z(this)+a);this.A-=this.B.Ah},function(){ze(this,this.Ha(),Mg(this));this.A-=this.B.ek},function(){var a=this.S();C(this,z(this)+a);this.A-=this.B.Ah},function(){var a=this.L&65535;zg(this,a,1,!0)&&(this.D=this.D&-256|Qc(this.oa,a,1,this.ea-1)&255,this.A-=this.B.yh)},function(){var a=this.L&65535;zg(this,a,this.X,!0)&&(this.D=this.D&~this.R|Qc(this.oa,a,this.X,this.ea-1)&this.R,this.A-=this.B.yh)},function(){var a=this.L&65535;zg(this,a,1,!1)&&(Vc(this.oa,a,1,this.D&255,this.ea-1),this.A-=this.B.Mh)}, +function(){var a=this.L&65535;zg(this,a,2,!1)&&(Vc(this.oa,a,this.X,this.D&this.R,this.ea-1),this.A-=this.B.Mh)},Xk,Xk,function(){this.M|=132;this.A-=this.B.Zc},function(){this.M|=68;this.A-=this.B.Zc},function(){this.P&131072?x.call(this,13,0):(this.ab|=4,this.A-=2,this.ca&&r(this,-2147483648)?(fg(this),rk(this.ca)):this.P&512||(this.ca&&fg(this),Gd(this)))},function(){hg(this)?pg(this):og(this);this.A-=2},function(){this.vc=!1;this.kd.call(this,bl,kk);this.vc&&(this.D=this.D&~this.R|this.Ea&this.R)}, +function(){this.vc=!1;this.mb.call(this,cl,kk);this.vc&&(this.D=this.D&~this.R|this.Ea&this.R,this.L=this.L&~this.R|this.cb&this.R)},function(){pg(this);this.A-=2},function(){og(this);this.A-=2},function(){this.Pa>this.lc?x.call(this,13,0):(this.P&=-513,this.A-=this.B.Gj)},function(){this.Pa>this.lc?x.call(this,13,0):(this.P|=512,this.M|=4,this.A-=2)},function(){this.P&=-1025;this.A-=2},function(){this.P|=1024;this.A-=2},function(){this.kd.call(this,Ce,kk)},function(){this.mb.call(this,De,kk)}],Kk= +[qi,dj,oi,fj,si,Rj,Zj,Gi],Yk=[ri,ej,pi,gj,ti,Sj,ak,Hi],Zk=[function(a,b){this.A-=-1===this.F?this.B.nc:this.B.vk;return b},Ji,Ji,Ji,Ji,Ji,Ji,Ji],$k=[function(a,b){this.A-=-1===this.F?this.B.mk:this.B.kk;return b},Ki,Ki,Ki,Ki,Ki,Ki,Ki],Pk=[function(a,b){var c=a;if(b&=this.Ra){if(b&=7){var d=a<>8-b)&255}else d=a<<7;sg(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ra){if(b&=7){var d=a<<8-b;c=(a>>>b|d)&255}else d=a;sg(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ra){var d= tg(this);(b%=9)?(c=(a<>9-b)&255,d=a<>b|d<<8-b|a<<9-b)&255,d=a<<8-b):d<<=7;sg(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ra){var d=0;8>>b-1,a=b>>>1&255,ng(this,a,128,b&1,a&128);return a},Ki,function(a,b){if(b&=this.Ra)9>24>>b-1,a=b>>1&255,ng(this, a,128,b&1);return a}],Qk=[function(a,b){var c=a;if(b&=this.Ra){if(b&=15){var d=a<>16-b)&65535}else d=a<<15;sg(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ra){if(b&=15){var d=a<<16-b;c=(a>>>b|d)&65535}else d=a;sg(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ra){var d=tg(this);(b%=17)?(c=(a<>17-b)&65535,d=a<>b|d<<16-b|a<<17-b)&65535,d=a<< 16-b):d<<=15;sg(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ra){var d=0;16>>b-1,a=b>>>1&65535,ng(this,a,32768,b&1,a&32768);return a},Ki,function(a,b){if(b&=this.Ra)17>16>>b-1,a=b>>1&65535,ng(this,a,32768,b&1);return a}],Rk=[function(a,b){var c=a;if(b&=this.Ra)c=a<>>32-b,sg(this,c,a<>>b|d;sg(this,c,d,-2147483648)}return c},function(a,b){var c=a;if(b&=this.Ra)c=tg(this),c=a<>>32-b>>>1,sg(this,c,a<>>b|c<<32-b|a<<32-b<<1,sg(this,c,a<<32-b,-2147483648);return c},function(a,b){var c=a;if(b&=this.Ra)a<<=b-1,c=a<<1,ng(this,c,-2147483648,a&-2147483648,(c^a)&-2147483648);return c},function(a,b){if(b&=this.Ra)b=a>>>b-1,a=b>>>1,ng(this,a,-2147483648,b&1,a&-2147483648);return a},Ki,function(a, -b){if(b&=this.Ra)b=a>>b-1,a=b>>1,ng(this,a,-2147483648,b&1);return a}],bl=[function(a,b){b=this.sa();ng(this,a&b,128);this.A-=-1===this.C?this.B.Wh:this.B.Vh;this.M|=2;return a},Ki,function(a){this.A-=-1===this.C?this.B.Bf:this.B.Af;return a^255},function(a){var b=-a|0;gg(this,0,a,b,191,!0);this.A-=-1===this.C?this.B.Bf:this.B.Af;return b&255},function(a){this.Ea=(this.D&255)*a&65535;this.Ea&65280?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.qk:this.B.pk;this.M|=2; -return a},function(a){var b=(this.D<<24>>24)*(a<<24>>24)|0;this.Ea=b&65535;127b?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.Vj:this.B.Uj;this.M|=2;return a},function(a,b){if(!a)return qk.call(this),a;var c=(b=this.D&65535)/a;if(255>24,d=(b=this.D<<16>>16)/c|0;if(d!=d<<24>>24||8086== -this.da&&-128==d)return qk.call(this),a;this.Ea=d&255|(b%c&255)<<8;this.vc=!0;this.A-=-1===this.C?this.B.Rj:this.B.Qj;this.M|=2;return a}],cl=[function(a,b){b=this.Ha();ng(this,a&b,this.Hb);this.A-=-1===this.C?this.B.Wh:this.B.Vh;this.M|=2;return a},Ki,function(a){this.A-=-1===this.C?this.B.Bf:this.B.Af;return a^this.R},function(a){var b=-a|0;gg(this,0,a,b,this.Hb|63,!0);this.A-=-1===this.C?this.B.Bf:this.B.Af;return b&this.R},function(a,b){2==this.X?(b=this.D&65535,b=b*a|0,this.Ea=b&65535,this.cb= -b>>16&65535):(Qi.call(this,a,this.D),80563==this.Qd&&68657152==this.D&&129==a&&(this.cb=0));this.cb?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.sk:this.B.rk;this.M|=2;return a},function(a,b){2==this.X?(b=this.D&65535,b=(b<<16>>16)*(a<<16>>16)|0,this.Ea=b&65535,this.cb=b>>16&65535,b=32767b):(Pi.call(this,a,this.D),b=this.cb!=this.Ea>>31);b?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.Xj:this.B.Wj;this.M|=2;return a},function(a, -b){if(2==this.X){if(!a)return qk.call(this),a;b=65536*(this.L&65535)+(this.D&65535);var c=b/a;if(65536<=c)return qk.call(this),a;this.Ea=c&65535;this.cb=b%a&65535}else{if(!dk.call(this,this.D,this.L,a))return qk.call(this),a;this.Ea|=0;this.cb|=0}this.vc=!0;this.A-=-1===this.C?this.B.Pj:this.B.Oj;this.M|=2;return a},function(a,b){if(2==this.X){if(!a)return qk.call(this),a;var c=a<<16>>16,d=(b=this.L<<16|this.D&65535)/c|0;if(d!=d<<16>>16||8086==this.da&&-32768==d)return qk.call(this),a;this.Ea=d&65535; -this.cb=b%c&65535}else{b=this.D;c=this.L;d=a;var e=0,f=0;0>d&&(d=-d|0,e=1-e);0>c&&(b=-b|0,c=~c+(b?0:1)|0,f=1,e=1-e);!dk.call(this,b,c,d)||this.Ea>2147483647+e||this.cb>2147483647+f?b=!1:(e&&(this.Ea=-this.Ea),f&&(this.cb=-this.cb),b=!0);if(!b)return qk.call(this),a;this.Ea|=0;this.cb|=0}this.vc=!0;this.A-=-1===this.C?this.B.Tj:this.B.Sj;this.M|=2;return a}],Ce=[function(a){var b=a+1|0;gg(this,a,1,b,190);this.A-=-1===this.C?this.B.zf:this.B.yf;return b&255},function(a){var b=a-1|0;gg(this,a,1,b,190, -!0);this.A-=-1===this.C?this.B.zf:this.B.yf;return b&255},Ki,Ki,Ki,Ki,Ki,Ki],De=[function(a){var b=a+1|0;gg(this,a,1,b,this.Hb|62);this.A-=-1===this.C?this.B.zf:this.B.yf;return b&this.R},function(a){var b=a-1|0;gg(this,a,1,b,this.Hb|62,!0);this.A-=-1===this.C?this.B.zf:this.B.yf;return b&this.R},function(a){ve(this,z(this));C(this,a);this.A-=-1===this.C?this.B.Lj:this.B.Kj;this.M|=2;return a},function(a){if(-1===this.C)return Ki.call(this,a);this.ta=this.Ca;mk.call(this,a,this.ja(this.C+this.X)); -this.A-=this.B.Ij;this.M|=2;this.ta=-1;return a},function(a){C(this,a);this.A-=-1===this.C?this.B.fk:this.B.ek;this.M|=2;return a},function(a){if(-1===this.C)return Ki.call(this,a);ze(this,a,this.ja(this.C+this.X));this.A-=this.B.ck;this.M|=2;return a},function(a){var b=a;this.M&512&&(a=a-2&65535,80286>this.da&&(b=a));ve(this,b);this.A-=-1===this.C?this.B.Ic:this.B.wk;this.M|=2;return a},Ki];function mf(){this.la.call(this,Wj);this.A-=-1===this.C?6:13} -function nf(){this.Ba.call(this,Vj);this.A-=-1===this.C?12:19}var af=Array(256);af[0]=function(){16>(this.ya(this.ea)&56)&&(this.M|=1);this.mb.call(this,this.ij,kk)};af[1]=function(){this.ya(this.ea)&16||(this.M|=1);this.mb.call(this,dl,kk)};af[2]=function(){!(this.ra&1)||this.P&131072?x.call(this,6):this.la.call(this,Ri)};af[3]=function(){!(this.ra&1)||this.P&131072?x.call(this,6):this.la.call(this,Xi)}; +b){if(b&=this.Ra)b=a>>b-1,a=b>>1,ng(this,a,-2147483648,b&1);return a}],bl=[function(a,b){b=this.sa();ng(this,a&b,128);this.A-=-1===this.C?this.B.Yh:this.B.Xh;this.M|=2;return a},Ki,function(a){this.A-=-1===this.C?this.B.Cf:this.B.Bf;return a^255},function(a){var b=-a|0;gg(this,0,a,b,191,!0);this.A-=-1===this.C?this.B.Cf:this.B.Bf;return b&255},function(a){this.Ea=(this.D&255)*a&65535;this.Ea&65280?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.rk:this.B.qk;this.M|=2; +return a},function(a){var b=(this.D<<24>>24)*(a<<24>>24)|0;this.Ea=b&65535;127b?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.Wj:this.B.Vj;this.M|=2;return a},function(a,b){if(!a)return qk.call(this),a;var c=(b=this.D&65535)/a;if(255>24,d=(b=this.D<<16>>16)/c|0;if(d!=d<<24>>24||8086== +this.da&&-128==d)return qk.call(this),a;this.Ea=d&255|(b%c&255)<<8;this.vc=!0;this.A-=-1===this.C?this.B.Sj:this.B.Rj;this.M|=2;return a}],cl=[function(a,b){b=this.Ha();ng(this,a&b,this.Hb);this.A-=-1===this.C?this.B.Yh:this.B.Xh;this.M|=2;return a},Ki,function(a){this.A-=-1===this.C?this.B.Cf:this.B.Bf;return a^this.R},function(a){var b=-a|0;gg(this,0,a,b,this.Hb|63,!0);this.A-=-1===this.C?this.B.Cf:this.B.Bf;return b&this.R},function(a,b){2==this.X?(b=this.D&65535,b=b*a|0,this.Ea=b&65535,this.cb= +b>>16&65535):(Qi.call(this,a,this.D),80563==this.Qd&&68657152==this.D&&129==a&&(this.cb=0));this.cb?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.tk:this.B.sk;this.M|=2;return a},function(a,b){2==this.X?(b=this.D&65535,b=(b<<16>>16)*(a<<16>>16)|0,this.Ea=b&65535,this.cb=b>>16&65535,b=32767b):(Pi.call(this,a,this.D),b=this.cb!=this.Ea>>31);b?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.Yj:this.B.Xj;this.M|=2;return a},function(a, +b){if(2==this.X){if(!a)return qk.call(this),a;b=65536*(this.L&65535)+(this.D&65535);var c=b/a;if(65536<=c)return qk.call(this),a;this.Ea=c&65535;this.cb=b%a&65535}else{if(!dk.call(this,this.D,this.L,a))return qk.call(this),a;this.Ea|=0;this.cb|=0}this.vc=!0;this.A-=-1===this.C?this.B.Qj:this.B.Pj;this.M|=2;return a},function(a,b){if(2==this.X){if(!a)return qk.call(this),a;var c=a<<16>>16,d=(b=this.L<<16|this.D&65535)/c|0;if(d!=d<<16>>16||8086==this.da&&-32768==d)return qk.call(this),a;this.Ea=d&65535; +this.cb=b%c&65535}else{b=this.D;c=this.L;d=a;var e=0,f=0;0>d&&(d=-d|0,e=1-e);0>c&&(b=-b|0,c=~c+(b?0:1)|0,f=1,e=1-e);!dk.call(this,b,c,d)||this.Ea>2147483647+e||this.cb>2147483647+f?b=!1:(e&&(this.Ea=-this.Ea),f&&(this.cb=-this.cb),b=!0);if(!b)return qk.call(this),a;this.Ea|=0;this.cb|=0}this.vc=!0;this.A-=-1===this.C?this.B.Uj:this.B.Tj;this.M|=2;return a}],Ce=[function(a){var b=a+1|0;gg(this,a,1,b,190);this.A-=-1===this.C?this.B.Af:this.B.zf;return b&255},function(a){var b=a-1|0;gg(this,a,1,b,190, +!0);this.A-=-1===this.C?this.B.Af:this.B.zf;return b&255},Ki,Ki,Ki,Ki,Ki,Ki],De=[function(a){var b=a+1|0;gg(this,a,1,b,this.Hb|62);this.A-=-1===this.C?this.B.Af:this.B.zf;return b&this.R},function(a){var b=a-1|0;gg(this,a,1,b,this.Hb|62,!0);this.A-=-1===this.C?this.B.Af:this.B.zf;return b&this.R},function(a){ve(this,z(this));C(this,a);this.A-=-1===this.C?this.B.Mj:this.B.Lj;this.M|=2;return a},function(a){if(-1===this.C)return Ki.call(this,a);this.ta=this.Ca;mk.call(this,a,this.ja(this.C+this.X)); +this.A-=this.B.Jj;this.M|=2;this.ta=-1;return a},function(a){C(this,a);this.A-=-1===this.C?this.B.gk:this.B.fk;this.M|=2;return a},function(a){if(-1===this.C)return Ki.call(this,a);ze(this,a,this.ja(this.C+this.X));this.A-=this.B.dk;this.M|=2;return a},function(a){var b=a;this.M&512&&(a=a-2&65535,80286>this.da&&(b=a));ve(this,b);this.A-=-1===this.C?this.B.Ic:this.B.xk;this.M|=2;return a},Ki];function jf(){this.la.call(this,Wj);this.A-=-1===this.C?6:13} +function nf(){this.Ba.call(this,Vj);this.A-=-1===this.C?12:19}var af=Array(256);af[0]=function(){16>(this.ya(this.ea)&56)&&(this.M|=1);this.mb.call(this,this.oj,kk)};af[1]=function(){this.ya(this.ea)&16||(this.M|=1);this.mb.call(this,dl,kk)};af[2]=function(){!(this.ra&1)||this.P&131072?x.call(this,6):this.la.call(this,Ri)};af[3]=function(){!(this.ra&1)||this.P&131072?x.call(this,6):this.la.call(this,Xi)}; af[5]=function(){this.Pa?x.call(this,13,0,0,!0):(yg(this,this.ja(2054)),this.J=this.ja(2086),this.K=this.ja(2088),this.N=this.ja(2090),this.H=this.ja(2094),this.L=this.ja(2096),this.I=this.ja(2098),this.D=this.ja(2100),je(this.pa,2102,this.ja(2084)),je(this.ba,2108,this.ja(2082)),je(this.U,2114,this.ja(2080)),je(this.Fa,2120,this.ja(2078)),ye(this,this.ja(2072)),C(this,this.ja(2074)),ne(this,this.ja(2092)),this.Kb=this.ja(2126)|this.ya(2128)<<16,this.Jc=this.Kb+this.ja(2130),this.Qb=this.ja(2138)| this.ya(2140)<<16,this.$c=this.Qb+this.ja(2142),je(this.Gb,2132,this.ja(2076)),je(this.ka,2144,this.ja(2070)),this.A-=195)};af[6]=function(){this.Pa?x.call(this,13,0):(this.ra&=-9,this.A-=2)};af[11]=Ie;af[166]=Ie;af[255]=Ie;var B=[];B[5]=Ie; B[7]=function(){if(this.Pa)x.call(this,13,0,0,!0);else{var a=this.pa.Bb(this.J&this.xa,204);if(-1!==a){fk.call(this,this.ia(a));var b=this.ia(a+168),c=(b&24576)>>13;ye(this,this.ia(a+4),c);this.Kb=this.ia(a+112);this.Jc=this.Kb+this.ia(a+116);this.Qb=this.ia(a+100);this.$c=this.Qb+this.ia(a+104);he(this.Gb,this.ia(a+56),this.ia(a+120),this.ia(a+124),this.ia(a+128));he(this.ka,this.ia(a+52),this.ia(a+84),this.ia(a+88),this.ia(a+92));this.J=this.ia(a+12);this.K=this.ia(a+16);this.N=this.ia(a+20);this.H= this.ia(a+28);this.L=this.ia(a+32);this.I=this.ia(a+36);this.D=this.ia(a+40);he(this.La,this.ia(a+60),this.ia(a+132),this.ia(a+136),this.ia(a+140));he(this.Ka,this.ia(a+64),this.ia(a+144),this.ia(a+148),this.ia(a+152));he(this.Fa,this.ia(a+68),this.ia(a+156),this.ia(a+160),this.ia(a+164));he(this.U,this.ia(a+72),b,this.ia(a+172),this.ia(a+176));he(this.ba,this.ia(a+76),this.ia(a+180),this.ia(a+184),this.ia(a+188));he(this.pa,this.ia(a+80),this.ia(a+192),this.ia(a+196),this.ia(a+200));C(this,this.ia(a+ -8));ne(this,this.ia(a+24))}this.A-=122<<(a&3?1:0)}};B[16]=Lk;B[17]=Mk;B[18]=Nk;B[19]=Ok;B[32]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa();switch((a&56)>>3){case 0:var b=this.ra;break;case 2:b=this.pd;break;case 3:b=this.wc;break;default:bf.call(this);return}Af(this,a&7,b);this.A-=6}};B[33]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;4==b||5==b?bf.call(this):(Af(this,a&7,this.Rb[b]),this.A-=22)}}; -B[34]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=zf(this,a&7);switch((a&56)>>3){case 0:fk.call(this,b);this.A-=10;break;case 2:this.pd=b;this.A-=4;break;case 3:this.wc=b;uc(this);this.A-=5;break;default:bf.call(this)}}};B[35]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;4==b||5==b?bf.call(this):(a=zf(this,a&7),a!=this.Rb[b]&&(Zf(this,!1),this.Rb[b]=a,Zf(this,!0)),this.A-=4>b?22:14)}}; -B[36]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;6>b?bf.call(this):(Af(this,a&7,this.Xf[b]),this.A-=12)}};B[38]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;6>b?bf.call(this):(this.Xf[b]=zf(this,a&7),this.A-=12)}};B[128]=function(){var a=this.Ha();mg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[129]=function(){var a=this.Ha();mg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)}; +8));ne(this,this.ia(a+24))}this.A-=122<<(a&3?1:0)}};B[16]=Lk;B[17]=Mk;B[18]=Nk;B[19]=Ok;B[32]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa();switch((a&56)>>3){case 0:var b=this.ra;break;case 2:b=this.pd;break;case 3:b=this.wc;break;default:bf.call(this);return}vf(this,a&7,b);this.A-=6}};B[33]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;4==b||5==b?bf.call(this):(vf(this,a&7,this.Rb[b]),this.A-=22)}}; +B[34]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=uf(this,a&7);switch((a&56)>>3){case 0:fk.call(this,b);this.A-=10;break;case 2:this.pd=b;this.A-=4;break;case 3:this.wc=b;uc(this);this.A-=5;break;default:bf.call(this)}}};B[35]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;4==b||5==b?bf.call(this):(a=uf(this,a&7),a!=this.Rb[b]&&(Zf(this,!1),this.Rb[b]=a,Zf(this,!0)),this.A-=4>b?22:14)}}; +B[36]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;6>b?bf.call(this):(vf(this,a&7,this.Yf[b]),this.A-=12)}};B[38]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;6>b?bf.call(this):(this.Yf[b]=uf(this,a&7),this.A-=12)}};B[128]=function(){var a=this.Ha();mg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[129]=function(){var a=this.Ha();mg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)}; B[130]=function(){var a=this.Ha();hg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[131]=function(){var a=this.Ha();hg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)};B[132]=function(){var a=this.Ha();kg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[133]=function(){var a=this.Ha();kg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)};B[134]=function(){var a=this.Ha();hg(this)||kg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua}; B[135]=function(){var a=this.Ha();hg(this)||kg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)};B[136]=function(){var a=this.Ha();lg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[137]=function(){var a=this.Ha();lg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)};B[138]=function(){var a=this.Ha();ig(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[139]=function(){var a=this.Ha();ig(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)}; B[140]=function(){var a=this.Ha();!lg(this)!=!mg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[141]=function(){var a=this.Ha();!lg(this)==!mg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[142]=function(){var a=this.Ha();kg(this)||!lg(this)!=!mg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[143]=function(){var a=this.Ha();kg(this)||!lg(this)!=!mg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)};B[144]=function(){gk.call(this,hj)}; @@ -430,116 +430,116 @@ a;vg(this);return a},function(a){this.M|=2;this.A-=14+(-1===this.C?0:2);if(-1!== 131072?x.call(this,6):(yg(this,a),this.A-=-1===this.C?3:6,this.M|=2);return a},Ki],el=[Ki,Ki,Ki,Ki,yi,Bi,Ai,zi]; function fl(a){pb.call(this,"ChipSet",a,32768);var b=a.model;b&&!gl[b]&&kb("Unrecognized ChipSet model: "+b);this.da=gl[b]||hl;this.B=[];b=il(a[jl]);this.B[0]=[b,b];null==b&&(this.L=[360,360],(b=a.floppies)&&b.length&&(this.L=b),kl(this,ll,this.L.length),kl(this,ml,a.monitor||(this.da=Yg&&(this.Ba=this.ka=2);this.M=a.scaleTimers||!1;this.Ra=a.dateRTC;this.Ka=this.La=!1;this.Ia=0;if(a=a.sound)this.Ia="number"!=typeof a||0>a|| 1e||1e||1=Yg){this.D=Sl;this.J=0;this.I=Tl;this.pa=0;this.K=Ul|Vl;512<=Wl(this)&&(this.K|=Xl);+Yl(this,ml,void 0)==Zl&&(this.K|=$l);(this.da|0)==zl&&(this.K=this.K|am|bm);this.ra= -cm|dm;this.U=Array(8);this.N=0;a&&(this.A=Array(El));em(this,this.Ra);for(a=fm;a<=gm;a++)this.A[a]=0;for(a=hm;ac?c=c?c:12:c=(c-=12)?c+128:140,d=!0);a.A[Wd]&$m||(d&&128>8} -l.save=function(){var a=new ag(this);a.set(0,[this.B]);for(var b=[],c=0;c=Yg&&(a.set(5,[this.D,this.J,this.I,this.pa,this.K,this.ra]),a.set(6,[this.U[7],this.U,this.N,this.A,this.la,this.aa]));return a.data()}; +cm|dm;this.U=Array(8);this.N=0;a&&(this.A=Array(El));em(this,this.Ra);for(a=fm;a<=gm;a++)this.A[a]=0;for(a=hm;ac?c=c?c:12:c=(c-=12)?c+128:140,d=!0);a.A[Wd]&$m||(d&&128>8} +l.save=function(){var a=new ag(this);a.set(0,[this.B]);for(var b=[],c=0;c=Yg&&(a.set(5,[this.D,this.J,this.I,this.pa,this.K,this.ra]),a.set(6,[this.U[7],this.U,this.N,this.A,this.la,this.Z]));return a.data()}; l.restore=function(a){var b;var c=a[0];Array.isArray(c[0])?this.B=c[0]:(this.B[0][0]=c[0],this.B[1][0]=c[1]&15,this.B[0][1]=c[2],this.B[1][1]=c[3]&15);Kl(this);c=a[1];for(b=0;b=f;f++){var g="pcjs-bitCell";f||(g+=" pcjs-bitCellLeft");d+='
'+f+"
\n"}e.innerHTML=d;ln(a,b,c,!0)}function mn(a,b,c){if(b=(a=nn[a.da|0])&&a[b])for(var d in b)if(a=b[d],a.zc&1<g.rb[0]&&(g.rb[0]=255,g.rb[1]--,0>g.rb[1]&&(g.rb[1]=255)));return h}function Bn(a,b,c,d,e,f){var g=a.F[b];r(a,768)&&t(a,d,e,f,"DMA"+b+".CHANNEL"+c+".COUNT["+g.Ab+"]",null,!0);a=g.oc[c];a.rb[g.Ab]=a.pc[g.Ab]=e;g.Ab^=1}function Cn(a,b,c,d){var e=a.F[b],f=e.Pb|Dn;e.Pb&=~En;r(a,768)&&t(a,c,null,d,"DMA"+b+".STATUS",f,!0);return f} -function Fn(a,b,c,d,e){var f=a.F[b];r(a,768)&&t(a,c,d,e,"DMA"+b+".REQ",null,!0);a=d&3;f.Pb=f.Pb&~(16<>2].oc[b&3],c,d,e)}function Jn(a,b,c){b=a.F[b>>2].oc[b&3];b.hg&&b.$g&&b.wg?(c&&(b.done=c),b.oe||Tn(a,b,!0)):c&&c(!0)} -function Tn(a,b,c){c&&(b.count=b.rb[1]<<8|b.rb[0],b.type=b.mode&Un,b.mj=b.ig=!1);for(var d=!1;0<=b.count&&(c=b.bg<<16|b.wb[1]<<8|b.wb[0],b.type==Vn?(d=!0,function(c){b.$g.call(b.hg,b.wg,-1,function(e,g){0>e&&(b.mj||(b.mj=!0),e=255);b.oe||a.oa.ub(c,e);(d=g)&&setTimeout(function(){Wn(b)||Tn(a,b)},0)})}(c)):b.type==Xn?(c=a.oa.ya(c),0>b.$g.call(b.hg,b.wg,c)&&(b.ig=!0)):b.type!=Yn&&(b.ig=!0)),!d&&!Wn(b););} -function Wn(a){if(!a.ig&&0<=--a.count&&(a.mode&Zn?(a.wb[0]--,0>a.wb[0]&&(a.wb[0]=255,a.wb[1]--,0>a.wb[1]&&(a.wb[1]=255))):(a.wb[0]++,255>2].oc[b&3],c,d,e)}function Jn(a,b,c){b=a.F[b>>2].oc[b&3];b.ig&&b.ah&&b.xg?(c&&(b.done=c),b.oe||Tn(a,b,!0)):c&&c(!0)} +function Tn(a,b,c){c&&(b.count=b.rb[1]<<8|b.rb[0],b.type=b.mode&Un,b.nj=b.jg=!1);for(var d=!1;0<=b.count&&(c=b.cg<<16|b.wb[1]<<8|b.wb[0],b.type==Vn?(d=!0,function(c){b.ah.call(b.ig,b.xg,-1,function(e,g){0>e&&(b.nj||(b.nj=!0),e=255);b.oe||a.oa.ub(c,e);(d=g)&&setTimeout(function(){Wn(b)||Tn(a,b)},0)})}(c)):b.type==Xn?(c=a.oa.ya(c),0>b.ah.call(b.ig,b.xg,c)&&(b.jg=!0)):b.type!=Yn&&(b.jg=!0)),!d&&!Wn(b););} +function Wn(a){if(!a.jg&&0<=--a.count&&(a.mode&Zn?(a.wb[0]--,0>a.wb[0]&&(a.wb[0]=255,a.wb[1]--,0>a.wb[1]&&(a.wb[1]=255))):(a.wb[0]++,255>3];b=1<<(b&7);d.cc&b||(d.cc|=b,d.Te=c||0,oo(a))}function Zg(a,b){var c=a.ic[b>>3];b=1<<(b&7);c.cc&b&&(c.cc&=~b,oo(a))}function oo(a,b){var c=-1;if(1>=1),Md(a.G,e))),b==Bo&&c==Fo&&dn(a))}function Go(a,b,c,d){t(a,c,null,d,"PIT"+b+".CTRL",null,2048);return b?a.wa:a.ta} -function Ho(a,b,c,d,e){t(a,c,d,e,"PIT"+b+".CTRL",null,2048);e=0;c=d&Io;b?(e=3,a.wa=d):a.ta=d;if(c==Jo){if(!(d&Ko))for(c=0;2>=c;c++)if(d&Lo<=c;c++)d&Lo<>=Qo;f=d&Ro;var g=d&So;d&=To;if(d==Uo)Po(a,e+c);else{e+=c;var h=a.qa[e];h.Lf=d;h.mode=g;h.Vg=f;h.pc=[0,0];h.rb=[0,0];h.je=[0,0];h.fd=!1;h.Je=!1;h.me=!1;h.Ne=!1;xo(a,e);b==Bo&&c==Co&&Zg(a,Do);b==Bo&&c==Fo&&255== -a.ic[0].sd&&a.H==(Vo|Wo|Xo|Yo)&&(b=a.qa[0],b.Oc[0]=b.pc[0],b.Oc[1]=b.pc[1],b.hd=Jd(a.G,a.M))}}}function Eo(a,b){a=a.qa[b];(b=a.pc[1]<<8|a.pc[0])||(b=1==a.Yc?256:65536);return b}function Ud(a,b){a=a.qa[b];(b=a.Oc[1]<<8|a.Oc[0])||(b=1==a.Yc?256:65536);return b}function Po(a,b){Dl(a,b);var c=a.qa[b];c.je[0]=c.rb[0];c.je[1]=c.rb[1];c.Je=!0;xo(a,b)}function xo(a,b){a=a.qa[b];a.vd=a.Lf==Zo?1:0;a.Yc=a.Lf==$o?2:1} +function mh(a,b,c){var d=a.ic[b>>3];b=1<<(b&7);d.cc&b||(d.cc|=b,d.Ue=c||0,oo(a))}function Zg(a,b){var c=a.ic[b>>3];b=1<<(b&7);c.cc&b&&(c.cc&=~b,oo(a))}function oo(a,b){var c=-1;if(1>=1),Md(a.G,e))),b==Bo&&c==Fo&&dn(a))}function Go(a,b,c,d){t(a,c,null,d,"PIT"+b+".CTRL",null,2048);return b?a.wa:a.ta} +function Ho(a,b,c,d,e){t(a,c,d,e,"PIT"+b+".CTRL",null,2048);e=0;c=d&Io;b?(e=3,a.wa=d):a.ta=d;if(c==Jo){if(!(d&Ko))for(c=0;2>=c;c++)if(d&Lo<=c;c++)d&Lo<>=Qo;f=d&Ro;var g=d&So;d&=To;if(d==Uo)Po(a,e+c);else{e+=c;var h=a.qa[e];h.Mf=d;h.mode=g;h.Wg=f;h.pc=[0,0];h.rb=[0,0];h.je=[0,0];h.fd=!1;h.Ke=!1;h.me=!1;h.Oe=!1;xo(a,e);b==Bo&&c==Co&&Zg(a,Do);b==Bo&&c==Fo&&255== +a.ic[0].sd&&a.H==(Vo|Wo|Xo|Yo)&&(b=a.qa[0],b.Oc[0]=b.pc[0],b.Oc[1]=b.pc[1],b.hd=Jd(a.G,a.M))}}}function Eo(a,b){a=a.qa[b];(b=a.pc[1]<<8|a.pc[0])||(b=1==a.Yc?256:65536);return b}function Ud(a,b){a=a.qa[b];(b=a.Oc[1]<<8|a.Oc[0])||(b=1==a.Yc?256:65536);return b}function Po(a,b){Dl(a,b);var c=a.qa[b];c.je[0]=c.rb[0];c.je[1]=c.rb[1];c.Ke=!0;xo(a,b)}function xo(a,b){a=a.qa[b];a.vd=a.Mf==Zo?1:0;a.Yc=a.Mf==$o?2:1} function Dl(a,b,c){var d=a.qa[b];if(d.me&&(b!=Fo||a.H&Vo)){var e=Jd(a.G,a.M),f=(e-d.hd)/a.Ea|0;0>f&&(d.hd=e,f=0);var g=Eo(a,b),h=Ud(a,b)-f;d.mode==zo?(0>=h&&(h=0),h||(d.fd=!0,d.me=!1,b||mh(a,Do))):d.mode==ap?(d.fd=1!=h,0>=h&&(h=g+h,0>=h&&(h=g),d.Oc[0]=h&255,d.Oc[1]=h>>8&255,d.hd=e,!b&&d.fd&&mh(a,Do))):d.mode==Vd&&(h-=f,0>=h&&(d.fd=!d.fd,h=g+h,0>=h&&(h=g),d.Oc[0]=h&255,d.Oc[1]=h>>8&255,d.hd=e,!b&&d.fd&&mh(a,Do)));d.rb[0]=h&255;d.rb[1]=h>>8&255;c&&(a.hd=0)}return d} -function Td(a,b){for(var c=0;c=Yg){b=a.G.Y.Yd;c=Jd(a.G,a.M);null==a.Ca&&(a.la=Jd(a.G,a.M),a.Pa=1024,a.Ca=Math.floor(a.G.Y.Yd/a.Pa),bn(a));c>=a.aa&&(a.A[Ym]|=bp,a.A[Wd]&Xd&&(a.A[Ym]|=cp,mh(a,dp)),a.aa=c+a.Ca);a.A[qm]==a.A[rm]&&a.A[sm]==a.A[tm]&&a.A[um]==a.A[vm]&&(a.A[Ym]|=ep,a.A[Wd]&fp&&(a.A[Ym]|=cp,mh(a,dp)));var d=c-a.la,e=Math.floor(d/b);if(e&&!(a.A[Wd]&gp)){for(;e--;)if(60<=++a.A[qm]&&(a.A[qm]=0,60<=++a.A[sm]&&(a.A[sm]=0,24<=++a.A[um]))){a.A[um]=0;a.A[wm]=a.A[wm]% -7+1;var f=a.A[zm];var g=Ka[a.A[ym]-1];28==g&&0===f%4&&(f%100||0===f%400)&&g++;f=g;++a.A[xm]>f&&(a.A[xm]=1,12<++a.A[ym]&&(a.A[ym]=1,a.A[zm]=(a.A[zm]+1)%100))}a.A[Bm]|=an;a.A[Ym]|=hp;a.A[Wd]&ip&&(a.A[Ym]|=cp,mh(a,dp))}a.la=c-d%b}}l.zm=function(a,b){var c=this.Aa;this.ha&jp&&(this.H&kp?c=this.B[0][1]:this.C&&(c=lp(this.C)));t(this,a,null,b,"PPI_A",c);return c};l.mo=function(a,b,c){t(this,a,b,c,"PPI_A");this.Aa=b};l.Am=function(a,b){var c=this.H;t(this,a,null,b,"PPI_B",c);return c}; -l.no=function(a,b,c){t(this,a,b,c,"PPI_B");mp(this,b)};function mp(a,b){var c=!!(b&np),d=!!(a.H&np);a.H=b;a.C&&op(a.C,!(b&kp),!!(b&Yo));c!=d&&dn(a,c)}l.Bm=function(a,b){var c=0;c=(this.da|0)==Il?this.H&Wo?c|this.B[1][1]&pp:c|this.B[1][1]>>4&1:this.H&qp?c|this.B[0][1]>>4:c|this.B[0][1]&15;this.H&Vo&&Dl(this,Fo).fd&&(c=this.H&np?c|rp:c|sp);t(this,a,null,b,"PPI_C",c,32896);return c};l.oo=function(a,b,c){t(this,a,b,c,"PPI_C");this.Fa=b};l.Cm=function(a,b){var c=this.ha;t(this,a,null,b,"PPI_CTRL",c);return c}; -l.po=function(a,b,c){t(this,a,b,c,"PPI_CTRL");this.ha=b};l.Hl=function(a,b){var c=this.C?lp(this.C):0;t(this,a,null,b,"8041_KBD",c);this.ea&=~tp;return c};l.sn=function(a,b,c){t(this,a,b,c,"8041_KBD")};l.Gl=function(a,b){var c=this.H;t(this,a,null,b,"8041_CTRL",c);return c};l.rn=function(a,b,c){t(this,a,b,c,"8041_CTRL");mp(this,b)};l.Il=function(a,b){var c=this.ea;t(this,a,null,b,"8041_STATUS",c);return c}; -l.Jl=function(a,b){var c=this.pa;t(this,a,null,b,"8042_OUTBUFF",c,16384);this.D&=~(tp|up);this.C&&vp(this.C);return c}; -l.un=function(a,b,c){t(this,a,b,c,"8042_INBUF.DATA",null,16384);if(this.D&wp)switch(this.J){case xp:yp(this,b);break;case zp:Ap(this,b);break;default:if(yp(this,this.I&~Tl),this.C){a=this.C;c=b;var d=-1;r(a)&&Tb(a,"sendCmd("+va(c)+")");switch(a.H||c){case Bp:d=Cp;Dp(a);break;case Ep:a.H&&(c=0);Fp(a,Cp);a.H=c;break;case Gp:a.H&&(c=0);Fp(a,Cp);a.H=c;break;default:Tb(a,"sendCmd(): unrecognized command")}Hp(this,d)}}this.J=b;this.D&=~wp}; -l.Kl=function(a,b){var c=this.H&~(Ip|Jp)|(Jd(this.G)&64?Jp:0);t(this,a,null,b,"8042_RWREG",c,16384);return c};l.vn=function(a,b,c){t(this,a,b,c,"8042_RWREG",null,16384);mp(this,b)};l.Ll=function(a,b){t(this,a,null,b,"8042_STATUS",this.D,16384);a=this.D&255;this.D&up&&(this.D|=tp,this.D&=~up);return a}; -l.tn=function(a,b,c){t(this,a,b,c,"8042_INBUFF.CMD",null,16384);this.J=b;this.D|=wp;a=0;this.J>=Kp&&(a=this.J^15,this.J=Kp);switch(this.J){case Lp:Hp(this,this.I);break;case Mp:yp(this,this.I|Tl);break;case Np:yp(this,this.I&~Tl);this.C&&vp(this.C);break;case Op:this.C&&(a=this.C,a.A=[],r(a)&&Tb(a,"scan codes flushed"));yp(this,this.I|Tl);Hp(this,Pp);Ap(this,cm|dm);break;case Qp:Hp(this,Rp);break;case Sp:Hp(this,this.K);break;case Tp:Hp(this,this.ra);break;case Up:Hp(this,this.I&Tl?0:Vp);break;case Kp:a& -1&&of(this.G)}};function yp(a,b){a.I=b;a.D=a.D&~Wp|b&Xp;a.C&&op(a.C,!!(b&Yp),!(b&Tl))}function Hp(a,b,c){0<=b&&(a.pa=b,c?a.D|=tp:(a.D&=~tp,a.D|=up))}function Ap(a,b){a.ra=b;qc(a.oa,!!(b&dm));b&cm||of(a.G)}function Zp(a,b){a.da>4)+(c&15),e=!0);if(d==um||d==vm)e&&23=c?c=12==c?0:c:(c-=116,c=24==c?12:c))}}else c=b;this.A[d]=c;d==Wd&&a&Xd&&b&Xd&&bn(this)};l.Hk=function(a,b,c){t(this,a,b,c,"NMI");this.fa=b};l.Yn=function(a,b,c){t(this,a,b,c,"FPU.CLEAR")};l.Zn=function(a,b,c){t(this,a,b,c,"FPU.RESET");this.Kc&&Tg(this.Kc)}; -l.Qm=function(a){if(r(this,16)&&al(this.ca,26,a)){var b=this.G.D>>8;Xf(this.G,a,function(a,d){return function(c){d=Jd(a.G)-d;var e=a.G.L&255,g=a.G.L>>8,h=a.G.L&255,k=a.G.L>>8;if(2==b||3==b)var m=" CH(hour)="+wa(g)+" CL(min)="+va(e)+" DH(sec)="+va(k);else if(4==b||5==b)m=" CX(year)="+wa(a.G.I)+" DH(month)="+va(k)+" DL(day)="+va(h);e=a.ca;g=d;e.message("INT "+va(26)+": C="+(hg(e.G)?1:0)+(m||"")+" (cycles="+g+(c?",level="+(c+1):"")+")")}}(this,Jd(this.G)))}return!0}; -function dn(a,b){if(a.P){void 0!==b?a.Ka=b:b=!!(a.Ka&&a.G&&a.G.Z.Xa);var c=Math.round(pl/Eo(a,Fo));if(20>c||2E4=Yg){b=a.G.Y.Yd;c=Jd(a.G,a.M);null==a.Ca&&(a.la=Jd(a.G,a.M),a.Pa=1024,a.Ca=Math.floor(a.G.Y.Yd/a.Pa),bn(a));c>=a.Z&&(a.A[Ym]|=bp,a.A[Wd]&Xd&&(a.A[Ym]|=cp,mh(a,dp)),a.Z=c+a.Ca);a.A[qm]==a.A[rm]&&a.A[sm]==a.A[tm]&&a.A[um]==a.A[vm]&&(a.A[Ym]|=ep,a.A[Wd]&fp&&(a.A[Ym]|=cp,mh(a,dp)));var d=c-a.la,e=Math.floor(d/b);if(e&&!(a.A[Wd]&gp)){for(;e--;)if(60<=++a.A[qm]&&(a.A[qm]=0,60<=++a.A[sm]&&(a.A[sm]=0,24<=++a.A[um]))){a.A[um]=0;a.A[wm]=a.A[wm]% +7+1;var f=a.A[zm];var g=Ka[a.A[ym]-1];28==g&&0===f%4&&(f%100||0===f%400)&&g++;f=g;++a.A[xm]>f&&(a.A[xm]=1,12<++a.A[ym]&&(a.A[ym]=1,a.A[zm]=(a.A[zm]+1)%100))}a.A[Wm]|=an;a.A[Ym]|=hp;a.A[Wd]&ip&&(a.A[Ym]|=cp,mh(a,dp))}a.la=c-d%b}}l.Am=function(a,b){var c=this.Aa;this.ha&jp&&(this.H&kp?c=this.B[0][1]:this.C&&(c=lp(this.C)));t(this,a,null,b,"PPI_A",c);return c};l.no=function(a,b,c){t(this,a,b,c,"PPI_A");this.Aa=b};l.Bm=function(a,b){var c=this.H;t(this,a,null,b,"PPI_B",c);return c}; +l.oo=function(a,b,c){t(this,a,b,c,"PPI_B");mp(this,b)};function mp(a,b){var c=!!(b&np),d=!!(a.H&np);a.H=b;a.C&&op(a.C,!(b&kp),!!(b&Yo));c!=d&&dn(a,c)}l.Cm=function(a,b){var c=0;c=(this.da|0)==Il?this.H&Wo?c|this.B[1][1]&pp:c|this.B[1][1]>>4&1:this.H&qp?c|this.B[0][1]>>4:c|this.B[0][1]&15;this.H&Vo&&Dl(this,Fo).fd&&(c=this.H&np?c|rp:c|sp);t(this,a,null,b,"PPI_C",c,32896);return c};l.po=function(a,b,c){t(this,a,b,c,"PPI_C");this.Fa=b};l.Dm=function(a,b){var c=this.ha;t(this,a,null,b,"PPI_CTRL",c);return c}; +l.qo=function(a,b,c){t(this,a,b,c,"PPI_CTRL");this.ha=b};l.Il=function(a,b){var c=this.C?lp(this.C):0;t(this,a,null,b,"8041_KBD",c);this.ea&=~tp;return c};l.tn=function(a,b,c){t(this,a,b,c,"8041_KBD")};l.Hl=function(a,b){var c=this.H;t(this,a,null,b,"8041_CTRL",c);return c};l.sn=function(a,b,c){t(this,a,b,c,"8041_CTRL");mp(this,b)};l.Jl=function(a,b){var c=this.ea;t(this,a,null,b,"8041_STATUS",c);return c}; +l.Kl=function(a,b){var c=this.pa;t(this,a,null,b,"8042_OUTBUFF",c,16384);this.D&=~(tp|up);this.C&&vp(this.C);return c}; +l.vn=function(a,b,c){t(this,a,b,c,"8042_INBUF.DATA",null,16384);if(this.D&wp)switch(this.J){case xp:yp(this,b);break;case zp:Ap(this,b);break;default:if(yp(this,this.I&~Tl),this.C){a=this.C;c=b;var d=-1;r(a)&&Tb(a,"sendCmd("+va(c)+")");switch(a.H||c){case Bp:d=Cp;Dp(a);break;case Ep:a.H&&(c=0);Fp(a,Cp);a.H=c;break;case Gp:a.H&&(c=0);Fp(a,Cp);a.H=c;break;default:Tb(a,"sendCmd(): unrecognized command")}Hp(this,d)}}this.J=b;this.D&=~wp}; +l.Ll=function(a,b){var c=this.H&~(Ip|Jp)|(Jd(this.G)&64?Jp:0);t(this,a,null,b,"8042_RWREG",c,16384);return c};l.wn=function(a,b,c){t(this,a,b,c,"8042_RWREG",null,16384);mp(this,b)};l.Ml=function(a,b){t(this,a,null,b,"8042_STATUS",this.D,16384);a=this.D&255;this.D&up&&(this.D|=tp,this.D&=~up);return a}; +l.un=function(a,b,c){t(this,a,b,c,"8042_INBUFF.CMD",null,16384);this.J=b;this.D|=wp;a=0;this.J>=Kp&&(a=this.J^15,this.J=Kp);switch(this.J){case Lp:Hp(this,this.I);break;case Mp:yp(this,this.I|Tl);break;case Np:yp(this,this.I&~Tl);this.C&&vp(this.C);break;case Op:this.C&&(a=this.C,a.A=[],r(a)&&Tb(a,"scan codes flushed"));yp(this,this.I|Tl);Hp(this,Pp);Ap(this,cm|dm);break;case Qp:Hp(this,Rp);break;case Sp:Hp(this,this.K);break;case Tp:Hp(this,this.ra);break;case Up:Hp(this,this.I&Tl?0:Vp);break;case Kp:a& +1&&of(this.G)}};function yp(a,b){a.I=b;a.D=a.D&~Wp|b&Xp;a.C&&op(a.C,!!(b&Yp),!(b&Tl))}function Hp(a,b,c){0<=b&&(a.pa=b,c?a.D|=tp:(a.D&=~tp,a.D|=up))}function Ap(a,b){a.ra=b;qc(a.oa,!!(b&dm));b&cm||of(a.G)}function Zp(a,b){a.da>4)+(c&15),e=!0);if(d==um||d==vm)e&&23=c?c=12==c?0:c:(c-=116,c=24==c?12:c))}}else c=b;this.A[d]=c;d==Wd&&a&Xd&&b&Xd&&bn(this)};l.Ik=function(a,b,c){t(this,a,b,c,"NMI");this.fa=b};l.Zn=function(a,b,c){t(this,a,b,c,"FPU.CLEAR")};l.$n=function(a,b,c){t(this,a,b,c,"FPU.RESET");this.Kc&&Tg(this.Kc)}; +l.Rm=function(a){if(r(this,16)&&al(this.ca,26,a)){var b=this.G.D>>8;Xf(this.G,a,function(a,d){return function(c){d=Jd(a.G)-d;var e=a.G.L&255,g=a.G.L>>8,h=a.G.L&255,k=a.G.L>>8;if(2==b||3==b)var m=" CH(hour)="+wa(g)+" CL(min)="+va(e)+" DH(sec)="+va(k);else if(4==b||5==b)m=" CX(year)="+wa(a.G.I)+" DH(month)="+va(k)+" DL(day)="+va(h);e=a.ca;g=d;e.message("INT "+va(26)+": C="+(hg(e.G)?1:0)+(m||"")+" (cycles="+g+(c?",level="+(c+1):"")+")")}}(this,Jd(this.G)))}return!0}; +function dn(a,b){if(a.P){void 0!==b?a.Ka=b:b=!!(a.Ka&&a.G&&a.G.aa.Xa);var c=Math.round(pl/Eo(a,Fo));if(20>c||2E4>>4,0,this.H,this.C,this.Id),delete this.Id);return!0};hq.prototype.Zb=function(){return!0}; function iq(a,b,c,d){if(d)a.Da("Unable to load system ROM (error "+d+": "+b+")",0>d);else{rb(a.de,b,c);if("["==c.charAt(0)||"{"==c.charAt(0))try{var e=eval("("+c+")"),f=e.bytes,g=e.longs||e.data;if(f)a.A=f;else if(g)for(a.A=Array(4*g.length),d=c=0;c>8&255,a.A[d++]=g[c]>>16&255,a.A[d++]=g[c]>>24&255;else a.A=e;a.Id=e.symbols;if(!a.A.length){kb("Empty ROM: "+b);return}if(1==a.A.length){kb(a.A[0]);return}}catch(h){a.Da("ROM data error: "+h.message);return}else for(b= c.replace(/\n/gm," ").replace(/ +$/,"").split(" "),a.A=Array(b.length),e=0;e>>d.A].af(e&d.D,a.A[c]&255,e)}b=!0}else b=!1;if(b){b=[];"number"==typeof a.F?b.push(a.F):null!=a.F&&a.F.length&&(b=a.F);for(c=0;c>>d.A].bf(e&d.D,a.A[c]&255,e)}b=!0}else b=!1;if(b){b=[];"number"==typeof a.F?b.push(a.F):null!=a.F&&a.F.length&&(b=a.F);for(c=0;cthis.B?fm:23,c=a.A[b]|a.A[b+1]<<8;c+=this.A>>10;a.A[b]=c&255;a.A[b+1]=c>>8;pm(a)}}else kb("No RAM allocated")}; l.save=function(){var a=new ag(this);this.controller&&a.set(0,this.controller.save());return a.data()};l.restore=function(a){return this.controller?this.controller.restore(a[0]):!0};function pq(a){this.D=a;this.C=rq;this.G=sq;this.B=tq;this.A=null}l=pq.prototype;l.save=function(){return[this.C,this.B]};l.restore=function(a){this.ub(0,a[0]&255);this.ub(2,a[1]&255);return!0};l.ya=function(a){var b=255;2>a?b=a&1?this.G>>8:this.G&255:4>a&&(b=a&1?this.B>>8:this.B&255);return b}; -l.ub=function(a,b){if(a)2==a&&(this.B=this.B&-256|b);else if(b!=(this.C&255)){a=this.D.oa;if(b&uq)this.A&&(yc(a,vq,wq,this.A),this.A=null);else{this.A||(this.A=zc(a,vq,wq));var c=zc(a,xq,wq);yc(a,vq,wq,c,b&yq?1:Gc)}this.C=this.C&-256|b}};l.qj=function(){return zq};l.ah=function(){return Aq};var qq=-2134900736,xq=16646144,vq=917504,wq=131072,uq=1,yq=2,rq=65535,sq=2575,tq=2,zq=[null,0],Aq=[function(a){return this.controller.ya(a)},null,null,function(a,b){this.controller.ub(a,b)},null,null]; -cb(function(){for(var a=zb(document,"pcx86","ram"),b=0;b=n.Hd&&d<=n.z&&(d-=n.Hd-n.ee),d=Mq[e]==d),d){(a=a.ma["key-"+e])&&void 0!==c&&(a.style.color=c?"#ffffff":"#000000",a.style.backgroundColor=c?"#000000":"#ffffff");break}}}l.tc=function(a,b,c,d){this.na=a;this.oa=b;this.G=c;this.ca=d;this.V=ac(a,"ChipSet");this.I=Ad(a,"autoType")||this.I;Wf(c,33,this.Rm.bind(this))}; -l.Rm=function(){if(10==(this.G.D>>8&255))if(this.P=!0,this.L)this.L(),this.L=null,this.P=!1;else{var a=this.I;!this.F&&a&&(this.F=a,this.fh(this.F))}return!0};function Cq(a,b){var c=0;a.da=null;"string"==typeof b&&(a.da=b.toUpperCase(),c=Pq.indexOf(a.da),0>c&&(c=0));if(b=Pq[c])a.ha=parseInt(b.substr(2),10)}function Dp(a){Tb(a,"keyboard reset",65792);a.A=[];Fp(a,Qq)}function op(a,b,c){a.N!==c&&(a.N=a.U=c)&&(a.J=!0);a.K!==b&&(a.K=b)&&!a.U&&aq(a,!0);a.K&&a.U&&(Dp(a),a.U=!1)} +e.na&&e.na.cd();Gq(e,Iq,!0)},!0;case "scroll-lock":return this.ma[f]=c,c.onclick=function(a){a.preventDefault();e.na&&e.na.cd();Gq(e,Jq,!0)},!0;default:var g=b.toUpperCase().replace(/-/g,"_");if(void 0!==Kq[g]&&"button"==a)return this.ma[f]=c,c.onclick=function(a,b,c){return function(b){b.preventDefault();a.na&&a.na.cd();a.C="";Lq(a,c,!0);Gq(a,c,!0)}}(this,g,Kq[g]),!0;if(void 0!==Mq[b])return this.ba++,this.ma[f]=c,a=function(a,b,c){return function(b){b.preventDefault();a.na&&a.na.cd();a.C="";Gq(a, +c)}}(this,b,Mq[b]),b=function(a,b,c){return function(){Nq(a,c)}}(this,b,Mq[b]),"ontouchstart"in window?(c.ontouchstart=a,c.ontouchend=b):(c.onmousedown=a,c.onmouseup=c.onmouseout=b),!0;if(d)return this.ma[f]=c,c.onclick=function(a){a.preventDefault();e.na&&e.na.cd();return e.gh(d)},!0}return!1}; +function Oq(a,b,c){if(a.ba){for(var d in pa)if(b==pa[d]){b=+d;(d=na[d])&&(b=d);break}for(var e in Mq)if((d=Mq[e]==b)||(d=b,d>=n.Hd&&d<=n.z&&(d-=n.Hd-n.ee),d=Mq[e]==d),d){(a=a.ma["key-"+e])&&void 0!==c&&(a.style.color=c?"#ffffff":"#000000",a.style.backgroundColor=c?"#000000":"#ffffff");break}}}l.tc=function(a,b,c,d){this.na=a;this.oa=b;this.G=c;this.ca=d;var e=this;this.qa=Cd(this.G,this.id+".inject",function(){Pq(e)});this.V=ac(a,"ChipSet");this.I=Bd(a,"autoType")||this.I;Wf(c,33,this.Sm.bind(this))}; +l.Sm=function(){if(10==(this.G.D>>8&255))if(this.P=!0,this.L)this.L(),this.L=null,this.P=!1;else{var a=this.I;!this.F&&a&&(this.F=a,this.gh(this.F))}return!0};function Cq(a,b){var c=0;a.da=null;"string"==typeof b&&(a.da=b.toUpperCase(),c=Qq.indexOf(a.da),0>c&&(c=0));if(b=Qq[c])a.ka=parseInt(b.substr(2),10)}function Dp(a){Tb(a,"keyboard reset",65792);a.A=[];Fp(a,Rq)}function op(a,b,c){a.N!==c&&(a.N=a.U=c)&&(a.J=!0);a.K!==b&&(a.K=b)&&!a.U&&aq(a,!0);a.K&&a.U&&(Dp(a),a.U=!1)} function Fp(a,b){a.V&&(a.A.unshift(b),a.J=!0,Zp(a.V,b))}function vp(a){var b=0;a.A.length&&a.J&&(b=a.A[0],a.V&&Zp(a.V,b));r(a)&&Tb(a,b?"scan code "+va(b)+" available":"no scan codes available")}function lp(a){var b=0;a.A.length&&(b=a.A[0]);r(a)&&Tb(a,"scan code "+va(b)+" delivered");return b}function aq(a,b){0>=1);if(b&Vq){if(!1===d)return!0;d=null}null==d?d=!((c?a.D:a.jc)&b):d||b&Wq&&(b=Wq);if(c){a.D&=~b;d&&(a.D|=b);c=b;var f,g;for(g in Xq)d="led-"+g,e=Xq[g],c&&c!=e||!(f=a.ma[d])||(f.style.backgroundColor=a.D&e?"#00ff00":"#000000")}else a.jc&=~b,d&&(a.jc|=b);return!0}}return!1} -function Gq(a,b,c){if((N[b]||N[b+=1E3])&&a.G&&a.G.Z.Xa){Tq[b]&&a.B.length&&0e||(e==a.B.length&&(d={},d.ve=b,d.jc=a.jc,Oq(a,b,!0),e++),0b.zd){if(!b.mf){Nq(a,b.ve);return}b.mf=!1;var c=a.ka}else c=1==b.zd++?500:100;b.ji=setTimeout(function(a){return function(){Yq(a,b)}}(a),c)}} -function $q(a,b,c){var d=b;if(b>=n.ee&&b<=n.Yf)!(a.jc&(ar|br|cr))==c&&(d=b+(n.Hd-n.ee));else if(b>=n.Hd&&b<=n.z)!!(a.jc&(ar|br|cr))==c&&(d=b-(n.Hd-n.ee));else if(!!(a.jc&(ar|br))==c){if(a=pa[b])d=a}else if(a=na[b])d=a;return d}l.xg=function(a){a||(this.jc&=~Wq)}; -function Dq(a,b,c){var d=!0,e=!1,f=!1,g=b.keyCode;if(!Eq(a.na))return!1;a.C="";Db(a.de);var h=$q(a,g,!0);a.Zg&&h==n["`"]&&(g=h=27);if(N[g+1E3])if(h+=1E3,2==b.location&&(h+=2E3),Lq(a,h,!1,c)){if(20==g||144==g||145==g)a.fa||(c=e=!0);if(!(c||91!=g&&93!=g))for(var k=0;ke||(e==a.B.length&&(d={},d.ve=b,d.jc=a.jc,Oq(a,b,!0),e++),0b.zd){if(!b.nf){Nq(a,b.ve);return}b.nf=!1;var c=a.la}else c=1==b.zd++?500:100;b.li=setTimeout(function(a){return function(){Yq(a,b)}}(a),c)}} +function $q(a,b,c){var d=b;if(b>=n.ee&&b<=n.Zf)!(a.jc&(ar|br|cr))==c&&(d=b+(n.Hd-n.ee));else if(b>=n.Hd&&b<=n.z)!!(a.jc&(ar|br|cr))==c&&(d=b-(n.Hd-n.ee));else if(!!(a.jc&(ar|br))==c){if(a=pa[b])d=a}else if(a=na[b])d=a;return d}l.yg=function(a){a||(this.jc&=~Wq)}; +function Dq(a,b,c){var d=!0,e=!1,f=!1,g=b.keyCode;if(!Eq(a.na))return!1;a.C="";Db(a.de);var h=$q(a,g,!0);a.$g&&h==n["`"]&&(g=h=27);if(N[g+1E3])if(h+=1E3,2==b.location&&(h+=2E3),Lq(a,h,!1,c)){if(20==g||144==g||145==g)a.ha||(c=e=!0);if(!(c||91!=g&&93!=g))for(var k=0;k=n.ee&&b<=n.Yf||b>=n.Hd&&b<=n.z;e>>>=8;){var g=0,h=e&255;f==mr||f==nr?d.push(f|(c?0:lr)):(h==O?a.D&(ar|br)||a.D&cr&&b||(g=h):h==or?a.D&(dr|pr)||(g=h):h==qr?a.D&(er|rr)||(g=h):d.push(f|(c?0:lr)),g&&(c?d.unshift(g):d.push(g|lr)))}for(c=0;c=n.ee&&b<=n.Zf||b>=n.Hd&&b<=n.z;e>>>=8;){var g=0,h=e&255;f==mr||f==nr?d.push(f|(c?0:lr)):(h==O?a.D&(ar|br)||a.D&cr&&b||(g=h):h==or?a.D&(dr|pr)||(g=h):h==qr?a.D&(er|rr)||(g=h):d.push(f|(c?0:lr)),g&&(c?d.unshift(g):d.push(g|lr)))}for(c=0;c"]]=52|O<<8;N[n["/"]]=53; +N[1009]=15;N[n.q]=16;N[n.Q]=16|O<<8;N[n.Yo]=17;N[n.Ji]=17|O<<8;N[n.e]=18;N[n.E]=18|O<<8;N[n.r]=19;N[n.Ei]=19|O<<8;N[n.t]=20;N[n.Gi]=20|O<<8;N[n.y]=21;N[n.Li]=21|O<<8;N[n.Wo]=22;N[n.Hi]=22|O<<8;N[n.Cl]=23;N[n.wi]=23|O<<8;N[n.on]=24;N[n.Ci]=24|O<<8;N[n.p]=25;N[n.Di]=25|O<<8;N[n["["]]=26;N[n["{"]]=26|O<<8;N[n["]"]]=27;N[n["}"]]=27|O<<8;N[13]=28;N[1017]=or;N[n.Hd]=30;N[n.ee]=30|O<<8;N[n.So]=31;N[n.Fi]=31|O<<8;N[n.d]=32;N[n.si]=32|O<<8;N[n.zl]=33;N[n.ti]=33|O<<8;N[n.Al]=34;N[n.ui]=34|O<<8;N[n.Bl]=35; +N[n.vi]=35|O<<8;N[n.Wm]=36;N[n.xi]=36|O<<8;N[n.k]=37;N[n.yi]=37|O<<8;N[n.Xm]=38;N[n.zi]=38|O<<8;N[n[";"]]=39;N[n[":"]]=39|O<<8;N[n["'"]]=40;N[n['"']]=40|O<<8;N[n["`"]]=41;N[n["~"]]=41|O<<8;N[1016]=O;N[n["\\"]]=43;N[n["|"]]=43|O<<8;N[n.z]=44;N[n.Zf]=44|O<<8;N[n.x]=45;N[n.Ki]=45|O<<8;N[n.ql]=46;N[n.ri]=46|O<<8;N[n.Xo]=47;N[n.Ii]=47|O<<8;N[n.ol]=48;N[n.pi]=48|O<<8;N[n.n]=49;N[n.Bi]=49|O<<8;N[n.cn]=50;N[n.Ai]=50|O<<8;N[n[","]]=51;N[n["<"]]=51|O<<8;N[n["."]]=52;N[n[">"]]=52|O<<8;N[n["/"]]=53; N[n["?"]]=53|O<<8;N[3016]=54;N[1044]=55;N[1018]=qr;N[1032]=57;N[Hq]=58;N[1112]=59;N[1113]=60;N[1114]=61;N[1115]=62;N[1116]=63;N[1117]=64;N[1118]=65;N[1119]=66;N[1120]=67;N[1121]=68;N[Iq]=69;N[Jq]=70;N[1036]=71;N[1038]=72;N[1033]=73;N[1109]=74;N[1037]=75;N[1101]=76;N[1039]=77;N[1107]=78;N[1035]=79;N[1040]=80;N[1034]=81;N[1045]=82;N[1046]=kr;N[4027]=84;N[1122]=87;N[1123]=88;N[1091]=91;N[1093]=93;N[1224]=91;N[ur]=46|or<<8;N[fr]=70|or<<8;N[4046]=kr|or<<8|qr<<16;N[4045]=82|or<<8|qr<<16; -N[4013]=28|or<<8|qr<<16;var Bp=255,Ep=243,Gp=237,Qq=170,Cp=250,tr=255,sr=20;cb(function(){for(var a=zb(document,"pcx86","keyboard"),b=0;bc.length)c=[!1,0,null,null,0,Array(b>2,32768));this.rc=c[0];this.Uc=c[1];this.Xe=c[2];this.ga=c[3];this.gc=c[4]&255;this.Bg=c[4]>>8&255;this.$a=c[5];this.kh=xr;this.ag=zr;this.$d=this.$a[Ar]|this.$a[Br]<<8;this.$f=63;if(b>=lq){this.$f=255; -this.kh=yr;this.ag=Cr;b=c[6];void 0===b&&(b=[!1,0,Array(Dr),0,f==Zl?0:Er,0,0,Array(Fr),0,0,0,Array(Gr),0,[this.fb,this.Tb,this.ud],Array(this.ud>>2),Hr|Ir|Jr|Kr|Lr,0,-1,0,-1,0,-1,0,0,0,0,Mr,Nr,0,0,Or,Array(Pr)]);this.Ie=b[0];this.Bd=b[1];this.Dc=b[2];this.Pg=Qr;this.Eg=b[3];this.Ze=b[4];this.Kf=b[5];this.Ed=b[6];this.be=b[7];this.Rg=Rr;this.Qk=b[8];this.Rk=b[9];this.Dd=b[10];this.Cd=b[11];this.Qg=Sr;this.xb=b[12];d=b[13];"number"==typeof d&&(d=[this.fb,this.Tb,d]);this.fb=d[0];this.Tb=d[1];d=this.ud>> -2;if((this.dd=b[14])&&this.dd.length=lq){var c=[];c[0]=a.Ie;c[1]=a.Bd;c[2]=a.Dc;c[3]=a.Eg;c[4]=a.Ze;c[5]=a.Kf;c[6]=a.Ed;c[7]=a.be;c[8]=a.Qk;c[9]=a.Rk;c[10]=a.Dd;c[11]=a.Cd;c[12]=a.xb;c[13]=[a.fb,a.Tb,a.ud];var d;if(d=a.dd){var e=0,f=[];if(void 0!==d[0])for(var g=0;2>g;g++)for(var h=g;h>1;f[e++]=k;h=m}f.lengthc.length)c=[!1,0,null,null,0,Array(b>2,32768));this.rc=c[0];this.Uc=c[1];this.Ye=c[2];this.ga=c[3];this.gc=c[4]&255;this.Cg=c[4]>>8&255;this.$a=c[5];this.mh=xr;this.bg=zr;this.$d=this.$a[Ar]|this.$a[Br]<<8;this.ag=63;if(b>=lq){this.ag=255; +this.mh=yr;this.bg=Cr;b=c[6];void 0===b&&(b=[!1,0,Array(Dr),0,f==Zl?0:Er,0,0,Array(Fr),0,0,0,Array(Gr),0,[this.fb,this.Tb,this.ud],Array(this.ud>>2),Hr|Ir|Jr|Kr|Lr,0,-1,0,-1,0,-1,0,0,0,0,Mr,Nr,0,0,Or,Array(Pr)]);this.Je=b[0];this.Bd=b[1];this.Dc=b[2];this.Qg=Qr;this.Fg=b[3];this.$e=b[4];this.Lf=b[5];this.Ed=b[6];this.be=b[7];this.Sg=Rr;this.Rk=b[8];this.Sk=b[9];this.Dd=b[10];this.Cd=b[11];this.Rg=Sr;this.xb=b[12];d=b[13];"number"==typeof d&&(d=[this.fb,this.Tb,d]);this.fb=d[0];this.Tb=d[1];d=this.ud>> +2;if((this.dd=b[14])&&this.dd.length=lq){var c=[];c[0]=a.Je;c[1]=a.Bd;c[2]=a.Dc;c[3]=a.Fg;c[4]=a.$e;c[5]=a.Lf;c[6]=a.Ed;c[7]=a.be;c[8]=a.Rk;c[9]=a.Sk;c[10]=a.Dd;c[11]=a.Cd;c[12]=a.xb;c[13]=[a.fb,a.Tb,a.ud];var d;if(d=a.dd){var e=0,f=[];if(void 0!==d[0])for(var g=0;2>g;g++)for(var h=g;h>1;f[e++]=k;h=m}f.length=lq){var d=0,e=0,f=0;switch(b){case as:d=bs;a.Ma==nq&&(e=cs);break;case ds:a.Ma==lq&&(d=es);break;case fs:d=gs;a.Ma==nq&&(e=hs);break;case is:d=js;a.Ma==nq&&(e=ks);break;case ls:d=ms;a.Ma==nq&&(f=ns);break;case os:d=ps,a.Ma==nq&&(f=qs)}d&&(c|=a.$a[rs]&d?256:0,c|=a.$a[rs]&e?512:0,c|=a.$a[ss]&f?512:0)}return c} var Br=12,Ar=13,xr=18,as=6,rs=7,bs=1,js=2,gs=4,ms=8,ps=16,es=32,cs=32,ks=64,hs=128,ss=9,ns=32,qs=64,ds=10,fs=16,is=18,ls=21,os=24,yr=25,ts={},us=(ts[0]=255,ts[1]=255,ts[2]=255,ts[3]=15,ts[4]=127,ts[5]=31,ts[6]=127,ts[7]=127,ts[8]=3,ts[9]=31,ts[10]=127,ts[11]=31,ts[Br]=63,ts[Ar]=255,ts[14]=63,ts[15]=255,ts[16]=63,ts[17]=255,ts),zr="HTOTAL HDISP HSPOS HSWIDTH VTOTAL VTOTADJ VDISP VSPOS ILMODE MAXSCAN CURSTART CUREND STARTHIGH STARTLOW CURHIGH CURLOW PENHIGH PENLOW".split(" "),Cr="HTOTAL HDEND HBSTART HBEND HRSTART HREND VTOTAL OVERFLOW PRESCAN MAXSCAN CURSTART CUREND STARTHIGH STARTLOW CURHIGH CURLOW VRSTART VREND VDEND OFFSET UNDERLINE VBSTART VBEND MODECTRL LINECOMP".split(" "), Dr=20,Qr="PAL00 PAL01 PAL02 PAL03 PAL04 PAL05 PAL06 PAL07 PAL08 PAL09 PAL0A PAL0B PAL0C PAL0D PAL0E PAL0F MODE OVERSCAN PLANES HPAN".split(" "),Er=1,Mr=1,Fr=5,Rr=["RESET","CLOCKING","MAPMASK","CHARMAP","MEMMODE"],Nr=255,Or=0,Pr=256,Gr=9,Sr="SRESET ESRESET COLORCMP DATAROT READMAP MODE MISC COLORDC BITMASK".split(" "),Hr=1024,Ir=4096,Yr=65280,Jr=0,Kr=16,$r=255,Lr=-2147483648,Tr=[];Tr[2]=Hr;Tr[3]=Hr|Ir;Tr[16]=1280;Tr[512]=Jr;Tr[1024]=Jr|32;Tr[1536]=Jr|96;Tr[2560]=Jr|160;Tr[3584]=Jr|224;Tr[768]=Jr|Kr; -Tr[4096]=1;Tr[8192]=2;Tr[24576]=98;Tr[40960]=162;Tr[57344]=226;var Zr=[];Zr[Hr]=function(a){a+=this.G;return(this.controller.xb=this.W[a])>>this.controller.$h&255};Zr[Hr|16384]=function(a){return(this.controller.xb=this.W[(a&-4)+this.G])>>((a&3)<<3)&255};Zr[Hr|Ir]=function(a){a+=this.G;var b=this.controller.xb=this.W[a&-2];return(a&1?b>>8:b)&255}; -Zr[1280]=function(a){a+=this.G;a=this.controller.xb=this.W[a];for(var b=this.controller.mh,c=this.controller.lh&b,d=0,e=128;e;)(a&b)==c&&(d|=e),c>>>=1,b>>>=1,e>>=1;return d};Zr[Jr]=function(a,b){a+=this.G;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Zd;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; +Tr[4096]=1;Tr[8192]=2;Tr[24576]=98;Tr[40960]=162;Tr[57344]=226;var Zr=[];Zr[Hr]=function(a){a+=this.G;return(this.controller.xb=this.W[a])>>this.controller.bi&255};Zr[Hr|16384]=function(a){return(this.controller.xb=this.W[(a&-4)+this.G])>>((a&3)<<3)&255};Zr[Hr|Ir]=function(a){a+=this.G;var b=this.controller.xb=this.W[a&-2];return(a&1?b>>8:b)&255}; +Zr[1280]=function(a){a+=this.G;a=this.controller.xb=this.W[a];for(var b=this.controller.oh,c=this.controller.nh&b,d=0,e=128;e;)(a&b)==c&&(d|=e),c>>>=1,b>>>=1,e>>=1;return d};Zr[Jr]=function(a,b){a+=this.G;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Zd;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; Zr[Jr|32]=function(a,b){a+=this.G;b=b>>this.controller.Pc|b<<8-this.controller.Pc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Zd;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; Zr[Jr|96]=function(a,b){a+=this.G;b=b>>this.controller.Pc|b<<8-this.controller.Pc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Zd;b&=this.controller.xb;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; Zr[Jr|160]=function(a,b){a+=this.G;b=b>>this.controller.Pc|b<<8-this.controller.Pc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Zd;b|=this.controller.xb;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; @@ -547,189 +547,190 @@ Zr[Jr|224]=function(a,b){a+=this.G;b=b>>this.controller.Pc|b<<8-this.controller. Zr[Jr|Kr]=function(a,b){a+=this.G;var c=a&-2;b=(b|b<<8|b<<16|b<<24)&this.controller.Db|this.controller.xb&~this.controller.Db;a=this.controller.kb&(c==a?16711935:-16711936);b=b&a|this.W[c]&~a;this.W[c]!=b&&(this.W[c]=b,this.Oa=!0)};Zr[1]=function(a){a+=this.G;var b=this.W[a]&~this.controller.kb|this.controller.xb&this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; Zr[1|Kr]=function(a){a+=this.G;var b=a&-2;a=this.controller.kb&(b==a?16711935:-16711936);a=this.W[b]&~a|this.controller.xb&a;this.W[b]!=a&&(this.W[b]=a,this.Oa=!0)};Zr[2]=function(a,b){a+=this.G;b=vs[b&15];b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; Zr[98]=function(a,b){a+=this.G;b=vs[b&15];b&=this.controller.xb;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)};Zr[162]=function(a,b){a+=this.G;b=vs[b&15];b|=this.controller.xb;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; -Zr[226]=function(a,b){a+=this.G;b=vs[b&15];b^=this.controller.xb;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)};Zr[3]=function(a,b){a+=this.G;b=b>>this.controller.Pc|b<<8-this.controller.Pc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Db;b=this.controller.Df&b|this.controller.xb&~b;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; -function Q(a,b,c,d,e){pb.call(this,"Video",a,262144);var f=this,g;this.$c=Ua("Gecko/");this.da=a.model;var h=ws[this.da]||ws.mda;this.Ma=h[0];this.ud=a.memory||0;this.nd=a.switches;this.Sb=a.randomize;null==this.Sb&&(this.Sb=1);this.ea=a.mode;if(null==this.ea||null==xs[this.ea])this.ea=h[1];this.Rb=a.charCols;this.Ac=a.charRows;if(void 0===this.Rb||void 0===this.Ac)this.Rb=xs[this.ea][0],this.Ac=xs[this.ea][1];this.aa=a.screenWidth;this.ka=a.screenHeight;this.bd=a.scale;this.Qd=12<=Math.round(this.aa/ -this.Rb);this.N=b;this.L=c;this.F=(this.lg=d)||b||null;this.lc=a.screenColor||"black";this.md=(1-(Xa("flicker")||a.flicker||0)).toString();this.Hb=!1;b&&(b.style.backgroundColor=this.lc);e&&(e.style.backgroundColor=this.lc);b=a.smoothing;(c=Xa("smoothing"))&&(b="true"==c);null!=b&&(g=Va(this.L,"imageSmoothingEnabled"))&&(this.L[g]=b);this.od=a.touchScreen;this.lb=ys;this.H=null;this.Pd=a.autoLock;this.fb=this.Tb=0;this.ra=[];this.ha=Array(this.Ma==nq?256:16);this.Ia=!1;if(this.P=e)if(g=Va(e,"requestFullscreen")|| -Va(e,"requestFullScreen")){this.P.A=e[g];if(e=Va(document,"on","fullscreenchange")){var k=Va(document,"fullscreenElement")||Va(document,"fullScreenElement");document.addEventListener(e,function(){zs(f,!!k)},!1)}(e=Va(document,"on","fullscreenerror"))&&document.addEventListener(e,function(){zs(f,null)},!1)}if(this.F&&(this.F.onfocus=function(){return f.xg(!0)},this.F.onblur=function(){return f.xg(!1)},this.F.ne=(g=Va(this.F,"requestPointerLock"))&&this.F[g],this.F.B=(g=Va(this.F,"exitPointerLock"))&& -this.F[g],this.F.ne&&(e=Va(document,"on","pointerlockchange")))){var m=Va(document,"pointerLockElement");document.addEventListener(e,function(){f.Ff(!(!m||document[m]!==f.F))},!1)}(this.Aa=a.fontROM)&&"json"!=ya(this.Aa)&&(this.Aa=Na()+"/api/v1/dump?file="+this.Aa+"&format=bytes")}ia(Q,pb);l=Q.prototype; -l.tc=function(a,b,c,d){var e=this;this.oa=b;this.G=c;this.ca=d;c=+Ad(a,"randomize");0<=c&&1>=c&&(this.Sb=c);c=(c=ws[this.da])&&c[0];c!==As&&(Pc(b,this,Bs),Uc(b,this,Cs));c!==Ds&&(Pc(b,this,Es),Uc(b,this,Fs));this.Ma>=lq&&(Pc(b,this,Gs),Uc(b,this,Hs));this.Ma==nq&&(Pc(b,this,Is),Uc(b,this,Js));d&&Cl(d,262144,function(a){if(e.B)if(a[0]){var b=e.B;if(b.dd){var c,d=!1,f=8,g=8,h=-1,J=b.video.D>>3;for(c=0;c=P&&(g=P,d=!0);break;case "p":0<=P&&3>=P&&(h=P);break;case "w":P=b.fb&&(I-=b.fb);a="";for(c=0;ch?q(G):ta(G>>(h<<3),8));d&&(I+=J-g);a&&(a+="\n");a+=H}a&&b.ca.O(a);b.B=I}else b.ca.O("no buffer")}else e.ca.O("BIOSMODE: "+va(e.la)),b=e.B,Wr(b,"CRTC",b.gc,b.$a,b.ag),b.Ma>=lq&&(Wr(b," GRC",b.Dd,b.Cd,b.Qg), -Wr(b," SEQ",b.Ed,b.be,b.Rg),Wr(b," ATC",b.Bd,b.Dc,b.Pg),Wr(b," ATCINDX",b.Bd),b.ca.O(" ATCDATA: "+b.Ie),Wr(b," FEAT",b.Kf),Wr(b," MISC",b.Ze),Wr(b," STATUS0",b.Eg)),Wr(b," STATUS1",b.ga),b.Ma!=Ds&&b.Ma!=As||Wr(b," MODEREG",b.Uc),b.Ma==As&&Wr(b," COLOR",b.Xe),b.Ma>=lq&&(b.ca.O(" LATCHES: "+q(b.xb)),b.ca.O(" ACCESS: "+q(b.og,4)),b.ca.O("Use 'dump video [addr]' to dump video memory"));else e.ca.O("no active video card")});if((this.C=ac(a,"Keyboard"))&&this.N){for(var f in this.ma)0c&&(a=Math.round(c/b*100)+"%")}d.$c?(d.N.style.width=a,d.N.style.width=a,d.N.style.display="block",d.N.style.margin="auto"):(d.P.style.width=a,d.P.style.height="auto");d.P.style.backgroundColor=d.lc;d.P.A()}d.F&&d.F.focus()}}:c.parentNode.removeChild(c), -!0;case "lockPointer":return this.Sd=c.textContent,this.F&&this.F.ne?c.onclick=function(){d.ne(!0)}:c.parentNode.removeChild(c),!0;case "refresh":return c.onclick=function(){Ps(d,!0)},!0}return!1};function zs(a,b){!b&&a.P&&(a.$c?a.N.style.width=a.N.style.height="":a.P.style.width=a.P.style.height="");Tb(a,"notifyFullScreen("+b+")",!0);a.C&&(a.C.Zg=b)} -l.ne=function(a){var b=!1;this.F&&(a?this.F.ne&&(this.F.ne(),this.H&&this.H.Ff(!0),b=!0):this.F.B&&(this.F.B(),this.H&&this.H.Ff(!1),b=!0),this.F&&this.F.focus());return b};l.Ff=function(a){this.H&&(this.H.Ff(a),this.C&&(this.C.Zg=a));var b=this.ma.lockPointer;b&&(b.textContent=a?"Press Esc to Unlock Pointer":this.Sd)}; -function Ks(a,b){var c=a.F;c&&!a.lb&&(a.lb=b,c.addEventListener("touchstart",function(b){gq(a.V,b);a.lb!=Ns&&Rs(a,b,!0)},!1),b!=Ns&&(c.addEventListener("touchmove",function(b){Rs(a,b)},!0),c.addEventListener("touchend",function(b){Rs(a,b,!1)},!1),a.mb=a.vb=a.pd=-1,a.wc=!1,a.Kb=null,a.vc=!1,a.Rd=function(){a.vc=!0;a.H.Xd(Ss,!0)}))}l.xg=function(a){this.C&&this.C.xg(a)}; -function Rs(a,b,c){var d=0,e=0;var f=a.N;do isNaN(f.offsetLeft)||(d+=f.offsetLeft,e+=f.offsetTop);while(f=f.offsetParent);var g=a.aa/a.N.offsetWidth,h=a.ka/a.N.offsetHeight;if(b.targetTouches&&b.targetTouches.length){f=b.targetTouches[0].pageX;var k=b.targetTouches[0].pageY}else f=b.pageX,k=b.pageY;f=(f-d)*g;k=(k-e)*h;if(a.lb==Ms)c&&Gq(a.C,Ts[k/(a.ka/3)|0][f/(a.aa/3)|0],!0);else if(a.H){e=a.wc;d=b.timeStamp-a.pd;!0===c?(a.wc=500d){a.H.Xd(Ss,!0);a.H.Xd(Ss,!1);return}}if(c||0>a.mb||0>a.vb)a.mb=f,a.vb=k;c=Math.round(f-a.mb);b=Math.round(k-a.vb);a.mb=f;a.vb=k;a.H.rf(c,b,a.mb,a.vb)}}l.$b=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Zb=function(a){return a?this.save():!0}; +Zr[226]=function(a,b){a+=this.G;b=vs[b&15];b^=this.controller.xb;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)};Zr[3]=function(a,b){a+=this.G;b=b>>this.controller.Pc|b<<8-this.controller.Pc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Db;b=this.controller.Ef&b|this.controller.xb&~b;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; +function Q(a,b,c,d,e){pb.call(this,"Video",a,262144);var f=this,g;this.$c=Ua("Gecko/");this.da=a.model;var h=ws[this.da]||ws.mda;this.Ma=h[0];this.ud=a.memory||0;this.nd=a.switches;this.Sb=a.randomize;null==this.Sb&&(this.Sb=1);this.ea=a.mode;if(null==this.ea||null==xs[this.ea])this.ea=h[1];this.Rb=a.charCols;this.Ac=a.charRows;if(void 0===this.Rb||void 0===this.Ac)this.Rb=xs[this.ea][0],this.Ac=xs[this.ea][1];this.Z=a.screenWidth;this.ka=a.screenHeight;this.bd=a.scale;this.Qd=12<=Math.round(this.Z/ +this.Rb);this.N=b;this.L=c;this.F=(this.mg=d)||b||null;this.lc=a.screenColor||"black";this.md=(1-(Xa("flicker")||a.flicker||0)).toString();this.Hb=!1;b&&(b.style.backgroundColor=this.lc);e&&(e.style.backgroundColor=this.lc);b=a.smoothing;(c=Xa("smoothing"))&&(b="true"==c);null!=b&&(g=Va(this.L,"imageSmoothingEnabled"))&&(this.L[g]=b);this.od=a.touchScreen;this.lb=ys;this.H=null;this.Pd=a.autoLock;this.fb=this.Tb=0;this.ra=[];this.ha=Array(this.Ma==nq?256:16);this.Ia=!1;if(this.P=e)if(g=Va(e,"requestFullscreen")|| +Va(e,"requestFullScreen")){this.P.A=e[g];if(e=Va(document,"on","fullscreenchange")){var k=Va(document,"fullscreenElement")||Va(document,"fullScreenElement");document.addEventListener(e,function(){zs(f,!!k)},!1)}(e=Va(document,"on","fullscreenerror"))&&document.addEventListener(e,function(){zs(f,null)},!1)}if(this.F&&(this.F.onfocus=function(){return f.yg(!0)},this.F.onblur=function(){return f.yg(!1)},this.F.ne=(g=Va(this.F,"requestPointerLock"))&&this.F[g],this.F.B=(g=Va(this.F,"exitPointerLock"))&& +this.F[g],this.F.ne&&(e=Va(document,"on","pointerlockchange")))){var m=Va(document,"pointerLockElement");document.addEventListener(e,function(){f.Gf(!(!m||document[m]!==f.F))},!1)}(this.Aa=a.fontROM)&&"json"!=ya(this.Aa)&&(this.Aa=Na()+"/api/v1/dump?file="+this.Aa+"&format=bytes")}ia(Q,pb);l=Q.prototype; +l.tc=function(a,b,c,d){var e=this;this.oa=b;this.G=c;this.ca=d;c=+Bd(a,"randomize");0<=c&&1>=c&&(this.Sb=c);c=(c=ws[this.da])&&c[0];c!==As&&(Pc(b,this,Bs),Uc(b,this,Cs));c!==Ds&&(Pc(b,this,Es),Uc(b,this,Fs));this.Ma>=lq&&(Pc(b,this,Gs),Uc(b,this,Hs));this.Ma==nq&&(Pc(b,this,Is),Uc(b,this,Js));d&&Cl(d,262144,function(a){if(e.B)if(a[0]){var b=e.B;if(b.dd){var c,d=!1,f=8,g=8,h=-1,J=b.video.D>>3;for(c=0;c=P&&(g=P,d=!0);break;case "p":0<=P&&3>=P&&(h=P);break;case "w":P=b.fb&&(I-=b.fb);a="";for(c=0;ch?q(G):ta(G>>(h<<3),8));d&&(I+=J-g);a&&(a+="\n");a+=H}a&&b.ca.O(a);b.B=I}else b.ca.O("no buffer")}else e.ca.O("BIOSMODE: "+va(e.la)),b=e.B,Wr(b,"CRTC",b.gc,b.$a,b.bg),b.Ma>=lq&&(Wr(b," GRC",b.Dd,b.Cd,b.Rg), +Wr(b," SEQ",b.Ed,b.be,b.Sg),Wr(b," ATC",b.Bd,b.Dc,b.Qg),Wr(b," ATCINDX",b.Bd),b.ca.O(" ATCDATA: "+b.Je),Wr(b," FEAT",b.Lf),Wr(b," MISC",b.$e),Wr(b," STATUS0",b.Fg)),Wr(b," STATUS1",b.ga),b.Ma!=Ds&&b.Ma!=As||Wr(b," MODEREG",b.Uc),b.Ma==As&&Wr(b," COLOR",b.Ye),b.Ma>=lq&&(b.ca.O(" LATCHES: "+q(b.xb)),b.ca.O(" ACCESS: "+q(b.pg,4)),b.ca.O("Use 'dump video [addr]' to dump video memory"));else e.ca.O("no active video card")});if((this.C=ac(a,"Keyboard"))&&this.N){for(var f in this.ma)0c&&(a=Math.round(c/b*100)+"%")}d.$c?(d.N.style.width=a,d.N.style.width=a,d.N.style.display="block",d.N.style.margin="auto"):(d.P.style.width=a,d.P.style.height="auto");d.P.style.backgroundColor=d.lc;d.P.A()}d.F&&d.F.focus()}}:c.parentNode.removeChild(c), +!0;case "lockPointer":return this.Sd=c.textContent,this.F&&this.F.ne?c.onclick=function(){d.ne(!0)}:c.parentNode.removeChild(c),!0;case "refresh":return c.onclick=function(){Ps(d,!0)},!0}return!1};function zs(a,b){!b&&a.P&&(a.$c?a.N.style.width=a.N.style.height="":a.P.style.width=a.P.style.height="");Tb(a,"notifyFullScreen("+b+")",!0);a.C&&(a.C.$g=b)} +l.ne=function(a){var b=!1;this.F&&(a?this.F.ne&&(this.F.ne(),this.H&&this.H.Gf(!0),b=!0):this.F.B&&(this.F.B(),this.H&&this.H.Gf(!1),b=!0),this.F&&this.F.focus());return b};l.Gf=function(a){this.H&&(this.H.Gf(a),this.C&&(this.C.$g=a));var b=this.ma.lockPointer;b&&(b.textContent=a?"Press Esc to Unlock Pointer":this.Sd)}; +function Ks(a,b){var c=a.F;c&&!a.lb&&(a.lb=b,c.addEventListener("touchstart",function(b){gq(a.V,b);a.lb!=Ns&&Rs(a,b,!0)},!1),b!=Ns&&(c.addEventListener("touchmove",function(b){Rs(a,b)},!0),c.addEventListener("touchend",function(b){Rs(a,b,!1)},!1),a.mb=a.vb=a.pd=-1,a.wc=!1,a.Kb=null,a.vc=!1,a.Rd=function(){a.vc=!0;a.H.Xd(Ss,!0)}))}l.yg=function(a){this.C&&this.C.yg(a)}; +function Rs(a,b,c){var d=0,e=0;var f=a.N;do isNaN(f.offsetLeft)||(d+=f.offsetLeft,e+=f.offsetTop);while(f=f.offsetParent);var g=a.Z/a.N.offsetWidth,h=a.ka/a.N.offsetHeight;if(b.targetTouches&&b.targetTouches.length){f=b.targetTouches[0].pageX;var k=b.targetTouches[0].pageY}else f=b.pageX,k=b.pageY;f=(f-d)*g;k=(k-e)*h;if(a.lb==Ms)c&&Gq(a.C,Ts[k/(a.ka/3)|0][f/(a.Z/3)|0],!0);else if(a.H){e=a.wc;d=b.timeStamp-a.pd;!0===c?(a.wc=500d){a.H.Xd(Ss,!0);a.H.Xd(Ss,!1);return}}if(c||0>a.mb||0>a.vb)a.mb=f,a.vb=k;c=Math.round(f-a.mb);b=Math.round(k-a.vb);a.mb=f;a.vb=k;a.H.sf(c,b,a.mb,a.vb)}}l.$b=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Zb=function(a){return a?this.save():!0}; l.reset=function(){var a=0;this.V&&(a=+Yl(this.V,ml,void 0));this.da||(this.Ma=a==Zl?Ds:As);this.ea=Us;switch(this.Ma){case nq:a=7;break;case lq:var b=Vs[this.Fb];b&&(a=b[0]);a||(a=4);break;case Ds:a=Zl;this.ea=Ws;break;default:a=2}this.fa!==a&&(this.fa=a);this.B=null;this.U=this.fc=new vr(this,Ds);this.K=this.Gb=new vr(this,As);this.Ma>1&255;c=c>>8&~$s;c>>4==(c&15)&&(c^=15)}else d=c&255,c=(c&256?at|bt:ct|dt)|et&c>>8;Mc(this.oa,b,d|c<<8)}Ps(this,!0)}};function Xs(a){a.A.Ze&Er?(a.U=a.fc,a.K=a.A):(a.U=a.A,a.K=a.Gb)}l.save=function(){var a=new ag(this);a.set(0,Vr(this.fc));a.set(1,Vr(this.Gb));a.set(2,[this.fa,this.ea,this.la]);a.set(3,Vr(this.A));return a.data()}; +a;b+=2){var c=65536*Math.random()|0;if(4==this.fa||7==this.fa){var d=b>>1&255;c=c>>8&~$s;c>>4==(c&15)&&(c^=15)}else d=c&255,c=(c&256?at|bt:ct|dt)|et&c>>8;Mc(this.oa,b,d|c<<8)}Ps(this,!0)}};function Xs(a){a.A.$e&Er?(a.U=a.fc,a.K=a.A):(a.U=a.A,a.K=a.Gb)}l.save=function(){var a=new ag(this);a.set(0,Vr(this.fc));a.set(1,Vr(this.Gb));a.set(2,[this.fa,this.ea,this.la]);a.set(3,Vr(this.A));return a.data()}; l.restore=function(a){var b=a[2];this.fa=b[0];this.ea=b[1];this.la=b[2];this.B=null;this.U=this.fc=new vr(this,Ds,a[0]);this.K=this.Gb=new vr(this,As,a[1]);this.A=new vr(this,this.Ma,a[3],this.ud);this.A.rc&&Xs(this);Ys(this);if(!ft(this))return!1;gt(this);return!0}; function Os(a,b,c,d){if(d)a.Da("Unable to load font ROM (error "+d+": "+b+")",0>d);else{rb(a.de,b,c);try{var e=eval("("+c+")"),f=e.bytes||e;if(!f.length){kb("Empty font ROM: "+b);return}if(1==f.length){kb(f[0]);return}if(8192==f.length)mq(a,f,[6144,0]);else if(2048==f.length)mq(a,f,[0]);else{a.Da("Unrecognized font data length ("+f.length+")");return}}catch(g){a.Da("Font ROM data error: "+g.message);return}(a.L||a.ca)&&Pb(a)}} -function ht(a,b){if(1==b)return a.ha[0]=it[ct],a.ha[1]=it[at],a.ha;if(2==b){var c=a.B.Xe;if(a.B===a.A){var d=a.A.Dc[0];c=d&7;d&16&&(c|=8);18!=a.A.Dc[1]&&(c|=32)}a.ha[0]=it[c&15];c=c&32?jt:kt;for(d=0;de;e++){var f=d[e]||0;var g=f<<2&252;var h=f>>4&252;f=f>>10&252;a.ha[e]=[g,h,f,255]}else{var k=d&&d[255];b=null!=c.Dc[15]?c.Dc:lt;for(e=0;16>e;e++)f=b[e]& +function ht(a,b){if(1==b)return a.ha[0]=it[ct],a.ha[1]=it[at],a.ha;if(2==b){var c=a.B.Ye;if(a.B===a.A){var d=a.A.Dc[0];c=d&7;d&16&&(c|=8);18!=a.A.Dc[1]&&(c|=32)}a.ha[0]=it[c&15];c=c&32?jt:kt;for(d=0;de;e++){var f=d[e]||0;var g=f<<2&252;var h=f>>4&252;f=f>>10&252;a.ha[e]=[g,h,f,255]}else{var k=d&&d[255];b=null!=c.Dc[15]?c.Dc:lt;for(e=0;16>e;e++)f=b[e]& 63,k?(f|=(c.Dc[20]&12)<<4,c.Dc[16]&128&&(f&=-49,f|=(c.Dc[20]&3)<<4),f=d[f],g=f<<2&252,h=f>>4&252,f=f>>10&252):(g=(f&4?170:0)|(f&32?85:0),h=(f&2?170:0)|(f&16?85:0),f=(f&1?170:0)|(f&8?85:0)),a.ha[e]=[g,h,f,255]}a.Ia=!0}return a.ha}function mq(a,b,c,d){a.zb=b;a.Pa=c;a.Fa=d} function Ys(a,b){var c=!1;if(window&&a.zb&&(!b||a.I)){var d=0,e=a.Fa?a.Fa:8,f=ht(a);null!=a.Pa[0]&&mt(a,nt,a.Pa[0],d,e,8,a.zb,f)&&(c=!0);d=a.Fa?0:2048;e=a.Fa?a.Fa:9;null!=a.Pa[1]&&(mt(a,ot,a.Pa[1],d,e,14,a.zb,pt,qt)&&(c=!0),a.Fa&&mt(a,a.Ma,a.Pa[1],0,a.Fa,14,a.zb,f)&&(c=!0))}b||(a.ba=-1,a.Ba=-1,a.ta=0);return c}function mt(a,b,c,d,e,f,g,h,k){var m=!1;null!=c&&(rt(a,b,c,d,e,f,g,h,k)&&(m=!0),a.Qd&&rt(a,b<<1,c,d,e,f,g,h,k)&&(m=!0));return m} -function rt(a,b,c,d,e,f,g,h,k){var m=!1,p=b&1?0:1,v=a.ra[b],u=16>h.length?h.length:16;v||(v={Gc:e<ra||!Z?ra:8,jb=cc.createImageData(m.Gc,m.Hc);for(G=0;256>G;G++){for(A=0;A=ra-2,Sd=ib[A>(8<=H&&192<=G&&223>=G?7:H)?P:Sb;st(jb,Fg,kf,Gg);I&&st(jb,Fg+1,kf,Gg)}cc.putImageData(jb,(G&15)*m.Gc,(G>>4)*m.Hc)}m.Ae[J]="#"+q(P[0],2)+q(P[1],2)+q(P[2],2);m.Mi[J]=P;m.Og[J]=Jb;m=!0}}a.ra[b]=v;return m}function tt(a){0a.Ba&&(a.Ba=0):a.Ba=-1} -function gt(a){if(a.I){for(var b=10;15>=b;b++)if(null==a.B.$a[b])return;var c=a.B.$a[10];b=c&31;var d=a.B.$a[11]&us[11],e=a.B.$a[9]&us[9],f=!1;a.B===a.A&&(f=!0,7!=e||4!=b||d||(d=7));if(c&32||b>d&&!f||b>e)ut(a);else{c=a.B.$a[15];c|=(a.B.$a[14]&a.B.$f)<<8;a.ba!=c&&(ut(a),a.ba=c);d=d-b+1;if(a.qd!=b||a.Sc!=d)a.qd=b,a.Sc=d;a.wa=e+1;tt(a)}}} +function rt(a,b,c,d,e,f,g,h,k){var m=!1,p=b&1?0:1,v=a.ra[b],u=16>h.length?h.length:16;v||(v={Gc:e<ra||!Z?ra:8,jb=cc.createImageData(m.Gc,m.Hc);for(G=0;256>G;G++){for(A=0;A=ra-2,Sd=ib[A>(8<=H&&192<=G&&223>=G?7:H)?P:Sb;st(jb,Fg,mf,Gg);I&&st(jb,Fg+1,mf,Gg)}cc.putImageData(jb,(G&15)*m.Gc,(G>>4)*m.Hc)}m.Be[J]="#"+q(P[0],2)+q(P[1],2)+q(P[2],2);m.Ni[J]=P;m.Pg[J]=Jb;m=!0}}a.ra[b]=v;return m}function tt(a){0a.Ba&&(a.Ba=0):a.Ba=-1} +function gt(a){if(a.I){for(var b=10;15>=b;b++)if(null==a.B.$a[b])return;var c=a.B.$a[10];b=c&31;var d=a.B.$a[11]&us[11],e=a.B.$a[9]&us[9],f=!1;a.B===a.A&&(f=!0,7!=e||4!=b||d||(d=7));if(c&32||b>d&&!f||b>e)ut(a);else{c=a.B.$a[15];c|=(a.B.$a[14]&a.B.ag)<<8;a.ba!=c&&(ut(a),a.ba=c);d=d-b+1;if(a.qd!=b||a.Sc!=d)a.qd=b,a.Sc=d;a.wa=e+1;tt(a)}}} function ut(a){if(0<=a.ba){if(void 0!==a.M){var b=vt<<8,c=a.M[a.ba];if(c&b){c&=~b;b=a.ba%a.D;var d=a.ba/a.D|0;a.I&&a.ra[a.I]&&(a.Ea&&wt(a,b,d,c,a.Ea),wt(a,b,d,c));a.M[a.ba]=c}}a.ba=-1}} function xt(a){var b=a.B;a.Tc=!1;var c=b.Cd[5];if(null!=c){var d=Hr;var e=Jr,f=b.Cd[3]&31;switch(c&3){case 0:if(f){e=Jr|32;switch(f&24){case 8:e=Jr|96;break;case 16:e=Jr|160;break;case 24:e=Jr|224}b.Pc=f&7}break;case 1:e=1;break;case 2:switch(f&24){default:e=2;break;case 8:e=98;break;case 16:e=162;break;case 24:e=226}break;case 3:a.Ma==nq&&(e=3,b.Pc=f&7)}c&8&&(d=1280);b=b.be[4];null!=b&&(b&4||(d|=Ir,e|=Kr),c&64&&(b&8&&(d|=16384,e|=4),a.Tc=!0));d|=e}return d} -function yt(a,b){var c=a.B;return c&&null!=b&&b!=c.og?(c.Gg(b),a.oa.Gg(c.fb,c.Tb,c.ah(),!0),!0):!1} +function yt(a,b){var c=a.B;return c&&null!=b&&b!=c.pg?(c.Hg(b),a.oa.Hg(c.fb,c.Tb,c.bh(),!0),!0):!1} function ft(a,b){var c=a.la,d=a.B;if(d)if(d.Ma==Ds)c=Ws;else if(d.Ma>=lq){c=null;var e=d.ud>>2,f=32768=d.$a[is]?Dt:Et:Ft:f&128|| -350>e?c=m?Gt:Ht:480<=e&&(c=a.fa==Zl?It:Jt):c=m?7-c:Kt:c-=m?2:0);h=xt(a)}}else d.Uc&8?(d.Uc&2?(c=d.Uc&16?Kt:Lt,d.Uc&4||--c):(c=d.Uc&1?Us:Mt,d.Uc&4&&--c),a.Hb&&(a.N.style.opacity="1",a.Hb=!1)):!a.Hb&&1>+a.md&&(a.Hb=!0,a.N.style.opacity=a.md,d=a.G,d.Z.Of=!0,Fd(d));else a.la=null,null==c&&(c=a.ea);if(!Zs(a,c,b))return!1;yt(a,h);return!0} +350>e?c=m?Gt:Ht:480<=e&&(c=a.fa==Zl?It:Jt):c=m?7-c:Kt:c-=m?2:0);h=xt(a)}}else d.Uc&8?(d.Uc&2?(c=d.Uc&16?Kt:Lt,d.Uc&4||--c):(c=d.Uc&1?Us:Mt,d.Uc&4&&--c),a.Hb&&(a.N.style.opacity="1",a.Hb=!1)):!a.Hb&&1>+a.md&&(a.Hb=!0,a.N.style.opacity=a.md,d=a.G,d.aa.Pf=!0,Fd(d));else a.la=null,null==c&&(c=a.ea);if(!Zs(a,c,b))return!1;yt(a,h);return!0} function Zs(a,b,c){if(null!=b&&(b!=a.la||c)){a.Fd=0;a.la=b;a.Ia=!1;b=a.B||(b==Ws?a.U:a.K);if(b!=a.B||b.fb!=a.fb||b.Tb!=a.Tb){ut(a);if(a.fb){if(!Ec(a.oa,a.fb,a.Tb))return!1;a.B&&(a.B.rc=!1)}a.B=b;b.rc=!0;a.fb=b.fb;a.Tb=b.Tb;if(!rc(a.oa,b.fb,b.Tb,3,b===a.A?b:null))return!1}a:{a.I=0;a.D=a.Rb;a.J=a.Ac;a.La=a.D;a.Qb=xs[Ws][2];b=0;if(c=xs[a.la])a.D=c[0],a.J=c[1],a.Qb=c[2],b=c[3],a.I=c[4],4!=a.fa&&7!=a.fa||a.B!==a.A||a.I!=nt||(7==(a.A.$a[ss]&31)?a.J=350>Xr(a.A,is)?43:50:a.I=a.Ma);a.ld=a.D*a.J|0;a.kd=a.ld/ -a.Qb|0;a.Ra=a.kd;a.kc=0;void 0!==b&&(a.Ra=(a.Ra<<1)+b|0,a.kc=a.Ra+b>>1);if(a.ra.length){a.qa=a.aa/a.D|0;a.pa=a.ka/a.J|0;if(a.I){b=a.ra[a.I];if(!b)break a;c=a.ra[a.I<<1];a.bd&&80==a.D?c&&a.qa>=3*c.Gc>>2&&(a.I<<=1,b=c):(c&&a.qa>=c.Gc&&(a.I<<=1,b=c),a.bd||(a.qa=b.Gc,a.pa=b.Hc));a.ab=a.cb=0;b&&(a.ab=a.D*b.Gc,a.cb=a.J*b.Hc)}else a.qa=a.pa=1,a.ab=a.D,a.cb=a.J;a.Ka=a.L.createImageData(a.ab,a.cb);a.Ca=document.createElement("canvas");a.Ca.width=a.ab;a.Ca.height=a.cb;a.Ea=a.Ca.getContext("2d");a.Jc=a.Kc=0; -a.sc=a.aa;a.uc=a.ka;b=a.aa-a.D*a.qa;c=a.ka-a.J*a.pa;0>1,a.sc-=b);0>1,a.uc-=c);if(b||c)a.L.fillStyle=a.N.style.backgroundColor,a.L.fillRect(0,0,a.aa,a.ka)}}mu(a,!0);Ps(a)}return!0}function st(a,b,c,d){b=(b+c*a.width)*d.length;a.data[b]=d[0];a.data[b+1]=d[1];a.data[b+2]=d[2];a.data[b+3]=d[3]}function ou(a){a.ta=-1;a.Ga=!1;var b=a.kd;if(void 0===a.M||a.M.length!=b)a.M=Array(b)}function mu(a,b){b||(a.Ia=!1);ou(a)} -function wt(a,b,c,d,e){var f=d&255,g=d>>8;d=g&15;var h=a.ra[a.I];h.gf&&(d=h.gf[d]);var k=g>>4&15;h.gf&&(k=h.gf[k]);e?(b*=h.Gc,c*=h.Hc,e.fillStyle=h.Ae[k],e.fillRect(b,c,h.Gc,h.Hc)):(b=b*a.qa+a.Jc,c=c*a.pa+a.Kc,a.L.fillStyle=h.Ae[k],a.L.fillRect(b,c,a.qa,a.pa));g&pu&&(k=(f&15)*h.Gc,f=(f>>4)*h.Hc,e?e.drawImage(h.Og[d],k,f,h.Gc,h.Hc,b,c,h.Gc,h.Hc):a.L.drawImage(h.Og[d],k,f,h.Gc,h.Hc,b,c,a.qa,a.pa));g&vt&&(f=a.qd,g=a.Sc,e?(a.wa&&a.wa!==h.Hc&&(f=f*h.Hc/a.wa|0,g=g*h.Hc/a.wa|0),e.fillStyle=h.Ae[d],e.fillRect(b, -c+f,h.Gc,g)):(a.wa&&a.wa!==a.pa&&(f=f*a.pa/a.wa|0,g=g*a.pa/a.wa|0),a.L.fillStyle=h.Ae[d],a.L.fillRect(b,c+f,a.qa,g)))} -function Ps(a,b){b=void 0===b?!1:b;if(a.Z.ac){var c=!1,d=a.B;d&&(d!==a.A?d.Uc&8&&(c=!0):d.Bd&32&&(c=!0));if(c||b){if(b)ou(a);else if(void 0===a.M)return;c=!1;!(b||++a.Fd&15)&&0<=a.Ba&&(a.Ba++,c=!0);var e=a.ld,f=a.fb,g=f,h=g+a.Tb;a.la>=Dt&&(f=g=655360,h=g+65536);if(qu(a,d)&8||d.Ef&&d.Ef=lq&&d.$a[19]&&d.$a[19]<<1!=d.$a[1]+1&&(a.La=d.$a[19]<<(a.I?1:d.$a[20]&64?3:4),k=(a.La*(a.J-1)+a.D)/ +a.Qb|0;a.Ra=a.kd;a.kc=0;void 0!==b&&(a.Ra=(a.Ra<<1)+b|0,a.kc=a.Ra+b>>1);if(a.ra.length){a.qa=a.Z/a.D|0;a.pa=a.ka/a.J|0;if(a.I){b=a.ra[a.I];if(!b)break a;c=a.ra[a.I<<1];a.bd&&80==a.D?c&&a.qa>=3*c.Gc>>2&&(a.I<<=1,b=c):(c&&a.qa>=c.Gc&&(a.I<<=1,b=c),a.bd||(a.qa=b.Gc,a.pa=b.Hc));a.ab=a.cb=0;b&&(a.ab=a.D*b.Gc,a.cb=a.J*b.Hc)}else a.qa=a.pa=1,a.ab=a.D,a.cb=a.J;a.Ka=a.L.createImageData(a.ab,a.cb);a.Ca=document.createElement("canvas");a.Ca.width=a.ab;a.Ca.height=a.cb;a.Ea=a.Ca.getContext("2d");a.Jc=a.Kc=0; +a.sc=a.Z;a.uc=a.ka;b=a.Z-a.D*a.qa;c=a.ka-a.J*a.pa;0>1,a.sc-=b);0>1,a.uc-=c);if(b||c)a.L.fillStyle=a.N.style.backgroundColor,a.L.fillRect(0,0,a.Z,a.ka)}}mu(a,!0);Ps(a)}return!0}function st(a,b,c,d){b=(b+c*a.width)*d.length;a.data[b]=d[0];a.data[b+1]=d[1];a.data[b+2]=d[2];a.data[b+3]=d[3]}function ou(a){a.ta=-1;a.Ga=!1;var b=a.kd;if(void 0===a.M||a.M.length!=b)a.M=Array(b)}function mu(a,b){b||(a.Ia=!1);ou(a)} +function wt(a,b,c,d,e){var f=d&255,g=d>>8;d=g&15;var h=a.ra[a.I];h.hf&&(d=h.hf[d]);var k=g>>4&15;h.hf&&(k=h.hf[k]);e?(b*=h.Gc,c*=h.Hc,e.fillStyle=h.Be[k],e.fillRect(b,c,h.Gc,h.Hc)):(b=b*a.qa+a.Jc,c=c*a.pa+a.Kc,a.L.fillStyle=h.Be[k],a.L.fillRect(b,c,a.qa,a.pa));g&pu&&(k=(f&15)*h.Gc,f=(f>>4)*h.Hc,e?e.drawImage(h.Pg[d],k,f,h.Gc,h.Hc,b,c,h.Gc,h.Hc):a.L.drawImage(h.Pg[d],k,f,h.Gc,h.Hc,b,c,a.qa,a.pa));g&vt&&(f=a.qd,g=a.Sc,e?(a.wa&&a.wa!==h.Hc&&(f=f*h.Hc/a.wa|0,g=g*h.Hc/a.wa|0),e.fillStyle=h.Be[d],e.fillRect(b, +c+f,h.Gc,g)):(a.wa&&a.wa!==a.pa&&(f=f*a.pa/a.wa|0,g=g*a.pa/a.wa|0),a.L.fillStyle=h.Be[d],a.L.fillRect(b,c+f,a.qa,g)))} +function Ps(a,b){b=void 0===b?!1:b;if(a.aa.ac){var c=!1,d=a.B;d&&(d!==a.A?d.Uc&8&&(c=!0):d.Bd&32&&(c=!0));if(c||b){if(b)ou(a);else if(void 0===a.M)return;c=!1;!(b||++a.Fd&15)&&0<=a.Ba&&(a.Ba++,c=!0);var e=a.ld,f=a.fb,g=f,h=g+a.Tb;a.la>=Dt&&(f=g=655360,h=g+65536);if(qu(a,d)&8||d.Ff&&d.Ff=lq&&d.$a[19]&&d.$a[19]<<1!=d.$a[1]+1&&(a.La=d.$a[19]<<(a.I?1:d.$a[20]&64?3:4),k=(a.La*(a.J-1)+a.D)/ a.Qb|0,a.la<=Ws&&(k<<=1));var p=d=0;g+k>h&&(p=k,g>=h?(d=f+(g-h),k=0):(d=f,k=h-g,p-=k));h=a.ba-(m>>1);g=ru(a,f,g,k,0,h,e,b,c);p&&(g+=ru(a,f,d,p,0+g,h,e,b,c));g&&(a.Ga=!0)}}} -function ru(a,b,c,d,e,f,g,h,k){var m=d>>1;m>g&&(m=g);var p=c+d;if(h=!h&&a.Ga){h=a.oa;for(var v=!0,u=c>>>h.A,A=h.B-(c&h.D);0f)return m;c+=f<<1;e+=f;g=e+1}}if(a.I){if(a.ra[a.I]){b=c;c=e;k=f=e=0;h=pu<<8;d=1048575;u=a.B.Uc&32;a.Ma>=lq&&(u=a.B.Dc[16]&8);v=a.ba-a.B.$d;u&&(k=$s<<8,d&=~k,a.Ba&2||(d&=~h));for(a.ta=0;b>1;g=0;c=a.Qb;e=b;f=16==c?65536:196608;k=16==c?1:2;h=ht(a,k);v=d=0;u=a.D;A=0;var J=a.J,H=0;for(a.ta=0;e>8|(G&255)<<8;var P=f,I=16;d>=k))>>(I-=k);st(a.Ka,d++,v,h[Z])}d>A&&(A=d);v=H&&(H=v+1)}e+=2;g++;if(d>=a.D){d= -0;v+=2;if(v>a.J)break;v==a.J&&(v=1,e=b+a.kc)}}ua.D?a.La-a.D-H>>3:0;for(a.ta=0;c>=8;k>v&&(v=k);h=A&&(A=h+1)}c+=J;if(k>=a.D){k=0;if(++h>a.J)break;c+=G}}H&& -(g=0)}else{m=0;g=p-c;e=ht(a);f=a.B.dd;h=k=0;d=a.D;v=0;u=a.J;A=0;J=a.B.Dc[19]&15;H=a.La>a.D?a.La-a.D-J>>3:0;for(a.ta=0;cP&&(I=P)):(G<<=J,I-=J,a.Ga=!1):(a.Ga&&G===a.M[m]?(k+=I,I=0):a.M[m]=G,m++);if(I){kv&&(v=k);h=A&&(A=h+1)}if(k>=a.D){k=0;if(++h>a.J)break;c+=H}}J&&(g=0)}da&&(b.rh=a,a=-a|0);a%b.oh>b.gn&&(c|=1);a%b.ph>b.jn&&(c|=9);b.ai=a/b.ph|0;return c}l.vm=function(a,b){return tu(this,this.U,a,b)};l.jo=function(a,b,c){var d=this.U;d.Bg=d.gc;d.gc=b&31;t(this,a,b,c,"CRTC.INDX")};l.um=function(a,b){return uu(this,this.U,a,b)};l.io=function(a,b,c){vu(this,this.U,a,b,c)};l.wm=function(a,b){return wu(this,this.U,b)};l.ko=function(a,b,c){a=this.U;t(this,a.port+4,b,c,"MODE");a.Uc=b;ft(this,!1)}; -l.xm=function(a,b){return xu(this,this.U,b)};l.Gk=function(a,b,c){this.A.Kf=this.A.Kf&-4|b&3;t(this,a,b,c,"FEAT")};l.Ql=function(a,b){a=this.A.Bd;b&&!r(this)||t(this,960,null,b,"ATC.INDX",a);return a};l.jl=function(a,b){a=this.A.Dc[this.A.Bd&31];b&&!r(this)||t(this,960,null,b,"ATC."+this.A.Pg[this.A.Bd&31],a);return a}; -l.Fk=function(a,b,c){var d=this.A,e=d.Bd&32;if(d.Ie){d.Ie=!1;var f=d.Bd&31;if(16<=f||!e)if(yu||d.Dc[f]!==b)c&&!r(this)||t(this,a,b,c,"ATC."+d.Pg[f]),d.Dc[f]=b,mu(this,!1)}else d.Bd=b,t(this,a,b,c,"ATC.INDX"),d.Ie=!0,b&32&&!e&&Ys(this,!0)&&Ps(this,!0),a=d.$a[Ar],a|=(d.$a[Br]&d.$f)<<8,d.$d!=a&&(d.$d=a,mu(this)),d.Ef=0}; -l.Hm=function(a,b){a=0;if(this.Ma==lq)a=3-((this.A.Ze&12)>>2),a=(this.Fb&1<>this.A.yc&63;b&&!r(this)||t(this,969,null,b,"DAC.DATA["+va(this.A.ad)+"]["+va(this.A.yc)+"]",a);this.A.yc+=6;12>1;m>g&&(m=g);var p=c+d;if(h=!h&&a.Ga){h=a.oa;for(var v=!0,u=c>>>h.A,A=h.B-(c&h.D);0f)return m;c+=f<<1;e+=f;g=e+1}}if(a.I){if(a.ra[a.I]){b=c;c=e;k=f=e=0;h=pu<<8;d=1048575;u=a.B.Uc&32;a.Ma>=lq&&(u=a.B.Dc[16]&8);v=a.ba-a.B.$d;u&&(k=$s<<8,d&=~k,a.Ba&2||(d&=~h));for(a.ta=0;b>1;g=0;c=a.Qb;e=b;f=16==c?65536:196608;k=16==c?1:2;h=ht(a,k);v=d=0;u=a.D;A=0;var J=a.J,H=0;for(a.ta=0;e>8|(G&255)<<8;var P=f,I=16;d>=k))>>(I-=k);st(a.Ka,d++,v,h[Z])}d>A&&(A=d);v=H&&(H=v+1)}e+=2;g++;if(d>=a.D){d= +0;v+=2;if(v>a.J)break;v==a.J&&(v=1,e=b+a.kc)}}ua.D?a.La-a.D-H>>3:0;for(a.ta=0;c>=8;k>v&&(v=k);h=A&&(A=h+1)}c+=J;if(k>=a.D){k=0;if(++h>a.J)break;c+=G}}H&&(g= +0)}else{m=0;g=p-c;e=ht(a);f=a.B.dd;h=k=0;d=a.D;v=0;u=a.J;A=0;J=a.B.Dc[19]&15;H=a.La>a.D?a.La-a.D-J>>3:0;for(a.ta=0;cP&&(I=P)):(G<<=J,I-=J,a.Ga=!1):(a.Ga&&G===a.M[m]?(k+=I,I=0):a.M[m]=G,m++);if(I){kv&&(v=k);h=A&&(A=h+1)}if(k>=a.D){k=0;if(++h>a.J)break;c+=H}}J&&(g=0)}da&&(b.th=a,a=-a|0);a%b.qh>b.hn&&(c|=1);a%b.rh>b.kn&&(c|=9);b.ci=a/b.rh|0;return c}l.wm=function(a,b){return tu(this,this.U,a,b)};l.ko=function(a,b,c){var d=this.U;d.Cg=d.gc;d.gc=b&31;t(this,a,b,c,"CRTC.INDX")};l.vm=function(a,b){return uu(this,this.U,a,b)};l.jo=function(a,b,c){vu(this,this.U,a,b,c)};l.xm=function(a,b){return wu(this,this.U,b)};l.lo=function(a,b,c){a=this.U;t(this,a.port+4,b,c,"MODE");a.Uc=b;ft(this,!1)}; +l.ym=function(a,b){return xu(this,this.U,b)};l.Hk=function(a,b,c){this.A.Lf=this.A.Lf&-4|b&3;t(this,a,b,c,"FEAT")};l.Rl=function(a,b){a=this.A.Bd;b&&!r(this)||t(this,960,null,b,"ATC.INDX",a);return a};l.kl=function(a,b){a=this.A.Dc[this.A.Bd&31];b&&!r(this)||t(this,960,null,b,"ATC."+this.A.Qg[this.A.Bd&31],a);return a}; +l.Gk=function(a,b,c){var d=this.A,e=d.Bd&32;if(d.Je){d.Je=!1;var f=d.Bd&31;if(16<=f||!e)if(yu||d.Dc[f]!==b)c&&!r(this)||t(this,a,b,c,"ATC."+d.Qg[f]),d.Dc[f]=b,mu(this,!1)}else d.Bd=b,t(this,a,b,c,"ATC.INDX"),d.Je=!0,b&32&&!e&&Ys(this,!0)&&Ps(this,!0),a=d.$a[Ar],a|=(d.$a[Br]&d.ag)<<8,d.$d!=a&&(d.$d=a,mu(this)),d.Ff=0}; +l.Im=function(a,b){a=0;if(this.Ma==lq)a=3-((this.A.$e&12)>>2),a=(this.Fb&1<>this.A.yc&63;b&&!r(this)||t(this,969,null,b,"DAC.DATA["+va(this.A.ad)+"]["+va(this.A.yc)+"]",a);this.A.yc+=6;12Missing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.height="auto";0<=Oa().indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height=(a.clientWidth*d/c|0)+"px"}}(c, e,d.screenWidth,d.screenHeight),c.onresize(null));var f=+(Xa("aspect")||d.aspect);f&&.3<=f&&3.33>=f&&(bb("onresize",function(a,b,c){return function(){b.style.height=(a.clientWidth/c|0)+"px"}}(c,e,f)),window.onresize());c.appendChild(e);f=document.createElement("textarea");Ua("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"),f.style.fontSize="16px");c.appendChild(f);var g=e.getContext("2d");d=new Q(d,e,g,f,c);yb(d,c)}}); function zu(a){pb.call(this,"ParallelPort",a,4194304);this.H=a.adapter;switch(this.H){case 1:this.D=956;this.C=7;break;case 2:this.D=888;this.C=7;break;case 3:this.D=632;this.C=5;break;default:kb("Unrecognized parallel adapter #"+this.H);return}this.A=this.B=null;a=a.binding;"console"==a?this.B="":wb(this,a,Au)}ia(zu,pb);l=zu.prototype;l.Eb=function(a,b,c){switch(b){case Au:return this.ma[b]=this.A=c,!0}return!1}; -l.tc=function(a,b,c,d){this.oa=b;this.G=c;this.ca=d;this.V=ac(a,"ChipSet");Pc(b,this,Bu,this.D);Uc(b,this,Cu,this.D);Pb(this)};l.$b=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Zb=function(a){return a?this.save():!0};l.reset=function(){Du(this)};l.save=function(){var a=new ag(this),b=0,c=[];c[b++]=this.F;c[b++]=this.Pb;c[b]=this.jf;a.set(0,c);return a.data()};l.restore=function(a){return Du(this,a[0])}; -function Du(a,b){var c=0;void 0===b&&(b=[0,0,0]);a.F=b[c++];a.Pb=b[c++];a.jf=b[c];return!0}l.im=function(a,b){var c=this.F;t(this,a,null,b,"DATA",c);return c};l.Gm=function(a,b){var c=this.Pb;t(this,a,null,b,"STAT",c);return c};l.em=function(a,b){var c=this.jf;t(this,a,null,b,"CTRL",c);return c}; -l.Un=function(a,b,c){t(this,a,b,c,"DATA");this.F=b;this.Pb|=Eu;a=!1;Tb(this,"transmitByte("+va(b)+")");this.A&&(8==b?this.A.value=this.A.value.slice(0,-1):(this.A.value+=String.fromCharCode(b),this.A.scrollTop=this.A.scrollHeight),a=!0);if(null!=this.B){if(10==b||1024<=this.B.length)this.O(this.B),this.B="";10!=b&&(this.B+=String.fromCharCode(b));a=!0}a&&(this.Pb&=~Eu);Fu(this)};l.Pn=function(a,b,c){t(this,a,b,c,"CTRL");this.jf=b;Fu(this)}; -function Fu(a){a.V&&a.C&&(a.jf&Gu&&!(a.Pb&Eu)?mh(a.V,a.C):Zg(a.V,a.C))}var Au="buffer",Eu=64,Gu=16,Bu={0:zu.prototype.im,1:zu.prototype.Gm,2:zu.prototype.em},Cu={0:zu.prototype.Un,2:zu.prototype.Pn};cb(function(){for(var a=zb(document,"pcx86","parallel"),b=0;b=b)a.preventDefault&&a.preventDefault(),64");if(2==c.length){var d=Da(c[0]);if(d!=this.ye)return;c=Da(c[1]);if(this.H=Cb(c)){var e=this.H.exports;if(e){var f=e.connect;f&&f.call(this.H,this.P);if(this.ba=e.receiveData){this.P=a;this.U=e.receiveStatus;this.status("Connected "+this.de+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; -l.$b=function(a,b){if(!b)if(this.uj(this.P),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Zb=function(a){return a?this.save():!0};l.reset=function(){Pu(this)};l.save=function(){var a=new ag(this),b=0,c=[];c[b++]=this.fa;c[b++]=this.ka;c[b++]=this.I;c[b++]=this.M;c[b++]=this.F;c[b++]=this.D;c[b++]=this.aa;c[b++]=this.A;c[b++]=this.B;c[b]=this.J;a.set(0,c);return a.data()};l.restore=function(a){return Pu(this,a[0])}; -function Pu(a,b){var c=0;void 0===b&&(b=[0,0,Qu,0,Ru,0,0,Lu|Mu,a.ra,[]]);a.fa=b[c++];a.ka=b[c++];a.I=b[c++];a.M=b[c++];a.F=b[c++];a.D=b[c++];a.aa=b[c++];a.A=b[c++];a.B=b[c++];a.J=b[c];return!0}l.We=function(a){if(null!=a)if("number"==typeof a)this.J.push(a);else if("string"==typeof a)for(var b=0;b>8:this.M;t(this,a,null,b,this.D&Xu?"DLM":"IER",c);return c}; -l.qm=function(a,b){var c=this.F;this.F|=Ru;t(this,a,null,b,"IIR",c);return c};l.rm=function(a,b){var c=this.D;t(this,a,null,b,"LCR",c);return c};l.tm=function(a,b){var c=this.aa;t(this,a,null,b,"MCR",c);return c};l.sm=function(a,b){var c=this.A;t(this,a,null,b,"LSR",c);return c};l.ym=function(a,b){var c=this.B;this.B&=~(Tu|Uu);t(this,a,null,b,"MSR",c);return c}; -l.so=function(a,b,c){t(this,a,b,c,this.D&Xu?"DLL":"THR");if(this.D&Xu)this.I=this.I&-256|b;else{this.ka=b;this.A&=~(Lu|Mu);Tb(this,"transmitByte("+va(b)+")");this.ba&&this.ba.call(this.H,b);if(this.C){if(13==b)this.L=0;else if(8==b)this.C.value=this.C.value.slice(0,-1),0":String.fromCharCode(b);c=a.length;32>b&&1==c&&(c=0);9==b&&(c=this.pa||8,c-=this.L%c,this.pa&&(a=Ca("",c)));!this.L&&c&&(10!=this.qa&&(a="\n"+a),this.la&&(a=String.fromCharCode(this.la)+ -a));this.C.value+=a;this.C.scrollTop=this.C.scrollHeight;this.L+=c}this.qa=b}else if(null!=this.K){if(10==b||1024<=this.K.length)this.O(this.K),this.K="";10!=b&&(this.K+=String.fromCharCode(b))}this.G&&Pd(this.G,this.wa,1E3/(1843200/((this.I||1)<<7))|0);Vu(this)}};l.eo=function(a,b,c){t(this,a,b,c,this.D&Xu?"DLM":"IER");this.D&Xu?this.I=this.I&255|b<<8:this.M=b};l.fo=function(a,b,c){t(this,a,b,c,"LCR");this.D=b}; -l.ho=function(a,b,c){var d=b^this.aa;t(this,a,b,c,"MCR");this.aa=b;d&(Yu|Zu)&&this.U&&(a=0,this.P?(a|=b&Zu?32:0,a|=b&Yu?320:0):(a|=b&Zu?16:0,a|=b&Yu?1048576:0),this.U.call(this.H,a))};function Vu(a){var b=-1;a.A&Wu&&a.M&$u?b=av:a.A&Lu&&a.M&bv?b=cv:a.B&(Tu|Uu)&&a.M&dv&&(b=ev);0<=b?(a.F&=~(Ru|fv),a.F|=b,a.V&&a.N&&mh(a.V,a.N,100)):(a.F|=Ru,a.V&&a.N&&Zg(a.V,a.N))} -var Ku="buffer",Qu=384,$u=1,bv=2,dv=8,Ru=1,av=4,cv=2,ev=0,fv=6,Xu=128,Yu=1,Zu=2,Wu=1,Lu=32,Mu=64,Tu=1,Uu=2,Iu=16,Ju=32,Nu={0:Hu.prototype.Dm,1:Hu.prototype.pm,2:Hu.prototype.qm,3:Hu.prototype.rm,4:Hu.prototype.tm,5:Hu.prototype.sm,6:Hu.prototype.ym},Ou={0:Hu.prototype.so,1:Hu.prototype.eo,3:Hu.prototype.fo,4:Hu.prototype.ho};cb(function(){for(var a=zb(document,"pcx86","serial"),b=0;b=b)a.preventDefault&&a.preventDefault(),64");if(2==c.length){var d=Da(c[0]);if(d!=this.ye)return;c=Da(c[1]);if(this.H=Cb(c)){var e=this.H.exports;if(e){var f=e.connect;f&&f.call(this.H,this.P);if(this.ba=e.receiveData){this.P=a;this.U=e.receiveStatus;this.status("Connected "+this.de+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; +l.$b=function(a,b){if(!b)if(this.vj(this.P),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Zb=function(a){return a?this.save():!0};l.reset=function(){Pu(this)};l.save=function(){var a=new ag(this),b=0,c=[];c[b++]=this.fa;c[b++]=this.ka;c[b++]=this.I;c[b++]=this.M;c[b++]=this.F;c[b++]=this.D;c[b++]=this.Z;c[b++]=this.A;c[b++]=this.B;c[b]=this.J;a.set(0,c);return a.data()};l.restore=function(a){return Pu(this,a[0])}; +function Pu(a,b){var c=0;void 0===b&&(b=[0,0,Qu,0,Ru,0,0,Lu|Mu,a.ra,[]]);a.fa=b[c++];a.ka=b[c++];a.I=b[c++];a.M=b[c++];a.F=b[c++];a.D=b[c++];a.Z=b[c++];a.A=b[c++];a.B=b[c++];a.J=b[c];return!0}l.Xe=function(a){if(null!=a)if("number"==typeof a)this.J.push(a);else if("string"==typeof a)for(var b=0;b>8:this.M;t(this,a,null,b,this.D&Xu?"DLM":"IER",c);return c}; +l.rm=function(a,b){var c=this.F;this.F|=Ru;t(this,a,null,b,"IIR",c);return c};l.sm=function(a,b){var c=this.D;t(this,a,null,b,"LCR",c);return c};l.um=function(a,b){var c=this.Z;t(this,a,null,b,"MCR",c);return c};l.tm=function(a,b){var c=this.A;t(this,a,null,b,"LSR",c);return c};l.zm=function(a,b){var c=this.B;this.B&=~(Tu|Uu);t(this,a,null,b,"MSR",c);return c}; +l.to=function(a,b,c){t(this,a,b,c,this.D&Xu?"DLL":"THR");if(this.D&Xu)this.I=this.I&-256|b;else{this.ka=b;this.A&=~(Lu|Mu);Tb(this,"transmitByte("+va(b)+")");this.ba&&this.ba.call(this.H,b);if(this.C){if(13==b)this.L=0;else if(8==b)this.C.value=this.C.value.slice(0,-1),0":String.fromCharCode(b);c=a.length;32>b&&1==c&&(c=0);9==b&&(c=this.pa||8,c-=this.L%c,this.pa&&(a=Ca("",c)));!this.L&&c&&(10!=this.qa&&(a="\n"+a),this.la&&(a=String.fromCharCode(this.la)+ +a));this.C.value+=a;this.C.scrollTop=this.C.scrollHeight;this.L+=c}this.qa=b}else if(null!=this.K){if(10==b||1024<=this.K.length)this.O(this.K),this.K="";10!=b&&(this.K+=String.fromCharCode(b))}this.G&&Pd(this.G,this.wa,1E3/(1843200/((this.I||1)<<7))|0);Vu(this)}};l.fo=function(a,b,c){t(this,a,b,c,this.D&Xu?"DLM":"IER");this.D&Xu?this.I=this.I&255|b<<8:this.M=b};l.ho=function(a,b,c){t(this,a,b,c,"LCR");this.D=b}; +l.io=function(a,b,c){var d=b^this.Z;t(this,a,b,c,"MCR");this.Z=b;d&(Yu|Zu)&&this.U&&(a=0,this.P?(a|=b&Zu?32:0,a|=b&Yu?320:0):(a|=b&Zu?16:0,a|=b&Yu?1048576:0),this.U.call(this.H,a))};function Vu(a){var b=-1;a.A&Wu&&a.M&$u?b=av:a.A&Lu&&a.M&bv?b=cv:a.B&(Tu|Uu)&&a.M&dv&&(b=ev);0<=b?(a.F&=~(Ru|fv),a.F|=b,a.V&&a.N&&mh(a.V,a.N,100)):(a.F|=Ru,a.V&&a.N&&Zg(a.V,a.N))} +var Ku="buffer",Qu=384,$u=1,bv=2,dv=8,Ru=1,av=4,cv=2,ev=0,fv=6,Xu=128,Yu=1,Zu=2,Wu=1,Lu=32,Mu=64,Tu=1,Uu=2,Iu=16,Ju=32,Nu={0:Hu.prototype.Em,1:Hu.prototype.qm,2:Hu.prototype.rm,3:Hu.prototype.sm,4:Hu.prototype.um,5:Hu.prototype.tm,6:Hu.prototype.zm},Ou={0:Hu.prototype.to,1:Hu.prototype.fo,3:Hu.prototype.ho,4:Hu.prototype.io};cb(function(){for(var a=zb(document,"pcx86","serial"),b=0;ba.A||0>a.B)a.A=b.screenX,a.B=b.screenY;a.N?(c=b.movementX||b.mozMovementX||b.webkitMovementX||0,d=b.movementY||b.mozMovementY||b.webkitMovementY||0):(c=b.screenX-a.A,d=b.screenY-a.B);a.A=b.screenX;a.B=b.screenY;a.rf(c,d,a.A,a.B)}} -l.Xd=function(a,b){if(this.rc&&this.G&&this.G.Z.Xa){var c="mouse button"+a+" "+(b?"dn":"up");switch(a){case Ss:if(this.L!=b){this.L=b;rv(this,c);return}break;case sv:if(this.M!=b){this.M=b;rv(this,c);return}}Tb(this,c+": ignored")}};l.rf=function(a,b,c,d){this.rc&&this.G&&this.G.Z.Xa&&(a=Math.round(Math.abs(a)*this.K)*Math.sign(a)||Math.sign(a),b=Math.round(Math.abs(b)*this.K)*Math.sign(b)||Math.sign(b),a||b)&&(r(this,16777216)&&Tb(this,"moveMouse("+a+","+b+")"),this.I=a,this.J=b,rv(this,null,c,d))}; -function rv(a,b,c,d){var e=64|(a.L?32:0)|(a.M?16:0)|(a.J&192)>>4|(a.I&192)>>6,f=a.I&63,g=a.J&63;r(a,8388608)&&Tb(a,(b?b+": ":"")+(void 0!==d?"mouse ("+c+","+d+"): ":"")+"serial packet ["+va(e)+","+va(f)+","+va(g)+"]",0,!0);a.F.We([e,f,g]);a.I=a.J=0} -l.hl=function(a){var b=1048592==(a&1048592);if(b){if(!this.rc){var c=!1;this.C&16||(this.reset(),Tb(this,"serial mouse reset"),c=!0);this.C&1048576||(Tb(this,"serial mouse ID requested"),c=!0);c&&(this.F.We([tv,tv]),Tb(this,"serial mouse ID sent"));mv(this);this.rc=b}}else this.rc&&(Tb(this,"serial mouse inactive"),nv(this),this.rc=b);this.C=a};l.Wl=function(a,b){t(this,a,null,b,"DATA",0);return 0};l.Xl=function(a,b){t(this,a,null,b,"TPPI",0);return 0}; -l.Vl=function(a,b){t(this,a,null,b,"CTRL",0);return 0};l.Ul=function(a,b){t(this,a,null,b,"CPPI",0);return 0};l.Hn=function(a,b,c){t(this,a,b,c,"DATA")};l.In=function(a,b,c){t(this,a,b,c,"TPPI")};l.Gn=function(a,b,c){t(this,a,b,c,"CTRL")};l.Fn=function(a,b,c){t(this,a,b,c,"CPPI")};var iv="bus",hv="serial",Ss=0,sv=2,kv=572,jv={0:gv.prototype.Wl,1:gv.prototype.Xl,2:gv.prototype.Vl,3:gv.prototype.Ul},lv={0:gv.prototype.Hn,1:gv.prototype.In,2:gv.prototype.Gn,3:gv.prototype.Fn},tv=77; -cb(function(){for(var a=zb(document,"pcx86","mouse"),b=0;ba.A||0>a.B)a.A=b.screenX,a.B=b.screenY;a.N?(c=b.movementX||b.mozMovementX||b.webkitMovementX||0,d=b.movementY||b.mozMovementY||b.webkitMovementY||0):(c=b.screenX-a.A,d=b.screenY-a.B);a.A=b.screenX;a.B=b.screenY;a.sf(c,d,a.A,a.B)}} +l.Xd=function(a,b){if(this.rc&&this.G&&this.G.aa.Xa){var c="mouse button"+a+" "+(b?"dn":"up");switch(a){case Ss:if(this.L!=b){this.L=b;rv(this,c);return}break;case sv:if(this.M!=b){this.M=b;rv(this,c);return}}Tb(this,c+": ignored")}}; +l.sf=function(a,b,c,d){this.rc&&this.G&&this.G.aa.Xa&&(a=Math.round(Math.abs(a)*this.K)*Math.sign(a)||Math.sign(a),b=Math.round(Math.abs(b)*this.K)*Math.sign(b)||Math.sign(b),a||b)&&(r(this,16777216)&&Tb(this,"moveMouse("+a+","+b+")"),this.I=a,this.J=b,rv(this,null,c,d))}; +function rv(a,b,c,d){var e=64|(a.L?32:0)|(a.M?16:0)|(a.J&192)>>4|(a.I&192)>>6,f=a.I&63,g=a.J&63;r(a,8388608)&&Tb(a,(b?b+": ":"")+(void 0!==d?"mouse ("+c+","+d+"): ":"")+"serial packet ["+va(e)+","+va(f)+","+va(g)+"]",0,!0);a.F.Xe([e,f,g]);a.I=a.J=0} +l.il=function(a){var b=1048592==(a&1048592);if(b){if(!this.rc){var c=!1;this.C&16||(this.reset(),Tb(this,"serial mouse reset"),c=!0);this.C&1048576||(Tb(this,"serial mouse ID requested"),c=!0);c&&(this.F.Xe([tv,tv]),Tb(this,"serial mouse ID sent"));mv(this);this.rc=b}}else this.rc&&(Tb(this,"serial mouse inactive"),nv(this),this.rc=b);this.C=a};l.Xl=function(a,b){t(this,a,null,b,"DATA",0);return 0};l.Yl=function(a,b){t(this,a,null,b,"TPPI",0);return 0}; +l.Wl=function(a,b){t(this,a,null,b,"CTRL",0);return 0};l.Vl=function(a,b){t(this,a,null,b,"CPPI",0);return 0};l.In=function(a,b,c){t(this,a,b,c,"DATA")};l.Jn=function(a,b,c){t(this,a,b,c,"TPPI")};l.Hn=function(a,b,c){t(this,a,b,c,"CTRL")};l.Gn=function(a,b,c){t(this,a,b,c,"CPPI")};var iv="bus",hv="serial",Ss=0,sv=2,kv=572,jv={0:gv.prototype.Xl,1:gv.prototype.Yl,2:gv.prototype.Wl,3:gv.prototype.Vl},lv={0:gv.prototype.In,1:gv.prototype.Jn,2:gv.prototype.Hn,3:gv.prototype.Gn},tv=77; +cb(function(){for(var a=zb(document,"pcx86","mouse"),b=0;b>2;var e=c=0;a=new DataView(a,0,b);g.A=Array(g.sb);for(b=0;bb.indexOf("/api/v1/dump")&&(a=ya(b),"json"==a||"gz"==a?f=encodeURI(b):"demandrw"==this.mode||"demandro"==this.mode?(f=Av(this,b),this.jg=!0):(c="path",d="&mbhd=10",!b.indexOf("http:")||!b.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(a)?(c="disk",d="&mbhd=0"): -za(b,"/")&&(c="dir"),f=Na()+"/api/v1/dump?"+c+"="+encodeURIComponent(b)+(this.Le?"":d)+"&format=json"));var k="Loading "+f+"...";return!!Ma(f,null,!0,function(a,b,c){Bv(g,a,b,c)},function(){g.O(k,Kb)})}; -function Bv(a,b,c,d){var e=null;a.Oe=!1;var f=!(!(0>d&&a.na)||a.na.Z.ac);if(a.jg)d?a.Da('Unable to connect to disk "'+a.H+'" (error '+d+": "+c+")",f):(a.D=!0,Cv(a),e=a);else if(d)a.Da('Unable to load disk "'+a.jd+'" (error '+d+": "+b+")",f);else{rb(a.controller.de,b,c);try{if(0g&&0c.indexOf("0x")&& +l.load=function(a,b,c,d,e){var f=b;if(this.J)return!0;this.jd=a;this.H=b;this.Gg=xa(b);var g=this;this.J=d;this.P=e||this.controller;if(c){var h=new FileReader;h.onload=function(){var a=h.result,b=a?a.byteLength:0,c=ma[b];if(c){g.sb=c[0];g.gb=c[1];g.Wa=c[2];g.Na=c[3]||512;var d=g.Na>>2;var e=c=0;a=new DataView(a,0,b);g.A=Array(g.sb);for(b=0;bb.indexOf("/api/v1/dump")&&(a=ya(b),"json"==a||"gz"==a?f=encodeURI(b):"demandrw"==this.mode||"demandro"==this.mode?(f=Av(this,b),this.kg=!0):(c="path",d="&mbhd=10",!b.indexOf("http:")||!b.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(a)?(c="disk",d="&mbhd=0"): +za(b,"/")&&(c="dir"),f=Na()+"/api/v1/dump?"+c+"="+encodeURIComponent(b)+(this.Me?"":d)+"&format=json"));var k="Loading "+f+"...";return!!Ma(f,null,!0,function(a,b,c){Bv(g,a,b,c)},function(){g.O(k,Kb)})}; +function Bv(a,b,c,d){var e=null;a.Pe=!1;var f=!(!(0>d&&a.na)||a.na.aa.ac);if(a.kg)d?a.Da('Unable to connect to disk "'+a.H+'" (error '+d+": "+c+")",f):(a.D=!0,Cv(a),e=a);else if(d)a.Da('Unable to load disk "'+a.jd+'" (error '+d+": "+b+")",f);else{rb(a.controller.de,b,c);try{if(0g&&0c.indexOf("0x")&& '["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+c+")");if(h.length)if(1==h.length)kb(h[0]);else{a.sb=h.length;a.gb=h[0].length;a.Wa=h[0][0].length;var k=h[0][0][0];a.Na=k&&k.length||512;for(d=c=0;d>=2;var p=k.pattern;void 0===p&&(p=k.pattern=0);var v=k.data;if(void 0===v){var u=k.bytes;if(void 0!==u&&u.length){for(var A=m<<2,J=u.length;J< A;J++)u[J]=p;Dv(k,u,0)}else k.data=v=[],u&&(k.pattern=p|p<<8|p<<16|p<<24);delete k.bytes}zv(k,d,f);for(A=0;Ae;e++){if(128==Fv(a,d,b+0,1)){c.Hf=Fv(a,d,b+8,4);(d=Ev(a,c.Hf))&&(f=!0);break}b+=16}if(!f)return}c.qf||(c.qf=Fv(a,d,19,2)||Fv(a,d,32,4),c.pf=Fv(a,d,14,2),c.ih=c.pf+Fv(a,d,22,2)*Fv(a,d,16,1),c.qh=Fv(a,d,17,2),c.uf=Fv(a,d,13,1));c.gh=c.ih+((32*c.qh+(c.Na-1))/c.Na|0);c.fn=(c.qf-c.gh)/c.uf|0;c.rg=4084>=c.fn?12:16;c.Dl=12==c.rg?4086:65526;e=[];for(d=c.ih;d>=8;f+=2;if(m)for(;k--;)Tv(c,f,1),254>=m?(p=m,u=Tv(c,f+1),f+=3):(p=Tv(c,f+3,1),u=Tv(c,f+4),f+=6),c.fe[p]&&(c.fe[p].hf[h]=[u]),c.A[h]=[p,u],h++;else h+=k}(g=Iv(d,Wv,b))&&Xv(d,g+b);g=Iv(d,Yv,b);h=Iv(d,Zv,b);g&&h&&Xv(d,g,g+h)}}}} -function Hv(a,b,c,d,e){var f=a.C.length,g=b.Na/32|0;b.pq=d+"\\";for(var h=0;hJ)break;for(var H=v.gh+(J-2)*v.uf,G=0;G>3,1),d?e=16==b.rg?e<<8:c&7?e<<4:(e&15)<<8:c&7&&(e>>=4));return e} -function Ev(a,b){var c=a.gb*a.Wa,d=b/c|0;return dg)break;e|=g<=f)break;e+=String.fromCharCode(f)}return e}function zv(a,b,c,d,e,f){a||(a={sector:d,length:e,data:[],pattern:f});a.El=b;a.Fl=c;a.gd=a.Nc=0;a.Oa=!1;return a} +function Cv(a){var b,c={},d;if(a.C&&a.C.length){var e=a.A;for(b=0;be;e++){if(128==Fv(a,d,b+0,1)){c.If=Fv(a,d,b+8,4);(d=Ev(a,c.If))&&(f=!0);break}b+=16}if(!f)return}c.rf||(c.rf=Fv(a,d,19,2)||Fv(a,d,32,4),c.qf=Fv(a,d,14,2),c.jh=c.qf+Fv(a,d,22,2)*Fv(a,d,16,1),c.sh=Fv(a,d,17,2),c.vf=Fv(a,d,13,1));c.hh=c.jh+((32*c.sh+(c.Na-1))/c.Na|0);c.gn=(c.rf-c.hh)/c.vf|0;c.sg=4084>=c.gn?12:16;c.El=12==c.sg?4086:65526;e=[];for(d=c.jh;d>=8;f+=2;if(m)for(;k--;)Tv(c,f,1),254>=m?(p=m,u=Tv(c,f+1),f+=3):(p=Tv(c,f+3,1),u=Tv(c,f+4),f+=6),c.fe[p]&&(c.fe[p].jf[h]=[u]),c.A[h]=[p,u],h++;else h+=k}(g=Iv(d,Wv,b))&&Xv(d,g+b);g=Iv(d,Yv,b);h=Iv(d,Zv,b);g&&h&&Xv(d,g,g+h)}}}} +function Hv(a,b,c,d,e){var f=a.C.length,g=b.Na/32|0;b.qq=d+"\\";for(var h=0;hJ)break;for(var H=v.hh+(J-2)*v.vf,G=0;G>3,1),d?e=16==b.sg?e<<8:c&7?e<<4:(e&15)<<8:c&7&&(e>>=4));return e} +function Ev(a,b){var c=a.gb*a.Wa,d=b/c|0;return dg)break;e|=g<=f)break;e+=String.fromCharCode(f)}return e}function zv(a,b,c,d,e,f){a||(a={sector:d,length:e,data:[],pattern:f});a.Fl=b;a.Gl=c;a.gd=a.Nc=0;a.Oa=!1;return a} function Av(a,b){b="action=open&volume="+b+("&mode="+a.mode);b+="&chs="+a.sb+":"+a.gb+":"+a.Wa+":"+a.Na;b+="&machine="+xv(a.controller);b+="&user="+yv(a.controller);return Na()+"/api/v1/disk?"+b} function bw(a,b,c,d,e,f,g){if(a.D){var h="action=read&volume="+a.H;h+="&chs="+a.sb+":"+a.gb+":"+a.Wa+":"+a.Na;h=h+("&addr="+b+":"+c+":"+d+":"+e)+("&machine="+xv(a.controller));h+="&user="+yv(a.controller);Ma(Na()+"/api/v1/disk?"+h,null,f,function(h,m,p){h=[b,c,d,e,f,g];var k=!1,u=h[0],A=h[1],J=h[2],H=h[3];if(!p){m=JSON.parse(m);for(k=0;H--;){var G=a.seek(u,A,J,!0);if(!G)break;Dv(G,m,k);k+=G.length;J++}k=h[4]}(h=h[5])&&h(p,k)})}else g&&g(-1,!1)} function cw(a,b,c,d,e,f,g){if(a.D){var h={};a.M=!0;h.action="write";h.volume=a.H;h.chs=a.sb+":"+a.gb+":"+a.Wa+":"+a.Na;h.addr=b+":"+c+":"+d+":"+e;h.machine=xv(a.controller);h.user=yv(a.controller);h.data=JSON.stringify(f);Ma(Na()+"/api/v1/disk",h,g,function(f,h,p){var k=[b,c,d,e,g];f=k[0];h=k[1];var m=k[2],A=k[3];k=k[4];a.M=!1;if(0<=f&&fb&&(b=0);2E3>2,e=Array(d),f=0;f>=2;var e=a.data;a=a.pattern;for(var f=0;f>8&255;c[d++]=g>>16&255;c[d++]=g>>24&255}return c}l.read=function(a,b){var c=-1;if(a&&b>2;c=(d>((b&3)<<3)&255}return c}; -l.write=function(a,b,c){if(this.Oe)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.Nc?f=a.gd+a.Nc&&(a.Nc+=f-(a.gd+a.Nc)+1):(a.gd=f,a.Nc=1);d[f]=d[f]&~(255<>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.Nc?f=a.gd+a.Nc&&(a.Nc+=f-(a.gd+a.Nc)+1):(a.gd=f,a.Nc=1);d[f]=d[f]&~(255<=this.A.length||k>=this.A[h].length||m>=this.A[h][k].length){c="sector (CHS="+h+":"+k+":"+ -m+") out of range ("+b+" changes applied)";b=-1;break}if(this.Oe){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(h=this.A[h][k][m]){for(k=h.data.length;kb?-2!=b&&this.Da("Unable to restore disk '"+this.jd+": "+c):Cv(this);return b}; +m+") out of range ("+b+" changes applied)";b=-1;break}if(this.Pe){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(h=this.A[h][k][m]){for(k=h.data.length;kb?-2!=b&&this.Da("Unable to restore disk '"+this.jd+": "+c):Cv(this);return b}; function hw(a){for(var b=0,c;c=Ev(a,b++);)iw(c);a=JSON.stringify(a.A,function(a,b){if("file"!=a)return b});a=a.replace(/,"length":512/g,"").replace(/,"pattern":0/g,"").replace(/,"data":\[]/g,"");a=a.replace(/"(sector|length|data|pattern)":/g,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/g,"");return a=a.replace(/(sector|length|data|pattern):/g,'"$1":')}function iw(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}var vv=0; -function aw(a,b,c,d,e){this.va=a;this.hc=b;this.Sg=c;this.Xi=d;this.ge=e}function Tv(a,b,c){var d;c=c||2;var e=b&511,f=Ev(a.va,a.ge[b>>9]);if(f){if(e+c<=f.length)return Fv(a.va,f,e,c);for(e=d=0;c--;)d|=Tv(a,b++,1)<>9]);if(f){if(e+c<=f.length)return Fv(a.va,f,e,c);for(e=d=0;c--;)d|=Tv(a,b++,1)<g.va.restore(A)&&(h=!1);h&&g.va&&void 0!==g.Va&&(g.hb=g.va.seek(g.Ib,g.bb,g.jb));h||(d=!1)}a.H=b[c++]||0;a.bc=b[c]||Aw;return d} -function uw(a){var b=0,c=[];c[b++]=a.Ya;c[b++]=0;c[b++]=a.ga;c[b++]=a.F;c[b++]=a.D;c[b++]=a.C;c[b++]=a.I;for(var d=b++,e=0,f=[],g=0;gg.va.restore(A)&&(h=!1);h&&g.va&&void 0!==g.Va&&(g.hb=g.va.seek(g.Ib,g.bb,g.jb));h||(d=!1)}a.H=b[c++]||0;a.bc=b[c]||Aw;return d} +function uw(a){var b=0,c=[];c[b++]=a.Ya;c[b++]=0;c[b++]=a.ga;c[b++]=a.F;c[b++]=a.D;c[b++]=a.C;c[b++]=a.I;for(var d=b++,e=0,f=[],g=0;gyw(a,e,b,c,!1,d);){if(!window.confirm("Click OK to reload the original disk and discard any changes."))return!1;var g=a,h=c;for(f=0;fa.sb||f[1]>a.gb)this.Da('Diskette "'+c+'" too large for drive '+String.fromCharCode(65+a.Ya)),b=null}b?(a.va=b,a.Tk=c,a.ue=d,Dw(this,d)||rw(this,c,d),zw(this,c,d,b),f=b.info(),this.H|=Ew,a.Pe||this.Da('Mounted diskette "'+c+'" in drive '+String.fromCharCode(65+a.Ya),a.ke||e),a.qg=f[0],a.wf=f[1],a.xf=f[2],this.na&&this.na.cd()):a.Ke=!1;a.ke&&(a.ke=!1,--this.K||Pb(this));mw(this,a.Ya);a.Pe&&(a.Pe(),a.Pe=null)}; +e,!1,!0)}return!0}a.Da("Unable to load the selected drive");return!1}function yw(a,b,c,d,e,f){var g=a.A[b];if(d&&(d=d.replace("/disks/pc/","/disks/pcx86/"),g.ue.toLowerCase()!=d.toLowerCase())){tw(a,b,e,!0);if(g.le)return a.Da("Drive "+b+" busy"),0;g.le=!0;e&&(g.ke=!0,a.K++,r(a)&&Tb(a,"loading diskette '"+c+"'"));g.Le=!!f;return(new uv(a,g,"preload")).load(c,d,f,a.ij)?1:0}return-1} +l.ij=function(a,b,c,d,e){a.le=!1;if(b){var f=b.info();if(b&&f[0]>a.sb||f[1]>a.gb)this.Da('Diskette "'+c+'" too large for drive '+String.fromCharCode(65+a.Ya)),b=null}b?(a.va=b,a.Uk=c,a.ue=d,Dw(this,d)||rw(this,c,d),zw(this,c,d,b),f=b.info(),this.H|=Ew,a.Qe||this.Da('Mounted diskette "'+c+'" in drive '+String.fromCharCode(65+a.Ya),a.ke||e),a.rg=f[0],a.xf=f[1],a.yf=f[2],this.na&&this.na.cd()):a.Le=!1;a.ke&&(a.ke=!1,--this.K||Pb(this));mw(this,a.Ya);a.Qe&&(a.Qe(),a.Qe=null)}; function rw(a,b,c,d){if((a=a.ma.listDisks)&&a.options){for(var e=0;e'+a+"");c.innerHTML=a}}l.Yo=function(a){for(var b=0;b=this.C&&(this.ga&=~(Hw|Iw),this.D=this.C=0);return c}; -l.Wn=function(a,b,c){r(this)&&t(this,a,b,c,"DATA["+this.C+"]");this.C=Kw[a].Jd){b=!1;this.D=0;a=Lw(this);var d=a&Jw;switch(d){case Mw:Lw(this);Lw(this);Nw(this);break;case Ow:c=Lw(this);this.Ya=c&3;var e=this.A[this.Ya];Nw(this);Pw(this,(e.tb&Qw)>>>24);break;case Rw:case Sw:c=Lw(this);b=c>>2&1;this.Ya=c&3;e=this.A[this.Ya];e.bb=b;c=e.Ib=Lw(this);var f=Lw(this);var g=e.jb=Lw(this);var h=Lw(this);e.yb=128<>2& -1;this.Ya=c&3;e=this.A[this.Ya];c=e.Ib;f=e.bb=b;g=e.jb=1;h=0;e.tb=Cw;e.va&&(e.hb=e.va.seek(e.Ib,e.bb,e.jb))?h=e.hb.length>>8:e.tb=Tw|Uw;Ww(this,e,a,b,c,f,g,h);b=!0;break;case cx:c=Lw(this);b=c>>2&1;this.Ya=c&3;e=this.A[this.Ya];c=e.Ib;f=e.bb=b;g=1;h=Lw(this);e.yb=128<>2&1,c=Lw(this),e.Ib+=c-e.Ud,0>e.Ib&&(e.Ib=0),e.Ib>=e.sb&&(e.Ib=e.sb-1),e.Ud=c,e.tb=Yw,e.Ib||(e.tb|=Zw),Nw(this),b=!0}0>>8);Pw(a,(b.tb&fx)>>>16);var k=0;if(e!=b.Ib||f!=b.bb)k=g=1;c&gx&&(f^=k,d||(k=0));Pw(a,e+k);Pw(a,f);Pw(a,g);Pw(a,h)}function Lw(a){var b=a.F[a.D];a.D++;return b}function Nw(a){a.D=a.C=0}function Pw(a,b){a.F[a.C++]=b}l.bl=function(a,b,c){void 0===b||0>b?this.te(a,c):c(-1,!1)};l.cl=function(a,b){return void 0!==b&&0<=b?hx(a,b):-1}; -l.tl=function(a,b){if(void 0!==b&&0<=b)a:if(a.tb)a=-1;else{a.Xc[a.Ge++]=b;if(a.Ge==a.Xc.length){a.Ib=a.Xc[0];a.bb=a.Xc[1];a.jb=a.Xc[2];a.yb=128<hx(a,a.Ti)){a=-1;break a}a.dg++}a.dg>=a.Vd&&(b=-1);a=b}else a=-1;return a};l.te=function(a,b){var c=-1,d=null,e=0;if(!a.tb&&a.va){do{if(a.hb&&(e=a.Va,0<=(c=a.va.read(a.hb,a.Va++)))){d=a.hb;break}a.hb=a.va.seek(a.Ib,a.bb,a.jb);if(!a.hb){a.tb=ix|Uw;break}a.Va=0;jx(a)}while(1)}b(c,!1,d,e)}; -function hx(a,b){if(a.tb||!a.va)return-1;do{if(a.hb&&a.va.write(a.hb,a.Va++,b))break;a.hb=a.va.seek(a.Ib,a.bb,a.jb);if(!a.hb){a.tb=kx|Uw;b=-1;break}a.Va=0;jx(a)}while(1);return b}function jx(a){a.jb++;a.jb>=a.xf+1&&(a.jb=1,a.bb++,a.bb>=a.wf&&(a.bb=0,a.Ib++))}var xw="Floppy Drive",Fw=4,Gw=8,Iw=16,Hw=64,vw=128,Mw=3,Ow=4,Rw=5,Sw=6,Xw=7,$w=8,bx=10,cx=13,dx=15,Jw=31,gx=128,Cw=0,Tw=8,Yw=32,Uw=64,ww=192,ax=255,Vw=512,ix=1024,kx=8192,ex=65280,fx=16711680,Zw=268435456,Qw=-16777216,Ew=128,Aw=0;aa={}; -var Kw={3:{Jd:3,Wd:0,name:aa.cq},4:{Jd:2,Wd:1,name:aa.aq},5:{Jd:9,Wd:7,name:aa.hq},6:{Jd:9,Wd:7,name:aa.Xp},7:{Jd:2,Wd:0,name:aa.Zp},8:{Jd:1,Wd:2,name:aa.bq},10:{Jd:2,Wd:7,name:aa.Yp},13:{Jd:6,Wd:7,name:aa.Up},15:{Jd:3,Wd:0,name:aa.$p}},pw={1009:jw.prototype.km,1012:jw.prototype.mm,1013:jw.prototype.jm,1015:jw.prototype.lm},qw={1010:jw.prototype.Xn,1013:jw.prototype.Wn,1015:jw.prototype.Vn}; -cb(function(){for(var a=zb(document,"pcx86","fdc"),b=0;bk.va.restore(g)&&(A=!1),A&&void 0!==k.Va&&(k.hb=k.va.seek(k.Od,k.bb,k.jb+k.cg)));A||(e=!1);null!=a.P&&1>=d&&(a.P|=(f.type&3)<<(1-d<< +function mw(a,b){if(0<=b&&b'+a+"");c.innerHTML=a}}l.Zo=function(a){for(var b=0;b=this.C&&(this.ga&=~(Hw|Iw),this.D=this.C=0);return c}; +l.Xn=function(a,b,c){r(this)&&t(this,a,b,c,"DATA["+this.C+"]");this.C=Kw[a].Jd){b=!1;this.D=0;a=Lw(this);var d=a&Jw;switch(d){case Mw:Lw(this);Lw(this);Nw(this);break;case Ow:c=Lw(this);this.Ya=c&3;var e=this.A[this.Ya];Nw(this);Pw(this,(e.tb&Qw)>>>24);break;case Rw:case Sw:c=Lw(this);b=c>>2&1;this.Ya=c&3;e=this.A[this.Ya];e.bb=b;c=e.Ib=Lw(this);var f=Lw(this);var g=e.jb=Lw(this);var h=Lw(this);e.yb=128<>2& +1;this.Ya=c&3;e=this.A[this.Ya];c=e.Ib;f=e.bb=b;g=e.jb=1;h=0;e.tb=Cw;e.va&&(e.hb=e.va.seek(e.Ib,e.bb,e.jb))?h=e.hb.length>>8:e.tb=Tw|Uw;Ww(this,e,a,b,c,f,g,h);b=!0;break;case cx:c=Lw(this);b=c>>2&1;this.Ya=c&3;e=this.A[this.Ya];c=e.Ib;f=e.bb=b;g=1;h=Lw(this);e.yb=128<>2&1,c=Lw(this),e.Ib+=c-e.Ud,0>e.Ib&&(e.Ib=0),e.Ib>=e.sb&&(e.Ib=e.sb-1),e.Ud=c,e.tb=Yw,e.Ib||(e.tb|=Zw),Nw(this),b=!0}0>>8);Pw(a,(b.tb&fx)>>>16);var k=0;if(e!=b.Ib||f!=b.bb)k=g=1;c&gx&&(f^=k,d||(k=0));Pw(a,e+k);Pw(a,f);Pw(a,g);Pw(a,h)}function Lw(a){var b=a.F[a.D];a.D++;return b}function Nw(a){a.D=a.C=0}function Pw(a,b){a.F[a.C++]=b}l.cl=function(a,b,c){void 0===b||0>b?this.te(a,c):c(-1,!1)};l.dl=function(a,b){return void 0!==b&&0<=b?hx(a,b):-1}; +l.ul=function(a,b){if(void 0!==b&&0<=b)a:if(a.tb)a=-1;else{a.Xc[a.He++]=b;if(a.He==a.Xc.length){a.Ib=a.Xc[0];a.bb=a.Xc[1];a.jb=a.Xc[2];a.yb=128<hx(a,a.Ui)){a=-1;break a}a.eg++}a.eg>=a.Vd&&(b=-1);a=b}else a=-1;return a};l.te=function(a,b){var c=-1,d=null,e=0;if(!a.tb&&a.va){do{if(a.hb&&(e=a.Va,0<=(c=a.va.read(a.hb,a.Va++)))){d=a.hb;break}a.hb=a.va.seek(a.Ib,a.bb,a.jb);if(!a.hb){a.tb=ix|Uw;break}a.Va=0;jx(a)}while(1)}b(c,!1,d,e)}; +function hx(a,b){if(a.tb||!a.va)return-1;do{if(a.hb&&a.va.write(a.hb,a.Va++,b))break;a.hb=a.va.seek(a.Ib,a.bb,a.jb);if(!a.hb){a.tb=kx|Uw;b=-1;break}a.Va=0;jx(a)}while(1);return b}function jx(a){a.jb++;a.jb>=a.yf+1&&(a.jb=1,a.bb++,a.bb>=a.xf&&(a.bb=0,a.Ib++))}var xw="Floppy Drive",Fw=4,Gw=8,Iw=16,Hw=64,vw=128,Mw=3,Ow=4,Rw=5,Sw=6,Xw=7,$w=8,bx=10,cx=13,dx=15,Jw=31,gx=128,Cw=0,Tw=8,Yw=32,Uw=64,ww=192,ax=255,Vw=512,ix=1024,kx=8192,ex=65280,fx=16711680,Zw=268435456,Qw=-16777216,Ew=128,Aw=0;aa={}; +var Kw={3:{Jd:3,Wd:0,name:aa.eq},4:{Jd:2,Wd:1,name:aa.bq},5:{Jd:9,Wd:7,name:aa.iq},6:{Jd:9,Wd:7,name:aa.Yp},7:{Jd:2,Wd:0,name:aa.$p},8:{Jd:1,Wd:2,name:aa.cq},10:{Jd:2,Wd:7,name:aa.Zp},13:{Jd:6,Wd:7,name:aa.Vp},15:{Jd:3,Wd:0,name:aa.aq}},pw={1009:jw.prototype.lm,1012:jw.prototype.nm,1013:jw.prototype.km,1015:jw.prototype.mm},qw={1010:jw.prototype.Yn,1013:jw.prototype.Xn,1015:jw.prototype.Wn}; +cb(function(){for(var a=zb(document,"pcx86","fdc"),b=0;bk.va.restore(g)&&(A=!1),A&&void 0!==k.Va&&(k.hb=k.va.seek(k.Od,k.bb,k.jb+k.dg)));A||(e=!1);null!=a.P&&1>=d&&(a.P|=(f.type&3)<<(1-d<< 1))}0<=a.Ya&&(a.B=a.A[a.Ya]);return e} -function tx(a){var b=0,c=[];a.M?(c[b++]=a.I,c[b++]=a.ta,c[b++]=a.J,c[b++]=a.fa,c[b++]=a.ea,c[b++]=a.ba,c[b++]=a.U,c[b++]=a.ga,c[b++]=a.ha,c[b++]=[a.L,a.Ya]):(c[b++]=a.P,c[b++]=a.ga,c[b++]=a.F,c[b++]=a.D,c[b++]=a.C,c[b++]=a.ra,c[b++]=a.pa,c[b++]=a.qa,c[b++]=a.N);for(var d=0,e=[],f=0;f=this.C&&(this.D=this.C=0,this.ga&=~(Cx|Dx|Ex));return c};l.uo=function(a,b,c){t(this,a,b,c,"DATA["+this.C+"]");this.C=a&&(this.ga|=Cx,this.ga&=~Gx,Hx(this))};l.Nm=function(a,b){var c=this.ga;t(this,a,null,b,"STATUS",c);this.D=a.B.Na?(a.ga=Jx,a.te(a.B,function(b){0<=b?(Kx(a),a.V&&a.V.da==zl&&(a.ga=0),a.ga=a.ga|ux|Lx|Mx):(a.ga=Nx,a.I=Ox)},!1)):a.ga=ux|Lx));return d}l.fl=function(a,b){return Ix(this,a,b)|Ix(this,a,b)<<8}; -function Px(a,b,c,d){if(a.B&&a.B.yb>=a.B.Na)if(0>Qx(a.B,c))a.ga=Nx,a.I=Ox;else if(1==a.B.Va||a.B.Va==a.B.Na)r(a,1048832)&&t(a,b,c,d,"DATA["+a.B.Va+"]"),1=a.B.Na&&(a.ga|=Mx))}l.zn=function(a,b,c){Px(this,a,b&255,c);Px(this,a,b>>8&255,c)};l.Pl=function(a,b){var c=this.I;t(this,a,null,b,"ERROR",c);return c};l.En=function(a,b,c){t(this,a,b,c,"WPREC");this.ta=b};l.Rl=function(a,b){var c=this.J;t(this,a,null,b,"SECCNT",c);return c}; -l.Cn=function(a,b,c){t(this,a,b,c,"SECCNT");this.J=b};l.Sl=function(a,b){var c=this.fa;t(this,a,null,b,"SECNUM",c);return c};l.Dn=function(a,b,c){t(this,a,b,c,"SECNUM");this.fa=b};l.Nl=function(a,b){var c=this.ea;t(this,a,null,b,"CYLLO",c);return c};l.yn=function(a,b,c){t(this,a,b,c,"CYLLO");this.ea=b};l.Ml=function(a,b){var c=this.ba;t(this,a,null,b,"CYLHI",c);return c};l.xn=function(a,b,c){t(this,a,b,c,"CYLHI");this.ba=b};l.Ol=function(a,b){var c=this.U;t(this,a,null,b,"DRVHD",c);return c}; -l.An=function(a,b,c){t(this,a,b,c,"DRVHD");this.U=b;this.ga=this.A[this.U&Rx?1:0]?this.ga|ux|Lx:this.ga&~ux};l.Tl=function(a,b){var c=this.ga;t(this,a,null,b,"STATUS",c);this.ga&ux&&(this.ga&=~Jx);return c};l.wn=function(a,b,c){t(this,a,b,c,"COMMAND");this.ha=b;this.V&&Zg(this.V,14);Sx(this)};l.Bn=function(a,b,c){t(this,a,b,c,"FDR");this.L&Tx&&!(b&Tx)&&(this.I=Ux);this.L=b}; +function tx(a){var b=0,c=[];a.M?(c[b++]=a.I,c[b++]=a.ta,c[b++]=a.J,c[b++]=a.fa,c[b++]=a.ea,c[b++]=a.ba,c[b++]=a.U,c[b++]=a.ga,c[b++]=a.ha,c[b++]=[a.L,a.Ya]):(c[b++]=a.P,c[b++]=a.ga,c[b++]=a.F,c[b++]=a.D,c[b++]=a.C,c[b++]=a.ra,c[b++]=a.pa,c[b++]=a.qa,c[b++]=a.N);for(var d=0,e=[],f=0;f=this.C&&(this.D=this.C=0,this.ga&=~(Cx|Dx|Ex));return c};l.vo=function(a,b,c){t(this,a,b,c,"DATA["+this.C+"]");this.C=a&&(this.ga|=Cx,this.ga&=~Gx,Hx(this))};l.Om=function(a,b){var c=this.ga;t(this,a,null,b,"STATUS",c);this.D=a.B.Na?(a.ga=Jx,a.te(a.B,function(b){0<=b?(Kx(a),a.V&&a.V.da==zl&&(a.ga=0),a.ga=a.ga|ux|Lx|Mx):(a.ga=Nx,a.I=Ox)},!1)):a.ga=ux|Lx));return d}l.gl=function(a,b){return Ix(this,a,b)|Ix(this,a,b)<<8}; +function Px(a,b,c,d){if(a.B&&a.B.yb>=a.B.Na)if(0>Qx(a.B,c))a.ga=Nx,a.I=Ox;else if(1==a.B.Va||a.B.Va==a.B.Na)r(a,1048832)&&t(a,b,c,d,"DATA["+a.B.Va+"]"),1=a.B.Na&&(a.ga|=Mx))}l.An=function(a,b,c){Px(this,a,b&255,c);Px(this,a,b>>8&255,c)};l.Ql=function(a,b){var c=this.I;t(this,a,null,b,"ERROR",c);return c};l.Fn=function(a,b,c){t(this,a,b,c,"WPREC");this.ta=b};l.Sl=function(a,b){var c=this.J;t(this,a,null,b,"SECCNT",c);return c}; +l.Dn=function(a,b,c){t(this,a,b,c,"SECCNT");this.J=b};l.Tl=function(a,b){var c=this.fa;t(this,a,null,b,"SECNUM",c);return c};l.En=function(a,b,c){t(this,a,b,c,"SECNUM");this.fa=b};l.Ol=function(a,b){var c=this.ea;t(this,a,null,b,"CYLLO",c);return c};l.zn=function(a,b,c){t(this,a,b,c,"CYLLO");this.ea=b};l.Nl=function(a,b){var c=this.ba;t(this,a,null,b,"CYLHI",c);return c};l.yn=function(a,b,c){t(this,a,b,c,"CYLHI");this.ba=b};l.Pl=function(a,b){var c=this.U;t(this,a,null,b,"DRVHD",c);return c}; +l.Bn=function(a,b,c){t(this,a,b,c,"DRVHD");this.U=b;this.ga=this.A[this.U&Rx?1:0]?this.ga|ux|Lx:this.ga&~ux};l.Ul=function(a,b){var c=this.ga;t(this,a,null,b,"STATUS",c);this.ga&ux&&(this.ga&=~Jx);return c};l.xn=function(a,b,c){t(this,a,b,c,"COMMAND");this.ha=b;this.V&&Zg(this.V,14);Sx(this)};l.Cn=function(a,b,c){t(this,a,b,c,"FDR");this.L&Tx&&!(b&Tx)&&(this.I=Ux);this.L=b}; function Sx(a){var b=!1,c=a.ha,d=a.U&Rx?1:0,e=a.U&Vx,f=a.ea|(a.ba&Wx)<<8,g=a.fa,h=a.J||256;a.Ya=-1;a.B=null;a.I=Xx;a.ga=ux|Lx;var k=a.A[d];k?(k.Od=f,k.bb=e,k.jb=g,k.yb=h*k.Na,c=c>=Yx?c:c&Zx,k.hb=null,k.Va=0,k.errorCode=0,a.Ya=d,a.B=k):c=-1;switch(c&Zx){case $x:b=!0;break;case ay:a.ga=Jx;a.te(k,function(b){0<=b&&a.V?(Kx(a),a.ga=ux|Lx|Mx):(a.ga=Nx,a.I=Ox)},!1);break;case by:a.ga=Mx;break;case cy:b=!0;break;case dy:b=!0;break;case Yx:a.I=Ux;b=!0;break;case ey:k.gb=e+1,k.Wa=h,b=!0}b&&Kx(a)} function Kx(a){a.V&&(a.L&fy||mh(a.V,14,120))} -function Hx(a){a.D=0;var b=gy(a),c=gy(a),d=c&32,e=d>>5,f=c&31,g=gy(a),h=gy(a),k=g<<2&768|h,m=g&63,p=gy(a),v=gy(a),u=a.A[e];u&&(u.Od=k,u.bb=f,u.jb=m,u.yb=p*u.Na);switch(b){case hy:iy(a,u?u.errorCode:jy);ky(a,c);ky(a,g);ky(a,h);ky(a,ly|d);b=-1;break;case Fx:for(c=0;0<=(b=gy(a));)u&&cb?this.te(a,c):c(-1,!1)};l.el=function(a,b){return void 0!==b&&0<=b?Qx(a,b):-1}; -l.ul=function(a,b){void 0!==b&&0<=b?(a.VaQx(a,a.Ti)){a=-1;break a}a.dg++}a.dg>=a.Vd&&(b=-1);a=b}else a=-1;return a}; +function Hx(a){a.D=0;var b=gy(a),c=gy(a),d=c&32,e=d>>5,f=c&31,g=gy(a),h=gy(a),k=g<<2&768|h,m=g&63,p=gy(a),v=gy(a),u=a.A[e];u&&(u.Od=k,u.bb=f,u.jb=m,u.yb=p*u.Na);switch(b){case hy:iy(a,u?u.errorCode:jy);ky(a,c);ky(a,g);ky(a,h);ky(a,ly|d);b=-1;break;case Fx:for(c=0;0<=(b=gy(a));)u&&cb?this.te(a,c):c(-1,!1)};l.fl=function(a,b){return void 0!==b&&0<=b?Qx(a,b):-1}; +l.vl=function(a,b){void 0!==b&&0<=b?(a.VaQx(a,a.Ui)){a=-1;break a}a.eg++}a.eg>=a.Vd&&(b=-1);a=b}else a=-1;return a}; function ty(a,b,c){b.errorCode=jy;if(b.va&&(b.hb=null,a.V)){b.errorCode=wx;Sn(a.V,3,a,"dmaRead",b);Jn(a.V,3,function(a){a||b.errorCode!=wx||(b.errorCode=jy);c(b.errorCode?my:ly)});return}c(b.errorCode?my:ly)}function vy(a,b,c){b.errorCode=jy;if(b.va&&(b.hb=null,a.V)){b.errorCode=wx;Sn(a.V,3,a,"dmaWrite",b);Jn(a.V,3,function(a){a||(b.errorCode==wx&&(b.errorCode=jy),b.errorCode==yy&&(b.errorCode=wx));c(b.errorCode?my:ly)});return}c(b.errorCode?my:ly)} -function xy(a,b,c){b.errorCode=jy;b.Ce&&b.Ce.length==b.yb||(b.Ce=Array(b.yb));b.Va=0;a.V?(b.errorCode=wx,Sn(a.V,3,a,"dmaWriteBuffer",b),Jn(a.V,3,function(a){a||b.errorCode!=wx||(b.errorCode=jy);c(b.errorCode?my:ly)})):c(b.errorCode?my:ly)} -l.te=function(a,b,c){var d=-1,e=null,f=0;if(a.errorCode)return b&&b(d,!1,e,f),d;var g=!1!==c?1:0;if(a.hb&&(f=a.Va,d=a.va.read(a.hb,a.Va),a.Va+=g,0<=d))return e=a.hb,b&&b(d,!1,e,f),d;if(b){if(a.va)return a.va.seek(a.Od,a.bb,a.jb+a.cg,!1,function(c,k){(a.hb=c)?(e=c,f=a.Va=0,zy(a),d=a.va.read(a.hb,a.Va),a.Va+=g):a.errorCode=yy;b(d,k,e,f)}),d;a.errorCode=yy;b(d,!1,e,f)}return d}; -function Qx(a,b){if(a.errorCode)return-1;do{if(a.hb&&a.va.write(a.hb,a.Va++,b))break;a.va&&a.va.seek(a.Od,a.bb,a.jb+a.cg,!0,function(b){a.hb=b});if(!a.hb){a.errorCode=yy;b=-1;break}a.Va=0;zy(a)}while(1);return b}function zy(a){a.jb++;var b=1-a.cg;a.jb>=a.Wa+b&&(a.jb=b,a.bb++,a.bb>=a.gb&&(a.bb=0,a.Od++))}l.Om=function(){var a=this.G.L&255;!(this.G.D>>8)&&128>8||!this.V)||(a=!(this.V.ic[0].sd&64));return a?!0:!1}; +function xy(a,b,c){b.errorCode=jy;b.De&&b.De.length==b.yb||(b.De=Array(b.yb));b.Va=0;a.V?(b.errorCode=wx,Sn(a.V,3,a,"dmaWriteBuffer",b),Jn(a.V,3,function(a){a||b.errorCode!=wx||(b.errorCode=jy);c(b.errorCode?my:ly)})):c(b.errorCode?my:ly)} +l.te=function(a,b,c){var d=-1,e=null,f=0;if(a.errorCode)return b&&b(d,!1,e,f),d;var g=!1!==c?1:0;if(a.hb&&(f=a.Va,d=a.va.read(a.hb,a.Va),a.Va+=g,0<=d))return e=a.hb,b&&b(d,!1,e,f),d;if(b){if(a.va)return a.va.seek(a.Od,a.bb,a.jb+a.dg,!1,function(c,k){(a.hb=c)?(e=c,f=a.Va=0,zy(a),d=a.va.read(a.hb,a.Va),a.Va+=g):a.errorCode=yy;b(d,k,e,f)}),d;a.errorCode=yy;b(d,!1,e,f)}return d}; +function Qx(a,b){if(a.errorCode)return-1;do{if(a.hb&&a.va.write(a.hb,a.Va++,b))break;a.va&&a.va.seek(a.Od,a.bb,a.jb+a.dg,!0,function(b){a.hb=b});if(!a.hb){a.errorCode=yy;b=-1;break}a.Va=0;zy(a)}while(1);return b}function zy(a){a.jb++;var b=1-a.dg;a.jb>=a.Wa+b&&(a.jb=b,a.bb++,a.bb>=a.gb&&(a.bb=0,a.Od++))}l.Pm=function(){var a=this.G.L&255;!(this.G.D>>8)&&128>8||!this.V)||(a=!(this.V.ic[0].sd&64));return a?!0:!1}; var xx="Hard Drive",Ax=["XTC","ATC","COMPAQ"],yx=[{0:[306,2],1:[375,8],2:[306,6],3:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[940,8],5:[940,6],6:[615,4],7:[462,8],8:[733,5],9:[900,15],10:[820,3],11:[855,5],12:[855,7],13:[306,8],14:[733,7],16:[612,4],17:[977,5],18:[977,7],19:[1024,7],20:[733,5],21:[733,7],22:[733,5],23:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[1023,8],5:[940,6],6:[697,5],7:[462,8],8:[925,5],9:[900,15],10:[980,5],11:[925,7],12:[925,9],13:[612,8],14:[980,4],16:[612,4],17:[980,5],18:[966, 6],19:[1023,8],20:[733,5],21:[733,7],22:[524,4,40],23:[924,8],24:[966,14],25:[966,16],26:[1023,14],27:[832,6,33],28:[1222,15,34],29:[1240,7,34],30:[615,4,25],31:[615,8,25],32:[905,9,25],33:[832,8,33],34:[966,7,34],35:[966,8,34],36:[966,9,34],37:[966,5,34],38:[612,16,63],39:[1023,11,33],40:[1023,15,34],41:[1630,15,52],42:[1023,16,63],43:[805,4,26],44:[805,2,26],45:[748,8,33],46:[748,6,33],47:[966,5,25]}],qx=496,Ux=1,Xx=0,Ox=16,Wx=3,Vx=15,Rx=16,Nx=1,Mx=8,Lx=16,ux=64,Jx=128,$x=16,ay=32,by=48,cy=64,dy= -112,Yx=144,ey=145,Zx=240,fy=2,Tx=4,ly=0,my=2,py=0,qy=1,hy=3,ry=5,sy=8,uy=10,Fx=12,wy=15,ny=224,oy=228,wx=0,jy=4,yy=20,vx=0,Gx=1,Cx=2,Dx=4,Ex=8,Bx=32,nx={800:lx.prototype.Mm,801:lx.prototype.Nm,802:lx.prototype.Lm},mx={496:lx.prototype.fl,497:lx.prototype.Pl,498:lx.prototype.Rl,499:lx.prototype.Sl,500:lx.prototype.Nl,501:lx.prototype.Ml,502:lx.prototype.Ol,503:lx.prototype.Tl},px={800:lx.prototype.uo,801:lx.prototype.xo,802:lx.prototype.wo,803:lx.prototype.vo,807:lx.prototype.bi,811:lx.prototype.bi, -815:lx.prototype.bi},ox={496:lx.prototype.zn,497:lx.prototype.En,498:lx.prototype.Cn,499:lx.prototype.Dn,500:lx.prototype.yn,501:lx.prototype.xn,502:lx.prototype.An,503:lx.prototype.wn,1014:lx.prototype.Bn};cb(function(){for(var a=zb(document,"pcx86","hdc"),b=0;bthis.A&&this.C.length&&(this.A=0);if(0>this.A||a!=this.C[this.A])this.C.splice(0,0,a),this.A=0;this.A--}else this.fa?a="end":a=this.C[this.A+1];b=[];if(a){a=a.replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(Da(a.substring(d,f))),d=f+1}}return b}; +112,Yx=144,ey=145,Zx=240,fy=2,Tx=4,ly=0,my=2,py=0,qy=1,hy=3,ry=5,sy=8,uy=10,Fx=12,wy=15,ny=224,oy=228,wx=0,jy=4,yy=20,vx=0,Gx=1,Cx=2,Dx=4,Ex=8,Bx=32,nx={800:lx.prototype.Nm,801:lx.prototype.Om,802:lx.prototype.Mm},mx={496:lx.prototype.gl,497:lx.prototype.Ql,498:lx.prototype.Sl,499:lx.prototype.Tl,500:lx.prototype.Ol,501:lx.prototype.Nl,502:lx.prototype.Pl,503:lx.prototype.Ul},px={800:lx.prototype.vo,801:lx.prototype.yo,802:lx.prototype.xo,803:lx.prototype.wo,807:lx.prototype.di,811:lx.prototype.di, +815:lx.prototype.di},ox={496:lx.prototype.An,497:lx.prototype.Fn,498:lx.prototype.Dn,499:lx.prototype.En,500:lx.prototype.zn,501:lx.prototype.yn,502:lx.prototype.Bn,503:lx.prototype.xn,1014:lx.prototype.Cn};cb(function(){for(var a=zb(document,"pcx86","hdc"),b=0;bthis.A&&this.C.length&&(this.A=0);if(0>this.A||a!=this.C[this.A])this.C.splice(0,0,a),this.A=0;this.A--}else this.fa?a="end":a=this.C[this.A+1];b=[];if(a){a=a.replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(Da(a.substring(d,f))),d=f+1}}return b}; function By(a,b,c){var d=a;b=b||32;if(c)if(32==b)d=a>>>0;else if(32>b)d=a&(1<a||a>=b)d=a%b,0>d&&(d+=b)}else 32>=b?d=a<<32-b>>32-b:(b=Math.pow(2,b-1),a>=b?(d=a%b,(a/b|0)&1&&(d-=b)):a<-b&&(d=a%b,((-a-1)/b|0)&1?d&&(d+=b):d||(d-=b)));a!=d&&(a=d);return a} function Cy(a,b,c){for(c=void 0===c?-1:c;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop();var f=a.pop();switch(d){case "*":f*=e;break;case "/":if(!e)return!1;f=Math.trunc(f/e);break;case "^/":if(!e)return!1;f%=e;break;case "+":f+=e;break;case "-":f-=e;break;case "<<":f<<=e;break;case ">>":f>>=e;break;case ">>>":f>>>=e;break;case "<":f=f":f=f>e?1:0;break;case ">=":f=f>=e?1:0;break;case "==":f=f==e?1:0;break;case "!=":f=f!=e?1:0;break; case "&":f&=e;break;case "!":case "|":f|=e;break;case "^!":f|=e;break;case "&&":f=f&&e?1:0;break;case "||":f=f||e?1:0;break;case ",,":f=By(f,18,!0)*Math.pow(2,18)+By(e,18,!0);break;case "_":case "^_":"^_"==d&&(e=35-(e&255));e&&(f=By(f,0,!0),f=0=|>>>|>>|>|<=|<<|<|-|\+|\^\/|\/|\*|,,| )/);d=Dy(a,b,0,b.length,a.D,c);void 0!==d&&e&&Ly(a,null,d)}return d} -function My(a,b){var c=a.ha[0],d=a.ha[1];var e="("==c||"{"==c||"["==c?"\\":"";var f="["==c?"\\":"";for(f=new RegExp(e+c+"([^"+f+c+f+d+"]+)"+e+d);e=b.match(f);){var g=Ky(a,e[1]);if(void 0===g)return;b=b.replace(c+e[1]+d,null!=g?Jy(a,g):"undefined")}if(a.Ea.length)for(c=a.Ea[0],d=a.Ea[1],e="("==c||"{"==c||"["==c?"\\":"",f="["==c?"\\":"",f=new RegExp(e+c+"([^"+f+c+f+d+"]+)"+e+d);e=b.match(f);)b=a.Jk(b,e[1]);for(;c=b.match(/\$([a-z]+)/i);){d=null;switch(c[1].toLowerCase()){case "ops":d=a.ba-a.ka}if(null== +function My(a,b){var c=a.ha[0],d=a.ha[1];var e="("==c||"{"==c||"["==c?"\\":"";var f="["==c?"\\":"";for(f=new RegExp(e+c+"([^"+f+c+f+d+"]+)"+e+d);e=b.match(f);){var g=Ky(a,e[1]);if(void 0===g)return;b=b.replace(c+e[1]+d,null!=g?Jy(a,g):"undefined")}if(a.Ea.length)for(c=a.Ea[0],d=a.Ea[1],e="("==c||"{"==c||"["==c?"\\":"",f="["==c?"\\":"",f=new RegExp(e+c+"([^"+f+c+f+d+"]+)"+e+d);e=b.match(f);)b=a.Kk(b,e[1]);for(;c=b.match(/\$([a-z]+)/i);){d=null;switch(c[1].toLowerCase()){case "ops":d=a.ba-a.ka}if(null== d)break;b=b.replace(c[0],d.toString())}return b}function Fy(a,b){for(;b;){switch(b&3){case 1:a=-By(a);break;case 2:a|=-1;break;case 3:for(var c=35;0<=c&&!(a&Math.pow(2,c));)c--;a=35-c}b>>>=2}return a} -function Ey(a,b,c,d,e){e=void 0===e?0:e;var f=Array.isArray(d)?d:void 0;if(null!=b){var g=a.bh(b);if(0<=g)g=a.dh(g);else if(g=b,a.I[g]?g=a.I[g].value:(g=g.substr(0,6),g=a.I[g]&&a.I[g].value),null!=g){var h=a.I[b]&&a.I[b].Uo;h&&(f?f.push(h):(f=Ky(a,h,d),void 0!==f?g+=f:(d||a.O("undefined "+(c||"value")+": "+b+" ("+h+")"),g=void 0)))}else g=qa(b,1c&&(e+=" '"+String.fromCharCode(c)+"'")}a.O((null!=b?b+": ":"")+e);return d}function Ny(a,b){var c=0;if(a.I){if(b)return Ly(a,b,a.I[b]&&a.I[b].value);b=Object.keys(a.I);b.sort();for(var d=0;d=Math.abs(b)?5:11;b=sa(b,10,a);break;default:b=q(b,0>2:0,!!e)}0>c?c=b.replace(/^0+([0-9A-F]+)$/i,"$1"):c=b;return c} var Hy={"||":5,"&&":6,"!":7,"|":7,"^!":8,"&":9,"!=":10,"==":10,">=":11,">":11,"<=":11,"<":11,">>>":12,">>":12,"<<":12,"-":13,"+":13,"^/":14,"/":14,"*":14,_:19,"^_":19,"{":20,"}":20},Gy={",,":1,"||":5,"&&":6,"!=":10,"==":10,">=":11,">":11,"<=":11,"<":11,">>>":12,">>":12,"<<":12,"-":13,"+":13,"^/":14,"/":14,"*":14,"!":15,"|":15,"^!":15,"&":15,_:19,"^_":19,"{":20,"}":20}; function Oy(a){Ay.call(this,a);this.ra=4;this.la=5;this.xa=1048575;this.N=Py(this,0,0);this.Ca=Py(this,0,0);this.ea=Py(this,0,0);this.F=[];this.B=this.V=this.L=[];Qy(this);this.wa=0;Ry(this);this.Fa={};Sy(this,a.messages);this.Ka=a.commands;var b=this;window?void 0===window.pcx86&&(window.pcx86=function(a){return Ty(b,a)}):void 0===global.pcx86&&(global.pcx86=function(a){return Ty(b,a)})}ia(Oy,Ay);l=Oy.prototype; -l.tc=function(a,b,c,d){this.oa=b;this.G=c;this.na=a;this.cb=ac(a,"FDC");this.Pa=ac(a,"HDC");this.Kc=ac(a,"FPU");this.H=ac(a,"Mouse");(a=Ad(a,"messages"))&&Sy(this,a);this.la=b.I>>2;this.xa=b.N;this.ab=new Zd(this.G,7,"DBG");this.pa=Uy;80186<=this.G.da&&(this.pa=Uy.slice(),this.pa[15]=Vy,80286<=this.G.da&&(this.pa[15]=Wy,80386<=this.G.da&&(this.ra=8)));Cl(this,64,function(a){Xy(d,d.G.sc,a[0])});Cl(this,4,function(a){if(a=a[0]){var b=Ey(d,a);if(void 0===b)d.O("invalid selector: "+a);else if(a=Yy(d, +l.tc=function(a,b,c,d){this.oa=b;this.G=c;this.na=a;this.cb=ac(a,"FDC");this.Pa=ac(a,"HDC");this.Kc=ac(a,"FPU");this.H=ac(a,"Mouse");(a=Bd(a,"messages"))&&Sy(this,a);this.la=b.I>>2;this.xa=b.N;this.ab=new Zd(this.G,7,"DBG");this.pa=Uy;80186<=this.G.da&&(this.pa=Uy.slice(),this.pa[15]=Vy,80286<=this.G.da&&(this.pa[15]=Wy,80386<=this.G.da&&(this.ra=8)));Cl(this,64,function(a){Xy(d,d.G.sc,a[0])});Cl(this,4,function(a){if(a=a[0]){var b=Ey(d,a);if(void 0===b)d.O("invalid selector: "+a);else if(a=Yy(d, b,Zy),d.O("dumpSel("+wa(a?a.T:b)+"): %"+q(a?a.Ob:null,d.la)),a){b=!1;if(a.type&4096){if(a.type&2048){var c="code"+(a.type&512?",readable":",execonly");a.type&1024&&(c+=",conforming")}else c="data"+(a.type&512?",writable":",readonly"),a.type&1024&&(c+=",expdown");a.type&256&&(c+=",accessed")}else{var e=$y[a.type];e&&(c=e[0],b=e[1])}!c||a.ob&32768||(c+=",not present");d.O((b?"seg="+wa(a.ua&65535)+" off="+wa(a.Sa):"base="+q(a.ua,d.la)+" limit="+az(a.Sa))+" type="+va(a.type>>8)+" ("+c+") ext="+wa(a.ext& --65296)+" dpl="+va(a.qc))}}else d.O("no selector")});Cl(this,134217728,function(a){var b;(a=a[0])&&(b=Ey(d,a));if(void 0===b)d.O("invalid MCB");else for(d.O("dumpMCB("+wa(b)+")");b;){a=Py(d,0,b);var c=d.ya(a,1),e=d.Vc(a,2),k=d.Vc(a,5);if(77!=c&&90!=c)break;d.O(bz(0,b)+": '"+String.fromCharCode(c)+"' PID="+wa(e)+" LEN="+wa(k)+' "'+cz(d,a,8)+'"');b+=1+k}});Cl(this,128,function(a){Xy(d,d.G.aa,a[0],d.G.aa!==d.G.sc)});Cl(this,8,function(a){a:{if(a=a[0]){var b=Ey(d,a);if(void 0===b){d.O("invalid task selector: "+ +-65296)+" dpl="+va(a.qc))}}else d.O("no selector")});Cl(this,134217728,function(a){var b;(a=a[0])&&(b=Ey(d,a));if(void 0===b)d.O("invalid MCB");else for(d.O("dumpMCB("+wa(b)+")");b;){a=Py(d,0,b);var c=d.ya(a,1),e=d.Vc(a,2),k=d.Vc(a,5);if(77!=c&&90!=c)break;d.O(bz(0,b)+": '"+String.fromCharCode(c)+"' PID="+wa(e)+" LEN="+wa(k)+' "'+cz(d,a,8)+'"');b+=1+k}});Cl(this,128,function(a){Xy(d,d.G.Z,a[0],d.G.Z!==d.G.sc)});Cl(this,8,function(a){a:{if(a=a[0]){var b=Ey(d,a);if(void 0===b){d.O("invalid task selector: "+ a);break a}a=Yy(d,b,Zy)}else a=d.G.ka;d.O("dumpTSS("+wa(a?a.T:b)+"): %"+q(a?a.ua:null,d.la));if(a){b="";var c=a.type&-513,e=256==c?4:8,k=256==c?dz:ez;for(u in k){var m=k[u];var p=a.ua+m;var v=Ag(d.G,p,2);2304==c&&(v|=Ag(d.G,p+2,2)<<16);b&&(b+="\n");b+=wa(m)+" "+Ca(u+":",11)+q(v,e)}if(2304==c){var u=0;for(m=v>>>16;mu;){p=a.ua+m;v=Ag(d.G,p,2);p=2;c="";if(!p||4>=8;b+="\n"+wa(m)+" ports "+wa(u)+"-"+wa(u+15)+": "+(""+c);u+=16;m+=2}}d.O(b)}}}); -this.J=null;this.La=0;this.Ga=!1;Wf(this.G,48,this.Sm.bind(this));Wf(this.G,65,this.Tm.bind(this));this.aa=null;Wf(this.G,104,this.Um.bind(this));Pb(this)};function fz(a,b,c,d,e,f){b=cz(a,b);var g=Yy(a,d);g=g?g.Sa+1:0;var h=(e?"_CODE":"_DATA")+q(c,2);f&&r(a,128)&&a.message(b+" "+(e?"code":"data")+"("+q(c,4)+")=#"+q(d,4)+" len "+q(g));e=gz(a,b,c);e[b+h]=0;jq(a,b,c,d,0,null,g,e)} +this.J=null;this.La=0;this.Ga=!1;Wf(this.G,48,this.Tm.bind(this));Wf(this.G,65,this.Um.bind(this));this.Z=null;Wf(this.G,104,this.Vm.bind(this));Pb(this)};function fz(a,b,c,d,e,f){b=cz(a,b);var g=Yy(a,d);g=g?g.Sa+1:0;var h=(e?"_CODE":"_DATA")+q(c,2);f&&r(a,128)&&a.message(b+" "+(e?"code":"data")+"("+q(c,4)+")=#"+q(d,4)+" len "+q(g));e=gz(a,b,c);e[b+h]=0;jq(a,b,c,d,0,null,g,e)} function hz(a,b,c,d){var e=a.Vc(b,2),f=a.Vc(b,2),g=iz(a,b,4),h=iz(a,b,4),k=Py(a,iz(a,b,4),a.Vc(b,2));b=Py(a,iz(a,b,4),a.Vc(b,2));b=cz(a,b).toUpperCase();k=cz(a,k).toUpperCase();var m=(c?"_CODE":"_DATA")+q(e,2);d&&r(a,128)&&a.message((b==k?"":b+"!")+k+" "+(c?"code":"data")+"("+q(e,4)+")="+q(f,4)+":"+q(g)+" len "+q(h));c=gz(a,k,e);c[k+m]=g;jq(a,k,e,f,g,null,h,c)}function jz(a,b,c){c=cz(a,c).toUpperCase();kz(a,c,b)} -l.Sm=function(){var a=this.G;if(null!=this.J&&2752554==a.D){var b=a.L&65535,c=a.K&65535,d=Py(this,y(a)+12,a.U.T);switch(iz(this,d)){case 336:hz(this,Py(this,a.H,b),!c,!!this.J)}}return!0}; -l.Tm=function(a){var b=this.G,c=b.D&65535,d=b.H&65535,e=b.I&65535,f=b.L&65535,g=b.K&65535,h=b.J&65535,k=b.pa.T;if(null==this.J)return 79==c&&Xf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Tb(a,"INT 0x41 handling enabled",128),a.J=!0):(Tb(a,"INT 0x41 monitoring enabled",128),a.J=!1)}}(this)),!0;switch(c){case 79:this.J&&(b.D=b.D&-65536|62342,Tb(this,"INT 0x41 handling enabled",128));break;case 80:fz(this,Py(this,h,k),d+1,e,!(g&1),!!this.J);break;case 82:kz(this,null, +l.Tm=function(){var a=this.G;if(null!=this.J&&2752554==a.D){var b=a.L&65535,c=a.K&65535,d=Py(this,y(a)+12,a.U.T);switch(iz(this,d)){case 336:hz(this,Py(this,a.H,b),!c,!!this.J)}}return!0}; +l.Um=function(a){var b=this.G,c=b.D&65535,d=b.H&65535,e=b.I&65535,f=b.L&65535,g=b.K&65535,h=b.J&65535,k=b.pa.T;if(null==this.J)return 79==c&&Xf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Tb(a,"INT 0x41 handling enabled",128),a.J=!0):(Tb(a,"INT 0x41 monitoring enabled",128),a.J=!1)}}(this)),!0;switch(c){case 79:this.J&&(b.D=b.D&-65536|62342,Tb(this,"INT 0x41 handling enabled",128));break;case 80:fz(this,Py(this,h,k),d+1,e,!(g&1),!!this.J);break;case 82:kz(this,null, d);break;case 127:this.J&&(b.D=b.D&-65536|(this.Ga?0:1));break;case 131:this.J&&(a=Py(this,b.L,e),this.La++?(this.O("TRAPFAULT failed"),lz(this,this.B,a,!0,!0),this.La=0,rk(this)):(this.O("INT 0x41 TRAPFAULT: fault="+wa(d)+" error="+q(b.K,8,!0)+" addr="+mz(a)),this.rd(this.B,a,!0),Ry(this,!0)));break;case 141:this.J&&(b.D=b.D&-65536|1);break;case 336:hz(this,Py(this,b.H,f),!g,!!this.J);break;case 338:jz(this,d,Py(this,b.J,f))}this.Ga=!1;return!this.J}; -l.Um=function(a){var b=this.G,c=b.D&255,d=b.D>>8&255,e=b.H&65535,f=b.I&65535,g=b.L&65535,h=b.J&65535,k=b.pa.T;if(null==this.aa){if(67==d){if(609437257==b.ia((b.ba.T<<4)+10)||1111835735==b.ia((b.ba.T<<4)+95))return!0;Xf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Tb(a,"INT 0x68 handling enabled",128),a.J=a.aa=!0):(Tb(a,"INT 0x68 monitoring enabled",128),a.aa=!1)}}(this))}return!0}switch(d){case 67:this.aa&&(b.D=b.D&-65536|62342);break;case 68:this.aa&&(a=ce(b.ba,this.ql.bind(this)))&& -(b.J=a[0],ue(b,a[1]));break;case 72:kz(this,null,e);break;case 80:32==c?fz(this,Py(this,h,k),0,f,!0,!!this.aa):128>c?fz(this,Py(this,h,k),e+1,c&64?g:f,!(c&1),!!this.aa):hz(this,Py(this,h,k),!(c&1),!!this.aa),this.aa&&(b.D=b.D&-256|1)}return!this.aa};l.ql=function(){var a=this.G;5==(a.D&255)&&(a.I=a.K=0,a.D=a.D&-256|1);return!1}; +l.Vm=function(a){var b=this.G,c=b.D&255,d=b.D>>8&255,e=b.H&65535,f=b.I&65535,g=b.L&65535,h=b.J&65535,k=b.pa.T;if(null==this.Z){if(67==d){if(609437257==b.ia((b.ba.T<<4)+10)||1111835735==b.ia((b.ba.T<<4)+95))return!0;Xf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Tb(a,"INT 0x68 handling enabled",128),a.J=a.Z=!0):(Tb(a,"INT 0x68 monitoring enabled",128),a.Z=!1)}}(this))}return!0}switch(d){case 67:this.Z&&(b.D=b.D&-65536|62342);break;case 68:this.Z&&(a=ce(b.ba,this.rl.bind(this)))&& +(b.J=a[0],ue(b,a[1]));break;case 72:kz(this,null,e);break;case 80:32==c?fz(this,Py(this,h,k),0,f,!0,!!this.Z):128>c?fz(this,Py(this,h,k),e+1,c&64?g:f,!(c&1),!!this.Z):hz(this,Py(this,h,k),!(c&1),!!this.Z),this.Z&&(b.D=b.D&-256|1)}return!this.Z};l.rl=function(){var a=this.G;5==(a.D&255)&&(a.I=a.K=0,a.D=a.D&-256|1);return!1}; l.Eb=function(a,b,c){var d=this;switch(b){case "debugInput":return this.ta=this.ma[b]=c,c.onkeydown=function(a){if(13==a.keyCode){var b=c.value;c.value="";Ty(d,b,!0)}else if(27==a.keyCode)c.value=b="";else if(38==a.keyCode?(b=null,d.A>>0)+1;a.ob=f;a.type=g;a.ext=k;a.Ob=d;be(a,!0,!0,!1)}}return a}l.Vb=function(a,b,c){var d=a&&a.za;if(null==d&&(d=-1,a)){var e=Yy(this,a.T,a.type);e&&(b=a.Ja||0,c=c||1,d=e=-1===e.Ob||e.ed&&(b>>>0)+c>e.Nb||!e.ed&&(b>>>0)+c<=e.Nb?e.ua+b|0:-1,a.za=d)}return d};l.ya=function(a,b){var c=255,d=this.Vb(a,!1,1);-1!==d&&(c=Ag(this.G,d,1,a.type==qz)|0,b&&rz(this,a,b));return c}; -l.nb=function(a,b){return a.Jb?iz(this,a,b?4:0):this.Vc(a,b?2:0)};l.Vc=function(a,b){var c=65535,d=this.Vb(a,!1,2);-1!==d&&(c=Ag(this.G,d,2,a.type==qz)|0,b&&rz(this,a,b));return c};function iz(a,b,c){var d=-1,e=a.Vb(b,!1,4);-1!==e&&(d=Ag(a.G,e,4,b.type==qz)|0,c&&rz(a,b,c));return d}l.ub=function(a,b,c,d){var e=this.Vb(a,!0,1);if(-1!==e){if(a.type!=qz)this.G.ub(e,b);else{var f=this.oa;f.aa[(e&f.C)>>>f.A].af(e&f.D,b&255,e)}c&&rz(this,a,c);d||Fd(this.G,!0)}}; -l.al=function(a,b,c){var d=this.Vb(a,!0,2);-1!==d&&(a.type!=qz?this.G.ib(d,b):Mc(this.oa,d,b),c&&rz(this,a,c),Fd(this.G,!0))};function Py(a,b,c,d,e,f,g){return sz(a,{},b,c,d,e,f,g)}function sz(a,b,c,d,e,f,g,h){b.Ja=c||0;b.T=d;b.za=e;b.type=f||(oz(a)?Zy:pz);b.Jb=null!=g?g:!(!a.G||4!=a.G.ba.X);b.ec=null!=h?h:!(!a.G||4!=a.G.ba.Lc);b.wd=!1;return b}function tz(a){return[a.Ja,a.T,a.za,a.wd,a.Jb,a.ec,a.De,a.Yg]}function uz(a){return{Ja:a[0],T:a[1],za:a[2],wd:a[3],Jb:a[4],ec:a[5],De:a[6],Yg:a[7]}} +l.nb=function(a,b){return a.Jb?iz(this,a,b?4:0):this.Vc(a,b?2:0)};l.Vc=function(a,b){var c=65535,d=this.Vb(a,!1,2);-1!==d&&(c=Ag(this.G,d,2,a.type==qz)|0,b&&rz(this,a,b));return c};function iz(a,b,c){var d=-1,e=a.Vb(b,!1,4);-1!==e&&(d=Ag(a.G,e,4,b.type==qz)|0,c&&rz(a,b,c));return d}l.ub=function(a,b,c,d){var e=this.Vb(a,!0,1);if(-1!==e){if(a.type!=qz)this.G.ub(e,b);else{var f=this.oa;f.Z[(e&f.C)>>>f.A].bf(e&f.D,b&255,e)}c&&rz(this,a,c);d||Fd(this.G,!0)}}; +l.bl=function(a,b,c){var d=this.Vb(a,!0,2);-1!==d&&(a.type!=qz?this.G.ib(d,b):Mc(this.oa,d,b),c&&rz(this,a,c),Fd(this.G,!0))};function Py(a,b,c,d,e,f,g){return sz(a,{},b,c,d,e,f,g)}function sz(a,b,c,d,e,f,g,h){b.Ja=c||0;b.T=d;b.za=e;b.type=f||(oz(a)?Zy:pz);b.Jb=null!=g?g:!(!a.G||4!=a.G.ba.X);b.ec=null!=h?h:!(!a.G||4!=a.G.ba.Lc);b.wd=!1;return b}function tz(a){return[a.Ja,a.T,a.za,a.wd,a.Jb,a.ec,a.Ee,a.Zg]}function uz(a){return{Ja:a[0],T:a[1],za:a[2],wd:a[3],Jb:a[4],ec:a[5],Ee:a[6],Zg:a[7]}} function vz(a,b,c){if(null!=b.T&&(a=Yy(a,b.T,b.type))){var d=b.Ja&a.xa;if(!a.ed){if(d>>>0>=a.Nb)return!1}else if(d>>>0e?null!=g?(f=Ky(a,b,void 0),e=null):(e=Ky(a,b,void 0),null==e&&(f=null)):(g=Ky(a,b.substring(0,e),void 0),f=Ky(a,b.substring(e+1),void 0),e=null)}null!=f&&(h=Py(a,f,g,e,c),d||vz(a,h,!0)||(a.O("invalid offset: "+mz(h)),h=null));return h}function zz(a,b,c){c&&(c=c.match(/(['"])(.*?)\1/))&&(b.kl=a.yg(b.Sk=c[2]))}l.Jk=function(a,b){var c=wz(this,b);return a.replace("["+b+"]",c?q(this.nb(c),c.Jb?8:4):"undefined")}; +p.p)}break}}if(h=v)return h;0>e?null!=g?(f=Ky(a,b,void 0),e=null):(e=Ky(a,b,void 0),null==e&&(f=null)):(g=Ky(a,b.substring(0,e),void 0),f=Ky(a,b.substring(e+1),void 0),e=null)}null!=f&&(h=Py(a,f,g,e,c),d||vz(a,h,!0)||(a.O("invalid offset: "+mz(h)),h=null));return h}function zz(a,b,c){c&&(c=c.match(/(['"])(.*?)\1/))&&(b.ll=a.zg(b.Tk=c[2]))}l.Kk=function(a,b){var c=wz(this,b);return a.replace("["+b+"]",c?q(this.nb(c),c.Jb?8:4):"undefined")}; function rz(a,b,c){c=c||1;null!=b.za&&(b.za+=c);null!=b.T&&(b.Ja+=c,vz(a,b)||(b.Ja=0,b.za=null))}function bz(a,b,c){return null!=b?q(b,4)+":"+q(a,a&-65536||c?8:4):q(a)}function mz(a){switch(a.type){case pz:case Az:var b="&";break;case Zy:b="#";break;case yz:b="%";break;case qz:b="%%";break;default:b=a.T?"":"%"}return a.type>=yz||null==a.T?b+q(a.za):b+bz(a.Ja,a.T,a.ec)} function cz(a,b,c){var d="";for(c=c||256;d.length>>a.G.lb;g=1}a.O("blockid "+(d?"linear ":"physical")+" blockaddr used size type");a.O("-------- --------- ---------- ------ ------ ----");c=-1;for(var h=0;g--;)(d=b[f])&&d.type==ed&&(d=qd(a.G,e,!1,!0)),d.type==c?h++||a.O("..."):(c=d.type,h=wc[c],c==gd&&(d=d.td,h+=" -> "+wc[d.type]),d&&a.O(q(d.id,8)+" %"+q(f<c&&(c=Ja(Cz,a.substr(b,2)));return c}; -function Dz(a,b){var c=0,d=a.dh(b);if(null!=d)switch(b){case Ez:case Fz:case Gz:case Hz:case Iz:case Jz:case Kz:case Lz:c=2;break;case Mz:case Nz:case Oz:case Pz:case Qz:case Rz:case Sz:case Tz:case Uz:case Vz+Wz:case Vz+Xz:case Vz+Yz:case Vz+Zz:case Vz+$z:case Vz+aA:c=4;break;case bA:case cA:case dA:case eA:case fA:case gA:case hA:case iA:case jA:case kA:case lA:case mA:case nA:c=8;break;case oA:c=a.ra}return c?q(d,c):"??"} -l.dh=function(a){if(0<=a){var b=this.G;switch(a){case Ez:var c=b.D&255;break;case Fz:c=b.I&255;break;case Gz:c=b.L&255;break;case Hz:c=b.H&255;break;case Iz:c=b.D>>8&255;break;case Jz:c=b.I>>8&255;break;case Kz:c=b.L>>8&255;break;case Lz:c=b.H>>8&255;break;case Mz:c=b.D&65535;break;case Nz:c=b.I&65535;break;case Oz:c=b.L&65535;break;case Pz:c=b.H&65535;break;case Qz:c=y(b)&65535;break;case Rz:c=b.N&65535;break;case Sz:c=b.K&65535;break;case Tz:c=b.J&65535;break;case Uz:c=z(b)&65535;break;case oA:c= -xe(b);break;case Vz+Wz:c=b.pa.T;break;case Vz+Xz:c=b.ba.T;break;case Vz+Yz:c=b.U.T;break;case Vz+Zz:c=b.Fa.T;break;default:if(80286==this.G.da)a==jA&&(c=b.ra);else if(80386<=this.G.da)switch(a){case bA:c=b.D;break;case cA:c=b.I;break;case dA:c=b.L;break;case eA:c=b.H;break;case fA:c=y(b);break;case gA:c=b.N;break;case hA:c=b.K;break;case iA:c=b.J;break;case jA:c=b.ra;break;case kA:c=b.Kg;break;case lA:c=b.pd;break;case mA:c=b.wc;break;case Vz+$z:c=b.Ka.T;break;case Vz+aA:c=b.La.T;break;case nA:c= +" "+h),c!=dd&&c!=ed&&(c=-1),h=0),e+=a.G.Lg,f++}function Bz(a,b,c){a=q(a)+" "+q(b)+" ";a=a+(c&&b&64?"D":"-")+(b&32?"A":"-")+(b&4?"U":"S");a+=b&2?"W":"R";return a+=b&1?"P":"N"}function gz(a,b,c){var d=[],e;for(e=null;e=ac(a.na,"Disk",e);){var f=e,g=b,h=c;d={};if(f.C)for(var k=0;kc&&(c=Ja(Cz,a.substr(b,2)));return c}; +function Dz(a,b){var c=0,d=a.eh(b);if(null!=d)switch(b){case Ez:case Fz:case Gz:case Hz:case Iz:case Jz:case Kz:case Lz:c=2;break;case Mz:case Nz:case Oz:case Pz:case Qz:case Rz:case Sz:case Tz:case Uz:case Vz+Wz:case Vz+Xz:case Vz+Yz:case Vz+Zz:case Vz+$z:case Vz+aA:c=4;break;case bA:case cA:case dA:case eA:case fA:case gA:case hA:case iA:case jA:case kA:case lA:case mA:case nA:c=8;break;case oA:c=a.ra}return c?q(d,c):"??"} +l.eh=function(a){if(0<=a){var b=this.G;switch(a){case Ez:var c=b.D&255;break;case Fz:c=b.I&255;break;case Gz:c=b.L&255;break;case Hz:c=b.H&255;break;case Iz:c=b.D>>8&255;break;case Jz:c=b.I>>8&255;break;case Kz:c=b.L>>8&255;break;case Lz:c=b.H>>8&255;break;case Mz:c=b.D&65535;break;case Nz:c=b.I&65535;break;case Oz:c=b.L&65535;break;case Pz:c=b.H&65535;break;case Qz:c=y(b)&65535;break;case Rz:c=b.N&65535;break;case Sz:c=b.K&65535;break;case Tz:c=b.J&65535;break;case Uz:c=z(b)&65535;break;case oA:c= +xe(b);break;case Vz+Wz:c=b.pa.T;break;case Vz+Xz:c=b.ba.T;break;case Vz+Yz:c=b.U.T;break;case Vz+Zz:c=b.Fa.T;break;default:if(80286==this.G.da)a==jA&&(c=b.ra);else if(80386<=this.G.da)switch(a){case bA:c=b.D;break;case cA:c=b.I;break;case dA:c=b.L;break;case eA:c=b.H;break;case fA:c=y(b);break;case gA:c=b.N;break;case hA:c=b.K;break;case iA:c=b.J;break;case jA:c=b.ra;break;case kA:c=b.Mg;break;case lA:c=b.pd;break;case mA:c=b.wc;break;case Vz+$z:c=b.Ka.T;break;case Vz+aA:c=b.La.T;break;case nA:c= z(b)}}}return c}; -function pA(a,b){b=My(a,b)||b;for(var c=0,d,e;0<=(c=b.indexOf("@",c));)e=a.bh(b,c+1),0<=e&&(b=b.substr(0,c)+Dz(a,e)+b.substr(c+1+Cz[e].length)),c++;for(c=0;0<=(c=b.indexOf("#",c));)e=b.substr(c+1,2),d=qa(e,16),null!=d&&32<=d&&128>d?(d=e+" '"+String.fromCharCode(d)+"'",b=b.replace("#"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("$",c));)e=b.substr(c+1,9),(d=wz(a,e))?(d=e+' "'+cz(a,d)+'"',b=b.replace("$"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("^",c));)e=b.substr(c+1,9),(d=wz(a,e))?(rz(a,d), -d=e+' "'+cz(a,d,11)+'"',b=b.replace("^"+e,d),c+=d.length):c++;return b}l.message=function(a,b){b&&(a+=" at "+mz(Py(this,z(this.G),this.G.ba.T))+" (%"+q(this.G.ea)+")");this.dc&536870912?this.Ba.push(a):this.Aa&&a==this.Aa||(this.Aa=a,this.dc&-2147483648&&(rk(this),a+=" (cpu halted)"),this.O(a),this.G&&(a=this.G,a.Z.Of=!0,Fd(a)))}; +function pA(a,b){b=My(a,b)||b;for(var c=0,d,e;0<=(c=b.indexOf("@",c));)e=a.dh(b,c+1),0<=e&&(b=b.substr(0,c)+Dz(a,e)+b.substr(c+1+Cz[e].length)),c++;for(c=0;0<=(c=b.indexOf("#",c));)e=b.substr(c+1,2),d=qa(e,16),null!=d&&32<=d&&128>d?(d=e+" '"+String.fromCharCode(d)+"'",b=b.replace("#"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("$",c));)e=b.substr(c+1,9),(d=wz(a,e))?(d=e+' "'+cz(a,d)+'"',b=b.replace("$"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("^",c));)e=b.substr(c+1,9),(d=wz(a,e))?(rz(a,d), +d=e+' "'+cz(a,d,11)+'"',b=b.replace("^"+e,d),c+=d.length):c++;return b}l.message=function(a,b){b&&(a+=" at "+mz(Py(this,z(this.G),this.G.ba.T))+" (%"+q(this.G.ea)+")");this.dc&536870912?this.Ba.push(a):this.Aa&&a==this.Aa||(this.Aa=a,this.dc&-2147483648&&(rk(this),a+=" (cpu halted)"),this.O(a),this.G&&(a=this.G,a.aa.Pf=!0,Fd(a)))}; function al(a,b,c,d){var e;d||(d=r(a,1)&&0>qA.indexOf(b),d||(e=rA[b])&&(d=r(a,e)?!0:524288==e&&r(a,e=1048576)));if(d){var f=a.G.D>>8&255;var g=a.G.L&255;if(33==b&&11==f||524288==e&&128<=g||1048576==e&&128>g)d=!1}d&&((e=(e=Yb[b])&&e[f]||"")&&(e=" "+pA(a,e)),a.message("INT "+va(b)+": AH="+va(f)+" at "+bz(c-2-a.G.ba.ua,a.G.ba.T)+e));return d} -function Ub(a,b,c,d,e,f,g,h){h|=256;if(null==e||(a.dc&h)==h)h=null,null!=e&&(h=a.G.ba.T,e-=a.G.ba.ua),a.message(b.ye+"."+(null!=d?"outPort":"inPort")+"("+wa(c)+","+(f?f:"unknown")+(null!=d?","+va(d):"")+")"+(null!=g?": "+va(g):"")+(null!=e?" at "+bz(e,h):""))}l.eh=function(){this.O("Type ? for help with PCx86 Debugger commands");sA(this);if(this.Ka){var a=this.Ka;this.Ka=null;Ty(this,a)}}; +function Ub(a,b,c,d,e,f,g,h){h|=256;if(null==e||(a.dc&h)==h)h=null,null!=e&&(h=a.G.ba.T,e-=a.G.ba.ua),a.message(b.ye+"."+(null!=d?"outPort":"inPort")+"("+wa(c)+","+(f?f:"unknown")+(null!=d?","+va(d):"")+")"+(null!=g?": "+va(g):"")+(null!=e?" at "+bz(e,h):""))}l.fh=function(){this.O("Type ? for help with PCx86 Debugger commands");sA(this);if(this.Ka){var a=this.Ka;this.Ka=null;Ty(this,a)}}; function Ry(a,b){var c;if(Og(a)){if(!a.U||!a.U.length){a.U=Array(tA);for(c=0;c>>g.lb].rd(f&g.Fb,a==this.L);h&&uc(g)}}e&&(a.push(b),c?(null!=b.za&&(b.T=null),b.wd=!0):(d||AA(this,a,a.length-1,"set"),Ry(this)));return e}; -function lz(a,b,c,d,e){for(var f=!1,g=BA(a,a.Vb(c)),h=1;h>>g.lb].rd(f&g.Fb,a==this.L);h&&uc(g)}}e&&(a.push(b),c?(null!=b.za&&(b.T=null),b.wd=!0):(d||AA(this,a,a.length-1,"set"),Ry(this)));return e}; +function lz(a,b,c,d,e){for(var f=!1,g=BA(a,a.Vb(c)),h=1;h>3&7,A=(3>(g>>6&3)?0:48)+u;(217==f||219==f)&&52<=A&&(A=u<<4|g&7);(u=JA[f])&&(v=u[A]);v&&(p=KA,k=v,m=k[0])}m>=p.length&&(g=a.ya(b,1),k=LA[m-p.length][g>>3&7],m=k[0]);p=p[m];u=k.length-1;v="";b.Jb&&(m==MA?p= "CWDE":m==NA?p="CDQ":m>=OA&&m<=PA&&(p+="D"));if(164<=f&&167>=f||170<=f&&175>=f)u=0,b.Jb&&"W"==p.slice(-1)&&(p=p.slice(0,-1)+"D");f=-1;A=!0;for(var J=1;J<=u;J++){var H="";var G=k[J];if(void 0!==G){0>f&&(f=G>>QA);m==RA&&(f==SA?v="[%800]":f==TA&&(v="ES:["+(b.ec?"E":"")+"DI]"));var P=G&UA;if(P!=VA)if(P==WA)A=!1;else{var I=G&XA;if(I>=R)if(0>g&&(g=a.ya(b,1)),I>6,ra=g&7;if(3>hb){P=0==p.indexOf("FI");if(!hb&&(!G.ec&&6==ra||G.ec&&5==ra))hb=2;else{if(G.ec)if(4!=ra)ra+= 8;else{Z=I;var ib=hb,Sb=G,Jb=Z.ya(Sb,1),cc=Jb>>6,vc=Jb>>3&7;Jb&=7;var jb="";if(ib||5!=Jb)jb=ZA[Jb+8];4!=vc&&(jb&&(jb+="+"),jb+=ZA[vc+8],cc&&(jb+="*"+(1<>24),2)):Z+("+"+q(I,2))):2==hb&&(Z&&(Z+="+"),G.ec?(I=iz(I,G,4),Z+=q(I)):(I=I.Vc(G,2),Z+=q(I,4)));Z="["+Z+"]";if(1==oa){I="";H&=UA;H==S&&(H=G.Jb?$A:T);switch(H){case aB:I="FAR";break;case U:I="BYTE";break;case T:if(P){I="INT16";break}I= "WORD";break;case $A:I="DWORD";break;case bB:if(P){I="INT32";break}case cB:I="REAL32";break;case dB:if(P){I="INT64";break}case eB:I="REAL64";break;case fB:I="REAL80";break;case gB:I="BCD80"}I&&(Z=I+" "+Z)}}else Z=hB(I,ra,H,G);H=Z}else H=I==YA?hB(a,g&7,G,b):hB(a,g>>3&7,G,b);else if(I==iB)H="1";else if(I==V){H=a;P=G;I=b;G=" ";switch(P&UA){case U:P&W&&(G=q(H.ya(I,1),2));break;case jB:G=q(H.ya(I,1)<<24>>24,I.Jb?8:4);break;case S:if(I.Jb){G=q(iz(H,I,4));break}case T:G=q(H.Vc(I,2),4);break;case aB:I=Py(H, H.nb(I,!0),H.Vc(I,2),null,I.type,I.Jb,I.ec);G=mz(I);H=kB(H,I);H[0]&&(G+=" ("+H[0]+")");break;default:G="imm("+wa(P)+")"}H=G}else I==lB?(b.ec?(H=8,G=iz(a,b,4)):(H=4,G=a.Vc(b,2)),H="["+q(G,H)+"]"):I==mB?(H=P==U?a.ya(b,1)<<24>>24:a.nb(b,!0),G=b.Ja+H&(b.Jb?-1:65535),H=q(G,b.Jb?8:4),G=kB(a,Py(a,G,b.T)),G[0]&&(H+=" ("+G[0]+")")):I==X?H=P==nB?"ST":P==oB?"ST("+(g&7)+")":hB(a,(G&pB)>>8,G,b):I==qB?H=hB(a,(G&pB)>>8,rB,b):I==sB?H="DS:[SI]":I==tB&&(H="ES:[DI]");if(!H||!H.length){v="INVALID";break}0aA||b>=$z&&80386>a.G.da)return"??";b+=Vz}else if(e==wB)b+=jA;else if(e==xB)b+=yB;else if(e==zB)b+=AB;else if(a=c&UA,a>=T&&(b=Mz&&b<=Tz&&4a.G.da&&(d="\n"+d,c+=e,e="");c+="\n"+DB(a,a.G.ba,b)+" ";80386<=a.G.da&&(e+="\n",c+=DB(a,a.G.Ka,b)+" "+DB(a,a.G.La,b)+"\n");c+=EB(a,"LD",a.G.Gb.T,a.G.Gb.ua,a.G.Gb.ua+a.G.Gb.Sa)+" "+EB(a,"GD",null,a.G.Kb,a.G.Jc)+" "+EB(a,"ID", -null,a.G.Qb,a.G.$c)+" ";c=c+(d+" "+e)+CB(a,jA);80386<=a.G.da&&(c+=CB(a,lA)+CB(a,mA))}else 80386<=a.G.da&&(c+=DB(a,a.G.Ka,b)+" "+DB(a,a.G.La,b)+" ");return c+=CB(a,oA)+BB(a,"V")+BB(a,"D")+BB(a,"I")+BB(a,"T")+BB(a,"S")+BB(a,"Z")+BB(a,"A")+BB(a,"P")+BB(a,"C")}l.bj=function(a,b){return a[0]>b[0]?1:a[0]>>0,p];var H=Fa(A,u,a.bj);0>H&&A.splice(-(H+1),0,u)}J&&(v.a=J.replace(/''/g,'"'))}a.F.push({fi:b,kn:c,T:d,Ja:e,za:f,Zm:g,Id:h,Li:m})} -function kz(a,b,c){for(var d=0;d>>0,f=a.Vb(b)>>>0,g=0;g>>0,p=h.za;null!=p&&(p>>>=0);var v=h.Zm;48==k&&(k=40);if(k==b.T&&e>=m&&e=p&&fb[0]?1:a[0]>>0,p];var H=Fa(A,u,a.cj);0>H&&A.splice(-(H+1),0,u)}J&&(v.a=J.replace(/''/g,'"'))}a.F.push({hi:b,mn:c,T:d,Ja:e,za:f,Zm:g,Id:h,Mi:m})} +function kz(a,b,c){for(var d=0;d>>0,f=a.Vb(b)>>>0,g=0;g>>0,p=h.za;null!=p&&(p>>>=0);var v=h.Zm;48==k&&(k=40);if(k==b.T&&e>=m&&e=p&&fc?(a.O("out of data at address "+mz(b)),p=!0):(a.ub(b,c,1,!0),m++)})})(a,f);Fd(a.G, +function KB(a,b){if(b[1]&&"?"!=b[1]){var c="json"==b[1],d=0,e=0,f=c?{}:wz(a,b[1]);if(f){var g=Ey(a,b[2],"drive #");if(void 0!==g){if(!c){d=Ey(a,b[3],"sector #");if(void 0===d)return;e=Ey(a,b[4],"# of sectors");void 0===e&&(e=1)}var h=a.cb;2<=g&&a.Pa&&(g-=2,h=a.Pa);if(h){var k=h.dj(g);if(k)if(k.va)if(c)LB(a.na),a.O(hw(k.va));else if(h.Vk(k,d,e)){var m=0,p=!1;for(b=mz(f);!p&&0c?(a.O("out of data at address "+mz(b)),p=!0):(a.ub(b,c,1,!0),m++)})})(a,f);Fd(a.G, !0);a.O(m+" bytes read at "+b)}else a.O("sector "+d+" request out of range");else a.O("drive "+g+" not loaded");else a.O("invalid drive: "+g)}else a.O("disk controller not present")}}}else a.O("load commands:"),a.O("\tl [address] [drive #] [sector #] [# sectors]")} function vA(a,b){var c;if(b&&"?"==b[1])a.O("register commands:"),a.O("\tr\tdump registers"),a.Kc&&a.O("\trfp\tdump floating-point registers"),a.O("\trp\tdump all registers"),a.O("\trx [#]\tset flag or register x to [#]");else{null==c&&(c=!0);if(b&&1f;f++){var g=c;d=null;if(f=a.ra&&(h=null);switch(h){case "AL":a.G.D= @@ -815,32 +816,32 @@ y(a.G)&-65536|g&65535);break;case "BP":a.G.N=a.G.N&-65536|g&65535;break;case "SI case "A":g?wg(a.G):ug(a.G);break;case "Z":g?xg(a.G):vg(a.G);break;case "S":g?(d=a.G,d.resultType&=-17,d.P|=128):(d=a.G,d.resultType&=-17,d.P&=-129);break;case "I":g?(d=a.G,d.P|=512):(d=a.G,d.P&=-513);break;case "D":g?(d=a.G,d.P|=1024):(d=a.G,d.P&=-1025);break;case "V":g?qg(a.G):rg(a.G);break;default:var k=!0;if(80286<=a.G.da)switch(k=!1,h){case "MS":yg(a.G,g);break;case "TR":-1===a.G.ka.load(g)&&(f=!1);break;default:if(k=!0,80386<=a.G.da)switch(k=!1,h){case "EAX":a.G.D=g;break;case "EBX":a.G.H=g; break;case "ECX":a.G.I=g;break;case "EDX":a.G.L=g;break;case "ESP":ne(a.G,g);break;case "EBP":a.G.N=g;break;case "ESI":a.G.K=g;break;case "EDI":a.G.J=g;break;case "FS":a.G.Ka.load(g);break;case "GS":a.G.La.load(g);break;case "CR0":a.G.ra=g;fk.call(a.G,g);break;case "CR2":a.G.pd=g;break;case "CR3":a.G.wc=g;a.G.wc=g;uc(a.G);break;default:k=!0}}if(k){a.O("unknown register: "+d);return}}if(!f){a.O("invalid value: "+b);return}Fd(a.G);a.O("updated registers:")}}a.O(FB(a,e));c&&(a.N=Py(a,z(a.G),a.G.ba.T), wA(a,mz(a.N)))}}function NB(a,b){b=Da(b);var c=b.match(/^(['"])(.*?)\1$/);c?a.O(pA(a,c[2])):Ky(a,b,!1)}function OB(a,b,c){for(var d=null,e=b.Ja,f=e,g=1;6>=g&&e;g++){if(2e&&(e=1);4096h[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.O(m)}h[3]&&(g=h[3],f=null);f=EA(a,b,g,f);b.Yg||d||d++;a.O(f);a.N=b;e-=b.za-k;c++}}} -l.yg=function(a,b,c){if(b)if(a){0>this.A&&this.C.length&&(this.A=0);if(0>this.A||a!=this.C[this.A])this.C.splice(0,0,a),this.A=0;this.A--}else a=this.C[this.A+1];b=[];if(a){a=a.toLowerCase().replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(Da(a.substring(d,f))),d=f+1}}return b}; +function PB(a,b,c){var d="t"!=b;c=Ey(a,c,null,!0)||1;var e=1==c?0:1;"tc"==b&&(e=c,c=1);$a(c,function(){return Rb(a,!0)&&nz(a,e,d,!1)},function(){Fd(a.G);Rb(a,!1)})}function vB(a,b,c){if(a.Zg=b)null!=a.lj&&(a.Jb=a.lj),null!=a.kj&&(a.ec=a.kj),a.lj=a.Jb,a.kj=a.ec;a.Ee=c||0} +function wA(a,b,c,d){if(b=wz(a,b,!0)){void 0===d&&(d=1);var e=256;if(void 0!==c){d=wz(a,c,!0);if(!d||d.Jae&&(e=1);4096h[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.O(m)}h[3]&&(g=h[3],f=null);f=EA(a,b,g,f);b.Zg||d||d++;a.O(f);a.N=b;e-=b.za-k;c++}}} +l.zg=function(a,b,c){if(b)if(a){0>this.A&&this.C.length&&(this.A=0);if(0>this.A||a!=this.C[this.A])this.C.splice(0,0,a),this.A=0;this.A--}else a=this.C[this.A+1];b=[];if(a){a=a.toLowerCase().replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(Da(a.substring(d,f))),d=f+1}}return b}; function DA(a,b,c){var d=!0;try{if(!b.length||"end"==b)a.fa&&(a.O("ended assemble at "+mz(a.ea)),a.N=a.ea,a.fa=!1),b="";else if(!c){var e=">> ";a.G.ra&1&&(e=a.G.P&131072?"-- ":"## ");a.O(e+b)}var f=b.charAt(0);if('"'==f||"'"==f)return!0;a.Aa=null;if(Ob(a)&&0p||"z">>20;Ra.Qi=a.G.wc+Ra.Dk;Ra.pb=vf.aa[(Ra.Qi&vf.C)>>>vf.A];Ra.wj=Ra.pb.Nd(Ra.Dk);Ra.Ek=($g&4190208)>>>10;Ra.Ri=(Ra.wj&-4096)+Ra.Ek;Ra.qb=vf.aa[(Ra.Ri&vf.C)>>>vf.A];Ra.xj=Ra.qb.Nd(Ra.Ek);Ra.ml=(Ra.xj&-4096)+($g&4095)}if(uf=Ra){a.O("linear PDE addr PDE PTE addr PTE physical");a.O("--------- ---------- -------- ---------- -------- ----------");var ij="%"+q($g);ij+=" %%"+Bz(uf.Qi,uf.wj);ij+=" %%"+ -Bz(uf.Ri,uf.xj,!0);ij+=" %%"+q(uf.ml);a.O(ij)}else a.O("unsupported operation")}}else a.O("missing address")}else{if("d"==ra){if("disk"==ib){Z[0]="l";Z[1]="json";KB(a,Z);break a}for(hb in Zb)if(Z[1]==hb){var Nt=a.Fa[hb];Nt?(Z.shift(),Z.shift(),Nt(Z)):a.O("no dump registered for "+ib);break a}ib||(ra=a.mb||"db")}if("dh"==ra){var Ot=ib,Pt=Sb,ah=Jb;ah=void 0===ah?"history":ah;var Qt="",Rt=0,Rc=a.qa,rd=a.U;if(rd.length){var Ac=+Ot||a.Ra,bh=+Pt||10;isNaN(Ac)?Ac=bh:Qt="more ";Ac>rd.length&&(a.O("note: only "+ -rd.length+" available"),Ac=rd.length);Rc-=Ac;0>Rc&&(null==rd[rd.length-1].T?(Ac=Rc+Ac,Rc=0):Rc+=rd.length);var Dm=[];"call"==Pt&&(bh=1E5,Dm=["CALL"]);for(void 0!==Ot&&a.O(Ac+" instructions earlier:");0=rd.length&&(Rc=0);a.Ra=Ac;Rt++;bh--}}Rt||(a.O("no "+ -Qt+"history available"),a.Ra=void 0)}else if("di"==ra){Z.shift();var Em=Z[0];if(Em){var dh=Ey(a,Em);if(void 0===dh||0>dh||255"abwd".indexOf(ra[1]))a.O("unrecognized dump command"); -else{a.mb=ra;var Fe=wz(a,ib);if(Fe&&(null!=Fe.T||null!=Fe.za)){var wf=0;if(Sb){if("l"==Sb.charAt(0))Sb=Sb.substr(1)||Jb,wf=Ey(a,Sb);else{var Yt=wz(a,Sb);if(!Yt)break a;wf=Yt.Ja-Fe.Ja+1}if(0>wf||65536>4||1,Hm=4==xf?16:a.D;"a"==ra[1]&&(Fm=!0,Gm=25,Hm=160,eh=Gm*Hm);for(;Gm--&&0mj?String.fromCharCode(mj):Fm?"":".";eh--}Ge&&(Ge+="\n");Ge=Fm?Ge+lj:Ge+(ib+" "+Jm+Ca(lj,lj.length+3*fh+1,!0))}Ge&&a.O(Ge.replace(/\s*$/,""));a.Ca=Fe}}}}}break;case "e":if("else"==g[0])break;var nj=1,Zt=255,$t=a.ya,au=a.ub;"ew"==g[0]&&(nj=2,Zt=65535,$t=a.Vc,au=a.al);var bu=nj<<1,cu=g[1];if(null==cu)a.O("edit memory commands:"),a.O("\teb [a] [...] edit bytes at address a"),a.O("\tew [a] [...] edit words at address a");else{var oj=wz(a,cu);if(oj)for(var pj= -2;pjOm;){for(var td=null,KC=256;$d.Ja>>>0>>0;){ih.Ja=a.nb($d,!0);if(null==$d.za||!KC--)break;ih.T=fu;if(td=OB(a,ih))break;ih.T=a.nb($d);if(td=OB(a,ih,!0)){fu=a.nb($d,!0);0>>20;Ra.Ri=a.G.wc+Ra.Ek;Ra.pb=xf.Z[(Ra.Ri&xf.C)>>>xf.A];Ra.yj=Ra.pb.Nd(Ra.Ek);Ra.Fk=($g&4190208)>>>10;Ra.Si=(Ra.yj&-4096)+Ra.Fk;Ra.qb=xf.Z[(Ra.Si&xf.C)>>>xf.A];Ra.zj=Ra.qb.Nd(Ra.Fk);Ra.nl=(Ra.zj&-4096)+($g&4095)}if(wf=Ra){a.O("linear PDE addr PDE PTE addr PTE physical");a.O("--------- ---------- -------- ---------- -------- ----------");var ij="%"+q($g);ij+=" %%"+Bz(wf.Ri,wf.yj);ij+=" %%"+ +Bz(wf.Si,wf.zj,!0);ij+=" %%"+q(wf.nl);a.O(ij)}else a.O("unsupported operation")}}else a.O("missing address")}else{if("d"==ra){if("disk"==ib){Z[0]="l";Z[1]="json";KB(a,Z);break a}for(hb in Zb)if(Z[1]==hb){var Nt=a.Fa[hb];Nt?(Z.shift(),Z.shift(),Nt(Z)):a.O("no dump registered for "+ib);break a}ib||(ra=a.mb||"db")}if("dh"==ra){var Ot=ib,Pt=Sb,ah=Jb;ah=void 0===ah?"history":ah;var Qt="",Rt=0,Rc=a.qa,rd=a.U;if(rd.length){var Ac=+Ot||a.Ra,bh=+Pt||10;isNaN(Ac)?Ac=bh:Qt="more ";Ac>rd.length&&(a.O("note: only "+ +rd.length+" available"),Ac=rd.length);Rc-=Ac;0>Rc&&(null==rd[rd.length-1].T?(Ac=Rc+Ac,Rc=0):Rc+=rd.length);var Cm=[];"call"==Pt&&(bh=1E5,Cm=["CALL"]);for(void 0!==Ot&&a.O(Ac+" instructions earlier:");0=rd.length&&(Rc=0);a.Ra=Ac;Rt++;bh--}}Rt||(a.O("no "+ +Qt+"history available"),a.Ra=void 0)}else if("di"==ra){Z.shift();var Dm=Z[0];if(Dm){var dh=Ey(a,Dm);if(void 0===dh||0>dh||255"abwd".indexOf(ra[1]))a.O("unrecognized dump command"); +else{a.mb=ra;var Fe=wz(a,ib);if(Fe&&(null!=Fe.T||null!=Fe.za)){var yf=0;if(Sb){if("l"==Sb.charAt(0))Sb=Sb.substr(1)||Jb,yf=Ey(a,Sb);else{var Yt=wz(a,Sb);if(!Yt)break a;yf=Yt.Ja-Fe.Ja+1}if(0>yf||65536>4||1,Gm=4==zf?16:a.D;"a"==ra[1]&&(Em=!0,Fm=25,Gm=160,eh=Fm*Gm);for(;Fm--&&0mj?String.fromCharCode(mj):Em?"":".";eh--}Ge&&(Ge+="\n");Ge=Em?Ge+lj:Ge+(ib+" "+Im+Ca(lj,lj.length+3*fh+1,!0))}Ge&&a.O(Ge.replace(/\s*$/,""));a.Ca=Fe}}}}}break;case "e":if("else"==g[0])break;var nj=1,Zt=255,$t=a.ya,au=a.ub;"ew"==g[0]&&(nj=2,Zt=65535,$t=a.Vc,au=a.bl);var bu=nj<<1,cu=g[1];if(null==cu)a.O("edit memory commands:"),a.O("\teb [a] [...] edit bytes at address a"),a.O("\tew [a] [...] edit words at address a");else{var oj=wz(a,cu);if(oj)for(var pj= +2;pjNm;){for(var td=null,KC=256;$d.Ja>>>0>>0;){ih.Ja=a.nb($d,!0);if(null==$d.za||!KC--)break;ih.T=fu;if(td=OB(a,ih))break;ih.T=a.nb($d);if(td=OB(a,ih,!0)){fu=a.nb($d,!0);0=this.D||(this.D=1);this.F=0;this.pa=a.busWidth||a.buswidth;this.A=kC;this.P=null;this.L=this.ha=!1;this.ra=Ad(this,"url")||"";this.ta=(Math.random()+.1).toString(36).substr(2,12);this.B=lC(this);if(this.G=xb("CPU",this.id)){this.ca=xb("Debugger",this.id);this.C=[];for(b=null;b=ac(this,"Video",b);)this.C.push(b);this.oa=new oc({id:this.de+".bus", -busWidth:this.pa},this.G,this.ca);var e=Bb(this.id);this.K=(this.J=xb("Panel",this.id))&&this.J.ma.print;this.ka=this.Da;this.la=this.print;this.qa=this.O;this.K&&(this.ka=this.J.Da,this.la=this.J.print,this.qa=this.J.O);for(b=0;b\nLicense: GPL version 3 or later "); -for(b=0;bkC){if(d.load(this.P)){this.H=new ag(this,"1.37.0",vC);this.H.load()&&(a!=uC&&wC(this,d)&&(a=xC),yC(this.H));this.H.set(tC,Ga("Y-m-d H:i:s"));zC(this.H);var e=this.A&&!this.L;if(a==uC||tb("Click OK to restore the previous PCx86 machine state.")){if(c=sC(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?d.load(g):("error"==f&&"no machine state"!= -g?(this.Da("Error: "+g),"unable to verify user"==g&&(Ta(AC,""),this.B=null)):this.O(f+": "+g),yC(d),d.load()?(c=sC(d),e=!0):c=!1))}e&&qC(this,c?d:null)}else a==xC&&d.clear()}else qC(this);delete this.P;delete this.V}e=Bb(this.id);for(f=0;fa[1];a=a[2];if(d=this.ma.power)d.textContent="Shutdown";this.Z.ac=!0;this.G&&(BC(this,this.G, -b,c,a),this.G.he());this.fa&&(wC(this,b),b.clear());!c&&this.H&&(this.H.clear(),delete this.H);this.F=0;Db(this.de,Ad(this,"autoScript"))};function wC(a,b){if(!a.Z.we){if(tb("There may be a problem with your PCx86 machine.\n\nTo help us diagnose it, click OK to send this PCx86 machine state to http://www.pcjs.org.")){var c=a.B||"";b=b.toString();var d={app:"PCx86",ver:"1.37.0"};d.url=a.ra;d.user=c;d.type="bug";d.data=b;Ma("http://www.pcjs.org/api/v1/report",d,!0)}return!0}return!1} -function QB(a,b,c){var d="none";if(a.F)return null;a.F--;var e=new ag(a,"1.37.0"),f=new ag(a,"1.37.0",rC),g=Ga("Y-m-d H:i:s");f.set(tC,g);e.set(tC,g);e.set(CC,"1.37.0");e.set(DC,window?window.location.href:null);e.set(EC,Oa());if(a.G&&a.G.Zb){var h=a.G.Zb(b,c);"object"===typeof h&&e.set(a.G.id,h);c&&(a.G.Z.ac=!1,!1===h&&(d=null))}g=Bb(a.id);for(var k=0;k=this.D||(this.D=1);this.F=0;this.pa=a.busWidth||a.buswidth;this.A=kC;this.P=null;this.L=this.ha=!1;this.ra=Bd(this,"url")||"";this.ta=(Math.random()+.1).toString(36).substr(2,12);this.B=lC(this);if(this.G=xb("CPU",this.id)){this.ca=xb("Debugger",this.id);this.C=[];for(b=null;b=ac(this,"Video",b);)this.C.push(b);this.oa=new oc({id:this.de+".bus", +busWidth:this.pa},this.G,this.ca);var e=Bb(this.id);this.K=(this.J=xb("Panel",this.id))&&this.J.ma.print;this.ka=this.Da;this.la=this.print;this.qa=this.O;this.K&&(this.ka=this.J.Da,this.la=this.J.print,this.qa=this.J.O);for(b=0;b\nLicense: GPL version 3 or later "); +for(b=0;bkC){if(d.load(this.P)){this.H=new ag(this,"1.37.1",vC);this.H.load()&&(a!=uC&&wC(this,d)&&(a=xC),yC(this.H));this.H.set(tC,Ga("Y-m-d H:i:s"));zC(this.H);var e=this.A&&!this.L;if(a==uC||tb("Click OK to restore the previous PCx86 machine state.")){if(c=sC(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?d.load(g):("error"==f&&"no machine state"!= +g?(this.Da("Error: "+g),"unable to verify user"==g&&(Ta(AC,""),this.B=null)):this.O(f+": "+g),yC(d),d.load()?(c=sC(d),e=!0):c=!1))}e&&qC(this,c?d:null)}else a==xC&&d.clear()}else qC(this);delete this.P;delete this.V}e=Bb(this.id);for(f=0;fa[1];a=a[2];if(d=this.ma.power)d.textContent="Shutdown";this.aa.ac=!0;this.G&&(BC(this, +this.G,b,c,a),this.G.he());this.fa&&(wC(this,b),b.clear());!c&&this.H&&(this.H.clear(),delete this.H);this.F=0;Db(this.de,Bd(this,"autoScript"))};function wC(a,b){if(!a.aa.we){if(tb("There may be a problem with your PCx86 machine.\n\nTo help us diagnose it, click OK to send this PCx86 machine state to http://www.pcjs.org.")){var c=a.B||"";b=b.toString();var d={app:"PCx86",ver:"1.37.1"};d.url=a.ra;d.user=c;d.type="bug";d.data=b;Ma("http://www.pcjs.org/api/v1/report",d,!0)}return!0}return!1} +function QB(a,b,c){var d="none";if(a.F)return null;a.F--;var e=new ag(a,"1.37.1"),f=new ag(a,"1.37.1",rC),g=Ga("Y-m-d H:i:s");f.set(tC,g);e.set(tC,g);e.set(CC,"1.37.1");e.set(DC,window?window.location.href:null);e.set(EC,Oa());if(a.G&&a.G.Zb){var h=a.G.Zb(b,c);"object"===typeof h&&e.set(a.G.id,h);c&&(a.G.aa.ac=!1,!1===h&&(d=null))}g=Bb(a.id);for(var k=0;k/g.exec(a)){var e=d[2];b("Loading "+e+"...");Ma(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,p=/( [a-z]+=)(['"])(.*?)\2/gi;m=p.exec(f);)k=0>k.toLowerCase().indexOf(m[1].toLowerCase())?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+ "> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/,"");a=a.replace(d[0],g);VC(a,b,c)}})}else c(a,null)} function WC(a,b,c,d){function e(a){if(void 0===h){var b=g&&zb(g,"machine-warning");h=b&&b[0]||g}h&&(h.innerHTML=Aa(a))}function f(a){e("Error: "+a);k&&(--SC||lb(!0));k=!1}var g,h,k=!0;SC++;sb[a]={};try{if(g=document.getElementById(a)){var m;if("object"==typeof resources&&(m=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],v=document.createElement("style");v.type="text/css";v.styleSheet?v.styleSheet.cssText=m:v.appendChild(document.createTextNode(m));p.appendChild(v)}c|| -(c="/versions/pcx86/1.37.0/components.xsl");m=function(d,h){h?TC(c,null,null,!1,e,function(d,k){k?(rb(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(k=h.transformNode(k))?(g.outerHTML=k,--SC||lb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(k),(k=d.transformToFragment(h,document))?g.parentNode?(g.parentNode.replaceChild(k,g),--SC||lb(!0)):f("invalid machine element: "+ +(c="/versions/pcx86/1.37.1/components.xsl");m=function(d,h){h?TC(c,null,null,!1,e,function(d,k){k?(rb(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(k=h.transformNode(k))?(g.outerHTML=k,--SC||lb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(k),(k=d.transformToFragment(h,document))?g.parentNode?(g.parentNode.replaceChild(k,g),--SC||lb(!0)):f("invalid machine element: "+ a):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?TC(b,a,d,!0,e,m):UC(b,null,a,d,!1,e,m)}else f("missing machine element: "+a)}catch(u){f(u.message)}return k}function XC(a,b,c,d){lb(!1);return WC(a,b,c,d)}window.embedPC=XC;window.embedPCx86=XC; window.commandMachine=function(a,b,c,d,e,f){if("script"==e)return Db(c,f)?(b&&(a.disabled=!0),!0):!1;if(d){var g=xb(d,c+".machine");if(g){var h=g.exports;if(h&&(h=h[e]))return h.call(g,f)?(b&&(a.disabled=!0),!0):!1}}console.log("unimplemented: commandMachine('"+c+"','"+d+"','"+e+"','"+f+"')");return!1};window.enableEvents=lb;window.sendEvent=nb; function YC(a,b,c,d){if(!c&&b){d.push(b);a=sb[d[0]];b=null;for(var e in a)if(za(e,"components.xsl")){b=e.replace(".xsl",".css");break}b?Ma(b,null,!0,function(a,b){ZC(b,d)}):ZC(null,d)}else kb("Error ("+c+") requesting "+a)} function ZC(a,b){var c,d,e=b[0],f=b[1];var g=b[4];if(g=g.match(/^(\s*\(function\(\)\{)([\s\S]*)(}\)\(\);)/)){var h=sb[e],k={},m;for(m in h){var p=h[m],v=ya(m);if("xml"==v){for(v=/[ \t]*]*path=(['"])(.*?)\1.*?<\/disk>\n?/g;c=v.exec(h[m]);){var u=c[2];u&&!h[u]&&(p=p.replace(c[0],""))}c=m=xa(m)}else"xsl"==v&&(d=m=xa(m));k[m]=p}a&&(k[m="css"]=a);b[2]&&(k[m="parms"]=b[2]);b[3]&&(k[m="state"]=b[3]);c&&d?(a=JSON.stringify(k),f+=".js",g=g[1]+"var resources="+a+";"+g[2]+g[3],g=g.replace(/\u00A9/g, "©"),a=Za(g,"javascript",!1,f),a=a+(', copy it to your web server as "'+f+'", and then add the following to your web page:\n\n')+('
\n')+"...\n",a=a+(' +
+ + + + + + + + + + + + + +
+ + + + js + , + + +
+
+ + + + + + + + + + + + + , + + + + + + + + + + + + .machine + . + + + + + + + + + + + + + + border:1px solid black;border-radius:10px; + border:; + + + + + + left:; + + + + + + top:; + + + + + + + + width:; + width:auto;max-width:; + + + + + + + + height:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto; + position:; + position:absolute; + + + + + overflow:auto;width:100%; + + background-color:; + background-color:; + + + + + - -component + +
+ + + + + + +
+ +
+
+ +
+ +
+
+ +
+ + +
[XML]
+ +
+ +
+
+
+
+ + + + + text-align:center; + + + +

+
+ + +
+
+ + + + type:'' + + + binding:'' + + + + border:1px solid black; + border:; + + + + + + width:; + + + + + + height:; + + + + + + left:; + + + + + + top:; + + + + + + position:absolute; + float:left; + float:right; + margin:0 auto; + ; + float:left; + + + + + + + + +
+ + + font-size:; + + + + + -label + + + width:; + + + + + + +
+
+
+ + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+
+
+ +
+
+ +

+
+ +
+
+
+ + +
+
+
+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + null + + + + + + ,autoStart: + + + + + + + + + + + + + + + 600 + + + + + keyboard + ,model: + + + + + + + + + + + + + + + false + + + + + serial + ,demo: + + + + + + + + + + + + + + disk + + + + + + + + + + + + + + + 0 + + + + + + + + + + + rom + ,size:,image:'' + + + + + + + + + + + + + + + 0 + + + + + ram + ,size: + + + + + + + + + + + + + + + 600 + + + + + + + 256 + + + + + + + 224 + + + + + + + black + + + + + + 32 + + + + + + 32 + + + + + + + 0 + + + + + + + 0 + + + + + + + + + + + + + + null + + + + + video + ,model:,screenWidth:,screenHeight:,charCols:,charRows:,charWidth:,charHeight:,charSet:'',screenColor:'',smoothing: + + + + + + + + + + + + + + debugger + + + + + + + + + + + + + + panel + + + + + + + + + + + + + [ + {} + , + ] + + + + computer + ,modules: + + + + + type:'',refID:'',start:,end: + + + diff --git a/versions/c1pjs/1.37.1/document.css b/versions/c1pjs/1.37.1/document.css new file mode 100644 index 000000000..7072b406e --- /dev/null +++ b/versions/c1pjs/1.37.1/document.css @@ -0,0 +1,162 @@ +@CHARSET "UTF-8"; + +.page { + margin: 2% 2%; + padding: 2% 2%; + min-width: 30em; + overflow: auto; + font-size: large; + font-family: Helvetica, Arial, sans-serif; + background: #303030; + color: #ccc; + +} +.page-header { +} +.page-header-title { + text-align: center; + +} +.page a { + color: #7fc07f; + text-decoration: none; +} +a.footlink, a.paralink { + text-decoration: none; +} +a.footlink:link, a.paralink:link { + color: blue; +} +a.footlink:visited, a.paralink:visited { + color: blue; +} +.galleryitem { + float: left; + width: 200px; +} +.item { + float: left; + width: 2em; + text-indent: 1em; +} +.list { + margin-left: 3em; + text-indent: 0; + text-align: justify; +} +ul { + list-style: none; +} +div.pnumber { + float: left; + width: 2em; + text-indent: 1em; +} +div.pitem { + margin-left: 10em; +} +p.indent, .justified p { + text-indent: 2em; + text-align: justify; + line-height: 1.5em; +} +p.noindent { + text-indent: 0; + text-align: justify; +} +p.center, .center { + text-align: center; +} +li.para { + margin-top: 1em; + margin-bottom: 1em; +} +.left { + text-align: left; +} +.right { + text-align: right; +} +blockquote.tag { + font-size: small; + font-family: Monaco, Fixed, monospace; + margin-top: 0; + margin-bottom: 0; +} +.blockquote { + padding-left: 1em; + text-indent: 0; + text-align: justify; +} +.italics { + font-style: italic; +} +.medium { + font-size: medium; +} +.small { + font-size: x-small; +} +.smallcaps { + font-variant: small-caps; +} +.strike { + text-decoration: line-through; +} +.summation, .bracelist { + display: inline-block; + position: relative; + vertical-align: middle; + text-align: center; + margin-bottom: 0.5ex; + text-indent: 0; +} +.bracelist-symbol { + font-size: 3em; + vertical-align: -40%; +} +.summation .summation-lower, .summation .summation-upper, .bracelist-item { + display: block; + font-size: 75%; + text-align: center; +} +.summation .summation-upper { + margin-bottom: 0; + margin-left: 0.8ex; + font-style: italic; +} +.summation .summation-lower{ + margin-bottom: -0.6ex; + font-style: italic; +} +.summation .summation-symbol { + font-size: 2em; +} +p sup { + vertical-align: baseline; + position: relative; + bottom: .5em; + font-size: small; +} +p sub { + vertical-align: baseline; + position: relative; + bottom: -.5em; + font-size: small; +} +.footnote { + font-size: medium; + text-indent: 1em; + text-align: justify; + margin-top: .5em; +} +.image-right { + float: right; + margin-left: 1em; + margin-top: 1em; + margin-bottom: 1em; +} +.image-caption { + font-size: small; + text-align: center; +} \ No newline at end of file diff --git a/versions/c1pjs/1.37.1/document.xsl b/versions/c1pjs/1.37.1/document.xsl new file mode 100644 index 000000000..c787e7e54 --- /dev/null +++ b/versions/c1pjs/1.37.1/document.xsl @@ -0,0 +1,452 @@ + + + + + +]> + + + + + + + + + +

+
+ + + + + + + +

+
+ +

+
+
+
+ + + + + + +
+
+ + +
+ +   + + +
+
+ +
+
+ + + + + + + + + + + + + + + + +

+
+ + +

+
+ + +

+
+ + +
+
+ + +
+
+ + + + + + + + + + + + + + +
+
+ + +
+
+ + +
  • +
    + + +
    image
    +
    + + +
    +
    + + + + +
    {.}
    +
    + +
    {.}
    +
    +
    +
    + + + + + + + + + + < + > + + + + × + + ÷ + σ + + + + + + + + + + + + { + + + + + + + + + + [] + + + + +
    + +
    +
    + + + , and + + + + + MDY + + + + + + + + + + + + + + + + + + + + January + February + March + April + May + June + July + August + September + October + November + December + + + , + + + + + +

    + +
    +
    + + +
    + {.}
    +
    +
    +
    + + + +

    Timeline

    +
    + +

    +
    +
    + +
    +
    + + + + + + + + + +

    +
    + +
    +
    +
    + + + +

    People

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + +

    +
      + +
    +
    + + + + + + + + + + +
  • + +
  • +
    + + + +

    +
    +

    + +

    +
    +
    + + + + false + + + + + + [Original] + + + + + + + + + + [] + + +
    by
    + + +
    + [Source: + + + + + + + ] +
    +
    +
    + + + +

    Resources

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + + +

    +
    +
      + +
    +
    + + +
  • +
    + + + +

    +
    +
    + +
    +
    + + + +

    +
    + +
    + + + +

    +
    +
      + +
    +
    + + + + + +
      + +
    +
    + + + + +
  • +
    + +
  • +
    + +
  • +
    +
    +
    + + +
  • +
    + + + + + + + + + + +
    + < ="" + + ></> + ></> + /> + +
    +
    + +
    diff --git a/versions/c1pjs/1.37.1/machine.xsl b/versions/c1pjs/1.37.1/machine.xsl new file mode 100644 index 000000000..a97603901 --- /dev/null +++ b/versions/c1pjs/1.37.1/machine.xsl @@ -0,0 +1,61 @@ + + + + +]> + + + + + + + + + + + + + + + + + js + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    +
    + + + + + , + +
    +
    + +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/c1pjs/1.37.1/manifest.xsl b/versions/c1pjs/1.37.1/manifest.xsl new file mode 100644 index 000000000..ea3a0fcc9 --- /dev/null +++ b/versions/c1pjs/1.37.1/manifest.xsl @@ -0,0 +1,247 @@ + + + + +]> + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Document Manifest

    +
    +
      + + + + None + + + + + + + + + + + + + + + + +
    +
    +
    +

    + +
    +
    +
    + + +
    + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Software Manifest

    +
    +
      + + + + None + + + + + Unknown + + + + + None + + + + + None + + + + + + + + + + + + + UpdatedReleased + + Unknown + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    + + + + + + + +

    No default machine specified for '' in manifest.xml

    +
    + +
    +
    +
    + + + + -dbg + + + + + + +
    + + + + + Unknown + +
  • +
      + + + + + + + + +
    • + + + + + + + + + + + + + + + + + + + + + + + + + +
        + +
      • + + + + + + +
      • +
        +
      +
      +
    • +
      + + + + + + + + +
    +
  • +
    +
    + +
    diff --git a/versions/c1pjs/1.37.1/outline.xsl b/versions/c1pjs/1.37.1/outline.xsl new file mode 100644 index 000000000..fc0c2a35d --- /dev/null +++ b/versions/c1pjs/1.37.1/outline.xsl @@ -0,0 +1,47 @@ + + + + +]> + + + + + + + + + + + + + + + + + + <xsl:value-of select="title"/><xsl:text> | </xsl:text><xsl:value-of select="$SITEHOST"/> + + + + + +
    +
    + +
    +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pc8080/1.37.1/common.css b/versions/pc8080/1.37.1/common.css new file mode 100644 index 000000000..a569abc64 --- /dev/null +++ b/versions/pc8080/1.37.1/common.css @@ -0,0 +1,278 @@ +@CHARSET "UTF-8"; +/** + @author Jeff Parsons (@jeffpar) + @website http://www.pcjs.org/ + @created 2013-05-05 + @modified 2014-02-23 + @license http://www.gnu.org/licenses/gpl.html + */ +body { + margin: 0; + background: #202020; +} +h1, h2 { + margin-top: 0; + color: #cccccc; +} +h1, h2, h3, h4 { + word-wrap: break-word; +} + +h4 a { + color: #cccccc !important; +} +p { + line-height: 1.5em; +} +img { + max-width: 100%; +} +a img { + vertical-align: bottom; +} +pre, code { + color: #000000; + background-color: #cccccc; + font-family: Monaco, Consolas, "Lucida Console", monospace; + font-size: 12px; +} +pre { + margin: 1em 2em; + padding: 1em; + border-radius: 5px; + overflow: auto; +} +code { + padding: 1px; +} +pre a, code a { + color: #006400 !important; +} +.common { + width: 100%; + margin: 0 auto; + color: #cccccc; +} +.common a { + + color: #7fc07f; + text-decoration: none; +} +.common hr { + border-color: #808080; +} +.common a:hover { + text-decoration: underline; +} +.common, .machine { + font-family: "Helvetica Neue", Helvetica, Arial, Geneva, sans-serif; + font-size: 15px; +} +.machine { + + overflow: hidden; +} +.c1pjs { + overflow: visible; +} +.machine-placeholder { + text-align: center; + font-weight: bold; +} +.machine-floating { + position: relative; + z-index: auto; + background-color: transparent; + padding-right: 0; +} +.machine-sticky { + position: fixed !important; + z-index: 1 !important; + background-color: #404040 !important; + padding-right: 16px !important; + top: 0 !important; +} +.common-top { + background: #202020; + font-size: small; +} +.common-top-left { + float: left; + width: 60%; +} +.common-top-left ul { + line-height: 1.5em; + list-style-type: none; + margin: 0; + padding: 1em 1em 1em 9px; + overflow: hidden; +} +.common-top-left ul li { + display: block; + float: left; +} +.common-top-left ul li a { + border-right: 1px solid #6f6f6f; + padding: 2px 6px 2px 6px; +} +.common-top-left ul li:last-child a { + border-right: none; +} +.common-top-right { + float: right; + width: 40%; +} +.common-top-right p { + float: right; + margin: 0; + padding: 1em; +} +.common-middle { + clear: both; + padding: 1px 1em 1px 1em; + background: #404040; +} +.common-sidebar { + float: left; + font-size: small; + width: 140px; + padding-bottom: 20px; + overflow: hidden; + white-space: nowrap; + word-wrap: break-word; +} +.common-list { + list-style-type: none; + margin-top: 0; + margin-bottom: 0; + padding-left: 0; +} +.common-list li { + + padding-bottom: 7px; +} +.common-list-data { + list-style-type: none; + margin-top: 0; + margin-bottom: 0; + padding-left: 0; +} +.common-list-data li { + line-height: 1.5em; +} +.common-list-data-items, .common-list-data-subitems { + font-size: x-small; + list-style-type: none; + margin-top: 0; + margin-bottom: 0; + padding-left: 2em; +} +.common-list-data-items li, .common-list-data-subitems li { + padding-bottom: 0; +} +.common-main { + margin-left: 150px; + +} +.common-main blockquote { + text-align: justify; +} +.common-image-gallery { + margin: 0 auto; + text-align: center; +} +.common-image-gallery:after { + content: ''; + display: block; +} +.common-image-frame { + display: inline-block; + margin: 8px; + text-align: center; +} +.common-image-link { + padding: 5px; + border: 1px solid black; + border-radius: 5px; + background-color: #FAEBD7; +} +.common-image-label { + font-size: x-small; +} +.common-bottom { + clear: both; + padding-top: 1em; +} +.common-bottom:after { + content: ''; + display: block; + clear: both; +} +.common-reference { + float: left; + font-size: x-small; +} +.common-reference a { + text-decoration: none; +} +.common-copyright { + float: right; + font-size: x-small; +} +.common-copyright a { + text-decoration: none; +} +.md-list { +} +.md-list li { + line-height: 1.5em; + margin-bottom: 1em; +} +.md-list li p { + padding-left: 2em; +} +.md-list-compact { +} +.md-list-compact li { + margin-bottom: 0; +} +.md-list-none { + list-style-type: none; + padding-left: 2em; +} +.md-list-none li { + margin-bottom: 0; +} +@media screen and (max-width: 900px) { + + .common-sidebar { + width: 100%; + white-space: normal; + } + .common-list { + padding-left: 0; + } + .common-list-data { + padding-left: 0; + } + .common-sidebar h4, .common-list li, .common-list-data li, .common-list-data-items li { + width: 130px; + float: left; + overflow: hidden; + vertical-align: top; + padding-right: 1em; + margin-top: 0; + } + .common-list-data-subitems { + display: none; + } + .common-main { + clear: both; + margin-left: 0; + padding-left: 0; + padding-right: 0; + } + .md-list-none { + padding-left: 1em; + } +} diff --git a/versions/pc8080/1.37.1/common.xsl b/versions/pc8080/1.37.1/common.xsl new file mode 100644 index 000000000..d97135ffb --- /dev/null +++ b/versions/pc8080/1.37.1/common.xsl @@ -0,0 +1,58 @@ + + + + + +]> + + + + + + + + + + + + + + + + + + + + + + +
    +
    + +
    +
    +

    Powered by JavaScript, Vanilla JS, and GitHub

    +
    +
    +
    + + +
    +

    + +
    +
    + +
    diff --git a/versions/pc8080/1.37.1/components.css b/versions/pc8080/1.37.1/components.css new file mode 100644 index 000000000..101b964a4 --- /dev/null +++ b/versions/pc8080/1.37.1/components.css @@ -0,0 +1,262 @@ +@CHARSET "UTF-8"; + + +*:not(input,textarea) { + -webkit-user-select: none; +} +.pcjs-embed { +} +.pcjs-embed:after { + clear:both; +} +.pcjs-machine { +} +.pcjs-name, .pcjs-menu { + clear: both; + font-weight: bold; + padding-bottom: 4px; +} +.pcjs-menu { + float: left; +} +.pcjs-canvas { + width: 100%; + height: auto; +} +.pcjs-container { + color: #000000; + position: relative; +} +.pcjs-label { + font-size: small; + line-height: 20px; + vertical-align: middle; + float: left; + font-family: Monaco, "Lucida Console", monospace; +} +.pcjs-controls textarea { + font-family: Monaco, "Lucida Console", monospace; + font-size: x-small; +} +.pcjs-fieldset { + border: none; + margin: 0; + padding: 0; +} +.pcjs-flag { + font-family: Monaco, "Lucida Console", monospace; + font-size: small; + text-align: center; + line-height: 20px; + vertical-align: middle; +} +.pcjs-progress { + height: 20px; + width: 200px; + margin-top: 8px; + border: 1px solid black; + position: relative; +} +.pcjs-progress-bar { + height: 20px; + width: 0; + background-color: gold; + position: absolute; + top: 0; +} +.pcjs-progress-text { + height: 20px; + width: 200px; + font-size: small; + line-height: 20px; + text-align: center; + position: absolute; + top: 0; + z-index: 1; +} +.pcjs-register { + font-family: Monaco, "Lucida Console", monospace; + font-size: small; + text-align: center; + line-height: 20px; + vertical-align: middle; + border: 1px solid black; +} +.pcjs-switches { + float: left; +} +.pcjs-bitBucket { + float: left; + width: 19px; + height: 38px; +} +.pcjs-bitCell { + float: left; + width: 19px; + height: 19px; + margin-right: -1px; + margin-bottom: -1px; + border: 1px solid black; + text-align: center; + line-height: 19px; +} +.pcjs-bitCellLeft { + border-left: 1px solid black; +} +.pcjs-bitLabel { + font-size: xx-small; + text-align: center; +} +.pcjs-description, .pcjs-status { + font-size: x-small; + line-height: 2.0em; +} +.pcjs-key { + border: 1px solid black; + font-size: x-small; + text-align: center; + position: absolute; + height: 34px; + line-height: 34px; + background-color: #ffffff; +} +.pcjs-panel-group { + color: #ffffff; + background-color: #404040; +} +.pcjs-triplet { + padding: 1px; +} +.pcjs-ledlbl { + text-align: center; + font-size: 40%; + background-color: #000000; +} +.pcjs-ledlbl0 { + text-align: right; + font-size: 50%; + background-color: #8d4076; +} +.pcjs-ledlbl1 { + text-align: right; + font-size: 50%; + background-color: #d83662; +} +.pcjs-ledpad { + text-align: center; + font-size: x-small; + line-height: 32px; + background-color: #000000; + border-bottom-left-radius: 20%; + border-bottom-right-radius: 20%; +} +.pcjs-led { + float: left; + width: 8px; + height: 8px; + margin: 4px; + border: 1px solid black; + text-align: center; + vertical-align: middle; + background-color: #000000; +} +.pcjs-rled { + float: left; + width: 8px; + height: 8px; + margin: 4px; + border: 1px solid black; + border-radius: 50%; + text-align: center; + vertical-align: middle; + background-color: #ff0000; + max-width: 50%; + max-height: 50%; +} +.pcjs-swlbl { + text-align: center; + font-size: 40%; + line-height: 16px; + background-color: #000000; + border-top-left-radius: 20%; + border-top-right-radius: 20%; +} +.pcjs-swpad { + height: 32px; + background-color: #000000; +} +.pcjs-switch { + height: 10px; + width: 28px; + margin-top: 0; + max-width: 90%; + background-color: #00ff00; +} +.pcjs-screen { + clear: both; + height: auto; + position: relative; + line-height: 0; +} +.pcjs-screen textarea { + position: absolute; + left: 0; + top: 0; + width: 100%; + height: 100%; + border: 0; + padding: 0; + resize: none; + color: white; + font-family: Monaco, "Lucida Console", monospace; + font-size: medium; + background: rgba(0, 0, 0, .5); + opacity: 0; + line-height: 0; +} +.pcjs-reference { + float: left; + font-size: x-small; +} +.pcjs-reference a { + text-decoration: none; +} +.pcjs-copyright { + float: right; + font-size: x-small; +} +.pcjs-copyright a { + text-decoration: none; +} +@media screen and (max-width: 800px) { + .pcjs-textarea { + width: 100% !important; + } + .pcjs-registers { + width: 100% !important; + max-width: none !important; + padding-left: 0 !important; + padding-right: 0 !important; + } + .pdp11-device { + width: 98% !important; + max-width: none !important; + margin-left: 8px !important; + padding-left: 0 !important; + padding-right: 0 !important; + } +} +@media screen and (min-width: 1200px) { + .machine-left { + max-width: 48%; + float: left; + } + .machine-right { + max-width: 48%; + float: left; + margin-left: 30px; + } + .machine-right + * { + clear: both; + } +} diff --git a/versions/pc8080/1.37.1/components.xsl b/versions/pc8080/1.37.1/components.xsl new file mode 100644 index 000000000..918013e0a --- /dev/null +++ b/versions/pc8080/1.37.1/components.xsl @@ -0,0 +1,1420 @@ + + + +]> + + + + + + + + pc + pcjs + pc8080 + PC8080 + 1.37.1 + www.pcjs.org + #FAEBD7 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + float: + + + + + + + js + + + +
    + + + + + + + + + + js + + + "" + + + + + +
    +
    + + + + + + + + + + + + + + + , + + + + + + + + + + + + + .machine + . + . + + + + + + + + + + + + + + + + + + + + ,comment:'' + + + + + + border:1px solid black;border-radius:15px; + border:; + + + + + + left:; + + + + + + top:; + + + + + + + + width:; + width:;max-width:; + width:auto;max-width:; + + + + + + + + height:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto;clear:both; + position:; + position:relative; + + + + + overflow:auto;width:100%; + + background-color:; + background-color:; + + + + + - -component + +
    + + + + + + +
    + + + + + + + + --object -screen + + +
    +
    + +
    + +
    +
    + + + + +
    + + +
    [XML]
    + +
    + + +
    +
    +
    +
    + + + + + text-align:center; + + + +

    +
    + + +
    +
    + + + + + + +
    +
    + + + + type:'' + + + binding:'' + + + value:'' + + + + border:1px solid black; + border:; + + + + + + width:; + + + + + + height:; + + + + + + left:; + + + + + + top:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto; + clear:both; + position:; + position:relative; + text-align:; + float:left; + + + + + + + + + + + + + + + + + + +
    + + + font-size:; + + + + + -label + + + + width:; + width:; + + + + + + + + text-align:right; + + + + +
    +
    +
    + + + + + + + + + + + + + + + + + + + + +
    +
    + +
    +
    + + +
    +
    +
    + +
    +
    + +
    +
    + +
    +
    +
    +
    +
    + +
    +
    + + + + +
    +
    + +
    +
    +
    + + +
    +
    +
    +
    +
    +
    + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + ; + + + + + + + + + + + + + + + : + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + ; + + + + + + + + + + + + + + + + + + + + + + + + + + + + 8088 + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + + null + + + + + + 0 + + + + + + + -1 + + + + + + + -1 + + + + + + + -1 + + + + + + ,model:'',stepping:'',fpu:,cycles:,multiplier:,autoStart:,addrReset:,csStart:,csInterval:,csStop: + + + + + + + + + + + + + + + 8087 + + + + + + + + + + + + ,model:'',stepping:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + true + + + + + + + false + + + + + + {} + + + + + + + + + + + + + + + + + + + chipset + ,model:'',scaleTimers:,sw1:'',sw2:'',sound:,floppies:,monitor:'',dateRTC:'' + + + + + + + + + + + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + device + ,type:'',baudReceive:,baudTransmit:,autoMount:'' + + + + + + + + + + + + + + + + + + + + keyboard + ,model:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + parallel + ,adapter:,binding:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + + 0 + + + + + + + 0 + + + + + + + false + + + + + serial + ,adapter:,baudReceive:,baudTransmit:,binding:'',tabSize:,charBOL:,upperCase: + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + 0.5 + + + + + + + + + + + mouse + ,adapter:,binding:'',type:'',scaleMouse:,serial:'' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + fdc + ,autoMount:'',sortBy:'' + + + + + + + + + + + + + + + + + + + + + XT + + + + + hdc + ,drives:'',type:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + null + + + + + + + + + + + + + + + + + rom + ,addr:,size:,alias:,file:'',notify:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + null + + + + + + null + + + + + + true + + + + + ram + ,addr:,size:,file:'',load:,exec:,test: + + + + + + + + + + + + + + + + + + + + + null + + + + + + + 256 + + + + + + + 224 + + + + + + + black + + + + + + 0 + + + + + + 0 + + + + + + false + + + + + + 1bpp + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + false + + + + + + 1 + + + + + + 1 + + + + + + + 80 + + + + + + + 25 + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + + + + 0 + + + + + + null + + + + + + 0 + + + + + + 60 + + + + + + 0.5 + + + + + video + ,model:'',mode:,screenWidth:,screenHeight:,screenColor:'',screenRotate:,bufferAddr:,bufferRAM:,bufferFormat:'',bufferCols:,bufferRows:,bufferBits:,bufferLeft:,bufferRotate:,memory:,switches:'',scale:,cellWidth:,cellHeight:,charCols:,charRows:,fontROM:'',fontColor:'',touchScreen:'',autoLock:,aspectRatio:,smoothing:,interruptRate:,refreshRate:,flicker: + + + + + + + + + + + + + + + 16 + + + + + + + + + + + + + + + + + debugger + ,base:,commands:'',messages:'' + + + + + + + + + + + + + + panel + + + + + + + + + + + + + + + + + + + + + true + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + computer + ,autoPower:,busWidth:,resume:'',state:'' + + + + + + + +
    diff --git a/versions/pc8080/1.37.1/document.css b/versions/pc8080/1.37.1/document.css new file mode 100644 index 000000000..7072b406e --- /dev/null +++ b/versions/pc8080/1.37.1/document.css @@ -0,0 +1,162 @@ +@CHARSET "UTF-8"; + +.page { + margin: 2% 2%; + padding: 2% 2%; + min-width: 30em; + overflow: auto; + font-size: large; + font-family: Helvetica, Arial, sans-serif; + background: #303030; + color: #ccc; + +} +.page-header { +} +.page-header-title { + text-align: center; + +} +.page a { + color: #7fc07f; + text-decoration: none; +} +a.footlink, a.paralink { + text-decoration: none; +} +a.footlink:link, a.paralink:link { + color: blue; +} +a.footlink:visited, a.paralink:visited { + color: blue; +} +.galleryitem { + float: left; + width: 200px; +} +.item { + float: left; + width: 2em; + text-indent: 1em; +} +.list { + margin-left: 3em; + text-indent: 0; + text-align: justify; +} +ul { + list-style: none; +} +div.pnumber { + float: left; + width: 2em; + text-indent: 1em; +} +div.pitem { + margin-left: 10em; +} +p.indent, .justified p { + text-indent: 2em; + text-align: justify; + line-height: 1.5em; +} +p.noindent { + text-indent: 0; + text-align: justify; +} +p.center, .center { + text-align: center; +} +li.para { + margin-top: 1em; + margin-bottom: 1em; +} +.left { + text-align: left; +} +.right { + text-align: right; +} +blockquote.tag { + font-size: small; + font-family: Monaco, Fixed, monospace; + margin-top: 0; + margin-bottom: 0; +} +.blockquote { + padding-left: 1em; + text-indent: 0; + text-align: justify; +} +.italics { + font-style: italic; +} +.medium { + font-size: medium; +} +.small { + font-size: x-small; +} +.smallcaps { + font-variant: small-caps; +} +.strike { + text-decoration: line-through; +} +.summation, .bracelist { + display: inline-block; + position: relative; + vertical-align: middle; + text-align: center; + margin-bottom: 0.5ex; + text-indent: 0; +} +.bracelist-symbol { + font-size: 3em; + vertical-align: -40%; +} +.summation .summation-lower, .summation .summation-upper, .bracelist-item { + display: block; + font-size: 75%; + text-align: center; +} +.summation .summation-upper { + margin-bottom: 0; + margin-left: 0.8ex; + font-style: italic; +} +.summation .summation-lower{ + margin-bottom: -0.6ex; + font-style: italic; +} +.summation .summation-symbol { + font-size: 2em; +} +p sup { + vertical-align: baseline; + position: relative; + bottom: .5em; + font-size: small; +} +p sub { + vertical-align: baseline; + position: relative; + bottom: -.5em; + font-size: small; +} +.footnote { + font-size: medium; + text-indent: 1em; + text-align: justify; + margin-top: .5em; +} +.image-right { + float: right; + margin-left: 1em; + margin-top: 1em; + margin-bottom: 1em; +} +.image-caption { + font-size: small; + text-align: center; +} \ No newline at end of file diff --git a/versions/pc8080/1.37.1/document.xsl b/versions/pc8080/1.37.1/document.xsl new file mode 100644 index 000000000..35d25d304 --- /dev/null +++ b/versions/pc8080/1.37.1/document.xsl @@ -0,0 +1,452 @@ + + + + + +]> + + + + + + + + + +

    +
    + + + + + + + +

    +
    + +

    +
    +
    +
    + + + + + + +
    +
    + + +
    + +   + + +
    +
    + +
    +
    + + + + + + + + + + + + + + + + +

    +
    + + +

    +
    + + +

    +
    + + +
    +
    + + +
    +
    + + + + + + + + + + + + + + +
    +
    + + +
    +
    + + +
  • +
    + + +
    image
    +
    + + +
    +
    + + + + +
    {.}
    +
    + +
    {.}
    +
    +
    +
    + + + + + + + + + + < + > + + + + × + + ÷ + σ + + + + + + + + + + + + { + + + + + + + + + + [] + + + + +
    + +
    +
    + + + , and + + + + + MDY + + + + + + + + + + + + + + + + + + + + January + February + March + April + May + June + July + August + September + October + November + December + + + , + + + + + +

    + +
    +
    + + +
    + {.}
    +
    +
    +
    + + + +

    Timeline

    +
    + +

    +
    +
    + +
    +
    + + + + + + + + + +

    +
    + +
    +
    +
    + + + +

    People

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + +

    +
      + +
    +
    + + + + + + + + + + +
  • + +
  • +
    + + + +

    +
    +

    + +

    +
    +
    + + + + false + + + + + + [Original] + + + + + + + + + + [] + + +
    by
    + + +
    + [Source: + + + + + + + ] +
    +
    +
    + + + +

    Resources

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + + +

    +
    +
      + +
    +
    + + +
  • +
    + + + +

    +
    +
    + +
    +
    + + + +

    +
    + +
    + + + +

    +
    +
      + +
    +
    + + + + + +
      + +
    +
    + + + + +
  • +
    + +
  • +
    + +
  • +
    +
    +
    + + +
  • +
    + + + + + + + + + + +
    + < ="" + + ></> + ></> + /> + +
    +
    + +
    diff --git a/versions/pc8080/1.37.1/machine.xsl b/versions/pc8080/1.37.1/machine.xsl new file mode 100644 index 000000000..4aa4d5025 --- /dev/null +++ b/versions/pc8080/1.37.1/machine.xsl @@ -0,0 +1,61 @@ + + + + +]> + + + + + + + + + + + + + + + + + js + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    +
    + + + + + , + +
    +
    + +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pc8080/1.37.1/manifest.xsl b/versions/pc8080/1.37.1/manifest.xsl new file mode 100644 index 000000000..ebaf564d1 --- /dev/null +++ b/versions/pc8080/1.37.1/manifest.xsl @@ -0,0 +1,247 @@ + + + + +]> + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Document Manifest

    +
    +
      + + + + None + + + + + + + + + + + + + + + + +
    +
    +
    +

    + +
    +
    +
    + + +
    + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Software Manifest

    +
    +
      + + + + None + + + + + Unknown + + + + + None + + + + + None + + + + + + + + + + + + + UpdatedReleased + + Unknown + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    + + + + + + + +

    No default machine specified for '' in manifest.xml

    +
    + +
    +
    +
    + + + + -dbg + + + + + + +
    + + + + + Unknown + +
  • +
      + + + + + + + + +
    • + + + + + + + + + + + + + + + + + + + + + + + + + +
        + +
      • + + + + + + +
      • +
        +
      +
      +
    • +
      + + + + + + + + +
    +
  • +
    +
    + +
    diff --git a/versions/pc8080/1.37.1/outline.xsl b/versions/pc8080/1.37.1/outline.xsl new file mode 100644 index 000000000..24659d479 --- /dev/null +++ b/versions/pc8080/1.37.1/outline.xsl @@ -0,0 +1,47 @@ + + + + +]> + + + + + + + + + + + + + + + + + + <xsl:value-of select="title"/><xsl:text> | </xsl:text><xsl:value-of select="$SITEHOST"/> + + + + + +
    +
    + +
    +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pc8080/1.37.1/pc8080-dbg.js b/versions/pc8080/1.37.1/pc8080-dbg.js new file mode 100644 index 000000000..f8678747a --- /dev/null +++ b/versions/pc8080/1.37.1/pc8080-dbg.js @@ -0,0 +1,313 @@ +(function(){/* + http://pcjs.org/modules/shared/lib/dumpapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/reportapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/userapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/keys.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/strlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/weblib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/cpudef.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/messages.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/state.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/embed.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/usrlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/component.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/panel.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/bus.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/memory.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/cpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/cpustate.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/cpuops.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/chipset.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/rom.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/ram.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/keyboard.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/video.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/serial.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pc8080/lib/computer.js (C) Jeff Parsons 2012-2017 +*/ +var l,aa="function"==typeof Object.create?Object.create:function(a){function b(){}b.prototype=a;return new b},ca;if("function"==typeof Object.setPrototypeOf)ca=Object.setPrototypeOf;else{var da;a:{var ea={vb:!0},fa={};try{fa.__proto__=ea;da=fa.vb;break a}catch(a){}da=!1}ca=da?function(a,b){a.__proto__=b;if(a.__proto__!==b)throw new TypeError(a+" is not extensible");return a}:null}var ha=ca; +function ia(a,b){a.prototype=aa(b.prototype);a.prototype.constructor=a;if(ha)ha(a,b);else for(var c in b)if("prototype"!=c)if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);d&&Object.defineProperty(a,c,d)}else a[c]=b[c];a.Pf=b.prototype} +for(var ja="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ka="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global&&null!=global?global:this,la=["Math","trunc"],ma=0;maa?-b:b};ra!=qa&&null!=ra&&ja(ka,pa,{configurable:!0,writable:!0,value:ra}); +var m={Be:0,Ee:1,Fe:2,Ge:3,He:4,Ie:5,Je:6,Ke:7,Le:8,Me:9,Ne:10,Oe:11,Pe:12,Qe:13,Re:14,Se:15,Te:16,Ue:17,Ve:18,We:19,Xe:20,Ye:21,Ze:22,$e:23,af:24,bf:25,cf:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,Ya:65,Ub:66,Vb:67,Db:68,E:69,Yb:70,Zb:71,$b:72,ac:73,bc:74,cc:75,Fb:76,gc:77,hc:78,lc:79,mc:80,Q:81,nc:82,pc:83,qc:84,rc:85,tc:86,uc:87, +wc:88,xc:89,tb:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,vb:97,td:98,wd:99,d:100,e:101,Ad:102,Cd:103,Dd:104,Ed:105,Nd:106,k:107,Od:108,Qd:109,n:110,Rd:111,p:112,q:113,r:114,ne:115,t:116,pe:117,qe:118,re:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,df:127},sa={59:186,61:187,173:189,224:91}; +function ta(a,b){if(a){b||(b=10);var c,d=0=b&&(c=a.match(/(-?[0-9]+)B([0-9]*)/))&& +(a=c[1],e=35-((c[2]||35)&255));c=a;if(((d=b)&&10!=d?16==d?null!==c.match(/^-?[0-9a-f]+$/i):8==d?null!==c.match(/^-?[0-7]+$/):2==d&&null!==c.match(/^-?[01]+$/):null!==c.match(/^-?[0-9]+$/))&&!isNaN(f=parseInt(a,b))){e&&(0>f&&(f+=Math.pow(2,36)),f=0a&&-1a&&(a+=Math.pow(b,c)),a>=Math.pow(b,c)&&(c=Math.ceil(Math.log(a)/Math.log(b))));for(var g=e||-1;0=h?48:55;f=String.fromCharCode(h)+f;a=Math.trunc(a/b)}g--}return(void 0===d?"":d)+f}function n(a,b,c){b?9=b?4:4294967295>=b?8:9);return wa(a,16,b,c?"0x":"")}function xa(a){return n(a,2,!0)} +function q(a){return n(a,4,!0)}function ya(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Ea[a]})}function Fa(a,b){return(a+" ").slice(0,b)} +function Ga(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Ea={"&":"&","<":"<",">":">",'"':""","'":"'"},Ha={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; +function Ia(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1;var h=c(b,a[g]);0f;f++){var g;switch(g="Y-m-d H:i:s".charAt(f)){case "a":b+=12>c?"am":"pm";break;case "d":b+=("0"+d).slice(-2);break;case "D":b+=Ka[a.getDay()].substr(0,3);break;case "F":b+=La[e-1];break;case "g":b+=c?12c&&(c+=a.length);0>c&&(c=0);for(var d=a.length;cb.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.Oa=g.load;d.Ga=g.exec;if(e=g.bytes)d.la=e;else if(e=g.words)for(d.la=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.la=Array(4*e.length),f=c=0;c>8&255,d.la[f++]=e[c]>>16&255,d.la[f++]=e[c]>>24&255;else(e=g.data)?d.Mf=e:d.la=g;d.la&&(d.la.length?1==d.la.length&&(r(d.la[0]),d=null):(r("Empty resource: "+a),d=null));d.qa=g.symbols}catch(h){r("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca?this.Gb=this.id:(this.$a=this.id.substr(0,a),this.Gb=this.id.substr(a+1));this.D={ready:!1,ib:!1,Hb:!1,Nf:!1,ia:!1,Qb:!1,error:!1};this.xb=null;this.D.error=!1;this.ga=c||0;this.K=this.w=this.I=this.R=null;sb.push(this)} +function tb(a,b,c){ub[a]&&b&&(ub[a][b]=c)}function vb(){return Date.now()||+new Date}function lb(a,b,c){b||r((c?c+": ":"")+a)}function r(a){window&&window.alert(a)}function wb(a){var b=!1;window&&(b=window.confirm(a));return b}function xb(a,b){a.value+=b;b=a.value;8192d?c+=a+"\n":c=c.substr(0,d)+(a+".")+ +c.substr(d+a.length);8192>1)+2;10>this.g&&(this.g=10);15>2;this.j=this.u-1;this.L=this.N/this.u|0;this.H=this.L-1;this.A=[];this.B=[];this.F=this.G=!1;this.S=[];this.T=[];a=new A;bc(a,this.K);this.b=Array(this.L);for(b=0;b>>a.g;0f&&(p=f);if(h&&h.size){if(h.type==d){if(e+f<=h.J)return h.mb+=h.J-e,h.J=e,!0;if(e>=h.J+h.mb){p=h.size-(e-k);p>f&&(p=f);h.mb=e-h.J+p;e=k+a.u;f-=p;g++;continue}}return dc(ec,e,f)}e=new A(e,p,a.u,d);bc(e,a.K,h);a.b[g++]=e;e=k+a.u;f-=p}return 0>=f?(a.status(Math.floor(c/1024)+"Kb "+fc[d]+" at "+q(b)),!0):dc(gc,b,c)} +function hc(a,b){return a.b[(b&a.C)>>>a.g].lb(b&a.j,b)}function ic(a,b){var c=b&a.j,d=(b&a.C)>>>a.g;return c!=a.j?a.b[d].Gc(c,b):a.b[d++].Va(c,b)|a.b[d&a.H].Va(0,b+1)<<8}function jc(a,b){var c=b&a.j,d=(b&a.C)>>>a.g;return c!=a.j?a.b[d].Mb(c,b):a.b[d++].lb(c,b)|a.b[d&a.H].lb(0,b+1)<<8}function kc(a,b,c){a.b[(b&a.C)>>>a.g].nb(b&a.j,c&255,b)}function lc(a,b,c){var d=b&a.j,e=(b&a.C)>>>a.g;d!=a.j?a.b[e].Jc(d,c&65535,b):(a.b[e++].Xa(d,c&255,b),a.b[e&a.H].Xa(0,c>>8&255,b+1))} +function mc(a){for(var b=0,c=[],d=0;d>>=f;if(void 0!==g){if(g[0])g[0](b,k,d);a.K&&a.G!=g[1]&&Dc(a.K,b,k)}else a.K&&(Sb(a.K,a,b,k,d),a.G&&Dc(a.K,b,k));f+=h<<3;b+=h;e-=h}}function dc(a,b,c){r("Memory block error ("+a+": "+n(b)+","+n(c)+")");return!1}var ec=1,gc=2,Ec;if(Tb){var Fc=new ArrayBuffer(2);(new DataView(Fc)).setUint16(0,256,!0);Ec=256===(new Uint16Array(Fc))[0]}else Ec=!1;var Gc=Ec; +function A(a,b,c,d){this.id=Hc+=2;this.b=null;this.J=a;this.mb=b;this.size=c||0;this.type=d||Ic;this.w=d==Jc;bc(this);this.Ca=this.Cc=!1;if(c)if(Tb)this.R=new ArrayBuffer(c),this.j=new DataView(this.R,0,c),this.g=new Uint8Array(this.R,0,c),this.u=new Uint16Array(this.R,0,c>>1),this.b=new Int32Array(this.R,0,c>>2),Kc(this,Gc?Lc:Mc);else{this.b=Array(c>>2);for(a=0;a>2);for(a=0;a>8,c)};l.he=function(a){return this.b[a>>2]>>>((a&3)<<3)&255};l.le=function(a){var b=a>>2;a=(a&3)<<3;var c=this.b[b]>>a;return 24>a?c&65535:c&255|(this.b[b+1]&255)<<8};l.ve=function(a,b){var c=a>>2;a=(a&3)<<3;this.b[c]=this.b[c]&~(255<>2;a=(a&3)<<3;24>a?this.b[c]=this.b[c]&~(65535<>8);this.Ca=!0};l.fe=function(a,b){if(this.K&&null!=this.J){var c=this.K;Tc(c,this.J+a,1,c.M)&&Uc(c,!0)}return this.lb(a,b)};l.je=function(a,b){if(this.K&&null!=this.J){var c=this.K;Tc(c,this.J+a,2,c.M)&&Uc(c,!0)}return this.Mb(a,b)}; +l.te=function(a,b,c){if(this.K&&null!=this.J){var d=this.K;Tc(d,this.J+a,1,d.B)&&Uc(d,!0)}this.w?this.ob(0,b):this.nb(a,b,c)};l.xe=function(a,b,c){if(this.K&&null!=this.J){var d=this.K;Tc(d,this.J+a,2,d.B)&&Uc(d,!0)}this.w?this.ob(0,b):this.Sb(a,b,c)};l.ee=function(a){return this.g[a]};l.ge=function(a){return this.g[a]};l.ie=function(a){return this.j.getUint16(a,!0)};l.ke=function(a){return a&1?this.g[a]|this.g[a+1]<<8:this.u[a>>1]};l.se=function(a,b){this.g[a]=b;this.Ca=!0}; +l.ue=function(a,b){this.g[a]=b;this.Ca=!0};l.we=function(a,b){this.j.setUint16(a,b,!0);this.Ca=!0};l.ye=function(a,b){a&1?(this.g[a]=b,this.g[a+1]=b>>8):this.u[a>>1]=b;this.Ca=!0};var Ic=0,Jc=2,fc=["NONE","RAM","ROM","VID","H/W"],Hc=0,Oc=[],Nc=[A.prototype.he,A.prototype.ve,A.prototype.le,A.prototype.ze],Rc=[A.prototype.fe,A.prototype.te,A.prototype.je,A.prototype.xe];if(Tb)var Mc=[A.prototype.ee,A.prototype.se,A.prototype.ie,A.prototype.we],Lc=[A.prototype.ge,A.prototype.ue,A.prototype.ke,A.prototype.ye]; +function Vc(a,b){t.call(this,"CPU",a,1);var c=a.multiplier||1;this.ya=a.cycles||b;this.T=c;this.Ra=Math.round(this.ya/1E4)/100;this.Z=this.Ra*this.T;this.D.ja=!1;this.D.Pb=!1;this.D.hb=a.autoStart;this.D.Ac=!1;this.D.Ua=!1;this.va=this.na=0;this.xa=a.csStart;this.ma=a.csInterval;this.ra=a.csStop;this.U=[];this.Bb=this.qb.bind(this);Nb(this)}ia(Vc,t);l=Vc.prototype; +l.Ea=function(a,b,c,d){this.R=a;this.I=b;this.K=d;for(b=0;b=a.na&&(a.na+=a.ma,c=!0);0<=a.ra&&a.ra<=dd(a)&&(a.ma=a.ra=-1,Zc(a),ed(a),c=!0);c&&a.i(dd(a)+" cycles: checksum="+n(a.va))}} +l.da=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.P[b]=c;a=!0;break;case "run":this.P[b]=c;c.onclick=function(){var a;if(a=d.R)if(a=d.R,a.D.ia)a=!0;else{var b=null,c,h=Cb(a.id);for(c=0;ca.Y/a.Z?b=1:d=!0;a.T=b;b=a.Ra*a.T;if(a.Z!=b){a.Z=b;b=a.Z.toFixed(2)+"Mhz";var e=a.P.setSpeed;e&&(e.textContent=b);a.i("target speed: "+b)}c&&a.R&&a.R.Wa()}gd(a,a.X);a.X=0;a.V=vb();a.ba=0;rd(a);return d}function td(a,b,c){var d=void 0===d?-1:d;var e=a.U.length;a.U.push([b,-1,d,c]);0<=d&&ud(a,e,d);return e}function ud(a,b,c){0<=b&&bb[1]&&(c=a.ya*a.T/1E3*c|0,a.D.ja&&(c+=vd(a)),b[1]=c))} +function vd(a,b){var c=a.ea-=a.b;a.b=0;b&&(a.ea=0);return c} +l.qb=function(a){if(Pb(this,!0)){if(!this.D.ja){fd(this);this.R&&this.R.start(this.V,dd(this));this.D.ja=!0;this.D.Pb=!0;this.W&&this.W.start();var b=this.P.run;b&&(b.textContent="Halt");this.R&&(wd(this.R,!0),a&&this.R.Wa(!0))}this.Ta>=this.ya&&rd(this,!0);this.Ba=0;this.Ka=vb();this.ba&&(a=this.Ka-this.ba,a>this.fb&&(this.V+=a,this.V>this.Ka&&(this.V=this.Ka)));try{do{for(var c,d=this.D.Ua?1:this.La,e=this.U.length-1;0<=e;e--){var f=this.U[e];0>f[1]||d>f[1]&&(d=f[1])}c=d;this.Cb(c);c=vd(this,!0); +this.Ba+=c;this.X+=c;cd(this,c);a=c;for(var g=this.U.length-1;0<=g;g--){var h=this.U[g];0>h[1]||(h[1]-=a,0>=h[1]&&(h[1]=-1,h[3](),0<=h[2]&&ud(this,g,h[2])))}this.sa-=c;if(0>=this.sa){this.sa+=this.La;++this.gb>=xd&&(this.R&&wd(this.R),this.gb=0);break}}while(this.D.ja)}catch(k){ed(this);bd(this);this.R&&this.R.stop(vb(),dd(this));Pb(this,!1);Lb(this,k.stack||k.message);return}c=setTimeout;d=this.Bb;this.ba=vb();e=this.fb;this.Ba&&(e=Math.round(e*this.Ba/this.La));e-=this.ba-this.Ka;if(f=this.ba-this.V)this.Y= +Math.round(this.X/(10*f))/100,864E5<=f&&(this.ka=0,fd(this));if(0>e||this.Ye&&(this.V-=e),e=0;this.Ta+=this.Ba;this.ba+=e;c(d,e)}else bd(this),this.R&&this.R.stop(vb(),dd(this))};l.Cb=function(){return 0};function ed(a,b){Ob(a,!0);vd(a);gd(a,a.X);a.X=0;if(a.D.ja){a.D.ja=!1;a.W&&a.W.stop();var c=a.P.run;c&&(c.textContent="Run")}a.D.complete=b}function bd(a,b){if(a.R){for(var c=a.R,d=0;d>8&255;a.A=b&255}function Jd(a){return a.B<<8|a.C}function Kd(a,b){a.B=b>>8&255;a.C=b&255}function D(a){return a.F<<8|a.G} +function Ld(a,b){a.F=b>>8&255;a.G=b&255}function B(a,b){a.j=b&65535}function Md(a){return a.H&256?1:0}function Nd(a,b){a.H=a.H&255|b}function Od(a){return Ub[a.L&255]?4:0}function Pd(a){return(a.L^a.O)&16?16:0}function Qd(a){return a.H&255?0:64}function Rd(a){return a.L&128?128:0}function Fd(a){return a.N&-214|Rd(a)|Qd(a)|Pd(a)|Od(a)|Md(a)}function Dd(a,b){a.H=a.L=a.O=0;b&1&&(a.H|=256);b&4||(a.L|=1);b&16&&(a.O|=16);b&64||(a.H|=255);b&128&&(a.L^=192);a.N=a.N&-726|b&512|2} +function Sd(a,b){a.O=a.g^b;return a.L=(a.H=a.g+b)&255}function Td(a,b){a.O=a.g^b;return a.L=(a.H=a.g+b+(a.H&256?1:0))&255}function Ud(a,b){a.H=a.L=a.O=a.g&b;(a.g|b)&8&&(a.O^=16);return a.H}function Vd(a,b){a.O=b^255;b=a.L=b+255&255;a.H=a.H&-256|b;return b}function Wd(a,b){a.O=b;b=a.L=b+1&255;a.H=a.H&-256|b;return b}function Xd(a,b){return a.L=a.H=a.O=a.g|b}function Yd(a,b){b^=255;a.O=a.g^b;return a.L=(a.H=a.g+b+1^256)&255} +function Zd(a,b){b^=255;a.O=a.g^b;return a.L=(a.H=a.g+b+(a.H&256?0:1)^256)&255}function $d(a,b){return a.L=a.H=a.O=a.g^b}function E(a,b){a=a.I;return a.b[(b&a.C)>>>a.g].Va(b&a.j,b)}function ae(a,b,c){a=a.I;a.b[(b&a.C)>>>a.g].Xa(b&a.j,c&255,b)}function F(a){var b=E(a,a.j);B(a,a.j+1);return b}function G(a){var b=ic(a.I,a.j);B(a,a.j+2);return b}function be(a){var b=ic(a.I,a.M);a.M=a.M+2&65535;return b}function H(a,b){a.M=a.M-2&65535;lc(a.I,a.M,b)} +function ce(a){if(a.b&&a.S&255&&a.N&512){for(var b=0;8>b&&!(a.S&1<b?255:1<>8;Nd(this,a&256);this.b-=4},ge,function(){var a;Ld(this,a=D(this)+Hd(this));Nd(this,a>>8&256);this.b-=10},function(){this.g=E(this,Hd(this));this.b-=7},function(){Id(this,Hd(this)-1);this.b-= +5},function(){this.A=Wd(this,this.A);this.b-=5},function(){this.A=Vd(this,this.A);this.b-=5},function(){this.A=F(this);this.b-=7},function(){var a=this.g<<8&256;this.g=(a|this.g)>>1;Nd(this,a);this.b-=4},ge,function(){Kd(this,G(this));this.b-=10},function(){ae(this,Jd(this),this.g);this.b-=7},function(){Kd(this,Jd(this)+1);this.b-=5},function(){this.B=Wd(this,this.B);this.b-=5},function(){this.B=Vd(this,this.B);this.b-=5},function(){this.B=F(this);this.b-=7},function(){var a=this.g<<1;this.g=a&255| +Md(this);Nd(this,a&256);this.b-=4},ge,function(){var a;Ld(this,a=D(this)+Jd(this));Nd(this,a>>8&256);this.b-=10},function(){this.g=E(this,Jd(this));this.b-=7},function(){Kd(this,Jd(this)-1);this.b-=5},function(){this.C=Wd(this,this.C);this.b-=5},function(){this.C=Vd(this,this.C);this.b-=5},function(){this.C=F(this);this.b-=7},function(){var a=this.g<<8;this.g=(Md(this)<<8|this.g)>>1;Nd(this,a&256);this.b-=4},ge,function(){Ld(this,G(this));this.b-=10},function(){var a=G(this);lc(this.I,a,D(this)); +this.b-=16},function(){Ld(this,D(this)+1);this.b-=5},function(){this.F=Wd(this,this.F);this.b-=5},function(){this.F=Vd(this,this.F);this.b-=5},function(){this.F=F(this);this.b-=7},function(){var a=0,b=Md(this);if(Pd(this)||9<(this.g&15))a|=6;if(b||154<=this.g)a|=96,b=1;this.g=Sd(this,a);Nd(this,b?256:0);this.b-=4},ge,function(){var a;Ld(this,a=D(this)+D(this));Nd(this,a>>8&256);this.b-=10},function(){var a=G(this);a=ic(this.I,a);Ld(this,a);this.b-=16},function(){Ld(this,D(this)-1);this.b-=5},function(){this.G= +Wd(this,this.G);this.b-=5},function(){this.G=Vd(this,this.G);this.b-=5},function(){this.G=F(this);this.b-=7},function(){this.g=~this.g&255;this.b-=4},ge,function(){this.M=G(this)&65535;this.b-=10},function(){ae(this,G(this),this.g);this.b-=13},function(){this.M=this.M+1&65535;this.b-=5},function(){var a=D(this);ae(this,a,Wd(this,E(this,a)));this.b-=10},function(){var a=D(this);ae(this,a,Vd(this,E(this,a)));this.b-=10},function(){ae(this,D(this),F(this));this.b-=10},function(){this.H|=256;this.b-= +4},ge,function(){var a;Ld(this,a=D(this)+this.M);Nd(this,a>>8&256);this.b-=10},function(){this.g=E(this,G(this));this.b-=13},function(){this.M=this.M-1&65535;this.b-=5},function(){this.g=Wd(this,this.g);this.b-=5},function(){this.g=Vd(this,this.g);this.b-=5},function(){this.g=F(this);this.b-=7},function(){Nd(this,Md(this)?0:256);this.b-=4},function(){this.b-=5},function(){this.u=this.A;this.b-=5},function(){this.u=this.B;this.b-=5},function(){this.u=this.C;this.b-=5},function(){this.u=this.F;this.b-= +5},function(){this.u=this.G;this.b-=5},function(){this.u=E(this,D(this));this.b-=7},function(){this.u=this.g;this.b-=5},function(){this.A=this.u;this.b-=5},function(){this.b-=5},function(){this.A=this.B;this.b-=5},function(){this.A=this.C;this.b-=5},function(){this.A=this.F;this.b-=5},function(){this.A=this.G;this.b-=5},function(){this.A=E(this,D(this));this.b-=7},function(){this.A=this.g;this.b-=5},function(){this.B=this.u;this.b-=5},function(){this.B=this.A;this.b-=5},function(){this.b-=5},function(){this.B= +this.C;this.b-=5},function(){this.B=this.F;this.b-=5},function(){this.B=this.G;this.b-=5},function(){this.B=E(this,D(this));this.b-=7},function(){this.B=this.g;this.b-=5},function(){this.C=this.u;this.b-=5},function(){this.C=this.A;this.b-=5},function(){this.C=this.B;this.b-=5},function(){this.b-=5},function(){this.C=this.F;this.b-=5},function(){this.C=this.G;this.b-=5},function(){this.C=E(this,D(this));this.b-=7},function(){this.C=this.g;this.b-=5},function(){this.F=this.u;this.b-=5},function(){this.F= +this.A;this.b-=5},function(){this.F=this.B;this.b-=5},function(){this.F=this.C;this.b-=5},function(){this.b-=5},function(){this.F=this.G;this.b-=5},function(){this.F=E(this,D(this));this.b-=7},function(){this.F=this.g;this.b-=5},function(){this.G=this.u;this.b-=5},function(){this.G=this.A;this.b-=5},function(){this.G=this.B;this.b-=5},function(){this.G=this.C;this.b-=5},function(){this.G=this.F;this.b-=5},function(){this.b-=5},function(){this.G=E(this,D(this));this.b-=7},function(){this.G=this.g; +this.b-=5},function(){ae(this,D(this),this.u);this.b-=7},function(){ae(this,D(this),this.A);this.b-=7},function(){ae(this,D(this),this.B);this.b-=7},function(){ae(this,D(this),this.C);this.b-=7},function(){ae(this,D(this),this.F);this.b-=7},function(){ae(this,D(this),this.G);this.b-=7},function(){var a=this.j-1;if(this.Ja.length)for(var b=0;b>8;this.b-=10},function(){var a=G(this);Rd(this)||B(this,a);this.b-=10},function(){this.N&=-513;this.b-=4},function(){var a=G(this);Rd(this)||(H(this,this.j),B(this,a),this.b-=6);this.b-=11},function(){H(this,Fd(this)&255|this.g<<8);this.b-=11},function(){this.g=Xd(this,F(this));this.b-=7},function(){H(this,this.j);B(this,48);this.b-=11},function(){Rd(this)&& +(B(this,be(this)),this.b-=6);this.b-=5},function(){this.M=D(this)&65535;this.b-=5},function(){var a=G(this);Rd(this)&&B(this,a);this.b-=10},function(){this.N|=512;this.b-=4;ce(this)},function(){var a=G(this);Rd(this)&&(H(this,this.j),B(this,a),this.b-=6);this.b-=11},je,function(){Yd(this,F(this));this.b-=7},function(){H(this,this.j);B(this,56);this.b-=11}]; +function ke(a){t.call(this,"ChipSet",a,32768);var b=a.model;b&&!le[b]&&lb("Unrecognized ChipSet model: "+b);this.g=le[b]||{};a.sound&&(this.U=null,window&&(this.U=window.AudioContext||window.webkitAudioContext),this.U&&new this.U);Nb(this)}ia(ke,t);l=ke.prototype;l.da=function(){return!1}; +l.Ea=function(a,b,c,d){this.I=b;this.w=c;this.K=d;this.R=a;this.B=Zb(a,"Keyboard");this.C=Zb(a,"SerialPort");this.video=Zb(a,"Video");oc(b,this,this.g.zb);Bc(b,this,this.g.Ab);if(d){var e=this;me(d,16384,function(){for(var a="",b=0;b>8-this.T&255;y(this,a,null,b,"SHIFT.RESULT",c,!0);return c};l.Vd=function(a,b,c){y(this,a,b,c,"SHIFT.COUNT",null,!0);this.T=b};l.Xd=function(a,b,c){y(this,a,b,c,"SOUND1",null,!0);this.Y=b};l.Wd=function(a,b,c){y(this,a,b,c,"SHIFT.DATA",null,!0);this.N=b<<8|this.N>>8}; +l.Yd=function(a,b,c){y(this,a,b,c,"SOUND2",null,!0);this.Z=b};l.Zd=function(a,b,c){y(this,a,b,c,"WATCHDOG",null,!0)};function oe(a){var b=0,c=0,d=~a.M;for(a=0;10>a;a++)d&1&&(b=9-a),d>>=1;for(a=0;10>a;a++)d&1&&(c=9-a),d>>=1;return 10*b+c} +l.Ld=function(a,b){var c=this.F;c&=~J.wa.jc;if((dd(this.w)&64)<<1&&(c|=J.wa.jc,c!=this.F)){var d=this.L&1;var e=this.L>>1&7;switch(e){case J.za.Ha.md:break;case J.za.Ha.Kc:this.M=this.M<<1|d;break;case J.za.Ha.Qc:d=oe(this);this.j[d]=J.za.sb;Rb(this,"doNVRCommand(): erase data at addr "+q(d));break;case J.za.Ha.Lc:this.b=this.b<<1|d;break;case J.za.Ha.qd:d=oe(this);e=this.b&J.za.sb;this.j[d]=e;Rb(this,"doNVRCommand(): write data "+q(e)+" to addr "+q(d));break;case J.za.Ha.kd:d=oe(this);e=this.j[d]; +null==e&&(e=J.za.sb);this.b=e;Rb(this,"doNVRCommand(): read data "+q(e)+" from addr "+q(d));break;case J.za.Ha.ld:this.b<<=1;this.S=this.b&J.za.sb+1;break;default:Rb(this,"doNVRCommand(): unrecognized command "+xa(e))}}c&=~J.wa.kc;this.S&&(c|=J.wa.kc);c&=~J.wa.dc;if(d=this.B){d=this.B;if(e=d.A)e=d.w,e=dd(d.w)>=d.G+(e.ya*e.T/1E3*1.2731488|0);e&&(d.A=!1);d=!d.A}d&&(c|=J.wa.dc);c&=~J.wa.sc;this.C&&this.C.ha&pe&&(c|=J.wa.sc);this.F=c;y(this,a,null,b,"FLAGS",c);return c}; +l.$d=function(a,b,c){y(this,a,b,c,"BRIGHTNESS");this.W=b};l.ce=function(a,b,c){y(this,a,b,c,"NVR.LATCH");this.L=b};l.be=function(a,b,c){y(this,a,b,c,"DC012");a=b&3;switch(b>>2&3){case 0:this.u=this.u&-4|a;break;case 1:this.u=this.u&-13|a<<2;this.video&&(b=this.video,a=this.u,Rb(b,"updateScrollOffset("+a+")"),b.ra!==a&&((b.ra=a)?yd(b,!0):b.va=!0));break;case 2:switch(a){case 0:this.O=~this.O;break;case 2:case 3:this.X=3-a}break;case 3:this.V=a}}; +l.ae=function(a,b,c){y(this,a,b,c,"DC011");b&J.Ia.jd?(b&=J.Ia.oc,this.H!=b&&(this.H=b,this.video&&(a=this.video,b=this.H==J.Ia.oc?50:60,Rb(a,"updateRate("+b+")"),a.fb=b))):(b&=J.Ia.Wb,this.G!=b&&(this.G=b,this.video&&(a=this.G==J.Ia.Wb?132:80,b=this.video,Rb(b,"updateDimensions("+a+","+(80>>0,g];var x=Ia(v,k,a.zc);0>x&&v.splice(-(x+1),0,k)}p&&(h.a=p.replace(/''/g,'"'))}a.C.push({Of:b,J:c,Pd:d,qa:e,yc:f})}delete this.qa}return!0};se.prototype.ta=function(){return!0}; +function te(a,b,c,d){if(d)a.aa("Unable to load system ROM (error "+d+": "+b+")");else{tb(a.$a,b,c);if("["==c.charAt(0)||"{"==c.charAt(0))try{var e=eval("("+c+")"),f=e.bytes,g=e.longs||e.data;if(f)a.b=f;else if(g)for(a.b=Array(4*g.length),d=c=0;c>8&255,a.b[d++]=g[c]>>16&255,a.b[d++]=g[c]>>24&255;else a.b=e;a.qa=e.symbols;if(!a.b.length){r("Empty ROM: "+b);return}if(1==a.b.length){r(a.b[0]);return}}catch(h){a.aa("ROM data error: "+h.message);return}else for(b= +c.replace(/\n/gm," ").replace(/ +$/,"").split(" "),a.b=Array(b.length),e=0;e>>f.g;0>>= +f.g;0=m.Ya&&a<=m.tb?d.g&(bf|cf)||(d.g|=cf,Ze(d,20,!0),df(d)):a>=m.vb&&a<=m.z&&d.g&cf&&(d.g&=~cf,Ze(d,20,!1),df(d));return!0}),c.onpaste=function(a){a:{if(d.C&&d.C.Pa&&(a.stopPropagation&&a.stopPropagation(),a.preventDefault&&a.preventDefault(),a=a.clipboardData||window.clipboardData)){ef(d.C,a.getData("Text"));a=!1;break a}a=!0}return a},!0;default:if(this.b.Sa&&void 0!==this.b.Sa[b])return this.P[e]=c,c.onclick= +function(a,b){return function(d){d.preventDefault&&d.preventDefault();d=!0;var e=0;17==b?e=ff:20==b&&(e=cf);if(e){c.style.fontWeight="normal";if(d=!(a.g&e))c.style.fontWeight="bold";gf(a,b,d)}Ze(a,b,d,!e);a.R&&a.R.Wa()}}(this,this.b.Sa[b]),!0}}return!1};l.Ea=function(a,b,c,d){this.R=a;this.w=c;this.K=d;var e=this;this.L=td(this.w,this.id,function(){hf(e)});this.W=Zb(a,"ChipSet");this.C=Zb(a,"SerialPort");oc(b,this,this.b.zb);Bc(b,this,this.b.Ab)}; +l.ua=function(a,b){if(!b)if(!a)this.reset();else if(!this.restore(a))return!1;return!0};l.ta=function(a){return a?this.save():!0};l.reset=function(){this.j=[];this.g=0;this.b.INIT&&!this.restore(this.b.INIT)&&this.aa("reset error")};l.save=function(){var a=new Gd(this);switch(this.b.oa){case K.oa:a.set(0,[this.F,this.B,this.A,this.G,-1])}return a.data()}; +l.restore=function(a){var b;if(a&&(b=a[0])&&b.length)switch(this.b.oa){case jf.oa:return!0;case K.oa:return this.F=b[0],df(this,this.F&K.Aa.ec),this.B=b[1],this.A=b[2],this.G=b[3],this.u=b[4],!0}return!1};function df(a,b){null!=b?a.H=b:b=a.H;for(var c in a.b.ab){var d="led-"+c;if(d=a.P[d]){var e=a.b.ab[c],f=!!(b&e);e&e-1&&(f=!(b&~e));d.style.backgroundColor=f?"#"+n(16711680,6):"#000000"}}if(d=a.P["led-caps-lock"])d.style.backgroundColor=a.g&cf?"#"+n(65280,6):"#000000"} +function gf(a,b,c,d){var e=0;switch(b){case 16:e=d?kf:lf;break;case 17:e=d?mf:ff;break;case 18:e=d?nf:of;break;case 91:e=d?pf:qf;break;case 20:e=cf,c=!(a.g&e)}e&&(a.g=c?a.g|e:a.g&~e);return c} +function af(a,b,c){var d=!0,e=b.keyCode;e=sa[e]||e;c=gf(a,e,c,2==b.location);a:if(e=a.b.Tb[e]||e,a.b.Qa[e])var f=e;else{for(f in a.b.Sa)if(a.b.Sa[f]===e)break a;f=null}f&&!b.metaKey&&(d=!1,a.g&(rf|sf)&&(13==f?(f=118,d=!0):8==f&&(f=46,d=!0),d&&(a.g=c?a.g|sf:a.g&~sf)),d=Ze(a,f,c),(!(f>=m.Ya&&f<=m.tb)||a.g|tf)&&b.preventDefault&&b.preventDefault());return d} +function $e(a,b,c){var d=!0;if(c){var e=b.keyCode,f=a.b.Qa[e],g;if(g=f){a:{for(var h in a.b.pb)if(a.b.pb[h]==f){f=+h;break a}f=0}g=!f}g&&(d=Ze(a,e,c,!0),b.preventDefault&&b.preventDefault())}return d} +function Ze(a,b,c,d){var e;a:{for(e=0;ee?a.j.push({Ob:b,Lb:Date.now(),wb:d||!1}):(a.j[e].Lb=Date.now(),a.j[e].wb=d||!1),d&&hf(a);else if(0<=e){if(!a.j[e].wb&&(d=a.j[e].Lb)&&Date.now()-dc||c>e)c=e}else{Ze(a,d,!1);b=0;continue}}b++}0<=c&&ud(a.w,a.L,c)}l.Md=function(a,b){var c=this.B;0<=this.u&&(this.u"]]= +229,M[m["<"]]=230,M[m.hc]=231,M[m.Ub]=232,M[m.wc]=233,M[m["?"]]=245,M[m.gc]=246,M[m.tc]=248,M[m.Vb]=249,M[m.tb]=250,M),Tb:{},ab:{},Sa:{"caps-lock":20,ctrl:17,esc:27,tab:9,"num-comma":116,"break":117,"line-feed":118,"no-scroll":119,setup:120},Mc:{pa:130,INIT:127},Aa:{pa:130,ad:1,$c:2,Zc:4,Yc:8,bd:16,fc:32,ec:63,nd:64,Ce:128,INIT:0},Xc:127};K.ab={l4:K.Aa.ad,l3:K.Aa.$c,l2:K.Aa.Zc,l1:K.Aa.Yc,locked:K.Aa.bd,local:K.Aa.fc,online:~K.Aa.fc,"caps-lock":cf};var Ye={SI1978:jf,VT100:K}; +K.INIT=[[K.Aa.INIT,K.Mc.INIT,!1,0,-1]];K.zb={130:Xe.prototype.Md};K.Ab={130:Xe.prototype.de};hb(function(){for(var a=zb(document,"pc8080","keyboard"),b=0;b>3)*a.N,!cc(a.I,a.ka,a.L,3)))return!1;a.L?(a.Ta=a.j.createImageData(b,c),a.cb=16/a.ma|0,Bf(a,a.L>>1)):Bf(a,(a.O+1)*a.Z);a.F=document.createElement("canvas");a.F.width=b;a.F.height=c;a.sa=a.F.getContext("2d");a.T={};a.X=1<=a.Ba?8:16,f=8>(7>4)*c)}return k}l.ua=function(a,b){return b||!a||this.restore(a)?!0:!1};l.ta=function(a){return!a||this.save()};l.save=function(){var a=new Gd(this);a.set(0,[]);return a.data()};l.restore=function(){return!0}; +l.jb=function(){var a=!1;if(this.b){if(this.b.jb){a="100%";if(screen&&screen.width&&screen.height){var b=screen.width/screen.height,c=this.M/this.H;b>c&&(a=Math.round(c/b*100)+"%")}this.Ra?(this.G.style.width=a,this.G.style.width=a,this.G.style.display="block",this.G.style.margin="auto"):(this.b.style.width=a,this.b.style.height="auto");this.b.style.backgroundColor="black";this.b.jb();a=!0}this.V&&this.V.focus()}return a}; +function zf(a,b){!b&&a.b&&(a.Ra?a.G.style.width=a.G.style.height="":a.b.style.width=a.b.style.height="");Rb(a,"notifyFullScreen("+b+")")}function Bf(a,b){a.bb=b;a.W=!1;if(void 0===a.A||a.A.length!=a.bb)a.A=Array(a.bb)}function Mf(a,b,c,d,e){d=a.g?(b.height-c-1)*b.width+d:c+d*b.width;e&&a.Y==Df&&(208<=c&&236>c?e=a.X+Ef:28<=c&&72>c&&(e=a.X+Ff));a=a.U[e];d*=a.length;b.data[d]=a[0];b.data[d+1]=a[1];b.data[d+2]=a[2];b.data[d+3]=a[3]} +function yd(a,b){var c=!0;if(!b){a.na&&(120==a.na?a.eb&1?(de(a.w,2),c=!1):de(a.w,1):de(a.w,4));if(c&&a.W&&a.L){var d=a.I,e=a.ka,f=a.L,g=!0,h=e>>>d.g;for(e=d.u-(e&d.j);0>=1);;){var u=hc(a.I,v++);if((u&Nf)==Nf){var w=hc(a.I,v++);d=w&Of;c=(w&Pf)<< +8|hc(a.I,v);c+=w&Qf?Rf:Sf;break}if(p>4)*u.ca,ob=u.fa,Oa=u.ca;if(C){var ua=z*w.fa;var na=f*w.ca;var va=w.fa;T=w.ca}else ua=z*w.Ja,na=f*w.Ka,va=w.Ja,T=w.Ka;u.fa>w.fa&&(ua*=2,va*=2);u.ca>w.ca&&(x==Lf&&(P+=w.ca),Oa=w.ca);C?C.drawImage(u.canvas,Na,P,ob,Oa,ua,na,va,T): +(ua+=0,na+=0,w.j.drawImage(u.canvas,Na,P,ob,Oa,ua,na,va,T))}e++}h++}f++}}a.W=!0;!b&&a.va&&1==e&&(a.A[k]=-1,e=0);a.va=!1;(e||b)&&a.sa&&a.j.drawImage(a.F,0,a.ra,a.C,a.N-a.ca,0,0,a.Bb,a.sd)}else{f=a.ka;g=f+a.L;k=e=h=0;b=a.C;p=0;c=a.N;x=d=0;v=a.ma;z=(1<>8|(w&255)<<8);e>C&z,Mf(a,a.Ta,e++,k,Na),C+=v;e>p&&(p=e);k=d&&(d=k+1)}f+=2;h++;if(e>=a.C&&(e=0,k++,k>a.N))break}a.W= +!0;bMissing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.backgroundColor=d.screenColor;e.style.height="auto";0<=Sa().indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height= +(a.clientWidth*d/c|0)+"px"}}(c,e,d.screenWidth,d.screenHeight),c.onresize());var f=+(d.aspect||$a("aspect"));f&&.3<=f&&3.33>=f&&(gb("onresize",function(a,b,c){return function(){b.style.height=(a.clientWidth/c|0)+"px"}}(c,e,f)),window.onresize());c.appendChild(e);f=document.createElement("textarea");Xa("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"),f.style.fontSize="16px");c.appendChild(f);var g=e.getContext("2d");d=new wf(d,e,g,f,c);yb(d,c)}}); +function Tf(a){t.call(this,"SerialPort",a,8388608);this.T=+a.adapter;switch(this.T){case 0:this.U=0;this.X=2;break;default:r("Unrecognized serial adapter #"+this.T);return}this.g=this.j=null;this.V=a.tabSize;this.S=a.charBOL;this.u=0;this.N=!1;this.F=!0;var b=a.binding;if("console"==b)this.j="";else{var c;a=Uf;b&&(void 0===c&&(c="Panel"),(c=Eb(c,this.id))&&(b=c.P[b])&&this.da(null,a,b))}this.A="";this.b=this.Pa=this.H=null;this.exports={connect:this.Ec,receiveData:this.Nb,receiveStatus:this.me}} +ia(Tf,t);l=Tf.prototype;l.da=function(a,b,c,d){var e=this;switch(b){case Uf:return this.P[b]=this.g=c,c.onkeydown=function(a){a=a||window.event;var b=a.keyCode;if(8===b||a.ctrlKey&&65<=b&&90>=b)a.preventDefault&&a.preventDefault(),64");if(2==c.length){var d=Ga(c[0]);if(d!=this.Gb)return;c=Ga(c[1]);if(this.b=Db(c)){var e=this.b.exports;if(e){var f=e.connect;f&&f.call(this.b,this.F);if(this.Pa=e.receiveData){this.F=a;this.H=e.receiveStatus;this.status("Connected "+this.$a+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; +l.ua=function(a,b){if(!b)if(this.Ec(this.F),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.ta=function(a){return a?this.save():!0};l.reset=function(){Yf(this)};l.save=function(){var a=new Gd(this),b=0,c=[];c[b++]=this.G;c[b++]=this.M;c[b++]=this.O;c[b++]=this.ha;c[b++]=this.B;c[b++]=this.C;c[b]=this.L;a.set(0,c);return a.data()};l.restore=function(a){return Yf(this,a[0])}; +function Yf(a,b){var c=0;void 0===b&&(b=Zf);a.G=b[c++];a.M=b[c++];a.O=b[c++];a.ha=b[c++];a.B=b[c++];a.C=b[c++];a.L=b[c];return!0}function $f(a,b){var c=a.L&b;b&15||(c>>=4);b=ag[c];c=((a.B&bg)>>2)+6;a.B&cg&&c++;c+=((a.B&dg)>>6)+1>>1;return 1E3/(b/c)|0}function Vf(a,b){Rb(a,"receiveByte("+xa(b)+"), status="+xa(a.ha));return a.N||a.ha&eg?!1:(a.M=b,a.ha|=eg,de(a.w,a.X),!0)} +l.Nb=function(a){null!=a&&(this.A="number"!=typeof a?a:this.A+String.fromCharCode(a));this.A&&(Vf(this,this.A.charCodeAt(0))&&(this.A=this.A.substr(1)),this.A&&this.w&&ud(this.w,this.Y,$f(this,fg)));return!0};l.me=function(a){this.ha&=~gg;a&64&&(this.ha|=gg)};function ef(a,b){a.ha=a.ha|pe|hg;b&&a.Pa&&a.Pa.call(a.b,b)}l.Gd=function(a,b){var c=this.M;y(this,a,null,b,"DATA",c);this.ha&=~eg;return c};l.Fd=function(a,b){var c=this.ha;y(this,a,null,b,"STATUS",c);return c}; +l.Ud=function(a,b,c){y(this,a,b,c,"DATA");this.O=b;this.ha&=~(pe|hg);Rb(this,"transmitByte("+xa(b)+")");if(19==b)this.N=!0;else if(17==b)this.N=!1;else if(this.Pa&&this.Pa.call(this.b,b),this.g)if(8==b)this.g.value=this.g.value.slice(0,-1),0":String.fromCharCode(b);c=a.length;9==b?(b=this.V||8,c=b-this.u%b,this.V&&(a=Fa("",c))):13==b&&(this.u=c=0,a="\n");this.S&&!this.u&&c&&(a=String.fromCharCode(this.S)+a);this.g.value+=a;this.g.scrollTop= +this.g.scrollHeight;this.u+=c}else if(null!=this.j){if(10==b||1024<=this.j.length)this.i(this.j),this.j="";10!=b&&(this.j+=String.fromCharCode(b))}this.w&&ud(this.w,this.Z,$f(this,ig))};l.Td=function(a,b,c){y(this,a,b,c,"CONTROL");this.G?(this.H&&(b^this.C)&(jg|kg)&&(a=0,this.F?(a|=b&jg?32:0,a|=b&kg?320:0):(a|=b&jg?16:0,a|=b&kg?1048576:0),this.H.call(this.b,a)),this.C=b,this.C&lg&&(this.G=!1)):(this.B=b,this.G=!0)};l.Sd=function(a,b,c){y(this,a,b,c,"BAUDRATES");this.L=b}; +var bg=12,cg=16,dg=192,kg=2,jg=32,lg=64,pe=1,eg=2,hg=4,gg=128,fg=15,ig=240,ag=[50,75,110,134.5,150,200,300,600,1200,1800,2E3,2400,3600,4800,9600,19200],Zf=[!1,0,0,133,142,39,238],Uf="buffer",Wf={0:Tf.prototype.Gd,1:Tf.prototype.Fd},Xf={0:Tf.prototype.Ud,1:Tf.prototype.Td,2:Tf.prototype.Sd};hb(function(){for(var a=zb(document,"pc8080","serial"),b=0;bthis.b&&this.g.length&&(this.b=0);if(0>this.b||a!=this.g[this.b])this.g.splice(0,0,a),this.b=0;this.b--}else this.N?a="end":a=this.g[this.b+1];b=[];if(a){a=a.replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(Ga(a.substring(d,f))),d=f+1}}return b}; +function ng(a,b,c){var d=a;b=b||32;if(c)if(32==b)d=a>>>0;else if(32>b)d=a&(1<a||a>=b)d=a%b,0>d&&(d+=b)}else 32>=b?d=a<<32-b>>32-b:(b=Math.pow(2,b-1),a>=b?(d=a%b,(a/b|0)&1&&(d-=b)):a<-b&&(d=a%b,((-a-1)/b|0)&1?d&&(d+=b):d||(d-=b)));a!=d&&(a=d);return a} +function og(a,b,c){for(c=void 0===c?-1:c;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop();var f=a.pop();switch(d){case "*":f*=e;break;case "/":if(!e)return!1;f=Math.trunc(f/e);break;case "^/":if(!e)return!1;f%=e;break;case "+":f+=e;break;case "-":f-=e;break;case "<<":f<<=e;break;case ">>":f>>=e;break;case ">>>":f>>>=e;break;case "<":f=f":f=f>e?1:0;break;case ">=":f=f>=e?1:0;break;case "==":f=f==e?1:0;break;case "!=":f=f!=e?1:0;break; +case "&":f&=e;break;case "!":case "|":f|=e;break;case "^!":f|=e;break;case "&&":f=f&&e?1:0;break;case "||":f=f||e?1:0;break;case ",,":f=ng(f,18,!0)*Math.pow(2,18)+ng(e,18,!0);break;case "_":case "^_":"^_"==d&&(e=35-(e&255));e&&(f=ng(f,0,!0),f=0=|>>>|>>|>|<=|<<|<|-|\+|\^\/|\/|\*|,,| )/);d=pg(a,b,0,b.length,a.u,c);void 0!==d&&e&&xg(a,null,d)}return d} +function yg(a,b){var c=a.U[0],d=a.U[1];var e="("==c||"{"==c||"["==c?"\\":"";var f="["==c?"\\":"";for(f=new RegExp(e+c+"([^"+f+c+f+d+"]+)"+e+d);e=b.match(f);){var g=wg(a,e[1]);if(void 0===g)return;b=b.replace(c+e[1]+d,null!=g?vg(a,g):"undefined")}if(a.ea.length)for(c=a.ea[0],d=a.ea[1],e="("==c||"{"==c||"["==c?"\\":"",f="["==c?"\\":"",f=new RegExp(e+c+"([^"+f+c+f+d+"]+)"+e+d);e=b.match(f);)b=b.replace("["+e[1]+"]","unimplemented");for(;c=b.match(/\$([a-z]+)/i);){d=null;switch(c[1].toLowerCase()){case "ops":d= +a.S-a.ba}if(null==d)break;b=b.replace(c[0],d.toString())}return b}function rg(a,b){for(;b;){switch(b&3){case 1:a=-ng(a);break;case 2:a|=-1;break;case 3:for(var c=35;0<=c&&!(a&Math.pow(2,c));)c--;a=35-c}b>>>=2}return a} +function qg(a,b,c,d,e){e=void 0===e?0:e;var f=Array.isArray(d)?d:void 0;if(null!=b){var g=a.Jb(b);if(0<=g)g=a.Kb(g);else if(g=b,a.A[g]?g=a.A[g].value:(g=g.substr(0,6),g=a.A[g]&&a.A[g].value),null!=g){var h=a.A[b]&&a.A[b].oe;h&&(f?f.push(h):(f=wg(a,h,d),void 0!==f?g+=f:(d||a.i("undefined "+(c||"value")+": "+b+" ("+h+")"),g=void 0)))}else g=ta(b,1c&&(e+=" '"+String.fromCharCode(c)+"'")}a.i((null!=b?b+": ":"")+e);return d}function zg(a,b){var c=0;if(a.A){if(b)return xg(a,b,a.A[b]&&a.A[b].value);b=Object.keys(a.A);b.sort();for(var d=0;d=a?8:262143>=a?18:36);b=wa(b,2,a,"",e);break;case 8:(a=0=a?6:16777215>=a?8:12);b=wa(b,8,a,e?"0o":"");break;case 10:(e=0=Math.abs(b)?5:11;b=wa(b,10,e);break;default:b=n(b,0>2:0,!!e)}0>c?c=b.replace(/^0+([0-9A-F]+)$/i,"$1"):c=b;return c} +var tg={"||":5,"&&":6,"!":7,"|":7,"^!":8,"&":9,"!=":10,"==":10,">=":11,">":11,"<=":11,"<":11,">>>":12,">>":12,"<<":12,"-":13,"+":13,"^/":14,"/":14,"*":14,_:19,"^_":19,"{":20,"}":20},sg={",,":1,"||":5,"&&":6,"!=":10,"==":10,">=":11,">":11,"<=":11,"<":11,">>>":12,">>":12,"<<":12,"-":13,"+":13,"^/":14,"/":14,"*":14,"!":15,"|":15,"^!":15,"&":15,_:19,"^_":19,"{":20,"}":20}; +function Ag(a){mg.call(this,a);this.style=Bg;this.L=Cg();this.ra=Cg();this.T=Cg();this.C=[];this.j=this.M=this.B=[];Dg(this);this.X=0;Eg(this);this.ka={};Fg(this,a.messages);this.ma=a.commands;var b=this;window?void 0===window.pc8080&&(window.pc8080=function(a){return ad(b,a)}):void 0===global.pc8080&&(global.pc8080=function(a){return ad(b,a)})}ia(Ag,mg);l=Ag.prototype; +l.Ea=function(a,b,c,d){this.I=b;this.w=c;this.R=a;(a=Xc(a,"messages"))&&Fg(this,a);this.na=Gg;me(this,64,function(a){a:{var b=d.I.b,c=a[0],e=a=0,k=b.length;if(c){a=Hg(hh(d,c));if(-1===a){d.i("invalid address: "+c);break a}e=a>>>d.I.g;k=1}d.i("blockid physical blockaddr used size type");d.i("-------- --------- ---------- ------ ------ ----");c=-1;for(var p=0;k--;){var v=b[e];v.type==c?p++||d.i("..."):(c=v.type,p=fc[c],v&&d.i(n(v.id)+" %"+n(e<>>e.g;f!=e.j?e.b[g].Sb(f,b&65535,d):(e.b[g++].nb(f,b&255,d),e.b[g&e.H].nb(0,b>>8&255,d+1));c&&kh(a,c);bd(this.w,!0)}};function Cg(a){return{J:a,Da:!1}}function lh(a){return[a.J,a.Da]}function mh(a){return{J:a[0],Da:a[1]}} +function hh(a,b,c){c=(c?a.L:a.ra).J;if(void 0!==b){var d=b=yg(a,b)||b;var e;if(d.match(/^[a-z_][a-z0-9_]*$/i))for(d=d.toUpperCase(),c=0;cc&&(c=Ma(qh,a.substr(b,1)));return c};function rh(a,b){var c=0;a=a.Kb(b);if(void 0!==a)switch(b){case sh:case th:case uh:case vh:case wh:case xh:case yh:case zh:c=2;break;case Ah:case Bh:case Ch:case Dh:case Eh:case Fh:case Gh:c=4}return c?n(a,c):"??"} +l.Kb=function(a){if(0<=a){var b=this.w;switch(a){case sh:var c=b.g;break;case th:c=b.u;break;case uh:c=b.A;break;case Ah:c=Hd(b);break;case vh:c=b.B;break;case wh:c=b.C;break;case Bh:c=Jd(b);break;case xh:c=b.F;break;case yh:c=b.G;break;case Ch:c=D(b);break;case zh:c=E(b,D(b));break;case Dh:c=b.M;break;case Eh:c=b.j;break;case Fh:c=Fd(b);break;case Gh:c=Fd(b)&255|b.g<<8}}return c}; +function Hh(a,b){b=yg(a,b)||b;for(var c=0,d,e;0<=(c=b.indexOf("@",c));)e=a.Jb(b,c+1),0<=e&&(b=b.substr(0,c)+rh(a,e)+b.substr(c+1+qh[e].length)),c++;for(c=0;0<=(c=b.indexOf("#",c));)e=b.substr(c+1,2),d=ta(e,16),null!=d&&32<=d&&128>d?(d=e+" '"+String.fromCharCode(d)+"'",b=b.replace("#"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("$",c));)e=b.substr(c+1,9),(d=hh(a,e))?(d=e+' "'+ph(a,d)+'"',b=b.replace("$"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("^",c));)e=b.substr(c+1,9),(d=hh(a,e))?(kh(d),d= +e+' "'+ph(a,d,11)+'"',b=b.replace("^"+e,d),c+=d.length):c++;return b}l.message=function(a,b){b&&(a+=" at "+oh(Cg(this.w.j).J));this.ga&536870912?this.Z.push(a):this.Y&&a==this.Y||(this.Y=a,this.ga&-2147483648&&(Uc(this),a+=" (cpu halted)"),this.i(a),this.w&&(a=this.w,vd(a),a.sa=0,bd(a)))}; +function Sb(a,b,c,d,e,f,g,h){h|=256;null!=f&&(a.ga&h)!=h||a.message(b.Gb+"."+(null!=d?"outPort":"inPort")+"("+q(c)+","+(f?f:"unknown")+(null!=d?","+xa(d):"")+")"+(null!=g?": "+xa(g):"")+(null!=e?" at "+oh(e):""))} +function Eg(a){var b;if(ee(a)){if(!a.H||!a.H.length){a.H=Array(Ih);for(b=0;b>>d.g],!1)}a.M=["br"];if(a.B)for(b=1;b>>d.g],!0);a.B=["bw"];a.sa=0}l.Na=function(a,b,c){var d=!0;c||Oh(this,a,b,!1,!0);if(a!=this.j){var e=Hg(b);if(-1===e)this.i("invalid address: "+oh(b.J)),d=!1;else{var f=this.I;f.b[e>>>f.g].Na(e&f.j,a==this.B)}}d&&(a.push(b),c?b.Da=!0:(Ph(this,a,a.length-1,"set"),Eg(this)));return d}; +function Oh(a,b,c,d,e){var f=!1;c=Hg(c);for(var g=1;g>>d.g],b==a.B));h.Da||Eg(a);break}}return f}function Qh(a,b){for(var c=1;c>24,4);break;case ci:C=n(u.Eb(C,2),4);break;default:u="imm("+q(w)+")";break a}u.style==Th&&w&di?C="["+C+"]":w&ei||(C=(u.style==Bg?"$":"0x")+C);u=C}else w&ei?(u=(x&fi)>>8, +w=qh[u],a.style==Th&&x&di&&(u==zh&&(w="HL"),w="["+w+"]"),u=w):w&gi&&(u=(f>>3&7).toString());if(!u||!u.length){h="INVALID";break}0b[0]?1:a[0]>>0;for(b=0;b>>0,h=f.Pd;if(e>=g&&e>8&255;case "C":d.A=f&255;break;case "D":d.B=f&255;break; +case "DE":d.B=f>>8&255;case "E":d.C=f&255;break;case "H":d.F=f&255;break;case "HL":d.F=f>>8&255;case "L":d.G=f&255;break;case "SP":d.M=f&65535;break;case "PC":B(d,f);a.L=Cg(d.j);break;case "PS":Dd(d,f);break;case "PSW":Dd(d,f&255|d.N&-256);d.g=f>>8;break;case "CF":d.H=f?d.H|256:d.H&255;break;case "PF":f?Od(d)||(d.L^=1):Od(d)&&(d.L^=1);break;case "AF":d.O=f?~d.L&16|d.O&-17:d.L&16|d.O&-17;break;case "ZF":d.H=f?d.H&-256:d.H|255;break;case "SF":f?Rd(d)||(d.L^=192):Rd(d)&&(d.L^=192);break;case "IF":d.N= +f?d.N|512:d.N&-513;break;default:a.i("unknown register: "+e);return}bd(d);a.i("updated registers:")}a.i(ki(a));c&&(a.L=Cg(d.j),Mh(a,oh(a.L.J)))}}function ri(a,b){b=Ga(b);var c=b.match(/^(['"])(.*?)\1$/);c?a.i(Hh(a,c[2])):wg(a,b,!1)}function si(a,b,c){var d="t"!=b;c=qg(a,c,null,!0)||1;var e=1==c?0:1;"tc"==b&&(e=c,c=1);bb(c,function(){return Pb(a,!0)&&jh(a,e,d,!1)},function(){bd(a.w);Pb(a,!1)})} +function Mh(a,b,c,d){if(b=hh(a,b,!0)){void 0===d&&(d=1);var e=256;if(void 0!==c){d=hh(a,c,!0);if(!d||d.Jh[0].indexOf("+"))){var p=h[0]+":";h[2]&&(p+=" "+h[2]);a.i(p)}h[3]&&(g=h[3],f=null);f=Sh(a,b,g,f);a.i(f);a.L=b;e-=b.J-k;c++}}} +l.yb=function(a,b,c){if(b)if(a){0>this.b&&this.g.length&&(this.b=0);if(0>this.b||a!=this.g[this.b])this.g.splice(0,0,a),this.b=0;this.b--}else this.N?a="end":a=this.g[this.b+1];b=[];if(a){a=a.toLowerCase().replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(Ga(a.substring(d,f))),d=f+1}}return b}; +function Rh(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.i(">> "+b):(a.N&&(a.i("ended assemble at "+oh(a.T.J)),a.L=a.T,a.N=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.Y=null;if(Mb(a)&&0p||"z"db.length&&(a.i("note: only "+db.length+" available"),Ba=db.length);Pa-=Ba;0>Pa&&(null==db[db.length-1].J?(Ba=Pa+Ba,Pa=0):Pa+=db.length);var ye= +[];"call"==Ng&&(rc=1E5,ye=["CALL"]);for(void 0!==Mg&&a.i(Ba+" instructions earlier:");0=db.length&&(Pa=0);a.va=Ba;Pg++;rc--}}Pg||(a.i("no "+Og+"history available"),a.va=void 0)}else{var hd=hh(a,na);if(hd){var id=0;va&&("l"==va.charAt(0)&&(va=va.substr(1)||Xi),id=qg(a,va)>>>0,65536>4||1;Zi--&&0ld?String.fromCharCode(ld):".";kd--}tc&&(tc+="\n");tc+=na+" "+Be+(0==uc?" "+Sg:"")}tc&&a.i(tc);a.ra=hd}}}}break;case "e":if("else"==f[0])break;var md=1,Tg=255,Ug=a.Fa,Vg=a.Xb;"ew"==f[0]&&(md=2,Tg=65535,Ug=a.Eb,Vg=a.Pc);var Wg=md<<1,Xg=f[1];if(null==Xg)a.i("edit memory commands:"), +a.i("\teb [a] [...] edit bytes at address a"),a.i("\tew [a] [...] edit words at address a");else{var nd=hh(a,Xg);if(nd)for(var od=2;odHe;){for(var Bb=null,ej=256;65536>xc.J>>>0;){ah.J= +a.Eb(xc,2);if(null==xc.J||!ej--)break;for(var fj=a,pd=ah,bh=null,yc=pd.J,ch=yc,Ie=1;6>=Ie&&yc;Ie++){if(2\nLicense: GPL version 3 or later ");for(b=0;bCi){if(Ei(d,this.H)){this.u=new Gd(this,"1.37.1",Ni);Ei(this.u)&&(Oi(this,d),a=Pi,Qi(this.u));this.u.set(Ki,Ja());Ri(this.u);var e=this.b&&!this.F;if(a==Li||wb("Click OK to restore the previous PC8080 machine state, or CANCEL to reset the machine.")){if(c=Ji(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Ei(d,g):("error"==f&&"no machine state"!= +g?(this.aa("Error: "+g),"unable to verify user"==g&&(Wa(Si,""),this.g=null)):this.i(f+": "+g),Qi(d),Ei(d)?(c=Ji(d),e=!0):c=!1))}e&&Hi(this,c?d:null)}else a==Pi&&d.clear()}else Hi(this);delete this.H;delete this.L}e=Cb(this.id);for(f=0;fa[1];a=a[2];this.V=!0;this.D.ia=!0;var d=this.P.power;d&&(d.textContent="Shutdown");this.w&&(Ti(this,this.w,b,c,a),this.w.hb());this.O&&(Oi(this,b),b.clear());!c&&this.u&&(this.u.clear(),delete this.u);this.j=0}; +function Oi(a,b){if(wb("There may be a problem with your PC8080 machine.\n\nTo help us diagnose it, click OK to send this PC8080 machine state to http://www.pcjs.org.")){var c=a.g||"";b=b.toString();var d={app:"PC8080",ver:"1.37.1"};d.url=a.W;d.user=c;d.type="bug";d.data=b;Qa("http://www.pcjs.org/api/v1/report",d,!0)}} +function ti(a,b,c){var d="none";if(a.j)return null;a.j--;var e=new Gd(a,"1.37.1"),f=new Gd(a,"1.37.1",Ii),g=Ja();f.set(Ki,g);e.set(Ki,g);e.set(Ui,"1.37.1");e.set(Vi,window?window.location.href:null);e.set(Wi,Sa());if(a.w&&a.w.ta){c&&ed(a.w);var h=a.w.ta(b,c);"object"===typeof h&&e.set(a.w.id,h);c&&(a.w.D.ia=!1,!1===h&&(d=null))}g=Cb(a.id);for(var k=0;kf.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),d?"}"==d.slice(-1)?(d=d.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(d?" parms='"+d+"'":"")+(f?' url="'+f+'"':"")));e||(a=a.replace(/().*?(<\/xsl:variable>)/, +"$1PC8080$2"),a=a.replace(/().*?(<\/xsl:variable>)/,"$1pc8080$2"));f=null;if("<"==a.charAt(0))try{e||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(v){f=null,a=v.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");Qa(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],p,v=/( [a-z]+=)(['"])(.*?)\2/gi;p=v.exec(f);)k=0>k.toLowerCase().indexOf(p[1].toLowerCase())?k.replace(">",p[0]+">"):k.replace(new RegExp(p[1]+"(['\"])(.*?)\\1"),p[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+ +"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/,"");a=a.replace(d[0],g);rj(a,b,c)}})}else c(a,null)} +function sj(a,b,c,d){function e(a){if(void 0===h){var b=g&&zb(g,"machine-warning");h=b&&b[0]||g}h&&(h.innerHTML=Da(a))}function f(a){e("Error: "+a);k&&(--oj||mb(!0));k=!1}var g,h,k=!0;oj++;ub[a]={};try{if(g=document.getElementById(a)){var p;if("object"==typeof resources&&(p=resources.css)){var v=document.head||document.getElementsByTagName("head")[0],x=document.createElement("style");x.type="text/css";x.styleSheet?x.styleSheet.cssText=p:x.appendChild(document.createTextNode(p));v.appendChild(x)}c|| +(c="/versions/pc8080/1.37.1/components.xsl");p=function(d,h){h?pj(c,null,null,!1,e,function(d,k){k?(tb(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(k=h.transformNode(k))?(g.outerHTML=k,--oj||mb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(k),(k=d.transformToFragment(h,document))?g.parentNode?(g.parentNode.replaceChild(k,g),--oj||mb(!0)):f("invalid machine element: "+ +a):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?pj(b,a,d,!0,e,p):qj(b,null,a,d,!1,e,p)}else f("missing machine element: "+a)}catch(z){f(z.message)}return k}window.embedPC8080=function(a,b,c,d){mb(!1);return sj(a,b,c,d)}; +window.commandMachine=function(a,b,c,d,e,f){if("script"==e){d=!1;c+=".machine";if(!f)delete Gb[c],d=!0;else if("string"==typeof f&&!Gb[c]){d=!0;e=Gb;for(var g=c,h=f.length,k=[],p=[],v="",x=null,z=0;z 1 G (Ground) + * TD 2 <-> 3 RD (Received Data) + * RD 3 <-> 2 TD (Transmitted Data) + * RTS 4 <-> 5 CTS (Clear To Send) + * CTS 5 <-> 4 RTS (Request To Send) + * DSR 6+8 <-> 20 DTR (Data Terminal Ready) + * SG 7 <-> 7 SG (Signal Ground) + * DTR 20 <-> 6+8 DSR (Data Set Ready + Carrier Detect) + * RI 22 <-> 22 RI (Ring Indicator) + * + * TODO: Move these definitions to a more appropriate shared file at some point. + */ +var RS232 = { + RTS: { + PIN: 4, + MASK: 0x00000010 + }, + CTS: { + PIN: 5, + MASK: 0x00000020 + }, + DSR: { + PIN: 6, + MASK: 0x00000040 + }, + CD: { + PIN: 8, + MASK: 0x00000100 + }, + DTR: { + PIN: 20, + MASK: 0x00100000 + }, + RI: { + PIN: 22, + MASK: 0x00400000 + } +}; + +/* + * NODE should be true if we're running under NodeJS (eg, command-line), false if not (eg, web browser) + */ +var NODE = false; + + +/** + * @copyright http://pcjs.org/modules/shared/lib/dumpapi.js (C) Jeff Parsons 2012-2017 + */ + +/* + * Our "DiskDump API", such as it was, used to look like: + * + * http://jsmachines.net/bin/convdisk.php?disk=/disks/pc/dos/ibm/2.00/PCDOS200-DISK1.json&format=img + * + * To make it (a bit) more "REST-like", the above request now looks like: + * + * http://www.pcjs.org/api/v1/dump?disk=/disks/pc/dos/ibm/2.00/PCDOS200-DISK1.json&format=img + * + * Similarly, our "FileDump API" used to look like: + * + * http://jsmachines.net/bin/convrom.php?rom=/devices/pc/rom/5150/1981-04-24/PCBIOS-REV1.rom&format=json + * + * and that request now looks like: + * + * http://www.pcjs.org/api/v1/dump?file=/devices/pc/rom/5150/1981-04-24/PCBIOS-REV1.rom&format=json + * + * I don't think it makes sense to avoid "query" parameters, because blending the path of a disk image with the + * the rest of the URL would be (a) confusing, and (b) more work to parse. + */ +var DumpAPI = { + ENDPOINT: "/api/v1/dump", + QUERY: { + DIR: "dir", // value is path of a directory (DiskDump only) + DISK: "disk", // value is path of a disk image (DiskDump only) + FILE: "file", // value is path of a ROM image file (FileDump only) + IMG: "img", // alias for DISK + PATH: "path", // value is path of a one or more files (DiskDump only) + FORMAT: "format", // value is one of FORMAT values below + COMMENTS: "comments", // value is either "true" or "false" + DECIMAL: "decimal", // value is either "true" to force all numbers to decimal, "false" or undefined otherwise + MBHD: "mbhd", // value is hard drive size in Mb (formerly "mbsize") (DiskDump only) (DEPRECATED) + SIZE: "size" // value is target disk size in Kb (supersedes "mbhd") (DiskDump only) + }, + FORMAT: { + JSON: "json", // default + JSON_GZ: "gz", // gzip is currently used ONLY for compressed JSON + DATA: "data", // same as "json", but built without JSON.stringify() (DiskDump only) + HEX: "hex", // deprecated + OCTAL: "octal", // displays data as octal words + BYTES: "bytes", // displays data as hex bytes; normally used only when comments are enabled + WORDS: "words", // displays data as hex words; normally used only when comments are enabled + LONGS: "longs", // displays data as dwords + IMG: "img", // returns the raw disk data (ie, using a Buffer object) (DiskDump only) + ROM: "rom" // returns the raw file data (ie, using a Buffer object) (FileDump only) + } +}; + +/* + * Because we use an overloaded API endpoint (ie, one that's shared with the FileDump module), we must + * also provide a list of commands which, when combined with the endpoint, define a unique request. + */ +DumpAPI.asDiskCommands = [DumpAPI.QUERY.DIR, DumpAPI.QUERY.DISK, DumpAPI.QUERY.PATH]; +DumpAPI.asFileCommands = [DumpAPI.QUERY.FILE]; + + + +/** + * @copyright http://pcjs.org/modules/shared/lib/reportapi.js (C) Jeff Parsons 2012-2017 + */ + +var ReportAPI = { + ENDPOINT: "/api/v1/report", + QUERY: { + APP: "app", + VER: "ver", + URL: "url", + USER: "user", + TYPE: "type", + DATA: "data" + }, + TYPE: { + BUG: "bug" + }, + RES: { + OK: "Thank you" + } +}; + + + +/** + * @copyright http://pcjs.org/modules/shared/lib/userapi.js (C) Jeff Parsons 2012-2017 + */ + +/* + * Examples of User API requests: + * + * web.getHost() + UserAPI.ENDPOINT + '?' + UserAPI.QUERY.REQ + '=' + UserAPI.REQ.VERIFY + '&' + UserAPI.QUERY.USER + '=' + sUser; + */ +var UserAPI = { + ENDPOINT: "/api/v1/user", + QUERY: { + REQ: "req", // specifies a request + USER: "user", // specifies a user ID + STATE: "state", // specifies a state ID + DATA: "data" // specifies state data + }, + REQ: { + CREATE: "create", // creates a user ID + VERIFY: "verify", // requests verification of a user ID + STORE: "store", // stores a machine state on the server + LOAD: "load" // loads a machine state from the server + }, + RES: { + CODE: "code", + DATA: "data" + }, + CODE: { + OK: "ok", + FAIL: "error" + }, + FAIL: { + DUPLICATE: "user already exists", + VERIFY: "unable to verify user", + BADSTATE: "invalid state parameter", + NOSTATE: "no machine state", + BADLOAD: "unable to load machine state", + BADSTORE: "unable to save machine state" + } +}; + + + +/** + * @copyright http://pcjs.org/modules/shared/lib/keys.js (C) Jeff Parsons 2012-2017 + */ + +var Keys = { + /* + * Keys and/or key combinations that generate common ASCII codes. + * + * NOTE: If you're looking for a general-purpose ASCII code table, see Str.ASCII in strlib.js; + * if something's missing, that's probably the more appropriate table to add it to. + * + * TODO: The Closure Compiler doesn't inline all references to these values, at least those with + * quoted property names, which is why I've 'unquoted' as many of them as possible. One solution + * would be to add mnemonics for all of them, not just the non-printable ones (eg, SPACE instead + * of ' ', AMP instead of '&', etc.) + */ + ASCII: { + BREAK: 0, CTRL_A: 1, CTRL_B: 2, CTRL_C: 3, CTRL_D: 4, CTRL_E: 5, CTRL_F: 6, CTRL_G: 7, + CTRL_H: 8, CTRL_I: 9, CTRL_J: 10, CTRL_K: 11, CTRL_L: 12, CTRL_M: 13, CTRL_N: 14, CTRL_O: 15, + CTRL_P: 16, CTRL_Q: 17, CTRL_R: 18, CTRL_S: 19, CTRL_T: 20, CTRL_U: 21, CTRL_V: 22, CTRL_W: 23, + CTRL_X: 24, CTRL_Y: 25, CTRL_Z: 26, + ' ': 32, '!': 33, '"': 34, '#': 35, '$': 36, '%': 37, '&': 38, "'": 39, + '(': 40, ')': 41, '*': 42, '+': 43, ',': 44, '-': 45, '.': 46, '/': 47, + '0': 48, '1': 49, '2': 50, '3': 51, '4': 52, '5': 53, '6': 54, '7': 55, + '8': 56, '9': 57, ':': 58, ';': 59, '<': 60, '=': 61, '>': 62, '?': 63, + '@': 64, A: 65, B: 66, C: 67, D: 68, E: 69, F: 70, G: 71, + H: 72, I: 73, J: 74, K: 75, L: 76, M: 77, N: 78, O: 79, + P: 80, Q: 81, R: 82, S: 83, T: 84, U: 85, V: 86, W: 87, + X: 88, Y: 89, Z: 90, '[': 91, '\\':92, ']': 93, '^': 94, '_': 95, + '`': 96, a: 97, b: 98, c: 99, d: 100, e: 101, f: 102, g: 103, + h: 104, i: 105, j: 106, k: 107, l: 108, m: 109, n: 110, o: 111, + p: 112, q: 113, r: 114, s: 115, t: 116, u: 117, v: 118, w: 119, + x: 120, y: 121, z: 122, '{':123, '|':124, '}':125, '~':126, DEL: 127 + }, + /* + * Browser keyCodes we must pay particular attention to. For the most part, these are non-alphanumeric + * or function keys, some which may require special treatment (eg, preventDefault() if returning false on + * the initial keyDown event is insufficient). + * + * keyCodes for most common ASCII keys can simply use the appropriate ASCII code above. + * + * Most of these represent non-ASCII keys (eg, the LEFT arrow key), yet for some reason, browsers defined + * them using ASCII codes (eg, the LEFT arrow key uses the ASCII code for '%' or 37). + */ + KEYCODE: { + /* 0x08 */ BS: 8, // BACKSPACE (ASCII.CTRL_H) + /* 0x09 */ TAB: 9, // TAB (ASCII.CTRL_I) + /* 0x0A */ LF: 10, // LINE FEED (ASCII.CTRL_J) (TODO: Determine if any key actually generates this) + /* 0x0D */ CR: 13, // CARRIAGE RETURN (ASCII.CTRL_M) + /* 0x10 */ SHIFT: 16, + /* 0x11 */ CTRL: 17, + /* 0x12 */ ALT: 18, + /* 0x13 */ PAUSE: 19, // PAUSE/BREAK + /* 0x14 */ CAPS_LOCK: 20, + /* 0x1B */ ESC: 27, + /* 0x20 */ SPACE: 32, + /* 0x21 */ PGUP: 33, + /* 0x22 */ PGDN: 34, + /* 0x23 */ END: 35, + /* 0x24 */ HOME: 36, + /* 0x25 */ LEFT: 37, + /* 0x26 */ UP: 38, + /* 0x27 */ RIGHT: 39, + /* 0x27 */ FF_QUOTE: 39, + /* 0x28 */ DOWN: 40, + /* 0x2C */ FF_COMMA: 44, + /* 0x2C */ PRTSC: 44, + /* 0x2D */ INS: 45, + /* 0x2E */ DEL: 46, + /* 0x2E */ FF_PERIOD: 46, + /* 0x2F */ FF_SLASH: 47, + /* 0x30 */ ZERO: 48, + /* 0x31 */ ONE: 49, + /* 0x32 */ TWO: 50, + /* 0x33 */ THREE: 51, + /* 0x34 */ FOUR: 52, + /* 0x35 */ FIVE: 53, + /* 0x36 */ SIX: 54, + /* 0x37 */ SEVEN: 55, + /* 0x38 */ EIGHT: 56, + /* 0x39 */ NINE: 57, + /* 0x3B */ FF_SEMI: 59, + /* 0x3D */ FF_EQUALS: 61, + /* 0x5B */ CMD: 91, // aka WIN + /* 0x5B */ FF_LBRACK: 91, + /* 0x5C */ FF_BSLASH: 92, + /* 0x5D */ RCMD: 93, // aka MENU + /* 0x5D */ FF_RBRACK: 93, + /* 0x60 */ NUM_0: 96, + /* 0x60 */ NUM_INS: 96, + /* 0x60 */ FF_BQUOTE: 96, + /* 0x61 */ NUM_1: 97, + /* 0x61 */ NUM_END: 97, + /* 0x62 */ NUM_2: 98, + /* 0x62 */ NUM_DOWN: 98, + /* 0x63 */ NUM_3: 99, + /* 0x63 */ NUM_PGDN: 99, + /* 0x64 */ NUM_4: 100, + /* 0x64 */ NUM_LEFT: 100, + /* 0x65 */ NUM_5: 101, + /* 0x65 */ NUM_CENTER: 101, + /* 0x66 */ NUM_6: 102, + /* 0x66 */ NUM_RIGHT: 102, + /* 0x67 */ NUM_7: 103, + /* 0x67 */ NUM_HOME: 103, + /* 0x68 */ NUM_8: 104, + /* 0x68 */ NUM_UP: 104, + /* 0x69 */ NUM_9: 105, + /* 0x69 */ NUM_PGUP: 105, + /* 0x6A */ NUM_MUL: 106, + /* 0x6B */ NUM_ADD: 107, + /* 0x6D */ NUM_SUB: 109, + /* 0x6E */ NUM_DEL: 110, // aka PERIOD + /* 0x6F */ NUM_DIV: 111, + /* 0x70 */ F1: 112, + /* 0x71 */ F2: 113, + /* 0x72 */ F3: 114, + /* 0x73 */ F4: 115, + /* 0x74 */ F5: 116, + /* 0x75 */ F6: 117, + /* 0x76 */ F7: 118, + /* 0x77 */ F8: 119, + /* 0x78 */ F9: 120, + /* 0x79 */ F10: 121, + /* 0x7A */ F11: 122, + /* 0x7B */ F12: 123, + /* 0x90 */ NUM_LOCK: 144, + /* 0x91 */ SCROLL_LOCK: 145, + /* 0xAD */ FF_DASH: 173, + /* 0xBA */ SEMI: 186, // Firefox: 59 (FF_SEMI) + /* 0xBB */ EQUALS: 187, // Firefox: 61 (FF_EQUALS) + /* 0xBC */ COMMA: 188, + /* 0xBD */ DASH: 189, // Firefox: 173 (FF_DASH) + /* 0xBE */ PERIOD: 190, + /* 0xBF */ SLASH: 191, + /* 0xC0 */ BQUOTE: 192, + /* 0xDB */ LBRACK: 219, + /* 0xDC */ BSLASH: 220, + /* 0xDD */ RBRACK: 221, + /* 0xDE */ QUOTE: 222, + /* 0xE0 */ FF_CMD: 224, // Firefox only (used for both CMD and RCMD) + // + // The following biases use what I'll call Decimal Coded Binary or DCB (the opposite of BCD), + // where the thousands digit is used to store the sum of "binary" digits 1 and/or 2 and/or 4. + // + // Technically, that makes it DCO (Decimal Coded Octal), but then again, BCD should have really + // been called HCD (Hexadecimal Coded Decimal), so if "they" can take liberties, so can I. + // + // ONDOWN is a bias we add to browser keyCodes that we want to handle on "down" rather than on "press". + // + ONDOWN: 1000, + // + // ONRIGHT is a bias we add to browser keyCodes that need to check for a "right" location (default is "left") + // + ONRIGHT: 2000, + // + // FAKE is a bias we add to signal these are fake keyCodes corresponding to internal keystroke combinations. + // The actual values are for internal use only and merely need to be unique and used consistently. + // + FAKE: 4000 + }, + /* + * The set of values that a browser may store in the 'location' property of a keyboard event object + * which we also support. + */ + LOCATION: { + LEFT: 1, + RIGHT: 2, + NUMPAD: 3 + } +}; + +/* + * Check the event object's 'location' property for a non-zero value for the following ONRIGHT keys. + */ +Keys.KEYCODE.NUM_CR = Keys.KEYCODE.CR + Keys.KEYCODE.ONRIGHT; + + +/* + * Maps Firefox keyCodes to their more common keyCode counterparts; a number of entries in this table + * are no longer valid (if indeed they ever were), so they've been commented out. It's likely that I + * simply extended this table to resolve additional differences in other browsers (ie, Opera), but without + * browser-specific checks, it's not safe to perform all the mappings shown below. + */ +Keys.FF_KEYCODES = {}; +Keys.FF_KEYCODES[Keys.KEYCODE.FF_SEMI] = Keys.KEYCODE.SEMI; // 59 -> 186 +Keys.FF_KEYCODES[Keys.KEYCODE.FF_EQUALS] = Keys.KEYCODE.EQUALS; // 61 -> 187 +Keys.FF_KEYCODES[Keys.KEYCODE.FF_DASH] = Keys.KEYCODE.DASH; // 173 -> 189 +Keys.FF_KEYCODES[Keys.KEYCODE.FF_CMD] = Keys.KEYCODE.CMD; // 224 -> 91 +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_COMMA] = Keys.KEYCODE.COMMA; // 44 -> 188 +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_PERIOD] = Keys.KEYCODE.PERIOD; // 46 -> 190 +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_SLASH] = Keys.KEYCODE.SLASH; // 47 -> 191 +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_BQUOTE] = Keys.KEYCODE.BQUOTE; // 96 -> 192 +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_LBRACK = Keys.KEYCODE.LBRACK; // 91 -> 219 +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_BSLASH] = Keys.KEYCODE.BSLASH; // 92 -> 220 +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_RBRACK] = Keys.KEYCODE.RBRACK; // 93 -> 221 +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_QUOTE] = Keys.KEYCODE.QUOTE; // 39 -> 222 + +/* + * Maps non-ASCII keyCodes to their ASCII counterparts + */ +Keys.NONASCII_KEYCODES = {}; +Keys.NONASCII_KEYCODES[Keys.KEYCODE.FF_DASH] = Keys.ASCII['-']; // 173 -> 45 +Keys.NONASCII_KEYCODES[Keys.KEYCODE.SEMI] = Keys.ASCII[';']; // 186 -> 59 +Keys.NONASCII_KEYCODES[Keys.KEYCODE.EQUALS] = Keys.ASCII['=']; // 187 -> 61 +Keys.NONASCII_KEYCODES[Keys.KEYCODE.DASH] = Keys.ASCII['-']; // 189 -> 45 +Keys.NONASCII_KEYCODES[Keys.KEYCODE.COMMA] = Keys.ASCII[',']; // 188 -> 44 +Keys.NONASCII_KEYCODES[Keys.KEYCODE.PERIOD] = Keys.ASCII['.']; // 190 -> 46 +Keys.NONASCII_KEYCODES[Keys.KEYCODE.SLASH] = Keys.ASCII['/']; // 191 -> 47 +Keys.NONASCII_KEYCODES[Keys.KEYCODE.BQUOTE] = Keys.ASCII['`']; // 192 -> 96 +Keys.NONASCII_KEYCODES[Keys.KEYCODE.LBRACK] = Keys.ASCII['[']; // 219 -> 91 +Keys.NONASCII_KEYCODES[Keys.KEYCODE.BSLASH] = Keys.ASCII['\\']; // 220 -> 92 +Keys.NONASCII_KEYCODES[Keys.KEYCODE.RBRACK] = Keys.ASCII[']']; // 221 -> 93 +Keys.NONASCII_KEYCODES[Keys.KEYCODE.QUOTE] = Keys.ASCII["'"]; // 222 -> 39 + +/* + * Maps unshifted keyCodes to their shifted counterparts; to be used when a shift-key is down. + * Alphabetic characters are handled in code, since they must also take CAPS_LOCK into consideration. + */ +Keys.SHIFTED_KEYCODES = {}; +Keys.SHIFTED_KEYCODES[Keys.ASCII['1']] = Keys.ASCII['!']; +Keys.SHIFTED_KEYCODES[Keys.ASCII['2']] = Keys.ASCII['@']; +Keys.SHIFTED_KEYCODES[Keys.ASCII['3']] = Keys.ASCII['#']; +Keys.SHIFTED_KEYCODES[Keys.ASCII['4']] = Keys.ASCII['$']; +Keys.SHIFTED_KEYCODES[Keys.ASCII['5']] = Keys.ASCII['%']; +Keys.SHIFTED_KEYCODES[Keys.ASCII['6']] = Keys.ASCII['^']; +Keys.SHIFTED_KEYCODES[Keys.ASCII['7']] = Keys.ASCII['&']; +Keys.SHIFTED_KEYCODES[Keys.ASCII['8']] = Keys.ASCII['*']; +Keys.SHIFTED_KEYCODES[Keys.ASCII['9']] = Keys.ASCII['(']; +Keys.SHIFTED_KEYCODES[Keys.ASCII['0']] = Keys.ASCII[')']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.SEMI] = Keys.ASCII[':']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.EQUALS] = Keys.ASCII['+']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.COMMA] = Keys.ASCII['<']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.DASH] = Keys.ASCII['_']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.PERIOD] = Keys.ASCII['>']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.SLASH] = Keys.ASCII['?']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.BQUOTE] = Keys.ASCII['~']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.LBRACK] = Keys.ASCII['{']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.BSLASH] = Keys.ASCII['|']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.RBRACK] = Keys.ASCII['}']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.QUOTE] = Keys.ASCII['"']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.FF_DASH] = Keys.ASCII['_']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.FF_EQUALS] = Keys.ASCII['+']; +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.FF_SEMI] = Keys.ASCII[':']; + + + +/** + * @copyright http://pcjs.org/modules/shared/lib/strlib.js (C) Jeff Parsons 2012-2017 + */ + +class Str { + /** + * isValidInt(s, base) + * + * The built-in parseInt() function has the annoying feature of returning a partial value (ie, + * up to the point where it encounters an invalid character); eg, parseInt("foo", 16) returns 0xf. + * + * So it's best to use our own Str.parseInt() function, which will in turn use this function to + * validate the entire string. + * + * @param {string} s is the string representation of some number + * @param {number} [base] is the radix to use (default is 10); only 2, 8, 10 and 16 are supported + * @return {boolean} true if valid, false if invalid (or the specified base isn't supported) + */ + static isValidInt(s, base) + { + if (!base || base == 10) return s.match(/^-?[0-9]+$/) !== null; + if (base == 16) return s.match(/^-?[0-9a-f]+$/i) !== null; + if (base == 8) return s.match(/^-?[0-7]+$/) !== null; + if (base == 2) return s.match(/^-?[01]+$/) !== null; + return false; + } + + /** + * parseInt(s, base) + * + * This is a wrapper around the built-in parseInt() function. Our wrapper recognizes certain prefixes + * ('$' or "0x" for hex, '#' or "0o" for octal) and suffixes ('.' for decimal, 'h' for hex, 'y' for + * binary), and then calls isValidInt() to ensure we don't convert strings that contain partial values; + * see isValidInt() for details. + * + * The use of multiple prefix/suffix combinations is undefined (although for the record, we process + * prefixes first). We do NOT support the "0b" prefix to indicate binary UNLESS one or more commas are + * also present (because "0b" is also a valid hex sequence), and we do NOT support a single leading zero + * to indicate octal (because such a number could also be decimal or hex). Any number of commas are + * allowed; we remove them all before calling the built-in parseInt(). + * + * More recently, we've added support for "^D", "^O", and "^B" prefixes to accommodate the base overrides + * that the PDP-10's MACRO-10 assembly language supports (decimal, octal, and binary, respectively). + * If this support turns out to adversely affect other debuggers, then it will have to be "conditionalized". + * Similarly, we've added support for "K", "M", and "G" MACRO-10-style suffixes that add 3, 6, or 9 zeros + * to the value to be parsed, respectively. + * + * @param {string} s is the string representation of some number + * @param {number} [base] is the radix to use (default is 10); can be overridden by prefixes/suffixes + * @return {number|undefined} corresponding value, or undefined if invalid + */ + static parseInt(s, base) + { + var value; + + if (s) { + if (!base) base = 10; + + var ch, chPrefix, chSuffix; + var fCommas = (s.indexOf(',') > 0); + if (fCommas) s = s.replace(/,/g, ''); + + ch = chPrefix = s.charAt(0); + if (chPrefix == '#') { + base = 8; + chPrefix = ''; + } + else if (chPrefix == '$') { + base = 16; + chPrefix = ''; + } + if (ch != chPrefix) { + s = s.substr(1); + } + else { + ch = chPrefix = s.substr(0, 2); + if (chPrefix == '0b' && fCommas || chPrefix == '^B') { + base = 2; + chPrefix = ''; + } + else if (chPrefix == '0o' || chPrefix == '^O') { + base = 8; + chPrefix = ''; + } + else if (chPrefix == '^D') { + base = 10; + chPrefix = ''; + } + else if (chPrefix == '0x') { + base = 16; + chPrefix = ''; + } + if (ch != chPrefix) s = s.substr(2); + } + ch = chSuffix = s.slice(-1); + if (chSuffix == 'Y' || chSuffix == 'y') { + base = 2; + chSuffix = ''; + } + else if (chSuffix == '.') { + base = 10; + chSuffix = ''; + } + else if (chSuffix == 'H' || chSuffix == 'h') { + base = 16; + chSuffix = ''; + } + else if (chSuffix == 'K') { + chSuffix = '000'; + } + else if (chSuffix == 'M') { + chSuffix = '000000'; + } + else if (chSuffix == 'G') { + chSuffix = '000000000'; + } + if (ch != chSuffix) s = s.slice(0, -1) + chSuffix; + /* + * This adds support for the MACRO-10 binary shifting (Bn) suffix, which must be stripped from the + * number before parsing, and then applied to the value after parsing. If n is omitted, 35 is assumed, + * which is a net shift of zero. If n < 35, then a left shift of (35 - n) is required; if n > 35, then + * a right shift of -(35 - n) is required. + */ + var v, shift = 0; + if (base <= 10) { + var match = s.match(/(-?[0-9]+)B([0-9]*)/); + if (match) { + s = match[1]; + shift = 35 - ((match[2] || 35) & 0xff); + } + } + if (Str.isValidInt(s, base) && !isNaN(v = parseInt(s, base))) { + /* + * With the need to support larger (eg, 36-bit) integers, truncating to 32 bits is no longer helpful. + * + * value = v|0; + */ + if (shift) { + /* + * Since binary shifting is a logical operation, and since shifting by division only works properly + * with positive numbers, we must convert a negative value to a positive value, by computing the two's + * complement. + */ + if (v < 0) v += Math.pow(2, 36); + if (shift > 0) { + v *= Math.pow(2, shift); + } else { + v = Math.trunc(v / Math.pow(2, -shift)); + } + } + value = v; + } + } + return value; + } + + /** + * toBase(n, radix, cch, sPrefix, nGrouping) + * + * Displays the given number as an unsigned integer using the specified radix and number of digits. + * + * @param {number|null|undefined} n + * @param {number} radix (ie, the base) + * @param {number} cch (the desired number of digits) + * @param {string} [sPrefix] (default is none) + * @param {number} [nGrouping] + * @return {string} + */ + static toBase(n, radix, cch, sPrefix = "", nGrouping = 0) + { + /* + * An initial "falsey" check for null takes care of both null and undefined; + * we can't rely entirely on isNaN(), because isNaN(null) returns false, oddly enough. + * + * Alternatively, we could mask and shift n regardless of whether it's null/undefined/NaN, + * since JavaScript coerces such operands to zero, but I think there's "value" in seeing those + * values displayed differently. + */ + var s = ""; + if (isNaN(n)) { + n = null; + } else if (n != null) { + /* + * Callers that produced an input by dividing by a power of two rather than shifting (in order + * to access more than 32 bits) may produce a fractional result, which ordinarily we would simply + * ignore, but if the integer portion is zero and the sign is negative, we should probably treat + * this value as a sign-extension. + */ + if (n < 0 && n > -1) n = -1; + /* + * Negative values should be two's complemented according to the number of digits; for example, + * 12 octal digits implies an upper limit 8^12. + */ + if (n < 0) { + n += Math.pow(radix, cch); + } + if (n >= Math.pow(radix, cch)) { + cch = Math.ceil(Math.log(n) / Math.log(radix)); + } + } + var g = nGrouping || -1; + while (cch-- > 0) { + if (!g) { + s = ',' + s; + g = nGrouping; + } + if (n == null) { + s = '?' + s; + } else { + var d = n % radix; + d += (d >= 0 && d <= 9? 0x30 : 0x41 - 10); + s = String.fromCharCode(d) + s; + n = Math.trunc(n / radix); + } + g--; + } + return sPrefix + s; + } + + /** + * toBin(n, cch, nGrouping) + * + * Converts an integer to binary, with the specified number of digits (up to a maximum of 36). + * + * @param {number|null|undefined} n (supports integers up to 36 bits now) + * @param {number} [cch] is the desired number of binary digits (0 or undefined for default of either 8, 18, or 36) + * @param {number} [nGrouping] + * @return {string} the binary representation of n + */ + static toBin(n, cch, nGrouping) + { + if (!cch) { + // cch = Math.ceil(Math.log(Math.abs(n) + 1) / Math.LN2) || 1; + var v = Math.abs(n); + if (v <= 0b11111111) { + cch = 8; + } else if (v <= 0b111111111111111111) { + cch = 18; + } else { + cch = 36; + } + } else if (cch > 36) cch = 36; + return Str.toBase(n, 2, cch, "", nGrouping); + } + + /** + * toBinBytes(n, cb, fPrefix) + * + * Converts an integer to binary, with the specified number of bytes (up to the default of 4). + * + * @param {number|null|undefined} n (interpreted as a 32-bit value) + * @param {number} [cb] is the desired number of binary bytes (4 is both the default and the maximum) + * @param {boolean} [fPrefix] + * @return {string} the binary representation of n + */ + static toBinBytes(n, cb, fPrefix) + { + var s = ""; + if (!cb || cb > 4) cb = 4; + for (var i = 0; i < cb; i++) { + if (s) s = ',' + s; + s = Str.toBin(n & 0xff, 8) + s; + n >>= 8; + } + return (fPrefix? "0b" : "") + s; + } + + /** + * toOct(n, cch, fPrefix) + * + * Converts an integer to octal, with the specified number of digits (default of 6; max of 12) + * + * You might be tempted to use the built-in n.toString(8) instead, but it doesn't zero-pad and it + * doesn't properly convert negative values. Moreover, if n is undefined, n.toString() will throw + * an exception, whereas this function will return '?' characters. + * + * @param {number|null|undefined} n (supports integers up to 36 bits now) + * @param {number} [cch] is the desired number of octal digits (0 or undefined for default of either 6, 8, or 12) + * @param {boolean} [fPrefix] + * @return {string} the octal representation of n + */ + static toOct(n, cch, fPrefix) + { + if (!cch) { + // cch = Math.ceil(Math.log(Math.abs(n) + 1) / Math.log(8)) || 1; + var v = Math.abs(n); + if (v <= 0o777777) { + cch = 6; + } else if (v <= 0o77777777) { + cch = 8; + } else { + cch = 12; + } + } else if (cch > 12) cch = 12; + return Str.toBase(n, 8, cch, fPrefix? "0o" : ""); + } + + /** + * toDec(n, cch) + * + * Converts an integer to decimal, with the specified number of digits (default of 5; max of 11) + * + * You might be tempted to use the built-in n.toString(10) instead, but it doesn't zero-pad and it + * doesn't properly convert negative values. Moreover, if n is undefined, n.toString() will throw + * an exception, whereas this function will return '?' characters. + * + * @param {number|null|undefined} n (supports integers up to 36 bits now) + * @param {number} [cch] is the desired number of decimal digits (0 or undefined for default of either 5 or 11) + * @return {string} the decimal representation of n + */ + static toDec(n, cch) + { + if (!cch) { + // cch = Math.ceil(Math.log(Math.abs(n) + 1) / Math.LN10) || 1; + var v = Math.abs(n); + if (v <= 99999) { + cch = 5; + } else { + cch = 11; + } + } else if (cch > 11) cch = 11; + return Str.toBase(n, 10, cch); + } + + /** + * toHex(n, cch, fPrefix) + * + * Converts an integer to hex, with the specified number of digits (default of 4 or 8, max of 9). + * + * You might be tempted to use the built-in n.toString(16) instead, but it doesn't zero-pad and it + * doesn't properly convert negative values; for example, if n is -2147483647, then n.toString(16) + * will return "-7fffffff" instead of "80000001". Moreover, if n is undefined, n.toString() will + * throw an exception, whereas this function will return '?' characters. + * + * NOTE: The following work-around (adapted from code found on StackOverflow) would be another solution, + * taking care of negative values, zero-padding, and upper-casing, but not null/undefined/NaN values: + * + * s = (n < 0? n + 0x100000000 : n).toString(16); + * s = "00000000".substr(0, 8 - s.length) + s; + * s = s.substr(0, cch).toUpperCase(); + * + * @param {number|null|undefined} n (supports integers up to 36 bits now) + * @param {number} [cch] is the desired number of hex digits (0 or undefined for default of either 4, 8, or 9) + * @param {boolean} [fPrefix] + * @return {string} the hex representation of n + */ + static toHex(n, cch, fPrefix) + { + if (!cch) { + // cch = Math.ceil(Math.log(Math.abs(n) + 1) / Math.log(16)) || 1; + var v = Math.abs(n); + if (v <= 0xffff) { + cch = 4; + } else if (v <= 0xffffffff) { + cch = 8; + } else { + cch = 9; + } + } else if (cch > 9) cch = 9; + return Str.toBase(n, 16, cch, fPrefix? "0x" : ""); + } + + /** + * toHexByte(b) + * + * Alias for Str.toHex(b, 2, true) + * + * @param {number|null|undefined} b is a byte value + * @return {string} the hex representation of b + */ + static toHexByte(b) + { + return Str.toHex(b, 2, true); + } + + /** + * toHexWord(w) + * + * Alias for Str.toHex(w, 4, true) + * + * @param {number|null|undefined} w is a word (16-bit) value + * @return {string} the hex representation of w + */ + static toHexWord(w) + { + return Str.toHex(w, 4, true); + } + + /** + * toHexLong(l) + * + * Alias for Str.toHex(l, 8, true) + * + * @param {number|null|undefined} l is a dword (32-bit) value + * @return {string} the hex representation of w + */ + static toHexLong(l) + { + return Str.toHex(l, 8, true); + } + + /** + * getBaseName(sFileName, fStripExt) + * + * This is a poor-man's version of Node's path.basename(), which Node-only components should use instead. + * + * Note that if fStripExt is true, this strips ANY extension, whereas path.basename() strips the extension only + * if it matches the second parameter (eg, path.basename("/foo/bar/baz/asdf/quux.html", ".html") returns "quux"). + * + * @param {string} sFileName + * @param {boolean} [fStripExt] + * @return {string} + */ + static getBaseName(sFileName, fStripExt) + { + var sBaseName = sFileName; + + var i = sFileName.lastIndexOf('/'); + if (i >= 0) sBaseName = sFileName.substr(i + 1); + + /* + * This next bit is a kludge to clean up names that are part of a URL that includes unsightly query parameters. + */ + i = sBaseName.indexOf('&'); + if (i > 0) sBaseName = sBaseName.substr(0, i); + + if (fStripExt) { + i = sBaseName.lastIndexOf("."); + if (i > 0) { + sBaseName = sBaseName.substring(0, i); + } + } + return sBaseName; + } + + /** + * getExtension(sFileName) + * + * This is a poor-man's version of Node's path.extname(), which Node-only components should use instead. + * + * Note that we EXCLUDE the period from the returned extension, whereas path.extname() includes it. + * + * @param {string} sFileName + * @return {string} the filename's extension (in lower-case and EXCLUDING the "."), or an empty string + */ + static getExtension(sFileName) + { + var sExtension = ""; + var i = sFileName.lastIndexOf("."); + if (i >= 0) { + sExtension = sFileName.substr(i + 1).toLowerCase(); + } + return sExtension; + } + + /** + * endsWith(s, sSuffix) + * + * @param {string} s + * @param {string} sSuffix + * @return {boolean} true if s ends with sSuffix, false if not + */ + static endsWith(s, sSuffix) + { + return s.indexOf(sSuffix, s.length - sSuffix.length) !== -1; + } + + /** + * escapeHTML(sHTML) + * + * @param {string} sHTML + * @return {string} with HTML entities "escaped", similar to PHP's htmlspecialchars() + */ + static escapeHTML(sHTML) + { + return sHTML.replace(/[&<>"']/g, function(m) + { + return Str.aHTMLEscapeMap[m]; + }); + } + + /** + * replace(sSearch, sReplace, s) + * + * The JavaScript replace() function ALWAYS interprets "$" specially in replacement strings, even when + * the search string is NOT a RegExp; specifically: + * + * $$ Inserts a "$" + * $& Inserts the matched substring + * $` Inserts the portion of the string that precedes the matched substring + * $' Inserts the portion of the string that follows the matched substring + * $n Where n is a positive integer less than 100, inserts the nth parenthesized sub-match string, + * provided the first argument was a RegExp object + * + * So, if a replacement string containing dollar signs passes through a series of replace() calls, untold + * problems could result. Hence, this function, which simply uses the replacement string as-is. + * + * Similar to the JavaScript replace() method (when sSearch is a string), this replaces only ONE occurrence + * (ie, the FIRST occurrence); it might be nice to add options to replace the LAST occurrence and/or ALL + * occurrences, but we'll revisit that later. + * + * @param {string} sSearch + * @param {string} sReplace + * @param {string} s + * @return {string} + */ + static replace(sSearch, sReplace, s) + { + var i = s.indexOf(sSearch); + if (i >= 0) { + s = s.substr(0, i) + sReplace + s.substr(i + sSearch.length); + } + return s; + } + + /** + * replaceAll(sSearch, sReplace, s) + * + * @param {string} sSearch + * @param {string} sReplace + * @param {string} s + * @return {string} + */ + static replaceAll(sSearch, sReplace, s) + { + var a = {}; + a[sSearch] = sReplace; + return Str.replaceArray(a, s); + } + + /** + * replaceArray(a, s) + * + * @param {Object} a + * @param {string} s + * @return {string} + */ + static replaceArray(a, s) + { + var sMatch = ""; + for (var k in a) { + /* + * As noted in: + * + * http://www.regexguru.com/2008/04/escape-characters-only-when-necessary/ + * + * inside character classes, only backslash, caret, hyphen and the closing bracket need to be + * escaped. And in fact, if you ensure that the closing bracket is first, the caret is not first, + * and the hyphen is last, you can avoid escaping those as well. + */ + k = k.replace(/([\\[\]*{}().+?])/g, "\\$1"); + sMatch += (sMatch? '|' : '') + k; + } + return s.replace(new RegExp('(' + sMatch + ')', "g"), function(m) + { + return a[m]; + }); + } + + /** + * pad(s, cch, fPadLeft) + * + * NOTE: the maximum amount of padding currently supported is 40 spaces. + * + * @param {string} s is a string + * @param {number} cch is desired length + * @param {boolean} [fPadLeft] (default is padding on the right) + * @return {string} the original string (s) with spaces padding it to the specified length + */ + static pad(s, cch, fPadLeft) + { + var sPadding = " "; + return fPadLeft? (sPadding + s).slice(-cch) : (s + sPadding).slice(0, cch); + } + + /** + * sprintf(format, ...) + * + * Copied from the CCjs project (/ccjs/lib/stdio.js) and extended. Far from complete let alone sprintf-compatible, + * but it's a start. + * + * @param {string} format + * @param {...} args + * @return {string} + */ + static sprintf(format, ...args) + { + var parts = format.split(/%([-+ 0#]?)([0-9]*)(\.?)([0-9]*)([hlL]?)([A-Za-z%])/); + var buffer = ""; + var partIndex = 0; + for (var i = 0; i < args.length; i++) { + + var arg = args[i], d, s; + buffer += parts[partIndex++]; + var flags = parts[partIndex]; + var minimum = +parts[partIndex+1] || 0; + var precision = +parts[partIndex+3] || 0; + var conversion = parts[partIndex+5]; + + switch(conversion) { + case 'd': + case 'f': + d = Math.trunc(arg); + s = d + ""; + if (precision) { + minimum -= (precision + 1); + } + if (s.length < minimum) { + if (flags == '0') { + if (d < 0) minimum--; + s = ("0000000000" + Math.abs(d)).slice(-minimum); + if (d < 0) s = '-' + s; + } else { + s = (" " + s).slice(-minimum); + } + } + if (precision) { + d = Math.trunc((arg - Math.trunc(arg)) * Math.pow(10, precision)); + s += '.' + ("0000000000" + Math.abs(d)).slice(-precision); + } + buffer += s; + break; + case 's': + buffer += arg; + break; + default: + /* + * The supported ANSI C set of conversions: "dioxXucsfeEgGpn%" + */ + buffer += "(unrecognized printf conversion %" + conversion + ")"; + break; + } + + partIndex += 6; + } + buffer += parts[partIndex]; + return buffer; + } + + /** + * stripLeadingZeros(s, fPad) + * + * @param {string} s + * @param {boolean} [fPad] + * @return {string} + */ + static stripLeadingZeros(s, fPad) + { + var cch = s.length; + s = s.replace(/^0+([0-9A-F]+)$/i, "$1"); + if (fPad) s = Str.pad(s, cch, true); + return s; + } + + /** + * trim(s) + * + * @param {string} s + * @return {string} + */ + static trim(s) + { + if (String.prototype.trim) { + return s.trim(); + } + return s.replace(/^\s+|\s+$/g, ""); + } + + /** + * toASCIICode(b) + * + * @param {number} b + * @return {string} + */ + static toASCIICode(b) + { + var s; + if (b != Str.ASCII.CR && b != Str.ASCII.LF) { + s = Str.aASCIICodes[b]; + } + if (s) { + s = '<' + s + '>'; + } else { + s = String.fromCharCode(b); + } + return s; + } +} + +Str.aHTMLEscapeMap = { + '&': '&', + '<': '<', + '>': '>', + '"': '"', + "'": ''' +}; + +/* + * Future home of a general-purpose ASCII table. TODO: Flesh it out. + */ +Str.ASCII = { + LF: 0x0A, + CR: 0x0D +}; + +/* + * Table for converting "unprintable" ASCII codes into mnemonics, to more clearly see what's being printed. + */ +Str.aASCIICodes = { + 0x00: "NUL", + 0x01: "SOH", // (CTRL_A) Start of Heading + 0x02: "STX", // (CTRL_B) Start of Text + 0x03: "ETX", // (CTRL_C) End of Text + 0x04: "EOT", // (CTRL_D) End of Transmission + 0x05: "ENQ", // (CTRL_E) Enquiry + 0x06: "ACK", // (CTRL_F) Acknowledge + 0x07: "BEL", // (CTRL_G) Bell + 0x08: "BS", // (CTRL_H) Backspace + 0x09: "TAB", // (CTRL_I) Horizontal Tab + 0x0A: "LF", // (CTRL_J) Line Feed (New Line) + 0x0B: "VT", // (CTRL_K) Vertical Tab + 0x0C: "FF", // (CTRL_L) Form Feed (New Page) + 0x0D: "CR", // (CTRL_M) Carriage Return + 0x0E: "SO", // (CTRL_N) Shift Out + 0x0F: "SI", // (CTRL_O) Shift In + 0x10: "DLE", // (CTRL_P) Data Link Escape + 0x11: "XON", // (CTRL_Q) Device Control 1 (aka DC1) + 0x12: "DC2", // (CTRL_R) Device Control 2 + 0x13: "XOFF", // (CTRL_S) Device Control 3 (aka DC3) + 0x14: "DC4", // (CTRL_T) Device Control 4 + 0x15: "NAK", // (CTRL_U) Negative Acknowledge + 0x16: "SYN", // (CTRL_V) Synchronous Idle + 0x17: "ETB", // (CTRL_W) End of Transmission Block + 0x18: "CAN", // (CTRL_X) Cancel + 0x19: "EM", // (CTRL_Y) End of Medium + 0x1A: "SUB", // (CTRL_Z) Substitute + 0x1B: "ESC", // Escape + 0x1C: "FS", // File Separator + 0x1D: "GS", // Group Separator + 0x1E: "RS", // Record Separator + 0x1F: "US" // Unit Separator +}; + +Str.TYPES = { + NULL: 0, + BYTE: 1, + WORD: 2, + DWORD: 3, + NUMBER: 4, + STRING: 5, + BOOLEAN: 6, + OBJECT: 7, + ARRAY: 8 +}; + + + +/** + * @copyright http://pcjs.org/modules/shared/lib/usrlib.js (C) Jeff Parsons 2012-2017 + */ + +/** + * @typedef {{ + * mask: number, + * shift: number + * }} + */ +var BitField; + +/** + * @typedef {Object.} + */ +var BitFields; + +class Usr { + /** + * binarySearch(a, v, fnCompare) + * + * @param {Array} a is an array + * @param {number|string|Array|Object} v + * @param {function((number|string|Array|Object), (number|string|Array|Object))} [fnCompare] + * @return {number} the index of matching entry if non-negative, otherwise the index of the insertion point + */ + static binarySearch(a, v, fnCompare) + { + var left = 0; + var right = a.length; + var found = 0; + if (fnCompare === undefined) { + fnCompare = function(a, b) + { + return a > b ? 1 : a < b ? -1 : 0; + }; + } + while (left < right) { + var middle = (left + right) >> 1; + var compareResult; + compareResult = fnCompare(v, a[middle]); + if (compareResult > 0) { + left = middle + 1; + } else { + right = middle; + found = !compareResult; + } + } + return found ? left : ~left; + } + + /** + * binaryInsert(a, v, fnCompare) + * + * If element v already exists in array a, the array is unchanged (we don't allow duplicates); otherwise, the + * element is inserted into the array at the appropriate index. + * + * @param {Array} a is an array + * @param {number|string|Array|Object} v is the value to insert + * @param {function((number|string|Array|Object), (number|string|Array|Object))} [fnCompare] + */ + static binaryInsert(a, v, fnCompare) + { + var index = Usr.binarySearch(a, v, fnCompare); + if (index < 0) { + a.splice(-(index + 1), 0, v); + } + } + + /** + * getTimestamp() + * + * @return {string} timestamp containing the current date and time ("yyyy-mm-dd hh:mm:ss") + */ + static getTimestamp() + { + return Usr.formatDate("Y-m-d H:i:s"); + } + + /** + * getMonthDays(nMonth, nYear) + * + * Note that if we're being called on behalf of the RTC, its year is always truncated to two digits (mod 100), + * so we have no idea what century the year 0 might refer to. When using the normal leap-year formula, 0 fails + * the mod 100 test but passes the mod 400 test, so as far as the RTC is concerned, every century year is a leap + * year. Since we're most likely dealing with the year 2000, that's fine, since 2000 was also a leap year. + * + * TODO: There IS a separate CMOS byte that's supposed to be set to CMOS_ADDR.CENTURY_DATE; it's always BCD, + * so theoretically it will contain values like 0x19 or 0x20 (for the 20th and 21st centuries, respectively), and + * we could add that as another parameter to this function, to improve the accuracy, but that would go beyond what + * a real RTC actually does. + * + * @param {number} nMonth (1-12) + * @param {number} nYear (normally a 4-digit year, but it may also be mod 100) + * @return {number} the maximum (1-based) day allowed for the specified month and year + */ + static getMonthDays(nMonth, nYear) + { + var nDays = Usr.aMonthDays[nMonth - 1]; + if (nDays == 28) { + if ((nYear % 4) === 0 && ((nYear % 100) || (nYear % 400) === 0)) { + nDays++; + } + } + return nDays; + } + + /** + * formatDate(sFormat, date) + * + * @param {string} sFormat (eg, "F j, Y", "Y-m-d H:i:s") + * @param {Date} [date] (default is the current time) + * @return {string} + * + * Supported identifiers in sFormat include: + * + * a: lowercase ante meridiem and post meridiem (am or pm) + * d: day of the month, 2 digits with leading zeros (01,02,...,31) + * D: 3-letter day of the week ("Sun","Mon",...,"Sat") + * F: month ("January","February",...,"December") + * g: hour in 12-hour format, without leading zeros (1,2,...,12) + * h: hour in 24-hour format, without leading zeros (0,1,...,23) + * H: hour in 24-hour format, with leading zeros (00,01,...,23) + * i: minutes, with leading zeros (00,01,...,59) + * j: day of the month, without leading zeros (1,2,...,31) + * l: day of the week ("Sunday","Monday",...,"Saturday") + * m: month, with leading zeros (01,02,...,12) + * M: 3-letter month ("Jan","Feb",...,"Dec") + * n: month, without leading zeros (1,2,...,12) + * s: seconds, with leading zeros (00,01,...,59) + * y: 2-digit year (eg, 14) + * Y: 4-digit year (eg, 2014) + * + * For more inspiration, see: http://php.net/manual/en/function.date.php (of which we support ONLY a subset). + */ + static formatDate(sFormat, date) + { + var sDate = ""; + if (!date) date = new Date(); + var iHour = date.getHours(); + var iDay = date.getDate(); + var iMonth = date.getMonth() + 1; + for (var i = 0; i < sFormat.length; i++) { + var ch; + switch ((ch = sFormat.charAt(i))) { + case 'a': + sDate += (iHour < 12 ? "am" : "pm"); + break; + case 'd': + sDate += ('0' + iDay).slice(-2); + break; + case 'D': + sDate += Usr.asDays[date.getDay()].substr(0, 3); + break; + case 'F': + sDate += Usr.asMonths[iMonth - 1]; + break; + case 'g': + sDate += (!iHour ? 12 : (iHour > 12 ? iHour - 12 : iHour)); + break; + case 'h': + sDate += iHour; + break; + case 'H': + sDate += ('0' + iHour).slice(-2); + break; + case 'i': + sDate += ('0' + date.getMinutes()).slice(-2); + break; + case 'j': + sDate += iDay; + break; + case 'l': + sDate += Usr.asDays[date.getDay()]; + break; + case 'm': + sDate += ('0' + iMonth).slice(-2); + break; + case 'M': + sDate += Usr.asMonths[iMonth - 1].substr(0, 3); + break; + case 'n': + sDate += iMonth; + break; + case 's': + sDate += ('0' + date.getSeconds()).slice(-2); + break; + case 'y': + sDate += ("" + date.getFullYear()).slice(-2); + break; + case 'Y': + sDate += date.getFullYear(); + break; + default: + sDate += ch; + break; + } + } + return sDate; + } + + /** + * defineBitFields(bfs) + * + * Prepares a bit field definition for use with getBitField() and setBitField(); eg: + * + * var bfs = Usr.defineBitFields({num:20, count:8, btmod:1, type:3}); + * + * The above defines a set of bit fields containing four fields: num (bits 0-19), count (bits 20-27), btmod (bit 28), and type (bits 29-31). + * + * Usr.setBitField(bfs.num, n, 1); + * + * The above set bit field "bfs.num" in numeric variable "n" to the value 1. + * + * @param {Object} bfs + * @return {BitFields} + */ + static defineBitFields(bfs) + { + var bit = 0; + for (var f in bfs) { + var width = bfs[f]; + var mask = ((1 << width) - 1) << bit; + bfs[f] = {mask: mask, shift: bit}; + bit += width; + } + return bfs; + } + + /** + * initBitFields(bfs, ...) + * + * @param {BitFields} bfs + * @param {...number} var_args + * @return {number} a value containing all supplied bit fields + */ + static initBitFields(bfs, var_args) + { + var v = 0, i = 1; + for (var f in bfs) { + if (i >= arguments.length) break; + v = Usr.setBitField(bfs[f], v, arguments[i++]); + } + return v; + } + + /** + * getBitField(bf, v) + * + * @param {BitField} bf + * @param {number} v is a value containing bit fields + * @return {number} the value of the bit field in v defined by bf + */ + static getBitField(bf, v) + { + return (v & bf.mask) >> bf.shift; + } + + /** + * setBitField(bf, v, n) + * + * @param {BitField} bf + * @param {number} v is a value containing bit fields + * @param {number} n is a value to store in v in the bit field defined by bf + * @return {number} updated v + */ + static setBitField(bf, v, n) + { + return (v & ~bf.mask) | ((n << bf.shift) & bf.mask); + } + + /** + * indexOf(a, t, i) + * + * Use this instead of Array.prototype.indexOf() if you can't be sure the browser supports it. + * + * @param {Array} a + * @param {*} t + * @param {number} [i] + * @returns {number} + */ + static indexOf(a, t, i) + { + if (Array.prototype.indexOf) { + return a.indexOf(t, i); + } + i = i || 0; + if (i < 0) i += a.length; + if (i < 0) i = 0; + for (var n = a.length; i < n; i++) { + if (i in a && a[i] === t) return i; + } + return -1; + } +} + +Usr.asDays = ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"]; +Usr.asMonths = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"]; +Usr.aMonthDays = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31]; + +/** + * getTime() + * + * @return {number} the current time, in milliseconds + */ +Usr.getTime = Date.now || function() { return +new Date(); }; + + + +/** + * @copyright http://pcjs.org/modules/shared/lib/weblib.js (C) Jeff Parsons 2012-2017 + */ + + +/* + * According to http://www.w3schools.com/jsref/jsref_obj_global.asp, these are the *global* properties + * and functions of JavaScript-in-the-Browser: + * + * Property Description + * --- + * Infinity A numeric value that represents positive/negative infinity + * NaN "Not-a-Number" value + * undefined Indicates that a variable has not been assigned a value + * + * Function Description + * --- + * decodeURI() Decodes a URI + * decodeURIComponent() Decodes a URI component + * encodeURI() Encodes a URI + * encodeURIComponent() Encodes a URI component + * escape() Deprecated in version 1.5. Use encodeURI() or encodeURIComponent() instead + * eval() Evaluates a string and executes it as if it was script code + * isFinite() Determines whether a value is a finite, legal number + * isNaN() Determines whether a value is an illegal number + * Number() Converts an object's value to a number + * parseFloat() Parses a string and returns a floating point number + * parseInt() Parses a string and returns an integer + * String() Converts an object's value to a string + * unescape() Deprecated in version 1.5. Use decodeURI() or decodeURIComponent() instead + * + * And according to http://www.w3schools.com/jsref/obj_window.asp, these are the properties and functions + * of the *window* object. + * + * Property Description + * --- + * closed Returns a Boolean value indicating whether a window has been closed or not + * defaultStatus Sets or returns the default text in the statusbar of a window + * document Returns the Document object for the window (See Document object) + * frames Returns an array of all the frames (including iframes) in the current window + * history Returns the History object for the window (See History object) + * innerHeight Returns the inner height of a window's content area + * innerWidth Returns the inner width of a window's content area + * length Returns the number of frames (including iframes) in a window + * location Returns the Location object for the window (See Location object) + * name Sets or returns the name of a window + * navigator Returns the Navigator object for the window (See Navigator object) + * opener Returns a reference to the window that created the window + * outerHeight Returns the outer height of a window, including toolbars/scrollbars + * outerWidth Returns the outer width of a window, including toolbars/scrollbars + * pageXOffset Returns the pixels the current document has been scrolled (horizontally) from the upper left corner of the window + * pageYOffset Returns the pixels the current document has been scrolled (vertically) from the upper left corner of the window + * parent Returns the parent window of the current window + * screen Returns the Screen object for the window (See Screen object) + * screenLeft Returns the x coordinate of the window relative to the screen + * screenTop Returns the y coordinate of the window relative to the screen + * screenX Returns the x coordinate of the window relative to the screen + * screenY Returns the y coordinate of the window relative to the screen + * self Returns the current window + * status Sets or returns the text in the statusbar of a window + * top Returns the topmost browser window + * + * Method Description + * --- + * alert() Displays an alert box with a message and an OK button + * atob() Decodes a base-64 encoded string + * blur() Removes focus from the current window + * btoa() Encodes a string in base-64 + * clearInterval() Clears a timer set with setInterval() + * clearTimeout() Clears a timer set with setTimeout() + * close() Closes the current window + * confirm() Displays a dialog box with a message and an OK and a Cancel button + * createPopup() Creates a pop-up window + * focus() Sets focus to the current window + * moveBy() Moves a window relative to its current position + * moveTo() Moves a window to the specified position + * open() Opens a new browser window + * print() Prints the content of the current window + * prompt() Displays a dialog box that prompts the visitor for input + * resizeBy() Resizes the window by the specified pixels + * resizeTo() Resizes the window to the specified width and height + * scroll() This method has been replaced by the scrollTo() method. + * scrollBy() Scrolls the content by the specified number of pixels + * scrollTo() Scrolls the content to the specified coordinates + * setInterval() Calls a function or evaluates an expression at specified intervals (in milliseconds) + * setTimeout() Calls a function or evaluates an expression after a specified number of milliseconds + * stop() Stops the window from loading + */ + +class Web { + /** + * log(s, type) + * + * For diagnostic output only. DEBUG must be true (or "--debug" specified via the command-line) + * for Component.log() to display anything. + * + * @param {string} [s] is the message text + * @param {string} [type] is the message type + */ + static log(s, type) + { + Component.log(s, type); + } + + /** + * notice(s, fPrintOnly, id) + * + * @param {string} s is the message text + * @param {boolean} [fPrintOnly] + * @param {string} [id] is the caller's ID, if any + */ + static notice(s, fPrintOnly, id) + { + Component.notice(s, fPrintOnly, id); + } + + /** + * getResource(sURL, dataPost, fAsync, done, progress) + * + * Request the specified resource (sURL), and once the request is complete, notify done(). + * + * If fAsync is true, a done() callback should ALWAYS be supplied; otherwise, you'll have no + * idea when the request is complete or what the response was. done() is passed three parameters: + * + * done(sURL, sResource, nErrorCode) + * + * If nErrorCode is zero, sResource should contain the requested data; otherwise, an error occurred. + * + * If dataPost is set to a string, that string can be used to control the response format; + * by default, the response format is plain text, but you can specify "bytes" to request arbitrary + * binary data, which should come back as a string of bytes. + * + * TODO: The "bytes" option works by calling overrideMimeType(), which was never a best practice. + * Instead, we should implement supported response types ("text" and "arraybuffer", at a minimum) + * by setting xmlHTTP.responseType to one of those values before calling xmlHTTP.send(). + * + * @param {string} sURL + * @param {string|Object|null} [dataPost] for a POST request (default is a GET request) + * @param {boolean} [fAsync] is true for an asynchronous request + * @param {function(string,string,number)} [done] + * @param {function(number)} [progress] + * @return {Array|null} Array containing [sResource, nErrorCode], or null if no response yet + */ + static getResource(sURL, dataPost, fAsync = false, done, progress) + { + var nErrorCode = 0, sResource = null, response = null; + + if (typeof resources == 'object' && (sResource = resources[sURL])) { + if (done) done(sURL, sResource, nErrorCode); + return [sResource, nErrorCode]; + } + else if (fAsync && typeof resources == 'function') { + resources(sURL, function(sResource, nErrorCode) + { + if (done) done(sURL, sResource, nErrorCode); + }); + return response; + } + + if (DEBUG) { + /* + * The larger resources we put on archive.pcjs.org should also be available locally. + * + * NOTE: "http://archive.pcjs.org" is now "https://s3-us-west-2.amazonaws.com/archive.pcjs.org" + */ + sURL = sURL.replace(/^(http:\/\/archive\.pcjs\.org|https:\/\/s3-us-west-2\.amazonaws\.com\/archive\.pcjs\.org)(\/.*)\/([^\/]*)$/, "$2/archive/$3"); + } + + + var xmlHTTP = (window.XMLHttpRequest? new window.XMLHttpRequest() : new window.ActiveXObject("Microsoft.XMLHTTP")); + if (fAsync) { + xmlHTTP.onreadystatechange = function() + { + if (xmlHTTP.readyState !== 4) { + if (progress) progress(1); + return; + } + /* + * The following line was recommended for WebKit, as a work-around to prevent the handler firing multiple + * times when debugging. Unfortunately, that's not the only XMLHttpRequest problem that occurs when + * debugging, so I think the WebKit problem is deeper than that. When we have multiple XMLHttpRequests + * pending, any debugging activity means most of them simply get dropped on floor, so what may actually be + * happening are mis-notifications rather than redundant notifications. + * + * xmlHTTP.onreadystatechange = undefined; + */ + sResource = xmlHTTP.responseText; + /* + * The normal "success" case is an HTTP status code of 200, but when testing with files loaded + * from the local file system (ie, when using the "file:" protocol), we have to be a bit more "flexible". + */ + if (xmlHTTP.status == 200 || !xmlHTTP.status && sResource.length && Web.getHostProtocol() == "file:") { + if (MAXDEBUG) Web.log("xmlHTTP.onreadystatechange(" + sURL + "): returned " + sResource.length + " bytes"); + } + else { + nErrorCode = xmlHTTP.status || -1; + Web.log("xmlHTTP.onreadystatechange(" + sURL + "): error code " + nErrorCode); + } + if (progress) progress(2); + if (done) done(sURL, sResource, nErrorCode); + }; + } + + if (progress) progress(0); + + if (dataPost && typeof dataPost == "object") { + var sDataPost = ""; + for (var p in dataPost) { + if (!dataPost.hasOwnProperty(p)) continue; + if (sDataPost) sDataPost += "&"; + sDataPost += p + '=' + encodeURIComponent(dataPost[p]); + } + sDataPost = sDataPost.replace(/%20/g, '+'); + if (MAXDEBUG) Web.log("Web.getResource(POST " + sURL + "): " + sDataPost.length + " bytes"); + xmlHTTP.open("POST", sURL, fAsync); // ensure that fAsync is a valid boolean (Internet Explorer xmlHTTP functions insist on it) + xmlHTTP.setRequestHeader("Content-type", "application/x-www-form-urlencoded"); + xmlHTTP.send(sDataPost); + } else { + if (MAXDEBUG) Web.log("Web.getResource(GET " + sURL + ")"); + xmlHTTP.open("GET", sURL, fAsync); // ensure that fAsync is a valid boolean (Internet Explorer xmlHTTP functions insist on it) + if (dataPost == "bytes") { + xmlHTTP.overrideMimeType("text/plain; charset=x-user-defined"); + } + xmlHTTP.send(); + } + + if (!fAsync) { + sResource = xmlHTTP.responseText; + if (xmlHTTP.status == 200) { + if (MAXDEBUG) Web.log("Web.getResource(" + sURL + "): returned " + sResource.length + " bytes"); + } else { + nErrorCode = xmlHTTP.status || -1; + Web.log("Web.getResource(" + sURL + "): error code " + nErrorCode); + } + if (done) done(sURL, sResource, nErrorCode); + response = [sResource, nErrorCode]; + } + return response; + } + + /** + * parseMemoryResource(sURL, sData) + * + * This converts a variety of JSON-style data streams into an Object with the following properties: + * + * aBytes + * aSymbols + * addrLoad + * addrExec + * + * If the source data contains a 'bytes' array, it's passed through to 'aBytes'; alternatively, if + * it contains a 'words' array, the values are converted from 16-bit to 8-bit and stored in 'aBytes', + * and if it contains a 'longs' array, the values are converted from 32-bit longs into bytes and + * stored in 'aBytes'. + * + * Alternatively, if the source data contains a 'data' array, we simply pass that through to the output + * object as: + * + * aData + * + * @param {string} sURL + * @param {string} sData + * @return {Object|null} (resource) + */ + static parseMemoryResource(sURL, sData) + { + var i; + var resource = { + aBytes: null, + aSymbols: null, + addrLoad: null, + addrExec: null + }; + + if (sData.charAt(0) == "[" || sData.charAt(0) == "{") { + try { + var a, ib, data; + + if (sData.substr(0, 1) == "<") { // if the "data" begins with a "<"... + /* + * Early server configs reported an error (via the nErrorCode parameter) if a tape URL was invalid, + * but more recent server configs now display a somewhat friendlier HTML error page. The downside, + * however, is that the original error has been buried, and we've received "data" that isn't actually + * tape data. So if the data we've received appears to be "HTML-like", we treat it as an error message. + */ + throw new Error(sData); + } + + /* + * TODO: IE9 is rather unfriendly and restrictive with regard to how much data it's willing to + * eval(). In particular, the 10Mb disk image we use for the Windows 1.01 demo config fails in + * IE9 with an "Out of memory" exception. One work-around would be to chop the data into chunks + * (perhaps one track per chunk, using regular expressions) and then manually re-assemble it. + * + * However, it turns out that using JSON.parse(sDiskData) instead of eval("(" + sDiskData + ")") + * is a much easier fix. The only drawback is that we must first quote any unquoted property names + * and remove any comments, because while eval() was cool with them, JSON.parse() is more particular; + * the following RegExp replacements take care of those requirements. + * + * The use of hex values is something else that eval() was OK with, but JSON.parse() is not, and + * while I've stopped using hex values in DumpAPI responses (at least when "format=json" is specified), + * I can't guarantee they won't show up in "legacy" images, and there's no simple RegExp replacement + * for transforming hex values into decimal values, so I cop out and fall back to eval() if I detect + * any hex prefixes ("0x") in the sequence. Ditto for error messages, which appear like so: + * + * ["unrecognized disk path: test.img"] + */ + if (sData.indexOf("0x") < 0 && sData.indexOf("0o") < 0 && sData.substr(0, 2) != '["') { + data = JSON.parse(sData.replace(/([a-z]+):/gm, '"$1":').replace(/\/\/[^\n]*/gm, "")); + } else { + data = eval("(" + sData + ")"); + } + + resource.addrLoad = data['load']; + resource.addrExec = data['exec']; + + if (a = data['bytes']) { + resource.aBytes = a; + } + else if (a = data['words']) { + /* + * Convert all words into bytes + */ + resource.aBytes = new Array(a.length * 2); + for (i = 0, ib = 0; i < a.length; i++) { + resource.aBytes[ib++] = a[i] & 0xff; + resource.aBytes[ib++] = (a[i] >> 8) & 0xff; + + } + } + else if (a = data['longs']) { + /* + * Convert all dwords (longs) into bytes + */ + resource.aBytes = new Array(a.length * 4); + for (i = 0, ib = 0; i < a.length; i++) { + resource.aBytes[ib++] = a[i] & 0xff; + resource.aBytes[ib++] = (a[i] >> 8) & 0xff; + resource.aBytes[ib++] = (a[i] >> 16) & 0xff; + resource.aBytes[ib++] = (a[i] >> 24) & 0xff; + } + } + else if (a = data['data']) { + resource.aData = a; + } + else { + resource.aBytes = data; + } + + if (resource.aBytes) { + if (!resource.aBytes.length) { + Component.error("Empty resource: " + sURL); + resource = null; + } + else if (resource.aBytes.length == 1) { + Component.error(resource.aBytes[0]); + resource = null; + } + } + resource.aSymbols = data['symbols']; + + } catch (e) { + Component.error("Resource data error (" + sURL + "): " + e.message); + resource = null; + } + } + else { + /* + * Parse the data manually; we assume it's a series of hex byte-values separated by whitespace. + */ + var ab = []; + var sHexData = sData.replace(/\n/gm, " ").replace(/ +$/, ""); + var asHexData = sHexData.split(" "); + for (i = 0; i < asHexData.length; i++) { + var n = parseInt(asHexData[i], 16); + if (isNaN(n)) { + Component.error("Resource data error (" + sURL + "): invalid hex byte (" + asHexData[i] + ")"); + break; + } + ab.push(n & 0xff); + } + if (i == asHexData.length) resource.aBytes = ab; + } + return resource; + } + + /** + * sendReport(sApp, sVer, sURL, sUser, sType, sReport, sHostName) + * + * Send a report (eg, bug report) to the server. + * + * @param {string} sApp (eg, "PCjs") + * @param {string} sVer (eg, "1.02") + * @param {string} sURL (eg, "/devices/pc/machine/5150/mda/64kb/machine.xml") + * @param {string} sUser (ie, the user key, if any) + * @param {string} sType (eg, "bug"); one of ReportAPI.TYPE.* + * @param {string} sReport (eg, unparsed state data) + * @param {string} [sHostName] (default is http://SITEHOST) + */ + static sendReport(sApp, sVer, sURL, sUser, sType, sReport, sHostName) + { + var dataPost = {}; + dataPost[ReportAPI.QUERY.APP] = sApp; + dataPost[ReportAPI.QUERY.VER] = sVer; + dataPost[ReportAPI.QUERY.URL] = sURL; + dataPost[ReportAPI.QUERY.USER] = sUser; + dataPost[ReportAPI.QUERY.TYPE] = sType; + dataPost[ReportAPI.QUERY.DATA] = sReport; + var sReportURL = (sHostName? sHostName : "http://" + SITEHOST) + ReportAPI.ENDPOINT; + Web.getResource(sReportURL, dataPost, true); + } + + /** + * getHost() + * + * @return {string} + */ + static getHost() + { + return ("http://" + (window? window.location.host : SITEHOST)); + } + + /** + * getHostURL() + * + * @return {string|null} + */ + static getHostURL() + { + return (window? window.location.href : null); + } + + /** + * getHostProtocol() + * + * @return {string} + */ + static getHostProtocol() + { + return (window? window.location.protocol : "file:"); + } + + /** + * getUserAgent() + * + * @return {string} + */ + static getUserAgent() + { + return (window? window.navigator.userAgent : ""); + } + + /** + * hasLocalStorage + * + * true if localStorage support exists, is enabled, and works; false otherwise + * + * @return {boolean} + */ + static hasLocalStorage() + { + if (Web.fLocalStorage == null) { + var f = false; + if (window) { + try { + window.localStorage.setItem(Web.sLocalStorageTest, Web.sLocalStorageTest); + f = (window.localStorage.getItem(Web.sLocalStorageTest) == Web.sLocalStorageTest); + window.localStorage.removeItem(Web.sLocalStorageTest); + } catch (e) { + Web.logLocalStorageError(e); + f = false; + } + } + Web.fLocalStorage = f; + } + return Web.fLocalStorage; + } + + /** + * logLocalStorageError(e) + * + * @param {Error} e is an exception + */ + static logLocalStorageError(e) + { + Web.log(e.message, "localStorage error"); + } + + /** + * getLocalStorageItem(sKey) + * + * Returns the requested key value, or null if the key does not exist, or undefined if localStorage is not available + * + * @param {string} sKey + * @return {string|null|undefined} sValue + */ + static getLocalStorageItem(sKey) + { + var sValue; + if (window) { + try { + sValue = window.localStorage.getItem(sKey); + } catch (e) { + Web.logLocalStorageError(e); + } + } + return sValue; + } + + /** + * setLocalStorageItem(sKey, sValue) + * + * @param {string} sKey + * @param {string} sValue + * @return {boolean} true if localStorage is available, false if not + */ + static setLocalStorageItem(sKey, sValue) + { + try { + window.localStorage.setItem(sKey, sValue); + return true; + } catch (e) { + Web.logLocalStorageError(e); + } + return false; + } + + /** + * removeLocalStorageItem(sKey) + * + * @param {string} sKey + */ + static removeLocalStorageItem(sKey) + { + try { + window.localStorage.removeItem(sKey); + } catch (e) { + Web.logLocalStorageError(e); + } + } + + /** + * getLocalStorageKeys() + * + * @return {Array} + */ + static getLocalStorageKeys() + { + var a = []; + try { + for (var i = 0, c = window.localStorage.length; i < c; i++) { + a.push(window.localStorage.key(i)); + } + } catch (e) { + Web.logLocalStorageError(e); + } + return a; + } + + /** + * reloadPage() + */ + static reloadPage() + { + if (window) window.location.reload(); + } + + /** + * isUserAgent(s) + * + * Check the browser's user-agent string for the given substring; "iOS" and "MSIE" are special values you can + * use that will match any iOS or MSIE browser, respectively (even IE11, in the case of "MSIE"). + * + * 2013-11-06: In a questionable move, MSFT changed the user-agent reported by IE11 on Windows 8.1, eliminating + * the "MSIE" string (which MSDN calls a "version token"; see http://msdn.microsoft.com/library/ms537503.aspx); + * they say "public websites should rely on feature detection, rather than browser detection, in order to design + * their sites for browsers that don't support the features used by the website." So, in IE11, we get a user-agent + * that tries to fool apps into thinking the browser is more like WebKit or Gecko: + * + * Mozilla/5.0 (Windows NT 6.3; Trident/7.0; rv:11.0) like Gecko + * + * That's a nice idea, but in the meantime, they hosed the XSL transform code in embed.js, which contained + * some very critical browser-specific code; turning on IE's "Compatibility Mode" didn't help either, because + * that's a sledgehammer solution which restores the old user-agent string but also disables other features like + * HTML5 canvas support. As an interim solution, I'm treating any "MSIE" check as a check for either "MSIE" or + * "Trident". + * + * UPDATE: I've since found ways to make the code in embed.js more browser-agnostic, so for now, there's isn't + * any code that cares about "MSIE", but I've left the change in place, because I wouldn't be surprised if I'll + * need more IE-specific code in the future, perhaps for things like copy/paste functionality, or mouse capture. + * + * @param {string} s is a substring to search for in the user-agent; as noted above, "iOS" and "MSIE" are special values + * @return {boolean} is true if the string was found, false if not + */ + static isUserAgent(s) + { + if (window) { + var userAgent = Web.getUserAgent(); + /* + * Here's one case where we have to be careful with Component, because when isUserAgent() is called by + * the init code below, component.js hasn't been loaded yet. The simple solution for now is to remove the call. + * + * Web.log("agent: " + userAgent); + * + * And yes, it would be pointless to use the conditional (?) operator below, if not for the Google Closure + * Compiler (v20130823) failing to detect the entire expression as a boolean. + */ + return s == "iOS" && !!userAgent.match(/(iPod|iPhone|iPad)/) && !!userAgent.match(/AppleWebKit/) || s == "MSIE" && !!userAgent.match(/(MSIE|Trident)/) || (userAgent.indexOf(s) >= 0); + } + return false; + } + + /** + * isMobile() + * + * Check the browser's user-agent string for the substring "Mobi", as per Mozilla recommendation: + * + * https://developer.mozilla.org/en-US/docs/Browser_detection_using_the_user_agent + * + * @return {boolean} is true if the browser appears to be a mobile (ie, non-desktop) web browser, false if not + */ + static isMobile() + { + return Web.isUserAgent("Mobi"); + } + + /** + * findProperty(obj, sProp, sSuffix) + * + * If both sProp and sSuffix are set, then any browser-specific prefixes are inserted between sProp and sSuffix, + * and if a match is found, it is returned without sProp. + * + * For example, if findProperty(document, 'on', 'fullscreenchange') discovers that 'onwebkitfullscreenchange' exists, + * it will return 'webkitfullscreenchange', in preparation for an addEventListener() call. + * + * More commonly, sSuffix is not used, so whatever property is found is returned as-is. + * + * @param {Object|null|undefined} obj + * @param {string} sProp + * @param {string} [sSuffix] + * @return {string|null} + */ + static findProperty(obj, sProp, sSuffix) + { + if (obj) { + for (var i = 0; i < Web.asBrowserPrefixes.length; i++) { + var sName = Web.asBrowserPrefixes[i]; + if (sSuffix) { + sName += sSuffix; + var sEvent = sProp + sName; + if (sEvent in obj) return sName; + } else { + if (!sName) { + sName = sProp[0]; + } else { + sName += sProp[0].toUpperCase(); + } + sName += sProp.substr(1); + if (sName in obj) return sName; + } + } + } + return null; + } + + /** + * getURLParm(sParm) + * + * First looks for sParm exactly as specified, then looks for the lower-case version. + * + * @param {string} sParm + * @return {string|undefined} + */ + static getURLParm(sParm) + { + if (!Web.parmsURL) { + Web.parmsURL = Web.parseURLParms(); + } + return Web.parmsURL[sParm] || Web.parmsURL[sParm.toLowerCase()]; + } + + /** + * parseURLParms(sParms) + * + * @param {string} [sParms] containing the parameter portion of a URL (ie, after the '?') + * @return {Object} containing properties for each parameter found + */ + static parseURLParms(sParms) + { + var aParms = {}; + if (window) { // an alternative to "if (typeof module === 'undefined')" if require("defines") was used + if (!sParms) { + /* + * Note that window.location.href returns the entire URL, whereas window.location.search + * returns only the parameters, if any (starting with the '?', which we skip over with a substr() call). + */ + sParms = window.location.search.substr(1); + } + var match; + var pl = /\+/g; // RegExp for replacing addition symbol with a space + var search = /([^&=]+)=?([^&]*)/g; + var decode = function(s) + { + return decodeURIComponent(s.replace(pl, " ")); + }; + + while ((match = search.exec(sParms))) { + aParms[decode(match[1])] = decode(match[2]); + } + } + return aParms; + } + + /** + * downloadFile(sData, sType, fBase64, sFileName) + * + * @param {string} sData + * @param {string} sType + * @param {boolean} [fBase64] + * @param {string} [sFileName] + */ + static downloadFile(sData, sType, fBase64, sFileName) + { + var link = null, sAlert; + var sURI = "data:application/" + sType + (fBase64? ";base64" : "") + ","; + + if (!Web.isUserAgent("Firefox")) { + sURI += (fBase64? sData : encodeURI(sData)); + } else { + sURI += (fBase64? sData : encodeURIComponent(sData)); + } + if (sFileName) { + link = document.createElement('a'); + if (typeof link.download != 'string') link = null; + } + if (link) { + link.href = sURI; + link.download = sFileName; + document.body.appendChild(link); // Firefox allegedly requires the link to be in the body + link.click(); + document.body.removeChild(link); + sAlert = 'Check your Downloads folder for ' + sFileName + '.'; + } else { + window.open(sURI); + sAlert = 'Check your browser for a new window/tab containing the requested data' + (sFileName? (' (' + sFileName + ')') : '') + '.'; + } + return sAlert; + } + + /** + * onCountRepeat(n, fnRepeat, fnComplete, msDelay) + * + * Call fnRepeat() n times with an msDelay millisecond delay between calls, + * then call fnComplete() when n has been exhausted OR fnRepeat() returns false. + * + * @param {number} n + * @param {function()} fnRepeat + * @param {function()} fnComplete + * @param {number} [msDelay] + */ + static onCountRepeat(n, fnRepeat, fnComplete, msDelay) + { + var fnTimeout = function doCountRepeat() + { + n -= 1; + if (n >= 0) { + if (!fnRepeat()) n = 0; + } + if (n > 0) { + setTimeout(fnTimeout, msDelay || 0); + return; + } + fnComplete(); + }; + fnTimeout(); + } + + /** + * onClickRepeat(e, msDelay, msRepeat, fn) + * + * Repeatedly call fn() with an initial msDelay, and an msRepeat delay thereafter, + * as long as HTML control Object e has an active "down" event and fn() returns true. + * + * @param {Object} e + * @param {number} msDelay + * @param {number} msRepeat + * @param {function(boolean)} fn is passed false on the first call, true on all repeated calls + */ + static onClickRepeat(e, msDelay, msRepeat, fn) + { + var ms = 0, timer = null, fIgnoreMouseEvents = false; + + var fnRepeat = function doClickRepeat() + { + if (fn(ms === msRepeat)) { + timer = setTimeout(fnRepeat, ms); + ms = msRepeat; + } + }; + e.onmousedown = function() + { + // Web.log("onMouseDown()"); + if (!fIgnoreMouseEvents) { + if (!timer) { + ms = msDelay; + fnRepeat(); + } + } + }; + e.ontouchstart = function() + { + // Web.log("onTouchStart()"); + if (!timer) { + ms = msDelay; + fnRepeat(); + } + }; + e.onmouseup = e.onmouseout = function() + { + // Web.log("onMouseUp()/onMouseOut()"); + if (timer) { + clearTimeout(timer); + timer = null; + } + }; + e.ontouchend = e.ontouchcancel = function() + { + // Web.log("onTouchEnd()/onTouchCancel()"); + if (timer) { + clearTimeout(timer); + timer = null; + } + /* + * Devices that generate ontouch* events ALSO generate onmouse* events, + * and generally do so immediately after all the touch events are complete, + * so unless we want double the action, we need to ignore mouse events. + */ + fIgnoreMouseEvents = true; + }; + } + + /** + * onPageEvent(sName, fn) + * + * For 'onload', 'onunload', and 'onpageshow' events, most callers should NOT use this function, but + * instead use Web.onInit(), Web.onShow(), and Web.onExit(), respectively. + * + * The only components that should still use onPageEvent() are THIS component (see the bottom of this file) + * and components that need to capture other events (eg, the 'onresize' event in the Video component). + * + * This function creates a chain of callbacks, allowing multiple JavaScript modules to define handlers + * for the same event, which wouldn't be possible if everyone modified window['onload'], window['onunload'], + * etc, themselves. However, that's less of a concern now, because assuming everyone else is now using + * onInit(), onExit(), etc, then there really IS only one component setting the window callback: this one. + * + * NOTE: It's risky to refer to obscure event handlers with "dot" names, because the Closure Compiler may + * erroneously replace them (eg, window.onpageshow is a good example). + * + * @param {string} sFunc + * @param {function()} fn + */ + static onPageEvent(sFunc, fn) + { + if (window) { + var fnPrev = window[sFunc]; + if (typeof fnPrev !== 'function') { + window[sFunc] = fn; + } else { + /* + * TODO: Determine whether there's any value in receiving/sending the Event object that the + * browser provides when it generates the original event. + */ + window[sFunc] = function onWindowEvent() + { + if (fnPrev) fnPrev(); + fn(); + }; + } + } + }; + + /** + * onInit(fn) + * + * Use this instead of setting window.onload. Allows multiple JavaScript modules to define their own 'onload' event handler. + * + * @param {function()} fn + */ + static onInit(fn) + { + Web.aPageEventHandlers['init'].push(fn); + }; + + /** + * onShow(fn) + * + * @param {function()} fn + * + * Use this instead of setting window.onpageshow. Allows multiple JavaScript modules to define their own 'onpageshow' event handler. + */ + static onShow(fn) + { + Web.aPageEventHandlers['show'].push(fn); + }; + + /** + * onExit(fn) + * + * @param {function()} fn + * + * Use this instead of setting window.onunload. Allows multiple JavaScript modules to define their own 'onunload' event handler. + */ + static onExit(fn) + { + Web.aPageEventHandlers['exit'].push(fn); + }; + + /** + * doPageEvent(afn) + * + * @param {Array.} afn + */ + static doPageEvent(afn) + { + if (Web.fPageEventsEnabled) { + try { + for (var i = 0; i < afn.length; i++) { + afn[i](); + } + } catch (e) { + Web.notice("An unexpected exception occurred:\n\n" + e.message + "\n\nPlease send this information to support@pcjs.org. Thanks."); + } + } + }; + + /** + * enablePageEvents(fEnable) + * + * @param {boolean} fEnable is true to enable page events, false to disable (they're enabled by default) + */ + static enablePageEvents(fEnable) + { + if (!Web.fPageEventsEnabled && fEnable) { + Web.fPageEventsEnabled = true; + if (Web.fPageLoaded) Web.sendPageEvent('init'); + if (Web.fPageShowed) Web.sendPageEvent('show'); + return; + } + Web.fPageEventsEnabled = fEnable; + } + + /** + * sendPageEvent(sEvent) + * + * This allows us to manually trigger page events. + * + * @param {string} sEvent (one of 'init', 'show' or 'exit') + */ + static sendPageEvent(sEvent) + { + if (Web.aPageEventHandlers[sEvent]) { + Web.doPageEvent(Web.aPageEventHandlers[sEvent]); + } + } +} + +Web.parmsURL = null; // initialized on first call to parseURLParms() + +Web.aPageEventHandlers = { + 'init': [], // list of window 'onload' handlers + 'show': [], // list of window 'onpageshow' handlers + 'exit': [] // list of window 'onunload' handlers (although we prefer to use 'onbeforeunload' if possible) +}; + +Web.asBrowserPrefixes = ['', 'moz', 'ms', 'webkit']; + +Web.fPageLoaded = false; // set once the page's first 'onload' event has occurred +Web.fPageShowed = false; // set once the page's first 'onpageshow' event has occurred +Web.fPageEventsEnabled = true; // default is true, set to false (or true) by enablePageEvents() + +/** + * fLocalStorage + * + * true if localStorage support exists, is enabled, and works; "falsey" otherwise + * + * @type {boolean|null} + */ +Web.fLocalStorage = null; + +/** + * TODO: Is there any way to get the Closure Compiler to stop inlining this string? This isn't cutting it. + * + * @const {string} + */ +Web.sLocalStorageTest = "PCjs.localStorage"; + +Web.onPageEvent('onload', function onPageLoad() { + Web.fPageLoaded = true; + Web.doPageEvent(Web.aPageEventHandlers['init']); +}); + +Web.onPageEvent('onpageshow', function onPageShow() { + Web.fPageShowed = true; + Web.doPageEvent(Web.aPageEventHandlers['show']); +}); + +Web.onPageEvent(Web.isUserAgent("iOS")? 'onpagehide' : (Web.isUserAgent("Opera")? 'onunload' : 'onbeforeunload'), function onPageUnload() { + Web.doPageEvent(Web.aPageEventHandlers['exit']); +}); + + + +/** + * @copyright http://pcjs.org/modules/shared/lib/component.js (C) Jeff Parsons 2012-2017 + */ + +/* + * All PCjs components now use JSDoc types, primarily so that Google's Closure Compiler will compile + * everything with zero warnings when ADVANCED_OPTIMIZATIONS are enabled. For more information about + * the JSDoc types supported by the Closure Compiler: + * + * https://developers.google.com/closure/compiler/docs/js-for-compiler#types + * + * I also attempted to validate this code with JSLint, but it complained too much; eg, it didn't like + * "while (true)", a tried and "true" programming convention for decades, and it wanted me to replace + * all "++" and "--" operators with "+= 1" and "-= 1", use "(s || '')" instead of "(s? s : '')", etc. + * + * I prefer sticking with traditional C-style idioms, in part because they are more portable. That + * does NOT mean I'm trying to write "portable JavaScript," but some of this code was ported from C code + * I'd written long ago, so portability is good, and I'm not going to throw that away if there's no need. + * + * UPDATE: I've since switched from JSLint to JSHint, which seems to have more reasonable defaults. + * And for new code, I have adopted some popular JavaScript idioms, like "(s || '')", although the need + * for those kinds of expressions will be reduced as I also start adopting some ES6 features, like + * default parameters. + */ + + +/** + * Since the Closure Compiler treats ES6 classes as @struct rather than @dict by default, + * it deters us from defining named properties on our components; eg: + * + * this['exports'] = {...} + * + * results in an error: + * + * Cannot do '[]' access on a struct + * + * So, in order to define 'exports', we must override the @struct assumption by annotating + * the class as @unrestricted (or @dict). Note that this must be done both here and in the + * subclass (eg, SerialPort), because otherwise the Compiler won't allow us to *reference* + * the named property either. + * + * TODO: Consider marking ALL our classes unrestricted, because otherwise it forces us to + * define every single property the class uses in its constructor, which results in a fair + * bit of redundant initialization, since many properties aren't (and don't need to be) fully + * initialized until the appropriate init(), reset(), restore(), etc. function is called. + * + * The upside, however, may be that since the structure of the class is completely defined by + * the constructor, JavaScript engines may be able to optimize and run more efficiently. + * + * @unrestricted + */ +class Component { + /** + * Component(type, parms, bitsMessage) + * + * A Component object requires: + * + * type: a user-defined type name (eg, "CPU") + * + * and accepts any or all of the following (parms) properties: + * + * id: component ID (default is "") + * name: component name (default is ""; if blank, toString() will use the type name only) + * comment: component comment string (default is undefined) + * + * Component subclasses will usually have additional (parms) properties. + * + * @param {string} type + * @param {Object} [parms] + * @param {number} [bitsMessage] selects message(s) that the component wants to enable (default is 0) + */ + constructor(type, parms, bitsMessage) + { + this.type = type; + + if (!parms) parms = {'id': "", 'name': ""}; + + this.id = parms['id'] || ""; + this.name = parms['name']; + this.comment = parms['comment']; + this.parms = parms; + + /* + * The following Component properties need to be accessible by other machines and/or command scripts; + * well, OK, or we could have exported some new functions to walk the contents of these properties, as we + * did with findMachineComponent(), but this works just as well. + * + * Also, while the double-assignment looks silly (ie, using both dot and bracket property notation), it + * resolves a complaint from the Closure Compiler, because if we use ONLY bracket notation here, then the + * Compiler wants us to change all the other references to bracket notation as well. + */ + this.exports = this['exports'] = {}; + this.bindings = this['bindings'] = {}; + + var i = this.id.indexOf('.'); + if (i < 0) { + this.idComponent = this.id; + } else { + this.idMachine = this.id.substr(0, i); + this.idComponent = this.id.substr(i + 1); + } + + /* + * Gather all the various component flags (booleans) into a single "flags" object, and encourage + * subclasses to do the same, to reduce the property clutter we have to wade through while debugging. + */ + this.flags = { + ready: false, + busy: false, + busyCancel: false, + initDone: false, + powered: false, + unloading: false, + error: false + }; + + this.fnReady = null; + this.clearError(); + this.bitsMessage = bitsMessage || 0; + + this.cmp = null; + this.bus = null; + this.cpu = null; + this.dbg = null; + + /* + * TODO: Consider adding another parameter to the Component() constructor that allows components to tell + * us if they support single or multiple instances per machine. For example, there can be multiple SerialPort + * components per machine, but only one CPU component (some machines also support an FPU, but that component + * is considered separate from the CPU). + * + * It's not critical, but it would help catch machine configuration errors; for example, a machine that mistakenly + * includes two CPU components may, aside from wasting memory, end up with odd side-effects, like unresponsive + * CPU controls. + */ + Component.add(this); + } + + /** + * Component.add(component) + * + * @param {Component} component + */ + static add(component) + { + /* + * This just generates a lot of useless noise, handy in the early days, not so much these days.... + * + * if (DEBUG) Component.log("Component.add(" + component.type + "," + component.id + ")"); + */ + Component.components.push(component); + } + + /** + * Component.addMachine(idMachine) + * + * @param {string} idMachine + */ + static addMachine(idMachine) + { + Component.machines[idMachine] = {}; + } + + /** + * Component.addMachineResource(idMachine, sName, data) + * + * @param {string} idMachine + * @param {string|null} sName (name of the resource) + * @param {*} data + */ + static addMachineResource(idMachine, sName, data) + { + /* + * I used to assert(Component.machines[idMachine]), but when we're running as a Node app, embed.js is not used, + * so addMachine() is never called, so resources do not need to be recorded. + */ + if (Component.machines[idMachine] && sName) { + Component.machines[idMachine][sName] = data; + } + } + + /** + * Component.getMachineResources(idMachine) + * + * @param {string} idMachine + * @return {Object|undefined} + */ + static getMachineResources(idMachine) + { + return Component.machines[idMachine]; + } + + /** + * Component.getTime() + * + * @return {number} the current time, in milliseconds + */ + static getTime() + { + return Date.now() || +new Date(); + } + + /** + * Component.log(s, type) + * + * For diagnostic output only. + * + * @param {string} [s] is the message text + * @param {string} [type] is the message type + */ + static log(s, type) + { + if (!COMPILED) { + if (s) { + var sElapsed = "", sMsg = (type? (type + ": ") : "") + s; + if (typeof Usr != "undefined") { + if (Component.msStart === undefined) { + Component.msStart = Component.getTime(); + } + sElapsed = (Component.getTime() - Component.msStart) + "ms: "; + } + sMsg = sMsg.replace(/\r/g, '\\r').replace(/\n/g, ' '); + if (window && window.console) console.log(sElapsed + sMsg); + } + } + } + + /** + * Component.assert(f, s) + * + * Verifies conditions that must be true (for DEBUG builds only). + * + * The Closure Compiler should automatically remove all references to Component.assert() in non-DEBUG builds. + * TODO: Add a task to the build process that "asserts" there are no instances of "assertion failure" in RELEASE builds. + * + * @param {boolean} f is the expression we are asserting to be true + * @param {string} [s] is description of the assertion on failure + */ + static assert(f, s) + { + if (DEBUG) { + if (!f) { + if (!s) s = "assertion failure"; + Component.log(s); + throw new Error(s); + } + } + } + + /** + * Component.print(s) + * + * Components that inherit from this class should use this.print(), rather than Component.print(), because + * if a Control Panel is loaded, it will override only the instance method, not the class method (overriding the + * class method would improperly affect any other machines loaded on the same page). + * + * @this {Component} + * @param {string} s + */ + static print(s) + { + if (!COMPILED) { + var i = s.lastIndexOf('\n'); + if (i >= 0) { + Component.println(s.substr(0, i)); + s = s.substr(i + 1); + } + Component.printBuffer += s; + } + } + + /** + * Component.println(s, type, id) + * + * Components that inherit from this class should use this.println(), rather than Component.println(), because + * if a Control Panel is loaded, it will override only the instance method, not the class method (overriding the + * class method would improperly affect any other machines loaded on the same page). + * + * @param {string} [s] is the message text + * @param {string} [type] is the message type + * @param {string} [id] is the caller's ID, if any + */ + static println(s, type, id) + { + if (!COMPILED) { + s = Component.printBuffer + (s || ""); + Component.log((id? (id + ": ") : "") + (s? ("\"" + s + "\"") : ""), type); + Component.printBuffer = ""; + } + } + + /** + * Component.notice(s, fPrintOnly, id) + * + * notice() is like println() but implies a need for user notification, so we alert() as well. + * + * @param {string} s is the message text + * @param {boolean} [fPrintOnly] + * @param {string} [id] is the caller's ID, if any + * @return {boolean} + */ + static notice(s, fPrintOnly, id) + { + if (!COMPILED) { + Component.println(s, Component.PRINT.NOTICE, id); + } + if (!fPrintOnly) Component.alertUser((id? (id + ": ") : "") + s); + return true; + } + + /** + * Component.warning(s) + * + * @param {string} s describes the warning + */ + static warning(s) + { + if (!COMPILED) { + Component.println(s, Component.PRINT.WARNING); + } + Component.alertUser(s); + } + + /** + * Component.error(s) + * + * @param {string} s describes the error; an alert() is displayed as well + */ + static error(s) + { + if (!COMPILED) { + Component.println(s, Component.PRINT.ERROR); + } + Component.alertUser(s); + } + + /** + * Component.alertUser(sMessage) + * + * @param {string} sMessage + */ + static alertUser(sMessage) + { + if (window) { + window.alert(sMessage); + } else { + Component.log(sMessage); + } + }; + + /** + * Component.confirmUser(sPrompt) + * + * @param {string} sPrompt + * @returns {boolean} true if the user clicked OK, false if Cancel/Close + */ + static confirmUser(sPrompt) + { + var fResponse = false; + if (window) { + fResponse = window.confirm(sPrompt); + } + return fResponse; + } + + /** + * Component.promptUser() + * + * @param {string} sPrompt + * @param {string} [sDefault] + * @returns {string|null} + */ + static promptUser(sPrompt, sDefault) + { + var sResponse = null; + if (window) { + sResponse = window.prompt(sPrompt, sDefault === undefined? "" : sDefault); + } + return sResponse; + } + + /** + * Component.appendControl(control, sText) + * + * @param {Object} control + * @param {string} sText + */ + static appendControl(control, sText) + { + control.value += sText; + /* + * Prevent the + + +
    +
    + +
    +
    + + +
    +
    +
    + +
    +
    + +
    +
    + +
    +
    +
    +
    +
    + +
    +
    + + + + +
    +
    + +
    +
    + + + +
    +
    +
    +
    + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + ; + + + + + + + + + + + + + + + : + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + ; + + + + + + + + + + + + + + + + + + + + + + + + + + + + 8088 + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + + null + + + + + + 0 + + + + + + + -1 + + + + + + + -1 + + + + + + + -1 + + + + + + ,model:'',stepping:'',fpu:,cycles:,multiplier:,autoStart:,addrReset:,csStart:,csInterval:,csStop: + + + + + + + + + + + + + + + 8087 + + + + + + + + + + + + ,model:'',stepping:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + true + + + + + + + false + + + + + + {} + + + + + + + + + + + + + + + + + + + chipset + ,model:'',scaleTimers:,sw1:'',sw2:'',sound:,floppies:,monitor:'',dateRTC:'' + + + + + + + + + + + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + device + ,type:'',baudReceive:,baudTransmit:,autoMount:'' + + + + + + + + + + + + + + + + + + + + keyboard + ,model:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + parallel + ,adapter:,binding:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + + 0 + + + + + + + 0 + + + + + + + false + + + + + serial + ,adapter:,baudReceive:,baudTransmit:,binding:'',tabSize:,charBOL:,upperCase: + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + 0.5 + + + + + + + + + + + mouse + ,adapter:,binding:'',type:'',scaleMouse:,serial:'' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + fdc + ,autoMount:'',sortBy:'' + + + + + + + + + + + + + + + + + + + + + XT + + + + + hdc + ,drives:'',type:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + null + + + + + + + + + + + + + + + + + rom + ,addr:,size:,alias:,file:'',notify:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + null + + + + + + null + + + + + + true + + + + + ram + ,addr:,size:,file:'',load:,exec:,test: + + + + + + + + + + + + + + + + + + + + + null + + + + + + + 256 + + + + + + + 224 + + + + + + + black + + + + + + 0 + + + + + + 0 + + + + + + false + + + + + + 1bpp + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + false + + + + + + 1 + + + + + + 1 + + + + + + + 80 + + + + + + + 25 + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + + + + 0 + + + + + + null + + + + + + 0 + + + + + + 60 + + + + + + 0.5 + + + + + video + ,model:'',mode:,screenWidth:,screenHeight:,screenColor:'',screenRotate:,bufferAddr:,bufferRAM:,bufferFormat:'',bufferCols:,bufferRows:,bufferBits:,bufferLeft:,bufferRotate:,memory:,switches:'',scale:,cellWidth:,cellHeight:,charCols:,charRows:,fontROM:'',fontColor:'',touchScreen:'',autoLock:,aspectRatio:,smoothing:,interruptRate:,refreshRate:,flicker: + + + + + + + + + + + + + + + 16 + + + + + + + + + + + + + + + + + debugger + ,base:,commands:'',messages:'' + + + + + + + + + + + + + + panel + + + + + + + + + + + + + + + + + + + + + true + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + computer + ,autoPower:,busWidth:,resume:'',state:'' + + + + + + + + diff --git a/versions/pcx86/1.37.1/document.css b/versions/pcx86/1.37.1/document.css new file mode 100644 index 000000000..7072b406e --- /dev/null +++ b/versions/pcx86/1.37.1/document.css @@ -0,0 +1,162 @@ +@CHARSET "UTF-8"; + +.page { + margin: 2% 2%; + padding: 2% 2%; + min-width: 30em; + overflow: auto; + font-size: large; + font-family: Helvetica, Arial, sans-serif; + background: #303030; + color: #ccc; + +} +.page-header { +} +.page-header-title { + text-align: center; + +} +.page a { + color: #7fc07f; + text-decoration: none; +} +a.footlink, a.paralink { + text-decoration: none; +} +a.footlink:link, a.paralink:link { + color: blue; +} +a.footlink:visited, a.paralink:visited { + color: blue; +} +.galleryitem { + float: left; + width: 200px; +} +.item { + float: left; + width: 2em; + text-indent: 1em; +} +.list { + margin-left: 3em; + text-indent: 0; + text-align: justify; +} +ul { + list-style: none; +} +div.pnumber { + float: left; + width: 2em; + text-indent: 1em; +} +div.pitem { + margin-left: 10em; +} +p.indent, .justified p { + text-indent: 2em; + text-align: justify; + line-height: 1.5em; +} +p.noindent { + text-indent: 0; + text-align: justify; +} +p.center, .center { + text-align: center; +} +li.para { + margin-top: 1em; + margin-bottom: 1em; +} +.left { + text-align: left; +} +.right { + text-align: right; +} +blockquote.tag { + font-size: small; + font-family: Monaco, Fixed, monospace; + margin-top: 0; + margin-bottom: 0; +} +.blockquote { + padding-left: 1em; + text-indent: 0; + text-align: justify; +} +.italics { + font-style: italic; +} +.medium { + font-size: medium; +} +.small { + font-size: x-small; +} +.smallcaps { + font-variant: small-caps; +} +.strike { + text-decoration: line-through; +} +.summation, .bracelist { + display: inline-block; + position: relative; + vertical-align: middle; + text-align: center; + margin-bottom: 0.5ex; + text-indent: 0; +} +.bracelist-symbol { + font-size: 3em; + vertical-align: -40%; +} +.summation .summation-lower, .summation .summation-upper, .bracelist-item { + display: block; + font-size: 75%; + text-align: center; +} +.summation .summation-upper { + margin-bottom: 0; + margin-left: 0.8ex; + font-style: italic; +} +.summation .summation-lower{ + margin-bottom: -0.6ex; + font-style: italic; +} +.summation .summation-symbol { + font-size: 2em; +} +p sup { + vertical-align: baseline; + position: relative; + bottom: .5em; + font-size: small; +} +p sub { + vertical-align: baseline; + position: relative; + bottom: -.5em; + font-size: small; +} +.footnote { + font-size: medium; + text-indent: 1em; + text-align: justify; + margin-top: .5em; +} +.image-right { + float: right; + margin-left: 1em; + margin-top: 1em; + margin-bottom: 1em; +} +.image-caption { + font-size: small; + text-align: center; +} \ No newline at end of file diff --git a/versions/pcx86/1.37.1/document.xsl b/versions/pcx86/1.37.1/document.xsl new file mode 100644 index 000000000..fb5936a47 --- /dev/null +++ b/versions/pcx86/1.37.1/document.xsl @@ -0,0 +1,452 @@ + + + + + +]> + + + + + + + + + +

    +
    + + + + + + + +

    +
    + +

    +
    +
    +
    + + + + + + +
    +
    + + +
    + +   + + +
    +
    + +
    +
    + + + + + + + + + + + + + + + + +

    +
    + + +

    +
    + + +

    +
    + + +
    +
    + + +
    +
    + + + + + + + + + + + + + + +
    +
    + + +
    +
    + + +
  • +
    + + +
    image
    +
    + + +
    +
    + + + + +
    {.}
    +
    + +
    {.}
    +
    +
    +
    + + + + + + + + + + < + > + + + + × + + ÷ + σ + + + + + + + + + + + + { + + + + + + + + + + [] + + + + +
    + +
    +
    + + + , and + + + + + MDY + + + + + + + + + + + + + + + + + + + + January + February + March + April + May + June + July + August + September + October + November + December + + + , + + + + + +

    + +
    +
    + + +
    + {.}
    +
    +
    +
    + + + +

    Timeline

    +
    + +

    +
    +
    + +
    +
    + + + + + + + + + +

    +
    + +
    +
    +
    + + + +

    People

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + +

    +
      + +
    +
    + + + + + + + + + + +
  • + +
  • +
    + + + +

    +
    +

    + +

    +
    +
    + + + + false + + + + + + [Original] + + + + + + + + + + [] + + +
    by
    + + +
    + [Source: + + + + + + + ] +
    +
    +
    + + + +

    Resources

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + + +

    +
    +
      + +
    +
    + + +
  • +
    + + + +

    +
    +
    + +
    +
    + + + +

    +
    + +
    + + + +

    +
    +
      + +
    +
    + + + + + +
      + +
    +
    + + + + +
  • +
    + +
  • +
    + +
  • +
    +
    +
    + + +
  • +
    + + + + + + + + + + +
    + < ="" + + ></> + ></> + /> + +
    +
    + +
    diff --git a/versions/pcx86/1.37.1/machine.xsl b/versions/pcx86/1.37.1/machine.xsl new file mode 100644 index 000000000..b14a0f847 --- /dev/null +++ b/versions/pcx86/1.37.1/machine.xsl @@ -0,0 +1,61 @@ + + + + +]> + + + + + + + + + + + + + + + + + js + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    +
    + + + + + , + +
    +
    + +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pcx86/1.37.1/manifest.xsl b/versions/pcx86/1.37.1/manifest.xsl new file mode 100644 index 000000000..aa8d6b46a --- /dev/null +++ b/versions/pcx86/1.37.1/manifest.xsl @@ -0,0 +1,247 @@ + + + + +]> + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Document Manifest

    +
    +
      + + + + None + + + + + + + + + + + + + + + + +
    +
    +
    +

    + +
    +
    +
    + + +
    + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Software Manifest

    +
    +
      + + + + None + + + + + Unknown + + + + + None + + + + + None + + + + + + + + + + + + + UpdatedReleased + + Unknown + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    + + + + + + + +

    No default machine specified for '' in manifest.xml

    +
    + +
    +
    +
    + + + + -dbg + + + + + + +
    + + + + + Unknown + +
  • +
      + + + + + + + + +
    • + + + + + + + + + + + + + + + + + + + + + + + + + +
        + +
      • + + + + + + +
      • +
        +
      +
      +
    • +
      + + + + + + + + +
    +
  • +
    +
    + +
    diff --git a/versions/pcx86/1.37.1/outline.xsl b/versions/pcx86/1.37.1/outline.xsl new file mode 100644 index 000000000..5fbcba812 --- /dev/null +++ b/versions/pcx86/1.37.1/outline.xsl @@ -0,0 +1,47 @@ + + + + +]> + + + + + + + + + + + + + + + + + + <xsl:value-of select="title"/><xsl:text> | </xsl:text><xsl:value-of select="$SITEHOST"/> + + + + + +
    +
    + +
    +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pcx86/1.37.1/pcx86-dbg.js b/versions/pcx86/1.37.1/pcx86-dbg.js new file mode 100644 index 000000000..5ce5e8330 --- /dev/null +++ b/versions/pcx86/1.37.1/pcx86-dbg.js @@ -0,0 +1,913 @@ +(function(){/* + http://pcjs.org/modules/shared/lib/diskapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/dumpapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/reportapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/userapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/keys.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/strlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/weblib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/interrupts.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/messages.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/state.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/embed.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/usrlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/component.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/panel.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/bus.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/memory.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/cpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86seg.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86cpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86fpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86func.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86help.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86mods.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86ops.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86op0f.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/chipset.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/rom.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/ram.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/keyboard.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/video.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/parallel.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/serial.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/mouse.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/disk.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/fdc.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/hdc.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/computer.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/save.js (C) Jeff Parsons 2012-2017 +*/ +var l,aa,ba="function"==typeof Object.create?Object.create:function(a){function b(){}b.prototype=a;return new b},ca;if("function"==typeof Object.setPrototypeOf)ca=Object.setPrototypeOf;else{var da;a:{var ea={Hd:!0},fa={};try{fa.__proto__=ea;da=fa.Hd;break a}catch(a){}da=!1}ca=da?function(a,b){a.__proto__=b;if(a.__proto__!==b)throw new TypeError(a+" is not extensible");return a}:null}var ha=ca; +function ia(a,b){a.prototype=ba(b.prototype);a.prototype.constructor=a;if(ha)ha(a,b);else for(var c in b)if("prototype"!=c)if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);d&&Object.defineProperty(a,c,d)}else a[c]=b[c];a.rq=b.prototype} +var ja="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ka="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global&&null!=global?global:this;function la(a,b){if(b){var c=ka;a=a.split(".");for(var d=0;da?-b:b}});la("Math.sign",function(a){return a?a:function(a){a=Number(a);return 0===a||isNaN(a)?a:0":62,"?":63,"@":64,ee:65,pi:66,ri:67,si:68,E:69,ti:70,ui:71,vi:72,wi:73,xi:74,yi:75,zi:76,Ai:77,Bi:78,Ci:79,Di:80,Q:81,Ei:82,Fi:83,Gi:84,Hi:85,Ii:86,Ji:87,Ki:88,Li:89,Zf:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,Hd:97,ol:98,ql:99,d:100,e:101,zl:102,Al:103,Bl:104,Cl:105,Wm:106,k:107,Xm:108,cn:109,n:110,on:111,p:112,q:113,r:114,So:115,t:116,Wo:117, +Xo:118,Yo:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Up:127},na={};na[173]=n["-"];na[186]=n[";"];na[187]=n["="];na[189]=n["-"];na[188]=n[","];na[190]=n["."];na[191]=n["/"];na[192]=n["`"];na[219]=n["["];na[220]=n["\\"];na[221]=n["]"];na[222]=n["'"];var pa={};pa[n["1"]]=n["!"];pa[n["2"]]=n["@"];pa[n["3"]]=n["#"];pa[n["4"]]=n.$;pa[n["5"]]=n["%"];pa[n["6"]]=n["^"];pa[n["7"]]=n["&"];pa[n["8"]]=n["*"];pa[n["9"]]=n["("];pa[n["0"]]=n[")"];pa[186]=n[":"];pa[187]=n["+"];pa[188]=n["<"];pa[189]=n._; +pa[190]=n[">"];pa[191]=n["?"];pa[192]=n["~"];pa[219]=n["{"];pa[220]=n["|"];pa[221]=n["}"];pa[222]=n['"'];pa[173]=n._;pa[61]=n["+"];pa[59]=n[":"]; +function qa(a,b){if(a){b||(b=10);var c,d=0=b&&(c=a.match(/(-?[0-9]+)B([0-9]*)/))&& +(a=c[1],e=35-((c[2]||35)&255));c=a;if(((d=b)&&10!=d?16==d?null!==c.match(/^-?[0-9a-f]+$/i):8==d?null!==c.match(/^-?[0-7]+$/):2==d&&null!==c.match(/^-?[01]+$/):null!==c.match(/^-?[0-9]+$/))&&!isNaN(f=parseInt(a,b))){e&&(0>f&&(f+=Math.pow(2,36)),f=0a&&-1a&&(a+=Math.pow(b,c)),a>=Math.pow(b,c)&&(c=Math.ceil(Math.log(a)/Math.log(b))));for(var g=e||-1;0=h?48:55;f=String.fromCharCode(h)+f;a=Math.trunc(a/b)}g--}return(void 0===d?"":d)+f}function ta(a,b,c){b?36=b?8:262143>=b?18:36);return sa(a,2,b,"",c)} +function ua(a,b,c){b?12=b?6:16777215>=b?8:12);return sa(a,8,b,c?"0o":"")}function q(a,b,c){b?9=b?4:4294967295>=b?8:9);return sa(a,16,b,c?"0x":"")}function va(a){return q(a,2,!0)}function wa(a){return q(a,4,!0)}function xa(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0"']/g,function(a){return Ba[a]})}function Ca(a,b,c){return c?(" "+a).slice(-b):(a+" ").slice(0,b)}function Da(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} +var Ba={"&":"&","<":"<",">":">",'"':""","'":"'"},Ea={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; +function Fa(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1;var h=c(b,a[g]);0d?"am":"pm";break;case "d":c+=("0"+e).slice(-2);break;case "D":c+=Ha[b.getDay()].substr(0,3);break;case "F":c+=Ia[f-1];break;case "g":c+=d?12c&&(c+=a.length);0>c&&(c=0);for(var d=a.length;ca?this.ye=this.id:(this.de=this.id.substr(0,a),this.ye=this.id.substr(a+1));this.aa={ready:!1,mf:!1,Xg:!1,pf:!1,ac:!1,we:!1,error:!1};this.lg=null;this.aa.error=!1;this.dc=c||0;this.ca=this.G=this.oa=this.na=null;qb.push(this)} +function rb(a,b,c){sb[a]&&b&&(sb[a][b]=c)}function kb(a){window&&window.alert(a)}function tb(a){var b=!1;window&&(b=window.confirm(a));return b}function ub(a,b){a.value+=b;b=a.value;8192e?d+=b+"\n":d=d.substr(0,e)+c+d.substr(e+b.length);8192Math.abs(a.B-b)?1:2),1==a.H?b=a.B:2==a.H&&(d=a.A));a.A=d;a.B=b;if(0<=d&&d>d.shift;d=g*a.oa.B;f=(g+f.mq)*a.oa.B-1;0f&&(d=f);c=d;break a}c=-1}if(-1!==c&&(c&=-16,c!=a.N)){b=c;if(a.context&&a.K&&a.L){e=ic-jc;f=a.K.width;a.L.fillStyle=kc;a.L.fillRect(0,e,f,jc);d=e+lc;g=a.K;var h=a.L,k,m=null.style.color,p=a.ka=10;a.D=p;a.J=d;a.ea=a.ba=lc;k||(k=a.U||a.ba+"px "+mc);a.Z=a.U=k;g&&(a.P=g);h&&(a.I=h,a.V=m||"white");a.M=a.P.width/24|0;if(null==b)nc(a,"Mouse over memory to dump");else for(nc(a,q(b,8,!0),null,0,1),k=1;16>=k;k++){d="";for(g=1;8>=g;g++)h=a.oa,m=b++,h=h.Z[(m&h.C)>>>h.A].ae(m&h.D,m),nc(a,q(h,2),null,1),d+= +32<=h&&128>h?String.fromCharCode(h):".";nc(a,d,null,0,1)}a.context.drawImage(a.K,0,e,f,jc,a.ra,a.ta,a.la,a.qa)}a.N=c}}}function nc(a,b,c,d,e){a.I.font=a.Z;a.I.fillStyle=a.V;a.I.fillText(b,a.D,a.J);a.D+=a.M;null!=c&&(16!=a.pa?b=c.toString():(b=8>a.fa?"0x":"",b+=q(c,a.fa)),a.I.fillText(b,a.D,a.J),a.D+=a.M);d&&(a.D+=a.M*d);e&&(a.D=a.ka,a.J+=(a.ea+2)*(e||1))} +function bc(){for(var a=!1,b=zb(document,"pcx86","panel"),c=0;c>2,ic=fc,kc="black",jc=fc>>1;cb(bc); +function oc(a,b,c){pb.call(this,"Bus",a);this.G=b;this.ca=c;this.I=a.busWidth||20;this.ba=Math.pow(2,this.I);this.N=this.C=this.ba-1|0;this.A=32==this.I||20>=this.I?12:24>=this.I?14:15;this.B=1<>2;this.D=this.B-1;this.M=this.ba/this.B|0;this.P=this.M-1;this.F=[];this.H=[];this.K=this.L=!1;this.V=[];this.U=[];a=new w;pc(a,this.ca);this.Z=Array(this.M);for(b=0;b>>a.A;0g&&(p=g);if(k&&k.size){if(k.type==d&&k.controller==e){if(f+g<=k.za)return k.xe+=k.za-f,k.za=f,!0;if(f>=k.za+k.xe){p=k.size-(f-m);p>g&&(p=g);k.xe=f-k.za+p;f=m+a.B;g-=p;h++;continue}}return sc(a,tc,f,g)}f=new w(f,p,a.B,d,e);pc(f,a.ca,k);a.Z[h++]=f;f=m+a.B;g-=p}return 0>=g?(uc(a.G),a.G.aa.Xa||(e=c/1024|0,a.status((e?e+"Kb ":c+" bytes ")+wc[d]+" at "+q(b))),!0):sc(a,xc,b,c)} +function qc(a,b){32==a.I?b?a.J&&(yc(a,1048576,1048576,a.J),a.J=null):a.J||(a.J=zc(a,1048576,1048576),yc(a,1048576,1048576,zc(a,0,1048576))):20>>this.A;0>>a.A;0>>=a.A;0>>a.A;0>>this.A].Cc(a&this.D,a)};function Lc(a,b){var c=b&a.D,d=(b&a.C)>>>a.A;return c!=a.D?a.Z[d].Kf(c,b):a.Z[d++].ae(c,b)|a.Z[d&a.P].ae(0,b+1)<<8} +l.ub=function(a,b){this.Z[(a&this.C)>>>this.A].Ec(a&this.D,b&255,a)};function Mc(a,b,c){var d=b&a.D,e=(b&a.C)>>>a.A;d!=a.D?a.Z[e].oi(d,c&65535,b):(a.Z[e++].bf(d,c&255,b),a.Z[e&a.P].bf(0,c>>8&255,b+1))} +function Nc(a,b){var c=0,d=[],e=!a.J&&a.N==a.C;e||qc(a,!0);for(var f=0;f>>=f;if(void 0!==g){if(g[0])g[0](b,k,e);a.ca&&a.L!=g[1]&&Wc(a.ca,b,k)}else a.ca&&(Ub(a.ca,a,b,k,e),a.L&&Wc(a.ca,b,k));f+=h<<3;b+=h;c-=h}}function sc(a,b,c,d,e){b="Memory block error ("+b+": "+q(c)+","+q(d)+")";e?a.ca?a.ca.message(b):a.log(b):kb(b);return!1}var hc,Xc={nn:20,count:8,lq:1,type:3},Yc=0,Zc;for(Zc in Xc){var $c=Xc[Zc];Xc[Zc]={dn:(1<<$c)-1<>1),this.W=new Int32Array(this.I,0,c>>2),Cc(this,Hc?Ic:Jc);else{this.W=Array(c>>2);for(e=0;e>2),a=0;a>8,c)};l.mi=function(a,b,c){this.Ec(a++,b&255,c++);this.Ec(a++,b>>8&255,c++);this.Ec(a++,b>>16&255,c++);this.Ec(a,b>>>24,c)};l.Bo=function(a){return this.W[a>>2]>>>((a&3)<<3)&255}; +l.No=function(a){var b=a>>2;a=(a&3)<<3;var c=this.W[b]>>a;return 24>a?c&65535:c&255|(this.W[b+1]&255)<<8};l.Ho=function(a){var b=a>>2;a=(a&3)<<3;var c=this.W[b];a&&(c=c>>>a|this.W[b+1]<<32-a);return c};l.cp=function(a,b){var c=a>>2;a=(a&3)<<3;this.W[c]=this.W[c]&~(255<>2;a=(a&3)<<3;24>a?this.W[c]=this.W[c]&~(65535<>8);this.Oa=!0}; +l.jp=function(a,b){var c=a>>2;if(a=(a&3)<<3){var d=-1<>>32-a}else this.W[c]=b;this.Oa=!0};l.Ao=function(a,b){this.ca&&null!=this.za&&nd(this.ca,this.za+a)||this.C&&od(this.C,b,1,!1);return this.ae(a,b)};l.Mo=function(a,b){this.ca&&null!=this.za&&nd(this.ca,this.za+a,2)||this.C&&od(this.C,b,2,!1);return this.Kf(a,b)};l.Go=function(a,b){this.ca&&null!=this.za&&nd(this.ca,this.za+a,4)||this.C&&od(this.C,b,4,!1);return this.fi(a,b)}; +l.bp=function(a,b,c){this.ca&&null!=this.za&&pd(this.ca,this.za+a)||this.C&&od(this.C,c,1,!0);this.D?this.cf(0,b,c):this.bf(a,b,c)};l.op=function(a,b,c){this.ca&&null!=this.za&&pd(this.ca,this.za+a,2)||this.C&&od(this.C,c,2,!0);this.D?this.cf(0,b,c):this.oi(a,b,c)};l.ip=function(a,b,c){this.ca&&null!=this.za&&pd(this.ca,this.za+a,4)||this.C&&od(this.C,c,4,!0);this.D?this.cf(0,b,c):this.K(a,b,c)};l.Do=function(a,b){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.F;return this.td.Cc(a,b)}; +l.Po=function(a,b){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.F;return this.td.Jf(a,b)};l.Jo=function(a,b){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.F;return this.td.Nd(a,b)};l.fp=function(a,b,c){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.J;this.td.Ec(a,b,c)};l.rp=function(a,b,c){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.J;this.td.Of(a,b,c)};l.lp=function(a,b,c){this.pb.W[this.A]|=this.F;this.qb.W[this.B]|=this.J;this.td.Nf(a,b,c)}; +l.Eo=function(a,b){return qd(this.C,b,!1).Cc(a,b)};l.Qo=function(a,b){return qd(this.C,b,!1).Jf(a,b)};l.Ko=function(a,b){return qd(this.C,b,!1).Nd(a,b)};l.gp=function(a,b,c){qd(this.C,c,!0).Ec(a,b,c)};l.sp=function(a,b,c){qd(this.C,c,!0).Of(a,b,c)};l.mp=function(a,b,c){qd(this.C,c,!0).Nf(a,b,c)};l.zo=function(a){return this.Qa[a]};l.Lk=function(a){return this.Qa[a]};l.Co=function(a){this.pb.W[this.A]|=32;this.qb.W[this.B]|=32;this.Cc=this.Lk;return this.Qa[a]}; +l.Lo=function(a){return this.H.getUint16(a,!0)};l.Qk=function(a){return a&1?this.Qa[a]|this.Qa[a+1]<<8:this.Td[a>>1]};l.Oo=function(a){this.pb.W[this.A]|=32;this.qb.W[this.B]|=32;this.Jf=this.Qk;return a&1?this.Qa[a]|this.Qa[a+1]<<8:this.Td[a>>1]};l.Fo=function(a){return this.H.getInt32(a,!0)};l.Nk=function(a){return a&3?this.Qa[a]|this.Qa[a+1]<<8|this.Qa[a+2]<<16|this.Qa[a+3]<<24:this.W[a>>2]}; +l.Io=function(a){this.pb.W[this.A]|=32;this.qb.W[this.B]|=32;this.Nd=this.Nk;return a&3?this.Qa[a]|this.Qa[a+1]<<8|this.Qa[a+2]<<16|this.Qa[a+3]<<24:this.W[a>>2]};l.ap=function(a,b){this.Qa[a]=b;this.Oa=!0};l.Yk=function(a,b){this.Qa[a]=b;this.Oa=!0};l.ep=function(a,b){this.Qa[a]=b;this.pb.W[this.A]|=32;this.qb.W[this.B]|=96;this.Ec=this.Yk;this.td.Oa=!0};l.np=function(a,b){this.H.setUint16(a,b,!0);this.Oa=!0};l.$k=function(a,b){a&1?(this.Qa[a]=b,this.Qa[a+1]=b>>8):this.Td[a>>1]=b;this.Oa=!0}; +l.qp=function(a,b){a&1?(this.Qa[a]=b,this.Qa[a+1]=b>>8):this.Td[a>>1]=b;this.pb.W[this.A]|=32;this.qb.W[this.B]|=96;this.Of=this.$k;this.td.Oa=!0};l.hp=function(a,b){this.H.setInt32(a,b,!0);this.Oa=!0};l.Zk=function(a,b){a&3?(this.Qa[a]=b,this.Qa[a+1]=b>>8,this.Qa[a+2]=b>>16,this.Qa[a+3]=b>>24):this.W[a>>2]=b;this.Oa=!0}; +l.kp=function(a,b){a&3?(this.Qa[a]=b,this.Qa[a+1]=b>>8,this.Qa[a+2]=b>>16,this.Qa[a+3]=b>>24):this.W[a>>2]=b;this.pb.W[this.A]|=32;this.qb.W[this.B]|=96;this.Nf=this.Zk;this.td.Oa=!0};function wd(a){Vb&&!Hc&&(a=a<<24|a<<8&16711680|a>>8&65280|a>>>24);return a} +var dd=0,Gc=2,ed=5,gd=6,wc="NONE RAM ROM VIDEO H/W UNPAGED PAGED".split(" "),cd=0,id=[],Kc=[w.prototype.Bo,w.prototype.cp,w.prototype.No,w.prototype.pp,w.prototype.Ho,w.prototype.jp],ld=[w.prototype.Ao,w.prototype.bp,w.prototype.Mo,w.prototype.op,w.prototype.Go,w.prototype.ip],hd=[w.prototype.Do,w.prototype.fp,w.prototype.Po,w.prototype.rp,w.prototype.Jo,w.prototype.lp],fd=[w.prototype.Eo,w.prototype.gp,w.prototype.Qo,w.prototype.sp,w.prototype.Ko,w.prototype.mp]; +if(Vb)var Jc=[w.prototype.zo,w.prototype.ap,w.prototype.Lo,w.prototype.np,w.prototype.Fo,w.prototype.hp],Ic=[w.prototype.Lk,w.prototype.Yk,w.prototype.Qk,w.prototype.$k,w.prototype.Nk,w.prototype.Zk],xd=[w.prototype.Co,w.prototype.ep,w.prototype.Oo,w.prototype.qp,w.prototype.Io,w.prototype.kp]; +function yd(a,b){pb.call(this,"CPU",a,1);b=a.cycles||b;var c=a.multiplier||1;this.Y={};this.Y.Yd=b;this.Y.lh=Math.round(1E3/zd);this.Y.Cj=this.Y.ph=this.Y.Ad=c;this.Y.og=Math.round(this.Y.Yd/1E4)/100;this.Y.Kd=this.Y.pe=this.Y.og*this.Y.Ad;this.aa.ki=this.aa.Xa=this.aa.Pf=!1;this.aa.he=a.autoStart;this.aa.hj=!1;this.aa.Ie=!1;this.Y.uf=this.Y.Se=0;this.Y.wf=a.csStart;this.Y.Re=a.csInterval;this.Y.Te=a.csStop;this.qa=[];this.Rd=0;this.wj=this.Ro.bind(this)}ia(yd,pb);l=yd.prototype; +l.tc=function(a,b,c,d){this.na=a;this.oa=b;this.ca=d;for(b=0;b=a.Y.Se&&(a.Y.Se+=a.Y.Re,c=!0);0<=a.Y.Te&&a.Y.Te<=Jd(a)&&(a.Y.Re=a.Y.Te=-1,Ed(a),Gd(a),c=!0);c&&a.O(Jd(a)+" cycles: checksum="+q(a.Y.uf))}} +l.Eb=function(a,b,c){var d=this;a=!1;switch(b){case "power":case "reset":this.ma[b]=c;a=!0;break;case "run":this.ma[b]=c;c.onclick=function(){var a=d.aa.Xa,b;if(b=d.na)if(b=d.na,b.aa.we&&(b.aa.we=!1,b.aa.pf&&!b.aa.ac&&b.We(Kd)),b.aa.ac)b=!0;else{var c=null,h,k=Bb(b.id);for(h=0;ha.Y.Ad)b=a.Y.Ad;a.Y.jn=Math.floor(a.Y.Yd/zd*b);a.Y.ph=b} +function Jd(a,b){var c=a.Fd+a.md+a.ld-a.A;b&&1a.Y.og&&(c=Math.round(c/a.Y.Ad));return c}function Dd(a){a.Fd=a.md=a.ld=a.A=0;Ed(a);Ld(a,a.Y.Cj)} +function Ld(a,b,c){var d=!0;if(void 0!==b){0b[1])&&(c=a.Y.Yd*a.Y.ph/1E3*c|0,a.aa.Xa&&(c+=Qd(a)),b[1]=c)}function Rd(a){for(var b=[],c=0;cthis.Y.lh&&(this.Y.xd+=a,this.Y.xd>this.Y.tf&&(this.Y.xd=this.Y.tf))}try{this.aa.Pf=!1;do{for(var b,c=this.aa.Ie?1:this.Y.Yd*this.Y.ph|0,d=this.qa.length-1;0<=d;d--){var e=this.qa[d];0>e[1]||c>e[1]&&(c=e[1])}b=c;if(this.V){Td(this.V);var f=this.V;a=b;var g=f.qa[0];if(g.me){var h=(Jd(f.G,f.M)-g.hd)/f.Ea|0,k=Ud(f,0)-h;g.mode==Vd&&(k-=h);var m=k*f.Ea| +0;g.mode==Vd&&(m>>=1);a>m&&(a=m)}b=a;var p=this.V;a=b;if(p.A&&p.A[Wd]&Xd){var v=p.Z-Jd(p.G,p.M);0v&&(a=v)}b=a}try{this.Jg(b)}catch(J){if("number"!=typeof J)throw J;}a=b=Qd(this);for(var u=this.qa.length-1;0<=u;u--){var A=this.qa[u];0>A[1]||(A[1]-=a,0>=A[1]&&(A[1]=-1,A[3](),0<=A[2]&&Pd(this,u,A[2])))}Id(this,b)}while(this.aa.Xa&&!this.aa.Pf)}catch(J){Gd(this);Fd(this);this.na&&this.na.stop(La(),Jd(this));Mb(this,J.stack||J.message);return}if(this.aa.Xa){b=setTimeout;c=this.wj;this.Y.qe=La(); +d=this.Y.lh;this.Y.qg&&(d=Math.round(d*this.Y.qg/this.Y.jn));d-=this.Y.qe-this.Y.tf;if(e=this.Y.qe-this.Y.xd)this.Y.Kd=Math.round(this.md/(10*e))/100,864E5<=e&&(this.Fd=0,this.V&&Td(this.V,!0),Ld(this));0>d?(-1E3>d&&(this.Y.xd-=d),d=0):this.Y.Kd>>0)+b>this.Nb&&(8088>=this.Lb.da?this.Lb.M|=8:x.call(this.Lb,13));return this.ua+a|0};l.$i=function(a,b){return(a>>>0)+b<=this.Nb?this.ua+a|0:this.fg()};l.sl=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.fg()};l.fg=function(){x.call(this.Lb,13,0);return-1}; +l.bj=function(a,b){return(a>>>0)+b<=this.Nb?this.ua+a|0:this.hg()};l.tl=function(a,b){return(a>>>0)+b>this.Nb?this.ua+a|0:this.hg()};l.hg=function(){x.call(this.Lb,13,0);return-1};function he(a,b,c,d,e){a.T=b;a.ua=d;a.Sa=e;a.Nb=(e>>>0)+1;a.ob=c;a.type=c&7936;a.ext=c>>16&192;a.Ob=(b&4?a.Lb.Gb.ua:a.Lb.Kb)+(b&65528)|0;a.id>>0)+1;a.ob=e;a.type=e&7936;a.ext=0;a.Ob=b;a.id>>0)+1,a.ob=a.A.ob,a.type=a.A.type,a.ext=a.A.ext,a.Ob=a.A.Ob,a.A.T=-1,be(a,!0,!0,!1),a.ua;a.A.T=-1;var f=e.ja(b+0),g=e.ja(b+4),h=g&7936,k=e.ja(b+2)|(g&255)<<16,m=e.ja(b+6),p=c&65528;if(80386<=e.da){var v=f;k|=(m&65280)<<16;f|=(m&15)<<16;m&128&&(f=f<<12|4095)}switch(a.id){case ke:var u=a.C;a.Ne=!1;if(u&&c==de&&a.B.length){var A=a.B[a.Hf-1];if(A&&!A())return-1}var J=c&3,H=(g&24576)>>13;A=-1;p||b>=e.Kb&& +b=a.Cb&&(J>a.Cb&&(A=le(e),me(e,le(e),!0),ne(e,A),a.Ne=!0),A=0);else{if(256==h||2304==h)return oe(a,c,u)?a.ua:-1;if(1024==h){A=2;var G=0;Jh||2048==(h&2560))return x.call(e,13,c&65532),-1;if(!(g&32768))return x.call(e,11,c&65532),-1}break;case ge:if(!p||4096>h||512!=(h&2560))return x.call(e,13,c&65532),-1;if(!(g&32768))return x.call(e, +12,c&65532),-1;break;case ie:u=h&-513;if(!p||256!=u&&2304!=u)return x.call(e,13,c&65532),-1;2304==u&&(a.Qi=k+e.ja(k+102)|0,a.ml=k+a.Sa|0);break;case fe:if(!(h&4096)&&768>>0)+1,a.ob=g,a.type=h,a.ext=m,a.Ob=b,be(a,!0,!0,!1));return k} +function oe(a,b,c){var d=a.Lb,e=a.Cb,f=d.ka.T,g=d.ka.ua;if(!c){if(!(d.ka.type&512))return x.call(d,13,b&65532),!1;d.ib(d.ka.Ob+4,d.ka.ob&=-513)}if(-1===d.ka.load(b))return!1;var h=d.ka.ua;if(!1!==c){if(d.ka.type&512)return x.call(d,13,b&65532),!1;d.ib(d.ka.Ob+4,d.ka.ob|=512)}d.ka.type=d.ka.type&-513|d.ka.ob&512;256==d.ka.type||768==d.ka.type?(d.ib(g+14,z(d)),d.ib(g+16,xe(d)),d.ib(g+18,d.D),d.ib(g+20,d.I),d.ib(g+22,d.L),d.ib(g+24,d.H),d.ib(g+26,y(d)),d.ib(g+28,d.N),d.ib(g+30,d.K),d.ib(g+32,d.J),d.ib(g+ +34,d.pa.T),d.ib(g+36,d.ba.T),d.ib(g+38,d.U.T),d.ib(g+40,d.Fa.T),d.Gb.load(d.ja(h+42)),ye(d,d.ja(h+16)|(c?16384:0)),d.D=d.ja(h+18),d.I=d.ja(h+20),d.L=d.ja(h+22),d.H=d.ja(h+24),d.N=d.ja(h+28),d.K=d.ja(h+30),d.J=d.ja(h+32),d.pa.load(d.ja(h+34)),d.Fa.load(d.ja(h+40)),ze(d,d.ja(h+14),d.ja(h+36)),b=38,g=26,a.Cb>>0)+1)}; +function be(a,b,c,d){void 0===c&&(c=!!(a.Lb.ra&1));a.ed=!1;if(c)if(a.load=a.ng,a.Aj=a.an,a.Bb=a.$i,a.Ub=a.bj,void 0===d&&(d=!!(a.Lb.P&131072)),d)a.load=a.H,a.Bb=a.D,a.Ub=a.F,a.Cb=a.qc=3,a.X=2,a.R=a.xa=65535,a.Sa=65535,a.Nb=a.Sa+1,a.Lc=a.X,a.Ob=-1,a.Ne=!1;else{if(!(a.T&-4))a.Bb=a.fg,a.Ub=a.hg;else if(a.type&4096){6144==(a.type&6656)&&(a.Bb=a.fg);if(a.type&2048||!(a.type&512))a.Ub=a.hg;1024==(a.type&3072)&&(a.Bb==a.$i&&(a.Bb=a.sl),a.Ub==a.bj&&(a.Ub=a.tl),a.ed=!0);b&&a.id>13,80386>a.Lb.da||!(a.ext&64)?(a.X=2,a.R=65535):(a.X=4,a.R=-1),a.Lc=a.X,a.xa=a.R)}else a.load=a.kh,a.Aj=a.bn,a.Bb=a.gg,a.Ub=a.gg,a.Cb=a.qc=0,a.Ob=-1,a.Ne=!1}var ke=1,we=2,ge=3,ie=4,fe=6,de=1; +function Ae(a){var b=+a.model||8088;switch(b){default:var c=4772727;break;case 80286:c=6E6;break;case 80386:c=16E6}yd.call(this,a,c);this.da=b;a=a.stepping;this.Qd=b+(a?qa(a,16):0);this.Xi=61442;this.Pd=1792;this.Pi=28672;this.Qf=4;this.Ra=255;this.B=80286<=this.da?Xb:Wb;this.wa=Be;this.fj=Ce;this.jj=De;this.oj=Ee;if(80186<=this.da&&(this.wa=Be.slice(),this.fj=Ce.slice(),this.jj=De.slice(),this.Ra=31,this.wa[15]=Ie,this.wa[96]=Je,this.wa[97]=Ke,this.wa[98]=Le,this.wa[99]=Ie,this.wa[100]=Ie,this.wa[101]= +Ie,this.wa[102]=Ie,this.wa[103]=Ie,this.wa[104]=Me,this.wa[105]=Ne,this.wa[106]=Oe,this.wa[107]=Pe,this.wa[108]=Qe,this.wa[109]=Re,this.wa[110]=Se,this.wa[111]=Te,this.wa[192]=Ue,this.wa[193]=Ve,this.wa[200]=We,this.wa[201]=Xe,this.wa[241]=Ye,this.fj[7]=Ze,this.jj[7]=Ze,80286<=this.da)){this.Xi=2;this.Pd|=28672;this.Qf=0;this.wa[15]=$e;this.qd=af.slice();for(b=0;b=this.Qd&&(this.qd[166]=jf,this.qd[167]=nf)}}this.Tf=[];this.Uf=[];this.Wf=0;Dd(this);this.aa.complete=this.aa.gj=!1;this.sj=0;this.sc=this.Z=[];this.lb=this.Lg=this.Fb=this.Rf=this.df=this.ef=this.bd=0;of(this)}ia(Ae,yd);function pf(a,b,c,d){md((d?a.sc:a.Z)[b>>>a.lb],c);d&&uc(a)} +function qf(a){var b;if(a.Z===a.sc){a.Z=Array(a.Rf);a.Vf=new w(null,0,0,ed,null,a);pc(a.Vf,a.ca);for(b=0;b>>20,f=a.sc[(a.wc+e&a.ef)>>>a.lb],g=f.Nd(e);if(!(g&1))return d||sf.call(a,b,!1,c),a.ff;if(!(g&4)&&3==a.Pa)return d||sf.call(a,b,!0,c),a.ff;var h=(b&4190208)>>>10;g=a.sc[((g&-4096)+h&a.ef)>>>a.lb];var k=g.Nd(h);if(!(k&1))return d||sf.call(a,b,!1,c),a.ff;if(!(k&4)&&3==a.Pa)return d||sf.call(a,b,!0,c),a.ff;c=a.sc[((k&-4096)+(b&4095)&a.ef)>>>a.lb];if(d)return c;d=b>>>a.lb;k=a.Z[d];b&=-4096;if(0>2;b.qb=g;b.B=h>>2;Vb&&Hc&&c.W&&!c.controller&&!c.Fe&&!c.Ge?(b.Qa=c.Qa,b.Td=c.Td,b.W=c.W,Cc(b,xd)):(b.F=c?wd(32):0,b.J=c?wd(96):0,Cc(b,hd));pc(b,a.ca,k);a.Z[d]=b;a.Sf.push(d);return b}function tf(a){a.Z!==a.sc&&(a.Z=a.sc,a.Vf=null,a.Sf=null,a.ff=null)}l=Ae.prototype;l.reset=function(){of(this);Dd(this);this.aa.error=!1}; +function uf(a,b){switch(b){case 0:var c=a.D;break;case 1:c=a.I;break;case 2:c=a.L;break;case 3:c=a.H;break;case 4:c=y(a);break;case 5:c=a.N;break;case 6:c=a.K;break;case 7:c=a.J}return c}function vf(a,b,c){switch(b){case 0:a.D=c;break;case 1:a.I=c;break;case 2:a.L=c;break;case 3:a.H=c;break;case 4:ne(a,c);break;case 5:a.N=c;break;case 6:a.K=c;break;case 7:a.J=c}} +function of(a){a.D=0;a.H=0;a.I=0;a.L=0;a.Ac=0;a.N=0;a.K=0;a.J=0;a.vc=!1;a.Ea=a.cb=0;a.Ym=[0,0];a.en=[0,0];a.Aa=0;a.pj=0;a.fa=0;a.ra=65520;a.Qb=0;a.$c=1023;a.P=a.lc=0;a.ze=a.gf=a.Sd=a.Ae=0;a.Sc=-1;a.nd=a.Tc=-1;a.od=a.ta=-1;a.ba=new Zd(a,ke,"CS");a.Fa=new Zd(a,we,"DS");a.pa=new Zd(a,we,"ES");a.U=new Zd(a,ge,"SS");ne(a,0);me(a,0);if(80386<=a.da){switch(a.Qd){case 80562:case 80563:a.L=771;break;case 80578:a.L=772;break;case 80594:a.L=773;break;case 80595:case 80596:a.L=776}a.ra=16;a.Mg=0;a.pd=0;a.wc= +0;a.Rb=[0,0,0,0,null,null,0,0];a.Yf=[null,null,null,null,null,null,0,0];a.Ka=new Zd(a,we,"FS");a.La=new Zd(a,we,"GS");tf(a)}a.Ig=new Zd(a,0,"NULL");a.Ga=a.Fa;a.Sb=a.U;a.M=a.ha=0;a.C=a.F=-1;a.Ia=a.Ig;a.ab=0;if(80286>a.da)ze(a,0,65535);else{a.Kb=0;a.Jc=65535;a.Gb=new Zd(a,5,"LDT",!0);a.ka=new Zd(a,ie,"TSS",!0);a.zb=new Zd(a,fe,"VER",!0);ze(a,65520,61440);var b=z(a);var c=a.ba;var d=-65536;80386>c.Lb.da&&(d&=16777215);c=c.ua=d;a.ea=c+b|0;a.Ng=(c>>>0)+(a.ba.Sa>>>0)+1}ye(a,0);pe(a)} +function Bf(a){2==a.Lc?(a.Vb=a.ja,a.kc=Cf,a.uc=Df,a.kd=Ef,2==a.X?(a.la=Ff,a.Ba=Gf,a.mb=Hf):(a.la=If,a.Ba=Jf,a.mb=Kf)):(a.Vb=a.ia,a.kc=Lf,a.uc=Mf,a.kd=Nf,2==a.X?(a.la=Of,a.Ba=Pf,a.mb=Qf):(a.la=Rf,a.Ba=Sf,a.mb=Tf))}function qe(a,b){a.X!=b&&(a.ha|=1024,a.X=b,a.R=2==b?65535:-1,Uf(a))}function Uf(a){2==a.X?(a.Hb=32768,a.nb=a.ja,a.fc=a.ib,2==a.Lc?(a.la=Ff,a.Ba=Gf,a.mb=Hf):(a.la=Of,a.Ba=Pf,a.mb=Qf)):(a.Hb=-2147483648,a.nb=a.ia,a.fc=a.eb,2==a.Lc?(a.la=If,a.Ba=Jf,a.mb=Kf):(a.la=Rf,a.Ba=Sf,a.mb=Tf))} +function Vf(a){a.Lc=a.ba.Lc;a.xa=a.ba.xa;Bf(a);a.X=a.ba.X;a.R=a.ba.R;Uf(a);a.ha&=-3073}l.qj=function(){var a=this.D+this.H+this.I+this.L+y(this)+this.N+this.K+this.J|0;return a=a+z(this)+this.ba.T+this.Fa.T+this.U.T+this.pa.T+xe(this)|0};function Wf(a,b,c){void 0===a.Tf[b]&&(a.Tf[b]=[]);a.Tf[b].push(c)}function Xf(a,b,c){c&&(null==a.Uf[b]&&a.Wf++,a.Uf[b]=c)}function Yf(a,b){var c=a.Uf[b];null!=c&&(c(--a.Wf),delete a.Uf[b])} +function Zf(a,b){for(var c=a.Rb[7],d=c>>16,e=0;4>e;e++){if(c&3){var f=!!(d&1),g=a.Rb[e];g&=~(d>>2&3);b?a.Z[g>>>a.lb].rd(g&a.Fb,f,a):md(a.Z[g>>>a.lb],f)}c>>=2;d>>=4}}function od(a,b,c,d){if(!(a.M&8192)&&a.Rb[7]&255){c--;var e=a.Rb[7],f=e>>16;d=d?1:0==d?3:0;for(var g=0;4>g;g++){if(e&3&&(f&3)==d){var h=f>>2;if(b+c>=a.Rb[g]&&b<=a.Rb[g]+h){a.Rb[6]|=1<>=2;f>>=4}}} +function pe(a,b,c){void 0===b&&(b=!!(a.ra&1));void 0===c&&(c=!!(a.P&131072));a.oj=b&&!c?$f:Ee;be(a.ba,!1,b,c);be(a.Fa,!1,b,c);be(a.U,!1,b,c);be(a.pa,!1,b,c);80386<=a.da&&(be(a.Ka,!1,b,c),be(a.La,!1,b,c));Vf(a)} +l.save=function(a){var b=new ag(this);b.set(0,[this.D,this.H,this.I,this.L,y(this),this.N,this.K,this.J]);var c=z(this),d=this.ba.save(),e=this.Fa.save(),f=this.U.save(),g=this.pa.save();if(null!=this.Kb){var h=[this.ra,this.Kb,this.Jc,this.Qb,this.$c,this.Gb.save(),this.ka.save(),this.lc];80386<=this.da&&(h.push(this.Mg),h.push(this.pd),h.push(this.wc),h.push(this.Rb),h.push(this.Yf))}else h=null;c=[c,d,e,f,g,h,xe(this)];80386<=this.da&&(c.push(this.Ka.save()),c.push(this.La.save()));b.set(1,c); +b.set(2,[this.Ga.hc,this.Sb.hc,this.M,this.ha,this.ab,this.C,this.F]);b.set(3,[0,this.Fd,this.Y.Ad,a,Rd(this)]);b.set(4,Nc(this.oa,!!(this.ra&-2147483648)));return b.data()}; +l.restore=function(a){var b=a[0];this.D=b[0];this.H=b[1];this.I=b[2];this.L=b[3];var c=b[4];this.N=b[5];this.K=b[6];this.J=b[7];b=a[1];this.ba.restore(b[1]);this.Fa.restore(b[2]);this.U.restore(b[3]);this.pa.restore(b[4]);var d=b[5];d&&d.length&&(this.ra=d[0],this.Kb=d[1],this.Jc=d[2],this.Qb=d[3],this.$c=d[4],this.Gb.restore(d[5]),this.ka.restore(d[6]),this.lc=d[7],80386<=this.da&&(this.Mg=d[8],this.pd=d[9],this.wc=d[10],this.Rb=d[11],this.Yf=d[12]),pe(this));ye(this,b[6]);d=!1;a:{var e=this.oa; +var f=a[4],g;for(g=0;g>>0)+(a.ba.Sa>>>0)+1;a.Pa=a.ba.Cb;Vf(a)} +function ze(a,b,c,d){var e=a.ba;e.Hf=b;e.C=d;b=e.load(c);return-1!==b?(dg(a,b+(a.ba.Hf&a.ba.R)),a.ba.Ne):null}function eg(a,b){var c=(a.ea>>>0)+b;c>a.Ng&&(8088>=a.da?(c=a.ba.ua+(c-a.Ng&a.R),2==b&&(a.M|=8)):x.call(a,13,0));return c|0}function fg(a){a.ea=a.od}function y(a){return a.Ac&~a.U.xa|a.Ca-a.U.ua}function ne(a,b){a.Ac=b;a.Ca=a.U.ua+(b&a.U.xa)|0} +function gg(a,b,c,d,e,f){if(63!=(e&63)&&e!=a.resultType){var g=(e^a.resultType)&a.resultType;g&&(g&1&&hg(a),g&2&&ig(a),g&4&&jg(a),g&8&&kg(a),g&16&&lg(a),g&32&&mg(a))}f?(a.ze=d,a.Sd=b):(a.ze=b,a.Sd=d);a.gf=c;a.Ae=d;a.resultType=e}function ng(a,b,c,d,e){a.resultType=c|26;a.Ae=b;d?og(a):pg(a);e?qg(a):rg(a);return b}function sg(a,b,c,d){c&d?og(a):pg(a);(b^c)&d?qg(a):rg(a)}function tg(a){return hg(a)?1:0} +function hg(a){a.resultType&1&&(a.P&=-2,(a.ze^(a.ze^a.gf)&(a.gf^a.Sd))&a.resultType&-2147450752&&(a.P|=1),a.resultType&=-2);return a.P&1}function ig(a){a.resultType&2&&(a.P&=-5,38505>>((a.Ae^a.Ae>>4)&15)&1&&(a.P|=4),a.resultType&=-3);return a.P&4}function jg(a){a.resultType&4&&(a.P&=-17,(a.Sd^a.ze^a.gf)&16&&(a.P|=16),a.resultType&=-5);return a.P&16}function kg(a){a.resultType&8&&(a.P&=-65,a.Ae&((a.resultType&-2147450752)-1|a.resultType&-2147450752)||(a.P|=64),a.resultType&=-9);return a.P&64} +function lg(a){a.resultType&16&&(a.P&=-129,a.Ae&a.resultType&-2147450752&&(a.P|=128),a.resultType&=-17);return a.P&128}function mg(a){a.resultType&32&&(a.P&=-2049,(a.ze^a.Sd)&(a.gf^a.Sd)&a.resultType&-2147450752&&(a.P|=2048),a.resultType&=-33);return a.P&2048}function pg(a){a.resultType&=-2;a.P&=-2}function ug(a){a.resultType&=-5;a.P&=-17}function vg(a){a.resultType&=-9;a.P&=-65}function rg(a){a.resultType&=-33;a.P&=-2049}function og(a){a.resultType&=-2;a.P|=1} +function wg(a){a.resultType&=-5;a.P|=16}function xg(a){a.resultType&=-9;a.P|=64}function qg(a){a.resultType&=-33;a.P|=2048}function xe(a){return a.P&-2262|hg(a)|ig(a)|jg(a)|kg(a)|lg(a)|mg(a)}function yg(a,b){b|=a.ra&1|65520;a.ra=a.ra&-65536|b&65535;a.ra&1&&pe(a,!0)}function ye(a,b,c){a.ra&1||(b&=~a.Pi);void 0===c&&(c=a.Pa);c?b=b&-12289|a.P&12288:a.lc=(b&12288)>>12;c>a.lc&&(b=b&-513|a.P&512);a.resultType=128;a.P=a.P&~(a.Pd|2261)|b&(a.Pd|2261)|a.Xi;a.P&256&&(a.ab|=2,a.M|=4)} +function zg(a,b,c,d){var e=0;if(a.ra&1&&(a.Pa>a.lc||a.P&131072)&&a.ka.Qi){var f=a.ka.Qi+(b>>>3);for(e=(1<>>=8,f++}return e?(r(a,256)&&Tb(a,"checkIOPM("+wa(b)+","+c+","+(d?"input":"output")+"): trapped",!0,!0),x.call(a,13,0),!1):!0} +l.Eb=function(a,b,c){switch(b){case "EAX":case "EBX":case "ECX":case "EDX":case "ESP":case "EBP":case "ESI":case "EDI":case "EIP":case "AX":case "BX":case "CX":case "DX":case "SP":case "BP":case "SI":case "DI":case "IP":case "PC":case "CS":case "DS":case "SS":case "ES":case "FS":case "GS":case "CR0":case "CR2":case "CR3":case "PS":case "C":case "P":case "A":case "Z":case "S":case "T":case "I":case "D":case "V":this.ma[b]=c;this.sj++;a=!0;break;default:a=yd.prototype.Eb.call(this,a,b,c)}return a}; +function Ag(a,b,c,d){var e=(d?a.sc:a.Z)[(b&a.bd)>>>a.lb];e&&e.type==ed&&(e=qd(a,b,!1,!0));if(e){var f=b&a.Fb;if(!c||1==c)return e.ae(f,b);if(2==c)return f>>this.lb].Cc(a&this.Fb,a)}; +l.ja=function(a){var b=a&this.Fb,c=(a&this.bd)>>>this.lb;this.A-=this.B.wg;if(b>>this.lb;if(b>>this.lb].Ec(a&this.Fb,b&255,a)}; +l.ib=function(a,b){var c=a&this.Fb,d=(a&this.bd)>>>this.lb;this.A-=this.B.wg;c>8&255,a+1))};l.eb=function(a,b){var c=a&this.Fb,d=(a&this.bd)>>>this.lb;this.A-=this.B.wg;if(c>>=8}};function Bg(a,b,c){a.Ia=b;a.vb=c&a.xa;a.C=b.Bb(a.vb,1);return a.M&1?0:a.ya(a.C)} +function D(a,b){return Bg(a,a.Ga,b)}function Cg(a,b){return Bg(a,a.Sb,b)}function Dg(a,b,c){a.Ia=b;a.vb=c&a.xa;a.C=b.Bb(a.vb,a.X);if(a.M&9){if(a.M&1)return 0;a=a.ya(a.C)|a.ya(b.Bb(0,1))<<8}else a=a.nb(a.C);return a}function E(a,b){a.Ia=a.Ga;a.vb=b&a.xa;a.C=a.Ia.Bb(a.vb,2);if(a.M&9){if(a.M&1)return 0;b=a.ya(a.C)|a.ya(a.Ia.Bb(0,1))<<8;a.M&=-9}else b=a.ja(a.C);return b} +function Eg(a,b){a.Ia=a.Sb;a.vb=b&a.xa;a.C=a.Ia.Bb(a.vb,2);if(a.M&9){if(a.M&1)return 0;b=a.ya(a.C)|a.ya(a.Ia.Bb(0,1))<<8;a.M&=-9}else b=a.ja(a.C);return b}function F(a,b){a.Ia=a.Ga;a.vb=b&a.xa;a.C=a.Ia.Bb(a.vb,4);return a.M&1?0:a.ia(a.C)}function Hg(a,b){a.Ia=a.Sb;a.vb=b&a.xa;a.C=a.Ia.Bb(a.vb,4);return a.M&1?0:a.ia(a.C)}function Ig(a,b){a.M&2||a.ub(a.Ia.Ub(a.vb,1),b)}function Jg(a,b){if(!(a.M&2)){var c=a.Ia.Ub(a.vb,2);a.M&8?(a.ub(c,b),a.ub(a.Ia.Ub(0,1),b>>8),a.M&=-9):a.ib(c,b)}} +function Kg(a,b){a.M&2||a.eb(a.Ia.Ub(a.vb,4),b)}function re(a,b,c){c=b.Bb(c,a.X);a.M&8?(b=a.ya(c)|a.ya(b.Bb(0,1))<<8,a.M&=-9):b=a.nb(c);return b}function Lg(a,b,c,d){c=b.Ub(c,a.X);a.M&8?(a.ub(c,d),a.ub(b.Ub(0,1),d>>8),a.M&=-9):a.fc(c,d)}l.sa=function(){var a=eg(this,1),b=this.ya(this.ea);this.ea=a;return b};function Mg(a){var b=eg(a,2);if(a.M&8){var c=a.ya(a.ea)|a.ya(b-1)<<8;a.M&=-9}else c=a.ja(a.ea);a.ea=b;return c} +function K(a){var b=eg(a,a.Lc);if(a.M&8){var c=a.ya(a.ea)|a.ya(b-1)<<8;a.M&=-9}else c=a.Vb(a.ea);a.ea=b;return c}l.Ha=function(){var a=eg(this,this.X);if(this.M&8){var b=this.ya(this.ea)|this.ya(a-1)<<8;this.M&=-9}else b=this.nb(this.ea);this.ea=a;return b};l.S=function(){var a=eg(this,1),b=this.ya(this.ea)<<24>>24;this.ea=a;return b}; +function le(a){var b=a.nb(a.Ca);a.Ca=a.Ca+a.X|0;var c=(a.Og>>>0)-(a.Ca>>>0);0>c&&(8088>=a.da?(ne(a,a.Ca-a.U.ua&a.U.xa),-1>c&&(b=b&255|a.ya(a.Ca-1)<<8)):-1>c?x.call(a,12,0):(!a.U.ed&&a.U.Sa==a.U.xa||a.U.ed&&!a.U.Sa)&&ne(a,a.Ca-a.U.ua&a.U.xa));return b}function ve(a,b){se(a,b,a.X)} +function se(a,b,c,d){d=void 0===d?c:d;var e=a.Ca-c|0,f=(e>>>0)-(a.xj>>>0);if(0>f){if(8088>=a.da&&-1==f){a.ub(e+1,b>>8);ne(a,e-a.U.ua&a.U.xa);a.ub(a.Ca,b);return}if(!a.U.ed&&a.U.Sa==a.U.xa||a.U.ed&&!a.U.Sa){if(f>-c){x.call(a,12,0);return}ne(a,e-a.U.ua&a.U.xa);e=a.Ca}else{x.call(a,12,0);return}}switch(d){case 1:a.ub(e,b);break;case 2:a.ib(e,b);break;case 4:a.eb(e,b)}a.Ca=e} +function Ng(a,b,c){var d=4;1==b.length&&(d=1,c=c?1:0);if(80386>a.da)2this.da?0:1;for(var e=0;2>e;e++){switch(d){case 0:if(this.ab&1&&this.P&512){var f=Pg(this.V);if(-1<=f&&(this.ab&=-2,0<=f)){this.ab&=-5; +Qg.call(this,f);d=!0;break a}}break;case 1:if(this.ab&2){this.ab&=-3;80386<=this.da&&(this.Rb[6]|=16384);Qg.call(this,1);d=!0;break a}}d=1-d}}d=!1}if(d&&!a){this.O("interrupt dispatched");this.M=0;break}if(this.ab&4){this.M=this.A=0;break}}if(b){if(Rg(this.ca,this.ea,c)){Gd(this);break}c=1}this.M=0;this.wa[this.sa()].call(this)}while(0>11;Wg(this);Xg(this,a[b++]);for(c=0;c=Yg&&Zg(a,lh))}function Wg(a){a.ga&=-129;a.ga&~a.bc&63&&(a.ga|=128);if(a.ga&128&&!(a.bc&128))return a=a.V,a.da>=Yg?mh(a,lh):a.fa&nh||Qg.call(a.G,2),!0;a=a.V;a.da>=Yg&&Zg(a,lh);return!1}function oh(a,b){80387<=a.da||(b&=-65);a.ga|=b;return Wg(a)} +function Ug(a){return a.ga|a.B<<11}function ph(a,b){return isFinite(b)?!0:!oh(a,Infinity===b?8:16)}function qh(a,b,c){var d=null;null!=b&&null!=c&&(d=b+c,ph(a,d)||(d=null));return d}function rh(a,b,c){var d=null;null!=b&&null!=c&&(d=b-c,ph(a,d)||(d=null));return d}function sh(a,b,c){var d=null;null!=b&&null!=c&&(d=b*c,ph(a,d)||(d=null));return d}function th(a,b,c){var d=null;null==b||null==c||!c&&oh(a,2)||(d=b/c,ph(a,d)||(d=null));return d} +function uh(a,b,c){if(null!=b&&null!=c){var d=0;isNaN(b)||isNaN(c)?d=17664:(b-=c,0>b?d=256:0===b&&(d=16384));a.ga=a.ga&-18177|d;return!0}return!1}function vh(a,b,c){if(null==b)return null;var d=a.bc&3072;0==d?(d=Math.round(b),.5===d-b&&d%2&&d--):d=1024==d||3072==d&&0=c){if(oh(a,1))return null;d=-c}else if(d<-c){if(oh(a,1))return null;d=-c}a.H[0]=d|0;2147483648d&&(a.H[1]=-1))}return d} +function wh(a,b){var c=3;a.C&1<=c;c<<=1)3!=(b&3)&&(a.C|=c),b>>=2}function xh(a){var b=a.B+0&7;return a.C&1<>16}function Ch(a){return a.G.ia(a.G.C)}function Dh(a){a.ha[0]=a.G.ia(a.G.C);return a.Z[0]}function Eh(a){a.H[0]=a.G.ia(a.G.C);a.H[1]=a.G.ia(a.G.C+4);return a.K[0]} +function Fh(a){a.D[0]=a.G.ia(a.G.C);a.D[1]=a.G.ia(a.G.C+4);a.D[2]=a.G.ja(a.G.C+8);return a.D}l.ji=function(){this.G.eb(this.G.C,this.H[0])};l.Xk=function(){this.G.eb(this.G.C,this.H[0]);this.G.eb(this.G.C+4,this.H[1])};function Gh(a){a.G.eb(a.G.C,a.D[0]);a.G.eb(a.G.C+4,a.D[1]);a.G.ib(a.G.C+8,a.D[2])}function Hh(a,b){var c=b[1],d=(b[2]&32768)>>4,e=b[2]&32767;b=b[0]>>>11|c<<21;c=c>>11&1048575;32767==e?e=2047:e&&(e+=-15360,0>=e&&(e=2047,b=c=0));a.H[0]=b;a.H[1]=c|(d|e)<<20;return a.K[0]} +function Ah(a,b,c){var d=c>>20&2047,e=2147483648|(c&1048575)<<11|b>>>21;2047==d?d=32767:d?d+=15360:e&=2147483647;a.D[0]=b<<11;a.D[1]=e;a.D[2]=c>>16&32768|d;return a.D}function Ih(a,b){for(var c=0,d=1;b--;)c+=(a&15)*d,d*=10,a>>=4;return c}function Jh(a,b){for(var c=0,d=0;b--;)c|=a%10<>11;Wg(a);Xg(a,c.nb(b+=c.X));!(c.ra&1)||c.P&131072?(a.I=c.nb(b+=c.X),d=c.nb(b+=c.X),a.P=d&2047,a.I|=(d&-4096)<<4,a.M=-1,a.J=c.nb(b+=c.X),a.J|=(c.nb(b+=c.X)&-4096)<<4,a.N=-1):(a.I=c.nb(b+=c.X),d=c.nb(b+=c.X),a.M=d&65535,a.P=d>>16&2047,a.J=c.nb(b+=c.X),a.N=c.nb(b+=c.X)&65535);return b+c.X} +function Nh(a,b){var c=a.G;c.fc(b,a.bc);c.fc(b+=c.X,Ug(a));c.fc(b+=c.X,Vg(a));if(!(c.ra&1)||c.P&131072){var d=(a.M<<4)+a.I;c.fc(b+=c.X,d);c.fc(b+=c.X,d>>4&-4096|a.P);d=(a.N<<4)+a.J;c.fc(b+=c.X,d);c.fc(b+=c.X,d>>4&-4096)}else c.fc(b+=c.X,a.I),c.fc(b+=c.X,a.M|a.P<<16),c.fc(b+=c.X,a.J),c.fc(b+=c.X,a.N);return b+c.X}function Oh(){this.ga&=-32896;Wg(this)}function Ph(){uh(this,L(this,0),L(this,this.A))}function Qh(){uh(this,L(this,0),L(this,this.A))&&Kh(this)}function Rh(){Qh.call(this)} +function Sh(){M(this,0,th(this,L(this,0),Dh(this)))}function Th(){this.C&=~(1<>20&2047)-1023),this.H[1]=(this.H[1]|1072693248)&-1073741825,Lh(this,this.K[0]))},102:function(){this.B=this.B-1&7;this.ga&=-513},103:function(){this.B= +this.B+1&7;this.ga&=-513},112:function(){M(this,0,L(this,0)%L(this,1))},113:function(){M(this,1,L(this,1)*Math.log(L(this,0)+1)/Math.LN2)&&Kh(this)},114:function(){var a=L(this,0),b=null;if(0<=a||!oh(this,1))b=Math.sqrt(a),ph(this,b)||(b=null);M(this,0,b)},116:function(){M(this,0,vh(this,L(this,0),li))},117:function(){var a=L(this,0),b=L(this,1);null!=a&&null!=b&&M(this,0,a*Math.pow(2,0>>0);Lh(this,a)},6:function(){var a=vh(this,Kh(this));null!=a&&(this.D[0]=Jh(a,8),this.D[1]=Jh(a/1E8,8),this.D[2]=Jh(a/1E16,2),0>a&&(this.D[2]|=32768),Gh(this))},7:function(){null!=vh(this,L(this,0),li)&&(this.Xk(),Kh(this))},48:function(){Th.call(this);Kh(this)},49:fi,50:ai,51:ai,52:di}},ni=[Oh,Uh,Vh,Wh,Xh,Yh,bi,Zh,ci,di];cb(function(){for(var a=zb(document,"pcx86","fpu"),b=0;b>16,c=c<<16>>16,d=d<<16>>16);this.A-=this.B.Fj;(bd)&&x.call(this,5);this.M|=2;return a}function wi(a,b){var c=0;if(b){vg(this);for(var d=1;d&this.R;){if(b&d){a=c;break}d<<=1;c++}}else xg(this);this.A-=11+3*c;return a}function xi(a,b){var c=0;if(b){vg(this);for(var d=2==this.X?15:31,e=1<>>=1;c++;d--}}else xg(this);this.A-=11+3*c;return a} +function yi(a,b){a&1<<(b&(2==this.X?15:31))?og(this):pg(this);this.A-=-1===this.C?3:6;this.M|=2;return a}function zi(a,b){b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=-1===this.C?6:8;return a^b}function Ai(a,b){b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=-1===this.C?6:8;return a&~b}function Bi(a,b){b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=-1===this.C?6:8;return a|b} +function Ci(a,b){if(-1===this.C)return yi.call(this,a,b);var c=this.X<<3;if(b>=c||b<-c)a=Dg(this,this.Ia,this.vb+(b>>(2==this.X?4:5))*this.X);b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=6;this.M|=2;return a}function Di(a,b){if(-1===this.C)return zi.call(this,a,b);var c=this.X<<3;if(b>=c||b<-c)a=Dg(this,this.Ia,this.vb+(b>>(2==this.X?4:5))*this.X);b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=8;return a^b} +function Ei(a,b){if(-1===this.C)return Ai.call(this,a,b);var c=this.X<<3;if(b>=c||b<-c)a=Dg(this,this.Ia,this.vb+(b>>(2==this.X?4:5))*this.X);b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=8;return a&~b}function Fi(a,b){if(-1===this.C)return Bi.call(this,a,b);var c=this.X<<3;if(b>=c||b<-c)a=Dg(this,this.Ia,this.vb+(b>>(2==this.X?4:5))*this.X);b=1<<(b&(2==this.X?15:31));a&b?og(this):pg(this);this.A-=8;return a|b} +function Gi(a,b){gg(this,a,b,a-b|0,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.xh:this.B.Mb;this.M|=2;return a}function Hi(a,b){gg(this,a,b,a-b|0,this.Hb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.xh:this.B.Mb;this.M|=2;return a} +function Ii(a){if(this.Kc){var b=this.Kc,c=this.pj,d=this.fa,e=d>>3&7;b.A=d&7;var f=(3>(d>>6&3)?0:48)+e;(217==c||219==c)&&52<=f&&(f=e<<4|b.A);if(e=mi[c][f]){if(0>ni.indexOf(e)){f=b.G;var g=f.od;8087==b.da&&(f.ha&16&&g++,f.ha&32&&g++);b.M=f.ba.T;b.I=g-f.ba.ua;-1!==f.C&&(b.N=f.Ia.T,b.J=f.C-f.Ia.ua);b.P=(c&7)<<8|d}e.call(b)}}this.A-=-1===this.C?2:8;return a}function Ji(a){if(80186>this.da)return Ki.call(this,a);x.call(this,13,0);return a}function Ze(a){x.call(this,6);return a} +function Ki(a){bf.call(this);return a}function Li(a,b){a=Mi.call(this,this.S(),b);80386>this.da&&(this.A-=12);return a}function Ni(a,b){a=this.Ha();a=2==this.X?Mi.call(this,a,b):Oi.call(this,a,b);80386>this.da&&(this.A-=12);return a}function Pi(a,b){var c=!1;0>b&&(b=-b|0,c=!c);0>a&&(a=-a|0,c=!c);Qi.call(this,a,b);c&&(this.Ea=~this.Ea+1|0,this.cb=~this.cb+(this.Ea?0:1)|0)} +function Mi(a,b){a=(a<<16>>16)*(b<<16>>16)|0;32767a?(og(this),qg(this)):(pg(this),rg(this));this.A-=-1===this.C?9:12;return a&65535}function Oi(a,b){Pi.call(this,a,b);this.cb!=this.Ea>>31?(og(this),qg(this)):(pg(this),rg(this));this.A-=-1===this.C?9:12;return this.Ea}function Ri(a,b){this.A-=14+(-1===this.C?0:2);vg(this);-1!==this.zb.load(b)&&this.zb.qc>=this.Pa&&this.zb.qc>=(b&3)&&(xg(this),a=this.zb.ob&-256,2=this.Pa)&&this.zb.qc>=(b&3))return xg(this),this.zb.Sa;vg(this);return a}function Yi(a,b){if(-1===this.C)return bf.call(this),a;me(this,this.ja(this.C+this.X));this.A-=this.B.Ve;return b} +function Zi(a,b){this.A-=-1===this.F?-1===this.C?this.B.pk:this.B.nk:this.B.lk;return b}function $i(a,b){switch(this.fa>>3&7){case 4:this.Aa=this.D;break;case 5:this.Aa=this.I;break;case 6:this.Aa=this.L;break;case 7:this.Aa=this.H}return b}function aj(a,b){return b} +function bj(a,b){a=this.fa>>3&7;switch(a){case 0:this.Aa=this.D;break;case 2:this.Aa=this.L;break;case 3:this.Aa=this.H;break;default:if(80286==this.da||80386==this.da&&4!=a&&5!=a)x.call(this,6);else switch(a){case 1:this.Aa=this.I;break;case 4:this.Aa=y(this);break;case 5:this.Aa=this.N;break;case 6:this.Aa=this.K;break;case 7:this.Aa=this.J}}return Zi.call(this,0,b)} +function cj(a,b){switch(this.fa>>3&7){case 0:b=this.pa.T;break;case 1:b=this.ba.T;break;case 2:b=this.U.T;break;case 3:b=this.Fa.T;break;case 4:if(80386<=this.da){b=this.Ka.T;break}x.call(this,6);b=a;break;case 5:if(80386<=this.da){b=this.La.T;break}default:x.call(this,6),b=a}-1!==this.F&&qe(this,2);return Zi.call(this,0,b)} +function Qi(a,b){if(a&-65536||b&-65536){var c=b&65535;b>>>=16;var d=a&65535;a>>>=16;var e=c*d;d=(e>>>16)+b*d;var f=d>>>16;d=(d&65535)+c*a;this.Ea=d<<16|e&65535;this.cb=f+((d>>>16)+b*a)|0}else this.Ea=a*b|0,this.cb=0}function dj(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return ng(this,a|b,128)}function ej(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return ng(this,a|b,this.Hb)&this.R} +function fj(a,b){var c=a-b-tg(this)|0;gg(this,a,b,c,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return c&255}function gj(a,b){var c=a-b-tg(this)|0;gg(this,a,b,c,this.Hb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return c&this.R}function hj(){return mg(this)?1:0}function rj(){return hg(this)?1:0}function sj(){return hg(this)?0:1}function tj(){return kg(this)?1:0}function uj(){return kg(this)?0:1}function vj(){return hg(this)||kg(this)?1:0} +function wj(){return hg(this)||kg(this)?0:1}function xj(){return lg(this)?1:0}function yj(){return lg(this)?0:1}function zj(){return ig(this)?1:0}function Aj(){return ig(this)?0:1}function Bj(){return!lg(this)!=!mg(this)?1:0}function Cj(){return!lg(this)!=!mg(this)?0:1}function Dj(){return kg(this)||!lg(this)!=!mg(this)?1:0}function Ej(){return kg(this)||!lg(this)!=!mg(this)?0:1}function Fj(a,b){return Gj.call(this,a,b,this.sa())}function Hj(a,b){return Ij.call(this,a,b,this.sa())} +function Jj(a,b){return Gj.call(this,a,b,this.I&31)}function Kj(a,b){return Ij.call(this,a,b,this.I&31)}function Lj(a,b){return Mj.call(this,a,b,this.sa())}function Nj(a,b){return Oj.call(this,a,b,this.sa())}function Pj(a,b){return Mj.call(this,a,b,this.I&31)}function Qj(a,b){return Oj.call(this,a,b,this.I&31)}function Rj(a,b){var c=a-b|0;gg(this,a,b,c,191,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return c&255} +function Sj(a,b){var c=a-b|0;gg(this,a,b,c,this.Hb|63,!0);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return c&this.R}function Tj(a,b){ng(this,a&b,128);this.A-=-1===this.F?-1===this.C?this.B.Zh:this.B.Df:this.B.Df;this.M|=2;return a}function Uj(a,b){ng(this,a&b,this.Hb);this.A-=-1===this.F?-1===this.C?this.B.Zh:this.B.Df:this.B.Df;this.M|=2;return a}function Vj(a,b){var c=this.D&this.R,d=(1<<(this.I&31))-1;return a&~(d<>(this.D&this.R)&(1<<(this.I&31))-1&this.R}function Xj(a,b){if(-1===this.C){switch(this.fa&7){case 0:this.D=this.D&-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.H=this.H&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.H=this.H&-65281|a<<8}this.A-=this.B.ai}else this.F=this.C,Ig(this,a),this.A-=this.B.$h;return b} +function Yj(a,b){if(-1===this.C){switch(this.fa&7){case 0:this.D=this.D&~this.R|a;break;case 1:this.I=this.I&~this.R|a;break;case 2:this.L=this.L&~this.R|a;break;case 3:this.H=this.H&~this.R|a;break;case 4:ne(this,y(this)&~this.R|a);break;case 5:this.N=this.H&~this.R|a;break;case 6:this.K=this.K&~this.R|a;break;case 7:this.J=this.J&~this.R|a}this.A-=this.B.ai}else{this.F=this.C;if(!(this.M&2)){var c=this.Ia.Ub(this.vb,this.X);this.M&8?(this.ub(c,a),this.ub(this.Ia.Ub(0,1),a>>8),this.M&=-9):this.fc(c, +a)}this.A-=this.B.$h}return b}function Zj(a,b){a^=b;ng(this,a,128);this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return a}function ak(a,b){this.A-=-1===this.F?-1===this.C?this.B.mc:this.B.Mb:this.B.Bc;return ng(this,a^b,this.Hb)&this.R}function bk(a,b){var c=a[1]-b[1];c||(c=a[0]-b[0]);return c}function ck(a){var b=a-1|0;gg(this,a,1,b,this.Hb|62,!0);this.A-=2;return a&~this.R|b&this.R} +function dk(a,b,c){c>>>=0;if(!c||c<=b>>>0)return!1;var d=0,e=1,f=this.Ym;f[0]=c>>>0;f[1]=0;c=this.en;c[0]=a>>>0;for(c[1]=b>>>0;0>>=0,a[1]++),e+=e;do 0<=bk(c,f)&&(a=c,b=f,a[0]-=b[0],a[1]-=b[1],0>a[0]&&(a[0]>>>=0,a[1]--),d+=e),a=f,a[0]>>>=1,a[1]&1&&(a[0]=(a[0]|2147483648)>>>0),a[1]>>>=1,e/=2;while(1<=e);this.Ea=d;this.cb=c[0];return!0}function ek(a){var b=a+1|0;gg(this,a,1,b,this.Hb|62);this.A-=2;return a&~this.R|b&this.R} +function fk(a){this.ra=a;pe(this);this.ra&-2147483648?qf(this):tf(this)}function gk(a){this.M|=1;this.uc.call(this,a);this.A-=-1===this.C?4:5}function Gj(a,b,c){if(c){16>>16-c)&65535;ng(this,a,32768,d&32768)}return a}function Ij(a,b,c){if(c){var d=a<>>32-c;ng(this,a,-2147483648,d&-2147483648)}return a}function Mj(a,b,c){if(c){16>>c-1;a=(d>>>1|b<<16-c)&65535;ng(this,a,32768,d&1)}return a} +function Oj(a,b,c){if(c){var d=a>>>c-1;a=d>>>1|b<<32-c;ng(this,a,-2147483648,d&1)}return a}function hk(){this.A-=-1===this.C?2:this.B.Ck;return 1}function ik(){var a=this.I&255;this.A-=(-1===this.C?this.B.Sh:this.B.Rh)+(a<this.Sc?(-1!=this.nd&&(this.nd!==this.ba.T&&(this.ba.Cb=this.nd&3,cg(this,this.nd)),this.nd=-1),this.od!==this.ea&&dg(this,this.od),-1!=this.Tc&&(this.Tc!==this.U.T&&me(this,this.Tc),this.Tc=-1),-1!==this.ta&&(this.ta!==this.Ca&&ne(this,this.Ac&~this.U.xa|this.ta-this.U.ua),this.ta=-1)):8!=this.Sc?(b=0,a=8):(b=0,a=-1,of(this),e=d=!1)):dg(this,this.od);var f=a,g=b,h=32,k=Ag(this,this.ea);204!=k||this.$c||(d=!1);this.P&131072&&(6== +f&&99==k||13==f&&205==k)&&(d=!1);!1===d&&(h|=1);983040<=this.ea&&1048575>=this.ea&&(d=!1);r(this,h|-2147483648)&&(d=!0);if(r(this,h)||d){var m=this.aa.Xa;f="Fault "+va(f)+(null!=g?" ("+wa(g)+")":"")+" on opcode "+va(k);d&&m&&(f+=" (blocked)");this.ca?(Tb(this,f,d||h,!0),d&&(d=m,rk(this.ca))):(this.Da(f),Gd(this))}if(d&&e)throw-1;if(e)throw this.Sc=a,nk.call(this,a,b,c),this.od=this.ea,this.M=1==a?this.M|8192:this.M|4096,a;} +function sf(a,b,c){this.pd=a;a=0;b&&(a|=1);c&&(a|=2);3==this.Pa&&(a|=4);x.call(this,14,a)}function pk(a){var b=a.ob&7680;a.T&65528&&(6144==b||7168==b||7168>b&&a.qc>8&255;break;case 197:b=this.I>>8&255;break;case 198:b=this.L>>8&255;break;case 199:b=this.H>>8&255;break;default:b=0}var c=this.fa>>3&7;switch(c){case 0:var d=this.D&255;break;case 1:d=this.I&255;break;case 2:d=this.L&255;break;case 3:d=this.H&255;break;case 4:d=this.D>>8&255;break;case 5:d=this.I>>8&255;break;case 6:d=this.L>>8&255;break;case 7:d=this.H>>8&255;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.D=this.D& +-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.H=this.H&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.H=this.H&-65281|a<<8}} +function Df(a){var b=(this.fa=this.sa())&199;switch(b){case 0:var c=D(this,this.H+this.K);this.F=this.C;break;case 1:c=D(this,this.H+this.J);this.F=this.C;break;case 2:c=Cg(this,this.N+this.K);this.F=this.C;break;case 3:c=Cg(this,this.N+this.J);this.F=this.C;break;case 4:c=D(this,this.K);this.F=this.C;break;case 5:c=D(this,this.J);this.F=this.C;break;case 6:c=D(this,K(this));this.F=this.C;break;case 7:c=D(this,this.H);this.F=this.C;break;case 64:c=D(this,this.H+this.K+this.S());this.F=this.C;break; +case 65:c=D(this,this.H+this.J+this.S());this.F=this.C;break;case 66:c=Cg(this,this.N+this.K+this.S());this.F=this.C;break;case 67:c=Cg(this,this.N+this.J+this.S());this.F=this.C;break;case 68:c=D(this,this.K+this.S());this.F=this.C;break;case 69:c=D(this,this.J+this.S());this.F=this.C;break;case 70:c=Cg(this,this.N+this.S());this.F=this.C;break;case 71:c=D(this,this.H+this.S());this.F=this.C;break;case 128:c=D(this,this.H+this.K+K(this));this.F=this.C;break;case 129:c=D(this,this.H+this.J+K(this)); +this.F=this.C;break;case 130:c=Cg(this,this.N+this.K+K(this));this.F=this.C;break;case 131:c=Cg(this,this.N+this.J+K(this));this.F=this.C;break;case 132:c=D(this,this.K+K(this));this.F=this.C;break;case 133:c=D(this,this.J+K(this));this.F=this.C;break;case 134:c=Cg(this,this.N+K(this));this.F=this.C;break;case 135:c=D(this,this.H+K(this));this.F=this.C;break;case 192:c=this.D&255;break;case 193:c=this.I&255;break;case 194:c=this.L&255;break;case 195:c=this.H&255;break;case 196:c=this.D>>8&255;break; +case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c=this.H>>8&255;break;default:c=0}switch(this.fa>>3&7){case 0:var d=this.D&255;break;case 1:d=this.I&255;break;case 2:d=this.L&255;break;case 3:d=this.H&255;break;case 4:d=this.D>>8&255;break;case 5:d=this.I>>8&255;break;case 6:d=this.L>>8&255;break;case 7:d=this.H>>8&255;break;default:d=0}a=a.call(this,c,d);switch(b){case 0:case 3:Ig(this,a);this.A-=this.B.Qc;break;case 1:case 2:Ig(this,a);this.A-=this.B.Rc;break;case 4:case 5:case 7:Ig(this, +a);this.A-=this.B.xc;break;case 6:Ig(this,a);this.A-=this.B.yd;break;case 64:case 67:case 128:case 131:Ig(this,a);this.A-=this.B.Wb;break;case 65:case 66:case 129:case 130:Ig(this,a);this.A-=this.B.Xb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Ig(this,a);this.A-=this.B.Za;break;case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.H=this.H&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I= +this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.H=this.H&-65281|a<<8}} +function Ef(a,b){var c=(this.fa=this.sa())&199;switch(c){case 0:var d=D(this,this.H+this.K);this.F=this.C;break;case 1:d=D(this,this.H+this.J);this.F=this.C;break;case 2:d=Cg(this,this.N+this.K);this.F=this.C;break;case 3:d=Cg(this,this.N+this.J);this.F=this.C;break;case 4:d=D(this,this.K);this.F=this.C;break;case 5:d=D(this,this.J);this.F=this.C;break;case 6:d=D(this,K(this));this.F=this.C;break;case 7:d=D(this,this.H);this.F=this.C;break;case 64:d=D(this,this.H+this.K+this.S());this.F=this.C;break; +case 65:d=D(this,this.H+this.J+this.S());this.F=this.C;break;case 66:d=Cg(this,this.N+this.K+this.S());this.F=this.C;break;case 67:d=Cg(this,this.N+this.J+this.S());this.F=this.C;break;case 68:d=D(this,this.K+this.S());this.F=this.C;break;case 69:d=D(this,this.J+this.S());this.F=this.C;break;case 70:d=Cg(this,this.N+this.S());this.F=this.C;break;case 71:d=D(this,this.H+this.S());this.F=this.C;break;case 128:d=D(this,this.H+this.K+K(this));this.F=this.C;break;case 129:d=D(this,this.H+this.J+K(this)); +this.F=this.C;break;case 130:d=Cg(this,this.N+this.K+K(this));this.F=this.C;break;case 131:d=Cg(this,this.N+this.J+K(this));this.F=this.C;break;case 132:d=D(this,this.K+K(this));this.F=this.C;break;case 133:d=D(this,this.J+K(this));this.F=this.C;break;case 134:d=Cg(this,this.N+K(this));this.F=this.C;break;case 135:d=D(this,this.H+K(this));this.F=this.C;break;case 192:d=this.D&255;break;case 193:d=this.I&255;break;case 194:d=this.L&255;break;case 195:d=this.H&255;break;case 196:d=this.D>>8&255;break; +case 197:d=this.I>>8&255;break;case 198:d=this.L>>8&255;break;case 199:d=this.H>>8&255;break;default:d=0}a=a[this.fa>>3&7].call(this,d,b.call(this));switch(c){case 0:case 3:Ig(this,a);this.A-=this.B.Qc;break;case 1:case 2:Ig(this,a);this.A-=this.B.Rc;break;case 4:case 5:case 7:Ig(this,a);this.A-=this.B.xc;break;case 6:Ig(this,a);this.A-=this.B.yd;break;case 64:case 67:case 128:case 131:Ig(this,a);this.A-=this.B.Wb;break;case 65:case 66:case 129:case 130:Ig(this,a);this.A-=this.B.Xb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Ig(this, +a);this.A-=this.B.Za;break;case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.H=this.H&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I=this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.H=this.H&-65281|a<<8}} +function Ff(a){switch((this.fa=this.sa())&199){case 0:var b=E(this,this.H+this.K);this.A-=this.B.Qc;break;case 1:b=E(this,this.H+this.J);this.A-=this.B.Rc;break;case 2:b=Eg(this,this.N+this.K);this.A-=this.B.Rc;break;case 3:b=Eg(this,this.N+this.J);this.A-=this.B.Qc;break;case 4:b=E(this,this.K);this.A-=this.B.xc;break;case 5:b=E(this,this.J);this.A-=this.B.xc;break;case 6:b=E(this,K(this));this.A-=this.B.yd;break;case 7:b=E(this,this.H);this.A-=this.B.xc;break;case 64:b=E(this,this.H+this.K+this.S()); +this.A-=this.B.Wb;break;case 65:b=E(this,this.H+this.J+this.S());this.A-=this.B.Xb;break;case 66:b=Eg(this,this.N+this.K+this.S());this.A-=this.B.Xb;break;case 67:b=Eg(this,this.N+this.J+this.S());this.A-=this.B.Wb;break;case 68:b=E(this,this.K+this.S());this.A-=this.B.Za;break;case 69:b=E(this,this.J+this.S());this.A-=this.B.Za;break;case 70:b=Eg(this,this.N+this.S());this.A-=this.B.Za;break;case 71:b=E(this,this.H+this.S());this.A-=this.B.Za;break;case 128:b=E(this,this.H+this.K+K(this));this.A-= +this.B.Wb;break;case 129:b=E(this,this.H+this.J+K(this));this.A-=this.B.Xb;break;case 130:b=Eg(this,this.N+this.K+K(this));this.A-=this.B.Xb;break;case 131:b=Eg(this,this.N+this.J+K(this));this.A-=this.B.Wb;break;case 132:b=E(this,this.K+K(this));this.A-=this.B.Za;break;case 133:b=E(this,this.J+K(this));this.A-=this.B.Za;break;case 134:b=Eg(this,this.N+K(this));this.A-=this.B.Za;break;case 135:b=E(this,this.H+K(this));this.A-=this.B.Za;break;case 192:b=this.D&65535;break;case 193:b=this.I&65535;break; +case 194:b=this.L&65535;break;case 195:b=this.H&65535;break;case 196:b=y(this)&65535;break;case 197:b=this.N&65535;break;case 198:b=this.K&65535;break;case 199:b=this.J&65535;break;default:b=0}var c=this.fa>>3&7;switch(c){case 0:var d=this.D&65535;break;case 1:d=this.I&65535;break;case 2:d=this.L&65535;break;case 3:d=this.H&65535;break;case 4:d=y(this)&65535;break;case 5:d=this.N&65535;break;case 6:d=this.K&65535;break;case 7:d=this.J&65535;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.D= +this.D&-65536|a;break;case 1:this.I=this.I&-65536|a;break;case 2:this.L=this.L&-65536|a;break;case 3:this.H=this.H&-65536|a;break;case 4:ne(this,y(this)&-65536|a);break;case 5:this.N=this.N&-65536|a;break;case 6:this.K=this.K&-65536|a;break;case 7:this.J=this.J&-65536|a}} +function Gf(a){var b=(this.fa=this.sa())&199;switch(b){case 0:var c=E(this,this.H+this.K);this.F=this.C;break;case 1:c=E(this,this.H+this.J);this.F=this.C;break;case 2:c=Eg(this,this.N+this.K);this.F=this.C;break;case 3:c=Eg(this,this.N+this.J);this.F=this.C;break;case 4:c=E(this,this.K);this.F=this.C;break;case 5:c=E(this,this.J);this.F=this.C;break;case 6:c=E(this,K(this));this.F=this.C;break;case 7:c=E(this,this.H);this.F=this.C;break;case 64:c=E(this,this.H+this.K+this.S());this.F=this.C;break; +case 65:c=E(this,this.H+this.J+this.S());this.F=this.C;break;case 66:c=Eg(this,this.N+this.K+this.S());this.F=this.C;break;case 67:c=Eg(this,this.N+this.J+this.S());this.F=this.C;break;case 68:c=E(this,this.K+this.S());this.F=this.C;break;case 69:c=E(this,this.J+this.S());this.F=this.C;break;case 70:c=Eg(this,this.N+this.S());this.F=this.C;break;case 71:c=E(this,this.H+this.S());this.F=this.C;break;case 128:c=E(this,this.H+this.K+K(this));this.F=this.C;break;case 129:c=E(this,this.H+this.J+K(this)); +this.F=this.C;break;case 130:c=Eg(this,this.N+this.K+K(this));this.F=this.C;break;case 131:c=Eg(this,this.N+this.J+K(this));this.F=this.C;break;case 132:c=E(this,this.K+K(this));this.F=this.C;break;case 133:c=E(this,this.J+K(this));this.F=this.C;break;case 134:c=Eg(this,this.N+K(this));this.F=this.C;break;case 135:c=E(this,this.H+K(this));this.F=this.C;break;case 192:c=this.D&65535;break;case 193:c=this.I&65535;break;case 194:c=this.L&65535;break;case 195:c=this.H&65535;break;case 196:c=y(this)&65535; +break;case 197:c=this.N&65535;break;case 198:c=this.K&65535;break;case 199:c=this.J&65535;break;default:c=0}switch(this.fa>>3&7){case 0:var d=this.D&65535;break;case 1:d=this.I&65535;break;case 2:d=this.L&65535;break;case 3:d=this.H&65535;break;case 4:d=y(this)&65535;break;case 5:d=this.N&65535;break;case 6:d=this.K&65535;break;case 7:d=this.J&65535;break;default:d=0}a=a.call(this,c,d);switch(b){case 0:case 3:Jg(this,a);this.A-=this.B.Qc;break;case 1:case 2:Jg(this,a);this.A-=this.B.Rc;break;case 4:case 5:case 7:Jg(this, +a);this.A-=this.B.xc;break;case 6:Jg(this,a);this.A-=this.B.yd;break;case 64:case 67:case 128:case 131:Jg(this,a);this.A-=this.B.Wb;break;case 65:case 66:case 129:case 130:Jg(this,a);this.A-=this.B.Xb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Jg(this,a);this.A-=this.B.Za;break;case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.H=this.H&-65536|a;break;case 196:ne(this,y(this)&-65536|a);break; +case 197:this.N=this.N&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a}} +function Hf(a,b){var c=(this.fa=this.sa())&199;switch(c){case 0:var d=E(this,this.H+this.K);this.F=this.C;break;case 1:d=E(this,this.H+this.J);this.F=this.C;break;case 2:d=Eg(this,this.N+this.K);this.F=this.C;break;case 3:d=Eg(this,this.N+this.J);this.F=this.C;break;case 4:d=E(this,this.K);this.F=this.C;break;case 5:d=E(this,this.J);this.F=this.C;break;case 6:d=E(this,K(this));this.F=this.C;break;case 7:d=E(this,this.H);this.F=this.C;break;case 64:d=E(this,this.H+this.K+this.S());this.F=this.C;break; +case 65:d=E(this,this.H+this.J+this.S());this.F=this.C;break;case 66:d=Eg(this,this.N+this.K+this.S());this.F=this.C;break;case 67:d=Eg(this,this.N+this.J+this.S());this.F=this.C;break;case 68:d=E(this,this.K+this.S());this.F=this.C;break;case 69:d=E(this,this.J+this.S());this.F=this.C;break;case 70:d=Eg(this,this.N+this.S());this.F=this.C;break;case 71:d=E(this,this.H+this.S());this.F=this.C;break;case 128:d=E(this,this.H+this.K+K(this));this.F=this.C;break;case 129:d=E(this,this.H+this.J+K(this)); +this.F=this.C;break;case 130:d=Eg(this,this.N+this.K+K(this));this.F=this.C;break;case 131:d=Eg(this,this.N+this.J+K(this));this.F=this.C;break;case 132:d=E(this,this.K+K(this));this.F=this.C;break;case 133:d=E(this,this.J+K(this));this.F=this.C;break;case 134:d=Eg(this,this.N+K(this));this.F=this.C;break;case 135:d=E(this,this.H+K(this));this.F=this.C;break;case 192:d=this.D&65535;break;case 193:d=this.I&65535;break;case 194:d=this.L&65535;break;case 195:d=this.H&65535;break;case 196:d=y(this)&65535; +break;case 197:d=this.N&65535;break;case 198:d=this.K&65535;break;case 199:d=this.J&65535;break;default:d=0}a=a[this.fa>>3&7].call(this,d,b.call(this));switch(c){case 0:case 3:Jg(this,a);this.A-=this.B.Qc;break;case 1:case 2:Jg(this,a);this.A-=this.B.Rc;break;case 4:case 5:case 7:Jg(this,a);this.A-=this.B.xc;break;case 6:Jg(this,a);this.A-=this.B.yd;break;case 64:case 67:case 128:case 131:Jg(this,a);this.A-=this.B.Wb;break;case 65:case 66:case 129:case 130:Jg(this,a);this.A-=this.B.Xb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Jg(this, +a);this.A-=this.B.Za;break;case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.H=this.H&-65536|a;break;case 196:ne(this,y(this)&-65536|a);break;case 197:this.N=this.N&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a}} +function If(a){switch((this.fa=this.sa())&199){case 0:var b=F(this,this.H+this.K);this.A-=this.B.Qc;break;case 1:b=F(this,this.H+this.J);this.A-=this.B.Rc;break;case 2:b=Hg(this,this.N+this.K);this.A-=this.B.Rc;break;case 3:b=Hg(this,this.N+this.J);this.A-=this.B.Qc;break;case 4:b=F(this,this.K);this.A-=this.B.xc;break;case 5:b=F(this,this.J);this.A-=this.B.xc;break;case 6:b=F(this,K(this));this.A-=this.B.yd;break;case 7:b=F(this,this.H);this.A-=this.B.xc;break;case 64:b=F(this,this.H+this.K+this.S()); +this.A-=this.B.Wb;break;case 65:b=F(this,this.H+this.J+this.S());this.A-=this.B.Xb;break;case 66:b=Hg(this,this.N+this.K+this.S());this.A-=this.B.Xb;break;case 67:b=Hg(this,this.N+this.J+this.S());this.A-=this.B.Wb;break;case 68:b=F(this,this.K+this.S());this.A-=this.B.Za;break;case 69:b=F(this,this.J+this.S());this.A-=this.B.Za;break;case 70:b=Hg(this,this.N+this.S());this.A-=this.B.Za;break;case 71:b=F(this,this.H+this.S());this.A-=this.B.Za;break;case 128:b=F(this,this.H+this.K+K(this));this.A-= +this.B.Wb;break;case 129:b=F(this,this.H+this.J+K(this));this.A-=this.B.Xb;break;case 130:b=Hg(this,this.N+this.K+K(this));this.A-=this.B.Xb;break;case 131:b=Hg(this,this.N+this.J+K(this));this.A-=this.B.Wb;break;case 132:b=F(this,this.K+K(this));this.A-=this.B.Za;break;case 133:b=F(this,this.J+K(this));this.A-=this.B.Za;break;case 134:b=Hg(this,this.N+K(this));this.A-=this.B.Za;break;case 135:b=F(this,this.H+K(this));this.A-=this.B.Za;break;case 192:b=this.D;break;case 193:b=this.I;break;case 194:b= +this.L;break;case 195:b=this.H;break;case 196:b=y(this);break;case 197:b=this.N;break;case 198:b=this.K;break;case 199:b=this.J;break;default:b=0}var c=this.fa>>3&7;switch(c){case 0:var d=this.D;break;case 1:d=this.I;break;case 2:d=this.L;break;case 3:d=this.H;break;case 4:d=y(this);break;case 5:d=this.N;break;case 6:d=this.K;break;case 7:d=this.J;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.D=a;break;case 1:this.I=a;break;case 2:this.L=a;break;case 3:this.H=a;break;case 4:ne(this,a); +break;case 5:this.N=a;break;case 6:this.K=a;break;case 7:this.J=a}} +function Jf(a){var b=(this.fa=this.sa())&199;switch(b){case 0:var c=F(this,this.H+this.K);this.F=this.C;break;case 1:c=F(this,this.H+this.J);this.F=this.C;break;case 2:c=Hg(this,this.N+this.K);this.F=this.C;break;case 3:c=Hg(this,this.N+this.J);this.F=this.C;break;case 4:c=F(this,this.K);this.F=this.C;break;case 5:c=F(this,this.J);this.F=this.C;break;case 6:c=F(this,K(this));this.F=this.C;break;case 7:c=F(this,this.H);this.F=this.C;break;case 64:c=F(this,this.H+this.K+this.S());this.F=this.C;break; +case 65:c=F(this,this.H+this.J+this.S());this.F=this.C;break;case 66:c=Hg(this,this.N+this.K+this.S());this.F=this.C;break;case 67:c=Hg(this,this.N+this.J+this.S());this.F=this.C;break;case 68:c=F(this,this.K+this.S());this.F=this.C;break;case 69:c=F(this,this.J+this.S());this.F=this.C;break;case 70:c=Hg(this,this.N+this.S());this.F=this.C;break;case 71:c=F(this,this.H+this.S());this.F=this.C;break;case 128:c=F(this,this.H+this.K+K(this));this.F=this.C;break;case 129:c=F(this,this.H+this.J+K(this)); +this.F=this.C;break;case 130:c=Hg(this,this.N+this.K+K(this));this.F=this.C;break;case 131:c=Hg(this,this.N+this.J+K(this));this.F=this.C;break;case 132:c=F(this,this.K+K(this));this.F=this.C;break;case 133:c=F(this,this.J+K(this));this.F=this.C;break;case 134:c=Hg(this,this.N+K(this));this.F=this.C;break;case 135:c=F(this,this.H+K(this));this.F=this.C;break;case 192:c=this.D;break;case 193:c=this.I;break;case 194:c=this.L;break;case 195:c=this.H;break;case 196:c=y(this);break;case 197:c=this.N;break; +case 198:c=this.K;break;case 199:c=this.J;break;default:c=0}switch(this.fa>>3&7){case 0:var d=this.D;break;case 1:d=this.I;break;case 2:d=this.L;break;case 3:d=this.H;break;case 4:d=y(this);break;case 5:d=this.N;break;case 6:d=this.K;break;case 7:d=this.J;break;default:d=0}a=a.call(this,c,d);switch(b){case 0:case 3:Kg(this,a);this.A-=this.B.Qc;break;case 1:case 2:Kg(this,a);this.A-=this.B.Rc;break;case 4:case 5:case 7:Kg(this,a);this.A-=this.B.xc;break;case 6:Kg(this,a);this.A-=this.B.yd;break;case 64:case 67:case 128:case 131:Kg(this, +a);this.A-=this.B.Wb;break;case 65:case 66:case 129:case 130:Kg(this,a);this.A-=this.B.Xb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Kg(this,a);this.A-=this.B.Za;break;case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.H=a;break;case 196:ne(this,a);break;case 197:this.N=a;break;case 198:this.K=a;break;case 199:this.J=a}} +function Kf(a,b){var c=(this.fa=this.sa())&199;switch(c){case 0:var d=F(this,this.H+this.K);this.F=this.C;break;case 1:d=F(this,this.H+this.J);this.F=this.C;break;case 2:d=Hg(this,this.N+this.K);this.F=this.C;break;case 3:d=Hg(this,this.N+this.J);this.F=this.C;break;case 4:d=F(this,this.K);this.F=this.C;break;case 5:d=F(this,this.J);this.F=this.C;break;case 6:d=F(this,K(this));this.F=this.C;break;case 7:d=F(this,this.H);this.F=this.C;break;case 64:d=F(this,this.H+this.K+this.S());this.F=this.C;break; +case 65:d=F(this,this.H+this.J+this.S());this.F=this.C;break;case 66:d=Hg(this,this.N+this.K+this.S());this.F=this.C;break;case 67:d=Hg(this,this.N+this.J+this.S());this.F=this.C;break;case 68:d=F(this,this.K+this.S());this.F=this.C;break;case 69:d=F(this,this.J+this.S());this.F=this.C;break;case 70:d=Hg(this,this.N+this.S());this.F=this.C;break;case 71:d=F(this,this.H+this.S());this.F=this.C;break;case 128:d=F(this,this.H+this.K+K(this));this.F=this.C;break;case 129:d=F(this,this.H+this.J+K(this)); +this.F=this.C;break;case 130:d=Hg(this,this.N+this.K+K(this));this.F=this.C;break;case 131:d=Hg(this,this.N+this.J+K(this));this.F=this.C;break;case 132:d=F(this,this.K+K(this));this.F=this.C;break;case 133:d=F(this,this.J+K(this));this.F=this.C;break;case 134:d=Hg(this,this.N+K(this));this.F=this.C;break;case 135:d=F(this,this.H+K(this));this.F=this.C;break;case 192:d=this.D;break;case 193:d=this.I;break;case 194:d=this.L;break;case 195:d=this.H;break;case 196:d=y(this);break;case 197:d=this.N;break; +case 198:d=this.K;break;case 199:d=this.J}a=a[this.fa>>3&7].call(this,d,b.call(this));switch(c){case 0:case 3:Kg(this,a);this.A-=this.B.Qc;break;case 1:case 2:Kg(this,a);this.A-=this.B.Rc;break;case 4:case 5:case 7:Kg(this,a);this.A-=this.B.xc;break;case 6:Kg(this,a);this.A-=this.B.yd;break;case 64:case 67:case 128:case 131:Kg(this,a);this.A-=this.B.Wb;break;case 65:case 66:case 129:case 130:Kg(this,a);this.A-=this.B.Xb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:Kg(this, +a);this.A-=this.B.Za;break;case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.H=a;break;case 196:ne(this,a);break;case 197:this.N=a;break;case 198:this.K=a;break;case 199:this.J=a}} +function Lf(a){switch((this.fa=this.sa())&199){case 0:var b=D(this,this.D);break;case 1:b=D(this,this.I);break;case 2:b=D(this,this.L);break;case 3:b=D(this,this.H);break;case 4:b=D(this,sk.call(this,0));break;case 5:b=D(this,K(this));break;case 6:b=D(this,this.K);break;case 7:b=D(this,this.J);break;case 64:b=D(this,this.D+this.S());break;case 65:b=D(this,this.I+this.S());break;case 66:b=D(this,this.L+this.S());break;case 67:b=D(this,this.H+this.S());break;case 68:b=D(this,sk.call(this,1)+this.S()); +break;case 69:b=Cg(this,this.N+this.S());break;case 70:b=D(this,this.K+this.S());break;case 71:b=D(this,this.J+this.S());break;case 128:b=D(this,this.D+K(this));break;case 129:b=D(this,this.I+K(this));break;case 130:b=D(this,this.L+K(this));break;case 131:b=D(this,this.H+K(this));break;case 132:b=D(this,sk.call(this,2)+K(this));break;case 133:b=Cg(this,this.N+K(this));break;case 134:b=D(this,this.K+K(this));break;case 135:b=D(this,this.J+K(this));break;case 192:b=this.D&255;break;case 193:b=this.I& +255;break;case 194:b=this.L&255;break;case 195:b=this.H&255;break;case 196:b=this.D>>8&255;break;case 197:b=this.I>>8&255;break;case 198:b=this.L>>8&255;break;case 199:b=this.H>>8&255;break;default:b=0}var c=this.fa>>3&7;switch(c){case 0:var d=this.D&255;break;case 1:d=this.I&255;break;case 2:d=this.L&255;break;case 3:d=this.H&255;break;case 4:d=this.D>>8&255;break;case 5:d=this.I>>8&255;break;case 6:d=this.L>>8&255;break;case 7:d=this.H>>8&255;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.D= +this.D&-256|a;break;case 1:this.I=this.I&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.H=this.H&-256|a;break;case 4:this.D=this.D&-65281|a<<8;break;case 5:this.I=this.I&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.H=this.H&-65281|a<<8}} +function Mf(a){var b=(this.fa=this.sa())&199;switch(b){case 0:var c=D(this,this.D);this.F=this.C;break;case 1:c=D(this,this.I);this.F=this.C;break;case 2:c=D(this,this.L);this.F=this.C;break;case 3:c=D(this,this.H);this.F=this.C;break;case 4:c=D(this,sk.call(this,0));this.F=this.C;break;case 5:c=D(this,K(this));this.F=this.C;break;case 6:c=D(this,this.K);this.F=this.C;break;case 7:c=D(this,this.J);this.F=this.C;break;case 64:c=D(this,this.D+this.S());this.F=this.C;break;case 65:c=D(this,this.I+this.S()); +this.F=this.C;break;case 66:c=D(this,this.L+this.S());this.F=this.C;break;case 67:c=D(this,this.H+this.S());this.F=this.C;break;case 68:c=D(this,sk.call(this,1)+this.S());this.F=this.C;break;case 69:c=Cg(this,this.N+this.S());this.F=this.C;break;case 70:c=D(this,this.K+this.S());this.F=this.C;break;case 71:c=D(this,this.J+this.S());this.F=this.C;break;case 128:c=D(this,this.D+K(this));this.F=this.C;break;case 129:c=D(this,this.I+K(this));this.F=this.C;break;case 130:c=D(this,this.L+K(this));this.F= +this.C;break;case 131:c=D(this,this.H+K(this));this.F=this.C;break;case 132:c=D(this,sk.call(this,2)+K(this));this.F=this.C;break;case 133:c=Cg(this,this.N+K(this));this.F=this.C;break;case 134:c=D(this,this.K+K(this));this.F=this.C;break;case 135:c=D(this,this.J+K(this));this.F=this.C;break;case 192:c=this.D&255;break;case 193:c=this.I&255;break;case 194:c=this.L&255;break;case 195:c=this.H&255;break;case 196:c=this.D>>8&255;break;case 197:c=this.I>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c= +this.H>>8&255;break;default:c=0}switch(this.fa>>3&7){case 0:var d=this.D&255;break;case 1:d=this.I&255;break;case 2:d=this.L&255;break;case 3:d=this.H&255;break;case 4:d=this.D>>8&255;break;case 5:d=this.I>>8&255;break;case 6:d=this.L>>8&255;break;case 7:d=this.H>>8&255;break;default:d=0}a=a.call(this,c,d);switch(b){case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.H=this.H&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break; +case 197:this.I=this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.H=this.H&-65281|a<<8;break;default:Ig(this,a)}} +function Nf(a,b){var c=(this.fa=this.sa())&199;switch(c){case 0:var d=D(this,this.D);this.F=this.C;break;case 1:d=D(this,this.I);this.F=this.C;break;case 2:d=D(this,this.L);this.F=this.C;break;case 3:d=D(this,this.H);this.F=this.C;break;case 4:d=D(this,sk.call(this,0));this.F=this.C;break;case 5:d=D(this,K(this));this.F=this.C;break;case 6:d=D(this,this.K);this.F=this.C;break;case 7:d=D(this,this.J);this.F=this.C;break;case 64:d=D(this,this.D+this.S());this.F=this.C;break;case 65:d=D(this,this.I+ +this.S());this.F=this.C;break;case 66:d=D(this,this.L+this.S());this.F=this.C;break;case 67:d=D(this,this.H+this.S());this.F=this.C;break;case 68:d=D(this,sk.call(this,1)+this.S());this.F=this.C;break;case 69:d=Cg(this,this.N+this.S());this.F=this.C;break;case 70:d=D(this,this.K+this.S());this.F=this.C;break;case 71:d=D(this,this.J+this.S());this.F=this.C;break;case 128:d=D(this,this.D+K(this));this.F=this.C;break;case 129:d=D(this,this.I+K(this));this.F=this.C;break;case 130:d=D(this,this.L+K(this)); +this.F=this.C;break;case 131:d=D(this,this.H+K(this));this.F=this.C;break;case 132:d=D(this,sk.call(this,2)+K(this));this.F=this.C;break;case 133:d=Cg(this,this.N+K(this));this.F=this.C;break;case 134:d=D(this,this.K+K(this));this.F=this.C;break;case 135:d=D(this,this.J+K(this));this.F=this.C;break;case 192:d=this.D&255;break;case 193:d=this.I&255;break;case 194:d=this.L&255;break;case 195:d=this.H&255;break;case 196:d=this.D>>8&255;break;case 197:d=this.I>>8&255;break;case 198:d=this.L>>8&255;break; +case 199:d=this.H>>8&255;break;default:d=0}a=a[this.fa>>3&7].call(this,d,b.call(this));switch(c){case 192:this.D=this.D&-256|a;break;case 193:this.I=this.I&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.H=this.H&-256|a;break;case 196:this.D=this.D&-65281|a<<8;break;case 197:this.I=this.I&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.H=this.H&-65281|a<<8;break;default:Ig(this,a)}} +function Of(a){switch((this.fa=this.sa())&199){case 0:var b=E(this,this.D);break;case 1:b=E(this,this.I);break;case 2:b=E(this,this.L);break;case 3:b=E(this,this.H);break;case 4:b=E(this,sk.call(this,0));break;case 5:b=E(this,K(this));break;case 6:b=E(this,this.K);break;case 7:b=E(this,this.J);break;case 64:b=E(this,this.D+this.S());break;case 65:b=E(this,this.I+this.S());break;case 66:b=E(this,this.L+this.S());break;case 67:b=E(this,this.H+this.S());break;case 68:b=E(this,sk.call(this,1)+this.S()); +break;case 69:b=Eg(this,this.N+this.S());break;case 70:b=E(this,this.K+this.S());break;case 71:b=E(this,this.J+this.S());break;case 128:b=E(this,this.D+K(this));break;case 129:b=E(this,this.I+K(this));break;case 130:b=E(this,this.L+K(this));break;case 131:b=E(this,this.H+K(this));break;case 132:b=E(this,sk.call(this,2)+K(this));break;case 133:b=Eg(this,this.N+K(this));break;case 134:b=E(this,this.K+K(this));break;case 135:b=E(this,this.J+K(this));break;case 192:b=this.D&65535;break;case 193:b=this.I& +65535;break;case 194:b=this.L&65535;break;case 195:b=this.H&65535;break;case 196:b=y(this)&65535;break;case 197:b=this.N&65535;break;case 198:b=this.K&65535;break;case 199:b=this.J&65535;break;default:b=0}var c=this.fa>>3&7;switch(c){case 0:var d=this.D&65535;break;case 1:d=this.I&65535;break;case 2:d=this.L&65535;break;case 3:d=this.H&65535;break;case 4:d=y(this)&65535;break;case 5:d=this.N&65535;break;case 6:d=this.K&65535;break;case 7:d=this.J&65535;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.D= +this.D&-65536|a;break;case 1:this.I=this.I&-65536|a;break;case 2:this.L=this.L&-65536|a;break;case 3:this.H=this.H&-65536|a;break;case 4:ne(this,y(this)&-65536|a);break;case 5:this.N=this.N&-65536|a;break;case 6:this.K=this.K&-65536|a;break;case 7:this.J=this.J&-65536|a}} +function Pf(a){var b=(this.fa=this.sa())&199;switch(b){case 0:var c=E(this,this.D);this.F=this.C;break;case 1:c=E(this,this.I);this.F=this.C;break;case 2:c=E(this,this.L);this.F=this.C;break;case 3:c=E(this,this.H);this.F=this.C;break;case 4:c=E(this,sk.call(this,0));this.F=this.C;break;case 5:c=E(this,K(this));this.F=this.C;break;case 6:c=E(this,this.K);this.F=this.C;break;case 7:c=E(this,this.J);this.F=this.C;break;case 64:c=E(this,this.D+this.S());this.F=this.C;break;case 65:c=E(this,this.I+this.S()); +this.F=this.C;break;case 66:c=E(this,this.L+this.S());this.F=this.C;break;case 67:c=E(this,this.H+this.S());this.F=this.C;break;case 68:c=E(this,sk.call(this,1)+this.S());this.F=this.C;break;case 69:c=Eg(this,this.N+this.S());this.F=this.C;break;case 70:c=E(this,this.K+this.S());this.F=this.C;break;case 71:c=E(this,this.J+this.S());this.F=this.C;break;case 128:c=E(this,this.D+K(this));this.F=this.C;break;case 129:c=E(this,this.I+K(this));this.F=this.C;break;case 130:c=E(this,this.L+K(this));this.F= +this.C;break;case 131:c=E(this,this.H+K(this));this.F=this.C;break;case 132:c=E(this,sk.call(this,2)+K(this));this.F=this.C;break;case 133:c=Eg(this,this.N+K(this));this.F=this.C;break;case 134:c=E(this,this.K+K(this));this.F=this.C;break;case 135:c=E(this,this.J+K(this));this.F=this.C;break;case 192:c=this.D&65535;break;case 193:c=this.I&65535;break;case 194:c=this.L&65535;break;case 195:c=this.H&65535;break;case 196:c=y(this)&65535;break;case 197:c=this.N&65535;break;case 198:c=this.K&65535;break; +case 199:c=this.J&65535;break;default:c=0}switch(this.fa>>3&7){case 0:var d=this.D&65535;break;case 1:d=this.I&65535;break;case 2:d=this.L&65535;break;case 3:d=this.H&65535;break;case 4:d=y(this)&65535;break;case 5:d=this.N&65535;break;case 6:d=this.K&65535;break;case 7:d=this.J&65535;break;default:d=0}a=a.call(this,c,d);switch(b){case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.H=this.H&-65536|a;break;case 196:ne(this, +y(this)&-65536|a);break;case 197:this.N=this.N&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a;break;default:Jg(this,a)}} +function Qf(a,b){var c=(this.fa=this.sa())&199;switch(c){case 0:var d=E(this,this.D);this.F=this.C;break;case 1:d=E(this,this.I);this.F=this.C;break;case 2:d=E(this,this.L);this.F=this.C;break;case 3:d=E(this,this.H);this.F=this.C;break;case 4:d=E(this,sk.call(this,0));this.F=this.C;break;case 5:d=E(this,K(this));this.F=this.C;break;case 6:d=E(this,this.K);this.F=this.C;break;case 7:d=E(this,this.J);this.F=this.C;break;case 64:d=E(this,this.D+this.S());this.F=this.C;break;case 65:d=E(this,this.I+ +this.S());this.F=this.C;break;case 66:d=E(this,this.L+this.S());this.F=this.C;break;case 67:d=E(this,this.H+this.S());this.F=this.C;break;case 68:d=E(this,sk.call(this,1)+this.S());this.F=this.C;break;case 69:d=Eg(this,this.N+this.S());this.F=this.C;break;case 70:d=E(this,this.K+this.S());this.F=this.C;break;case 71:d=E(this,this.J+this.S());this.F=this.C;break;case 128:d=E(this,this.D+K(this));this.F=this.C;break;case 129:d=E(this,this.I+K(this));this.F=this.C;break;case 130:d=E(this,this.L+K(this)); +this.F=this.C;break;case 131:d=E(this,this.H+K(this));this.F=this.C;break;case 132:d=E(this,sk.call(this,2)+K(this));this.F=this.C;break;case 133:d=Eg(this,this.N+K(this));this.F=this.C;break;case 134:d=E(this,this.K+K(this));this.F=this.C;break;case 135:d=E(this,this.J+K(this));this.F=this.C;break;case 192:d=this.D&65535;break;case 193:d=this.I&65535;break;case 194:d=this.L&65535;break;case 195:d=this.H&65535;break;case 196:d=y(this)&65535;break;case 197:d=this.N&65535;break;case 198:d=this.K&65535; +break;case 199:d=this.J&65535;break;default:d=0}a=a[this.fa>>3&7].call(this,d,b.call(this));switch(c){case 192:this.D=this.D&-65536|a;break;case 193:this.I=this.I&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.H=this.H&-65536|a;break;case 196:ne(this,y(this)&-65536|a);break;case 197:this.N=this.N&-65536|a;break;case 198:this.K=this.K&-65536|a;break;case 199:this.J=this.J&-65536|a;break;default:Jg(this,a)}} +function Rf(a){switch((this.fa=this.sa())&199){case 0:var b=F(this,this.D);break;case 1:b=F(this,this.I);break;case 2:b=F(this,this.L);break;case 3:b=F(this,this.H);break;case 4:b=F(this,sk.call(this,0));break;case 5:b=F(this,K(this));break;case 6:b=F(this,this.K);break;case 7:b=F(this,this.J);break;case 64:b=F(this,this.D+this.S());break;case 65:b=F(this,this.I+this.S());break;case 66:b=F(this,this.L+this.S());break;case 67:b=F(this,this.H+this.S());break;case 68:b=F(this,sk.call(this,1)+this.S()); +break;case 69:b=Hg(this,this.N+this.S());break;case 70:b=F(this,this.K+this.S());break;case 71:b=F(this,this.J+this.S());break;case 128:b=F(this,this.D+K(this));break;case 129:b=F(this,this.I+K(this));break;case 130:b=F(this,this.L+K(this));break;case 131:b=F(this,this.H+K(this));break;case 132:b=F(this,sk.call(this,2)+K(this));break;case 133:b=Hg(this,this.N+K(this));break;case 134:b=F(this,this.K+K(this));break;case 135:b=F(this,this.J+K(this));break;case 192:b=this.D;break;case 193:b=this.I;break; +case 194:b=this.L;break;case 195:b=this.H;break;case 196:b=y(this);break;case 197:b=this.N;break;case 198:b=this.K;break;case 199:b=this.J;break;default:b=0}var c=this.fa>>3&7;switch(c){case 0:var d=this.D;break;case 1:d=this.I;break;case 2:d=this.L;break;case 3:d=this.H;break;case 4:d=y(this);break;case 5:d=this.N;break;case 6:d=this.K;break;case 7:d=this.J;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.D=a;break;case 1:this.I=a;break;case 2:this.L=a;break;case 3:this.H=a;break;case 4:ne(this, +a);break;case 5:this.N=a;break;case 6:this.K=a;break;case 7:this.J=a}} +function Sf(a){var b=(this.fa=this.sa())&199;switch(b){case 0:var c=F(this,this.D);this.F=this.C;break;case 1:c=F(this,this.I);this.F=this.C;break;case 2:c=F(this,this.L);this.F=this.C;break;case 3:c=F(this,this.H);this.F=this.C;break;case 4:c=F(this,sk.call(this,0));this.F=this.C;break;case 5:c=F(this,K(this));this.F=this.C;break;case 6:c=F(this,this.K);this.F=this.C;break;case 7:c=F(this,this.J);this.F=this.C;break;case 64:c=F(this,this.D+this.S());this.F=this.C;break;case 65:c=F(this,this.I+this.S()); +this.F=this.C;break;case 66:c=F(this,this.L+this.S());this.F=this.C;break;case 67:c=F(this,this.H+this.S());this.F=this.C;break;case 68:c=F(this,sk.call(this,1)+this.S());this.F=this.C;break;case 69:c=Hg(this,this.N+this.S());this.F=this.C;break;case 70:c=F(this,this.K+this.S());this.F=this.C;break;case 71:c=F(this,this.J+this.S());this.F=this.C;break;case 128:c=F(this,this.D+K(this));this.F=this.C;break;case 129:c=F(this,this.I+K(this));this.F=this.C;break;case 130:c=F(this,this.L+K(this));this.F= +this.C;break;case 131:c=F(this,this.H+K(this));this.F=this.C;break;case 132:c=F(this,sk.call(this,2)+K(this));this.F=this.C;break;case 133:c=Hg(this,this.N+K(this));this.F=this.C;break;case 134:c=F(this,this.K+K(this));this.F=this.C;break;case 135:c=F(this,this.J+K(this));this.F=this.C;break;case 192:c=this.D;break;case 193:c=this.I;break;case 194:c=this.L;break;case 195:c=this.H;break;case 196:c=y(this);break;case 197:c=this.N;break;case 198:c=this.K;break;case 199:c=this.J;break;default:c=0}switch(this.fa>> +3&7){case 0:var d=this.D;break;case 1:d=this.I;break;case 2:d=this.L;break;case 3:d=this.H;break;case 4:d=y(this);break;case 5:d=this.N;break;case 6:d=this.K;break;case 7:d=this.J;break;default:d=0}a=a.call(this,c,d);switch(b){case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.H=a;break;case 196:ne(this,a);break;case 197:this.N=a;break;case 198:this.K=a;break;case 199:this.J=a;break;default:Kg(this,a)}} +function Tf(a,b){var c=(this.fa=this.sa())&199;switch(c){case 0:var d=F(this,this.D);this.F=this.C;break;case 1:d=F(this,this.I);this.F=this.C;break;case 2:d=F(this,this.L);this.F=this.C;break;case 3:d=F(this,this.H);this.F=this.C;break;case 4:d=F(this,sk.call(this,0));this.F=this.C;break;case 5:d=F(this,K(this));this.F=this.C;break;case 6:d=F(this,this.K);this.F=this.C;break;case 7:d=F(this,this.J);this.F=this.C;break;case 64:d=F(this,this.D+this.S());this.F=this.C;break;case 65:d=F(this,this.I+ +this.S());this.F=this.C;break;case 66:d=F(this,this.L+this.S());this.F=this.C;break;case 67:d=F(this,this.H+this.S());this.F=this.C;break;case 68:d=F(this,sk.call(this,1)+this.S());this.F=this.C;break;case 69:d=Hg(this,this.N+this.S());this.F=this.C;break;case 70:d=F(this,this.K+this.S());this.F=this.C;break;case 71:d=F(this,this.J+this.S());this.F=this.C;break;case 128:d=F(this,this.D+K(this));this.F=this.C;break;case 129:d=F(this,this.I+K(this));this.F=this.C;break;case 130:d=F(this,this.L+K(this)); +this.F=this.C;break;case 131:d=F(this,this.H+K(this));this.F=this.C;break;case 132:d=F(this,sk.call(this,2)+K(this));this.F=this.C;break;case 133:d=Hg(this,this.N+K(this));this.F=this.C;break;case 134:d=F(this,this.K+K(this));this.F=this.C;break;case 135:d=F(this,this.J+K(this));this.F=this.C;break;case 192:d=this.D;break;case 193:d=this.I;break;case 194:d=this.L;break;case 195:d=this.H;break;case 196:d=y(this);break;case 197:d=this.N;break;case 198:d=this.K;break;case 199:d=this.J;break;default:d= +0}a=a[this.fa>>3&7].call(this,d,b.call(this));switch(c){case 192:this.D=a;break;case 193:this.I=a;break;case 194:this.L=a;break;case 195:this.H=a;break;case 196:ne(this,a);break;case 197:this.N=a;break;case 198:this.K=a;break;case 199:this.J=a;break;default:Kg(this,a)}} +function sk(a){var b=this.sa(),c=b>>6;switch(b>>3&7){case 0:var d=this.D;break;case 1:d=this.I;break;case 2:d=this.L;break;case 3:d=this.H;break;case 4:d=0;break;case 5:d=this.N;break;case 6:d=this.K;break;case 7:d=this.J}switch(b&7){case 0:var e=this.D;break;case 1:e=this.I;break;case 2:e=this.L;break;case 3:e=this.H;break;case 4:e=y(this);this.Ga=this.Sb;break;case 5:a?(e=this.N,this.Ga=this.Sb):e=K(this);break;case 6:e=this.K;break;case 7:e=this.J}return(d<>8&255;if(9<(b&15)||jg(this)){b+=6;80286<=this.da&&255>8&255;if(9<(b&15)||jg(this)){b=b-6&15;c=c-1&255;var d=a=1}else d=a=0;this.D=this.D&-65536|c<<8|b;d?og(this):pg(this);a?wg(this):ug(this);this.A-=this.B.re},function(){this.D=ek.call(this,this.D)},function(){this.I=ek.call(this,this.I)},function(){this.L=ek.call(this,this.L)},function(){this.H=ek.call(this, +this.H)},function(){ne(this,ek.call(this,y(this)))},function(){this.N=ek.call(this,this.N)},function(){this.K=ek.call(this,this.K)},function(){this.J=ek.call(this,this.J)},function(){this.D=ck.call(this,this.D)},function(){this.I=ck.call(this,this.I)},function(){this.L=ck.call(this,this.L)},function(){this.H=ck.call(this,this.H)},function(){ne(this,ck.call(this,y(this)))},function(){this.N=ck.call(this,this.N)},function(){this.K=ck.call(this,this.K)},function(){this.J=ck.call(this,this.J)},function(){ve(this, +this.D&this.R);this.A-=this.B.Ic},function(){ve(this,this.I&this.R);this.A-=this.B.Ic},function(){ve(this,this.L&this.R);this.A-=this.B.Ic},function(){ve(this,this.H&this.R);this.A-=this.B.Ic},function(){ve(this,y(this)-2&65535);this.A-=this.B.Ic},function(){ve(this,this.N&this.R);this.A-=this.B.Ic},function(){ve(this,this.K&this.R);this.A-=this.B.Ic},function(){ve(this,this.J&this.R);this.A-=this.B.Ic},function(){this.D=this.D&~this.R|le(this);this.A-=this.B.nc},function(){this.I=this.I&~this.R| +le(this);this.A-=this.B.nc},function(){this.L=this.L&~this.R|le(this);this.A-=this.B.nc},function(){this.H=this.H&~this.R|le(this);this.A-=this.B.nc},function(){ne(this,y(this)&~this.R|le(this));this.A-=this.B.nc},function(){this.N=this.N&~this.R|le(this);this.A-=this.B.nc},function(){this.K=this.K&~this.R|le(this);this.A-=this.B.nc},function(){this.J=this.J&~this.R|le(this);this.A-=this.B.nc},tk,uk,vk,wk,xk,yk,zk,Ak,Bk,Ck,Dk,Ek,Fk,Gk,Hk,Ik,tk,uk,vk,wk,xk,yk,zk,Ak,Bk,Ck,Dk,Ek,Fk,Gk,Hk,Ik,Jk,function(){this.mb.call(this, +Yk,this.Ha);this.A-=-1===this.F?1:this.B.vg},Jk,function(){this.mb.call(this,Yk,this.S);this.A-=-1===this.F?1:this.B.vg},function(){this.uc.call(this,Tj)},function(){this.Ba.call(this,Uj)},function(){this.kc.call(this,Xj)},function(){this.la.call(this,Yj)},Lk,Mk,Nk,Ok,function(){this.M|=1;this.Ba.call(this,cj)},function(){this.M|=1;this.Ga=this.Sb=this.Ig;this.la.call(this,Ti)},function(){this.la.call(this,bj);switch(this.fa>>3&7){case 0:var a=this.D;this.D=this.Aa;ue(this,a);break;case 1:a=this.I; +this.I=this.Aa;cg(this,a);break;case 2:a=this.L;this.L=this.Aa;me(this,a);break;case 3:a=this.H;this.H=this.Aa;te(this,a);break;case 4:a=y(this);ne(this,this.Aa);80386<=this.da?this.Ka.load(a):ue(this,a);break;case 5:a=this.N;this.N=this.Aa;80386<=this.da?this.La.load(a):cg(this,a);break;case 6:a=this.K;this.K=this.Aa;me(this,a);break;case 7:a=this.J,this.J=this.Aa,te(this,a)}},function(){this.M|=1;this.ta=this.Ca;this.Aa=le(this);this.mb.call(this,Zk,lk);this.ta=-1},function(){this.A-=3},function(){var a= +this.D;this.D=this.D&~this.R|this.I&this.R;this.I=this.I&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.L&this.R;this.L=this.L&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.H&this.R;this.H=this.H&~this.R|a&this.R;this.A-=3},function(){var a=this.D,b=y(this);this.D=this.D&~this.R|b&this.R;ne(this,b&~this.R|a&this.R);this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.N&this.R;this.N=this.N&~this.R|a&this.R;this.A-=3},function(){var a= +this.D;this.D=this.D&~this.R|this.K&this.R;this.K=this.K&~this.R|a&this.R;this.A-=3},function(){var a=this.D;this.D=this.D&~this.R|this.J&this.R;this.J=this.J&~this.R|a&this.R;this.A-=3},function(){this.D=2==this.X?this.D&-65536|this.D<<24>>24&65535:this.D<<16>>16;this.A-=2},function(){this.L=2==this.X?this.L&-65536|(this.D&32768?65535:0):this.D&-2147483648?-1:0;this.A-=this.B.Hj},function(){mk.call(this,this.Ha(),Mg(this));this.A-=this.B.Kj},function(){this.A-=3},function(){var a=xe(this);a&131072&& +3>this.lc?x.call(this,13,0):(ve(this,a&-196609),this.A-=this.B.Ic)},function(){if(this.P&131072&&3>this.lc)x.call(this,13,0);else{var a=le(this);a=a&65535|this.P&-65536;ye(this,a);this.A-=this.B.nc}},function(){var a=this.D>>8&255;a&1?og(this):pg(this);a&4?(this.resultType&=-3,this.P|=4):(this.resultType&=-3,this.P&=-5);a&16?wg(this):ug(this);a&64?xg(this):vg(this);a&128?(this.resultType&=-17,this.P|=128):(this.resultType&=-17,this.P&=-129);this.A-=this.B.Yb},function(){this.D=this.D&-65281|(xe(this)& +213)<<8;this.A-=this.B.Yb},function(){var a=this.D&-256;var b=K(this);b=this.ya(this.Ga.Bb(b,1));this.D=a|b;this.A-=this.B.Hh},function(){this.D=this.D&~this.R|re(this,this.Ga,K(this));this.A-=this.B.Hh},function(){var a=K(this),b=this.D;this.ub(this.Ga.Ub(a,1),b);this.A-=this.B.Ih},function(){Lg(this,this.Ga,K(this),this.D);this.A-=this.B.Ih},function(){var a=1,b=0,c=this.xa,d=this.B.Jh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Lh,this.ha&256||(this.A-=this.B.Kh));if(a--){var e=this.ya(this.Ga.Bb(this.K& +c,1));this.ub(this.pa.Ub(this.J&c,1),e);e=this.P&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d;this.I=this.I&~c|this.I-b&c;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Jh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Lh,this.ha&256||(this.A-=this.B.Kh));if(a--){Lg(this,this.pa,this.J&c,re(this,this.Ga,this.K&c));var e=this.P&1024?-this.X:this.X;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.A-=d;this.I=this.I&~c|this.I-b&c;a&&(fg(this), +this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.uh;this.ha&192&&(a=this.I&c,b=1,d=this.B.wh,this.ha&256||(this.A-=this.B.vh));if(a--){var e=Bg(this,this.Ga,this.K),f=Bg(this,this.pa,this.J);this.F=this.C;Gi.call(this,e,f);e=this.P&1024?-1:1;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.uh;this.ha&192&&(a=this.I&c,b=1,d=this.B.wh,this.ha&256|| +(this.A-=this.B.vh));if(a--){var e=Dg(this,this.Ga,this.K&c),f=Dg(this,this.pa,this.J&c);this.F=this.C;Hi.call(this,e,f);e=this.P&1024?-this.X:this.X;this.K=this.K&~c|this.K+e&c;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this),this.M|=256)}},function(){ng(this,this.D&this.sa(),128);this.A-=this.B.re},function(){ng(this,this.D&this.Ha(),this.Hb);this.A-=this.B.re},function(){var a=1,b=0,c=this.xa,d=this.B.Uh;this.ha&192&&(a=this.I&c,b= +1,d=this.B.Wh,this.ha&256||(this.A-=this.B.Vh));if(a--){var e=this.D;this.ub(this.pa.Ub(this.J&c,1),e);this.I=this.I&~c|this.I-b&c;80546<=this.Qd&&80564>=this.Qd&&!(this.ha&2048)!=(103!=this.ya(this.ea))&&(c^=-65536);this.J=this.J&~c|this.J+(this.P&1024?-1:1)&c;this.A-=d;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Uh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Wh,this.ha&256||(this.A-=this.B.Vh));a--&&(Lg(this,this.pa,this.J&c,this.D),this.J=this.J&~c|this.J+(this.P&1024?-this.X: +this.X)&c,this.I=this.I&~c|this.I-b&c,this.A-=d,a&&(fg(this),this.M|=256))},function(){var a=1,b=0,c=this.xa,d=this.B.Bh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Dh,this.ha&256||(this.A-=this.B.Ch));if(a--){var e=this.ya(this.Ga.Bb(this.K&c,1));this.D=this.D&-256|e;this.K=this.K&~c|this.K+(this.P&1024?-1:1)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Bh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Dh,this.ha&256||(this.A-=this.B.Ch));if(a--){var e= +re(this,this.Ga,this.K&c);this.D=this.D&~this.R|e;this.K=this.K&~c|this.K+(this.P&1024?-this.X:this.X)&c;this.I=this.I&~c|this.I-b&c;this.A-=d;a&&(fg(this),this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Oh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Qh,this.ha&256||(this.A-=this.B.Ph));if(a--){var e=this.D&255,f=Bg(this,this.pa,this.J);this.F=this.C;Gi.call(this,e,f);this.J=this.J&~c|this.J+(this.P&1024?-1:1)&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this), +this.M|=256)}},function(){var a=1,b=0,c=this.xa,d=this.B.Oh;this.ha&192&&(a=this.I&c,b=1,d=this.B.Qh,this.ha&256||(this.A-=this.B.Ph));if(a--){var e=this.D&this.R,f=Dg(this,this.pa,this.J&c);this.F=this.C;Hi.call(this,e,f);this.J=this.J&~c|this.J+(this.P&1024?-this.X:this.X)&c;this.I=this.I&~c|this.I-b&c;this.A-=d-this.B.Mb;a&&kg(this)==(this.ha&64)&&(fg(this),this.M|=256)}},function(){this.D=this.D&-256|this.sa();this.A-=this.B.Yb},function(){this.I=this.I&-256|this.sa();this.A-=this.B.Yb},function(){this.L= +this.L&-256|this.sa();this.A-=this.B.Yb},function(){this.H=this.H&-256|this.sa();this.A-=this.B.Yb},function(){this.D=this.D&-65281|this.sa()<<8;this.A-=this.B.Yb},function(){this.I=this.I&-65281|this.sa()<<8;this.A-=this.B.Yb},function(){this.L=this.L&-65281|this.sa()<<8;this.A-=this.B.Yb},function(){this.H=this.H&-65281|this.sa()<<8;this.A-=this.B.Yb},function(){this.D=this.D&~this.R|this.Ha();this.A-=this.B.Yb},function(){this.I=this.I&~this.R|this.Ha();this.A-=this.B.Yb},function(){this.L=this.L& +~this.R|this.Ha();this.A-=this.B.Yb},function(){this.H=this.H&~this.R|this.Ha();this.A-=this.B.Yb},function(){ne(this,y(this)&~this.R|this.Ha());this.A-=this.B.Yb},function(){this.N=this.N&~this.R|this.Ha();this.A-=this.B.Yb},function(){this.K=this.K&~this.R|this.Ha();this.A-=this.B.Yb},function(){this.J=this.J&~this.R|this.Ha();this.A-=this.B.Yb},Sk,Tk,Sk,Tk,function(){this.la.call(this,Ui)},function(){this.la.call(this,Si)},function(){this.M|=1;this.kd.call(this,$k,this.sa)},function(){this.M|= +1;this.mb.call(this,$k,this.Ha)},Uk,Vk,Uk,Vk,function(){if(this.P&131072&&3>this.lc)x.call(this,13,0);else{var a=this.B.ak;this.Sc=-1;nk.call(this,3,null,a)}},function(){var a=this.sa();if(this.P&131072&&3>this.lc)x.call(this,13,0);else{a:{var b=this.Tf[a];if(void 0!==b)for(var c=0;cthis.lc)x.call(this,13,0);else{var a= +this.B.bk;this.Sc=-1;nk.call(this,4,null,a)}else this.A-=this.B.ck},function(){if(this.P&131072&&3>this.lc)x.call(this,13,0);else{this.Tc=this.U.T;this.ta=this.Ca;this.A-=this.B.Zj;if(this.ra&1&&this.P&16384){var a=this.ja(this.ka.ua+0);oe(this.ba,a,!1)}else{a=this.Pa;var b=le(this),c=le(this),d=le(this);if(this.P&131072)d=d&131071|this.P&-131072;else if(d&131072){var e=le(this),f=le(this),g=le(this),h=le(this),k=le(this),m=le(this);pe(this,!0,!0);me(this,f);ne(this,e);ue(this,g);te(this,h);this.Ka.load(k); +this.La.load(m)}null!=ze(this,b,c,!1)&&(ye(this,d,a),this.Wf&&Yf(this,this.ea))}this.Tc=this.ta=-1}},function(){this.kd.call(this,Pk,hk)},function(){this.mb.call(this,2==this.X?Qk:Rk,hk)},function(){this.kd.call(this,Pk,ik)},function(){this.mb.call(this,2==this.X?Qk:Rk,ik)},function(){var a=this.sa();if(a){var b=this.D&255;this.D=this.D&-65536|b/a<<8|b%a;ng(this,this.D,128);this.A-=this.B.Ej}else qk.call(this)},function(){var a=this.D&255,b=(this.D>>8&255)*this.sa()|0,c=a+b|0;this.D=this.D&-65536| +c&255;gg(this,a,b,c,191);this.A-=this.B.Dj},function(){this.D=this.D&-256|(hg(this)?255:0);this.A-=2},function(){this.D=this.D&-256|Bg(this,this.Ga,this.H+(this.D&255));this.A-=this.B.Dk},function(){Wk.call(this,216)},function(){Wk.call(this,217)},function(){Wk.call(this,218)},function(){Wk.call(this,219)},function(){Wk.call(this,220)},function(){Wk.call(this,221)},function(){Wk.call(this,222)},function(){Wk.call(this,223)},function(){var a=this.S(),b=this.I-1&this.xa;this.I=this.I&~this.xa|b;b&& +!kg(this)?(C(this,z(this)+a),this.A-=this.B.jk):this.A-=this.B.Eh},function(){var a=this.S(),b=this.I-1&this.xa;this.I=this.I&~this.xa|b;b&&kg(this)?(C(this,z(this)+a),this.A-=this.B.Fh):this.A-=this.B.Gh},function(){var a=this.S(),b=this.I-1&this.xa;this.I=this.I&~this.xa|b;b?(C(this,z(this)+a),this.A-=this.B.ik):this.A-=this.B.Eh},function(){var a=this.S();this.I&this.xa?this.A-=this.B.Gh:(C(this,z(this)+a),this.A-=this.B.Fh)},function(){var a=this.sa();zg(this,a,1,!0)&&(this.D=this.D&-256|Qc(this.oa, +a,1,this.ea-2)&255,this.A-=this.B.zh)},function(){var a=this.sa();zg(this,a,this.X,!0)&&(this.D=this.D&~this.R|Qc(this.oa,a,this.X,this.ea-2)&this.R,this.A-=this.B.zh)},function(){var a=this.sa();zg(this,a,1,!1)&&(Vc(this.oa,a,1,this.D&255,this.ea-2),this.A-=this.B.Nh)},function(){var a=this.sa();zg(this,a,this.X,!1)&&(Vc(this.oa,a,this.X,this.D&this.R,this.ea-2),this.A-=this.B.Nh)},function(){var a=this.Ha(),b=z(this);a=b+a;ve(this,b);C(this,a);this.A-=this.B.Ij},function(){var a=this.Ha();C(this, +z(this)+a);this.A-=this.B.Ah},function(){ze(this,this.Ha(),Mg(this));this.A-=this.B.ek},function(){var a=this.S();C(this,z(this)+a);this.A-=this.B.Ah},function(){var a=this.L&65535;zg(this,a,1,!0)&&(this.D=this.D&-256|Qc(this.oa,a,1,this.ea-1)&255,this.A-=this.B.yh)},function(){var a=this.L&65535;zg(this,a,this.X,!0)&&(this.D=this.D&~this.R|Qc(this.oa,a,this.X,this.ea-1)&this.R,this.A-=this.B.yh)},function(){var a=this.L&65535;zg(this,a,1,!1)&&(Vc(this.oa,a,1,this.D&255,this.ea-1),this.A-=this.B.Mh)}, +function(){var a=this.L&65535;zg(this,a,2,!1)&&(Vc(this.oa,a,this.X,this.D&this.R,this.ea-1),this.A-=this.B.Mh)},Xk,Xk,function(){this.M|=132;this.A-=this.B.Zc},function(){this.M|=68;this.A-=this.B.Zc},function(){this.P&131072?x.call(this,13,0):(this.ab|=4,this.A-=2,this.ca&&r(this,-2147483648)?(fg(this),rk(this.ca)):this.P&512||(this.ca&&fg(this),Gd(this)))},function(){hg(this)?pg(this):og(this);this.A-=2},function(){this.vc=!1;this.kd.call(this,bl,kk);this.vc&&(this.D=this.D&~this.R|this.Ea&this.R)}, +function(){this.vc=!1;this.mb.call(this,cl,kk);this.vc&&(this.D=this.D&~this.R|this.Ea&this.R,this.L=this.L&~this.R|this.cb&this.R)},function(){pg(this);this.A-=2},function(){og(this);this.A-=2},function(){this.Pa>this.lc?x.call(this,13,0):(this.P&=-513,this.A-=this.B.Gj)},function(){this.Pa>this.lc?x.call(this,13,0):(this.P|=512,this.M|=4,this.A-=2)},function(){this.P&=-1025;this.A-=2},function(){this.P|=1024;this.A-=2},function(){this.kd.call(this,Ce,kk)},function(){this.mb.call(this,De,kk)}],Kk= +[qi,dj,oi,fj,si,Rj,Zj,Gi],Yk=[ri,ej,pi,gj,ti,Sj,ak,Hi],Zk=[function(a,b){this.A-=-1===this.F?this.B.nc:this.B.vk;return b},Ji,Ji,Ji,Ji,Ji,Ji,Ji],$k=[function(a,b){this.A-=-1===this.F?this.B.mk:this.B.kk;return b},Ki,Ki,Ki,Ki,Ki,Ki,Ki],Pk=[function(a,b){var c=a;if(b&=this.Ra){if(b&=7){var d=a<>8-b)&255}else d=a<<7;sg(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ra){if(b&=7){var d=a<<8-b;c=(a>>>b|d)&255}else d=a;sg(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ra){var d= +tg(this);(b%=9)?(c=(a<>9-b)&255,d=a<>b|d<<8-b|a<<9-b)&255,d=a<<8-b):d<<=7;sg(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ra){var d=0;8>>b-1,a=b>>>1&255,ng(this,a,128,b&1,a&128);return a},Ki,function(a,b){if(b&=this.Ra)9>24>>b-1,a=b>>1&255,ng(this, +a,128,b&1);return a}],Qk=[function(a,b){var c=a;if(b&=this.Ra){if(b&=15){var d=a<>16-b)&65535}else d=a<<15;sg(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ra){if(b&=15){var d=a<<16-b;c=(a>>>b|d)&65535}else d=a;sg(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ra){var d=tg(this);(b%=17)?(c=(a<>17-b)&65535,d=a<>b|d<<16-b|a<<17-b)&65535,d=a<< +16-b):d<<=15;sg(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ra){var d=0;16>>b-1,a=b>>>1&65535,ng(this,a,32768,b&1,a&32768);return a},Ki,function(a,b){if(b&=this.Ra)17>16>>b-1,a=b>>1&65535,ng(this,a,32768,b&1);return a}],Rk=[function(a,b){var c=a;if(b&=this.Ra)c=a<>>32-b,sg(this,c,a<>>b|d;sg(this,c,d,-2147483648)}return c},function(a,b){var c=a;if(b&=this.Ra)c=tg(this),c=a<>>32-b>>>1,sg(this,c,a<>>b|c<<32-b|a<<32-b<<1,sg(this,c,a<<32-b,-2147483648);return c},function(a,b){var c=a;if(b&=this.Ra)a<<=b-1,c=a<<1,ng(this,c,-2147483648,a&-2147483648,(c^a)&-2147483648);return c},function(a,b){if(b&=this.Ra)b=a>>>b-1,a=b>>>1,ng(this,a,-2147483648,b&1,a&-2147483648);return a},Ki,function(a, +b){if(b&=this.Ra)b=a>>b-1,a=b>>1,ng(this,a,-2147483648,b&1);return a}],bl=[function(a,b){b=this.sa();ng(this,a&b,128);this.A-=-1===this.C?this.B.Yh:this.B.Xh;this.M|=2;return a},Ki,function(a){this.A-=-1===this.C?this.B.Cf:this.B.Bf;return a^255},function(a){var b=-a|0;gg(this,0,a,b,191,!0);this.A-=-1===this.C?this.B.Cf:this.B.Bf;return b&255},function(a){this.Ea=(this.D&255)*a&65535;this.Ea&65280?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.rk:this.B.qk;this.M|=2; +return a},function(a){var b=(this.D<<24>>24)*(a<<24>>24)|0;this.Ea=b&65535;127b?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.Wj:this.B.Vj;this.M|=2;return a},function(a,b){if(!a)return qk.call(this),a;var c=(b=this.D&65535)/a;if(255>24,d=(b=this.D<<16>>16)/c|0;if(d!=d<<24>>24||8086== +this.da&&-128==d)return qk.call(this),a;this.Ea=d&255|(b%c&255)<<8;this.vc=!0;this.A-=-1===this.C?this.B.Sj:this.B.Rj;this.M|=2;return a}],cl=[function(a,b){b=this.Ha();ng(this,a&b,this.Hb);this.A-=-1===this.C?this.B.Yh:this.B.Xh;this.M|=2;return a},Ki,function(a){this.A-=-1===this.C?this.B.Cf:this.B.Bf;return a^this.R},function(a){var b=-a|0;gg(this,0,a,b,this.Hb|63,!0);this.A-=-1===this.C?this.B.Cf:this.B.Bf;return b&this.R},function(a,b){2==this.X?(b=this.D&65535,b=b*a|0,this.Ea=b&65535,this.cb= +b>>16&65535):(Qi.call(this,a,this.D),80563==this.Qd&&68657152==this.D&&129==a&&(this.cb=0));this.cb?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.tk:this.B.sk;this.M|=2;return a},function(a,b){2==this.X?(b=this.D&65535,b=(b<<16>>16)*(a<<16>>16)|0,this.Ea=b&65535,this.cb=b>>16&65535,b=32767b):(Pi.call(this,a,this.D),b=this.cb!=this.Ea>>31);b?(og(this),qg(this)):(pg(this),rg(this));this.vc=!0;this.A-=-1===this.C?this.B.Yj:this.B.Xj;this.M|=2;return a},function(a, +b){if(2==this.X){if(!a)return qk.call(this),a;b=65536*(this.L&65535)+(this.D&65535);var c=b/a;if(65536<=c)return qk.call(this),a;this.Ea=c&65535;this.cb=b%a&65535}else{if(!dk.call(this,this.D,this.L,a))return qk.call(this),a;this.Ea|=0;this.cb|=0}this.vc=!0;this.A-=-1===this.C?this.B.Qj:this.B.Pj;this.M|=2;return a},function(a,b){if(2==this.X){if(!a)return qk.call(this),a;var c=a<<16>>16,d=(b=this.L<<16|this.D&65535)/c|0;if(d!=d<<16>>16||8086==this.da&&-32768==d)return qk.call(this),a;this.Ea=d&65535; +this.cb=b%c&65535}else{b=this.D;c=this.L;d=a;var e=0,f=0;0>d&&(d=-d|0,e=1-e);0>c&&(b=-b|0,c=~c+(b?0:1)|0,f=1,e=1-e);!dk.call(this,b,c,d)||this.Ea>2147483647+e||this.cb>2147483647+f?b=!1:(e&&(this.Ea=-this.Ea),f&&(this.cb=-this.cb),b=!0);if(!b)return qk.call(this),a;this.Ea|=0;this.cb|=0}this.vc=!0;this.A-=-1===this.C?this.B.Uj:this.B.Tj;this.M|=2;return a}],Ce=[function(a){var b=a+1|0;gg(this,a,1,b,190);this.A-=-1===this.C?this.B.Af:this.B.zf;return b&255},function(a){var b=a-1|0;gg(this,a,1,b,190, +!0);this.A-=-1===this.C?this.B.Af:this.B.zf;return b&255},Ki,Ki,Ki,Ki,Ki,Ki],De=[function(a){var b=a+1|0;gg(this,a,1,b,this.Hb|62);this.A-=-1===this.C?this.B.Af:this.B.zf;return b&this.R},function(a){var b=a-1|0;gg(this,a,1,b,this.Hb|62,!0);this.A-=-1===this.C?this.B.Af:this.B.zf;return b&this.R},function(a){ve(this,z(this));C(this,a);this.A-=-1===this.C?this.B.Mj:this.B.Lj;this.M|=2;return a},function(a){if(-1===this.C)return Ki.call(this,a);this.ta=this.Ca;mk.call(this,a,this.ja(this.C+this.X)); +this.A-=this.B.Jj;this.M|=2;this.ta=-1;return a},function(a){C(this,a);this.A-=-1===this.C?this.B.gk:this.B.fk;this.M|=2;return a},function(a){if(-1===this.C)return Ki.call(this,a);ze(this,a,this.ja(this.C+this.X));this.A-=this.B.dk;this.M|=2;return a},function(a){var b=a;this.M&512&&(a=a-2&65535,80286>this.da&&(b=a));ve(this,b);this.A-=-1===this.C?this.B.Ic:this.B.xk;this.M|=2;return a},Ki];function jf(){this.la.call(this,Wj);this.A-=-1===this.C?6:13} +function nf(){this.Ba.call(this,Vj);this.A-=-1===this.C?12:19}var af=Array(256);af[0]=function(){16>(this.ya(this.ea)&56)&&(this.M|=1);this.mb.call(this,this.oj,kk)};af[1]=function(){this.ya(this.ea)&16||(this.M|=1);this.mb.call(this,dl,kk)};af[2]=function(){!(this.ra&1)||this.P&131072?x.call(this,6):this.la.call(this,Ri)};af[3]=function(){!(this.ra&1)||this.P&131072?x.call(this,6):this.la.call(this,Xi)}; +af[5]=function(){this.Pa?x.call(this,13,0,0,!0):(yg(this,this.ja(2054)),this.J=this.ja(2086),this.K=this.ja(2088),this.N=this.ja(2090),this.H=this.ja(2094),this.L=this.ja(2096),this.I=this.ja(2098),this.D=this.ja(2100),je(this.pa,2102,this.ja(2084)),je(this.ba,2108,this.ja(2082)),je(this.U,2114,this.ja(2080)),je(this.Fa,2120,this.ja(2078)),ye(this,this.ja(2072)),C(this,this.ja(2074)),ne(this,this.ja(2092)),this.Kb=this.ja(2126)|this.ya(2128)<<16,this.Jc=this.Kb+this.ja(2130),this.Qb=this.ja(2138)| +this.ya(2140)<<16,this.$c=this.Qb+this.ja(2142),je(this.Gb,2132,this.ja(2076)),je(this.ka,2144,this.ja(2070)),this.A-=195)};af[6]=function(){this.Pa?x.call(this,13,0):(this.ra&=-9,this.A-=2)};af[11]=Ie;af[166]=Ie;af[255]=Ie;var B=[];B[5]=Ie; +B[7]=function(){if(this.Pa)x.call(this,13,0,0,!0);else{var a=this.pa.Bb(this.J&this.xa,204);if(-1!==a){fk.call(this,this.ia(a));var b=this.ia(a+168),c=(b&24576)>>13;ye(this,this.ia(a+4),c);this.Kb=this.ia(a+112);this.Jc=this.Kb+this.ia(a+116);this.Qb=this.ia(a+100);this.$c=this.Qb+this.ia(a+104);he(this.Gb,this.ia(a+56),this.ia(a+120),this.ia(a+124),this.ia(a+128));he(this.ka,this.ia(a+52),this.ia(a+84),this.ia(a+88),this.ia(a+92));this.J=this.ia(a+12);this.K=this.ia(a+16);this.N=this.ia(a+20);this.H= +this.ia(a+28);this.L=this.ia(a+32);this.I=this.ia(a+36);this.D=this.ia(a+40);he(this.La,this.ia(a+60),this.ia(a+132),this.ia(a+136),this.ia(a+140));he(this.Ka,this.ia(a+64),this.ia(a+144),this.ia(a+148),this.ia(a+152));he(this.Fa,this.ia(a+68),this.ia(a+156),this.ia(a+160),this.ia(a+164));he(this.U,this.ia(a+72),b,this.ia(a+172),this.ia(a+176));he(this.ba,this.ia(a+76),this.ia(a+180),this.ia(a+184),this.ia(a+188));he(this.pa,this.ia(a+80),this.ia(a+192),this.ia(a+196),this.ia(a+200));C(this,this.ia(a+ +8));ne(this,this.ia(a+24))}this.A-=122<<(a&3?1:0)}};B[16]=Lk;B[17]=Mk;B[18]=Nk;B[19]=Ok;B[32]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa();switch((a&56)>>3){case 0:var b=this.ra;break;case 2:b=this.pd;break;case 3:b=this.wc;break;default:bf.call(this);return}vf(this,a&7,b);this.A-=6}};B[33]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;4==b||5==b?bf.call(this):(vf(this,a&7,this.Rb[b]),this.A-=22)}}; +B[34]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=uf(this,a&7);switch((a&56)>>3){case 0:fk.call(this,b);this.A-=10;break;case 2:this.pd=b;this.A-=4;break;case 3:this.wc=b;uc(this);this.A-=5;break;default:bf.call(this)}}};B[35]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;4==b||5==b?bf.call(this):(a=uf(this,a&7),a!=this.Rb[b]&&(Zf(this,!1),this.Rb[b]=a,Zf(this,!0)),this.A-=4>b?22:14)}}; +B[36]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;6>b?bf.call(this):(vf(this,a&7,this.Yf[b]),this.A-=12)}};B[38]=function(){if(this.Pa)x.call(this,13,0);else{var a=this.sa(),b=(a&56)>>3;6>b?bf.call(this):(this.Yf[b]=uf(this,a&7),this.A-=12)}};B[128]=function(){var a=this.Ha();mg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[129]=function(){var a=this.Ha();mg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)}; +B[130]=function(){var a=this.Ha();hg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[131]=function(){var a=this.Ha();hg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)};B[132]=function(){var a=this.Ha();kg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[133]=function(){var a=this.Ha();kg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)};B[134]=function(){var a=this.Ha();hg(this)||kg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua}; +B[135]=function(){var a=this.Ha();hg(this)||kg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)};B[136]=function(){var a=this.Ha();lg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[137]=function(){var a=this.Ha();lg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)};B[138]=function(){var a=this.Ha();ig(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[139]=function(){var a=this.Ha();ig(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)}; +B[140]=function(){var a=this.Ha();!lg(this)!=!mg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[141]=function(){var a=this.Ha();!lg(this)==!mg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[142]=function(){var a=this.Ha();kg(this)||!lg(this)!=!mg(this)?(C(this,z(this)+a),this.A-=this.B.Ta):this.A-=this.B.Ua};B[143]=function(){var a=this.Ha();kg(this)||!lg(this)!=!mg(this)?this.A-=this.B.Ua:(C(this,z(this)+a),this.A-=this.B.Ta)};B[144]=function(){gk.call(this,hj)}; +B[145]=function(){gk.call(this,hj)};B[146]=function(){gk.call(this,rj)};B[147]=function(){gk.call(this,sj)};B[148]=function(){gk.call(this,tj)};B[149]=function(){gk.call(this,uj)};B[150]=function(){gk.call(this,vj)};B[151]=function(){gk.call(this,wj)};B[152]=function(){gk.call(this,xj)};B[153]=function(){gk.call(this,yj)};B[154]=function(){gk.call(this,zj)};B[155]=function(){gk.call(this,Aj)};B[156]=function(){gk.call(this,Bj)};B[157]=function(){gk.call(this,Cj)};B[158]=function(){gk.call(this,Dj)}; +B[159]=function(){gk.call(this,Ej)};B[160]=function(){se(this,this.Ka.T,this.X,2);this.A-=this.B.se};B[161]=function(){this.ta=this.Ca;var a=le(this);this.Ka.load(a);this.A-=this.B.nc;this.ta=-1};B[163]=function(){this.Ba.call(this,Ci);-1!==this.C&&(this.A-=6)};B[164]=function(){this.Ba.call(this,2==this.X?Fj:Hj);this.A-=-1===this.C?3:7};B[165]=function(){this.Ba.call(this,2==this.X?Jj:Kj);this.A-=-1===this.C?3:7};B[168]=function(){se(this,this.La.T,this.X,2);this.A-=this.B.se}; +B[169]=function(){this.ta=this.Ca;var a=le(this);this.La.load(a);this.A-=this.B.nc;this.ta=-1};B[171]=function(){this.Ba.call(this,Fi);-1!==this.C&&(this.A-=5)};B[172]=function(){this.Ba.call(this,2==this.X?Lj:Nj);this.A-=-1===this.C?3:7};B[173]=function(){this.Ba.call(this,2==this.X?Pj:Qj);this.A-=-1===this.C?3:7};B[175]=function(){this.la.call(this,2==this.X?Mi:Oi)};B[178]=function(){this.la.call(this,Yi)};B[179]=function(){this.Ba.call(this,Ei);-1!==this.C&&(this.A-=5)}; +B[180]=function(){this.la.call(this,Vi)};B[181]=function(){this.la.call(this,Wi)}; +B[182]=function(){this.kc.call(this,$i);switch(this.fa>>3&7){case 0:this.D=this.D&~this.R|this.D&255;break;case 1:this.I=this.I&~this.R|this.I&255;break;case 2:this.L=this.L&~this.R|this.L&255;break;case 3:this.H=this.H&~this.R|this.H&255;break;case 4:this.Ac=this.Ac&~this.R|this.D>>8&255;this.D=this.Aa;break;case 5:this.N=this.N&~this.R|this.I>>8&255;this.I=this.Aa;break;case 6:this.K=this.K&~this.R|this.L>>8&255;this.L=this.Aa;break;case 7:this.J=this.J&~this.R|this.H>>8&255,this.H=this.Aa}this.A-= +-1===this.C?3:6};B[183]=function(){qe(this,2);this.la.call(this,aj);switch(this.fa>>3&7){case 0:this.D=this.D&65535;break;case 1:this.I=this.I&65535;break;case 2:this.L=this.L&65535;break;case 3:this.H=this.H&65535;break;case 4:this.Ac=this.Ac&65535;break;case 5:this.N=this.N&65535;break;case 6:this.K=this.K&65535;break;case 7:this.J=this.J&65535}this.A-=-1===this.C?3:6};B[186]=function(){this.mb.call(this,el,this.sa)};B[187]=function(){this.Ba.call(this,Di);-1!==this.C&&(this.A-=5)}; +B[188]=function(){this.la.call(this,wi)};B[189]=function(){this.la.call(this,xi)}; +B[190]=function(){this.kc.call(this,$i);switch(this.fa>>3&7){case 0:this.D=this.D&~this.R|(this.D&255)<<24>>24&this.R;break;case 1:this.I=this.I&~this.R|(this.I&255)<<24>>24&this.R;break;case 2:this.L=this.L&~this.R|(this.L&255)<<24>>24&this.R;break;case 3:this.H=this.H&~this.R|(this.H&255)<<24>>24&this.R;break;case 4:this.Ac=this.Ac&~this.R|this.D<<16>>24&this.R;this.D=this.Aa;break;case 5:this.N=this.N&~this.R|this.I<<16>>24&this.R;this.I=this.Aa;break;case 6:this.K=this.K&~this.R|this.L<<16>>24& +this.R;this.L=this.Aa;break;case 7:this.J=this.J&~this.R|this.H<<16>>24&this.R,this.H=this.Aa}this.A-=-1===this.C?3:6};B[191]=function(){qe(this,2);this.la.call(this,aj);switch(this.fa>>3&7){case 0:this.D=this.D<<16>>16;break;case 1:this.I=this.I<<16>>16;break;case 2:this.L=this.L<<16>>16;break;case 3:this.H=this.H<<16>>16;break;case 4:this.Ac=this.Ac<<16>>16;break;case 5:this.N=this.N<<16>>16;break;case 6:this.K=this.K<<16>>16;break;case 7:this.J=this.J<<16>>16}this.A-=-1===this.C?3:6}; +var $f=[function(){this.A-=2+(-1===this.C?0:1);return this.Gb.T},function(){this.A-=2+(-1===this.C?0:1);return this.ka.T},function(a){this.M|=2;this.Gb.load(a);this.A-=17+(-1===this.C?0:2);return a},function(a){this.M|=2;-1!==this.ka.load(a)&&(this.ib(this.ka.Ob+4,this.ka.ob|=512),this.ka.type|=512);this.A-=17+(-1===this.C?0:2);return a},function(a){this.M|=2;this.A-=14+(-1===this.C?0:2);if(-1!==this.zb.load(a)&&2048!=(this.zb.ob&2560)&&(this.zb.qc>=this.Pa&&this.zb.qc>=(a&3)||7168==(this.zb.ob&7168)))return xg(this), +a;vg(this);return a},function(a){this.M|=2;this.A-=14+(-1===this.C?0:2);if(-1!==this.zb.load(a)&&512==(this.zb.ob&2560)&&this.zb.qc>=this.Pa&&this.zb.qc>=(a&3))return xg(this),a;vg(this);return a},Ki,Ki],Ee=[Ze,Ze,Ze,Ze,Ze,Ze,Ki,Ki],dl=[function(a){if(-1===this.C)x.call(this,6);else{a=this.Jc-this.Kb;var b=this.Kb;80286==this.da?b|=-16777216:80386<=this.da&&2!=this.X&&(a|=b<<16);this.eb(this.C+2,b);this.A-=11}return a},function(a){if(-1===this.C)x.call(this,6);else{a=this.$c-this.Qb;var b=this.Qb; +80286==this.da?b|=-16777216:80386<=this.da&&2!=this.X&&(a|=b<<16);this.eb(this.C+2,b);this.A-=12}return a},function(a){-1===this.C||this.P&131072?x.call(this,6):(this.Kb=this.ia(this.C+2)&(this.R|this.R<<8),a&=65535,this.Jc=this.Kb+a,this.M|=2,this.A-=11);return a},function(a){-1===this.C||this.P&131072?x.call(this,6):(this.Qb=this.ia(this.C+2)&(this.R|this.R<<8),a&=65535,this.$c=this.Qb+a,this.M|=2,this.A-=12);return a},function(){this.A-=2+(-1===this.C?0:1);return this.ra},Ki,function(a){this.P& +131072?x.call(this,6):(yg(this,a),this.A-=-1===this.C?3:6,this.M|=2);return a},Ki],el=[Ki,Ki,Ki,Ki,yi,Bi,Ai,zi]; +function fl(a){pb.call(this,"ChipSet",a,32768);var b=a.model;b&&!gl[b]&&kb("Unrecognized ChipSet model: "+b);this.da=gl[b]||hl;this.B=[];b=il(a[jl]);this.B[0]=[b,b];null==b&&(this.L=[360,360],(b=a.floppies)&&b.length&&(this.L=b),kl(this,ll,this.L.length),kl(this,ml,a.monitor||(this.da=Yg&&(this.Ba=this.ka=2);this.M=a.scaleTimers||!1;this.Ra=a.dateRTC;this.Ka=this.La=!1;this.Ia=0;if(a=a.sound)this.Ia="number"!=typeof a||0>a|| +1e||1=Yg){this.D=Sl;this.J=0;this.I=Tl;this.pa=0;this.K=Ul|Vl;512<=Wl(this)&&(this.K|=Xl);+Yl(this,ml,void 0)==Zl&&(this.K|=$l);(this.da|0)==zl&&(this.K=this.K|am|bm);this.ra= +cm|dm;this.U=Array(8);this.N=0;a&&(this.A=Array(El));em(this,this.Ra);for(a=fm;a<=gm;a++)this.A[a]=0;for(a=hm;ac?c=c?c:12:c=(c-=12)?c+128:140,d=!0);a.A[Wd]&$m||(d&&128>8} +l.save=function(){var a=new ag(this);a.set(0,[this.B]);for(var b=[],c=0;c=Yg&&(a.set(5,[this.D,this.J,this.I,this.pa,this.K,this.ra]),a.set(6,[this.U[7],this.U,this.N,this.A,this.la,this.Z]));return a.data()}; +l.restore=function(a){var b;var c=a[0];Array.isArray(c[0])?this.B=c[0]:(this.B[0][0]=c[0],this.B[1][0]=c[1]&15,this.B[0][1]=c[2],this.B[1][1]=c[3]&15);Kl(this);c=a[1];for(b=0;b=f;f++){var g="pcjs-bitCell";f||(g+=" pcjs-bitCellLeft");d+='
    '+f+"
    \n"}e.innerHTML=d;ln(a,b,c,!0)}function mn(a,b,c){if(b=(a=nn[a.da|0])&&a[b])for(var d in b)if(a=b[d],a.zc&1<g.rb[0]&&(g.rb[0]=255,g.rb[1]--,0>g.rb[1]&&(g.rb[1]=255)));return h}function Bn(a,b,c,d,e,f){var g=a.F[b];r(a,768)&&t(a,d,e,f,"DMA"+b+".CHANNEL"+c+".COUNT["+g.Ab+"]",null,!0);a=g.oc[c];a.rb[g.Ab]=a.pc[g.Ab]=e;g.Ab^=1}function Cn(a,b,c,d){var e=a.F[b],f=e.Pb|Dn;e.Pb&=~En;r(a,768)&&t(a,c,null,d,"DMA"+b+".STATUS",f,!0);return f} +function Fn(a,b,c,d,e){var f=a.F[b];r(a,768)&&t(a,c,d,e,"DMA"+b+".REQ",null,!0);a=d&3;f.Pb=f.Pb&~(16<>2].oc[b&3],c,d,e)}function Jn(a,b,c){b=a.F[b>>2].oc[b&3];b.ig&&b.ah&&b.xg?(c&&(b.done=c),b.oe||Tn(a,b,!0)):c&&c(!0)} +function Tn(a,b,c){c&&(b.count=b.rb[1]<<8|b.rb[0],b.type=b.mode&Un,b.nj=b.jg=!1);for(var d=!1;0<=b.count&&(c=b.cg<<16|b.wb[1]<<8|b.wb[0],b.type==Vn?(d=!0,function(c){b.ah.call(b.ig,b.xg,-1,function(e,g){0>e&&(b.nj||(b.nj=!0),e=255);b.oe||a.oa.ub(c,e);(d=g)&&setTimeout(function(){Wn(b)||Tn(a,b)},0)})}(c)):b.type==Xn?(c=a.oa.ya(c),0>b.ah.call(b.ig,b.xg,c)&&(b.jg=!0)):b.type!=Yn&&(b.jg=!0)),!d&&!Wn(b););} +function Wn(a){if(!a.jg&&0<=--a.count&&(a.mode&Zn?(a.wb[0]--,0>a.wb[0]&&(a.wb[0]=255,a.wb[1]--,0>a.wb[1]&&(a.wb[1]=255))):(a.wb[0]++,255>3];b=1<<(b&7);d.cc&b||(d.cc|=b,d.Ue=c||0,oo(a))}function Zg(a,b){var c=a.ic[b>>3];b=1<<(b&7);c.cc&b&&(c.cc&=~b,oo(a))}function oo(a,b){var c=-1;if(1>=1),Md(a.G,e))),b==Bo&&c==Fo&&dn(a))}function Go(a,b,c,d){t(a,c,null,d,"PIT"+b+".CTRL",null,2048);return b?a.wa:a.ta} +function Ho(a,b,c,d,e){t(a,c,d,e,"PIT"+b+".CTRL",null,2048);e=0;c=d&Io;b?(e=3,a.wa=d):a.ta=d;if(c==Jo){if(!(d&Ko))for(c=0;2>=c;c++)if(d&Lo<=c;c++)d&Lo<>=Qo;f=d&Ro;var g=d&So;d&=To;if(d==Uo)Po(a,e+c);else{e+=c;var h=a.qa[e];h.Mf=d;h.mode=g;h.Wg=f;h.pc=[0,0];h.rb=[0,0];h.je=[0,0];h.fd=!1;h.Ke=!1;h.me=!1;h.Oe=!1;xo(a,e);b==Bo&&c==Co&&Zg(a,Do);b==Bo&&c==Fo&&255== +a.ic[0].sd&&a.H==(Vo|Wo|Xo|Yo)&&(b=a.qa[0],b.Oc[0]=b.pc[0],b.Oc[1]=b.pc[1],b.hd=Jd(a.G,a.M))}}}function Eo(a,b){a=a.qa[b];(b=a.pc[1]<<8|a.pc[0])||(b=1==a.Yc?256:65536);return b}function Ud(a,b){a=a.qa[b];(b=a.Oc[1]<<8|a.Oc[0])||(b=1==a.Yc?256:65536);return b}function Po(a,b){Dl(a,b);var c=a.qa[b];c.je[0]=c.rb[0];c.je[1]=c.rb[1];c.Ke=!0;xo(a,b)}function xo(a,b){a=a.qa[b];a.vd=a.Mf==Zo?1:0;a.Yc=a.Mf==$o?2:1} +function Dl(a,b,c){var d=a.qa[b];if(d.me&&(b!=Fo||a.H&Vo)){var e=Jd(a.G,a.M),f=(e-d.hd)/a.Ea|0;0>f&&(d.hd=e,f=0);var g=Eo(a,b),h=Ud(a,b)-f;d.mode==zo?(0>=h&&(h=0),h||(d.fd=!0,d.me=!1,b||mh(a,Do))):d.mode==ap?(d.fd=1!=h,0>=h&&(h=g+h,0>=h&&(h=g),d.Oc[0]=h&255,d.Oc[1]=h>>8&255,d.hd=e,!b&&d.fd&&mh(a,Do))):d.mode==Vd&&(h-=f,0>=h&&(d.fd=!d.fd,h=g+h,0>=h&&(h=g),d.Oc[0]=h&255,d.Oc[1]=h>>8&255,d.hd=e,!b&&d.fd&&mh(a,Do)));d.rb[0]=h&255;d.rb[1]=h>>8&255;c&&(a.hd=0)}return d} +function Td(a,b){for(var c=0;c=Yg){b=a.G.Y.Yd;c=Jd(a.G,a.M);null==a.Ca&&(a.la=Jd(a.G,a.M),a.Pa=1024,a.Ca=Math.floor(a.G.Y.Yd/a.Pa),bn(a));c>=a.Z&&(a.A[Ym]|=bp,a.A[Wd]&Xd&&(a.A[Ym]|=cp,mh(a,dp)),a.Z=c+a.Ca);a.A[qm]==a.A[rm]&&a.A[sm]==a.A[tm]&&a.A[um]==a.A[vm]&&(a.A[Ym]|=ep,a.A[Wd]&fp&&(a.A[Ym]|=cp,mh(a,dp)));var d=c-a.la,e=Math.floor(d/b);if(e&&!(a.A[Wd]&gp)){for(;e--;)if(60<=++a.A[qm]&&(a.A[qm]=0,60<=++a.A[sm]&&(a.A[sm]=0,24<=++a.A[um]))){a.A[um]=0;a.A[wm]=a.A[wm]% +7+1;var f=a.A[zm];var g=Ka[a.A[ym]-1];28==g&&0===f%4&&(f%100||0===f%400)&&g++;f=g;++a.A[xm]>f&&(a.A[xm]=1,12<++a.A[ym]&&(a.A[ym]=1,a.A[zm]=(a.A[zm]+1)%100))}a.A[Wm]|=an;a.A[Ym]|=hp;a.A[Wd]&ip&&(a.A[Ym]|=cp,mh(a,dp))}a.la=c-d%b}}l.Am=function(a,b){var c=this.Aa;this.ha&jp&&(this.H&kp?c=this.B[0][1]:this.C&&(c=lp(this.C)));t(this,a,null,b,"PPI_A",c);return c};l.no=function(a,b,c){t(this,a,b,c,"PPI_A");this.Aa=b};l.Bm=function(a,b){var c=this.H;t(this,a,null,b,"PPI_B",c);return c}; +l.oo=function(a,b,c){t(this,a,b,c,"PPI_B");mp(this,b)};function mp(a,b){var c=!!(b&np),d=!!(a.H&np);a.H=b;a.C&&op(a.C,!(b&kp),!!(b&Yo));c!=d&&dn(a,c)}l.Cm=function(a,b){var c=0;c=(this.da|0)==Il?this.H&Wo?c|this.B[1][1]&pp:c|this.B[1][1]>>4&1:this.H&qp?c|this.B[0][1]>>4:c|this.B[0][1]&15;this.H&Vo&&Dl(this,Fo).fd&&(c=this.H&np?c|rp:c|sp);t(this,a,null,b,"PPI_C",c,32896);return c};l.po=function(a,b,c){t(this,a,b,c,"PPI_C");this.Fa=b};l.Dm=function(a,b){var c=this.ha;t(this,a,null,b,"PPI_CTRL",c);return c}; +l.qo=function(a,b,c){t(this,a,b,c,"PPI_CTRL");this.ha=b};l.Il=function(a,b){var c=this.C?lp(this.C):0;t(this,a,null,b,"8041_KBD",c);this.ea&=~tp;return c};l.tn=function(a,b,c){t(this,a,b,c,"8041_KBD")};l.Hl=function(a,b){var c=this.H;t(this,a,null,b,"8041_CTRL",c);return c};l.sn=function(a,b,c){t(this,a,b,c,"8041_CTRL");mp(this,b)};l.Jl=function(a,b){var c=this.ea;t(this,a,null,b,"8041_STATUS",c);return c}; +l.Kl=function(a,b){var c=this.pa;t(this,a,null,b,"8042_OUTBUFF",c,16384);this.D&=~(tp|up);this.C&&vp(this.C);return c}; +l.vn=function(a,b,c){t(this,a,b,c,"8042_INBUF.DATA",null,16384);if(this.D&wp)switch(this.J){case xp:yp(this,b);break;case zp:Ap(this,b);break;default:if(yp(this,this.I&~Tl),this.C){a=this.C;c=b;var d=-1;r(a)&&Tb(a,"sendCmd("+va(c)+")");switch(a.H||c){case Bp:d=Cp;Dp(a);break;case Ep:a.H&&(c=0);Fp(a,Cp);a.H=c;break;case Gp:a.H&&(c=0);Fp(a,Cp);a.H=c;break;default:Tb(a,"sendCmd(): unrecognized command")}Hp(this,d)}}this.J=b;this.D&=~wp}; +l.Ll=function(a,b){var c=this.H&~(Ip|Jp)|(Jd(this.G)&64?Jp:0);t(this,a,null,b,"8042_RWREG",c,16384);return c};l.wn=function(a,b,c){t(this,a,b,c,"8042_RWREG",null,16384);mp(this,b)};l.Ml=function(a,b){t(this,a,null,b,"8042_STATUS",this.D,16384);a=this.D&255;this.D&up&&(this.D|=tp,this.D&=~up);return a}; +l.un=function(a,b,c){t(this,a,b,c,"8042_INBUFF.CMD",null,16384);this.J=b;this.D|=wp;a=0;this.J>=Kp&&(a=this.J^15,this.J=Kp);switch(this.J){case Lp:Hp(this,this.I);break;case Mp:yp(this,this.I|Tl);break;case Np:yp(this,this.I&~Tl);this.C&&vp(this.C);break;case Op:this.C&&(a=this.C,a.A=[],r(a)&&Tb(a,"scan codes flushed"));yp(this,this.I|Tl);Hp(this,Pp);Ap(this,cm|dm);break;case Qp:Hp(this,Rp);break;case Sp:Hp(this,this.K);break;case Tp:Hp(this,this.ra);break;case Up:Hp(this,this.I&Tl?0:Vp);break;case Kp:a& +1&&of(this.G)}};function yp(a,b){a.I=b;a.D=a.D&~Wp|b&Xp;a.C&&op(a.C,!!(b&Yp),!(b&Tl))}function Hp(a,b,c){0<=b&&(a.pa=b,c?a.D|=tp:(a.D&=~tp,a.D|=up))}function Ap(a,b){a.ra=b;qc(a.oa,!!(b&dm));b&cm||of(a.G)}function Zp(a,b){a.da>4)+(c&15),e=!0);if(d==um||d==vm)e&&23=c?c=12==c?0:c:(c-=116,c=24==c?12:c))}}else c=b;this.A[d]=c;d==Wd&&a&Xd&&b&Xd&&bn(this)};l.Ik=function(a,b,c){t(this,a,b,c,"NMI");this.fa=b};l.Zn=function(a,b,c){t(this,a,b,c,"FPU.CLEAR")};l.$n=function(a,b,c){t(this,a,b,c,"FPU.RESET");this.Kc&&Tg(this.Kc)}; +l.Rm=function(a){if(r(this,16)&&al(this.ca,26,a)){var b=this.G.D>>8;Xf(this.G,a,function(a,d){return function(c){d=Jd(a.G)-d;var e=a.G.L&255,g=a.G.L>>8,h=a.G.L&255,k=a.G.L>>8;if(2==b||3==b)var m=" CH(hour)="+wa(g)+" CL(min)="+va(e)+" DH(sec)="+va(k);else if(4==b||5==b)m=" CX(year)="+wa(a.G.I)+" DH(month)="+va(k)+" DL(day)="+va(h);e=a.ca;g=d;e.message("INT "+va(26)+": C="+(hg(e.G)?1:0)+(m||"")+" (cycles="+g+(c?",level="+(c+1):"")+")")}}(this,Jd(this.G)))}return!0}; +function dn(a,b){if(a.P){void 0!==b?a.Ka=b:b=!!(a.Ka&&a.G&&a.G.aa.Xa);var c=Math.round(pl/Eo(a,Fo));if(20>c||2E4>>4,0,this.H,this.C,this.Id),delete this.Id);return!0};hq.prototype.Zb=function(){return!0}; +function iq(a,b,c,d){if(d)a.Da("Unable to load system ROM (error "+d+": "+b+")",0>d);else{rb(a.de,b,c);if("["==c.charAt(0)||"{"==c.charAt(0))try{var e=eval("("+c+")"),f=e.bytes,g=e.longs||e.data;if(f)a.A=f;else if(g)for(a.A=Array(4*g.length),d=c=0;c>8&255,a.A[d++]=g[c]>>16&255,a.A[d++]=g[c]>>24&255;else a.A=e;a.Id=e.symbols;if(!a.A.length){kb("Empty ROM: "+b);return}if(1==a.A.length){kb(a.A[0]);return}}catch(h){a.Da("ROM data error: "+h.message);return}else for(b= +c.replace(/\n/gm," ").replace(/ +$/,"").split(" "),a.A=Array(b.length),e=0;e>>d.A].bf(e&d.D,a.A[c]&255,e)}b=!0}else b=!1;if(b){b=[];"number"==typeof a.F?b.push(a.F):null!=a.F&&a.F.length&&(b=a.F);for(c=0;cthis.B?fm:23,c=a.A[b]|a.A[b+1]<<8;c+=this.A>>10;a.A[b]=c&255;a.A[b+1]=c>>8;pm(a)}}else kb("No RAM allocated")}; +l.save=function(){var a=new ag(this);this.controller&&a.set(0,this.controller.save());return a.data()};l.restore=function(a){return this.controller?this.controller.restore(a[0]):!0};function pq(a){this.D=a;this.C=rq;this.G=sq;this.B=tq;this.A=null}l=pq.prototype;l.save=function(){return[this.C,this.B]};l.restore=function(a){this.ub(0,a[0]&255);this.ub(2,a[1]&255);return!0};l.ya=function(a){var b=255;2>a?b=a&1?this.G>>8:this.G&255:4>a&&(b=a&1?this.B>>8:this.B&255);return b}; +l.ub=function(a,b){if(a)2==a&&(this.B=this.B&-256|b);else if(b!=(this.C&255)){a=this.D.oa;if(b&uq)this.A&&(yc(a,vq,wq,this.A),this.A=null);else{this.A||(this.A=zc(a,vq,wq));var c=zc(a,xq,wq);yc(a,vq,wq,c,b&yq?1:Gc)}this.C=this.C&-256|b}};l.rj=function(){return zq};l.bh=function(){return Aq};var qq=-2134900736,xq=16646144,vq=917504,wq=131072,uq=1,yq=2,rq=65535,sq=2575,tq=2,zq=[null,0],Aq=[function(a){return this.controller.ya(a)},null,null,function(a,b){this.controller.ub(a,b)},null,null]; +cb(function(){for(var a=zb(document,"pcx86","ram"),b=0;b=n.Hd&&d<=n.z&&(d-=n.Hd-n.ee),d=Mq[e]==d),d){(a=a.ma["key-"+e])&&void 0!==c&&(a.style.color=c?"#ffffff":"#000000",a.style.backgroundColor=c?"#000000":"#ffffff");break}}}l.tc=function(a,b,c,d){this.na=a;this.oa=b;this.G=c;this.ca=d;var e=this;this.qa=Cd(this.G,this.id+".inject",function(){Pq(e)});this.V=ac(a,"ChipSet");this.I=Bd(a,"autoType")||this.I;Wf(c,33,this.Sm.bind(this))}; +l.Sm=function(){if(10==(this.G.D>>8&255))if(this.P=!0,this.L)this.L(),this.L=null,this.P=!1;else{var a=this.I;!this.F&&a&&(this.F=a,this.gh(this.F))}return!0};function Cq(a,b){var c=0;a.da=null;"string"==typeof b&&(a.da=b.toUpperCase(),c=Qq.indexOf(a.da),0>c&&(c=0));if(b=Qq[c])a.ka=parseInt(b.substr(2),10)}function Dp(a){Tb(a,"keyboard reset",65792);a.A=[];Fp(a,Rq)}function op(a,b,c){a.N!==c&&(a.N=a.U=c)&&(a.J=!0);a.K!==b&&(a.K=b)&&!a.U&&aq(a,!0);a.K&&a.U&&(Dp(a),a.U=!1)} +function Fp(a,b){a.V&&(a.A.unshift(b),a.J=!0,Zp(a.V,b))}function vp(a){var b=0;a.A.length&&a.J&&(b=a.A[0],a.V&&Zp(a.V,b));r(a)&&Tb(a,b?"scan code "+va(b)+" available":"no scan codes available")}function lp(a){var b=0;a.A.length&&(b=a.A[0]);r(a)&&Tb(a,"scan code "+va(b)+" delivered");return b}function aq(a,b){0>=1);if(b&Vq){if(!1===d)return!0;d=null}null==d?d=!((c?a.D:a.jc)&b):d||b&Wq&&(b=Wq);if(c){a.D&=~b;d&&(a.D|=b);c=b;var f,g;for(g in Xq)d="led-"+g,e=Xq[g],c&&c!=e||!(f=a.ma[d])||(f.style.backgroundColor=a.D&e?"#00ff00":"#000000")}else a.jc&=~b,d&&(a.jc|=b);return!0}}return!1} +function Gq(a,b,c){if((N[b]||N[b+=1E3])&&a.G&&a.G.aa.Xa){Tq[b]&&a.B.length&&0e||(e==a.B.length&&(d={},d.ve=b,d.jc=a.jc,Oq(a,b,!0),e++),0b.zd){if(!b.nf){Nq(a,b.ve);return}b.nf=!1;var c=a.la}else c=1==b.zd++?500:100;b.li=setTimeout(function(a){return function(){Yq(a,b)}}(a),c)}} +function $q(a,b,c){var d=b;if(b>=n.ee&&b<=n.Zf)!(a.jc&(ar|br|cr))==c&&(d=b+(n.Hd-n.ee));else if(b>=n.Hd&&b<=n.z)!!(a.jc&(ar|br|cr))==c&&(d=b-(n.Hd-n.ee));else if(!!(a.jc&(ar|br))==c){if(a=pa[b])d=a}else if(a=na[b])d=a;return d}l.yg=function(a){a||(this.jc&=~Wq)}; +function Dq(a,b,c){var d=!0,e=!1,f=!1,g=b.keyCode;if(!Eq(a.na))return!1;a.C="";Db(a.de);var h=$q(a,g,!0);a.$g&&h==n["`"]&&(g=h=27);if(N[g+1E3])if(h+=1E3,2==b.location&&(h+=2E3),Lq(a,h,!1,c)){if(20==g||144==g||145==g)a.ha||(c=e=!0);if(!(c||91!=g&&93!=g))for(var k=0;k=n.ee&&b<=n.Zf||b>=n.Hd&&b<=n.z;e>>>=8;){var g=0,h=e&255;f==mr||f==nr?d.push(f|(c?0:lr)):(h==O?a.D&(ar|br)||a.D&cr&&b||(g=h):h==or?a.D&(dr|pr)||(g=h):h==qr?a.D&(er|rr)||(g=h):d.push(f|(c?0:lr)),g&&(c?d.unshift(g):d.push(g|lr)))}for(c=0;c"]]=52|O<<8;N[n["/"]]=53; +N[n["?"]]=53|O<<8;N[3016]=54;N[1044]=55;N[1018]=qr;N[1032]=57;N[Hq]=58;N[1112]=59;N[1113]=60;N[1114]=61;N[1115]=62;N[1116]=63;N[1117]=64;N[1118]=65;N[1119]=66;N[1120]=67;N[1121]=68;N[Iq]=69;N[Jq]=70;N[1036]=71;N[1038]=72;N[1033]=73;N[1109]=74;N[1037]=75;N[1101]=76;N[1039]=77;N[1107]=78;N[1035]=79;N[1040]=80;N[1034]=81;N[1045]=82;N[1046]=kr;N[4027]=84;N[1122]=87;N[1123]=88;N[1091]=91;N[1093]=93;N[1224]=91;N[ur]=46|or<<8;N[fr]=70|or<<8;N[4046]=kr|or<<8|qr<<16;N[4045]=82|or<<8|qr<<16; +N[4013]=28|or<<8|qr<<16;var Bp=255,Ep=243,Gp=237,Rq=170,Cp=250,tr=255,sr=20;cb(function(){for(var a=zb(document,"pcx86","keyboard"),b=0;bc.length)c=[!1,0,null,null,0,Array(b>2,32768));this.rc=c[0];this.Uc=c[1];this.Ye=c[2];this.ga=c[3];this.gc=c[4]&255;this.Cg=c[4]>>8&255;this.$a=c[5];this.mh=xr;this.bg=zr;this.$d=this.$a[Ar]|this.$a[Br]<<8;this.ag=63;if(b>=lq){this.ag=255; +this.mh=yr;this.bg=Cr;b=c[6];void 0===b&&(b=[!1,0,Array(Dr),0,f==Zl?0:Er,0,0,Array(Fr),0,0,0,Array(Gr),0,[this.fb,this.Tb,this.ud],Array(this.ud>>2),Hr|Ir|Jr|Kr|Lr,0,-1,0,-1,0,-1,0,0,0,0,Mr,Nr,0,0,Or,Array(Pr)]);this.Je=b[0];this.Bd=b[1];this.Dc=b[2];this.Qg=Qr;this.Fg=b[3];this.$e=b[4];this.Lf=b[5];this.Ed=b[6];this.be=b[7];this.Sg=Rr;this.Rk=b[8];this.Sk=b[9];this.Dd=b[10];this.Cd=b[11];this.Rg=Sr;this.xb=b[12];d=b[13];"number"==typeof d&&(d=[this.fb,this.Tb,d]);this.fb=d[0];this.Tb=d[1];d=this.ud>> +2;if((this.dd=b[14])&&this.dd.length=lq){var c=[];c[0]=a.Je;c[1]=a.Bd;c[2]=a.Dc;c[3]=a.Fg;c[4]=a.$e;c[5]=a.Lf;c[6]=a.Ed;c[7]=a.be;c[8]=a.Rk;c[9]=a.Sk;c[10]=a.Dd;c[11]=a.Cd;c[12]=a.xb;c[13]=[a.fb,a.Tb,a.ud];var d;if(d=a.dd){var e=0,f=[];if(void 0!==d[0])for(var g=0;2>g;g++)for(var h=g;h>1;f[e++]=k;h=m}f.length=lq){var d=0,e=0,f=0;switch(b){case as:d=bs;a.Ma==nq&&(e=cs);break;case ds:a.Ma==lq&&(d=es);break;case fs:d=gs;a.Ma==nq&&(e=hs);break;case is:d=js;a.Ma==nq&&(e=ks);break;case ls:d=ms;a.Ma==nq&&(f=ns);break;case os:d=ps,a.Ma==nq&&(f=qs)}d&&(c|=a.$a[rs]&d?256:0,c|=a.$a[rs]&e?512:0,c|=a.$a[ss]&f?512:0)}return c} +var Br=12,Ar=13,xr=18,as=6,rs=7,bs=1,js=2,gs=4,ms=8,ps=16,es=32,cs=32,ks=64,hs=128,ss=9,ns=32,qs=64,ds=10,fs=16,is=18,ls=21,os=24,yr=25,ts={},us=(ts[0]=255,ts[1]=255,ts[2]=255,ts[3]=15,ts[4]=127,ts[5]=31,ts[6]=127,ts[7]=127,ts[8]=3,ts[9]=31,ts[10]=127,ts[11]=31,ts[Br]=63,ts[Ar]=255,ts[14]=63,ts[15]=255,ts[16]=63,ts[17]=255,ts),zr="HTOTAL HDISP HSPOS HSWIDTH VTOTAL VTOTADJ VDISP VSPOS ILMODE MAXSCAN CURSTART CUREND STARTHIGH STARTLOW CURHIGH CURLOW PENHIGH PENLOW".split(" "),Cr="HTOTAL HDEND HBSTART HBEND HRSTART HREND VTOTAL OVERFLOW PRESCAN MAXSCAN CURSTART CUREND STARTHIGH STARTLOW CURHIGH CURLOW VRSTART VREND VDEND OFFSET UNDERLINE VBSTART VBEND MODECTRL LINECOMP".split(" "), +Dr=20,Qr="PAL00 PAL01 PAL02 PAL03 PAL04 PAL05 PAL06 PAL07 PAL08 PAL09 PAL0A PAL0B PAL0C PAL0D PAL0E PAL0F MODE OVERSCAN PLANES HPAN".split(" "),Er=1,Mr=1,Fr=5,Rr=["RESET","CLOCKING","MAPMASK","CHARMAP","MEMMODE"],Nr=255,Or=0,Pr=256,Gr=9,Sr="SRESET ESRESET COLORCMP DATAROT READMAP MODE MISC COLORDC BITMASK".split(" "),Hr=1024,Ir=4096,Yr=65280,Jr=0,Kr=16,$r=255,Lr=-2147483648,Tr=[];Tr[2]=Hr;Tr[3]=Hr|Ir;Tr[16]=1280;Tr[512]=Jr;Tr[1024]=Jr|32;Tr[1536]=Jr|96;Tr[2560]=Jr|160;Tr[3584]=Jr|224;Tr[768]=Jr|Kr; +Tr[4096]=1;Tr[8192]=2;Tr[24576]=98;Tr[40960]=162;Tr[57344]=226;var Zr=[];Zr[Hr]=function(a){a+=this.G;return(this.controller.xb=this.W[a])>>this.controller.bi&255};Zr[Hr|16384]=function(a){return(this.controller.xb=this.W[(a&-4)+this.G])>>((a&3)<<3)&255};Zr[Hr|Ir]=function(a){a+=this.G;var b=this.controller.xb=this.W[a&-2];return(a&1?b>>8:b)&255}; +Zr[1280]=function(a){a+=this.G;a=this.controller.xb=this.W[a];for(var b=this.controller.oh,c=this.controller.nh&b,d=0,e=128;e;)(a&b)==c&&(d|=e),c>>>=1,b>>>=1,e>>=1;return d};Zr[Jr]=function(a,b){a+=this.G;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Zd;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; +Zr[Jr|32]=function(a,b){a+=this.G;b=b>>this.controller.Pc|b<<8-this.controller.Pc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Zd;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; +Zr[Jr|96]=function(a,b){a+=this.G;b=b>>this.controller.Pc|b<<8-this.controller.Pc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Zd;b&=this.controller.xb;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; +Zr[Jr|160]=function(a,b){a+=this.G;b=b>>this.controller.Pc|b<<8-this.controller.Pc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Zd;b|=this.controller.xb;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; +Zr[Jr|224]=function(a,b){a+=this.G;b=b>>this.controller.Pc|b<<8-this.controller.Pc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Md|this.controller.Zd;b^=this.controller.xb;b=b&this.controller.Db|this.controller.xb&~this.controller.Db;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)};Zr[Jr|4]=function(a,b){var c=(a&-4)+this.G;a=(a&3)<<3;b=b<>this.controller.Pc|b<<8-this.controller.Pc&255;b=(b|b<<8|b<<16|b<<24)&this.controller.Db;b=this.controller.Ef&b|this.controller.xb&~b;b=b&this.controller.kb|this.W[a]&~this.controller.kb;this.W[a]!=b&&(this.W[a]=b,this.Oa=!0)}; +function Q(a,b,c,d,e){pb.call(this,"Video",a,262144);var f=this,g;this.$c=Ua("Gecko/");this.da=a.model;var h=ws[this.da]||ws.mda;this.Ma=h[0];this.ud=a.memory||0;this.nd=a.switches;this.Sb=a.randomize;null==this.Sb&&(this.Sb=1);this.ea=a.mode;if(null==this.ea||null==xs[this.ea])this.ea=h[1];this.Rb=a.charCols;this.Ac=a.charRows;if(void 0===this.Rb||void 0===this.Ac)this.Rb=xs[this.ea][0],this.Ac=xs[this.ea][1];this.Z=a.screenWidth;this.ka=a.screenHeight;this.bd=a.scale;this.Qd=12<=Math.round(this.Z/ +this.Rb);this.N=b;this.L=c;this.F=(this.mg=d)||b||null;this.lc=a.screenColor||"black";this.md=(1-(Xa("flicker")||a.flicker||0)).toString();this.Hb=!1;b&&(b.style.backgroundColor=this.lc);e&&(e.style.backgroundColor=this.lc);b=a.smoothing;(c=Xa("smoothing"))&&(b="true"==c);null!=b&&(g=Va(this.L,"imageSmoothingEnabled"))&&(this.L[g]=b);this.od=a.touchScreen;this.lb=ys;this.H=null;this.Pd=a.autoLock;this.fb=this.Tb=0;this.ra=[];this.ha=Array(this.Ma==nq?256:16);this.Ia=!1;if(this.P=e)if(g=Va(e,"requestFullscreen")|| +Va(e,"requestFullScreen")){this.P.A=e[g];if(e=Va(document,"on","fullscreenchange")){var k=Va(document,"fullscreenElement")||Va(document,"fullScreenElement");document.addEventListener(e,function(){zs(f,!!k)},!1)}(e=Va(document,"on","fullscreenerror"))&&document.addEventListener(e,function(){zs(f,null)},!1)}if(this.F&&(this.F.onfocus=function(){return f.yg(!0)},this.F.onblur=function(){return f.yg(!1)},this.F.ne=(g=Va(this.F,"requestPointerLock"))&&this.F[g],this.F.B=(g=Va(this.F,"exitPointerLock"))&& +this.F[g],this.F.ne&&(e=Va(document,"on","pointerlockchange")))){var m=Va(document,"pointerLockElement");document.addEventListener(e,function(){f.Gf(!(!m||document[m]!==f.F))},!1)}(this.Aa=a.fontROM)&&"json"!=ya(this.Aa)&&(this.Aa=Na()+"/api/v1/dump?file="+this.Aa+"&format=bytes")}ia(Q,pb);l=Q.prototype; +l.tc=function(a,b,c,d){var e=this;this.oa=b;this.G=c;this.ca=d;c=+Bd(a,"randomize");0<=c&&1>=c&&(this.Sb=c);c=(c=ws[this.da])&&c[0];c!==As&&(Pc(b,this,Bs),Uc(b,this,Cs));c!==Ds&&(Pc(b,this,Es),Uc(b,this,Fs));this.Ma>=lq&&(Pc(b,this,Gs),Uc(b,this,Hs));this.Ma==nq&&(Pc(b,this,Is),Uc(b,this,Js));d&&Cl(d,262144,function(a){if(e.B)if(a[0]){var b=e.B;if(b.dd){var c,d=!1,f=8,g=8,h=-1,J=b.video.D>>3;for(c=0;c=P&&(g=P,d=!0);break;case "p":0<=P&&3>=P&&(h=P);break;case "w":P=b.fb&&(I-=b.fb);a="";for(c=0;ch?q(G):ta(G>>(h<<3),8));d&&(I+=J-g);a&&(a+="\n");a+=H}a&&b.ca.O(a);b.B=I}else b.ca.O("no buffer")}else e.ca.O("BIOSMODE: "+va(e.la)),b=e.B,Wr(b,"CRTC",b.gc,b.$a,b.bg),b.Ma>=lq&&(Wr(b," GRC",b.Dd,b.Cd,b.Rg), +Wr(b," SEQ",b.Ed,b.be,b.Sg),Wr(b," ATC",b.Bd,b.Dc,b.Qg),Wr(b," ATCINDX",b.Bd),b.ca.O(" ATCDATA: "+b.Je),Wr(b," FEAT",b.Lf),Wr(b," MISC",b.$e),Wr(b," STATUS0",b.Fg)),Wr(b," STATUS1",b.ga),b.Ma!=Ds&&b.Ma!=As||Wr(b," MODEREG",b.Uc),b.Ma==As&&Wr(b," COLOR",b.Ye),b.Ma>=lq&&(b.ca.O(" LATCHES: "+q(b.xb)),b.ca.O(" ACCESS: "+q(b.pg,4)),b.ca.O("Use 'dump video [addr]' to dump video memory"));else e.ca.O("no active video card")});if((this.C=ac(a,"Keyboard"))&&this.N){for(var f in this.ma)0c&&(a=Math.round(c/b*100)+"%")}d.$c?(d.N.style.width=a,d.N.style.width=a,d.N.style.display="block",d.N.style.margin="auto"):(d.P.style.width=a,d.P.style.height="auto");d.P.style.backgroundColor=d.lc;d.P.A()}d.F&&d.F.focus()}}:c.parentNode.removeChild(c), +!0;case "lockPointer":return this.Sd=c.textContent,this.F&&this.F.ne?c.onclick=function(){d.ne(!0)}:c.parentNode.removeChild(c),!0;case "refresh":return c.onclick=function(){Ps(d,!0)},!0}return!1};function zs(a,b){!b&&a.P&&(a.$c?a.N.style.width=a.N.style.height="":a.P.style.width=a.P.style.height="");Tb(a,"notifyFullScreen("+b+")",!0);a.C&&(a.C.$g=b)} +l.ne=function(a){var b=!1;this.F&&(a?this.F.ne&&(this.F.ne(),this.H&&this.H.Gf(!0),b=!0):this.F.B&&(this.F.B(),this.H&&this.H.Gf(!1),b=!0),this.F&&this.F.focus());return b};l.Gf=function(a){this.H&&(this.H.Gf(a),this.C&&(this.C.$g=a));var b=this.ma.lockPointer;b&&(b.textContent=a?"Press Esc to Unlock Pointer":this.Sd)}; +function Ks(a,b){var c=a.F;c&&!a.lb&&(a.lb=b,c.addEventListener("touchstart",function(b){gq(a.V,b);a.lb!=Ns&&Rs(a,b,!0)},!1),b!=Ns&&(c.addEventListener("touchmove",function(b){Rs(a,b)},!0),c.addEventListener("touchend",function(b){Rs(a,b,!1)},!1),a.mb=a.vb=a.pd=-1,a.wc=!1,a.Kb=null,a.vc=!1,a.Rd=function(){a.vc=!0;a.H.Xd(Ss,!0)}))}l.yg=function(a){this.C&&this.C.yg(a)}; +function Rs(a,b,c){var d=0,e=0;var f=a.N;do isNaN(f.offsetLeft)||(d+=f.offsetLeft,e+=f.offsetTop);while(f=f.offsetParent);var g=a.Z/a.N.offsetWidth,h=a.ka/a.N.offsetHeight;if(b.targetTouches&&b.targetTouches.length){f=b.targetTouches[0].pageX;var k=b.targetTouches[0].pageY}else f=b.pageX,k=b.pageY;f=(f-d)*g;k=(k-e)*h;if(a.lb==Ms)c&&Gq(a.C,Ts[k/(a.ka/3)|0][f/(a.Z/3)|0],!0);else if(a.H){e=a.wc;d=b.timeStamp-a.pd;!0===c?(a.wc=500d){a.H.Xd(Ss,!0);a.H.Xd(Ss,!1);return}}if(c||0>a.mb||0>a.vb)a.mb=f,a.vb=k;c=Math.round(f-a.mb);b=Math.round(k-a.vb);a.mb=f;a.vb=k;a.H.sf(c,b,a.mb,a.vb)}}l.$b=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Zb=function(a){return a?this.save():!0}; +l.reset=function(){var a=0;this.V&&(a=+Yl(this.V,ml,void 0));this.da||(this.Ma=a==Zl?Ds:As);this.ea=Us;switch(this.Ma){case nq:a=7;break;case lq:var b=Vs[this.Fb];b&&(a=b[0]);a||(a=4);break;case Ds:a=Zl;this.ea=Ws;break;default:a=2}this.fa!==a&&(this.fa=a);this.B=null;this.U=this.fc=new vr(this,Ds);this.K=this.Gb=new vr(this,As);this.Ma>1&255;c=c>>8&~$s;c>>4==(c&15)&&(c^=15)}else d=c&255,c=(c&256?at|bt:ct|dt)|et&c>>8;Mc(this.oa,b,d|c<<8)}Ps(this,!0)}};function Xs(a){a.A.$e&Er?(a.U=a.fc,a.K=a.A):(a.U=a.A,a.K=a.Gb)}l.save=function(){var a=new ag(this);a.set(0,Vr(this.fc));a.set(1,Vr(this.Gb));a.set(2,[this.fa,this.ea,this.la]);a.set(3,Vr(this.A));return a.data()}; +l.restore=function(a){var b=a[2];this.fa=b[0];this.ea=b[1];this.la=b[2];this.B=null;this.U=this.fc=new vr(this,Ds,a[0]);this.K=this.Gb=new vr(this,As,a[1]);this.A=new vr(this,this.Ma,a[3],this.ud);this.A.rc&&Xs(this);Ys(this);if(!ft(this))return!1;gt(this);return!0}; +function Os(a,b,c,d){if(d)a.Da("Unable to load font ROM (error "+d+": "+b+")",0>d);else{rb(a.de,b,c);try{var e=eval("("+c+")"),f=e.bytes||e;if(!f.length){kb("Empty font ROM: "+b);return}if(1==f.length){kb(f[0]);return}if(8192==f.length)mq(a,f,[6144,0]);else if(2048==f.length)mq(a,f,[0]);else{a.Da("Unrecognized font data length ("+f.length+")");return}}catch(g){a.Da("Font ROM data error: "+g.message);return}(a.L||a.ca)&&Pb(a)}} +function ht(a,b){if(1==b)return a.ha[0]=it[ct],a.ha[1]=it[at],a.ha;if(2==b){var c=a.B.Ye;if(a.B===a.A){var d=a.A.Dc[0];c=d&7;d&16&&(c|=8);18!=a.A.Dc[1]&&(c|=32)}a.ha[0]=it[c&15];c=c&32?jt:kt;for(d=0;de;e++){var f=d[e]||0;var g=f<<2&252;var h=f>>4&252;f=f>>10&252;a.ha[e]=[g,h,f,255]}else{var k=d&&d[255];b=null!=c.Dc[15]?c.Dc:lt;for(e=0;16>e;e++)f=b[e]& +63,k?(f|=(c.Dc[20]&12)<<4,c.Dc[16]&128&&(f&=-49,f|=(c.Dc[20]&3)<<4),f=d[f],g=f<<2&252,h=f>>4&252,f=f>>10&252):(g=(f&4?170:0)|(f&32?85:0),h=(f&2?170:0)|(f&16?85:0),f=(f&1?170:0)|(f&8?85:0)),a.ha[e]=[g,h,f,255]}a.Ia=!0}return a.ha}function mq(a,b,c,d){a.zb=b;a.Pa=c;a.Fa=d} +function Ys(a,b){var c=!1;if(window&&a.zb&&(!b||a.I)){var d=0,e=a.Fa?a.Fa:8,f=ht(a);null!=a.Pa[0]&&mt(a,nt,a.Pa[0],d,e,8,a.zb,f)&&(c=!0);d=a.Fa?0:2048;e=a.Fa?a.Fa:9;null!=a.Pa[1]&&(mt(a,ot,a.Pa[1],d,e,14,a.zb,pt,qt)&&(c=!0),a.Fa&&mt(a,a.Ma,a.Pa[1],0,a.Fa,14,a.zb,f)&&(c=!0))}b||(a.ba=-1,a.Ba=-1,a.ta=0);return c}function mt(a,b,c,d,e,f,g,h,k){var m=!1;null!=c&&(rt(a,b,c,d,e,f,g,h,k)&&(m=!0),a.Qd&&rt(a,b<<1,c,d,e,f,g,h,k)&&(m=!0));return m} +function rt(a,b,c,d,e,f,g,h,k){var m=!1,p=b&1?0:1,v=a.ra[b],u=16>h.length?h.length:16;v||(v={Gc:e<ra||!Z?ra:8,jb=cc.createImageData(m.Gc,m.Hc);for(G=0;256>G;G++){for(A=0;A=ra-2,Sd=ib[A>(8<=H&&192<=G&&223>=G?7:H)?P:Sb;st(jb,Fg,mf,Gg);I&&st(jb,Fg+1,mf,Gg)}cc.putImageData(jb,(G&15)*m.Gc,(G>>4)*m.Hc)}m.Be[J]="#"+q(P[0],2)+q(P[1],2)+q(P[2],2);m.Ni[J]=P;m.Pg[J]=Jb;m=!0}}a.ra[b]=v;return m}function tt(a){0a.Ba&&(a.Ba=0):a.Ba=-1} +function gt(a){if(a.I){for(var b=10;15>=b;b++)if(null==a.B.$a[b])return;var c=a.B.$a[10];b=c&31;var d=a.B.$a[11]&us[11],e=a.B.$a[9]&us[9],f=!1;a.B===a.A&&(f=!0,7!=e||4!=b||d||(d=7));if(c&32||b>d&&!f||b>e)ut(a);else{c=a.B.$a[15];c|=(a.B.$a[14]&a.B.ag)<<8;a.ba!=c&&(ut(a),a.ba=c);d=d-b+1;if(a.qd!=b||a.Sc!=d)a.qd=b,a.Sc=d;a.wa=e+1;tt(a)}}} +function ut(a){if(0<=a.ba){if(void 0!==a.M){var b=vt<<8,c=a.M[a.ba];if(c&b){c&=~b;b=a.ba%a.D;var d=a.ba/a.D|0;a.I&&a.ra[a.I]&&(a.Ea&&wt(a,b,d,c,a.Ea),wt(a,b,d,c));a.M[a.ba]=c}}a.ba=-1}} +function xt(a){var b=a.B;a.Tc=!1;var c=b.Cd[5];if(null!=c){var d=Hr;var e=Jr,f=b.Cd[3]&31;switch(c&3){case 0:if(f){e=Jr|32;switch(f&24){case 8:e=Jr|96;break;case 16:e=Jr|160;break;case 24:e=Jr|224}b.Pc=f&7}break;case 1:e=1;break;case 2:switch(f&24){default:e=2;break;case 8:e=98;break;case 16:e=162;break;case 24:e=226}break;case 3:a.Ma==nq&&(e=3,b.Pc=f&7)}c&8&&(d=1280);b=b.be[4];null!=b&&(b&4||(d|=Ir,e|=Kr),c&64&&(b&8&&(d|=16384,e|=4),a.Tc=!0));d|=e}return d} +function yt(a,b){var c=a.B;return c&&null!=b&&b!=c.pg?(c.Hg(b),a.oa.Hg(c.fb,c.Tb,c.bh(),!0),!0):!1} +function ft(a,b){var c=a.la,d=a.B;if(d)if(d.Ma==Ds)c=Ws;else if(d.Ma>=lq){c=null;var e=d.ud>>2,f=32768=d.$a[is]?Dt:Et:Ft:f&128|| +350>e?c=m?Gt:Ht:480<=e&&(c=a.fa==Zl?It:Jt):c=m?7-c:Kt:c-=m?2:0);h=xt(a)}}else d.Uc&8?(d.Uc&2?(c=d.Uc&16?Kt:Lt,d.Uc&4||--c):(c=d.Uc&1?Us:Mt,d.Uc&4&&--c),a.Hb&&(a.N.style.opacity="1",a.Hb=!1)):!a.Hb&&1>+a.md&&(a.Hb=!0,a.N.style.opacity=a.md,d=a.G,d.aa.Pf=!0,Fd(d));else a.la=null,null==c&&(c=a.ea);if(!Zs(a,c,b))return!1;yt(a,h);return!0} +function Zs(a,b,c){if(null!=b&&(b!=a.la||c)){a.Fd=0;a.la=b;a.Ia=!1;b=a.B||(b==Ws?a.U:a.K);if(b!=a.B||b.fb!=a.fb||b.Tb!=a.Tb){ut(a);if(a.fb){if(!Ec(a.oa,a.fb,a.Tb))return!1;a.B&&(a.B.rc=!1)}a.B=b;b.rc=!0;a.fb=b.fb;a.Tb=b.Tb;if(!rc(a.oa,b.fb,b.Tb,3,b===a.A?b:null))return!1}a:{a.I=0;a.D=a.Rb;a.J=a.Ac;a.La=a.D;a.Qb=xs[Ws][2];b=0;if(c=xs[a.la])a.D=c[0],a.J=c[1],a.Qb=c[2],b=c[3],a.I=c[4],4!=a.fa&&7!=a.fa||a.B!==a.A||a.I!=nt||(7==(a.A.$a[ss]&31)?a.J=350>Xr(a.A,is)?43:50:a.I=a.Ma);a.ld=a.D*a.J|0;a.kd=a.ld/ +a.Qb|0;a.Ra=a.kd;a.kc=0;void 0!==b&&(a.Ra=(a.Ra<<1)+b|0,a.kc=a.Ra+b>>1);if(a.ra.length){a.qa=a.Z/a.D|0;a.pa=a.ka/a.J|0;if(a.I){b=a.ra[a.I];if(!b)break a;c=a.ra[a.I<<1];a.bd&&80==a.D?c&&a.qa>=3*c.Gc>>2&&(a.I<<=1,b=c):(c&&a.qa>=c.Gc&&(a.I<<=1,b=c),a.bd||(a.qa=b.Gc,a.pa=b.Hc));a.ab=a.cb=0;b&&(a.ab=a.D*b.Gc,a.cb=a.J*b.Hc)}else a.qa=a.pa=1,a.ab=a.D,a.cb=a.J;a.Ka=a.L.createImageData(a.ab,a.cb);a.Ca=document.createElement("canvas");a.Ca.width=a.ab;a.Ca.height=a.cb;a.Ea=a.Ca.getContext("2d");a.Jc=a.Kc=0; +a.sc=a.Z;a.uc=a.ka;b=a.Z-a.D*a.qa;c=a.ka-a.J*a.pa;0>1,a.sc-=b);0>1,a.uc-=c);if(b||c)a.L.fillStyle=a.N.style.backgroundColor,a.L.fillRect(0,0,a.Z,a.ka)}}mu(a,!0);Ps(a)}return!0}function st(a,b,c,d){b=(b+c*a.width)*d.length;a.data[b]=d[0];a.data[b+1]=d[1];a.data[b+2]=d[2];a.data[b+3]=d[3]}function ou(a){a.ta=-1;a.Ga=!1;var b=a.kd;if(void 0===a.M||a.M.length!=b)a.M=Array(b)}function mu(a,b){b||(a.Ia=!1);ou(a)} +function wt(a,b,c,d,e){var f=d&255,g=d>>8;d=g&15;var h=a.ra[a.I];h.hf&&(d=h.hf[d]);var k=g>>4&15;h.hf&&(k=h.hf[k]);e?(b*=h.Gc,c*=h.Hc,e.fillStyle=h.Be[k],e.fillRect(b,c,h.Gc,h.Hc)):(b=b*a.qa+a.Jc,c=c*a.pa+a.Kc,a.L.fillStyle=h.Be[k],a.L.fillRect(b,c,a.qa,a.pa));g&pu&&(k=(f&15)*h.Gc,f=(f>>4)*h.Hc,e?e.drawImage(h.Pg[d],k,f,h.Gc,h.Hc,b,c,h.Gc,h.Hc):a.L.drawImage(h.Pg[d],k,f,h.Gc,h.Hc,b,c,a.qa,a.pa));g&vt&&(f=a.qd,g=a.Sc,e?(a.wa&&a.wa!==h.Hc&&(f=f*h.Hc/a.wa|0,g=g*h.Hc/a.wa|0),e.fillStyle=h.Be[d],e.fillRect(b, +c+f,h.Gc,g)):(a.wa&&a.wa!==a.pa&&(f=f*a.pa/a.wa|0,g=g*a.pa/a.wa|0),a.L.fillStyle=h.Be[d],a.L.fillRect(b,c+f,a.qa,g)))} +function Ps(a,b){b=void 0===b?!1:b;if(a.aa.ac){var c=!1,d=a.B;d&&(d!==a.A?d.Uc&8&&(c=!0):d.Bd&32&&(c=!0));if(c||b){if(b)ou(a);else if(void 0===a.M)return;c=!1;!(b||++a.Fd&15)&&0<=a.Ba&&(a.Ba++,c=!0);var e=a.ld,f=a.fb,g=f,h=g+a.Tb;a.la>=Dt&&(f=g=655360,h=g+65536);if(qu(a,d)&8||d.Ff&&d.Ff=lq&&d.$a[19]&&d.$a[19]<<1!=d.$a[1]+1&&(a.La=d.$a[19]<<(a.I?1:d.$a[20]&64?3:4),k=(a.La*(a.J-1)+a.D)/ +a.Qb|0,a.la<=Ws&&(k<<=1));var p=d=0;g+k>h&&(p=k,g>=h?(d=f+(g-h),k=0):(d=f,k=h-g,p-=k));h=a.ba-(m>>1);g=ru(a,f,g,k,0,h,e,b,c);p&&(g+=ru(a,f,d,p,0+g,h,e,b,c));g&&(a.Ga=!0)}}} +function ru(a,b,c,d,e,f,g,h,k){var m=d>>1;m>g&&(m=g);var p=c+d;if(h=!h&&a.Ga){h=a.oa;for(var v=!0,u=c>>>h.A,A=h.B-(c&h.D);0f)return m;c+=f<<1;e+=f;g=e+1}}if(a.I){if(a.ra[a.I]){b=c;c=e;k=f=e=0;h=pu<<8;d=1048575;u=a.B.Uc&32;a.Ma>=lq&&(u=a.B.Dc[16]&8);v=a.ba-a.B.$d;u&&(k=$s<<8,d&=~k,a.Ba&2||(d&=~h));for(a.ta=0;b>1;g=0;c=a.Qb;e=b;f=16==c?65536:196608;k=16==c?1:2;h=ht(a,k);v=d=0;u=a.D;A=0;var J=a.J,H=0;for(a.ta=0;e>8|(G&255)<<8;var P=f,I=16;d>=k))>>(I-=k);st(a.Ka,d++,v,h[Z])}d>A&&(A=d);v=H&&(H=v+1)}e+=2;g++;if(d>=a.D){d= +0;v+=2;if(v>a.J)break;v==a.J&&(v=1,e=b+a.kc)}}ua.D?a.La-a.D-H>>3:0;for(a.ta=0;c>=8;k>v&&(v=k);h=A&&(A=h+1)}c+=J;if(k>=a.D){k=0;if(++h>a.J)break;c+=G}}H&&(g= +0)}else{m=0;g=p-c;e=ht(a);f=a.B.dd;h=k=0;d=a.D;v=0;u=a.J;A=0;J=a.B.Dc[19]&15;H=a.La>a.D?a.La-a.D-J>>3:0;for(a.ta=0;cP&&(I=P)):(G<<=J,I-=J,a.Ga=!1):(a.Ga&&G===a.M[m]?(k+=I,I=0):a.M[m]=G,m++);if(I){kv&&(v=k);h=A&&(A=h+1)}if(k>=a.D){k=0;if(++h>a.J)break;c+=H}}J&&(g=0)}da&&(b.th=a,a=-a|0);a%b.qh>b.hn&&(c|=1);a%b.rh>b.kn&&(c|=9);b.ci=a/b.rh|0;return c}l.wm=function(a,b){return tu(this,this.U,a,b)};l.ko=function(a,b,c){var d=this.U;d.Cg=d.gc;d.gc=b&31;t(this,a,b,c,"CRTC.INDX")};l.vm=function(a,b){return uu(this,this.U,a,b)};l.jo=function(a,b,c){vu(this,this.U,a,b,c)};l.xm=function(a,b){return wu(this,this.U,b)};l.lo=function(a,b,c){a=this.U;t(this,a.port+4,b,c,"MODE");a.Uc=b;ft(this,!1)}; +l.ym=function(a,b){return xu(this,this.U,b)};l.Hk=function(a,b,c){this.A.Lf=this.A.Lf&-4|b&3;t(this,a,b,c,"FEAT")};l.Rl=function(a,b){a=this.A.Bd;b&&!r(this)||t(this,960,null,b,"ATC.INDX",a);return a};l.kl=function(a,b){a=this.A.Dc[this.A.Bd&31];b&&!r(this)||t(this,960,null,b,"ATC."+this.A.Qg[this.A.Bd&31],a);return a}; +l.Gk=function(a,b,c){var d=this.A,e=d.Bd&32;if(d.Je){d.Je=!1;var f=d.Bd&31;if(16<=f||!e)if(yu||d.Dc[f]!==b)c&&!r(this)||t(this,a,b,c,"ATC."+d.Qg[f]),d.Dc[f]=b,mu(this,!1)}else d.Bd=b,t(this,a,b,c,"ATC.INDX"),d.Je=!0,b&32&&!e&&Ys(this,!0)&&Ps(this,!0),a=d.$a[Ar],a|=(d.$a[Br]&d.ag)<<8,d.$d!=a&&(d.$d=a,mu(this)),d.Ff=0}; +l.Im=function(a,b){a=0;if(this.Ma==lq)a=3-((this.A.$e&12)>>2),a=(this.Fb&1<>this.A.yc&63;b&&!r(this)||t(this,969,null,b,"DAC.DATA["+va(this.A.ad)+"]["+va(this.A.yc)+"]",a);this.A.yc+=6;12Missing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.height="auto";0<=Oa().indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height=(a.clientWidth*d/c|0)+"px"}}(c, +e,d.screenWidth,d.screenHeight),c.onresize(null));var f=+(Xa("aspect")||d.aspect);f&&.3<=f&&3.33>=f&&(bb("onresize",function(a,b,c){return function(){b.style.height=(a.clientWidth/c|0)+"px"}}(c,e,f)),window.onresize());c.appendChild(e);f=document.createElement("textarea");Ua("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"),f.style.fontSize="16px");c.appendChild(f);var g=e.getContext("2d");d=new Q(d,e,g,f,c);yb(d,c)}}); +function zu(a){pb.call(this,"ParallelPort",a,4194304);this.H=a.adapter;switch(this.H){case 1:this.D=956;this.C=7;break;case 2:this.D=888;this.C=7;break;case 3:this.D=632;this.C=5;break;default:kb("Unrecognized parallel adapter #"+this.H);return}this.A=this.B=null;a=a.binding;"console"==a?this.B="":wb(this,a,Au)}ia(zu,pb);l=zu.prototype;l.Eb=function(a,b,c){switch(b){case Au:return this.ma[b]=this.A=c,!0}return!1}; +l.tc=function(a,b,c,d){this.oa=b;this.G=c;this.ca=d;this.V=ac(a,"ChipSet");Pc(b,this,Bu,this.D);Uc(b,this,Cu,this.D);Pb(this)};l.$b=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Zb=function(a){return a?this.save():!0};l.reset=function(){Du(this)};l.save=function(){var a=new ag(this),b=0,c=[];c[b++]=this.F;c[b++]=this.Pb;c[b]=this.kf;a.set(0,c);return a.data()};l.restore=function(a){return Du(this,a[0])}; +function Du(a,b){var c=0;void 0===b&&(b=[0,0,0]);a.F=b[c++];a.Pb=b[c++];a.kf=b[c];return!0}l.jm=function(a,b){var c=this.F;t(this,a,null,b,"DATA",c);return c};l.Hm=function(a,b){var c=this.Pb;t(this,a,null,b,"STAT",c);return c};l.fm=function(a,b){var c=this.kf;t(this,a,null,b,"CTRL",c);return c}; +l.Vn=function(a,b,c){t(this,a,b,c,"DATA");this.F=b;this.Pb|=Eu;a=!1;Tb(this,"transmitByte("+va(b)+")");this.A&&(8==b?this.A.value=this.A.value.slice(0,-1):(this.A.value+=String.fromCharCode(b),this.A.scrollTop=this.A.scrollHeight),a=!0);if(null!=this.B){if(10==b||1024<=this.B.length)this.O(this.B),this.B="";10!=b&&(this.B+=String.fromCharCode(b));a=!0}a&&(this.Pb&=~Eu);Fu(this)};l.Qn=function(a,b,c){t(this,a,b,c,"CTRL");this.kf=b;Fu(this)}; +function Fu(a){a.V&&a.C&&(a.kf&Gu&&!(a.Pb&Eu)?mh(a.V,a.C):Zg(a.V,a.C))}var Au="buffer",Eu=64,Gu=16,Bu={0:zu.prototype.jm,1:zu.prototype.Hm,2:zu.prototype.fm},Cu={0:zu.prototype.Vn,2:zu.prototype.Qn};cb(function(){for(var a=zb(document,"pcx86","parallel"),b=0;b=b)a.preventDefault&&a.preventDefault(),64");if(2==c.length){var d=Da(c[0]);if(d!=this.ye)return;c=Da(c[1]);if(this.H=Cb(c)){var e=this.H.exports;if(e){var f=e.connect;f&&f.call(this.H,this.P);if(this.ba=e.receiveData){this.P=a;this.U=e.receiveStatus;this.status("Connected "+this.de+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; +l.$b=function(a,b){if(!b)if(this.vj(this.P),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Zb=function(a){return a?this.save():!0};l.reset=function(){Pu(this)};l.save=function(){var a=new ag(this),b=0,c=[];c[b++]=this.fa;c[b++]=this.ka;c[b++]=this.I;c[b++]=this.M;c[b++]=this.F;c[b++]=this.D;c[b++]=this.Z;c[b++]=this.A;c[b++]=this.B;c[b]=this.J;a.set(0,c);return a.data()};l.restore=function(a){return Pu(this,a[0])}; +function Pu(a,b){var c=0;void 0===b&&(b=[0,0,Qu,0,Ru,0,0,Lu|Mu,a.ra,[]]);a.fa=b[c++];a.ka=b[c++];a.I=b[c++];a.M=b[c++];a.F=b[c++];a.D=b[c++];a.Z=b[c++];a.A=b[c++];a.B=b[c++];a.J=b[c];return!0}l.Xe=function(a){if(null!=a)if("number"==typeof a)this.J.push(a);else if("string"==typeof a)for(var b=0;b>8:this.M;t(this,a,null,b,this.D&Xu?"DLM":"IER",c);return c}; +l.rm=function(a,b){var c=this.F;this.F|=Ru;t(this,a,null,b,"IIR",c);return c};l.sm=function(a,b){var c=this.D;t(this,a,null,b,"LCR",c);return c};l.um=function(a,b){var c=this.Z;t(this,a,null,b,"MCR",c);return c};l.tm=function(a,b){var c=this.A;t(this,a,null,b,"LSR",c);return c};l.zm=function(a,b){var c=this.B;this.B&=~(Tu|Uu);t(this,a,null,b,"MSR",c);return c}; +l.to=function(a,b,c){t(this,a,b,c,this.D&Xu?"DLL":"THR");if(this.D&Xu)this.I=this.I&-256|b;else{this.ka=b;this.A&=~(Lu|Mu);Tb(this,"transmitByte("+va(b)+")");this.ba&&this.ba.call(this.H,b);if(this.C){if(13==b)this.L=0;else if(8==b)this.C.value=this.C.value.slice(0,-1),0":String.fromCharCode(b);c=a.length;32>b&&1==c&&(c=0);9==b&&(c=this.pa||8,c-=this.L%c,this.pa&&(a=Ca("",c)));!this.L&&c&&(10!=this.qa&&(a="\n"+a),this.la&&(a=String.fromCharCode(this.la)+ +a));this.C.value+=a;this.C.scrollTop=this.C.scrollHeight;this.L+=c}this.qa=b}else if(null!=this.K){if(10==b||1024<=this.K.length)this.O(this.K),this.K="";10!=b&&(this.K+=String.fromCharCode(b))}this.G&&Pd(this.G,this.wa,1E3/(1843200/((this.I||1)<<7))|0);Vu(this)}};l.fo=function(a,b,c){t(this,a,b,c,this.D&Xu?"DLM":"IER");this.D&Xu?this.I=this.I&255|b<<8:this.M=b};l.ho=function(a,b,c){t(this,a,b,c,"LCR");this.D=b}; +l.io=function(a,b,c){var d=b^this.Z;t(this,a,b,c,"MCR");this.Z=b;d&(Yu|Zu)&&this.U&&(a=0,this.P?(a|=b&Zu?32:0,a|=b&Yu?320:0):(a|=b&Zu?16:0,a|=b&Yu?1048576:0),this.U.call(this.H,a))};function Vu(a){var b=-1;a.A&Wu&&a.M&$u?b=av:a.A&Lu&&a.M&bv?b=cv:a.B&(Tu|Uu)&&a.M&dv&&(b=ev);0<=b?(a.F&=~(Ru|fv),a.F|=b,a.V&&a.N&&mh(a.V,a.N,100)):(a.F|=Ru,a.V&&a.N&&Zg(a.V,a.N))} +var Ku="buffer",Qu=384,$u=1,bv=2,dv=8,Ru=1,av=4,cv=2,ev=0,fv=6,Xu=128,Yu=1,Zu=2,Wu=1,Lu=32,Mu=64,Tu=1,Uu=2,Iu=16,Ju=32,Nu={0:Hu.prototype.Em,1:Hu.prototype.qm,2:Hu.prototype.rm,3:Hu.prototype.sm,4:Hu.prototype.um,5:Hu.prototype.tm,6:Hu.prototype.zm},Ou={0:Hu.prototype.to,1:Hu.prototype.fo,3:Hu.prototype.ho,4:Hu.prototype.io};cb(function(){for(var a=zb(document,"pcx86","serial"),b=0;ba.A||0>a.B)a.A=b.screenX,a.B=b.screenY;a.N?(c=b.movementX||b.mozMovementX||b.webkitMovementX||0,d=b.movementY||b.mozMovementY||b.webkitMovementY||0):(c=b.screenX-a.A,d=b.screenY-a.B);a.A=b.screenX;a.B=b.screenY;a.sf(c,d,a.A,a.B)}} +l.Xd=function(a,b){if(this.rc&&this.G&&this.G.aa.Xa){var c="mouse button"+a+" "+(b?"dn":"up");switch(a){case Ss:if(this.L!=b){this.L=b;rv(this,c);return}break;case sv:if(this.M!=b){this.M=b;rv(this,c);return}}Tb(this,c+": ignored")}}; +l.sf=function(a,b,c,d){this.rc&&this.G&&this.G.aa.Xa&&(a=Math.round(Math.abs(a)*this.K)*Math.sign(a)||Math.sign(a),b=Math.round(Math.abs(b)*this.K)*Math.sign(b)||Math.sign(b),a||b)&&(r(this,16777216)&&Tb(this,"moveMouse("+a+","+b+")"),this.I=a,this.J=b,rv(this,null,c,d))}; +function rv(a,b,c,d){var e=64|(a.L?32:0)|(a.M?16:0)|(a.J&192)>>4|(a.I&192)>>6,f=a.I&63,g=a.J&63;r(a,8388608)&&Tb(a,(b?b+": ":"")+(void 0!==d?"mouse ("+c+","+d+"): ":"")+"serial packet ["+va(e)+","+va(f)+","+va(g)+"]",0,!0);a.F.Xe([e,f,g]);a.I=a.J=0} +l.il=function(a){var b=1048592==(a&1048592);if(b){if(!this.rc){var c=!1;this.C&16||(this.reset(),Tb(this,"serial mouse reset"),c=!0);this.C&1048576||(Tb(this,"serial mouse ID requested"),c=!0);c&&(this.F.Xe([tv,tv]),Tb(this,"serial mouse ID sent"));mv(this);this.rc=b}}else this.rc&&(Tb(this,"serial mouse inactive"),nv(this),this.rc=b);this.C=a};l.Xl=function(a,b){t(this,a,null,b,"DATA",0);return 0};l.Yl=function(a,b){t(this,a,null,b,"TPPI",0);return 0}; +l.Wl=function(a,b){t(this,a,null,b,"CTRL",0);return 0};l.Vl=function(a,b){t(this,a,null,b,"CPPI",0);return 0};l.In=function(a,b,c){t(this,a,b,c,"DATA")};l.Jn=function(a,b,c){t(this,a,b,c,"TPPI")};l.Hn=function(a,b,c){t(this,a,b,c,"CTRL")};l.Gn=function(a,b,c){t(this,a,b,c,"CPPI")};var iv="bus",hv="serial",Ss=0,sv=2,kv=572,jv={0:gv.prototype.Xl,1:gv.prototype.Yl,2:gv.prototype.Wl,3:gv.prototype.Vl},lv={0:gv.prototype.In,1:gv.prototype.Jn,2:gv.prototype.Hn,3:gv.prototype.Gn},tv=77; +cb(function(){for(var a=zb(document,"pcx86","mouse"),b=0;b>2;var e=c=0;a=new DataView(a,0,b);g.A=Array(g.sb);for(b=0;bb.indexOf("/api/v1/dump")&&(a=ya(b),"json"==a||"gz"==a?f=encodeURI(b):"demandrw"==this.mode||"demandro"==this.mode?(f=Av(this,b),this.kg=!0):(c="path",d="&mbhd=10",!b.indexOf("http:")||!b.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(a)?(c="disk",d="&mbhd=0"): +za(b,"/")&&(c="dir"),f=Na()+"/api/v1/dump?"+c+"="+encodeURIComponent(b)+(this.Me?"":d)+"&format=json"));var k="Loading "+f+"...";return!!Ma(f,null,!0,function(a,b,c){Bv(g,a,b,c)},function(){g.O(k,Kb)})}; +function Bv(a,b,c,d){var e=null;a.Pe=!1;var f=!(!(0>d&&a.na)||a.na.aa.ac);if(a.kg)d?a.Da('Unable to connect to disk "'+a.H+'" (error '+d+": "+c+")",f):(a.D=!0,Cv(a),e=a);else if(d)a.Da('Unable to load disk "'+a.jd+'" (error '+d+": "+b+")",f);else{rb(a.controller.de,b,c);try{if(0g&&0c.indexOf("0x")&& +'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+c+")");if(h.length)if(1==h.length)kb(h[0]);else{a.sb=h.length;a.gb=h[0].length;a.Wa=h[0][0].length;var k=h[0][0][0];a.Na=k&&k.length||512;for(d=c=0;d>=2;var p=k.pattern;void 0===p&&(p=k.pattern=0);var v=k.data;if(void 0===v){var u=k.bytes;if(void 0!==u&&u.length){for(var A=m<<2,J=u.length;J< +A;J++)u[J]=p;Dv(k,u,0)}else k.data=v=[],u&&(k.pattern=p|p<<8|p<<16|p<<24);delete k.bytes}zv(k,d,f);for(A=0;Ae;e++){if(128==Fv(a,d,b+0,1)){c.If=Fv(a,d,b+8,4);(d=Ev(a,c.If))&&(f=!0);break}b+=16}if(!f)return}c.rf||(c.rf=Fv(a,d,19,2)||Fv(a,d,32,4),c.qf=Fv(a,d,14,2),c.jh=c.qf+Fv(a,d,22,2)*Fv(a,d,16,1),c.sh=Fv(a,d,17,2),c.vf=Fv(a,d,13,1));c.hh=c.jh+((32*c.sh+(c.Na-1))/c.Na|0);c.gn=(c.rf-c.hh)/c.vf|0;c.sg=4084>=c.gn?12:16;c.El=12==c.sg?4086:65526;e=[];for(d=c.jh;d>=8;f+=2;if(m)for(;k--;)Tv(c,f,1),254>=m?(p=m,u=Tv(c,f+1),f+=3):(p=Tv(c,f+3,1),u=Tv(c,f+4),f+=6),c.fe[p]&&(c.fe[p].jf[h]=[u]),c.A[h]=[p,u],h++;else h+=k}(g=Iv(d,Wv,b))&&Xv(d,g+b);g=Iv(d,Yv,b);h=Iv(d,Zv,b);g&&h&&Xv(d,g,g+h)}}}} +function Hv(a,b,c,d,e){var f=a.C.length,g=b.Na/32|0;b.qq=d+"\\";for(var h=0;hJ)break;for(var H=v.hh+(J-2)*v.vf,G=0;G>3,1),d?e=16==b.sg?e<<8:c&7?e<<4:(e&15)<<8:c&7&&(e>>=4));return e} +function Ev(a,b){var c=a.gb*a.Wa,d=b/c|0;return dg)break;e|=g<=f)break;e+=String.fromCharCode(f)}return e}function zv(a,b,c,d,e,f){a||(a={sector:d,length:e,data:[],pattern:f});a.Fl=b;a.Gl=c;a.gd=a.Nc=0;a.Oa=!1;return a} +function Av(a,b){b="action=open&volume="+b+("&mode="+a.mode);b+="&chs="+a.sb+":"+a.gb+":"+a.Wa+":"+a.Na;b+="&machine="+xv(a.controller);b+="&user="+yv(a.controller);return Na()+"/api/v1/disk?"+b} +function bw(a,b,c,d,e,f,g){if(a.D){var h="action=read&volume="+a.H;h+="&chs="+a.sb+":"+a.gb+":"+a.Wa+":"+a.Na;h=h+("&addr="+b+":"+c+":"+d+":"+e)+("&machine="+xv(a.controller));h+="&user="+yv(a.controller);Ma(Na()+"/api/v1/disk?"+h,null,f,function(h,m,p){h=[b,c,d,e,f,g];var k=!1,u=h[0],A=h[1],J=h[2],H=h[3];if(!p){m=JSON.parse(m);for(k=0;H--;){var G=a.seek(u,A,J,!0);if(!G)break;Dv(G,m,k);k+=G.length;J++}k=h[4]}(h=h[5])&&h(p,k)})}else g&&g(-1,!1)} +function cw(a,b,c,d,e,f,g){if(a.D){var h={};a.M=!0;h.action="write";h.volume=a.H;h.chs=a.sb+":"+a.gb+":"+a.Wa+":"+a.Na;h.addr=b+":"+c+":"+d+":"+e;h.machine=xv(a.controller);h.user=yv(a.controller);h.data=JSON.stringify(f);Ma(Na()+"/api/v1/disk",h,g,function(f,h,p){var k=[b,c,d,e,g];f=k[0];h=k[1];var m=k[2],A=k[3];k=k[4];a.M=!1;if(0<=f&&fb&&(b=0);2E3>2,e=Array(d),f=0;f>=2;var e=a.data;a=a.pattern;for(var f=0;f>8&255;c[d++]=g>>16&255;c[d++]=g>>24&255}return c}l.read=function(a,b){var c=-1;if(a&&b>2;c=(d>((b&3)<<3)&255}return c}; +l.write=function(a,b,c){if(this.Pe)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.Nc?f=a.gd+a.Nc&&(a.Nc+=f-(a.gd+a.Nc)+1):(a.gd=f,a.Nc=1);d[f]=d[f]&~(255<=this.A.length||k>=this.A[h].length||m>=this.A[h][k].length){c="sector (CHS="+h+":"+k+":"+ +m+") out of range ("+b+" changes applied)";b=-1;break}if(this.Pe){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(h=this.A[h][k][m]){for(k=h.data.length;kb?-2!=b&&this.Da("Unable to restore disk '"+this.jd+": "+c):Cv(this);return b}; +function hw(a){for(var b=0,c;c=Ev(a,b++);)iw(c);a=JSON.stringify(a.A,function(a,b){if("file"!=a)return b});a=a.replace(/,"length":512/g,"").replace(/,"pattern":0/g,"").replace(/,"data":\[]/g,"");a=a.replace(/"(sector|length|data|pattern)":/g,"$1:");a=a.replace(/,"[^"]*":([0-9]+|true|false)/g,"");return a=a.replace(/(sector|length|data|pattern):/g,'"$1":')}function iw(a){var b=a.data,c=b.length;if(c<<2==a.length){for(var d=c-1,e=b[d],f=0;d--&&b[d]===e;)f++;f++&&(b.length=c-f,a.pattern=e)}}var vv=0; +function aw(a,b,c,d,e){this.va=a;this.hc=b;this.Tg=c;this.Yi=d;this.ge=e}function Tv(a,b,c){var d;c=c||2;var e=b&511,f=Ev(a.va,a.ge[b>>9]);if(f){if(e+c<=f.length)return Fv(a.va,f,e,c);for(e=d=0;c--;)d|=Tv(a,b++,1)<g.va.restore(A)&&(h=!1);h&&g.va&&void 0!==g.Va&&(g.hb=g.va.seek(g.Ib,g.bb,g.jb));h||(d=!1)}a.H=b[c++]||0;a.bc=b[c]||Aw;return d} +function uw(a){var b=0,c=[];c[b++]=a.Ya;c[b++]=0;c[b++]=a.ga;c[b++]=a.F;c[b++]=a.D;c[b++]=a.C;c[b++]=a.I;for(var d=b++,e=0,f=[],g=0;gyw(a,e,b,c,!1,d);){if(!window.confirm("Click OK to reload the original disk and discard any changes."))return!1;var g=a,h=c;for(f=0;fa.sb||f[1]>a.gb)this.Da('Diskette "'+c+'" too large for drive '+String.fromCharCode(65+a.Ya)),b=null}b?(a.va=b,a.Uk=c,a.ue=d,Dw(this,d)||rw(this,c,d),zw(this,c,d,b),f=b.info(),this.H|=Ew,a.Qe||this.Da('Mounted diskette "'+c+'" in drive '+String.fromCharCode(65+a.Ya),a.ke||e),a.rg=f[0],a.xf=f[1],a.yf=f[2],this.na&&this.na.cd()):a.Le=!1;a.ke&&(a.ke=!1,--this.K||Pb(this));mw(this,a.Ya);a.Qe&&(a.Qe(),a.Qe=null)}; +function rw(a,b,c,d){if((a=a.ma.listDisks)&&a.options){for(var e=0;e'+a+"");c.innerHTML=a}}l.Zo=function(a){for(var b=0;b=this.C&&(this.ga&=~(Hw|Iw),this.D=this.C=0);return c}; +l.Xn=function(a,b,c){r(this)&&t(this,a,b,c,"DATA["+this.C+"]");this.C=Kw[a].Jd){b=!1;this.D=0;a=Lw(this);var d=a&Jw;switch(d){case Mw:Lw(this);Lw(this);Nw(this);break;case Ow:c=Lw(this);this.Ya=c&3;var e=this.A[this.Ya];Nw(this);Pw(this,(e.tb&Qw)>>>24);break;case Rw:case Sw:c=Lw(this);b=c>>2&1;this.Ya=c&3;e=this.A[this.Ya];e.bb=b;c=e.Ib=Lw(this);var f=Lw(this);var g=e.jb=Lw(this);var h=Lw(this);e.yb=128<>2& +1;this.Ya=c&3;e=this.A[this.Ya];c=e.Ib;f=e.bb=b;g=e.jb=1;h=0;e.tb=Cw;e.va&&(e.hb=e.va.seek(e.Ib,e.bb,e.jb))?h=e.hb.length>>8:e.tb=Tw|Uw;Ww(this,e,a,b,c,f,g,h);b=!0;break;case cx:c=Lw(this);b=c>>2&1;this.Ya=c&3;e=this.A[this.Ya];c=e.Ib;f=e.bb=b;g=1;h=Lw(this);e.yb=128<>2&1,c=Lw(this),e.Ib+=c-e.Ud,0>e.Ib&&(e.Ib=0),e.Ib>=e.sb&&(e.Ib=e.sb-1),e.Ud=c,e.tb=Yw,e.Ib||(e.tb|=Zw),Nw(this),b=!0}0>>8);Pw(a,(b.tb&fx)>>>16);var k=0;if(e!=b.Ib||f!=b.bb)k=g=1;c&gx&&(f^=k,d||(k=0));Pw(a,e+k);Pw(a,f);Pw(a,g);Pw(a,h)}function Lw(a){var b=a.F[a.D];a.D++;return b}function Nw(a){a.D=a.C=0}function Pw(a,b){a.F[a.C++]=b}l.cl=function(a,b,c){void 0===b||0>b?this.te(a,c):c(-1,!1)};l.dl=function(a,b){return void 0!==b&&0<=b?hx(a,b):-1}; +l.ul=function(a,b){if(void 0!==b&&0<=b)a:if(a.tb)a=-1;else{a.Xc[a.He++]=b;if(a.He==a.Xc.length){a.Ib=a.Xc[0];a.bb=a.Xc[1];a.jb=a.Xc[2];a.yb=128<hx(a,a.Ui)){a=-1;break a}a.eg++}a.eg>=a.Vd&&(b=-1);a=b}else a=-1;return a};l.te=function(a,b){var c=-1,d=null,e=0;if(!a.tb&&a.va){do{if(a.hb&&(e=a.Va,0<=(c=a.va.read(a.hb,a.Va++)))){d=a.hb;break}a.hb=a.va.seek(a.Ib,a.bb,a.jb);if(!a.hb){a.tb=ix|Uw;break}a.Va=0;jx(a)}while(1)}b(c,!1,d,e)}; +function hx(a,b){if(a.tb||!a.va)return-1;do{if(a.hb&&a.va.write(a.hb,a.Va++,b))break;a.hb=a.va.seek(a.Ib,a.bb,a.jb);if(!a.hb){a.tb=kx|Uw;b=-1;break}a.Va=0;jx(a)}while(1);return b}function jx(a){a.jb++;a.jb>=a.yf+1&&(a.jb=1,a.bb++,a.bb>=a.xf&&(a.bb=0,a.Ib++))}var xw="Floppy Drive",Fw=4,Gw=8,Iw=16,Hw=64,vw=128,Mw=3,Ow=4,Rw=5,Sw=6,Xw=7,$w=8,bx=10,cx=13,dx=15,Jw=31,gx=128,Cw=0,Tw=8,Yw=32,Uw=64,ww=192,ax=255,Vw=512,ix=1024,kx=8192,ex=65280,fx=16711680,Zw=268435456,Qw=-16777216,Ew=128,Aw=0;aa={}; +var Kw={3:{Jd:3,Wd:0,name:aa.eq},4:{Jd:2,Wd:1,name:aa.bq},5:{Jd:9,Wd:7,name:aa.iq},6:{Jd:9,Wd:7,name:aa.Yp},7:{Jd:2,Wd:0,name:aa.$p},8:{Jd:1,Wd:2,name:aa.cq},10:{Jd:2,Wd:7,name:aa.Zp},13:{Jd:6,Wd:7,name:aa.Vp},15:{Jd:3,Wd:0,name:aa.aq}},pw={1009:jw.prototype.lm,1012:jw.prototype.nm,1013:jw.prototype.km,1015:jw.prototype.mm},qw={1010:jw.prototype.Yn,1013:jw.prototype.Xn,1015:jw.prototype.Wn}; +cb(function(){for(var a=zb(document,"pcx86","fdc"),b=0;bk.va.restore(g)&&(A=!1),A&&void 0!==k.Va&&(k.hb=k.va.seek(k.Od,k.bb,k.jb+k.dg)));A||(e=!1);null!=a.P&&1>=d&&(a.P|=(f.type&3)<<(1-d<< +1))}0<=a.Ya&&(a.B=a.A[a.Ya]);return e} +function tx(a){var b=0,c=[];a.M?(c[b++]=a.I,c[b++]=a.ta,c[b++]=a.J,c[b++]=a.fa,c[b++]=a.ea,c[b++]=a.ba,c[b++]=a.U,c[b++]=a.ga,c[b++]=a.ha,c[b++]=[a.L,a.Ya]):(c[b++]=a.P,c[b++]=a.ga,c[b++]=a.F,c[b++]=a.D,c[b++]=a.C,c[b++]=a.ra,c[b++]=a.pa,c[b++]=a.qa,c[b++]=a.N);for(var d=0,e=[],f=0;f=this.C&&(this.D=this.C=0,this.ga&=~(Cx|Dx|Ex));return c};l.vo=function(a,b,c){t(this,a,b,c,"DATA["+this.C+"]");this.C=a&&(this.ga|=Cx,this.ga&=~Gx,Hx(this))};l.Om=function(a,b){var c=this.ga;t(this,a,null,b,"STATUS",c);this.D=a.B.Na?(a.ga=Jx,a.te(a.B,function(b){0<=b?(Kx(a),a.V&&a.V.da==zl&&(a.ga=0),a.ga=a.ga|ux|Lx|Mx):(a.ga=Nx,a.I=Ox)},!1)):a.ga=ux|Lx));return d}l.gl=function(a,b){return Ix(this,a,b)|Ix(this,a,b)<<8}; +function Px(a,b,c,d){if(a.B&&a.B.yb>=a.B.Na)if(0>Qx(a.B,c))a.ga=Nx,a.I=Ox;else if(1==a.B.Va||a.B.Va==a.B.Na)r(a,1048832)&&t(a,b,c,d,"DATA["+a.B.Va+"]"),1=a.B.Na&&(a.ga|=Mx))}l.An=function(a,b,c){Px(this,a,b&255,c);Px(this,a,b>>8&255,c)};l.Ql=function(a,b){var c=this.I;t(this,a,null,b,"ERROR",c);return c};l.Fn=function(a,b,c){t(this,a,b,c,"WPREC");this.ta=b};l.Sl=function(a,b){var c=this.J;t(this,a,null,b,"SECCNT",c);return c}; +l.Dn=function(a,b,c){t(this,a,b,c,"SECCNT");this.J=b};l.Tl=function(a,b){var c=this.fa;t(this,a,null,b,"SECNUM",c);return c};l.En=function(a,b,c){t(this,a,b,c,"SECNUM");this.fa=b};l.Ol=function(a,b){var c=this.ea;t(this,a,null,b,"CYLLO",c);return c};l.zn=function(a,b,c){t(this,a,b,c,"CYLLO");this.ea=b};l.Nl=function(a,b){var c=this.ba;t(this,a,null,b,"CYLHI",c);return c};l.yn=function(a,b,c){t(this,a,b,c,"CYLHI");this.ba=b};l.Pl=function(a,b){var c=this.U;t(this,a,null,b,"DRVHD",c);return c}; +l.Bn=function(a,b,c){t(this,a,b,c,"DRVHD");this.U=b;this.ga=this.A[this.U&Rx?1:0]?this.ga|ux|Lx:this.ga&~ux};l.Ul=function(a,b){var c=this.ga;t(this,a,null,b,"STATUS",c);this.ga&ux&&(this.ga&=~Jx);return c};l.xn=function(a,b,c){t(this,a,b,c,"COMMAND");this.ha=b;this.V&&Zg(this.V,14);Sx(this)};l.Cn=function(a,b,c){t(this,a,b,c,"FDR");this.L&Tx&&!(b&Tx)&&(this.I=Ux);this.L=b}; +function Sx(a){var b=!1,c=a.ha,d=a.U&Rx?1:0,e=a.U&Vx,f=a.ea|(a.ba&Wx)<<8,g=a.fa,h=a.J||256;a.Ya=-1;a.B=null;a.I=Xx;a.ga=ux|Lx;var k=a.A[d];k?(k.Od=f,k.bb=e,k.jb=g,k.yb=h*k.Na,c=c>=Yx?c:c&Zx,k.hb=null,k.Va=0,k.errorCode=0,a.Ya=d,a.B=k):c=-1;switch(c&Zx){case $x:b=!0;break;case ay:a.ga=Jx;a.te(k,function(b){0<=b&&a.V?(Kx(a),a.ga=ux|Lx|Mx):(a.ga=Nx,a.I=Ox)},!1);break;case by:a.ga=Mx;break;case cy:b=!0;break;case dy:b=!0;break;case Yx:a.I=Ux;b=!0;break;case ey:k.gb=e+1,k.Wa=h,b=!0}b&&Kx(a)} +function Kx(a){a.V&&(a.L&fy||mh(a.V,14,120))} +function Hx(a){a.D=0;var b=gy(a),c=gy(a),d=c&32,e=d>>5,f=c&31,g=gy(a),h=gy(a),k=g<<2&768|h,m=g&63,p=gy(a),v=gy(a),u=a.A[e];u&&(u.Od=k,u.bb=f,u.jb=m,u.yb=p*u.Na);switch(b){case hy:iy(a,u?u.errorCode:jy);ky(a,c);ky(a,g);ky(a,h);ky(a,ly|d);b=-1;break;case Fx:for(c=0;0<=(b=gy(a));)u&&cb?this.te(a,c):c(-1,!1)};l.fl=function(a,b){return void 0!==b&&0<=b?Qx(a,b):-1}; +l.vl=function(a,b){void 0!==b&&0<=b?(a.VaQx(a,a.Ui)){a=-1;break a}a.eg++}a.eg>=a.Vd&&(b=-1);a=b}else a=-1;return a}; +function ty(a,b,c){b.errorCode=jy;if(b.va&&(b.hb=null,a.V)){b.errorCode=wx;Sn(a.V,3,a,"dmaRead",b);Jn(a.V,3,function(a){a||b.errorCode!=wx||(b.errorCode=jy);c(b.errorCode?my:ly)});return}c(b.errorCode?my:ly)}function vy(a,b,c){b.errorCode=jy;if(b.va&&(b.hb=null,a.V)){b.errorCode=wx;Sn(a.V,3,a,"dmaWrite",b);Jn(a.V,3,function(a){a||(b.errorCode==wx&&(b.errorCode=jy),b.errorCode==yy&&(b.errorCode=wx));c(b.errorCode?my:ly)});return}c(b.errorCode?my:ly)} +function xy(a,b,c){b.errorCode=jy;b.De&&b.De.length==b.yb||(b.De=Array(b.yb));b.Va=0;a.V?(b.errorCode=wx,Sn(a.V,3,a,"dmaWriteBuffer",b),Jn(a.V,3,function(a){a||b.errorCode!=wx||(b.errorCode=jy);c(b.errorCode?my:ly)})):c(b.errorCode?my:ly)} +l.te=function(a,b,c){var d=-1,e=null,f=0;if(a.errorCode)return b&&b(d,!1,e,f),d;var g=!1!==c?1:0;if(a.hb&&(f=a.Va,d=a.va.read(a.hb,a.Va),a.Va+=g,0<=d))return e=a.hb,b&&b(d,!1,e,f),d;if(b){if(a.va)return a.va.seek(a.Od,a.bb,a.jb+a.dg,!1,function(c,k){(a.hb=c)?(e=c,f=a.Va=0,zy(a),d=a.va.read(a.hb,a.Va),a.Va+=g):a.errorCode=yy;b(d,k,e,f)}),d;a.errorCode=yy;b(d,!1,e,f)}return d}; +function Qx(a,b){if(a.errorCode)return-1;do{if(a.hb&&a.va.write(a.hb,a.Va++,b))break;a.va&&a.va.seek(a.Od,a.bb,a.jb+a.dg,!0,function(b){a.hb=b});if(!a.hb){a.errorCode=yy;b=-1;break}a.Va=0;zy(a)}while(1);return b}function zy(a){a.jb++;var b=1-a.dg;a.jb>=a.Wa+b&&(a.jb=b,a.bb++,a.bb>=a.gb&&(a.bb=0,a.Od++))}l.Pm=function(){var a=this.G.L&255;!(this.G.D>>8)&&128>8||!this.V)||(a=!(this.V.ic[0].sd&64));return a?!0:!1}; +var xx="Hard Drive",Ax=["XTC","ATC","COMPAQ"],yx=[{0:[306,2],1:[375,8],2:[306,6],3:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[940,8],5:[940,6],6:[615,4],7:[462,8],8:[733,5],9:[900,15],10:[820,3],11:[855,5],12:[855,7],13:[306,8],14:[733,7],16:[612,4],17:[977,5],18:[977,7],19:[1024,7],20:[733,5],21:[733,7],22:[733,5],23:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[1023,8],5:[940,6],6:[697,5],7:[462,8],8:[925,5],9:[900,15],10:[980,5],11:[925,7],12:[925,9],13:[612,8],14:[980,4],16:[612,4],17:[980,5],18:[966, +6],19:[1023,8],20:[733,5],21:[733,7],22:[524,4,40],23:[924,8],24:[966,14],25:[966,16],26:[1023,14],27:[832,6,33],28:[1222,15,34],29:[1240,7,34],30:[615,4,25],31:[615,8,25],32:[905,9,25],33:[832,8,33],34:[966,7,34],35:[966,8,34],36:[966,9,34],37:[966,5,34],38:[612,16,63],39:[1023,11,33],40:[1023,15,34],41:[1630,15,52],42:[1023,16,63],43:[805,4,26],44:[805,2,26],45:[748,8,33],46:[748,6,33],47:[966,5,25]}],qx=496,Ux=1,Xx=0,Ox=16,Wx=3,Vx=15,Rx=16,Nx=1,Mx=8,Lx=16,ux=64,Jx=128,$x=16,ay=32,by=48,cy=64,dy= +112,Yx=144,ey=145,Zx=240,fy=2,Tx=4,ly=0,my=2,py=0,qy=1,hy=3,ry=5,sy=8,uy=10,Fx=12,wy=15,ny=224,oy=228,wx=0,jy=4,yy=20,vx=0,Gx=1,Cx=2,Dx=4,Ex=8,Bx=32,nx={800:lx.prototype.Nm,801:lx.prototype.Om,802:lx.prototype.Mm},mx={496:lx.prototype.gl,497:lx.prototype.Ql,498:lx.prototype.Sl,499:lx.prototype.Tl,500:lx.prototype.Ol,501:lx.prototype.Nl,502:lx.prototype.Pl,503:lx.prototype.Ul},px={800:lx.prototype.vo,801:lx.prototype.yo,802:lx.prototype.xo,803:lx.prototype.wo,807:lx.prototype.di,811:lx.prototype.di, +815:lx.prototype.di},ox={496:lx.prototype.An,497:lx.prototype.Fn,498:lx.prototype.Dn,499:lx.prototype.En,500:lx.prototype.zn,501:lx.prototype.yn,502:lx.prototype.Bn,503:lx.prototype.xn,1014:lx.prototype.Cn};cb(function(){for(var a=zb(document,"pcx86","hdc"),b=0;bthis.A&&this.C.length&&(this.A=0);if(0>this.A||a!=this.C[this.A])this.C.splice(0,0,a),this.A=0;this.A--}else this.fa?a="end":a=this.C[this.A+1];b=[];if(a){a=a.replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(Da(a.substring(d,f))),d=f+1}}return b}; +function By(a,b,c){var d=a;b=b||32;if(c)if(32==b)d=a>>>0;else if(32>b)d=a&(1<a||a>=b)d=a%b,0>d&&(d+=b)}else 32>=b?d=a<<32-b>>32-b:(b=Math.pow(2,b-1),a>=b?(d=a%b,(a/b|0)&1&&(d-=b)):a<-b&&(d=a%b,((-a-1)/b|0)&1?d&&(d+=b):d||(d-=b)));a!=d&&(a=d);return a} +function Cy(a,b,c){for(c=void 0===c?-1:c;c--&&b.length;){var d=b.pop();if(2>a.length)return!1;var e=a.pop();var f=a.pop();switch(d){case "*":f*=e;break;case "/":if(!e)return!1;f=Math.trunc(f/e);break;case "^/":if(!e)return!1;f%=e;break;case "+":f+=e;break;case "-":f-=e;break;case "<<":f<<=e;break;case ">>":f>>=e;break;case ">>>":f>>>=e;break;case "<":f=f":f=f>e?1:0;break;case ">=":f=f>=e?1:0;break;case "==":f=f==e?1:0;break;case "!=":f=f!=e?1:0;break; +case "&":f&=e;break;case "!":case "|":f|=e;break;case "^!":f|=e;break;case "&&":f=f&&e?1:0;break;case "||":f=f||e?1:0;break;case ",,":f=By(f,18,!0)*Math.pow(2,18)+By(e,18,!0);break;case "_":case "^_":"^_"==d&&(e=35-(e&255));e&&(f=By(f,0,!0),f=0=|>>>|>>|>|<=|<<|<|-|\+|\^\/|\/|\*|,,| )/);d=Dy(a,b,0,b.length,a.D,c);void 0!==d&&e&&Ly(a,null,d)}return d} +function My(a,b){var c=a.ha[0],d=a.ha[1];var e="("==c||"{"==c||"["==c?"\\":"";var f="["==c?"\\":"";for(f=new RegExp(e+c+"([^"+f+c+f+d+"]+)"+e+d);e=b.match(f);){var g=Ky(a,e[1]);if(void 0===g)return;b=b.replace(c+e[1]+d,null!=g?Jy(a,g):"undefined")}if(a.Ea.length)for(c=a.Ea[0],d=a.Ea[1],e="("==c||"{"==c||"["==c?"\\":"",f="["==c?"\\":"",f=new RegExp(e+c+"([^"+f+c+f+d+"]+)"+e+d);e=b.match(f);)b=a.Kk(b,e[1]);for(;c=b.match(/\$([a-z]+)/i);){d=null;switch(c[1].toLowerCase()){case "ops":d=a.ba-a.ka}if(null== +d)break;b=b.replace(c[0],d.toString())}return b}function Fy(a,b){for(;b;){switch(b&3){case 1:a=-By(a);break;case 2:a|=-1;break;case 3:for(var c=35;0<=c&&!(a&Math.pow(2,c));)c--;a=35-c}b>>>=2}return a} +function Ey(a,b,c,d,e){e=void 0===e?0:e;var f=Array.isArray(d)?d:void 0;if(null!=b){var g=a.dh(b);if(0<=g)g=a.eh(g);else if(g=b,a.I[g]?g=a.I[g].value:(g=g.substr(0,6),g=a.I[g]&&a.I[g].value),null!=g){var h=a.I[b]&&a.I[b].Vo;h&&(f?f.push(h):(f=Ky(a,h,d),void 0!==f?g+=f:(d||a.O("undefined "+(c||"value")+": "+b+" ("+h+")"),g=void 0)))}else g=qa(b,1c&&(e+=" '"+String.fromCharCode(c)+"'")}a.O((null!=b?b+": ":"")+e);return d}function Ny(a,b){var c=0;if(a.I){if(b)return Ly(a,b,a.I[b]&&a.I[b].value);b=Object.keys(a.I);b.sort();for(var d=0;d=Math.abs(b)?5:11;b=sa(b,10,a);break;default:b=q(b,0>2:0,!!e)}0>c?c=b.replace(/^0+([0-9A-F]+)$/i,"$1"):c=b;return c} +var Hy={"||":5,"&&":6,"!":7,"|":7,"^!":8,"&":9,"!=":10,"==":10,">=":11,">":11,"<=":11,"<":11,">>>":12,">>":12,"<<":12,"-":13,"+":13,"^/":14,"/":14,"*":14,_:19,"^_":19,"{":20,"}":20},Gy={",,":1,"||":5,"&&":6,"!=":10,"==":10,">=":11,">":11,"<=":11,"<":11,">>>":12,">>":12,"<<":12,"-":13,"+":13,"^/":14,"/":14,"*":14,"!":15,"|":15,"^!":15,"&":15,_:19,"^_":19,"{":20,"}":20}; +function Oy(a){Ay.call(this,a);this.ra=4;this.la=5;this.xa=1048575;this.N=Py(this,0,0);this.Ca=Py(this,0,0);this.ea=Py(this,0,0);this.F=[];this.B=this.V=this.L=[];Qy(this);this.wa=0;Ry(this);this.Fa={};Sy(this,a.messages);this.Ka=a.commands;var b=this;window?void 0===window.pcx86&&(window.pcx86=function(a){return Ty(b,a)}):void 0===global.pcx86&&(global.pcx86=function(a){return Ty(b,a)})}ia(Oy,Ay);l=Oy.prototype; +l.tc=function(a,b,c,d){this.oa=b;this.G=c;this.na=a;this.cb=ac(a,"FDC");this.Pa=ac(a,"HDC");this.Kc=ac(a,"FPU");this.H=ac(a,"Mouse");(a=Bd(a,"messages"))&&Sy(this,a);this.la=b.I>>2;this.xa=b.N;this.ab=new Zd(this.G,7,"DBG");this.pa=Uy;80186<=this.G.da&&(this.pa=Uy.slice(),this.pa[15]=Vy,80286<=this.G.da&&(this.pa[15]=Wy,80386<=this.G.da&&(this.ra=8)));Cl(this,64,function(a){Xy(d,d.G.sc,a[0])});Cl(this,4,function(a){if(a=a[0]){var b=Ey(d,a);if(void 0===b)d.O("invalid selector: "+a);else if(a=Yy(d, +b,Zy),d.O("dumpSel("+wa(a?a.T:b)+"): %"+q(a?a.Ob:null,d.la)),a){b=!1;if(a.type&4096){if(a.type&2048){var c="code"+(a.type&512?",readable":",execonly");a.type&1024&&(c+=",conforming")}else c="data"+(a.type&512?",writable":",readonly"),a.type&1024&&(c+=",expdown");a.type&256&&(c+=",accessed")}else{var e=$y[a.type];e&&(c=e[0],b=e[1])}!c||a.ob&32768||(c+=",not present");d.O((b?"seg="+wa(a.ua&65535)+" off="+wa(a.Sa):"base="+q(a.ua,d.la)+" limit="+az(a.Sa))+" type="+va(a.type>>8)+" ("+c+") ext="+wa(a.ext& +-65296)+" dpl="+va(a.qc))}}else d.O("no selector")});Cl(this,134217728,function(a){var b;(a=a[0])&&(b=Ey(d,a));if(void 0===b)d.O("invalid MCB");else for(d.O("dumpMCB("+wa(b)+")");b;){a=Py(d,0,b);var c=d.ya(a,1),e=d.Vc(a,2),k=d.Vc(a,5);if(77!=c&&90!=c)break;d.O(bz(0,b)+": '"+String.fromCharCode(c)+"' PID="+wa(e)+" LEN="+wa(k)+' "'+cz(d,a,8)+'"');b+=1+k}});Cl(this,128,function(a){Xy(d,d.G.Z,a[0],d.G.Z!==d.G.sc)});Cl(this,8,function(a){a:{if(a=a[0]){var b=Ey(d,a);if(void 0===b){d.O("invalid task selector: "+ +a);break a}a=Yy(d,b,Zy)}else a=d.G.ka;d.O("dumpTSS("+wa(a?a.T:b)+"): %"+q(a?a.ua:null,d.la));if(a){b="";var c=a.type&-513,e=256==c?4:8,k=256==c?dz:ez;for(u in k){var m=k[u];var p=a.ua+m;var v=Ag(d.G,p,2);2304==c&&(v|=Ag(d.G,p+2,2)<<16);b&&(b+="\n");b+=wa(m)+" "+Ca(u+":",11)+q(v,e)}if(2304==c){var u=0;for(m=v>>>16;mu;){p=a.ua+m;v=Ag(d.G,p,2);p=2;c="";if(!p||4>=8;b+="\n"+wa(m)+" ports "+wa(u)+"-"+wa(u+15)+": "+(""+c);u+=16;m+=2}}d.O(b)}}}); +this.J=null;this.La=0;this.Ga=!1;Wf(this.G,48,this.Tm.bind(this));Wf(this.G,65,this.Um.bind(this));this.Z=null;Wf(this.G,104,this.Vm.bind(this));Pb(this)};function fz(a,b,c,d,e,f){b=cz(a,b);var g=Yy(a,d);g=g?g.Sa+1:0;var h=(e?"_CODE":"_DATA")+q(c,2);f&&r(a,128)&&a.message(b+" "+(e?"code":"data")+"("+q(c,4)+")=#"+q(d,4)+" len "+q(g));e=gz(a,b,c);e[b+h]=0;jq(a,b,c,d,0,null,g,e)} +function hz(a,b,c,d){var e=a.Vc(b,2),f=a.Vc(b,2),g=iz(a,b,4),h=iz(a,b,4),k=Py(a,iz(a,b,4),a.Vc(b,2));b=Py(a,iz(a,b,4),a.Vc(b,2));b=cz(a,b).toUpperCase();k=cz(a,k).toUpperCase();var m=(c?"_CODE":"_DATA")+q(e,2);d&&r(a,128)&&a.message((b==k?"":b+"!")+k+" "+(c?"code":"data")+"("+q(e,4)+")="+q(f,4)+":"+q(g)+" len "+q(h));c=gz(a,k,e);c[k+m]=g;jq(a,k,e,f,g,null,h,c)}function jz(a,b,c){c=cz(a,c).toUpperCase();kz(a,c,b)} +l.Tm=function(){var a=this.G;if(null!=this.J&&2752554==a.D){var b=a.L&65535,c=a.K&65535,d=Py(this,y(a)+12,a.U.T);switch(iz(this,d)){case 336:hz(this,Py(this,a.H,b),!c,!!this.J)}}return!0}; +l.Um=function(a){var b=this.G,c=b.D&65535,d=b.H&65535,e=b.I&65535,f=b.L&65535,g=b.K&65535,h=b.J&65535,k=b.pa.T;if(null==this.J)return 79==c&&Xf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Tb(a,"INT 0x41 handling enabled",128),a.J=!0):(Tb(a,"INT 0x41 monitoring enabled",128),a.J=!1)}}(this)),!0;switch(c){case 79:this.J&&(b.D=b.D&-65536|62342,Tb(this,"INT 0x41 handling enabled",128));break;case 80:fz(this,Py(this,h,k),d+1,e,!(g&1),!!this.J);break;case 82:kz(this,null, +d);break;case 127:this.J&&(b.D=b.D&-65536|(this.Ga?0:1));break;case 131:this.J&&(a=Py(this,b.L,e),this.La++?(this.O("TRAPFAULT failed"),lz(this,this.B,a,!0,!0),this.La=0,rk(this)):(this.O("INT 0x41 TRAPFAULT: fault="+wa(d)+" error="+q(b.K,8,!0)+" addr="+mz(a)),this.rd(this.B,a,!0),Ry(this,!0)));break;case 141:this.J&&(b.D=b.D&-65536|1);break;case 336:hz(this,Py(this,b.H,f),!g,!!this.J);break;case 338:jz(this,d,Py(this,b.J,f))}this.Ga=!1;return!this.J}; +l.Vm=function(a){var b=this.G,c=b.D&255,d=b.D>>8&255,e=b.H&65535,f=b.I&65535,g=b.L&65535,h=b.J&65535,k=b.pa.T;if(null==this.Z){if(67==d){if(609437257==b.ia((b.ba.T<<4)+10)||1111835735==b.ia((b.ba.T<<4)+95))return!0;Xf(b,a,function(a){return function(){62342!=(b.D&65535)?(b.D=b.D&-65536|62342,Tb(a,"INT 0x68 handling enabled",128),a.J=a.Z=!0):(Tb(a,"INT 0x68 monitoring enabled",128),a.Z=!1)}}(this))}return!0}switch(d){case 67:this.Z&&(b.D=b.D&-65536|62342);break;case 68:this.Z&&(a=ce(b.ba,this.rl.bind(this)))&& +(b.J=a[0],ue(b,a[1]));break;case 72:kz(this,null,e);break;case 80:32==c?fz(this,Py(this,h,k),0,f,!0,!!this.Z):128>c?fz(this,Py(this,h,k),e+1,c&64?g:f,!(c&1),!!this.Z):hz(this,Py(this,h,k),!(c&1),!!this.Z),this.Z&&(b.D=b.D&-256|1)}return!this.Z};l.rl=function(){var a=this.G;5==(a.D&255)&&(a.I=a.K=0,a.D=a.D&-256|1);return!1}; +l.Eb=function(a,b,c){var d=this;switch(b){case "debugInput":return this.ta=this.ma[b]=c,c.onkeydown=function(a){if(13==a.keyCode){var b=c.value;c.value="";Ty(d,b,!0)}else if(27==a.keyCode)c.value=b="";else if(38==a.keyCode?(b=null,d.A>>0)+1;a.ob=f;a.type=g;a.ext=k;a.Ob=d;be(a,!0,!0,!1)}}return a}l.Vb=function(a,b,c){var d=a&&a.za;if(null==d&&(d=-1,a)){var e=Yy(this,a.T,a.type);e&&(b=a.Ja||0,c=c||1,d=e=-1===e.Ob||e.ed&&(b>>>0)+c>e.Nb||!e.ed&&(b>>>0)+c<=e.Nb?e.ua+b|0:-1,a.za=d)}return d};l.ya=function(a,b){var c=255,d=this.Vb(a,!1,1);-1!==d&&(c=Ag(this.G,d,1,a.type==qz)|0,b&&rz(this,a,b));return c}; +l.nb=function(a,b){return a.Jb?iz(this,a,b?4:0):this.Vc(a,b?2:0)};l.Vc=function(a,b){var c=65535,d=this.Vb(a,!1,2);-1!==d&&(c=Ag(this.G,d,2,a.type==qz)|0,b&&rz(this,a,b));return c};function iz(a,b,c){var d=-1,e=a.Vb(b,!1,4);-1!==e&&(d=Ag(a.G,e,4,b.type==qz)|0,c&&rz(a,b,c));return d}l.ub=function(a,b,c,d){var e=this.Vb(a,!0,1);if(-1!==e){if(a.type!=qz)this.G.ub(e,b);else{var f=this.oa;f.Z[(e&f.C)>>>f.A].bf(e&f.D,b&255,e)}c&&rz(this,a,c);d||Fd(this.G,!0)}}; +l.bl=function(a,b,c){var d=this.Vb(a,!0,2);-1!==d&&(a.type!=qz?this.G.ib(d,b):Mc(this.oa,d,b),c&&rz(this,a,c),Fd(this.G,!0))};function Py(a,b,c,d,e,f,g){return sz(a,{},b,c,d,e,f,g)}function sz(a,b,c,d,e,f,g,h){b.Ja=c||0;b.T=d;b.za=e;b.type=f||(oz(a)?Zy:pz);b.Jb=null!=g?g:!(!a.G||4!=a.G.ba.X);b.ec=null!=h?h:!(!a.G||4!=a.G.ba.Lc);b.wd=!1;return b}function tz(a){return[a.Ja,a.T,a.za,a.wd,a.Jb,a.ec,a.Ee,a.Zg]}function uz(a){return{Ja:a[0],T:a[1],za:a[2],wd:a[3],Jb:a[4],ec:a[5],Ee:a[6],Zg:a[7]}} +function vz(a,b,c){if(null!=b.T&&(a=Yy(a,b.T,b.type))){var d=b.Ja&a.xa;if(!a.ed){if(d>>>0>=a.Nb)return!1}else if(d>>>0e?null!=g?(f=Ky(a,b,void 0),e=null):(e=Ky(a,b,void 0),null==e&&(f=null)):(g=Ky(a,b.substring(0,e),void 0),f=Ky(a,b.substring(e+1),void 0),e=null)}null!=f&&(h=Py(a,f,g,e,c),d||vz(a,h,!0)||(a.O("invalid offset: "+mz(h)),h=null));return h}function zz(a,b,c){c&&(c=c.match(/(['"])(.*?)\1/))&&(b.ll=a.zg(b.Tk=c[2]))}l.Kk=function(a,b){var c=wz(this,b);return a.replace("["+b+"]",c?q(this.nb(c),c.Jb?8:4):"undefined")}; +function rz(a,b,c){c=c||1;null!=b.za&&(b.za+=c);null!=b.T&&(b.Ja+=c,vz(a,b)||(b.Ja=0,b.za=null))}function bz(a,b,c){return null!=b?q(b,4)+":"+q(a,a&-65536||c?8:4):q(a)}function mz(a){switch(a.type){case pz:case Az:var b="&";break;case Zy:b="#";break;case yz:b="%";break;case qz:b="%%";break;default:b=a.T?"":"%"}return a.type>=yz||null==a.T?b+q(a.za):b+bz(a.Ja,a.T,a.ec)} +function cz(a,b,c){var d="";for(c=c||256;d.length>>a.G.lb;g=1}a.O("blockid "+(d?"linear ":"physical")+" blockaddr used size type");a.O("-------- --------- ---------- ------ ------ ----");c=-1;for(var h=0;g--;)(d=b[f])&&d.type==ed&&(d=qd(a.G,e,!1,!0)),d.type==c?h++||a.O("..."):(c=d.type,h=wc[c],c==gd&&(d=d.td,h+=" -> "+wc[d.type]),d&&a.O(q(d.id,8)+" %"+q(f<c&&(c=Ja(Cz,a.substr(b,2)));return c}; +function Dz(a,b){var c=0,d=a.eh(b);if(null!=d)switch(b){case Ez:case Fz:case Gz:case Hz:case Iz:case Jz:case Kz:case Lz:c=2;break;case Mz:case Nz:case Oz:case Pz:case Qz:case Rz:case Sz:case Tz:case Uz:case Vz+Wz:case Vz+Xz:case Vz+Yz:case Vz+Zz:case Vz+$z:case Vz+aA:c=4;break;case bA:case cA:case dA:case eA:case fA:case gA:case hA:case iA:case jA:case kA:case lA:case mA:case nA:c=8;break;case oA:c=a.ra}return c?q(d,c):"??"} +l.eh=function(a){if(0<=a){var b=this.G;switch(a){case Ez:var c=b.D&255;break;case Fz:c=b.I&255;break;case Gz:c=b.L&255;break;case Hz:c=b.H&255;break;case Iz:c=b.D>>8&255;break;case Jz:c=b.I>>8&255;break;case Kz:c=b.L>>8&255;break;case Lz:c=b.H>>8&255;break;case Mz:c=b.D&65535;break;case Nz:c=b.I&65535;break;case Oz:c=b.L&65535;break;case Pz:c=b.H&65535;break;case Qz:c=y(b)&65535;break;case Rz:c=b.N&65535;break;case Sz:c=b.K&65535;break;case Tz:c=b.J&65535;break;case Uz:c=z(b)&65535;break;case oA:c= +xe(b);break;case Vz+Wz:c=b.pa.T;break;case Vz+Xz:c=b.ba.T;break;case Vz+Yz:c=b.U.T;break;case Vz+Zz:c=b.Fa.T;break;default:if(80286==this.G.da)a==jA&&(c=b.ra);else if(80386<=this.G.da)switch(a){case bA:c=b.D;break;case cA:c=b.I;break;case dA:c=b.L;break;case eA:c=b.H;break;case fA:c=y(b);break;case gA:c=b.N;break;case hA:c=b.K;break;case iA:c=b.J;break;case jA:c=b.ra;break;case kA:c=b.Mg;break;case lA:c=b.pd;break;case mA:c=b.wc;break;case Vz+$z:c=b.Ka.T;break;case Vz+aA:c=b.La.T;break;case nA:c= +z(b)}}}return c}; +function pA(a,b){b=My(a,b)||b;for(var c=0,d,e;0<=(c=b.indexOf("@",c));)e=a.dh(b,c+1),0<=e&&(b=b.substr(0,c)+Dz(a,e)+b.substr(c+1+Cz[e].length)),c++;for(c=0;0<=(c=b.indexOf("#",c));)e=b.substr(c+1,2),d=qa(e,16),null!=d&&32<=d&&128>d?(d=e+" '"+String.fromCharCode(d)+"'",b=b.replace("#"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("$",c));)e=b.substr(c+1,9),(d=wz(a,e))?(d=e+' "'+cz(a,d)+'"',b=b.replace("$"+e,d),c+=d.length):c++;for(c=0;0<=(c=b.indexOf("^",c));)e=b.substr(c+1,9),(d=wz(a,e))?(rz(a,d), +d=e+' "'+cz(a,d,11)+'"',b=b.replace("^"+e,d),c+=d.length):c++;return b}l.message=function(a,b){b&&(a+=" at "+mz(Py(this,z(this.G),this.G.ba.T))+" (%"+q(this.G.ea)+")");this.dc&536870912?this.Ba.push(a):this.Aa&&a==this.Aa||(this.Aa=a,this.dc&-2147483648&&(rk(this),a+=" (cpu halted)"),this.O(a),this.G&&(a=this.G,a.aa.Pf=!0,Fd(a)))}; +function al(a,b,c,d){var e;d||(d=r(a,1)&&0>qA.indexOf(b),d||(e=rA[b])&&(d=r(a,e)?!0:524288==e&&r(a,e=1048576)));if(d){var f=a.G.D>>8&255;var g=a.G.L&255;if(33==b&&11==f||524288==e&&128<=g||1048576==e&&128>g)d=!1}d&&((e=(e=Yb[b])&&e[f]||"")&&(e=" "+pA(a,e)),a.message("INT "+va(b)+": AH="+va(f)+" at "+bz(c-2-a.G.ba.ua,a.G.ba.T)+e));return d} +function Ub(a,b,c,d,e,f,g,h){h|=256;if(null==e||(a.dc&h)==h)h=null,null!=e&&(h=a.G.ba.T,e-=a.G.ba.ua),a.message(b.ye+"."+(null!=d?"outPort":"inPort")+"("+wa(c)+","+(f?f:"unknown")+(null!=d?","+va(d):"")+")"+(null!=g?": "+va(g):"")+(null!=e?" at "+bz(e,h):""))}l.fh=function(){this.O("Type ? for help with PCx86 Debugger commands");sA(this);if(this.Ka){var a=this.Ka;this.Ka=null;Ty(this,a)}}; +function Ry(a,b){var c;if(Og(a)){if(!a.U||!a.U.length){a.U=Array(tA);for(c=0;c>>g.lb].rd(f&g.Fb,a==this.L);h&&uc(g)}}e&&(a.push(b),c?(null!=b.za&&(b.T=null),b.wd=!0):(d||AA(this,a,a.length-1,"set"),Ry(this)));return e}; +function lz(a,b,c,d,e){for(var f=!1,g=BA(a,a.Vb(c)),h=1;h>3&7,A=(3>(g>>6&3)?0:48)+u;(217==f||219==f)&&52<=A&&(A=u<<4|g&7);(u=JA[f])&&(v=u[A]);v&&(p=KA,k=v,m=k[0])}m>=p.length&&(g=a.ya(b,1),k=LA[m-p.length][g>>3&7],m=k[0]);p=p[m];u=k.length-1;v="";b.Jb&&(m==MA?p= +"CWDE":m==NA?p="CDQ":m>=OA&&m<=PA&&(p+="D"));if(164<=f&&167>=f||170<=f&&175>=f)u=0,b.Jb&&"W"==p.slice(-1)&&(p=p.slice(0,-1)+"D");f=-1;A=!0;for(var J=1;J<=u;J++){var H="";var G=k[J];if(void 0!==G){0>f&&(f=G>>QA);m==RA&&(f==SA?v="[%800]":f==TA&&(v="ES:["+(b.ec?"E":"")+"DI]"));var P=G&UA;if(P!=VA)if(P==WA)A=!1;else{var I=G&XA;if(I>=R)if(0>g&&(g=a.ya(b,1)),I>6,ra=g&7;if(3>hb){P=0==p.indexOf("FI");if(!hb&&(!G.ec&&6==ra||G.ec&&5==ra))hb=2;else{if(G.ec)if(4!=ra)ra+= +8;else{Z=I;var ib=hb,Sb=G,Jb=Z.ya(Sb,1),cc=Jb>>6,vc=Jb>>3&7;Jb&=7;var jb="";if(ib||5!=Jb)jb=ZA[Jb+8];4!=vc&&(jb&&(jb+="+"),jb+=ZA[vc+8],cc&&(jb+="*"+(1<>24),2)):Z+("+"+q(I,2))):2==hb&&(Z&&(Z+="+"),G.ec?(I=iz(I,G,4),Z+=q(I)):(I=I.Vc(G,2),Z+=q(I,4)));Z="["+Z+"]";if(1==oa){I="";H&=UA;H==S&&(H=G.Jb?$A:T);switch(H){case aB:I="FAR";break;case U:I="BYTE";break;case T:if(P){I="INT16";break}I= +"WORD";break;case $A:I="DWORD";break;case bB:if(P){I="INT32";break}case cB:I="REAL32";break;case dB:if(P){I="INT64";break}case eB:I="REAL64";break;case fB:I="REAL80";break;case gB:I="BCD80"}I&&(Z=I+" "+Z)}}else Z=hB(I,ra,H,G);H=Z}else H=I==YA?hB(a,g&7,G,b):hB(a,g>>3&7,G,b);else if(I==iB)H="1";else if(I==V){H=a;P=G;I=b;G=" ";switch(P&UA){case U:P&W&&(G=q(H.ya(I,1),2));break;case jB:G=q(H.ya(I,1)<<24>>24,I.Jb?8:4);break;case S:if(I.Jb){G=q(iz(H,I,4));break}case T:G=q(H.Vc(I,2),4);break;case aB:I=Py(H, +H.nb(I,!0),H.Vc(I,2),null,I.type,I.Jb,I.ec);G=mz(I);H=kB(H,I);H[0]&&(G+=" ("+H[0]+")");break;default:G="imm("+wa(P)+")"}H=G}else I==lB?(b.ec?(H=8,G=iz(a,b,4)):(H=4,G=a.Vc(b,2)),H="["+q(G,H)+"]"):I==mB?(H=P==U?a.ya(b,1)<<24>>24:a.nb(b,!0),G=b.Ja+H&(b.Jb?-1:65535),H=q(G,b.Jb?8:4),G=kB(a,Py(a,G,b.T)),G[0]&&(H+=" ("+G[0]+")")):I==X?H=P==nB?"ST":P==oB?"ST("+(g&7)+")":hB(a,(G&pB)>>8,G,b):I==qB?H=hB(a,(G&pB)>>8,rB,b):I==sB?H="DS:[SI]":I==tB&&(H="ES:[DI]");if(!H||!H.length){v="INVALID";break}0aA||b>=$z&&80386>a.G.da)return"??";b+=Vz}else if(e==wB)b+=jA;else if(e==xB)b+=yB;else if(e==zB)b+=AB;else if(a=c&UA,a>=T&&(b=Mz&&b<=Tz&&4a.G.da&&(d="\n"+d,c+=e,e="");c+="\n"+DB(a,a.G.ba,b)+" ";80386<=a.G.da&&(e+="\n",c+=DB(a,a.G.Ka,b)+" "+DB(a,a.G.La,b)+"\n");c+=EB(a,"LD",a.G.Gb.T,a.G.Gb.ua,a.G.Gb.ua+a.G.Gb.Sa)+" "+EB(a,"GD",null,a.G.Kb,a.G.Jc)+" "+EB(a,"ID", +null,a.G.Qb,a.G.$c)+" ";c=c+(d+" "+e)+CB(a,jA);80386<=a.G.da&&(c+=CB(a,lA)+CB(a,mA))}else 80386<=a.G.da&&(c+=DB(a,a.G.Ka,b)+" "+DB(a,a.G.La,b)+" ");return c+=CB(a,oA)+BB(a,"V")+BB(a,"D")+BB(a,"I")+BB(a,"T")+BB(a,"S")+BB(a,"Z")+BB(a,"A")+BB(a,"P")+BB(a,"C")}l.cj=function(a,b){return a[0]>b[0]?1:a[0]>>0,p];var H=Fa(A,u,a.cj);0>H&&A.splice(-(H+1),0,u)}J&&(v.a=J.replace(/''/g,'"'))}a.F.push({hi:b,mn:c,T:d,Ja:e,za:f,Zm:g,Id:h,Mi:m})} +function kz(a,b,c){for(var d=0;d>>0,f=a.Vb(b)>>>0,g=0;g>>0,p=h.za;null!=p&&(p>>>=0);var v=h.Zm;48==k&&(k=40);if(k==b.T&&e>=m&&e=p&&fc?(a.O("out of data at address "+mz(b)),p=!0):(a.ub(b,c,1,!0),m++)})})(a,f);Fd(a.G, +!0);a.O(m+" bytes read at "+b)}else a.O("sector "+d+" request out of range");else a.O("drive "+g+" not loaded");else a.O("invalid drive: "+g)}else a.O("disk controller not present")}}}else a.O("load commands:"),a.O("\tl [address] [drive #] [sector #] [# sectors]")} +function vA(a,b){var c;if(b&&"?"==b[1])a.O("register commands:"),a.O("\tr\tdump registers"),a.Kc&&a.O("\trfp\tdump floating-point registers"),a.O("\trp\tdump all registers"),a.O("\trx [#]\tset flag or register x to [#]");else{null==c&&(c=!0);if(b&&1f;f++){var g=c;d=null;if(f=a.ra&&(h=null);switch(h){case "AL":a.G.D= +a.G.D&-256|g&255;break;case "AH":a.G.D=a.G.D&-65281|g<<8&255;break;case "AX":a.G.D=a.G.D&-65536|g&65535;break;case "BL":a.G.H=a.G.H&-256|g&255;break;case "BH":a.G.H=a.G.H&-65281|g<<8&255;break;case "BX":a.G.H=a.G.H&-65536|g&65535;break;case "CL":a.G.I=a.G.I&-256|g&255;break;case "CH":a.G.I=a.G.I&-65281|g<<8&255;break;case "CX":a.G.I=a.G.I&-65536|g&65535;break;case "DL":a.G.L=a.G.L&-256|g&255;break;case "DH":a.G.L=a.G.L&-65281|g<<8&255;break;case "DX":a.G.L=a.G.L&-65536|g&65535;break;case "SP":ne(a.G, +y(a.G)&-65536|g&65535);break;case "BP":a.G.N=a.G.N&-65536|g&65535;break;case "SI":a.G.K=a.G.K&-65536|g&65535;break;case "DI":a.G.J=a.G.J&-65536|g&65535;break;case "DS":te(a.G,g);break;case "ES":ue(a.G,g);break;case "SS":me(a.G,g);break;case "CS":cg(a.G,g);a.N=Py(a,z(a.G),a.G.ba.T);break;case "IP":case "EIP":C(a.G,g);a.N=Py(a,z(a.G),a.G.ba.T);break;case "PC":case "PS":ye(a.G,g);break;case "C":g?og(a.G):pg(a.G);break;case "P":g?(d=a.G,d.resultType&=-3,d.P|=4):(d=a.G,d.resultType&=-3,d.P&=-5);break; +case "A":g?wg(a.G):ug(a.G);break;case "Z":g?xg(a.G):vg(a.G);break;case "S":g?(d=a.G,d.resultType&=-17,d.P|=128):(d=a.G,d.resultType&=-17,d.P&=-129);break;case "I":g?(d=a.G,d.P|=512):(d=a.G,d.P&=-513);break;case "D":g?(d=a.G,d.P|=1024):(d=a.G,d.P&=-1025);break;case "V":g?qg(a.G):rg(a.G);break;default:var k=!0;if(80286<=a.G.da)switch(k=!1,h){case "MS":yg(a.G,g);break;case "TR":-1===a.G.ka.load(g)&&(f=!1);break;default:if(k=!0,80386<=a.G.da)switch(k=!1,h){case "EAX":a.G.D=g;break;case "EBX":a.G.H=g; +break;case "ECX":a.G.I=g;break;case "EDX":a.G.L=g;break;case "ESP":ne(a.G,g);break;case "EBP":a.G.N=g;break;case "ESI":a.G.K=g;break;case "EDI":a.G.J=g;break;case "FS":a.G.Ka.load(g);break;case "GS":a.G.La.load(g);break;case "CR0":a.G.ra=g;fk.call(a.G,g);break;case "CR2":a.G.pd=g;break;case "CR3":a.G.wc=g;a.G.wc=g;uc(a.G);break;default:k=!0}}if(k){a.O("unknown register: "+d);return}}if(!f){a.O("invalid value: "+b);return}Fd(a.G);a.O("updated registers:")}}a.O(FB(a,e));c&&(a.N=Py(a,z(a.G),a.G.ba.T), +wA(a,mz(a.N)))}}function NB(a,b){b=Da(b);var c=b.match(/^(['"])(.*?)\1$/);c?a.O(pA(a,c[2])):Ky(a,b,!1)}function OB(a,b,c){for(var d=null,e=b.Ja,f=e,g=1;6>=g&&e;g++){if(2e&&(e=1);4096h[0].indexOf("+"))){var m=h[0]+":";h[2]&&(m+=" "+h[2]);a.O(m)}h[3]&&(g=h[3],f=null);f=EA(a,b,g,f);b.Zg||d||d++;a.O(f);a.N=b;e-=b.za-k;c++}}} +l.zg=function(a,b,c){if(b)if(a){0>this.A&&this.C.length&&(this.A=0);if(0>this.A||a!=this.C[this.A])this.C.splice(0,0,a),this.A=0;this.A--}else a=this.C[this.A+1];b=[];if(a){a=a.toLowerCase().replace(/""/g,"'");var d=0,e=null;c=c||";";for(var f=0;f<=a.length;f++){var g=a.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==c&&!e||!g)b.push(Da(a.substring(d,f))),d=f+1}}return b}; +function DA(a,b,c){var d=!0;try{if(!b.length||"end"==b)a.fa&&(a.O("ended assemble at "+mz(a.ea)),a.N=a.ea,a.fa=!1),b="";else if(!c){var e=">> ";a.G.ra&1&&(e=a.G.P&131072?"-- ":"## ");a.O(e+b)}var f=b.charAt(0);if('"'==f||"'"==f)return!0;a.Aa=null;if(Ob(a)&&0p||"z">>20;Ra.Ri=a.G.wc+Ra.Ek;Ra.pb=xf.Z[(Ra.Ri&xf.C)>>>xf.A];Ra.yj=Ra.pb.Nd(Ra.Ek);Ra.Fk=($g&4190208)>>>10;Ra.Si=(Ra.yj&-4096)+Ra.Fk;Ra.qb=xf.Z[(Ra.Si&xf.C)>>>xf.A];Ra.zj=Ra.qb.Nd(Ra.Fk);Ra.nl=(Ra.zj&-4096)+($g&4095)}if(wf=Ra){a.O("linear PDE addr PDE PTE addr PTE physical");a.O("--------- ---------- -------- ---------- -------- ----------");var ij="%"+q($g);ij+=" %%"+Bz(wf.Ri,wf.yj);ij+=" %%"+ +Bz(wf.Si,wf.zj,!0);ij+=" %%"+q(wf.nl);a.O(ij)}else a.O("unsupported operation")}}else a.O("missing address")}else{if("d"==ra){if("disk"==ib){Z[0]="l";Z[1]="json";KB(a,Z);break a}for(hb in Zb)if(Z[1]==hb){var Nt=a.Fa[hb];Nt?(Z.shift(),Z.shift(),Nt(Z)):a.O("no dump registered for "+ib);break a}ib||(ra=a.mb||"db")}if("dh"==ra){var Ot=ib,Pt=Sb,ah=Jb;ah=void 0===ah?"history":ah;var Qt="",Rt=0,Rc=a.qa,rd=a.U;if(rd.length){var Ac=+Ot||a.Ra,bh=+Pt||10;isNaN(Ac)?Ac=bh:Qt="more ";Ac>rd.length&&(a.O("note: only "+ +rd.length+" available"),Ac=rd.length);Rc-=Ac;0>Rc&&(null==rd[rd.length-1].T?(Ac=Rc+Ac,Rc=0):Rc+=rd.length);var Cm=[];"call"==Pt&&(bh=1E5,Cm=["CALL"]);for(void 0!==Ot&&a.O(Ac+" instructions earlier:");0=rd.length&&(Rc=0);a.Ra=Ac;Rt++;bh--}}Rt||(a.O("no "+ +Qt+"history available"),a.Ra=void 0)}else if("di"==ra){Z.shift();var Dm=Z[0];if(Dm){var dh=Ey(a,Dm);if(void 0===dh||0>dh||255"abwd".indexOf(ra[1]))a.O("unrecognized dump command"); +else{a.mb=ra;var Fe=wz(a,ib);if(Fe&&(null!=Fe.T||null!=Fe.za)){var yf=0;if(Sb){if("l"==Sb.charAt(0))Sb=Sb.substr(1)||Jb,yf=Ey(a,Sb);else{var Yt=wz(a,Sb);if(!Yt)break a;yf=Yt.Ja-Fe.Ja+1}if(0>yf||65536>4||1,Gm=4==zf?16:a.D;"a"==ra[1]&&(Em=!0,Fm=25,Gm=160,eh=Fm*Gm);for(;Fm--&&0mj?String.fromCharCode(mj):Em?"":".";eh--}Ge&&(Ge+="\n");Ge=Em?Ge+lj:Ge+(ib+" "+Im+Ca(lj,lj.length+3*fh+1,!0))}Ge&&a.O(Ge.replace(/\s*$/,""));a.Ca=Fe}}}}}break;case "e":if("else"==g[0])break;var nj=1,Zt=255,$t=a.ya,au=a.ub;"ew"==g[0]&&(nj=2,Zt=65535,$t=a.Vc,au=a.bl);var bu=nj<<1,cu=g[1];if(null==cu)a.O("edit memory commands:"),a.O("\teb [a] [...] edit bytes at address a"),a.O("\tew [a] [...] edit words at address a");else{var oj=wz(a,cu);if(oj)for(var pj= +2;pjNm;){for(var td=null,KC=256;$d.Ja>>>0>>0;){ih.Ja=a.nb($d,!0);if(null==$d.za||!KC--)break;ih.T=fu;if(td=OB(a,ih))break;ih.T=a.nb($d);if(td=OB(a,ih,!0)){fu=a.nb($d,!0);0=this.D||(this.D=1);this.F=0;this.pa=a.busWidth||a.buswidth;this.A=kC;this.P=null;this.L=this.ha=!1;this.ra=Bd(this,"url")||"";this.ta=(Math.random()+.1).toString(36).substr(2,12);this.B=lC(this);if(this.G=xb("CPU",this.id)){this.ca=xb("Debugger",this.id);this.C=[];for(b=null;b=ac(this,"Video",b);)this.C.push(b);this.oa=new oc({id:this.de+".bus", +busWidth:this.pa},this.G,this.ca);var e=Bb(this.id);this.K=(this.J=xb("Panel",this.id))&&this.J.ma.print;this.ka=this.Da;this.la=this.print;this.qa=this.O;this.K&&(this.ka=this.J.Da,this.la=this.J.print,this.qa=this.J.O);for(b=0;b\nLicense: GPL version 3 or later "); +for(b=0;bkC){if(d.load(this.P)){this.H=new ag(this,"1.37.1",vC);this.H.load()&&(a!=uC&&wC(this,d)&&(a=xC),yC(this.H));this.H.set(tC,Ga("Y-m-d H:i:s"));zC(this.H);var e=this.A&&!this.L;if(a==uC||tb("Click OK to restore the previous PCx86 machine state.")){if(c=sC(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?d.load(g):("error"==f&&"no machine state"!= +g?(this.Da("Error: "+g),"unable to verify user"==g&&(Ta(AC,""),this.B=null)):this.O(f+": "+g),yC(d),d.load()?(c=sC(d),e=!0):c=!1))}e&&qC(this,c?d:null)}else a==xC&&d.clear()}else qC(this);delete this.P;delete this.V}e=Bb(this.id);for(f=0;fa[1];a=a[2];if(d=this.ma.power)d.textContent="Shutdown";this.aa.ac=!0;this.G&&(BC(this, +this.G,b,c,a),this.G.he());this.fa&&(wC(this,b),b.clear());!c&&this.H&&(this.H.clear(),delete this.H);this.F=0;Db(this.de,Bd(this,"autoScript"))};function wC(a,b){if(!a.aa.we){if(tb("There may be a problem with your PCx86 machine.\n\nTo help us diagnose it, click OK to send this PCx86 machine state to http://www.pcjs.org.")){var c=a.B||"";b=b.toString();var d={app:"PCx86",ver:"1.37.1"};d.url=a.ra;d.user=c;d.type="bug";d.data=b;Ma("http://www.pcjs.org/api/v1/report",d,!0)}return!0}return!1} +function QB(a,b,c){var d="none";if(a.F)return null;a.F--;var e=new ag(a,"1.37.1"),f=new ag(a,"1.37.1",rC),g=Ga("Y-m-d H:i:s");f.set(tC,g);e.set(tC,g);e.set(CC,"1.37.1");e.set(DC,window?window.location.href:null);e.set(EC,Oa());if(a.G&&a.G.Zb){var h=a.G.Zb(b,c);"object"===typeof h&&e.set(a.G.id,h);c&&(a.G.aa.ac=!1,!1===h&&(d=null))}g=Bb(a.id);for(var k=0;kf.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),d?"}"==d.slice(-1)?(d=d.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(d?" parms='"+d+"'":"")+(f?' url="'+f+'"':"")));e||(a=a.replace(/().*?(<\/xsl:variable>)/, +"$1PCx86$2"),a=a.replace(/().*?(<\/xsl:variable>)/,"$1pcx86$2"));f=null;if("<"==a.charAt(0))try{e||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(p){f=null,a=p.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");Ma(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,p=/( [a-z]+=)(['"])(.*?)\2/gi;m=p.exec(f);)k=0>k.toLowerCase().indexOf(m[1].toLowerCase())?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+ +"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/,"");a=a.replace(d[0],g);VC(a,b,c)}})}else c(a,null)} +function WC(a,b,c,d){function e(a){if(void 0===h){var b=g&&zb(g,"machine-warning");h=b&&b[0]||g}h&&(h.innerHTML=Aa(a))}function f(a){e("Error: "+a);k&&(--SC||lb(!0));k=!1}var g,h,k=!0;SC++;sb[a]={};try{if(g=document.getElementById(a)){var m;if("object"==typeof resources&&(m=resources.css)){var p=document.head||document.getElementsByTagName("head")[0],v=document.createElement("style");v.type="text/css";v.styleSheet?v.styleSheet.cssText=m:v.appendChild(document.createTextNode(m));p.appendChild(v)}c|| +(c="/versions/pcx86/1.37.1/components.xsl");m=function(d,h){h?TC(c,null,null,!1,e,function(d,k){k?(rb(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(k=h.transformNode(k))?(g.outerHTML=k,--SC||lb(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(k),(k=d.transformToFragment(h,document))?g.parentNode?(g.parentNode.replaceChild(k,g),--SC||lb(!0)):f("invalid machine element: "+ +a):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?TC(b,a,d,!0,e,m):UC(b,null,a,d,!1,e,m)}else f("missing machine element: "+a)}catch(u){f(u.message)}return k}function XC(a,b,c,d){lb(!1);return WC(a,b,c,d)}window.embedPC=XC;window.embedPCx86=XC; +window.commandMachine=function(a,b,c,d,e,f){if("script"==e)return Db(c,f)?(b&&(a.disabled=!0),!0):!1;if(d){var g=xb(d,c+".machine");if(g){var h=g.exports;if(h&&(h=h[e]))return h.call(g,f)?(b&&(a.disabled=!0),!0):!1}}console.log("unimplemented: commandMachine('"+c+"','"+d+"','"+e+"','"+f+"')");return!1};window.enableEvents=lb;window.sendEvent=nb; +function YC(a,b,c,d){if(!c&&b){d.push(b);a=sb[d[0]];b=null;for(var e in a)if(za(e,"components.xsl")){b=e.replace(".xsl",".css");break}b?Ma(b,null,!0,function(a,b){ZC(b,d)}):ZC(null,d)}else kb("Error ("+c+") requesting "+a)} +function ZC(a,b){var c,d,e=b[0],f=b[1];var g=b[4];if(g=g.match(/^(\s*\(function\(\)\{)([\s\S]*)(}\)\(\);)/)){var h=sb[e],k={},m;for(m in h){var p=h[m],v=ya(m);if("xml"==v){for(v=/[ \t]*]*path=(['"])(.*?)\1.*?<\/disk>\n?/g;c=v.exec(h[m]);){var u=c[2];u&&!h[u]&&(p=p.replace(c[0],""))}c=m=xa(m)}else"xsl"==v&&(d=m=xa(m));k[m]=p}a&&(k[m="css"]=a);b[2]&&(k[m="parms"]=b[2]);b[3]&&(k[m="state"]=b[3]);c&&d?(a=JSON.stringify(k),f+=".js",g=g[1]+"var resources="+a+";"+g[2]+g[3],g=g.replace(/\u00A9/g, +"©"),a=Za(g,"javascript",!1,f),a=a+(', copy it to your web server as "'+f+'", and then add the following to your web page:\n\n')+('
    \n')+"...\n",a=a+('\n'; + sAlert += '\n\n'; + sAlert += 'The machine should appear where the
    is located.'; + Component.alertUser(sAlert); + return; + } + Component.alertUser("Missing XML/XSL resources"); +} + +/** + * Prevent the Closure Compiler from renaming functions we want to export, by adding them + * as (named) properties of a global object. + */ +window['savePC'] = savePC; diff --git a/versions/pcx86/1.37.1/pcx86.js b/versions/pcx86/1.37.1/pcx86.js new file mode 100644 index 000000000..329d5d5d6 --- /dev/null +++ b/versions/pcx86/1.37.1/pcx86.js @@ -0,0 +1,718 @@ +(function(){/* + http://pcjs.org/modules/shared/lib/diskapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/dumpapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/reportapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/userapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/keys.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/strlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/weblib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/interrupts.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/messages.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/state.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/embed.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/usrlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/component.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/panel.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/bus.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/memory.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/cpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86seg.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86cpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86fpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86func.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86help.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86mods.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86ops.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/x86op0f.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/chipset.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/rom.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/ram.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/keyboard.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/video.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/parallel.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/serial.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/mouse.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/disk.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/fdc.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/hdc.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pcx86/lib/computer.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/save.js (C) Jeff Parsons 2012-2017 +*/ +var l,aa,ba="function"==typeof Object.create?Object.create:function(a){function b(){}b.prototype=a;return new b},da;if("function"==typeof Object.setPrototypeOf)da=Object.setPrototypeOf;else{var ea;a:{var fa={fd:!0},ha={};try{ha.__proto__=fa;ea=ha.fd;break a}catch(a){}ea=!1}da=ea?function(a,b){a.__proto__=b;if(a.__proto__!==b)throw new TypeError(a+" is not extensible");return a}:null}var ia=da; +function ja(a,b){a.prototype=ba(b.prototype);a.prototype.constructor=a;if(ia)ia(a,b);else for(var c in b)if("prototype"!=c)if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);d&&Object.defineProperty(a,c,d)}else a[c]=b[c];a.So=b.prototype} +var ka="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},la="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global&&null!=global?global:this;function ma(a,b){if(b){var c=la;a=a.split(".");for(var d=0;da?-b:b}});ma("Math.sign",function(a){return a?a:function(a){a=Number(a);return 0===a||isNaN(a)?a:0":62,"?":63,"@":64,Fd:65,sh:66,th:67,uh:68,E:69,vh:70,wh:71,xh:72,yh:73,zh:74,Ah:75,Bh:76,Ch:77,Dh:78,Eh:79,Fh:80,Q:81,Gh:82,Hh:83,Ih:84,Jh:85,Kh:86,Lh:87,Mh:88,Nh:89,pf:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,fd:97,ck:98,dk:99,d:100,e:101,mk:102,nk:103,pk:104,qk:105,Fl:106,k:107,Gl:108,Kl:109,n:110,Sl:111,p:112,q:113,r:114,sn:115,t:116,vn:117, +wn:118,xn:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,uo:127},pa={};pa[173]=n["-"];pa[186]=n[";"];pa[187]=n["="];pa[189]=n["-"];pa[188]=n[","];pa[190]=n["."];pa[191]=n["/"];pa[192]=n["`"];pa[219]=n["["];pa[220]=n["\\"];pa[221]=n["]"];pa[222]=n["'"];var p={};p[n["1"]]=n["!"];p[n["2"]]=n["@"];p[n["3"]]=n["#"];p[n["4"]]=n.$;p[n["5"]]=n["%"];p[n["6"]]=n["^"];p[n["7"]]=n["&"];p[n["8"]]=n["*"];p[n["9"]]=n["("];p[n["0"]]=n[")"];p[186]=n[":"];p[187]=n["+"];p[188]=n["<"];p[189]=n._;p[190]=n[">"]; +p[191]=n["?"];p[192]=n["~"];p[219]=n["{"];p[220]=n["|"];p[221]=n["}"];p[222]=n['"'];p[173]=n._;p[61]=n["+"];p[59]=n[":"]; +function qa(a,b){if(a){b||(b=10);var c,d=0=b&&(c=a.match(/(-?[0-9]+)B([0-9]*)/))&& +(a=c[1],e=35-((c[2]||35)&255));c=a;if(((d=b)&&10!=d?16==d?null!==c.match(/^-?[0-9a-f]+$/i):8==d?null!==c.match(/^-?[0-7]+$/):2==d&&null!==c.match(/^-?[01]+$/):null!==c.match(/^-?[0-9]+$/))&&!isNaN(f=parseInt(a,b))){e&&(0>f&&(f+=Math.pow(2,36)),f=0=b?4:4294967295>=b?8:9);c=c?"0x":"";var d=void 0===d?0:d;var e="";isNaN(a)?a=null:null!=a&&(0>a&&-1a&&(a+=Math.pow(16,b)),a>=Math.pow(16,b)&&(b=Math.ceil(Math.log(a)/Math.log(16))));for(var f=d||-1;0=g?48:55;e=String.fromCharCode(g)+e;a=Math.trunc(a/16)}f--}return(void 0===c?"":c)+e} +function sa(a,b){var c=a,d=a.lastIndexOf("/");0<=d&&(c=a.substr(d+1));d=c.indexOf("&");0"']/g,function(a){return wa[a]})}function xa(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")} +var wa={"&":"&","<":"<",">":">",'"':""","'":"'"},ya={0:"NUL",1:"SOH",2:"STX",3:"ETX",4:"EOT",5:"ENQ",6:"ACK",7:"BEL",8:"BS",9:"TAB",10:"LF",11:"VT",12:"FF",13:"CR",14:"SO",15:"SI",16:"DLE",17:"XON",18:"DC2",19:"XOFF",20:"DC4",21:"NAK",22:"SYN",23:"ETB",24:"CAN",25:"EM",26:"SUB",27:"ESC",28:"FS",29:"GS",30:"RS",31:"US"}; +function za(a){var b,c="";b||(b=new Date);for(var d=b.getHours(),e=b.getDate(),f=b.getMonth()+1,g=0;gd?"am":"pm";break;case "d":c+=("0"+e).slice(-2);break;case "D":c+=Aa[b.getDay()].substr(0,3);break;case "F":c+=Ba[f-1];break;case "g":c+=d?12a?this.Be=this.id:(this.Dd=this.id.substr(0,a),this.Be=this.id.substr(a+1));this.Y={ready:!1,Mo:!1,No:!1,Je:!1,Sb:!1,Yd:!1,error:!1};this.Cf=null;this.Y.error=!1;this.Ea=this.R=this.oa=this.na=null;$a.push(this)}function ab(a,b,c){bb[a]&&b&&(bb[a][b]=c)}function q(a){window&&window.alert(a)} +function cb(a){var b=!1;window&&(b=window.confirm(a));return b}function eb(a,b){a.value+=b;b=a.value;8192e?d+=b+"\n":d=d.substr(0,e)+c+d.substr(e+b.length);8192Math.abs(a.B-b)?1:2),1==a.G?b=a.B:2==a.G&&(d=a.A));a.A=d;a.B=b;if(0<=d&&d>d.shift;d=g*a.oa.A;f=(g+f.Oo)*a.oa.A-1;0f&&(d=f);c=d;break a}c=-1}if(-1!==c&&(c&=-16,c!=a.M)){b=c;if(a.context&&a.J&&a.K){e=Hb-Ib;f=a.J.width;a.K.fillStyle=Jb;a.K.fillRect(0,e,f,Ib);d=e+Kb;g=a.J;var h=a.K,k,m=null.style.color,r=a.ia=10;a.D=r;a.I=d;a.ba=a.aa=Kb;k||(k=a.W||a.aa+"px "+Lb);a.X=a.W=k;g&&(a.N=g);h&&(a.H=h,a.U=m||"white");a.L=a.N.width/24|0;if(null==b)Mb(a,"Mouse over memory to dump");else for(Mb(a,ra(b,8,!0),null,0,1),k=1;16>=k;k++){d="";for(g=1;8>=g;g++)h=a.oa,m=b++,h=h.X[(m&h.D)>>>h.B].Cd(m&h.C,m),Mb(a,ra(h,2),null,1), +d+=32<=h&&128>h?String.fromCharCode(h):".";Mb(a,d,null,0,1)}a.context.drawImage(a.J,0,e,f,Ib,a.qa,a.ra,a.ka,a.pa)}a.M=c}}}function Mb(a,b,c,d,e){a.H.font=a.X;a.H.fillStyle=a.U;a.H.fillText(b,a.D,a.I);a.D+=a.L;null!=c&&(16!=a.ma?b=c.toString():(b=8>a.da?"0x":"",b+=ra(c,a.da)),a.H.fillText(b,a.D,a.I),a.D+=a.L);d&&(a.D+=a.L*d);e&&(a.D=a.ia,a.I+=(a.ba+2)*(e||1))} +function Bb(){for(var a=!1,b=jb(document,"pcx86","panel"),c=0;c>2,Hb=Eb,Jb="black",Ib=Eb>>1;Sa(Bb); +function Nb(a,b,c){u.call(this,"Bus",a);this.R=b;this.Ea=c;this.F=a.busWidth||20;this.N=Math.pow(2,this.F);this.W=this.D=this.N-1|0;this.B=32==this.F||20>=this.F?12:24>=this.F?14:15;this.A=1<>2;this.C=this.A-1;this.H=this.N/this.A|0;this.K=this.H-1;this.I=[];this.J=[];this.L=[];this.M=[];a=new w;Ob(a,this.Ea);this.X=Array(this.H);for(b=0;b>>a.B;0g&&(r=g);if(k&&k.size){if(k.type==d&&k.controller==e){if(f+g<=k.ee)return k.xe+=k.ee-f,k.ee=f,!0;if(f>=k.ee+k.xe){r=k.size-(f-m);r>g&&(r=g);k.xe=f-k.ee+r;f=m+a.A;g-=r;h++;continue}}return Rb(a,Sb,f,g)}f=new w(f,r,a.A,d,e);Ob(f,a.Ea,k);a.X[h++]=f;f=m+a.A;g-=r}return 0>=g?(Tb(a.R),a.R.Y.cb||(e=c/1024|0,a.status((e?e+"Kb ":c+" bytes ")+Ub[d]+" at "+ra(b))),!0):Rb(a,Vb,b,c)} +function Pb(a,b){32==a.F?b?a.G&&(Wb(a,1048576,1048576,a.G),a.G=null):a.G||(a.G=Xb(a,1048576,1048576),Wb(a,1048576,1048576,Xb(a,0,1048576))):20>>this.B;0>>a.B;0>>=a.B;0>>a.B;0>>this.B].nc(a&this.C,a)};function hc(a,b){var c=b&a.C,d=(b&a.D)>>>a.B;return c!=a.C?a.X[d].$e(c,b):a.X[d++].Cd(c,b)|a.X[d&a.K].Cd(0,b+1)<<8} +l.Bb=function(a,b){this.X[(a&this.D)>>>this.B].pc(a&this.C,b&255,a)};function ic(a,b,c){var d=b&a.C,e=(b&a.D)>>>a.B;d!=a.C?a.X[e].qh(d,c&65535,b):(a.X[e++].df(d,c&255,b),a.X[e&a.K].df(0,c>>8&255,b+1))} +function jc(a,b){var c=0,d=[],e=!a.G&&a.W==a.D;e||Pb(a,!0);for(var f=0;f>>=f;if(void 0!==g&&g[0])g[0](b,k,e);f+=h<<3;b+=h;c-=h}}function Rb(a,b,c,d,e){b="Memory block error ("+b+": "+ra(c)+","+ra(d)+")";e?a.Ea?a.Ea.message(b):a.log(b):q(b);return!1} +var Gb,oc={Rl:20,count:8,Lo:1,type:3},pc=0,qc;for(qc in oc){var rc=oc[qc];oc[qc]={Ll:(1<>1),this.S=new Int32Array(this.L,0,c>>2),Zb(this,dc?ec:fc);else{this.S=Array(c>>2);for(e=0;e>2),a=0;a>8,c)};l.nh=function(a,b,c){this.pc(a++,b&255,c++);this.pc(a++,b>>8&255,c++);this.pc(a++,b>>16&255,c++);this.pc(a,b>>>24,c)};l.an=function(a){return this.S[a>>2]>>>((a&3)<<3)&255}; +l.nn=function(a){var b=a>>2;a=(a&3)<<3;var c=this.S[b]>>a;return 24>a?c&65535:c&255|(this.S[b+1]&255)<<8};l.gn=function(a){var b=a>>2;a=(a&3)<<3;var c=this.S[b];a&&(c=c>>>a|this.S[b+1]<<32-a);return c};l.Cn=function(a,b){var c=a>>2;a=(a&3)<<3;this.S[c]=this.S[c]&~(255<>2;a=(a&3)<<3;24>a?this.S[c]=this.S[c]&~(65535<>8);this.Fa=!0}; +l.In=function(a,b){var c=a>>2;if(a=(a&3)<<3){var d=-1<>>32-a}else this.S[c]=b;this.Fa=!0};l.$m=function(a,b){this.F&&Fc(this.F,b,1,!1);return this.Cd(a,b)};l.mn=function(a,b){this.F&&Fc(this.F,b,2,!1);return this.$e(a,b)};l.fn=function(a,b){this.F&&Fc(this.F,b,4,!1);return this.hh(a,b)};l.Bn=function(a,b,c){this.F&&Fc(this.F,c,1,!0);this.H||this.df(a,b,c)};l.Nn=function(a,b,c){this.F&&Fc(this.F,c,2,!0);this.H||this.qh(a,b,c)}; +l.Hn=function(a,b,c){this.F&&Fc(this.F,c,4,!0);this.H||this.R(a,b,c)};l.cn=function(a,b){this.A.S[this.C]|=this.I;this.B.S[this.D]|=this.I;return this.J.nc(a,b)};l.pn=function(a,b){this.A.S[this.C]|=this.I;this.B.S[this.D]|=this.I;return this.J.Ze(a,b)};l.jn=function(a,b){this.A.S[this.C]|=this.I;this.B.S[this.D]|=this.I;return this.J.Rd(a,b)};l.En=function(a,b,c){this.A.S[this.C]|=this.I;this.B.S[this.D]|=this.M;this.J.pc(a,b,c)}; +l.Qn=function(a,b,c){this.A.S[this.C]|=this.I;this.B.S[this.D]|=this.M;this.J.ff(a,b,c)};l.Kn=function(a,b,c){this.A.S[this.C]|=this.I;this.B.S[this.D]|=this.M;this.J.ef(a,b,c)};l.dn=function(a,b){return Gc(this.F,b,!1).nc(a,b)};l.qn=function(a,b){return Gc(this.F,b,!1).Ze(a,b)};l.kn=function(a,b){return Gc(this.F,b,!1).Rd(a,b)};l.Fn=function(a,b,c){Gc(this.F,c,!0).pc(a,b,c)};l.Rn=function(a,b,c){Gc(this.F,c,!0).ff(a,b,c)};l.Ln=function(a,b,c){Gc(this.F,c,!0).ef(a,b,c)};l.Zm=function(a){return this.Ha[a]}; +l.Cj=function(a){return this.Ha[a]};l.bn=function(a){this.A.S[this.C]|=32;this.B.S[this.D]|=32;this.nc=this.Cj;return this.Ha[a]};l.ln=function(a){return this.K.getUint16(a,!0)};l.Hj=function(a){return a&1?this.Ha[a]|this.Ha[a+1]<<8:this.vd[a>>1]};l.on=function(a){this.A.S[this.C]|=32;this.B.S[this.D]|=32;this.Ze=this.Hj;return a&1?this.Ha[a]|this.Ha[a+1]<<8:this.vd[a>>1]};l.en=function(a){return this.K.getInt32(a,!0)}; +l.Ej=function(a){return a&3?this.Ha[a]|this.Ha[a+1]<<8|this.Ha[a+2]<<16|this.Ha[a+3]<<24:this.S[a>>2]};l.hn=function(a){this.A.S[this.C]|=32;this.B.S[this.D]|=32;this.Rd=this.Ej;return a&3?this.Ha[a]|this.Ha[a+1]<<8|this.Ha[a+2]<<16|this.Ha[a+3]<<24:this.S[a>>2]};l.An=function(a,b){this.Ha[a]=b;this.Fa=!0};l.Pj=function(a,b){this.Ha[a]=b;this.Fa=!0};l.Dn=function(a,b){this.Ha[a]=b;this.A.S[this.C]|=32;this.B.S[this.D]|=96;this.pc=this.Pj;this.J.Fa=!0}; +l.Mn=function(a,b){this.K.setUint16(a,b,!0);this.Fa=!0};l.Rj=function(a,b){a&1?(this.Ha[a]=b,this.Ha[a+1]=b>>8):this.vd[a>>1]=b;this.Fa=!0};l.Pn=function(a,b){a&1?(this.Ha[a]=b,this.Ha[a+1]=b>>8):this.vd[a>>1]=b;this.A.S[this.C]|=32;this.B.S[this.D]|=96;this.ff=this.Rj;this.J.Fa=!0};l.Gn=function(a,b){this.K.setInt32(a,b,!0);this.Fa=!0};l.Qj=function(a,b){a&3?(this.Ha[a]=b,this.Ha[a+1]=b>>8,this.Ha[a+2]=b>>16,this.Ha[a+3]=b>>24):this.S[a>>2]=b;this.Fa=!0}; +l.Jn=function(a,b){a&3?(this.Ha[a]=b,this.Ha[a+1]=b>>8,this.Ha[a+2]=b>>16,this.Ha[a+3]=b>>24):this.S[a>>2]=b;this.A.S[this.C]|=32;this.B.S[this.D]|=96;this.ef=this.Qj;this.J.Fa=!0};function Hc(a){wb&&!dc&&(a=a<<24|a<<8&16711680|a>>8&65280|a>>>24);return a} +var wc=0,cc=2,xc=5,zc=6,Ub="NONE RAM ROM VIDEO H/W UNPAGED PAGED".split(" "),vc=0,Bc=[],gc=[w.prototype.an,w.prototype.Cn,w.prototype.nn,w.prototype.On,w.prototype.gn,w.prototype.In],Ec=[w.prototype.$m,w.prototype.Bn,w.prototype.mn,w.prototype.Nn,w.prototype.fn,w.prototype.Hn],Ac=[w.prototype.cn,w.prototype.En,w.prototype.pn,w.prototype.Qn,w.prototype.jn,w.prototype.Kn],yc=[w.prototype.dn,w.prototype.Fn,w.prototype.qn,w.prototype.Rn,w.prototype.kn,w.prototype.Ln]; +if(wb)var fc=[w.prototype.Zm,w.prototype.An,w.prototype.ln,w.prototype.Mn,w.prototype.en,w.prototype.Gn],ec=[w.prototype.Cj,w.prototype.Pj,w.prototype.Hj,w.prototype.Rj,w.prototype.Ej,w.prototype.Qj],Ic=[w.prototype.bn,w.prototype.Dn,w.prototype.on,w.prototype.Pn,w.prototype.hn,w.prototype.Jn]; +function Jc(a,b){u.call(this,"CPU",a);b=a.cycles||b;var c=a.multiplier||1;this.V={};this.V.zd=b;this.V.ng=Math.round(1E3/Kc);this.V.xi=this.V.sg=this.V.nd=c;this.V.Ff=Math.round(this.V.zd/1E4)/100;this.V.jd=this.V.re=this.V.Ff*this.V.nd;this.Y.Nj=this.Y.cb=this.Y.Yf=!1;this.Y.Gd=a.autoStart;this.Y.ci=!1;this.Y.yf=!1;this.V.Gf=this.V.se=0;this.V.Hf=a.csStart;this.V.Le=a.csInterval;this.V.Me=a.csStop;this.pa=[];this.sd=0;this.pi=this.rn.bind(this)}ja(Jc,u);l=Jc.prototype; +l.jc=function(a,b,c,d){this.na=a;this.oa=b;this.Ea=d;for(b=0;ba.V.nd)b=a.V.nd;a.V.Ol=Math.floor(a.V.zd/Kc*b);a.V.sg=b}function Xc(a,b){var c=a.Ic+a.Sc+a.Wc-a.A;b&&1a.V.Ff&&(c=Math.round(c/a.V.nd));return c} +function Oc(a){a.Ic=a.Sc=a.Wc=a.A=0;Pc(a);Uc(a,a.V.xi)}function Uc(a,b,c){if(void 0!==b){0b[1])&&(c=a.V.zd*a.V.sg/1E3*c|0,a.Y.cb&&(c+=$c(a)),b[1]=c)}function ad(a){for(var b=[],c=0;cthis.V.ng&&(this.V.$c+=a,this.V.$c>this.V.Ke&&(this.V.$c=this.V.Ke))}try{this.Y.Yf=!1;do{for(var b,c=this.Y.yf?1:this.V.zd*this.V.sg|0,d=this.pa.length-1;0<=d;d--){var e=this.pa[d];0>e[1]||c>e[1]&&(c=e[1])}b=c;if(this.U){bd(this.U);var f=this.U;a=b;var g=f.pa[0];if(g.Ld){var h=(Xc(f.R,f.M)-g.kd)/f.Ba|0,k=cd(f,0)-h;g.mode==dd&&(k-=h);var m=k*f.Ba|0; +g.mode==dd&&(m>>=1);a>m&&(a=m)}b=a;var r=this.U;a=b;if(r.A&&r.A[ed]&fd){var x=r.X-Xc(r.R,r.M);0x&&(a=x)}b=a}try{this.Oj(b)}catch(O){if("number"!=typeof O)throw O;}a=b=$c(this);for(var t=this.pa.length-1;0<=t;t--){var z=this.pa[t];0>z[1]||(z[1]-=a,0>=z[1]&&(z[1]=-1,z[3](),0<=z[2]&&Zc(this,t,z[2])))}a=b;if(this.Y.yf){var E=!1;this.V.Gf=this.V.Gf+this.ji()|0;this.V.se-=a;0>=this.V.se&&(this.V.se+=this.V.Le,E=!0);0<=this.V.Me&&this.V.Me<=Xc(this)&&(this.V.Le=this.V.Me=-1,Pc(this),Rc(this),E=!0); +E&&this.qb(Xc(this)+" cycles: checksum="+ra(this.V.Gf))}}while(this.Y.cb&&!this.Y.Yf)}catch(O){Rc(this);Qc(this);this.na&&this.na.stop(Da(),Xc(this));ub(this,O.stack||O.message);return}if(this.Y.cb){b=setTimeout;c=this.pi;this.V.Od=Da();d=this.V.ng;this.V.If&&(d=Math.round(d*this.V.If/this.V.Ol));d-=this.V.Od-this.V.Ke;if(e=this.V.Od-this.V.$c)this.V.jd=Math.round(this.Sc/(10*e))/100,864E5<=e&&(this.Ic=0,this.U&&bd(this.U,!0),Uc(this));0>d?(-1E3>d&&(this.V.$c-=d),d=0):this.V.jd>>0)+b>this.C&&(8088>=this.A.ca?this.A.K|=8:y.call(this.A,13));return this.va+a|0};l.Zh=function(a,b){return(a>>>0)+b<=this.C?this.va+a|0:this.vf()};l.ek=function(a,b){return(a>>>0)+b>this.C?this.va+a|0:this.vf()};l.vf=function(){y.call(this.A,13,0);return-1};l.ai=function(a,b){return(a>>>0)+b<=this.C?this.va+a|0:this.xf()};l.fk=function(a,b){return(a>>>0)+b>this.C?this.va+a|0:this.xf()};l.xf=function(){y.call(this.A,13,0);return-1}; +function md(a,b,c,d,e){a.ha=b;a.va=d;a.jb=e;a.C=(e>>>0)+1;a.nb=c;a.type=c&7936;a.ext=c>>16&192;a.bc=(b&4?a.A.lc.va:a.A.Jb)+(b&65528)|0;a.id>>0)+1;a.nb=e;a.type=e&7936;a.ext=0;a.bc=b;a.id>>0)+1,a.nb=a.B.nb,a.type=a.B.type,a.ext=a.B.ext,a.bc=a.B.bc,a.B.ha=-1,id(a,!0,!0,!1),a.va;a.B.ha=-1;var f=e.ga(b+0),g=e.ga(b+4),h=g&7936,k=e.ga(b+2)|(g&255)<<16,m=e.ga(b+6),r=c&65528;if(80386<=e.ca){var x=f;k|=(m&65280)<<16;f|=(m&15)<<16;m&128&&(f=f<<12|4095)}switch(a.id){case pd:var t=a.D;a.ne=!1;if(t&&c==qd&&a.F.length){var z=a.F[a.Ye-1];if(z&&!z())return-1}var E=c&3,O=(g&24576)>>13;z=-1;r||b>=e.Jb&& +b=a.tb&&(E>a.tb&&(z=A(e),rd(e,A(e),!0),B(e,z),a.ne=!0),z=0);else{if(256==h||2304==h)return sd(a,c,t)?a.va:-1;if(1024==h){z=2;var K=0;Eh||2048==(h&2560))return y.call(e,13,c&65532),-1;if(!(g&32768))return y.call(e,11,c&65532),-1}break;case ld:if(!r||4096>h||512!=(h&2560))return y.call(e,13,c&65532),-1;if(!(g&32768))return y.call(e, +12,c&65532),-1;break;case nd:t=h&-513;if(!r||256!=t&&2304!=t)return y.call(e,13,c&65532),-1;2304==t&&(a.Th=k+e.ga(k+102)|0,a.bk=k+a.jb|0);break;case kd:if(!(h&4096)&&768>>0)+1,a.nb=g,a.type=h,a.ext=m,a.bc=b,id(a,!0,!0,!1));return k} +function sd(a,b,c){var d=a.A,e=a.tb,f=d.ka.ha,g=d.ka.va;if(!c){if(!(d.ka.type&512))return y.call(d,13,b&65532),!1;d.Za(d.ka.bc+4,d.ka.nb&=-513)}if(-1===d.ka.load(b))return!1;var h=d.ka.va;if(!1!==c){if(d.ka.type&512)return y.call(d,13,b&65532),!1;d.Za(d.ka.bc+4,d.ka.nb|=512)}d.ka.type=d.ka.type&-513|d.ka.nb&512;256==d.ka.type||768==d.ka.type?(d.Za(g+14,F(d)),d.Za(g+16,Ad(d)),d.Za(g+18,d.F),d.Za(g+20,d.H),d.Za(g+22,d.L),d.Za(g+24,d.G),d.Za(g+26,C(d)),d.Za(g+28,d.M),d.Za(g+30,d.J),d.Za(g+32,d.I),d.Za(g+ +34,d.xa.ha),d.Za(g+36,d.fa.ha),d.Za(g+38,d.W.ha),d.Za(g+40,d.Ga.ha),d.lc.load(d.ga(h+42)),Bd(d,d.ga(h+16)|(c?16384:0)),d.F=d.ga(h+18),d.H=d.ga(h+20),d.L=d.ga(h+22),d.G=d.ga(h+24),d.M=d.ga(h+28),d.J=d.ga(h+30),d.I=d.ga(h+32),d.xa.load(d.ga(h+34)),d.Ga.load(d.ga(h+40)),Cd(d,d.ga(h+14),d.ga(h+36)),b=38,g=26,a.tb>>0)+1)}; +function id(a,b,c,d){void 0===c&&(c=!!(a.A.ra&1));a.ke=!1;if(c)if(a.load=a.Ef,a.ti=a.Il,a.sb=a.Zh,a.Kb=a.ai,void 0===d&&(d=!!(a.A.N&131072)),d)a.load=a.J,a.sb=a.H,a.Kb=a.I,a.tb=a.ic=3,a.T=2,a.O=a.ta=65535,a.jb=65535,a.C=a.jb+1,a.Jc=a.T,a.bc=-1,a.ne=!1;else{if(!(a.ha&-4))a.sb=a.vf,a.Kb=a.xf;else if(a.type&4096){6144==(a.type&6656)&&(a.sb=a.vf);if(a.type&2048||!(a.type&512))a.Kb=a.xf;1024==(a.type&3072)&&(a.sb==a.Zh&&(a.sb=a.ek),a.Kb==a.ai&&(a.Kb=a.fk),a.ke=!0);b&&a.id>13,80386>a.A.ca||!(a.ext&64)?(a.T=2,a.O=65535):(a.T=4,a.O=-1),a.Jc=a.T,a.ta=a.O)}else a.load=a.ui,a.ti=a.Jl,a.sb=a.wf,a.Kb=a.wf,a.tb=a.ic=0,a.bc=-1,a.ne=!1}var pd=1,zd=2,ld=3,nd=4,kd=6,qd=1; +function Dd(a){var b=+a.model||8088;switch(b){default:var c=4772727;break;case 80286:c=6E6;break;case 80386:c=16E6}Jc.call(this,a,c);this.ca=b;a=a.stepping;this.qd=b+(a?qa(a,16):0);this.Ph=61442;this.pd=1792;this.Oh=28672;this.gf=4;this.Ma=255;this.B=80286<=this.ca?yb:xb;this.qa=Ed;this.Yh=Fd;this.bi=Gd;this.ei=Hd;if(80186<=this.ca&&(this.qa=Ed.slice(),this.Yh=Fd.slice(),this.bi=Gd.slice(),this.Ma=31,this.qa[15]=Id,this.qa[96]=Jd,this.qa[97]=Kd,this.qa[98]=Ld,this.qa[99]=Id,this.qa[100]=Id,this.qa[101]= +Id,this.qa[102]=Id,this.qa[103]=Id,this.qa[104]=Md,this.qa[105]=Nd,this.qa[106]=Od,this.qa[107]=Pd,this.qa[108]=Qd,this.qa[109]=Rd,this.qa[110]=Sd,this.qa[111]=Td,this.qa[192]=Ud,this.qa[193]=Vd,this.qa[200]=Wd,this.qa[201]=Xd,this.qa[241]=Yd,this.Yh[7]=Zd,this.bi[7]=Zd,80286<=this.ca)){this.Ph=2;this.pd|=28672;this.gf=0;this.qa[15]=$d;this.dd=ae.slice();for(b=0;b=this.qd&&(this.dd[166]=ie,this.dd[167]=je)}}this.kf=[];this.Xh=[];this.$f=0;Oc(this);this.Y.complete=this.Y.gk=!1;this.ii=0;this.Nc=this.X=[];this.Eb=this.rh=this.Db=this.hf=this.ze=this.Ae=this.Dc=0;ke(this)}ja(Dd,Jc); +function le(a){var b;if(a.X===a.Nc){a.X=Array(a.hf);a.lf=new w(null,0,0,xc,null,a);Ob(a.lf,a.Ea);for(b=0;b>>20,f=a.Nc[(a.Vc+e&a.Ae)>>>a.Eb],g=f.Rd(e);if(!(g&1))return d||ne.call(a,b,!1,c),a.Ce;if(!(g&4)&&3==a.La)return d||ne.call(a,b,!0,c),a.Ce;var h=(b&4190208)>>>10;g=a.Nc[((g&-4096)+h&a.Ae)>>>a.Eb];var k=g.Rd(h);if(!(k&1))return d||ne.call(a,b,!1,c),a.Ce;if(!(k&4)&&3==a.La)return d||ne.call(a,b,!0,c),a.Ce;c=a.Nc[((k&-4096)+(b&4095)&a.Ae)>>>a.Eb];if(d)return c;d=b>>>a.Eb;k=a.X[d];b&=-4096;if(0>2;b.B=g;b.D=h>>2;wb&&dc&&c.S&&!c.controller&&!c.fe&&!c.ge?(b.Ha=c.Ha,b.vd=c.vd,b.S=c.S,Zb(b,Ic)):(b.I=c?Hc(32):0,b.M=c?Hc(96):0,Zb(b,Ac));Ob(b,a.Ea,k);a.X[d]=b;a.jf.push(d);return b}function oe(a){a.X!==a.Nc&&(a.X=a.Nc,a.lf=null,a.jf=null,a.Ce=null)}l=Dd.prototype;l.reset=function(){ke(this);Oc(this);this.Y.error=!1}; +function pe(a,b){switch(b){case 0:var c=a.F;break;case 1:c=a.H;break;case 2:c=a.L;break;case 3:c=a.G;break;case 4:c=C(a);break;case 5:c=a.M;break;case 6:c=a.J;break;case 7:c=a.I}return c}function qe(a,b,c){switch(b){case 0:a.F=c;break;case 1:a.H=c;break;case 2:a.L=c;break;case 3:a.G=c;break;case 4:B(a,c);break;case 5:a.M=c;break;case 6:a.J=c;break;case 7:a.I=c}} +function ke(a){a.F=0;a.G=0;a.H=0;a.L=0;a.kc=0;a.M=0;a.J=0;a.I=0;a.fc=!1;a.Ba=a.Sa=0;a.Ql=[0,0];a.Tl=[0,0];a.ua=0;a.hi=0;a.aa=0;a.ra=65520;a.Wb=0;a.Qc=1023;a.N=a.Yb=0;a.$d=a.De=a.Zd=a.ae=0;a.sc=-1;a.Tc=a.uc=-1;a.Uc=a.ma=-1;a.fa=new hd(a,pd,"CS");a.Ga=new hd(a,zd,"DS");a.xa=new hd(a,zd,"ES");a.W=new hd(a,ld,"SS");B(a,0);rd(a,0);if(80386<=a.ca){switch(a.qd){case 80562:case 80563:a.L=771;break;case 80578:a.L=772;break;case 80594:a.L=773;break;case 80595:case 80596:a.L=776}a.ra=16;a.ri=0;a.td=0;a.Vc=0; +a.Cb=[0,0,0,0,null,null,0,0];a.nf=[null,null,null,null,null,null,0,0];a.rb=new hd(a,zd,"FS");a.vb=new hd(a,zd,"GS");oe(a)}a.bg=new hd(a,0,"NULL");a.Ca=a.Ga;a.Gb=a.W;a.K=a.ba=0;a.C=a.D=-1;a.Da=a.bg;a.Qa=0;if(80286>a.ca)Cd(a,0,65535);else{a.Jb=0;a.Oc=65535;a.lc=new hd(a,5,"LDT",!0);a.ka=new hd(a,nd,"TSS",!0);a.gb=new hd(a,kd,"VER",!0);Cd(a,65520,61440);var b=F(a);var c=a.fa;var d=-65536;80386>c.A.ca&&(d&=16777215);c=c.va=d;a.da=c+b|0;a.ag=(c>>>0)+(a.fa.jb>>>0)+1}Bd(a,0);td(a)} +function re(a){2==a.Jc?(a.ni=a.ga,a.Xb=se,a.ec=te,a.Rc=ue,2==a.T?(a.ia=ve,a.za=we,a.eb=xe):(a.ia=ye,a.za=ze,a.eb=Ae)):(a.ni=a.ea,a.Xb=Be,a.ec=Ce,a.Rc=De,2==a.T?(a.ia=Ee,a.za=Fe,a.eb=Ge):(a.ia=He,a.za=Ie,a.eb=Je))}function ud(a,b){a.T!=b&&(a.ba|=1024,a.T=b,a.O=2==b?65535:-1,Ke(a))}function Ke(a){2==a.T?(a.wb=32768,a.mb=a.ga,a.Lb=a.Za,2==a.Jc?(a.ia=ve,a.za=we,a.eb=xe):(a.ia=Ee,a.za=Fe,a.eb=Ge)):(a.wb=-2147483648,a.mb=a.ea,a.Lb=a.Ta,2==a.Jc?(a.ia=ye,a.za=ze,a.eb=Ae):(a.ia=He,a.za=Ie,a.eb=Je))} +function Le(a){a.Jc=a.fa.Jc;a.ta=a.fa.ta;re(a);a.T=a.fa.T;a.O=a.fa.O;Ke(a);a.ba&=-3073}l.ji=function(){var a=this.F+this.G+this.H+this.L+C(this)+this.M+this.J+this.I|0;return a=a+F(this)+this.fa.ha+this.Ga.ha+this.W.ha+this.xa.ha+Ad(this)|0};function Me(a,b,c){void 0===a.kf[b]&&(a.kf[b]=[]);a.kf[b].push(c)}function Ne(a,b){var c=a.Xh[b];null!=c&&(c(--a.$f),delete a.Xh[b])} +function Oe(a,b){for(var c=a.Cb[7],d=c>>16,e=0;4>e;e++){if(c&3){var f=!!(d&1),g=a.Cb[e];g&=~(d>>2&3);if(b){g=a.X[g>>>a.Eb];var h=a;f?0===g.ge++&&(h&&(g.F=h),Dc(g,Ec,!1)):0===g.fe++&&(h&&(g.F=h),Cc(g,Ec,!1))}else g=a.X[g>>>a.Eb],f?0===--g.ge&&(f=g,f.pc=f.H?f.oh:f.df,f.ff=f.H?f.ph:f.qh,f.ef=f.H?f.nh:f.R):0===--g.fe&&(f=g,f.nc=f.Cd,f.Ze=f.$e,f.Rd=f.hh)}c>>=2;d>>=4}} +function Fc(a,b,c,d){if(!(a.K&8192)&&a.Cb[7]&255){c--;var e=a.Cb[7],f=e>>16;d=d?1:0==d?3:0;for(var g=0;4>g;g++){if(e&3&&(f&3)==d){var h=f>>2;if(b+c>=a.Cb[g]&&b<=a.Cb[g]+h){a.Cb[6]|=1<>=2;f>>=4}}}function td(a,b,c){void 0===b&&(b=!!(a.ra&1));void 0===c&&(c=!!(a.N&131072));a.ei=b&&!c?Pe:Hd;id(a.fa,!1,b,c);id(a.Ga,!1,b,c);id(a.W,!1,b,c);id(a.xa,!1,b,c);80386<=a.ca&&(id(a.rb,!1,b,c),id(a.vb,!1,b,c));Le(a)} +l.save=function(a){var b=new Qe(this);b.set(0,[this.F,this.G,this.H,this.L,C(this),this.M,this.J,this.I]);var c=F(this),d=this.fa.save(),e=this.Ga.save(),f=this.W.save(),g=this.xa.save();if(null!=this.Jb){var h=[this.ra,this.Jb,this.Oc,this.Wb,this.Qc,this.lc.save(),this.ka.save(),this.Yb];80386<=this.ca&&(h.push(this.ri),h.push(this.td),h.push(this.Vc),h.push(this.Cb),h.push(this.nf))}else h=null;c=[c,d,e,f,g,h,Ad(this)];80386<=this.ca&&(c.push(this.rb.save()),c.push(this.vb.save()));b.set(1,c); +b.set(2,[this.Ca.Wf,this.Gb.Wf,this.K,this.ba,this.Qa,this.C,this.D]);b.set(3,[0,this.Ic,this.V.nd,a,ad(this)]);b.set(4,jc(this.oa,!!(this.ra&-2147483648)));return b.data()}; +l.restore=function(a){var b=a[0];this.F=b[0];this.G=b[1];this.H=b[2];this.L=b[3];var c=b[4];this.M=b[5];this.J=b[6];this.I=b[7];b=a[1];this.fa.restore(b[1]);this.Ga.restore(b[2]);this.W.restore(b[3]);this.xa.restore(b[4]);var d=b[5];d&&d.length&&(this.ra=d[0],this.Jb=d[1],this.Oc=d[2],this.Wb=d[3],this.Qc=d[4],this.lc.restore(d[5]),this.ka.restore(d[6]),this.Yb=d[7],80386<=this.ca&&(this.ri=d[8],this.td=d[9],this.Vc=d[10],this.Cb=d[11],this.nf=d[12]),td(this));Bd(this,b[6]);d=!1;a:{var e=this.oa; +var f=a[4],g;for(g=0;g>>0)+(a.fa.jb>>>0)+1;a.La=a.fa.tb;Le(a)} +function Cd(a,b,c,d){var e=a.fa;e.Ye=b;e.D=d;b=e.load(c);return-1!==b?(Te(a,b+(a.fa.Ye&a.fa.O)),a.fa.ne):null}function Ue(a,b){var c=(a.da>>>0)+b;c>a.ag&&(8088>=a.ca?(c=a.fa.va+(c-a.ag&a.O),2==b&&(a.K|=8)):y.call(a,13,0));return c|0}function Ve(a){a.da=a.Uc}function C(a){return a.kc&~a.W.ta|a.Aa-a.W.va}function B(a,b){a.kc=b;a.Aa=a.W.va+(b&a.W.ta)|0} +function We(a,b,c,d,e,f){if(63!=(e&63)&&e!=a.resultType){var g=(e^a.resultType)&a.resultType;g&&(g&1&&Xe(a),g&2&&Ye(a),g&4&&Ze(a),g&8&&$e(a),g&16&&af(a),g&32&&bf(a))}f?(a.$d=d,a.Zd=b):(a.$d=b,a.Zd=d);a.De=c;a.ae=d;a.resultType=e}function cf(a,b,c,d,e){a.resultType=c|26;a.ae=b;d?df(a):ef(a);e?ff(a):gf(a);return b}function hf(a,b,c,d){c&d?df(a):ef(a);(b^c)&d?ff(a):gf(a)}function jf(a){return Xe(a)?1:0} +function Xe(a){a.resultType&1&&(a.N&=-2,(a.$d^(a.$d^a.De)&(a.De^a.Zd))&a.resultType&-2147450752&&(a.N|=1),a.resultType&=-2);return a.N&1}function Ye(a){a.resultType&2&&(a.N&=-5,38505>>((a.ae^a.ae>>4)&15)&1&&(a.N|=4),a.resultType&=-3);return a.N&4}function Ze(a){a.resultType&4&&(a.N&=-17,(a.Zd^a.$d^a.De)&16&&(a.N|=16),a.resultType&=-5);return a.N&16}function $e(a){a.resultType&8&&(a.N&=-65,a.ae&((a.resultType&-2147450752)-1|a.resultType&-2147450752)||(a.N|=64),a.resultType&=-9);return a.N&64} +function af(a){a.resultType&16&&(a.N&=-129,a.ae&a.resultType&-2147450752&&(a.N|=128),a.resultType&=-17);return a.N&128}function bf(a){a.resultType&32&&(a.N&=-2049,(a.$d^a.Zd)&(a.De^a.Zd)&a.resultType&-2147450752&&(a.N|=2048),a.resultType&=-33);return a.N&2048}function ef(a){a.resultType&=-2;a.N&=-2}function kf(a){a.resultType&=-5;a.N&=-17}function lf(a){a.resultType&=-9;a.N&=-65}function gf(a){a.resultType&=-33;a.N&=-2049}function df(a){a.resultType&=-2;a.N|=1} +function mf(a){a.resultType&=-5;a.N|=16}function nf(a){a.resultType&=-9;a.N|=64}function ff(a){a.resultType&=-33;a.N|=2048}function Ad(a){return a.N&-2262|Xe(a)|Ye(a)|Ze(a)|$e(a)|af(a)|bf(a)}function of(a,b){b|=a.ra&1|65520;a.ra=a.ra&-65536|b&65535;a.ra&1&&td(a,!0)}function Bd(a,b,c){a.ra&1||(b&=~a.Oh);void 0===c&&(c=a.La);c?b=b&-12289|a.N&12288:a.Yb=(b&12288)>>12;c>a.Yb&&(b=b&-513|a.N&512);a.resultType=128;a.N=a.N&~(a.pd|2261)|b&(a.pd|2261)|a.Ph;a.N&256&&(a.Qa|=2,a.K|=4)} +function pf(a,b,c){var d=0;if(a.ra&1&&(a.La>a.Yb||a.N&131072)&&a.ka.Th){var e=a.ka.Th+(b>>>3);for(d=(1<>>=8,e++}return d?(y.call(a,13,0),!1):!0} +l.Ab=function(a,b,c){switch(b){case "EAX":case "EBX":case "ECX":case "EDX":case "ESP":case "EBP":case "ESI":case "EDI":case "EIP":case "AX":case "BX":case "CX":case "DX":case "SP":case "BP":case "SI":case "DI":case "IP":case "PC":case "CS":case "DS":case "SS":case "ES":case "FS":case "GS":case "CR0":case "CR2":case "CR3":case "PS":case "C":case "P":case "A":case "Z":case "S":case "T":case "I":case "D":case "V":this.ja[b]=c;this.ii++;a=!0;break;default:a=Jc.prototype.Ab.call(this,a,b,c)}return a}; +function qf(a,b,c,d){var e=(d?a.Nc:a.X)[(b&a.Dc)>>>a.Eb];e&&e.type==xc&&(e=Gc(a,b,!1,!0));if(e){var f=b&a.Db;if(!c||1==c)return e.Cd(f,b);if(2==c)return f>>this.Eb].nc(a&this.Db,a)}; +l.ga=function(a){var b=a&this.Db,c=(a&this.Dc)>>>this.Eb;this.A-=this.B.Nf;if(b>>this.Eb;if(b>>this.Eb].pc(a&this.Db,b&255,a)}; +l.Za=function(a,b){var c=a&this.Db,d=(a&this.Dc)>>>this.Eb;this.A-=this.B.Nf;c>8&255,a+1))};l.Ta=function(a,b){var c=a&this.Db,d=(a&this.Dc)>>>this.Eb;this.A-=this.B.Nf;if(c>>=8}};function rf(a,b,c){a.Da=b;a.fb=c&a.ta;a.C=b.sb(a.fb,1);return a.K&1?0:a.Ia(a.C)} +function I(a,b){return rf(a,a.Ca,b)}function J(a,b){return rf(a,a.Gb,b)}function sf(a,b,c){a.Da=b;a.fb=c&a.ta;a.C=b.sb(a.fb,a.T);if(a.K&9){if(a.K&1)return 0;a=a.Ia(a.C)|a.Ia(b.sb(0,1))<<8}else a=a.mb(a.C);return a}function L(a,b){a.Da=a.Ca;a.fb=b&a.ta;a.C=a.Da.sb(a.fb,2);if(a.K&9){if(a.K&1)return 0;b=a.Ia(a.C)|a.Ia(a.Da.sb(0,1))<<8;a.K&=-9}else b=a.ga(a.C);return b} +function M(a,b){a.Da=a.Gb;a.fb=b&a.ta;a.C=a.Da.sb(a.fb,2);if(a.K&9){if(a.K&1)return 0;b=a.Ia(a.C)|a.Ia(a.Da.sb(0,1))<<8;a.K&=-9}else b=a.ga(a.C);return b}function N(a,b){a.Da=a.Ca;a.fb=b&a.ta;a.C=a.Da.sb(a.fb,4);return a.K&1?0:a.ea(a.C)}function P(a,b){a.Da=a.Gb;a.fb=b&a.ta;a.C=a.Da.sb(a.fb,4);return a.K&1?0:a.ea(a.C)}function tf(a,b){a.K&2||a.Bb(a.Da.Kb(a.fb,1),b)}function uf(a,b){if(!(a.K&2)){var c=a.Da.Kb(a.fb,2);a.K&8?(a.Bb(c,b),a.Bb(a.Da.Kb(0,1),b>>8),a.K&=-9):a.Za(c,b)}} +function vf(a,b){a.K&2||a.Ta(a.Da.Kb(a.fb,4),b)}function vd(a,b,c){c=b.sb(c,a.T);a.K&8?(b=a.Ia(c)|a.Ia(b.sb(0,1))<<8,a.K&=-9):b=a.mb(c);return b}function wf(a,b,c,d){c=b.Kb(c,a.T);a.K&8?(a.Bb(c,d),a.Bb(b.Kb(0,1),d>>8),a.K&=-9):a.Lb(c,d)}l.la=function(){var a=Ue(this,1),b=this.Ia(this.da);this.da=a;return b};function xf(a){var b=Ue(a,2);if(a.K&8){var c=a.Ia(a.da)|a.Ia(b-1)<<8;a.K&=-9}else c=a.ga(a.da);a.da=b;return c} +function Q(a){var b=Ue(a,a.Jc);if(a.K&8){var c=a.Ia(a.da)|a.Ia(b-1)<<8;a.K&=-9}else c=a.ni(a.da);a.da=b;return c}l.ya=function(){var a=Ue(this,this.T);if(this.K&8){var b=this.Ia(this.da)|this.Ia(a-1)<<8;this.K&=-9}else b=this.mb(this.da);this.da=a;return b};l.P=function(){var a=Ue(this,1),b=this.Ia(this.da)<<24>>24;this.da=a;return b}; +function A(a){var b=a.mb(a.Aa);a.Aa=a.Aa+a.T|0;var c=(a.si>>>0)-(a.Aa>>>0);0>c&&(8088>=a.ca?(B(a,a.Aa-a.W.va&a.W.ta),-1>c&&(b=b&255|a.Ia(a.Aa-1)<<8)):-1>c?y.call(a,12,0):(!a.W.ke&&a.W.jb==a.W.ta||a.W.ke&&!a.W.jb)&&B(a,a.Aa-a.W.va&a.W.ta));return b}function D(a,b){wd(a,b,a.T)} +function wd(a,b,c,d){d=void 0===d?c:d;var e=a.Aa-c|0,f=(e>>>0)-(a.wi>>>0);if(0>f){if(8088>=a.ca&&-1==f){a.Bb(e+1,b>>8);B(a,e-a.W.va&a.W.ta);a.Bb(a.Aa,b);return}if(!a.W.ke&&a.W.jb==a.W.ta||a.W.ke&&!a.W.jb){if(f>-c){y.call(a,12,0);return}B(a,e-a.W.va&a.W.ta);e=a.Aa}else{y.call(a,12,0);return}}switch(d){case 1:a.Bb(e,b);break;case 2:a.Za(e,b);break;case 4:a.Ta(e,b)}a.Aa=e} +function yf(a,b,c){var d=4;1==b.length&&(d=1,c=c?1:0);if(80386>a.ca)2this.ca?0:1;for(var b=0;2>b;b++){switch(a){case 0:if(this.Qa&1&&this.N&512){var c=zf(this.U);if(-1<=c&&(this.Qa&=-2,0<=c)){this.Qa&=-5;Af.call(this,c);break a}}break;case 1:if(this.Qa&2){this.Qa&=-3;80386<= +this.ca&&(this.Cb[6]|=16384);Af.call(this,1);break a}}a=1-a}}if(this.Qa&4){this.K=this.A=0;break}}this.K=0;this.qa[this.la()].call(this)}while(0>11;Ef(this);Ff(this,a[b++]);for(c=0;c=Gf&&Hf(a,If))}function Ef(a){a.Z&=-129;a.Z&~a.F&63&&(a.Z|=128);if(a.Z&128&&!(a.F&128))return a=a.U,a.ca>=Gf?Jf(a,If):a.da&Kf||Af.call(a.R,2),!0;a=a.U;a.ca>=Gf&&Hf(a,If);return!1}function Lf(a,b){80387<=a.ca||(b&=-65);a.Z|=b;return Ef(a)} +function Mf(a,b){return isFinite(b)?!0:!Lf(a,Infinity===b?8:16)}function Nf(a,b,c){var d=null;null!=b&&null!=c&&(d=b+c,Mf(a,d)||(d=null));return d}function Of(a,b,c){var d=null;null!=b&&null!=c&&(d=b-c,Mf(a,d)||(d=null));return d}function Pf(a,b,c){var d=null;null!=b&&null!=c&&(d=b*c,Mf(a,d)||(d=null));return d}function Qf(a,b,c){var d=null;null==b||null==c||!c&&Lf(a,2)||(d=b/c,Mf(a,d)||(d=null));return d} +function Rf(a,b,c){if(null!=b&&null!=c){var d=0;isNaN(b)||isNaN(c)?d=17664:(b-=c,0>b?d=256:0===b&&(d=16384));a.Z=a.Z&-18177|d;return!0}return!1}function Sf(a,b,c){if(null==b)return null;var d=a.F&3072;0==d?(d=Math.round(b),.5===d-b&&d%2&&d--):d=1024==d||3072==d&&0=c){if(Lf(a,1))return null;d=-c}else if(d<-c){if(Lf(a,1))return null;d=-c}a.G[0]=d|0;2147483648d&&(a.G[1]=-1))}return d} +function Tf(a,b){var c=3;a.C&1<=c;c<<=1)3!=(b&3)&&(a.C|=c),b>>=2}function Xf(a){var b=a.B+0&7;return a.C&1<>20&2047;var e=2147483648|(d&1048575)<<11|c>>>21;2047==b?b=32767:b?b+=15360:e&=2147483647;a.D[0]=c<<11;a.D[1]=e;a.D[2]=d>>16&32768|b;d=a.D}return d}function $f(a){return a.R.ga(a.R.C)<<16>>16} +function ag(a){return a.R.ea(a.R.C)}function bg(a){a.ia[0]=a.R.ea(a.R.C);return a.X[0]}function cg(a){a.G[0]=a.R.ea(a.R.C);a.G[1]=a.R.ea(a.R.C+4);return a.K[0]}function dg(a){a.D[0]=a.R.ea(a.R.C);a.D[1]=a.R.ea(a.R.C+4);a.D[2]=a.R.ga(a.R.C+8);return a.D}l.lh=function(){this.R.Ta(this.R.C,this.G[0])};l.Mj=function(){this.R.Ta(this.R.C,this.G[0]);this.R.Ta(this.R.C+4,this.G[1])};function eg(a){a.R.Ta(a.R.C,a.D[0]);a.R.Ta(a.R.C+4,a.D[1]);a.R.Za(a.R.C+8,a.D[2])} +function fg(a,b){var c=b[1],d=(b[2]&32768)>>4,e=b[2]&32767;b=b[0]>>>11|c<<21;c=c>>11&1048575;32767==e?e=2047:e&&(e+=-15360,0>=e&&(e=2047,b=c=0));a.G[0]=b;a.G[1]=c|(d|e)<<20;return a.K[0]}function gg(a,b){for(var c=0,d=1;b--;)c+=(a&15)*d,d*=10,a>>=4;return c}function hg(a,b){for(var c=0,d=0;b--;)c|=a%10<>11;Ef(a);Ff(a,c.mb(b+=c.T));!(c.ra&1)||c.N&131072?(a.I=c.mb(b+=c.T),d=c.mb(b+=c.T),a.N=d&2047,a.I|=(d&-4096)<<4,a.L=-1,a.J=c.mb(b+=c.T),a.J|=(c.mb(b+=c.T)&-4096)<<4,a.M=-1):(a.I=c.mb(b+=c.T),d=c.mb(b+=c.T),a.L=d&65535,a.N=d>>16&2047,a.J=c.mb(b+=c.T),a.M=c.mb(b+=c.T)&65535);return b+c.T} +function lg(a,b){var c=a.R;c.Lb(b,a.F);c.Lb(b+=c.T,a.Z|a.B<<11);c.Lb(b+=c.T,Df(a));if(!(c.ra&1)||c.N&131072){var d=(a.L<<4)+a.I;c.Lb(b+=c.T,d);c.Lb(b+=c.T,d>>4&-4096|a.N);d=(a.M<<4)+a.J;c.Lb(b+=c.T,d);c.Lb(b+=c.T,d>>4&-4096)}else c.Lb(b+=c.T,a.I),c.Lb(b+=c.T,a.L|a.N<<16),c.Lb(b+=c.T,a.J),c.Lb(b+=c.T,a.M);return b+c.T}function mg(){this.Z&=-32896;Ef(this)}function ng(){Rf(this,R(this,0),R(this,this.A))}function og(){Rf(this,R(this,0),R(this,this.A))&&ig(this)}function pg(){og.call(this)} +function qg(){S(this,0,Qf(this,R(this,0),bg(this)))}function rg(){this.C&=~(1<>20&2047)-1023),this.G[1]=(this.G[1]|1072693248)&-1073741825,jg(this,this.K[0]))},102:function(){this.B=this.B-1&7;this.Z&=-513},103:function(){this.B=this.B+1&7;this.Z&=-513},112:function(){S(this, +0,R(this,0)%R(this,1))},113:function(){S(this,1,R(this,1)*Math.log(R(this,0)+1)/Math.LN2)&&ig(this)},114:function(){var a=R(this,0),b=null;if(0<=a||!Lf(this,1))b=Math.sqrt(a),Mf(this,b)||(b=null);S(this,0,b)},116:function(){S(this,0,Sf(this,R(this,0),Kg))},117:function(){var a=R(this,0),b=R(this,1);null!=a&&null!=b&&S(this,0,a*Math.pow(2,0>>0);jg(this,a)},6:function(){var a= +Sf(this,ig(this));null!=a&&(this.D[0]=hg(a,8),this.D[1]=hg(a/1E8,8),this.D[2]=hg(a/1E16,2),0>a&&(this.D[2]|=32768),eg(this))},7:function(){null!=Sf(this,R(this,0),Kg)&&(this.Mj(),ig(this))},48:function(){rg.call(this);ig(this)},49:Eg,50:zg,51:zg,52:Cg}},Mg=[mg,sg,tg,ug,vg,wg,Ag,xg,Bg,Cg];Sa(function(){for(var a=jb(document,"pcx86","fpu"),b=0;b>16,c=c<<16>>16,d=d<<16>>16);this.A-=this.B.Ai;(bd)&&y.call(this,5);this.K|=2;return a}function Vg(a,b){var c=0;if(b){lf(this);for(var d=1;d&this.O;){if(b&d){a=c;break}d<<=1;c++}}else nf(this);this.A-=11+3*c;return a}function Wg(a,b){var c=0;if(b){lf(this);for(var d=2==this.T?15:31,e=1<>>=1;c++;d--}}else nf(this);this.A-=11+3*c;return a} +function Xg(a,b){a&1<<(b&(2==this.T?15:31))?df(this):ef(this);this.A-=-1===this.C?3:6;this.K|=2;return a}function Yg(a,b){b=1<<(b&(2==this.T?15:31));a&b?df(this):ef(this);this.A-=-1===this.C?6:8;return a^b}function Zg(a,b){b=1<<(b&(2==this.T?15:31));a&b?df(this):ef(this);this.A-=-1===this.C?6:8;return a&~b}function $g(a,b){b=1<<(b&(2==this.T?15:31));a&b?df(this):ef(this);this.A-=-1===this.C?6:8;return a|b} +function ah(a,b){if(-1===this.C)return Xg.call(this,a,b);var c=this.T<<3;if(b>=c||b<-c)a=sf(this,this.Da,this.fb+(b>>(2==this.T?4:5))*this.T);b=1<<(b&(2==this.T?15:31));a&b?df(this):ef(this);this.A-=6;this.K|=2;return a}function bh(a,b){if(-1===this.C)return Yg.call(this,a,b);var c=this.T<<3;if(b>=c||b<-c)a=sf(this,this.Da,this.fb+(b>>(2==this.T?4:5))*this.T);b=1<<(b&(2==this.T?15:31));a&b?df(this):ef(this);this.A-=8;return a^b} +function ch(a,b){if(-1===this.C)return Zg.call(this,a,b);var c=this.T<<3;if(b>=c||b<-c)a=sf(this,this.Da,this.fb+(b>>(2==this.T?4:5))*this.T);b=1<<(b&(2==this.T?15:31));a&b?df(this):ef(this);this.A-=8;return a&~b}function dh(a,b){if(-1===this.C)return $g.call(this,a,b);var c=this.T<<3;if(b>=c||b<-c)a=sf(this,this.Da,this.fb+(b>>(2==this.T?4:5))*this.T);b=1<<(b&(2==this.T?15:31));a&b?df(this):ef(this);this.A-=8;return a|b} +function eh(a,b){We(this,a,b,a-b|0,191,!0);this.A-=-1===this.D?-1===this.C?this.B.Zb:this.B.zg:this.B.zb;this.K|=2;return a}function fh(a,b){We(this,a,b,a-b|0,this.wb|63,!0);this.A-=-1===this.D?-1===this.C?this.B.Zb:this.B.zg:this.B.zb;this.K|=2;return a} +function gh(a){if(this.rd){var b=this.rd,c=this.hi,d=this.aa,e=d>>3&7;b.A=d&7;var f=(3>(d>>6&3)?0:48)+e;(217==c||219==c)&&52<=f&&(f=e<<4|b.A);if(e=Lg[c][f]){if(0>Mg.indexOf(e)){f=b.R;var g=f.Uc;8087==b.ca&&(f.ba&16&&g++,f.ba&32&&g++);b.L=f.fa.ha;b.I=g-f.fa.va;-1!==f.C&&(b.M=f.Da.ha,b.J=f.C-f.Da.va);b.N=(c&7)<<8|d}e.call(b)}}this.A-=-1===this.C?2:8;return a}function hh(a){if(80186>this.ca)return T.call(this,a);y.call(this,13,0);return a}function Zd(a){y.call(this,6);return a} +function T(a){be.call(this);return a}function ih(a,b){a=jh.call(this,this.P(),b);80386>this.ca&&(this.A-=12);return a}function kh(a,b){a=this.ya();a=2==this.T?jh.call(this,a,b):lh.call(this,a,b);80386>this.ca&&(this.A-=12);return a}function mh(a,b){var c=!1;0>b&&(b=-b|0,c=!c);0>a&&(a=-a|0,c=!c);nh.call(this,a,b);c&&(this.Ba=~this.Ba+1|0,this.Sa=~this.Sa+(this.Ba?0:1)|0)} +function jh(a,b){a=(a<<16>>16)*(b<<16>>16)|0;32767a?(df(this),ff(this)):(ef(this),gf(this));this.A-=-1===this.C?9:12;return a&65535}function lh(a,b){mh.call(this,a,b);this.Sa!=this.Ba>>31?(df(this),ff(this)):(ef(this),gf(this));this.A-=-1===this.C?9:12;return this.Ba}function oh(a,b){this.A-=14+(-1===this.C?0:2);lf(this);-1!==this.gb.load(b)&&this.gb.ic>=this.La&&this.gb.ic>=(b&3)&&(nf(this),a=this.gb.nb&-256,2=this.La)&&this.gb.ic>=(b&3))return nf(this),this.gb.jb;lf(this);return a}function vh(a,b){if(-1===this.C)return be.call(this),a;rd(this,this.ga(this.C+this.T));this.A-=this.B.te;return b} +function wh(a,b){this.A-=-1===this.D?-1===this.C?this.B.jj:this.B.ij:this.B.gj;return b}function xh(a,b){switch(this.aa>>3&7){case 4:this.ua=this.F;break;case 5:this.ua=this.H;break;case 6:this.ua=this.L;break;case 7:this.ua=this.G}return b}function yh(a,b){return b} +function zh(a,b){a=this.aa>>3&7;switch(a){case 0:this.ua=this.F;break;case 2:this.ua=this.L;break;case 3:this.ua=this.G;break;default:if(80286==this.ca||80386==this.ca&&4!=a&&5!=a)y.call(this,6);else switch(a){case 1:this.ua=this.H;break;case 4:this.ua=C(this);break;case 5:this.ua=this.M;break;case 6:this.ua=this.J;break;case 7:this.ua=this.I}}return wh.call(this,0,b)} +function Ah(a,b){switch(this.aa>>3&7){case 0:b=this.xa.ha;break;case 1:b=this.fa.ha;break;case 2:b=this.W.ha;break;case 3:b=this.Ga.ha;break;case 4:if(80386<=this.ca){b=this.rb.ha;break}y.call(this,6);b=a;break;case 5:if(80386<=this.ca){b=this.vb.ha;break}default:y.call(this,6),b=a}-1!==this.D&&ud(this,2);return wh.call(this,0,b)} +function nh(a,b){if(a&-65536||b&-65536){var c=b&65535;b>>>=16;var d=a&65535;a>>>=16;var e=c*d;d=(e>>>16)+b*d;var f=d>>>16;d=(d&65535)+c*a;this.Ba=d<<16|e&65535;this.Sa=f+((d>>>16)+b*a)|0}else this.Ba=a*b|0,this.Sa=0}function Bh(a,b){this.A-=-1===this.D?-1===this.C?this.B.Zb:this.B.zb:this.B.mc;return cf(this,a|b,128)}function Ch(a,b){this.A-=-1===this.D?-1===this.C?this.B.Zb:this.B.zb:this.B.mc;return cf(this,a|b,this.wb)&this.O} +function Dh(a,b){var c=a-b-jf(this)|0;We(this,a,b,c,191,!0);this.A-=-1===this.D?-1===this.C?this.B.Zb:this.B.zb:this.B.mc;return c&255}function Eh(a,b){var c=a-b-jf(this)|0;We(this,a,b,c,this.wb|63,!0);this.A-=-1===this.D?-1===this.C?this.B.Zb:this.B.zb:this.B.mc;return c&this.O}function Fh(){return bf(this)?1:0}function Gh(){return Xe(this)?1:0}function Hh(){return Xe(this)?0:1}function Ih(){return $e(this)?1:0}function Jh(){return $e(this)?0:1}function Kh(){return Xe(this)||$e(this)?1:0} +function Lh(){return Xe(this)||$e(this)?0:1}function Mh(){return af(this)?1:0}function Nh(){return af(this)?0:1}function Oh(){return Ye(this)?1:0}function Ph(){return Ye(this)?0:1}function Qh(){return!af(this)!=!bf(this)?1:0}function Rh(){return!af(this)!=!bf(this)?0:1}function Sh(){return $e(this)||!af(this)!=!bf(this)?1:0}function Th(){return $e(this)||!af(this)!=!bf(this)?0:1}function Uh(a,b){return Vh.call(this,a,b,this.la())}function Wh(a,b){return Xh.call(this,a,b,this.la())} +function Yh(a,b){return Vh.call(this,a,b,this.H&31)}function Zh(a,b){return Xh.call(this,a,b,this.H&31)}function $h(a,b){return di.call(this,a,b,this.la())}function ei(a,b){return fi.call(this,a,b,this.la())}function gi(a,b){return di.call(this,a,b,this.H&31)}function hi(a,b){return fi.call(this,a,b,this.H&31)}function ii(a,b){var c=a-b|0;We(this,a,b,c,191,!0);this.A-=-1===this.D?-1===this.C?this.B.Zb:this.B.zb:this.B.mc;return c&255} +function ji(a,b){var c=a-b|0;We(this,a,b,c,this.wb|63,!0);this.A-=-1===this.D?-1===this.C?this.B.Zb:this.B.zb:this.B.mc;return c&this.O}function ki(a,b){cf(this,a&b,128);this.A-=-1===this.D?-1===this.C?this.B.ah:this.B.Ue:this.B.Ue;this.K|=2;return a}function li(a,b){cf(this,a&b,this.wb);this.A-=-1===this.D?-1===this.C?this.B.ah:this.B.Ue:this.B.Ue;this.K|=2;return a}function mi(a,b){var c=this.F&this.O,d=(1<<(this.H&31))-1;return a&~(d<>(this.F&this.O)&(1<<(this.H&31))-1&this.O}function oi(a,b){if(-1===this.C){switch(this.aa&7){case 0:this.F=this.F&-256|a;break;case 1:this.H=this.H&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.G=this.G&-256|a;break;case 4:this.F=this.F&-65281|a<<8;break;case 5:this.H=this.H&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.G=this.G&-65281|a<<8}this.A-=this.B.dh}else this.D=this.C,tf(this,a),this.A-=this.B.bh;return b} +function pi(a,b){if(-1===this.C){switch(this.aa&7){case 0:this.F=this.F&~this.O|a;break;case 1:this.H=this.H&~this.O|a;break;case 2:this.L=this.L&~this.O|a;break;case 3:this.G=this.G&~this.O|a;break;case 4:B(this,C(this)&~this.O|a);break;case 5:this.M=this.G&~this.O|a;break;case 6:this.J=this.J&~this.O|a;break;case 7:this.I=this.I&~this.O|a}this.A-=this.B.dh}else{this.D=this.C;if(!(this.K&2)){var c=this.Da.Kb(this.fb,this.T);this.K&8?(this.Bb(c,a),this.Bb(this.Da.Kb(0,1),a>>8),this.K&=-9):this.Lb(c, +a)}this.A-=this.B.bh}return b}function qi(a,b){a^=b;cf(this,a,128);this.A-=-1===this.D?-1===this.C?this.B.Zb:this.B.zb:this.B.mc;return a}function ri(a,b){this.A-=-1===this.D?-1===this.C?this.B.Zb:this.B.zb:this.B.mc;return cf(this,a^b,this.wb)&this.O}function si(a,b){var c=a[1]-b[1];c||(c=a[0]-b[0]);return c}function ti(a){var b=a-1|0;We(this,a,1,b,this.wb|62,!0);this.A-=2;return a&~this.O|b&this.O} +function ui(a,b,c){c>>>=0;if(!c||c<=b>>>0)return!1;var d=0,e=1,f=this.Ql;f[0]=c>>>0;f[1]=0;c=this.Tl;c[0]=a>>>0;for(c[1]=b>>>0;0>>=0,a[1]++),e+=e;do 0<=si(c,f)&&(a=c,b=f,a[0]-=b[0],a[1]-=b[1],0>a[0]&&(a[0]>>>=0,a[1]--),d+=e),a=f,a[0]>>>=1,a[1]&1&&(a[0]=(a[0]|2147483648)>>>0),a[1]>>>=1,e/=2;while(1<=e);this.Ba=d;this.Sa=c[0];return!0}function vi(a){var b=a+1|0;We(this,a,1,b,this.wb|62);this.A-=2;return a&~this.O|b&this.O} +function wi(a){this.K|=1;this.ec.call(this,a);this.A-=-1===this.C?4:5}function Vh(a,b,c){if(c){16>>16-c)&65535;cf(this,a,32768,d&32768)}return a}function Xh(a,b,c){if(c){var d=a<>>32-c;cf(this,a,-2147483648,d&-2147483648)}return a}function di(a,b,c){if(c){16>>c-1;a=(d>>>1|b<<16-c)&65535;cf(this,a,32768,d&1)}return a}function fi(a,b,c){if(c){var d=a>>>c-1;a=d>>>1|b<<32-c;cf(this,a,-2147483648,d&1)}return a} +function xi(){this.A-=-1===this.C?2:this.B.wj;return 1}function yi(){var a=this.H&255;this.A-=(-1===this.C?this.B.Ug:this.B.Tg)+(a<this.sc?(-1!=this.Tc&&(this.Tc!==this.fa.ha&&(this.fa.tb=this.Tc&3,Se(this,this.Tc)),this.Tc=-1),this.Uc!==this.da&&Te(this,this.Uc),-1!=this.uc&&(this.uc!==this.W.ha&&rd(this,this.uc),this.uc=-1),-1!==this.ma&&(this.ma!==this.Aa&&B(this,this.kc&~this.W.ta|this.ma-this.W.va),this.ma=-1)):8!=this.sc?(b=0,a=8):(b=0,a=-1,ke(this),e=d=!1)):Te(this,this.Uc);var f=a,g=b,h=qf(this,this.da);204!=h||this.Qc||(d=!1);this.N&131072&&(6==f&& +99==h||13==f&&205==h)&&(d=!1);983040<=this.da&&1048575>=this.da&&(d=!1);if(d){var k=this.Y.cb;f="Fault "+ra(f,2,!0)+(null!=g?" ("+ra(g,4,!0)+")":"")+" on opcode "+ra(h,2,!0);d&&k&&(f+=" (blocked)");this.wa(f);Rc(this)}if(d&&e)throw-1;if(e)throw this.sc=a,Di.call(this,a,b,c),this.Uc=this.da,this.K=1==a?this.K|8192:this.K|4096,a;}function ne(a,b,c){this.td=a;a=0;b&&(a|=1);c&&(a|=2);3==this.La&&(a|=4);y.call(this,14,a)} +function Fi(a){var b=a.nb&7680;a.ha&65528&&(6144==b||7168==b||7168>b&&a.ic>8&255;break;case 197:b=this.H>>8&255;break;case 198:b=this.L>>8&255;break;case 199:b=this.G>>8&255;break;default:b=0}var c=this.aa>>3&7;switch(c){case 0:var d=this.F&255;break;case 1:d=this.H&255;break;case 2:d=this.L&255;break;case 3:d=this.G&255;break;case 4:d=this.F>>8&255;break;case 5:d=this.H>>8&255;break;case 6:d=this.L>>8&255;break;case 7:d=this.G>>8&255;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.F=this.F&-256|a;break; +case 1:this.H=this.H&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.G=this.G&-256|a;break;case 4:this.F=this.F&-65281|a<<8;break;case 5:this.H=this.H&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.G=this.G&-65281|a<<8}} +function te(a){var b=(this.aa=this.la())&199;switch(b){case 0:var c=I(this,this.G+this.J);this.D=this.C;break;case 1:c=I(this,this.G+this.I);this.D=this.C;break;case 2:c=J(this,this.M+this.J);this.D=this.C;break;case 3:c=J(this,this.M+this.I);this.D=this.C;break;case 4:c=I(this,this.J);this.D=this.C;break;case 5:c=I(this,this.I);this.D=this.C;break;case 6:c=I(this,Q(this));this.D=this.C;break;case 7:c=I(this,this.G);this.D=this.C;break;case 64:c=I(this,this.G+this.J+this.P());this.D=this.C;break; +case 65:c=I(this,this.G+this.I+this.P());this.D=this.C;break;case 66:c=J(this,this.M+this.J+this.P());this.D=this.C;break;case 67:c=J(this,this.M+this.I+this.P());this.D=this.C;break;case 68:c=I(this,this.J+this.P());this.D=this.C;break;case 69:c=I(this,this.I+this.P());this.D=this.C;break;case 70:c=J(this,this.M+this.P());this.D=this.C;break;case 71:c=I(this,this.G+this.P());this.D=this.C;break;case 128:c=I(this,this.G+this.J+Q(this));this.D=this.C;break;case 129:c=I(this,this.G+this.I+Q(this)); +this.D=this.C;break;case 130:c=J(this,this.M+this.J+Q(this));this.D=this.C;break;case 131:c=J(this,this.M+this.I+Q(this));this.D=this.C;break;case 132:c=I(this,this.J+Q(this));this.D=this.C;break;case 133:c=I(this,this.I+Q(this));this.D=this.C;break;case 134:c=J(this,this.M+Q(this));this.D=this.C;break;case 135:c=I(this,this.G+Q(this));this.D=this.C;break;case 192:c=this.F&255;break;case 193:c=this.H&255;break;case 194:c=this.L&255;break;case 195:c=this.G&255;break;case 196:c=this.F>>8&255;break; +case 197:c=this.H>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c=this.G>>8&255;break;default:c=0}switch(this.aa>>3&7){case 0:var d=this.F&255;break;case 1:d=this.H&255;break;case 2:d=this.L&255;break;case 3:d=this.G&255;break;case 4:d=this.F>>8&255;break;case 5:d=this.H>>8&255;break;case 6:d=this.L>>8&255;break;case 7:d=this.G>>8&255;break;default:d=0}a=a.call(this,c,d);switch(b){case 0:case 3:tf(this,a);this.A-=this.B.Bc;break;case 1:case 2:tf(this,a);this.A-=this.B.Cc;break;case 4:case 5:case 7:tf(this, +a);this.A-=this.B.gc;break;case 6:tf(this,a);this.A-=this.B.ad;break;case 64:case 67:case 128:case 131:tf(this,a);this.A-=this.B.Mb;break;case 65:case 66:case 129:case 130:tf(this,a);this.A-=this.B.Nb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:tf(this,a);this.A-=this.B.Pa;break;case 192:this.F=this.F&-256|a;break;case 193:this.H=this.H&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.F=this.F&-65281|a<<8;break;case 197:this.H= +this.H&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8}} +function ue(a,b){var c=(this.aa=this.la())&199;switch(c){case 0:var d=I(this,this.G+this.J);this.D=this.C;break;case 1:d=I(this,this.G+this.I);this.D=this.C;break;case 2:d=J(this,this.M+this.J);this.D=this.C;break;case 3:d=J(this,this.M+this.I);this.D=this.C;break;case 4:d=I(this,this.J);this.D=this.C;break;case 5:d=I(this,this.I);this.D=this.C;break;case 6:d=I(this,Q(this));this.D=this.C;break;case 7:d=I(this,this.G);this.D=this.C;break;case 64:d=I(this,this.G+this.J+this.P());this.D=this.C;break; +case 65:d=I(this,this.G+this.I+this.P());this.D=this.C;break;case 66:d=J(this,this.M+this.J+this.P());this.D=this.C;break;case 67:d=J(this,this.M+this.I+this.P());this.D=this.C;break;case 68:d=I(this,this.J+this.P());this.D=this.C;break;case 69:d=I(this,this.I+this.P());this.D=this.C;break;case 70:d=J(this,this.M+this.P());this.D=this.C;break;case 71:d=I(this,this.G+this.P());this.D=this.C;break;case 128:d=I(this,this.G+this.J+Q(this));this.D=this.C;break;case 129:d=I(this,this.G+this.I+Q(this)); +this.D=this.C;break;case 130:d=J(this,this.M+this.J+Q(this));this.D=this.C;break;case 131:d=J(this,this.M+this.I+Q(this));this.D=this.C;break;case 132:d=I(this,this.J+Q(this));this.D=this.C;break;case 133:d=I(this,this.I+Q(this));this.D=this.C;break;case 134:d=J(this,this.M+Q(this));this.D=this.C;break;case 135:d=I(this,this.G+Q(this));this.D=this.C;break;case 192:d=this.F&255;break;case 193:d=this.H&255;break;case 194:d=this.L&255;break;case 195:d=this.G&255;break;case 196:d=this.F>>8&255;break; +case 197:d=this.H>>8&255;break;case 198:d=this.L>>8&255;break;case 199:d=this.G>>8&255;break;default:d=0}a=a[this.aa>>3&7].call(this,d,b.call(this));switch(c){case 0:case 3:tf(this,a);this.A-=this.B.Bc;break;case 1:case 2:tf(this,a);this.A-=this.B.Cc;break;case 4:case 5:case 7:tf(this,a);this.A-=this.B.gc;break;case 6:tf(this,a);this.A-=this.B.ad;break;case 64:case 67:case 128:case 131:tf(this,a);this.A-=this.B.Mb;break;case 65:case 66:case 129:case 130:tf(this,a);this.A-=this.B.Nb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:tf(this, +a);this.A-=this.B.Pa;break;case 192:this.F=this.F&-256|a;break;case 193:this.H=this.H&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.F=this.F&-65281|a<<8;break;case 197:this.H=this.H&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8}} +function ve(a){switch((this.aa=this.la())&199){case 0:var b=L(this,this.G+this.J);this.A-=this.B.Bc;break;case 1:b=L(this,this.G+this.I);this.A-=this.B.Cc;break;case 2:b=M(this,this.M+this.J);this.A-=this.B.Cc;break;case 3:b=M(this,this.M+this.I);this.A-=this.B.Bc;break;case 4:b=L(this,this.J);this.A-=this.B.gc;break;case 5:b=L(this,this.I);this.A-=this.B.gc;break;case 6:b=L(this,Q(this));this.A-=this.B.ad;break;case 7:b=L(this,this.G);this.A-=this.B.gc;break;case 64:b=L(this,this.G+this.J+this.P()); +this.A-=this.B.Mb;break;case 65:b=L(this,this.G+this.I+this.P());this.A-=this.B.Nb;break;case 66:b=M(this,this.M+this.J+this.P());this.A-=this.B.Nb;break;case 67:b=M(this,this.M+this.I+this.P());this.A-=this.B.Mb;break;case 68:b=L(this,this.J+this.P());this.A-=this.B.Pa;break;case 69:b=L(this,this.I+this.P());this.A-=this.B.Pa;break;case 70:b=M(this,this.M+this.P());this.A-=this.B.Pa;break;case 71:b=L(this,this.G+this.P());this.A-=this.B.Pa;break;case 128:b=L(this,this.G+this.J+Q(this));this.A-=this.B.Mb; +break;case 129:b=L(this,this.G+this.I+Q(this));this.A-=this.B.Nb;break;case 130:b=M(this,this.M+this.J+Q(this));this.A-=this.B.Nb;break;case 131:b=M(this,this.M+this.I+Q(this));this.A-=this.B.Mb;break;case 132:b=L(this,this.J+Q(this));this.A-=this.B.Pa;break;case 133:b=L(this,this.I+Q(this));this.A-=this.B.Pa;break;case 134:b=M(this,this.M+Q(this));this.A-=this.B.Pa;break;case 135:b=L(this,this.G+Q(this));this.A-=this.B.Pa;break;case 192:b=this.F&65535;break;case 193:b=this.H&65535;break;case 194:b= +this.L&65535;break;case 195:b=this.G&65535;break;case 196:b=C(this)&65535;break;case 197:b=this.M&65535;break;case 198:b=this.J&65535;break;case 199:b=this.I&65535;break;default:b=0}var c=this.aa>>3&7;switch(c){case 0:var d=this.F&65535;break;case 1:d=this.H&65535;break;case 2:d=this.L&65535;break;case 3:d=this.G&65535;break;case 4:d=C(this)&65535;break;case 5:d=this.M&65535;break;case 6:d=this.J&65535;break;case 7:d=this.I&65535;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.F=this.F& +-65536|a;break;case 1:this.H=this.H&-65536|a;break;case 2:this.L=this.L&-65536|a;break;case 3:this.G=this.G&-65536|a;break;case 4:B(this,C(this)&-65536|a);break;case 5:this.M=this.M&-65536|a;break;case 6:this.J=this.J&-65536|a;break;case 7:this.I=this.I&-65536|a}} +function we(a){var b=(this.aa=this.la())&199;switch(b){case 0:var c=L(this,this.G+this.J);this.D=this.C;break;case 1:c=L(this,this.G+this.I);this.D=this.C;break;case 2:c=M(this,this.M+this.J);this.D=this.C;break;case 3:c=M(this,this.M+this.I);this.D=this.C;break;case 4:c=L(this,this.J);this.D=this.C;break;case 5:c=L(this,this.I);this.D=this.C;break;case 6:c=L(this,Q(this));this.D=this.C;break;case 7:c=L(this,this.G);this.D=this.C;break;case 64:c=L(this,this.G+this.J+this.P());this.D=this.C;break; +case 65:c=L(this,this.G+this.I+this.P());this.D=this.C;break;case 66:c=M(this,this.M+this.J+this.P());this.D=this.C;break;case 67:c=M(this,this.M+this.I+this.P());this.D=this.C;break;case 68:c=L(this,this.J+this.P());this.D=this.C;break;case 69:c=L(this,this.I+this.P());this.D=this.C;break;case 70:c=M(this,this.M+this.P());this.D=this.C;break;case 71:c=L(this,this.G+this.P());this.D=this.C;break;case 128:c=L(this,this.G+this.J+Q(this));this.D=this.C;break;case 129:c=L(this,this.G+this.I+Q(this)); +this.D=this.C;break;case 130:c=M(this,this.M+this.J+Q(this));this.D=this.C;break;case 131:c=M(this,this.M+this.I+Q(this));this.D=this.C;break;case 132:c=L(this,this.J+Q(this));this.D=this.C;break;case 133:c=L(this,this.I+Q(this));this.D=this.C;break;case 134:c=M(this,this.M+Q(this));this.D=this.C;break;case 135:c=L(this,this.G+Q(this));this.D=this.C;break;case 192:c=this.F&65535;break;case 193:c=this.H&65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=C(this)&65535; +break;case 197:c=this.M&65535;break;case 198:c=this.J&65535;break;case 199:c=this.I&65535;break;default:c=0}switch(this.aa>>3&7){case 0:var d=this.F&65535;break;case 1:d=this.H&65535;break;case 2:d=this.L&65535;break;case 3:d=this.G&65535;break;case 4:d=C(this)&65535;break;case 5:d=this.M&65535;break;case 6:d=this.J&65535;break;case 7:d=this.I&65535;break;default:d=0}a=a.call(this,c,d);switch(b){case 0:case 3:uf(this,a);this.A-=this.B.Bc;break;case 1:case 2:uf(this,a);this.A-=this.B.Cc;break;case 4:case 5:case 7:uf(this, +a);this.A-=this.B.gc;break;case 6:uf(this,a);this.A-=this.B.ad;break;case 64:case 67:case 128:case 131:uf(this,a);this.A-=this.B.Mb;break;case 65:case 66:case 129:case 130:uf(this,a);this.A-=this.B.Nb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:uf(this,a);this.A-=this.B.Pa;break;case 192:this.F=this.F&-65536|a;break;case 193:this.H=this.H&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:B(this,C(this)&-65536|a);break; +case 197:this.M=this.M&-65536|a;break;case 198:this.J=this.J&-65536|a;break;case 199:this.I=this.I&-65536|a}} +function xe(a,b){var c=(this.aa=this.la())&199;switch(c){case 0:var d=L(this,this.G+this.J);this.D=this.C;break;case 1:d=L(this,this.G+this.I);this.D=this.C;break;case 2:d=M(this,this.M+this.J);this.D=this.C;break;case 3:d=M(this,this.M+this.I);this.D=this.C;break;case 4:d=L(this,this.J);this.D=this.C;break;case 5:d=L(this,this.I);this.D=this.C;break;case 6:d=L(this,Q(this));this.D=this.C;break;case 7:d=L(this,this.G);this.D=this.C;break;case 64:d=L(this,this.G+this.J+this.P());this.D=this.C;break; +case 65:d=L(this,this.G+this.I+this.P());this.D=this.C;break;case 66:d=M(this,this.M+this.J+this.P());this.D=this.C;break;case 67:d=M(this,this.M+this.I+this.P());this.D=this.C;break;case 68:d=L(this,this.J+this.P());this.D=this.C;break;case 69:d=L(this,this.I+this.P());this.D=this.C;break;case 70:d=M(this,this.M+this.P());this.D=this.C;break;case 71:d=L(this,this.G+this.P());this.D=this.C;break;case 128:d=L(this,this.G+this.J+Q(this));this.D=this.C;break;case 129:d=L(this,this.G+this.I+Q(this)); +this.D=this.C;break;case 130:d=M(this,this.M+this.J+Q(this));this.D=this.C;break;case 131:d=M(this,this.M+this.I+Q(this));this.D=this.C;break;case 132:d=L(this,this.J+Q(this));this.D=this.C;break;case 133:d=L(this,this.I+Q(this));this.D=this.C;break;case 134:d=M(this,this.M+Q(this));this.D=this.C;break;case 135:d=L(this,this.G+Q(this));this.D=this.C;break;case 192:d=this.F&65535;break;case 193:d=this.H&65535;break;case 194:d=this.L&65535;break;case 195:d=this.G&65535;break;case 196:d=C(this)&65535; +break;case 197:d=this.M&65535;break;case 198:d=this.J&65535;break;case 199:d=this.I&65535;break;default:d=0}a=a[this.aa>>3&7].call(this,d,b.call(this));switch(c){case 0:case 3:uf(this,a);this.A-=this.B.Bc;break;case 1:case 2:uf(this,a);this.A-=this.B.Cc;break;case 4:case 5:case 7:uf(this,a);this.A-=this.B.gc;break;case 6:uf(this,a);this.A-=this.B.ad;break;case 64:case 67:case 128:case 131:uf(this,a);this.A-=this.B.Mb;break;case 65:case 66:case 129:case 130:uf(this,a);this.A-=this.B.Nb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:uf(this, +a);this.A-=this.B.Pa;break;case 192:this.F=this.F&-65536|a;break;case 193:this.H=this.H&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:B(this,C(this)&-65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.J=this.J&-65536|a;break;case 199:this.I=this.I&-65536|a}} +function ye(a){switch((this.aa=this.la())&199){case 0:var b=N(this,this.G+this.J);this.A-=this.B.Bc;break;case 1:b=N(this,this.G+this.I);this.A-=this.B.Cc;break;case 2:b=P(this,this.M+this.J);this.A-=this.B.Cc;break;case 3:b=P(this,this.M+this.I);this.A-=this.B.Bc;break;case 4:b=N(this,this.J);this.A-=this.B.gc;break;case 5:b=N(this,this.I);this.A-=this.B.gc;break;case 6:b=N(this,Q(this));this.A-=this.B.ad;break;case 7:b=N(this,this.G);this.A-=this.B.gc;break;case 64:b=N(this,this.G+this.J+this.P()); +this.A-=this.B.Mb;break;case 65:b=N(this,this.G+this.I+this.P());this.A-=this.B.Nb;break;case 66:b=P(this,this.M+this.J+this.P());this.A-=this.B.Nb;break;case 67:b=P(this,this.M+this.I+this.P());this.A-=this.B.Mb;break;case 68:b=N(this,this.J+this.P());this.A-=this.B.Pa;break;case 69:b=N(this,this.I+this.P());this.A-=this.B.Pa;break;case 70:b=P(this,this.M+this.P());this.A-=this.B.Pa;break;case 71:b=N(this,this.G+this.P());this.A-=this.B.Pa;break;case 128:b=N(this,this.G+this.J+Q(this));this.A-=this.B.Mb; +break;case 129:b=N(this,this.G+this.I+Q(this));this.A-=this.B.Nb;break;case 130:b=P(this,this.M+this.J+Q(this));this.A-=this.B.Nb;break;case 131:b=P(this,this.M+this.I+Q(this));this.A-=this.B.Mb;break;case 132:b=N(this,this.J+Q(this));this.A-=this.B.Pa;break;case 133:b=N(this,this.I+Q(this));this.A-=this.B.Pa;break;case 134:b=P(this,this.M+Q(this));this.A-=this.B.Pa;break;case 135:b=N(this,this.G+Q(this));this.A-=this.B.Pa;break;case 192:b=this.F;break;case 193:b=this.H;break;case 194:b=this.L;break; +case 195:b=this.G;break;case 196:b=C(this);break;case 197:b=this.M;break;case 198:b=this.J;break;case 199:b=this.I;break;default:b=0}var c=this.aa>>3&7;switch(c){case 0:var d=this.F;break;case 1:d=this.H;break;case 2:d=this.L;break;case 3:d=this.G;break;case 4:d=C(this);break;case 5:d=this.M;break;case 6:d=this.J;break;case 7:d=this.I;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.F=a;break;case 1:this.H=a;break;case 2:this.L=a;break;case 3:this.G=a;break;case 4:B(this,a);break;case 5:this.M= +a;break;case 6:this.J=a;break;case 7:this.I=a}} +function ze(a){var b=(this.aa=this.la())&199;switch(b){case 0:var c=N(this,this.G+this.J);this.D=this.C;break;case 1:c=N(this,this.G+this.I);this.D=this.C;break;case 2:c=P(this,this.M+this.J);this.D=this.C;break;case 3:c=P(this,this.M+this.I);this.D=this.C;break;case 4:c=N(this,this.J);this.D=this.C;break;case 5:c=N(this,this.I);this.D=this.C;break;case 6:c=N(this,Q(this));this.D=this.C;break;case 7:c=N(this,this.G);this.D=this.C;break;case 64:c=N(this,this.G+this.J+this.P());this.D=this.C;break; +case 65:c=N(this,this.G+this.I+this.P());this.D=this.C;break;case 66:c=P(this,this.M+this.J+this.P());this.D=this.C;break;case 67:c=P(this,this.M+this.I+this.P());this.D=this.C;break;case 68:c=N(this,this.J+this.P());this.D=this.C;break;case 69:c=N(this,this.I+this.P());this.D=this.C;break;case 70:c=P(this,this.M+this.P());this.D=this.C;break;case 71:c=N(this,this.G+this.P());this.D=this.C;break;case 128:c=N(this,this.G+this.J+Q(this));this.D=this.C;break;case 129:c=N(this,this.G+this.I+Q(this)); +this.D=this.C;break;case 130:c=P(this,this.M+this.J+Q(this));this.D=this.C;break;case 131:c=P(this,this.M+this.I+Q(this));this.D=this.C;break;case 132:c=N(this,this.J+Q(this));this.D=this.C;break;case 133:c=N(this,this.I+Q(this));this.D=this.C;break;case 134:c=P(this,this.M+Q(this));this.D=this.C;break;case 135:c=N(this,this.G+Q(this));this.D=this.C;break;case 192:c=this.F;break;case 193:c=this.H;break;case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=C(this);break;case 197:c=this.M;break; +case 198:c=this.J;break;case 199:c=this.I;break;default:c=0}switch(this.aa>>3&7){case 0:var d=this.F;break;case 1:d=this.H;break;case 2:d=this.L;break;case 3:d=this.G;break;case 4:d=C(this);break;case 5:d=this.M;break;case 6:d=this.J;break;case 7:d=this.I;break;default:d=0}a=a.call(this,c,d);switch(b){case 0:case 3:vf(this,a);this.A-=this.B.Bc;break;case 1:case 2:vf(this,a);this.A-=this.B.Cc;break;case 4:case 5:case 7:vf(this,a);this.A-=this.B.gc;break;case 6:vf(this,a);this.A-=this.B.ad;break;case 64:case 67:case 128:case 131:vf(this, +a);this.A-=this.B.Mb;break;case 65:case 66:case 129:case 130:vf(this,a);this.A-=this.B.Nb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:vf(this,a);this.A-=this.B.Pa;break;case 192:this.F=a;break;case 193:this.H=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:B(this,a);break;case 197:this.M=a;break;case 198:this.J=a;break;case 199:this.I=a}} +function Ae(a,b){var c=(this.aa=this.la())&199;switch(c){case 0:var d=N(this,this.G+this.J);this.D=this.C;break;case 1:d=N(this,this.G+this.I);this.D=this.C;break;case 2:d=P(this,this.M+this.J);this.D=this.C;break;case 3:d=P(this,this.M+this.I);this.D=this.C;break;case 4:d=N(this,this.J);this.D=this.C;break;case 5:d=N(this,this.I);this.D=this.C;break;case 6:d=N(this,Q(this));this.D=this.C;break;case 7:d=N(this,this.G);this.D=this.C;break;case 64:d=N(this,this.G+this.J+this.P());this.D=this.C;break; +case 65:d=N(this,this.G+this.I+this.P());this.D=this.C;break;case 66:d=P(this,this.M+this.J+this.P());this.D=this.C;break;case 67:d=P(this,this.M+this.I+this.P());this.D=this.C;break;case 68:d=N(this,this.J+this.P());this.D=this.C;break;case 69:d=N(this,this.I+this.P());this.D=this.C;break;case 70:d=P(this,this.M+this.P());this.D=this.C;break;case 71:d=N(this,this.G+this.P());this.D=this.C;break;case 128:d=N(this,this.G+this.J+Q(this));this.D=this.C;break;case 129:d=N(this,this.G+this.I+Q(this)); +this.D=this.C;break;case 130:d=P(this,this.M+this.J+Q(this));this.D=this.C;break;case 131:d=P(this,this.M+this.I+Q(this));this.D=this.C;break;case 132:d=N(this,this.J+Q(this));this.D=this.C;break;case 133:d=N(this,this.I+Q(this));this.D=this.C;break;case 134:d=P(this,this.M+Q(this));this.D=this.C;break;case 135:d=N(this,this.G+Q(this));this.D=this.C;break;case 192:d=this.F;break;case 193:d=this.H;break;case 194:d=this.L;break;case 195:d=this.G;break;case 196:d=C(this);break;case 197:d=this.M;break; +case 198:d=this.J;break;case 199:d=this.I}a=a[this.aa>>3&7].call(this,d,b.call(this));switch(c){case 0:case 3:vf(this,a);this.A-=this.B.Bc;break;case 1:case 2:vf(this,a);this.A-=this.B.Cc;break;case 4:case 5:case 7:vf(this,a);this.A-=this.B.gc;break;case 6:vf(this,a);this.A-=this.B.ad;break;case 64:case 67:case 128:case 131:vf(this,a);this.A-=this.B.Mb;break;case 65:case 66:case 129:case 130:vf(this,a);this.A-=this.B.Nb;break;case 68:case 69:case 70:case 71:case 132:case 133:case 134:case 135:vf(this, +a);this.A-=this.B.Pa;break;case 192:this.F=a;break;case 193:this.H=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:B(this,a);break;case 197:this.M=a;break;case 198:this.J=a;break;case 199:this.I=a}} +function Be(a){switch((this.aa=this.la())&199){case 0:var b=I(this,this.F);break;case 1:b=I(this,this.H);break;case 2:b=I(this,this.L);break;case 3:b=I(this,this.G);break;case 4:b=I(this,Hi.call(this,0));break;case 5:b=I(this,Q(this));break;case 6:b=I(this,this.J);break;case 7:b=I(this,this.I);break;case 64:b=I(this,this.F+this.P());break;case 65:b=I(this,this.H+this.P());break;case 66:b=I(this,this.L+this.P());break;case 67:b=I(this,this.G+this.P());break;case 68:b=I(this,Hi.call(this,1)+this.P()); +break;case 69:b=J(this,this.M+this.P());break;case 70:b=I(this,this.J+this.P());break;case 71:b=I(this,this.I+this.P());break;case 128:b=I(this,this.F+Q(this));break;case 129:b=I(this,this.H+Q(this));break;case 130:b=I(this,this.L+Q(this));break;case 131:b=I(this,this.G+Q(this));break;case 132:b=I(this,Hi.call(this,2)+Q(this));break;case 133:b=J(this,this.M+Q(this));break;case 134:b=I(this,this.J+Q(this));break;case 135:b=I(this,this.I+Q(this));break;case 192:b=this.F&255;break;case 193:b=this.H& +255;break;case 194:b=this.L&255;break;case 195:b=this.G&255;break;case 196:b=this.F>>8&255;break;case 197:b=this.H>>8&255;break;case 198:b=this.L>>8&255;break;case 199:b=this.G>>8&255;break;default:b=0}var c=this.aa>>3&7;switch(c){case 0:var d=this.F&255;break;case 1:d=this.H&255;break;case 2:d=this.L&255;break;case 3:d=this.G&255;break;case 4:d=this.F>>8&255;break;case 5:d=this.H>>8&255;break;case 6:d=this.L>>8&255;break;case 7:d=this.G>>8&255;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.F= +this.F&-256|a;break;case 1:this.H=this.H&-256|a;break;case 2:this.L=this.L&-256|a;break;case 3:this.G=this.G&-256|a;break;case 4:this.F=this.F&-65281|a<<8;break;case 5:this.H=this.H&-65281|a<<8;break;case 6:this.L=this.L&-65281|a<<8;break;case 7:this.G=this.G&-65281|a<<8}} +function Ce(a){var b=(this.aa=this.la())&199;switch(b){case 0:var c=I(this,this.F);this.D=this.C;break;case 1:c=I(this,this.H);this.D=this.C;break;case 2:c=I(this,this.L);this.D=this.C;break;case 3:c=I(this,this.G);this.D=this.C;break;case 4:c=I(this,Hi.call(this,0));this.D=this.C;break;case 5:c=I(this,Q(this));this.D=this.C;break;case 6:c=I(this,this.J);this.D=this.C;break;case 7:c=I(this,this.I);this.D=this.C;break;case 64:c=I(this,this.F+this.P());this.D=this.C;break;case 65:c=I(this,this.H+this.P()); +this.D=this.C;break;case 66:c=I(this,this.L+this.P());this.D=this.C;break;case 67:c=I(this,this.G+this.P());this.D=this.C;break;case 68:c=I(this,Hi.call(this,1)+this.P());this.D=this.C;break;case 69:c=J(this,this.M+this.P());this.D=this.C;break;case 70:c=I(this,this.J+this.P());this.D=this.C;break;case 71:c=I(this,this.I+this.P());this.D=this.C;break;case 128:c=I(this,this.F+Q(this));this.D=this.C;break;case 129:c=I(this,this.H+Q(this));this.D=this.C;break;case 130:c=I(this,this.L+Q(this));this.D= +this.C;break;case 131:c=I(this,this.G+Q(this));this.D=this.C;break;case 132:c=I(this,Hi.call(this,2)+Q(this));this.D=this.C;break;case 133:c=J(this,this.M+Q(this));this.D=this.C;break;case 134:c=I(this,this.J+Q(this));this.D=this.C;break;case 135:c=I(this,this.I+Q(this));this.D=this.C;break;case 192:c=this.F&255;break;case 193:c=this.H&255;break;case 194:c=this.L&255;break;case 195:c=this.G&255;break;case 196:c=this.F>>8&255;break;case 197:c=this.H>>8&255;break;case 198:c=this.L>>8&255;break;case 199:c= +this.G>>8&255;break;default:c=0}switch(this.aa>>3&7){case 0:var d=this.F&255;break;case 1:d=this.H&255;break;case 2:d=this.L&255;break;case 3:d=this.G&255;break;case 4:d=this.F>>8&255;break;case 5:d=this.H>>8&255;break;case 6:d=this.L>>8&255;break;case 7:d=this.G>>8&255;break;default:d=0}a=a.call(this,c,d);switch(b){case 192:this.F=this.F&-256|a;break;case 193:this.H=this.H&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.F=this.F&-65281|a<<8;break; +case 197:this.H=this.H&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8;break;default:tf(this,a)}} +function De(a,b){var c=(this.aa=this.la())&199;switch(c){case 0:var d=I(this,this.F);this.D=this.C;break;case 1:d=I(this,this.H);this.D=this.C;break;case 2:d=I(this,this.L);this.D=this.C;break;case 3:d=I(this,this.G);this.D=this.C;break;case 4:d=I(this,Hi.call(this,0));this.D=this.C;break;case 5:d=I(this,Q(this));this.D=this.C;break;case 6:d=I(this,this.J);this.D=this.C;break;case 7:d=I(this,this.I);this.D=this.C;break;case 64:d=I(this,this.F+this.P());this.D=this.C;break;case 65:d=I(this,this.H+ +this.P());this.D=this.C;break;case 66:d=I(this,this.L+this.P());this.D=this.C;break;case 67:d=I(this,this.G+this.P());this.D=this.C;break;case 68:d=I(this,Hi.call(this,1)+this.P());this.D=this.C;break;case 69:d=J(this,this.M+this.P());this.D=this.C;break;case 70:d=I(this,this.J+this.P());this.D=this.C;break;case 71:d=I(this,this.I+this.P());this.D=this.C;break;case 128:d=I(this,this.F+Q(this));this.D=this.C;break;case 129:d=I(this,this.H+Q(this));this.D=this.C;break;case 130:d=I(this,this.L+Q(this)); +this.D=this.C;break;case 131:d=I(this,this.G+Q(this));this.D=this.C;break;case 132:d=I(this,Hi.call(this,2)+Q(this));this.D=this.C;break;case 133:d=J(this,this.M+Q(this));this.D=this.C;break;case 134:d=I(this,this.J+Q(this));this.D=this.C;break;case 135:d=I(this,this.I+Q(this));this.D=this.C;break;case 192:d=this.F&255;break;case 193:d=this.H&255;break;case 194:d=this.L&255;break;case 195:d=this.G&255;break;case 196:d=this.F>>8&255;break;case 197:d=this.H>>8&255;break;case 198:d=this.L>>8&255;break; +case 199:d=this.G>>8&255;break;default:d=0}a=a[this.aa>>3&7].call(this,d,b.call(this));switch(c){case 192:this.F=this.F&-256|a;break;case 193:this.H=this.H&-256|a;break;case 194:this.L=this.L&-256|a;break;case 195:this.G=this.G&-256|a;break;case 196:this.F=this.F&-65281|a<<8;break;case 197:this.H=this.H&-65281|a<<8;break;case 198:this.L=this.L&-65281|a<<8;break;case 199:this.G=this.G&-65281|a<<8;break;default:tf(this,a)}} +function Ee(a){switch((this.aa=this.la())&199){case 0:var b=L(this,this.F);break;case 1:b=L(this,this.H);break;case 2:b=L(this,this.L);break;case 3:b=L(this,this.G);break;case 4:b=L(this,Hi.call(this,0));break;case 5:b=L(this,Q(this));break;case 6:b=L(this,this.J);break;case 7:b=L(this,this.I);break;case 64:b=L(this,this.F+this.P());break;case 65:b=L(this,this.H+this.P());break;case 66:b=L(this,this.L+this.P());break;case 67:b=L(this,this.G+this.P());break;case 68:b=L(this,Hi.call(this,1)+this.P()); +break;case 69:b=M(this,this.M+this.P());break;case 70:b=L(this,this.J+this.P());break;case 71:b=L(this,this.I+this.P());break;case 128:b=L(this,this.F+Q(this));break;case 129:b=L(this,this.H+Q(this));break;case 130:b=L(this,this.L+Q(this));break;case 131:b=L(this,this.G+Q(this));break;case 132:b=L(this,Hi.call(this,2)+Q(this));break;case 133:b=M(this,this.M+Q(this));break;case 134:b=L(this,this.J+Q(this));break;case 135:b=L(this,this.I+Q(this));break;case 192:b=this.F&65535;break;case 193:b=this.H& +65535;break;case 194:b=this.L&65535;break;case 195:b=this.G&65535;break;case 196:b=C(this)&65535;break;case 197:b=this.M&65535;break;case 198:b=this.J&65535;break;case 199:b=this.I&65535;break;default:b=0}var c=this.aa>>3&7;switch(c){case 0:var d=this.F&65535;break;case 1:d=this.H&65535;break;case 2:d=this.L&65535;break;case 3:d=this.G&65535;break;case 4:d=C(this)&65535;break;case 5:d=this.M&65535;break;case 6:d=this.J&65535;break;case 7:d=this.I&65535;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.F= +this.F&-65536|a;break;case 1:this.H=this.H&-65536|a;break;case 2:this.L=this.L&-65536|a;break;case 3:this.G=this.G&-65536|a;break;case 4:B(this,C(this)&-65536|a);break;case 5:this.M=this.M&-65536|a;break;case 6:this.J=this.J&-65536|a;break;case 7:this.I=this.I&-65536|a}} +function Fe(a){var b=(this.aa=this.la())&199;switch(b){case 0:var c=L(this,this.F);this.D=this.C;break;case 1:c=L(this,this.H);this.D=this.C;break;case 2:c=L(this,this.L);this.D=this.C;break;case 3:c=L(this,this.G);this.D=this.C;break;case 4:c=L(this,Hi.call(this,0));this.D=this.C;break;case 5:c=L(this,Q(this));this.D=this.C;break;case 6:c=L(this,this.J);this.D=this.C;break;case 7:c=L(this,this.I);this.D=this.C;break;case 64:c=L(this,this.F+this.P());this.D=this.C;break;case 65:c=L(this,this.H+this.P()); +this.D=this.C;break;case 66:c=L(this,this.L+this.P());this.D=this.C;break;case 67:c=L(this,this.G+this.P());this.D=this.C;break;case 68:c=L(this,Hi.call(this,1)+this.P());this.D=this.C;break;case 69:c=M(this,this.M+this.P());this.D=this.C;break;case 70:c=L(this,this.J+this.P());this.D=this.C;break;case 71:c=L(this,this.I+this.P());this.D=this.C;break;case 128:c=L(this,this.F+Q(this));this.D=this.C;break;case 129:c=L(this,this.H+Q(this));this.D=this.C;break;case 130:c=L(this,this.L+Q(this));this.D= +this.C;break;case 131:c=L(this,this.G+Q(this));this.D=this.C;break;case 132:c=L(this,Hi.call(this,2)+Q(this));this.D=this.C;break;case 133:c=M(this,this.M+Q(this));this.D=this.C;break;case 134:c=L(this,this.J+Q(this));this.D=this.C;break;case 135:c=L(this,this.I+Q(this));this.D=this.C;break;case 192:c=this.F&65535;break;case 193:c=this.H&65535;break;case 194:c=this.L&65535;break;case 195:c=this.G&65535;break;case 196:c=C(this)&65535;break;case 197:c=this.M&65535;break;case 198:c=this.J&65535;break; +case 199:c=this.I&65535;break;default:c=0}switch(this.aa>>3&7){case 0:var d=this.F&65535;break;case 1:d=this.H&65535;break;case 2:d=this.L&65535;break;case 3:d=this.G&65535;break;case 4:d=C(this)&65535;break;case 5:d=this.M&65535;break;case 6:d=this.J&65535;break;case 7:d=this.I&65535;break;default:d=0}a=a.call(this,c,d);switch(b){case 192:this.F=this.F&-65536|a;break;case 193:this.H=this.H&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:B(this, +C(this)&-65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.J=this.J&-65536|a;break;case 199:this.I=this.I&-65536|a;break;default:uf(this,a)}} +function Ge(a,b){var c=(this.aa=this.la())&199;switch(c){case 0:var d=L(this,this.F);this.D=this.C;break;case 1:d=L(this,this.H);this.D=this.C;break;case 2:d=L(this,this.L);this.D=this.C;break;case 3:d=L(this,this.G);this.D=this.C;break;case 4:d=L(this,Hi.call(this,0));this.D=this.C;break;case 5:d=L(this,Q(this));this.D=this.C;break;case 6:d=L(this,this.J);this.D=this.C;break;case 7:d=L(this,this.I);this.D=this.C;break;case 64:d=L(this,this.F+this.P());this.D=this.C;break;case 65:d=L(this,this.H+ +this.P());this.D=this.C;break;case 66:d=L(this,this.L+this.P());this.D=this.C;break;case 67:d=L(this,this.G+this.P());this.D=this.C;break;case 68:d=L(this,Hi.call(this,1)+this.P());this.D=this.C;break;case 69:d=M(this,this.M+this.P());this.D=this.C;break;case 70:d=L(this,this.J+this.P());this.D=this.C;break;case 71:d=L(this,this.I+this.P());this.D=this.C;break;case 128:d=L(this,this.F+Q(this));this.D=this.C;break;case 129:d=L(this,this.H+Q(this));this.D=this.C;break;case 130:d=L(this,this.L+Q(this)); +this.D=this.C;break;case 131:d=L(this,this.G+Q(this));this.D=this.C;break;case 132:d=L(this,Hi.call(this,2)+Q(this));this.D=this.C;break;case 133:d=M(this,this.M+Q(this));this.D=this.C;break;case 134:d=L(this,this.J+Q(this));this.D=this.C;break;case 135:d=L(this,this.I+Q(this));this.D=this.C;break;case 192:d=this.F&65535;break;case 193:d=this.H&65535;break;case 194:d=this.L&65535;break;case 195:d=this.G&65535;break;case 196:d=C(this)&65535;break;case 197:d=this.M&65535;break;case 198:d=this.J&65535; +break;case 199:d=this.I&65535;break;default:d=0}a=a[this.aa>>3&7].call(this,d,b.call(this));switch(c){case 192:this.F=this.F&-65536|a;break;case 193:this.H=this.H&-65536|a;break;case 194:this.L=this.L&-65536|a;break;case 195:this.G=this.G&-65536|a;break;case 196:B(this,C(this)&-65536|a);break;case 197:this.M=this.M&-65536|a;break;case 198:this.J=this.J&-65536|a;break;case 199:this.I=this.I&-65536|a;break;default:uf(this,a)}} +function He(a){switch((this.aa=this.la())&199){case 0:var b=N(this,this.F);break;case 1:b=N(this,this.H);break;case 2:b=N(this,this.L);break;case 3:b=N(this,this.G);break;case 4:b=N(this,Hi.call(this,0));break;case 5:b=N(this,Q(this));break;case 6:b=N(this,this.J);break;case 7:b=N(this,this.I);break;case 64:b=N(this,this.F+this.P());break;case 65:b=N(this,this.H+this.P());break;case 66:b=N(this,this.L+this.P());break;case 67:b=N(this,this.G+this.P());break;case 68:b=N(this,Hi.call(this,1)+this.P()); +break;case 69:b=P(this,this.M+this.P());break;case 70:b=N(this,this.J+this.P());break;case 71:b=N(this,this.I+this.P());break;case 128:b=N(this,this.F+Q(this));break;case 129:b=N(this,this.H+Q(this));break;case 130:b=N(this,this.L+Q(this));break;case 131:b=N(this,this.G+Q(this));break;case 132:b=N(this,Hi.call(this,2)+Q(this));break;case 133:b=P(this,this.M+Q(this));break;case 134:b=N(this,this.J+Q(this));break;case 135:b=N(this,this.I+Q(this));break;case 192:b=this.F;break;case 193:b=this.H;break; +case 194:b=this.L;break;case 195:b=this.G;break;case 196:b=C(this);break;case 197:b=this.M;break;case 198:b=this.J;break;case 199:b=this.I;break;default:b=0}var c=this.aa>>3&7;switch(c){case 0:var d=this.F;break;case 1:d=this.H;break;case 2:d=this.L;break;case 3:d=this.G;break;case 4:d=C(this);break;case 5:d=this.M;break;case 6:d=this.J;break;case 7:d=this.I;break;default:d=0}a=a.call(this,d,b);switch(c){case 0:this.F=a;break;case 1:this.H=a;break;case 2:this.L=a;break;case 3:this.G=a;break;case 4:B(this, +a);break;case 5:this.M=a;break;case 6:this.J=a;break;case 7:this.I=a}} +function Ie(a){var b=(this.aa=this.la())&199;switch(b){case 0:var c=N(this,this.F);this.D=this.C;break;case 1:c=N(this,this.H);this.D=this.C;break;case 2:c=N(this,this.L);this.D=this.C;break;case 3:c=N(this,this.G);this.D=this.C;break;case 4:c=N(this,Hi.call(this,0));this.D=this.C;break;case 5:c=N(this,Q(this));this.D=this.C;break;case 6:c=N(this,this.J);this.D=this.C;break;case 7:c=N(this,this.I);this.D=this.C;break;case 64:c=N(this,this.F+this.P());this.D=this.C;break;case 65:c=N(this,this.H+this.P()); +this.D=this.C;break;case 66:c=N(this,this.L+this.P());this.D=this.C;break;case 67:c=N(this,this.G+this.P());this.D=this.C;break;case 68:c=N(this,Hi.call(this,1)+this.P());this.D=this.C;break;case 69:c=P(this,this.M+this.P());this.D=this.C;break;case 70:c=N(this,this.J+this.P());this.D=this.C;break;case 71:c=N(this,this.I+this.P());this.D=this.C;break;case 128:c=N(this,this.F+Q(this));this.D=this.C;break;case 129:c=N(this,this.H+Q(this));this.D=this.C;break;case 130:c=N(this,this.L+Q(this));this.D= +this.C;break;case 131:c=N(this,this.G+Q(this));this.D=this.C;break;case 132:c=N(this,Hi.call(this,2)+Q(this));this.D=this.C;break;case 133:c=P(this,this.M+Q(this));this.D=this.C;break;case 134:c=N(this,this.J+Q(this));this.D=this.C;break;case 135:c=N(this,this.I+Q(this));this.D=this.C;break;case 192:c=this.F;break;case 193:c=this.H;break;case 194:c=this.L;break;case 195:c=this.G;break;case 196:c=C(this);break;case 197:c=this.M;break;case 198:c=this.J;break;case 199:c=this.I;break;default:c=0}switch(this.aa>> +3&7){case 0:var d=this.F;break;case 1:d=this.H;break;case 2:d=this.L;break;case 3:d=this.G;break;case 4:d=C(this);break;case 5:d=this.M;break;case 6:d=this.J;break;case 7:d=this.I;break;default:d=0}a=a.call(this,c,d);switch(b){case 192:this.F=a;break;case 193:this.H=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:B(this,a);break;case 197:this.M=a;break;case 198:this.J=a;break;case 199:this.I=a;break;default:vf(this,a)}} +function Je(a,b){var c=(this.aa=this.la())&199;switch(c){case 0:var d=N(this,this.F);this.D=this.C;break;case 1:d=N(this,this.H);this.D=this.C;break;case 2:d=N(this,this.L);this.D=this.C;break;case 3:d=N(this,this.G);this.D=this.C;break;case 4:d=N(this,Hi.call(this,0));this.D=this.C;break;case 5:d=N(this,Q(this));this.D=this.C;break;case 6:d=N(this,this.J);this.D=this.C;break;case 7:d=N(this,this.I);this.D=this.C;break;case 64:d=N(this,this.F+this.P());this.D=this.C;break;case 65:d=N(this,this.H+ +this.P());this.D=this.C;break;case 66:d=N(this,this.L+this.P());this.D=this.C;break;case 67:d=N(this,this.G+this.P());this.D=this.C;break;case 68:d=N(this,Hi.call(this,1)+this.P());this.D=this.C;break;case 69:d=P(this,this.M+this.P());this.D=this.C;break;case 70:d=N(this,this.J+this.P());this.D=this.C;break;case 71:d=N(this,this.I+this.P());this.D=this.C;break;case 128:d=N(this,this.F+Q(this));this.D=this.C;break;case 129:d=N(this,this.H+Q(this));this.D=this.C;break;case 130:d=N(this,this.L+Q(this)); +this.D=this.C;break;case 131:d=N(this,this.G+Q(this));this.D=this.C;break;case 132:d=N(this,Hi.call(this,2)+Q(this));this.D=this.C;break;case 133:d=P(this,this.M+Q(this));this.D=this.C;break;case 134:d=N(this,this.J+Q(this));this.D=this.C;break;case 135:d=N(this,this.I+Q(this));this.D=this.C;break;case 192:d=this.F;break;case 193:d=this.H;break;case 194:d=this.L;break;case 195:d=this.G;break;case 196:d=C(this);break;case 197:d=this.M;break;case 198:d=this.J;break;case 199:d=this.I;break;default:d= +0}a=a[this.aa>>3&7].call(this,d,b.call(this));switch(c){case 192:this.F=a;break;case 193:this.H=a;break;case 194:this.L=a;break;case 195:this.G=a;break;case 196:B(this,a);break;case 197:this.M=a;break;case 198:this.J=a;break;case 199:this.I=a;break;default:vf(this,a)}} +function Hi(a){var b=this.la(),c=b>>6;switch(b>>3&7){case 0:var d=this.F;break;case 1:d=this.H;break;case 2:d=this.L;break;case 3:d=this.G;break;case 4:d=0;break;case 5:d=this.M;break;case 6:d=this.J;break;case 7:d=this.I}switch(b&7){case 0:var e=this.F;break;case 1:e=this.H;break;case 2:e=this.L;break;case 3:e=this.G;break;case 4:e=C(this);this.Ca=this.Gb;break;case 5:a?(e=this.M,this.Ca=this.Gb):e=Q(this);break;case 6:e=this.J;break;case 7:e=this.I}return(d<>8&255;if(9<(b&15)||Ze(this)){b+=6;80286<=this.ca&&255>8&255;if(9<(b&15)||Ze(this)){b=b-6&15;c=c-1&255;var d=a=1}else d=a=0;this.F=this.F&-65536|c<<8|b;d?df(this):ef(this);a?mf(this):kf(this);this.A-=this.B.Pd},function(){this.F=vi.call(this,this.F)},function(){this.H=vi.call(this,this.H)},function(){this.L=vi.call(this,this.L)},function(){this.G=vi.call(this, +this.G)},function(){B(this,vi.call(this,C(this)))},function(){this.M=vi.call(this,this.M)},function(){this.J=vi.call(this,this.J)},function(){this.I=vi.call(this,this.I)},function(){this.F=ti.call(this,this.F)},function(){this.H=ti.call(this,this.H)},function(){this.L=ti.call(this,this.L)},function(){this.G=ti.call(this,this.G)},function(){B(this,ti.call(this,C(this)))},function(){this.M=ti.call(this,this.M)},function(){this.J=ti.call(this,this.J)},function(){this.I=ti.call(this,this.I)},function(){D(this, +this.F&this.O);this.A-=this.B.tc},function(){D(this,this.H&this.O);this.A-=this.B.tc},function(){D(this,this.L&this.O);this.A-=this.B.tc},function(){D(this,this.G&this.O);this.A-=this.B.tc},function(){D(this,C(this)-2&65535);this.A-=this.B.tc},function(){D(this,this.M&this.O);this.A-=this.B.tc},function(){D(this,this.J&this.O);this.A-=this.B.tc},function(){D(this,this.I&this.O);this.A-=this.B.tc},function(){this.F=this.F&~this.O|A(this);this.A-=this.B.$b},function(){this.H=this.H&~this.O|A(this); +this.A-=this.B.$b},function(){this.L=this.L&~this.O|A(this);this.A-=this.B.$b},function(){this.G=this.G&~this.O|A(this);this.A-=this.B.$b},function(){B(this,C(this)&~this.O|A(this));this.A-=this.B.$b},function(){this.M=this.M&~this.O|A(this);this.A-=this.B.$b},function(){this.J=this.J&~this.O|A(this);this.A-=this.B.$b},function(){this.I=this.I&~this.O|A(this);this.A-=this.B.$b},Ii,Ji,Ki,Li,Mi,Ni,Oi,Pi,Qi,Ri,Si,Ti,Ui,Vi,Wi,Xi,Ii,Ji,Ki,Li,Mi,Ni,Oi,Pi,Qi,Ri,Si,Ti,Ui,Vi,Wi,Xi,Yi,function(){this.eb.call(this, +mj,this.ya);this.A-=-1===this.D?1:this.B.Mf},Yi,function(){this.eb.call(this,mj,this.P);this.A-=-1===this.D?1:this.B.Mf},function(){this.ec.call(this,ki)},function(){this.za.call(this,li)},function(){this.Xb.call(this,oi)},function(){this.ia.call(this,pi)},$i,aj,bj,cj,function(){this.K|=1;this.za.call(this,Ah)},function(){this.K|=1;this.Ca=this.Gb=this.bg;this.ia.call(this,qh)},function(){this.ia.call(this,zh);switch(this.aa>>3&7){case 0:var a=this.F;this.F=this.ua;yd(this,a);break;case 1:a=this.H; +this.H=this.ua;Se(this,a);break;case 2:a=this.L;this.L=this.ua;rd(this,a);break;case 3:a=this.G;this.G=this.ua;xd(this,a);break;case 4:a=C(this);B(this,this.ua);80386<=this.ca?this.rb.load(a):yd(this,a);break;case 5:a=this.M;this.M=this.ua;80386<=this.ca?this.vb.load(a):Se(this,a);break;case 6:a=this.J;this.J=this.ua;rd(this,a);break;case 7:a=this.I,this.I=this.ua,xd(this,a)}},function(){this.K|=1;this.ma=this.Aa;this.ua=A(this);this.eb.call(this,nj,Bi);this.ma=-1},function(){this.A-=3},function(){var a= +this.F;this.F=this.F&~this.O|this.H&this.O;this.H=this.H&~this.O|a&this.O;this.A-=3},function(){var a=this.F;this.F=this.F&~this.O|this.L&this.O;this.L=this.L&~this.O|a&this.O;this.A-=3},function(){var a=this.F;this.F=this.F&~this.O|this.G&this.O;this.G=this.G&~this.O|a&this.O;this.A-=3},function(){var a=this.F,b=C(this);this.F=this.F&~this.O|b&this.O;B(this,b&~this.O|a&this.O);this.A-=3},function(){var a=this.F;this.F=this.F&~this.O|this.M&this.O;this.M=this.M&~this.O|a&this.O;this.A-=3},function(){var a= +this.F;this.F=this.F&~this.O|this.J&this.O;this.J=this.J&~this.O|a&this.O;this.A-=3},function(){var a=this.F;this.F=this.F&~this.O|this.I&this.O;this.I=this.I&~this.O|a&this.O;this.A-=3},function(){this.F=2==this.T?this.F&-65536|this.F<<24>>24&65535:this.F<<16>>16;this.A-=2},function(){this.L=2==this.T?this.L&-65536|(this.F&32768?65535:0):this.F&-2147483648?-1:0;this.A-=this.B.Ci},function(){Ci.call(this,this.ya(),xf(this));this.A-=this.B.Fi},function(){this.A-=3},function(){var a=Ad(this);a&131072&& +3>this.Yb?y.call(this,13,0):(D(this,a&-196609),this.A-=this.B.tc)},function(){if(this.N&131072&&3>this.Yb)y.call(this,13,0);else{var a=A(this);a=a&65535|this.N&-65536;Bd(this,a);this.A-=this.B.$b}},function(){var a=this.F>>8&255;a&1?df(this):ef(this);a&4?(this.resultType&=-3,this.N|=4):(this.resultType&=-3,this.N&=-5);a&16?mf(this):kf(this);a&64?nf(this):lf(this);a&128?(this.resultType&=-17,this.N|=128):(this.resultType&=-17,this.N&=-129);this.A-=this.B.Ob},function(){this.F=this.F&-65281|(Ad(this)& +213)<<8;this.A-=this.B.Ob},function(){var a=this.F&-256;var b=Q(this);b=this.Ia(this.Ca.sb(b,1));this.F=a|b;this.A-=this.B.Jg},function(){this.F=this.F&~this.O|vd(this,this.Ca,Q(this));this.A-=this.B.Jg},function(){var a=Q(this),b=this.F;this.Bb(this.Ca.Kb(a,1),b);this.A-=this.B.Kg},function(){wf(this,this.Ca,Q(this),this.F);this.A-=this.B.Kg},function(){var a=1,b=0,c=this.ta,d=this.B.Lg;this.ba&192&&(a=this.H&c,b=1,d=this.B.Ng,this.ba&256||(this.A-=this.B.Mg));if(a--){var e=this.Ia(this.Ca.sb(this.J& +c,1));this.Bb(this.xa.Kb(this.I&c,1),e);e=this.N&1024?-1:1;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I+e&c;this.A-=d;this.H=this.H&~c|this.H-b&c;a&&(Ve(this),this.K|=256)}},function(){var a=1,b=0,c=this.ta,d=this.B.Lg;this.ba&192&&(a=this.H&c,b=1,d=this.B.Ng,this.ba&256||(this.A-=this.B.Mg));if(a--){wf(this,this.xa,this.I&c,vd(this,this.Ca,this.J&c));var e=this.N&1024?-this.T:this.T;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I+e&c;this.A-=d;this.H=this.H&~c|this.H-b&c;a&&(Ve(this), +this.K|=256)}},function(){var a=1,b=0,c=this.ta,d=this.B.wg;this.ba&192&&(a=this.H&c,b=1,d=this.B.yg,this.ba&256||(this.A-=this.B.xg));if(a--){var e=rf(this,this.Ca,this.J),f=rf(this,this.xa,this.I);this.D=this.C;eh.call(this,e,f);e=this.N&1024?-1:1;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I+e&c;this.H=this.H&~c|this.H-b&c;this.A-=d-this.B.zb;a&&$e(this)==(this.ba&64)&&(Ve(this),this.K|=256)}},function(){var a=1,b=0,c=this.ta,d=this.B.wg;this.ba&192&&(a=this.H&c,b=1,d=this.B.yg,this.ba&256|| +(this.A-=this.B.xg));if(a--){var e=sf(this,this.Ca,this.J&c),f=sf(this,this.xa,this.I&c);this.D=this.C;fh.call(this,e,f);e=this.N&1024?-this.T:this.T;this.J=this.J&~c|this.J+e&c;this.I=this.I&~c|this.I+e&c;this.H=this.H&~c|this.H-b&c;this.A-=d-this.B.zb;a&&$e(this)==(this.ba&64)&&(Ve(this),this.K|=256)}},function(){cf(this,this.F&this.la(),128);this.A-=this.B.Pd},function(){cf(this,this.F&this.ya(),this.wb);this.A-=this.B.Pd},function(){var a=1,b=0,c=this.ta,d=this.B.Wg;this.ba&192&&(a=this.H&c,b= +1,d=this.B.Yg,this.ba&256||(this.A-=this.B.Xg));if(a--){var e=this.F;this.Bb(this.xa.Kb(this.I&c,1),e);this.H=this.H&~c|this.H-b&c;80546<=this.qd&&80564>=this.qd&&!(this.ba&2048)!=(103!=this.Ia(this.da))&&(c^=-65536);this.I=this.I&~c|this.I+(this.N&1024?-1:1)&c;this.A-=d;a&&(Ve(this),this.K|=256)}},function(){var a=1,b=0,c=this.ta,d=this.B.Wg;this.ba&192&&(a=this.H&c,b=1,d=this.B.Yg,this.ba&256||(this.A-=this.B.Xg));a--&&(wf(this,this.xa,this.I&c,this.F),this.I=this.I&~c|this.I+(this.N&1024?-this.T: +this.T)&c,this.H=this.H&~c|this.H-b&c,this.A-=d,a&&(Ve(this),this.K|=256))},function(){var a=1,b=0,c=this.ta,d=this.B.Dg;this.ba&192&&(a=this.H&c,b=1,d=this.B.Fg,this.ba&256||(this.A-=this.B.Eg));if(a--){var e=this.Ia(this.Ca.sb(this.J&c,1));this.F=this.F&-256|e;this.J=this.J&~c|this.J+(this.N&1024?-1:1)&c;this.H=this.H&~c|this.H-b&c;this.A-=d;a&&(Ve(this),this.K|=256)}},function(){var a=1,b=0,c=this.ta,d=this.B.Dg;this.ba&192&&(a=this.H&c,b=1,d=this.B.Fg,this.ba&256||(this.A-=this.B.Eg));if(a--){var e= +vd(this,this.Ca,this.J&c);this.F=this.F&~this.O|e;this.J=this.J&~c|this.J+(this.N&1024?-this.T:this.T)&c;this.H=this.H&~c|this.H-b&c;this.A-=d;a&&(Ve(this),this.K|=256)}},function(){var a=1,b=0,c=this.ta,d=this.B.Qg;this.ba&192&&(a=this.H&c,b=1,d=this.B.Sg,this.ba&256||(this.A-=this.B.Rg));if(a--){var e=this.F&255,f=rf(this,this.xa,this.I);this.D=this.C;eh.call(this,e,f);this.I=this.I&~c|this.I+(this.N&1024?-1:1)&c;this.H=this.H&~c|this.H-b&c;this.A-=d-this.B.zb;a&&$e(this)==(this.ba&64)&&(Ve(this), +this.K|=256)}},function(){var a=1,b=0,c=this.ta,d=this.B.Qg;this.ba&192&&(a=this.H&c,b=1,d=this.B.Sg,this.ba&256||(this.A-=this.B.Rg));if(a--){var e=this.F&this.O,f=sf(this,this.xa,this.I&c);this.D=this.C;fh.call(this,e,f);this.I=this.I&~c|this.I+(this.N&1024?-this.T:this.T)&c;this.H=this.H&~c|this.H-b&c;this.A-=d-this.B.zb;a&&$e(this)==(this.ba&64)&&(Ve(this),this.K|=256)}},function(){this.F=this.F&-256|this.la();this.A-=this.B.Ob},function(){this.H=this.H&-256|this.la();this.A-=this.B.Ob},function(){this.L= +this.L&-256|this.la();this.A-=this.B.Ob},function(){this.G=this.G&-256|this.la();this.A-=this.B.Ob},function(){this.F=this.F&-65281|this.la()<<8;this.A-=this.B.Ob},function(){this.H=this.H&-65281|this.la()<<8;this.A-=this.B.Ob},function(){this.L=this.L&-65281|this.la()<<8;this.A-=this.B.Ob},function(){this.G=this.G&-65281|this.la()<<8;this.A-=this.B.Ob},function(){this.F=this.F&~this.O|this.ya();this.A-=this.B.Ob},function(){this.H=this.H&~this.O|this.ya();this.A-=this.B.Ob},function(){this.L=this.L& +~this.O|this.ya();this.A-=this.B.Ob},function(){this.G=this.G&~this.O|this.ya();this.A-=this.B.Ob},function(){B(this,C(this)&~this.O|this.ya());this.A-=this.B.Ob},function(){this.M=this.M&~this.O|this.ya();this.A-=this.B.Ob},function(){this.J=this.J&~this.O|this.ya();this.A-=this.B.Ob},function(){this.I=this.I&~this.O|this.ya();this.A-=this.B.Ob},gj,hj,gj,hj,function(){this.ia.call(this,rh)},function(){this.ia.call(this,ph)},function(){this.K|=1;this.Rc.call(this,oj,this.la)},function(){this.K|=1; +this.eb.call(this,oj,this.ya)},ij,jj,ij,jj,function(){if(this.N&131072&&3>this.Yb)y.call(this,13,0);else{var a=this.B.Wi;this.sc=-1;Di.call(this,3,null,a)}},function(){var a=this.la();if(this.N&131072&&3>this.Yb)y.call(this,13,0);else{a:{var b=this.kf[a];if(void 0!==b)for(var c=0;cthis.Yb)y.call(this,13,0);else{var a=this.B.Xi;this.sc=-1;Di.call(this,4,null, +a)}else this.A-=this.B.Yi},function(){if(this.N&131072&&3>this.Yb)y.call(this,13,0);else{this.uc=this.W.ha;this.ma=this.Aa;this.A-=this.B.Ui;if(this.ra&1&&this.N&16384){var a=this.ga(this.ka.va+0);sd(this.fa,a,!1)}else{a=this.La;var b=A(this),c=A(this),d=A(this);if(this.N&131072)d=d&131071|this.N&-131072;else if(d&131072){var e=A(this),f=A(this),g=A(this),h=A(this),k=A(this),m=A(this);td(this,!0,!0);rd(this,f);B(this,e);yd(this,g);xd(this,h);this.rb.load(k);this.vb.load(m)}null!=Cd(this,b,c,!1)&& +(Bd(this,d,a),this.$f&&Ne(this,this.da))}this.uc=this.ma=-1}},function(){this.Rc.call(this,dj,xi)},function(){this.eb.call(this,2==this.T?ej:fj,xi)},function(){this.Rc.call(this,dj,yi)},function(){this.eb.call(this,2==this.T?ej:fj,yi)},function(){var a=this.la();if(a){var b=this.F&255;this.F=this.F&-65536|b/a<<8|b%a;cf(this,this.F,128);this.A-=this.B.zi}else Gi.call(this)},function(){var a=this.F&255,b=(this.F>>8&255)*this.la()|0,c=a+b|0;this.F=this.F&-65536|c&255;We(this,a,b,c,191);this.A-=this.B.yi}, +function(){this.F=this.F&-256|(Xe(this)?255:0);this.A-=2},function(){this.F=this.F&-256|rf(this,this.Ca,this.G+(this.F&255));this.A-=this.B.xj},function(){kj.call(this,216)},function(){kj.call(this,217)},function(){kj.call(this,218)},function(){kj.call(this,219)},function(){kj.call(this,220)},function(){kj.call(this,221)},function(){kj.call(this,222)},function(){kj.call(this,223)},function(){var a=this.P(),b=this.H-1&this.ta;this.H=this.H&~this.ta|b;b&&!$e(this)?(H(this,F(this)+a),this.A-=this.B.ej): +this.A-=this.B.Gg},function(){var a=this.P(),b=this.H-1&this.ta;this.H=this.H&~this.ta|b;b&&$e(this)?(H(this,F(this)+a),this.A-=this.B.Hg):this.A-=this.B.Ig},function(){var a=this.P(),b=this.H-1&this.ta;this.H=this.H&~this.ta|b;b?(H(this,F(this)+a),this.A-=this.B.dj):this.A-=this.B.Gg},function(){var a=this.P();this.H&this.ta?this.A-=this.B.Ig:(H(this,F(this)+a),this.A-=this.B.Hg)},function(){var a=this.la();pf(this,a,1)&&(this.F=this.F&-256|lc(this.oa,a,1,this.da-2)&255,this.A-=this.B.Bg)},function(){var a= +this.la();pf(this,a,this.T)&&(this.F=this.F&~this.O|lc(this.oa,a,this.T,this.da-2)&this.O,this.A-=this.B.Bg)},function(){var a=this.la();pf(this,a,1)&&(nc(this.oa,a,1,this.F&255,this.da-2),this.A-=this.B.Pg)},function(){var a=this.la();pf(this,a,this.T)&&(nc(this.oa,a,this.T,this.F&this.O,this.da-2),this.A-=this.B.Pg)},function(){var a=this.ya(),b=F(this);a=b+a;D(this,b);H(this,a);this.A-=this.B.Di},function(){var a=this.ya();H(this,F(this)+a);this.A-=this.B.Cg},function(){Cd(this,this.ya(),xf(this)); +this.A-=this.B.$i},function(){var a=this.P();H(this,F(this)+a);this.A-=this.B.Cg},function(){var a=this.L&65535;pf(this,a,1)&&(this.F=this.F&-256|lc(this.oa,a,1,this.da-1)&255,this.A-=this.B.Ag)},function(){var a=this.L&65535;pf(this,a,this.T)&&(this.F=this.F&~this.O|lc(this.oa,a,this.T,this.da-1)&this.O,this.A-=this.B.Ag)},function(){var a=this.L&65535;pf(this,a,1)&&(nc(this.oa,a,1,this.F&255,this.da-1),this.A-=this.B.Og)},function(){var a=this.L&65535;pf(this,a,2)&&(nc(this.oa,a,this.T,this.F&this.O, +this.da-1),this.A-=this.B.Og)},lj,lj,function(){this.K|=132;this.A-=this.B.Hc},function(){this.K|=68;this.A-=this.B.Hc},function(){this.N&131072?y.call(this,13,0):(this.Qa|=4,this.A-=2,this.N&512||Rc(this))},function(){Xe(this)?ef(this):df(this);this.A-=2},function(){this.fc=!1;this.Rc.call(this,pj,Ai);this.fc&&(this.F=this.F&~this.O|this.Ba&this.O)},function(){this.fc=!1;this.eb.call(this,qj,Ai);this.fc&&(this.F=this.F&~this.O|this.Ba&this.O,this.L=this.L&~this.O|this.Sa&this.O)},function(){ef(this); +this.A-=2},function(){df(this);this.A-=2},function(){this.La>this.Yb?y.call(this,13,0):(this.N&=-513,this.A-=this.B.Bi)},function(){this.La>this.Yb?y.call(this,13,0):(this.N|=512,this.K|=4,this.A-=2)},function(){this.N&=-1025;this.A-=2},function(){this.N|=1024;this.A-=2},function(){this.Rc.call(this,Fd,Ai)},function(){this.eb.call(this,Gd,Ai)}],Zi=[Pg,Bh,Ng,Dh,Rg,ii,qi,eh],mj=[Qg,Ch,Og,Eh,Sg,ji,ri,fh],nj=[function(a,b){this.A-=-1===this.D?this.B.$b:this.B.pj;return b},hh,hh,hh,hh,hh,hh,hh],oj=[function(a, +b){this.A-=-1===this.D?this.B.hj:this.B.fj;return b},T,T,T,T,T,T,T],dj=[function(a,b){var c=a;if(b&=this.Ma){if(b&=7){var d=a<>8-b)&255}else d=a<<7;hf(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ma){if(b&=7){var d=a<<8-b;c=(a>>>b|d)&255}else d=a;hf(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ma){var d=jf(this);(b%=9)?(c=(a<>9-b)&255,d=a<>b|d<< +8-b|a<<9-b)&255,d=a<<8-b):d<<=7;hf(this,c,d,128)}return c},function(a,b){var c=a;if(b&=this.Ma){var d=0;8>>b-1,a=b>>>1&255,cf(this,a,128,b&1,a&128);return a},T,function(a,b){if(b&=this.Ma)9>24>>b-1,a=b>>1&255,cf(this,a,128,b&1);return a}],ej=[function(a,b){var c=a;if(b&=this.Ma){if(b&=15){var d=a<>16-b)&65535}else d=a<<15;hf(this,c,d,32768)}return c},function(a, +b){var c=a;if(b&=this.Ma){if(b&=15){var d=a<<16-b;c=(a>>>b|d)&65535}else d=a;hf(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ma){var d=jf(this);(b%=17)?(c=(a<>17-b)&65535,d=a<>b|d<<16-b|a<<17-b)&65535,d=a<<16-b):d<<=15;hf(this,c,d,32768)}return c},function(a,b){var c=a;if(b&=this.Ma){var d=0;16>>b-1,a=b>>>1&65535,cf(this,a,32768,b&1,a&32768);return a},T,function(a,b){if(b&=this.Ma)17>16>>b-1,a=b>>1&65535,cf(this,a,32768,b&1);return a}],fj=[function(a,b){var c=a;if(b&=this.Ma)c=a<>>32-b,hf(this,c,a<>>b|d;hf(this,c,d,-2147483648)}return c},function(a,b){var c=a;if(b&=this.Ma)c=jf(this),c=a<>>32-b>>>1,hf(this,c,a<>>b|c<<32-b|a<<32-b<<1,hf(this,c,a<<32-b,-2147483648);return c},function(a,b){var c=a;if(b&=this.Ma)a<<=b-1,c=a<<1,cf(this,c,-2147483648,a&-2147483648,(c^a)&-2147483648);return c},function(a,b){if(b&=this.Ma)b=a>>>b-1,a=b>>>1,cf(this,a,-2147483648,b&1,a&-2147483648);return a},T,function(a,b){if(b&=this.Ma)b=a>>b-1,a=b>>1,cf(this,a,-2147483648,b&1);return a}],pj=[function(a,b){b=this.la();cf(this,a&b,128);this.A-=-1===this.C?this.B.$g:this.B.Zg;this.K|= +2;return a},T,function(a){this.A-=-1===this.C?this.B.Te:this.B.Se;return a^255},function(a){var b=-a|0;We(this,0,a,b,191,!0);this.A-=-1===this.C?this.B.Te:this.B.Se;return b&255},function(a){this.Ba=(this.F&255)*a&65535;this.Ba&65280?(df(this),ff(this)):(ef(this),gf(this));this.fc=!0;this.A-=-1===this.C?this.B.lj:this.B.kj;this.K|=2;return a},function(a){var b=(this.F<<24>>24)*(a<<24>>24)|0;this.Ba=b&65535;127b?(df(this),ff(this)):(ef(this),gf(this));this.fc=!0;this.A-=-1===this.C?this.B.Ri: +this.B.Qi;this.K|=2;return a},function(a,b){if(!a)return Gi.call(this),a;var c=(b=this.F&65535)/a;if(255>24,d=(b=this.F<<16>>16)/c|0;if(d!=d<<24>>24||8086==this.ca&&-128==d)return Gi.call(this),a;this.Ba=d&255|(b%c&255)<<8;this.fc=!0;this.A-=-1===this.C?this.B.Ni:this.B.Mi;this.K|=2;return a}],qj=[function(a,b){b=this.ya(); +cf(this,a&b,this.wb);this.A-=-1===this.C?this.B.$g:this.B.Zg;this.K|=2;return a},T,function(a){this.A-=-1===this.C?this.B.Te:this.B.Se;return a^this.O},function(a){var b=-a|0;We(this,0,a,b,this.wb|63,!0);this.A-=-1===this.C?this.B.Te:this.B.Se;return b&this.O},function(a,b){2==this.T?(b=this.F&65535,b=b*a|0,this.Ba=b&65535,this.Sa=b>>16&65535):(nh.call(this,a,this.F),80563==this.qd&&68657152==this.F&&129==a&&(this.Sa=0));this.Sa?(df(this),ff(this)):(ef(this),gf(this));this.fc=!0;this.A-=-1===this.C? +this.B.nj:this.B.mj;this.K|=2;return a},function(a,b){2==this.T?(b=this.F&65535,b=(b<<16>>16)*(a<<16>>16)|0,this.Ba=b&65535,this.Sa=b>>16&65535,b=32767b):(mh.call(this,a,this.F),b=this.Sa!=this.Ba>>31);b?(df(this),ff(this)):(ef(this),gf(this));this.fc=!0;this.A-=-1===this.C?this.B.Ti:this.B.Si;this.K|=2;return a},function(a,b){if(2==this.T){if(!a)return Gi.call(this),a;b=65536*(this.L&65535)+(this.F&65535);var c=b/a;if(65536<=c)return Gi.call(this),a;this.Ba=c&65535;this.Sa=b%a&65535}else{if(!ui.call(this, +this.F,this.L,a))return Gi.call(this),a;this.Ba|=0;this.Sa|=0}this.fc=!0;this.A-=-1===this.C?this.B.Li:this.B.Ki;this.K|=2;return a},function(a,b){if(2==this.T){if(!a)return Gi.call(this),a;var c=a<<16>>16,d=(b=this.L<<16|this.F&65535)/c|0;if(d!=d<<16>>16||8086==this.ca&&-32768==d)return Gi.call(this),a;this.Ba=d&65535;this.Sa=b%c&65535}else{b=this.F;c=this.L;d=a;var e=0,f=0;0>d&&(d=-d|0,e=1-e);0>c&&(b=-b|0,c=~c+(b?0:1)|0,f=1,e=1-e);!ui.call(this,b,c,d)||this.Ba>2147483647+e||this.Sa>2147483647+f? +b=!1:(e&&(this.Ba=-this.Ba),f&&(this.Sa=-this.Sa),b=!0);if(!b)return Gi.call(this),a;this.Ba|=0;this.Sa|=0}this.fc=!0;this.A-=-1===this.C?this.B.Pi:this.B.Oi;this.K|=2;return a}],Fd=[function(a){var b=a+1|0;We(this,a,1,b,190);this.A-=-1===this.C?this.B.Re:this.B.Qe;return b&255},function(a){var b=a-1|0;We(this,a,1,b,190,!0);this.A-=-1===this.C?this.B.Re:this.B.Qe;return b&255},T,T,T,T,T,T],Gd=[function(a){var b=a+1|0;We(this,a,1,b,this.wb|62);this.A-=-1===this.C?this.B.Re:this.B.Qe;return b&this.O}, +function(a){var b=a-1|0;We(this,a,1,b,this.wb|62,!0);this.A-=-1===this.C?this.B.Re:this.B.Qe;return b&this.O},function(a){D(this,F(this));H(this,a);this.A-=-1===this.C?this.B.Hi:this.B.Gi;this.K|=2;return a},function(a){if(-1===this.C)return T.call(this,a);this.ma=this.Aa;Ci.call(this,a,this.ga(this.C+this.T));this.A-=this.B.Ei;this.K|=2;this.ma=-1;return a},function(a){H(this,a);this.A-=-1===this.C?this.B.bj:this.B.aj;this.K|=2;return a},function(a){if(-1===this.C)return T.call(this,a);Cd(this,a, +this.ga(this.C+this.T));this.A-=this.B.Zi;this.K|=2;return a},function(a){var b=a;this.K&512&&(a=a-2&65535,80286>this.ca&&(b=a));D(this,b);this.A-=-1===this.C?this.B.tc:this.B.rj;this.K|=2;return a},T];function ie(){this.ia.call(this,ni);this.A-=-1===this.C?6:13}function je(){this.za.call(this,mi);this.A-=-1===this.C?12:19}var ae=Array(256);ae[0]=function(){16>(this.Ia(this.da)&56)&&(this.K|=1);this.eb.call(this,this.ei,Ai)};ae[1]=function(){this.Ia(this.da)&16||(this.K|=1);this.eb.call(this,rj,Ai)}; +ae[2]=function(){!(this.ra&1)||this.N&131072?y.call(this,6):this.ia.call(this,oh)};ae[3]=function(){!(this.ra&1)||this.N&131072?y.call(this,6):this.ia.call(this,uh)}; +ae[5]=function(){this.La?y.call(this,13,0,0,!0):(of(this,this.ga(2054)),this.I=this.ga(2086),this.J=this.ga(2088),this.M=this.ga(2090),this.G=this.ga(2094),this.L=this.ga(2096),this.H=this.ga(2098),this.F=this.ga(2100),od(this.xa,2102,this.ga(2084)),od(this.fa,2108,this.ga(2082)),od(this.W,2114,this.ga(2080)),od(this.Ga,2120,this.ga(2078)),Bd(this,this.ga(2072)),H(this,this.ga(2074)),B(this,this.ga(2092)),this.Jb=this.ga(2126)|this.Ia(2128)<<16,this.Oc=this.Jb+this.ga(2130),this.Wb=this.ga(2138)| +this.Ia(2140)<<16,this.Qc=this.Wb+this.ga(2142),od(this.lc,2132,this.ga(2076)),od(this.ka,2144,this.ga(2070)),this.A-=195)};ae[6]=function(){this.La?y.call(this,13,0):(this.ra&=-9,this.A-=2)};ae[11]=Id;ae[166]=Id;ae[255]=Id;var G=[];G[5]=Id; +G[7]=function(){if(this.La)y.call(this,13,0,0,!0);else{var a=this.xa.sb(this.I&this.ta,204);if(-1!==a){this.ra=this.ea(a);td(this);this.ra&-2147483648?le(this):oe(this);var b=this.ea(a+168),c=(b&24576)>>13;Bd(this,this.ea(a+4),c);this.Jb=this.ea(a+112);this.Oc=this.Jb+this.ea(a+116);this.Wb=this.ea(a+100);this.Qc=this.Wb+this.ea(a+104);md(this.lc,this.ea(a+56),this.ea(a+120),this.ea(a+124),this.ea(a+128));md(this.ka,this.ea(a+52),this.ea(a+84),this.ea(a+88),this.ea(a+92));this.I=this.ea(a+12);this.J= +this.ea(a+16);this.M=this.ea(a+20);this.G=this.ea(a+28);this.L=this.ea(a+32);this.H=this.ea(a+36);this.F=this.ea(a+40);md(this.vb,this.ea(a+60),this.ea(a+132),this.ea(a+136),this.ea(a+140));md(this.rb,this.ea(a+64),this.ea(a+144),this.ea(a+148),this.ea(a+152));md(this.Ga,this.ea(a+68),this.ea(a+156),this.ea(a+160),this.ea(a+164));md(this.W,this.ea(a+72),b,this.ea(a+172),this.ea(a+176));md(this.fa,this.ea(a+76),this.ea(a+180),this.ea(a+184),this.ea(a+188));md(this.xa,this.ea(a+80),this.ea(a+192),this.ea(a+ +196),this.ea(a+200));H(this,this.ea(a+8));B(this,this.ea(a+24))}this.A-=122<<(a&3?1:0)}};G[16]=$i;G[17]=aj;G[18]=bj;G[19]=cj;G[32]=function(){if(this.La)y.call(this,13,0);else{var a=this.la();switch((a&56)>>3){case 0:var b=this.ra;break;case 2:b=this.td;break;case 3:b=this.Vc;break;default:be.call(this);return}qe(this,a&7,b);this.A-=6}};G[33]=function(){if(this.La)y.call(this,13,0);else{var a=this.la(),b=(a&56)>>3;4==b||5==b?be.call(this):(qe(this,a&7,this.Cb[b]),this.A-=22)}}; +G[34]=function(){if(this.La)y.call(this,13,0);else{var a=this.la(),b=pe(this,a&7);switch((a&56)>>3){case 0:this.ra=b;td(this);this.ra&-2147483648?le(this):oe(this);this.A-=10;break;case 2:this.td=b;this.A-=4;break;case 3:this.Vc=b;Tb(this);this.A-=5;break;default:be.call(this)}}};G[35]=function(){if(this.La)y.call(this,13,0);else{var a=this.la(),b=(a&56)>>3;4==b||5==b?be.call(this):(a=pe(this,a&7),a!=this.Cb[b]&&(Oe(this,!1),this.Cb[b]=a,Oe(this,!0)),this.A-=4>b?22:14)}}; +G[36]=function(){if(this.La)y.call(this,13,0);else{var a=this.la(),b=(a&56)>>3;6>b?be.call(this):(qe(this,a&7,this.nf[b]),this.A-=12)}};G[38]=function(){if(this.La)y.call(this,13,0);else{var a=this.la(),b=(a&56)>>3;6>b?be.call(this):(this.nf[b]=pe(this,a&7),this.A-=12)}};G[128]=function(){var a=this.ya();bf(this)?(H(this,F(this)+a),this.A-=this.B.Ja):this.A-=this.B.Ka};G[129]=function(){var a=this.ya();bf(this)?this.A-=this.B.Ka:(H(this,F(this)+a),this.A-=this.B.Ja)}; +G[130]=function(){var a=this.ya();Xe(this)?(H(this,F(this)+a),this.A-=this.B.Ja):this.A-=this.B.Ka};G[131]=function(){var a=this.ya();Xe(this)?this.A-=this.B.Ka:(H(this,F(this)+a),this.A-=this.B.Ja)};G[132]=function(){var a=this.ya();$e(this)?(H(this,F(this)+a),this.A-=this.B.Ja):this.A-=this.B.Ka};G[133]=function(){var a=this.ya();$e(this)?this.A-=this.B.Ka:(H(this,F(this)+a),this.A-=this.B.Ja)};G[134]=function(){var a=this.ya();Xe(this)||$e(this)?(H(this,F(this)+a),this.A-=this.B.Ja):this.A-=this.B.Ka}; +G[135]=function(){var a=this.ya();Xe(this)||$e(this)?this.A-=this.B.Ka:(H(this,F(this)+a),this.A-=this.B.Ja)};G[136]=function(){var a=this.ya();af(this)?(H(this,F(this)+a),this.A-=this.B.Ja):this.A-=this.B.Ka};G[137]=function(){var a=this.ya();af(this)?this.A-=this.B.Ka:(H(this,F(this)+a),this.A-=this.B.Ja)};G[138]=function(){var a=this.ya();Ye(this)?(H(this,F(this)+a),this.A-=this.B.Ja):this.A-=this.B.Ka};G[139]=function(){var a=this.ya();Ye(this)?this.A-=this.B.Ka:(H(this,F(this)+a),this.A-=this.B.Ja)}; +G[140]=function(){var a=this.ya();!af(this)!=!bf(this)?(H(this,F(this)+a),this.A-=this.B.Ja):this.A-=this.B.Ka};G[141]=function(){var a=this.ya();!af(this)==!bf(this)?(H(this,F(this)+a),this.A-=this.B.Ja):this.A-=this.B.Ka};G[142]=function(){var a=this.ya();$e(this)||!af(this)!=!bf(this)?(H(this,F(this)+a),this.A-=this.B.Ja):this.A-=this.B.Ka};G[143]=function(){var a=this.ya();$e(this)||!af(this)!=!bf(this)?this.A-=this.B.Ka:(H(this,F(this)+a),this.A-=this.B.Ja)};G[144]=function(){wi.call(this,Fh)}; +G[145]=function(){wi.call(this,Fh)};G[146]=function(){wi.call(this,Gh)};G[147]=function(){wi.call(this,Hh)};G[148]=function(){wi.call(this,Ih)};G[149]=function(){wi.call(this,Jh)};G[150]=function(){wi.call(this,Kh)};G[151]=function(){wi.call(this,Lh)};G[152]=function(){wi.call(this,Mh)};G[153]=function(){wi.call(this,Nh)};G[154]=function(){wi.call(this,Oh)};G[155]=function(){wi.call(this,Ph)};G[156]=function(){wi.call(this,Qh)};G[157]=function(){wi.call(this,Rh)};G[158]=function(){wi.call(this,Sh)}; +G[159]=function(){wi.call(this,Th)};G[160]=function(){wd(this,this.rb.ha,this.T,2);this.A-=this.B.Qd};G[161]=function(){this.ma=this.Aa;var a=A(this);this.rb.load(a);this.A-=this.B.$b;this.ma=-1};G[163]=function(){this.za.call(this,ah);-1!==this.C&&(this.A-=6)};G[164]=function(){this.za.call(this,2==this.T?Uh:Wh);this.A-=-1===this.C?3:7};G[165]=function(){this.za.call(this,2==this.T?Yh:Zh);this.A-=-1===this.C?3:7};G[168]=function(){wd(this,this.vb.ha,this.T,2);this.A-=this.B.Qd}; +G[169]=function(){this.ma=this.Aa;var a=A(this);this.vb.load(a);this.A-=this.B.$b;this.ma=-1};G[171]=function(){this.za.call(this,dh);-1!==this.C&&(this.A-=5)};G[172]=function(){this.za.call(this,2==this.T?$h:ei);this.A-=-1===this.C?3:7};G[173]=function(){this.za.call(this,2==this.T?gi:hi);this.A-=-1===this.C?3:7};G[175]=function(){this.ia.call(this,2==this.T?jh:lh)};G[178]=function(){this.ia.call(this,vh)};G[179]=function(){this.za.call(this,ch);-1!==this.C&&(this.A-=5)}; +G[180]=function(){this.ia.call(this,sh)};G[181]=function(){this.ia.call(this,th)}; +G[182]=function(){this.Xb.call(this,xh);switch(this.aa>>3&7){case 0:this.F=this.F&~this.O|this.F&255;break;case 1:this.H=this.H&~this.O|this.H&255;break;case 2:this.L=this.L&~this.O|this.L&255;break;case 3:this.G=this.G&~this.O|this.G&255;break;case 4:this.kc=this.kc&~this.O|this.F>>8&255;this.F=this.ua;break;case 5:this.M=this.M&~this.O|this.H>>8&255;this.H=this.ua;break;case 6:this.J=this.J&~this.O|this.L>>8&255;this.L=this.ua;break;case 7:this.I=this.I&~this.O|this.G>>8&255,this.G=this.ua}this.A-= +-1===this.C?3:6};G[183]=function(){ud(this,2);this.ia.call(this,yh);switch(this.aa>>3&7){case 0:this.F=this.F&65535;break;case 1:this.H=this.H&65535;break;case 2:this.L=this.L&65535;break;case 3:this.G=this.G&65535;break;case 4:this.kc=this.kc&65535;break;case 5:this.M=this.M&65535;break;case 6:this.J=this.J&65535;break;case 7:this.I=this.I&65535}this.A-=-1===this.C?3:6};G[186]=function(){this.eb.call(this,sj,this.la)};G[187]=function(){this.za.call(this,bh);-1!==this.C&&(this.A-=5)}; +G[188]=function(){this.ia.call(this,Vg)};G[189]=function(){this.ia.call(this,Wg)}; +G[190]=function(){this.Xb.call(this,xh);switch(this.aa>>3&7){case 0:this.F=this.F&~this.O|(this.F&255)<<24>>24&this.O;break;case 1:this.H=this.H&~this.O|(this.H&255)<<24>>24&this.O;break;case 2:this.L=this.L&~this.O|(this.L&255)<<24>>24&this.O;break;case 3:this.G=this.G&~this.O|(this.G&255)<<24>>24&this.O;break;case 4:this.kc=this.kc&~this.O|this.F<<16>>24&this.O;this.F=this.ua;break;case 5:this.M=this.M&~this.O|this.H<<16>>24&this.O;this.H=this.ua;break;case 6:this.J=this.J&~this.O|this.L<<16>>24& +this.O;this.L=this.ua;break;case 7:this.I=this.I&~this.O|this.G<<16>>24&this.O,this.G=this.ua}this.A-=-1===this.C?3:6};G[191]=function(){ud(this,2);this.ia.call(this,yh);switch(this.aa>>3&7){case 0:this.F=this.F<<16>>16;break;case 1:this.H=this.H<<16>>16;break;case 2:this.L=this.L<<16>>16;break;case 3:this.G=this.G<<16>>16;break;case 4:this.kc=this.kc<<16>>16;break;case 5:this.M=this.M<<16>>16;break;case 6:this.J=this.J<<16>>16;break;case 7:this.I=this.I<<16>>16}this.A-=-1===this.C?3:6}; +var Pe=[function(){this.A-=2+(-1===this.C?0:1);return this.lc.ha},function(){this.A-=2+(-1===this.C?0:1);return this.ka.ha},function(a){this.K|=2;this.lc.load(a);this.A-=17+(-1===this.C?0:2);return a},function(a){this.K|=2;-1!==this.ka.load(a)&&(this.Za(this.ka.bc+4,this.ka.nb|=512),this.ka.type|=512);this.A-=17+(-1===this.C?0:2);return a},function(a){this.K|=2;this.A-=14+(-1===this.C?0:2);if(-1!==this.gb.load(a)&&2048!=(this.gb.nb&2560)&&(this.gb.ic>=this.La&&this.gb.ic>=(a&3)||7168==(this.gb.nb& +7168)))return nf(this),a;lf(this);return a},function(a){this.K|=2;this.A-=14+(-1===this.C?0:2);if(-1!==this.gb.load(a)&&512==(this.gb.nb&2560)&&this.gb.ic>=this.La&&this.gb.ic>=(a&3))return nf(this),a;lf(this);return a},T,T],Hd=[Zd,Zd,Zd,Zd,Zd,Zd,T,T],rj=[function(a){if(-1===this.C)y.call(this,6);else{a=this.Oc-this.Jb;var b=this.Jb;80286==this.ca?b|=-16777216:80386<=this.ca&&2!=this.T&&(a|=b<<16);this.Ta(this.C+2,b);this.A-=11}return a},function(a){if(-1===this.C)y.call(this,6);else{a=this.Qc-this.Wb; +var b=this.Wb;80286==this.ca?b|=-16777216:80386<=this.ca&&2!=this.T&&(a|=b<<16);this.Ta(this.C+2,b);this.A-=12}return a},function(a){-1===this.C||this.N&131072?y.call(this,6):(this.Jb=this.ea(this.C+2)&(this.O|this.O<<8),a&=65535,this.Oc=this.Jb+a,this.K|=2,this.A-=11);return a},function(a){-1===this.C||this.N&131072?y.call(this,6):(this.Wb=this.ea(this.C+2)&(this.O|this.O<<8),a&=65535,this.Qc=this.Wb+a,this.K|=2,this.A-=12);return a},function(){this.A-=2+(-1===this.C?0:1);return this.ra},T,function(a){this.N& +131072?y.call(this,6):(of(this,a),this.A-=-1===this.C?3:6,this.K|=2);return a},T],sj=[T,T,T,T,Xg,$g,Zg,Yg]; +function U(a){u.call(this,"ChipSet",a);var b=a.model;b&&!tj[b]&&q("Unrecognized ChipSet model: "+b);this.ca=tj[b]||uj;this.B=[];b=vj(a[wj]);this.B[0]=[b,b];null==b&&(this.L=[360,360],(b=a.floppies)&&b.length&&(this.L=b),xj(this,yj,this.L.length),xj(this,zj,a.monitor||(this.ca=Gf&&(this.za=this.ka=2);this.M=a.scaleTimers||!1;this.Sa=a.dateRTC;this.La=this.Ma=!1;this.Ga=0;if(a=a.sound)this.Ga="number"!=typeof a||0>a||1d||1=Gf){this.F=ak;this.J=0;this.I=bk;this.qa=0;this.K=ck|dk;512<=ek(this)&&(this.K|=fk);+gk(this,zj,void 0)==hk&&(this.K|=ik);(this.ca|0)==Mj&&(this.K=this.K|jk|kk);this.ra= +lk|mk;this.G=Array(8);this.W=0;a&&(this.A=Array(nk));ok(this,this.Sa);for(a=pk;a<=qk;a++)this.A[a]=0;for(a=rk;a>8} +l.save=function(){var a=new Qe(this);a.set(0,[this.B]);for(var b=[],c=0;c=Gf&&(a.set(5,[this.F,this.J,this.I,this.qa,this.K,this.ra]),a.set(6,[this.G[7],this.G,this.W,this.A,this.ma,this.X]));return a.data()}; +l.restore=function(a){var b;var c=a[0];Array.isArray(c[0])?this.B=c[0]:(this.B[0][0]=c[0],this.B[1][0]=c[1]&15,this.B[0][1]=c[2],this.B[1][1]=c[3]&15);Sj(this);c=a[1];for(b=0;b=f;f++){var g="pcjs-bitCell";f||(g+=" pcjs-bitCellLeft");d+='
    '+f+"
    \n"}e.innerHTML=d;Zk(a,b,c,!0)}function $k(a,b,c){if(b=(a=V[a.ca|0])&&a[b])for(var d in b)if(a=b[d],a.hc&1<d.ib[0]&&(d.ib[0]=255,d.ib[1]--,0>d.ib[1]&&(d.ib[1]=255)));return e}function nl(a,b,c,d){a=a.D[b];c=a.Tb[c];c.ib[a.Ib]=c.cc[a.Ib]=d;a.Ib^=1} +function ol(a,b){a=a.D[b];b=a.Fb|pl;a.Fb&=~ql;return b}function rl(a,b,c){a=a.D[b];b=c&3;a.Fb=a.Fb&~(16<>2].Tb[b&3],c,d,e)}function vl(a,b,c){b=a.D[b>>2].Tb[b&3];b.zf&&b.jg&&b.Of?(c&&(b.done=c),b.Nd||Al(a,b,!0)):c&&c(!0)} +function Al(a,b,c){c&&(b.count=b.ib[1]<<8|b.ib[0],b.type=b.mode&Bl,b.gi=b.Af=!1);for(var d=!1;0<=b.count&&(c=b.sf<<16|b.hb[1]<<8|b.hb[0],b.type==Cl?(d=!0,function(c){b.jg.call(b.zf,b.Of,-1,function(e,g){0>e&&(b.gi||(b.gi=!0),e=255);b.Nd||a.oa.Bb(c,e);(d=g)&&setTimeout(function(){Dl(b)||Al(a,b)},0)})}(c)):b.type==El?(c=a.oa.Ia(c),0>b.jg.call(b.zf,b.Of,c)&&(b.Af=!0)):b.type!=Fl&&(b.Af=!0)),!d&&!Dl(b););} +function Dl(a){if(!a.Af&&0<=--a.count&&(a.mode&Gl?(a.hb[0]--,0>a.hb[0]&&(a.hb[0]=255,a.hb[1]--,0>a.hb[1]&&(a.hb[1]=255))):(a.hb[0]++,255>3];b=1<<(b&7);d.Ub&b||(d.Ub|=b,d.Ne=c||0,Tl(a))}function Hf(a,b){var c=a.ac[b>>3];b=1<<(b&7);c.Ub&b&&(c.Ub&=~b,Tl(a))}function Tl(a,b){var c=-1;if(1>=1),Vc(a.R,d))),b==em&&c==im&&Sk(a))} +function jm(a,b,c){var d=0,e=c&km;b?(d=3,a.fa=c):a.ua=c;if(e==lm){if(!(c&mm))for(e=0;2>=e;e++)if(c&nm<=e;e++)c&nm<>=sm;f=c&tm;var g=c&um;c&=vm;if(c==wm)rm(a,d+e);else{d+=e;var h=a.pa[d];h.cf=c;h.mode=g;h.gg=f;h.cc=[0,0];h.ib=[0,0];h.Id=[0,0];h.Lc=!1;h.je=!1;h.Ld=!1;h.oe=!1;$l(a,d);b==em&&e==fm&&Hf(a,gm);b==em&&e==im&&255==a.ac[0].Xc&&a.H==(xm|ym|zm|Am)&&(e=a.pa[0], +e.zc[0]=e.cc[0],e.zc[1]=e.cc[1],e.kd=Xc(a.R,a.M))}}}function hm(a,b){a=a.pa[b];(b=a.cc[1]<<8|a.cc[0])||(b=1==a.hd?256:65536);return b}function cd(a,b){a=a.pa[b];(b=a.zc[1]<<8|a.zc[0])||(b=1==a.hd?256:65536);return b}function rm(a,b){am(a,b);var c=a.pa[b];c.Id[0]=c.ib[0];c.Id[1]=c.ib[1];c.je=!0;$l(a,b)}function $l(a,b){a=a.pa[b];a.Zc=a.cf==Bm?1:0;a.hd=a.cf==Cm?2:1} +function am(a,b,c){var d=a.pa[b];if(d.Ld&&(b!=im||a.H&xm)){var e=Xc(a.R,a.M),f=(e-d.kd)/a.Ba|0;0>f&&(d.kd=e,f=0);var g=hm(a,b),h=cd(a,b)-f;d.mode==cm?(0>=h&&(h=0),h||(d.Lc=!0,d.Ld=!1,b||Jf(a,gm))):d.mode==Dm?(d.Lc=1!=h,0>=h&&(h=g+h,0>=h&&(h=g),d.zc[0]=h&255,d.zc[1]=h>>8&255,d.kd=e,!b&&d.Lc&&Jf(a,gm))):d.mode==dd&&(h-=f,0>=h&&(d.Lc=!d.Lc,h=g+h,0>=h&&(h=g),d.zc[0]=h&255,d.zc[1]=h>>8&255,d.kd=e,!b&&d.Lc&&Jf(a,gm)));d.ib[0]=h&255;d.ib[1]=h>>8&255;c&&(a.kd=0)}return d} +function bd(a,b){for(var c=0;c=Gf){b=a.R.V.zd;c=Xc(a.R,a.M);null==a.Aa&&(a.ma=Xc(a.R,a.M),a.Qa=1024,a.Aa=Math.floor(a.R.V.zd/a.Qa),Qk(a));c>=a.X&&(a.A[Nk]|=Em,a.A[ed]&fd&&(a.A[Nk]|=Fm,Jf(a,Gm)),a.X=c+a.Aa);a.A[Ak]==a.A[Bk]&&a.A[Ck]==a.A[Dk]&&a.A[Ek]==a.A[Fk]&&(a.A[Nk]|=Hm,a.A[ed]&Im&&(a.A[Nk]|=Fm,Jf(a,Gm)));var d=c-a.ma,e=Math.floor(d/b);if(e&&!(a.A[ed]&Jm)){for(;e--;)if(60<=++a.A[Ak]&&(a.A[Ak]=0,60<=++a.A[Ck]&&(a.A[Ck]=0,24<=++a.A[Ek]))){a.A[Ek]=0;a.A[Gk]=a.A[Gk]% +7+1;var f=a.A[Jk];var g=Ca[a.A[Ik]-1];28==g&&0===f%4&&(f%100||0===f%400)&&g++;f=g;++a.A[Hk]>f&&(a.A[Hk]=1,12<++a.A[Ik]&&(a.A[Ik]=1,a.A[Jk]=(a.A[Jk]+1)%100))}a.A[Lk]|=Km;a.A[Nk]|=Lm;a.A[ed]&Mm&&(a.A[Nk]|=Fm,Jf(a,Gm))}a.ma=c-d%b}}l.ml=function(){var a=this.xa;this.ia&Nm&&(this.H&Om?a=this.B[0][1]:this.C&&(a=Tm(this.C)));return a};l.Nm=function(a,b){this.xa=b};l.nl=function(){return this.H};l.Om=function(a,b){Um(this,b)}; +function Um(a,b){var c=!!(b&Vm),d=!!(a.H&Vm);a.H=b;a.C&&Wm(a.C,!(b&Om),!!(b&Am));c!=d&&Sk(a,c)}l.ol=function(){var a=0;a=(this.ca|0)==Qj?this.H&ym?a|this.B[1][1]&Xm:a|this.B[1][1]>>4&1:this.H&Ym?a|this.B[0][1]>>4:a|this.B[0][1]&15;this.H&xm&&am(this,im).Lc&&(a=this.H&Vm?a|Zm:a|$m);return a};l.Pm=function(a,b){this.Ca=b};l.pl=function(){return this.ia};l.Qm=function(a,b){this.ia=b};l.uk=function(){var a=this.C?Tm(this.C):0;this.ba&=~an;return a};l.Vl=function(){};l.tk=function(){return this.H}; +l.Ul=function(a,b){Um(this,b)};l.vk=function(){return this.ba};l.wk=function(){var a=this.qa;this.F&=~(an|bn);this.C&&cn(this.C);return a};l.Xl=function(a,b){if(this.F&dn)switch(this.J){case en:fn(this,b);break;case gn:hn(this,b);break;default:if(fn(this,this.I&~bk),this.C){a=this.C;var c=b,d=-1;switch(a.F||c){case jn:d=kn;a.Pb=[];ln(a,mn);break;case nn:a.F&&(c=0);ln(a,kn);a.F=c;break;case on:a.F&&(c=0),ln(a,kn),a.F=c}pn(this,d)}}this.J=b;this.F&=~dn}; +l.xk=function(){return this.H&~(qn|rn)|(Xc(this.R)&64?rn:0)};l.Yl=function(a,b){Um(this,b)};l.yk=function(){var a=this.F&255;this.F&bn&&(this.F|=an,this.F&=~bn);return a}; +l.Wl=function(a,b){this.J=b;this.F|=dn;a=0;this.J>=sn&&(a=this.J^15,this.J=sn);switch(this.J){case tn:pn(this,this.I);break;case un:fn(this,this.I|bk);break;case vn:fn(this,this.I&~bk);this.C&&cn(this.C);break;case wn:this.C&&(this.C.Pb=[]);fn(this,this.I|bk);pn(this,xn);hn(this,lk|mk);break;case yn:pn(this,zn);break;case An:pn(this,this.K);break;case Bn:pn(this,this.ra);break;case Cn:pn(this,this.I&bk?0:Dn);break;case sn:a&1&&ke(this.R)}}; +function fn(a,b){a.I=b;a.F=a.F&~En|b&Fn;a.C&&Wm(a.C,!!(b&Gn),!(b&bk))}function pn(a,b,c){0<=b&&(a.qa=b,c?a.F|=an:(a.F&=~an,a.F|=bn))}function hn(a,b){a.ra=b;Pb(a.oa,!!(b&mk));b&lk||ke(a.R)}function Hn(a,b){a.cac?c=c?c:12:c=(c-=12)?c+128:140,d=!0);this.A[ed]&Nn||(d&&128>4)+(d&15),e=!0);if(a==Ek||a==Fk)e&&23=d?d=12==d?0:d:(d-=116,d=24==d?12:d))}}else d=b;this.A[a]=d;a==ed&&c&fd&&b&fd&&Qk(this)};l.Aj=function(a,b){this.da=b};l.Am=function(){};l.Bm=function(){this.rd&&Cf(this.rd)}; +function Sk(a,b){if(a.N){void 0!==b?a.La=b:b=!!(a.La&&a.R&&a.R.Y.cb);var c=Math.round(Cj/hm(a,im));if(20>c||2E4>>4,0,this.G,this.C,this.H),delete this.H);return!0};Qn.prototype.Qb=function(){return!0}; +function Rn(a,b,c,d){if(d)a.wa("Unable to load system ROM (error "+d+": "+b+")",0>d);else{ab(a.Dd,b,c);if("["==c.charAt(0)||"{"==c.charAt(0))try{var e=eval("("+c+")"),f=e.bytes,g=e.longs||e.data;if(f)a.A=f;else if(g)for(a.A=Array(4*g.length),d=c=0;c>8&255,a.A[d++]=g[c]>>16&255,a.A[d++]=g[c]>>24&255;else a.A=e;a.H=e.symbols;if(!a.A.length){q("Empty ROM: "+b);return}if(1==a.A.length){q(a.A[0]);return}}catch(h){a.wa("ROM data error: "+h.message);return}else for(b= +c.replace(/\n/gm," ").replace(/ +$/,"").split(" "),a.A=Array(b.length),e=0;e>>d.B].df(e&d.C,a.A[c]&255,e)}b=!0}else b=!1;if(b){b=[];"number"==typeof a.F?b.push(a.F):null!=a.F&&a.F.length&&(b=a.F);for(c=0;cthis.B?pk:23,c=a.A[b]|a.A[b+1]<<8;c+=this.A>>10;a.A[b]=c&255;a.A[b+1]=c>>8;zk(a)}}else q("No RAM allocated")}; +l.save=function(){var a=new Qe(this);this.controller&&a.set(0,this.controller.save());return a.data()};l.restore=function(a){return this.controller?this.controller.restore(a[0]):!0};function Xn(a){this.F=a;this.C=Zn;this.D=$n;this.B=ao;this.A=null}l=Xn.prototype;l.save=function(){return[this.C,this.B]};l.restore=function(a){this.Bb(0,a[0]&255);this.Bb(2,a[1]&255);return!0};l.Ia=function(a){var b=255;2>a?b=a&1?this.D>>8:this.D&255:4>a&&(b=a&1?this.B>>8:this.B&255);return b}; +l.Bb=function(a,b){if(a)2==a&&(this.B=this.B&-256|b);else if(b!=(this.C&255)){a=this.F.oa;if(b&bo)this.A&&(Wb(a,co,eo,this.A),this.A=null);else{this.A||(this.A=Xb(a,co,eo));var c=Xb(a,fo,eo);Wb(a,co,eo,c,b&go?1:cc)}this.C=this.C&-256|b}};l.ki=function(){return ho};l.kg=function(){return io};var Yn=-2134900736,fo=16646144,co=917504,eo=131072,bo=1,go=2,Zn=65535,$n=2575,ao=2,ho=[null,0],io=[function(a){return this.controller.Ia(a)},null,null,function(a,b){this.controller.Bb(a,b)},null,null]; +Sa(function(){for(var a=jb(document,"pcx86","ram"),b=0;b=n.fd&&d<=n.z&&(d-=n.fd-n.Fd),d=uo[e]==d),d){(a=a.ja["key-"+e])&&void 0!==c&&(a.style.color=c?"#ffffff":"#000000",a.style.backgroundColor=c?"#000000":"#ffffff");break}}}l.jc=function(a,b,c,d){this.na=a;this.oa=b;this.R=c;this.Ea=d;var e=this;this.ka=Nc(this.R,this.id+".inject",function(){xo(e)});this.U=Ab(a,"ChipSet");this.G=Mc(a,"autoType")||this.G;Me(c,33,this.El.bind(this))}; +l.El=function(){if(10==(this.R.F>>8&255))if(this.M=!0,this.J)this.J(),this.J=null,this.M=!1;else{var a=this.G;!this.D&&a&&(this.D=a,this.lg(this.D))}return!0};function ko(a,b){var c=0;a.ca=null;"string"==typeof b&&(a.ca=b.toUpperCase(),c=yo.indexOf(a.ca),0>c&&(c=0));if(b=yo[c])a.fa=parseInt(b.substr(2),10)}function Wm(a,b,c){a.L!==c&&(a.L=a.N=c)&&(a.H=!0);a.I!==b&&(a.I=b)&&!a.N&&Jn(a,!0);a.I&&a.N&&(a.Pb=[],ln(a,mn),a.N=!1)}function ln(a,b){a.U&&(a.Pb.unshift(b),a.H=!0,Hn(a.U,b))} +function cn(a){if(a.Pb.length&&a.H){var b=a.Pb[0];a.U&&Hn(a.U,b)}}function Tm(a){var b=0;a.Pb.length&&(b=a.Pb[0]);return b}function Jn(a,b){0>=1);if(b&Co){if(!1===d)return!0;d=null}null==d?d=!((c?a.C:a.Vb)&b):d||b&Do&&(b=Do);if(c){a.C&=~b;d&&(a.C|=b);c=b;var f,g;for(g in Eo)d="led-"+g,e=Eo[g],c&&c!=e||!(f=a.ja[d])||(f.style.backgroundColor=a.C&e?"#00ff00":"#000000")}else a.Vb&=~b,d&&(a.Vb|=b);return!0}}return!1} +function oo(a,b,c){if((W[b]||W[b+=1E3])&&a.R&&a.R.Y.cb){Ao[b]&&a.A.length&&0e||(e==a.A.length&&(d={},d.Xd=b,d.Vb=a.Vb,wo(a,b,!0),e++),0b.bd){if(!b.Ie){vo(a,b.Xd);return}b.Ie=!1;var c=a.ia}else c=1==b.bd++?500:100;b.mh=setTimeout(function(a){return function(){Fo(a,b)}}(a),c)}} +function Ho(a,b,c){var d=b;if(b>=n.Fd&&b<=n.pf)!(a.Vb&(Io|Jo|Ko))==c&&(d=b+(n.fd-n.Fd));else if(b>=n.fd&&b<=n.z)!!(a.Vb&(Io|Jo|Ko))==c&&(d=b-(n.fd-n.Fd));else if(!!(a.Vb&(Io|Jo))==c){if(a=p[b])d=a}else if(a=pa[b])d=a;return d}l.Pf=function(a){a||(this.Vb&=~Do)}; +function lo(a,b,c){var d=!0,e=!1,f=!1,g=b.keyCode;if(!mo(a.na))return!1;a.B="";nb(a.Dd);var h=Ho(a,g,!0);a.ig&&h==n["`"]&&(g=h=27);if(W[g+1E3])if(h+=1E3,2==b.location&&(h+=2E3),to(a,h,!1,c)){if(20==g||144==g||145==g)a.ba||(c=e=!0);if(!(c||91!=g&&93!=g))for(var k=0;k=n.Fd&&b<=n.pf||b>=n.fd&&b<=n.z;e>>>=8;){var g=0,h=e&255;f==Uo||f==Vo?d.push(f|(c?0:To)):(h==X?a.C&(Io|Jo)||a.C&Ko&&b||(g=h):h==Wo?a.C&(Lo|Xo)||(g=h):h==Yo?a.C&(Mo|Zo)||(g=h):d.push(f|(c?0:To)),g&&(c?d.unshift(g):d.push(g|To)))}for(c=0;c"]]=52|X<<8;W[n["/"]]=53; +W[n["?"]]=53|X<<8;W[3016]=54;W[1044]=55;W[1018]=Yo;W[1032]=57;W[po]=58;W[1112]=59;W[1113]=60;W[1114]=61;W[1115]=62;W[1116]=63;W[1117]=64;W[1118]=65;W[1119]=66;W[1120]=67;W[1121]=68;W[qo]=69;W[ro]=70;W[1036]=71;W[1038]=72;W[1033]=73;W[1109]=74;W[1037]=75;W[1101]=76;W[1039]=77;W[1107]=78;W[1035]=79;W[1040]=80;W[1034]=81;W[1045]=82;W[1046]=So;W[4027]=84;W[1122]=87;W[1123]=88;W[1091]=91;W[1093]=93;W[1224]=91;W[bp]=46|Wo<<8;W[No]=70|Wo<<8;W[4046]=So|Wo<<8|Yo<<16;W[4045]=82|Wo<<8|Yo<<16; +W[4013]=28|Wo<<8|Yo<<16;var jn=255,nn=243,on=237,mn=170,kn=250,ap=255,$o=20;Sa(function(){for(var a=jb(document,"pcx86","keyboard"),b=0;bc.length)c=[!1,0,null,null,0,Array(b>2,32768));this.dc=c[0];this.Ec=c[1];this.af=c[2];this.Z=c[3];this.oc=c[4]&255;this.Sf=c[4]>>8&255;this.Ua=c[5];this.pg=ep;this.Bd=this.Ua[gp]|this.Ua[hp]<<8;this.rf=63;if(b>=Tn){this.rf=255;this.pg=fp;b=c[6];void 0===b&&(b=[!1,0,Array(ip),0,f== +hk?0:jp,0,0,Array(kp),0,0,0,Array(lp),0,[this.ab,this.Hb,this.Yc],Array(this.Yc>>2),mp|np|op|pp|qp,0,-1,0,-1,0,-1,0,0,0,0,rp,sp,0,0,tp,Array(up)]);this.He=b[0];this.Sd=b[1];this.vc=b[2];this.ih=b[3];this.bf=b[4];this.Vf=b[5];this.Vd=b[6];this.Ud=b[7];this.Ij=b[8];this.Jj=b[9];this.Td=b[10];this.od=b[11];this.pb=b[12];d=b[13];"number"==typeof d&&(d=[this.ab,this.Hb,d]);this.ab=d[0];this.Hb=d[1];d=this.Yc>>2;if((this.ud=b[14])&&this.ud.length=Tn){var c=[];c[0]=a.He;c[1]=a.Sd;c[2]=a.vc;c[3]=a.ih;c[4]=a.bf;c[5]=a.Vf;c[6]=a.Vd;c[7]=a.Ud;c[8]=a.Ij;c[9]=a.Jj;c[10]=a.Td;c[11]=a.od;c[12]=a.pb;c[13]=[a.ab,a.Hb,a.Yc];var d;if(d=a.ud){var e=0,f=[];if(void 0!==d[0])for(var g=0;2>g;g++)for(var h=g;h>1;f[e++]=k;h=m}f.length=Tn){var d=0,e=0,f=0;switch(b){case Cp:d=Dp;a.Oa==Vn&&(e=Ep);break;case Fp:a.Oa==Tn&&(d=Gp);break;case Hp:d=Ip;a.Oa==Vn&&(e=Jp);break;case Kp:d=Lp;a.Oa==Vn&&(e=Mp);break;case Np:d=Op;a.Oa==Vn&&(f=Pp);break;case Qp:d=Rp,a.Oa==Vn&&(f=Sp)}d&&(c|=a.Ua[Tp]&d?256:0,c|=a.Ua[Tp]&e?512:0,c|=a.Ua[Up]&f?512:0)}return c} +var hp=12,gp=13,ep=18,Cp=6,Tp=7,Dp=1,Lp=2,Ip=4,Op=8,Rp=16,Gp=32,Ep=32,Mp=64,Jp=128,Up=9,Pp=32,Sp=64,Fp=10,Hp=16,Kp=18,Np=21,Qp=24,fp=25,Vp={},Wp=(Vp[0]=255,Vp[1]=255,Vp[2]=255,Vp[3]=15,Vp[4]=127,Vp[5]=31,Vp[6]=127,Vp[7]=127,Vp[8]=3,Vp[9]=31,Vp[10]=127,Vp[11]=31,Vp[hp]=63,Vp[gp]=255,Vp[14]=63,Vp[15]=255,Vp[16]=63,Vp[17]=255,Vp),ip=20,jp=1,rp=1,kp=5,sp=255,tp=0,up=256,lp=9,mp=1024,np=4096,yp=65280,op=0,pp=16,Ap=255,qp=-2147483648,vp=[];vp[2]=mp;vp[3]=mp|np;vp[16]=1280;vp[512]=op;vp[1024]=op|32; +vp[1536]=op|96;vp[2560]=op|160;vp[3584]=op|224;vp[768]=op|pp;vp[4096]=1;vp[8192]=2;vp[24576]=98;vp[40960]=162;vp[57344]=226;var zp=[];zp[mp]=function(a){a+=this.G;return(this.controller.pb=this.S[a])>>this.controller.eh&255};zp[mp|16384]=function(a){return(this.controller.pb=this.S[(a&-4)+this.G])>>((a&3)<<3)&255};zp[mp|np]=function(a){a+=this.G;var b=this.controller.pb=this.S[a&-2];return(a&1?b>>8:b)&255}; +zp[1280]=function(a){a+=this.G;a=this.controller.pb=this.S[a];for(var b=this.controller.rg,c=this.controller.qg&b,d=0,e=128;e;)(a&b)==c&&(d|=e),c>>>=1,b>>>=1,e>>=1;return d};zp[op]=function(a,b){a+=this.G;b=(b|b<<8|b<<16|b<<24)&this.controller.md|this.controller.Ad;b=b&this.controller.ub|this.controller.pb&~this.controller.ub;b=b&this.controller.Ya|this.S[a]&~this.controller.Ya;this.S[a]!=b&&(this.S[a]=b,this.Fa=!0)}; +zp[op|32]=function(a,b){a+=this.G;b=b>>this.controller.Ac|b<<8-this.controller.Ac&255;b=(b|b<<8|b<<16|b<<24)&this.controller.md|this.controller.Ad;b=b&this.controller.ub|this.controller.pb&~this.controller.ub;b=b&this.controller.Ya|this.S[a]&~this.controller.Ya;this.S[a]!=b&&(this.S[a]=b,this.Fa=!0)}; +zp[op|96]=function(a,b){a+=this.G;b=b>>this.controller.Ac|b<<8-this.controller.Ac&255;b=(b|b<<8|b<<16|b<<24)&this.controller.md|this.controller.Ad;b&=this.controller.pb;b=b&this.controller.ub|this.controller.pb&~this.controller.ub;b=b&this.controller.Ya|this.S[a]&~this.controller.Ya;this.S[a]!=b&&(this.S[a]=b,this.Fa=!0)}; +zp[op|160]=function(a,b){a+=this.G;b=b>>this.controller.Ac|b<<8-this.controller.Ac&255;b=(b|b<<8|b<<16|b<<24)&this.controller.md|this.controller.Ad;b|=this.controller.pb;b=b&this.controller.ub|this.controller.pb&~this.controller.ub;b=b&this.controller.Ya|this.S[a]&~this.controller.Ya;this.S[a]!=b&&(this.S[a]=b,this.Fa=!0)}; +zp[op|224]=function(a,b){a+=this.G;b=b>>this.controller.Ac|b<<8-this.controller.Ac&255;b=(b|b<<8|b<<16|b<<24)&this.controller.md|this.controller.Ad;b^=this.controller.pb;b=b&this.controller.ub|this.controller.pb&~this.controller.ub;b=b&this.controller.Ya|this.S[a]&~this.controller.Ya;this.S[a]!=b&&(this.S[a]=b,this.Fa=!0)};zp[op|4]=function(a,b){var c=(a&-4)+this.G;a=(a&3)<<3;b=b<>this.controller.Ac|b<<8-this.controller.Ac&255;b=(b|b<<8|b<<16|b<<24)&this.controller.ub;b=this.controller.Ve&b|this.controller.pb&~b;b=b&this.controller.Ya|this.S[a]&~this.controller.Ya;this.S[a]!=b&&(this.S[a]=b,this.Fa=!0)}; +function Y(a,b,c,d,e){u.call(this,"Video",a);var f=this,g;this.Oc=La("Gecko/");this.ca=a.model;var h=Yp[this.ca]||Yp.mda;this.Oa=h[0];this.Yc=a.memory||0;this.Uc=a.switches;this.Lb=a.randomize;null==this.Lb&&(this.Lb=1);this.ba=a.mode;if(null==this.ba||null==Zp[this.ba])this.ba=h[1];this.Jb=a.charCols;this.sc=a.charRows;if(void 0===this.Jb||void 0===this.sc)this.Jb=Zp[this.ba][0],this.sc=Zp[this.ba][1];this.X=a.screenWidth;this.ia=a.screenHeight;this.Qc=a.scale;this.rd=12<=Math.round(this.X/this.Jb); +this.M=b;this.J=c;this.F=(this.Df=d)||b||null;this.Yb=a.screenColor||"black";this.Tc=(1-(Oa("flicker")||a.flicker||0)).toString();this.Eb=!1;b&&(b.style.backgroundColor=this.Yb);e&&(e.style.backgroundColor=this.Yb);b=a.smoothing;(c=Oa("smoothing"))&&(b="true"==c);null!=b&&(g=Ma(this.J,"imageSmoothingEnabled"))&&(this.J[g]=b);this.Vc=a.touchScreen;this.gb=$p;this.K=null;this.qd=a.autoLock;this.ab=this.Hb=0;this.qa=[];this.fa=Array(this.Oa==Vn?256:16);this.Ga=!1;if(this.N=e)if(g=Ma(e,"requestFullscreen")|| +Ma(e,"requestFullScreen")){this.N.A=e[g];if(e=Ma(document,"on","fullscreenchange")){var k=Ma(document,"fullscreenElement")||Ma(document,"fullScreenElement");document.addEventListener(e,function(){aq(f,!!k)},!1)}(e=Ma(document,"on","fullscreenerror"))&&document.addEventListener(e,function(){aq(f,null)},!1)}if(this.F&&(this.F.onfocus=function(){return f.Pf(!0)},this.F.onblur=function(){return f.Pf(!1)},this.F.Md=(g=Ma(this.F,"requestPointerLock"))&&this.F[g],this.F.B=(g=Ma(this.F,"exitPointerLock"))&& +this.F[g],this.F.Md&&(e=Ma(document,"on","pointerlockchange")))){var m=Ma(document,"pointerLockElement");document.addEventListener(e,function(){f.Xe(!(!m||document[m]!==f.F))},!1)}(this.xa=a.fontROM)&&"json"!=ta(this.xa)&&(this.xa=Fa()+"/api/v1/dump?file="+this.xa+"&format=bytes")}ja(Y,u);l=Y.prototype; +l.jc=function(a,b,c,d){var e=this;this.oa=b;this.R=c;this.Ea=d;c=+Mc(a,"randomize");0<=c&&1>=c&&(this.Lb=c);c=(c=Yp[this.ca])&&c[0];c!==bq&&(kc(b,this,cq),mc(b,this,dq));c!==eq&&(kc(b,this,fq),mc(b,this,gq));this.Oa>=Tn&&(kc(b,this,hq),mc(b,this,iq));this.Oa==Vn&&(kc(b,this,jq),mc(b,this,kq));if((this.C=Ab(a,"Keyboard"))&&this.M){for(var f in this.ja)0c&&(a=Math.round(c/b*100)+"%")}d.Oc?(d.M.style.width=a,d.M.style.width=a,d.M.style.display="block",d.M.style.margin="auto"):(d.N.style.width=a,d.N.style.height="auto");d.N.style.backgroundColor=d.Yb;d.N.A()}d.F&&d.F.focus()}}:c.parentNode.removeChild(c), +!0;case "lockPointer":return this.td=c.textContent,this.F&&this.F.Md?c.onclick=function(){d.Md(!0)}:c.parentNode.removeChild(c),!0;case "refresh":return c.onclick=function(){qq(d,!0)},!0}return!1};function aq(a,b){!b&&a.N&&(a.Oc?a.M.style.width=a.M.style.height="":a.N.style.width=a.N.style.height="");a.C&&(a.C.ig=b)}l.Md=function(a){var b=!1;this.F&&(a?this.F.Md&&(this.F.Md(),this.K&&this.K.Xe(!0),b=!0):this.F.B&&(this.F.B(),this.K&&this.K.Xe(!1),b=!0),this.F&&this.F.focus());return b}; +l.Xe=function(a){this.K&&(this.K.Xe(a),this.C&&(this.C.ig=a));var b=this.ja.lockPointer;b&&(b.textContent=a?"Press Esc to Unlock Pointer":this.td)};function lq(a,b){var c=a.F;c&&!a.gb&&(a.gb=b,c.addEventListener("touchstart",function(b){Pn(a.U,b);a.gb!=oq&&sq(a,b,!0)},!1),b!=oq&&(c.addEventListener("touchmove",function(b){sq(a,b)},!0),c.addEventListener("touchend",function(b){sq(a,b,!1)},!1),a.mb=a.rb=a.dd=-1,a.lc=!1,a.Cb=null,a.kc=!1,a.sd=function(){a.kc=!0;a.K.ie(tq,!0)}))} +l.Pf=function(a){this.C&&this.C.Pf(a)}; +function sq(a,b,c){var d=0,e=0;var f=a.M;do isNaN(f.offsetLeft)||(d+=f.offsetLeft,e+=f.offsetTop);while(f=f.offsetParent);var g=a.X/a.M.offsetWidth,h=a.ia/a.M.offsetHeight;if(b.targetTouches&&b.targetTouches.length){f=b.targetTouches[0].pageX;var k=b.targetTouches[0].pageY}else f=b.pageX,k=b.pageY;f=(f-d)*g;k=(k-e)*h;if(a.gb==nq)c&&oo(a.C,uq[k/(a.ia/3)|0][f/(a.X/3)|0],!0);else if(a.K){e=a.lc;d=b.timeStamp-a.dd;!0===c?(a.lc=500d){a.K.ie(tq,!0);a.K.ie(tq,!1);return}}if(c||0>a.mb||0>a.rb)a.mb=f,a.rb=k;c=Math.round(f-a.mb);b=Math.round(k-a.rb);a.mb=f;a.rb=k;a.K.mg(c,b,a.mb,a.rb)}}l.Rb=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Qb=function(a){return a?this.save():!0}; +l.reset=function(){var a=0;this.U&&(a=+gk(this.U,zj,void 0));this.ca||(this.Oa=a==hk?eq:bq);this.ba=vq;switch(this.Oa){case Vn:a=7;break;case Tn:var b=wq[this.wb];b&&(a=b[0]);a||(a=4);break;case eq:a=hk;this.ba=xq;break;default:a=2}this.da!==a&&(this.da=a);this.B=null;this.W=this.Wb=new cp(this,eq);this.I=this.Db=new cp(this,bq);this.Oa>1&255;c=c>>8&~Bq;c>>4==(c&15)&&(c^=15)}else d=c&255,c=(c&256?Cq|Dq:Eq|Fq)|Gq&c>>8;ic(this.oa,b,d|c<<8)}qq(this,!0)}};function yq(a){a.A.bf&jp?(a.W=a.Wb,a.I=a.A):(a.W=a.A,a.I=a.Db)}l.save=function(){var a=new Qe(this);a.set(0,xp(this.Wb));a.set(1,xp(this.Db));a.set(2,[this.da,this.ba,this.ma]);a.set(3,xp(this.A));return a.data()}; +l.restore=function(a){var b=a[2];this.da=b[0];this.ba=b[1];this.ma=b[2];this.B=null;this.W=this.Wb=new cp(this,eq,a[0]);this.I=this.Db=new cp(this,bq,a[1]);this.A=new cp(this,this.Oa,a[3],this.Yc);this.A.dc&&yq(this);zq(this);if(!Hq(this))return!1;Iq(this);return!0}; +function pq(a,b,c,d){if(d)a.wa("Unable to load font ROM (error "+d+": "+b+")",0>d);else{ab(a.Dd,b,c);try{var e=eval("("+c+")"),f=e.bytes||e;if(!f.length){q("Empty font ROM: "+b);return}if(1==f.length){q(f[0]);return}if(8192==f.length)Un(a,f,[6144,0]);else if(2048==f.length)Un(a,f,[0]);else{a.wa("Unrecognized font data length ("+f.length+")");return}}catch(g){a.wa("Font ROM data error: "+g.message);return}(a.J||a.Ea)&&v(a)}} +function Jq(a,b){if(1==b)return a.fa[0]=Kq[Eq],a.fa[1]=Kq[Cq],a.fa;if(2==b){var c=a.B.af;if(a.B===a.A){var d=a.A.vc[0];c=d&7;d&16&&(c|=8);18!=a.A.vc[1]&&(c|=32)}a.fa[0]=Kq[c&15];c=c&32?Lq:Mq;for(d=0;de;e++){var f=d[e]||0;var g=f<<2&252;var h=f>>4&252;f=f>>10&252;a.fa[e]=[g,h,f,255]}else{var k=d&&d[255];b=null!=c.vc[15]?c.vc:Nq;for(e=0;16>e;e++)f=b[e]& +63,k?(f|=(c.vc[20]&12)<<4,c.vc[16]&128&&(f&=-49,f|=(c.vc[20]&3)<<4),f=d[f],g=f<<2&252,h=f>>4&252,f=f>>10&252):(g=(f&4?170:0)|(f&32?85:0),h=(f&2?170:0)|(f&16?85:0),f=(f&1?170:0)|(f&8?85:0)),a.fa[e]=[g,h,f,255]}a.Ga=!0}return a.fa}function Un(a,b,c,d){a.vb=b;a.Qa=c;a.Ca=d} +function zq(a,b){var c=!1;if(window&&a.vb&&(!b||a.G)){var d=0,e=a.Ca?a.Ca:8,f=Jq(a);null!=a.Qa[0]&&Oq(a,Pq,a.Qa[0],d,e,8,a.vb,f)&&(c=!0);d=a.Ca?0:2048;e=a.Ca?a.Ca:9;null!=a.Qa[1]&&(Oq(a,Qq,a.Qa[1],d,e,14,a.vb,Rq,Sq)&&(c=!0),a.Ca&&Oq(a,a.Oa,a.Qa[1],0,a.Ca,14,a.vb,f)&&(c=!0))}b||(a.aa=-1,a.za=-1,a.ra=0);return c}function Oq(a,b,c,d,e,f,g,h,k){var m=!1;null!=c&&(Tq(a,b,c,d,e,f,g,h,k)&&(m=!0),a.rd&&Tq(a,b<<1,c,d,e,f,g,h,k)&&(m=!0));return m} +function Tq(a,b,c,d,e,f,g,h,k){var m=!1,r=b&1?0:1,x=a.qa[b],t=16>h.length?h.length:16;x||(x={qc:e<Uf||!sc?Uf:8,bi=Pm.createImageData(m.qc,m.rc);for(K=0;256>K;K++){for(z=0;z=Uf-2,bu=Zt[z>(8<=O&&192<=K&&223>=K?7:O)?ca:$t;Uq(bi,Qm,Rm,Sm);na&&Uq(bi,Qm+1,Rm,Sm)}Pm.putImageData(bi,(K&15)*m.qc,(K>>4)*m.rc)}m.be[E]="#"+ra(ca[0],2)+ra(ca[1],2)+ra(ca[2],2);m.Qh[E]=ca;m.cg[E]=Vf;m=!0}}a.qa[b]=x;return m}function Vq(a){0a.za&&(a.za=0):a.za=-1} +function Iq(a){if(a.G){for(var b=10;15>=b;b++)if(null==a.B.Ua[b])return;var c=a.B.Ua[10];b=c&31;var d=a.B.Ua[11]&Wp[11],e=a.B.Ua[9]&Wp[9],f=!1;a.B===a.A&&(f=!0,7!=e||4!=b||d||(d=7));if(c&32||b>d&&!f||b>e)Wq(a);else{c=a.B.Ua[15];c|=(a.B.Ua[14]&a.B.rf)<<8;a.aa!=c&&(Wq(a),a.aa=c);d=d-b+1;if(a.Wc!=b||a.Ic!=d)a.Wc=b,a.Ic=d;a.ua=e+1;Vq(a)}}} +function Wq(a){if(0<=a.aa){if(void 0!==a.L){var b=Xq<<8,c=a.L[a.aa];if(c&b){c&=~b;b=a.aa%a.D;var d=a.aa/a.D|0;a.G&&a.qa[a.G]&&(a.Ba&&Yq(a,b,d,c,a.Ba),Yq(a,b,d,c));a.L[a.aa]=c}}a.aa=-1}} +function Zq(a){var b=a.B;a.Nc=!1;var c=b.od[5];if(null!=c){var d=mp;var e=op,f=b.od[3]&31;switch(c&3){case 0:if(f){e=op|32;switch(f&24){case 8:e=op|96;break;case 16:e=op|160;break;case 24:e=op|224}b.Ac=f&7}break;case 1:e=1;break;case 2:switch(f&24){default:e=2;break;case 8:e=98;break;case 16:e=162;break;case 24:e=226}break;case 3:a.Oa==Vn&&(e=3,b.Ac=f&7)}c&8&&(d=1280);b=b.Ud[4];null!=b&&(b&4||(d|=np,e|=pp),c&64&&(b&8&&(d|=16384,e|=4),a.Nc=!0));d|=e}return d} +function $q(a,b){var c=a.B;return c&&null!=b&&b!=c.og?(c.Xf(b),a.oa.Xf(c.ab,c.Hb,c.kg(),!0),!0):!1} +function Hq(a,b){var c=a.ma,d=a.B;if(d)if(d.Oa==eq)c=xq;else if(d.Oa>=Tn){c=null;var e=d.Yc>>2,f=32768=d.Ua[Kp]?er:fr:gr:f&128|| +350>e?c=m?hr:ir:480<=e&&(c=a.da==hk?jr:kr):c=m?7-c:lr:c-=m?2:0);h=Zq(a)}}else d.Ec&8?(d.Ec&2?(c=d.Ec&16?lr:mr,d.Ec&4||--c):(c=d.Ec&1?vq:nr,d.Ec&4&&--c),a.Eb&&(a.M.style.opacity="1",a.Eb=!1)):!a.Eb&&1>+a.Tc&&(a.Eb=!0,a.M.style.opacity=a.Tc,d=a.R,d.Y.Yf=!0,Qc(d));else a.ma=null,null==c&&(c=a.ba);if(!Aq(a,c,b))return!1;$q(a,h);return!0} +function Aq(a,b,c){if(null!=b&&(b!=a.ma||c)){a.pd=0;a.ma=b;a.Ga=!1;b=a.B||(b==xq?a.W:a.I);if(b!=a.B||b.ab!=a.ab||b.Hb!=a.Hb){Wq(a);if(a.ab){if(!ac(a.oa,a.ab,a.Hb))return!1;a.B&&(a.B.dc=!1)}a.B=b;b.dc=!0;a.ab=b.ab;a.Hb=b.Hb;if(!Qb(a.oa,b.ab,b.Hb,3,b===a.A?b:null))return!1}a:{a.G=0;a.D=a.Jb;a.H=a.sc;a.Ma=a.D;a.Gb=Zp[xq][2];b=0;if(c=Zp[a.ma])a.D=c[0],a.H=c[1],a.Gb=c[2],b=c[3],a.G=c[4],4!=a.da&&7!=a.da||a.B!==a.A||a.G!=Pq||(7==(a.A.Ua[Up]&31)?a.H=350>Bp(a.A,Kp)?43:50:a.G=a.Oa);a.Sc=a.D*a.H|0;a.Rc=a.Sc/ +a.Gb|0;a.Sa=a.Rc;a.Xb=0;void 0!==b&&(a.Sa=(a.Sa<<1)+b|0,a.Xb=a.Sa+b>>1);if(a.qa.length){a.ka=a.X/a.D|0;a.pa=a.ia/a.H|0;if(a.G){b=a.qa[a.G];if(!b)break a;c=a.qa[a.G<<1];a.Qc&&80==a.D?c&&a.ka>=3*c.qc>>2&&(a.G<<=1,b=c):(c&&a.ka>=c.qc&&(a.G<<=1,b=c),a.Qc||(a.ka=b.qc,a.pa=b.rc));a.eb=a.fb=0;b&&(a.eb=a.D*b.qc,a.fb=a.H*b.rc)}else a.ka=a.pa=1,a.eb=a.D,a.fb=a.H;a.La=a.J.createImageData(a.eb,a.fb);a.Aa=document.createElement("canvas");a.Aa.width=a.eb;a.Aa.height=a.fb;a.Ba=a.Aa.getContext("2d");a.uc=a.Dc=0; +a.ec=a.X;a.fc=a.ia;b=a.X-a.D*a.ka;c=a.ia-a.H*a.pa;0>1,a.ec-=b);0>1,a.fc-=c);if(b||c)a.J.fillStyle=a.M.style.backgroundColor,a.J.fillRect(0,0,a.X,a.ia)}}or(a,!0);qq(a)}return!0}function Uq(a,b,c,d){b=(b+c*a.width)*d.length;a.data[b]=d[0];a.data[b+1]=d[1];a.data[b+2]=d[2];a.data[b+3]=d[3]}function pr(a){a.ra=-1;a.Da=!1;var b=a.Rc;if(void 0===a.L||a.L.length!=b)a.L=Array(b)}function or(a,b){b||(a.Ga=!1);pr(a)} +function Yq(a,b,c,d,e){var f=d&255,g=d>>8;d=g&15;var h=a.qa[a.G];h.Ee&&(d=h.Ee[d]);var k=g>>4&15;h.Ee&&(k=h.Ee[k]);e?(b*=h.qc,c*=h.rc,e.fillStyle=h.be[k],e.fillRect(b,c,h.qc,h.rc)):(b=b*a.ka+a.uc,c=c*a.pa+a.Dc,a.J.fillStyle=h.be[k],a.J.fillRect(b,c,a.ka,a.pa));g&qr&&(k=(f&15)*h.qc,f=(f>>4)*h.rc,e?e.drawImage(h.cg[d],k,f,h.qc,h.rc,b,c,h.qc,h.rc):a.J.drawImage(h.cg[d],k,f,h.qc,h.rc,b,c,a.ka,a.pa));g&Xq&&(f=a.Wc,g=a.Ic,e?(a.ua&&a.ua!==h.rc&&(f=f*h.rc/a.ua|0,g=g*h.rc/a.ua|0),e.fillStyle=h.be[d],e.fillRect(b, +c+f,h.qc,g)):(a.ua&&a.ua!==a.pa&&(f=f*a.pa/a.ua|0,g=g*a.pa/a.ua|0),a.J.fillStyle=h.be[d],a.J.fillRect(b,c+f,a.ka,g)))} +function qq(a,b){b=void 0===b?!1:b;if(a.Y.Sb){var c=!1,d=a.B;d&&(d!==a.A?d.Ec&8&&(c=!0):d.Sd&32&&(c=!0));if(c||b){if(b)pr(a);else if(void 0===a.L)return;c=!1;!(b||++a.pd&15)&&0<=a.za&&(a.za++,c=!0);var e=a.Sc,f=a.ab,g=f,h=g+a.Hb;a.ma>=er&&(f=g=655360,h=g+65536);if(rr(a,d)&8||d.We&&d.We=Tn&&d.Ua[19]&&d.Ua[19]<<1!=d.Ua[1]+1&&(a.Ma=d.Ua[19]<<(a.G?1:d.Ua[20]&64?3:4),k=(a.Ma*(a.H-1)+a.D)/ +a.Gb|0,a.ma<=xq&&(k<<=1));var r=d=0;g+k>h&&(r=k,g>=h?(d=f+(g-h),k=0):(d=f,k=h-g,r-=k));h=a.aa-(m>>1);g=sr(a,f,g,k,0,h,e,b,c);r&&(g+=sr(a,f,d,r,0+g,h,e,b,c));g&&(a.Da=!0)}}} +function sr(a,b,c,d,e,f,g,h,k){var m=d>>1;m>g&&(m=g);var r=c+d;if(h=!h&&a.Da){h=a.oa;for(var x=!0,t=c>>>h.B,z=h.A-(c&h.C);0f)return m;c+=f<<1;e+=f;g=e+1}}if(a.G){if(a.qa[a.G]){b=c;c=e;k=f=e=0;h=qr<<8;d=1048575;t=a.B.Ec&32;a.Oa>=Tn&&(t=a.B.vc[16]&8);x=a.aa-a.B.Bd;t&&(k=Bq<<8,d&=~k,a.za&2||(d&=~h));for(a.ra=0;b>1;g=0;c=a.Gb;e=b;f=16==c?65536:196608;k=16==c?1:2;h=Jq(a,k);x=d=0;t=a.D;z=0;var E=a.H,O=0;for(a.ra=0;e>8|(K&255)<<8;var ca=f,na=16;d>=k))>>(na-=k);Uq(a.La,d++,x,h[sc])}d>z&&(z=d);x=O&&(O=x+1)}e+=2;g++;if(d>=a.D){d= +0;x+=2;if(x>a.H)break;x==a.H&&(x=1,e=b+a.Xb)}}ta.D?a.Ma-a.D-O>>3:0;for(a.ra=0;c>=8;k>x&&(x=k);h=z&&(z=h+1)}c+=E;if(k>=a.D){k=0;if(++h>a.H)break;c+= +K}}O&&(g=0)}else{m=0;g=r-c;e=Jq(a);f=a.B.ud;h=k=0;d=a.D;x=0;t=a.H;z=0;E=a.B.vc[19]&15;O=a.Ma>a.D?a.Ma-a.D-E>>3:0;for(a.ra=0;cca&&(na=ca)):(K<<=E,na-=E,a.Da=!1):(a.Da&&K===a.L[m]?(k+=na,na=0):a.L[m]=K,m++);if(na){kx&&(x=k);h=z&&(z=h+1)}if(k>=a.D){k=0;if(++h>a.H)break;c+=O}}E&&(g=0)}da&&(b.vg=a,a=-a|0);a%b.tg>b.Nl&&(c|=1);a%b.ug>b.Pl&&(c|=9);b.fh=a/b.ug|0;return c}l.il=function(){return ur(this.W)};l.Km=function(a,b){a=this.W;a.Sf=a.oc;a.oc=b&31};l.hl=function(){return vr(this.W)};l.Jm=function(a,b){wr(this,this.W,b)};l.jl=function(){return this.W.Ec};l.Lm=function(a,b){this.W.Ec=b;Hq(this,!1)};l.kl=function(){return xr(this,this.W)};l.zj=function(a,b){this.A.Vf=this.A.Vf&-4|b&3};l.Dk=function(){return this.A.Sd}; +l.ak=function(){return this.A.vc[this.A.Sd&31]};l.yj=function(a,b){a=this.A;var c=a.Sd&32;if(a.He){a.He=!1;var d=a.Sd&31;if(16<=d||!c)if(yr||a.vc[d]!==b)a.vc[d]=b,or(this,!1)}else a.Sd=b,a.He=!0,b&32&&!c&&zq(this,!0)&&qq(this,!0),b=a.Ua[gp],b|=(a.Ua[hp]&a.rf)<<8,a.Bd!=b&&(a.Bd=b,or(this)),a.We=0};l.ul=function(){var a=0;if(this.Oa==Tn)a=3-((this.A.bf&12)>>2),a=(this.wb&1<>this.A.wc&63;this.A.wc+=6;12Missing <canvas> support. Please try a newer web browser.";break}e.setAttribute("class","pcjs-canvas");e.setAttribute("width",d.screenWidth);e.setAttribute("height",d.screenHeight);e.style.height="auto";0<=Ga().indexOf("MSIE")&&(c.onresize=function(a,b,c,d){return function(){b.style.height=(a.clientWidth*d/c|0)+"px"}}(c, +e,d.screenWidth,d.screenHeight),c.onresize(null));var f=+(Oa("aspect")||d.aspect);f&&.3<=f&&3.33>=f&&(Ra("onresize",function(a,b,c){return function(){b.style.height=(a.clientWidth/c|0)+"px"}}(c,e,f)),window.onresize());c.appendChild(e);f=document.createElement("textarea");La("iOS")&&(f.setAttribute("autocapitalize","off"),f.setAttribute("autocorrect","off"),f.style.fontSize="16px");c.appendChild(f);var g=e.getContext("2d");d=new Y(d,e,g,f,c);ib(d,c)}}); +function zr(a){u.call(this,"ParallelPort",a);this.G=a.adapter;switch(this.G){case 1:this.D=956;this.C=7;break;case 2:this.D=888;this.C=7;break;case 3:this.D=632;this.C=5;break;default:q("Unrecognized parallel adapter #"+this.G);return}this.A=this.B=null;a=a.binding;"console"==a?this.B="":gb(this,a,Ar)}ja(zr,u);l=zr.prototype;l.Ab=function(a,b,c){switch(b){case Ar:return this.ja[b]=this.A=c,!0}return!1}; +l.jc=function(a,b,c,d){this.oa=b;this.R=c;this.Ea=d;this.U=Ab(a,"ChipSet");kc(b,this,Br,this.D);mc(b,this,Cr,this.D);v(this)};l.Rb=function(a,b){if(!b)if(!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Qb=function(a){return a?this.save():!0};l.reset=function(){Dr(this)};l.save=function(){var a=new Qe(this),b=0,c=[];c[b++]=this.F;c[b++]=this.Fb;c[b]=this.Fe;a.set(0,c);return a.data()};l.restore=function(a){return Dr(this,a[0])}; +function Dr(a,b){var c=0;void 0===b&&(b=[0,0,0]);a.F=b[c++];a.Fb=b[c++];a.Fe=b[c];return!0}l.Wk=function(){return this.F};l.tl=function(){return this.Fb};l.Sk=function(){return this.Fe}; +l.wm=function(a,b){this.F=b;this.Fb|=Er;a=!1;this.A&&(8==b?this.A.value=this.A.value.slice(0,-1):(this.A.value+=String.fromCharCode(b),this.A.scrollTop=this.A.scrollHeight),a=!0);if(null!=this.B){if(10==b||1024<=this.B.length)this.qb(this.B),this.B="";10!=b&&(this.B+=String.fromCharCode(b));a=!0}a&&(this.Fb&=~Er);Fr(this)};l.rm=function(a,b){this.Fe=b;Fr(this)};function Fr(a){a.U&&a.C&&(a.Fe&Gr&&!(a.Fb&Er)?Jf(a.U,a.C):Hf(a.U,a.C))} +var Ar="buffer",Er=64,Gr=16,Br={0:zr.prototype.Wk,1:zr.prototype.tl,2:zr.prototype.Sk},Cr={0:zr.prototype.wm,2:zr.prototype.rm};Sa(function(){for(var a=jb(document,"pcx86","parallel"),b=0;b=b)a.preventDefault&&a.preventDefault(),64");if(2==c.length){var d=xa(c[0]);if(d!=this.Be)return;c=xa(c[1]);if(this.F=mb(c)){var e=this.F.exports;if(e){var f=e.connect;f&&f.call(this.F,this.N);if(this.aa=e.receiveData){this.N=a;this.W=e.receiveStatus;this.status("Connected "+this.Dd+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}}; +l.Rb=function(a,b){if(!b)if(this.oi(this.N),!a||!this.restore)this.reset();else if(!this.restore(a))return!1;return!0};l.Qb=function(a){return a?this.save():!0};l.reset=function(){Pr(this)};l.save=function(){var a=new Qe(this),b=0,c=[];c[b++]=this.da;c[b++]=this.ia;c[b++]=this.G;c[b++]=this.L;c[b++]=this.D;c[b++]=this.J;c[b++]=this.X;c[b++]=this.A;c[b++]=this.B;c[b]=this.H;a.set(0,c);return a.data()};l.restore=function(a){return Pr(this,a[0])}; +function Pr(a,b){var c=0;void 0===b&&(b=[0,0,Qr,0,Rr,0,0,Lr|Mr,a.qa,[]]);a.da=b[c++];a.ia=b[c++];a.G=b[c++];a.L=b[c++];a.D=b[c++];a.J=b[c++];a.X=b[c++];a.A=b[c++];a.B=b[c++];a.H=b[c];return!0}l.ve=function(a){if(null!=a)if("number"==typeof a)this.H.push(a);else if("string"==typeof a)for(var b=0;b>8:this.L};l.dl=function(){var a=this.D;this.D|=Rr;return a};l.el=function(){return this.J};l.gl=function(){return this.X}; +l.fl=function(){return this.A};l.ll=function(){var a=this.B;this.B&=~(Tr|Ur);return a}; +l.Tm=function(a,b){if(this.J&Xr)this.G=this.G&-256|b;else{this.ia=b;this.A&=~(Lr|Mr);this.aa&&this.aa.call(this.F,b);if(this.C){if(13==b)this.K=0;else if(8==b)this.C.value=this.C.value.slice(0,-1),0":String.fromCharCode(b);c=a.length;32>b&&1==c&&(c=0);9==b&&(c=this.ma||8,c-=this.K%c,this.ma&&(a=" ".slice(0,c)));!this.K&&c&&(10!=this.pa&&(a="\n"+a),this.ka&&(a=String.fromCharCode(this.ka)+a)); +this.C.value+=a;this.C.scrollTop=this.C.scrollHeight;this.K+=c}this.pa=b}else if(null!=this.I){if(10==b||1024<=this.I.length)this.qb(this.I),this.I="";10!=b&&(this.I+=String.fromCharCode(b))}this.R&&Zc(this.R,this.ua,1E3/(1843200/((this.G||1)<<7))|0);Vr(this)}};l.Gm=function(a,b){this.J&Xr?this.G=this.G&255|b<<8:this.L=b};l.Hm=function(a,b){this.J=b}; +l.Im=function(a,b){a=b^this.X;this.X=b;a&(Yr|Zr)&&this.W&&(a=0,this.N?(a|=b&Zr?32:0,a|=b&Yr?320:0):(a|=b&Zr?16:0,a|=b&Yr?1048576:0),this.W.call(this.F,a))};function Vr(a){var b=-1;a.A&Wr&&a.L&$r?b=as:a.A&Lr&&a.L&bs?b=cs:a.B&(Tr|Ur)&&a.L&ds&&(b=es);0<=b?(a.D&=~(Rr|fs),a.D|=b,a.U&&a.M&&Jf(a.U,a.M,100)):(a.D|=Rr,a.U&&a.M&&Hf(a.U,a.M))} +var Kr="buffer",Qr=384,$r=1,bs=2,ds=8,Rr=1,as=4,cs=2,es=0,fs=6,Xr=128,Yr=1,Zr=2,Wr=1,Lr=32,Mr=64,Tr=1,Ur=2,Ir=16,Jr=32,Nr={0:Hr.prototype.ql,1:Hr.prototype.cl,2:Hr.prototype.dl,3:Hr.prototype.el,4:Hr.prototype.gl,5:Hr.prototype.fl,6:Hr.prototype.ll},Or={0:Hr.prototype.Tm,1:Hr.prototype.Gm,3:Hr.prototype.Hm,4:Hr.prototype.Im};Sa(function(){for(var a=jb(document,"pcx86","serial"),b=0;ba.A||0>a.B)a.A=b.screenX,a.B=b.screenY;a.M?(c=b.movementX||b.mozMovementX||b.webkitMovementX||0,d=b.movementY||b.mozMovementY||b.webkitMovementY||0):(c=b.screenX-a.A,d=b.screenY-a.B);a.A=b.screenX;a.B=b.screenY;a.mg(c,d,a.A,a.B)}} +l.ie=function(a,b){if(this.dc&&this.R&&this.R.Y.cb)switch(a){case tq:this.K!=b&&(this.K=b,rs(this));break;case ss:this.L!=b&&(this.L=b,rs(this))}};l.mg=function(a,b){this.dc&&this.R&&this.R.Y.cb&&(a=Math.round(Math.abs(a)*this.J)*Math.sign(a)||Math.sign(a),b=Math.round(Math.abs(b)*this.J)*Math.sign(b)||Math.sign(b),a||b)&&(this.H=a,this.I=b,rs(this))};function rs(a){a.F.ve([64|(a.K?32:0)|(a.L?16:0)|(a.I&192)>>4|(a.H&192)>>6,a.H&63,a.I&63]);a.H=a.I=0} +l.Zj=function(a){var b=1048592==(a&1048592);if(b){if(!this.dc){var c=!1;this.C&16||(this.reset(),c=!0);this.C&1048576||(c=!0);c&&this.F.ve([ts,ts]);ms(this);this.dc=b}}else this.dc&&(ns(this),this.dc=b);this.C=a};l.Jk=function(){return 0};l.Kk=function(){return 0};l.Ik=function(){return 0};l.Hk=function(){return 0};l.jm=function(){};l.km=function(){};l.im=function(){};l.hm=function(){}; +var is="bus",hs="serial",tq=0,ss=2,ks=572,js={0:gs.prototype.Jk,1:gs.prototype.Kk,2:gs.prototype.Ik,3:gs.prototype.Hk},ls={0:gs.prototype.jm,1:gs.prototype.km,2:gs.prototype.im,3:gs.prototype.hm},ts=77;Sa(function(){for(var a=jb(document,"pcx86","mouse"),b=0;b>2;var e=c=0;a=new DataView(a,0,b);g.A=Array(g.kb);for(b=0;bb.indexOf("/api/v1/dump")&&(a=ta(b),"json"==a||"gz"==a?f=encodeURI(b):"demandrw"==this.mode||"demandro"==this.mode?(f=As(this,b),this.Bf=!0):(c="path",d="&mbhd=10",!b.indexOf("http:")||!b.indexOf("ftp:")||0<="dsk ima img 360 720 12 144".split(" ").indexOf(a)?(c="disk",d= +"&mbhd=0"):ua(b,"/")&&(c="dir"),f=Fa()+"/api/v1/dump?"+c+"="+encodeURIComponent(b)+(this.me?"":d)+"&format=json"));var k="Loading "+f+"...";return!!Ea(f,null,!0,function(a,b,c){Bs(g,a,b,c)},function(){g.qb(k,tb)})}; +function Bs(a,b,c,d){var e=null;a.pe=!1;var f=!(!(0>d&&a.na)||a.na.Y.Sb);if(a.Bf)d?a.wa('Unable to connect to disk "'+a.F+'" (error '+d+": "+c+")",f):(a.C=!0,e=a);else if(d)a.wa('Unable to load disk "'+a.Pc+'" (error '+d+": "+b+")",f);else{ab(a.controller.Dd,b,c);try{if(0g&&0c.indexOf("0x")&& +'["'!=c.substr(0,2)?JSON.parse(c.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+c+")");if(h.length)if(1==h.length)q(h[0]);else{a.kb=h.length;a.$a=h[0].length;a.Xa=h[0][0].length;var k=h[0][0][0];a.ob=k&&k.length||512;for(d=c=0;d>=2;var r=k.pattern;void 0===r&&(r=k.pattern=0);var x=k.data;if(void 0===x){var t=k.bytes;if(void 0!==t&&t.length){for(var z=m<<2,E=t.length;E< +z;E++)t[E]=r;Cs(k,t,0)}else k.data=x=[],t&&(k.pattern=r|r<<8|r<<16|r<<24);delete k.bytes}zs(k,d,f);for(z=0;zg)break;e|=g<b&&(b=0);2E3>2,e=Array(d),f=0;f>=2;var e=a.data;a=a.pattern;for(var f=0;f>8&255;c[d++]=g>>16&255;c[d++]=g>>24&255}return c}l.read=function(a,b){var c=-1;if(a&&b>2;c=(d>((b&3)<<3)&255}return c}; +l.write=function(a,b,c){if(this.pe)return!1;if(b>2;b=(b&3)<<3;for(var g=d.length;g<=f;g++)d[g]=e;a.yc?f=a.Mc+a.yc&&(a.yc+=f-(a.Mc+a.yc)+1):(a.Mc=f,a.yc=1);d[f]=d[f]&~(255<=this.A.length||k>=this.A[h].length||m>=this.A[h][k].length){c="sector (CHS="+h+":"+k+":"+ +m+") out of range ("+b+" changes applied)";b=-1;break}if(this.pe){c="unable to modify write-protected disk";b=-1;break}e=g[f++];f=g[f++];g=e+f.length;if(h=this.A[h][k][m]){for(k=h.data.length;kb&&-2!=b&&this.wa("Unable to restore disk '"+this.Pc+": "+c);return b};var vs=0; +function Ls(a){u.call(this,"FDC",a);this.dmaRead=Ls.prototype.Tj;this.dmaWrite=Ls.prototype.Uj;this.dmaFormat=Ls.prototype.hk;this.M=Ms(a.autoMount);this.K=a.sortBy||"name";"none"==this.K&&(this.K=null);this.B=[];this.L=!La("Mobi")&&window&&"FileReader"in window;this.exports={loadDisk:this.vi,wait:this.yn}}ja(Ls,u);l=Ls.prototype; +l.Ab=function(a,b,c){var d=this;switch(b){case "listDisks":this.ja[b]=c;if(this.K){b=[];for(a=0;ag.sa.restore(z)&&(h=!1);h&&g.sa&&void 0!==g.Ra&&(g.Va=g.sa.seek(g.yb,g.Wa,g.bb));h||(d=!1)}a.H=b[c++]||0;a.F=b[c]||bt;return d} +function Ws(a){var b=0,c=[];c[b++]=a.Na;c[b++]=0;c[b++]=a.Z;c[b++]=a.G;c[b++]=a.D;c[b++]=a.C;c[b++]=a.I;for(var d=b++,e=0,f=[],g=0;g$s(a,e,b,c,!1,d);){if(!window.confirm("Click OK to reload the original disk and discard any changes."))return!1;var g=a,h=c;for(f=0;fa.kb||f[1]>a.$a)this.wa('Diskette "'+c+'" too large for drive '+String.fromCharCode(65+a.Na)),b=null}b?(a.sa=b,a.Kj=c,a.Wd=d,dt(this,d)||Ts(this,c,d),at(this,c,d,b),f=b.info(),this.H|=et,a.qe||this.wa('Mounted diskette "'+c+'" in drive '+String.fromCharCode(65+a.Na),a.Jd||e),a.Jf=f[0],a.Oe=f[1],a.Pe=f[2],this.na&&Yc(this.na)):a.le=!1;a.Jd&&(a.Jd=!1,--this.J||v(this));Os(this,a.Na);a.qe&&(a.qe(),a.qe=null)}; +function Ts(a,b,c,d){if((a=a.ja.listDisks)&&a.options){for(var e=0;e'+a+"");c.innerHTML=a}}l.yn=function(a){for(var b=0;b=this.C&&(this.Z&=~(ht|it),this.D=this.C=0);return a}; +l.ym=function(a,b){this.C=kt[a].gd){b=!1;this.D=0;a=lt(this);var c=a&jt;switch(c){case mt:lt(this);lt(this);nt(this);break;case ot:var d=lt(this);this.Na=d&3;var e=this.A[this.Na];nt(this);pt(this,(e.lb&qt)>>>24);break;case rt:case st:d=lt(this);b=d>>2&1;this.Na=d&3;e=this.A[this.Na];e.Wa=b;d=e.yb=lt(this);var f=lt(this);var g=e.bb=lt(this);var h=lt(this);e.xb=128<>2&1;this.Na=d&3;e=this.A[this.Na];d=e.yb; +f=e.Wa=b;g=e.bb=1;h=0;e.lb=vt;e.sa&&(e.Va=e.sa.seek(e.yb,e.Wa,e.bb))?h=e.Va.length>>8:e.lb=tt|ut;xt(this,e,a,b,d,f,g,h);b=!0;break;case Et:d=lt(this);b=d>>2&1;this.Na=d&3;e=this.A[this.Na];d=e.yb;f=e.Wa=b;g=1;h=lt(this);e.xb=128<>2& +1,d=lt(this),e.yb+=d-e.wd,0>e.yb&&(e.yb=0),e.yb>=e.kb&&(e.yb=e.kb-1),e.wd=d,e.lb=zt,e.yb||(e.lb|=At),nt(this),b=!0}0>>8);pt(a,(b.lb&Ht)>>>16);var k=0;if(e!=b.yb||f!=b.Wa)k=g=1;c&It&&(f^=k,d||(k=0));pt(a,e+k);pt(a,f);pt(a,g);pt(a,h)} +function lt(a){var b=a.G[a.D];a.D++;return b}function nt(a){a.D=a.C=0}function pt(a,b){a.G[a.C++]=b}l.Tj=function(a,b,c){if(void 0===b||0>b){b=-1;var d=null,e=0;if(!a.lb&&a.sa){do{if(a.Va&&(e=a.Ra,0<=(b=a.sa.read(a.Va,a.Ra++)))){d=a.Va;break}a.Va=a.sa.seek(a.yb,a.Wa,a.bb);if(!a.Va){a.lb=Jt|ut;break}a.Ra=0;Kt(a)}while(1)}c(b,!1,d,e)}else c(-1,!1)};l.Uj=function(a,b){return void 0!==b&&0<=b?Lt(a,b):-1}; +l.hk=function(a,b){if(void 0!==b&&0<=b)a:if(a.lb)a=-1;else{a.Gc[a.he++]=b;if(a.he==a.Gc.length){a.yb=a.Gc[0];a.Wa=a.Gc[1];a.bb=a.Gc[2];a.xb=128<Lt(a,a.Vh)){a=-1;break a}a.uf++}a.uf>=a.xd&&(b=-1);a=b}else a=-1;return a};function Lt(a,b){if(a.lb||!a.sa)return-1;do{if(a.Va&&a.sa.write(a.Va,a.Ra++,b))break;a.Va=a.sa.seek(a.yb,a.Wa,a.bb);if(!a.Va){a.lb=Mt|ut;b=-1;break}a.Ra=0;Kt(a)}while(1);return b} +function Kt(a){a.bb++;a.bb>=a.Pe+1&&(a.bb=1,a.Wa++,a.Wa>=a.Oe&&(a.Wa=0,a.yb++))}var Zs="Floppy Drive",ft=4,gt=8,it=16,ht=64,Xs=128,mt=3,ot=4,rt=5,st=6,yt=7,Bt=8,Dt=10,Et=13,Ft=15,jt=31,It=128,vt=0,tt=8,zt=32,ut=64,Ys=192,Ct=255,wt=512,Jt=1024,Mt=8192,Gt=65280,Ht=16711680,At=268435456,qt=-16777216,et=128,bt=0;aa={}; +var kt={3:{gd:3,yd:0,name:aa.Eo},4:{gd:2,yd:1,name:aa.Co},5:{gd:9,yd:7,name:aa.Io},6:{gd:9,yd:7,name:aa.yo},7:{gd:2,yd:0,name:aa.Ao},8:{gd:1,yd:2,name:aa.Do},10:{gd:2,yd:7,name:aa.zo},13:{gd:6,yd:7,name:aa.vo},15:{gd:3,yd:0,name:aa.Bo}},Rs={1009:Ls.prototype.Yk,1012:Ls.prototype.$k,1013:Ls.prototype.Xk,1015:Ls.prototype.Zk},Ss={1010:Ls.prototype.zm,1013:Ls.prototype.ym,1015:Ls.prototype.xm}; +Sa(function(){for(var a=jb(document,"pcx86","fdc"),b=0;bk.sa.restore(g)&&(z=!1),z&&void 0!==k.Ra&&(k.Va=k.sa.seek(k.Ed,k.Wa,k.bb+k.tf)));z||(e=!1);null!=a.W&&1>=d&&(a.W|=(f.type&3)<<(1-d<<1))}0<= +a.Na&&(a.B=a.A[a.Na]);return e} +function Ut(a){var b=0,c=[];a.L?(c[b++]=a.H,c[b++]=a.ra,c[b++]=a.I,c[b++]=a.da,c[b++]=a.ba,c[b++]=a.aa,c[b++]=a.N,c[b++]=a.Z,c[b++]=a.fa,c[b++]=[a.K,a.Na]):(c[b++]=a.W,c[b++]=a.Z,c[b++]=a.G,c[b++]=a.D,c[b++]=a.C,c[b++]=a.qa,c[b++]=a.ma,c[b++]=a.pa,c[b++]=a.M);for(var d=0,e=[],f=0;f=this.C&&(this.D=this.C=0,this.Z&=~(gu|hu|iu));return a}; +l.Vm=function(a,b){this.C=a&&(this.Z|=gu,this.Z&=~ku,lu(this))};l.Al=function(){var a=this.Z;this.D=a.B.ob?(a.Z=ou,nu(a.B,function(b){0<=b?(pu(a),a.U&&a.U.ca==Mj&&(a.Z=0),a.Z=a.Z|Vt|qu|ru):(a.Z=su,a.H=tu)},!1)):a.Z=Vt|qu));return b}l.Xj=function(){return mu(this)|mu(this)<<8};function uu(a,b){a.B&&a.B.xb>=a.B.ob&&(0>vu(a.B,b)?(a.Z=su,a.H=tu):(1==a.B.Ra||a.B.Ra==a.B.ob)&&1=a.B.ob&&(a.Z|=ru)))} +l.bm=function(a,b){uu(this,b&255);uu(this,b>>8&255)};l.Ck=function(){return this.H};l.gm=function(a,b){this.ra=b};l.Ek=function(){return this.I};l.em=function(a,b){this.I=b};l.Fk=function(){return this.da};l.fm=function(a,b){this.da=b};l.Ak=function(){return this.ba};l.am=function(a,b){this.ba=b};l.zk=function(){return this.aa};l.$l=function(a,b){this.aa=b};l.Bk=function(){return this.N};l.cm=function(a,b){this.N=b;this.Z=this.A[this.N&wu?1:0]?this.Z|Vt|qu:this.Z&~Vt}; +l.Gk=function(){var a=this.Z;this.Z&Vt&&(this.Z&=~ou);return a};l.Zl=function(a,b){this.fa=b;this.U&&Hf(this.U,14);xu(this)};l.dm=function(a,b){this.K&yu&&!(b&yu)&&(this.H=zu);this.K=b}; +function xu(a){var b=!1,c=a.fa,d=a.N&wu?1:0,e=a.N&Au,f=a.ba|(a.aa&Bu)<<8,g=a.da,h=a.I||256;a.Na=-1;a.B=null;a.H=Cu;a.Z=Vt|qu;var k=a.A[d];k?(k.Ed=f,k.Wa=e,k.bb=g,k.xb=h*k.ob,c=c>=Du?c:c&Eu,k.Va=null,k.Ra=0,k.errorCode=0,a.Na=d,a.B=k):c=-1;switch(c&Eu){case Fu:b=!0;break;case Gu:a.Z=ou;nu(k,function(b){0<=b&&a.U?(pu(a),a.Z=Vt|qu|ru):(a.Z=su,a.H=tu)},!1);break;case Hu:a.Z=ru;break;case Iu:b=!0;break;case Ju:b=!0;break;case Du:a.H=zu;b=!0;break;case Ku:k.$a=e+1,k.Xa=h,b=!0}b&&pu(a)} +function pu(a){a.U&&(a.K&Lu||Jf(a.U,14,120))} +function lu(a){a.D=0;var b=Mu(a),c=Mu(a),d=c&32,e=d>>5,f=c&31,g=Mu(a),h=Mu(a),k=g<<2&768|h,m=g&63,r=Mu(a),x=Mu(a),t=a.A[e];t&&(t.Ed=k,t.Wa=f,t.bb=m,t.xb=r*t.ob);switch(b){case Nu:Ou(a,t?t.errorCode:Pu);Qu(a,c);Qu(a,g);Qu(a,h);Qu(a,Ru|d);b=-1;break;case ju:for(c=0;0<=(b=Mu(a));)t&&cb?nu(a,c):c(-1,!1)};l.Wj=function(a,b){return void 0!==b&&0<=b?vu(a,b):-1}; +l.ik=function(a,b){void 0!==b&&0<=b?(a.Ravu(a,a.Vh)){a=-1;break a}a.uf++}a.uf>=a.xd&&(b=-1);a=b}else a=-1;return a}; +function Zu(a,b,c){b.errorCode=Pu;if(b.sa&&(b.Va=null,a.U)){b.errorCode=Xt;zl(a.U,3,a,"dmaRead",b);vl(a.U,3,function(a){a||b.errorCode!=Xt||(b.errorCode=Pu);c(b.errorCode?Su:Ru)});return}c(b.errorCode?Su:Ru)}function av(a,b,c){b.errorCode=Pu;if(b.sa&&(b.Va=null,a.U)){b.errorCode=Xt;zl(a.U,3,a,"dmaWrite",b);vl(a.U,3,function(a){a||(b.errorCode==Xt&&(b.errorCode=Pu),b.errorCode==dv&&(b.errorCode=Xt));c(b.errorCode?Su:Ru)});return}c(b.errorCode?Su:Ru)} +function cv(a,b,c){b.errorCode=Pu;b.de&&b.de.length==b.xb||(b.de=Array(b.xb));b.Ra=0;a.U?(b.errorCode=Xt,zl(a.U,3,a,"dmaWriteBuffer",b),vl(a.U,3,function(a){a||b.errorCode!=Xt||(b.errorCode=Pu);c(b.errorCode?Su:Ru)})):c(b.errorCode?Su:Ru)} +function nu(a,b,c){var d=-1,e=null,f=0;if(a.errorCode)return b&&b(d,!1,e,f),d;var g=!1!==c?1:0;if(a.Va&&(f=a.Ra,d=a.sa.read(a.Va,a.Ra),a.Ra+=g,0<=d))return e=a.Va,b&&b(d,!1,e,f),d;if(b){if(a.sa)return a.sa.seek(a.Ed,a.Wa,a.bb+a.tf,!1,function(c,k){(a.Va=c)?(e=c,f=a.Ra=0,ev(a),d=a.sa.read(a.Va,a.Ra),a.Ra+=g):a.errorCode=dv;b(d,k,e,f)}),d;a.errorCode=dv;b(d,!1,e,f)}return d} +function vu(a,b){if(a.errorCode)return-1;do{if(a.Va&&a.sa.write(a.Va,a.Ra++,b))break;a.sa&&a.sa.seek(a.Ed,a.Wa,a.bb+a.tf,!0,function(b){a.Va=b});if(!a.Va){a.errorCode=dv;b=-1;break}a.Ra=0;ev(a)}while(1);return b}function ev(a){a.bb++;var b=1-a.tf;a.bb>=a.Xa+b&&(a.bb=b,a.Wa++,a.Wa>=a.$a&&(a.Wa=0,a.Ed++))}l.Cl=function(){var a=this.R.L&255;!(this.R.F>>8)&&128>8||!this.U)||(a=!(this.U.ac[0].Xc&64));return a?!0:!1}; +var Yt="Hard Drive",eu=["XTC","ATC","COMPAQ"],cu=[{0:[306,2],1:[375,8],2:[306,6],3:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[940,8],5:[940,6],6:[615,4],7:[462,8],8:[733,5],9:[900,15],10:[820,3],11:[855,5],12:[855,7],13:[306,8],14:[733,7],16:[612,4],17:[977,5],18:[977,7],19:[1024,7],20:[733,5],21:[733,7],22:[733,5],23:[306,4]},{1:[306,4],2:[615,4],3:[615,6],4:[1023,8],5:[940,6],6:[697,5],7:[462,8],8:[925,5],9:[900,15],10:[980,5],11:[925,7],12:[925,9],13:[612,8],14:[980,4],16:[612,4],17:[980,5],18:[966, +6],19:[1023,8],20:[733,5],21:[733,7],22:[524,4,40],23:[924,8],24:[966,14],25:[966,16],26:[1023,14],27:[832,6,33],28:[1222,15,34],29:[1240,7,34],30:[615,4,25],31:[615,8,25],32:[905,9,25],33:[832,8,33],34:[966,7,34],35:[966,8,34],36:[966,9,34],37:[966,5,34],38:[612,16,63],39:[1023,11,33],40:[1023,15,34],41:[1630,15,52],42:[1023,16,63],43:[805,4,26],44:[805,2,26],45:[748,8,33],46:[748,6,33],47:[966,5,25]}],Rt=496,zu=1,Cu=0,tu=16,Bu=3,Au=15,wu=16,su=1,ru=8,qu=16,Vt=64,ou=128,Fu=16,Gu=32,Hu=48,Iu=64,Ju= +112,Du=144,Ku=145,Eu=240,Lu=2,yu=4,Ru=0,Su=2,Vu=0,Wu=1,Nu=3,Xu=5,Yu=8,$u=10,ju=12,bv=15,Tu=224,Uu=228,Xt=0,Pu=4,dv=20,Wt=0,ku=1,gu=2,hu=4,iu=8,fu=32,Ot={800:Z.prototype.zl,801:Z.prototype.Al,802:Z.prototype.yl},Nt={496:Z.prototype.Xj,497:Z.prototype.Ck,498:Z.prototype.Ek,499:Z.prototype.Fk,500:Z.prototype.Ak,501:Z.prototype.zk,502:Z.prototype.Bk,503:Z.prototype.Gk},Qt={800:Z.prototype.Vm,801:Z.prototype.Ym,802:Z.prototype.Xm,803:Z.prototype.Wm,807:Z.prototype.gh,811:Z.prototype.gh,815:Z.prototype.gh}, +Pt={496:Z.prototype.bm,497:Z.prototype.gm,498:Z.prototype.em,499:Z.prototype.fm,500:Z.prototype.am,501:Z.prototype.$l,502:Z.prototype.cm,503:Z.prototype.Zl,1014:Z.prototype.dm};Sa(function(){for(var a=jb(document,"pcx86","hdc"),b=0;b=this.D||(this.D=1);this.F=0;this.ma=a.busWidth||a.buswidth;this.A=hv;this.M=null;this.J=this.fa=!1;this.qa=Mc(this,"url")||"";this.ra=(Math.random()+.1).toString(36).substr(2,12);this.B=iv(this);if(this.R=hb("CPU",this.id)){this.Ea=hb("Debugger",this.id);this.C=[];for(b=null;b=Ab(this,"Video",b);)this.C.push(b);this.oa=new Nb({id:this.Dd+".bus",busWidth:this.ma}, +this.R,this.Ea);var e=lb(this.id);this.ba=(this.I=hb("Panel",this.id))&&this.I.ja.print;this.ia=this.wa;this.ka=this.print;this.pa=this.qb;this.ba&&(this.ia=this.I.wa,this.ka=this.I.print,this.pa=this.I.qb);for(b=0;b\nLicense: GPL version 3 or later "); +for(b=0;bhv){if(d.load(this.M)){this.G=new Qe(this,"1.37.1",sv);this.G.load()&&(a!=rv&&tv(this,d)&&(a=uv),vv(this.G));this.G.set(qv,za("Y-m-d H:i:s"));wv(this.G);var e=this.A&&!this.J;if(a==rv||cb("Click OK to restore the previous PCx86 machine state.")){if(c=pv(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?d.load(g):("error"==f&&"no machine state"!= +g?(this.wa("Error: "+g),"unable to verify user"==g&&(Ka(xv,""),this.B=null)):this.qb(f+": "+g),vv(d),d.load()?(c=pv(d),e=!0):c=!1))}e&&nv(this,c?d:null)}else a==uv&&d.clear()}else nv(this);delete this.M;delete this.N}e=lb(this.id);for(f=0;fa[1];a=a[2];if(d=this.ja.power)d.textContent="Shutdown";this.Y.Sb=!0;this.R&&(yv(this,this.R, +b,c,a),this.R.Gd());this.da&&(tv(this,b),b.clear());!c&&this.G&&(this.G.clear(),delete this.G);this.F=0;nb(this.Dd,Mc(this,"autoScript"))};function tv(a,b){if(!a.Y.Yd){if(cb("There may be a problem with your PCx86 machine.\n\nTo help us diagnose it, click OK to send this PCx86 machine state to http://www.pcjs.org.")){var c=a.B||"";b=b.toString();var d={app:"PCx86",ver:"1.37.1"};d.url=a.qa;d.user=c;d.type="bug";d.data=b;Ea("http://www.pcjs.org/api/v1/report",d,!0)}return!0}return!1} +function zv(a,b,c){var d="none";if(a.F)return null;a.F--;var e=new Qe(a,"1.37.1"),f=new Qe(a,"1.37.1",ov),g=za("Y-m-d H:i:s");f.set(qv,g);e.set(qv,g);e.set(Av,"1.37.1");e.set(Bv,window?window.location.href:null);e.set(Cv,Ga());if(a.R&&a.R.Qb){var h=a.R.Qb(b,c);"object"===typeof h&&e.set(a.R.id,h);c&&(a.R.Y.Sb=!1,!1===h&&(d=null))}g=lb(a.id);for(var k=0;kf.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(f=window.location.pathname+f),d?"}"==d.slice(-1)?(d=d.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(d?" parms='"+d+"'":"")+(f?' url="'+f+'"':"")));e||(a=a.replace(/().*?(<\/xsl:variable>)/, +"$1PCx86$2"),a=a.replace(/().*?(<\/xsl:variable>)/,"$1pcx86$2"));f=null;if("<"==a.charAt(0))try{e||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(f=new window.ActiveXObject("Microsoft.XMLDOM"),f.async=!1,f.loadXML(a)):f=(new window.DOMParser).parseFromString(a,"text/xml")}catch(r){f=null,a=r.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");Ea(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],m,r=/( [a-z]+=)(['"])(.*?)\2/gi;m=r.exec(f);)k=0>k.toLowerCase().indexOf(m[1].toLowerCase())?k.replace(">",m[0]+">"):k.replace(new RegExp(m[1]+"(['\"])(.*?)\\1"),m[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+ +"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/,"");a=a.replace(d[0],g);Kv(a,b,c)}})}else c(a,null)} +function Lv(a,b,c,d){function e(a){if(void 0===h){var b=g&&jb(g,"machine-warning");h=b&&b[0]||g}h&&(h.innerHTML=va(a))}function f(a){e("Error: "+a);k&&(--Hv||Wa(!0));k=!1}var g,h,k=!0;Hv++;bb[a]={};try{if(g=document.getElementById(a)){var m;if("object"==typeof resources&&(m=resources.css)){var r=document.head||document.getElementsByTagName("head")[0],x=document.createElement("style");x.type="text/css";x.styleSheet?x.styleSheet.cssText=m:x.appendChild(document.createTextNode(m));r.appendChild(x)}c|| +(c="/versions/pcx86/1.37.1/components.xsl");m=function(d,h){h?Iv(c,null,null,!1,e,function(d,k){k?(ab(a,c,d),e("Processing "+b+"..."),window.ActiveXObject||"ActiveXObject"in window?(k=h.transformNode(k))?(g.outerHTML=k,--Hv||Wa(!0)):f("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(d=new XSLTProcessor,d.importStylesheet(k),(k=d.transformToFragment(h,document))?g.parentNode?(g.parentNode.replaceChild(k,g),--Hv||Wa(!0)):f("invalid machine element: "+ +a):f("transformToFragment failed")):f("unable to transform XML: unsupported browser")):f(d)}):f(d)};"<"!=b.charAt(0)?Iv(b,a,d,!0,e,m):Jv(b,null,a,d,!1,e,m)}else f("missing machine element: "+a)}catch(t){f(t.message)}return k}function Mv(a,b,c,d){Wa(!1);return Lv(a,b,c,d)}window.embedPC=Mv;window.embedPCx86=Mv; +window.commandMachine=function(a,b,c,d,e,f){if("script"==e)return nb(c,f)?(b&&(a.disabled=!0),!0):!1;if(d){var g=hb(d,c+".machine");if(g){var h=g.exports;if(h&&(h=h[e]))return h.call(g,f)?(b&&(a.disabled=!0),!0):!1}}console.log("unimplemented: commandMachine('"+c+"','"+d+"','"+e+"','"+f+"')");return!1};window.enableEvents=Wa;window.sendEvent=Ya; +function Nv(a,b,c,d){if(!c&&b){d.push(b);a=bb[d[0]];b=null;for(var e in a)if(ua(e,"components.xsl")){b=e.replace(".xsl",".css");break}b?Ea(b,null,!0,function(a,b){Ov(b,d)}):Ov(null,d)}else q("Error ("+c+") requesting "+a)} +function Ov(a,b){var c,d,e=b[0],f=b[1];var g=b[4];if(g=g.match(/^(\s*\(function\(\)\{)([\s\S]*)(}\)\(\);)/)){var h=bb[e],k={},m;for(m in h){var r=h[m],x=ta(m);if("xml"==x){for(x=/[ \t]*]*path=(['"])(.*?)\1.*?<\/disk>\n?/g;c=x.exec(h[m]);){var t=c[2];t&&!h[t]&&(r=r.replace(c[0],""))}c=m=sa(m)}else"xsl"==x&&(d=m=sa(m));k[m]=r}a&&(k[m="css"]=a);b[2]&&(k[m="parms"]=b[2]);b[3]&&(k[m="state"]=b[3]);c&&d?(a=JSON.stringify(k),f+=".js",g=g[1]+"var resources="+a+";"+g[2]+g[3],g=g.replace(/\u00A9/g, +"©"),a=Qa(g,"javascript",!1,f),a=a+(', copy it to your web server as "'+f+'", and then add the following to your web page:\n\n')+('
    \n')+"...\n",a=a+(' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + float: + + + + + + + js + + + +
    + + + + + + + + + + js + + + "" + + + + + +
    +
    + + + + + + + + + + + + + + + , + + + + + + + + + + + + + .machine + . + . + + + + + + + + + + + + + + + + + + + + ,comment:'' + + + + + + border:1px solid black;border-radius:15px; + border:; + + + + + + left:; + + + + + + top:; + + + + + + + + width:; + width:;max-width:; + width:auto;max-width:; + + + + + + + + height:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto;clear:both; + position:; + position:relative; + + + + + overflow:auto;width:100%; + + background-color:; + background-color:; + + + + + - -component + +
    + + + + + + +
    + + + + + + + + --object -screen + + +
    +
    + +
    + +
    +
    + + + + +
    + + +
    [XML]
    + +
    + + +
    +
    +
    +
    + + + + + text-align:center; + + + +

    +
    + + +
    +
    + + + + + + +
    +
    + + + + type:'' + + + binding:'' + + + value:'' + + + + border:1px solid black; + border:; + + + + + + width:; + + + + + + height:; + + + + + + left:; + + + + + + top:; + + + + + + padding:; + + padding-top:; + padding-right:; + padding-bottom:; + padding-left:; + + + + + + float:left; + float:right; + margin:0 auto; + clear:both; + position:; + position:relative; + text-align:; + float:left; + + + + + + + + + + + + + + + + + + +
    + + + font-size:; + + + + + -label + + + + width:; + width:; + + + + + + + + text-align:right; + + + + +
    +
    +
    + + + + + + + + + + + + + + + + + + + + +
    +
    + +
    +
    + + +
    +
    +
    + +
    +
    + +
    +
    + +
    +
    +
    +
    +
    + +
    +
    + + + + +
    +
    + +
    +
    +
    + + +
    +
    +
    +
    +
    +
    + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + ; + + + + + + + + + + + + + + + : + + + + + + + + + + + + + + + + + desc:'' + + ,href:'' + + + + + + + + + + + + ; + + + + + + + + + + + + + + + + + + + + + + + + + + + + 8088 + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + + null + + + + + + 0 + + + + + + + -1 + + + + + + + -1 + + + + + + + -1 + + + + + + ,model:'',stepping:'',fpu:,cycles:,multiplier:,autoStart:,addrReset:,csStart:,csInterval:,csStop: + + + + + + + + + + + + + + + 8087 + + + + + + + + + + + + ,model:'',stepping:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + true + + + + + + + false + + + + + + {} + + + + + + + + + + + + + + + + + + + chipset + ,model:'',scaleTimers:,sw1:'',sw2:'',sound:,floppies:,monitor:'',dateRTC:'' + + + + + + + + + + + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + device + ,type:'',baudReceive:,baudTransmit:,autoMount:'' + + + + + + + + + + + + + + + + + + + + keyboard + ,model:'' + + + + + + + + + + + + + + + 0 + + + + + + + + + + + parallel + ,adapter:,binding:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + + 0 + + + + + + + 0 + + + + + + + false + + + + + serial + ,adapter:,baudReceive:,baudTransmit:,binding:'',tabSize:,charBOL:,upperCase: + + + + + + + + + + + + + + + 0 + + + + + + + + + + + + + + + + + + 0.5 + + + + + + + + + + + mouse + ,adapter:,binding:'',type:'',scaleMouse:,serial:'' + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + fdc + ,autoMount:'',sortBy:'' + + + + + + + + + + + + + + + + + + + + + XT + + + + + hdc + ,drives:'',type:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + null + + + + + + + + + + + + + + + + + rom + ,addr:,size:,alias:,file:'',notify:'' + + + + + + + + + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + null + + + + + + null + + + + + + true + + + + + ram + ,addr:,size:,file:'',load:,exec:,test: + + + + + + + + + + + + + + + + + + + + + null + + + + + + + 256 + + + + + + + 224 + + + + + + + black + + + + + + 0 + + + + + + 0 + + + + + + false + + + + + + 1bpp + + + + + + 0 + + + + + + 0 + + + + + + 1 + + + + + + 0 + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + false + + + + + + 1 + + + + + + 1 + + + + + + + 80 + + + + + + + 25 + + + + + + + + + + + + + + + + + + + + + + + + + + + + false + + + + + + + 0 + + + + + + null + + + + + + 0 + + + + + + 60 + + + + + + 0.5 + + + + + video + ,model:'',mode:,screenWidth:,screenHeight:,screenColor:'',screenRotate:,bufferAddr:,bufferRAM:,bufferFormat:'',bufferCols:,bufferRows:,bufferBits:,bufferLeft:,bufferRotate:,memory:,switches:'',scale:,cellWidth:,cellHeight:,charCols:,charRows:,fontROM:'',fontColor:'',touchScreen:'',autoLock:,aspectRatio:,smoothing:,interruptRate:,refreshRate:,flicker: + + + + + + + + + + + + + + + 16 + + + + + + + + + + + + + + + + + debugger + ,base:,commands:'',messages:'' + + + + + + + + + + + + + + panel + + + + + + + + + + + + + + + + + + + + + true + + + + + + + 0 + + + + + + 0 + + + + + + + + + + + + computer + ,autoPower:,busWidth:,resume:'',state:'' + + + + + + + + diff --git a/versions/pdpjs/1.37.1/document.css b/versions/pdpjs/1.37.1/document.css new file mode 100644 index 000000000..7072b406e --- /dev/null +++ b/versions/pdpjs/1.37.1/document.css @@ -0,0 +1,162 @@ +@CHARSET "UTF-8"; + +.page { + margin: 2% 2%; + padding: 2% 2%; + min-width: 30em; + overflow: auto; + font-size: large; + font-family: Helvetica, Arial, sans-serif; + background: #303030; + color: #ccc; + +} +.page-header { +} +.page-header-title { + text-align: center; + +} +.page a { + color: #7fc07f; + text-decoration: none; +} +a.footlink, a.paralink { + text-decoration: none; +} +a.footlink:link, a.paralink:link { + color: blue; +} +a.footlink:visited, a.paralink:visited { + color: blue; +} +.galleryitem { + float: left; + width: 200px; +} +.item { + float: left; + width: 2em; + text-indent: 1em; +} +.list { + margin-left: 3em; + text-indent: 0; + text-align: justify; +} +ul { + list-style: none; +} +div.pnumber { + float: left; + width: 2em; + text-indent: 1em; +} +div.pitem { + margin-left: 10em; +} +p.indent, .justified p { + text-indent: 2em; + text-align: justify; + line-height: 1.5em; +} +p.noindent { + text-indent: 0; + text-align: justify; +} +p.center, .center { + text-align: center; +} +li.para { + margin-top: 1em; + margin-bottom: 1em; +} +.left { + text-align: left; +} +.right { + text-align: right; +} +blockquote.tag { + font-size: small; + font-family: Monaco, Fixed, monospace; + margin-top: 0; + margin-bottom: 0; +} +.blockquote { + padding-left: 1em; + text-indent: 0; + text-align: justify; +} +.italics { + font-style: italic; +} +.medium { + font-size: medium; +} +.small { + font-size: x-small; +} +.smallcaps { + font-variant: small-caps; +} +.strike { + text-decoration: line-through; +} +.summation, .bracelist { + display: inline-block; + position: relative; + vertical-align: middle; + text-align: center; + margin-bottom: 0.5ex; + text-indent: 0; +} +.bracelist-symbol { + font-size: 3em; + vertical-align: -40%; +} +.summation .summation-lower, .summation .summation-upper, .bracelist-item { + display: block; + font-size: 75%; + text-align: center; +} +.summation .summation-upper { + margin-bottom: 0; + margin-left: 0.8ex; + font-style: italic; +} +.summation .summation-lower{ + margin-bottom: -0.6ex; + font-style: italic; +} +.summation .summation-symbol { + font-size: 2em; +} +p sup { + vertical-align: baseline; + position: relative; + bottom: .5em; + font-size: small; +} +p sub { + vertical-align: baseline; + position: relative; + bottom: -.5em; + font-size: small; +} +.footnote { + font-size: medium; + text-indent: 1em; + text-align: justify; + margin-top: .5em; +} +.image-right { + float: right; + margin-left: 1em; + margin-top: 1em; + margin-bottom: 1em; +} +.image-caption { + font-size: small; + text-align: center; +} \ No newline at end of file diff --git a/versions/pdpjs/1.37.1/document.xsl b/versions/pdpjs/1.37.1/document.xsl new file mode 100644 index 000000000..6c589fb1b --- /dev/null +++ b/versions/pdpjs/1.37.1/document.xsl @@ -0,0 +1,452 @@ + + + + + +]> + + + + + + + + + +

    +
    + + + + + + + +

    +
    + +

    +
    +
    +
    + + + + + + +
    +
    + + +
    + +   + + +
    +
    + +
    +
    + + + + + + + + + + + + + + + + +

    +
    + + +

    +
    + + +

    +
    + + +
    +
    + + +
    +
    + + + + + + + + + + + + + + +
    +
    + + +
    +
    + + +
  • +
    + + +
    image
    +
    + + +
    +
    + + + + +
    {.}
    +
    + +
    {.}
    +
    +
    +
    + + + + + + + + + + < + > + + + + × + + ÷ + σ + + + + + + + + + + + + { + + + + + + + + + + [] + + + + +
    + +
    +
    + + + , and + + + + + MDY + + + + + + + + + + + + + + + + + + + + January + February + March + April + May + June + July + August + September + October + November + December + + + , + + + + + +

    + +
    +
    + + +
    + {.}
    +
    +
    +
    + + + +

    Timeline

    +
    + +

    +
    +
    + +
    +
    + + + + + + + + + +

    +
    + +
    +
    +
    + + + +

    People

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + +

    +
      + +
    +
    + + + + + + + + + + +
  • + +
  • +
    + + + +

    +
    +

    + +

    +
    +
    + + + + false + + + + + + [Original] + + + + + + + + + + [] + + +
    by
    + + +
    + [Source: + + + + + + + ] +
    +
    +
    + + + +

    Resources

    +
    + +

    +
    +
    + +
    +
    + + +

    + +
    + + + +

    +
    +
      + +
    +
    + + +
  • +
    + + + +

    +
    +
    + +
    +
    + + + +

    +
    + +
    + + + +

    +
    +
      + +
    +
    + + + + + +
      + +
    +
    + + + + +
  • +
    + +
  • +
    + +
  • +
    +
    +
    + + +
  • +
    + + + + + + + + + + +
    + < ="" + + ></> + ></> + /> + +
    +
    + +
    diff --git a/versions/pdpjs/1.37.1/machine.xsl b/versions/pdpjs/1.37.1/machine.xsl new file mode 100644 index 000000000..95a4b5ff7 --- /dev/null +++ b/versions/pdpjs/1.37.1/machine.xsl @@ -0,0 +1,61 @@ + + + + +]> + + + + + + + + + + + + + + + + + js + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    +
    + + + + + , + +
    +
    + +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pdpjs/1.37.1/manifest.xsl b/versions/pdpjs/1.37.1/manifest.xsl new file mode 100644 index 000000000..efa366088 --- /dev/null +++ b/versions/pdpjs/1.37.1/manifest.xsl @@ -0,0 +1,247 @@ + + + + +]> + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Document Manifest

    +
    +
      + + + + None + + + + + + + + + + + + + + + + +
    +
    +
    +

    + +
    +
    +
    + + +
    + + + + + + + + + + + <xsl:value-of select="$SITEHOST"/> + + + + +
    + +
    +

    Software Manifest

    +
    +
      + + + + None + + + + + Unknown + + + + + None + + + + + None + + + + + + + + + + + + + UpdatedReleased + + Unknown + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    +
    +
    + + + + + + + +

    No default machine specified for '' in manifest.xml

    +
    + +
    +
    +
    + + + + -dbg + + + + + + +
    + + + + + Unknown + +
  • +
      + + + + + + + + +
    • + + + + + + + + + + + + + + + + + + + + + + + + + +
        + +
      • + + + + + + +
      • +
        +
      +
      +
    • +
      + + + + + + + + +
    +
  • +
    +
    + +
    diff --git a/versions/pdpjs/1.37.1/outline.xsl b/versions/pdpjs/1.37.1/outline.xsl new file mode 100644 index 000000000..ba8ebb0ba --- /dev/null +++ b/versions/pdpjs/1.37.1/outline.xsl @@ -0,0 +1,47 @@ + + + + +]> + + + + + + + + + + + + + + + + + + <xsl:value-of select="title"/><xsl:text> | </xsl:text><xsl:value-of select="$SITEHOST"/> + + + + + +
    +
    + +
    +
    + + + + -dbg + + + + + + +
    + +
    diff --git a/versions/pdpjs/1.37.1/pdp10-dbg.js b/versions/pdpjs/1.37.1/pdp10-dbg.js new file mode 100644 index 000000000..396e0e585 --- /dev/null +++ b/versions/pdpjs/1.37.1/pdp10-dbg.js @@ -0,0 +1,308 @@ +(function(){/* + http://pcjs.org/modules/shared/lib/dumpapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/reportapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/userapi.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/keys.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/strlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/weblib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/messages.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/device.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/rom.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/ram.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/computer.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/state.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/embed.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/usrlib.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/component.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/defines.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/panel.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/bus.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/memory.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/cpu.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/cpustate.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/cpuops.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/serial.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/shared/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/debugger.js (C) Jeff Parsons 2012-2017 + http://pcjs.org/modules/pdp10/lib/macro10.js (C) Jeff Parsons 2012-2017 +*/ +var m,aa="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){a!=Array.prototype&&a!=Object.prototype&&(a[b]=c.value)},ba="undefined"!=typeof window&&window===this?this:"undefined"!=typeof global&&null!=global?global:this;function ca(){ca=function(){};ba.Symbol||(ba.Symbol=da)}var da=function(){var a=0;return function(b){return"jscomp_symbol_"+(b||"")+a++}}(); +function ea(){ca();var a=ba.Symbol.iterator;a||(a=ba.Symbol.iterator=ba.Symbol("iterator"));"function"!=typeof Array.prototype[a]&&aa(Array.prototype,a,{configurable:!0,writable:!0,value:function(){return fa(this)}});ea=function(){}}function fa(a){var b=0;return ha(function(){return ba?-b:b}});sa("Math.log2",function(a){return a?a:function(a){return Math.log(a)/Math.LN2}}); +var ya={uc:0,Nb:1,wc:2,xc:3,yc:4,zc:5,Ac:6,Bc:7,wb:8,Cc:9,Ob:10,Dc:11,Ec:12,Pb:13,Fc:14,Gc:15,Hc:16,Ic:17,Jc:18,Kc:19,Lc:20,Mc:21,Nc:22,Oc:23,Pc:24,Qc:25,Rc:26," ":32,"!":33,'"':34,"#":35,$:36,"%":37,"&":38,"'":39,"(":40,")":41,"*":42,"+":43,",":44,"-":45,".":46,"/":47,0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,":":58,";":59,"<":60,"=":61,">":62,"?":63,"@":64,vb:65,tc:66,vc:67,Sc:68,E:69,Tc:70,Uc:71,Vc:72,Wc:73,Xc:74,Yc:75,Zc:76,$c:77,ad:78,bd:79,cd:80,Q:81,dd:82,ed:83,fd:84,gd:85,hd:86,jd:87, +kd:88,ld:89,Rb:90,"[":91,"\\":92,"]":93,"^":94,_:95,"`":96,yb:97,md:98,nd:99,d:100,e:101,od:102,pd:103,qd:104,rd:105,td:106,k:107,ud:108,vd:109,n:110,wd:111,p:112,q:113,r:114,xd:115,t:116,Ad:117,Bd:118,Cd:119,x:120,y:121,z:122,"{":123,"|":124,"}":125,"~":126,Qb:127}; +function za(a,b){if(a){b||(b=10);var c,d=0=b&&(c=a.match(/(-?[0-9]+)B([0-9]*)/))&& +(a=c[1],e=35-((c[2]||35)&255));c=a;if(((d=b)&&10!=d?16==d?null!==c.match(/^-?[0-9a-f]+$/i):8==d?null!==c.match(/^-?[0-7]+$/):2==d&&null!==c.match(/^-?[01]+$/):null!==c.match(/^-?[0-9]+$/))&&!isNaN(f=parseInt(a,b))){e&&(0>f&&(f+=Math.pow(2,36)),f=0a&&-1a&&(a+=Math.pow(b,c)),a>=Math.pow(b,c)&&(c=Math.ceil(Math.log(a)/Math.log(b))));for(var g=e||-1;0=h?48:55;f=String.fromCharCode(h)+f;a=Math.trunc(a/b)}g--}return(void 0===d?"":d)+f}function Ba(a,b,c){b?12=b?6:16777215>=b?8:12);return Aa(a,8,b,c?"0o":"")} +function Ca(a,b){b?11=Math.abs(a)?5:11;return Aa(a,10,b)}function n(a,b,c){b?9=b?4:4294967295>=b?8:9);return Aa(a,16,b,c?"0x":"")}function Da(a){var b=a,c=a.lastIndexOf("/");0<=c&&(b=a.substr(c+1));c=b.indexOf("&");0"']/g,function(a){return Ka[a]})}function La(a,b){return(a+" ").slice(0,b)}function Ma(a){return String.prototype.trim?a.trim():a.replace(/^\s+|\s+$/g,"")}var Ka={"&":"&","<":"<",">":">",'"':""","'":"'"};function Na(a,b,c){var d=0,e=a.length,f=0;for(c||(c=function(a,b){return a>b?1:a>1;var h=c(b,a[g]);0f;f++){var g;switch(g="Y-m-d H:i:s".charAt(f)){case "a":b+=12>c?"am":"pm";break;case "d":b+=("0"+d).slice(-2);break;case "D":b+=Pa[a.getDay()].substr(0,3);break;case "F":b+=Qa[e-1];break;case "g":b+=c?12b.indexOf("0x")&&0>b.indexOf("0o")&&'["'!=b.substr(0,2)?JSON.parse(b.replace(/([a-z]+):/gm,'"$1":').replace(/\/\/[^\n]*/gm,"")):eval("("+b+")");d.ka=g.load;d.xa=g.exec;if(e=g.bytes)d.da=e;else if(e=g.words)for(d.da=Array(2*e.length),f=c=0;c>8&255;else if(e=g.longs)for(d.da=Array(4*e.length),f=c=0;c>8&255,d.da[f++]=e[c]>>16&255,d.da[f++]=e[c]>>24&255;else(e=g.data)?d.Na=e:d.da=g;d.da&&(d.da.length?1==d.da.length&&(r(d.da[0]),d=null):(r("Empty resource: "+a),d=null));d.Z=g.symbols}catch(h){r("Resource data error ("+a+"): "+h.message),d=null}else{e=[];b=b.replace(/\n/gm," ").replace(/ +$/,"").split(" ");for(c=0;ca?this.Db=this.id:(this.Za=this.id.substr(0,a),this.Db=this.id.substr(a+1));this.A={ready:!1,Ta:!1,nb:!1,sd:!1,aa:!1,tb:!1,error:!1};this.bb=null;this.A.error=!1;this.ca=c||0;this.D=this.v=this.H=this.G=null;ub.push(this)} +function vb(a,b,c){wb[a]&&b&&(wb[a][b]=c)}function xb(){return Date.now()||+new Date}function r(a){window&&window.alert(a)}function yb(a){var b=!1;window&&(b=window.confirm(a));return b}function zb(a,b){a.value+=b;b=a.value;8192d?c+=a+"\n":c=c.substr(0,d)+(a+".")+ +c.substr(d+a.length);8192a;a++)this.b["S"+a]=[0,0,!1,!1,this.dc,a];this.D=this.v=this.H=this.G=null;this.exports={hold:this.Vb,toggle:this.oc,reset:this.kc, +set:this.nc};Xb(this)}ra(nc,t);m=nc.prototype;m.reset=function(a){this.stop();a&&pc(this,this.w=0)}; +m.ra=function(a,b,c,d){if(this.G&&this.G.ra(a,b,c,d)||this.v&&this.v.ra(a,b,c,d)||this.D&&this.D.ra(a,b,c,d))return!0;switch(b){case "PC":return this.J[b]=c,this.L++,!0;default:return"led"==a||"rled"==a?(this.J[b]=c,this.C[b]=d?1:0,this.L++,!0):"switch"==a?(void 0===this.b[b]&&(this.b[b]=[d?1:0,d?1:0]),this.J[b]=c,a=c.parentElement||c,a=a.parentElement||a,a.onmousedown=function(a,b){return function(){qc(a,b)}}(this,b),a.onmouseup=a.onmouseout=function(a,b){return function(){rc(a,b)}}(this,b),a.ontouchstart= +function(a,b){return function(c){qc(a,b);c.preventDefault()}}(this,b),a.ontouchend=function(a,b){return function(){rc(a,b)}}(this,b),!0):t.prototype.ra.call(this,a,b,c,d)}};m.Ka=function(a,b,c,d){this.G=a;this.H=b;this.v=c;this.D=d;sc(this);tc(this)};m.za=function(a,b){if(!b)if(this.V&&uc(),!a)this.reset(!0);else if(!this.restore(a))return!1;return!0};m.qa=function(a){return a?this.save():!0};m.save=function(){var a=new F(this);a.set(0,[this.i,this.w,this.j]);return a.data()}; +m.restore=function(a){if(a=a[0])vc(this,this.i=a[0]),pc(this,this.w=a[1]),wc(this,a[2]);return!0};m.kc=function(){for(var a in this.b){var b=this.b[a];b[1]=b[0]}tc(this);return!0};function xc(a,b,c){if(a=a.J[b])a.style.backgroundColor=c?"#ff0000":"#000000"}function sc(a,b){for(var c in a.C)xc(a,c,null!=b?b:a.C[c])}function yc(a,b,c){if(a=a.J[b])a.style.marginTop=c?"0px":"20px",a.style.backgroundColor=c?"#00ff00":"#228B22"}function tc(a){for(var b in a.b)yc(a,b,a.b[b][1])} +m.Vb=function(a,b,c){if(qc(this,b)){if(c){var d=this;setTimeout(function(){rc(d,b);a&&a()},+c);return!1}rc(this,b)}return!0};m.nc=function(a,b){if("SR"==a)return wc(this,za(b,8));var c=this.b[a];return c?(c[1]=+b?1:0,yc(this,a,c[1]),!0):!1};m.oc=function(a){return qc(this,a)?(rc(this,a),!0):!1};function qc(a,b){var c=a.b[b];return c?(yc(a,b,c[1]=1-c[1]),c[3]=!0,c[4]&&c[4].call(a,c[1],c[5]),b!=zc&&(a.O=b==Ac,a.R=b==Bc),!0):!1} +function rc(a,b){var c=a.b[b];c&&(c[2]&&c[3]&&(yc(a,b,c[1]=c[0]),c[4]&&c[4].call(a,c[1],c[5])),c[3]=!1)}m.ec=function(a){a||this.v.A.P||(G(this.v,this.i),this.b[Cc]&&this.b[Cc][1]&&Dc(this.v))};m.fc=function(){};m.$b=function(a){a||H(this.v)}; +m.Yb=function(a){if(!a&&!this.v.A.P)if(this.b[Cc]&&this.b[Cc][1])Dc(this.v);else{if((a=this.D)&&!Yb(a,!0))Zb(a,!0),Ec(a,0,null),Zb(a,!1);else try{var b=this.v.Xa(1);0c;c++){var d=a,e="A"+c,f=b&1<c;c++){var d=a,e="D"+c,f=b&1<b;b++)a.b["S"+b][1]=a.j&1<d.length){for(var e=0,f=Array(4096),g=0;g>>a.i;0f&&(l=f);if(h&&h.size){if(h.type==d){if(e+f<=h.B)return h.Va+=h.B-e,h.B=e,!0;if(e>=h.B+h.Va){l=h.size-(e-k);l>f&&(l=f);h.Va=e-h.B+l;e=k+16384;f-=l;g++;continue}}return Uc(Vc,e,f)}e=new Mc(a,e,l,16384,d);Nc(e,a.D,h);a.b[g++]=e;e=k+16384;f-=l}return 0>=f?(a.status("Added "+(c>>10)+"Kb "+Wc[d]+" at "+Ba(b)),!0):Uc(Xc,b,c)} +function Kc(a,b){var c=a.b[(b&a.j)>>>a.i];a.w++;b=c.w(b&16383,b);a.w--;return b}function Jc(a,b,c){var d=a.b[(b&a.j)>>>a.i];a.w++;d.D(c,b&16383,b);a.w--}function Sc(a){for(var b=0,c=[],d=0;d=a.sa&&(a.sa+=a.oa,c=!0);0<=a.ta&&a.ta<=sd(a)&&(a.oa=a.ta=-1,od(a),H(a),c=!0);c&&a.u(sd(a)+" cycles: checksum="+n(a.Fa))}} +m.ra=function(a,b,c){var d=this;switch(b){case "power":case "reset":return this.J[b]=c,!0;case "run":return this.J[b]=c,c.onclick=function(){var a;if(a=d.G)if(a=d.G,a.A.aa)a=!0;else{var b=null,c,h=Cb(a.id);for(c=0;ca.Y/a.ba?b=1:d=!0;a.ga=b;b=a.hb*a.ga;if(a.ba!=b){a.ba=b;b=a.ba.toFixed(2)+"Mhz";var e=a.J.setSpeed;e&&(e.textContent=b);a.u("target speed: "+b)}c&&a.G&&wd(a.G)}Gc(a,a.M);a.M=0;a.L=xb();a.S=0;ud(a);return d}function xd(a,b){for(var c=a.R.length-1;0<=c;c--){var d=a.R[c];0>d[0]||b>d[0]&&(b=d[0])}return b}function yd(a){for(var b=[],c=0;cd[0]||(d[0]-=b,0>=d[0]&&(d[0]=-1,d[1]()))}}function zd(a,b){var c=a.V-=a.N;a.N=0;b&&(a.V=0);return c} +m.lc=function(){if(this.A.P){this.$a>=this.kb&&ud(this,!0);this.ua=0;this.Ea=xb();if(this.S){var a=this.Ea-this.S;a>this.jb&&(this.L+=a,this.L>this.Ea&&(this.L=this.Ea))}try{do{var b=xd(this,this.A.Sa?1:this.Ha);try{this.Xa(b)}catch(e){if("number"!=typeof e)throw e;}b=zd(this,!0);this.ua+=b;this.M+=b;Hc(this,b);Fc(this,b);this.la-=b;if(0>=this.la){this.la+=this.Ha;++this.lb>=Ad&&(this.G&&K(this.G,void 0),this.lb=0);break}}while(this.A.P)}catch(e){H(this);this.G&&this.G.stop(xb(),sd(this));Ub(this, +e.stack||e.message);return}if(this.A.P){a=setTimeout;b=this.Fb;this.S=xb();var c=this.jb;this.ua&&(c=Math.round(c*this.ua/this.Ha));c-=this.S-this.Ea;var d=this.S-this.L;d&&(this.Y=Math.round(this.M/(10*d))/100,864E5<=d&&(this.W=0,td(this)));if(0>c||this.Yc&&(this.L-=c),c=0;this.$a+=this.ua;this.S+=c;a(b,c)}}}; +function Dc(a,b){if(!Vb(a))if(a.A.P)a.u(a.toString()+" busy");else{td(a);a.A.P=!0;a.A.fb=!0;var c=a.J.run;c&&(c.textContent="Halt");a.G&&(b&&wd(a.G,!0),a.G.start(a.L,sd(a)));a.D||a.status("Started");setTimeout(a.Fb,0)}}m.Xa=function(){return 0};function H(a,b){var c=!1;if(a.A.P){zd(a);Gc(a,a.M);a.M=0;a.A.P=!1;if(c=a.J.run)c.textContent="Run";a.G&&a.G.stop(xb(),sd(a));c=!0;a.D||a.status("Stopped")}a.A.complete=b;return c}var vd=30,Ad=15,ld=["power","reset"]; +function Bd(a){var b=+a.model||1001;kd.call(this,a,1E6);this.ib=b;this.Ya=+a.addrReset||0;this.Sb=Cd.bind(this);this.w=M.bind(this);this.Ba=null;this.ub=[];this.A.complete=!1}ra(Bd,kd);m=Bd.prototype; +m.reset=function(){this.status("Model "+this.ib);this.A.P&&H(this);this.Ia=this.Ja=this.b=this.I=0;this.i=this.na=this.Ya;this.K=this.O=-1;this.F=this.j=0;this.mb=[0,0];this.va=[0,0];this.ma=[0,0];this.wa=[0,0];this.Aa=this.i;this.C=0;this.f=this.hc;this.g=this.sc;this.Ba=null;nd(this);this.A.error=!1;kd.prototype.reset.call(this)};m.Kb=function(){return 0}; +m.save=function(){var a=new F(this);a.set(0,[this.b,this.I,this.Ia,this.Ja,this.i,this.O,this.K,this.j,this.C,this.na,this.Aa,this.Ya]);a.set(1,[]);a.set(2,[this.W,this.ga,this.A.fa]);a.set(3,Dd(this));a.set(4,yd(this));return a.data()}; +m.restore=function(a){var b=a[0];ea();ca();ea();var c=b[Symbol.iterator];b=c?c.call(b):fa(b);this.b=b.next().value;this.I=b.next().value;this.Ia=b.next().value;this.Ja=b.next().value;this.i=b.next().value;this.O=b.next().value;this.K=b.next().value;this.j=b.next().value;this.C=b.next().value;this.na=b.next().value;this.Aa=b.next().value;this.Ya=b.next().value;b=a[2];this.W=b[0];td(this,b[1]);this.A.fa=b[2];b=a[3];for(c=b.length-1;0<=c;c--){var d;a:{for(d=0;d>>b.i].f(a&16383,a)};m.sc=function(a,b){var c=this.H;a=this.Aa=a;c.b[(a&c.j)>>>c.i].g(b,a&16383,a);return b}; +m.Xa=function(a){this.A.complete=!0;var b=this.D?Hd(this.D)?1:this.A.fb?-1:0:0,c=a?this.A.fb?0:1:-1;this.A.fb=!1;this.V=this.N=a;this.C=this.C&-5|(b?4:0);do{if(this.C){if(this.C&4){if(Id(this.D,Gd(this),c)){H(this);break}++b||(this.C&=-5);c||c++}if(a=this.C&11)this.C&2?this.Ba||(this.C&=-3):this.C&1&&this.C++,a=!1;if(a){if(this.C&4&&Id(this.D,Gd(this),c)){H(this);break}if(0>c)break}}this.C&=15;this.I&4194304?this.I=this.Ia=this.f(this.b):0<=this.O?(this.I=this.Ja=this.f(this.O),this.O=-1):(this.I= +this.Ja=this.f(this.na=this.i),this.i=(this.i+1)%dc);this.I&=8388607;this.b=this.I&262143;if(a=this.I>>18&15)this.b=this.b+(this.Ia=this.f(a))&cc;a=this.I&4194304?-1:this.Ja/kc|0;0<=a&&this.Sb(a);this.N--}while(0>4].call(this,a,a&15)}function O(a){this.w(a)} +function Kd(){var a=0,b=this.f(this.b),c=b/lc&63,d=b>>24&63;c-=d;0>c&&(a++,c=36-d,0>c&&(c=100-d));b=c*lc+(d<<24)+(b&16777215);a&&(b=(b+a)%D);this.g(this.b,b)}function Ld(a,b){a=this.f(this.b);if(0>this.K)this.K=a,this.I=this.b|4194304;else{var c=this.K/lc&63,d=this.K>>24&63;a=32>c+d?(a>>c&(1<>>0:Math.trunc(a/Math.pow(2,c))%Math.pow(2,d);this.g(b,a);this.j&=-8193;this.K=-1}} +function Md(a,b){a=this.f(this.b);if(0>this.K)this.K=a,this.I=this.b|4194304;else{var c=this.K/lc&63,d=this.K>>24&63;b=this.f(b)%Math.pow(2,d)*Math.pow(2,c)%D;a=a-a%Math.pow(2,c+d)+b+a%Math.pow(2,c);this.g(this.b,a);this.j&=-8193;this.K=-1}}function Nd(a,b){this.g(b,this.f(this.b))}function Od(a,b){this.g(b,this.b)}function Pd(a,b){this.g(this.b,this.f(b))}function Qd(a,b){this.g(b,0)}function Rd(a,b){this.g(b,C-this.f(b))}function Sd(a,b){this.g(b,C)} +function Td(a,b){var c=this.f(this.b),d=this.f(b);this.g(b,Ud(a,d,c)+(c-(c&x)))}function ke(a,b){var c=this.f(b);this.g(b,Ud(a,c,0))}function le(a,b){b=this.f(b);var c=this.f(this.b);this.g(this.b,Ud(a,c,b)+(b-(b&x)))}function me(a,b){var c=this.f(this.b),d=c;if(a&=384)switch(d-=d&x,a){case 256:d+=x;break;case 384:d+=c>z?x:0}c=d;this.g(this.b,c);b&&this.g(b,c)}function ne(a,b){var c=(this.f(this.b)&x)*y,d=this.f(b);this.g(b,Ud(a,d,c)+c)} +function oe(a,b){var c=this.b*y,d=this.f(b);this.g(b,Ud(a,d,c)+c)}function pe(a,b){b=(this.f(b)&x)*y;var c=this.f(this.b);this.g(this.b,Ud(a,c,b)+b)}function qe(a,b){var c=this.f(this.b),d=(c&x)*y;c=Ud(a,c,d)+d;this.g(this.b,c);b&&this.g(b,c)}function re(a,b){var c=this.f(this.b)&x,d=this.f(b);this.g(b,se(a,d,c)+c)}function te(a,b){var c=this.f(b);this.g(b,se(a,c,this.b)+this.b)}function ue(a,b){b=this.f(b)&x;var c=this.f(this.b);this.g(this.b,se(a,c,b)+b)} +function ve(a,b){var c=this.f(this.b),d=c;if(a&=384)switch(d&=x,a){case 256:d+=x*y;break;case 384:d+=c>ec?x*y:0}c=d;this.g(this.b,c);b&&this.g(b,c)}function we(a,b){var c=this.f(this.b)/y|0,d=this.f(b);this.g(b,se(a,d,c)+c)}function xe(a,b){var c=this.f(b);this.g(b,se(a,c,0))}function ye(a,b){b=this.f(b)/y|0;var c=this.f(this.b);this.g(this.b,se(a,c,b)+b)}function ze(a,b){var c=this.f(this.b),d=c/y|0;c=se(a,c,d)+d;this.g(this.b,c);b&&this.g(b,c)}function P(a){Ae[a&7].call(this,a,a>>3&127)} +function Be(){}function Ce(){}function M(a){this.u("undefined opcode: "+Ba(a));Fd(this,-1);H(this)}function De(a){a>z&&(a!=A?a=hc-a:this.j|=163840);return a}function Q(a,b){var c=(a+b)%D;Ee.call(this,a,b,c);return c} +function Fe(a,b,c){var d=!1,e=!1;if(void 0===c){if(!a)return this.j|=131104,-1;c=b>z?C:0}else if((c=(az&&(a=D-a,d=!d);c>z&&(b?(c=C-c,b=D-b):c&&(c=D-c),e=!0,d=!d);f=this.mb;f[0]=0;f[1]=0;f=this.va;f[0]=1;f[1]=0;f=this.ma;f[0]=a;f[1]=0;a=this.wa;a[0]=b;for(a[1]=c;0c[0]&&(c[0]+=D,c[1]--),He(this.mb,this.va),Ie(this.wa)))break;Je(this.ma);Je(this.va)}while(!Ie(this.va));b=this.mb[0];this.F=this.wa[0];d&&b&&(b=D-b);e&&this.F&&(this.F=D-this.F);return b} +function Ke(a,b,c,d){var e=a,f=b;b=!1;e>z&&(d||1001!=this.ib||e!=A)&&(e=D-e,b=!b);f>z&&(f=D-f,b=!b);if(ez)&&(g!=C||a<=z)&&(this.j|=131072),g=a);return g} +function Le(a){a?a==A?this.j|=163840:a=hc-a:this.j|=98304;return a}function Me(a,b){var c=a-b;0>c&&(c+=D);Ee.call(this,c,b,a);return c}function Ee(a,b,c){a=Math.trunc(a/gc);b=Math.trunc(b/gc);c=Math.trunc(c/gc);var d=a^(a^b)&(b^c);this.j=this.j|(d&2?65536:0)|(d&1?32768:0)|((a^c)&(b^c)&2?131072:0)}function R(a,b){return((a/E|0)&(b/E|0))*E+((a&b)>>>0)}function S(a,b){return R(a,(~(b/E|0)&15)*E+(~b>>>0))}function Ne(a,b){return(a>>0)}function T(a,b){return(a/E|0|b/E|0)*E+((a|b)>>>0)}function U(a){return a>>0)}function W(a){return(a/y|0)+(a&x)*y}function se(a,b,c){switch(a&384){case 0:b-=b&x;break;case 128:b=0;break;case 256:b=x*y;break;case 384:b=c>ec?x*y:0}return b}function Ud(a,b,c){switch(a&384){case 0:b&=x;break;case 128:b=0;break;case 256:b=x;break;case 384:b=c>z?x:0}return b} +function He(a,b){a[0]+=b[0];a[1]+=b[1];a[0]>=D&&(a[0]%=D,a[1]++)}function Ge(a,b){var c=a[1]-b[1];c||(c=a[0]-b[0]);return c}function Je(a){a[1]%2&&(a[0]+=D);a[0]=Math.trunc(a[0]/2);a[1]=Math.trunc(a[1]/2)}function Ie(a){return!a[0]&&!a[1]} +var Jd=[O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,O,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,M,function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},Kd,function(a,b){this.j&8192||(Kd.call(this),this.j|=8192);Ld.call(this,0,b)},Ld,function(a,b){this.j&8192||(Kd.call(this),this.j|=8192);Md.call(this,0,b)},Md,function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)}, +function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)}, +function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},function(a){this.w(a)},Nd,Od,Pd,function(a,b){b&&this.g(b,this.f(this.b))},function(a,b){a=this.f(this.b);a=(a/y|0)+(a&x)*y;this.g(b,a)},function(a,b){this.g(b,this.b*y)},function(a,b){a=this.f(b);a=(a/y|0)+(a&x)*y;this.g(this.b,a)},function(a,b){a=this.f(this.b);a=(a/y|0)+(a&x)*y;this.g(this.b,a);b&&this.g(b,a)},function(a,b){this.g(b,Le.call(this,this.f(this.b)))},function(a,b){this.g(b, +Le.call(this,this.b))},function(a,b){this.g(this.b,Le.call(this,this.f(b)))},function(a,b){a=Le.call(this,this.f(this.b));this.g(this.b,a);b&&this.g(b,a)},function(a,b){this.g(b,De.call(this,this.f(this.b)))},function(a,b){this.g(b,this.b)},function(a,b){this.g(this.b,De.call(this,this.f(b)))},function(a,b){a=De.call(this,this.f(this.b));this.g(this.b,a);b&&this.g(b,a)},function(a,b){this.g(b,Ke.call(this,this.f(b),this.f(this.b),!0))},function(a,b){this.g(b,Ke.call(this,this.f(b),this.b,!0))},function(a, +b){this.g(this.b,Ke.call(this,this.f(b),this.f(this.b),!0))},function(a,b){this.g(this.b,this.g(b,Ke.call(this,this.f(b),this.f(this.b),!0)))},function(a,b){this.g(b,Ke.call(this,this.f(b),this.f(this.b)));this.g(b+1&15,this.F)},function(a,b){this.g(b,Ke.call(this,this.f(b),this.b));this.g(b+1&15,this.F)},function(a,b){this.g(this.b,Ke.call(this,this.f(b),this.f(this.b)))},function(a,b){this.g(this.b,this.g(b,Ke.call(this,this.f(b),this.f(this.b))));this.g(b+1&15,this.F)},function(a,b){a=Fe.call(this, +this.f(this.b),this.f(b));0>a||(this.g(b,a),this.g(b+1&15,this.F))},function(a,b){a=Fe.call(this,this.b,this.f(b));0>a||(this.g(b,a),this.g(b+1&15,this.F))},function(a,b){a=Fe.call(this,this.f(this.b),this.f(b));0>a||this.g(this.b,a)},function(a,b){a=Fe.call(this,this.f(this.b),this.f(b));0>a||(this.g(this.b,this.g(b,a)),this.g(b+1&15,this.F))},function(a,b){a=this.f(b);var c=this.f(b+1&15);c=Fe.call(this,this.f(this.b),c,a);0>c||(this.g(b,c),this.g(b+1&15,this.F))},function(a,b){a=this.f(b);var c= +this.f(b+1&15);c=Fe.call(this,this.b,c,a);0>c||(this.g(b,c),this.g(b+1&15,this.F))},function(a,b){a=this.f(b);b=this.f(b+1&15);b=Fe.call(this,this.f(this.b),b,a);0>b||this.g(this.b,b)},function(a,b){a=this.f(b);var c=this.f(b+1&15);c=Fe.call(this,this.f(this.b),c,a);0>c||(this.g(b,this.g(this.b,c)),this.g(b+1&15,this.F))},function(a,b){if(a=(this.b&fc)<<14>>23|this.b&255){var c=this.f(b);if(0a&&(e+=c*Math.pow(2,a)%A,d=A-Math.pow(2,35-a));cz&&(this.j|=131072):c- +d=a?e=cz&&(d=D-Math.pow(2,36+a),e+=d));this.g(b,e)}},function(a,b){if(a=((this.b&fc)<<14>>23|this.b&255)%36){var c=this.f(b);0>a&&(a=36+a);c=c*Math.pow(2,a)%D+Math.trunc(c/Math.pow(2,36-a));this.g(b,c)}},function(a,b){if(a=(this.b&fc)<<14>>23|this.b&255){var c=this.f(b);c=0=a?0:Math.trunc(c/Math.pow(2,-a));this.g(b,c)}},function(a,b){a=0;var c=this.f(b);if(c){for(;c>23|this.b&255){var c=this.f(b),d=this.f(b+1&15);if(0z&&cz&&dz&&(this.j|=131072):d-f<=z&&(this.j|=131072)}d=0;e>z&&(c+=A,d+=A)}else c=c*Math.pow(2,a)%A+Math.trunc(d%A/Math.pow(2,35-a)),d=d*Math.pow(2,a)%A,f=A-Math.pow(2,35-a),e<=z?e+f>z&&(this.j|=131072):(e-f<=z&&(this.j|=131072),c+=A,d+=A)}else-36>= +a?(d=-72>=a?c>z?C:0:Math.trunc(c%A/Math.pow(2,-a-35)),c<=z?c=0:(c=C,d+=A)):(f=c>z?D-Math.pow(2,36+a):0,d=Math.trunc(d%A/Math.pow(2,-a))+c%A*Math.pow(2,35+a)%A,c=Math.trunc(c/Math.pow(2,-a))+f,c>z&&(d+=A));this.g(b,c);this.g(b+1&15,d)}},function(a,b){if(a=((this.b&fc)<<14>>23|this.b&255)%72){var c=this.f(b),d=this.f(b+1&15),e=c;0>a&&(a=72+a);36>a?(c=c*Math.pow(2,a)%D+Math.trunc(d/Math.pow(2,36-a)),d=d*Math.pow(2,a)%D+Math.trunc(e/Math.pow(2,36-a))):(c=d*Math.pow(2,a-36)%D+Math.trunc(c/Math.pow(2,72- +a)),d=e*Math.pow(2,a-36)%D+Math.trunc(d/Math.pow(2,72-a)));this.g(b,c);this.g(b+1&15,d)}},function(a,b){if(a=(this.b&fc)<<14>>23|this.b&255){var c=this.f(b),d=this.f(b+1&15);0=a?(d=-72>=a?0:Math.trunc(c/Math.pow(2,-a-36)),c=0):(d=Math.trunc(d/Math.pow(2,-a))+c*Math.pow(2,36+a)%D,c=Math.trunc(c/Math.pow(2,-a)));this.g(b,c);this.g(b+1&15,d)}},M,function(a,b){a=this.f(b);this.g(b, +this.f(this.b));this.g(this.b,a)},function(a,b){var c=a=!1,d=this.f(b),e=d/y|0;for(d&=x;!a;)if(this.g(d,this.f(e)),(a=d>=this.b)||(e=e+1&x,d=d+1&x,c=!0),a||!this.A.P){c&&this.g(b,e*y+d);a||Fd(this,-1);break}},function(a,b){a=(this.f(b)+262145)%D;this.g(b,a);a=A&&G(this,this.b)},function(a,b){b&1&&(this.j|=4096);b&2&&Ed(this,this.Ia/y|0);b&4&&H(this);b&8&&this.w(a);G(this,this.b)},function(a,b){a=b<<14;this.j&a&&(this.j&=~a,G(this, +this.b))},function(){this.O=this.b},M,function(a,b){a=(this.f(b)+262145)%D;this.g(b,a);a/y|0||(this.j|=262144);this.g(a&cc,(this.j&x)*y+this.i);this.j&=-8193;G(this,this.b)},function(a,b){a=this.f(b);a+=262145;this.g(a&cc,this.f(this.b));a>=D&&(a-=D);a/y|0||(this.j|=262144);this.g(b,a)},function(a,b){a=this.f(b);var c=this.f(a&cc);this.g(this.b,c);this.b==b&&(a=c);a-=262145;0>a&&(a+=D);(a/y|0)==x&&(this.j|=262144);this.g(b,a)},function(a,b){a=this.f(b);var c=this.f(a&cc);a-=262145;0>a&&(a+=D);(a/ +y|0)==x&&(this.j|=262144);this.g(b,a);G(this,c&cc)},function(){this.g(this.b,(this.j&x)*y+this.i);this.j&=-8193;G(this,this.b+1)},function(a,b){this.g(b,(this.j&x)*y+this.i);this.j&=-8193;G(this,this.b)},function(a,b){this.g(this.b,this.f(b));this.g(b,this.b*y+this.i);G(this,this.b+1)},function(a,b){a=this.f(b);this.g(b,this.f(a/y|0));G(this,this.b)},function(a,b){this.g(b,Q.call(this,this.f(b),this.f(this.b)))},function(a,b){this.g(b,Q.call(this,this.f(b),this.b))},function(a,b){this.g(this.b,Q.call(this, +this.f(b),this.f(this.b)))},function(a,b){this.g(this.b,this.g(b,Q.call(this,this.f(b),this.f(this.b))))},function(a,b){this.g(b,Me.call(this,this.f(b),this.f(this.b)))},function(a,b){this.g(b,Me.call(this,this.f(b),this.b))},function(a,b){this.g(this.b,Me.call(this,this.f(b),this.f(this.b)))},function(a,b){this.g(this.b,this.g(b,Me.call(this,this.f(b),this.f(this.b))))},Be,function(a,b){0>Ne(this.f(b),this.b)&&G(this,this.i+1)},function(a,b){0==Ne(this.f(b),this.b)&&G(this,this.i+1)},function(a, +b){0>=Ne(this.f(b),this.b)&&G(this,this.i+1)},function(){G(this,this.i+1)},function(a,b){0<=Ne(this.f(b),this.b)&&G(this,this.i+1)},function(a,b){0!=Ne(this.f(b),this.b)&&G(this,this.i+1)},function(a,b){0Ne(this.f(b),this.f(this.b))&&G(this,this.i+1)},function(a,b){0==Ne(this.f(b),this.f(this.b))&&G(this,this.i+1)},function(a,b){0>=Ne(this.f(b),this.f(this.b))&&G(this,this.i+1)},function(){G(this,this.i+1)},function(a,b){0<=Ne(this.f(b), +this.f(this.b))&&G(this,this.i+1)},function(a,b){0!=Ne(this.f(b),this.f(this.b))&&G(this,this.i+1)},function(a,b){0U(this.f(b))&&G(this,this.b)},function(a,b){0==U(this.f(b))&&G(this,this.b)},function(a,b){0>=U(this.f(b))&&G(this,this.b)},function(){G(this,this.b)},function(a,b){0<=U(this.f(b))&&G(this,this.b)},function(a,b){0!=U(this.f(b))&&G(this,this.b)},function(a,b){0U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.f(this.b);0==U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.f(this.b);0>=U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){G(this,this.i+1);b&&this.g(b,this.f(this.b))},function(a,b){a=this.f(this.b);0<=U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.f(this.b);0!=U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.f(this.b);0U(a)&&G(this,this.b)},function(a,b){a=this.g(b,Q.call(this,this.f(b),1));0==U(a)&&G(this,this.b)},function(a,b){a=this.g(b,Q.call(this,this.f(b),1));0>=U(a)&&G(this,this.b)},function(a,b){this.g(b,Q.call(this,this.f(b),1));G(this,this.b)},function(a,b){a=this.g(b,Q.call(this,this.f(b),1));0<=U(a)&&G(this,this.b)},function(a,b){a=this.g(b,Q.call(this,this.f(b),1));0!=U(a)&&G(this,this.b)},function(a,b){a=this.g(b, +Q.call(this,this.f(b),1));0U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b,Q.call(this,this.f(this.b),1));0==U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b,Q.call(this,this.f(this.b),1));0>=U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b,Q.call(this,this.f(this.b),1));G(this, +this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b,Q.call(this,this.f(this.b),1));0<=U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b,Q.call(this,this.f(this.b),1));0!=U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b,Q.call(this,this.f(this.b),1));0U(a)&&G(this,this.b)},function(a,b){a=this.g(b,Q.call(this,this.f(b), +C));0==U(a)&&G(this,this.b)},function(a,b){a=this.g(b,Q.call(this,this.f(b),C));0>=U(a)&&G(this,this.b)},function(a,b){this.g(b,Q.call(this,this.f(b),C));G(this,this.b)},function(a,b){a=this.g(b,Q.call(this,this.f(b),C));0<=U(a)&&G(this,this.b)},function(a,b){a=this.g(b,Q.call(this,this.f(b),C));0!=U(a)&&G(this,this.b)},function(a,b){a=this.g(b,Q.call(this,this.f(b),C));0U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b,Q.call(this,this.f(this.b),C));0==U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b,Q.call(this,this.f(this.b),C));0>=U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b,Q.call(this,this.f(this.b),C));G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b,Q.call(this,this.f(this.b),C));0<=U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b, +Q.call(this,this.f(this.b),C));0!=U(a)&&G(this,this.i+1);b&&this.g(b,a)},function(a,b){a=this.g(this.b,Q.call(this,this.f(this.b),C));0>>f.i;0>>= +f.i;0>>=a.i;0g&&g>=-A&&(g+=D);g=Math.trunc(Math.abs(g))%D;for(var h=d;f--&&h=ya.vb&&c<=ya.Rb&&(b=c-(ya.vb-ya.Nb));b&&(a.preventDefault&&a.preventDefault(),d.cb(b));return!0},c.onkeypress=function(a){a=a||window.event;if(!a.metaKey){var b=a.which||a.keyCode;a.altKey&&b==ya.Pb&&(b=ya.Ob);d.cb(b);a.preventDefault&&a.preventDefault()}return!0},c.onpaste=function(a){a.stopPropagation&&a.stopPropagation(); +a.preventDefault&&a.preventDefault();(a=a.clipboardData||window.clipboardData)&&d.cb(a.getData("Text"))},c.removeAttribute("readonly"),!0}return!1};m.Ka=function(a,b,c,d){this.G=a;this.H=b;this.v=c;this.D=d;Xb(this)}; +m.Lb=function(a){if(!this.b){var b=md(this.G,"connection");if(b){var c=b.split("->");if(2==c.length){var d=Ma(c[0]);if(d!=this.Db)return;c=Ma(c[1]);if(this.b=Db(c)){var e=this.b.exports;if(e){var f=e.connect;f&&f.call(this.b,this.j);if(this.C=e.receiveData){this.j=a;this.status("Connected "+this.Za+"."+d+" to "+c);return}}}}this.status("Unable to establish connection: "+b)}}};m.za=function(a,b){if(!b)if(this.Lb(this.j),!a)this.reset();else if(!this.restore(a))return!1;return!0}; +m.qa=function(a){return a?this.save():!0};m.reset=function(){};m.save=function(){var a=new F(this);a.set(0,[]);return a.data()};m.restore=function(){return!0};m.cb=function(a){if("number"==typeof a)this.i.push(a);else if("string"==typeof a)for(var b=0,c,d=0;da.C&&a.w.length&&(a.C=0);if(0>a.C||b!=a.w[a.C])a.w.splice(0,0,b),a.C=0;a.C--}else a.V?b="end":b=a.w[a.C+1];a=[];if(b){b=b.replace(/""/g,"'");c=0;var e=null;d=d||";";for(var f=0;f<=b.length;f++){var g=b.charAt(f);if('"'==g||"'"==g)e?g==e&&(e=null):e=g;else if(g==d&&!e||!g)a.push(Ma(b.substring(c,f))),c=f+1}}return a}function Ze(a,b,c){if(32>=a.L)return b&c;b=X(a,b,0,!0);c=X(a,c,0,!0);return((b/$e|0)&(c/$e|0))*$e+((b&c)>>>0)} +function af(a,b,c){if(32>=a.L)return b|c;b=X(a,b,0,!0);c=X(a,c,0,!0);return((b/$e|0)^(c/$e|0))*$e+((b^c)>>>0)}Xe.prototype.Ib=function(a,b){return a*b};function X(a,b,c,d){var e=b;c=c||a.L;if(d)if(32==c)e=b>>>0;else if(32>c)e=b&(1<b||b>=a)e=b%a,0>e&&(e+=a)}else 32>=c?e=b<<32-c>>32-c:(a=Math.pow(2,c-1),b>=a?(e=b%a,(b/a|0)&1&&(e-=a)):b<-a&&(e=b%a,((-b-1)/a|0)&1?e&&(e+=a):e||(e-=a)));b!=e&&(b=e);return b} +function bf(a,b,c,d){for(d=void 0===d?-1:d;d--&&c.length;){var e=c.pop();if(2>b.length)return!1;var f=b.pop();var g=b.pop();switch(e){case "*":g=a.Ib(g,f);break;case "/":if(!f)return!1;g=Math.trunc(g/f);break;case "^/":if(!f)return!1;g%=f;break;case "+":g+=f;break;case "-":g-=f;break;case "<<":g<<=f;break;case ">>":g>>=f;break;case ">>>":g>>>=f;break;case "<":g=g":g=g>f?1:0;break;case ">=":g=g>=f?1:0;break;case "==":g=g==f?1:0;break;case "!=":g=g!=f? +1:0;break;case "&":g=Ze(a,g,f);break;case "!":case "|":e=g;32>=a.L?g=e|f:(e=X(a,e,0,!0),f=X(a,f,0,!0),g=(e/$e|0|f/$e|0)*$e+((e|f)>>>0));break;case "^!":g=af(a,g,f);break;case "&&":g=g&&f?1:0;break;case "||":g=g||f?1:0;break;case ",,":g=X(a,g,18,!0)*Math.pow(2,18)+X(a,f,18,!0);break;case "_":case "^_":"^_"==e&&(f=35-(f&255));f&&(g=X(a,g,0,!0),g=0=|>>>|>>|>|<=|<<|<|-|\+|\^\/|\/|\*|,,| )/);d=cf(a,b,0,b.length,a.T,c);void 0!==d&&e&&kf(a,null,d)}return d} +function ef(a,b,c){for(;c;){switch(c&3){case 1:b=-X(a,b);break;case 2:b=af(a,b,-1);break;case 3:for(var d=35;0<=d&&!Ze(a,b,Math.pow(2,d));)d--;b=35-d}c>>>=2}return b} +function df(a,b,c,d,e){e=void 0===e?0:e;var f=Array.isArray(d)?d:void 0;if(null!=b){var g=a.qb(b);if(0<=g)g=a.rb(g);else if(g=b,a.b[g]?g=a.b[g].value:(g=g.substr(0,6),g=a.b[g]&&a.b[g].value),null!=g){var h=a.b[b]&&a.b[b].Mb;h&&(f?f.push(h):(f=jf(a,h,d),void 0!==f?g+=f:(d||a.u("undefined "+(c||"value")+": "+b+" ("+h+")"),g=void 0)))}else g=za(b,1=a.L?8:6)+" "+c+".";32<=c&&127>c&&(e+=" '"+String.fromCharCode(c)+"'")}a.u((null!=b?b+": ":"")+e);return d}function lf(a){var b=a.b;a.b={};return b}function mf(a,b){var c=0;if(a.b){if(b)return kf(a,b,a.b[b]&&a.b[b].value);b=Object.keys(a.b);b.sort();for(var d=0;d=a?8:262143>=a?18:36);b=Aa(b,2,a,"",e);break;case 8:b=Ba(b,0>2:0,!!e)}0>c?c=b.replace(/^0+([0-9A-F]+)$/i,"$1"):c=b;return c} +var gf={"||":5,"&&":6,"!":7,"|":7,"^!":8,"&":9,"!=":10,"==":10,">=":11,">":11,"<=":11,"<":11,">>>":12,">>":12,"<<":12,"-":13,"+":13,"^/":14,"/":14,"*":14,_:19,"^_":19,"{":20,"}":20},ff={",,":1,"||":5,"&&":6,"!=":10,"==":10,">=":11,">":11,"<=":11,"<":11,">>>":12,">>":12,"<<":12,"-":13,"+":13,"^/":14,"/":14,"*":14,"!":15,"|":15,"^!":15,"&":15,_:19,"^_":19,"{":20,"}":20},$e=Math.pow(2,32); +function nf(a){Xe.call(this,a);this.Ha=!1;this.Ea=18;this.L=36;this.S=["<",">"];this.sa=[];this.Ga=Y();this.M=Y(0);this.na=Y(0);this.ga=Y(0);this.I=[];this.i=this.N=this.K=[];of(this);this.W=this.oa=0;this.j=[];this.Aa=void 0;pf(this);this.D=this;this.ua={};this.ca=this.Eb=0;this.Y=null;this.R=[];qf(this,a.messages);this.ta=a.commands;this.Fa=[];this.O=0;this.Ma=this.Ba=null;this.F=this.Ja=this.Ia=this.ma=this.wa=0;this.va=this.la=this.ba=null;var b=this;window?void 0===window[u]&&(window[u]=function(a){return rd(b, +a)}):void 0===global[u]&&(global[u]=function(a){return rd(b,a)})}ra(nf,Xe);function rf(a){a=a&&a.B;null==a&&(a=-1);return a}function Y(a,b,c){return{B:void 0===a?null:a,ab:void 0===b?!1:b,pa:!1,T:c}}function sf(a,b,c,d){a.B=b;a.ab=c||!1;a.pa=!1;a.T=d}function tf(a){return[a.B,a.ab,a.pa,a.T,a.eb]}function uf(a,b){var c=Y(b[0],b[1],b[2]);c.pa=b[3];b[4]&&(c.zb=Ye(a,c.eb=b[4]));return c}m=nf.prototype; +m.Ka=function(a,b,c,d){this.H=b;this.G=a;this.v=c;this.la=a.j;this.Ea=b.F;(b=md(a,"messages"))&&qf(this,b);if(a=md(a,"commands"))this.ta=a;vf(this,function(a){a:{var b=d.H.b,c=a[0],e=a=0,k=b.length;if(c){a=rf(wf(d,c,d.na));if(-1===a){d.u("invalid address: "+c);break a}e=a>>>d.H.i;k=1}d.u("blockid physical blockaddr used size type");d.u("-------- --------- --------- ------ ------ ----");c=-1;for(var l=0;k--;){var p=b[e];p.type==c?l++||d.u("..."):(c=p.type,l=Wc[c],p&&d.u(n(p.id,8)+" %"+ +n(e<a&&(a+=D);0>b&&(b+=D);a=Ke.call(this.v,a,b,!1,!0);a>=A&&(a-=D);return a}; +function wf(a,b,c){var d;c||(c=Y());var e=c.B;if(void 0!==b){a:{e=a.S[0];var f=a.S[1];var g="("==e||"{"==e||"["==e?"\\":"";var h="["==e?"\\":"";for(h=new RegExp(g+e+"([^"+h+e+h+f+"]+)"+g+f);g=b.match(h);){var k=jf(a,g[1]);if(void 0===k){b=void 0;break a}b=b.replace(e+g[1]+f,null!=k?L(a,k):"undefined")}if(a.sa.length)for(e=a.sa[0],f=a.sa[1],g="("==e||"{"==e||"["==e?"\\":"",h="["==e?"\\":"",h=new RegExp(g+e+"([^"+h+e+h+f+"]+)"+g+f);g=b.match(h);)b=b.replace("["+g[1]+"]","unimplemented");for(;e=b.match(/\$([a-z]+)/i);){f= +null;switch(e[1].toLowerCase()){case "ops":f=0}if(null==f)break;b=b.replace(e[0],f.toString())}}if("%"==b.charAt(0)){var l=!0;b=b.substr(1)}var p;e=b;if(e.match(/^[a-z_][a-z0-9_]*$/i))for(e=e.toUpperCase(),f=0;fa&&a>=-A&&(a+=D);return Math.trunc(Math.abs(a))%Math.pow(2,void 0===b?36:b)}function zf(a,b){return L(a,b/dc,18)+" "+L(a,b%dc,18)} +function qf(a,b){a.D=a;a.ca=a.Eb=536870916;a.Y=null;a.R=[];b=Ye(a,b.replace("keys","key").replace("kbd","keyboard"),!1,"|");if(b.length)for(var c in mc){a:{var d=void 0;if(Array.prototype.indexOf)d=b.indexOf(c,d);else{d=d||0;0>d&&(d+=b.length);0>d&&(d=0);for(var e=b.length;d>23&&a.v.na==b&&(b=Fd(a.v,1)));if(0d&&(d=a.v.f(b)),0<=d&&(sf(a.j[a.W],b),++a.W==a.j.length&&(a.W=0)));return!1} +function Sf(a,b,c,d){var e=Y(b.B),f=a.La(b,1),g,h=0,k=f/ic|0,l;for(l in Tf)if(g=Tf[l][k&l]){var p=+l;k>>=6;switch(p){case 32512:var q=Uf;h=k&3;break;case 32256:q=Vf;h=k&7;break;case 29248:q=Wf,h=(k&48)>>2|(k&6)>>1}break}q=q&&q[h]||"";"S"==q&&g>Xf&&(q="B");q=Yf[g||0]+q;if(g){if(28700==p)p=f/jc&127,h=L(a,p,-1);else for(p=f>>23&15,h=L(a,p,-1),k=0;h&&k>18&15)&&(q+="("+L(a, +f,-1)+")")}else q=La(q,8)+zf(a,f);f=q;g="";p=L(a,e.B,18)+":";if(-1!==e.B&&-1!==b.B){do if(q=a.La(e,1),g+=" "+zf(a,q),null==e.B)break;while(e.B!=b.B)}p+=La(g,16)+f;c&&(p=La(p,48)+";"+(c||""),p=a.v.A.Sa?p+("cycles="+sd(a.v).toString()+" cs="+n(a.v.Fa)):p+(null!=d?"="+d.toString():""));return p} +function $f(a,b,c,d,e){var f=-1;if(b){for(var g=b.toUpperCase(),h=0;hXf&&(J="B");if(g==Yf[l]+J){f=29248!=q?v:(v&3)<<1|(v&12)<<2;f=(B|f<<6)*ic;break}}if(0<=f)break}if(0<=f)break}!(0>f)||c&&c.match(/^[0-9A-Z$%.?]/i)|| +(c=b+c,b="",f=0)}else c&&(f=q=0);if(0<=f&&c)for(g=c.split(","),2l||127l||15l||262143f&&!e&&a.u("unknown instruction: "+b+" "+c);return f}function of(a){var b;a.i=["bp"];if(a.N)for(b=1;b>>d.i],!1)}a.N=["br"];if(a.K)for(b=1;b>>d.i],!0);a.K=["bw"];a.wa=0;a.oa=0} +m.Qa=function(a,b,c){var d=!0;c||ag(this,a,b,!1,!0);if(a!=this.i){var e=rf(b);if(-1===e)this.u("invalid address: "+L(this,b.B,18)),d=!1;else{var f=this.H;f.b[e>>>f.i].Qa(e&16383,a==this.K)}}d&&(a.push(b),c?b.pa=!0:(bg(this,a,a.length-1,"set"),pf(this)));return d};function ag(a,b,c,d,e){var f=!1;c=rf(c);for(var g=1;g>>d.i],b==a.K));h.pa||pf(a);break}}return f} +function cg(a,b){for(var c=1;cd;d++){!d||d&3||(c+="\n");var e=a,f=Ba(d,2);sf(e.Ga,d);f+="="+L(e,e.La(e.Ga),36)+" ";c+=f}if(b){b="";for(d=0;d=Ff?1:d==Cf?23:18)+" "),b+=e;c+="\n"+b}return c}m.Gb=function(a,b){return a[0]>b[0]?1:a[0]>>0,g];var q=Na(p,k,a.Gb);0>q&&p.splice(-(q+1),0,k)}l&&(h.a=l.replace(/''/g,'"'))}a.I.push({yd:b,B:c,Wb:d,Z:e,Bb:f})}function fg(a,b,c){var d=[],e=rf(b)>>>0;for(b=0;b>>0,h=f.Wb;if(e>=g&&e>>d.i].g(a,b&16383,b);null==f&&(f=b);b>g&&(g=b);e++});e?(b="start address ",null!=c?(G(a.v,c),b+=L(a,c)):b+="unspecified",a.u(e+" words loaded at "+L(a,f)+"-"+L(a,g)+", "+b),pd(a)):a.u("no data")}function gg(a,b,c,d){var e={},f=a.I[b].Bb,g=0,h=null;0<=c&&c=b[1][0]?b[1]:void 0,e=d?b[2]:b[1],f=wf(a,d,a.ga);if(!e)return a.u("begin assemble at "+L(a,f.B,18)),a.V=!0,K(a.G),!0;var g=e.match(/^(['"]?)(.*?)(\.klm|\.mac|\.html|\.txt|)\1$/i);if(g&&(g[1]||g[3])){f=wf(a,d);if(a.va)a.u("assembly already in progress");else{var h=g[2]+g[3];g[3]||(c+="s");var k=f.B,l=a.va=new Og(a);Pg(l,h,k,c,function(b,c){if(!b)try{var d=l.J;null==d&&(d=k);hg(a,l.U,d)}catch(v){"number"==typeof v?b=v||-1:(a.u(v.message), +b=-1)}b&&a.u("error ("+b+") processing "+(c||h));a.va=null;b||rd(a)})}return!1}b.shift();b.shift();b.shift();b=$f(a,e,b.join(""),f.B||0);0<=b&&(a.xb(f,b),a.u(Sf(a,f)));return!0}function Qg(a,b){var c=b.match(/^\s*([A-Z_]?[A-Z0-9_]*)\s*(=?)\s*(.*)$/i);if(c){if(!c[1])return mf(a)||a.u("no variables"),!0;if(!c[2])return mf(a,c[1]);if(!c[3])return delete a.b[c[1]],!0;b=jf(a,c[3]);return void 0!==b?(a.b[c[1]]={value:b,Mb:void 0},!0):!1}a.u("invalid assignment:"+b);return!1} +function Rg(a,b,c){var d=null;b=wf(a,b);var e=fg(a,b,!0);if(e.length){var f;if(e[0]){var g="";(f=b.B-e[1])&&(g=" + "+n(f,4,!0));f=e[0]+" ("+L(a,e[1],18)+")"+g;c&&a.u(f);d=f}4b){a.u("unknown register: "+f);return}f=0;var h=a.v;switch(b){case Bf:G(h, +g);sf(a.M,h.i);break;case Ef:Ed(h,g);break;case Ff:f=131072;break;case Gf:f=65536;break;case Hf:f=32768;break;case If:f=8192;break;case Jf:f=32;break;case Kf:f=262144}f&&(h.j=g?h.j|f:h.j&~f);K(a.G);a.u("updated registers:")}}a.u(eg(a,e));c&&(sf(a.M,Gd(d)),Qf(a,L(a,a.M.B,18)))}}function Sg(a,b){b=Ma(b);var c=b.match(/^(['"])(.*?)\1$/);c?1h[0].indexOf("+"))){var l=h[0]+":";h[2]&&(l+=" "+h[2]);a.u(l)}h[3]&&(g=h[3],f=null);h=a.ga;l=b;h.B=l.B;h.ab=l.ab;h.pa=l.pa;h.T=l.T;a.u(Sf(a,b,g,f));e-=b.B-k;c++}} +function dg(a,b,c){var d=!0;try{b.length&&"end"!=b?c||a.u(Of+b):(a.V&&(a.u("ended assemble at "+L(a,a.ga.B,18)),a.V=!1),b="");var e=b.charAt(0);if('"'==e||"'"==e)return!0;a.Y=null;if(Wb(a)&&0B||"z"va.length&&(a.u("note: only "+va.length+" available"),ia=va.length);ma-=ia;0>ma&&(null==va[va.length-1].B?(ia=ma+ia,ma=0):ma+=va.length);var Yd=[];"call"==qg&&(Ib=1E5,Yd=["CALL"]);for(void 0!==pg&&a.u(ia+" instructions earlier:");0=va.length&&(ma=0);a.Aa=ia;sg++;Ib--}}sg||(a.u("no "+rg+"history available"),a.Aa=void 0)}else{var Sa=0,vg="ds"==nb,Kb=wf(a,ua,a.na);Ha&&("l"==Ha.charAt(0)?(Ha=Ha.substr(1)||ki,Sa=df(a,Ha)):Sa=wf(a,Ha).B-Kb.B,0>Sa&&(Sa=0),65536Pc?".":String.fromCharCode(Pc);be-=7}}Ta&&(Ta+="\n");Ta=vg?Ta+(Ia+","):Ta+(ua+": "+Ia+(0>yg?" "+xg:""))}Ta&&a.u(Ta);a.T=mi}}}break;case "e":if("else"==k[0])break;var zg=k[0],ce=k[1];if("e"==zg||"ew"==zg){var pi=a.La;var qi=a.xb}else ce=null;if(null==ce)a.u("edit memory commands:"),a.u("\tew [a] [...] edit words at address a");else for(var de=wf(a,ce,a.na),ee=2;eefe;){for(var Ua=null,ti=256;65536>Nb.B>>>0;){ge.B=a.La(Nb,2);if(null==Nb.B||!ti--)break;if(!(ge.B&1)){for(var ui=a,Qc=ge,Dg=null,Ob=Qc.B,Eg=Ob,he=1;6>=he&&Ob;he++){if(2Kg)a.u("step commands:"),a.u("\tp\tstep over instruction"),a.u("\tpr\tstep over instruction with register update");else if(a.O)a.u("step in progress");else{var Lg=Y(a.v.i);a.La(Lg);a.O?(a.Qa(a.i,Lg,!0),Mf(a)||(a.G&&wd(a.G),a.O=0)):Tg(a,Kg?"tr":"t")}break;case "r":if("reset"==b){a.G&&a.G.reset();break}Pf(a,k);break;case "s":a:switch(k[1]){case "base":if(k[2]){var qb=+k[2]; +if(2==qb||8==qb||10==qb||16==qb)a.T=qb;else{a.u("invalid base: "+qb);break}}a.u("default base: "+a.T);break;case "cs":var Qb;void 0!==k[3]&&(Qb=+k[3]);switch(k[2]){case "int":a.v.oa=Qb;break;case "start":a.v.Ga=Qb;break;case "stop":a.v.ta=Qb;break;default:a.u("unknown cs option");break a}void 0!==Qb&&od(a.v);a.u("checksums "+(a.v.A.Sa?"enabled":"disabled"));break;case "sp":void 0!==k[2]&&(td(a.v,+k[2])||a.u("warning: using 1x multiplier, previous target not reached"));a.u("target speed: "+(a.v.ba.toFixed(2)+ +"Mhz")+" ("+a.v.ga+"x)");break;default:if(k[1]){a.u("unknown option: "+k[1]);break}case "?":a.u("debugger options:"),a.u("\tbase #\t\tset default base to #"),a.u("\tcs int #\tset checksum cycle interval to #"),a.u("\tcs start #\tset checksum cycle start count to #"),a.u("\tcs stop #\tset checksum cycle stop count to #"),a.u("\tsp #\t\tset speed multiplier to #")}break;case "t":Tg(a,k[0],k[1]);break;case "u":Qf(a,k[1],k[2],8);break;case "v":if("var"==k[0]){Qg(a,b.substr(3))||(d=!1);break}if("ver"== +k[0]){a.u((bc||"PDP10")+" version 1.37.1 ("+a.v.ib+",RELEASE)");a.u(window?window.navigator.userAgent:"");break}f=!0;break;case "?":if(k[1]){Sg(a,b.substr(1));break}var ie="commands:",je;for(je in Vg)ie+="\n"+La(je,9)+Vg[je];Hd(a)||(ie+="\nnote: history disabled if no exec breakpoints");a.u(ie);break;default:f=!0}f&&(a.u("unknown command: "+b),d=!1)}}catch(Ng){a.u("Debugger "+(Ng.stack||Ng.message)),d=!1}return d} +function rd(a,b,c){null!=b&&(a.Fa=Ye(a,b,c));for(;b=a.Fa.shift();)if(!dg(a,b))return!1;return!0} +var Vg={"?":"help/print","a [#]":"assemble","b [#]":"breakpoint",c:"clear output","d [#]":"dump memory","e [#]":"edit memory","g [#]":"go [to #]",h:"halt","if":"eval expression","int [#]":"request interrupt",k:"stack trace",ln:"list nearest symbol(s)",m:"messages",p:"step over",print:"print expression",r:"dump/set registers",reset:"reset machine",s:"set options","t [#]":"trace","u [#]":"unassemble","var":"assign variable",ver:"print version"},Xf=20,Yf=".WORD HLL HLLZ HLLO HLLE HRL HRLZ HRLO HRLE HRR HRRZ HRRO HRRE HLR HLRZ HLRO HLRE MOVE MOVS MOVN MOVM EXCH BLT PUSH POP LDB DPB IBP ILDB IDPB SETZ SETO SETA SETCA SETM SETCM AND ANDCA ANDCM ANDCB IOR ORCA ORCM ORCB XOR EQV LSH LSHC ROT ROTC ADD SUB MUL IMUL DIV IDIV ASH ASHC FSC FADR FSBR FMPR FDVR DFN UFA FAD FSB FMP FDV AOBJP AOBJN CAI CAM JUMP SKIP AOJ AOS SOJ SOS TR TL TD TS XCT JFFO JFCL JSR JSP JRST JSA JRA PUSHJ POPJ BLKI DATAI BLKO DATAO CONO CONI CONSZ CONSO UUO JOV JCRY0 JCRY1 JCRY JFOV HALT JRSTF JEN".split(" "), +Bf=0,Cf=1,Df=2,Ef=3,Ff=4,Gf=5,Hf=6,If=7,Jf=8,Kf=9,Af="PC RA EA PS OV C0 C1 BI ND PD".split(" "),Wg={},Tf=(Wg[28672]={0:101},Wg[32704]={5632:64,5696:63,5760:58,5824:27,5888:28,5952:25,6016:29,6080:26,10240:56,10304:48,10368:46,10432:84,10496:57,10560:49,10624:47,10752:21,10816:22,10880:69,10944:70,11008:88,11072:85,11136:83,11264:91,11328:23,11392:24,11456:92,11520:86,11584:87,11648:89,11712:90},Wg[32512]={6144:65,6400:59,6656:66,6912:60,7168:67,7424:61,7680:68,7936:62,8192:17,8448:18,8704:19,8960:Xf, +9216:53,9472:52,9728:55,9984:54,11776:50,12032:51,16384:30,16640:36,16896:37,17152:34,17408:38,17664:32,17920:44,18176:40,18432:39,18688:45,18944:33,19200:41,19456:35,19712:42,19968:43,20224:31,20480:1,20736:5,20992:2,21248:6,21504:3,21760:7,22016:4,22272:8,22528:9,22784:13,23040:10,23296:14,23552:11,23808:15,24064:12,24320:16},Wg[32256]={12288:71,12800:72,13312:73,13824:74,14336:75,14848:76,15360:77,15872:78},Wg[29248]={24576:79,24640:80,25088:81,25152:82},Wg[28700]={28672:93,28676:94,28680:95,28684:96, +28688:97,28692:98,28696:99,28700:100},Wg),Uf=["","I","M","S"],Vf=" L E LE A GE N G".split(" "),Wf="N NE NA NN Z ZE ZA ZN C CE CA CN O OE OA ON".split(" "),Zf=[{0:85,8:102,4:103,2:104,6:105,1:106},{0:88,4:107,2:108,10:109}],Lf=1E3,Of=">> ";hb(function(){for(var a=w(document,u,"debugger"),b=0;bb.indexOf(":")&&0<=".MAC.KLM".indexOf(b.slice(-4).toUpperCase())&&(b+=".txt");Va(b,null,!0,function(b,d,e){if(e)a.done&&a.done(e,b);else{e=d;if(Fa(b,".html")){e="";for(var c=/
    ([\s\S]*?)<\/pre>/gi;b=c.exec(d);)b=b[1],0<=b.indexOf("&")&&(b=b.replace(/</gi,"<").replace(/>/gi,">").replace(/&/gi,"&")),e+=b;(b=e.match(/&[a-z]+;/i))&&$g(a,"unrecognized HTML entity '"+b[0]+"'")}d=e.split(/(\r?\n)/);
    +if(d.length&1){if(b=d.pop())$g(a,"unexpected line '"+b+"'"),d.push(b),d.push("")}else $g(a,"unexpected number of lines ("+d.length+")");a.D=a.D.concat(d);a.N[a.R]=d.length>>1;a.R++;setTimeout(function(){Zg(a)},0)}})}}
    +function Yg(a){if(0<=a.W.indexOf("p"))a.u(a.D.join(""));else{var b=lf(a.b);ah(a,"APR",0);ah(a,"PI",4);try{for(var c=0;ca.W.indexOf("d")&&(a.b.b=b)}}
    +function ch(a,b,c,d,e){var f;null!=a.w&&(b=hh(a,b));for(var g=!0,h="";g;){var k=b.match(a.ga);if(!k||k[5]&&";"!=k[5].charAt(0))return a.error("failed to parse line '"+b+"'"),!1;g=!1;h=k[2].toUpperCase();if(h==ih||h==jh)c=null;if(c){for(f=0;fv)break;q=v+1;var J=v+l.length,Oc="",ta="";v&&(Oc=b[v-1]).match(/[0-9A-Z$%.]/i)||!(J>=b.length)&&(ta=b[J]).match(/[0-9A-Z$%.]/i)||
    +("'"==Oc&&v--,"'"==ta&&J++,b=b.substr(0,v)+p+b.substr(J),q=v+p.length,g=!0)}}}c=null}if(a.i&&(1==a.i&&(f=b.indexOf(a.C),0<=f?(a.i++,b=b.substr(f+1)):a.error("expected "+a.S+" definition in '"+b+"'")),1=I?a.X+=I:a.error("unrecognized BLOCK expression '"+h+"'");break;case wh:h=c;b=k=0;for(c=36;I=xh(a,h);){h=h.substr(I.length).trim();d=I;if(e=I.match(/^\((.*)\)\s*(.*)$/))e[1]&&(k=fh(a,"^D"+e[1])),d=e[2];if(k){d=d?fh(a,d):0;if(void 0===d||0>k||36c&&yh(a,b);break;case zh:(h=c)?(a.J=fh(a,h),void 0===a.J&&a.error("unrecognized END expression '"+h+"'")):a.J=a.ka;break;case Ah:Bh(a,c);break;case Ch:dh(a);break;case Dh:a.X=fh(a,c)||0;break;case Eh:eh(a);break;case Fh:Bh(a,c.replace(",",",,"));break;case Gh:case Hh:case Ih:case Jh:case Kh:case Lh:case Mh:case Nh:case Oh:case Ph:case Qh:case Rh:case ih:case jh:case Sh:case Th:oh(a,h,k);break;case Uh:h=Vh(a,c);for(I=0;Id.Da&&Z(a,d.ja);break;case Ph:0>=d.Da&&Z(a,d.ja);break;case Hh:case Qh:case Ih:case Nh:d.Da&&Z(a,d.ja);break;case ih:case jh:for(b=0;ba.Ca&&(a.Ca=a.X);a.X=0}function fi(a){if(a.G.length){var b=a.G[a.G.length-1].name;b&&a.M.push({name:b,U:a.U,ea:a.ea});b=a.G.pop();a.U=b.U;a.ea=b.ea;a.X=b.X;a.Ca=b.Ca;a.G.length||-1==a.Ca||a.error("scope restore error")}else a.error("scope nesting error")}
    +function xh(a,b){var c=void 0===c?",":c;for(var d=0,e=!1,f=null,g=0;d"==h&&0>--g){a.error("missing bracket(s) in '"+b+"'");break}}}g?0f&&(g=g.replace(/\.([^0-9]|$)/g,L(a.b,d,-1)+"$1"),f=jf(a.b,g,c),void 0===f&&a.error("unable to parse expression '"+b+"'",e));return f}
    +function nh(a,b){for(var c=0,d="",e=0,f=-1,g=b.length;e=--c){g=e;break}}0>c&&a.error("missing bracket(s) in '"+b+"'");0<=f&&(d=b.substr(f,g-f));return d}function bh(a,b){b=void 0===b?a.ha:b;for(var c=0;b>a.N[c];)if(b-=a.N[c],cd?c="":(c=b.substr(d+1),b=b.substr(0,d),a.w=null);a.F+=b}if(null==a.w){d=b=0;var e=a.F.length;a.S==th&&e++;for(var f=0;f=k&&(k-=32),k=k+32&63);d+=k*Math.pow(2,g);g-=h;b++;0>g&&(yh(a,d),b=0)}b&&yh(a,d)}return c}
    +function oh(a,b,c){var d,e;a.C="<";a.O=">";var f=d=e=[];if(b==Gh){var g=c.match(/([A-Z$%.][0-9A-Z$%.]*)\s*(\([^)]*\)|)\s*,?\s*(<|)([\s\S]*)/i);if(!g)return a.error("unrecognized "+b+" in '"+c+"'"),c;var h=g[1];if(g[2]&&","!=g[2]){d=f=Vh(a,g[2],!0);b=[];for(c=0;c");0>l&&(l=d[c].length);b[c]=d[c].substr(k,l-k);d[c]=d[c].substr(0,k)}}d=b}k=hi;b=3}else if(b==Sh){a.C="[";a.O="]";g=c.match(/([A-Z$%.][0-9A-Z$%.]*)\s*(\[)([\s\S]*)/i);
    +if(!g)return a.error("unrecognized "+b+" in '"+c+"'"),c;h=g[1];k=di;b=2}else if(b==ph)a.C="[",a.O="]",h="?"+Ca(++a.ba,5),a.v[h]&&a.error("literal symbol '"+h+"' redefined"),g=[c[0],c.substr(1)],k=ii,b=0;else if(b==ih||b==jh){a.j||a.error(b+" outside of macro");g=c.match(/([A-Z$%.][0-9A-Z$%.]*)\s*,\s*(<|)([\s\S]*)/i);if(!g)return a.error("unrecognized "+b+" operands '"+c+"'"),c;for(k=0;k=D)&&$g(a,"truncated value "+Ba(b)+" at location "+Ba(c)+" to "+Ba(d));return d}Og.prototype.error=function(a,b){throw Error("error in "+bh(this,b)+": "+a);};
    +function $g(a,b){a.u("warning in "+bh(a,void 0)+": "+b)}Og.prototype.u=function(a){this.b?this.b.u(a):console.log(a)};
    +var lh=1,mh=4,sh="ASCII",th="ASCIZ",vh="BLOCK",wh="BYTE",Gh="DEFINE",zh="END",Ah="EXP",Hh="IF1",Ih="IFDEF",Jh="IFDIF",Kh="IFE",Lh="IFG",Mh="IFGE",Nh="IFIDN",Oh="IFL",Ph="IFLE",Qh="IFN",Rh="IFNDEF",ih="IRP",jh="IRPC",Wh="LALL",Ch="LIT",ph="LITERAL",Xh="LIST",Dh="LOC",Yh="NOSYM",Sh="OPDEF",Zh="PAGE",Uh="PURGE",Th="REPEAT",uh="SIXBIT",$h="SUBTTL",ai="TITLE",Eh="VAR",bi="XALL",Fh="XWD",ci="XLIST",hi=-1,di=-2,ii=-3,gi=-4;
    +function ji(a,b,c){t.call(this,"Computer",a,33554432);this.A.aa=!1;this.S=null;xi(this,b);this.O=md(this,"autoPower",a,6);this.w=0;this.Y=+a.busWidth||+a.buswidth;this.M=this.I=this.N=null;this.L=this.W=!1;this.K=this.C=null;this.V=this.R=!1;this.ba=md(this,"url")||"";(Math.random()+.1).toString(36);this.i=yi(this);if(this.v=Eb("CPU",this.id)){this.D=Eb("Debugger",this.id);this.H=new Lc({id:this.Za+".bus",busWidth:this.Y},this.v,this.D);var d=Cb(this.id);if(this.F=(this.j=Eb("Panel",this.id))&&this.j.J.print)for(b=
    +0;b\nLicense: GPL version 3 or later ");for(b=0;bzi){if(Ai(d,this.M)){this.C=new F(this,"1.37.1",Ji);Ai(this.C)&&(Ki(this,d),a=Li,Mi(this.C));this.C.set(Gi,Oa());Ni(this.C);var e=this.b&&!this.L;if(a==Hi||yb("Click OK to restore the previous "+bc+" machine state, or CANCEL to reset the machine.")){if(c=Fi(d)){var f=d.get("code"),g=d.get("data");f&&("ok"==f?Ai(d,g):("error"==f&&"no machine state"!=
    +g?(this.ia("Error: "+g),"unable to verify user"==g&&(ab(Oi,""),this.i=null)):this.u(f+": "+g),Mi(d),Ai(d)?(c=Fi(d),e=!0):c=!1))}e&&Di(this,c?d:null)}else a==Li&&d.clear()}else Di(this);delete this.M;delete this.K}e=Cb(this.id);for(f=0;fa[1];a=a[2];this.V=!0;this.A.aa=!0;var d=this.J.power;d&&(d.textContent="Shutdown");this.v&&(Pi(this,this.v,b,c,a),K(this,-2),this.v.fa());this.R&&(Ki(this,b),b.clear());!c&&this.C&&(this.C.clear(),delete this.C);this.w=0};
    +function Ki(a,b){if(yb("There may be a problem with your "+bc+" machine.\n\nTo help us diagnose it, click OK to send this "+bc+" machine state to http://www.pcjs.org.")){var c=a.ba;a=a.i||"";b=b.toString();var d={};d.app=bc;d.ver="1.37.1";d.url=c;d.user=a;d.type="bug";d.data=b;Va("http://www.pcjs.org/api/v1/report",d,!0)}}
    +function Ug(a,b,c){var d="none";if(a.w)return null;a.w--;var e=new F(a,"1.37.1"),f=new F(a,"1.37.1",Ei),g=Oa();f.set(Gi,g);e.set(Gi,g);e.set(Qi,"1.37.1");e.set(Ri,window?window.location.href:null);e.set(Si,window?window.navigator.userAgent:"");if(a.v&&a.v.qa){c&&(b&&(a.v.A.fa=a.v.A.P),H(a.v));var h=a.v.qa(b,c);"object"===typeof h&&e.set(a.v.id,h);c&&(a.v.A.aa=!1,!1===h&&(d=null))}g=Cb(a.id);for(var k=0;k=d||30<=(c.gb+=d))&&(e.textContent=c.A.P?c.Y.toFixed(2)+"Mhz":"Stopped",c.gb=0)}if(a.j&&(a=a.j,b=b||0,a.L)){c=a.v.A.P;d=!!(a.v.C&8);if(0>=b||60<=(a.K+=b)){e=a.v.i;if(a.J.PC){var f=a.D&&a.D.T||8;e=e||0;e=8==f?Ba(e,void 0):n(e,void 0);a.J.PC.textContent!=e&&(a.J.PC.textContent=e)}a.K=0}-1>b?a.i=a.v.i:0g.indexOf("/")&&"/"==window.location.pathname.slice(-1)&&(g=window.location.pathname+g),e?"}"==e.slice(-1)?(e=e.slice(0,-1),1]*\sid=)(['"]).*?\2/,"$1$2"+c+"$2"+(e?" parms='"+e+"'":"")+(g?' url="'+g+'"':"")));f||(a=a.replace(/().*?(<\/xsl:variable>)/,
    +"$1PDPjs$2"),a=a.replace(/().*?(<\/xsl:variable>)/,"$1"+d+"$2"));g=null;if("<"==a.charAt(0))try{f||(a=a.replace(/\s*/g,"")),window.ActiveXObject||"ActiveXObject"in window?(g=new window.ActiveXObject("Microsoft.XMLDOM"),g.async=!1,g.loadXML(a)):g=(new window.DOMParser).parseFromString(a,"text/xml")}catch(q){g=null,a=q.message}else a="unrecognized XML: "+(255/g.exec(a)){var e=d[2];b("Loading "+e+"...");Va(e,null,!0,function(f,g,h){if(h||!g)c(a,"unable to resolve XML reference: "+d[0]+" ("+h+")");else{if(f=d[3])if(h=g.match(new RegExp("<"+d[1]+"[^>]*>"))){for(var k=h[0],l,p=/( [a-z]+=)(['"])(.*?)\2/gi;l=p.exec(f);)k=0>k.toLowerCase().indexOf(l[1].toLowerCase())?k.replace(">",l[0]+">"):k.replace(new RegExp(l[1]+"(['\"])(.*?)\\1"),l[0]);h[0]!=k&&(g=g.replace(h[0],k))}else{c(a,"missing <"+d[1]+
    +"> in "+e);return}g=g.replace(/<\?xml[^>]*>[\r\n]*/,"");a=a.replace(d[0],g);$i(a,b,c)}})}else c(a,null)}
    +function aj(a,b,c,d,e){function f(a){if(void 0===k){var b=h&&w(h,"machine-warning");k=b&&b[0]||h}k&&(k.innerHTML=Ga(a))}function g(a){f("Error: "+a);l&&(--Xi||lb(!0));l=!1}var h,k,l=!0;Xi++;wb[b]={};try{if(h=document.getElementById(b)){var p;if("object"==typeof resources&&(p=resources.css)){var q=document.head||document.getElementsByTagName("head")[0],B=document.createElement("style");B.type="text/css";B.styleSheet?B.styleSheet.cssText=p:B.appendChild(document.createTextNode(p));q.appendChild(B)}d||
    +(p=a,"pdp"==a.substr(0,3)&&(p="pdpjs"),d="/versions/"+p+"/1.37.1/components.xsl");p=function(e,k){k?Yi(d,null,a,null,!1,f,function(a,e){e?(vb(b,d,a),f("Processing "+c+"..."),window.ActiveXObject||"ActiveXObject"in window?(e=k.transformNode(e))?(h.outerHTML=e,--Xi||lb(!0)):g("transformNodeToObject failed"):document.implementation&&document.implementation.createDocument?(a=new XSLTProcessor,a.importStylesheet(e),(e=a.transformToFragment(k,document))?h.parentNode?(h.parentNode.replaceChild(e,h),--Xi||
    +lb(!0)):g("invalid machine element: "+b):g("transformToFragment failed")):g("unable to transform XML: unsupported browser")):g(a)}):g(e)};"<"!=c.charAt(0)?Yi(c,b,a,e,!0,f,p):Zi(c,null,b,a,e,!1,f,p)}else g("missing machine element: "+b)}catch(v){g(v.message)}return l}window.embedPDP10=function(a,b,c,d){lb(!1);return aj("pdp10",a,b,c,d)};window.embedPDP11=function(a,b,c,d){lb(!1);return aj("pdp11",a,b,c,d)};
    +window.commandMachine=function(a,b,c,d,e,f){if("script"==e){d=!1;c+=".machine";if(!f)delete Gb[c],d=!0;else if("string"==typeof f&&!Gb[c]){d=!0;e=Gb;for(var g=c,h=f.length,k=[],l=[],p="",q=null,B=0;B  1        G       (Ground)
    + *     TD      2  <->  3        RD      (Received Data)
    + *     RD      3  <->  2        TD      (Transmitted Data)
    + *     RTS     4  <->  5        CTS     (Clear To Send)
    + *     CTS     5  <->  4        RTS     (Request To Send)
    + *     DSR   6+8  <->  20       DTR     (Data Terminal Ready)
    + *     SG      7  <->  7        SG      (Signal Ground)
    + *     DTR    20  <->  6+8      DSR     (Data Set Ready + Carrier Detect)
    + *     RI     22  <->  22       RI      (Ring Indicator)
    + *
    + * TODO: Move these definitions to a more appropriate shared file at some point.
    + */
    +var RS232 = {
    +    RTS: {
    +        PIN:  4,
    +        MASK: 0x00000010
    +    },
    +    CTS: {
    +        PIN:  5,
    +        MASK: 0x00000020
    +    },
    +    DSR: {
    +        PIN:  6,
    +        MASK: 0x00000040
    +    },
    +    CD: {
    +        PIN:  8,
    +        MASK: 0x00000100
    +    },
    +    DTR: {
    +        PIN:  20,
    +        MASK: 0x00100000
    +    },
    +    RI: {
    +        PIN:  22,
    +        MASK: 0x00400000
    +    }
    +};
    +
    +/*
    + * NODE should be true if we're running under NodeJS (eg, command-line), false if not (eg, web browser)
    + */
    +var NODE = false;
    +
    +
    +/**
    + * @copyright http://pcjs.org/modules/shared/lib/dumpapi.js (C) Jeff Parsons 2012-2017
    + */
    +
    +/*
    + * Our "DiskDump API", such as it was, used to look like:
    + *
    + *      http://jsmachines.net/bin/convdisk.php?disk=/disks/pc/dos/ibm/2.00/PCDOS200-DISK1.json&format=img
    + *
    + * To make it (a bit) more "REST-like", the above request now looks like:
    + *
    + *      http://www.pcjs.org/api/v1/dump?disk=/disks/pc/dos/ibm/2.00/PCDOS200-DISK1.json&format=img
    + *
    + * Similarly, our "FileDump API" used to look like:
    + *
    + *      http://jsmachines.net/bin/convrom.php?rom=/devices/pc/rom/5150/1981-04-24/PCBIOS-REV1.rom&format=json
    + *
    + * and that request now looks like:
    + *
    + *      http://www.pcjs.org/api/v1/dump?file=/devices/pc/rom/5150/1981-04-24/PCBIOS-REV1.rom&format=json
    + *
    + * I don't think it makes sense to avoid "query" parameters, because blending the path of a disk image with the
    + * the rest of the URL would be (a) confusing, and (b) more work to parse.
    + */
    +var DumpAPI = {
    +    ENDPOINT:       "/api/v1/dump",
    +    QUERY: {
    +        DIR:        "dir",      // value is path of a directory (DiskDump only)
    +        DISK:       "disk",     // value is path of a disk image (DiskDump only)
    +        FILE:       "file",     // value is path of a ROM image file (FileDump only)
    +        IMG:        "img",      // alias for DISK
    +        PATH:       "path",     // value is path of a one or more files (DiskDump only)
    +        FORMAT:     "format",   // value is one of FORMAT values below
    +        COMMENTS:   "comments", // value is either "true" or "false"
    +        DECIMAL:    "decimal",  // value is either "true" to force all numbers to decimal, "false" or undefined otherwise
    +        MBHD:       "mbhd",     // value is hard drive size in Mb (formerly "mbsize") (DiskDump only) (DEPRECATED)
    +        SIZE:       "size"      // value is target disk size in Kb (supersedes "mbhd") (DiskDump only)
    +    },
    +    FORMAT: {
    +        JSON:       "json",     // default
    +        JSON_GZ:    "gz",       // gzip is currently used ONLY for compressed JSON
    +        DATA:       "data",     // same as "json", but built without JSON.stringify() (DiskDump only)
    +        HEX:        "hex",      // deprecated
    +        OCTAL:      "octal",    // displays data as octal words
    +        BYTES:      "bytes",    // displays data as hex bytes; normally used only when comments are enabled
    +        WORDS:      "words",    // displays data as hex words; normally used only when comments are enabled
    +        LONGS:      "longs",    // displays data as dwords
    +        IMG:        "img",      // returns the raw disk data (ie, using a Buffer object) (DiskDump only)
    +        ROM:        "rom"       // returns the raw file data (ie, using a Buffer object) (FileDump only)
    +    }
    +};
    +
    +/*
    + * Because we use an overloaded API endpoint (ie, one that's shared with the FileDump module), we must
    + * also provide a list of commands which, when combined with the endpoint, define a unique request.
    + */
    +DumpAPI.asDiskCommands = [DumpAPI.QUERY.DIR, DumpAPI.QUERY.DISK, DumpAPI.QUERY.PATH];
    +DumpAPI.asFileCommands = [DumpAPI.QUERY.FILE];
    +
    +
    +
    +/**
    + * @copyright http://pcjs.org/modules/shared/lib/reportapi.js (C) Jeff Parsons 2012-2017
    + */
    +
    +var ReportAPI = {
    +    ENDPOINT:       "/api/v1/report",
    +    QUERY: {
    +        APP:        "app",
    +        VER:        "ver",
    +        URL:        "url",
    +        USER:       "user",
    +        TYPE:       "type",
    +        DATA:       "data"
    +    },
    +    TYPE: {
    +        BUG:        "bug"
    +    },
    +    RES: {
    +        OK:         "Thank you"
    +    }
    +};
    +
    +
    +
    +/**
    + * @copyright http://pcjs.org/modules/shared/lib/userapi.js (C) Jeff Parsons 2012-2017
    + */
    +
    +/*
    + * Examples of User API requests:
    + *
    + *      web.getHost() + UserAPI.ENDPOINT + '?' + UserAPI.QUERY.REQ + '=' + UserAPI.REQ.VERIFY + '&' + UserAPI.QUERY.USER + '=' + sUser;
    + */
    +var UserAPI = {
    +    ENDPOINT:       "/api/v1/user",
    +    QUERY: {
    +        REQ:        "req",      // specifies a request
    +        USER:       "user",     // specifies a user ID
    +        STATE:      "state",    // specifies a state ID
    +        DATA:       "data"      // specifies state data
    +    },
    +    REQ: {
    +        CREATE:     "create",   // creates a user ID
    +        VERIFY:     "verify",   // requests verification of a user ID
    +        STORE:      "store",    // stores a machine state on the server
    +        LOAD:       "load"      // loads a machine state from the server
    +    },
    +    RES: {
    +        CODE:       "code",
    +        DATA:       "data"
    +    },
    +    CODE: {
    +        OK:         "ok",
    +        FAIL:       "error"
    +    },
    +    FAIL: {
    +        DUPLICATE:  "user already exists",
    +        VERIFY:     "unable to verify user",
    +        BADSTATE:   "invalid state parameter",
    +        NOSTATE:    "no machine state",
    +        BADLOAD:    "unable to load machine state",
    +        BADSTORE:   "unable to save machine state"
    +    }
    +};
    +
    +
    +
    +/**
    + * @copyright http://pcjs.org/modules/shared/lib/keys.js (C) Jeff Parsons 2012-2017
    + */
    +
    +var Keys = {
    +    /*
    +     * Keys and/or key combinations that generate common ASCII codes.
    +     *
    +     * NOTE: If you're looking for a general-purpose ASCII code table, see Str.ASCII in strlib.js;
    +     * if something's missing, that's probably the more appropriate table to add it to.
    +     *
    +     * TODO: The Closure Compiler doesn't inline all references to these values, at least those with
    +     * quoted property names, which is why I've 'unquoted' as many of them as possible.  One solution
    +     * would be to add mnemonics for all of them, not just the non-printable ones (eg, SPACE instead
    +     * of ' ', AMP instead of '&', etc.)
    +     */
    +    ASCII: {
    +          BREAK:  0, CTRL_A:  1, CTRL_B:  2, CTRL_C:  3, CTRL_D:  4, CTRL_E:  5, CTRL_F:  6, CTRL_G:  7,
    +         CTRL_H:  8, CTRL_I:  9, CTRL_J: 10, CTRL_K: 11, CTRL_L: 12, CTRL_M: 13, CTRL_N: 14, CTRL_O: 15,
    +         CTRL_P: 16, CTRL_Q: 17, CTRL_R: 18, CTRL_S: 19, CTRL_T: 20, CTRL_U: 21, CTRL_V: 22, CTRL_W: 23,
    +         CTRL_X: 24, CTRL_Y: 25, CTRL_Z: 26,
    +            ' ': 32,    '!': 33,    '"': 34,    '#': 35,    '$': 36,    '%': 37,    '&': 38,    "'": 39,
    +            '(': 40,    ')': 41,    '*': 42,    '+': 43,    ',': 44,    '-': 45,    '.': 46,    '/': 47,
    +            '0': 48,    '1': 49,    '2': 50,    '3': 51,    '4': 52,    '5': 53,    '6': 54,    '7': 55,
    +            '8': 56,    '9': 57,    ':': 58,    ';': 59,    '<': 60,    '=': 61,    '>': 62,    '?': 63,
    +            '@': 64,     A:  65,     B:  66,     C:  67,     D:  68,     E:  69,     F:  70,     G:  71,
    +             H:  72,     I:  73,     J:  74,     K:  75,     L:  76,     M:  77,     N:  78,     O:  79,
    +             P:  80,     Q:  81,     R:  82,     S:  83,     T:  84,     U:  85,     V:  86,     W:  87,
    +             X:  88,     Y:  89,     Z:  90,    '[': 91,    '\\':92,    ']': 93,    '^': 94,    '_': 95,
    +            '`': 96,     a:  97,     b:  98,     c:  99,     d: 100,     e: 101,     f: 102,     g: 103,
    +             h:  104,    i: 105,     j: 106,     k: 107,     l: 108,     m: 109,     n: 110,     o: 111,
    +             p:  112,    q: 113,     r: 114,     s: 115,     t: 116,     u: 117,     v: 118,     w: 119,
    +             x:  120,    y: 121,     z: 122,    '{':123,    '|':124,    '}':125,    '~':126,   DEL: 127
    +    },
    +    /*
    +     * Browser keyCodes we must pay particular attention to.  For the most part, these are non-alphanumeric
    +     * or function keys, some which may require special treatment (eg, preventDefault() if returning false on
    +     * the initial keyDown event is insufficient).
    +     *
    +     * keyCodes for most common ASCII keys can simply use the appropriate ASCII code above.
    +     *
    +     * Most of these represent non-ASCII keys (eg, the LEFT arrow key), yet for some reason, browsers defined
    +     * them using ASCII codes (eg, the LEFT arrow key uses the ASCII code for '%' or 37).
    +     */
    +    KEYCODE: {
    +        /* 0x08 */ BS:          8,          // BACKSPACE        (ASCII.CTRL_H)
    +        /* 0x09 */ TAB:         9,          // TAB              (ASCII.CTRL_I)
    +        /* 0x0A */ LF:          10,         // LINE FEED        (ASCII.CTRL_J) (TODO: Determine if any key actually generates this)
    +        /* 0x0D */ CR:          13,         // CARRIAGE RETURN  (ASCII.CTRL_M)
    +        /* 0x10 */ SHIFT:       16,
    +        /* 0x11 */ CTRL:        17,
    +        /* 0x12 */ ALT:         18,
    +        /* 0x13 */ PAUSE:       19,         // PAUSE/BREAK
    +        /* 0x14 */ CAPS_LOCK:   20,
    +        /* 0x1B */ ESC:         27,
    +        /* 0x20 */ SPACE:       32,
    +        /* 0x21 */ PGUP:        33,
    +        /* 0x22 */ PGDN:        34,
    +        /* 0x23 */ END:         35,
    +        /* 0x24 */ HOME:        36,
    +        /* 0x25 */ LEFT:        37,
    +        /* 0x26 */ UP:          38,
    +        /* 0x27 */ RIGHT:       39,
    +        /* 0x27 */ FF_QUOTE:    39,
    +        /* 0x28 */ DOWN:        40,
    +        /* 0x2C */ FF_COMMA:    44,
    +        /* 0x2C */ PRTSC:       44,
    +        /* 0x2D */ INS:         45,
    +        /* 0x2E */ DEL:         46,
    +        /* 0x2E */ FF_PERIOD:   46,
    +        /* 0x2F */ FF_SLASH:    47,
    +        /* 0x30 */ ZERO:        48,
    +        /* 0x31 */ ONE:         49,
    +        /* 0x32 */ TWO:         50,
    +        /* 0x33 */ THREE:       51,
    +        /* 0x34 */ FOUR:        52,
    +        /* 0x35 */ FIVE:        53,
    +        /* 0x36 */ SIX:         54,
    +        /* 0x37 */ SEVEN:       55,
    +        /* 0x38 */ EIGHT:       56,
    +        /* 0x39 */ NINE:        57,
    +        /* 0x3B */ FF_SEMI:     59,
    +        /* 0x3D */ FF_EQUALS:   61,
    +        /* 0x5B */ CMD:         91,         // aka WIN
    +        /* 0x5B */ FF_LBRACK:   91,
    +        /* 0x5C */ FF_BSLASH:   92,
    +        /* 0x5D */ RCMD:        93,         // aka MENU
    +        /* 0x5D */ FF_RBRACK:   93,
    +        /* 0x60 */ NUM_0:       96,
    +        /* 0x60 */ NUM_INS:     96,
    +        /* 0x60 */ FF_BQUOTE:   96,
    +        /* 0x61 */ NUM_1:       97,
    +        /* 0x61 */ NUM_END:     97,
    +        /* 0x62 */ NUM_2:       98,
    +        /* 0x62 */ NUM_DOWN:    98,
    +        /* 0x63 */ NUM_3:       99,
    +        /* 0x63 */ NUM_PGDN:    99,
    +        /* 0x64 */ NUM_4:       100,
    +        /* 0x64 */ NUM_LEFT:    100,
    +        /* 0x65 */ NUM_5:       101,
    +        /* 0x65 */ NUM_CENTER:  101,
    +        /* 0x66 */ NUM_6:       102,
    +        /* 0x66 */ NUM_RIGHT:   102,
    +        /* 0x67 */ NUM_7:       103,
    +        /* 0x67 */ NUM_HOME:    103,
    +        /* 0x68 */ NUM_8:       104,
    +        /* 0x68 */ NUM_UP:      104,
    +        /* 0x69 */ NUM_9:       105,
    +        /* 0x69 */ NUM_PGUP:    105,
    +        /* 0x6A */ NUM_MUL:     106,
    +        /* 0x6B */ NUM_ADD:     107,
    +        /* 0x6D */ NUM_SUB:     109,
    +        /* 0x6E */ NUM_DEL:     110,        // aka PERIOD
    +        /* 0x6F */ NUM_DIV:     111,
    +        /* 0x70 */ F1:          112,
    +        /* 0x71 */ F2:          113,
    +        /* 0x72 */ F3:          114,
    +        /* 0x73 */ F4:          115,
    +        /* 0x74 */ F5:          116,
    +        /* 0x75 */ F6:          117,
    +        /* 0x76 */ F7:          118,
    +        /* 0x77 */ F8:          119,
    +        /* 0x78 */ F9:          120,
    +        /* 0x79 */ F10:         121,
    +        /* 0x7A */ F11:         122,
    +        /* 0x7B */ F12:         123,
    +        /* 0x90 */ NUM_LOCK:    144,
    +        /* 0x91 */ SCROLL_LOCK: 145,
    +        /* 0xAD */ FF_DASH:     173,
    +        /* 0xBA */ SEMI:        186,        // Firefox:  59 (FF_SEMI)
    +        /* 0xBB */ EQUALS:      187,        // Firefox:  61 (FF_EQUALS)
    +        /* 0xBC */ COMMA:       188,
    +        /* 0xBD */ DASH:        189,        // Firefox: 173 (FF_DASH)
    +        /* 0xBE */ PERIOD:      190,
    +        /* 0xBF */ SLASH:       191,
    +        /* 0xC0 */ BQUOTE:      192,
    +        /* 0xDB */ LBRACK:      219,
    +        /* 0xDC */ BSLASH:      220,
    +        /* 0xDD */ RBRACK:      221,
    +        /* 0xDE */ QUOTE:       222,
    +        /* 0xE0 */ FF_CMD:      224,        // Firefox only (used for both CMD and RCMD)
    +        //
    +        // The following biases use what I'll call Decimal Coded Binary or DCB (the opposite of BCD),
    +        // where the thousands digit is used to store the sum of "binary" digits 1 and/or 2 and/or 4.
    +        //
    +        // Technically, that makes it DCO (Decimal Coded Octal), but then again, BCD should have really
    +        // been called HCD (Hexadecimal Coded Decimal), so if "they" can take liberties, so can I.
    +        //
    +        // ONDOWN is a bias we add to browser keyCodes that we want to handle on "down" rather than on "press".
    +        //
    +        ONDOWN:                 1000,
    +        //
    +        // ONRIGHT is a bias we add to browser keyCodes that need to check for a "right" location (default is "left")
    +        //
    +        ONRIGHT:                2000,
    +        //
    +        // FAKE is a bias we add to signal these are fake keyCodes corresponding to internal keystroke combinations.
    +        // The actual values are for internal use only and merely need to be unique and used consistently.
    +        //
    +        FAKE:                   4000
    +    },
    +    /*
    +     * The set of values that a browser may store in the 'location' property of a keyboard event object
    +     * which we also support.
    +     */
    +    LOCATION: {
    +        LEFT:                   1,
    +        RIGHT:                  2,
    +        NUMPAD:                 3
    +    }
    +};
    +
    +/*
    + * Check the event object's 'location' property for a non-zero value for the following ONRIGHT keys.
    + */
    +Keys.KEYCODE.NUM_CR = Keys.KEYCODE.CR + Keys.KEYCODE.ONRIGHT;
    +
    +
    +/*
    + * Maps Firefox keyCodes to their more common keyCode counterparts; a number of entries in this table
    + * are no longer valid (if indeed they ever were), so they've been commented out.  It's likely that I
    + * simply extended this table to resolve additional differences in other browsers (ie, Opera), but without
    + * browser-specific checks, it's not safe to perform all the mappings shown below.
    + */
    +Keys.FF_KEYCODES = {};
    +Keys.FF_KEYCODES[Keys.KEYCODE.FF_SEMI]   = Keys.KEYCODE.SEMI;           //  59 -> 186
    +Keys.FF_KEYCODES[Keys.KEYCODE.FF_EQUALS] = Keys.KEYCODE.EQUALS;         //  61 -> 187
    +Keys.FF_KEYCODES[Keys.KEYCODE.FF_DASH]   = Keys.KEYCODE.DASH;           // 173 -> 189
    +Keys.FF_KEYCODES[Keys.KEYCODE.FF_CMD]    = Keys.KEYCODE.CMD;            // 224 -> 91
    +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_COMMA]  = Keys.KEYCODE.COMMA;       //  44 -> 188
    +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_PERIOD] = Keys.KEYCODE.PERIOD;      //  46 -> 190
    +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_SLASH]  = Keys.KEYCODE.SLASH;       //  47 -> 191
    +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_BQUOTE] = Keys.KEYCODE.BQUOTE;      //  96 -> 192
    +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_LBRACK  = Keys.KEYCODE.LBRACK;      //  91 -> 219
    +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_BSLASH] = Keys.KEYCODE.BSLASH;      //  92 -> 220
    +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_RBRACK] = Keys.KEYCODE.RBRACK;      //  93 -> 221
    +// Keys.FF_KEYCODES[Keys.KEYCODE.FF_QUOTE]  = Keys.KEYCODE.QUOTE;       //  39 -> 222
    +
    +/*
    + * Maps non-ASCII keyCodes to their ASCII counterparts
    + */
    +Keys.NONASCII_KEYCODES = {};
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.FF_DASH] = Keys.ASCII['-'];         // 173 -> 45
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.SEMI]    = Keys.ASCII[';'];         // 186 -> 59
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.EQUALS]  = Keys.ASCII['='];         // 187 -> 61
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.DASH]    = Keys.ASCII['-'];         // 189 -> 45
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.COMMA]   = Keys.ASCII[','];         // 188 -> 44
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.PERIOD]  = Keys.ASCII['.'];         // 190 -> 46
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.SLASH]   = Keys.ASCII['/'];         // 191 -> 47
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.BQUOTE]  = Keys.ASCII['`'];         // 192 -> 96
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.LBRACK]  = Keys.ASCII['['];         // 219 -> 91
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.BSLASH]  = Keys.ASCII['\\'];        // 220 -> 92
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.RBRACK]  = Keys.ASCII[']'];         // 221 -> 93
    +Keys.NONASCII_KEYCODES[Keys.KEYCODE.QUOTE]   = Keys.ASCII["'"];         // 222 -> 39
    +
    +/*
    + * Maps unshifted keyCodes to their shifted counterparts; to be used when a shift-key is down.
    + * Alphabetic characters are handled in code, since they must also take CAPS_LOCK into consideration.
    + */
    +Keys.SHIFTED_KEYCODES = {};
    +Keys.SHIFTED_KEYCODES[Keys.ASCII['1']]     = Keys.ASCII['!'];
    +Keys.SHIFTED_KEYCODES[Keys.ASCII['2']]     = Keys.ASCII['@'];
    +Keys.SHIFTED_KEYCODES[Keys.ASCII['3']]     = Keys.ASCII['#'];
    +Keys.SHIFTED_KEYCODES[Keys.ASCII['4']]     = Keys.ASCII['$'];
    +Keys.SHIFTED_KEYCODES[Keys.ASCII['5']]     = Keys.ASCII['%'];
    +Keys.SHIFTED_KEYCODES[Keys.ASCII['6']]     = Keys.ASCII['^'];
    +Keys.SHIFTED_KEYCODES[Keys.ASCII['7']]     = Keys.ASCII['&'];
    +Keys.SHIFTED_KEYCODES[Keys.ASCII['8']]     = Keys.ASCII['*'];
    +Keys.SHIFTED_KEYCODES[Keys.ASCII['9']]     = Keys.ASCII['('];
    +Keys.SHIFTED_KEYCODES[Keys.ASCII['0']]     = Keys.ASCII[')'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.SEMI]   = Keys.ASCII[':'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.EQUALS] = Keys.ASCII['+'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.COMMA]  = Keys.ASCII['<'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.DASH]   = Keys.ASCII['_'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.PERIOD] = Keys.ASCII['>'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.SLASH]  = Keys.ASCII['?'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.BQUOTE] = Keys.ASCII['~'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.LBRACK] = Keys.ASCII['{'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.BSLASH] = Keys.ASCII['|'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.RBRACK] = Keys.ASCII['}'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.QUOTE]  = Keys.ASCII['"'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.FF_DASH]   = Keys.ASCII['_'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.FF_EQUALS] = Keys.ASCII['+'];
    +Keys.SHIFTED_KEYCODES[Keys.KEYCODE.FF_SEMI]   = Keys.ASCII[':'];
    +
    +
    +
    +/**
    + * @copyright http://pcjs.org/modules/shared/lib/strlib.js (C) Jeff Parsons 2012-2017
    + */
    +
    +class Str {
    +    /**
    +     * isValidInt(s, base)
    +     *
    +     * The built-in parseInt() function has the annoying feature of returning a partial value (ie,
    +     * up to the point where it encounters an invalid character); eg, parseInt("foo", 16) returns 0xf.
    +     *
    +     * So it's best to use our own Str.parseInt() function, which will in turn use this function to
    +     * validate the entire string.
    +     *
    +     * @param {string} s is the string representation of some number
    +     * @param {number} [base] is the radix to use (default is 10); only 2, 8, 10 and 16 are supported
    +     * @return {boolean} true if valid, false if invalid (or the specified base isn't supported)
    +     */
    +    static isValidInt(s, base)
    +    {
    +        if (!base || base == 10) return s.match(/^-?[0-9]+$/) !== null;
    +        if (base == 16) return s.match(/^-?[0-9a-f]+$/i) !== null;
    +        if (base == 8) return s.match(/^-?[0-7]+$/) !== null;
    +        if (base == 2) return s.match(/^-?[01]+$/) !== null;
    +        return false;
    +    }
    +
    +    /**
    +     * parseInt(s, base)
    +     *
    +     * This is a wrapper around the built-in parseInt() function.  Our wrapper recognizes certain prefixes
    +     * ('$' or "0x" for hex, '#' or "0o" for octal) and suffixes ('.' for decimal, 'h' for hex, 'y' for
    +     * binary), and then calls isValidInt() to ensure we don't convert strings that contain partial values;
    +     * see isValidInt() for details.
    +     *
    +     * The use of multiple prefix/suffix combinations is undefined (although for the record, we process
    +     * prefixes first).  We do NOT support the "0b" prefix to indicate binary UNLESS one or more commas are
    +     * also present (because "0b" is also a valid hex sequence), and we do NOT support a single leading zero
    +     * to indicate octal (because such a number could also be decimal or hex).  Any number of commas are
    +     * allowed; we remove them all before calling the built-in parseInt().
    +     *
    +     * More recently, we've added support for "^D", "^O", and "^B" prefixes to accommodate the base overrides
    +     * that the PDP-10's MACRO-10 assembly language supports (decimal, octal, and binary, respectively).
    +     * If this support turns out to adversely affect other debuggers, then it will have to be "conditionalized".
    +     * Similarly, we've added support for "K", "M", and "G" MACRO-10-style suffixes that add 3, 6, or 9 zeros
    +     * to the value to be parsed, respectively.
    +     *
    +     * @param {string} s is the string representation of some number
    +     * @param {number} [base] is the radix to use (default is 10); can be overridden by prefixes/suffixes
    +     * @return {number|undefined} corresponding value, or undefined if invalid
    +     */
    +    static parseInt(s, base)
    +    {
    +        var value;
    +
    +        if (s) {
    +            if (!base) base = 10;
    +
    +            var ch, chPrefix, chSuffix;
    +            var fCommas = (s.indexOf(',') > 0);
    +            if (fCommas) s = s.replace(/,/g, '');
    +
    +            ch = chPrefix = s.charAt(0);
    +            if (chPrefix == '#') {
    +                base = 8;
    +                chPrefix = '';
    +            }
    +            else if (chPrefix == '$') {
    +                base = 16;
    +                chPrefix = '';
    +            }
    +            if (ch != chPrefix) {
    +                s = s.substr(1);
    +            }
    +            else {
    +                ch = chPrefix = s.substr(0, 2);
    +                if (chPrefix == '0b' && fCommas || chPrefix == '^B') {
    +                    base = 2;
    +                    chPrefix = '';
    +                }
    +                else if (chPrefix == '0o' || chPrefix == '^O') {
    +                    base = 8;
    +                    chPrefix = '';
    +                }
    +                else if (chPrefix == '^D') {
    +                    base = 10;
    +                    chPrefix = '';
    +                }
    +                else if (chPrefix == '0x') {
    +                    base = 16;
    +                    chPrefix = '';
    +                }
    +                if (ch != chPrefix) s = s.substr(2);
    +            }
    +            ch = chSuffix = s.slice(-1);
    +            if (chSuffix == 'Y' || chSuffix == 'y') {
    +                base = 2;
    +                chSuffix = '';
    +            }
    +            else if (chSuffix == '.') {
    +                base = 10;
    +                chSuffix = '';
    +            }
    +            else if (chSuffix == 'H' || chSuffix == 'h') {
    +                base = 16;
    +                chSuffix = '';
    +            }
    +            else if (chSuffix == 'K') {
    +                chSuffix = '000';
    +            }
    +            else if (chSuffix == 'M') {
    +                chSuffix = '000000';
    +            }
    +            else if (chSuffix == 'G') {
    +                chSuffix = '000000000';
    +            }
    +            if (ch != chSuffix) s = s.slice(0, -1) + chSuffix;
    +            /*
    +             * This adds support for the MACRO-10 binary shifting (Bn) suffix, which must be stripped from the
    +             * number before parsing, and then applied to the value after parsing.  If n is omitted, 35 is assumed,
    +             * which is a net shift of zero.  If n < 35, then a left shift of (35 - n) is required; if n > 35, then
    +             * a right shift of -(35 - n) is required.
    +             */
    +            var v, shift = 0;
    +            if (base <= 10) {
    +                var match = s.match(/(-?[0-9]+)B([0-9]*)/);
    +                if (match) {
    +                    s = match[1];
    +                    shift = 35 - ((match[2] || 35) & 0xff);
    +                }
    +            }
    +            if (Str.isValidInt(s, base) && !isNaN(v = parseInt(s, base))) {
    +                /*
    +                 * With the need to support larger (eg, 36-bit) integers, truncating to 32 bits is no longer helpful.
    +                 *
    +                 *      value = v|0;
    +                 */
    +                if (shift) {
    +                    /*
    +                     * Since binary shifting is a logical operation, and since shifting by division only works properly
    +                     * with positive numbers, we must convert a negative value to a positive value, by computing the two's
    +                     * complement.
    +                     */
    +                    if (v < 0) v += Math.pow(2, 36);
    +                    if (shift > 0) {
    +                        v *= Math.pow(2, shift);
    +                    } else {
    +                        v = Math.trunc(v / Math.pow(2, -shift));
    +                    }
    +                }
    +                value = v;
    +            }
    +        }
    +        return value;
    +    }
    +
    +    /**
    +     * toBase(n, radix, cch, sPrefix, nGrouping)
    +     *
    +     * Displays the given number as an unsigned integer using the specified radix and number of digits.
    +     *
    +     * @param {number|null|undefined} n
    +     * @param {number} radix (ie, the base)
    +     * @param {number} cch (the desired number of digits)
    +     * @param {string} [sPrefix] (default is none)
    +     * @param {number} [nGrouping]
    +     * @return {string}
    +     */
    +    static toBase(n, radix, cch, sPrefix = "", nGrouping = 0)
    +    {
    +        /*
    +         * An initial "falsey" check for null takes care of both null and undefined;
    +         * we can't rely entirely on isNaN(), because isNaN(null) returns false, oddly enough.
    +         *
    +         * Alternatively, we could mask and shift n regardless of whether it's null/undefined/NaN,
    +         * since JavaScript coerces such operands to zero, but I think there's "value" in seeing those
    +         * values displayed differently.
    +         */
    +        var s = "";
    +        if (isNaN(n)) {
    +            n = null;
    +        } else if (n != null) {
    +            /*
    +             * Callers that produced an input by dividing by a power of two rather than shifting (in order
    +             * to access more than 32 bits) may produce a fractional result, which ordinarily we would simply
    +             * ignore, but if the integer portion is zero and the sign is negative, we should probably treat
    +             * this value as a sign-extension.
    +             */
    +            if (n < 0 && n > -1) n = -1;
    +            /*
    +             * Negative values should be two's complemented according to the number of digits; for example,
    +             * 12 octal digits implies an upper limit 8^12.
    +             */
    +            if (n < 0) {
    +                n += Math.pow(radix, cch);
    +            }
    +            if (n >= Math.pow(radix, cch)) {
    +                cch = Math.ceil(Math.log(n) / Math.log(radix));
    +            }
    +        }
    +        var g = nGrouping || -1;
    +        while (cch-- > 0) {
    +            if (!g) {
    +                s = ',' + s;
    +                g = nGrouping;
    +            }
    +            if (n == null) {
    +                s = '?' + s;
    +            } else {
    +                var d = n % radix;
    +                d += (d >= 0 && d <= 9? 0x30 : 0x41 - 10);
    +                s = String.fromCharCode(d) + s;
    +                n = Math.trunc(n / radix);
    +            }
    +            g--;
    +        }
    +        return sPrefix + s;
    +    }
    +
    +    /**
    +     * toBin(n, cch, nGrouping)
    +     *
    +     * Converts an integer to binary, with the specified number of digits (up to a maximum of 36).
    +     *
    +     * @param {number|null|undefined} n (supports integers up to 36 bits now)
    +     * @param {number} [cch] is the desired number of binary digits (0 or undefined for default of either 8, 18, or 36)
    +     * @param {number} [nGrouping]
    +     * @return {string} the binary representation of n
    +     */
    +    static toBin(n, cch, nGrouping)
    +    {
    +        if (!cch) {
    +            // cch = Math.ceil(Math.log(Math.abs(n) + 1) / Math.LN2) || 1;
    +            var v = Math.abs(n);
    +            if (v <= 0b11111111) {
    +                cch = 8;
    +            } else if (v <= 0b111111111111111111) {
    +                cch = 18;
    +            } else {
    +                cch = 36;
    +            }
    +        } else if (cch > 36) cch = 36;
    +        return Str.toBase(n, 2, cch, "", nGrouping);
    +    }
    +
    +    /**
    +     * toBinBytes(n, cb, fPrefix)
    +     *
    +     * Converts an integer to binary, with the specified number of bytes (up to the default of 4).
    +     *
    +     * @param {number|null|undefined} n (interpreted as a 32-bit value)
    +     * @param {number} [cb] is the desired number of binary bytes (4 is both the default and the maximum)
    +     * @param {boolean} [fPrefix]
    +     * @return {string} the binary representation of n
    +     */
    +    static toBinBytes(n, cb, fPrefix)
    +    {
    +        var s = "";
    +        if (!cb || cb > 4) cb = 4;
    +        for (var i = 0; i < cb; i++) {
    +            if (s) s = ',' + s;
    +            s = Str.toBin(n & 0xff, 8) + s;
    +            n >>= 8;
    +        }
    +        return (fPrefix? "0b" : "") + s;
    +    }
    +
    +    /**
    +     * toOct(n, cch, fPrefix)
    +     *
    +     * Converts an integer to octal, with the specified number of digits (default of 6; max of 12)
    +     *
    +     * You might be tempted to use the built-in n.toString(8) instead, but it doesn't zero-pad and it
    +     * doesn't properly convert negative values.  Moreover, if n is undefined, n.toString() will throw
    +     * an exception, whereas this function will return '?' characters.
    +     *
    +     * @param {number|null|undefined} n (supports integers up to 36 bits now)
    +     * @param {number} [cch] is the desired number of octal digits (0 or undefined for default of either 6, 8, or 12)
    +     * @param {boolean} [fPrefix]
    +     * @return {string} the octal representation of n
    +     */
    +    static toOct(n, cch, fPrefix)
    +    {
    +        if (!cch) {
    +            // cch = Math.ceil(Math.log(Math.abs(n) + 1) / Math.log(8)) || 1;
    +            var v = Math.abs(n);
    +            if (v <= 0o777777) {
    +                cch = 6;
    +            } else if (v <= 0o77777777) {
    +                cch = 8;
    +            } else {
    +                cch = 12;
    +            }
    +        } else if (cch > 12) cch = 12;
    +        return Str.toBase(n, 8, cch, fPrefix? "0o" : "");
    +    }
    +
    +    /**
    +     * toDec(n, cch)
    +     *
    +     * Converts an integer to decimal, with the specified number of digits (default of 5; max of 11)
    +     *
    +     * You might be tempted to use the built-in n.toString(10) instead, but it doesn't zero-pad and it
    +     * doesn't properly convert negative values.  Moreover, if n is undefined, n.toString() will throw
    +     * an exception, whereas this function will return '?' characters.
    +     *
    +     * @param {number|null|undefined} n (supports integers up to 36 bits now)
    +     * @param {number} [cch] is the desired number of decimal digits (0 or undefined for default of either 5 or 11)
    +     * @return {string} the decimal representation of n
    +     */
    +    static toDec(n, cch)
    +    {
    +        if (!cch) {
    +            // cch = Math.ceil(Math.log(Math.abs(n) + 1) / Math.LN10) || 1;
    +            var v = Math.abs(n);
    +            if (v <= 99999) {
    +                cch = 5;
    +            } else {
    +                cch = 11;
    +            }
    +        } else if (cch > 11) cch = 11;
    +        return Str.toBase(n, 10, cch);
    +    }
    +
    +    /**
    +     * toHex(n, cch, fPrefix)
    +     *
    +     * Converts an integer to hex, with the specified number of digits (default of 4 or 8, max of 9).
    +     *
    +     * You might be tempted to use the built-in n.toString(16) instead, but it doesn't zero-pad and it
    +     * doesn't properly convert negative values; for example, if n is -2147483647, then n.toString(16)
    +     * will return "-7fffffff" instead of "80000001".  Moreover, if n is undefined, n.toString() will
    +     * throw an exception, whereas this function will return '?' characters.
    +     *
    +     * NOTE: The following work-around (adapted from code found on StackOverflow) would be another solution,
    +     * taking care of negative values, zero-padding, and upper-casing, but not null/undefined/NaN values:
    +     *
    +     *      s = (n < 0? n + 0x100000000 : n).toString(16);
    +     *      s = "00000000".substr(0, 8 - s.length) + s;
    +     *      s = s.substr(0, cch).toUpperCase();
    +     *
    +     * @param {number|null|undefined} n (supports integers up to 36 bits now)
    +     * @param {number} [cch] is the desired number of hex digits (0 or undefined for default of either 4, 8, or 9)
    +     * @param {boolean} [fPrefix]
    +     * @return {string} the hex representation of n
    +     */
    +    static toHex(n, cch, fPrefix)
    +    {
    +        if (!cch) {
    +            // cch = Math.ceil(Math.log(Math.abs(n) + 1) / Math.log(16)) || 1;
    +            var v = Math.abs(n);
    +            if (v <= 0xffff) {
    +                cch = 4;
    +            } else if (v <= 0xffffffff) {
    +                cch = 8;
    +            } else {
    +                cch = 9;
    +            }
    +        } else if (cch > 9) cch = 9;
    +        return Str.toBase(n, 16, cch, fPrefix? "0x" : "");
    +    }
    +
    +    /**
    +     * toHexByte(b)
    +     *
    +     * Alias for Str.toHex(b, 2, true)
    +     *
    +     * @param {number|null|undefined} b is a byte value
    +     * @return {string} the hex representation of b
    +     */
    +    static toHexByte(b)
    +    {
    +        return Str.toHex(b, 2, true);
    +    }
    +
    +    /**
    +     * toHexWord(w)
    +     *
    +     * Alias for Str.toHex(w, 4, true)
    +     *
    +     * @param {number|null|undefined} w is a word (16-bit) value
    +     * @return {string} the hex representation of w
    +     */
    +    static toHexWord(w)
    +    {
    +        return Str.toHex(w, 4, true);
    +    }
    +
    +    /**
    +     * toHexLong(l)
    +     *
    +     * Alias for Str.toHex(l, 8, true)
    +     *
    +     * @param {number|null|undefined} l is a dword (32-bit) value
    +     * @return {string} the hex representation of w
    +     */
    +    static toHexLong(l)
    +    {
    +        return Str.toHex(l, 8, true);
    +    }
    +
    +    /**
    +     * getBaseName(sFileName, fStripExt)
    +     *
    +     * This is a poor-man's version of Node's path.basename(), which Node-only components should use instead.
    +     *
    +     * Note that if fStripExt is true, this strips ANY extension, whereas path.basename() strips the extension only
    +     * if it matches the second parameter (eg, path.basename("/foo/bar/baz/asdf/quux.html", ".html") returns "quux").
    +     *
    +     * @param {string} sFileName
    +     * @param {boolean} [fStripExt]
    +     * @return {string}
    +     */
    +    static getBaseName(sFileName, fStripExt)
    +    {
    +        var sBaseName = sFileName;
    +
    +        var i = sFileName.lastIndexOf('/');
    +        if (i >= 0) sBaseName = sFileName.substr(i + 1);
    +
    +        /*
    +         * This next bit is a kludge to clean up names that are part of a URL that includes unsightly query parameters.
    +         */
    +        i = sBaseName.indexOf('&');
    +        if (i > 0) sBaseName = sBaseName.substr(0, i);
    +
    +        if (fStripExt) {
    +            i = sBaseName.lastIndexOf(".");
    +            if (i > 0) {
    +                sBaseName = sBaseName.substring(0, i);
    +            }
    +        }
    +        return sBaseName;
    +    }
    +
    +    /**
    +     * getExtension(sFileName)
    +     *
    +     * This is a poor-man's version of Node's path.extname(), which Node-only components should use instead.
    +     *
    +     * Note that we EXCLUDE the period from the returned extension, whereas path.extname() includes it.
    +     *
    +     * @param {string} sFileName
    +     * @return {string} the filename's extension (in lower-case and EXCLUDING the "."), or an empty string
    +     */
    +    static getExtension(sFileName)
    +    {
    +        var sExtension = "";
    +        var i = sFileName.lastIndexOf(".");
    +        if (i >= 0) {
    +            sExtension = sFileName.substr(i + 1).toLowerCase();
    +        }
    +        return sExtension;
    +    }
    +
    +    /**
    +     * endsWith(s, sSuffix)
    +     *
    +     * @param {string} s
    +     * @param {string} sSuffix
    +     * @return {boolean} true if s ends with sSuffix, false if not
    +     */
    +    static endsWith(s, sSuffix)
    +    {
    +        return s.indexOf(sSuffix, s.length - sSuffix.length) !== -1;
    +    }
    +
    +    /**
    +     * escapeHTML(sHTML)
    +     *
    +     * @param {string} sHTML
    +     * @return {string} with HTML entities "escaped", similar to PHP's htmlspecialchars()
    +     */
    +    static escapeHTML(sHTML)
    +    {
    +        return sHTML.replace(/[&<>"']/g, function(m)
    +        {
    +            return Str.aHTMLEscapeMap[m];
    +        });
    +    }
    +
    +    /**
    +     * replace(sSearch, sReplace, s)
    +     *
    +     * The JavaScript replace() function ALWAYS interprets "$" specially in replacement strings, even when
    +     * the search string is NOT a RegExp; specifically:
    +     *
    +     *      $$  Inserts a "$"
    +     *      $&  Inserts the matched substring
    +     *      $`  Inserts the portion of the string that precedes the matched substring
    +     *      $'  Inserts the portion of the string that follows the matched substring
    +     *      $n  Where n is a positive integer less than 100, inserts the nth parenthesized sub-match string,
    +     *          provided the first argument was a RegExp object
    +     *
    +     * So, if a replacement string containing dollar signs passes through a series of replace() calls, untold
    +     * problems could result.  Hence, this function, which simply uses the replacement string as-is.
    +     *
    +     * Similar to the JavaScript replace() method (when sSearch is a string), this replaces only ONE occurrence
    +     * (ie, the FIRST occurrence); it might be nice to add options to replace the LAST occurrence and/or ALL
    +     * occurrences, but we'll revisit that later.
    +     *
    +     * @param {string} sSearch
    +     * @param {string} sReplace
    +     * @param {string} s
    +     * @return {string}
    +     */
    +    static replace(sSearch, sReplace, s)
    +    {
    +        var i = s.indexOf(sSearch);
    +        if (i >= 0) {
    +            s = s.substr(0, i) + sReplace + s.substr(i + sSearch.length);
    +        }
    +        return s;
    +    }
    +
    +    /**
    +     * replaceAll(sSearch, sReplace, s)
    +     *
    +     * @param {string} sSearch
    +     * @param {string} sReplace
    +     * @param {string} s
    +     * @return {string}
    +     */
    +    static replaceAll(sSearch, sReplace, s)
    +    {
    +        var a = {};
    +        a[sSearch] = sReplace;
    +        return Str.replaceArray(a, s);
    +    }
    +
    +    /**
    +     * replaceArray(a, s)
    +     *
    +     * @param {Object} a
    +     * @param {string} s
    +     * @return {string}
    +     */
    +    static replaceArray(a, s)
    +    {
    +        var sMatch = "";
    +        for (var k in a) {
    +            /*
    +             * As noted in:
    +             *
    +             *      http://www.regexguru.com/2008/04/escape-characters-only-when-necessary/
    +             *
    +             * inside character classes, only backslash, caret, hyphen and the closing bracket need to be
    +             * escaped.  And in fact, if you ensure that the closing bracket is first, the caret is not first,
    +             * and the hyphen is last, you can avoid escaping those as well.
    +             */
    +            k = k.replace(/([\\[\]*{}().+?])/g, "\\$1");
    +            sMatch += (sMatch? '|' : '') + k;
    +        }
    +        return s.replace(new RegExp('(' + sMatch + ')', "g"), function(m)
    +        {
    +            return a[m];
    +        });
    +    }
    +
    +    /**
    +     * pad(s, cch, fPadLeft)
    +     *
    +     * NOTE: the maximum amount of padding currently supported is 40 spaces.
    +     *
    +     * @param {string} s is a string
    +     * @param {number} cch is desired length
    +     * @param {boolean} [fPadLeft] (default is padding on the right)
    +     * @return {string} the original string (s) with spaces padding it to the specified length
    +     */
    +    static pad(s, cch, fPadLeft)
    +    {
    +        var sPadding = "                                        ";
    +        return fPadLeft? (sPadding + s).slice(-cch) : (s + sPadding).slice(0, cch);
    +    }
    +
    +    /**
    +     * sprintf(format, ...)
    +     *
    +     * Copied from the CCjs project (/ccjs/lib/stdio.js) and extended.  Far from complete let alone sprintf-compatible,
    +     * but it's a start.
    +     *
    +     * @param {string} format
    +     * @param {...} args
    +     * @return {string}
    +     */
    +    static sprintf(format, ...args)
    +    {
    +        var parts = format.split(/%([-+ 0#]?)([0-9]*)(\.?)([0-9]*)([hlL]?)([A-Za-z%])/);
    +        var buffer = "";
    +        var partIndex = 0;
    +        for (var i = 0; i < args.length; i++) {
    +
    +            var arg = args[i], d, s;
    +            buffer += parts[partIndex++];
    +            var flags = parts[partIndex];
    +            var minimum = +parts[partIndex+1] || 0;
    +            var precision = +parts[partIndex+3] || 0;
    +            var conversion = parts[partIndex+5];
    +
    +            switch(conversion) {
    +            case 'd':
    +            case 'f':
    +                d = Math.trunc(arg);
    +                s = d + "";
    +                if (precision) {
    +                    minimum -= (precision + 1);
    +                }
    +                if (s.length < minimum) {
    +                    if (flags == '0') {
    +                        if (d < 0) minimum--;
    +                        s = ("0000000000" + Math.abs(d)).slice(-minimum);
    +                        if (d < 0) s = '-' + s;
    +                    } else {
    +                        s = ("          " + s).slice(-minimum);
    +                    }
    +                }
    +                if (precision) {
    +                    d = Math.trunc((arg - Math.trunc(arg)) * Math.pow(10, precision));
    +                    s += '.' + ("0000000000" + Math.abs(d)).slice(-precision);
    +                }
    +                buffer += s;
    +                break;
    +            case 's':
    +                buffer += arg;
    +                break;
    +            default:
    +                /*
    +                 * The supported ANSI C set of conversions: "dioxXucsfeEgGpn%"
    +                 */
    +                buffer += "(unrecognized printf conversion %" + conversion + ")";
    +                break;
    +            }
    +
    +            partIndex += 6;
    +        }
    +        buffer += parts[partIndex];
    +        return buffer;
    +    }
    +
    +    /**
    +     * stripLeadingZeros(s, fPad)
    +     *
    +     * @param {string} s
    +     * @param {boolean} [fPad]
    +     * @return {string}
    +     */
    +    static stripLeadingZeros(s, fPad)
    +    {
    +        var cch = s.length;
    +        s = s.replace(/^0+([0-9A-F]+)$/i, "$1");
    +        if (fPad) s = Str.pad(s, cch, true);
    +        return s;
    +    }
    +
    +    /**
    +     * trim(s)
    +     *
    +     * @param {string} s
    +     * @return {string}
    +     */
    +    static trim(s)
    +    {
    +        if (String.prototype.trim) {
    +            return s.trim();
    +        }
    +        return s.replace(/^\s+|\s+$/g, "");
    +    }
    +
    +    /**
    +     * toASCIICode(b)
    +     *
    +     * @param {number} b
    +     * @return {string}
    +     */
    +    static toASCIICode(b)
    +    {
    +        var s;
    +        if (b != Str.ASCII.CR && b != Str.ASCII.LF) {
    +            s = Str.aASCIICodes[b];
    +        }
    +        if (s) {
    +            s = '<' + s + '>';
    +        } else {
    +            s = String.fromCharCode(b);
    +        }
    +        return s;
    +    }
    +}
    +
    +Str.aHTMLEscapeMap = {
    +    '&': '&',
    +    '<': '<',
    +    '>': '>',
    +    '"': '"',
    +    "'": '''
    +};
    +
    +/*
    + * Future home of a general-purpose ASCII table.  TODO: Flesh it out.
    + */
    +Str.ASCII = {
    +    LF:     0x0A,
    +    CR:     0x0D
    +};
    +
    +/*
    + * Table for converting "unprintable" ASCII codes into mnemonics, to more clearly see what's being printed.
    + */
    +Str.aASCIICodes = {
    +    0x00:   "NUL",
    +    0x01:   "SOH",      // (CTRL_A) Start of Heading
    +    0x02:   "STX",      // (CTRL_B) Start of Text
    +    0x03:   "ETX",      // (CTRL_C) End of Text
    +    0x04:   "EOT",      // (CTRL_D) End of Transmission
    +    0x05:   "ENQ",      // (CTRL_E) Enquiry
    +    0x06:   "ACK",      // (CTRL_F) Acknowledge
    +    0x07:   "BEL",      // (CTRL_G) Bell
    +    0x08:   "BS",       // (CTRL_H) Backspace
    +    0x09:   "TAB",      // (CTRL_I) Horizontal Tab
    +    0x0A:   "LF",       // (CTRL_J) Line Feed (New Line)
    +    0x0B:   "VT",       // (CTRL_K) Vertical Tab
    +    0x0C:   "FF",       // (CTRL_L) Form Feed (New Page)
    +    0x0D:   "CR",       // (CTRL_M) Carriage Return
    +    0x0E:   "SO",       // (CTRL_N) Shift Out
    +    0x0F:   "SI",       // (CTRL_O) Shift In
    +    0x10:   "DLE",      // (CTRL_P) Data Link Escape
    +    0x11:   "XON",      // (CTRL_Q) Device Control 1 (aka DC1)
    +    0x12:   "DC2",      // (CTRL_R) Device Control 2
    +    0x13:   "XOFF",     // (CTRL_S) Device Control 3 (aka DC3)
    +    0x14:   "DC4",      // (CTRL_T) Device Control 4
    +    0x15:   "NAK",      // (CTRL_U) Negative Acknowledge
    +    0x16:   "SYN",      // (CTRL_V) Synchronous Idle
    +    0x17:   "ETB",      // (CTRL_W) End of Transmission Block
    +    0x18:   "CAN",      // (CTRL_X) Cancel
    +    0x19:   "EM",       // (CTRL_Y) End of Medium
    +    0x1A:   "SUB",      // (CTRL_Z) Substitute
    +    0x1B:   "ESC",      // Escape
    +    0x1C:   "FS",       // File Separator
    +    0x1D:   "GS",       // Group Separator
    +    0x1E:   "RS",       // Record Separator
    +    0x1F:   "US"        // Unit Separator
    +};
    +
    +Str.TYPES = {
    +    NULL:       0,
    +    BYTE:       1,
    +    WORD:       2,
    +    DWORD:      3,
    +    NUMBER:     4,
    +    STRING:     5,
    +    BOOLEAN:    6,
    +    OBJECT:     7,
    +    ARRAY:      8
    +};
    +
    +
    +
    +/**
    + * @copyright http://pcjs.org/modules/shared/lib/usrlib.js (C) Jeff Parsons 2012-2017
    + */
    +
    +/**
    + * @typedef {{
    + *  mask:       number,
    + *  shift:      number
    + * }}
    + */
    +var BitField;
    +
    +/**
    + * @typedef {Object.}
    + */
    +var BitFields;
    +
    +class Usr {
    +    /**
    +     * binarySearch(a, v, fnCompare)
    +     *
    +     * @param {Array} a is an array
    +     * @param {number|string|Array|Object} v
    +     * @param {function((number|string|Array|Object), (number|string|Array|Object))} [fnCompare]
    +     * @return {number} the index of matching entry if non-negative, otherwise the index of the insertion point
    +     */
    +    static binarySearch(a, v, fnCompare)
    +    {
    +        var left = 0;
    +        var right = a.length;
    +        var found = 0;
    +        if (fnCompare === undefined) {
    +            fnCompare = function(a, b)
    +            {
    +                return a > b ? 1 : a < b ? -1 : 0;
    +            };
    +        }
    +        while (left < right) {
    +            var middle = (left + right) >> 1;
    +            var compareResult;
    +            compareResult = fnCompare(v, a[middle]);
    +            if (compareResult > 0) {
    +                left = middle + 1;
    +            } else {
    +                right = middle;
    +                found = !compareResult;
    +            }
    +        }
    +        return found ? left : ~left;
    +    }
    +
    +    /**
    +     * binaryInsert(a, v, fnCompare)
    +     *
    +     * If element v already exists in array a, the array is unchanged (we don't allow duplicates); otherwise, the
    +     * element is inserted into the array at the appropriate index.
    +     *
    +     * @param {Array} a is an array
    +     * @param {number|string|Array|Object} v is the value to insert
    +     * @param {function((number|string|Array|Object), (number|string|Array|Object))} [fnCompare]
    +     */
    +    static binaryInsert(a, v, fnCompare)
    +    {
    +        var index = Usr.binarySearch(a, v, fnCompare);
    +        if (index < 0) {
    +            a.splice(-(index + 1), 0, v);
    +        }
    +    }
    +
    +    /**
    +     * getTimestamp()
    +     *
    +     * @return {string} timestamp containing the current date and time ("yyyy-mm-dd hh:mm:ss")
    +     */
    +    static getTimestamp()
    +    {
    +        return Usr.formatDate("Y-m-d H:i:s");
    +    }
    +
    +    /**
    +     * getMonthDays(nMonth, nYear)
    +     *
    +     * Note that if we're being called on behalf of the RTC, its year is always truncated to two digits (mod 100),
    +     * so we have no idea what century the year 0 might refer to.  When using the normal leap-year formula, 0 fails
    +     * the mod 100 test but passes the mod 400 test, so as far as the RTC is concerned, every century year is a leap
    +     * year.  Since we're most likely dealing with the year 2000, that's fine, since 2000 was also a leap year.
    +     *
    +     * TODO: There IS a separate CMOS byte that's supposed to be set to CMOS_ADDR.CENTURY_DATE; it's always BCD,
    +     * so theoretically it will contain values like 0x19 or 0x20 (for the 20th and 21st centuries, respectively), and
    +     * we could add that as another parameter to this function, to improve the accuracy, but that would go beyond what
    +     * a real RTC actually does.
    +     *
    +     * @param {number} nMonth (1-12)
    +     * @param {number} nYear (normally a 4-digit year, but it may also be mod 100)
    +     * @return {number} the maximum (1-based) day allowed for the specified month and year
    +     */
    +    static getMonthDays(nMonth, nYear)
    +    {
    +        var nDays = Usr.aMonthDays[nMonth - 1];
    +        if (nDays == 28) {
    +            if ((nYear % 4) === 0 && ((nYear % 100) || (nYear % 400) === 0)) {
    +                nDays++;
    +            }
    +        }
    +        return nDays;
    +    }
    +
    +    /**
    +     * formatDate(sFormat, date)
    +     *
    +     * @param {string} sFormat (eg, "F j, Y", "Y-m-d H:i:s")
    +     * @param {Date} [date] (default is the current time)
    +     * @return {string}
    +     *
    +     * Supported identifiers in sFormat include:
    +     *
    +     *      a:  lowercase ante meridiem and post meridiem (am or pm)
    +     *      d:  day of the month, 2 digits with leading zeros (01,02,...,31)
    +     *      D:  3-letter day of the week ("Sun","Mon",...,"Sat")
    +     *      F:  month ("January","February",...,"December")
    +     *      g:  hour in 12-hour format, without leading zeros (1,2,...,12)
    +     *      h:  hour in 24-hour format, without leading zeros (0,1,...,23)
    +     *      H:  hour in 24-hour format, with leading zeros (00,01,...,23)
    +     *      i:  minutes, with leading zeros (00,01,...,59)
    +     *      j:  day of the month, without leading zeros (1,2,...,31)
    +     *      l:  day of the week ("Sunday","Monday",...,"Saturday")
    +     *      m:  month, with leading zeros (01,02,...,12)
    +     *      M:  3-letter month ("Jan","Feb",...,"Dec")
    +     *      n:  month, without leading zeros (1,2,...,12)
    +     *      s:  seconds, with leading zeros (00,01,...,59)
    +     *      y:  2-digit year (eg, 14)
    +     *      Y:  4-digit year (eg, 2014)
    +     *
    +     * For more inspiration, see: http://php.net/manual/en/function.date.php (of which we support ONLY a subset).
    +     */
    +    static formatDate(sFormat, date)
    +    {
    +        var sDate = "";
    +        if (!date) date = new Date();
    +        var iHour = date.getHours();
    +        var iDay = date.getDate();
    +        var iMonth = date.getMonth() + 1;
    +        for (var i = 0; i < sFormat.length; i++) {
    +            var ch;
    +            switch ((ch = sFormat.charAt(i))) {
    +            case 'a':
    +                sDate += (iHour < 12 ? "am" : "pm");
    +                break;
    +            case 'd':
    +                sDate += ('0' + iDay).slice(-2);
    +                break;
    +            case 'D':
    +                sDate += Usr.asDays[date.getDay()].substr(0, 3);
    +                break;
    +            case 'F':
    +                sDate += Usr.asMonths[iMonth - 1];
    +                break;
    +            case 'g':
    +                sDate += (!iHour ? 12 : (iHour > 12 ? iHour - 12 : iHour));
    +                break;
    +            case 'h':
    +                sDate += iHour;
    +                break;
    +            case 'H':
    +                sDate += ('0' + iHour).slice(-2);
    +                break;
    +            case 'i':
    +                sDate += ('0' + date.getMinutes()).slice(-2);
    +                break;
    +            case 'j':
    +                sDate += iDay;
    +                break;
    +            case 'l':
    +                sDate += Usr.asDays[date.getDay()];
    +                break;
    +            case 'm':
    +                sDate += ('0' + iMonth).slice(-2);
    +                break;
    +            case 'M':
    +                sDate += Usr.asMonths[iMonth - 1].substr(0, 3);
    +                break;
    +            case 'n':
    +                sDate += iMonth;
    +                break;
    +            case 's':
    +                sDate += ('0' + date.getSeconds()).slice(-2);
    +                break;
    +            case 'y':
    +                sDate += ("" + date.getFullYear()).slice(-2);
    +                break;
    +            case 'Y':
    +                sDate += date.getFullYear();
    +                break;
    +            default:
    +                sDate += ch;
    +                break;
    +            }
    +        }
    +        return sDate;
    +    }
    +
    +    /**
    +     * defineBitFields(bfs)
    +     *
    +     * Prepares a bit field definition for use with getBitField() and setBitField(); eg:
    +     *
    +     *      var bfs = Usr.defineBitFields({num:20, count:8, btmod:1, type:3});
    +     *
    +     * The above defines a set of bit fields containing four fields: num (bits 0-19), count (bits 20-27), btmod (bit 28), and type (bits 29-31).
    +     *
    +     *      Usr.setBitField(bfs.num, n, 1);
    +     *
    +     * The above set bit field "bfs.num" in numeric variable "n" to the value 1.
    +     *
    +     * @param {Object} bfs
    +     * @return {BitFields}
    +     */
    +    static defineBitFields(bfs)
    +    {
    +        var bit = 0;
    +        for (var f in bfs) {
    +            var width = bfs[f];
    +            var mask = ((1 << width) - 1) << bit;
    +            bfs[f] = {mask: mask, shift: bit};
    +            bit += width;
    +        }
    +        return bfs;
    +    }
    +
    +    /**
    +     * initBitFields(bfs, ...)
    +     *
    +     * @param {BitFields} bfs
    +     * @param {...number} var_args
    +     * @return {number} a value containing all supplied bit fields
    +     */
    +    static initBitFields(bfs, var_args)
    +    {
    +        var v = 0, i = 1;
    +        for (var f in bfs) {
    +            if (i >= arguments.length) break;
    +            v = Usr.setBitField(bfs[f], v, arguments[i++]);
    +        }
    +        return v;
    +    }
    +
    +    /**
    +     * getBitField(bf, v)
    +     *
    +     * @param {BitField} bf
    +     * @param {number} v is a value containing bit fields
    +     * @return {number} the value of the bit field in v defined by bf
    +     */
    +    static getBitField(bf, v)
    +    {
    +        return (v & bf.mask) >> bf.shift;
    +    }
    +
    +    /**
    +     * setBitField(bf, v, n)
    +     *
    +     * @param {BitField} bf
    +     * @param {number} v is a value containing bit fields
    +     * @param {number} n is a value to store in v in the bit field defined by bf
    +     * @return {number} updated v
    +     */
    +    static setBitField(bf, v, n)
    +    {
    +        return (v & ~bf.mask) | ((n << bf.shift) & bf.mask);
    +    }
    +
    +    /**
    +     * indexOf(a, t, i)
    +     *
    +     * Use this instead of Array.prototype.indexOf() if you can't be sure the browser supports it.
    +     *
    +     * @param {Array} a
    +     * @param {*} t
    +     * @param {number} [i]
    +     * @returns {number}
    +     */
    +    static indexOf(a, t, i)
    +    {
    +        if (Array.prototype.indexOf) {
    +            return a.indexOf(t, i);
    +        }
    +        i = i || 0;
    +        if (i < 0) i += a.length;
    +        if (i < 0) i = 0;
    +        for (var n = a.length; i < n; i++) {
    +            if (i in a && a[i] === t) return i;
    +        }
    +        return -1;
    +    }
    +}
    +
    +Usr.asDays = ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"];
    +Usr.asMonths = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
    +Usr.aMonthDays = [31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
    +
    +/**
    + * getTime()
    + *
    + * @return {number} the current time, in milliseconds
    + */
    +Usr.getTime = Date.now || function() { return +new Date(); };
    +
    +
    +
    +/**
    + * @copyright http://pcjs.org/modules/shared/lib/weblib.js (C) Jeff Parsons 2012-2017
    + */
    +
    +
    +/*
    + * According to http://www.w3schools.com/jsref/jsref_obj_global.asp, these are the *global* properties
    + * and functions of JavaScript-in-the-Browser:
    + *
    + * Property             Description
    + * ---
    + * Infinity             A numeric value that represents positive/negative infinity
    + * NaN                  "Not-a-Number" value
    + * undefined            Indicates that a variable has not been assigned a value
    + *
    + * Function             Description
    + * ---
    + * decodeURI()          Decodes a URI
    + * decodeURIComponent() Decodes a URI component
    + * encodeURI()          Encodes a URI
    + * encodeURIComponent() Encodes a URI component
    + * escape()             Deprecated in version 1.5. Use encodeURI() or encodeURIComponent() instead
    + * eval()               Evaluates a string and executes it as if it was script code
    + * isFinite()           Determines whether a value is a finite, legal number
    + * isNaN()              Determines whether a value is an illegal number
    + * Number()             Converts an object's value to a number
    + * parseFloat()         Parses a string and returns a floating point number
    + * parseInt()           Parses a string and returns an integer
    + * String()             Converts an object's value to a string
    + * unescape()           Deprecated in version 1.5. Use decodeURI() or decodeURIComponent() instead
    + *
    + * And according to http://www.w3schools.com/jsref/obj_window.asp, these are the properties and functions
    + * of the *window* object.
    + *
    + * Property             Description
    + * ---
    + * closed               Returns a Boolean value indicating whether a window has been closed or not
    + * defaultStatus        Sets or returns the default text in the statusbar of a window
    + * document             Returns the Document object for the window (See Document object)
    + * frames               Returns an array of all the frames (including iframes) in the current window
    + * history              Returns the History object for the window (See History object)
    + * innerHeight          Returns the inner height of a window's content area
    + * innerWidth           Returns the inner width of a window's content area
    + * length               Returns the number of frames (including iframes) in a window
    + * location             Returns the Location object for the window (See Location object)
    + * name                 Sets or returns the name of a window
    + * navigator            Returns the Navigator object for the window (See Navigator object)
    + * opener               Returns a reference to the window that created the window
    + * outerHeight          Returns the outer height of a window, including toolbars/scrollbars
    + * outerWidth           Returns the outer width of a window, including toolbars/scrollbars
    + * pageXOffset          Returns the pixels the current document has been scrolled (horizontally) from the upper left corner of the window
    + * pageYOffset          Returns the pixels the current document has been scrolled (vertically) from the upper left corner of the window
    + * parent               Returns the parent window of the current window
    + * screen               Returns the Screen object for the window (See Screen object)
    + * screenLeft           Returns the x coordinate of the window relative to the screen
    + * screenTop            Returns the y coordinate of the window relative to the screen
    + * screenX              Returns the x coordinate of the window relative to the screen
    + * screenY              Returns the y coordinate of the window relative to the screen
    + * self                 Returns the current window
    + * status               Sets or returns the text in the statusbar of a window
    + * top                  Returns the topmost browser window
    + *
    + * Method               Description
    + * ---
    + * alert()              Displays an alert box with a message and an OK button
    + * atob()               Decodes a base-64 encoded string
    + * blur()               Removes focus from the current window
    + * btoa()               Encodes a string in base-64
    + * clearInterval()      Clears a timer set with setInterval()
    + * clearTimeout()       Clears a timer set with setTimeout()
    + * close()              Closes the current window
    + * confirm()            Displays a dialog box with a message and an OK and a Cancel button
    + * createPopup()        Creates a pop-up window
    + * focus()              Sets focus to the current window
    + * moveBy()             Moves a window relative to its current position
    + * moveTo()             Moves a window to the specified position
    + * open()               Opens a new browser window
    + * print()              Prints the content of the current window
    + * prompt()             Displays a dialog box that prompts the visitor for input
    + * resizeBy()           Resizes the window by the specified pixels
    + * resizeTo()           Resizes the window to the specified width and height
    + * scroll()             This method has been replaced by the scrollTo() method.
    + * scrollBy()           Scrolls the content by the specified number of pixels
    + * scrollTo()           Scrolls the content to the specified coordinates
    + * setInterval()        Calls a function or evaluates an expression at specified intervals (in milliseconds)
    + * setTimeout()         Calls a function or evaluates an expression after a specified number of milliseconds
    + * stop()               Stops the window from loading
    + */
    +
    +class Web {
    +    /**
    +     * log(s, type)
    +     *
    +     * For diagnostic output only.  DEBUG must be true (or "--debug" specified via the command-line)
    +     * for Component.log() to display anything.
    +     *
    +     * @param {string} [s] is the message text
    +     * @param {string} [type] is the message type
    +     */
    +    static log(s, type)
    +    {
    +        Component.log(s, type);
    +    }
    +
    +    /**
    +     * notice(s, fPrintOnly, id)
    +     *
    +     * @param {string} s is the message text
    +     * @param {boolean} [fPrintOnly]
    +     * @param {string} [id] is the caller's ID, if any
    +     */
    +    static notice(s, fPrintOnly, id)
    +    {
    +        Component.notice(s, fPrintOnly, id);
    +    }
    +
    +    /**
    +     * getResource(sURL, dataPost, fAsync, done, progress)
    +     *
    +     * Request the specified resource (sURL), and once the request is complete, notify done().
    +     *
    +     * If fAsync is true, a done() callback should ALWAYS be supplied; otherwise, you'll have no
    +     * idea when the request is complete or what the response was.  done() is passed three parameters:
    +     *
    +     *      done(sURL, sResource, nErrorCode)
    +     *
    +     * If nErrorCode is zero, sResource should contain the requested data; otherwise, an error occurred.
    +     *
    +     * If dataPost is set to a string, that string can be used to control the response format;
    +     * by default, the response format is plain text, but you can specify "bytes" to request arbitrary
    +     * binary data, which should come back as a string of bytes.
    +     *
    +     * TODO: The "bytes" option works by calling overrideMimeType(), which was never a best practice.
    +     * Instead, we should implement supported response types ("text" and "arraybuffer", at a minimum)
    +     * by setting xmlHTTP.responseType to one of those values before calling xmlHTTP.send().
    +     *
    +     * @param {string} sURL
    +     * @param {string|Object|null} [dataPost] for a POST request (default is a GET request)
    +     * @param {boolean} [fAsync] is true for an asynchronous request
    +     * @param {function(string,string,number)} [done]
    +     * @param {function(number)} [progress]
    +     * @return {Array|null} Array containing [sResource, nErrorCode], or null if no response yet
    +     */
    +    static getResource(sURL, dataPost, fAsync = false, done, progress)
    +    {
    +        var nErrorCode = 0, sResource = null, response = null;
    +
    +        if (typeof resources == 'object' && (sResource = resources[sURL])) {
    +            if (done) done(sURL, sResource, nErrorCode);
    +            return [sResource, nErrorCode];
    +        }
    +        else if (fAsync && typeof resources == 'function') {
    +            resources(sURL, function(sResource, nErrorCode)
    +            {
    +                if (done) done(sURL, sResource, nErrorCode);
    +            });
    +            return response;
    +        }
    +
    +        if (DEBUG) {
    +            /*
    +             * The larger resources we put on archive.pcjs.org should also be available locally.
    +             *
    +             * NOTE: "http://archive.pcjs.org" is now "https://s3-us-west-2.amazonaws.com/archive.pcjs.org"
    +             */
    +            sURL = sURL.replace(/^(http:\/\/archive\.pcjs\.org|https:\/\/s3-us-west-2\.amazonaws\.com\/archive\.pcjs\.org)(\/.*)\/([^\/]*)$/, "$2/archive/$3");
    +        }
    +
    +
    +        var xmlHTTP = (window.XMLHttpRequest? new window.XMLHttpRequest() : new window.ActiveXObject("Microsoft.XMLHTTP"));
    +        if (fAsync) {
    +            xmlHTTP.onreadystatechange = function()
    +            {
    +                if (xmlHTTP.readyState !== 4) {
    +                    if (progress) progress(1);
    +                    return;
    +                }
    +                /*
    +                 * The following line was recommended for WebKit, as a work-around to prevent the handler firing multiple
    +                 * times when debugging.  Unfortunately, that's not the only XMLHttpRequest problem that occurs when
    +                 * debugging, so I think the WebKit problem is deeper than that.  When we have multiple XMLHttpRequests
    +                 * pending, any debugging activity means most of them simply get dropped on floor, so what may actually be
    +                 * happening are mis-notifications rather than redundant notifications.
    +                 *
    +                 *      xmlHTTP.onreadystatechange = undefined;
    +                 */
    +                sResource = xmlHTTP.responseText;
    +                /*
    +                 * The normal "success" case is an HTTP status code of 200, but when testing with files loaded
    +                 * from the local file system (ie, when using the "file:" protocol), we have to be a bit more "flexible".
    +                 */
    +                if (xmlHTTP.status == 200 || !xmlHTTP.status && sResource.length && Web.getHostProtocol() == "file:") {
    +                    if (MAXDEBUG) Web.log("xmlHTTP.onreadystatechange(" + sURL + "): returned " + sResource.length + " bytes");
    +                }
    +                else {
    +                    nErrorCode = xmlHTTP.status || -1;
    +                    Web.log("xmlHTTP.onreadystatechange(" + sURL + "): error code " + nErrorCode);
    +                }
    +                if (progress) progress(2);
    +                if (done) done(sURL, sResource, nErrorCode);
    +            };
    +        }
    +
    +        if (progress) progress(0);
    +
    +        if (dataPost && typeof dataPost == "object") {
    +            var sDataPost = "";
    +            for (var p in dataPost) {
    +                if (!dataPost.hasOwnProperty(p)) continue;
    +                if (sDataPost) sDataPost += "&";
    +                sDataPost += p + '=' + encodeURIComponent(dataPost[p]);
    +            }
    +            sDataPost = sDataPost.replace(/%20/g, '+');
    +            if (MAXDEBUG) Web.log("Web.getResource(POST " + sURL + "): " + sDataPost.length + " bytes");
    +            xmlHTTP.open("POST", sURL, fAsync);     // ensure that fAsync is a valid boolean (Internet Explorer xmlHTTP functions insist on it)
    +            xmlHTTP.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
    +            xmlHTTP.send(sDataPost);
    +        } else {
    +            if (MAXDEBUG) Web.log("Web.getResource(GET " + sURL + ")");
    +            xmlHTTP.open("GET", sURL, fAsync);      // ensure that fAsync is a valid boolean (Internet Explorer xmlHTTP functions insist on it)
    +            if (dataPost == "bytes") {
    +                xmlHTTP.overrideMimeType("text/plain; charset=x-user-defined");
    +            }
    +            xmlHTTP.send();
    +        }
    +
    +        if (!fAsync) {
    +            sResource = xmlHTTP.responseText;
    +            if (xmlHTTP.status == 200) {
    +                if (MAXDEBUG) Web.log("Web.getResource(" + sURL + "): returned " + sResource.length + " bytes");
    +            } else {
    +                nErrorCode = xmlHTTP.status || -1;
    +                Web.log("Web.getResource(" + sURL + "): error code " + nErrorCode);
    +            }
    +            if (done) done(sURL, sResource, nErrorCode);
    +            response = [sResource, nErrorCode];
    +        }
    +        return response;
    +    }
    +
    +    /**
    +     * parseMemoryResource(sURL, sData)
    +     *
    +     * This converts a variety of JSON-style data streams into an Object with the following properties:
    +     *
    +     *      aBytes
    +     *      aSymbols
    +     *      addrLoad
    +     *      addrExec
    +     *
    +     * If the source data contains a 'bytes' array, it's passed through to 'aBytes'; alternatively, if
    +     * it contains a 'words' array, the values are converted from 16-bit to 8-bit and stored in 'aBytes',
    +     * and if it contains a 'longs' array, the values are converted from 32-bit longs into bytes and
    +     * stored in 'aBytes'.
    +     *
    +     * Alternatively, if the source data contains a 'data' array, we simply pass that through to the output
    +     * object as:
    +     *
    +     *      aData
    +     *
    +     * @param {string} sURL
    +     * @param {string} sData
    +     * @return {Object|null} (resource)
    +     */
    +    static parseMemoryResource(sURL, sData)
    +    {
    +        var i;
    +        var resource = {
    +            aBytes: null,
    +            aSymbols: null,
    +            addrLoad: null,
    +            addrExec: null
    +        };
    +
    +        if (sData.charAt(0) == "[" || sData.charAt(0) == "{") {
    +            try {
    +                var a, ib, data;
    +
    +                if (sData.substr(0, 1) == "<") {    // if the "data" begins with a "<"...
    +                    /*
    +                     * Early server configs reported an error (via the nErrorCode parameter) if a tape URL was invalid,
    +                     * but more recent server configs now display a somewhat friendlier HTML error page.  The downside,
    +                     * however, is that the original error has been buried, and we've received "data" that isn't actually
    +                     * tape data.  So if the data we've received appears to be "HTML-like", we treat it as an error message.
    +                     */
    +                    throw new Error(sData);
    +                }
    +
    +                /*
    +                 * TODO: IE9 is rather unfriendly and restrictive with regard to how much data it's willing to
    +                 * eval().  In particular, the 10Mb disk image we use for the Windows 1.01 demo config fails in
    +                 * IE9 with an "Out of memory" exception.  One work-around would be to chop the data into chunks
    +                 * (perhaps one track per chunk, using regular expressions) and then manually re-assemble it.
    +                 *
    +                 * However, it turns out that using JSON.parse(sDiskData) instead of eval("(" + sDiskData + ")")
    +                 * is a much easier fix. The only drawback is that we must first quote any unquoted property names
    +                 * and remove any comments, because while eval() was cool with them, JSON.parse() is more particular;
    +                 * the following RegExp replacements take care of those requirements.
    +                 *
    +                 * The use of hex values is something else that eval() was OK with, but JSON.parse() is not, and
    +                 * while I've stopped using hex values in DumpAPI responses (at least when "format=json" is specified),
    +                 * I can't guarantee they won't show up in "legacy" images, and there's no simple RegExp replacement
    +                 * for transforming hex values into decimal values, so I cop out and fall back to eval() if I detect
    +                 * any hex prefixes ("0x") in the sequence.  Ditto for error messages, which appear like so:
    +                 *
    +                 *      ["unrecognized disk path: test.img"]
    +                 */
    +                if (sData.indexOf("0x") < 0 && sData.indexOf("0o") < 0 && sData.substr(0, 2) != '["') {
    +                    data = JSON.parse(sData.replace(/([a-z]+):/gm, '"$1":').replace(/\/\/[^\n]*/gm, ""));
    +                } else {
    +                    data = eval("(" + sData + ")");
    +                }
    +
    +                resource.addrLoad = data['load'];
    +                resource.addrExec = data['exec'];
    +
    +                if (a = data['bytes']) {
    +                    resource.aBytes = a;
    +                }
    +                else if (a = data['words']) {
    +                    /*
    +                     * Convert all words into bytes
    +                     */
    +                    resource.aBytes = new Array(a.length * 2);
    +                    for (i = 0, ib = 0; i < a.length; i++) {
    +                        resource.aBytes[ib++] = a[i] & 0xff;
    +                        resource.aBytes[ib++] = (a[i] >> 8) & 0xff;
    +
    +                    }
    +                }
    +                else if (a = data['longs']) {
    +                    /*
    +                     * Convert all dwords (longs) into bytes
    +                     */
    +                    resource.aBytes = new Array(a.length * 4);
    +                    for (i = 0, ib = 0; i < a.length; i++) {
    +                        resource.aBytes[ib++] = a[i] & 0xff;
    +                        resource.aBytes[ib++] = (a[i] >> 8) & 0xff;
    +                        resource.aBytes[ib++] = (a[i] >> 16) & 0xff;
    +                        resource.aBytes[ib++] = (a[i] >> 24) & 0xff;
    +                    }
    +                }
    +                else if (a = data['data']) {
    +                    resource.aData = a;
    +                }
    +                else {
    +                    resource.aBytes = data;
    +                }
    +
    +                if (resource.aBytes) {
    +                    if (!resource.aBytes.length) {
    +                        Component.error("Empty resource: " + sURL);
    +                        resource = null;
    +                    }
    +                    else if (resource.aBytes.length == 1) {
    +                        Component.error(resource.aBytes[0]);
    +                        resource = null;
    +                    }
    +                }
    +                resource.aSymbols = data['symbols'];
    +
    +            } catch (e) {
    +                Component.error("Resource data error (" + sURL + "): " + e.message);
    +                resource = null;
    +            }
    +        }
    +        else {
    +            /*
    +             * Parse the data manually; we assume it's a series of hex byte-values separated by whitespace.
    +             */
    +            var ab = [];
    +            var sHexData = sData.replace(/\n/gm, " ").replace(/ +$/, "");
    +            var asHexData = sHexData.split(" ");
    +            for (i = 0; i < asHexData.length; i++) {
    +                var n = parseInt(asHexData[i], 16);
    +                if (isNaN(n)) {
    +                    Component.error("Resource data error (" + sURL + "): invalid hex byte (" + asHexData[i] + ")");
    +                    break;
    +                }
    +                ab.push(n & 0xff);
    +            }
    +            if (i == asHexData.length) resource.aBytes = ab;
    +        }
    +        return resource;
    +    }
    +
    +    /**
    +     * sendReport(sApp, sVer, sURL, sUser, sType, sReport, sHostName)
    +     *
    +     * Send a report (eg, bug report) to the server.
    +     *
    +     * @param {string} sApp (eg, "PCjs")
    +     * @param {string} sVer (eg, "1.02")
    +     * @param {string} sURL (eg, "/devices/pc/machine/5150/mda/64kb/machine.xml")
    +     * @param {string} sUser (ie, the user key, if any)
    +     * @param {string} sType (eg, "bug"); one of ReportAPI.TYPE.*
    +     * @param {string} sReport (eg, unparsed state data)
    +     * @param {string} [sHostName] (default is http://SITEHOST)
    +     */
    +    static sendReport(sApp, sVer, sURL, sUser, sType, sReport, sHostName)
    +    {
    +        var dataPost = {};
    +        dataPost[ReportAPI.QUERY.APP] = sApp;
    +        dataPost[ReportAPI.QUERY.VER] = sVer;
    +        dataPost[ReportAPI.QUERY.URL] = sURL;
    +        dataPost[ReportAPI.QUERY.USER] = sUser;
    +        dataPost[ReportAPI.QUERY.TYPE] = sType;
    +        dataPost[ReportAPI.QUERY.DATA] = sReport;
    +        var sReportURL = (sHostName? sHostName : "http://" + SITEHOST) + ReportAPI.ENDPOINT;
    +        Web.getResource(sReportURL, dataPost, true);
    +    }
    +
    +    /**
    +     * getHost()
    +     *
    +     * @return {string}
    +     */
    +    static getHost()
    +    {
    +        return ("http://" + (window? window.location.host : SITEHOST));
    +    }
    +
    +    /**
    +     * getHostURL()
    +     *
    +     * @return {string|null}
    +     */
    +    static getHostURL()
    +    {
    +        return (window? window.location.href : null);
    +    }
    +
    +    /**
    +     * getHostProtocol()
    +     *
    +     * @return {string}
    +     */
    +    static getHostProtocol()
    +    {
    +        return (window? window.location.protocol : "file:");
    +    }
    +
    +    /**
    +     * getUserAgent()
    +     *
    +     * @return {string}
    +     */
    +    static getUserAgent()
    +    {
    +        return (window? window.navigator.userAgent : "");
    +    }
    +
    +    /**
    +     * hasLocalStorage
    +     *
    +     * true if localStorage support exists, is enabled, and works; false otherwise
    +     *
    +     * @return {boolean}
    +     */
    +    static hasLocalStorage()
    +    {
    +        if (Web.fLocalStorage == null) {
    +            var f = false;
    +            if (window) {
    +                try {
    +                    window.localStorage.setItem(Web.sLocalStorageTest, Web.sLocalStorageTest);
    +                    f = (window.localStorage.getItem(Web.sLocalStorageTest) == Web.sLocalStorageTest);
    +                    window.localStorage.removeItem(Web.sLocalStorageTest);
    +                } catch (e) {
    +                    Web.logLocalStorageError(e);
    +                    f = false;
    +                }
    +            }
    +            Web.fLocalStorage = f;
    +        }
    +        return Web.fLocalStorage;
    +    }
    +
    +    /**
    +     * logLocalStorageError(e)
    +     *
    +     * @param {Error} e is an exception
    +     */
    +    static logLocalStorageError(e)
    +    {
    +        Web.log(e.message, "localStorage error");
    +    }
    +
    +    /**
    +     * getLocalStorageItem(sKey)
    +     *
    +     * Returns the requested key value, or null if the key does not exist, or undefined if localStorage is not available
    +     *
    +     * @param {string} sKey
    +     * @return {string|null|undefined} sValue
    +     */
    +    static getLocalStorageItem(sKey)
    +    {
    +        var sValue;
    +        if (window) {
    +            try {
    +                sValue = window.localStorage.getItem(sKey);
    +            } catch (e) {
    +                Web.logLocalStorageError(e);
    +            }
    +        }
    +        return sValue;
    +    }
    +
    +    /**
    +     * setLocalStorageItem(sKey, sValue)
    +     *
    +     * @param {string} sKey
    +     * @param {string} sValue
    +     * @return {boolean} true if localStorage is available, false if not
    +     */
    +    static setLocalStorageItem(sKey, sValue)
    +    {
    +        try {
    +            window.localStorage.setItem(sKey, sValue);
    +            return true;
    +        } catch (e) {
    +            Web.logLocalStorageError(e);
    +        }
    +        return false;
    +    }
    +
    +    /**
    +     * removeLocalStorageItem(sKey)
    +     *
    +     * @param {string} sKey
    +     */
    +    static removeLocalStorageItem(sKey)
    +    {
    +        try {
    +            window.localStorage.removeItem(sKey);
    +        } catch (e) {
    +            Web.logLocalStorageError(e);
    +        }
    +    }
    +
    +    /**
    +     * getLocalStorageKeys()
    +     *
    +     * @return {Array}
    +     */
    +    static getLocalStorageKeys()
    +    {
    +        var a = [];
    +        try {
    +            for (var i = 0, c = window.localStorage.length; i < c; i++) {
    +                a.push(window.localStorage.key(i));
    +            }
    +        } catch (e) {
    +            Web.logLocalStorageError(e);
    +        }
    +        return a;
    +    }
    +
    +    /**
    +     * reloadPage()
    +     */
    +    static reloadPage()
    +    {
    +        if (window) window.location.reload();
    +    }
    +
    +    /**
    +     * isUserAgent(s)
    +     *
    +     * Check the browser's user-agent string for the given substring; "iOS" and "MSIE" are special values you can
    +     * use that will match any iOS or MSIE browser, respectively (even IE11, in the case of "MSIE").
    +     *
    +     * 2013-11-06: In a questionable move, MSFT changed the user-agent reported by IE11 on Windows 8.1, eliminating
    +     * the "MSIE" string (which MSDN calls a "version token"; see http://msdn.microsoft.com/library/ms537503.aspx);
    +     * they say "public websites should rely on feature detection, rather than browser detection, in order to design
    +     * their sites for browsers that don't support the features used by the website." So, in IE11, we get a user-agent
    +     * that tries to fool apps into thinking the browser is more like WebKit or Gecko:
    +     *
    +     *      Mozilla/5.0 (Windows NT 6.3; Trident/7.0; rv:11.0) like Gecko
    +     *
    +     * That's a nice idea, but in the meantime, they hosed the XSL transform code in embed.js, which contained
    +     * some very critical browser-specific code; turning on IE's "Compatibility Mode" didn't help either, because
    +     * that's a sledgehammer solution which restores the old user-agent string but also disables other features like
    +     * HTML5 canvas support. As an interim solution, I'm treating any "MSIE" check as a check for either "MSIE" or
    +     * "Trident".
    +     *
    +     * UPDATE: I've since found ways to make the code in embed.js more browser-agnostic, so for now, there's isn't
    +     * any code that cares about "MSIE", but I've left the change in place, because I wouldn't be surprised if I'll
    +     * need more IE-specific code in the future, perhaps for things like copy/paste functionality, or mouse capture.
    +     *
    +     * @param {string} s is a substring to search for in the user-agent; as noted above, "iOS" and "MSIE" are special values
    +     * @return {boolean} is true if the string was found, false if not
    +     */
    +    static isUserAgent(s)
    +    {
    +        if (window) {
    +            var userAgent = Web.getUserAgent();
    +            /*
    +             * Here's one case where we have to be careful with Component, because when isUserAgent() is called by
    +             * the init code below, component.js hasn't been loaded yet.  The simple solution for now is to remove the call.
    +             *
    +             *      Web.log("agent: " + userAgent);
    +             *
    +             * And yes, it would be pointless to use the conditional (?) operator below, if not for the Google Closure
    +             * Compiler (v20130823) failing to detect the entire expression as a boolean.
    +             */
    +            return s == "iOS" && !!userAgent.match(/(iPod|iPhone|iPad)/) && !!userAgent.match(/AppleWebKit/) || s == "MSIE" && !!userAgent.match(/(MSIE|Trident)/) || (userAgent.indexOf(s) >= 0);
    +        }
    +        return false;
    +    }
    +
    +    /**
    +     * isMobile()
    +     *
    +     * Check the browser's user-agent string for the substring "Mobi", as per Mozilla recommendation:
    +     *
    +     *      https://developer.mozilla.org/en-US/docs/Browser_detection_using_the_user_agent
    +     *
    +     * @return {boolean} is true if the browser appears to be a mobile (ie, non-desktop) web browser, false if not
    +     */
    +    static isMobile()
    +    {
    +        return Web.isUserAgent("Mobi");
    +    }
    +
    +    /**
    +     * findProperty(obj, sProp, sSuffix)
    +     *
    +     * If both sProp and sSuffix are set, then any browser-specific prefixes are inserted between sProp and sSuffix,
    +     * and if a match is found, it is returned without sProp.
    +     *
    +     * For example, if findProperty(document, 'on', 'fullscreenchange') discovers that 'onwebkitfullscreenchange' exists,
    +     * it will return 'webkitfullscreenchange', in preparation for an addEventListener() call.
    +     *
    +     * More commonly, sSuffix is not used, so whatever property is found is returned as-is.
    +     *
    +     * @param {Object|null|undefined} obj
    +     * @param {string} sProp
    +     * @param {string} [sSuffix]
    +     * @return {string|null}
    +     */
    +    static findProperty(obj, sProp, sSuffix)
    +    {
    +        if (obj) {
    +            for (var i = 0; i < Web.asBrowserPrefixes.length; i++) {
    +                var sName = Web.asBrowserPrefixes[i];
    +                if (sSuffix) {
    +                    sName += sSuffix;
    +                    var sEvent = sProp + sName;
    +                    if (sEvent in obj) return sName;
    +                } else {
    +                    if (!sName) {
    +                        sName = sProp[0];
    +                    } else {
    +                        sName += sProp[0].toUpperCase();
    +                    }
    +                    sName += sProp.substr(1);
    +                    if (sName in obj) return sName;
    +                }
    +            }
    +        }
    +        return null;
    +    }
    +
    +    /**
    +     * getURLParm(sParm)
    +     *
    +     * First looks for sParm exactly as specified, then looks for the lower-case version.
    +     *
    +     * @param {string} sParm
    +     * @return {string|undefined}
    +     */
    +    static getURLParm(sParm)
    +    {
    +        if (!Web.parmsURL) {
    +            Web.parmsURL = Web.parseURLParms();
    +        }
    +        return Web.parmsURL[sParm] || Web.parmsURL[sParm.toLowerCase()];
    +    }
    +
    +    /**
    +     * parseURLParms(sParms)
    +     *
    +     * @param {string} [sParms] containing the parameter portion of a URL (ie, after the '?')
    +     * @return {Object} containing properties for each parameter found
    +     */
    +    static parseURLParms(sParms)
    +    {
    +        var aParms = {};
    +        if (window) {       // an alternative to "if (typeof module === 'undefined')" if require("defines") was used
    +            if (!sParms) {
    +                /*
    +                 * Note that window.location.href returns the entire URL, whereas window.location.search
    +                 * returns only the parameters, if any (starting with the '?', which we skip over with a substr() call).
    +                 */
    +                sParms = window.location.search.substr(1);
    +            }
    +            var match;
    +            var pl = /\+/g; // RegExp for replacing addition symbol with a space
    +            var search = /([^&=]+)=?([^&]*)/g;
    +            var decode = function(s)
    +            {
    +                return decodeURIComponent(s.replace(pl, " "));
    +            };
    +
    +            while ((match = search.exec(sParms))) {
    +                aParms[decode(match[1])] = decode(match[2]);
    +            }
    +        }
    +        return aParms;
    +    }
    +
    +    /**
    +     * downloadFile(sData, sType, fBase64, sFileName)
    +     *
    +     * @param {string} sData
    +     * @param {string} sType
    +     * @param {boolean} [fBase64]
    +     * @param {string} [sFileName]
    +     */
    +    static downloadFile(sData, sType, fBase64, sFileName)
    +    {
    +        var link = null, sAlert;
    +        var sURI = "data:application/" + sType + (fBase64? ";base64" : "") + ",";
    +
    +        if (!Web.isUserAgent("Firefox")) {
    +            sURI += (fBase64? sData : encodeURI(sData));
    +        } else {
    +            sURI += (fBase64? sData : encodeURIComponent(sData));
    +        }
    +        if (sFileName) {
    +            link = document.createElement('a');
    +            if (typeof link.download != 'string') link = null;
    +        }
    +        if (link) {
    +            link.href = sURI;
    +            link.download = sFileName;
    +            document.body.appendChild(link);    // Firefox allegedly requires the link to be in the body
    +            link.click();
    +            document.body.removeChild(link);
    +            sAlert = 'Check your Downloads folder for ' + sFileName + '.';
    +        } else {
    +            window.open(sURI);
    +            sAlert = 'Check your browser for a new window/tab containing the requested data' + (sFileName? (' (' + sFileName + ')') : '') + '.';
    +        }
    +        return sAlert;
    +    }
    +
    +    /**
    +     * onCountRepeat(n, fnRepeat, fnComplete, msDelay)
    +     *
    +     * Call fnRepeat() n times with an msDelay millisecond delay between calls,
    +     * then call fnComplete() when n has been exhausted OR fnRepeat() returns false.
    +     *
    +     * @param {number} n
    +     * @param {function()} fnRepeat
    +     * @param {function()} fnComplete
    +     * @param {number} [msDelay]
    +     */
    +    static onCountRepeat(n, fnRepeat, fnComplete, msDelay)
    +    {
    +        var fnTimeout = function doCountRepeat()
    +        {
    +            n -= 1;
    +            if (n >= 0) {
    +                if (!fnRepeat()) n = 0;
    +            }
    +            if (n > 0) {
    +                setTimeout(fnTimeout, msDelay || 0);
    +                return;
    +            }
    +            fnComplete();
    +        };
    +        fnTimeout();
    +    }
    +
    +    /**
    +     * onClickRepeat(e, msDelay, msRepeat, fn)
    +     *
    +     * Repeatedly call fn() with an initial msDelay, and an msRepeat delay thereafter,
    +     * as long as HTML control Object e has an active "down" event and fn() returns true.
    +     *
    +     * @param {Object} e
    +     * @param {number} msDelay
    +     * @param {number} msRepeat
    +     * @param {function(boolean)} fn is passed false on the first call, true on all repeated calls
    +     */
    +    static onClickRepeat(e, msDelay, msRepeat, fn)
    +    {
    +        var ms = 0, timer = null, fIgnoreMouseEvents = false;
    +
    +        var fnRepeat = function doClickRepeat()
    +        {
    +            if (fn(ms === msRepeat)) {
    +                timer = setTimeout(fnRepeat, ms);
    +                ms = msRepeat;
    +            }
    +        };
    +        e.onmousedown = function()
    +        {
    +            // Web.log("onMouseDown()");
    +            if (!fIgnoreMouseEvents) {
    +                if (!timer) {
    +                    ms = msDelay;
    +                    fnRepeat();
    +                }
    +            }
    +        };
    +        e.ontouchstart = function()
    +        {
    +            // Web.log("onTouchStart()");
    +            if (!timer) {
    +                ms = msDelay;
    +                fnRepeat();
    +            }
    +        };
    +        e.onmouseup = e.onmouseout = function()
    +        {
    +            // Web.log("onMouseUp()/onMouseOut()");
    +            if (timer) {
    +                clearTimeout(timer);
    +                timer = null;
    +            }
    +        };
    +        e.ontouchend = e.ontouchcancel = function()
    +        {
    +            // Web.log("onTouchEnd()/onTouchCancel()");
    +            if (timer) {
    +                clearTimeout(timer);
    +                timer = null;
    +            }
    +            /*
    +             * Devices that generate ontouch* events ALSO generate onmouse* events,
    +             * and generally do so immediately after all the touch events are complete,
    +             * so unless we want double the action, we need to ignore mouse events.
    +             */
    +            fIgnoreMouseEvents = true;
    +        };
    +    }
    +
    +    /**
    +     * onPageEvent(sName, fn)
    +     *
    +     * For 'onload', 'onunload', and 'onpageshow' events, most callers should NOT use this function, but
    +     * instead use Web.onInit(), Web.onShow(), and Web.onExit(), respectively.
    +     *
    +     * The only components that should still use onPageEvent() are THIS component (see the bottom of this file)
    +     * and components that need to capture other events (eg, the 'onresize' event in the Video component).
    +     *
    +     * This function creates a chain of callbacks, allowing multiple JavaScript modules to define handlers
    +     * for the same event, which wouldn't be possible if everyone modified window['onload'], window['onunload'],
    +     * etc, themselves.  However, that's less of a concern now, because assuming everyone else is now using
    +     * onInit(), onExit(), etc, then there really IS only one component setting the window callback: this one.
    +     *
    +     * NOTE: It's risky to refer to obscure event handlers with "dot" names, because the Closure Compiler may
    +     * erroneously replace them (eg, window.onpageshow is a good example).
    +     *
    +     * @param {string} sFunc
    +     * @param {function()} fn
    +     */
    +    static onPageEvent(sFunc, fn)
    +    {
    +        if (window) {
    +            var fnPrev = window[sFunc];
    +            if (typeof fnPrev !== 'function') {
    +                window[sFunc] = fn;
    +            } else {
    +                /*
    +                 * TODO: Determine whether there's any value in receiving/sending the Event object that the
    +                 * browser provides when it generates the original event.
    +                 */
    +                window[sFunc] = function onWindowEvent()
    +                {
    +                    if (fnPrev) fnPrev();
    +                    fn();
    +                };
    +            }
    +        }
    +    };
    +
    +    /**
    +     * onInit(fn)
    +     *
    +     * Use this instead of setting window.onload.  Allows multiple JavaScript modules to define their own 'onload' event handler.
    +     *
    +     * @param {function()} fn
    +     */
    +    static onInit(fn)
    +    {
    +        Web.aPageEventHandlers['init'].push(fn);
    +    };
    +
    +    /**
    +     * onShow(fn)
    +     *
    +     * @param {function()} fn
    +     *
    +     * Use this instead of setting window.onpageshow.  Allows multiple JavaScript modules to define their own 'onpageshow' event handler.
    +     */
    +    static onShow(fn)
    +    {
    +        Web.aPageEventHandlers['show'].push(fn);
    +    };
    +
    +    /**
    +     * onExit(fn)
    +     *
    +     * @param {function()} fn
    +     *
    +     * Use this instead of setting window.onunload.  Allows multiple JavaScript modules to define their own 'onunload' event handler.
    +     */
    +    static onExit(fn)
    +    {
    +        Web.aPageEventHandlers['exit'].push(fn);
    +    };
    +
    +    /**
    +     * doPageEvent(afn)
    +     *
    +     * @param {Array.} afn
    +     */
    +    static doPageEvent(afn)
    +    {
    +        if (Web.fPageEventsEnabled) {
    +            try {
    +                for (var i = 0; i < afn.length; i++) {
    +                    afn[i]();
    +                }
    +            } catch (e) {
    +                Web.notice("An unexpected exception occurred:\n\n" + e.message + "\n\nPlease send this information to support@pcjs.org. Thanks.");
    +            }
    +        }
    +    };
    +
    +    /**
    +     * enablePageEvents(fEnable)
    +     *
    +     * @param {boolean} fEnable is true to enable page events, false to disable (they're enabled by default)
    +     */
    +    static enablePageEvents(fEnable)
    +    {
    +        if (!Web.fPageEventsEnabled && fEnable) {
    +            Web.fPageEventsEnabled = true;
    +            if (Web.fPageLoaded) Web.sendPageEvent('init');
    +            if (Web.fPageShowed) Web.sendPageEvent('show');
    +            return;
    +        }
    +        Web.fPageEventsEnabled = fEnable;
    +    }
    +
    +    /**
    +     * sendPageEvent(sEvent)
    +     *
    +     * This allows us to manually trigger page events.
    +     *
    +     * @param {string} sEvent (one of 'init', 'show' or 'exit')
    +     */
    +    static sendPageEvent(sEvent)
    +    {
    +        if (Web.aPageEventHandlers[sEvent]) {
    +            Web.doPageEvent(Web.aPageEventHandlers[sEvent]);
    +        }
    +    }
    +}
    +
    +Web.parmsURL = null;            // initialized on first call to parseURLParms()
    +
    +Web.aPageEventHandlers = {
    +    'init': [],                 // list of window 'onload' handlers
    +    'show': [],                 // list of window 'onpageshow' handlers
    +    'exit': []                  // list of window 'onunload' handlers (although we prefer to use 'onbeforeunload' if possible)
    +};
    +
    +Web.asBrowserPrefixes = ['', 'moz', 'ms', 'webkit'];
    +
    +Web.fPageLoaded = false;        // set once the page's first 'onload' event has occurred
    +Web.fPageShowed = false;        // set once the page's first 'onpageshow' event has occurred
    +Web.fPageEventsEnabled = true;  // default is true, set to false (or true) by enablePageEvents()
    +
    +/**
    + * fLocalStorage
    + *
    + * true if localStorage support exists, is enabled, and works; "falsey" otherwise
    + *
    + * @type {boolean|null}
    + */
    +Web.fLocalStorage = null;
    +
    +/**
    + * TODO: Is there any way to get the Closure Compiler to stop inlining this string?  This isn't cutting it.
    + *
    + * @const {string}
    + */
    +Web.sLocalStorageTest = "PCjs.localStorage";
    +
    +Web.onPageEvent('onload', function onPageLoad() {
    +    Web.fPageLoaded = true;
    +    Web.doPageEvent(Web.aPageEventHandlers['init']);
    +});
    +
    +Web.onPageEvent('onpageshow', function onPageShow() {
    +    Web.fPageShowed = true;
    +    Web.doPageEvent(Web.aPageEventHandlers['show']);
    +});
    +
    +Web.onPageEvent(Web.isUserAgent("iOS")? 'onpagehide' : (Web.isUserAgent("Opera")? 'onunload' : 'onbeforeunload'), function onPageUnload() {
    +    Web.doPageEvent(Web.aPageEventHandlers['exit']);
    +});
    +
    +
    +
    +/**
    + * @copyright http://pcjs.org/modules/shared/lib/component.js (C) Jeff Parsons 2012-2017
    + */
    +
    +/*
    + * All PCjs components now use JSDoc types, primarily so that Google's Closure Compiler will compile
    + * everything with zero warnings when ADVANCED_OPTIMIZATIONS are enabled.  For more information about
    + * the JSDoc types supported by the Closure Compiler:
    + *
    + *      https://developers.google.com/closure/compiler/docs/js-for-compiler#types
    + *
    + * I also attempted to validate this code with JSLint, but it complained too much; eg, it didn't like
    + * "while (true)", a tried and "true" programming convention for decades, and it wanted me to replace
    + * all "++" and "--" operators with "+= 1" and "-= 1", use "(s || '')" instead of "(s? s : '')", etc.
    + *
    + * I prefer sticking with traditional C-style idioms, in part because they are more portable.  That
    + * does NOT mean I'm trying to write "portable JavaScript," but some of this code was ported from C code
    + * I'd written long ago, so portability is good, and I'm not going to throw that away if there's no need.
    + *
    + * UPDATE: I've since switched from JSLint to JSHint, which seems to have more reasonable defaults.
    + * And for new code, I have adopted some popular JavaScript idioms, like "(s || '')", although the need
    + * for those kinds of expressions will be reduced as I also start adopting some ES6 features, like
    + * default parameters.
    + */
    +
    +
    +/**
    + * Since the Closure Compiler treats ES6 classes as @struct rather than @dict by default,
    + * it deters us from defining named properties on our components; eg:
    + *
    + *      this['exports'] = {...}
    + *
    + * results in an error:
    + *
    + *      Cannot do '[]' access on a struct
    + *
    + * So, in order to define 'exports', we must override the @struct assumption by annotating
    + * the class as @unrestricted (or @dict).  Note that this must be done both here and in the
    + * subclass (eg, SerialPort), because otherwise the Compiler won't allow us to *reference*
    + * the named property either.
    + *
    + * TODO: Consider marking ALL our classes unrestricted, because otherwise it forces us to
    + * define every single property the class uses in its constructor, which results in a fair
    + * bit of redundant initialization, since many properties aren't (and don't need to be) fully
    + * initialized until the appropriate init(), reset(), restore(), etc. function is called.
    + *
    + * The upside, however, may be that since the structure of the class is completely defined by
    + * the constructor, JavaScript engines may be able to optimize and run more efficiently.
    + *
    + * @unrestricted
    + */
    +class Component {
    +    /**
    +     * Component(type, parms, bitsMessage)
    +     *
    +     * A Component object requires:
    +     *
    +     *      type: a user-defined type name (eg, "CPU")
    +     *
    +     * and accepts any or all of the following (parms) properties:
    +     *
    +     *      id: component ID (default is "")
    +     *      name: component name (default is ""; if blank, toString() will use the type name only)
    +     *      comment: component comment string (default is undefined)
    +     *
    +     * Component subclasses will usually have additional (parms) properties.
    +     *
    +     * @param {string} type
    +     * @param {Object} [parms]
    +     * @param {number} [bitsMessage] selects message(s) that the component wants to enable (default is 0)
    +     */
    +    constructor(type, parms, bitsMessage)
    +    {
    +        this.type = type;
    +
    +        if (!parms) parms = {'id': "", 'name': ""};
    +
    +        this.id = parms['id'] || "";
    +        this.name = parms['name'];
    +        this.comment = parms['comment'];
    +        this.parms = parms;
    +
    +        /*
    +         * The following Component properties need to be accessible by other machines and/or command scripts;
    +         * well, OK, or we could have exported some new functions to walk the contents of these properties, as we
    +         * did with findMachineComponent(), but this works just as well.
    +         *
    +         * Also, while the double-assignment looks silly (ie, using both dot and bracket property notation), it
    +         * resolves a complaint from the Closure Compiler, because if we use ONLY bracket notation here, then the
    +         * Compiler wants us to change all the other references to bracket notation as well.
    +         */
    +        this.exports = this['exports'] = {};
    +        this.bindings = this['bindings'] = {};
    +
    +        var i = this.id.indexOf('.');
    +        if (i < 0) {
    +            this.idComponent = this.id;
    +        } else {
    +            this.idMachine = this.id.substr(0, i);
    +            this.idComponent = this.id.substr(i + 1);
    +        }
    +
    +        /*
    +         * Gather all the various component flags (booleans) into a single "flags" object, and encourage
    +         * subclasses to do the same, to reduce the property clutter we have to wade through while debugging.
    +         */
    +        this.flags = {
    +            ready:      false,
    +            busy:       false,
    +            busyCancel: false,
    +            initDone:   false,
    +            powered:    false,
    +            unloading:  false,
    +            error:      false
    +        };
    +
    +        this.fnReady = null;
    +        this.clearError();
    +        this.bitsMessage = bitsMessage || 0;
    +
    +        this.cmp = null;
    +        this.bus = null;
    +        this.cpu = null;
    +        this.dbg = null;
    +
    +        /*
    +         * TODO: Consider adding another parameter to the Component() constructor that allows components to tell
    +         * us if they support single or multiple instances per machine.  For example, there can be multiple SerialPort
    +         * components per machine, but only one CPU component (some machines also support an FPU, but that component
    +         * is considered separate from the CPU).
    +         *
    +         * It's not critical, but it would help catch machine configuration errors; for example, a machine that mistakenly
    +         * includes two CPU components may, aside from wasting memory, end up with odd side-effects, like unresponsive
    +         * CPU controls.
    +         */
    +        Component.add(this);
    +    }
    +
    +    /**
    +     * Component.add(component)
    +     *
    +     * @param {Component} component
    +     */
    +    static add(component)
    +    {
    +        /*
    +         * This just generates a lot of useless noise, handy in the early days, not so much these days....
    +         *
    +         *      if (DEBUG) Component.log("Component.add(" + component.type + "," + component.id + ")");
    +         */
    +        Component.components.push(component);
    +    }
    +
    +    /**
    +     * Component.addMachine(idMachine)
    +     *
    +     * @param {string} idMachine
    +     */
    +    static addMachine(idMachine)
    +    {
    +        Component.machines[idMachine] = {};
    +    }
    +
    +    /**
    +     * Component.addMachineResource(idMachine, sName, data)
    +     *
    +     * @param {string} idMachine
    +     * @param {string|null} sName (name of the resource)
    +     * @param {*} data
    +     */
    +    static addMachineResource(idMachine, sName, data)
    +    {
    +        /*
    +         * I used to assert(Component.machines[idMachine]), but when we're running as a Node app, embed.js is not used,
    +         * so addMachine() is never called, so resources do not need to be recorded.
    +         */
    +        if (Component.machines[idMachine] && sName) {
    +            Component.machines[idMachine][sName] = data;
    +        }
    +    }
    +
    +    /**
    +     * Component.getMachineResources(idMachine)
    +     *
    +     * @param {string} idMachine
    +     * @return {Object|undefined}
    +     */
    +    static getMachineResources(idMachine)
    +    {
    +        return Component.machines[idMachine];
    +    }
    +
    +    /**
    +     * Component.getTime()
    +     *
    +     * @return {number} the current time, in milliseconds
    +     */
    +    static getTime()
    +    {
    +        return Date.now() || +new Date();
    +    }
    +
    +    /**
    +     * Component.log(s, type)
    +     *
    +     * For diagnostic output only.
    +     *
    +     * @param {string} [s] is the message text
    +     * @param {string} [type] is the message type
    +     */
    +    static log(s, type)
    +    {
    +        if (!COMPILED) {
    +            if (s) {
    +                var sElapsed = "", sMsg = (type? (type + ": ") : "") + s;
    +                if (typeof Usr != "undefined") {
    +                    if (Component.msStart === undefined) {
    +                        Component.msStart = Component.getTime();
    +                    }
    +                    sElapsed = (Component.getTime() - Component.msStart) + "ms: ";
    +                }
    +                sMsg = sMsg.replace(/\r/g, '\\r').replace(/\n/g, ' ');
    +                if (window && window.console) console.log(sElapsed + sMsg);
    +            }
    +        }
    +    }
    +
    +    /**
    +     * Component.assert(f, s)
    +     *
    +     * Verifies conditions that must be true (for DEBUG builds only).
    +     *
    +     * The Closure Compiler should automatically remove all references to Component.assert() in non-DEBUG builds.
    +     * TODO: Add a task to the build process that "asserts" there are no instances of "assertion failure" in RELEASE builds.
    +     *
    +     * @param {boolean} f is the expression we are asserting to be true
    +     * @param {string} [s] is description of the assertion on failure
    +     */
    +    static assert(f, s)
    +    {
    +        if (DEBUG) {
    +            if (!f) {
    +                if (!s) s = "assertion failure";
    +                Component.log(s);
    +                throw new Error(s);
    +            }
    +        }
    +    }
    +
    +    /**
    +     * Component.print(s)
    +     *
    +     * Components that inherit from this class should use this.print(), rather than Component.print(), because
    +     * if a Control Panel is loaded, it will override only the instance method, not the class method (overriding the
    +     * class method would improperly affect any other machines loaded on the same page).
    +     *
    +     * @this {Component}
    +     * @param {string} s
    +     */
    +    static print(s)
    +    {
    +        if (!COMPILED) {
    +            var i = s.lastIndexOf('\n');
    +            if (i >= 0) {
    +                Component.println(s.substr(0, i));
    +                s = s.substr(i + 1);
    +            }
    +            Component.printBuffer += s;
    +        }
    +    }
    +
    +    /**
    +     * Component.println(s, type, id)
    +     *
    +     * Components that inherit from this class should use this.println(), rather than Component.println(), because
    +     * if a Control Panel is loaded, it will override only the instance method, not the class method (overriding the
    +     * class method would improperly affect any other machines loaded on the same page).
    +     *
    +     * @param {string} [s] is the message text
    +     * @param {string} [type] is the message type
    +     * @param {string} [id] is the caller's ID, if any
    +     */
    +    static println(s, type, id)
    +    {
    +        if (!COMPILED) {
    +            s = Component.printBuffer + (s || "");
    +            Component.log((id? (id + ": ") : "") + (s? ("\"" + s + "\"") : ""), type);
    +            Component.printBuffer = "";
    +        }
    +    }
    +
    +    /**
    +     * Component.notice(s, fPrintOnly, id)
    +     *
    +     * notice() is like println() but implies a need for user notification, so we alert() as well.
    +     *
    +     * @param {string} s is the message text
    +     * @param {boolean} [fPrintOnly]
    +     * @param {string} [id] is the caller's ID, if any
    +     * @return {boolean}
    +     */
    +    static notice(s, fPrintOnly, id)
    +    {
    +        if (!COMPILED) {
    +            Component.println(s, Component.PRINT.NOTICE, id);
    +        }
    +        if (!fPrintOnly) Component.alertUser((id? (id + ": ") : "") + s);
    +        return true;
    +    }
    +
    +    /**
    +     * Component.warning(s)
    +     *
    +     * @param {string} s describes the warning
    +     */
    +    static warning(s)
    +    {
    +        if (!COMPILED) {
    +            Component.println(s, Component.PRINT.WARNING);
    +        }
    +        Component.alertUser(s);
    +    }
    +
    +    /**
    +     * Component.error(s)
    +     *
    +     * @param {string} s describes the error; an alert() is displayed as well
    +     */
    +    static error(s)
    +    {
    +        if (!COMPILED) {
    +            Component.println(s, Component.PRINT.ERROR);
    +        }
    +        Component.alertUser(s);
    +    }
    +
    +    /**
    +     * Component.alertUser(sMessage)
    +     *
    +     * @param {string} sMessage
    +     */
    +    static alertUser(sMessage)
    +    {
    +        if (window) {
    +            window.alert(sMessage);
    +        } else {
    +            Component.log(sMessage);
    +        }
    +    };
    +
    +    /**
    +     * Component.confirmUser(sPrompt)
    +     *
    +     * @param {string} sPrompt
    +     * @returns {boolean} true if the user clicked OK, false if Cancel/Close
    +     */
    +    static confirmUser(sPrompt)
    +    {
    +        var fResponse = false;
    +        if (window) {
    +            fResponse = window.confirm(sPrompt);
    +        }
    +        return fResponse;
    +    }
    +
    +    /**
    +     * Component.promptUser()
    +     *
    +     * @param {string} sPrompt
    +     * @param {string} [sDefault]
    +     * @returns {string|null}
    +     */
    +    static promptUser(sPrompt, sDefault)
    +    {
    +        var sResponse = null;
    +        if (window) {
    +            sResponse = window.prompt(sPrompt, sDefault === undefined? "" : sDefault);
    +        }
    +        return sResponse;
    +    }
    +
    +    /**
    +     * Component.appendControl(control, sText)
    +     *
    +     * @param {Object} control
    +     * @param {string} sText
    +     */
    +    static appendControl(control, sText)
    +    {
    +        control.value += sText;
    +        /*
    +         * Prevent the