/* Copyright 2007 Google Inc. All Rights Reserved. */ 
var j={};this.goog=j;j.global=this;j.provide=function(a){var b=a.split("."),c=j.global;for(var d;d=b.shift();){if(c[d]){c=c[d]}else{c=(c[d]={})}}};j.getObjectByName=function(a){var b=a.split("."),c=j.global;for(var d;d=b.shift();){if(c[d]){c=c[d]}else{return null}}return c};j.globalize=function(a,b){Xg(b||j.global,a||j)};j.addDependency=function(a,b,c){};j.require=function(a){};j.addIncludeRoot=function(a,b){};j.basePath="";var mq=function(){};j.nullFunction=mq;var Y=function(a){return typeof a!=
"undefined"};j.isDef=Y;var bq=function(a){return a===null};j.isNull=bq;var Ta=function(a){return a instanceof Array||ib(a)&&ld(a.join)&&ld(a.reverse)};j.isArray=Ta;var Za=function(a){return ib(a)&&typeof a.length=="number"};j.isArrayLike=Za;j.isDateLike=function(a){return ib(a)&&ld(a.getFullYear)};var la=function(a){return typeof a=="string"};j.isString=la;j.isBoolean=function(a){return typeof a=="boolean"};j.isNumber=function(a){return typeof a=="number"};var ld=function(a){return typeof a=="function"};
j.isFunction=ld;var ib=function(a){return a!=null&&typeof a=="object"};j.isObject=ib;var Ab=function(a){if(a.hasOwnProperty&&a.hasOwnProperty(bd)){return a[bd]}if(!a[bd]){a[bd]=++j.Aw}return a[bd]};j.getHashCode=Ab;j.removeHashCode=function(a){if("removeAttribute"in a){a.removeAttribute(bd)}try{delete a[bd]}catch(b){}};var bd="closure_hashCode_";j.zA=bd;j.Aw=0;var Qo=function(a){if(ib(a)){if(a.Ca){return a.Ca()}var b=Ta(a)?[]:{};for(var c in a){b[c]=Qo(a[c])}return b}return a};j.cloneObject=Qo;var ba=
function(a,b){var c=a.lu||[];c=c.concat(Array.prototype.slice.call(arguments,2));if(a.ln){b=a.ln}if(a.kn){a=a.kn}var d=function(){var e=c.concat(Array.prototype.slice.call(arguments));return a.apply(b,e)};d.lu=c;d.ln=b;d.kn=a;return d};j.p=ba;j.hy=function(a){return ba.apply(null,[a,null].concat(Array.prototype.slice.call(arguments,1)))};var Xg=function(a,b){for(var c in b){a[c]=b[c]}};j.Np=Xg;var Bb=function(){return(new Date).getTime()};j.now=Bb;j.globalEval=function(a){if(j.global.execScript){j.global.execScript(a,
"JavaScript")}else if(j.global.eval){j.global.eval(a)}else{throw Error("goog.globalEval not available");}};j.getMsg=function(a,b){var c=b||{};for(var d in c){a=a.replace(new RegExp("\\{\\$"+d+"\\}","gi"),c[d])}return a};j.exportSymbol=function(a,b){j.global[a]=b};j.exportProperty=function(a,b,c){a[b]=c};if(!Function.prototype.apply){Function.prototype.apply=function(a,b){var c=[],d,e;if(!a)a=j.global;if(!b)b=[];for(var f=0;f<b.length;f++){c[f]="args["+f+"]"}e="oScope.__applyTemp__.peek().("+c.join(",")+
");";if(!a.__applyTemp__){a.__applyTemp__=[]}a.__applyTemp__.push(this);d=eval(e);a.__applyTemp__.pop();return d}}Function.prototype.p=function(a){return ba.apply(null,[this,a].concat(Array.prototype.slice.call(arguments,1)))};Function.prototype.hy=function(){return ba.apply(null,[this,null].concat(Array.prototype.slice.call(arguments)))};Function.prototype.la=function(a){var b=function(){};b.prototype=a.prototype;this.tc=a.prototype;this.prototype=new b};Function.prototype.Np=function(a){Xg(this.prototype,
a)};if(!Array.prototype.push){Array.prototype.push=function(){for(var a=0;a<arguments.length;a++){this[this.length]=arguments[a]}return this.length}}if(!Array.prototype.pop){Array.prototype.pop=function(){var a;if(this.length){a=this[this.length-1];this.length--}return a}}Array.prototype.peek=function(){return this[this.length-1]};if(!Array.prototype.shift){Array.prototype.shift=function(){var a;if(this.length){a=this[0];for(var b=0;b<this.length-1;b++){this[b]=this[b+1]}this.length--}return a}}if(!Array.prototype.unshift){Array.prototype.unshift=
function(){var a=arguments.length;for(var b=this.length-1;b>=0;b--){this[b+a]=this[b]}for(var c=0;c<a;c++){this[c]=arguments[c]}return this.length}};var x={};j.array=x;x.indexOf=function(a,b,c){if(a.indexOf){return a.indexOf(b,c)}if(Array.indexOf){return Array.indexOf(a,b,c)}if(c==null){c=0}else if(c<0){c=Math.max(0,a.length+c)}for(var d=c;d<a.length;d++){if(a[d]===b)return d}return-1};x.lastIndexOf=function(a,b,c){if(c==null){c=a.length-1}if(a.lastIndexOf){return a.lastIndexOf(b,c)}if(Array.lastIndexOf){return Array.lastIndexOf(a,b,c)}if(c<0){c=Math.max(0,a.length+c)}for(var d=c;d>=0;d--){if(a[d]===b)return d}return-1};var Wi=function(a,b,c){if(a.forEach){a.forEach(b,
c)}else if(Array.forEach){Array.forEach(a,b,c)}else{var d=a.length,e=la(a)?a.split(""):a;for(var f=0;f<d;f++){b.call(c,e[f],f,a)}}};x.forEach=Wi;x.filter=function(a,b,c){if(a.filter){return a.filter(b,c)}if(Array.filter){return Array.filter(a,b,c)}var d=a.length,e=[],f=la(a)?a.split(""):a;for(var g=0;g<d;g++){if(b.call(c,f[g],g,a)){e.push(f[g])}}return e};var Yi=function(a,b,c){if(a.map){return a.map(b,c)}if(Array.map){return Array.map(a,b,c)}var d=a.length,e=[],f=la(a)?a.split(""):a;for(var g=0;g<
d;g++){e.push(b.call(c,f[g],g,a))}return e};x.map=Yi;var Po=function(a,b,c){if(a.some){return a.some(b,c)}if(Array.some){return Array.some(a,b,c)}var d=a.length,e=la(a)?a.split(""):a;for(var f=0;f<d;f++){if(b.call(c,e[f],f,a)){return true}}return false};x.some=Po;var No=function(a,b,c){if(a.every){return a.every(b,c)}if(Array.every){return Array.every(a,b,c)}var d=a.length,e=la(a)?a.split(""):a;for(var f=0;f<d;f++){if(!b.call(c,e[f],f,a)){return false}}return true};x.every=No;x.contains=function(a,
b){if(a.contains){return a.contains(b)}return x.indexOf(a,b)>-1};var Oo=function(a){return a.length==0};x.bc=Oo;x.clear=function(a){if(!Ta(a)){for(var b=a.length-1;b>=0;b--){delete a[b]}}a.length=0};var vg=function(a,b){if(!x.contains(a,b)){a.push(b)}};x.insert=vg;var Xi=function(a,b,c){x.splice(a,c,0,b)};x.Tw=Xi;x.insertBefore=function(a,b,c){var d;if(arguments.length==2||(d=x.indexOf(a,c))==-1){a.push(b)}else{Xi(a,b,d)}};x.remove=function(a,b){var c=x.indexOf(a,b),d;if(d=c!=-1){Zi(a,c)}return d};
var Zi=function(a,b){return Array.prototype.splice.call(a,b,1).length==1};x.zy=Zi;var Mo=function(a){if(Ta(a)){return a.concat()}else{var b=[];for(var c=0;c<a.length;c++){b[c]=a[c]}return b}};x.Ca=Mo;x.toArray=function(a){if(Ta(a)){return a.concat()}if(Za(a)){return Mo(a)}return[a]};x.extend=function(a,b){if(!Ta(b)){a.push(b)}else{a.push.apply(a,b)}};x.splice=function(a,b,c,d){return Array.prototype.splice.apply(a,x.slice(arguments,1))};x.slice=function(a,b,c){if(arguments.length<=2){return Array.prototype.slice.call(a,
b)}else{return Array.prototype.slice.call(a,b,c)}};x.find=x.indexOf;x.insertValue=vg;x.deleteValue=x.remove;x.removeDuplicates=function(a,b){var c=b||a,d={},e=0,f=0;while(f<a.length){var g=a[f++],h=ib(g)?Ab(g):g;if(!(h in d)){d[h]=true;c[e++]=g}}c.length=e};x.binarySearch=function(a,b,c){var d=0,e=a.length-1,f=c||Vi;while(d<=e){var g=d+e>>1,h=f(b,a[g]);if(h>0){d=g+1}else if(h<0){e=g-1}else{return g}}return-(d+1)};x.sort=function(a,b){Array.prototype.sort.call(a,b||Vi)};var Vi=function(a,b){return a>
b?1:(a<b?-1:0)};x.defaultCompare=Vi;j.object={};var Tj=function(a,b,c){for(var d in a){b.call(c,a[d],d,a)}};j.object.forEach=Tj;j.object.filter=function(a,b,c){var d={};for(var e in a){if(b.call(c,a[e],e,a)){d[e]=a[e]}}return d};j.object.map=function(a,b,c){var d={};for(var e in a){d[e]=b.call(c,a[e],e,a)}return d};j.object.some=function(a,b,c){for(var d in a){if(b.call(c,a[d],d,a)){return true}}return false};j.object.every=function(a,b,c){for(var d in a){if(!b.call(c,a[d],d,a)){return false}}return true};var Uj=function(a){var b=0;
for(var c in a){b++}return b};j.object.Ua=Uj;j.object.contains=function(a,b){return Sj(a,b)};var Vj=function(a){var b=[];for(var c in a){b.push(a[c])}return b};j.object.Va=Vj;var sf=function(a){var b=[];for(var c in a){b.push(c)}return b};j.object.Zb=sf;var nq=function(a,b){return b in a};j.object.Cb=nq;var Sj=function(a,b){for(var c in a){if(a[c]==b){return true}}return false};j.object.th=Sj;var oq=function(a){for(var b in a){return false}return true};j.object.bc=oq;j.object.clear=function(a){var b=
sf(a);for(var c=b.length-1;c>=0;c--){j.object.remove(a,b[c])}};j.object.remove=function(a,b){var c;if(c=b in a){delete a[b]}return c};j.object.add=function(a,b,c){if(b in a){throw Error('The object already contains the key "'+b+'"');}Wj(a,b,c)};j.object.ha=function(a,b,c){if(b in a){return a[b]}return c};var Wj=function(a,b,c){a[b]=c};j.object.ma=Wj;j.object.Ca=function(a){var b={};for(var c in a){b[c]=a[c]}return b};var F={};j.string=F;var ve=function(a,b){return a.indexOf(b)==0};F.startsWith=ve;var qc=function(a,b){var c=a.length-b.length;return c>=0&&a.lastIndexOf(b,c)==c};F.endsWith=qc;F.subs=function(a){for(var b=1;b<arguments.length;b++){a=a.replace(/\%s/,String(arguments[b]))}return a};var rq=function(a){return a.replace(/\s+/g," ").replace(/^\s+|\s+$/g,"")};F.collapseWhitespace=rq;var Pd=function(a){return/^\s*$/.test(a)};F.bc=Pd;F.isAlpha=function(a){return!/[^a-zA-Z]/.test(a)};F.isNumeric=function(a){return!/[^0-9]/.test(a)};
F.isAlphaNumeric=function(a){return!/[^a-zA-Z0-9]/.test(a)};F.isSpace=function(a){return a==" "};F.stripNewlines=function(a){return a.replace(/(\r\n|\r|\n)+/g," ")};var qq=function(a){return a.replace(/(\r\n|\r|\n)/g,"\n")};F.canonicalizeNewlines=qq;var tq=function(a){return a.replace(/\xa0|\s/g," ")};F.normalizeWhitespace=tq;F.normalizeSpaces=function(a){return a.replace(/\xa0|[ \t]+/g," ")};var rc=function(a){return a.replace(/^\s+|\s+$/g,"")};F.trim=rc;var wq=function(a){return a.replace(/^\s+/,
"")};F.trimLeft=wq;var xq=function(a){return a.replace(/\s+$/,"")};F.trimRight=xq;F.caseInsensitiveCompare=function(a,b){var c=String(a).toLowerCase(),d=String(b).toLowerCase();if(c<d){return-1}else if(c==d){return 0}else{return 1}};var Yj=/(\.\d+)|(\d+)|(\D+)/g;F.HC=Yj;var uq=function(a,b){if(a==b){return 0}if(!a){return-1}if(!b){return 1}var c=a.toLowerCase().match(Yj),d=b.toLowerCase().match(Yj),e=Math.min(c.length,d.length);for(var f=0;f<e;f++){var g=c[f],h=d[f];if(g!=h){var i=parseInt(g,10);
if(!isNaN(i)){var k=parseInt(h,10);if(!isNaN(k)&&i-k){return i-k}}return g<h?-1:1}}if(c.length!=d.length){return c.length-d.length}return a<b?-1:1};F.numerateCompare=uq;var Bc=function(a){return encodeURIComponent(a)};F.urlEncode=Bc;var bh=function(a){return decodeURIComponent(a.replace(/\+/g," "))};F.urlDecode=bh;var $g=function(a,b){return a.replace(/(\r\n|\r|\n)/g,b?"<br />":"<br>")};F.newLineToBr=$g;var za=function(a){return a.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\"/g,
"&quot;")};F.htmlEscape=za;var Ob=function(a){if(a.indexOf("&")>=0){var b=document.createElement("a");b.innerHTML=a;if(b[Xj]){b[Xj]()}a=b.firstChild.nodeValue;b.innerHTML=""}return a};F.unescapeEntities=Ob;var Xj="normalize";F.NORMALIZE_FN=Xj;var ch=function(a,b){return $g(a.replace(/  /g," &#160;"),b)};F.whitespaceEscape=ch;F.stripQuotes=function(a,b){if(a.charAt(0)==b&&a.charAt(a.length-1)==b){return a.substring(1,a.length-1)}return a};F.truncate=function(a,b,c){if(c){a=Ob(a)}if(a.length>b){a=a.substring(0,
b)+"..."}if(c){a=za(a)}return a};F.truncateMiddle=function(a,b,c){if(c){a=Ob(a)}if(a.length>b){var d=Math.floor(b/2),e=a.length-d;d+=b%2;a=a.substring(0,d)+"..."+a.substring(e)}if(c){a=za(a)}return a};var Zg={"\u0008":"\\b","\u000c":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\u000b":"\\x0B",'"':'\\"',"'":"'","\\":"\\"};F.rC=Zg;F.quote=function(a){a=String(a);if(a.quote){return a.quote()}else{var b='"';for(var c=0;c<a.length;c++){b+=sq(a.charAt(c))}return b+'"'}};var sq=function(a){if(a in Zg){return Zg[a]}var b=
a,c=a.charCodeAt(0);if(c>31&&c<127){b=a}else{if(c<256){b="\\x";if(c<16||c>256){b+="0"}}else{b="\\u";if(c<4096){b+="0"}}b+=c.toString(16).toUpperCase()}return Zg[a]=b};F.escapeChar=sq;var vq=function(a){var b={};for(var c=0;c<a.length;c++){b[a.charAt(c)]=true}return b};F.toMap=vq;var pq=vq("()[]{}+-?*.$^|,:#<!\\");F.AA=pq;F.contains=function(a,b){return a.indexOf(b)!=-1};var ah=function(a){a=String(a);var b="",c;for(var d=0;d<a.length;d++){c=a.charAt(d);if(c=="\u0008"){c="\\x08"}else if(c in pq){c=
"\\"+c}b+=c}return b};F.regExpEscape=ah;F.padNumber=function(a,b,c){var d=Math.floor(a),e=String(d);return(new Array(Math.max(0,b-e.length+1))).join("0")+(Y(c)?a.toFixed(c):a)};var md={};j.math=md;var hq=function(a){return Math.floor(Math.random()*a)};md.randomInt=hq;md.uniformRandom=function(a,b){return a+Math.random()*(b-a)};var Ac=function(a,b){this.width=Y(a)?Number(a):undefined;this.height=Y(b)?Number(b):undefined};md.Size=Ac;Ac.prototype.Ca=function(){return new Ac(this.width,this.height)};Ac.prototype.toString=function(){return"("+this.width+" x "+this.height+")"};Ac.Fa=function(a,b){if(a==b){return true}if(!a||!b){return false}return a.width==b.width&&a.height==
b.height};var aa=function(a,b){this.x=Y(a)?Number(a):undefined;this.y=Y(b)?Number(b):undefined};md.Coordinate=aa;aa.prototype.Ca=function(){return new aa(this.x,this.y)};aa.prototype.toString=function(){return"("+this.x+", "+this.y+")"};aa.Fa=function(a,b){if(a==b){return true}if(!a||!b){return false}return a.x==b.x&&a.y==b.y};aa.distance=function(a,b){var c=a.x-b.x,d=a.y-b.y;return Math.sqrt(c*c+d*d)};aa.squaredDistance=function(a,b){var c=a.x-b.x,d=a.y-b.y;return c*c+d*d};aa.difference=function(a,
b){return new aa(a.x-b.x,a.y-b.y)};var zc=function(a,b){a=Number(a);b=Number(b);this.start=a<b?a:b;this.end=a<b?b:a};md.Range=zc;zc.prototype.Ca=function(){return new zc(this.start,this.end)};zc.prototype.toString=function(){return"["+this.start+", "+this.end+"]"};zc.Fa=function(a,b){if(a==b){return true}if(!a||!b){return false}return a.start==b.start&&a.end==b.end};zc.intersection=function(a,b){var c=Math.max(a.start,b.start),d=Math.min(a.end,b.end);return c<=d?new zc(c,d):null};zc.boundingRange=
function(a,b){return new zc(Math.min(a.start,b.start),Math.max(a.end,b.end))};zc.contains=function(a,b){return a.start<=b.start&&a.end>=b.end};var jb=function(a,b,c,d){this.left=Y(a)?Number(a):undefined;this.top=Y(b)?Number(b):undefined;this.width=Y(c)?Number(c):undefined;this.height=Y(d)?Number(d):undefined};md.Rect=jb;jb.prototype.Ca=function(){return new jb(this.left,this.top,this.width,this.height)};jb.prototype.toString=function(){return"("+this.left+", "+this.top+" - "+this.width+"w x "+this.height+
"h)"};jb.Fa=function(a,b){if(a==b){return true}if(!a||!b){return false}return a.left==b.left&&a.width==b.width&&a.top==b.top&&a.height==b.height};var gq=function(a,b){var c=Math.max(a.left,b.left),d=Math.min(a.left+a.width,b.left+b.width);if(c<=d){var e=Math.max(a.top,b.top),f=Math.min(a.top+a.height,b.top+b.height);if(e<=f){return new jb(c,e,d-c,f-e)}}return null};jb.intersection=gq;jb.difference=function(a,b){if(!gq(a,b)){return[a.Ca()]}var c=[],d=a.top,e=a.height,f=a.left+a.width,g=a.top+a.height,
h=b.left+b.width,i=b.top+b.height;if(b.top>a.top){c.push(new jb(a.left,a.top,a.width,b.top-a.top));d=b.top}if(i<g){c.push(new jb(a.left,i,a.width,g-i));e=i-d}if(b.left>a.left){c.push(new jb(a.left,d,b.left-a.left,e))}if(h<f){c.push(new jb(h,d,f-h,e))}return c};jb.boundingRect=function(a,b){if(!a||!b){return null}var c=Math.min(a.left,b.left),d=Math.min(a.top,b.top),e=Math.max(a.left+a.width,b.left+b.width),f=Math.max(a.top+a.height,b.top+b.height);return new jb(c,d,e-c,f-d)};var Na=function(a,b,c,
d){this.top=Y(a)?Number(a):undefined;this.right=Y(b)?Number(b):undefined;this.bottom=Y(c)?Number(c):undefined;this.left=Y(d)?Number(d):undefined};md.Box=Na;Na.boundingBox=function(){var a=new Na(arguments[0].y,arguments[0].x,arguments[0].y,arguments[0].x);for(var b=1;b<arguments.length;b++){var c=arguments[b];a.top=Math.min(a.top,c.y);a.right=Math.max(a.right,c.x);a.bottom=Math.max(a.bottom,c.y);a.left=Math.min(a.left,c.x)}return a};Na.prototype.Ca=function(){return new Na(this.top,this.right,this.bottom,
this.left)};Na.prototype.toString=function(){return"("+this.top+"t, "+this.right+"r, "+this.bottom+"b, "+this.left+"l)"};Na.Fa=function(a,b){if(a==b){return true}if(!a||!b){return false}return a.top==b.top&&a.right==b.right&&a.bottom==b.bottom&&a.left==b.left};j.userAgent={};(function(){var a=navigator.userAgent,b=typeof opera!="undefined",c=!b&&a.indexOf("MSIE")!=-1,d=!b&&a.indexOf("Safari")!=-1,e=!b&&navigator.product=="Gecko"&&!d,f=!b&&a.indexOf("Konqueror")!=-1,g=f||d,h,i;if(b){h=opera.version()}else{if(e){i=/rv\:([^\);]+)(\)|;)/}else if(c){i=/MSIE\s+([^\);]+)(\)|;)/}else if(d){i=/AppleWebKit\/(\S+)/}else if(f){i=/Konqueror\/([^\);]+)(\)|;)/}if(i){i.test(a);h=RegExp.$1}}var k=navigator.platform,n=k.indexOf("Mac")!=-1,s=k.indexOf("Win")!=-1,u=k.indexOf("Linux")!=
-1;j.userAgent.OPERA=b;j.userAgent.IE=c;j.userAgent.GECKO=e;j.userAgent.KONQUEROR=f;j.userAgent.SAFARI=d;j.userAgent.KHTML=g;j.userAgent.VERSION=h;j.userAgent.PLATFORM=navigator.platform;j.userAgent.MAC=n;j.userAgent.WINDOWS=s;j.userAgent.LINUX=u})();var th=function(a,b){if(!isNaN(a)&&!isNaN(b)){return a-b}var c=a.split("."),d=b.split("."),e=Math.min(c.length,d.length);for(var f=0;f<e;f++){if(typeof d[f]=="undefined"){return 1}if(typeof c[f]=="undefined"){return-1}if(!isNaN(c[f])&&isNaN(d[f])&&c[f]==
parseInt(d[f],10)){return 1}if(isNaN(c[f])&&!isNaN(d[f])&&parseInt(c[f],10)==d[f]){return-1}if(d[f]>c[f]){return-1}else if(d[f]<c[f]){return 1}}return 0};j.userAgent.compare=th;var Qq=function(a){return th(j.userAgent.VERSION,a)>=0};j.userAgent.isVersion=Qq;var m={};j.dom=m;var af={ELEMENT:1,ATTRIBUTE:2,TEXT:3,CDATA_SECTION:4,ENTITY_REFERENCE:5,ENTITY:6,PROCESSING_INSTRUCTION:7,COMMENT:8,DOCUMENT:9,DOCUMENT_TYPE:10,DOCUMENT_FRAGMENT:11,NOTATION:12},Xs=af.ATTRIBUTE,dp=af.DOCUMENT,zg=af.ELEMENT,Ed=af.TEXT;m.NodeType=af;var ed=function(){if(!m.Fn){m.Fn=new X}return m.Fn};m.SB=ed;var hp=function(a){return a?new X(Wa(a)):ed()};m.xv=hp;var Cg=function(){return ed().po()};m.po=Cg;var l=function(a){return ed().eb(a)};m.eb=l;var dd=l;m.Mr=dd;var Dg=function(a,
b,c){return ed().ro(a,b,c)};m.ro=Dg;var $o=Dg;m.Nr=$o;var Fg=function(a,b){Tj(b,function(c,d){if(d=="style"){a.style.cssText=c}else if(d=="class"){a.className=c}else if(d=="for"){a.htmlFor=c}else{a[d]=c}})};m.sz=Fg;var ef=function(a){var b=a||j.global||window,c=b.document.body,d,e;if(typeof opera!="undefined"){d=c.clientWidth;e=c.clientHeight}else if(document.compatMode=="CSS1Compat"){d=c.parentNode.clientWidth;e=c.parentNode.clientHeight}else{d=c.clientWidth;e=c.clientHeight}return new Ac(d,e)};
m.dw=ef;var op=function(a){var b=a||j.global||window,c=b.document,d,e;if(document.compatMode=="CSS1Compat"){d=c.documentElement.scrollLeft;e=c.documentElement.scrollTop}else{d=c.body.scrollLeft;e=c.body.scrollTop}return new aa(d,e)};m.getPageScroll=op;var pp=function(a){return a.parentWindow||a.defaultView};m.getWindow=pp;var Vb=function(a){var b=ed();return b.zn.apply(b,arguments)};m.zn=Vb;m.Or=Vb;m.createElement=function(a){return ed().createElement(a)};m.createTextNode=function(a){return ed().createTextNode(a)};
m.appendChild=function(a,b){a.appendChild(b)};var mj=function(a){var b;while(b=a.firstChild){a.removeChild(b)}};m.Ay=mj;m.removeNode=function(a){if(a.parentNode){a.parentNode.removeChild(a)}};var ip=function(a){return df(a.firstChild,true)};m.Av=ip;var kp=function(a){return df(a.lastChild,false)};m.Hv=kp;var lp=function(a){return df(a.nextSibling,true)};m.Iv=lp;var lj=function(a){return df(a.previousSibling,false)};m.Sv=lj;var df=function(a,b){while(a&&a.nodeType!=zg){a=b?a.nextSibling:a.previousSibling}return a};
m.WB=df;var qp=function(a){return ib(a)&&a.nodeType>0};m.fx=qp;m.contains=function(a,b){if(typeof a.contains!="undefined"){return a.contains(b)}if(typeof a.compareDocumentPosition!="undefined"){return a==b||Boolean(a.compareDocumentPosition(b)&16)}while(b&&a!=b){b=b.parentNode}return b==a};var Wa=function(a){return a.nodeType==dp?a:a.ownerDocument||a.document};m.Mv=Wa;var jp=function(a){return j.userAgent.SAFARI?a.document:a.contentDocument||a.contentWindow.document};m.Bv=jp;var Mc=function(a,b){if("textContent"in
a){a.textContent=b}else if(a.firstChild&&a.firstChild.nodeType==Ed){while(a.lastChild!=a.firstChild){a.removeChild(a.lastChild)}a.firstChild.data=b}else{while(a.hasChildNodes()){a.removeChild(a.lastChild)}var c=Wa(a);a.appendChild(c.createTextNode(b))}};m.yz=Mc;var fp=function(a,b){var c=[];Bg(a,b,c,true);return c[0]};m.nv=fp;var gp=function(a,b){var c=[];Bg(a,b,c,false);return c};m.ov=gp;var Bg=function(a,b,c,d){if(a!=null){for(var e=0,f;f=a.childNodes[e];e++){if(b(f)){c.push(f);if(d){return}}Bg(f,
b,c,d)}}};m.tB=Bg;var kj={SCRIPT:1,STYLE:1,HEAD:1,IFRAME:1,OBJECT:1};m.TAGS_TO_IGNORE=kj;var bf={IMG:" ",BR:"\n"};m.PREDEFINED_TAG_VALUES=bf;var Eg=function(a){if(a.innerText){return qq(a.innerText)}var b=[],c=function(e){if(e.nodeName in kj){}else if(e.nodeType==Ed){b.push(String(e.nodeValue).replace(/(\r\n|\r|\n)/g,""))}else if(e.nodeName in bf){b.push(bf[e.nodeName])}else{var f=e.firstChild;while(f){c(f);f=f.nextSibling}}};c(a);var d=b.join("").replace(/ +/g," ");if(d!=" "){d=d.replace(/^\s*/,
"")}return d};m.aw=Eg;var mp=function(a){return Eg(a).length};m.Jv=mp;var np=function(a,b){var c=b||Wa(a).body,d=[];while(a&&a!=c){var e=a;while(e=e.previousSibling){d.unshift(Eg(e))}a=a.parentNode}return wq(d.join("")).replace(/ +/g," ").length};m.Kv=np;m.getNodeAtOffset=function(a,b,c){var d=[a],e=0,f;while(d.length>0&&e<b){f=d.pop();if(f.nodeName in kj){}else if(f.nodeType==Ed){var g=f.nodeValue.replace(/(\r\n|\r|\n)/g,"").replace(/ +/g," ");e+=g.length}else if(f.nodeName in bf){e+=bf(f.nodeName).length}else{for(var h=
f.childNodes.length-1;h>=0;h--){d.push(f.childNodes[h])}}}if(ib(c)){c.remainder=f?f.nodeValue.length+b-e-1:0;c.node=f}return f};var X=function(a){this.Yf=a||j.global.document||document};m.DomHelper=X;X.prototype.xv=hp;X.prototype.po=function(){return this.Yf};var bp=function(a){if(la(a)){return this.Yf.getElementById(a)}else{return a}};X.prototype.eb=bp;X.prototype.Mr=bp;var cp=function(a,b,c){var d=a||"*",e=c||this.Yf,f=e.getElementsByTagName(d);if(b){return x.filter(f,function(g){return x.contains(g.className.split(" "),
b)})}else{return f}};X.prototype.ro=cp;X.prototype.Nr=cp;X.prototype.sz=Fg;X.prototype.dw=ef;var ap=function(a,b){if(j.userAgent.IE&&b&&b.name){a="<"+a+' name="'+za(b.name)+'">'}var c=this.createElement(a);if(b){Fg(c,b)}if(arguments.length>2){var d=x.slice(arguments,2),e=function(g){if(la(g)){this.appendChild(c,this.createTextNode(g))}else if(g){this.appendChild(c,g)}};for(var f=0;f<d.length;f++){if(Ta(d[f])){Wi(d[f],e,this)}else{e.call(this,d[f])}}}return c};X.prototype.zn=ap;X.prototype.Or=ap;X.prototype.createElement=
function(a){return this.Yf.createElement(a)};X.prototype.createTextNode=function(a){return this.Yf.createTextNode(a)};X.prototype.appendChild=m.appendChild;X.prototype.Ay=mj;X.prototype.removeNode=m.removeNode;X.prototype.Av=ip;X.prototype.Hv=kp;X.prototype.Iv=lp;X.prototype.Sv=lj;X.prototype.fx=qp;X.prototype.contains=m.contains;X.prototype.Mv=Wa;X.prototype.Bv=jp;X.prototype.yz=Mc;X.prototype.nv=fp;X.prototype.ov=gp;X.prototype.aw=Eg;X.prototype.Jv=mp;X.prototype.Kv=np;j.style={};var gh=function(a,b,c){a.style[dk(b)]=c};j.style.setStyle=gh;j.style.getStyle=function(a,b){return a.style[dk(b)]};var fh=function(a,b){var c=Wa(a);if(c.defaultView&&c.defaultView.getComputedStyle){var d=c.defaultView.getComputedStyle(a,"");if(d){return d[b]}}if(a.currentStyle){return a.currentStyle[b]}else{return a.style[b]}};j.style.bC=fh;j.style.getBackgroundColor=function(a){return fh(a,"backgroundColor")};j.style.setPosition=function(a,b,c){var d,e;if(b instanceof aa){d=b.x;e=b.y}else{d=
b;e=c}a.style.left=typeof d=="number"?Math.round(d)+"px":d;a.style.top=typeof e=="number"?Math.round(e)+"px":e};j.style.Qv=function(a){return new aa(a.offsetLeft,a.offsetTop)};var Pb=function(a){var b;if(a){if(a.nodeType==dp){b=a}else{b=Wa(a)}}else{b=Cg()}if(j.userAgent.IE&&b.compatMode!="CSS1Compat"){return b.body}return b.documentElement};j.style.getClientViewportElement=Pb;var pa=function(a){var b=Wa(a),c=new aa(0,0),d=Pb(b);if(a==d){return c}var e=null,f;if(a.getBoundingClientRect){f=a.getBoundingClientRect();
var g=d.scrollTop,h=d.scrollLeft;c.x=f.left+h;c.y=f.top+g}else if(b.getBoxObjectFor){f=b.getBoxObjectFor(a);var i=b.getBoxObjectFor(d);c.x=f.screenX-i.screenX;c.y=f.screenY-i.screenY}else{c.x=a.offsetLeft;c.y=a.offsetTop;e=a.offsetParent;if(e!=a){while(e){c.x+=e.offsetLeft;c.y+=e.offsetTop;e=e.offsetParent}}if(j.userAgent.OPERA||j.userAgent.SAFARI&&fh(a,"position")=="absolute"){c.y-=b.body.offsetTop}e=a.parentNode;while(e&&e!=d){c.x-=e.scrollLeft;if(!j.userAgent.OPERA||e.tagName!="TR"){c.y-=e.scrollTop}e=
e.parentNode}}return c};j.style.getPageOffset=pa;j.style.getPageOffsetLeft=function(a){return pa(a).x};var uf=function(a){return pa(a).y};j.style.getPageOffsetTop=uf;j.style.getRelativePosition=function(a,b){var c=ck(a),d=ck(b);return new aa(c.x-d.x,c.y-d.y)};var ck=function(a){var b=new aa;if(a.nodeType==zg){if(a.getBoundingClientRect){var c=a.getBoundingClientRect();b.x=c.left;b.y=c.top}else{var d=Wa(a),e=Pb(d),f=pa(a);b.x=f.x-e.scrollLeft;b.y=f.y-e.scrollTop}}else{b.x=a.clientX;b.y=a.clientY}return b};
j.style.getClientPosition=ck;var xe=function(a,b,c){var d=pa(a);if(b instanceof aa){c=b.y;b=b.x}var e=b-d.x,f=c-d.y;j.style.setPosition(a,a.offsetLeft+e,a.offsetTop+f)};j.style.setPageOffset=xe;var ye=function(a,b,c){var d;if(b instanceof Ac){d=b.height;b=b.width}else{d=c}a.style.width=typeof b=="number"?Math.round(b)+"px":b;a.style.height=typeof d=="number"?Math.round(d)+"px":d};j.style.setSize=ye;var bb=function(a){if(fh(a,"display")!="none"){return new Ac(a.offsetWidth,a.offsetHeight)}var b=a.style,
c=b.visibility,d=b.position;b.visibility="hidden";b.position="absolute";b.display="";var e=a.offsetWidth,f=a.offsetHeight;b.display="none";b.position=d;b.visibility=c;return new Ac(e,f)};j.style.Zd=bb;var dk=function(a){return String(a).replace(/\-([a-z])/g,function(b,c){return c.toUpperCase()})};j.style.toCamelCase=dk;j.style.toSelectorCase=function(a){return a.replace(/([A-Z])/g,"-$1").toLowerCase()};var Qd=function(a,b){var c=a.style;if("opacity"in c){c.opacity=b}else if("MozOpacity"in c){c.MozOpacity=
b}else if("KhtmlOpacity"in c){c.KhtmlOpacity=b}else if("filter"in c){c.filter="alpha(opacity="+b*100+")"}};j.style.se=Qd;var cb=function(a,b){a.style.display=b?"":"none"};j.style.showElement=cb;var I={};m.classes=I;I.ma=function(a,b){a.className=b};var cf=function(a){return a.className.split(" ")};I.ha=cf;I.add=function(a,b){var c=cf(a),d=x.slice(arguments,1),e=1;for(var f=0;f<d.length;f++){if(!x.contains(c,d[f])){c.push(d[f]);e&=1}else{e&=0}}a.className=c.join(" ");return Boolean(e)};I.remove=function(a,b){var c=cf(a),d=x.slice(arguments,1),e=0;for(var f=0;f<c.length;f++){if(x.contains(d,c[f])){x.splice(c,f--,1);e++}}a.className=c.join(" ");return e==d.length};var ep=function(a,b,c){var d=
cf(a),e=false;for(var f=0;f<d.length;f++){if(d[f]==b){x.splice(d,f--,1);e=true}}if(e){d.push(c);a.className=d.join(" ")}return e};I.swap=ep;var Ag=function(a,b){return x.contains(cf(a),b)};I.has=Ag;I.toggle=function(a,b){if(Ag(a,b)){I.remove(a,b);return false}else{I.add(a,b);return true}};var ab={};j.structs=ab;var ak=function(a){if(typeof a.Ua=="function"){return a.Ua()}if(Za(a)||la(a)){return a.length}return Uj(a)};ab.Ua=ak;var qd=function(a){if(typeof a.Va=="function"){return a.Va()}if(la(a)){return a.split("")}if(Za(a)){var b=[],c=a.length;for(var d=0;d<c;d++){b.push(a[d])}return b}return Vj(a)};ab.Va=qd;var we=function(a){if(typeof a.Zb=="function"){return a.Zb()}if(typeof a.Va=="function"){return undefined}if(Za(a)||la(a)){var b=[],c=a.length;for(var d=0;d<c;d++){b.push(d)}return b}return sf(a)};
ab.Zb=we;ab.contains=function(a,b){if(typeof a.contains=="function"){return a.contains(b)}if(Za(a)||la(a)){return x.contains(a,b)}return Sj(a,b)};var bk=function(a){if(typeof a.bc=="function"){return a.bc()}if(Za(a)||la(a)){return Oo(a)}return oq(a)};ab.bc=bk;ab.clear=function(a){if(typeof a.clear=="function"){a.clear()}else if(Za(a)){x.clear(a)}else{j.object.clear(a)}};var pd=function(a,b,c){if(typeof a.forEach=="function"){a.forEach(b,c)}else if(Za(a)||la(a)){Wi(a,b,c)}else{var d=we(a),e=qd(a),
f=e.length;for(var g=0;g<f;g++){b.call(c,e[g],d&&d[g],a)}}};ab.forEach=pd;ab.filter=function(a,b,c,d){if(typeof a.filter=="function"){return a.filter(b,c)}if(Za(a)||la(a)){return x.filter(a,b,c)}var e,f=we(a),g=qd(a),h=g.length;if(f&&O){e=new (d||Object);for(var i=0;i<h;i++){if(b.call(c,g[i],f[i],a)){$j(e,f[i],g[i])}}}else if(oa){e=new (d||Array);for(var i=0;i<h;i++){if(b.call(c,g[i],undefined,a)){oa.add(e,g[i])}}}return e};ab.map=function(a,b,c,d){if(typeof a.map=="function"){return a.map(b,c)}if(Za(a)||
la(a)){return Yi(a,b,c)}var e,f=we(a),g=qd(a),h=g.length;if(f&&O){e=new (d||Object);for(var i=0;i<h;i++){$j(e,f[i],b.call(c,g[i],f[i],a))}}else if(oa){e=new (d||Array);for(var i=0;i<h;i++){oa.add(e,f[i],b.call(c,g[i],undefined,a))}}return e};var Aq=function(a,b,c){if(typeof a.some=="function"){return a.some(b,c)}if(Za(a)||la(a)){return Po(a,b,c)}var d=we(a),e=qd(a),f=e.length;for(var g=0;g<f;g++){if(b.call(c,e[g],d&&d[g],a)){return true}}return false};ab.some=Aq;ab.every=function(a,b,c){if(typeof a.every==
"function"){return a.every(b,c)}if(Za(a)||la(a)){return No(a,b,c)}var d=we(a),e=qd(a),f=e.length;for(var g=0;g<f;g++){if(!b.call(c,e[g],d&&d[g],a)){return false}}return true};var O=function(a){this.wa={};if(a){this.ij(a)}};ab.Map=O;O.prototype.tb=0;O.prototype.Ua=function(){return this.tb};var dh=function(a){return a.charAt(0)==":"};O.mC=dh;var yq=function(a){return a.substring(1)};O.Gv=yq;var tf=function(a){return":"+a};O.AC=tf;O.prototype.Va=function(){var a=[];for(var b in this.wa){if(dh(b)){a.push(this.wa[b])}}return a};O.prototype.Zb=function(){var a=[];for(var b in this.wa){if(dh(b)){a.push(yq(b))}}return a};O.prototype.Cb=function(a){return tf(a)in this.wa};O.prototype.th=
function(a){for(var b in this.wa){if(dh(b)&&this.wa[b]==a){return true}}return false};O.prototype.bc=function(){return this.tb==0};O.prototype.clear=function(){this.wa={};this.tb=0};O.prototype.remove=function(a){if(j.object.remove(this.wa,tf(a))){this.tb--;return true}return false};O.prototype.ha=function(a,b){var c=tf(a);if(c in this.wa){return this.wa[c]}return b};O.prototype.ma=function(a,b){var c=tf(a);if(!(c in this.wa)){this.tb++}this.wa[c]=b};O.prototype.ij=function(a){var b,c;if(a instanceof
O){b=a.Zb();c=a.Va()}else{b=sf(a);c=Vj(a)}for(var d=0;d<b.length;d++){this.ma(b[d],c[d])}};O.prototype.Ca=function(){return new O(this)};O.Ua=function(a){return ak(a)};O.Va=function(a){return qd(a)};O.Zb=function(a){if(typeof a.Zb=="function"){return a.Zb()}var b=[];if(Za(a)){for(var c=0;c<a.length;c++){b.push(c)}}else{return sf(a)}return b};var Zj=function(a,b){if(typeof a.Cb=="function"){return a.Cb(b)}if(Za(a)){return b<a.length}return nq(a,b)};O.Cb=Zj;O.th=function(a,b){return ab.contains(a,b)};
O.bc=function(a){return bk(a)};O.clear=function(a){ab.clear(a)};O.remove=function(a,b){if(typeof a.remove=="function"){return a.remove(b)}if(Za(a)){return Zi(a,b)}return j.object.remove(a,b)};O.add=function(a,b,c){if(typeof a.add=="function"){a.add(b,c)}else if(Zj(a,b)){throw Error('The collection already contains the key "'+b+'"');}else{Wj(a,b,c)}};O.ha=function(a,b,c){if(typeof a.ha=="function"){return a.ha(b,c)}if(Zj(a,b)){return a[b]}return c};var $j=function(a,b,c){if(typeof a.ma=="function"){a.ma(b,
c)}else{a[b]=c}};O.ma=$j;var oa=function(a){this.wa=new O;if(a){this.ij(a)}};ab.Set=oa;var eh=function(a){var b=typeof a;if(b=="object"){return"o"+Ab(a)}else{return b.substr(0,1)+a}};oa.Gv=eh;oa.prototype.Ua=function(){return this.wa.Ua()};oa.prototype.add=function(a){this.wa.ma(eh(a),a)};oa.prototype.ij=function(a){var b=zq(a),c=b.length;for(var d=0;d<c;d++){this.add(b[d])}};oa.prototype.remove=function(a){return this.wa.remove(eh(a))};oa.prototype.clear=function(){this.wa.clear()};oa.prototype.bc=function(){return this.wa.bc()};
oa.prototype.contains=function(a){return this.wa.Cb(eh(a))};oa.prototype.Va=function(){return this.wa.Va()};oa.prototype.Ca=function(){return new oa(this)};oa.Ua=function(a){return ak(a)};var zq=function(a){return qd(a)};oa.Va=zq;oa.contains=function(a,b){return ab.contains(a,b)};oa.bc=function(a){return bk(a)};oa.clear=function(a){ab.clear(a)};oa.remove=function(a,b){if(typeof a.remove=="function"){return a.remove(b)}else if(Za(a)){return x.remove(a,b)}else{for(var c in a){if(a[c]==b){delete a[c];
return true}}return false}};oa.add=function(a,b){if(typeof a.add=="function"){a.add(b)}else if(Za(a)){a[a.length]=b}else{throw Error('The collection does not know how to add "'+b+'"');}};var w=function(a){var b;if(a instanceof w){this.Ai(a.Ko());this.Ci(a.Po());this.qi(a.qo());this.xi(a.ck());this.wi(a.bk());this.yi(a.Uv().Ca());this.ri(a.to())}else if(a&&(b=String(a).match(Ko()))){this.Ai(b[1],true);this.Ci(b[2],true);this.qi(b[3],true);this.xi(b[4]);this.wi(b[5],true);this.yi(b[6]);this.ri(b[7],true)}else{this.Qb=new Ea(null,this)}};j.Uri=w;w.prototype.dd="";w.prototype.Gd="";w.prototype.Me="";w.prototype.ff=null;w.prototype.df="";w.prototype.Qb=null;w.prototype.Oe="";w.prototype.toString=
function(){if(this.kb){return this.kb}var a=[];if(this.dd){a.push(tg(this.dd,Ui),":")}if(this.Me){a.push("//");if(this.Gd){a.push(tg(this.Gd,Ui),"@")}a.push(Ti(this.Me));if(this.ff!=null){a.push(":",String(this.ck()))}}if(this.df){a.push(tg(this.df,Lo))}var b=String(this.Qb);if(b){a.push("?",b)}if(this.Oe){a.push("#",Ti(this.Oe))}return this.kb=a.join("")};w.prototype.Jq=function(a){var b=this.Ca(),c=a.yw();if(c){b.Ai(a.Ko())}else{c=a.zw()}if(c){b.Ci(a.Po())}else{c=a.tw()}if(c){b.qi(a.qo())}else{c=
a.ww()}var d=a.bk();if(c){b.xi(a.ck())}else{c=a.vw();if(c){if(!/^\//.test(d)){d=b.bk().replace(/\/?[^\/]*$/,"/"+d)}}}if(c){b.wi(d)}else{c=a.xw()}if(c){b.yi(a.Tv())}else{c=a.uw()}if(c){b.ri(a.to())}return b};w.prototype.Ca=function(){return new Io(this.dd,this.Gd,this.Me,this.ff,this.df,this.Qb.Ca(),this.Oe)};w.prototype.Ko=function(){return this.dd};w.prototype.Ai=function(a,b){delete this.kb;this.dd=b?he(a):a;if(this.dd){this.dd=this.dd.replace(/:$/,"")}return this};w.prototype.yw=function(){return!(!this.dd)};
w.prototype.Po=function(){return this.Gd};w.prototype.Ci=function(a,b){delete this.kb;this.Gd=b?he(a):a;return this};w.prototype.zw=function(){return!(!this.Gd)};w.prototype.qo=function(){return this.Me};w.prototype.qi=function(a,b){delete this.kb;this.Me=b?he(a):a;return this};w.prototype.tw=function(){return!(!this.Me)};w.prototype.ck=function(){return this.ff};w.prototype.xi=function(a){delete this.kb;if(a){a=Number(a);if(isNaN(a)||a<0){throw Error("Bad port number "+a);}this.ff=a}else{this.ff=
null}return this};w.prototype.ww=function(){return this.ff!=null};w.prototype.bk=function(){return this.df};w.prototype.wi=function(a,b){delete this.kb;this.df=b?he(a):a;return this};w.prototype.vw=function(){return!(!this.df)};w.prototype.xw=function(){return this.Qb!==null&&this.Qb.toString()!==""};w.prototype.yi=function(a){delete this.kb;if(a instanceof Ea){this.Qb=a;this.Qb.Ka=this}else{this.Qb=new Ea(a,this)}return this};w.prototype.Tv=function(){return this.Qb.toString()};w.prototype.Uv=function(){return this.Qb};
w.prototype.$a=function(a,b){delete this.kb;this.Qb.ma(a,b);return this};w.prototype.nz=function(a,b){delete this.kb;if(!Ta(b)){b=[String(b)]}this.Qb.Ez(a,b);return this};w.prototype.eg=function(a){return this.Qb.ha(a)};w.prototype.to=function(){return this.Oe};w.prototype.ri=function(a,b){delete this.kb;this.Oe=b?he(a):a;return this};w.prototype.uw=function(){return!(!this.Oe)};w.parse=function(a){return a instanceof w?a.Ca():new w(a)};var Io=function(a,b,c,d,e,f,g){var h=new w;h.Ai(a);h.Ci(b);h.qi(c);
h.xi(d);h.wi(e);h.yi(f);h.ri(g);return h};w.create=Io;w.Jq=function(a,b){if(!(a instanceof w)){a=w.parse(a)}if(!(b instanceof w)){b=w.parse(b)}return a.Jq(b)};var he=function(a){return a?bh(a):""};w.mB=he;var Ti=function(a){if(la(a)){return encodeURIComponent(a)}return null};w.qB=Ti;var tg=function(a,b){if(la(a)){return encodeURI(a).replace(b,Jo)}return null};w.pB=tg;var Jo=function(a){var b=a.charCodeAt(0);return"%"+(b>>4&15).toString(16)+(b&15).toString(16)};w.oB=Jo;var ug=null;w.ty=ug;var Ko=function(){if(!ug){ug=
(w.ty=/^(?:([^:\/?#]+):)?(?:\/\/(?:([^\/?#]*)@)?([^\/?#:@]*)(?::([0-9]+))?)?([^?#]+)?(?:\?([^#]*))?(?:#(.*))?$/)}return ug};w.YB=Ko;var Ui=/[#\/\?@]/g;w.RC=Ui;var Lo=/[\#\?]/g;w.QC=Lo;var Ea=function(a,b){this.Wa=new O;this.Ka=b;if(a){var c=a.split("&");for(var d=0;d<c.length;d++){var e=c[d].split("=");this.add(bh(e[0]),e.length>1?bh(e[1]):"")}}};w.QueryData=Ea;Ea.prototype.tb=0;Ea.prototype.Ua=function(){return this.tb};Ea.prototype.add=function(a,b){this.rg();if(!this.Cb(a)){this.Wa.ma(a,[b])}else{this.Wa.ha(a).push(b)}this.tb++;
return this};Ea.prototype.remove=function(a){if(this.Wa.Cb(a)){this.rg();this.tb-=this.Wa.ha(a).length;return this.Wa.remove(a)}return false};Ea.prototype.clear=function(){this.rg();this.Wa.clear();this.tb=0};Ea.prototype.bc=function(){return this.tb==0};Ea.prototype.Cb=function(a){return this.Wa.Cb(a)};Ea.prototype.th=function(a){var b=this.Va();return x.contains(b,a)};Ea.prototype.Zb=function(){var a=this.Wa.Va(),b=this.Wa.Zb(),c=[];for(var d=0;d<b.length;d++){for(var e=0;e<a[d].length;e++){c.push(b[d])}}return c};
Ea.prototype.Va=function(a){if(a){if(this.Cb(a)){return this.Wa.ha(a)}else{return[]}}else{var b=this.Wa.Va();return Array.prototype.concat.apply([],b)}};Ea.prototype.ma=function(a,b){this.rg();if(this.Cb(a)){var c=this.Wa.ha(a);this.tb-=c.length}this.Wa.ma(a,[b]);this.tb++;return this};Ea.prototype.ha=function(a,b){if(this.Cb(a)){return this.Wa.ha(a)[0]}else{return b}};Ea.prototype.Ez=function(a,b){this.rg();if(this.Cb(a)){var c=this.Wa.ha(a);this.tb-=c.length}if(b.length>0){this.Wa.ma(a,b);this.tb+=
b.length}};Ea.prototype.toString=function(){if(this.kb){return this.kb}var a=[],b=this.Zb(),c=this.Va();for(var d=0;d<b.length;d++){a.push(encodeURIComponent(b[d])+"="+encodeURIComponent(c[d]))}return this.kb=a.join("&")};Ea.prototype.rg=function(){delete this.kb;if(this.Ka){delete this.Ka.kb}};Ea.prototype.Ca=function(){var a=new Ea;a.Wa=this.Wa.Ca();return a};var ue=function(a){this.Be=j.userAgent.IE?[]:"";if(a){this.Da(a)}};F.StringBuffer=ue;ue.prototype.Da=function(a){if(j.userAgent.IE){for(var b=0;b<arguments.length;b++){this.Be.push(arguments[b])}}else{for(var b=0;b<arguments.length;b++){this.Be+=arguments[b]}}return this};ue.prototype.clear=function(){if(j.userAgent.IE){this.Be.length=0}else{this.Be=""}};ue.prototype.toString=function(){if(j.userAgent.IE){return this.Be.join("")}else{return this.Be}};var Ra={};j.debug=Ra;Ra.catchErrors=function(a,b,c){var d=a||xg(),e=c||j.global,f=e.onerror;e.onerror=function(g,h,i){if(f){f(g,h,i)}var k=String(h).split(/[\/\\]/).pop();d.er("Error: "+g+" ("+k+" @ Line: "+i+")");return Boolean(b)}};Ra.expose=function(a){if(!Y(a))return"undefined";if(a==null)return"NULL";var b=[];for(var c in a){var d=c+" = ";try{d+=a[c]}catch(e){d+="*** "+e+" ***"}b.push(d)}return b.join("\n")};Ra.deepExpose=function(a){var b=new oa,c=new ue,d=function(e,f){var g=f+"  ",h=function(n){return n.replace(/\n/g,
"\n"+f)};try{if(!Y(e)){c.Da("undefined")}else if(bq(e)){c.Da("NULL")}else if(la(e)){c.Da('"'+h(e)+'"')}else if(ld(e)){c.Da(h(String(e)))}else if(ib(e)){if(b.contains(e)){c.Da("*** reference loop detected ***")}else{b.add(e);c.Da("{");for(var i in e){c.Da("\n");c.Da(g);c.Da(i+" = ");d(e[i],g)}c.Da("\n"+f+"}")}}else{c.Da(e)}}catch(k){c.Da("*** "+k+" ***")}};d(a,"");return c.toString()};var Vo=function(a){var b=[];for(var c=0;c<a.length;c++){if(Ta(a[c])){b.push(Vo(a[c]))}else{b.push(a[c])}}return"[ "+
b.join(", ")+" ]"};Ra.exposeArray=Vo;var Wo=function(a,b){try{var c=Zo(a),d="Message: "+za(c.message)+'\nUrl: <a href="view-source:'+c.filename+'" target="_new">'+c.fileName+"</a>\nLine: "+c.lineNumber+"\n\nBrowser stack:\n"+za(c.stack+"-> ")+"[end]\n\nJS stack traversal:\n"+za(jj(b||arguments.callee)+"-> ");return d}catch(e){return"Exception trying to expose exception! You win, we lose. "+e}};Ra.exposeException=Wo;var Zo=function(a){return typeof a=="string"?{message:a,name:"Unknown error",lineNumber:"Not available",
fileName:j.global.document.location.href,stack:"Not available"}:(!a.lineNumber||!a.fileName||!a.stack?{message:a.message,name:a.name,lineNumber:"Not available",fileName:j.global.document.location.href,stack:"Not available"}:a)};Ra.normalizeErrorObject=Zo;var Uo=50;Ra.MAX_STACK_DEPTH=Uo;var jj=function(a,b){var c=new ue,d=b||[];if(x.contains(d,a)){c.Da("[...circular reference...]")}else if(a&&d.length<Uo){c.Da(Yo(a)+"(");var e=a.arguments;for(var f=0;f<e.length;f++){if(f>0){c.Da(", ")}var g=typeof e[f]==
"object"&&e[f].toSource?e[f].toSource():String(e[f]);if(g.length>40){g=g.substr(0,40)+"..."}c.Da(g)}d.push(a);c.Da(")\n");try{c.Da(jj(a.caller,d))}catch(h){c.Da("[exception trying to get caller]\n")}}else if(a){c.Da("[...long stack...]")}else{c.Da("[end]")}return c.toString()};Ra.getStacktrace=jj;var Yo=function(a){if(!$e[a]){var b=/function ([^\(]+)/.exec(String(a));if(b){var c=b[1],d=/^\$(.+)\$$/.exec(c);if(d){c=d[1].replace(/\${1,2}/g,".")}$e[a]=c}else{$e[a]="[Anonymous]"}}return $e[a]};Ra.getFunctionName=
Yo;var Xo=function(a,b,c,d){if(document.all){return""}var e=b||j.global,f=c||"",g=d||0;if(e==a){return f}for(var h in e){if(h=="Packages"||h=="sun"||h=="netscape"||h=="java"){continue}if(e[h]==a){return f+h}if((typeof e[h]=="function"||typeof e[h]=="object")&&e[h]!=j.global&&e[h]!=j.global.document&&e.hasOwnProperty(h)&&g<6){var i=Xo(a,e[h],f+h+".",g+1);if(i)return i}}return""};Ra.QB=Xo;var $e={};Ra.vB=$e;var xa=function(a){this.wd=a;this.$=null;this.Au={};this.Ue=[]};Ra.Logger=xa;xa.prototype.fe=null;var Fa=function(a,b){this.name=a;this.value=b};xa.Level=Fa;Fa.OFF=new Fa("OFF",Number.INFINITY);var To=new Fa("SHOUT",1200);Fa.SHOUT=To;var gj=new Fa("SEVERE",1000);Fa.SEVERE=gj;var hj=new Fa("WARNING",900);Fa.WARNING=hj;var fj=new Fa("INFO",800);Fa.INFO=fj;var So=new Fa("CONFIG",700);Fa.CONFIG=So;var ej=new Fa("FINE",500);Fa.FINE=ej;Fa.FINER=new Fa("FINER",400);Fa.FINEST=new Fa("FINEST",300);Fa.ALL=
new Fa("ALL",0);var ij=function(a){return cj(a)};xa.getLogger=ij;xa.prototype.Do=function(){return this.wd};xa.prototype.Tt=function(a){this.Ue.push(a)};xa.prototype.Dy=function(a){for(var b=0;b<this.Ue.length;b++){if(this.Ue[b]==a){this.Ue.splice(b,1);return true}}return false};xa.prototype.gg=function(){return this.$};xa.prototype.Zq=function(a){this.fe=a};xa.prototype.Zj=function(){return this.fe};xa.prototype.tk=function(a){if(this.fe){return a.value>=this.fe.value}if(this.$){return this.$.tk(a)}return false};
xa.prototype.log=function(a,b,c){if(!this.tk(a)){return}var d=new Fb(a,String(b),this.wd);if(c){d.gz(c);d.hz(Wo(c,arguments.callee.caller))}this.ux(d)};xa.prototype.er=function(a,b){this.log(gj,a,b)};xa.prototype.Ql=function(a,b){this.log(hj,a,b)};xa.prototype.wb=function(a,b){this.log(fj,a,b)};xa.prototype.bo=function(a,b){this.log(ej,a,b)};xa.prototype.ux=function(a){if(!this.tk(a.Zj())){return}var b=this;while(b){b.tu(a);b=b.gg()}};xa.prototype.tu=function(a){for(var b=0;b<this.Ue.length;b++){this.Ue[b](a)}};
xa.prototype.pz=function(a){this.$=a};xa.prototype.Rt=function(a,b){this.Au[a]=b};var Lc={};Ra.LogManager=Lc;var Ze={};Lc.Jp=Ze;var ie=null;Lc.Ny=ie;var dj=function(){if(!ie){ie=(Lc.Ny=new xa(""));Ze[""]=ie;ie.Zq(So)}};Lc.initialize=dj;Lc.getLoggers=function(){return Ze};var xg=function(){dj();return ie};Lc.getRoot=xg;var cj=function(a){dj();var b=Ze[a];if(b==null){b=Ro(a)}return b};Lc.getLogger=cj;var Ro=function(a){var b=new xa(a),c=a.split("."),d=c[c.length-1];c.length=c.length-1;var e=c.join("."),
f=cj(e);f.Rt(d,b);b.pz(f);Ze[a]=b;return b};Lc.jB=Ro;var Fb=function(a,b,c){this.VC=j.debug.LogRecord.Nx++;this.aA=Bb();this.fe=a;this.Kx=b;this.vx=c};Ra.LogRecord=Fb;Fb.prototype.Wn=null;Fb.prototype.Vn=null;Fb.Nx=0;Fb.prototype.yo=function(){return this.vx};Fb.prototype.yv=function(){return this.Wn};Fb.prototype.gz=function(a){this.Wn=a};Fb.prototype.zv=function(){return this.Vn};Fb.prototype.hz=function(a){this.Vn=a};Fb.prototype.Zj=function(){return this.fe};Fb.prototype.Zq=function(a){this.fe=a};Fb.prototype.Ao=function(){return this.Kx};Fb.prototype.Bo=
function(){return this.aA};var Ub=function(a){this.xq=a||"";this.Dq=Bb()};Ra.Formatter=Ub;Ub.prototype.vl=true;Ub.prototype.kr=true;Ub.prototype.jr=true;Ub.prototype.Kh=function(a){throw Error("Must override formatRecord");};var $i=function(a){var b=new Date(a.Bo());return cd(b.getFullYear()-2000)+cd(b.getMonth()+1)+cd(b.getDate())+" "+cd(b.getHours())+":"+cd(b.getMinutes())+":"+cd(b.getSeconds())+"."+cd(Math.floor(b.getMilliseconds()/10))};Ub.RB=$i;var cd=function(a){if(a<10){return"0"+a}return String(a)};Ub.cC=cd;var aj=
function(a,b){var c=a.Bo()-b,d=c/1000,e=d.toFixed(3),f=0;if(d<1){f=2}else{while(d<100){f++;d*=10}}while(f-- >0){e=" "+e}return e};Ub.$B=aj;var bj=function(a){Ub.call(this,a)};Ra.HtmlFormatter=bj;bj.la(Ub);bj.prototype.Kh=function(a){var b;switch(a.Zj()){case To:b="dbg-sh";break;case gj:b="dbg-sev";break;case hj:b="dbg-w";break;case fj:b="dbg-i";break;case ej:default:b="dbg-f";break}var c=[];c.push(this.xq);c.push(" ");if(this.vl){c.push("["+$i(a)+"] ")}if(this.kr){c.push("[");c.push(ch(aj(a,this.Dq)));
c.push("s] ")}if(this.jr){c.push("[");c.push(za(a.yo()));c.push("] ")}c.push('<span class="'+b+'">');c.push($g(ch(za(a.Ao()))));if(a.yv()){c.push("<br>");c.push($g(ch(a.zv())))}c.push("</span><br>");return c.join("")};var yg=function(a){Ub.call(this,a)};Ra.TextFormatter=yg;yg.la(Ub);yg.prototype.Kh=function(a){var b=[];b.push(this.xq);b[b.length]=" ";if(this.vl){b.push("[");b.push($i(a));b.push("] ")}if(this.kr){b.push("[");b.push(aj(a,this.Dq));b.push("s] ")}if(this.jr){b.push("["+a.yo()+"] ")}b.push(a.Ao());
b.push("\n");return b.join("")};var Kc=function(){this.Aq=this.Xx.p(this);this.Wj=new yg;this.Wj.vl=false;this.$w=false;this.Ip=""};Ra.Console=Kc;Kc.prototype.az=function(a){if(a==this.$w){return}if(a){xg().Tt(this.Aq)}else{xg().Dy(this.Aq);this.logBuffer=""}};Kc.prototype.Xx=function(a){if(window.console){window.console.log(this.Wj.Kh(a))}else{this.Ip+=this.Wj.Kh(a)}};var wg=null;Kc.instance=wg;Kc.autoInstall=function(){if(!Kc.Yh){wg=(Kc.instance=new Kc)}if(document.location.href.indexOf("Debug=true")!=-1){wg.az(true)}};Kc.hd=
function(){alert(wg.Ip)};var na={};j.ds=na;var yp={};na.Util=yp;var Wb=function(){};na.DataNode=Wb;Wb.prototype.ha=function(){};Wb.prototype.ma=function(a){};Wb.prototype.jc=function(a){};Wb.prototype.Fb=function(a){};Wb.prototype.vb=function(a){};Wb.prototype.Xq=function(a,b){};Wb.prototype.ya=function(){};Wb.prototype.ol=function(a){};Wb.prototype.Gb=function(){};Wb.prototype.lc=function(){};var gf={LOADED:"LOADED",LOADING:"LOADING",FAILED:"FAILED",NOT_LOADED:"NOT_LOADED"},Jg=gf.FAILED,uj=gf.LOADED,wp=gf.LOADING,hf=gf.NOT_LOADED;
na.LoadState=gf;var wc=function(){};na.BaseDataNode=wc;wc.prototype.ma=function(a){};wc.prototype.jc=function(a){return new fd};wc.prototype.Fb=function(a,b){return null};wc.prototype.vb=function(a){return null};wc.prototype.Gb=function(){var a="",b=this.ya();if(this.Ph&&this.Ph()){a=this.Ph().Gb()+(b.indexOf(wj)!=-1?"":Kg)}return a+b};wc.prototype.lc=function(){};wc.prototype.Ph=null;var Gd=function(){};na.DataNodeList=Gd;Gd.prototype.add=function(a){};Gd.prototype.ha=function(a){};Gd.prototype.Mh=
function(a){};Gd.prototype.Ua=function(){};Gd.prototype.sl=function(a,b){};Gd.prototype.removeNode=function(a){};var fb=function(a){this.wa={};this.vd=[];this.sd={};if(a){for(var b=0,c;c=a[b];b++){this.add(c)}}};na.BasicNodeList=fb;fb.prototype.add=function(a){this.vd.push(a);var b=a.ya();if(b!=null){this.wa[b]=a;this.sd[b]=this.vd.length-1}};fb.prototype.ha=function(a){return this.wa[a]||null};fb.prototype.Mh=function(a){return this.vd[a]||null};fb.prototype.Ua=function(){return this.vd.length};
fb.prototype.sl=function(a,b){if(b==null){this.removeNode(a)}else{var c=this.sd[a];if(c!=null){this.wa[a]=b;this.vd[c]=b}else{this.add(b)}}};fb.prototype.removeNode=function(a){var b=this.sd[a];if(b!=null){this.vd.splice(b,1);delete this.wa[a];delete this.sd[a];for(var c in this.sd){if(this.sd[c]>b){this.sd[c]--}}}return b!=null};fb.prototype.indexOf=function(a){return this.sd[a]};var fd=function(){fb.call(this)};na.EmptyNodeList=fd;fd.la(fb);fd.prototype.add=function(a){throw Error("Can't add to EmptyNodeList");
};var xj="@";na.ht=xj;var vj="*";na.STR_ALL_CHILDREN_SELECTOR=vj;var xp="*";na.STR_WILDCARD=xp;var Kg="/";na.STR_PATH_SEPARATOR=Kg;var wj="[";na.STR_ARRAY_START=wj;var gb=ij("goog.ds");na.logger=gb;yp.makeReferenceNode=function(a,b){var c=function(){};c.prototype=a;var d=new c;d.ya=function(){return b};return d};var Xa=function(){this.Je=new fb;this.bn=new O;this.Ek={};this.di={};this.Tm={};this.iv=0};na.DataManager=Xa;var Gg=null;Xa.Yh=Gg;Xa.la(Wb);var Ya=function(){if(!Gg){Gg=(Xa.Yh=new Xa)}return Gg};Xa.getInstance=Ya;Xa.prototype.St=function(a,b,c){var d=!(!b),e=c||a.ya();if(!ve(e,"$")){e="$"+e}a.ol(e);this.Je.add(a);this.bn.ma(e,d)};Xa.prototype.Yj=function(a){if(this.Tm[a]){return this.Tm[a].$j()}else{return this.Je.ha(a)}};Xa.prototype.ha=function(){return this.Je};Xa.prototype.ma=function(a){throw Error("Can't set on DataManager");
};Xa.prototype.jc=function(a){if(a){return new fb([this.Fb(a)])}else{return this.Je}};Xa.prototype.Fb=function(a){return this.Yj(a)};Xa.prototype.vb=function(a){var b=this.Yj(a);return b?b.ha():null};Xa.prototype.ya=function(){return""};Xa.prototype.Gb=function(){return""};Xa.prototype.lc=function(){var a=this.Je.Ua();for(var b=0;b<a;b++){var c=this.Je.Mh(b),d=this.bn.ha(c.ya());if(d){c.lc()}}};Xa.prototype.Jf=function(a,b,c){var d=0;if(qc(b,"/...")){d=1000;b=b.substring(0,b.length-4)}else if(qc(b,
"/*")){d=1;b=b.substring(0,b.length-2)}c=c||"";var e=b+":"+c+":"+Ab(a),f={dataPath:b,id:c,fn:a},g=yb(b),h=Ab(a);if(!this.di[h]){this.di[h]={}}this.di[h][e]={listener:f,items:[]};while(g){var i={listener:f,maxAncestors:d},k=this.Ek[g.gk()];if(k==null){k={};this.Ek[g.gk()]=k}k[e]=i;d=0;g=g.gg();this.di[h][e].items.push({key:e,obj:k})}};Xa.prototype.Ac=function(a){var b,c=yb(a),d=0;while(c){var e=this.Ek[c.gk()];if(e){for(var f in e){var g=e[f],b=g.listener;if(d<=g.maxAncestors){b.fn(a,b.id)}}}d++;c=
c.gg()}this.iv++};var C=function(a){if(a){this.cr(a)}};na.Expr=C;C.prototype.cr=function(a,b,c,d){this.Cl=a;if(!c&&!d){if(qc(a,tp)){this.uu=true;a=a.substring(0,a.length-1)}if(qc(a,"()")){if(qc(a,sj)||qc(a,rj)||qc(a,tj)){var e=a.lastIndexOf(vp);if(e!=-1){this.Rj=a.substring(e+1);a=a.substring(0,e)}else{this.Rj=a;a=Hg}if(this.Rj==na.wA){this.ax=true}}}}this.le=b||a.split("/");this.qb=this.le.length;this.Ap=this.le[this.qb-1];this.ja=this.le[0];if(this.qb==1){this.il=this;this.sg=ve(a,"$")}else{this.il=Ig(this.ja,null,
this,null);this.sg=this.il.sg;this.ja=this.il.ja}if(this.qb==1&&!this.sg){this.bx=a==Hg||a==up;this.ex=ve(a,sp);this.Yw=a==pj;this.Xw=a==oj;this.Zw=a==qj}};C.prototype.gk=function(){return this.Cl};C.prototype.gg=function(){if(!this.by){if(this.qb>1){this.cy=Ig(null,this.le.slice(0,this.le.length-1),this,null)}this.by=true}return this.cy};C.prototype.Eo=function(){if(!this.Lx){if(this.qb>1){this.Mx=Ig(null,this.le.slice(1),null,this)}this.Lx=true}return this.Mx};C.prototype.$b=function(a){if(a==null){a=
Ya()}else if(this.sg){a=a.getDataRoot?a.getDataRoot():Ya()}if(this.qb==1){return a.vb(this.ja)}else if(this.qb==0){return a.ha()}if(this.ax){var b=this.Lv(a);return b.Ua()}var c=a.Fb(this.ja);if(c==null){return null}else{return this.Eo().$b(c)}};C.prototype.Lv=function(a,b){return this.ak(a,false,b)};C.prototype.$j=function(a,b){return this.ak(a,true,b)};C.prototype.ak=function(a,b,c){if(a==null){a=Ya()}else if(this.sg){a=a.getDataRoot?a.getDataRoot():Ya()}if(this.qb==0&&b){return a}else if(this.qb==
0&&!b){return new fb([a])}else if(this.qb==1){if(b){return a.Fb(this.ja,c)}else{return a.jc(this.ja)}}else{var d=a.Fb(this.ja,c);if(d==null&&b){return null}else if(d==null&&!b){return new fd}return this.Eo().ak(d,b,c)}};C.prototype.uu=false;C.prototype.le=[];C.prototype.qb=null;C.prototype.ja=null;C.prototype.Ap=null;C.prototype.bx=false;C.prototype.ex=false;C.prototype.Yw=false;C.prototype.Xw=false;C.prototype.Zw=false;C.prototype.Rj=null;var yb=function(a){var b=ff[a];if(b==null){b=new C(a);ff[a]=
b}return b};C.create=yb;var Ig=function(a,b,c,d){var e=a||b.join("/"),f=ff[e];if(f==null){f=new C;f.cr(e,b,c,d);ff[e]=f}return f};C.iB=Ig;var ff={};C.ou=ff;var vp="/";C.RA=vp;var Hg=".";C.LA=Hg;var up="";C.MA=up;var sp="@";C.ht=sp;var pj="*|text()";C.HA=pj;var oj="@*";C.GA=oj;var qj="*";C.IA=qj;var sj="name()";C.PA=sj;var rj="count()";C.KA=rj;var tj="position()";C.QA=tj;C.OA="[";C.NA="]";var tp="?";C.JA=tp;C.CURRENT=yb(Hg);C.ALL_CHILD_NODES=yb(pj);C.ALL_ELEMENTS=yb(qj);C.ALL_ATTRIBUTES=yb(oj);C.NAME=
yb(sj);C.COUNT=yb(rj);C.POSITION=yb(tj);m.xml={};m.xml.createDocument=function(a,b){if(b&&!a){throw Error("Can't create document with namespace and no root tag");}if(document.implementation&&document.implementation.createDocument){return document.implementation.createDocument(b||"",a||"",null)}else if(typeof ActiveXObject!="undefined"){var c=new ActiveXObject("MSXML2.DOMDocument");if(c){if(a){c.appendChild(c.createNode(zg,a,b||""))}return c}}throw Error("Your browser does not support creating new documents");};var rp=function(a){if(typeof DOMParser!=
"undefined"){return(new DOMParser).parseFromString(a,"application/xml")}else{var b=new ActiveXObject("MSXML2.DOMDocument");b.loadXML(a);return b}};m.xml.loadXml=rp;m.xml.selectSingleNode=function(a,b){if(typeof a.selectSingleNode!="undefined"){var c=Wa(a);if(typeof c.setProperty!="undefined"){c.setProperty("SelectionLanguage","XPath")}return a.selectSingleNode(b)}else if(document.implementation.hasFeature("XPath","3.0")){var c=Wa(a),d=c.createNSResolver(c.documentElement),e=c.evaluate(b,a,d,XPathResult.FIRST_ORDERED_NODE_TYPE,
null);return e.singleNodeValue}};m.xml.selectNodes=function(a,b){if(typeof a.selectNodes!="undefined"){var c=Wa(a);if(typeof c.setProperty!="undefined"){c.setProperty("SelectionLanguage","XPath")}return a.selectNodes(b)}else if(document.implementation.hasFeature("XPath","3.0")){var c=Wa(a),d=c.createNSResolver(c.documentElement),e=c.evaluate(b,a,d,XPathResult.ORDERED_NODE_SNAPSHOT_TYPE,null),f=[],g=e.snapshotLength;for(var h=0;h<g;h++){f.push(e.snapshotItem(h))}return f}else{return[]}};var pf={};j.net=pf;var od=function(){var a=lq();if(a){return new ActiveXObject(a)}else{return new XMLHttpRequest}};pf.XmlHttp=od;var te={};od.ReadyState=te;var kq=0;te.UNINITIALIZED=kq;te.LOADING=1;var Qj=2;te.LOADED=Qj;te.INTERACTIVE=3;var Yg=4;te.COMPLETE=Yg;var lq=function(){if(!od.fp&&typeof XMLHttpRequest=="undefined"&&typeof ActiveXObject!="undefined"){var a=["MSXML2.XMLHTTP.6.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"];for(var b=0;b<a.length;b++){var c=a[b];try{new ActiveXObject(c);
return od.fp=c}catch(d){}}throw Error("Could not create ActiveXObject. ActiveX might be disabled, or MSXML might not be installed");}return od.fp};od.XB=lq;var Ha=function(a,b,c){this.$=b;this.bb=c||(a?a.nodeName:null);this.lz(a)};na.XmlDataSource=Ha;var zp="@*";Ha.uA=zp;Ha.prototype.lz=function(a){this.oc=a;if(a!=null){switch(a.nodeType){case Xs:case Ed:this.vf=a.nodeValue;break;case zg:if(a.childNodes.length==1&&a.firstChild.nodeType==Ed){this.vf=a.firstChild.nodeValue}}}};Ha.prototype.Fe=function(){if(this.Ta){return}var a=new fb;if(this.oc!=null){var b=this.oc.childNodes;for(var c=0,d;d=b[c];c++){if(d.nodeType!=Ed||!Ap(d.nodeValue)){var e=new Ha(d,
this,d.nodeName);a.add(e)}}}this.Ta=a};Ha.prototype.Lu=function(){if(this.an){return}var a=new fb;if(this.oc!=null&&this.oc.attributes!=null){var b=this.oc.attributes;for(var c=0,d;d=b[c];c++){var e=new Ha(d,this,d.nodeName);a.add(e)}}this.an=a};Ha.prototype.ha=function(){this.Fe();return this.vf!=null?this.vf:this.Ta};Ha.prototype.ma=function(a){throw Error("Can't set on XmlDataSource yet");};Ha.prototype.jc=function(a){if(a&&a==zp){this.Lu();return this.an}else if(a==null||a==vj){this.Fe();return this.Ta}else{throw new Error("Unsupported selector");
}};Ha.prototype.Fb=function(a){if(ve(a,xj)){var b=this.oc.getAttributeNode(a.substring(1));return b?new Ha(b,this):null}else{return this.jc().ha(a)}};Ha.prototype.vb=function(a){if(ve(a,xj)){var b=this.oc.getAttributeNode(a.substring(1));return b?b.nodeValue:null}else{var b=this.Fb(a);return b?b.ha():null}};Ha.prototype.ya=function(){return this.bb};Ha.prototype.ol=function(a){this.bb=a};Ha.prototype.Gb=function(){var a="";if(this.$){a=this.$.Gb()+(this.bb.indexOf(wj)!=-1?"":Kg)}return a+this.bb};
Ha.prototype.lc=function(){};var Ap=function(a){return/^[\r\n\t ]*$/.test(a)};Ha.jC=Ap;var Lg=function(){return m.xml.createDocument("nothing")};Ha.hB=Lg;var Id=function(a,b){Ha.call(this,null,null,b);if(a){this.Ka=new w(a)}else{this.Ka=null}};na.XmlHttpDataSource=Id;Id.la(Ha);Id.prototype.Pb=hf;Id.prototype.lc=function(){if(this.Ka){gb.wb("Sending XML request for DataSource "+this.ya()+" to "+this.Ka);this.Pb=wp;this.sx=new hd(this.Ka,ba(this.Fl,this),ba(this.mv,this))}else{this.oc=Lg();this.Pb=
hf}};Id.prototype.Fl=function(){gb.wb("Got data for DataSource "+this.ya());var a=this.sx.Vv(),b=a.responseXML;if(b&&!b.hasChildNodes()&&ib(a.responseText)){b=rp(a.responseText)}if(!b||!b.hasChildNodes()){this.Pb=Jg;this.oc=Lg()}else{this.Pb=uj;this.oc=b.documentElement}if(this.ya()){Ya().Ac(this.ya())}};Id.prototype.mv=function(){gb.wb("Data retrieve failed for DataSource "+this.ya());this.Pb=Jg;this.oc=Lg();if(this.ya()){Ya().Ac(this.ya())}};var hd=function(a,b,c){this.oe=null;this.Vx=b;this.aq=
c||this.jw;this.Ka=new w(a);this.qx()};na.WA=hd;hd.prototype.qx=function(){this.oe=new od;if(this.oe){try{this.oe.onreadystatechange=ba(this.Qk,this);this.oe.open("GET",String(this.Ka),true);this.oe.send(null)}catch(a){this.aq.call(this)}}};hd.prototype.Qk=function(){var a=this.oe,b=a.readyState;if(b==Yg){var c=a.status,d;if(c==200||c==0){d=ba(this.Pk,this)}else{d=ba(this.Mk,this)}window.setTimeout(d,10)}};hd.prototype.Pk=function(){this.Vx(this)};hd.prototype.Mk=function(){this.aq(this)};hd.prototype.jw=
function(){throw Error("Error fetching data from URL: "+this.Ka);};hd.prototype.Vv=function(){return this.oe};var nd={COMPLETE:"complete",SUCCESS:"success",ERROR:"error",ABORT:"abort",READY:"ready",READY_STATE_CHANGE:"readystatechange",TIMEOUT:"timeout"},ct=nd.ABORT,qf=nd.COMPLETE,iq=nd.ERROR,jq=nd.READY,dt=nd.READY_STATE_CHANGE,et=nd.SUCCESS,ft=nd.TIMEOUT;pf.EventType=nd;var vc=function(){};j.Disposable=vc;vc.prototype.Jj=false;vc.prototype.Yb=function(){return this.Jj};var Si=function(){if(!this.Jj){this.Jj=true}};vc.prototype.qa=Si;j.qa=function(a){if(typeof a.qa=="function"){a.qa()}};var ca={};j.events=ca;var Yb={};ca.Fc=Yb;var Gb={};ca.zC=Gb;var t=function(a,b,c,d,e){if(Ta(b)){for(var f=0;f<b.length;f++){t(a,b[f],c,d,e)}return null}var g=jd(b),h=pe(a,g,c,d,e);if(h in Yb){return h}var i=Ab(a);if(!(i in Gb)){Gb[i]={}}if(!(g in Gb[i])){Gb[i][g]=[]}Gb[i][g].push(h);var k=Fp.p(a,h,b),n=new Aj(c,k,a,b,d,e);Yb[h]=n;if(b instanceof oe){b.bu(n)}else{if(a.addEventListener){if(a==j.global||!a.Cn){a.addEventListener(b,k,d)}}else if(a.attachEvent){a.attachEvent("on"+b,k)}else{throw Error("Object {"+
a+"} does not support event listeners.");}}return h};ca.Ec=t;var $=function(a,b,c,d,e){if(Ta(b)){for(var f=0;f<b.length;f++){$(a,b[f],c,d,e)}return null}var g=pe(a,b,c,d,e);return Mb(g)};ca.Br=$;var Mb=function(a){if(!(a in Yb)){return false}var b=Yb[a],c=b.src,d=b.type,e=b.proxy;if(d instanceof oe){d.Cy(b)}else{if(c.removeEventListener){if(c==j.global||!c.Cn){c.removeEventListener(d,e,b.capture)}}else if(c.detachEvent){c.detachEvent("on"+d,e)}}delete Yb[a];var f=jd(d);x.remove(Gb[Ab(c)][f],a);return true};
ca.unlistenByKey=Mb;var Cj=function(a,b,c){var d=0;if(a){var e=Dp(a,b,c);for(var f=0;f<e.length;f++){var g=e[f];if(g){Mb(pe(g.src,g.type,g.listener,g.capture,g.handler));d++}}}else{for(var h in Yb){Mb(h);d++}}return d};ca.Eq=Cj;var Dp=function(a,b,c){var d=Ab(a),e=[];if(d in Gb){var f=Gb[d];if(b){var g=jd(b);if(b in f){Bj(e,f[g],c)}}else{for(var h in f){Bj(e,f[h],c)}}}return e};ca.PB=Dp;var jd=function(a){return a instanceof oe?Ab(a):a};ca.dC=jd;var Bj=function(a,b,c){var d=!Y(c);for(var e=0;e<b.length;e++){var f=
b[e],g=Yb[f];if(d||g.capture==c){a.push(g)}}};ca.OB=Bj;var Ep=function(a,b,c){var d=Ab(a),e=[];if(d in Gb){var f=Gb[d],g=jd(b);if(g in f){var h=f[g];for(var i=0;i<h.length;i++){var k=Yb[h[i]];if(k.capture==c){e.push(k)}}}}return e};ca.getListeners=Ep;ca.hasListener=function(a,b,c){var d=Ab(a);if(d in Gb){var e=Gb[d],f=jd(b);if(f in e){var g=e[f];for(var h=0;h<g.length;h++){var i=Yb[g[h]];if(i.capture==c){return true}}}}return false};ca.expose=function(a){var b=[];for(var c in a){if(a[c]&&a[c].id){b.push(c+
" = "+a[c]+" ("+a[c].id+")")}else{b.push(c+" = "+a[c])}}return b.join("\n")};var hb={CLICK:"click",DBLCLICK:"dblclick",MOUSEDOWN:"mousedown",MOUSEUP:"mouseup",MOUSEOVER:"mouseover",MOUSEOUT:"mouseout",MOUSEMOVE:"mousemove",KEYPRESS:"keypress",KEYDOWN:"keydown",KEYUP:"keyup",BLUR:"blur",FOCUS:"focus",FOCUSIN:document.all?"focusin":"DOMFocusIn",FOCUSOUT:document.all?"focusout":"DOMFocusOut",CHANGE:"change",SELECT:"select",SUBMIT:"submit",LOAD:"load",UNLOAD:"unload",HELP:"help",RESIZE:"resize",SCROLL:"scroll",
READYSTATECHANGE:"readystatechange"},Kd=hb.BLUR,yj=hb.CHANGE,rb=hb.CLICK,Ys=hb.DBLCLICK,je=hb.FOCUS,Zs=hb.FOCUSIN,ke=hb.KEYDOWN,le=hb.KEYPRESS,Ng=hb.KEYUP,Xb=hb.MOUSEDOWN,me=hb.MOUSEMOVE,id=hb.MOUSEOUT,Ld=hb.MOUSEOVER,ne=hb.MOUSEUP,Cp=hb.RESIZE,$s=hb.UNLOAD;ca.EventType=hb;var Fp=function(a,b){var c=x.slice(arguments,2),d=Yb[a];if(!d){return undefined}if(!d.src.addEventListener&&!Hp(d)){return undefined}if(c.length==0&&window.event||c.length==1&&Ip(c[0])){var e=c[0]||window.event,f=new Jd(e,this);
try{f.stopPropagation();f.me=false;var g=[];for(var h=f.currentTarget;h;h=h.parentNode){g.push(h)}var i=true;for(var k=g.length-1;!f.me&&k>=0;k--){f.currentTarget=g[k];i&=jf(g[k],b,true,[f])}for(var k=0;!f.me&&k<g.length;k++){f.currentTarget=g[k];i&=jf(g[k],b,false,[f])}return i}finally{f.qa()}}else if(c.length==1&&Gp(c[0])){var n=c[0]=new Jd(c[0],this);try{return Og(d,c)}finally{n.qa()}}else{return Og(d,c)}};ca.lw=Fp;var Hp=function(a){var b=jd(a.type),c=pe(a.src,a.type,a.listener,a.capture,a.handler),
d=Ab(a.src);return Gb[d][b][0]==c};ca.kC=Hp;var jf=function(a,b,c,d){var e=Ep(a,b,c),f=1;for(var g=0;g<e.length;g++){f&=Og(e[g],d)!==false}return Boolean(f)};ca.fireListeners=jf;var Og=function(a,b){return a.$d.apply(a,b)};ca.uB=Og;var pe=function(a,b,c,d,e){return Ab(a)+"_"+jd(b)+"_"+Ab(c)+"_"+Boolean(d)+"_"+(e?Ab(e):"")};ca.createKey=pe;var Gp=function(a){return ib(a)&&/event/i.test(a)};ca.iC=Gp;var Ip=function(a){return j.userAgent.IE&&ib(a)&&Y(a.srcElement)&&Y(a.cancelBubble)&&Y(a.type)};ca.lC=
Ip;ca.getTotalListenerCount=function(){return Uj(Yb)};var oe=function(){};ca.EventWrapper=oe;oe.prototype.bu=function(a){throw Error("Not implemented");};oe.prototype.Cy=function(a){throw Error("Not implemented");};var zb=function(a,b){this.type=a;this.target=b;this.currentTarget=this.target};ca.Event=zb;zb.la(vc);zb.prototype.me=false;zb.prototype.ni=true;zb.prototype.stopPropagation=function(){this.me=true};zb.prototype.preventDefault=function(){this.ni=false};var Jd=function(a,b){this.type=a.type;this.timestamp=new Date;this.target=a.target||a.srcElement;this.currentTarget=b;this.relatedTarget=null;if(Y(a.relatedTarget)){this.relatedTarget=a.relatedTarget}else if(this.type==Ld){this.relatedTarget=a.fromElement}else if(this.type==id){this.relatedTarget=a.toElement}this.offsetX=Y(a.layerX)?a.layerX:a.offsetX;this.offsetY=Y(a.layerY)?a.layerY:a.offsetY;this.clientX=Y(a.clientX)?a.clientX:a.pageX;this.clientY=Y(a.clientY)?a.clientY:a.pageY;this.screenX=a.screenX||
0;this.screenY=a.screenY||0;this.button=a.button;this.keyCode=a.keyCode||0;this.charCode=a.charCode||(this.type==le?a.keyCode:0);this.ctrlKey=a.ctrlKey;this.altKey=a.altKey;this.shiftKey=a.shiftKey;this.Td=a};ca.BrowserEvent=Jd;Jd.la(zb);Jd.prototype.stopPropagation=function(){this.me=true;if(this.Td.stopPropagation){this.Td.stopPropagation()}else{this.Td.cancelBubble=true}};Jd.prototype.preventDefault=function(){this.ni=false;if(!this.Td.preventDefault){this.Td.returnValue=false}else{this.Td.preventDefault()}};
Jd.prototype.qa=function(){if(!this.Yb()){zb.prototype.qa.call(this);this.Td=null}};var Aj=function(a,b,c,d,e,f){if(ld(a)){this.np=true}else if(a&&typeof a.$d=="function"){this.np=false}else{throw Error("Invalid listener argument");}this.listener=a;this.proxy=b;this.src=c;this.type=d;this.capture=!(!e);this.handler=f};ca.Listener=Aj;Aj.prototype.$d=function(){if(this.np){return this.listener.apply(this.handler||this.src,arguments)}return this.listener.$d.apply(this.listener,arguments)};var Sa=function(){};ca.EventTarget=Sa;Sa.la(vc);Sa.prototype.Go=function(){return null};Sa.prototype.addEventListener=function(a,b,c,d){t(this,a,b,c,d)};Sa.prototype.removeEventListener=function(a,b,c,d){$(this,a,b,c,d)};Sa.prototype.dispatchEvent=function(a){if(la(a)){a=new zb(a,this)}else if(!(a instanceof zb)){var b=a;a=new zb(a.type,this);Xg(a,b)}else{a.target=a.target||this}var c=[];for(var d=this;d;d=d.Go()){c.push(d)}var e=1;for(var f=c.length-1;!a.me&&f>=0;f--){a.currentTarget=c[f];e&=jf(c[f],
a.type,true,[a])&&a.ni!=false}for(var f=0;!a.me&&f<c.length;f++){a.currentTarget=c[f];e&=jf(c[f],a.type,false,[a])&&a.ni!=false}return Boolean(e)};var Mg=function(){if(!this.Yb()){Si.call(this);Cj(this)}};Sa.prototype.qa=Mg;Sa.prototype.Cn=true;var ac={};j.json=ac;var cq=function(a){if(a==""){return false}a=a.replace(/"(\\.|[^"\\])*"/g,"");return a==""||!/[^,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]/.test(a)};ac.oC=cq;ac.parse=function(a){a=String(a);if(typeof a.parseJSON=="function"){return a.parseJSON()}if(cq(a)){try{return eval("("+a+")")}catch(b){}}throw Error("Invalid JSON string: "+a);};ac.unsafeParse=function(a){return eval("("+a+")")};ac.serialize=function(a){if(a!=null&&typeof a.toJSONString=="function"){return a.toJSONString()}var b=[];
Vg(a,b);return b.join("")};var Vg=function(a,b){switch(typeof a){case "string":Oj(a,b);break;case "number":eq(a,b);break;case "boolean":b.push(a);break;case "undefined":b.push("null");break;case "object":if(a==null){b.push("null");break}if(Ta(a)){dq(a,b);break}fq(a,b);break;default:throw Error("Unknown type: "+typeof a);}};ac.$C=Vg;var Ug={'"':'\\"',"\\":"\\\\","/":"\\/","\u0008":"\\b","\u000c":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\u000b":"\\u000b"};ac.eB=Ug;var Oj=function(a,b){b.push('"',a.replace(/[\\\"\x00-\x1f\x80-\uffff]/g,
function(c){if(c in Ug){return Ug[c]}var d=c.charCodeAt(0),e="\\u";if(d<16){e+="000"}else if(d<256){e+="00"}else if(d<4096){e+="0"}return Ug[c]=e+d.toString(16)}),'"')};ac.ZC=Oj;var eq=function(a,b){b.push(isFinite(a)&&!isNaN(a)?a:"null")};ac.XC=eq;var dq=function(a,b){var c=a.length;b.push("[");var d="";for(var e=0;e<c;e++){b.push(d);Vg(a[e],b);d=","}b.push("]")};ac.WC=dq;var fq=function(a,b){b.push("{");var c="";for(var d in a){b.push(c);Oj(d,b);b.push(":");Vg(a[d],b);c=","}b.push("}")};ac.YC=fq;var N=function(){Sa.call(this);this.headers=new O;this.Fk=ij("goog.net.XhrLite");this.headers.ma("Content-type","application/x-www-form-urlencoded")};pf.XhrLite=N;N.la(Sa);N.send=function(a,b,c,d,e){var f=new N;if(b){t(f,qf,b)}t(f,jq,f.qa,false,f);f.send(a,c,d,e)};N.prototype.Uc=false;N.prototype.ra=null;N.prototype.zp="";N.prototype.wp="";N.prototype.Dk="";N.prototype.Ki=0;N.prototype.Bb=null;N.prototype.send=function(a,b,c,d){if(this.Uc){throw Error("[goog.net.XhrLite] Object is active with another request");
}var e=b||"GET";this.zp=a;this.Dk="";this.wp=e;this.Uc=true;this.ra=new od;this.ra.onreadystatechange=this.Qk.p(this);try{this.$c("Opening Xhr");this.ra.open(e,a,true)}catch(f){this.$c("Error opening Xhr: "+f.message);this.Un(f);return}var g=c?String(c):"";if(e=="POST"){this.ra.setRequestHeader("Content-Length",g.length)}var h=this.headers.Ca();if(d){pd(d,function(i,k){h.ma(k,i)})}pd(h,function(i,k){this.ra.setRequestHeader(k,i)},this);try{if(this.Bb){j.global.clearTimeout(this.Bb);this.Bb=null}if(this.Ki>
0){this.$c("Will abort after "+this.Ki+"ms if incomplete");this.Bb=j.global.setTimeout(ba(this.Hl,this),this.Ki)}this.$c("Sending request");this.ra.send(g)}catch(f){this.$c("Send error: "+f.message);this.Un(f)}};N.prototype.Hl=function(){if(typeof j=="undefined"){}else if(this.ra){this.$c("Timed out after "+this.Ki+"ms, aborting");this.dispatchEvent(ft);this.abort()}};N.prototype.Un=function(a){this.ra.abort();this.Uc=false;this.Dk=a;this.dispatchEvent(qf);this.dispatchEvent(iq);this.wj()};N.prototype.abort=
function(){if(this.ra){this.$c("Aborting");this.ra.abort();this.Uc=false;this.dispatchEvent(ct);this.wj()}};N.prototype.qa=function(){if(!this.Yb()){this.abort();N.tc.qa.call(this)}};N.prototype.Qk=function(){if(typeof j=="undefined"){}else if(j.userAgent.IE&&this.Qh()==Yg&&this.Sh()==2){this.$c("Local request error detected and ignored")}else{this.dispatchEvent(dt);if(this.Ye()){this.$c("Request complete");this.Uc=false;if(this.tg()){this.dispatchEvent(qf);this.dispatchEvent(et)}else{this.Dk=this.Zv()+
" ["+this.Sh()+"]";this.dispatchEvent(qf);this.dispatchEvent(iq)}this.wj()}}};N.prototype.wj=function(){if(this.ra){this.ra.onreadystatechange=j.userAgent.IE?mq:null;this.ra=null;if(this.Bb){j.global.clearTimeout(this.Bb);this.Bb=null}this.dispatchEvent(jq)}};N.prototype.mp=function(){return this.Uc};N.prototype.Ye=function(){return this.Qh()==Yg};N.prototype.tg=function(){switch(this.Sh()){case 0:case 200:case 304:return true;default:return false}};N.prototype.Qh=function(){return this.ra?this.ra.readyState:
kq};N.prototype.Sh=function(){try{return this.Qh()>Qj?this.ra.status:-1}catch(a){this.Fk.Ql("Can not get status: "+a.message);return-1}};N.prototype.Zv=function(){try{return this.Qh()>Qj?this.ra.statusText:""}catch(a){this.Fk.bo("Can not get status: "+a.message);return""}};N.prototype.hg=function(){return this.ra?this.ra.responseText:""};N.prototype.Io=function(){return this.ra?this.ra.responseXML:null};N.prototype.dk=function(){return this.ra?ac.parse(this.ra.responseText):undefined};N.prototype.getResponseHeader=
function(a){return this.ra&&this.Ye()?this.ra.getResponseHeader(a):undefined};N.prototype.$c=function(a){this.Fk.bo(a+" ["+this.wp+" "+this.zp+" "+this.Sh()+"]")};var Ga=function(a,b,c){this.$=c;this.bb=b;this.ul(a)};na.JsDataSource=Ga;Ga.prototype.ul=function(a){this.ja=a;this.Ta=null};Ga.prototype.ha=function(){return!ib(this.ja)?this.ja:this.jc()};Ga.prototype.ma=function(a){if(a&&ib(this.ja)){throw Error("Can't set group nodes to new values yet");}if(this.$){this.$.ja[this.bb]=a}this.ja=a;this.Ta=null;Ya().Ac(this.Gb())};Ga.prototype.jc=function(a){if(!this.ja){return new fd}if(!a||a==vj){this.Fe(false);return this.Ta}else if(a.indexOf(xp)==-1){if(this.ja[a]!=
null){return new fb([this.Fb(a)])}else{return new fd}}else{throw new Error("Selector not supported yet ("+a+")");}};Ga.prototype.Fe=function(a){if(this.Ta&&!a){return}if(!ib(this.ja)){this.Ta=new fd;return}var b=new fb;if(this.ja!=null){var c;if(Ta(this.ja)){for(var d=0;d<this.ja.length;d++){var e=this.ja[d].id,f=e!=null?String(e):"["+d+"]";c=new Ga(this.ja[d],f,this);b.add(c)}}else{for(var f in this.ja){var g=this.ja[f];if(g.ya){b.add(g)}else if(!ld(g)){c=new Ga(g,f,this);b.add(c)}}}}this.Ta=b};
Ga.prototype.Fb=function(a,b){if(!this.ja){return null}var c=this.jc().ha(a);if(!c&&b){var d={};if(Ta(this.ja)){d["id"]=a;this.ja.push(d)}else{this.ja[a]=d}c=new Ga(d,a,this);if(this.Ta){this.Ta.add(c)}}return c};Ga.prototype.vb=function(a){if(this.Ta){var b=this.jc().ha(a);return b?b.ha():null}else if(this.ja){return this.ja[a]}else{return null}};Ga.prototype.Xq=function(a,b){var c=null,d=null,e=false;if(b!=null){if(b.ya){d=b;d.$=this}else{if(Ta(b)||ib(b)){d=new Ga(b,a,this)}else{d=new Hd(this.ja,
a,this)}}}if(Ta(this.ja)){this.Fe();var f=this.Ta.indexOf(a);if(b==null){var g=this.Ta.ha(a);if(g){c=g.Gb()}this.ja.splice(f,1)}else{if(f){this.ja[f]=b}else{this.ja.push(b)}}if(f==null){e=true}this.Ta.sl(a,d)}else if(ib(this.ja)){if(b==null){this.Fe();var g=this.Ta.ha(a);if(g){c=g.Gb()}delete this.ja[a]}else{if(!this.ja[a]){e=true}this.ja[a]=b}if(this.Ta){this.Ta.sl(a,d)}}var h=Ya();if(d){h.Ac(d.Gb());if(e){h.Ac(this.Gb())}}else if(c){h.Ac(c);h.Ac(this.Gb())}return d};Ga.prototype.ya=function(){return this.bb};
Ga.prototype.ol=function(a){this.bb=a};Ga.prototype.Gb=function(){var a="";if(this.$){a=this.$.Gb()+Kg}return a+this.bb};Ga.prototype.lc=function(){};var Hd=function(a,b,c){wc.call(this);this.bb=b;this.$=a;this.ay=c||this.$};na.JsPropertyDataSource=Hd;Hd.la(wc);Hd.prototype.ha=function(){return this.$[this.bb]};Hd.prototype.ma=function(a){var b=this.$[this.bb];this.$[this.bb]=a;if(b!=a){Ya().Ac(this.Gb())}};Hd.prototype.ya=function(){return this.bb};Hd.prototype.Ph=function(){return this.ay};var Nc=
function(a,b){Ga.call(this,null,b,null);if(a){this.Ka=new w(a)}else{this.Ka=null}};na.JsonDataSource=Nc;Nc.la(Ga);Nc.prototype.Pb=hf;Nc["dataSources"]={};Nc.prototype.lc=function(){if(this.Ka){Nc.dataSources[this.bb]=this;gb.wb("Sending JS request for DataSource "+this.ya()+" to "+this.Ka);this.Pb=wp;var a=new w(this.Ka);a.nz("callback","JsonReceive."+this.bb);j.global["JsonReceive"][this.bb]=ba(this.vy,this);var b=m.createElement("script");b.src=a;b.onload=ba(this.Pk,this);b.onreadystatechange=ba(this.Yx,
this);$o("head")[0].appendChild(b)}else{this.ja={};this.Pb=hf}};Nc.prototype.Yx=function(a){};Nc.prototype.Pk=function(a){};Nc.prototype.vy=function(a){this.ul(a);this.Pb=uj;Ya().Ac(this.ya())};j.global["JsonReceive"]={};var gd=function(a,b,c,d){Ga.call(this,null,b,null);if(a){this.Ka=new w(a);this.ra=new N;t(this.ra,qf,this.Eu,false,this)}else{this.Ka=null}this.Gi=c;this.Qj=d};na.JsXmlHttpDataSource=gd;gd.la(Ga);gd.prototype.Gi=null;gd.prototype.Qj=null;gd.prototype.lc=function(){gb.wb("Sending JS request for DataSource "+this.ya()+" to "+this.Ka);if(this.Ka){this.ra.send(this.Ka)}else{this.ja={};this.Pb=hf}};gd.prototype.Fl=function(){Ya().Ac(this.ya())};gd.prototype.Eu=function(a){if(this.ra.tg()){gb.wb("Got data for DataSource "+
this.ya());var b=this.ra.hg();if(this.Gi){var c=b.indexOf(this.Gi);b=b.substring(c+this.Gi.length)}if(this.Qj){var d=b.lastIndexOf(this.Qj);b=b.substring(0,d)}try{var e=eval("["+b+"][0]");this.ul(e);this.Pb=uj}catch(f){this.Pb=Jg;gb.er("Failed to parse data: "+f.message)}j.global.setTimeout(ba(this.Fl,this),0)}else{gb.wb("Data retrieve failed for DataSource "+this.ya());this.Pb=Jg}};j.focus={};var ya=function(){this.en="..";this.fl={};this.Sl={};this.wf={};this.pg={};this.Ew={};this.Rl={}};j.focus.Ui=ya;var sb=function(){if(!Rg){Rg=(ya.Yh=new ya)}return Rg};ya.ha=sb;var Rg=null;ya.Yh=Rg;ya.prototype.ar=function(a,b,c){a=new w(a);if(b&&c){if(!this.wf[b]){this.wf[b]={}}this.wf[b][c]=a}else if(b){this.Sl[b]=a}else if(c){this.fl[c]=a}else{this.en=a}};ya.prototype.fk=function(a,b){if(this.wf[a]&&this.wf[a][b]){return this.wf[a][b]}else if(this.Sl[a]){return this.Sl[a]}else if(this.fl[b]){return this.fl[b]}else{return this.en}};
ya.prototype.Cq=function(a){this.pg[a.Re()]=a};ya.prototype.$m=function(a,b,c){var d=this.pg[a];if(d&&d.Mf){d.Mf(b,c);return true}var e=this.Ew[a];if(e&&e.Mf){e.Mf(b,c);return true}return false};ya.prototype.Sd=function(a,b,c){var d=this.pg[a];if(d&&d.Sd){d.Sd(b,c);return true}return false};ya.prototype.Xf=function(a,b,c){var d=this.pg[a];if(d&&d.Xf){d.Xf(b,c);return true}return false};ya.tA=0;ya.prototype.Mu=function(a,b,c,d){var e=this.Nu(a,b),f=new Cc.Dialog;f.getContentElement().appendChild(e);
f.setButtonSet(new Cc.Dialog.ButtonSet);f.Rb(true);e.src=this.Ou(a,c,d);this.Rl[a]=f};ya.prototype.Nu=function(a,b){var c=a+"-iframe",d=dd(c);if(!d){d=Vb("iframe",{id:c});gh(d,"display","block");gh(d,"backgroundColor","#FFF");gh(d,"border","2px outset black");ye(d,b.width,b.height)}return d};ya.prototype.Ou=function(a,b,c){var d=new w(this.fk()+"/ui/"+a);if(c){var e="UiWidgetCallback"+j.focus.Ui.tA++;j.global[e]=c;d.$a("done",e)}d.$a("js","RAW");d.$a("pop","TRUE");if(b){pd(b,function(f,g){d.$a(g,
f)})}return d};ya.prototype.fv=function(a){var b=this.Rl[a];if(b){b.qa()}delete this.Rl[a]};ya.prototype.Yy=function(a,b){var c=this.pg[a],d=dd(c.Re()+"-iframe");if(d&&d.contentWindow["UI_receive"]){d.contentWindow["UI_receive"](b)}};ya.prototype.Xm=function(a){var b=a||document;for(var c=b.firstChild;c;c=c.nextSibling){this.Xm(c)}if(b.getAttribute){var d=b.getAttribute("gtype");if(d){var e={};for(var f=0;f<b.attributes.length;f++){var g=b.attributes[f];e[g.name]=g.value}var h=this.$m(d,b,e);if(!h){this.Sd(d,
b,e)}}}};ya.Qn=0;ya.prototype.Jn=function(a,b,c,d,e){var f=e||document,g=f.createElement("div");g.style.position="absolute";g.style.zIndex=40;g.id="UiWidget"+j.focus.Ui.Qn++;f.body.appendChild(g);xe(g,b.x,b.y);if(c){ye(g,c.width,c.height)}this.Sd(a,g,d);return g.id};ya.prototype.Jn=function(a,b,c,d,e){var f=e||document,g=f.createElement("div");g.style.position="absolute";g.style.zIndex=40;g.id="UiWidget"+j.focus.Ui.Qn++;f.body.appendChild(g);xe(g,b.x,b.y);if(c){ye(g,c.width,c.height)}this.Sd(a,g,
d);return g.id};ya.prototype.ev=function(a,b){var c=b||document,d=c.getElementById(a);if(d){d.parentNode.removeChild(d)}};window["UI_setServerBase"]=function(a,b,c){sb().ar(a,b,c)};window["UI_getServerBase"]=function(a,b){sb().fk(a,b)};window["UI_attachAndDisplayAllWidgets"]=function(a){sb().Xm(a)};window["UI_attachWidget"]=function(a,b,c){sb().$m(a,b,c)};window["UI_displayInline"]=function(a,b,c){sb().Sd(a,b,c)};window["UI_displayIframe"]=function(a,b){sb().Xf(a,b)};var se={};j.focus.UiUtil=se;var kd=function(a){this.ia=a;t(a,["input","propertychange"],this.qw,false,this);t(a,le,this.nw,false,this);t(a,ke,this.mw,false,this);var b=[je,rb,Kd];t(a,b,this.ow,false,this)};j.focus.InputEventHandler=kd;kd.Np(Sa.prototype);var Od={};kd.Event=Od;var Qp="DOWN_ARROW";Od.DOWN_ARROW=Qp;var Up="UP_ARROW";Od.UP_ARROW=Up;var Rp="ENTER";Od.ENTER=Rp;var Sp="ESCAPE";Od.ESCAPE=Sp;var Vp="VALUE";Od.VALUE=Vp;var Tp="STABLE_VALUE";Od.STABLE_VALUE=Tp;var Wp=[40,38,9,13,12];kd.sC=Wp;
kd.prototype.nw=function(a){if(x.contains(Wp,a.keyCode)){a.preventDefault()}else if(!this.dispatchEvent(a)){a.preventDefault()}};kd.prototype.mw=function(a){var b=a.keyCode,c=null;if(b==40){c=Qp}else if(b==38){c=Up}else if(b==13){c=Rp}else if(b==40){c=Sp}if(c){var d=this.dispatchEvent(c);if(!d){a.preventDefault()}}};kd.prototype.ow=function(a){this.dispatchEvent(a)};kd.prototype.qw=function(a){var b=new zb(Vp);b.value=this.ia.value;this.dispatchEvent(b);var c=new zb(Tp);c.value=this.ia.value;this.dispatchEvent(c)};
se.constrainImage=function(a,b){if(a){a.style.display="block";var c=a.width;if(c>b){a.style.width=b+"px"}}};var Sg=function(a,b,c,d){var e=a.split("."),f=d||j.global,g=f,h=e.length;for(var i=0;i<h-1;i++){g=g[e[i]]}g[e[h-1]]=b;if(c){f[c]=b}};se.exportName=Sg;var Pg=function(a){this.Cc=a;this.Vp=-1};j.focus.Panel=Pg;Pg.prototype.hd=function(a,b){this.Vp=a;this.rk();if(!b){this.jf()}};Pg.prototype.rk=function(){if(!this.ud){j.global.setTimeout(ba(this.jf,this),0)}this.ud=true};Pg.prototype.jf=function(a){if(this.ud){for(var b=
0;b<this.Cc.length;b++){var c=this.Cc[b],d=dd(c);if(this.Vp==c){this.pD=c;d.style.display="block"}else{d.style.display="none"}}this.ud=false}};var aq=function(a,b){if(a.value==""||a.value==b){a.defaulted=true;a.value=b;I.add(a,"input-default")}t(a,je,function(){if(a.defaulted){a.value="";I.remove(a,"input-default");a.defaulted=false}});t(a,Kd,function(){if(a.value==""&&!a.defaulted){a.defaulted=true;a.value=b;I.add(a,"input-default")}});t(a,Ng,function(c){if(c.keyCode==27){a.value=""}})};se.setDefaultText=
aq;se.decorate=function(){var a=document.getElementsByTagName("*"),b=x.filter(a,function(f){return f.getAttribute("gtype")!=null});for(var c=0;c<b.length;c++){var d=b[c],e=d.getAttribute("gtype");if(e=="input"){new Pp(d)}else if(e=="button"){new Md(d)}}};se.decorateElement=function(a){if(la(a)){a=dd(a)}if(a){var b=a.nodeName,c={};for(var d=0;d<a.attributes.length;d++){var e=a.attributes[d];c[e.nodeName]=e.nodeValue}if(b=="BUTTON"){var f=new j.focus.ButtonFactory;f.decorate(a,c)}}};var Pp=function(a,
b,c){if(a){this.td=a;this.ip=b||a.getAttribute("icon");if(this.ip){this.e=Vb("div",{className:this.td.className});this.td.className="";this.ca=m.createElement("img");this.ca.src=this.ip;this.ca.style.verticalAlign="bottom";this.e.appendChild(this.ca);var d=bb(this.td);a.parentNode.replaceChild(this.e,a);var e=bb(this.ca).width,f=e?e:16;d.width=bb(this.e).width-f-20;this.e.appendChild(a);this.td.style.width=d.width+"px";this.td.style.border="0px";this.td.style.padding="0px";this.td.style.paddingLeft=
"4px";this.e.style.verticalAlign="top"}this.Ke=c||a.getAttribute("defaultText");if(this.Ke){aq(this.td,this.Ke)}}};j.focus.InputDecorator=Pp;var Md=function(a,b){this.ia=a;if(a==null){return}this.Ch=b?j.focus.BooleanExpr.create(b):null;if(this.Ch){var c=ba(this.rr,this);pd(this.Ch.getDataDeps(),function(h){Ya().Jf(c,h.Cl)});this.rr()}if(j.userAgent.IE){var d=bb(a);a.style.width=String(d.width*0.77)+"px";var e=Number(a.currentStyle.paddingTop.split("px")[0]),f=Number(a.currentStyle.paddingBottom.split("px")[0]);
a.style.paddingTop=String(e+2)+"px";var g=f>=2?f-2:0;a.style.paddingBottom=String(g)+"px"}t(a,Xb,ba(this.qy,this));t(a,ne,ba(this.wq,this));t(a,id,ba(this.Bx,this));t(a,Ld,ba(this.jA,this));t(a,rb,ba(this.wq,this))};j.focus.ButtonDecorator=Md;Md.prototype.qy=function(a){I.add(a.target,"presubmit");a.target.vq=true};Md.prototype.wq=function(a){I.remove(a.target,"presubmit");a.target.vq=false};Md.prototype.Bx=function(a){I.remove(a.target,"presubmit")};Md.prototype.jA=function(a){if(a.target.vq){I.add(a.target,
"presubmit")}};Md.prototype.rr=function(){if(this.Ch){this.ia.disabled=!this.Ch.$b()}};var Tg=function(a,b){this.nc=a;this.Ej=b||"$LastMessage";this.Fx=yb(this.Ej+"/Message");this.iA=yb(this.Ej+"/Level");Ya().Jf(ba(this.rk,this),this.Ej+"/...");this.ud=false};j.focus.UserMessageBox=Tg;Tg.prototype.rk=function(){if(!this.ud){j.global.setTimeout(ba(this.jf,this),0)}this.ud=true};Tg.prototype.jf=function(){if(this.ud){var a=this.Fx.$b();if(a==null){I.remove(this.nc,"error");I.remove(this.nc,"info");
this.nc.innerHTML=""}else{var b=this.iA.$b();if(b==j.focus.UserMessages.Level.INFO){I.add(this.nc,"info");I.remove(this.nc,"error")}else{I.add(this.nc,"error");I.remove(this.nc,"info")}I.add(this.nc,"hilite");if(a.length<150){this.nc.innerHTML=za(a)}else{this.nc.innerHTML="An unknown error occurred.";alert(a)}j.global.setTimeout(ba(this.py,this),1000)}this.ud=false}};Tg.prototype.py=function(){I.remove(this.nc,"hilite")};var of=function(a,b,c,d,e){this.ia=l(a);this.nd=yb(b);this.Hu=c;this.Ke=d||this.ia.getAttribute("defaultText");
this.Lp=e;if(this.Lp){this.ia.setAttribute("maxlength",this.Lp)}Ya().Jf(ba(this.Dj,this),b);t(this.ia,yj,this.Bh,false,this);if(this.Hu){t(this.ia,Ng,this.Bh,false,this)}var f=this.nd.$b();if(f){this.ia.value=f}if(this.Ke){t(this.ia,Kd,this.vj,false,this);t(this.ia,je,this.Ux,false,this);this.vj()}};j.focus.InputBinder=of;of.prototype.Dj=function(){if(!this.ng){var a=this.nd.$b();this.lg=true;this.ia.value=a?a:"";this.lg=false;this.Vf=false;if(this.Ke){this.vj()}}};of.prototype.Bh=function(){if(!this.lg){var a=
this.ia.value||null;this.ng=true;var b=this.nd.gg().$j(null,true);b.Xq(this.nd.Ap,a);this.ng=false}};of.prototype.vj=function(){if(this.ia.value==""&&!this.Vf){this.Vf=true;I.add(this.ia,"input-default");this.ia.value=this.Ke}else{I.remove(this.ia,"input-default");this.Vf=false}};of.prototype.Ux=function(){if(this.Vf){this.ia.value="";I.remove(this.ia,"input-default");this.Vf=false}};var Ij=function(a,b,c){this.ia=l(a);this.nd=yb(b);var d=this.nd.$b();if(c){this.lB=c;pd(c.Va(),function(g,h){var i=
m.createElement("option");i.value=h;i.text=g;this.ia.options[this.ia.options.length++]=i})}for(var e=0;e<this.ia.options.length;e++){var f=this.ia.options[e];if(d==f.value){f.selected=true}}Ya().Jf(ba(this.Dj,this),b);t(this.ia,yj,this.Bh,false,this)};j.focus.SelectBinder=Ij;Ij.prototype.Dj=function(){if(!this.ng){var a=this.nd.$b();this.lg=true;this.ia.value=a?a:"";this.lg=false}};Ij.prototype.Bh=function(){if(!this.lg){var a=this.ia.value||null;this.ng=true;j.focus.ContactUtil.setData(this.nd.Cl,
a);this.ng=false}};var Np=function(a,b){this.Ha=a;this.tC=b};j.focus.DataValue=Np;Np.prototype.Re=function(){return this.id};var Mp=function(a){this.sA=a||{};this.rA=new O(this.sA)};j.focus.DataType=Mp;Mp.prototype.Va=function(){return this.rA};var yc={};j.focus.SimpleSizer=yc;yc.og=function(){Mj();t(j.global,Cp,$p)};yc.maximizeToEnclosingElement=function(a){a.setAttribute("maximize","true")};var $p=function(){Mj()};yc.cq=$p;var Mj=function(a){var b=a||document;Kj(b);Lj(b)};yc.updateSizes=Mj;var Kj=
function(a){for(var b=a.firstChild;b;b=b.nextSibling){Kj(b)}if(a.nodeType==1&&a.getAttribute("maximize")=="true"){a.style.width="1px";a.style.height="1px"}};yc.FC=Kj;var Lj=function(a){var b;if(a.nodeType==1&&a.getAttribute("maximize")=="true"&&a.nodeName!="TR"){var c,d;if(a.parentNode.nodeName=="BODY"){var e=ef();c=e.width;d=e.height}else{var f=a.parentNode;c=a.parentNode.offsetWidth-Jj(f);if(!j.userAgent.IE){c-=Jj(a)}d=a.parentNode.offsetHeight-Zp(f)}a.style.width=c+"px";a.style.height=d+"px";if(a.offsetHeight>
d){a.style.height=2*d-a.offsetHeight+"px"}if(a.nodeName=="TABLE"){var g=null,h=0,i;for(var i=0;i<a.rows.length;i++){var k=a.rows[i];if(k.getAttribute("maximize")=="true"){g=k;g.style.height="100%"}}if(g){for(var i=0;i<a.rows.length;i++){var k=a.rows[i];if(k!=g){h+=k.offsetHeight}}g.style.height=d-h-2+"px";g.style.width=""}}}for(b=a.firstChild;b;b=b.nextSibling){Lj(b)}};yc.cD=Lj;var Jj=function(a){return Nb(a,"paddingLeft")+Nb(a,"paddingRight")+Nb(a,"marginLeft")+Nb(a,"marginRight")+Nb(a,"borderLeftWidth")+
Nb(a,"borderRightWidth")};yc.TB=Jj;var Zp=function(a){return Nb(a,"paddingTop")+Nb(a,"paddingBottom")+Nb(a,"marginTop")+Nb(a,"marginBottom")+Nb(a,"borderTopWidth")+Nb(a,"borderBottomWidth")};yc.eC=Zp;var Nb=function(a,b){var c=Wa(a),d;if(c.defaultView&&c.defaultView.getComputedStyle){var e=c.defaultView.getComputedStyle(a,"");if(e){d=e[b]}}if(!d){d=a.currentStyle?a.currentStyle[b]:a.style[b]}if(qc(d,"px")){return Number(d.substring(0,d.length-2))}else{return 0}};yc.aC=Nb;m.selection={};m.selection.setStart=function(a,b){if(typeof a.selectionStart=="number"){a.selectionStart=b}else if(j.userAgent.IE){var c=Fd(a),d=c[0],e=c[1];if(!d.inRange(e)){return}var f=a.value,g=0,h=b;while(g!=-1&&g<h){g=f.indexOf("\r\n",g);if(g!=-1&&g<h){b--;g++}}d.collapse(true);d.move("character",b);d.select()}else{throw Error("Cannot set the selection start");}};var nj=function(a){if(typeof a.selectionStart=="number"){return a.selectionStart}if(j.userAgent.IE){var b=Fd(a),c=b[0],d=b[1];if(!c.inRange(d)){return-1}c.setEndPoint("EndToStart",
d);return c.text.length}throw Error("Cannot get the selection start");};m.selection.getStart=nj;m.selection.setEnd=function(a,b){if(typeof a.selectionEnd=="number"){a.selectionEnd=b}else if(j.userAgent.IE){var c=Fd(a),d=c[0],e=c[1];if(!d.inRange(e)){return}e.collapse();e.moveEnd("character",b-nj(a));e.select()}else{throw Error("Cannot set the selection end");}};m.selection.getEnd=function(a){if(typeof a.selectionEnd=="number"){return a.selectionEnd}if(j.userAgent.IE){var b=Fd(a),c=b[0],d=b[1];if(!c.inRange(d)){return 0}c.setEndPoint("EndToEnd",
d);return c.text.length}throw Error("Cannot get the selection end");};m.selection.setText=function(a,b){if(typeof a.selectionEnd=="number"){var c=a.value,d=a.selectionStart,e=c.substr(0,d),f=c.substr(a.selectionEnd);a.value=e+b+f;a.selectionStart=d;a.selectionEnd=d+b.length}else if(j.userAgent.IE){var g=Fd(a),h=g[0],i=g[1];if(!h.inRange(i)){return}var k=i.duplicate();i.text=b;i.setEndPoint("StartToStart",k);i.select()}else{throw Error("Cannot set the selection end");}};m.selection.getText=function(a){if(typeof a.selectionEnd==
"number"){var b=a.value;return b.substring(a.selectionStart,a.selectionEnd)}if(j.userAgent.IE){var c=Fd(a),d=c[0],e=c[1];if(!d.inRange(e)){return""}return e.text}throw Error("Cannot get the selection text");};var Fd=function(a){var b=a.ownerDocument||a.document,c=b.selection.createRange(),d;if(a.type=="textarea"){d=c.duplicate();d.moveToElementText(a)}else{d=a.createTextRange()}return[d,c]};m.selection.ZB=Fd;var Cc={};j.ui=Cc;var ha=function(a,b,c){vc.call(this);this.Dx=a;this.Rq=c;this.kf=b;t(b,[kh,lh,ih,jh],this);this.Lc=null;this.Ex=10;this.oa=[];this.qd=-1;this.pd=0;this.tf=null;this.Pd=null};Cc.AutoComplete=ha;ha.la(vc);var wf={HILITE:"hilite",SELECT:"select",DISMISS:"dismiss",CANCEL_DISMISS:"canceldismiss"},ih=wf.CANCEL_DISMISS,jh=wf.DISMISS,kh=wf.HILITE,lh=wf.SELECT;ha.EventType=wf;ha.prototype.qa=function(){if(!this.Yb()){ha.tc.qa.call(this);$(this.kf,[kh,lh,ih,jh],this)}};ha.prototype.$d=function(a){if(a.target==
this.kf){switch(a.type){case kh:this.be(a.row);break;case lh:this.be(a.row);this.pi();break;case ih:this.sj();break;case jh:this.In();break}}};ha.prototype.zz=function(a){if(this.Lc==a){return}this.Lc=a;this.Dx.Iq(this.Lc,this.Ex,this.Cx.p(this));this.sj()};ha.prototype.xz=function(a){this.tf=a};ha.prototype.Bw=function(){if(this.qd>=this.pd&&this.qd<this.pd+this.oa.length-1){this.be(this.qd+1);return true}return false};ha.prototype.Cw=function(){if(this.qd>this.pd){this.be(this.qd-1);return true}return false};
ha.prototype.be=function(a){if(this.uo(a)!=-1){this.qd=a;this.kf.be(a);return true}return false};ha.prototype.pi=function(){var a=this.uo(this.qd);if(a!=-1){this.Rq.ml(this.oa[a]);this.Le();return true}return false};ha.prototype.Le=function(){this.qd=-1;this.Lc=null;this.pd+=this.oa.length;this.oa.length=0;window.clearTimeout(this.Pd);this.Pd=null;this.kf.Le()};ha.prototype.In=function(){if(!this.Pd){this.Pd=window.setTimeout(this.Le.p(this),50)}};ha.prototype.sj=function(){window.setTimeout((function(){if(this.Pd){window.clearTimeout(this.Pd);
this.Pd=null}}).p(this),10)};ha.prototype.qa=function(){if(!this.Yb()){ha.tc.qa.call(this);this.kf.qa();this.Rq.qa()}};ha.prototype.Cx=function(a,b){if(this.Lc!=a){return}this.pd+=this.oa.length;this.oa=b;var c=[];for(var d=0;d<b.length;++d){c.push({id:this.Dv(d),data:b[d]})}this.kf.Gy(c,this.Lc,this.tf);if(c.length!=0){this.be(this.pd)}};ha.prototype.uo=function(a){var b=a-this.pd;if(b<0||b>=this.oa.length){return-1}return b};ha.prototype.Dv=function(a){return this.pd+a};var vf=function(a){this.oa=a};ha.ArrayMatcher=vf;vf.prototype.Iq=function(a,b,c){var d=this.Rv(a,b);if(d.length==0){d=this.Xv(a,b)}c(a,d)};vf.prototype.Rv=function(a,b){var c=[];if(a!=""){var d=ah(a),e=new RegExp("(^|\\W+)"+d,"i");Aq(this.oa,function(f){if(String(f).match(e)){c.push(f)}return c.length>=b})}return c};vf.prototype.Xv=function(a,b){var c=[];pd(this.oa,function(f){var g=a.toLowerCase(),h=String(f).toLowerCase(),i=0;if(h.indexOf(g)!=-1){i=parseInt(h.indexOf(g)/4,10)}else{var k=g.split(""),
n=-1,i=0,s=10;for(var u=0,z;z=k[u];u++){var v=h.indexOf(z);if(v>n){var A=v-n-1;if(A>s-5){A=s-5}i+=A;n=v}else{i+=s;s+=5}}}if(i<g.length*6){c.push({str:f,score:i})}});c.sort(function(f,g){return f.score-g.score});var d=[];for(var e=0;e<b&&e<c.length;e++){d.push(c[e].str)}return d};var ra=function(a,b,c){this.La=null;this.Oj=[];this.pf=a||",;";this.Vu=this.pf.substring(0,1);this.hA=new RegExp("/^[s"+this.pf+"]+|[s"+this.pf+"]+$/g");this.Zy=new RegExp("s*["+this.pf+"]$");this.Dp=b||"";this.Wz=50;this.yk=null;this.Cj=null;this.Bn=0;this.Cg=c!=null?c:true};ha.InputHandler=ra;ra.la(vc);var Dq=",;";ra.STANDARD_LIST_SEPARATORS=Dq;var Cq='"';ra.QUOTE_LITERALS=Cq;ra.prototype.qa=function(){if(!this.Yb()){ra.tc.qa.call(this);this.Zu.apply(this,this.Oj)}};ra.prototype.mj=function(){for(var a=
0;a<arguments.length;a++){var b=arguments[a];this.Oj.push(b);t(b,le,this.tp,false,this);t(b,ke,this.sp,false,this);var c=[je,rb];t(b,c,this.eo,false,this);t(b,Kd,this.gn,false,this)}};ra.prototype.Zu=function(){for(var a=0;a<arguments.length;a++){var b=arguments[a];$(b,le,this.tp,false,this);$(b,ke,this.sp,false,this);var c=[je,rb];$(b,c,this.eo,false,this);$(b,Kd,this.gn,false,this);x.remove(this.Oj,b)}};ra.prototype.Ym=function(a){this.La=a};ra.prototype.ml=function(a){if(this.Cg){var b=this.Cj,
c=this.Bn,d=this.Bl(b.value),e=d[c].replace(this.xr(d[c]),a.toString());if(!this.Zy.test(e)){e=xq(e)+this.Vu+" "}d[c]=e;if(c!=0){d[c]=" "+e}b.value=d.join("");var f=0;for(var g=0;g<=c;g++){f+=d[g].length}b.focus();m.selection.setStart(b,f);m.selection.setEnd(b,f)}else{this.Cj.value=a.toString()}};ra.prototype.tp=function(a){var b=a.keyCode;if(this.pf.indexOf(String.fromCharCode(a.charCode))!=-1){if(this.La&&this.La.pi()&&this.Cg){a.preventDefault()}}else if(b==13){if(this.La&&this.La.pi()&&this.Cg){a.preventDefault()}}else if(b!=
40&&b!=38&&b!=27&&b!=9){this.dq(a)}};ra.prototype.sp=function(a){var b=a.keyCode;if(b==40){if(this.La&&this.La.Bw()){a.preventDefault()}}else if(b==38){if(this.La&&this.La.Cw()){a.preventDefault()}}else if(b==9){j.global.clearTimeout(this.yk);this.qj(a.currentTarget);if(this.La&&this.La.pi()&&this.Cg){a.preventDefault()}}else if(b==27){if(this.La){this.La.Le()}}else if(j.userAgent.IE&&(b==8||b==46)){this.dq(a)}};ra.prototype.dq=function(a){j.global.clearTimeout(this.yk);this.yk=j.global.setTimeout(this.qj.p(this,
a.currentTarget),this.Wz)};ra.prototype.eo=function(a){if(this.La){this.La.sj()}this.qj(a.currentTarget)};ra.prototype.gn=function(a){if(this.La){this.La.In()}};ra.prototype.qj=function(a){var b=nj(a),c=this.gy(a.value,b);this.Cj=a;this.Bn=this.Oo(a.value,b);if(this.La){this.La.xz(a);this.La.zz(rc(c))}};ra.prototype.gy=function(a,b){return this.xr(this.Bl(a)[this.Oo(a,b)])};ra.prototype.xr=function(a){return String(a).replace(this.hA,"")};ra.prototype.Oo=function(a,b){var c=this.Bl(a),d=0;for(var e=
0,f=0;e<c.length&&f<b;e++){f+=c[e].length;d=e}return d};ra.prototype.Bl=function(a){if(!this.Cg){return[a]}var b=String(a).split(""),c=[],d=[];for(var e=0,f=false;e<b.length;e++){if(this.Dp&&this.Dp.indexOf(b[e])!=-1){if(!f){c.push(d.join(""));d.length=0}d.push(b[e]);f=!f}else if(!f&&this.pf.indexOf(b[e])!=-1){d.push(b[e]);c.push(d.join(""));d.length=0}else{d.push(b[e])}}c.push(d.join(""));return c};var sa=function(a,b,c){this.$=a||Cg().body;this.ne=!a;this.g=null;this.Lc="";this.oa=[];this.Wh=-1;this.Yg=false;this.className="ac-renderer";this.rowClassName="ac-row";this.activeClassName="active";this.Ie=b;this.My=c!=null?c:false;this.wk=null};ha.Renderer=sa;sa.la(Sa);sa.prototype.Gy=function(a,b,c){this.Lc=b;this.oa=a;this.Wh=0;this.tf=c;this.Jg=[];this.yy()};sa.prototype.Le=function(){if(this.Yg){this.Yg=false;cb(this.g,false)}};sa.prototype.hd=function(){if(!this.Yg){this.Yg=true;cb(this.g,
true)}};sa.prototype.ug=function(){return this.Yg};sa.prototype.Dw=function(a){if(a>=0&&a<this.g.childNodes.length){if(this.Wh>=0){I.remove(this.Jg[this.Wh],this.activeClassName)}I.add(this.Jg[a],this.activeClassName);this.Wh=a}};sa.prototype.be=function(a){for(var b=0;b<this.oa.length;b++){if(this.oa[b].id==a){this.Dw(b);return}}};sa.prototype.yy=function(){if(!this.g){this.g=m.createElement("div");I.add(this.g,this.className);m.appendChild(this.$,this.g);t(this.g,rb,this.To,false,this);t(this.g,
Xb,this.Vo,false,this);t(Wa(this.g),rb,this.Uo,false,this);t(this.g,Ld,this.Wo,false,this)}this.Jg.length=0;mj(this.g);if(this.Ie&&this.Ie.Gq){this.Ie.Gq(this,this.g,this.oa,this.Lc)}else{pd(this.oa,function(e){m.appendChild(this.g,this.Fy(e,this.Lc))},this)}if(this.oa.length==0){this.Le();return}else{this.hd()}this.ry(this.g);if(this.tf&&this.ne){var a=pa(this.tf),b=bb(this.tf),c=bb(Pb()),d=bb(this.g);a.y=b.height+a.y;if((this.My||a.x+d.width>c.width)&&this.wk!="LEFT"){a.x=a.x+b.width-d.width;this.wk=
"RIGHT"}else{this.wk="LEFT"}xe(this.g,a)}};sa.prototype.qa=function(){if(!this.Yb()){sa.tc.qa.call(this);if(this.g){$(this.g,rb,this.To,false,this);$(this.g,Xb,this.Vo,false,this);$(Wa(this.g),rb,this.Uo,false,this);$(this.g,Ld,this.Wo,false,this);m.removeNode(this.g);this.g=null}this.$=null}};sa.prototype.ry=function(a){if(j.userAgent.GECKO&&j.userAgent.MAC){a.style.width="";a.style.overflow="visible";a.style.width=a.offsetWidth;a.style.overflow="auto"}};sa.prototype.Ey=function(a,b,c){c.innerHTML=
za(a.data.toString())};sa.prototype.cp=function(a,b){if(a.nodeType==Ed){var c=a.nodeValue;b=ah(b);var d=new RegExp("(.*?)(^|\\W+)("+b+")","gi"),e=[],f=0,g=d.exec(c);while(g){e.push(g[1]);e.push(g[2]);e.push(g[3]);f=d.lastIndex;g=d.exec(c)}e.push(c.substring(f));if(e.length>1){a.nodeValue=e[0]+e[1];var h=m.createElement("b");m.appendChild(h,m.createTextNode(e[2]));h=a.parentNode.insertBefore(h,a.nextSibling);for(var i=e.length-1;i>=3;i--){a.parentNode.insertBefore(m.createTextNode(e[i]),h.nextSibling)}}}else{var k=
a.firstChild;while(k){var n=k.nextSibling;this.cp(k,b);k=n}}};sa.prototype.Fy=function(a,b){var c=Vb("div",{className:this.rowClassName});if(this.Ie&&this.Ie.Hq){this.Ie.Hq(a,b,c)}else{this.Ey(a,b,c)}if(b){this.cp(c,b)}I.add(c,this.rowClassName);this.Jg.push(c);return c};sa.prototype.Jo=function(a){while(a&&a!=this.g&&!Ag(a,this.rowClassName)){a=a.parentNode}return a?x.indexOf(this.Jg,a):-1};sa.prototype.To=function(a){var b=this.Jo(a.target);if(b>=0){this.dispatchEvent({type:lh,row:this.oa[b].id})}a.stopPropagation()};
sa.prototype.Vo=function(a){this.dispatchEvent(ih);a.stopPropagation()};sa.prototype.Uo=function(a){this.dispatchEvent(jh)};sa.prototype.Wo=function(a){var b=this.Jo(a.target);if(b>=0){this.dispatchEvent({type:kh,row:this.oa[b].id})}};var Eq=function(){};sa.CustomRenderer=Eq;Eq.prototype.Gq=function(a,b,c,d){};var Bq=function(a,b,c,d){var e=new vf(a),f=new sa,g=new ra(null,null,!(!c));ha.call(this,e,f,g);g.Ym(this);g.mj(b)};ha.Basic=Bq;Bq.la(ha);var Jp={};j.focus.AutoComplete=Jp;var Nd=function(){this.ok=false;this.sh=[];this.gB=[];this.de=null;this.qg=[];this.So=[]};j.focus.EmailAutocomplete=Nd;Nd.prototype.og=function(a,b,c,d,e){if(this.ok){gb.Ql("Init already called");return}this.ok=true;var f;f=c?new gd(b+"&jsx=true","Contacts","&&&START&&&","&&&END&&&"):new Id(b,"Contacts");var g=Ya();g.St(f,true);g.Jf(ba(this.fw,this),"$Contacts");g.lc();var h=e?new Nj:null,i=new sa(null,h,d);this.de=new lf(Dq,Cq);var k=new ha(this,i,this.de);this.de.Ym(k);
if(a){this.Ut(a)}};Nd.prototype.Ut=function(a){if(!this.ok){gb.Ql("Init should be called first");return}if(Ta(a)){this.qg=this.qg.concat(a);for(var b=0;b<a.length;b++){this.de.mj.call(this.de,a[b])}}else{this.qg.push(a);this.de.mj.call(this.de,a)}};Nd.prototype.Iq=function(a,b,c){var d=[];if(a!=""){var e=ah(a),f=f=new RegExp('(^|<| |")'+e,"i"),g=this.So;for(var h=0;h<g.length&&d.length<b;++h){var i=g[h];if(i.Do().match(f)){d.push(i)}}g=this.sh;for(var h=0;h<g.length&&d.length<b;++h){var i=g[h];if(i.toString().match(f)){d.push(i)}}}c(a,
d)};Nd.prototype.fw=function(a,b){var c=Ya().Yj("$Contacts");gb.wb("Got contacts");var d=c.Fb("Body");if(!d){gb.wb("No response body");return}var e=d.Fb("Contacts");if(!e){gb.wb("No contacts");return}var f=e.jc(),g=f.Ua();gb.wb("Got "+g+" contacts");if(g>0){for(var h=0;h<this.qg.length;h++){this.qg[h].setAttribute("autocomplete","off")}}var i=new O;for(var h=0;h<g;h++){var k=f.Mh(h),n=k.vb("Email"),s=k.vb("Name"),u=k.vb("Groups");if(u!=null){var z=u.length;for(var v=0;v<z;v++){var A=i.ha(u[v].id);
if(A==null){A=[];i.ma(u[v].id,A)}A.push(Ej(s,u[v].value))}}var e={};e.contactData=k;var T=Ej(s,n);e.formattedValue=T;e.toString=function(){return this.formattedValue};this.sh.push(e)}gb.wb("Created contact array");var J=c.Fb("Body").Fb("Groups");if(J!=null){var u=J.jc();g=u.Ua();gb.wb("Got "+g+" groups");for(var h=0;h<g;h++){var hc=u.Mh(h),Fc=hc.vb("id"),s=hc.vb("Name");if(Fc.charAt(0)!="^"){var Ba=i.ha(Fc);if(Ba!=null){this.So.push(new kf(s,Ba))}}}}};var Nj=function(){};j.focus.TwoLineEmailRenderer=
Nj;Nj.prototype.Hq=function(a,b,c){var d=a.data.contactData.vb("Name"),e=a.data.contactData.vb("Email"),f="";if(d&&e){f=za(d)+"<br/>"+za(e)}else if(d&&la(d)){f=za(d)}else if(e&&la(e)){f=za(e)}c.innerHTML=f};var _emailAutocomplete=j.global["_emailAutocomplete"]=new Nd,_initEmailAutocomplete=j.global["_initEmailAutocomplete"]=ba(j.global["_emailAutocomplete"].og,j.global["_emailAutocomplete"]),Ej=function(a,b){if(a==null||a.length==0){return" <"+b+">"}else{return'"'+a+'" <'+b+">"}};Nd.formatEntry=Ej;
var lf=function(a,b,c){ra.call(this,a,b,c)};j.focus.GroupsInputHandler=lf;lf.la(ra);lf.prototype.ml=function(a){if(a.mo){a=a.mo().join(", ")}lf.tc.ml.call(this,a)};var kf=function(a,b){this.wd=a;this.sh=b};Jp.Group=kf;kf.prototype.toString=function(){return this.wd+" (Group)"};kf.prototype.Do=function(){return this.wd};kf.prototype.mo=function(){return this.sh};var mf={};j.focus.HtmlUtil=mf;var $b={};j.focus.PickerLauncher=$b;var Dj={};j.focus.ContactManagerLauncher=Dj;var nf="/ui/";mf.serverBase=nf;var Op=function(a){nf=(mf.serverBase=a)};mf.ar=Op;window["HtmlUtil_setServerBase"]=Op;var Gj=function(a,b){var c=307,d;if(a){var e=document.getElementById(a);d=pa(e);var f=bb(e);d.y+=f.height}else{d=new aa(0,0)}var g=f.width>c?f.width:c,h=554,i=313,k=600;if(b){d.x+=b.screenX-b.clientX;d.y+=b.screenY-b.clientY}if(d.x+i>screen.width){d.x=screen.width-i}if(d.y+
k>screen.height){d.y=screen.height-k}var n=new jb(d.x,d.y,g,h);return n};$b.getCoordinates=Gj;var Yp=function(a,b,c){var d=Gj(a,b),e="toolbar=no,location=no,menubar=no,scrollbars=no,resizable=yes,status=no,width="+d.width+",height="+d.height+",top="+d.top+",left="+d.left,f=Qg(a,c).toString();window.open(f,"_picker",e)};$b.popPicker=Yp;var Qg=function(a,b){var c=new w(nf+"ContactPicker");if(a){c.$a("inputId",a)}if(b){c.$a("dm","goog")}c.$a("js","RAW");return c};$b.getUri=Qg;var Xp=function(a,b,c){if($b.curIframe){Hj()}var d=
Gj(a,null),e=Qg(a,c);window["iframeDone"]=Hj;e.$a("done","iframeDone");var f=dd("picker-iframe-div");if(f==null){var f=Vb("div",{id:"picker-iframe-div",style:"position: absolute; background-color; #FFF",zIndex:10});document.body.appendChild(f);f.innerHTML='<iframe id="picker-iframe" style="display:none; background-color; #FFF; border: 0"></iframe>'}var g=dd("picker-iframe");g.style.display="block";xe(f,d.left,d.top);ye(g,d.width,d.height);g.src=e;$b.curIframeDiv=f;$b.curIframe=g};$b.popIframe=Xp;
var Hj=function(){m.removeNode($b.curIframeDiv);$b.curIframeDiv=null;$b.curIframe=null};$b.iframeDone=Hj;var Kp=function(a){var b=new w(nf+"ContactManager"),c=a||"THREE";b.$a("style",c);b.$a("js","RAW");b.$a("pop","TRUE");return b};Dj.getUri=Kp;var Lp=function(a,b){var c=b=="TWO"?502:750,d=new jb(0,0,c,500),e="toolbar=no,location=no,menubar=no,scrollbars=no,resizable=yes,status=no,width="+d.width+",height="+d.height+",top="+d.top+",left="+d.left,f=Kp(b).toString();window.open(f,"_manager",e)};Dj.popManager=
Lp;var re=function(){};j.focus.PhotoPickerInstaller=re;re.prototype.Re=function(){return"photopicker.PhotoPicker"};re.install=function(){var a=new re;sb().Cq(a)};re.prototype.Mf=function(a,b){new Zb(a,b)};re.prototype.Xf=function(a,b){var c=new Ac(546,376);if(j.userAgent.IE){c.width+=2;c.height-=4}sb().Mu(this.Re(),c,a,b)};var Zb=function(a,b){this.ia=a;this.Mi=b;this.Zm(a)};j.focus.PhotoPickerEventHandler=Zb;Zb.prototype.Zm=function(a){t(a,Ld,this.Dg,false,this);t(a,id,this.pc,false,this);t(a,rb,
this.$x,false,this)};Zb.prototype.e=null;Zb.prototype.Uh=null;Zb.prototype.Dg=function(a){if(this.e){this.mn();return}var b=bb(this.ia);if(j.userAgent.IE){b.width+=4;b.height+=4}b.width+=2;b.height+=2;var c=Vb("div");this.e=c;this.Zm(c);c.style.position="absolute";c.style.zIndex=20;ye(c,b);c.style.border="2px solid blue";c.innerHTML='<div style="background-color: white; text-align: center; font-family: Arial; font-size: 12px; padding: 2px"><a href="javascript:void(0)">Change picture</a></div>';var d=
pa(this.ia);d.x-=3;d.y-=3;c.ownerDocument.body.appendChild(c);xe(c,d)};Zb.prototype.pc=function(a){if(this.e){var b=a.relatedTarget;if(!b||b!=this.ia&&!m.contains(this.e,b)){this.lk(true)}}};Zb.prototype.$x=function(){this.lk(false);var a=yb("$Contacts/"+this.Mi.contactid).$j(),b=a.vb("Name")||a.vb("Email"),c=a.vb("Email"),d={dn:b};if(c&&!qc(c,"hotmail.com")&&!qc(c,"yahoo.com")){d["eUrl"]=j.focus.ContactData.ha().getBasePhotoUrl()+encodeURIComponent(c)+"?t=e&rp=1&pld=1&"+hq(2000000)}sb().Xf("photopicker.PhotoPicker",
d,this.rw.p(this))};Zb.prototype.lk=function(a){this.mn();if(a){var b=ba(this.lk,this,false);this.Uh=j.global.setTimeout(b,20);return}if(this.ia&&this.e){this.e.parentNode.removeChild(this.e);this.e=null}};Zb.prototype.mn=function(){if(this.Uh){j.global.clearTimeout(this.Uh);this.Uh=null}};Zb.isPointInElementRect=function(a,b){var c=pa(b);return c.x<a.x&&a.x<c.x&&c.y<a.y&&a.y<c.y};Zb.prototype.rw=function(a){var b=this.Mi.contactid;if(a.type=="PHOTO_PICKED"){if(a.evergreen){j.focus.ContactData.ha().chooseEvergreen(b)}else{j.focus.ContactData.ha().savePhoto(b,
a.imageUrl,a.cropString)}}else if(a.type=="SUGGEST_DONE"&&a.suggestMessage){j.focus.ContactData.ha().sendPhotoSuggestion(b,a.suggestMessage)}else{sb().Yy("photopicker.PhotoPicker",{type:"CLOSE"});sb().fv("photopicker.PhotoPicker")}};var xc=function(){};j.focus.HovercardInstaller=xc;xc.prototype.og=function(){j.focus.ContactUtil.installShortcuts();var a=j.focus.ContactData.ha();a.setUseGroups(true);a.setGetAllFields(true);a.setUseThumbs(true);a.lc()};xc.prototype.Re=function(){return"goog.focus.Hovercard"};
xc.install=function(){var a=new xc;a.og();sb().Cq(a)};xc.prototype.og=function(){var a=sb().fk("CONTACTS");j.focus.ContactUtil.installShortcuts();j.focus.ViewManager.ha().addXmlView(a+"/ui/view/Hovercard.xml");var b=j.focus.ContactData.ha();b.setUseGroups(true);b.setGetAllFields(true);b.setUseThumbs(true);b.lc();t(j.focus.ViewManager.ha(),"WidgetEvent",this.hw,false)};xc.prototype.hw=function(a){};xc.prototype.Re=function(){return"goog.focus.Hovercard"};xc.prototype.Mf=function(a,b){a.style.color=
"green";var c=new qe(a,b);t(a,Ld,c.Fw,false,c)};xc.prototype.Sd=function(a,b){j.focus.ViewManager.ha().renderView("Hovercard",a,null,{Email:b["email"]})};var qe=function(a,b){this.ia=a;this.Mi=b};j.focus.HovercardEventHandler=qe;qe.prototype.Qp=function(a){var b=new aa(a.clientX,a.clientY),c=Fj(b,this.ia)||Fj(b,this.cv);if(!c){this.Rz()}};var Fj=function(a,b){var c=pa(b),d=bb(b);c.x-=10;c.y-=10;d.width+=20;d.height+=20;return c.x<a.x&&a.x<c.x+d.width&&c.y<a.y&&a.y<c.y+d.height};qe.isPointInElementRect=
Fj;qe.prototype.Fw=function(a){if(this.ia.dp)return;this.ia.style.textDecoration="underline";this.ia.style.cursor="pointer";var b=new aa(a.offsetX+5,a.offsetY+5);this.Pn=sb().Jn("goog.focus.Hovercard",b,null,this.Mi);this.cv=dd(this.Pn);t(document,me,this.Qp,false,this);this.ia.dp=true};qe.prototype.Rz=function(){$(document,me,this.Qp,false,this);this.ia.style.color="green";this.ia.style.textDecoration="";sb().ev(this.Pn);this.ia.dp=false};Sg("goog.focus.ContactManagerLauncher.popManager",Lp);Sg("goog.focus.PickerLauncher.popPicker",
Yp);Sg("goog.focus.PickerLauncher.popIframe",Xp);var oc=function(a){Sa.call(this);this.Ww=a||1};j.Timer=oc;oc.la(Sa);oc.prototype.Pj=false;oc.prototype.Li=null;oc.prototype.$z=function(){if(this.Pj){this.dispatchEvent(Go)}};oc.prototype.start=function(){this.Pj=true;if(!this.Li){this.Li=j.global.setInterval(this.$z.p(this),this.Ww)}};oc.prototype.stop=function(){this.Pj=false;j.global.clearInterval(this.Li);this.Li=null};oc.prototype.qa=function(){if(!this.Yb()){Mg.call(this);this.stop()}};var Go="tick";oc.TICK=Go;var Ho=function(a,b,c){if(ld(a)){if(c){a=
a.p(c)}}else if(a&&typeof a.$d=="function"){a=a.$d.p(a)}else{throw Error("Invalid listener argument");}return j.global.setTimeout(a,b||0)};oc.callOnce=Ho;oc.clear=function(a){j.global.clearTimeout(a)};var zj={BACKSPACE:8,TAB:9,ENTER:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,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,CONTEXT_MENU:93,NUM_PLUS:107,NUM_MINUS:109,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,
F10:121,F11:122,F12:123,NUMLOCK:144,COMMA:188,DOT:190,SLASH:191,BACKSLASH:220,WIN_KEY:224},at=zj.ENTER,bt=zj.ESC;ca.KeyCodes=zj;var nh=function(a,b,c){zb.call(this,a,b);this.item=c};Cc.ItemEvent=nh;nh.la(zb);var Z=function(a,b){this.Hb=[];this.fz(a);if(b){this.Bz(b)}};Cc.PopupBase=Z;Z.la(Sa);var gk={TOGGLE_DISPLAY:"toggle_display",MOVE_OFFSCREEN:"move_offscreen"},Nq=gk.MOVE_OFFSCREEN,hk=gk.TOGGLE_DISPLAY;Z.Type=gk;Z.prototype.g=null;Z.prototype.hu=true;Z.prototype.gb=false;Z.prototype.xp=-1;Z.prototype.ai=-1;Z.prototype.Ea=hk;var zf={BEFORE_SHOW:"beforeshow",SHOW:"show",BEFORE_HIDE:"beforehide",HIDE:"hide"},it=zf.BEFORE_HIDE,jt=zf.BEFORE_SHOW,kt=zf.HIDE,lt=zf.SHOW;Z.EventType=zf;var yf=150;Z.DEBOUNCE_DELAY_MS=
yf;Z.prototype.Bz=function(a){this.Ea=a};Z.prototype.eb=function(){return this.g};Z.prototype.fz=function(a){this.dv();this.g=a};Z.prototype.dv=function(){if(this.gb){throw Error("Can not change this state of the popup while showing.");}};Z.prototype.ug=function(){return this.gb};Z.prototype.pp=function(){return this.gb||Bb()-this.ai<yf};var Oq=function(a){if(a){if(!this.g){throw Error("Caller must call setElement before trying to show thepopup");}this.ne();this.Jz()}else{this.Vh()}};Z.prototype.Rb=
Oq;Z.prototype.ne=function(){};Z.prototype.Jz=function(){if(this.gb){return}if(!this.Tx()){return}if(this.hu){var a=Wa(this.g);this.Hb.push(t(a,Xb,this.$p,true,this));if(j.userAgent.IE){this.Hb.push(t(a,Zs,this.Zp,true,this))}}if(this.Ea==hk){this.g.style.visibility="visible";cb(this.g,true)}else if(this.Ea==Nq){this.ne()}this.gb=true;this.ke()};Z.prototype.Vh=function(a){if(this.gb){if(!this.Sx(a)){return}this.Fq();if(this.Ea==hk){this.g.style.visibility="hidden";cb(this.g,false)}else if(this.Ea==
Nq){this.Ix()}this.gb=false;this.Nk()}};Z.prototype.Ix=function(){this.g.style.left="-200px";this.g.style.top="-200px"};Z.prototype.Tx=function(){return this.dispatchEvent(jt)};Z.prototype.ke=function(){this.xp=Bb();this.ai=-1;this.dispatchEvent(lt)};Z.prototype.Sx=function(a){return this.dispatchEvent({type:it,target:a})};Z.prototype.Nk=function(){this.ai=Bb();this.dispatchEvent(kt)};Z.prototype.$p=function(a){if(!m.contains(this.g,a.target)){this.Vh(a.target)}};Z.prototype.Zp=function(a){if(!m.contains(this.g,
a.target)){if(Bb()-this.xp<yf){return}this.Vh()}};Z.prototype.Fq=function(){for(var a=0;a<this.Hb.length;a++){Mb(this.Hb[a])}this.Hb.length=0};Z.prototype.qa=function(){this.Fq();Mg.call(this);this.g=null};var Ua=function(a){this.sq=Be;this.Ax=new Na(0,0,0,0);this.Zk=new ph(0,0);Z.call(this,a)};Cc.Popup=Ua;Ua.la(Z);var xf={TOP_LEFT:1,TOP_RIGHT:2,BOTTOM_LEFT:3,BOTTOM_RIGHT:4},qh=xf.BOTTOM_LEFT,Jq=xf.BOTTOM_RIGHT,Be=xf.TOP_LEFT,rh=xf.TOP_RIGHT;Ua.Corner=xf;var Ce={IGNORE:0,ADJUST_X:1,FAIL_X:2,ADJUST_Y:4,FAIL_Y:8},gt=Ce.ADJUST_X,ht=Ce.ADJUST_Y,Kq=Ce.FAIL_X,Lq=Ce.FAIL_Y,Mq=Ce.IGNORE;Ua.Overflow=Ce;var ze=function(){};Ua.AbstractPosition=ze;ze.prototype.Ad=function(a,b,c){};var Ae=function(a,b){this.element=
a;this.corner=b};Ua.AnchoredPosition=Ae;Ae.la(ze);Ae.prototype.Ad=function(a,b,c){De(this.element,this.corner,a,b,new aa(0,0),c)};var ek=function(a,b){Ae.call(this,a,b)};Ua.AnchoredViewPortPosition=ek;ek.la(Ae);ek.prototype.Ad=function(a,b,c){var d=De(this.element,this.corner,a,b,new aa(0,0),c,Kq|Lq);if(!d){De(this.element,b,a,this.corner,new aa(0,0),c)}};var ph=function(a,b){if(a instanceof aa){this.coordinate=a}else{this.coordinate=new aa(a,b)}};Ua.AbsolutePosition=ph;ph.la(ze);ph.prototype.Ad=
function(a,b,c){fk(this.coordinate,a,b,c)};var sh=function(a,b){if(a instanceof aa){this.coordinate=a}else{this.coordinate=new aa(a,b)}};Ua.ViewPortPosition=sh;sh.la(ze);sh.prototype.Ad=function(a,b,c){var d=Pb(a);De(d,Be,a,b,this.coordinate,c)};var Iq=function(a,b){if(a instanceof aa){this.coordinate=a}else{this.coordinate=new aa(a,b)}};Ua.ClientPosition=Iq;sh.la(ze);Iq.prototype.Ad=function(a,b,c){var d=Pb(a),e=new aa(this.coordinate.x+d.scrollLeft,this.coordinate.y+d.scrollTop);De(d,Be,a,b,e,c)};
Ua.prototype.Pv=function(){return this.sq};Ua.prototype.Qv=function(a){return this.Zk};Ua.prototype.setPosition=function(a){this.Zk=a;if(this.gb){this.ne()}};Ua.prototype.ne=function(){if(!this.gb){cb(this.g,true)}this.Zk.Ad(this.g,this.sq,this.Ax);if(!this.gb){cb(this.g,false)}};Ua.prototype.Ad=function(){this.ne()};var De=function(a,b,c,d,e,f,g){j.style.setPosition(c,0,0);var h=pa(c),i=pa(a),k=new aa(i.x-h.x,i.y-h.y),n=1,s=1,u=bb(a);switch(b){case Be:break;case rh:k.x+=u.width;n=-1;break;case qh:k.y+=
u.height;s=-1;break;case Jq:k.x+=u.width;k.y+=u.height;n=-1;s=-1;break}if(e){k.x+=n*e.x;k.y+=s*e.y}return fk(k,c,d,f,g)};Ua.positionPopup=De;var fk=function(a,b,c,d,e){var f=d?d:new Na(0,0,0,0),g=e||Mq,h=bb(b);switch(c){case Be:a.x+=f.left;a.y+=f.top;break;case rh:a.x-=h.width;a.x-=f.right;a.y+=f.top;break;case qh:a.y-=h.height;a.x+=f.left;a.y-=f.bottom;break;case Jq:a.x-=h.width;a.y-=h.height;a.x-=f.right;a.y-=f.bottom;break}if(g!=Mq){var i=Wa(b),k=pp(i)||window,n=bb(b),s=ef(k),u=op(k);if(a.x+n.width-
u.x>s.width){if(g&gt){a.x-=a.x+n.width-u.x-s.width}else if(g&Kq){return false}}if(a.y+n.height-u.y>s.height){if(g&ht){a.y-=a.y+n.height-u.y-s.height}else if(g&Lq){return false}}}j.style.setPosition(b,a);return true};Ua.positionAtCoordinate=fk;var Cb=function(a){Ua.call(this,a);this.Hb=[]};Cc.MenuBase=Cb;Cb.la(Ua);var Hq={};Cb.Events=Hq;var oh="itemaction";Hq.ITEM_ACTION=oh;Cb.prototype.ke=function(){Cb.tc.ke.call(this);this.Hb.push(t(this.g,Ld,this.Dg,false,this));this.Hb.push(t(this.g,id,this.pc,false,this));this.Hb.push(t(this.g,Xb,this.xd,false,this));this.Hb.push(t(this.g,ne,this.Jb,false,this));this.Hb.push(t(this.g,j.userAgent.IE?ke:le,this.Ok,false,this))};Cb.prototype.Nk=function(a){Cb.tc.Nk.call(this);for(var b=0;b<this.Hb.length;b++){Mb(this.Hb[b])}this.Hb.length=
0};Cb.prototype.gd=function(a){};Cb.prototype.Dg=function(a){};Cb.prototype.pc=function(a){};Cb.prototype.xd=function(a){};Cb.prototype.Jb=function(a){};Cb.prototype.Ok=function(a){};var Ia=function(a){Cb.call(this,a)};Cc.AttachableMenu=Ia;Ia.la(Cb);Ia.prototype.ib=null;Ia.prototype.qp="menu-item";Ia.prototype.Oq="menu-item-selected";Ia.prototype.bi=Bb();Ia.prototype.vo=function(){return this.qp};var hh=function(a){if(this.ib){I.remove(this.ib,this.Oq)}this.ib=a;if(this.ib){I.add(this.ib,this.Oq);var b=this.ib.offsetTop,c=this.ib.offsetHeight,d=this.g.scrollTop,e=this.g.offsetHeight;if(b<d){this.g.scrollTop=b}else if(b+c>d+e){this.g.scrollTop=b+c-e}}};Ia.prototype.gd=hh;Ia.prototype.ke=
function(){Ia.tc.ke.call(this);this.g.focus()};Ia.prototype.Oh=function(a){var b=this.g.getElementsByTagName("*"),c=b.length,d;if(this.ib){for(var e=0;e<c;e++){if(b[e]==this.ib){d=a?e-1:e+1;break}}}if(!Y(d)){d=a?c-1:0}for(var e=0;e<c;e++){var f=a?-1:1,g=d+f*e%c;if(g<0){g+=c}else if(g>=c){g-=c}if(this.op(b[g])){return b[g]}}return null};Ia.prototype.Dg=function(a){var b=this.Pe(a.target);if(b==null){return}if(Bb()-this.bi>yf){this.gd(b)}};Ia.prototype.pc=function(a){var b=this.Pe(a.target);if(b==null){return}if(Bb()-
this.bi>yf){this.gd(null)}};Ia.prototype.xd=function(a){a.preventDefault()};Ia.prototype.Jb=function(a){var b=this.Pe(a.target);if(b==null){return}this.Rb(false);this.bq(b)};Ia.prototype.Ok=function(a){switch(a.keyCode){case 40:this.gd(this.Oh(false));this.bi=Bb();break;case 38:this.gd(this.Oh(true));this.bi=Bb();break;case 13:if(this.ib){this.bq();this.Rb(false)}break;case 27:this.Rb(false);break}a.preventDefault()};Ia.prototype.bq=function(a){this.dispatchEvent(new nh(oh,this,a||this.ib))};Ia.prototype.op=
function(a){return Ag(a,this.qp)};Ia.prototype.Pe=function(a){while(a!=null&&a!=document.body){if(this.op(a)){return a}a=a.parentNode}return null};var M=function(a,b){var c=a||"menu",d=b||Cg().body;this.g=Vb("div",{tabIndex:0,className:c});d.appendChild(this.g);Ia.call(this,this.g);this.Kb=null;this.ee=[]};Cc.BasicMenu=M;M.la(Ia);M.prototype.Ne=null;M.prototype.Ky=null;M.prototype.Ni=10;var Fq=300;M.SA=Fq;M.prototype.Go=function(){return this.Kb};M.prototype.ew=function(){return this.Ni};M.prototype.add=function(a){var b=this.eb();if(!b){throw Error("setElement() called before create()");}if(a.zo()){throw Error("Menu item already added to a menu");
}a.rl(this);this.ee.push(a);b.appendChild(a.vh())};M.prototype.Tw=function(a,b){var c=this.eb();if(!c){throw Error("setElement() called before create()");}if(a.zo()){throw Error("Menu item already added to a menu");}a.rl(this);Xi(this.ee,a,b);c.insertBefore(a.vh(),c.childNodes[b])};M.prototype.remove=function(a){a.remove();a.rl(null);x.remove(this.ee,a)};M.prototype.zy=function(a){this.remove(this.ee[a])};M.prototype.focus=function(){this.g.focus()};M.prototype.oz=function(a){this.Kb=a};M.prototype.Wq=
function(a,b,c){if(this.Ne){Mb(this.Ne)}if(this.Lf!=a){this.xj=false;this.ai=-1}var d=c||rb;this.Ne=t(a,d,this.Sk,false,this);var e=t(window,Cp,this.cq,false,this);this.setPosition(new Ae(a,b||qh));this.Lf=a};M.prototype.qa=function(){if(!this.Yb()){for(var a=0;a<this.ee.length;a++){this.ee[a].qa()}Mg.call(this);Mb(this.Ne);Mb(this.Ky);m.removeNode(this.g);this.g=null;this.Lf=null}M.tc.qa.call(this)};M.prototype.Rb=function(a,b){if(this.pp()&&a){return}if(a==false){if(this.ta){this.ta.rh();hh.call(this,
null)}if(this.Kb&&!b){this.Kb.focus()}}else{if(this.Kb){this.Ni=this.Kb.ew()+1}this.g.style.zIndex=this.Ni}if(b&&this.Kb){this.Kb.Rb(a,b)}if(this.Tc){window.clearTimeout(this.Tc);this.Tc=null}this.ta=null;Oq.call(this,a)};M.prototype.vz=function(a){this.gd(a==-1?null:this.g.childNodes[a])};M.prototype.$h=function(a,b){if(a||!this.ta||!this.ta.Yo()){hh.call(this,a)}var c=a?this.Se(a):null;if(c&&c!=this.ta){if(b&&this.ta){this.ta.rh();this.ta=null}if(this.Tc){window.clearTimeout(this.Tc);this.Tc=null}if(!b){this.Tc=
window.setTimeout(this.Wy.p(this,c),Fq)}if(this.Kb){this.Kb.gd(this.Lf);this.g.focus()}}};M.prototype.gd=function(a){var b,c;if(!a){b=null;c=null}else if(typeof a.nodeType!="undefined"){b=a;c=this.Se(b)}else{c=a;b=c.g}if(b||!this.ta||!this.ta.Yo()){hh.call(this,b)}if(c==this.ta){return}if(this.ta&&b){this.ta.rh()}if(b){var c=this.Se(b);if(c.Ve()){c.Tk();c.ig().focus()}this.ta=c}};M.prototype.Wy=function(a){if(this.Tc){window.clearTimeout(this.Tc);this.Tc=null}var b=this.Se(this.ib);if(b!=a){return}if(this.ta&&
a){this.ta.rh()}if(a.Ve()){a.Tk();a.ig().focus()}else{this.g.focus()}this.ta=a};M.prototype.hj=function(a){var b=this.Se(a);if(b.Ve()){b.Tk();var c=b.ig();c.focus();this.ta=b}else{this.Rb(false,true);this.dispatchEvent(new nh(oh,this,b))}};var Gq=function(){if(!this.xj){this.Rb(true)}this.xj=false};M.prototype.Sk=Gq;M.prototype.wn=function(a){if(m.contains(this.g,a)){return true}if(this.ta&&this.ta.Ve()){return this.ta.ig().wn(a)}return false};M.prototype.$p=function(a){if(this.Lf==a.target||m.contains(this.Lf,
a.target)){this.xj=true}var b=this;while(b.Kb){b=b.Kb}if(!b.wn(a.target)){this.Vh()}};M.prototype.Dg=function(a){var b=this.Pe(a.target);if(b==null){return}this.$h(b)};M.prototype.pc=function(a){var b=this.Pe(a.target);if(b==null){return}this.$h(null)};M.prototype.Zp=function(a){};M.prototype.Jb=function(a){var b=this.Pe(a.target);if(b==null){return}this.hj(b)};M.prototype.cq=function(){if(!this.Yb()&&this.ug()){this.Ad()}};M.prototype.Ok=function(a){var b=false;switch(a.keyCode){case 37:if(this.Kb){this.Rb(false)}b=
true;break;case 39:var c=this.Se(this.ib);if(this.ib&&c.Ve()){this.hj(this.ib);c.ig().vz(0)}b=true;break;case 40:this.$h(this.Oh(false),true);b=true;break;case 38:this.$h(this.Oh(true),true);b=true;break;case 13:if(this.ib){this.hj(this.ib)}b=true;break;case 27:this.Rb(false);b=true;break}if(b){a.preventDefault()}};M.prototype.ke=function(){M.tc.ke.call(this);this.gd(null);if(!this.Kb){this.g.focus()}};M.prototype.Se=function(a){var b=-1;for(var c=a;c;c=lj(c)){b++}return b==-1?null:this.ee[b]};var kb=
function(a,b,c){this.Ba=String(a);this.vf=b||a;this.Sb=c||null;this.mc=null;this.g=null};M.Item=kb;kb.prototype.$b=function(){return this.vf};kb.prototype.sf=function(a){this.vf=a};kb.prototype.qa=function(){this.remove();if(this.Sb){this.Sb.qa()}};kb.prototype.rl=function(a){this.mc=a;if(this.Sb){this.Sb.oz(a)}};kb.prototype.zo=function(){return this.mc};kb.prototype.vh=function(){if(!this.mc){throw Error("MenuItem is not attached to a menu");}this.g=Vb("div",{className:this.mc.vo()},this.Ba,this.Sb?
Vb("span",null,"\u25b6"):null);return this.g};kb.prototype.remove=function(){m.removeNode(this.g);this.g=null};kb.prototype.Ve=function(){return this.Sb!=null};kb.prototype.Yo=function(){return this.Ve()?this.Sb.pp():false};kb.prototype.ig=function(){return this.Sb};kb.prototype.Tk=function(){if(this.Sb){var a=this.Sb,b=a.Pv()==rh?Be:rh;a.Wq(this.g,b);a.Rb(true)}};kb.prototype.rh=function(){if(this.Sb){this.Sb.Rb(false)}};var mh=function(){kb.call(this,null)};M.Separator=mh;mh.la(kb);mh.prototype.vh=
function(){if(!this.mc){throw Error("MenuSeparator is not attached to a menu");}this.g=m.createElement("hr");return this.g};function rd(){}var rk=function(a){if(typeof Error!="undefined"){throw new Error(a||"Assertion Failed");}else{throw a;}};rd.raise=rk;var Fe=function(a){if(a===undefined)a="Assertion failed";if(!(Ke===undefined))Ke(a+"\n");rk(a)};rd.fail=Fe;rd.isTrue=function(a,b){if(!a){if(b===undefined)b="Assertion failed";Fe(b)}};rd.Fa=function(a,b,c){if(a!=b){if(c===undefined){c="AS_Assert.equals failed: <"+a+"> != <"+b+">"}Fe(c)}};rd.typeOf=function(a,b,c){if(typeof a==b)return;if(a||a==""){try{if(b==pk[typeof a]||
a instanceof b){return}}catch(d){}}if(c===undefined){if(typeof b=="function"){var e=b.toString().match(/^\s*function\s+([^\s\{]+)/);if(e)b=e[1]}c="AS_Assert.typeOf failed: <"+a+"> not typeof "+b}Fe(c)};var pk={string:String,number:Number,"boolean":Boolean};rd.TYPE_MAP=pk;var qk=function(a,b){var c=qk.caller;if(c&&c.arguments.length!=a){if(b===undefined){b=c.name+" expected "+a+" arguments  but received "+c.arguments.length}Fe(b)}};rd.numArgs=qk;var Fk=false;function Ke(a){try{throw a;}catch(b){sl(b)}}function sl(a,b){var c="Javascript exception: "+(b?b:"")+" "+a;if(Sd()){c+=" "+a.name+": "+a.message+" ("+a.number+")"}var d="";if(typeof a=="string"){d=a+"\n"}else{for(var e in a){try{d+=e+": "+a[e]+"\n"}catch(f){}}}d+=Dk(sl.caller);er(c+"\n"+d,1)}var Ss=/function (\w+)/;function cr(a){var b=Ss.exec(String(a));if(b){return b[1]}return""}function Dk(a){try{if(!Sd()&&!(Ff("safari")||Ff("konqueror"))&&Ff("mozilla")){return Error().stack}if(!a)return"";
var b="- "+cr(a)+"(";for(var c=0;c<a.arguments.length;c++){if(c>0)b+=", ";var d=String(a.arguments[c]);if(d.length>40){d=d.substr(0,40)+"..."}b+=d}b+=")\n";b+=Dk(a.caller);return b}catch(e){return"[Cannot get stack trace]: "+e+"\n"}}var fr;var Sc=null,Fh=false;function dr(){if((Sc==null||Sc.closed)&&!Fh){try{Fh=true;Sc=window.open("","debug","width=700,height=500,toolbar=no,resizable=yes,scrollbars=yes,left=16,top=16,screenx=16,screeny=16");Sc.blur();Sc.document.open();Fh=false;var a="<font color=#ff0000><b>To turn off this debugging window,hit 'D' inside the main caribou window, then close this window.</b></font><br>";
Ek(a)}catch(b){}}}function er(a,b){if(!Fk){if(typeof Sq!="undefined"){Sq(Sh(a))}return}try{var c=Re()-fr,d="["+c+"] "+Sh(a).replace(/\n/g,"<br>")+"<br>";if(b==1){d="<font color=#ff0000><b>Error: "+d+"</b></font>";Sc.focus()}}catch(e){}Ek(d)}function Ek(a){if(!Fk){return}try{dr();Sc.document.write(a);Sc.scrollTo(0,1000000)}catch(b){}};function Ff(a){if(a in zh){return zh[a]}return zh[a]=navigator.userAgent.toLowerCase().indexOf(a)!=-1}var zh={};function Sd(){return Ff("msie")&&!window.opera}function jk(a){if(typeof Error!="undefined"){throw new Error(a||"Assertion Failed");}else{throw a;}}function Le(a){if(a===undefined)a="Assertion failed";if(Me(Ke))Ke(a+"\n");jk(a)}function Oa(a,b){if(!a){if(b===undefined)b="Assertion failed";Le(b)}}function vk(a,b,c){if(a!=b){if(c===undefined){c="AssertEquals failed: <"+a+"> != <"+b+">"}Le(c)}}
function Rc(a,b,c){if(typeof a==b)return;if(a||a==""){try{if(b==Vq[typeof a]||a instanceof b)return}catch(d){}}if(c===undefined){if(typeof b=="function"){var e=b.toString().match(/^\s*function\s+([^\s\{]+)/);if(e)b=e[1]}c="AssertType failed: <"+a+"> not typeof "+b}Le(c)}var Vq={string:String,number:Number,"boolean":Boolean};function Fs(a,b,c,d,e){b=""+b;Oa(typeof a=="string"&&typeof b=="string"&&!a.match(/[\s;]/)&&!b.match(/[\s;]/),"trying to set an invalid cookie");if(!Me(c))c=-1;if(!Me(d))d="/";
if(!Me(e))e=null;var f=e==null?"":";domain="+e,g=d==null?"":";path="+d,h;if(c<0){h=""}else if(c==0){var i=new Date(1970,1,1);h=";expires="+i.toUTCString()}else{var k=new Date(Re()+c*1000);h=";expires="+k.toUTCString()}document.cookie=a+"="+b+f+g+h};function Re(){return(new Date).getTime()}function yr(a){try{return a.parentNode}catch(b){return a}}function Br(a,b){do{if(a===b)return true;b=yr(b)}while(b&&b!==document.body);return false}function Hl(a){return Il(a,Vs)}var Vs={gp:function(a){return a.document.body.scrollTop},
hp:function(a){return a.document.documentElement.scrollTop},Nn:function(a){return a.pageYOffset}};function Gl(a){return Il(a,Us)}var Us={gp:function(a){return a.document.body.scrollLeft},hp:function(a){return a.document.documentElement.scrollLeft},Nn:function(a){return a.pageXOffset}};function Il(a,b){try{if(!window.opera&&"compatMode"in a.document&&a.document.compatMode=="CSS1Compat"){return b.hp(a)}else if(Sd()){return b.gp(a)}}catch(c){}return b.Nn(a)}var Js=/&/g,ot=/</g,mt=/>/g;function Sh(a){if(!a)return"";
return a.replace(Js,"&amp;").replace(ot,"&lt;").replace(mt,"&gt;").replace(st,"&quot;")}var st=/\"/g;function Sf(a){return Sf.rp[a]}function Li(a){if(!Sf.rp){var b={};b["\\"]="\\\\";b["'"]="\\047";b["\u0008"]="\\b";b['"']="\\042";b["<"]="\\074";b[">"]="\\076";b["&"]="\\046";b["\n"]="\\n";b["\r"]="\\r";b["\u0085"]="\\205";b["\u2028"]="\\u2028";b["\u2029"]="\\u2029";Sf.rp=b}return"'"+a.toString().replace(/[\'\\\r\n\b\"<>&\u0085\u2028\u2029]/g,Sf)+"'"}var yt=/\s+/g,Ks=/^ /,Os=/ $/;function Ck(a){if(!a)return"";
return a.replace(yt," ").replace(Ks,"").replace(Os,"")}function Bk(a){var b={};b.clientX=a.clientX;b.clientY=a.clientY;b.pageX=a.pageX;b.pageY=a.pageY;b.type=a.type;b.srcElement=a.srcElement;b.target=a.target;b.cancelBubble=a.cancelBubble;b.explicitOriginalTarget=a.explicitOriginalTarget;b.button=a.button;b.shiftKey=a.shiftKey;b.ctrlKey=a.ctrlKey;return b}function Wm(a){var b="",c="";for(var d=0;d<a.length;){var e=Fl(a,d);if(e.charAt(0)=="<"){var f=e.indexOf(">");c=e.substring(1,f!=-1?f:e.length)}else if(c==
""){b+=e}d+=e.length}if(c==""&&b.indexOf("@")!=-1){c=b;b=""}b=Ck(b);b=to(b,"'");b=to(b,'"');c=Ck(c);return[b,c]}function to(a,b){var c=a.length;if(a.charAt(0)==b&&a.charAt(c-1)==b){return a.substring(1,c-1)}return a}function wr(a){var b=[],c="",d;for(var e=0;e<a.length;){d=Fl(a,e);if(d==","){tk(b,c);c="";e++;continue}c+=d;e+=d.length}if(c!=""||d==","){tk(b,c)}return b}var qt='"<([',Ms='">)]';function Fl(a,b){var c=a.charAt(b),d=qt.indexOf(c);if(d==-1)return c;var e=a.indexOf(Ms.charAt(d),b+1),f=e>=
0?a.substring(b,e+1):a.substr(b);return f}function tk(a,b){b=br(b);a[a.length]=b}var zt=/[()<>@,;:\\\".\[\]]/;function br(a){var b=Wm(a),c=b[0],d=b[1];if(c.indexOf('"')==-1){var e=zt.test(c);if(e){c='"'+c+'"'}}if(c=="")return d;else if(d=="")return c;else return c+" <"+d+">"}function Me(a){return typeof a!="undefined"}function Ps(a){return document.getElementById(a)}function Qs(a){return document.all[a]}var eb=document.getElementById?Ps:Qs;function Rh(a){Oa(a,"func passed to GetFnName() is undefined");
var b;if(!("name"in a)){var c=/\W*function\s+([\w\$]+)\(/.exec(a);if(!c){throw new Error("Cannot extract name from function: "+a);}b=c[1];a.name=b}else{b=a.name}if(!b||b=="anonymous"){throw new Error("Anonymous function has no name: "+a);}return a.name}function Sq(a){try{if(window.parent!=window&&window.parent.log){window.parent.log(window.name+"::"+a);return}}catch(b){}var c=eb("log");if(c){var d="<p class=logentry><span class=logdate>"+new Date+"</span><span class=logmsg>"+a+"</span></p>";c.innerHTML=
d+c.innerHTML}else{window.status=a}};function Bd(a,b,c){this.x=a;this.y=b;this.coordinateFrame=c||null}Bd.prototype.toString=function(){return"[P "+this.x+","+this.y+"]"};Bd.prototype.Ca=function(){return new Bd(this.x,this.y,this.coordinateFrame)};function Wd(a,b){this.dx=a;this.dy=b}Wd.prototype.toString=function(){return"[D "+this.dx+","+this.dy+"]"};function Ic(a,b,c,d,e){this.x=a;this.y=b;this.w=c;this.h=d;this.coordinateFrame=e||null}Ic.prototype.contains=function(a){return this.x<=a.x&&a.x<this.x+this.w&&this.y<=a.y&&a.y<this.y+
this.h};Ic.prototype.Vw=function(a){var b=function(c,d){return new Bd(c,d,null)};return this.contains(b(a.x,a.y))||this.contains(b(a.x+a.w,a.y))||this.contains(b(a.x+a.w,a.y+a.h))||this.contains(b(a.x,a.y+a.h))||a.contains(b(this.x,this.y))||a.contains(b(this.x+this.w,this.y))||a.contains(b(this.x+this.w,this.y+this.h))||a.contains(b(this.x,this.y+this.h))};Ic.prototype.toString=function(){return"[R "+this.w+"x"+this.h+"+"+this.x+"+"+this.y+"]"};Ic.prototype.Ca=function(){return new Ic(this.x,this.y,
this.w,this.h,this.coordinateFrame)};function dc(a){function b(k){for(var n=a.offsetParent;n&&n.offsetParent;n=n.offsetParent){if(n.scrollLeft){k.x-=n.scrollLeft}if(n.scrollTop){k.y-=n.scrollTop}}}var c;if(a.ownerDocument&&a.ownerDocument.parentWindow){c=a.ownerDocument.parentWindow}else{c=window}if(a.ownerDocument&&a.ownerDocument.getBoxObjectFor){var d=a.ownerDocument.getBoxObjectFor(a),e=new Ic(d.x,d.y,d.width,d.height,c);b(e);return e}if(a.getBoundingClientRect){var f=a.getBoundingClientRect();return new Ic(f.left+Gl(c),f.top+Hl(c),
f.right-f.left,f.bottom-f.top,c)}var g=0,h=0;for(var i=a;i.offsetParent;i=i.offsetParent){g+=i.offsetLeft;h+=i.offsetTop}var e=new Ic(g,h,a.offsetWidth,a.offsetHeight,c);b(e);return e}function ik(a){var b=dc(a);return new Bd(b.x,b.y,b.coordinateFrame)}function vr(a,b){Oa(a,"p1 passed to Distance is undefined");Oa(b,"p2 passed to Distance is undefined");Oa(a.coordinateFrame==b.coordinateFrame);var c=a.x-b.x,d=a.y-b.y;return Math.sqrt(c*c+d*d)}function Wc(a){var b=0,c=0;if(a.pageX||a.pageY){b=a.pageX;
c=a.pageY}else if(a.clientX||a.clientY){var d=a.target?a.target:a.srcElement,e;if(d.ownerDocument&&d.ownerDocument.parentWindow){e=d.ownerDocument.parentWindow}else{e=window}b=a.clientX+Gl(e);c=a.clientY+Hl(e)}return new Bd(b,c,window)};function Xd(a){return a<0?-1:1}function Rf(a){return a|0}function Ql(a){Ke(a);throw a;}function ea(a,b){var c=a.toString();while(c.length<b){c="0"+c}return c}var Vh=[undefined,31,undefined,31,30,31,30,31,31,30,31,30,31];function Ec(a,b){if(2!==b){return Vh[b]}var c=a<<4,d=Vh[c];if(!d){d=Math.round((Date.UTC(a,2,1)-Date.UTC(a,1,1))/86400000);Vh[c]=d}return d}var Rl={};function Ar(a,b){var c=a<<4|b,d=Rl[c];if(!d){d=(new Date(a,b-1,1,0,0,0,0)).getDay();Rl[c]=d}return d}function Wh(a){return(a.o-1+Ar(a.n,
a.j))%7}function Ol(a,b,c,d,e,f){var g;if(a===d){if((g=b-e)===0){return c-f}else if(g<0){g=c-f;do{g-=Ec(a,b++)}while(b<e);return g}else{g=c-f;do{g+=Ec(d,e++)}while(e<b);return g}}else{return Math.round((Date.UTC(a,b-1,c)-Date.UTC(d,e-1,f))/86400000)}}function Pl(a,b){return Ol(a.n,a.j,a.o,b.n,b.j,b.o)}function db(a,b,c,d,e,f){if(!isNaN(a)){this.n=a}if(!isNaN(b)){this.j=b}if(!isNaN(c)){this.o=c}if(!isNaN(d)){this.ba=d}if(!isNaN(e)){this.da=e}if(!isNaN(f)){this.ea=f}}db.prototype.n=NaN;db.prototype.j=
NaN;db.prototype.o=NaN;db.prototype.ba=NaN;db.prototype.da=NaN;db.prototype.ea=NaN;db.prototype.vv=function(){return Wh(this)};db.prototype.toString=function(){if(this.Jc!==undefined)return this.Jc;this.Jc=this.ue();return this.Jc};function ud(){}ud.prototype=new db;ud.prototype.constructor=ud;function Ka(a,b,c){Oa(b&&c,"invalid date params: "+b+" "+c);db.call(this,a,b,c,NaN,NaN,NaN)}Ka.prototype=new ud;Ka.prototype.constructor=Ka;var Ll=function(){var a=new Date;return nb(a.getFullYear(),a.getMonth()+
1,a.getDate())};Ka.now=Ll;Ka.prototype.type="Date";Ka.prototype.fc=function(){return this};Ka.prototype.Tg=function(){return new ua(this.n,this.j,this.o,0,0,0)};Ka.prototype.na=function(){if(undefined===this.rb){this.rb=Th(this.n,this.j,this.o)}return this.rb};function Th(a,b,c){return(((a-1970)*12+b<<5)+c)*86400}Ka.prototype.Ye=function(){return true};Ka.prototype.ue=function(){return ea(this.n,4)+ea(this.j,2)+ea(this.o,2)};Ka.prototype.Fa=function(a){return this.constructor===a.constructor&&this.o===
a.o&&this.j===a.j&&this.n===a.n};var Of={};Ka.ou=Of;var Kl=0;Ka.dB=Kl;var Jl=200;Ka.CA=Jl;var nb=function(a,b,c){var d=Th(a,b,c);if(d in Of){return Of[d]}else{var e=new Ka(a,b,c);e.rb=d;if(Kl<Jl){Of[d]=e}return e}};Ka.create=nb;function ua(a,b,c,d,e,f){db.call(this,a,b,c,d,e,f)}ua.prototype=new ud;ua.prototype.constructor=ua;ua.now=function(){var a=new Date;return new ua(a.getFullYear(),a.getMonth()+1,a.getDate(),a.getHours(),a.getMinutes(),a.getSeconds())};ua.prototype.type="DateTime";ua.prototype.fc=
function(){return nb(this.n,this.j,this.o)};ua.prototype.Tg=function(){return this};ua.prototype.na=function(){if(undefined===this.rb){this.rb=(((((this.n-1970)*12+this.j<<5)+this.o)*24+this.ba)*60+this.da)*60+this.ea}return this.rb};ua.prototype.Ye=function(){return true};ua.prototype.ue=function(){return ea(this.n,4)+ea(this.j,2)+ea(this.o,2)+"T"+ea(this.ba,2)+ea(this.da,2)+ea(this.ea,2)};ua.prototype.Fa=function(a){return this.constructor===a.constructor&&this.o===a.o&&this.j===a.j&&this.n===a.n&&
this.ba===a.ba&&this.da===a.da&&this.ea===a.ea};ua.prototype.Ca=function(){var a=new ua(this.n,this.j,this.o,this.ba,this.da,this.ea);if(this.Jc!==undefined)a.Jc=this.Jc;return a};function vd(a,b,c){db.call(this,NaN,NaN,NaN,a,b,c)}vd.prototype=new db;vd.prototype.constructor=vd;vd.prototype.type="Time";vd.prototype.ue=function(){return"T"+ea(this.ba,2)+ea(this.da,2)+ea(this.ea,2)};vd.prototype.Fa=function(a){return this.constructor===a.constructor&&this.ba===a.ba&&this.da===a.da&&this.ea===a.ea};
vd.prototype.na=function(){return(this.ba*60+this.da)*60+this.ea};function Dc(a,b,c,d){var e=d+60*(c+60*(b+24*a)),f=Rf(e/86400);e-=f*86400;var g=Rf(e/3600);e-=g*3600;var h=Rf(e/60);e-=h*60;var i=Rf(e);db.call(this,NaN,NaN,f,g,h,i)}Dc.prototype=new db;Dc.prototype.constructor=Dc;Dc.prototype.type="Duration";Dc.prototype.na=function(){if(undefined===this.rb){this.rb=((this.o*24+this.ba)*60+this.da)*60+this.ea}return this.rb};Dc.prototype.ue=function(){var a=this.n?Xd(this.n):(this.j?Xd(this.j):(this.o?
Xd(this.o):(this.ba?Xd(this.ba):(this.da?Xd(this.da):(this.ea?Xd(this.ea):0))))),b=a<0?"-P":"P";if(this.n){b+=a*this.n+"Y"}if(this.j){b+=a*this.j+"N"}if(this.o){b+=this.o%7?a*this.o+"D":a*this.o/7+"W"}if(this.ba||this.da||this.ea){b+="T"}if(this.ba){b+=a*this.ba+"H"}if(this.da){b+=a*this.da+"M"}if(this.ea){b+=a*this.ea+"S"}if(!a){b+="0D"}return b};Dc.prototype.Fa=function(a){return this.constructor===a.constructor&&this.o===a.o&&this.ba===a.ba&&this.da===a.da&&this.ea===a.ea};function Cf(a){Rc(a,
db);var b=new ta;b.n=a.n||0;b.j=a.j||0;b.o=a.o||0;b.ba=a.ba||0;b.da=a.da||0;b.ea=a.ea||0;return b}function uh(a,b,c){Oa(!(isNaN(a)|isNaN(b)|isNaN(c)));var d=new ta;d.n=a||0;d.j=b||0;d.o=c||0;return d}function ta(){}ta.prototype=new db;ta.prototype.constructor=ta;ta.prototype.type="DTBuilder";ta.prototype.n=(ta.prototype.j=(ta.prototype.o=(ta.prototype.ba=(ta.prototype.da=(ta.prototype.ea=0)))));ta.prototype.na=function(){this.normalize();var a;if(isNaN(this.ba)){a=Th(this.n,this.j,this.o)}else{a=
(((((this.n-1970)*12+this.j<<5)+this.o)*24+this.ba)*60+this.da)*60+this.ea}return a};ta.prototype.cu=function(a){if(a.o){this.o+=a.o}if(a.ba){this.ba+=a.ba}if(a.da){this.da+=a.da}if(a.ea){this.ea+=a.ea}};ta.prototype.normalize=function(){this.Px();this.Kk();var a=Ec(this.n,this.j);while(this.o<1){this.j-=1;this.Kk();a=Ec(this.n,this.j);this.o+=a}while(this.o>a){this.o-=a;this.j+=1;this.Kk();a=Ec(this.n,this.j)}};ta.prototype.Px=function(){var a;if(this.ea<0){a=Math.ceil(this.ea/-60);this.ea+=60*a;
this.da-=a}else if(this.ea>=60){a=Math.floor(this.ea/60);this.ea-=60*a;this.da+=a}if(this.da<0){a=Math.ceil(this.da/-60);this.da+=60*a;this.ba-=a}else if(this.da>=60){a=Math.floor(this.da/60);this.da-=60*a;this.ba+=a}if(this.ba<0){a=Math.ceil(this.ba/-24);this.ba+=24*a;this.o-=a}else if(this.ba>=24){a=Math.floor(this.ba/24);this.ba-=24*a;this.o+=a}};ta.prototype.Kk=function(){var a;if(this.j<1){a=Math.ceil((this.j-1)/-12);this.j+=12*a;this.n-=a}else if(this.j>12){a=Math.floor((this.j-1)/12);this.j-=
12*a;this.n+=a}};ta.prototype.fc=function(){this.normalize();return nb(this.n,this.j,this.o)};ta.prototype.Tg=function(){this.normalize();return new ua(this.n,this.j,this.o,this.ba,this.da,this.ea)};ta.prototype.dA=function(){if(this.n||this.j){Ql("Can't convert months or years to ICAL_Duration");return undefined}else{return new Dc(this.o,this.ba,this.da,this.ea)}};ta.prototype.toString=function(){return"["+(undefined!==this.n?ea(this.n,4):"????")+"/"+(undefined!==this.j?ea(this.j,2):"??")+"/"+(undefined!==
this.o?ea(this.o,2):"??")+" "+(undefined!==this.ba?ea(this.ba,2):"??")+" "+(undefined!==this.da?ea(this.da,2):"??")+" "+(undefined!==this.ea?ea(this.ea,2):"??")+"]"};ta.prototype.Fa=function(a){return this.constructor===a.constructor&&this.o===a.o&&this.j===a.j&&this.n===a.n&&this.ba===a.ba&&this.da===a.da&&this.ea===a.ea};function Pf(a,b){Oa(a instanceof ua||a instanceof Ka);this.start=a;if(b.constructor==Dc){var c=Cf(a);c.cu(b);this.end=this.start instanceof ua?c.Tg():c.fc()}else{vk(b.constructor,
a.constructor);this.end=b}this.duration=Ml(this.end,this.start)}Pf.prototype.type="PeriodOfTime";Pf.prototype.toString=function(){if(this.Jc!==undefined)return this.Jc;this.Jc=this.start+"/"+this.end;return this.Jc};Pf.prototype.Fa=function(a){return this.constructor===a.constructor&&this.start.Fa(a.start)&&this.end.Fa(a.end)};Pf.prototype.contains=function(a){return this.start.na()<=a.start.na()&&this.end.na()>=a.end.na()};function Uh(a,b){Oa(a instanceof gc||a instanceof fc);this.start=a;vk(b.constructor,
a.constructor);this.end=b;try{this.duration=Ml(this.end,this.start)}catch(c){this.duration=null}}Uh.prototype.type="PartialPeriodOfTime";Uh.prototype.ue=function(){return this.start+"/"+this.end};Uh.prototype.Fa=function(a){return this.constructor===a.constructor&&this.start.Fa(a.start)&&this.end.Fa(a.end)};function Ml(a,b){if(isNaN(a.n)!=isNaN(b.n)||isNaN(a.ba)!=isNaN(b.ba)){Ql("diff("+a+", "+b+")");return undefined}var c=Cf(a);if(isNaN(a.n)){c.ba-=b.ba;c.da-=b.da;c.ea-=b.ea}else{c.n=NaN;c.j=NaN;
c.o=Ol(a.n,a.j,a.o,b.n,b.j,b.o);if(!isNaN(a.ba)){c.ba-=b.ba;c.da-=b.da;c.ea-=b.ea}}return c.dA()}function fc(a,b,c){this.n=a;this.j=b;this.o=c}fc.prototype=new ud;fc.prototype.constructor=fc;fc.prototype.type="PartialDate";fc.prototype.fc=function(){return nb(this.n||0,this.j||1,this.o||1)};fc.prototype.Tg=function(){return new ua(this.n||0,this.j||1,this.o||1,0,0,0)};fc.prototype.Ye=function(){return!isNaN(this.na())};fc.prototype.na=function(){if(undefined===this.rb){this.rb=(((this.n-1970)*12+
this.j<<5)+this.o)*86400}return this.rb};fc.prototype.Fa=function(a){return this.constructor===a.constructor&&(this.o===a.o||isNaN(this.o)&&isNaN(a.o))&&(this.j===a.j||isNaN(this.j)&&isNaN(a.j))&&(this.n===a.n||isNaN(this.n)&&isNaN(a.n))};fc.prototype.ue=function(){return(undefined!==this.n?ea(this.n,4):"????")+(undefined!==this.j?ea(this.j,2):"??")+(undefined!==this.o?ea(this.o,2):"??")};function gc(a,b,c,d,e,f){this.n=a;this.j=b;this.o=c;this.ba=d;this.da=e;this.ea=f}gc.prototype=new ud;gc.prototype.constructor=
gc;gc.prototype.type="PartialDateTime";gc.prototype.fc=function(){return nb(this.n||0,this.j||1,this.o||1)};gc.prototype.Tg=function(){return new ua(this.n||0,this.j||1,this.o||1,this.ba||0,this.da||0,this.ea||0)};gc.prototype.Ye=function(){return!isNaN(this.na())};gc.prototype.na=function(){if(undefined===this.rb){this.rb=(((((this.n-1970)*12+this.j<<5)+this.o)*24+this.ba)*60+this.da)*60+this.ea}return this.rb};gc.prototype.Fa=function(a){return this.constructor===a.constructor&&(this.o===a.o||isNaN(this.o)&&
isNaN(a.o))&&(this.j===a.j||isNaN(this.j)&&isNaN(a.j))&&(this.n===a.n||isNaN(this.n)&&isNaN(a.n))&&(this.ba===a.ba||isNaN(this.ba)&&isNaN(a.ba))&&(this.da===a.da||isNaN(this.da)&&isNaN(a.da))&&(this.ea===a.ea||isNaN(this.ea)&&isNaN(a.ea))};gc.prototype.ue=function(){return(undefined!==this.n?ea(this.n,4):"????")+(undefined!==this.j?ea(this.j,2):"??")+(undefined!==this.o?ea(this.o,2):"??")+"T"+(undefined!==this.ba?ea(this.ba,2):"??")+(undefined!==this.da?ea(this.da,2):"??")+(undefined!==this.ea?ea(this.ea,
2):"??")};var Qf=undefined,Sl=[];function zr(a,b,c){var d=b>2&&29===Ec(a,2);return Nl[b]+d+c-1}var Nl=[undefined,0,31,59,90,120,151,181,212,243,273,304,334];zr.DA=Nl;function Uq(){var a=new Date,b=Qf;Qf=nb(a.getFullYear(),a.getMonth()+1,a.getDate());if(b&&!b.Fa(Qf)){for(var c=0;c<Sl.length;++c){var d=Sl[c];try{d(Qf)}catch(e){}}}var f=new Date(a.getFullYear(),a.getMonth(),a.getDate(),0,0,0,0);f.setDate(f.getDate()+1);var g=f.getTime()-a.getTime();if(g<0||g>=1800000){g=1800000}window.setTimeout(Uq,
g)}Uq();Function.prototype.p=function(a){if(typeof this!="function"){throw new Error("Bind must be called as a method of a function object.");}var b=this,c=Array.prototype.splice.call(arguments,1,arguments.length);return function(){var d=c.concat();for(var e=0;e<arguments.length;e++){d.push(arguments[e])}return b.apply(a,d)}};var Pc,Rd;(function(){var a={},b=0;function c(f){if(f.Cp==null){f.Cp=++b}return f.Cp}function d(f,g,h,i){var k=c(f),n=c(h);i=!(!i);var s=k+"_"+g+"_"+n+"_"+i;return s}Pc=function(f,g,h,i){var k=d(f,g,h,i);if(k in a){return k}var n=e.p(null,k);a[k]={listener:h,proxy:n};if(f.addEventListener){f.addEventListener(g,n,i)}else if(f.attachEvent){f.attachEvent("on"+g,n)}else{throw new Error("Node {"+f+"} does not support event listeners.");}return k};Rd=function(f,g,h,i){var k=d(f,g,h,i);if(!(k in a)){return false}var n=
a[k].proxy;if(f.removeEventListener){f.removeEventListener(g,n,i)}else if(f.detachEvent){f.detachEvent("on"+g,n)}delete a[k];return true};function e(f){var g=Array.prototype.splice.call(arguments,1,arguments.length);return a[f].listener.apply(null,g)}})();function gr(a){return function(b,c,d,e){var f=dc(c),g=ik(c.offsetParent),h;switch(d){case 1:if(undefined!==e){if(da&1){f.x+=e.dx}if(da&2){f.y+=e.dy}}h=a(f);if(!h){return false}if(da&1){if(undefined!==e){e.dx+=h.x-f.x+g.x}else{c.style.left=h.x+"px"}}if(da&2){if(undefined!==e){e.dy+=h.y-f.y+g.y}else{c.style.top=h.y+"px"}}break;case 2:if(undefined!==e){if(da&1){f.w+=e.dx}if(da&2){f.h+=e.dy}}if(undefined===e){var i=new Bd(f.x+f.w,f.y+f.h,window);h=a(i);if(!h){return false}if(da&1){var k=h.x-c.offsetLeft;
if(k<=0){return false}c.style.width=k+"px"}if(da&2){var n=h.y-c.offsetTop;if(n<=0){return false}c.style.height=n+"px"}}break;case 5:if(e){var h=a(Da);if(!h){return false}if(da&1){if(Da.x-h.x<h.w/2){e.dx-=h.x-Da.x}else{e.dx-=h.x+h.w-Da.x}}if(da&2){if(Da.y-h.y<h.h/2){e.dy-=h.y-Da.y}else{e.dy-=h.y+h.h-Da.y}}}break}return true}}var ir=2*Math.PI/16,r=undefined,ka=0,nc=undefined,Da=undefined,Ye=undefined,ge=undefined,ad=undefined,da=undefined,Sb=undefined,$c=undefined,Bo=false,rg=undefined,Eb=undefined;
function _DD_Install(a){if(!a){a=document}Eb=a;Pc(Eb.body,"mousedown",jr)}var Pi=[];function lr(a){Pi.push(a)}function Jk(a,b){for(var c=Pi.length-1;c>=0;--c){var d=Pi[c](a,b);if(d){return d}}return undefined}var fe;function jr(a){fe=Bk(a||window.event);Pc(Eb.body,"mousemove",Gh);Pc(Eb.body,"mouseup",Hh);return false}function kr(a){var b=undefined;for(var c=a.srcElement||a.target;c;c=c.parentNode){b=Jk(c,a);if(!b)continue;Da=Wc(a);if(b.Pg(a,c)){if(!(r&&ka>=0&&ka<6&&1===1+ka%1&&da&&0===(da&-4))){var d=
"Bogus drag: el="+r+", type="+ka+", axis mask="+da;If();jk(d)}a.cancelBubble=true;nc=b;Ye=Da;ge={x:r.offsetLeft,y:r.offsetTop,w:r.offsetWidth,h:r.offsetHeight};if(ka===4){ad=[Da]}Sb=new Wd(0,0);$c=new Wd(0,0);if(ka===1||ka===2||ka===5){if(ka!==2&&nc.useUserDefinedAlpha&&!nc.useUserDefinedAlpha()){Gk(r,true)}rg=r.style.zIndex;r.style.zIndex=2000}if(Sd()){Pc(Eb.body,"mouseleave",Jf)}else{Pc(Eb.body,"mouseout",Jf)}}else{If()}return false}return true}function Hh(a){if(fe){fe=null;Rd(Eb.body,"mousemove",
Gh);Rd(Eb.body,"mouseup",Hh);var b=undefined;for(var c=a.srcElement||a.target;c;c=c.parentNode){b=Jk(c,a);if(b&&b.handleClick){b.handleClick(c,a);return false}}return}var d=a||Eb.parentWindow.event;if(!nc.Ih(d,r,ka)){Hf()}else{If()}}function Gh(a){if(fe){var b=kr(fe);fe=null;if(b){Hf();return true}}if(!r){return true}if(!nc){return true}var c=a||Eb.parentWindow.event;c.cancelBubble=true;var d=Wc(c),e=new Wd(d.x-Da.x+Sb.dx,d.y-Da.y+Sb.dy);if(!(e.dx|e.dy)){return false}var f=new Wd(e.dx,e.dy);Da=d;
Bo=true;var g=ik(r);if(da&1){$c.dx+=f.dx}if(da&2){$c.dy+=f.dy}if(nc.Te(c,r,ka,f,$c)){var h=ik(r);$c.dx-=h.x-g.x;$c.dy-=h.y-g.y;switch(ka){case 1:case 2:case 5:Sb.dx=e.dx-f.dx;Sb.dy=e.dy-f.dy;break}switch(ka){case 1:if(!(da&1)){f.dx=0}if(!(da&2)){f.dy=0}var i=r.currentStyle?r.currentStyle:r.ownerDocument.defaultView.getComputedStyle(r,"");if(i&&i.position=="relative"){r.style.left=$c.dx+"px";r.style.top=$c.dy+"px"}else{var k=r.offsetLeft+f.dx,n=r.offsetTop+f.dy;if(f.dx){r.style.left=k+"px"}if(f.dy){r.style.top=
n+"px"}if(f.dx&&k!==r.offsetLeft){r.style.left=k+k-r.offsetLeft+"px"}if(f.dy&&n!==r.offsetTop){r.style.top=n+n-r.offsetTop+"px"}}break;case 5:var s=dc(r);if(da&1){var u=Da.x+Sb.dx,z=Math.min(u,Ye.x),v=Math.abs(u-Ye.x);if(z!==s.x){var k=z;r.style.left=k+"px";if(k!==r.offsetLeft){r.style.left=k+k-r.offsetLeft+"px"}}if(v!==s.w){r.style.width=v+"px";if(v!=r.offsetWidth){v=Math.max(0,v+v-r.offsetWidth);r.style.width=v+"px"}}}if(da&2){var A=Da.y+Sb.dy,T=Math.min(A,Ye.y),J=Math.abs(A-Ye.y);if(T!==s.y){var n=
T;r.style.top=n+"px";if(n!==r.offsetTop){r.style.top=n+n-r.offsetTop+"px"}}if(J!==s.h){r.style.height=J+"px";if(J!=r.offsetHeight){J=Math.max(0,J+J-r.offsetHeight);r.style.height=J+"px"}}}break;case 2:if(f.dx&&da&1){var hc=r.offsetWidth,v=hc+f.dx;if(v<0){Sb.dx+=v;v=0}if(v<1){Sb.dx+=v-1;v=1}r.style.width=v+"px";if(v!=r.offsetWidth){v+=v-r.offsetWidth;if(v<1){v=1}r.style.width=v+"px"}}if(f.dy&&da&2){var Fc=r.offsetHeight,J=Fc+f.dy;if(J<0){Sb.dy+=J;J=0}if(J<1){Sb.dy+=J-1;J=1}r.style.height=J+"px";if(J!=
r.offsetHeight){J+=J-r.offsetHeight;if(J<1){J=1}r.style.height=J+"px"}}break;case 3:if(!(da&1)){f.dx=0}if(!(da&2)){f.dy=0}if(r.scrollBy){r.scrollBy(f.dx,f.dy)}else{f.dx*=-1;f.dy*=-1;var Ba=r.scrollLeft,Xh=r.scrollLeft+r.scrollWidth-r.offsetWidth,ic=r.scrollTop,Tf=r.scrollTop+r.scrollHeight-r.offsetHeight;f.dx=Math.max(Math.min(f.dx,Xh),-Ba);f.dy=Math.max(Math.min(f.dy,Tf),-ic);if(f.dx){r.scrollLeft=r.scrollLeft+f.dx}if(f.dy){r.scrollTop=r.scrollTop+f.dy}}break;case 4:if(f.dx|f.dy){if(ad.length>=1){var wd=
f,Gc=ad[ad.length-1],Qb=new Wd(wd.dx+Gc.dx,wd.dy+Gc.dy),xd=false;if(Qb.dx*Qb.dx+Qb.dy*Qb.dy<=25){xd=true}else{var Uf=Math.atan2(wd.dx,wd.dy),Ne=Math.atan2(Gc.dx,Gc.dy),Vf=Math.abs((Uf-Ne+2*Math.PI)%(2*Math.PI));xd=Vf<ir}if(xd){Gc.dx=Qb.dx;Gc.dy=Qb.dy}else{ad.push(f)}}else{ad.push(f)}Kk(ad)}break}}else{Hf()}return false}function Jf(a){a=a||window.event;var b=a.relatedTarget||a.toElement;if(!b){Hf()}}function If(){if(ka!==0){if(r){if(ka===4){Kk([])}nc.bv(r,ka)}if(ka===1||ka===2||ka===5){if(ka!==2&&
nc.useUserDefinedAlpha&&!nc.useUserDefinedAlpha()){Gk(r,false)}if(undefined!==rg){r.style.zIndex=rg;rg=undefined}else{delete r.style.zIndex}}}r=undefined;ka=0;Da=undefined;ge=undefined;da=0;Sb=undefined;Bo=false;if(nc){if(Sd()){Rd(Eb.body,"mouseleave",Jf)}else{Rd(Eb.body,"mouseout",Jf)}}nc=undefined;Rd(Eb.body,"mousemove",Gh);Rd(Eb.body,"mouseup",Hh)}function Hf(){switch(ka){case 1:var a=r.currentStyle?r.currentStyle:window.getComputedStyle(r,"");if(a&&a.position=="relative"){r.style.left="0px";r.style.top=
"0px"}else{r.style.left=ge.x+"px";r.style.top=ge.y+"px"}break;case 2:r.style.width=ge.w+"px";r.style.height=ge.h+"px";break;case 3:break;case 4:ad=[];break;case 0:break;case 5:break;default:jk("failed to cancel drag with dd_dragType="+ka)}If()}function Gk(a,b){if(Sd()){a.style.filter=b?"alpha(opacity=50)":"alpha(opacity=100)"}else{a.style.MozOpacity=b?0.5:1}}var Qi=false,Ri=undefined;function Kk(a){Ri=a;if(!Qi){Qi=true;window.setTimeout(hr,100)}}function hr(){var a=Ri;Ri=undefined;Qi=false;if(!a){return}var b=
"";if(a.length){var c=a[0].x,d=a[0].y,e=0,f=0;for(var g=1;g<a.length;g++){var h=a[g];if(!(h.dx|h.dy)){continue}if(g!=0){b+="<img class=gestimg src=images/joiner.png width=5 height=5 style=left:"+(c-2)+"px;top:"+(d-2)+"px>"}var i=Math.atan2(h.dx,h.dy),k,n=Math.floor(i/(Math.PI/6));switch(n){case 0:case 6:case -6:k="vert.png";break;case 1:case -4:k="negslope.png";break;case 2:case -2:case 3:case -3:k="horz.png";break;case 4:case -1:k="posslope.png";break;case 5:case -5:k="vert.png";break}var s=Math.max(1,
Math.abs(h.dx)),u=Math.max(1,Math.abs(h.dy));b+="<img class=gestimg src=images/"+k+" width="+s+" height="+u+" style=left:"+(c+Math.min(h.dx,0))+"px;top:"+(d+Math.min(h.dy,0))+"px>";c+=h.dx;d+=h.dy;e=Math.max(c,e);f=Math.max(d,f)}}var z=eb("gesture");z.style.display="none";z.innerHTML=b;z.style.display="inline"}function Gs(){}Gs.prototype.Te=function(a,b,c,d,e){throw new Error("Unimplemented");};function Va(a){this.Qq=a;this.Tq=a?Va.getSelection(a):undefined;this.co=false;this.hx=null;this.oj=3}Va.getSelection=function(a,b){b=b||[];if(a.className&&a.className.match(/\bddSelected\b/)){b.push(a)}else{for(var c=a.firstChild;c;c=c.nextSibling){Va.getSelection(c,b)}}return b};Va.clearSelection=function(a){var b=Va.getSelection(a);for(var c=b.length;--c>=0;){var d=b[c];d.className=d.className.replace(/\s*\bddSelected\b/g,"")}return b};Va.prototype.Ow=function(a,b){a.style.left=b.x+"px";a.style.top=
b.y+"px";if(this.oj&1){a.style.width="0px"}if(this.oj&2){a.style.height="0px"}};Va.prototype.Pw=function(a){a.style.display="block"};var Ik=function(a,b){var c=eb("ddLasso");if(!c){c=document.createElement("div");c.id="ddLasso";c.style.position="absolute";c.style.display="none";document.body.appendChild(c)}var d=Wc(a);this.Ow(c,d);this.Pw(c);ka=5;da=this.oj;r=c;this.hx=c;var e=this;window.setTimeout(function(){if(!e.finished){e.yj(c)}},200);return true};Va.prototype.Pg=Ik;Va.prototype.Ih=function(a,
b,c){return true};Va.prototype.gx=function(a){return a.className&&a.className.match(/\bddSelectable\b/)};Va.prototype.un=function(a,b,c){if(this.gx(a)){var d=dc(a);if(!(b.x+b.w<d.x||d.x+d.w<b.x||b.y+b.h<d.y||d.y+d.h<b.y)){c.push(a)}return}else{for(var e=a.firstChild;e;e=e.nextSibling){this.un(e,b,c)}}};Va.prototype.yj=function(a){if(!this.Qq)return;var b=[];this.un(this.Qq,dc(a),b);this.rf(b);if(!this.co){var c=this;window.setTimeout(function(){if(!c.finished){c.yj(a)}},200)}};Va.prototype.rf=function(a){var b=
this.Tq;for(var c=a.length;--c>=0;){a[c].dd_newSelection=true}for(var c=b.length;--c>=0;){var d=b[c];d.dd_oldSelection=true;if(!d.dd_newSelection){d.className=d.className.replace(/\s*\bddSelected\b/g,"")}}for(var c=a.length;--c>=0;){var d=a[c];if(!d.dd_oldSelection){d.className=(d.className||" ")+" ddSelected"}d["dd_newSelection"]=false}for(var c=b.length;--c>=0;){b[c].dd_oldSelection=false}this.Tq=a};var Hk=function(a,b,c,d){return true};Va.prototype.Te=Hk;Va.prototype.bv=function(a,b){this.co=true;
this.yj(a);a.style.display="none"};function Ge(a,b){Va.call(this,a);this.Lz=gr(b);this.gridFn=b}Ge.prototype=new Va(undefined);Ge.prototype.constructor=Ge;Ge.prototype.Te=function(a,b,c,d){return Hk(a,b,c,d)&&this.Lz(a,b,c,d)};Ge.prototype.Pg=function(a,b){if(Ik.call(this,a,b)){var c=this.gridFn(Da,true);if(da&1){Da.x=Da.x-c.x<c.w>>1?c.x:c.x+c.w}if(da&2){Da.y=Da.y-c.y<c.h>>1?c.y:c.y+c.h}return true}else{return false}};function Es(){this.Ld=[]}function _PC_Install(a){if(Do)return false;Do=true;var b=a?a:document;Pc(b.body,"mousedown",Bs);return true}function Bs(a){if(Dd.Ld.length==0)return false;var a=a||window.event;for(var b=Dd.Ld.length-1;b>=0;--b){var c=Dd.Ld[b];Rm(c);if(c.Fj(a)){Dd.Ld.splice(b,1)}}return true}function As(a){Rm(a);for(var b=0;b<Dd.Ld.length;++b){if(a===Dd.Ld[b])return false}Dd.Ld.push(a);return true}function Rm(a){Rc(a.Fj,Function,"popup missing deactivate function")}var Dd=new Es,Do=false;var E={};E.parse=function(a,b,c,d,e){return Ie(a,e)(b,c,d)};var kl=function(a){return E.symbols=a};E.loadLocaleSymbols=kl;E.FULL_FORMAT=0;E.LONG_FORMAT=1;var cl=2;E.MEDIUM_FORMAT=cl;E.SHORT_FORMAT=3;E.DEFAULT_FORMAT=cl;var ll=function(a,b,c,d,e){return fl(a,e)(b,c,d)};E.parseDate=ll;var fl=function(a,b){b=Je(b);return Ie(b.DATEFORMATS[a],b)};E.getDateParser=fl;E.parseTime=function(a,b,c,d,e){return il(a,e)(b,c,d)};var il=function(a,b){b=Je(b);return Ie(b.TIMEFORMATS[a],b)};E.getTimeParser=il;E.parseDateTime=
function(a,b,c,d,e){return gl(a,e)(b,c,d)};var gl=function(a,b){b=Je(b);return Ie(b.DATEFORMATS[a]+" "+b.TIMEFORMATS[a],b)};E.getDateTimeParser=gl;var Ie=function(a,b){b=Je(b);var c=[];ml(a,c);return function(d,e,f){var g=new si,h=[e],i=-1,k=0,n=0;for(var s=0;s<c.length;++s){if(c[s].count>0){if(i<0&&c[s].abutStart){i=s;k=e;n=0}if(i>=0){var u=c[s].count;if(s==i){u-=n;n++;if(u==0){return 0}}if(!Ph(d,h,c[s],u,g)){s=i-1;h[0]=k;continue}}else{i=-1;if(!Ph(d,h,c[s],0,g)){return 0}}}else{i=-1;if(c[s].text.charAt(0)==
" "){var z=h[0];Oh(d,h);if(h[0]>z){continue}}else if(d.indexOf(c[s].text,h[0])==h[0]){h[0]+=c[s].text.length;continue}return 0}}if(!g.pu(f)){return 0}return h[0]-e}};E.parser=Ie;var Je=function(a){if(!a){if(!E.symbols){E.symbols=mb}a=E.symbols}return a};E.Ly=Je;var hl=function(a,b){var c=a.charAt(b),d=b+1;while(d<a.length&&a.charAt(d)==c){++d}return d-b};E.VB=hl;var el="GyMdkHmsSEDahKzZv";E.FA=el;var dl="MydhHmsSDkK";E.EA=dl;var Lf=function(a){if(a.count<=0){return false}var b=dl.indexOf(a.text.charAt(0));
return b>0||b==0&&a.count<3};E.nC=Lf;var jl=function(a){var b=false;for(var c=0;c<a.length;c++){if(Lf(a[c])){if(!b&&c+1<a.length&&Lf(a[c+1])){b=true;a[c].abutStart=true}}else{b=false}}};E.fC=jl;var ml=function(a,b){var c=false,d="";for(var e=0;e<a.length;e++){var f=a.charAt(e);if(f==" "){if(d.length>0){b.push({text:d,count:0,abutStart:false});d=""}b.push({text:" ",count:0,abutStart:false});while(e+1<a.length&&a.charAt(e+1)==" "){e++}continue}if(c){if(f=="'"){if(e+1<a.length&&a.charAt(e+1)=="'"){d+=
f;++e}else{c=false}}else{d+=f}continue}if(el.indexOf(f)>=0){if(d.length>0){b.push({text:d,count:0,abutStart:false});d=""}var g=hl(a,e);b.push({text:f,count:g,abutStart:false});e+=g-1;continue}if(f=="'"){if(e+1<a.length&&a.charAt(e+1)=="'"){d+="'";e++}else{c=true}}else{d+=f}}if(d.length>0){b.push({text:d,count:0,abutStart:false})}jl(b)};E.LC=ml;var Oh=function(a,b){var c=a.substring(b[0]).match(/^\s+/);if(c){b[0]+=c[0].length}};E.eD=Oh;var Mh="GMT";E.xA=Mh;var Ph=function(a,b,c,d,e){Oh(a,b);var f=
b[0],g=c.text.charAt(0),h=-1;if(Lf(c)){if(d>0){if(f+d>a.length){return false}h=Vd(a.substring(0,f+d),b)}else{h=Vd(a,b)}}switch(g){case "G":e.era=td(a,b,E.symbols.ERAS);return true;case "M":return pl(a,b,e,h);case "E":return nl(a,b,e);case "a":e.ampm=td(a,b,E.symbols.AMPMS);return true;case "y":return ql(a,b,f,h,c,e);case "d":e.day=h;return true;case "S":return ol(h,b,f,e);case "h":if(h==12){h=0}case "K":case "H":case "k":e.hours=h;return true;case "m":e.minutes=h;return true;case "s":e.seconds=h;
return true;case "z":case "Z":case "v":return rl(a,b,e);default:return false}};E.lD=Ph;var ql=function(a,b,c,d,e,f){var g;if(d<0){g=a.charAt(b[0]);if(g!="+"&&g!="-"){return false}b[0]++;d=Vd(a,b);if(d<0){return false}if(g=="-"){d=-d}}if(g==null&&b[0]-c==2&&e.count==2){f.Az(d)}else{f.n=d}return true};E.kD=ql;var pl=function(a,b,c,d){if(d<0){d=td(a,b,E.symbols.MONTHS);if(d<0){d=td(a,b,E.symbols.SHORTMONTHS)}if(d<0){return false}c.j=d;return true}else{c.j=d-1;return true}};E.jD=pl;var nl=function(a,
b,c){var d;d=td(a,b,E.symbols.WEEKDAYS);if(d<0){d=td(a,b,E.symbols.SHORTWEEKDAYS)}if(d<0){return false}c.dayOfWeek=d;return true};E.hD=nl;var ol=function(a,b,c,d){var e=b[0]-c;if(e<3){while(e<3){a*=10;e++}}else{var f=1;while(e>3){f*=10;e--}a=(a+(f>>1))/f}d.milliseconds=a;return true};E.iD=ol;var rl=function(a,b,c){if(a.indexOf(Mh,b[0])==b[0]){b[0]+=Mh.length;return Nh(a,b,c)}return Nh(a,b,c)};E.mD=rl;var Nh=function(a,b,c){if(b[0]>=a.length){c.tzOffset=0;return true}var d=1;switch(a.charAt(b[0])){case "-":d=
-1;case "+":b[0]++;break}var e=b[0],f=Vd(a,b);if(f==0&&b[0]==e){return false}var g;if(b[0]<a.length&&a.charAt(b[0])==":"){g=f*60;b[0]++;e=b[0];f=Vd(a,b);if(f==0&&b[0]==e){return false}g+=f}else{g=f;if(g<24&&b[0]-e<=2)g*=60;else g=g%100+g/100*60}g*=d;c.tzOffset=-g;return true};E.MC=Nh;var Vd=function(a,b){var c=a.substring(b[0]).match(/^\d+/);if(!c){return-1}b[0]+=c[0].length;return parseInt(c[0],10)};E.KC=Vd;var td=function(a,b,c){var d=c.length,e=0,f=-1,g=a.substring(b[0]).toLowerCase();for(var h=
0;h<d;++h){var i=c[h].length;if(i>e&&g.indexOf(c[h].toLowerCase())==0){f=h;e=i}}if(f>=0){b[0]+=e}return f};E.BC=td;function si(){}si.prototype.Az=function(a){var b=new Date,c=b.getFullYear()-80,d=c%100;this.ambiguousYear=a==d;a+=Math.floor(c/100)*100+(a<d?100:0);return this.n=a};si.prototype.pu=function(a){if(this.era!==undefined&&this.n!==undefined&&this.era==0&&this.n>0){this.n=-(this.n-1)}if(this.n!==undefined){a.setFullYear(this.n)}var b=a.getDate();a.setDate(1);if(this.j!==undefined){a.setMonth(this.j)}if(this.day!==
undefined){a.setDate(this.day)}else{a.setDate(b)}if(this.hours===undefined){this.hours=a.getHours()}if(this.ampm!==undefined&&this.ampm>0){if(this.hours<12){this.hours+=12}}a.setHours(this.hours);if(this.minutes!==undefined){a.setMinutes(this.minutes)}if(this.seconds!==undefined){a.setSeconds(this.seconds)}if(this.milliseconds!==undefined){a.setMilliseconds(this.milliseconds)}if(this.tzOffset!==undefined){var c=a.getTimezoneOffset();a.setTime(a.getTime()+(this.tzOffset-c)*60*1000)}if(this.ambiguousYear){var d=
new Date;d.setFullYear(d.getFullYear()-80);if(a.getTime()<d.getTime()){a.setFullYear(d.getFullYear()+100)}}if(this.dayOfWeek!==undefined){if(this.day==undefined){var e=(7+this.dayOfWeek-a.getDay())%7;if(e>3){e-=7}var f=a.getMonth();a.setDate(a.getDate()+e);if(a.getMonth()!=f){a.setDate(a.getDate()+(e>0?-7:7))}}else if(this.dayOfWeek!=a.getDay()){return false}}return true};var G={},mb;function tt(a,b){mb=a}var sd=function(a,b,c){return He(a,c)(b,c)};G.format=sd;var Lh=function(a){G.symbols=a};G.loadLocaleSymbols=Lh;G.FULL_FORMAT=0;G.LONG_FORMAT=1;G.MEDIUM_FORMAT=2;G.SHORT_FORMAT=3;G.DEFAULT_FORMAT=2;G.Jh=function(a,b,c){c=Uc(c);return sd(c.DATEFORMATS[a],b,c)};G.getDateFormatter=function(a,b){b=Uc(b);return He(b.DATEFORMATS[a],b)};G.formatTime=function(a,b,c){c=Uc(c);return sd(c.TIMEFORMATS[a],b,c)};G.getTimeFormatter=function(a,b){b=Uc(b);return He(b.TIMEFORMATS[a],
b)};G.formatDateTime=function(a,b,c){c=Uc(c);return sd(c.DATEFORMATS[a]+" "+c.TIMEFORMATS[a],b,c)};G.getDateTimeFormatter=function(a,b){b=Uc(b);return He(b.DATEFORMATS[a]+" "+b.TIMEFORMATS[a],b)};var Jh=[/^\'(?:[^\']|\'\')*\'/,/^(?:G+|y+|M+|k+|S+|E+|a+|h+|K+|H+|c+|L+|Q+|d+|m+|s+|v+|z+|Z+)/,/^[^\'GyMkSEahKHcLQdmsvzZ]+/];G.VA=Jh;var He=function(a,b){b=Uc(b);var c=[];while(a){for(var d=0;d<Jh.length;++d){var e=a.match(Jh[d]);if(e){var f=e[0];a=a.substring(f.length);if(d==0){if(f=="''"){f="'"}else{f=
f.substring(1,f.length-1);f=f.replace(/\'\'/,"'")}}c.push({text:f,type:d});break}}}return function(g){var h="";for(var i=0;i<c.length;++i){if(1==c[i].type){var k=c[i].text,n=Uk[k.charAt(0)];h+=n(k.length,g,b)}else{h+=c[i].text}}return h}};G.formatter=He;var Kh="0000000000000000";G.XA=Kh;var Ja=function(a,b){var c=String(a);while(c.length<b){c=Kh.substring(0,Math.min(b-c.length,Kh.length))+c}return c};G.qD=Ja;var Sk=function(a,b,c){var d=b.getFullYear()>0?1:0;return a>=4?c.ERANAMES[d]:c.ERAS[d]};G.DB=
Sk;var bl=function(a,b,c){var d=b.getFullYear();if(d<0){d=-d}return a==2?Ja(d%100,2):String(d)};G.NB=bl;var Wk=function(a,b,c){var d=b.getMonth();switch(a){case 5:return c.NARROWMONTHS[d];case 4:return c.MONTHS[d];case 3:return c.SHORTMONTHS[d];default:return Ja(d+1,a)}};G.HB=Wk;var Ok=function(a,b,c){var d=b.getHours();return d==0?Ja(24,a):Ja(d,a)};G.zB=Ok;var Tk=function(a,b,c){var d=b.getTime()%1000;if(a==1){return String(Math.round(d/100))}if(a==2){d=Math.floor(d/10);return Ja(d,2)}var e=Ja(d,
3);if(a>3){e+=Ja(0,a-3)}return e};G.EB=Tk;var Rk=function(a,b,c){var d=b.getDay();return a>=4?c.WEEKDAYS[d]:c.SHORTWEEKDAYS[d]};G.CB=Rk;var Pk=function(a,b,c){return b.getHours()>=12&&b.getHours()<24?c.AMPMS[1]:c.AMPMS[0]};G.AB=Pk;var Nk=function(a,b,c){var d=b.getHours()%12;return d==0?Ja(12,a):Ja(d,a)};G.yB=Nk;var Lk=function(a,b,c){var d=b.getHours()%12;return Ja(d,a)};G.wB=Lk;var Mk=function(a,b,c){var d=b.getHours();return Ja(d,a)};G.xB=Mk;var Zk=function(a,b,c){var d=b.getDay();switch(a){case 5:return c.STANDALONENARROWWEEKDAYS[d];
case 4:return c.STANDALONEWEEKDAYS[d];case 3:return c.STANDALONESHORTWEEKDAYS[d];default:return Ja(d,1)}};G.KB=Zk;var $k=function(a,b,c){var d=b.getMonth();switch(a){case 5:return c.STANDALONENARROWMONTHS[d];case 4:return c.STANDALONEMONTHS[d];case 3:return c.STANDALONESHORTMONTHS[d];default:return Ja(d+1,a)}};G.LB=$k;var Xk=function(a,b,c){var d=Math.floor(b.getMonth()/3);return a<4?c.SHORTQUARTERS[d]:c.QUARTERS[d]};G.IB=Xk;var Qk=function(a,b,c){var d=b.getDate();return Ja(d,a)};G.BB=Qk;var Vk=
function(a,b,c){var d=b.getMinutes();return Ja(d,a)};G.GB=Vk;var Yk=function(a,b,c){var d=b.getSeconds();return Ja(d,a)};G.JB=Yk;var al=function(a,b,c){if(a<4){var d=b.getTimezoneOffset(),e="-";if(d<0){d=-d;e="+"}d=d/3*5+d%60;return e+Ja(d,4)}return Kf(a,b,c)};G.MB=al;var Kf=function(a,b,c){var d=b.getTimezoneOffset(),e="";if(d>0){e+="GMT-"}else{d=-d;e+="GMT+"}e+=Ja(d/60,2);e+=":";e+=Ja(d%60,2);return e};G.aB=Kf;var Uk={G:Sk,y:bl,M:Wk,k:Ok,S:Tk,E:Rk,a:Pk,h:Nk,K:Lk,H:Mk,c:Zk,L:$k,Q:Xk,d:Qk,m:Vk,s:Yk,
v:Kf,z:Kf,Z:al};G.FB=Uk;var Uc=function(a){if(!a){if(!G.symbols){G.symbols=mb}a=G.symbols}return a};G.Ly=Uc;var Oc=function(a){this.zk={};this.Xo=a};ca.EventHandler=Oc;Oc.la(vc);Oc.prototype.Ec=function(a,b,c,d,e){if(Ta(b)){for(var f=0;f<b.length;f++){this.Ec(a,b[f],c,d,e)}return}var g=t(a,b,c||this,d||false,e||this.Xo||this);this.zk[g]=true};Oc.prototype.Br=function(a,b,c,d,e){if(Ta(b)){for(var f=0;f<b.length;f++){this.Br(a,b[f],c,d,e)}return}var g=pe(a,b,c||this,d||false,e||this.Xo||this);Mb(g);j.object.remove(this.zk,g)};Oc.prototype.Eq=function(){Tj(this.zk,function(a,b){Mb(b)})};var Bp=function(){if(!this.Yb()){Si.call(this);
this.Eq()}};Oc.prototype.qa=Bp;Oc.prototype.$d=function(a){throw Error("EventHandler.handleEvent not impemented");};var $a={};pf.cookies=$a;var pc=function(a,b,c,d,e){if(/;=/g.test(a)){throw new Error('Invalid cookie name "'+a+'"');}if(/;/g.test(b)){throw new Error('Invalid cookie value "'+b+'"');}if(!Y(c)){c=-1}var f=e?";domain="+e:"",g=d?";path="+d:"",h;if(c<0){h=""}else if(c==0){var i=new Date(1970,1,1);h=";expires="+i.toUTCString()}else{var k=new Date((new Date).getTime()+c*1000);h=";expires="+k.toUTCString()}document.cookie=a+"="+b+f+g+h};$a.ma=pc;var bc=function(a,b){var c=a+"=",d=String(document.cookie);
for(var e=-1;(e=d.indexOf(c,e+1))>=0;){var f=e;while(--f>=0){var g=d.charAt(f);if(g==";"){f=-1;break}}if(f==-1){var h=d.indexOf(";",e);if(h<0){h=d.length}return d.substring(e+c.length,h)}}return b};$a.ha=bc;$a.remove=function(a,b,c){var d=Rj(a);pc(a,"",0,b,c);return d};var rf=function(){var a=String(document.cookie),b=a.split(/\s*;\s*/),c=[],d=[],e,f;for(var g=0;f=b[g];g++){e=f.indexOf("=");if(e==-1){c.push("");d.push(f)}else{c.push(f.substring(0,e));d.push(f.substring(e+1))}}return{keys:c,values:d}};
$a.UB=rf;$a.Zb=function(){return rf().keys};$a.Va=function(){return rf().values};$a.bc=function(){return document.cookie==""};$a.Ua=function(){var a=String(document.cookie),b=a.split(/\s*;\s*/);return b.length};var Rj=function(a){var b={};return bc(a,b)!==b};$a.Cb=Rj;$a.th=function(a){var b=rf().values;for(var c=0;c<b.length;c++){if(b[c]==a){return true}}return false};$a.clear=function(a){var b=rf().keys;for(var c=b.length-1;c>=0;c--){$a.remove(b[c])}};var Af={};j.userAgent.flash=Af;(function(){function a(h){var i=h.match(/[\d]+/g);i.length=3;return i.join(".")}var b=false,c="";if(navigator.plugins&&navigator.plugins.length){var d=navigator.plugins["Shockwave Flash"];if(d){b=true;if(d.description){c=a(d.description)}}if(navigator.plugins["Shockwave Flash 2.0"]){b=true;c="2.0.0.11"}}else if(navigator.mimeTypes&&navigator.mimeTypes.length){var e=navigator.mimeTypes["application/x-shockwave-flash"];b=e&&e.enabledPlugin;if(b){c=a(e.enabledPlugin.description)}}else{try{var f=
new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");b=true;c=a(f.GetVariable("$version"))}catch(g){try{var f=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");b=true;c="6.0.21"}catch(g){try{var f=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");b=true;c=a(f.GetVariable("$version"))}catch(g){}}}}Af.HAS_FLASH=b;Af.VERSION=c})();var Pq=function(a){return th(Af.VERSION,a)>=0};Af.isVersionNewer=Pq;function H(a,b,c,d){this.yc=this.yx();this.$y=a;this.Ml=b;this.Xh=c;this.Eg=d;this.Uf={};this.ab=[];this.Oz=[];this.pb=0;this.ed=null;this.ZA=false;this.Bq=false;this.Gn=false;this.Za=null;this.nf=null;this.Gz();this.zc=null;this.Qu=null;this.xn=parseInt(this.lo("contentWidth"),10);this.Fu=parseInt(this.lo("contentHeight"),10);this.px();if(this.zc!=null){this.pb=this.zc.selectMode}this.Jl=new kc(this);this.kc=new ma(this);this.Nd=new Jb(this);this.oD={};this.lx();if(this.zc!=null){this.wo()}document.body.appendChild(this.yc)}
var jc=0;H.ALBUM_MODE=jc;var tc=1;H.GRID_MODE=tc;H.prototype.no=function(a){var b={};b.width=this.xn;b.height=this.Fu;return b};H.prototype.lx=function(){var a=document.createElement("table"),b=document.createElement("tbody"),c=document.createElement("tr"),d=document.createElement("td");a.appendChild(b);a.setAttribute("cellpadding","0");a.setAttribute("cellspacing","0");a.style.borderCollapse="collapse";b.appendChild(c);c.appendChild(d);d.appendChild(this.Jl.Yd());c=document.createElement("tr");this.Aj=
document.createElement("td");this.Aj.height=j.userAgent.IE?266:270;b.appendChild(c);c.appendChild(this.Aj);this.kx();c=document.createElement("tr");d=document.createElement("td");b.appendChild(c);c.appendChild(d);var e=document.createElement("center");e.style.padding="20px";this.ed=document.createElement("input");this.ed.type="button";this.ed.disabled="1";this.ed.value="Select Album";t(this.ed,rb,this.ll.p(this));e.appendChild(this.ed);var f=document.createElement("input");f.type="button";f.value=
"Cancel";Kb(f,"position:relative; left:6px");t(f,rb,this.vu.p(this));e.appendChild(f);d.appendChild(e);this.yc.appendChild(a)};H.prototype.kx=function(){var a=document.createElement("table");a.setAttribute("cellspacing","8");a.setAttribute("cellpadding","0");Kb(a,"position:relative; left:4px");var b=document.createElement("tbody"),c=document.createElement("tr"),d=document.createElement("td");a.appendChild(b);b.appendChild(c);c.appendChild(d);d.width=this.xn;d.appendChild(this.Nd.Yd());d.appendChild(this.kc.Yd());
this.Aj.appendChild(a)};H.prototype.oo=function(){return this.yc};H.prototype.hd=function(a){this.yc.style.display="block";this.cf=a;this.kc.reset()};H.prototype.Zc=function(){this.yc.style.display="none";if(this.cf)this.cf();this.cf=null};H.prototype.Bi=function(a,b){if(this.ed){this.ed.disabled=a?"":"1";if(b!=null){this.ed.value=b}}};H.prototype.Fo=function(){return this.Eg};H.prototype.tl=function(a,b){if(this.Eg!=a){this.Eg=a;var c=this.kc.jo();if(a=="BANNER"&&this.pb!=tc||c&&c.id!=this.Xh){this.pb=
jc;this.wo()}this.Jl.Kl()}this.Gn=b};H.prototype.ko=function(){return this.ab};H.prototype.uv=function(){return this.zc};H.prototype.sw=function(){return this.zc!=null&&this.zc.selectMode==jc};H.prototype.qv=function(a){for(var b=0;b<this.ab.length;b++){var c=this.ab[b];if(a==c.id){return c}}return null};H.prototype.Lg=function(a){if(this.pb!=a){this.Nd.Yd().style.display=a==jc?"block":"none";this.kc.Yd().style.display=a==tc?"block":"none";this.pb=a}var b=this.Rh();if(b){this.Bi(b.Zo(),b.Lo())}this.Jl.Lg(a)};
H.prototype.Rh=function(){if(this.pb==jc){return this.Nd}else if(this.pb==tc){return this.kc}return null};H.prototype.ll=function(){if(this.pb==jc){this.kc.Vq(this.Nd.Mo());this.Lg(tc)}else if(this.pb==tc){this.Zc();this.Za=this.kc.jo();this.nf=this.kc.Wv();if(this.nf){this.Fr(this.nf);if(!this.Gn){this.Xp(null)}}}else{this.Zc()}};H.prototype.Py=function(a){if(this.Za&&this.nf){this.Xp(a);return false}return true};H.prototype.vu=function(){this.Zc()};H.prototype.yx=function(){var a=document.createElement("div"),
b="position: absolute; top: 20px; left:20px; z-index:1001; display:block; padding:0px; width:408px; height:380px; ";if(j.userAgent.IE&&!Qq("8")){var c=document.getElementsByTagName("base")[0],d=c.href+"img/dialogframe.png",e=document.createElement("div"),f='position:absolute; width:408px; height:380px; display:block; z-index:-1; filter: progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled="true", src="'+d+'", sizingMethod="scale");';Kb(e,f);a.appendChild(e)}else{b+='background-image: url("img/dialogframe.png")'}Kb(a,
b);return a};H.prototype.lo=function(a){return this.Uf[a]};H.prototype.Gz=function(){this.Uf["commandLabel"]="Choose Photo";this.Uf["logoURL"]="img/googlephotos_sm.gif";this.Uf["contentWidth"]=364;this.Uf["contentHeight"]=248};H.prototype.te=function(){if(this.pb==jc&&this.Nd){this.Nd.te()}else if(this.pb==tc&&this.kc){this.kc.te()}};H.prototype.Fr=function(a){var b="lhcl_portrait_id",c="48",d=false;if(this.Eg=="BANNER"){b="lhcl_cover_id";c="160";d=_album.blogger}var e=document.getElementById(b);
if(e){var f=a.thumbnailURL,g=f.split("?"),h=g[0]+"?crop=1&imgmax="+c;if(d){e.style.background="url('"+h+"') no-repeat left"}else{e.src=h}}};H.prototype.iq=function(a){var b;if(j.userAgent.IE){b=new ActiveXObject("Microsoft.XMLDOM");b.async=false;b.loadXML(a)}else{var c=new DOMParser;b=c.parseFromString(a,"text/xml")}return b};H.prototype.Xp=function(a){var b=this.Za.id,c=this.$y+"&uname="+this.Ml+"&aid="+b,d=(new Date).getTime();c+="&v="+d;var e="selectedphotos="+this.nf.id+"&noredir=true&optgt="+
this.Eg;N.send(c,this.uy.p(this,this.nf,a),"POST",e)};H.prototype.uy=function(a,b,c){var d=c.target;if(d.tg()){this.Fr(a);if(b){b.submit()}}};H.prototype.wo=function(){var a=this.zc.url;this.zi(true);N.send(a,this.cl.p(this))};H.prototype.cl=function(a){var b=this.Rh(),c=a.target;this.zi(false);if(!c.tg()){if(b.Rd){b.Rd("Sorry, we couldn't load the feed. Try again in a little while.")}return}var d=c.hg();if(d.substring(0,5)!="<?xml"){if(b.Rd){b.Rd("Sorry, we can't find the requested feed.")}return}var e=
null,f=this.pb==jc,g;if(j.userAgent.IE){g=this.iq(d)}else{g=c.Io()}e=new Yc(this,g,f);if(e!=null){this.ab=e.xo()}this.Vy();var h=this.Rh();if(h){h.te()}};H.prototype.Vy=function(){if(this.Xh&&this.Xh.length>0){var a=this.qv(this.Xh);if(a!=null){this.kc.Vq(a);this.Lg(tc)}}};H.prototype.uk=function(){return this.Bq};H.prototype.zi=function(a){this.Bq=a};H.prototype.Kw=function(){return this.zc&&this.zc.extraParams=="q=*"};H.prototype.px=function(){var a="http://"+document.domain+":"+document.location.port+
"/data/feed/back_compat/user/"+this.Ml+"?alt=rss&kind=album",b=new vm("My Google Photos","lh",this.Ml,"Lighthouse",a,jc,null,null);this.Oz.push(b);this.zc=b;this.Qu="lh"};function $f(a,b,c){this.title=a;this.id=b;this.Gl=c;this.lq=[];this.description=null;this.kq=0;this.Sj=null;this.Yn=false;this.PC=null}$f.prototype.Wt=function(a){this.lq.push(a)};$f.prototype.Ua=function(){return this.kq};$f.prototype.Nv=function(){return this.lq};function ag(a,b,c,d,e){this.title=a;this.id=c;this.thumbnailURL=
d;this.fullsizeURL=e;this.mediaType=b;this.Mc=-1;this.Bc=-1}ag.prototype.ez=function(a,b){this.Mc=a;this.Bc=b};ag.prototype.sv=function(){return 1};ag.prototype.wv=function(){if(this.Mc==-1||this.Bc==-1){return null}return this.Mc.toString()+"x"+this.Bc.toString()};function Jb(a){this.pa=a;this.contentSize=this.pa.no(true);this.yc=this.xx();this.fd=-1;this.mf=[]}Jb.prototype.Mo=function(){if(this.fd<0){return null}var a=this.pa.ko();return a[this.fd]};Jb.prototype.Yd=function(){return this.yc};Jb.prototype.Zo=function(){return this.fd>=0};Jb.prototype.Lo=function(){return"Select Album"};Jb.prototype.te=function(){this.my()};Jb.prototype.xx=function(){var a=document.createElement("div"),b=this.contentSize.height+8,c="position:relative; top:16px; left:6px;  font-family:sans-serif; height:"+
b+"px; width:"+this.contentSize.width;c+="px; background: white; overflow:auto; overflow-x:hidden";Kb(a,c);var d=document.createElement("table");d.width="100%";d.setAttribute("cellspacing","0");d.setAttribute("cellpadding","0");d.style.borderCollapse="collapse";var e=document.createElement("tbody");d.appendChild(e);this.vc=e;this.oh=d;this.Kf(e,true);a.appendChild(d);t(a,Xb,this.Ik.p(this));a.ondblclick=this.Kj.p(this);return a};Jb.prototype.my=function(){var a=this.pa.ko();this.mf=[];this.fd=-1;
this.oh.removeChild(this.vc);this.vc=document.createElement("tbody");this.oh.appendChild(this.vc);if(a.length<1){this.Kf(this.vc,false);return}for(var b=0;b<a.length;b++){var c=a[b],d=document.createElement("tr");this.vc.appendChild(d);if(b%2){d.style.background="#ffffff"}else{d.style.background="#eeeeee"}var e=document.createElement("td");e.height=32;e.width=42;var f=document.createElement("img");if(c.Gl!=null){f.src=c.Gl}else{f.src="img/transparent.gif"}f.width=32;f.height=28;f.hspace=4;f.style.border=
"1px solid #808080";e.appendChild(f);d.appendChild(e);var e=document.createElement("td");e.height=32;var g=c.Ua(),h=c.title.replace(/_/g," "),i=document.createElement("font");i.color="#4D4D4D";i.size="4";i.style.cursor="default";i.innerHTML=Sh(h);e.appendChild(i);var k=document.createElement("font");k.innerHTML="&nbsp;("+g+")";k.style.position="relative";k.style.top="-2px";e.appendChild(k);d.appendChild(e);d.Ak=i;d.yn=k;d.ga=f;this.mf.push(d)}};Jb.prototype.Kf=function(a,b){var c=document.createElement("tr"),
d=document.createElement("td"),e="<br><br><br><center><font size=4 font color=#4D4D4D>";if(this.pa.uk()||b){e+='Loading Album List...<img src="img/spin.gif" hspace=8></font></center>'}else{e+="No Albums Found."}d.innerHTML=e;c.appendChild(d);a.appendChild(c)};Jb.prototype.Rd=function(a){this.oh.removeChild(this.vc);this.vc=document.createElement("tbody");this.oh.appendChild(this.vc);var b=document.createElement("tr"),c=document.createElement("td");c.innerHTML="<br><br><br><center><font size=4 font color=#cc0000>"+
a+"</font></center>";b.appendChild(c);this.vc.appendChild(b)};Jb.prototype.Xy=function(a){if(this.fd!=a){var b;if(this.fd>=0){b=this.mf[this.fd];if(this.fd%2){b.style.background="#ffffff"}else{b.style.background="#eeeeee"}b.Ak.color="#4D4D4D";b.yn.color="#4D4D4D";b.ga.style.border="1px solid #808080"}b=this.mf[a];if(b){b.style.background="#112ABB";b.Ak.color="#ffffff";b.yn.color="#ffffff";b.ga.style.border="1px solid white";this.fd=a;this.pa.Bi(true,H.SELECT_ALBUM_MSG)}}};Jb.prototype.Ik=function(a){var b=
zd(a),c=pa(this.vc),d=bb(this.yc),e=b.y-c.y;if(j.userAgent.SAFARI&&b.x-c.x>=d.width-16){return}var f=0;for(var g=0;g<this.mf.length;g++){var h=this.mf[g],i=bb(h).height;if(j.userAgent.SAFARI){i=Math.max(32,bb(h.Ak).height)}f+=i;if(e<=f){this.Xy(g);return}}};Jb.prototype.Kj=function(a){if(this.Mo()){this.pa.ll()}};function ma(a){this.pa=a;this.Qf=this.pa.no(true);this.yc=this.zx();this.Ic=-1;this.rd=[];this.Xk=[];this.Za=null;this.Oi=5;this.Vm=this.pa.Vm}ma.prototype.Vq=function(a){if(a!=this.Za){this.Za=a;if(a!=null){this.ox()}this.Ic=-1;this.qq()}};ma.prototype.jo=function(){return this.Za};ma.prototype.Yd=function(){return this.yc};ma.prototype.Zo=function(){return this.Ic>=0};ma.prototype.Lr=function(){return true};ma.prototype.Lo=function(){return"Choose Photo"};ma.prototype.zx=function(){var a=document.createElement("div"),
b=4,c=this.Qf.height;if(this.Lr()){c-=20}else{b=16}var d="display:none; position:relative; top:"+b+"px; left:6px; height:"+c+"px; width:"+this.Qf.width+"px";Kb(a,d);this.Yc=document.createElement("div");d="height:"+c+"px; width:"+this.Qf.width+"px; padding-left: 6px; padding-top: 4px; font-family:sans-serif; background: white; overflow:auto";Kb(this.Yc,d);this.Kc=document.createElement("div");this.Yc.appendChild(this.Kc);this.Kf();t(this.Yc,Xb,this.Ik.p(this));this.Yc.ondblclick=this.Kj.p(this);a.appendChild(this.Yc);
if(this.Lr()){this.Ab=document.createElement("div");Kb(this.Ab,"position:absolute; top:238px; left:69px; display: none");this.zl=new ob("zoom","img/slidertrack.png","img/sliderknob.png",215,0,100,50,17,24,this.oA.p(this),null);var e=this.zl.Yv();this.zl.Pt();this.Ab.appendChild(e);a.appendChild(this.Ab)}else{this.Ab=null}return a};ma.prototype.oA=function(a){this.Fz(Math.round((100-a)/10))};ma.prototype.qq=function(){this.Yc.removeChild(this.Kc);this.Kc=document.createElement("div");this.Yc.appendChild(this.Kc);
this.rd=[];this.Xk=[];var a;if(this.Za==null){a=this.pa.ab}else{a=this.Za.Nv()}if(a.length<1){if(this.pa.uk()){this.Kf()}else{this.Rd("No Images Found.")}if(this.Ab)this.Ab.style.display="none";return}for(var b=0;b<a.length;b++){var c=a[b],d=document.createElement("img"),e=Math.round((this.Qf.width-60)/this.Oi),f=c.sv();if(f==0){var g=Math.round(e*3/4)}else{if(f>1){var g=Math.round(e/f)}else{e=Math.round(e*f);var g=Math.round(e/f)}}d.src=c.thumbnailURL;d.width=e;d.height=g;if(c.title!=null){d.title=
this.bw(c)}if(b==this.Ic){d.style.border="2px solid #112ABB";d.hspace=0;d.vspace=0}else{d.style.border="1px solid #808080";d.hspace=1;d.vspace=1}this.Kc.appendChild(d);this.rd.push(d);this.Xk.push(c)}if(this.Ab)this.Ab.style.display=a.length>0?"inline":"none"};ma.prototype.Kf=function(){if(this.pa.Kw()&&!this.pa.uk()){return}var a=document.createElement("div");a.innerHTML='<br><br><br><center><font size=4 font color=#4D4D4D>Loading Photos...<img src="img/spin.gif" hspace=8></font></center>';this.Kc.appendChild(a)};
ma.prototype.Rd=function(a){this.Yc.removeChild(this.Kc);this.Kc=document.createElement("div");this.Yc.appendChild(this.Kc);var b=document.createElement("div");b.innerHTML="<br><br><br><center><font size=4 font color=#cc0000>"+a+"</font></center>";this.Kc.appendChild(b)};ma.prototype.bw=function(a){var b=a.title,c=a.wv();if(c!=null){b+=", "+c}return b};ma.prototype.Wv=function(){if(this.Ic<0){return null}return this.Xk[this.Ic]};ma.prototype.uz=function(a){if(a!=this.Ic){if(this.Ic>=0){var b=this.rd[this.Ic];
b.style.border="1px solid #808080";b.hspace=1;b.vspace=1}var c=this.rd[a];c.style.border="2px solid #112ABB";c.hspace=0;c.vspace=0;this.Ic=a;this.pa.Bi(true,H.SELECT_PHOTO_MSG)}};ma.prototype.mA=function(){var a=Math.round((this.Qf.width-40)/this.Oi);for(var b=0;b<this.rd.length;b++){var c=this.rd[b];c.width=a;c.height=a}};ma.prototype.qu=function(a){for(var b=0;b<this.rd.length;b++){var c=this.rd[b],d=pa(c),e=bb(c);if(a.x>=d.x&&a.y>=d.y&&a.x<d.x+e.width&&a.y<d.y+e.height){return b}}return null};
ma.prototype.ox=function(){var a;if(this.Za!=null){if(this.Za.Sj==null||this.Za.Yn){return}a=this.Za.Sj}else{var b=this.pa.uv();a=b.url}if(!this.Vm){var c=(new Date).getTime();a+="&v="+c}this.pa.zi(true);N.send(a,this.cl.p(this))};ma.prototype.cl=function(a){var b=null,c=a.target,d=document.location.hash;if(d.length>0&&d.charAt(0)=="#"){d=d.substring(1)}this.pa.zi(false);if(!c.tg()){var e=this.pa.Rh();e.Rd("Sorry, we couldn't load the feed.  Try again in a little while.");return}var f;if(j.userAgent.IE){f=
this.pa.iq(c.hg())}else{f=c.Io()}b=new Yc(this.pa,f,false);var g=null;if(b!=null){if(this.Za==null){this.pa.ab=[]}g=b.xo();for(var h=0;h<g.length;h++){var i=g[h];if(this.Za!=null){this.Za.Wt(i)}else{this.pa.ab.push(i)}if(i.id==d){this.Ic=h;this.pa.Bi(true,H.SELECT_PHOTO_MSG)}}}if(this.Za){this.Za.Yn=true}this.te()};ma.prototype.Ik=function(a){var b=zd(a),c=this.qu(b);if(c!=null){this.uz(c)}};ma.prototype.Kj=function(a){this.pa.ll()};ma.prototype.Fz=function(a){if(a<1){a=1}if(this.Oi!=a){this.Oi=a;
this.mA()}};ma.prototype.te=function(){this.qq()};ma.prototype.reset=function(){this.zl.sf(50)};function Yc(a,b,c){this.pa=a;this.fs=b;this.vk=[];this.kv(c)}Yc.prototype.xo=function(){return this.vk};Yc.prototype.kv=function(a){var b=this.fs.getElementsByTagName("item");for(var c=0;c<b.length;c++){var d=b[c];if(a){this.Qt(d)}else{this.Xt(d)}}};Yc.prototype.Ob=function(a,b){var c=b,d=b.split(":");if(d.length>1){if(!j.userAgent.IE){c=d[1]}}var e=a.getElementsByTagName(c);for(var f=0;f<e.length;f++){if(e[f].nodeName!=b)continue;var g=e[f].firstChild;if(g!=null){var h=g.nodeValue;if(h!=null){return h}}}return null};
Yc.prototype.Qt=function(a){var b=this.Ob(a,"title"),c=this.Ob(a,"photo:thumbnail"),d=this.Ob(a,"gphoto:numphotos"),e=this.Ob(a,"gphoto:rsslink"),f=this.Ob(a,"gphoto:id"),g=this.Ob(a,"description");c=this.jj(c,e);var h=new $f(b,f,c);h.kq=parseInt(d,10);h.Sj=e;h.description=g;this.vk.push(h)};Yc.prototype.Xt=function(a){var b=this.Ob(a,"title"),c=this.Ob(a,"link"),d=this.Ob(a,"photo:thumbnail"),e=this.Ob(a,"photo:imgsrc"),f=this.Ob(a,"gphoto:id");d=this.jj(d,c);e=this.jj(e,c);var g=parseInt(this.Ob(a,
"gphoto:width"),10),h=parseInt(this.Ob(a,"gphoto:height"),10);if(d){var i=d.split("?");d=i[0]+"?imgmax=160&crop=1"}var k=new ag(b,"image/jpeg",f,d,e);k.ez(g,h);this.vk.push(k)};Yc.prototype.jj=function(a,b){if(a==null){return null}var c=a;if(a.length<7||a.substring(0,7)!="http://"){var d=b.split("/");c="http://"+d[2]+a}return c};function vm(a,b,c,d,e,f,g,h){this.title=a;this.id=b;this.user=c;this.format=d;this.url=e;this.selectMode=f;this.description=g;this.extraParams=h;this.hasTags=false;this.canDelete=false;this.Gu=[];this.JC=false};vm.prototype.push=function(a){this.Gu.push(a)};function kc(a){this.pa=a;this.wr=this.mx();this.pb=jc;this.Kl();this.CC=false;this.wC=0}kc.prototype.mx=function(){var a=document.createElement("div"),b=j.userAgent.IE?"4":"8";Kb(a,"position:relative; top:4px; left:12px; background: transparent; font-family:sans-serif; width:380px; padding:0px; height:42px");var c=document.createElement("div");Kb(c,"position:absolute; top:"+b+"px; left:4px; color: white; font-weight: bold; cursor:default");c.unselectable="on";c.innerHTML="Photo Chooser";a.appendChild(c);
this.af=document.createElement("div");Kb(this.af,"position:absolute; top:32px; left:4px; color: #777777; cursor: pointer");a.appendChild(this.af);t(this.af,rb,this.bA.p(this),true);t(a,Xb,this.ik.p(this),true);return a};kc.prototype.Yd=function(){return this.wr};kc.prototype.jz=function(a){this.af.innerHTML="<font size=2><b>"+a+"</b></font>"};kc.prototype.bA=function(a){if(this.pb==tc){if(this.pa.sw()&&this.pa.Fo()=="PORTRAIT"){this.pa.Lg(jc);this.pa.Nd.te()}}};kc.prototype.Kl=function(){var a=this.pa.Fo()==
"BANNER",b="Select an Album to browse:",c="#777777",d="none";if(a){b="Select a Cover Photo:"}else if(this.pb==tc){b="&laquo;&nbsp;Back to Albums List";c="#112ABB";d="underline"}this.jz(b);this.af.style.color=c;this.af.style.textDecoration=d};kc.prototype.Lg=function(a){this.pb=a;this.Kl()};kc.prototype.ik=function(a){this.pk=zd(a);var b=this.pa.oo(),c=pa(this.wr),d=this.pk.y-c.y;this.Qw=parseInt(b.style.left,10);this.Rw=parseInt(b.style.top,10);if(d>28){return false}this.Bg=this.Th.p(this);this.Vg=
this.jg.p(this);this.Gg=this.jk.p(this);t(document.body,me,this.Bg);t(document.body,ne,this.Vg);t(document.body,id,this.Gg);return false};kc.prototype.Th=function(a){var b=zd(a),c=this.pa.oo(),d=b.y-this.pk.y+this.Rw,e=b.x-this.pk.x+this.Qw,f=ef(),g=f.width-40,h=f.height-40;d=Math.max(Math.min(d,h),0);e=Math.max(Math.min(e,g),0);c.style.top=d+"px";c.style.left=e+"px";Yd(a);return false};kc.prototype.jg=function(a){$(document.body,me,this.Bg);$(document.body,ne,this.Vg);$(document.body,id,this.Gg);
Yd(a);return false};kc.prototype.jk=function(a){if(!(a.relatedTarget||a.toElement)){this.jg(a)}};var bg={},Kb=function(a,b){if(j.userAgent.IE){a.style.setAttribute("cssText",b)}else{a.setAttribute("style",b)}};bg.setStyle=Kb;var Yd=function(a){if(a.stopPropagation){a.preventDefault();a.stopPropagation()}else{a.cancelBubble=true;a.returnValue=false}};bg.swallowEvent=Yd;var wm=function(){var a=0,b=0;if(j.userAgent.SAFARI){a=-1*window.pageXOffset;b=-1*window.pageYOffset}else{var c=Pb();a=c.scrollLeft;b=c.scrollTop}return{x:a,y:b}};bg.getScrollOffset=wm;var zd=function(a){var b={x:a.clientX,y:a.clientY},
c=wm();b.x+=c.x;b.y+=c.y;return b};bg.getMousePosition=zd;function ob(a,b,c,d,e,f,g,h,i,k,n){this.Kz=a;this.ku=b;this.Nw=c;this.jn=d;this.Bp=h;this.gl=i;this.xc=k;this.On=n;this.Ab=null;this.Ag=e;this.Gk=f;this.mh=this.jn-this.Bp-this.gl;this.Vc=g;this.pr=g;this.Sw=0;this.jf()}ob.prototype.Yv=function(){return this.Ab};ob.prototype.jf=function(){this.Ab=document.createElement("div");this.Pf=document.createElement("img");this.Pf.setAttribute("src",this.ku);this.Pf.setAttribute("width",this.jn);this.Mw=document.createElement("div");this.Mw.setAttribute("id",
this.Kz+"-knob");this.ac=document.createElement("img");this.ac.setAttribute("src",this.Nw);this.ac.setAttribute("border","0");Kb(this.ac,"position:relative; top:0px; left:0px; cursor:move");this.ac.style.top="2px";this.Ab.appendChild(this.Pf);this.Ab.appendChild(this.ac);this.ql()};ob.prototype.Pt=function(){this.up=this.ik.p(this);this.hn=this.gw.p(this);t(this.ac,Xb,this.up);t(this.Pf,rb,this.hn)};ob.prototype.Fj=function(){$(this.ac,Xb,this.up);$(this.Pf,rb,this.hn)};ob.prototype.ik=function(a){var b=
zd(a);this.Sw=b.x-this.gl;this.hC=parseInt(this.ac.style.left,10);this.pr=this.Vc;this.cn=pa(this.Ab);this.Bg=this.Th.p(this);this.Vg=this.jg.p(this);this.Gg=this.jk.p(this);t(document.body,me,this.Bg);t(document.body,ne,this.Vg);t(document.body,id,this.Gg);Yd(a);return false};ob.prototype.Th=function(a){var b=zd(a),c=Math.round(this.ac.width/2),d=b.x-this.cn.x;if(d<this.mh/2){c=0}this.Vc=this.su(d-c);this.ql();if(this.xc){this.xc(this.Vc)}Yd(a);return false};ob.prototype.jg=function(a){$(document.body,
me,this.Bg);$(document.body,ne,this.Vg);$(document.body,id,this.Gg);if(this.On){this.On(this.pr,this.Vc)}Yd(a);return false};ob.prototype.jk=function(a){if(!(a.relatedTarget||a.toElement)){this.jg(a)}};ob.prototype.gw=function(a){this.cn=pa(this.Ab);return this.Th(a)};ob.prototype.Fv=function(a){var b=this.ru(a),c=Math.round(this.ac.width/2);return b-c-this.gl-this.mh};ob.prototype.ql=function(){this.ac.style.left=this.Fv(this.Vc)+"px"};ob.prototype.$b=function(){return this.Vc};ob.prototype.sf=function(a){if(a!=
this.Vc){this.Vc=a;this.ql();if(this.xc){this.xc(this.Vc)}}};ob.prototype.ru=function(a){return(a-this.Ag)*this.mh/(this.Gk-this.Ag)};ob.prototype.su=function(a){var b=Math.round(this.ac.width/2),c=this.Gk-this.Ag,d=this.Ag+Math.round(c*(a-this.Bp)/(this.mh-b));return Math.max(Math.min(d,this.Gk),this.Ag)};var jg=function(a){return"Error: "+a},be="Loading&#8230;",Nm=function(a){return"Photos: "+a},ds=function(a,b){return a+" "+b},bs=function(a){return"Copying items to album: "+a},ns=function(a){return"Moving items to album: "+a},Fm="Album dates must be set to 1970 or later. Please try again.",Tr=function(a,b){return"Album descriptions must be less than "+b+" characterslong. You are currently using "+a+" characters. Please make your description shorter and try again."},Ur=function(a,b){return"Album descriptions must be "+
b+" characters or less. You are currently using "+a+" characters. Please make your description shorter and try again."},vs=function(a){return"For albums you want to show publicly. Anyone who visits "+a+" can see them"},ws=function(a){return"This album will be visible to all users at "+a+". It will be included in Picasa Web Albums community search, based on preferences (Community search preferences may be modified on the Settings page)."},Zr=function(a,b){return"Choose an album below or "+a+"create a new album"+
b+"."},cs=function(a,b){return"Enter details for a new album below or "+a+"choose an existing album"+b+"."},qi="There was an error communicating with the server. Please check your connection and try again.",Qr=function(a){return a+" has been added as a favorite."},Vr=function(a){return"Would you like to link to "+a+"'s public gallery?"},fs=function(a,b){return"You are receiving activity updates from these users. For all your favorite users, click "+a+"here"+b},es=function(a,b){return"You are viewing all favorite users.  To view only those whose activity updates you are receiving, click "+
a+"here"+b},Om="Are you sure you want to remove this from your favorites?",Im="Report inappropriate content",as=function(a,b){return"If you own the copyright for this work and would like it removed, please see our "+a+"instructions for notification of copyright infringement"+b+"."},gs=function(a,b){return"We're sorry, the maximum length for flagging messages is "+b+" characters. You are currently using "+a+" characters. Please modify your message and try again."},ig="Sorry, we encountered an error while loading this album.",
ps=function(a,b,c){return a+" - "+b+" of "+c},Xr=function(a,b){return"Your caption is "+a+" characters long. ("+b+" maximum)"},pi=function(a,b){return"We're sorry, you cannot copy or move more than "+b+" photos at once. You currently have "+a+" photos selected."},Em="I'm afraid your caption is a bit too long. Please, try to be more brief!",Yr=function(a,b){return"Your caption is "+a+" characters long. ("+b+" maximum)"},Sr=function(a,b){return"This photo has been added. "+a+"View your order"+b+"."},
os=function(a,b){return"Your order has been opened in a new window.  If a new window didn't open, click "+a+"here"+b},li="Add a comment",ys=function(a,b,c){return a+"Sign in"+c+" if you have a Google account, or "+b+"sign up"+c+" for a free account."},$r=function(a,b){return"Your comment is "+a+" characters long. ("+b+" maximum)"},mi="Download Photo",rs=function(a,b){return"Photo "+a+" of "+b},qs=function(a){return a+" pixels"},ts=function(a){return a+"KB"},Jm="You need Flash 7 or higher to watch videos.",
ri="View Album",oi="Share Photo",Lm="Magnified view, click on image and drag to move.",Gm="We're sorry, this photo is not currently available. It may have been deleted by its owner, or there may have been an error on the server. Click OK to continue.",Km="The server denied permission for this action. Please make sure you are still logged in to your account and try again.",Mm="It seems the item you requested has been misplaced. Please check your internet connection, cross your fingers, and try again.",
Qm="Something unusual has happened. Hopefully, it is so unusual that you will never see this dialog again.",Pm="The server may be a little bit broken temporarily. Please try again in a few moments while it sorts itself out.",Hm="Delete this photo",js=function(a,b){return"Paste link in "+a+"email or IM"+b},is=function(a,b){return"HTML to "+a+"embed in website"+b},kg=function(a){return a+"px"},Rr=function(a,b){return"Photos added by "+a+": "+b},xs=function(a){return a+" shared an album with you."},
Wr=function(a){return'The address "'+a+'" does not appear to be a valid email address. Please check the address and try again.'},ni="There was an error communicating with the server. Please try again.",us=function(a){return"+ "+a+" more"},ks=function(a,b){return"Too many tags (max is "+a+", but "+b+" entered)"},ms=function(a,b){return"Text too long (max is "+a+"letters, but "+b+" were entered)"},ls=function(a,b){return"Tags can only be "+a+" letters long. You entered one that was "+b+" letters long."},
ss=function(a){return"Now searching in "+a},hs=function(a){return a+"'s Gallery"},zs=function(a){return"View "+a+"'s gallery page"};function Ws(a){if(document.defaultView)return document.defaultView.getComputedStyle(a,"");else if(a.currentStyle)return a.currentStyle;else return null}function xt(a,b){var c=l(b);if(c)c.style.visibility=a?"":"hidden"}function o(a,b){return function(){b.apply(a,arguments)}}function Tb(a,b){var c=[];for(var d=2;d<arguments.length;++d)c.push(arguments[d]);return function(){var e=[];for(var f=0;f<arguments.length;++f)e.push(arguments[f]);e=c.concat(e);b.apply(a,e);for(f=0;f<e.length;++f)delete e[f]}}
function sg(a,b,c){var d=o(a,b);return window.setTimeout(d,c)}function Ma(a,b){return function(c){if(!c)c=window.event;if(c&&!c.target)c.target=c.srcElement;b.call(a,c)}}function wa(a,b,c){if(a.addEventListener)a.addEventListener(b,c,false);else if(a.attachEvent)a.attachEvent("on"+b,c)}function Aa(a,b,c){if(a.removeEventListener)a.removeEventListener(b,c,false);else if(a.detachEvent)a.detachEvent("on"+b,c)}function cc(a){if(window.event){a.cancelBubble=true;a.returnValue=false}else if(a){a.cancelBubble=
true;if(a.preventDefault){a.preventDefault();a.stopPropagation()}}}var Ee=[],Df=0;function qg(a){xh(Ee,a);if(!Df)Df=window.setInterval(Ct,10)}function kk(a){Tq(Ee,a);if(Ee.length==0)Bt()}function Bt(){if(Df)window.clearInterval(Df);Df=0}function Ct(){var a=Re();for(var b=0;b<Ee.length;b++){if(Ee[b])Ee[b](a)}}function xb(a){P.Pa(this);this.Xj=a;this.xc=o(this,this.Hl);this.Ha=0}xb.prototype.aa=function(){P.Sa(this);this.reset();this.Xj=null};xb.prototype.ma=function(a){this.reset();this.Ha=window.setTimeout(this.Xj,
a)};xb.prototype.reset=function(){if(this.Ha)window.clearTimeout(this.Ha);this.Ha=0};xb.prototype.mp=function(){return this.Ha!=0};xb.prototype.Hl=function(){this.Ha=0;this.Xj()};function tb(a,b){a.appendChild(b);while(a.childNodes.length>1)a.removeChild(a.firstChild)}function Cd(){return self.innerHeight||document.documentElement.clientHeight}function Rq(a){a=a.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;");a=a.replace(/"/g,"&quot;").replace(/'/g,"&#39;");return a}function Xe(a,
b){var c=[],d=0,e=0,f=b||20,g=/[-.,?!\/\\#]/,h=-1;for(var i=0;i<a.length;i++){var k=a.charAt(i);if(k.search(/\s/)==0){d=0;continue}else if(k=="<"){while(k&&k!=">")k=a.charAt(++i);continue}if(d>=f){var n=a.substring(e,i);if(h>=e&&h<i){c.push(n.substring(0,h-e+1));d=i-h-1;e=h+1}else{c.push(a.substring(e,i));d=0;e=i}}if(k=="&"){while(k&&k!=";")k=a.charAt(++i)}else if(k.search(g)==0){h=i}d++}if(c.length){var s=j.userAgent.GECKO?"<wbr />":"&shy;";c.push(a.substring(e));return c.join(s)}else{return a}}
function Eo(a){return a.split("?")[0]}var Ns,vh,nk;(function(){var a="(?:(?:(?:\\d{1,3}\\.){3}\\d{1,3})|(?:(?:[a-z0-9\\-]+\\.)+(?:aero|biz|cat|com|coop|edu|gov|info|int|jobs|mil|mobi|museum|name|net|org|pro|travel|[a-z]{2})\\b))",b="a-z0-9/~?&;=%@+$#_\\-",c="/(?:["+b+",:\\.]*["+b+"])?",d="\\b(?:https?://)?"+a+"(?::\\d+)?(?:"+c+")?",e="\\b[a-z0-9_.+\\-]+@"+a;Ns=new RegExp("("+a+")","gi");vh=new RegExp("("+e+")","gi");nk=new RegExp("("+d+")","gi")})();function nt(a){var b=a.match(vh);return!(!b)&&b==
a}function Co(a){var b=a.split(/\s/);for(var c=0;c<b.length;c++){var d=b[c];if(d.search(vh)>=0){d=d.replace(vh,'<a href="mailto:$1">$1</a>');b[c]=d}else if(d.search(nk)>=0){d=d.replace(nk,'<a href="http://$1" rel="nofollow">$1</a>');d=d.replace(/http:\/\/(https?:\/\/)/,"$1");b[c]=d}}return b.join(" ")}function Nf(){this.Qx=0;this.ki={};this.sn=o(this,this.cs);wa(window,"unload",this.sn)}Nf.prototype.Pa=function(a){a.__d=this.Qx++;this.ki[a.__d]=a};Nf.prototype.Sa=function(a){delete this.ki[a.__d]};
Nf.prototype.cs=function(){for(var a in this.ki){var b=this.ki[a];if(b&&b.aa)b.aa()}Aa(window,"unload",this.sn)};function Ls(a){Cj()}t(j.global,$s,Ls);function Qc(a,b,c){return Math.min(Math.max(a,b),c)}function At(a,b){return(a.x-b.x)*(a.x-b.x)+(a.y-b.y)*(a.y-b.y)}function xh(a,b,c){if(!c){c=function(f,g){if(f<g)return-1;if(f>g)return 1;return 0}}for(var d=0;d<a.length;++d){var e=c(b,a[d]);if(e==-1){a.splice(d,0,b);return null}else if(e==0){return a[d]}}a.push(b);return null}function Tq(a,b){for(var c=
0;c<a.length;++c){if(b>a[c])return null;if(b==a[c])return a.splice(c,1)}return null}function Oi(a,b){var c={},d=a.length;if(b){for(var e=0;e<d;e++)c[a[e][b]]=e}else{for(var e=0;e<d;e++)c[a[e]]=e}return c}function ja(a,b){var c=a.match(/(\{\w*\})/g);if(!c)return a;for(var d=0;d<c.length;d++){var e=c[d],f=new RegExp(e,"g"),g=e.substring(1,e.length-1);a=a.replace(f,b[g]!=undefined?b[g]:"")}return a}if("a".replace(/(a)/g,function(a,b){return"b"})=="b"){ja=function(a,b){return a.replace(/\{(\w*)\}/g,function(c,
d){return b[d]!=undefined?b[d]:""})}}var mk=m.createElement("div");function D(a,b){mk.innerHTML=ja(a,b);return mk.removeChild(mk.firstChild)}var yh={},Ef={};function p(a){if(!a)a="_";var b=yh[a]||0,c=a;if(b)c+="_"+b;yh[a]=b+1;return c}function q(a,b){Ef[a]=b}function y(a){if(Ef[a])delete Ef[a];if(yh[a]==1)yh[a]=0}function qb(a){var b=[];for(var c=1;c<arguments.length;c++)b.push(arguments[c]);b.push(a);if(Ef[a])Ef[a].apply(this,b)}function wh(a){var b=a.split(/\,/);if(b.length!=3)return null;var c=
parseInt(b[0],10),d=parseInt(b[1],10),e=parseInt(b[2],10);if(c<1)return null;if(d<1||d>12)return null;var f=new Date(e,d-1,c);return f}function Rs(a,b){if(b<0||b>3)return a;var c=wh(a);if(c==null){return a}return sd(mb.DATEFORMATS[b],c,null)}function rt(a,b,c,d){if(d<0||d>3)return;if(typeof a!="number")return;if(typeof b!="number")return;if(typeof c!="number")return;if(a<1)return;if(b<1||b>12)return;var e=new Date(c,b-1,a);document.write(sd(mb.DATEFORMATS[d],e,null))}function ok(){var a=document.getElementsByTagName("div");
for(var b=0;b<a.length;b++){if(a[b].className=="lhcl_wrap"){I.remove(a[b],"lhcl_wrap");Ao(a[b])}}a=document.getElementsByTagName("span");for(var b=0;b<a.length;b++){var c=a[b].className;if(c!=null&&c.substring(0,11)=="lhcl_trunc_"){var d=parseInt(c.substring(11),10);a[b].className="";Hs(a[b],d)}}}function Hs(a,b){if(a&&a.hasChildNodes()){var c=a.firstChild;if(c.nodeValue.length>b){var d=c.splitText(b);a.removeChild(d);a.appendChild(D("&#8230;",{}))}}}function Ao(a){Mi(a,0,"",0)}function Mi(a,b,c,
d){if(!a)return;if(b<1&&j.userAgent.IE){a.style.wordWrap="break-word";return}var e=-1;if(b>0){a.innerHTML="g";for(var f=1;f<b;f++){a.innerHTML=a.innerHTML+"<br />g"}e=a.offsetHeight;a.innerHTML=c;if(a.offsetWidth<=d&&a.offsetHeight<=e){return}}if(!a.hasChildNodes())return;var g=a.firstChild;if(g.nodeValue.length<1)return;var h=0,i=0,k=g.nodeValue.length;while(h<k){var n=Math.min(g.nodeValue.length,i+5),s=g.nodeValue.substring(i,n).search(/\s/);if(s>-1||n<k){var u=s>-1?s+1:n,z=s>-1?s+1:5,v=g.splitText(u);
if(e>0){a.removeChild(v);if(a.offsetHeight>e){a.innerHTML=a.innerHTML+"&#8230;";h=k}else{var A=m.createElement("wbr");a.appendChild(A);a.appendChild(v);g=v;i=0;h+=z}}else{var A=m.createElement("wbr");a.insertBefore(A,v);g=v;i=0;h+=z}}else{h=k}}if(e>0){while(a.offsetHeight>e&&a.childNodes.length>2){a.removeChild(a.lastChild);a.removeChild(a.lastChild);a.innerHTML=a.innerHTML+"&#8230;"}}}var Wg=function(a,b){return Math.max(a.top,b.top)<Math.min(a.bottom,b.bottom)&&Math.max(a.left,b.left)<Math.min(a.right,
b.right)};Na.Vw=Wg;var Pj=function(a,b){if(!Wg(a,b)){return[new jb(a.top,a.left,a.width,a.height)]}var c=[],d=a.top,e=a.bottom;if(b.top>a.top){c.push(new Na(a.top,a.right,b.top,a.left));d=b.top}if(b.bottom<a.bottom){c.push(new Na(b.bottom,a.right,a.bottom,a.left));e=b.bottom}if(b.left>a.left){c.push(new Na(d,b.left,e,a.left))}if(b.right<a.right){c.push(new Na(d,a.right,e,b.right))}return c};Na.difference=Pj;Na.boundingBox=function(a,b){return new Na(Math.min(a.top,b.top),Math.max(a.right,b.right),
Math.max(a.bottom,b.bottom),Math.min(a.left,b.left))};function wt(){pc("_lh_backLink",location.pathname+location.search+location.hash)}function pt(a,b){if(_features.newStrings){return b}else{return a}}function Lr(){if(!j.userAgent.IE){return}if(th(j.userAgent.VERSION,"7.0")>=0){return}var a=Dg("img","lhcl_png"),b=document.getElementsByTagName("base")[0].href;for(var c=0;c<a.length;++c){var d=a[c],e=d.src;d.src=b+"img/spacer.png";d.style.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+
e+"', sizingMethod='crop')"}}function dg(a,b){var c=b?"PUBLIC_ALBUM_INDEX_ON":"PUBLIC_ALBUM_INDEX_OFF";Q.Aa(_setPrefUrl,Jr.p(null,a,b),"pref="+c)}function Jr(a,b,c){if(c.status>=400||c.text.indexOf("success")<0){alert(ni);return}a(b)};;;function mc(a){P.Pa(this);var b=a||2;this.nb=[];for(var c=0;c<b;c++){this.nb[c]=null}this.Ja=[];this.pe=1;if(typeof XMLHttpRequest!="undefined"){this.Qe=this.Mt}else if(typeof window.ActiveXObject!="undefined"){for(var c=0;c<Ni.length;c++){var d=Ni[c];try{var e=new ActiveXObject(d);if(!e)continue;this.Qe=function(){return new ActiveXObject(d)};break}catch(f){}}}}var Ni=["MSXML2.XMLHTTP.6.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","MICROSOFT.XMLHTTP"];mc.PROG_IDS=Ni;mc.prototype.aa=function(){P.Sa(this);
this.Qe=null;while(this.nb.length){var a=this.nb.pop();if(a&&a.readyState<4)a.abort()}for(var b in this)this[b]=null};mc.prototype.Hf=function(){return!(!this.Qe)};mc.prototype.Aa=function(a,b,c,d){if(!this.Qe){if(b)b(null);return 0}var e={id:this.pe++,url:a,cb:b,data:c};if(c||d)this.Ja.push(e);else this.Ja.unshift(e);this.ej();return e.id};mc.prototype.Vl=function(a){for(var b=0;b<this.nb.length;b++){if(this.nb[b]&&this.nb[b].id==a){if(this.nb.xhr)this.nb.xhr.abort();this.nb.splice(b,1,null);this.ej();
return}}this.Wr(a)};mc.prototype.Wr=function(a){for(var b=0;b<this.Ja.length;b++){if(this.Ja[b].id==a){this.Ja.splice(b,1);return}}};mc.prototype.bm=function(a){if(a.status>=400)return null;try{return eval("("+a.text+")")}catch(b){return null}};mc.prototype.Mt=function(){return new XMLHttpRequest};mc.prototype.ej=function(){if(!(this.Ja.length&&this.Qe))return;var a=x.indexOf(this.nb,null);if(a<0)return;var b=this.Ja.pop(),c=this.Qe();c.onreadystatechange=Tb(this,this.Ss,a,b.cb);this.nb[a]={id:b.id,
xhr:c};c.open(b.data?"post":"get",b.url,true);if(b.data){c.setRequestHeader("Content-Type","application/x-www-form-urlencoded");c.setRequestHeader("Content-Length",b.data.length)}c.send(b.data)};mc.prototype.Ss=function(a,b){if(this.nb.length<=a||!this.nb[a])return;var c=this.nb[a].xhr;if(!c||c.readyState!=4)return;if(b){var d={status:c.status,xml:c.responseXML,text:c.responseText};b(d)}delete this.nb[a];this.nb[a]=null;this.ej()};function Xc(a){P.Pa(this);this.cA=document.title;this.wc=location.hash;this.zh=[];this.Uu=a;this.ub=null;this.hq=null;if(document.frames){this.Gw=document.frames["lhid_secrethistory"].document}}Xc.prototype.aa=function(){P.Sa(this);if(this.ur)window.clearInterval(this.ur)};Xc.prototype.Dm=function(){this.wc=location.hash;this.im();this.ur=window.setInterval(o(this,this.Ds),16)};Xc.prototype.Ds=function(){if(location.hash==this.wc)return;this.wc=location.hash;this.im()};Xc.prototype.Pi=function(a,
b){this.zh.push({re:b,vpage:a})};Xc.prototype.im=function(){if(this.Gw)this.Bs();var a,b;for(var c=0;c<this.zh.length;++c){a=this.zh[c].re.exec(this.wc);if(a){b=this.zh[c].vpage;break}}if(!b){a={index:-1,input:this.wc,length:0};b=this.Uu}if(this.hq==b&&this.ub.xa){this.ub.xa(a)}else{if(this.ub)this.ub.jb();this.ub=new b(a)}if(this.ub.title)document.title=this.cA+this.ub.title;this.hq=b};Xc.prototype.Bs=function(){var a=document.frames["lhid_secrethistory"].document,b={title:document.title},c=Li(this.wc),
d=za(this.wc);if(a.body.innerHTML!=d){b.test="window.parent.location.hash!="+c;b.dest=c;b.state=d}else if(a.body.innerHTML==""){b.test="window.parent.location.hash.length>1";b.dest='""';b.state="#"}else{return}var e=ja('<html lang="en-us"><title>{title}</title><script type="text/javascript">function loadparent(){if({test})window.parent.location.hash={dest};}<\/script><body onload="loadparent()">{state}</body></html>',b);a.open();a.write(e);a.close()};function Vc(a){this.e=a;this.ph=1;this.xc=this.lv.p(this);this.Eh=false;this.Nm=1;this.Om=1}Vc.prototype.stop=function(){if(this.Eh)kk(this.xc);this.Eh=false};Vc.prototype.se=function(a){this.e.style.visibility=this.ph?"":"hidden";this.ph=Qc(a,0,0.99);Qd(this.e,this.ph)};Vc.prototype.Xc=function(a,b){var c=this.ph;this.Nm=c;this.Om=a;this.Dn=a-c;var d=Re();this.Uz=d;this.sr=d+Math.abs(this.Dn)*b;this.Rn=this.sr-d;if(this.Rn==0){this.stop();this.se(a)}else{if(!this.Eh)qg(this.xc);this.Eh=true}};Vc.prototype.lv=
function(a){var b=this.Om;if(a<this.sr){var c=(a-this.Uz)/this.Rn;b=c*this.Dn+this.Nm}else{this.stop()}this.se(b)};function Pa(a,b,c,d){P.Pa(this);this.e=m.createElement("span");a.appendChild(this.e);this.Xd=null;var e=this.Cc={lhui_startflag:p("Flag"),lhui_form:p("form"),lhui_cancel:p("cancel")};q(e.lhui_startflag,o(this,this.rt));q(e.lhui_form,o(this,this.lt));q(e.lhui_cancel,o(this,this.Bm));if(b)this.cj(b,c,d)}Pa.prototype.aa=function(){P.Sa(this);y(this.Cc.lhui_startflag);y(this.Cc.lhui_form);y(this.Cc.lhui_cancel)};Pa.prototype.jb=function(){if(this.e)m.removeNode(this.e);if(this.Xd)m.removeNode(this.Xd);
qb("restoreVideo");this.aa()};Pa.prototype.cj=function(a,b,c,d){this.zr=a;this.Md=b;this.Ia=c;this.pC=d;this.Bm()};Pa.prototype.rt=function(){var a=D(km,this.Cc);a.style.visibility="hidden";document.body.insertBefore(a,document.body.firstChild);qb("hideVideo");var b=a.offsetWidth,c=a.offsetHeight,d=pa(this.e);a.style.top=d.y-c/2+"px";a.style.left=d.x+this.e.offsetWidth-b+"px";var e=pa(a);if(e.x<50)a.style.left=d.x-20+"px";e=pa(a);this.e.innerHTML="&nbsp;";a.style.visibility="";var f=Cd(),g=document.body.scrollTop;
if(e.y<g){g=e.y}else if(e.y+c-g>f){g=e.y;var h=10;if(c+h<f)g+=c+h-f}window.scrollTo(e.x,g);this.Xd=a};Pa.prototype.Bm=function(){if(this.Xd)m.removeNode(this.Xd);qb("restoreVideo");tb(this.e,D(xr,this.Cc))};Pa.prototype.qt=function(){if(this.Xd)m.removeNode(this.Xd);qb("restoreVideo");tb(this.e,D("<b>Thank you for reporting this content. Your vigilance helps us improve Web Albums.</b>",this.Cc))};Pa.prototype.lt=function(){var a=l(this.Cc.lhui_form);if(!(a&&a.reason&&a.msg&&this.zr))return;var b=
0;for(var c=0;c<a.reason.length;c++){if(a.reason[c].checked){b=a.reason[c].value}}var d=rc(a.msg.value),e;if(!b){e="You must select one of the provided categories."}else if(d.length>ci){e=gs(d.length,ci)}if(e){alert(e);return}if(!confirm("Are you sure you want to flag this content for review?")){return}var f=["uname="+this.zr];if(this.Md)f.push("aid="+this.Md);if(this.Ia)f.push("iid="+this.Ia);var g=["reason="+b,"msg="+Bc(d)],h="/lh/flagInappropriate?"+f.join("&");Q.Aa(h,null,g.join("&"));this.qt()};
var ci=200;Pa.MAX_FLAG_MESSAGE_LENGTH=ci;var lm="http://picasa.google.com/support/bin/answer.py?answer=44321";Pa.FLAG_HELP_URL=lm;var jm="http://www.google.com/picasa_web_dmca.html";Pa.COPYRIGHT_NOTICE_URL=jm;var im='<a href="'+jm+'" target="_blank">';Pa.COPYRIGHT_LINK_START=im;var mm=1;Pa.HATE=mm;var om=2;Pa.OFFENSIVE=om;var nm=3;Pa.NUDITY=nm;var pm=4;Pa.OTHER=pm;var xr="<a href=\"javascript:_d('{lhui_startflag}')\">"+Im+"</a>",km='<form id="{lhui_form}" class="lhcl_flagger" action="javascript:_d(\'{lhui_form}\')"><h1>'+
Im+"</h1><p>By submitting this form, you're alerting the Picasa team to inappropriate content on this page. <a href=\""+lm+'" target="_blank">What does this mean?</a></p><h2>Why are you reporting this as inappropriate?</h2><p><input type="radio" name="reason" value="'+mm+'" /> This content promotes violence or is hateful.<br /><input type="radio" name="reason" value="'+om+'" /> This content is offensive.<br /><input type="radio" name="reason" value="'+nm+'" /> This content contains nudity.<br /><input type="radio" name="reason" value="'+
pm+'" /> This content is otherwise inappropriate.</p><p>'+as(im,"</a>")+'</p><h2>Briefly tell us why you are reporting this content for review:</h2><p><textarea name="msg"></textarea></p><div class="lhcl_buttons"><input type="submit" value="Submit" /><input type="button" value="Cancel" onclick="_d(\'{lhui_cancel}\')" /></div></form>';Pa.FLAGGER_HTML=km;function L(a,b){P.Pa(this);this.$=a;this.Vk=b;this.e=m.createElement("div");var c=this.e.style;c.position="relative";c.overflow="hidden";c.minWidth=Zc+"px";this.ca=m.createElement("img");this.ca.style.position="absolute";if(typeof this.ca.complete=="undefined")this.ca.complete=true;this.bd=new Image;this.bd.onload=(this.bd.onerror=Ma(this,this.Gp));this.ca.onerror=Ma(this,this.Mk);this.Hx=Ma(this,this.Wx);this.ad=Ma(this,this.xd);this.Ib=Ma(this,this.je);this.ge=Ma(this,this.pc);this.Gc=Ma(this,this.Jb);
this.Hz=o(this,this.ir);this.Ji=new xb(o(this,this.Xz));this.Op=false;this.Pp=false}L.prototype.aa=function(){P.Sa(this);if(this.Ji)this.Ji.aa();var a=this.ca;if(a){a.onload=(a.onerror=(a.ondragstart=null))}a=this.bd;if(a){a.onload=(a.onerror=null)}this.ti(false);this.si(false);this.ae=true;this.Ff(false);for(var b in this)this[b]=null};L.prototype.xm=function(a,b,c,d,e){b=b||Zc;c=c||Zc;var f=b/c;this.mr=false;if(Math.max(b,c)>We){if(b>c){b=We;c=Math.floor(b/f)}else{c=We;b=Math.floor(c*f)}this.mr=
true}if(this.Xg!=a){this.Xe=false;this.Ji.reset();this.xb=false}this.Xg=a;this.Mc=b;this.Bc=c;this.kd=f;this.yg=Math.max(this.Mc,this.Bc);this.Ir=d||null;this.Hr=e||Ei;this.ve();this.Ff(false);this.Lq=1;this.yf=0.5;this.Af=0.5};L.prototype.ve=function(){if(this.ae)return;if(this.ic)m.removeNode(this.ic);if(this.ca)m.removeNode(this.ca);if(this.e)m.removeNode(this.e);this.ic=null;this.ae=true;this.El=false};L.prototype.Qc=function(a){if(!this.ae)return;var b=this.Mg(),c=a==Di?b:_thumbSize;if(!a){var d=
this.dm(this.Xg);for(var e=0;e<d.length;e++){c=Math.max(c,d[e]);if(c>=b)break}}var f=this.cm(c);this.El=true;this.ca.onload=this.Hz;this.jp=c;if(this.onloadstart)this.onloadstart();if(this.ca.src==f&&this.ca.complete){this.ir()}else if(this.bd.src!=f||this.bd.complete){this.Xe=false;this.ca.src=f}};L.prototype.xa=function(){if(this.fb()&&!this.ae){if(!this.ic){var a={url:this.Ir,hl:_LH.locale,mode:this.Hr};this.ic=D(eo,a);this.e.appendChild(this.ic)}this.Mg();return}var b=this.Mg(),c=this.cm(b);if(!this.xb&&
this.bd.src!=c&&!this.Xe){this.xb=true;this.Rx=b;if(this.onloadstart)this.onloadstart();this.bd.src=c}};L.prototype.fb=function(){return Mf&&this.Ir};L.prototype.ir=function(){var a=this.ca;this.Tl(a,this.jp);if(!this.El)return;this.ae=(this.El=false);a.onload=null;this.Lm();var b=this.Mg();this.Vk.appendChild(this.e);this.e.appendChild(a);this.Mg();if(this.onshow)this.onshow();if(this.onload&&this.jp==b&&!this.fb())this.onload()};L.prototype.Gp=function(a){this.Tl(this.bd,this.Rx);if(!this.xb)return;
this.Xe=false;this.ca.src=this.bd.src;this.Lm();if(!this.hidden&&this.onload)this.onload();this.Ji.ma(1000)};L.prototype.Mk=function(a){this.Xe=true;if(this.onError)this.onError(a);if(this.ca.onload)this.ca.onload()};L.prototype.Lm=function(){if(this.Xe)return;var a=this.ca;this.Xg=Eo(a.src);var b=this.Mc,c=this.Bc;if((b-c)*(a.width-a.height)<0){this.Mc=c;this.Bc=b;this.kd=c/b}};L.prototype.Xz=function(){if(!this.ca)return;this.xb=false;this.xa()};L.prototype.dm=function(a){if(!og[a])og[a]=[];return og[a]};
L.prototype.Tl=function(a,b){var c=Eo(a.src),d=this.dm(c);xh(d,b)};L.prototype.cm=function(a){a=a||We;if(a<Math.max(this.Mc,this.Bc)||this.mr){a=Fi(a);return this.Xg+"?imgmax="+a}else{return this.Xg}};L.prototype.Ff=function(a){if(this.Zg==a)return;this.Zg=a;this.si(a);this.ti(false);this.ca.ondragstart=a?this.Hx:null;if(!this.ae)this.xa()};L.prototype.Qo=function(){return this.Zg};L.prototype.Co=function(){return this.Hk/this.yg};L.prototype.xd=function(a){this.Tp=a.clientX;this.Up=a.clientY;this.si(false);
this.ti(true);cc(a)};L.prototype.Jb=function(a){this.si(true);this.ti(false)};L.prototype.je=function(a){var b=this.Tp-a.clientX,c=this.Up-a.clientY;this.Tp=a.clientX;this.Up=a.clientY;this.yf+=b/this.Ln;this.Af+=c/this.Kn;this.Mn()};L.prototype.pc=function(a){if(!(a.relatedTarget||a.toElement))this.Jb(a)};L.prototype.ti=function(a){if(a==this.Pp)return;this.Pp=a;var b=a?wa:Aa;b(document,"mouseup",this.Gc);b(document,"mousemove",this.Ib);b(document,"mouseout",this.ge)};L.prototype.si=function(a){if(a==
this.Op)return;this.Op=a;var b=a?wa:Aa;b(this.ca,"mousedown",this.ad)};L.prototype.Wx=function(a){cc(a)};L.prototype.Mg=function(){var a=this.$.Ur(this),b=a.w,c=a.h,d=a.f;if(this.fb()){c-=ng}var e=b/c,f=this.Mc,g=this.Bc;if(this.fb()){f*=10000;g*=10000}if(f>b||g>c){var h=Math.min(Zc,this.yg);if(this.fb()&&this.Hr!=Ei){h=0}if(this.kd>=e){if(f<g)h*=this.kd;f=Qc(b,h,f);g=f/this.kd}else{if(g<f)h/=this.kd;g=Qc(c,h,g);f=g*this.kd}if(this.fb()){f=Math.floor(f);g=Math.floor(g)}else{var i=Math.min(Fi(Math.max(f,
g)),this.yg);if(f>g){f=i;g=Math.floor(f/this.kd)}else{g=i;f=Math.floor(g*this.kd)}}}this.Hk=Math.max(f,g);this.EC=this.Hk/this.yg;if(this.Zg){f=this.Lq*this.Mc;g=this.Lq*this.Bc}if(!d){if(this.Zg){c=Qc(c,Zc,g)}else{c=g}}this.Ln=f;this.Kn=g;this.fy=b;this.ey=c;if(!this.ae)this.Mn();return this.Zg?this.yg:this.Hk};L.prototype.Mn=function(){var a=this.Ln,b=this.Kn,c=this.fy,d=this.ey,e=this.ca.style,f=0,g=0;if(this.Xe){e.border="2px solid red";f=4;g=4}else{e.border=""}e.width=Math.max(a-f,0)+"px";e.height=
Math.max(b-g,0)+"px";var h=c/2,i=d/2;this.yf=Qc(this.yf,h/a,1-h/a);this.Af=Qc(this.Af,i/b,1-i/b);e.cursor="";if(a<=c){e.left=h-a/2+"px"}else{e.left=h-a*this.yf+"px";e.cursor="move"}if(b<=d){e.top=i-b/2+"px"}else{e.top=i-b*this.Af+"px";e.cursor="move"}if(this.ic){var k=this.ic.style;k.width=Math.max(a,0)+"px";k.height=Math.max(b+ng,0)+"px";k.top=i-b/2+"px";k.left=h-a/2+"px"}if(this.fb()){d+=ng}this.e.style.width=c<=Zc?Zc+"px":"";this.e.style.height=Math.max(d,0)+"px"};var Fi=function(a){var b=co;for(var c=
b.length-1;c>0;c--){if(a>=b[c])return b[c]}return b[0]};L.dD=Fi;var og={};L.sizecache=og;var ng=27;L.VIDEO_CONTROLS_HEIGHT=ng;var Ei="embedded";L.VIDEO_EMBEDDED_MODE=Ei;L.MIN_VIDEO_SIZE=240;var Zc=512;L.MIN_SIZE=Zc;var We=1600;L.MAX_SIZE=We;var bo=0;L.NORMAL=bo;var Di=1;L.FULL_SIZE=Di;var ao=2;L.FAST=ao;var co=[72,128,144,176,288,400,512,576,640,720,800,912,1024,1152,1280,1440,1600];L.SIZE_LIST=co;var eo='<embed style="position:absolute" type="application/x-shockwave-flash" src="http://video.google.com/googleplayer.swf?videoUrl={url}&hl={hl}&autoplay=yes" allowScriptAccess="always" swLiveConnect="true" quality="best" bgcolor="#eeeeee" scale="noScale" salign="TL" width="240" height="240" FlashVars="playerMode={mode}"></embed>';
L.VIDEO_EMBED_HTML=eo;function La(a,b,c,d,e){P.Pa(this);this.$=a;this.e=b;this.q=c;this.Zn=!(!d);this.io=!(!e);this.ec=o(this,this.Ub);wa(window,"resize",this.ec);this.tx=o(this,this.Wi);this.rx=o(this,this.eh);this.NC=o(this,this.Xi);this.gv=o(this,this.Js);this.Tz=o(this,this.At);this.Hi=new xb(o(this,this.Em));this.ka=-1;this.qA=-1;this.IC=null;this.Ja=[];this.ca=null;this.Ya=null;this.xb=false;this.nk=false;this.Ii=false;this.ho=1;q("movieDone",o(this,this.eh))}La.prototype.aa=function(){P.Sa(this);if(this.Hi)this.Hi.aa();
if(this.ca)this.ca.aa();if(this.Ya)this.Ya.aa();if(this.ec)Aa(window,"resize",this.ec);y("movieDone");for(var a in this)this[a]=null};La.prototype.Oc=function(){return this.ka};La.prototype.Nh=function(){return this.ca};La.prototype.bh=function(a,b){if(a<0||a>=this.q.length)return false;if(b)this.nn();this.qA=a;this.Ja.push(a);this.jm();return true};La.prototype.nn=function(){this.Ja.length=0;if(this.Ya)this.Ya.onshow=null;this.xb=false};La.prototype.rm=function(){this.bh(this.ka,true)};La.prototype.mt=
function(a){this.io=!(!a)};La.prototype.jm=function(){this.Ii=false;this.Hi.reset();if(this.xb||this.Ja.length==0)return;this.xb=true;this.nk=false;this.yq=false;var a=this.Ja.shift();this.ho=a>this.ka?1:-1;if(this.ca)this.ca.onload=null;if(this.qm(a)){this.ka=a;this.Ya.onshow=this.Tz;this.Ya.onload=this.rx;this.Ya.onError=this.gv;this.Ya.onloadstart=this.tx;var b=bo;if(this.Ja.length){b=ao}else if(this.io){b=Di}this.Ya.Qc(b)}};La.prototype.qm=function(a){if(!this.q){return false}var b=this.q[a];
if(!b){return false}if(!this.Ya){this.Ya=new L(this,this.e)}this.Ya.xm(b.s,b.w,b.h,b.vsurl||null,this.Zn?"mini":"normal");if(j.userAgent.IE&&Mf&&b.vsurl){this.hasVideo=true}return true};La.prototype.At=function(){var a=this.ca;this.ca=this.Ya;this.Ya=a;if(this.onshow)this.onshow();if(a){a.ve();a.onloadstart=(a.onshow=(a.onload=(a.onError=null)))}this.xb=false;if(this.Ja.length){this.jm()}else{this.Hi.ma(200)}};La.prototype.Wi=function(){if(this.onloadstart)this.onloadstart()};La.prototype.eh=function(){if(this.onload)this.onload();
this.nk=true;if(this.yq)this.Xi();else if(this.Ii)this.Em()};La.prototype.Em=function(){if(!this.Ii&&this.onstopped)this.onstopped();this.Ii=true;if(!this.ca||this.Ja.length)return;if(this.nk){this.yq=true;this.Xi()}else{this.ca.xa()}};La.prototype.Js=function(a){if(this.onError){this.onError()}if(this.Ya&&this.Ya.onload){this.Ya.onload()}};La.prototype.Xi=function(){var a=this.q.length;if(a<2)return;var b=this.ka+this.ho;if(b<0)b=1;if(b>a-1)b=a-2;if(this.qm(b)){this.Ya.xa()}};La.prototype.Ub=function(){var a=
self.outerWidth||self.innerHeight||document.documentElement.clientHeight,b=self.outerHeight||Cd();if(a!=this.jx||b!=this.ix){this.jx=a;this.ix=b;if(this.ca)this.ca.xa();if(this.onresize)this.onresize()}};La.prototype.Ur=function(a){return{f:this.Zn,w:this.e.offsetWidth,h:this.$.Ri(a)}};function va(a){P.Pa(this);this.$=a;var b={lhf_prev:p("Previous"),lhf_next:p("Next"),lhf_exit:p("Exit"),lhf_play:p("Play"),lhf_stop:p("Pause"),lhf_fast:p("Faster"),lhf_slow:p("Slower"),lhf_show:p("ToggleCaptions")};q(b.lhf_prev,o(a,a.Ef));q(b.lhf_next,o(a,a.Df));q(b.lhf_exit,o(a,a.ah));q(b.lhf_play,o(a,a.pm));q(b.lhf_stop,o(a,a.Jd));q(b.lhf_fast,o(a,a.yt));q(b.lhf_slow,o(a,a.xt));q(b.lhf_show,o(this,this.Fm));this.Iu=b;this.Ib=Ma(this,this.Ns);wa(document,"mousemove",this.Ib);this.We=new xb(o(this,
this.dh));var c=D(qo,{});c.style.display="none";document.body.appendChild(c);this.fi=c;this.gi=new xb(o(this,this.ut));var d=new ee(document.body,"lhcl_slideshow_feedback");this.Tj=d;this.Gh=new xb(o(this,this.fm));this.Fh=new Vc(d.div);this.Fh.se(0);var e=m.createElement("div");document.body.appendChild(e);e.className="lhcl_slideshow_container";this.vn=e;var f=new ee(e,"lhcl_slideshow_caption");this.uj=f;var g=new ee(e,"lhcl_slideshow_controls");this.uh=g;if(!j.userAgent.IE){Qd(f.bg,0.7);Qd(g.bg,
0.7);Qd(d.bg,0.7)}var h=m.createElement("table");g.fg.appendChild(h);var i=m.createElement("tbody");h.appendChild(i);var k=m.createElement("tr");i.appendChild(k);var n=m.createElement("td");k.appendChild(n);this.OC=new wb(n,"img/slideshowprev.gif","img/slideshowprev_on.gif",'javascript:_d("'+b.lhf_prev+'")');var s=m.createElement("td");k.appendChild(s);this.Qz=new wb(s,"img/slideshowpause.gif","img/slideshowpause_on.gif",'javascript:_d("'+b.lhf_stop+'")');this.mq=new wb(s,"img/slideshowplay.gif",
"img/slideshowplay_on.gif",'javascript:_d("'+b.lhf_play+'")');this.mq.Qc(false);var u=m.createElement("td");k.appendChild(u);this.GC=new wb(u,"img/slideshownext.gif","img/slideshownext_on.gif",'javascript:_d("'+b.lhf_next+'")');var z=m.createElement("td");k.appendChild(z);this.sB=new wb(z,"img/slideshowminus.gif","img/slideshowminus_on.gif",'javascript:_d("'+b.lhf_fast+'")');this.tr=m.createElement("td");k.appendChild(this.tr);var v=m.createElement("td");k.appendChild(v);this.fD=new wb(v,"img/slideshowplus.gif",
"img/slideshowplus_on.gif",'javascript:_d("'+b.lhf_slow+'")');var A=m.createElement("td");k.appendChild(A);this.Ei=m.createElement("a");this.Ei.href='javascript:_d("'+b.lhf_show+'")';A.appendChild(this.Ei);this.Ei.innerHTML="hide captions";var T=m.createElement("td");k.appendChild(T);this.rB=new wb(T,"img/slideshowexit.gif","img/slideshowexit_on.gif",'javascript:_d("'+b.lhf_exit+'")');this.Rf=new Vc(g.contents);this.Rf.se(0);this.tj=new Vc(f.contents);this.tj.se(0);this.zb=true;this.Ng=true}va.prototype.aa=
function(){P.Sa(this);if(this.Ib)Aa(document,"mousemove",this.Ib);if(this.Gh)this.Gh.aa();if(this.gi)this.gi.aa();if(this.We)this.We.aa();this.Rf.stop();this.tj.stop();this.Fh.stop();var a=this.Iu;if(a){y(a.lhf_prev);y(a.lhf_next);y(a.lhf_exit);y(a.lhf_play);y(a.lhf_stop)}if(this.uj)this.uj.aa();if(this.uh)this.uh.aa();if(this.Tj)this.Tj.aa();if(this.fi)m.removeNode(this.fi);if(this.vn)m.removeNode(this.vn);for(var b in this)this[b]=null};va.prototype.Qc=function(){this.We.reset();this.Rf.Xc(1,Hi);
if(!this.Rp)this.ve(mo)};va.prototype.ve=function(a){this.We.reset();if(a)this.We.ma(a);else this.dh()};va.prototype.bj=function(a){if(!a&&!this.zb){this.fm();this.Gh.reset();return}if(a==this.zb)return;this.Qz.Qc(a);this.mq.Qc(!a);var b="pause";if(a){this.ve();b="play"}else{this.Qc()}this.Tj.fg.innerHTML=b;this.Fh.Xc(1,oo);this.Gh.ma(no);this.zb=a};va.prototype.fm=function(){this.Fh.Xc(0,po)};va.prototype.aj=function(a){if(a){this.gi.ma(500)}else{this.gi.reset();this.fi.style.display="none"}};va.prototype.dj=
function(a){var b=a?1:0;this.tj.Xc(b,lo)};va.prototype.Zi=function(a){this.Ba=a;if(!this.Ng)return;if(a){a=Xe(a);this.uj.fg.innerHTML=a;this.dj(true)}else{this.dj(false)}};va.prototype.Cv=function(){return this.uh.bg.offsetHeight};va.prototype.Fm=function(){this.Ng=!this.Ng;var a="show captions";if(this.Ng){this.Zi(this.Ba);a="hide captions"}else if(this.Ba){if(this.Ba)this.dj(false)}this.Ei.innerHTML=a};va.prototype.lh=function(a){var b=a/1000;this.tr.innerHTML="seconds: "+b;this.Qc()};va.prototype.ut=
function(){this.fi.style.display=""};va.prototype.dh=function(){if(this.Rf){this.Rf.Xc(0,Hi)}};va.prototype.Ns=function(a){if(a.clientX==this.yf&&a.clientY==this.Af)return;this.Qc();this.yf=a.clientX;this.Af=a.clientY;this.Rp=false;for(var b=a.target;b!=null;b=b.parentNode){if(b==this.uh.div){this.We.reset();this.Rp=true;break}}};function ee(a,b){P.Pa(this);var c={fg:p("fg"),bg:p("bg"),outer:p("table"),inner:p("inner"),className:b};this.e=D(ro,c);a.appendChild(this.e);this.contents=l(c.inner);this.div=
l(c.outer);this.fg=l(c.fg);this.bg=l(c.bg);if(j.userAgent.IE){this.fg.onresize=o(this,this.et)}}ee.prototype.aa=function(){P.Sa(this);if(this.bg)this.bg.onresize=null;if(this.e)m.removeNode(this.e)};ee.prototype.et=function(){this.bg.style.height=this.fg.offsetHeight-1+"px"};function wb(a,b,c,d){P.Pa(this);var e={anchor:p("anchor"),off_id:p("button"),off_src:b,on_id:p("buttonOn"),on_src:c,mouseover:p("mouseover"),mousedown:p("mousedown"),mouseout:p("mouseout"),mouseup:p("mouseup")};this.b=e;this.e=
D(ko,e);a.appendChild(this.e);this.Nt=l(e.anchor);this.Nt.href=d;this.yd=l(e.on_id);if(j.userAgent.IE){this.yd.style.visibility="hidden"}else{this.ie=new Vc(this.yd);this.ie.se(0)}q(e.mouseover,o(this,this.Ps));q(e.mouseout,o(this,this.Os));q(e.mousedown,o(this,this.Ms));q(e.mouseup,o(this,this.Qs))}wb.prototype.aa=function(){P.Sa(this);var a=this.b;y(a.mouseover);y(a.mouseout);y(a.mousedown);y(a.mouseup);if(this.ie)this.ie.stop()};wb.prototype.Qc=function(a){this.e.style.display=a?"":"none"};wb.prototype.Ps=
function(){if(!j.userAgent.IE){this.ie.Xc(0.5,Gi)}};wb.prototype.Os=function(){if(j.userAgent.IE){this.yd.style.visibility="hidden"}else{this.ie.Xc(0,Gi)}};wb.prototype.Ms=function(){if(j.userAgent.IE){this.yd.style.visibility=""}else{this.ie.Xc(1,0)}};wb.prototype.Qs=function(){if(j.userAgent.IE){this.yd.style.visibility="hidden"}else{this.ie.Xc(0.5,0)}};var mo=3000;va.CONTROL_DISPLAY_DURATION=mo;var Hi=300;va.CONTROL_FADE_DURATION=Hi;var lo=300;va.CAPTION_FADE_DURATION=lo;var oo=100;va.FEEDBACK_FADE_IN_DURATION=
oo;var po=300;va.FEEDBACK_FADE_OUT_DURATION=po;var no=2000;va.FEEDBACK_DISPLAY_DURATION=no;var qo='<div class="lhcl_slideshow_loading">'+be+"</div>";va.LOADING_HTML=qo;var ro='<table id="{outer}" class="{className}"><tr><td><div id="{inner}" style="position:relative;height:100%"><div id="{bg}" class="{className}_bg" style="position:absolute;z-index:2;width:100%;height:100%"></div><div id="{fg}" class="{className}_fg" style="position:relative;z-index:3;width:100%"></div></div></td></tr></table>';ee.OVERLAY_HTML=
ro;var Gi=200;wb.FADE_DURATION=Gi;var ko='<table><tr><td><a id="{anchor}" onmouseover="_d(\'{mouseover}\')" onmouseout="_d(\'{mouseout}\')" onmousedown="_d(\'{mousedown}\')" onmouseup="_d(\'{mouseup}\')"><img id="{on_id}" src="{on_src}" style="position:absolute;" ondragstart="return false" /><img id="{off_id}" src="{off_src}" onmousedown="return false" /></a></td></tr></table>';wb.BUTTON_HTML=ko;function ia(a){P.Pa(this);this.kk=[];for(var b=document.body.firstChild;b!=null;b=b.nextSibling){if(b.style&&b.style.display==""){b.style.display="none";this.kk.push(b)}}var c=document.body;this.e=m.createElement("div");c.appendChild(this.e);this.ju=Ws(c).backgroundColor;c.style.background="#000";if(j.userAgent.IE)document.documentElement.style.overflow="hidden";else c.style.overflow="hidden";this.q=_photo;this.r=new va(this);this.fa=new La(this,this.e,this.q,true);this.fa.onshow=o(this,this.Vs);
this.fa.onload=o(this,this.Ks);this.fa.onloadstart=o(this,this.Ls);this.cd=Oi(this.q,"id");this.ef=new xb(o(this,this.Tr));this.zb=true;this.xb=false;this.mb=4000;Ii(this);this.r.lh(this.mb);this.Ze=Ma(this,this.Tb);this.vg=Ma(this,this.Id);this.Of=o(this,this.Rc);wa(document,"keydown",this.Ze);wa(document,"keyup",this.vg);wa(window,"blur",this.Of);this.dc=new xb(o(this,this.fh));this.Dc=false;this.cc=0;this.xa(a);q("f",o(this,this.qs))}ia.prototype.aa=function(){P.Sa(this);y("f");if(this.fa)this.fa.aa();
if(this.r)this.r.aa();if(this.Ze){Aa(document,"keydown",this.Ze);Aa(document,"keyup",this.vg);Aa(window,"blur",this.Of)}if(this.dc)this.dc.aa();for(var a in this)this[a]=null};ia.prototype.jb=function(){this.Jd();while(this.kk.length)this.kk.pop().style.display="";var a=document.body.style;a.background=this.ju;if(j.userAgent.IE){document.documentElement.style.overflow=""}else if(j.userAgent.GECKO){a.overflow="-moz-scrollbars-vertical"}else{a.overflow=""}this.Jd();if(this.e)m.removeNode(this.e);this.aa()};
ia.prototype.xa=function(a){var b=a[1],c=this.cd[b];if(c==undefined){location.replace(location.href.replace(/#.*/,"#unknown-"+b));return}this.title=" - "+this.q[c].t;this.ka=c;this.fa.mt(!this.Dc);this.fa.bh(c)};ia.prototype.Nb=function(a,b){var c=this.ka+a,d=this.q.length;if(b){while(c<0)c+=d;c%=d}if(c<0||c>=d)return false;if(j.userAgent.IE&&Mf){if(this.fa.hasVideo&&this.q[c].vsurl){so(this);window.open(location.href.replace(/#.*/,"#s"+this.q[c].id),"_top");return true}}location.replace(location.href.replace(/#.*/,
"#s"+this.q[c].id));return true};ia.prototype.Df=function(){this.Jd();this.Nb(1,true)};ia.prototype.Ef=function(){this.Jd();this.Nb(-1,true)};ia.prototype.pm=function(){if(this.zb)return;this.zb=true;this.r.bj(true);if(!this.xb)this.ef.ma(this.mb)};ia.prototype.Jd=function(){this.zb=false;this.r.bj(false);this.ef.reset()};ia.prototype.ah=function(){location=_album.link};ia.prototype.yt=function(){this.mb=Math.max(this.mb-1000,1000);this.r.lh(this.mb);if(this.zb)this.ef.ma(this.mb)};ia.prototype.xt=
function(){this.mb=Math.min(this.mb+1000,20000);this.r.lh(this.mb);if(this.zb)this.ef.ma(this.mb)};ia.prototype.Ri=function(a){var b=Cd();if(a.fb()){b-=this.r.Cv();if(b<0)b=0}return b};ia.prototype.Vs=function(){this.r.aj(false);var a=this.fa.Oc();if(!this.fa.Nh().fb()){this.r.Zi(this.q[a].c)}else{this.r.Zi("")}if(this.Dc)this.Nb(this.lf,true)};ia.prototype.Ls=function(){this.xb=true;this.r.aj(true)};ia.prototype.Ks=function(){this.xb=false;this.r.aj(false);if(this.zb)this.ef.ma(this.mb)};ia.prototype.Tb=
function(a){if(a.altKey||a.metaKey||a.ctrlKey)return;var b=a.target.nodeName.toLowerCase();if(b=="textarea"||b=="input"||b=="select")return;var c=parseInt(String.fromCharCode(a.keyCode),10);if(c===0||c){this.mb=c*1000;this.r.lh(this.mb);if(this.zb)this.ef.ma(this.mb);return}switch(a.keyCode){case 27:this.ah();cc(a);break;case 37:if(this.cc!=37){this.Ef();this.ye(-1)}this.cc=37;cc(a);break;case 39:if(this.cc!=39){this.Df();this.ye(1)}this.cc=39;cc(a);break;case 32:if(this.zb)this.Jd();else this.pm();
cc(a);break}};ia.prototype.Id=function(a){switch(a.keyCode){case 37:case 39:this.Rc();break}};ia.prototype.ye=function(a){this.Rc();this.lf=a;if(a!=0)this.dc.ma(400)};ia.prototype.Rc=function(){this.dc.reset();this.Dc=false;this.cc=0};ia.prototype.fh=function(){this.Dc=true;this.Jd();this.Nb(this.lf,true)};ia.prototype.Tr=function(){this.Nb(1,true)};ia.prototype.qs=function(a,b){if(a=="stateChanged"){var c=b.split(",");if(c[1].indexOf("completed")>-1){qb("movieDone")}}};var so=function(a){if(a&&a.r){var b=
a.r.zb?"1":"0",c=a.r.Ng?"1":"0",d=a.mb;pc(pg,b+","+c+","+d)}};ia.SaveSettings=so;var Ii=function(a){if(a&&a.r){var b=bc(pg);if(b&&b.length){var c=b.split(",");if(c.length==3){a.zb=c[0]=="1";a.r.bj(a.zb);if(c[1]!="1")a.r.Fm();a.mb=parseInt(c[2],10)}}}$a.remove(pg)};ia.RestoreSettings=Ii;var pg="_lh_slideshow";ia.SLIDESHOW_COOKIE=pg;function vb(a,b,c){this.$=a;this.yb=_photo;this.Mq=!(!c);this.b={albumlink:_album.link,albumlinkID:p("lhid_albumlink"),prevboxID:p("prevbox"),nextboxID:p("nextbox"),zoomID:p("zoom"),zoomTextID:p("zoomtext"),toolID:p("tools"),emailID:p("email")};var d=this.Mq?sn:qn;this.e=D(d,this.b);b.appendChild(this.e);if(!_authuser.user){l(this.b.emailID).style.display="none"}if(_authuser.isOwner&&!this.Mq){this.uc={rotateFunc:p("func"),leftID:p("leftrotate"),rightID:p("rightrotate"),leftOn:"img/rotateleft_normal.gif",
leftOff:"img/rotateleft_ghosted.gif",rightOn:"img/rotateright_normal.gif",rightOff:"img/rotateright_ghosted.gif"};l(this.b.toolID).innerHTML=ja(rn,this.uc);q(this.uc.rotateFunc,o(this,this.Ts))}q(this.b.zoomID,Ma(this.$,this.$.Gm));this.xe(false);this.zoom=false;this.li=p("prev");this.ji=p("next");var e={src:"img/left_normal.gif",id:this.li,alt:"Previous"},f={src:"img/right_normal.gif",id:this.ji,alt:"Next"},g=D(ui,e),h=D(ui,f);g.style.visibility=(h.style.visibility="hidden");l(this.b.prevboxID).appendChild(g);
l(this.b.nextboxID).appendChild(h);q(this.li,Tb(this,this.mm,-1));q(this.ji,Tb(this,this.mm,1));this.jd(true);this.TC=o(this,this.gt)}vb.prototype.aa=function(){if(this.e)m.removeNode(this.e);y(this.b.zoomID);y(this.li);y(this.ji);if(this.uc)y(this.uc.rotateID);for(var a in this)this[a]=null};vb.prototype.jd=function(a){if(!a&&!this.$.Ul()){return}if(this.uc){l(this.uc.leftID).src=a?this.uc.leftOff:this.uc.leftOn;l(this.uc.rightID).src=a?this.uc.rightOff:this.uc.rightOn;this.$u=a}};vb.prototype.Hm=
function(a,b){var c=l(this.li),d=l(this.ji);if(a){c.style.visibility="";c.href=location.href;c.hash=a}else{c.style.visibility="hidden";c.blur()}if(b){d.style.visibility="";d.href=location.href;d.hash=b}else{d.style.visibility="hidden";d.blur()}};vb.prototype.Pc=function(a){this.qf(this.yb[a])};vb.prototype.qf=function(a){this.xe(false);this.q=a;this.Ia=this.q.id;var b=a.user?a.user.name:_user.name,c=a.album?a.album.ctitle:"";if(!c&&_album){c=_album.name}var d=["uname="+b,"aname="+c,"iid="+this.Ia],
e="/lh/emailPhoto?"+d.join("&");l(this.b.emailID).href=e;l(this.b.emailID+"_t").innerHTML=this.q.vsurl?"Share Video":oi;var f=l(this.b.albumlinkID);if(f){f.href=this.b.albumlink}this.jd(!(!this.q.vsurl))};vb.prototype.xe=function(a,b){var c=l(this.b.zoomID),d=l(this.b.zoomTextID);if(b){a=false;c.src="img/zoom_ghosted.gif";c.title=""}else{c.src=a?"img/zoom_active.gif":"img/zoom_normal.gif";c.title=a?"Zoom out":"Zoom in"}d.style.display=a?"":"none";c.className=b?"":"lhcl_fakelink";this.zoom=a};vb.prototype.Ts=
function(a){if(this.$u||!this.$.Ti())return;var b=this.Ia,c=_album.id,d=_user.name;if(this.q&&this.q.album&&this.q.user){b=this.q.id;c=this.q.album.id;d=this.q.user.name}var e=["selectedphotos="+b,"optgt="+a,"uname="+d,"aid="+c,"noredir=true"];this.Bd=b;var f=_selectedPhotosPath+"&"+e.join("&");N.send(f,tn.p(this),"POST")};var tn=function(a){if(this.$.gc(a)||this.$.Nc(a)){this.$.Kd();return}this.$.Cf(this.Bd,true)};vb.prototype.gt=tn;vb.prototype.mm=function(a,b){if(b==0){this.mouseups++}else if(b==
1||b==2&&this.mouseups>=2){this.$.Nb(a);this.mouseups=0}};var qn='<div><table class="lhcl_photonav"><tr><td width="50%"><table width="100%"><tr><td width="100%"><span class="lhcl_albumlink" ><a id="{albumlinkID}" href="{albumlink}">&laquo; '+ri+'</a></span></td><td><div class="lhcl_photoArrowBox" id="{prevboxID}" style="background-image:url(img/left_ghosted.gif)"></div></td></tr></table></td><td><table width="100%" class="lhcl_editbuttons"><tr><td><div class="lhcl_photoArrowBox" id="{nextboxID}" style="background-image:url(img/right_ghosted.gif)"></div></td><td width="100%"></td><td class="lhcl_toolspace"><span id="{toolID}"></span></td><td><span><a class="lhcl_nounderline" id="{emailID}"><div class="lhcl_cbbox lhcl_cbox_disabled"><p class="lhcl_cbdesc"></p><p class="lhcl_cblink"><em><img src="img/share_icon.gif"  /> <span id="{emailID}_t">'+
oi+'</span></em></p></div></a><span></td><td class="lhcl_toolspace"><span><img src="img/zoom_normal.gif" title="Zoom In" class="lhcl_fakelink"id="{zoomID}" onclick="_d(\'{zoomID}\')" /></span></td></tr></table></td></tr></table><div class="lhcl_zoomtext" id="{zoomTextID}" style="display:none">'+Lm+"</div></div>";vb.NAV_TOOLBAR_HTML=qn;var ui='<a href="" id="{id}" onclick="return false"><img src="{src}" title="{alt}" onmouseup="_d(\'{id}\', 0); return false" onmousedown="_d(\'{id}\', 1); return false" ondblclick="_d(\'{id}\', 2); return false" /></a>';
vb.NAV_ARROW_HTML=ui;var rn='<img id="{leftID}" src="{leftOff}" title="Rotate Left" class="lhcl_fakelink" onclick="_d(\'{rotateFunc}\', \'ROTATE270\')" /><img id="{rightID}" src="{rightOff}" title="Rotate Right" class="lhcl_fakelink" onclick="_d(\'{rotateFunc}\', \'ROTATE90\')" />';vb.NAV_TOOLBAR_TOOLS_HTML=rn;var sn='<div><table class="lhcl_photonav"><tr><td width="50%"><table width="100%"><tr><td width="100%"></td><td><div class="lhcl_photoArrowBox" id="{prevboxID}" style="background-image:url(img/left_ghosted.gif)"></div></td></tr></table></td><td><table width="100%" class="lhcl_editbuttons"><tr><td id="indexbox"><span><b>'+
be+'</b></span></td><td><div class="lhcl_photoArrowBox" id="{nextboxID}" style="background-image:url(img/right_ghosted.gif)"></div></td><td width="100%"></td><td class="lhcl_toolspace"><span id="{toolID}"></span></td><td><span><a class="lhcl_nounderline" id="{emailID}"><div class="lhcl_cbbox lhcl_cbox_disabled"><p class="lhcl_cbdesc"></p><p class="lhcl_cblink"><em><img src="img/share_icon.gif"  /> <span id="{emailID}_t">'+oi+'</span></em></p></div></a><span></td><td class="lhcl_toolspace"><span><img src="img/zoom_normal.gif" title="Zoom In" class="lhcl_fakelink"id="{zoomID}" onclick="_d(\'{zoomID}\')" /></span></td></tr></table></td></tr></table><div class="lhcl_zoomtext" id="{zoomTextID}" style="display:none">'+
Lm+"</div></div>";vb.SEARCH_NAV_TOOLBAR_HTML=sn;function fa(a,b,c,d,e){this.$=a;this.yb=c?c:_photo;this.kl=e;var f={lhui_albumtitle:Xe(_album.title),lhui_indexbox:p("indexbox"),lhui_infobox:p("infobox"),lhui_exifbox:p("exifbox"),lhui_downloadlink:p("download"),lhui_albumlink:p("lhid_viewalbum"),lhui_slideshowlink:p("slideshow"),lhui_togglelink:p("toggle"),lhui_links:p("links")};if(d){f.lhui_slideshow_link_markup=""}else{f.lhui_slideshow_link_markup=ja(pn,f)}var g=this.kl?on:ln;this.g=D(g,f);b.appendChild(this.g);this.Lw=l(f.lhui_indexbox);this.lp=
l(f.lhui_infobox);this.Xn=l(f.lhui_exifbox);this.Lj=l(f.lhui_downloadlink);this.kj=l(f.lhui_albumlink);if(d){this.Al=null}else{this.Al=l(f.lhui_slideshowlink)}this.fA=l(f.lhui_togglelink);if(_features.cart&&Y(_updateCartPath)&&(e||_album.prints)){this.ld=m.createElement("div");l(f.lhui_links).appendChild(this.ld);this.cartMsgId=p("cartmsg");var h=D(kn,this);l(f.lhui_links).appendChild(h);this.By=Tb(this,this.Jm,false);this.au=Tb(this,this.Jm,true);this.yu=o(this,this.Yr);this.zu=o(this,this.Zr);var i=
bc("_cart1","");if(i.length){var k="/lh/listCart";if(!e){k+="?uname="+_user.name}Q.Aa(k,this.zu)}}this.Il=f.lhui_togglelink;q(this.Il,o(this,this.Ft));this.wl=false;var n=document.getElementById("hdf_profile");if(n){n.innerHTML+='<div id="debug_meta_rss"></div>'}}fa.prototype.aa=function(){if(this.jv)m.removeNode(this.jv);if(this.g)m.removeNode(this.g);if(this.Il)y(this.Il);for(var a in this)this[a]=null};fa.prototype.Pc=function(a){this.ka=a;var b=this.yb[a];if(!b){return}b.album=b.album||_album;
if(!Y(b.ka)){b.ka=a}this.qf(b)};fa.prototype.Ho=function(){return(this.Wb?this.Wb.album:null)||_album};fa.prototype.Ov=function(){return this.Wb?this.Wb.user:_user};fa.prototype.uf=function(){return this.totalPhotoCount||this.yb.length};fa.prototype.qf=function(a){this.Wb=a;var b=this.uf();if(b>0){this.Lw.innerHTML="<b>"+rs(a.ka+1,b)+"</b>"}this.xa(a.b?a.b:null);if(a.vsurl){this.Lj.innerHTML="";l("lhid_flashMsg").style.display=Mf?"none":""}else{this.Lj.href=a.s+"?imgdl=1";this.Lj.innerHTML=mi;l("lhid_flashMsg").style.display=
"none"}if(this.kj&&a.album){this.kj.innerHTML=ri;this.kj.href=a.album.link}if(this.Al){this.Al.href=location.href.replace(/#/,"#s")}if(_features.cart&&this.ld){this.fj(a,false)}};fa.prototype.xa=function(a){if(!a||!a.exif){tb(this.lp,D(lg,{}));this.Km(null);return}var b=l("debug_meta_rss");if(b){b.innerHTML=ja('<a href="/lh/rssPhoto?uname={username}&amp;iid={id}&js=1">RSS</a><br />',{username:_user.name,id:a.id})}a.datestring=a.exif.time||a.o;var c=this.Ov();a.username=c?c.name:be;var d=this.Ho();
a.albumname=d?d.name:be;a.sizestring=qs(a.width+"&times;"+a.height)+" &#8211; "+ts(a.kbytes);tb(this.lp,D(mn,a));a.exif.title=a.title;this.Km(a.exif)};fa.prototype.Km=function(a){if(a){if(a.exposure){var b=parseFloat(a.exposure);if(b&&b<=0.5)a.exposure="1/"+Math.round(1/b)}if(a.focallength){var c=parseFloat(a.focallength);if(c)a.focallength=Math.round(c*10)/10}}var d=[];for(var e=0;e<tl.length;e++){var f=tl[e],g=f[0],h=f[1],i="";if(a){i=a[g];if(!i||i=="0"||i=="0.0"){i="n/a"}else{if(f.length>=3)i=
ja(f[2],{s:i});i="<em>"+Xe(i)+"</em>"}}d.push(h+": "+i)}var k='<div class="lhcl_exifbox">'+d.join("<br />")+"</div>";tb(this.Xn,D(k,{}))};fa.prototype.Ft=function(){var a=this.Xn,b=this.fA;if(!(a&&b))return;if(this.wl){a.className="lhcl_exifoff";b.innerHTML="more info";this.wl=false}else{a.className="lhcl_photoinfo";b.innerHTML="less info";this.wl=true}};fa.prototype.Jm=function(a){this.Rm=a;var b=this.Wb;this.Jy=(this.ka=b.index);var c=["uname="+(b.user?b.user.name:_user.name),"iid="+b.id,"noredir=true"];
if(!a){c.push("cartop=remove")}var d=bc("_rtok","");c.push("rtok="+d);Q.Aa(_updateCartPath,this.yu,c.join("&"))};fa.prototype.Yr=function(a){if(this.$.gc(a)){return}var b=false;if(a.text.indexOf("<id>1</id>")>=0){b=true}else if(this.$.Nc(a)){return}this.Wb.inCart=this.Rm;if(this.Jy==this.ka){this.fj(this.Wb,true)}var c=l("lhid_cartDiv"),d=l("lhid_cartCount");if(c&&d){c.style.display="";var e=d.innerHTML?parseInt(d.innerHTML,10):0;if(!b){d.innerHTML=this.Rm?e+1:e-1}}};fa.prototype.Zr=function(a){if(this.$.gc(a)){return}this.on=
eval("("+a.text+")");var b=this.Wb?this.Wb:this.yb[this.ka];if(b){this.fj(b,false)}};fa.prototype.cx=function(a){if(Y(a.inCart)){return a.inCart}if(!this.on){return false}var b=a.user?a.user.name:_user.name,c=this.on[b];return c&&x.indexOf(c,a.id)>=0};fa.prototype.fj=function(a,b){var c=this.Ho();if(c&&c.prints&&!a.vsurl){cb(this.ld,true);if(this.cx(a)){if(b){l(this.cartMsgId).innerHTML=gn}else{l(this.cartMsgId).innerHTML=""}this.ld.innerHTML=nn;this.ld.onclick=this.By}else{this.ld.innerHTML=hn;this.ld.onclick=
this.au;l(this.cartMsgId).innerHTML=""}}else{cb(this.ld,false);l(this.cartMsgId).innerHTML=""}};var tl=[["title","Filename"],["make","Camera"],["model","Model"],["iso","ISO"],["exposure","Exposure","{s} sec"],["fstop","Aperture","f/{s}"],["focallength","Focal Length","{s}mm"]];fa.COORDINATE_FORMAT="{n}&deg; {s}";var mn='<div class="lhcl_photoinfo">{datestring}<br />{sizestring}<br /></div>';fa.METADATA_HTML=mn;var kn='<div id="{cartMsgId}" class="lhcl_output"></div>';fa.CART_MESSAGE_HTML=kn;var lg=
'<div class="lhcl_photoinfo">'+be+"<br />&nbsp;</div>";fa.METADATA_LOADING_HTML=lg;var jn='<a href="/lh/viewCart" onclick="javascript:_setBackLink()" >';fa.BACK_TO_CART_LINK=jn;var gn="<span>"+Sr(jn,"</a>")+"</span>";fa.ADDED_TO_CART_MESSAGE=gn;var nn='<img src="img/clearcart.gif"> <span class="lhcl_fakelink">Remove from order</span>';fa.REMOVE_FROM_CART_LINK=nn;var hn='<img src="img/order.gif"> <span class="lhcl_fakelink">Order Prints</span>';fa.ADD_TO_CART_LINK=hn;var pn='<a href="#" id="{lhui_slideshowlink}" onclick="_d(\'hideSlideshow\');">Slideshow</a>';
fa.SLIDESHOW_LINK_HTML=pn;var ln='<div class="lhcl_toolbox"><div class="lhcl_tools lhcl_hideoverflow"><div id="{lhui_indexbox}">&nbsp;</div><div class="lhcl_albumtitle">{lhui_albumtitle}</div><div id="{lhui_infobox}">'+lg+'</div><div class="lhcl_exifoff" id="{lhui_exifbox}"></div><div style="text-align:right"><span class="lhcl_toollink lhcl_fakelink" id="{lhui_togglelink}" onclick="_d(\'{lhui_togglelink}\')">more info</span></div><div class="lhcl_pseudo_hr"></div><div id="{lhui_links}"><a href="#" id="{lhui_downloadlink}" style="display:block;">'+
mi+'</a>{lhui_slideshow_link_markup}<br /></div><div id="lhid_flashMsg" class="lhcl_output" style="display:none;"><span>'+Jm+'</span><br /><br /><a href="http://www.macromedia.com/go/getflashplayer">Download Flash</a></div></div></div>';fa.METADATA_BOX_HTML=ln;var on='<div class="lhcl_toolbox"><div class="lhcl_tools lhcl_hideoverflow"><a class="lhcl_albumtitle" id="lhid_main_albumtitle" href="#"><b>Album: </b><span id="lhid_main_albumtitle_text">{lhui_albumtitle}</span></a><div id="{lhui_infobox}">'+
lg+'</div><div class="lhcl_exifoff" id="{lhui_exifbox}"></div><div style="text-align:right"><span class="lhcl_toollink lhcl_fakelink" id="{lhui_togglelink}" onclick="_d(\'{lhui_togglelink}\')">more info</span></div><div class="lhcl_pseudo_hr"></div><div id="{lhui_links}"><a href="#" id="{lhui_downloadlink}" style="display:block;">'+mi+'</a>{lhui_slideshow_link_markup}<a href="#" id="{lhui_albumlink}" style="display:block;">'+ri+'</a></div><div id="lhid_flashMsg" class="lhcl_output" style="display:none;"><span>'+
Jm+'</span><br /><br /><a href="http://www.macromedia.com/go/getflashplayer">Download Flash</a></div></div></div>';fa.SEARCH_METADATA_BOX_HTML=on;function Qa(a,b){this.$=a;var c={lhui_albumFunc:p("SetAlbumCover"),lhui_snippetFunc:p("UpdateSnippet"),lhui_snippetId:p("SnippetPanel"),lhui_snippetCheckBoxId:p("SnippetCheckBox"),lhui_snippetTextBoxId:p("SnippetTextBox"),lhui_deleteFunc:p("DeletePhoto"),lhui_copyFunc:p("CopyPhoto"),lhui_moveFunc:p("MovePhoto"),lhui_outputId:p("output"),lhui_deleteId:p("delete")};this.b=c;c.embed_html=ja(_LH.locale=="en_US"?Vn:Un,c);this.e=D(Xn,c);b.appendChild(this.e);q(c.lhui_albumFunc,Tb(this,this.nm,xi));q(c.lhui_snippetFunc,
o(this,this.gj));q(c.lhui_deleteFunc,Tb(this,this.nm,Ue));q(c.lhui_copyFunc,o(this,this.Fs));q(c.lhui_moveFunc,o(this,this.Rs));this.Ot=o(this,this.Qr);this.If=null;this.Bd=null;this.Hn=l(this.b.lhui_deleteId)}Qa.prototype.aa=function(){if(this.e)m.removeNode(this.e);var a=this.b;if(a){y(a.lhui_albumFunc);y(a.lhui_deleteFunc);y(a.lhui_copyFunc);y(a.lhui_moveFunc);y(a.lhui_snippetFunc)}for(var b in this)this[b]=null};Qa.prototype.Pc=function(a){this.Ia=_photo[a].id;this.b.snippet={l:_album.slideshowlink+
"#"+this.Ia,a:_album.titleshort,al:_album.link,u:_photo[a].s};if(_photo[a].vsurl){this.gj(Yn)}else{this.gj(de.close)}var b=this.sk;this.sk=!(!_photo[a].vsurl);if(this.sk){this.Hn.innerHTML="Delete this video"}else{this.Hn.innerHTML=Hm}if(this.If==Ue)if(b)this.hh("Video deleted.");else this.hh("Photo deleted.");else this.hh(null);this.If=null};Qa.prototype.hh=function(a){var b=l(this.b.lhui_outputId);if(!b)return;if(a){b.innerHTML="<span>"+a+"</span>";b.style.display=""}else{b.style.display="none"}};
Qa.prototype.jd=function(a){};Qa.prototype.nm=function(a){if(!this.$.Ti())return;var b=["selectedphotos="+this.Ia,"noredir=true","optgt="+a];if(a==Ue){var c;if(_album.blogger){c="Are you sure you want to delete this photo? It will no longer appear in your blog if you delete it."}else{c=this.sk?"Are you sure you want to delete this video?":"Are you sure you want to delete this photo?"}if(!confirm(c)){this.$.Kd();return}}this.If=a;this.Bd=this.Ia;var d=_selectedPhotosPath+"&uname="+_user.name+"&aid="+
_album.id;Q.Aa(d,this.Ot,b.join("&"))};Qa.prototype.Qr=function(a){if(this.$.gc(a)||this.$.Nc(a)){this.$.Kd();return}if(this.If==Ue){this.$.ls(this.Bd)}else if(this.If==xi){this.$.Kd();this.hh("Album cover set.")}};Qa.prototype.gj=function(a){var b=l("lhid_embed");if(a==Yn){cb(b,false)}else{cb(b,true);var c=l(this.b.lhui_snippetId),d;if(a==de.open){d=true}else if(a==de.close){d=false}else{d=c.style.display=="none"}cb(c,d);l("lhid_zippy").src=d?"img/opentriangle.gif":"img/triangle.gif";var e=l(this.b.lhui_snippetCheckBoxId),
f=this.b.snippet.u;if(_LH.locale=="en_US"){b.className=d?"lhcl_embed_on":"lhcl_embed";if(d){l("lhid_link").value=this.b.snippet.l;var g="/s"+l("lhid_sizeSelect").value+"/$1";this.b.snippet.s=f.replace(/\/([^\/]*)$/,g);var h=e.checked?yi:zi,i=ja(h,this.b.snippet);l(this.b.lhui_snippetTextBoxId).value=i}else{e.checked=false}}else{if(d){var g="/s"+Wn+"/$1";this.b.snippet.s=f.replace(/\/([^\/]*)$/,g);var h=e.checked?zi:yi,i=ja(h,this.b.snippet),k=l(this.b.lhui_snippetTextBoxId);k.value=i;k.focus();k.select()}else{e.checked=
false}}}};Qa.prototype.Fs=function(){qb("hideVideo");LH_copyDialog([this.Ia])};Qa.prototype.Rs=function(){if(!_album.blogger||confirm("Are you sure you want to move this photo? It will no longer appear in your blog if you move it.")){qb("hideVideo");LH_moveDialog([this.Ia])}};var de={toggle:0,open:1,close:-1,Zc:-2},Yn=de.Zc,Zn=de.toggle;Qa.SNIPPET_ACTION=de;var Ue="DELETE";Qa.DELETE_OP=Ue;var xi="BANNER";Qa.BANNER_OP=xi;var Xn='<div class="lhcl_toolbox"><div class="lhcl_tools"><a href="javascript:_d(\'{lhui_albumFunc}\')">Set as album cover</a><br /><a href="javascript:_d(\'{lhui_copyFunc}\')">Copy to another album</a><br /><a href="javascript:_d(\'{lhui_moveFunc}\')">Move to another album</a><br /><div class="lhcl_pseudo_hr"></div>{embed_html}<a id="{lhui_deleteId}" href="javascript:_d(\'{lhui_deleteFunc}\')">'+
Hm+'</a><div id="{lhui_outputId}" class="lhcl_output"></div></div>';Qa.SIDEBAR_TOOLS_HTML=Xn;var Wn=288;Qa.PHOTO_SNIPPET_SIZE=Wn;var zi='<a href="{l}"><img src="{s}" /></a>';Qa.PHOTO_ONLY_SNIPPET_HTML=zi;var yi='<table style="width:auto;"><tr><td><a href="{l}"><img src="{s}" /></a></td></tr><tr><tr><td style="font-family:arial,sans-serif; font-size:11px; text-align:right">From <a href="{al}">{a}</a></td></tr></table>';Qa.PHOTO_LINKS_SNIPPET_HTML=yi;var Un='<div id="lhid_embed"><a href="javascript:_d(\'{lhui_snippetFunc}\', '+
Zn+')">Embed in Blog/MySpace</a> <img src="img/triangle.gif" class="hand" id="lhid_zippy" onclick="_d(\'{lhui_snippetFunc}\', '+Zn+')"><br /><div style="display:none;" id="{lhui_snippetId}">Copy and paste the HTML below to post a thumbnail of this image on your blog or MySpace page.<br /><input type="checkbox" id="{lhui_snippetCheckBoxId}" onclick="_d(\'{lhui_snippetFunc}\', 1)"/>Hide album link<br /><textarea id="{lhui_snippetTextBoxId}"></textarea></div></div>';Qa.PHOTO_EMBED_HTML=Un;var Vn='<ul class="lhcl_albumcontrols"><li style="padding-top:0.2em;width:216px"><div id="lhid_embed" class="lhcl_embed"><span class="lhcl_fakelink" onclick="_d(\'{lhui_snippetFunc}\')">Link to this Photo</span> <img src="img/triangle.gif" class="hand" id="lhid_zippy" onclick="_d(\'{lhui_snippetFunc}\')"><div id="{lhui_snippetId}" class="lhcl_embedlinks" style="display:none;"><div id="lhid_snippetinfo" style="margin-top:0.2em;">'+
js("<b>","</b>")+'<br/><input class="lhcl_embedtextbox" onclick="this.select()" id="lhid_link"></div><div class="lhcl_pseudo_hr_embed"></div><div style="margin-top: 0.4em;">'+is("<b>","</b>")+'<input class="lhcl_embedtextbox" onclick="this.select()" type="text" id="{lhui_snippetTextBoxId}" /></div><div style="white-space:nowrap;">Select size<select id="lhid_sizeSelect" onchange="_d(\'{lhui_snippetFunc}\', 1)"><option value="144">Thumbnail '+kg(144)+'</option><option value="288">Small '+kg(288)+'</option><option value="400">Medium '+
kg(400)+'</option><option value="800">Large '+kg(800)+'</option></select></div><div style="margin-top:0.3em">Show link to album <input id="{lhui_snippetCheckBoxId}" type="checkbox" style="margin:0;" onclick="_d(\'{lhui_snippetFunc}\', 1)"/></div></div></div></li></ul>';Qa.PHOTO_LINKS_HTML=Vn;function qa(a,b,c){this.$=a;this.q=null;this.sb=m.createElement("div");b.appendChild(this.sb);this.md=m.createElement("div");b.appendChild(this.md);this.tn=p("comment");this.nh=p("addcommentbox");this.Ar=p("unauthcommentbox");this.Uj=p("addcomment");this.$e=D(dn,{lhui_commentbox:this.tn,lhui_addcommentbox:this.nh,lhui_unauthcommentbox:this.Ar,signInStr:ti(),lhui_focuscomment:this.Uj});c.appendChild(this.$e);this.$e.style.display="none";q(this.Uj,o(this,this.ss));this.oy=o(this,this.at);this.Wu=o(this,
this.ks);this.xC=o(this,this.BA);this.Pl=p("viewAll");q(this.Pl,o(this,this.Lt));this.Gj=p("deleteCommentFunc");q(this.Gj,o(this,this.js));this.Vj=p("focusFunc");q(this.Vj,o(this,this.ts));this.rj=_authuser.user}qa.prototype.aa=function(){this.we();if(this.sb)m.removeNode(this.sb);if(this.md)m.removeNode(this.md);if(this.$e)m.removeNode(this.$e);y(this.Uj);y(this.Pl);y(this.Gj);y(this.Vj);for(var a in this)this[a]=null};qa.prototype.we=function(){this.sb.innerHTML="&nbsp;";this.md.innerHTML="";if(this.pe){Q.Vl(this.pe);
this.pe=0}if(this.ag)y(this.ag);if(this.Og)y(this.Og)};qa.prototype.Gt=function(a){this.q=a;this.xa(a.b)};qa.prototype.xa=function(a){this.Ia=a.id;var b=a.comment;this.sb.innerHTML="&nbsp;";if(b.length>0){var c=['<table class="lhcl_comments">'],d=this.q?this.q.user:null,e=_authuser.name,f=d?d.name==e:_authuser.isOwner;for(var g=0;g<b.length;++g){var h=b[g];h.lhui_date=h.timestamp;h.lhcl_ownerclass=_authuser.name==h.username?"lhcl_ownercomment":"";h.lhui_comment=Xe(Co(h.comment.replace(/\n/g,"<br />")));
if(h.link){h.lhui_linkstart='<a href="'+h.link+'">';h.lhui_linkend="</a>"}if(f||e==h.username){h.lhui_deletelink=ja(cn,{lhui_commentId:h.id,lhui_func:this.Gj})}c.push(ja(an,h))}c.push("</table>");this.sb.innerHTML=c.join("")}var i=l(this.tn);if(b.length){var h=b[b.length-1];h.lhui_date=h.timestamp;h.lhui_viewallbox=p("viewall");tb(i,D(en,h));i.style.display="";if(b.length>1){l(h.lhui_viewallbox).appendChild(D(fn,{lhui_viewallfunc:this.Pl}))}}else{i.innerHTML="";i.style.display="none"}this.$e.style.display=
"";l(this.nh).style.display=this.rj?"":"none";l(this.Ar).style.display=this.rj?"none":"";this.Cs(b.length)};qa.prototype.Cs=function(a){this.md.innerHTML="";if(!this.rj){this.signInBoxId=p("signInBox");var b=D(bn,{lhui_signInBoxId:this.signInBoxId,signInStr:ti()})}else{if(this.fB||a>=100){l(this.nh).style.display="none";this.md.innerHTML="Commenting is closed for this photo.";return}else{l(this.nh).style.display=""}this.ag=p("commentForm");this.Rg=p("commentText");this.Og=p("commentLength");this.Sz=
p("submitButton");var b=D($m,{lhui_formId:this.ag,lhui_id:this.Rg,lhui_sizeId:this.Og,lhui_submitId:this.Sz,lhui_focusFunc:this.Vj})}this.md.appendChild(b);this.Tn=false;q(this.ag,o(this,this.$s));q(this.Og,o(this,this.pt))};qa.prototype.$s=function(){var a=l(this.ag),b=l(this.Rg);if(!(b&&a))return;var c=rc(b.value);if(!c){alert("Please enter a comment first.");return}if(c.length>512){alert("Your comment seems to be a bit long. Please, do try to be more efficient with your words.");return}var d=["uname="+
(this.q?this.q.user.name:_user.name),"aname="+(this.q?this.q.album.name:_album.name),"iid="+this.Ia,"AddComment="+Bc(c),"noredir=true"];for(var e=0;e<a.elements.length;e++){var f=a.elements[e];f.disabled=true;f.blur()}this.Bd=this.Ia;this.Cu=c;Q.Aa(_addCommentPath,this.oy,d.join("&"))};qa.prototype.at=function(a){if(this.$.gc(a)||this.$.Nc(a)){var b=l(this.Rg);if(b)b.value=this.Cu;return}this.$.Cf(this.Bd,true)};qa.prototype.js=function(a){if(!confirm("Are you sure you want to delete this comment?"))return;
var b=["uname="+(this.q?this.q.user.name:_user.name),"mode=delete","cid_"+a+"=on","iid="+this.Ia,"noredir=true"];this.Bd=this.Ia;Q.Aa(_selectedCommentsPath,this.Wu,b.join("&"))};qa.prototype.ks=function(a){this.$.Cf(this.Bd,true)};qa.prototype.pt=function(a){var b=l(this.Og);if(!(b&&a))return;if(a.value.length>480){var c=a.value.length,d=m.createElement("span"),e=m.createTextNode($r(c,512));d.appendChild(e);if(c>512)d.style.color="red";tb(b,d)}else{b.innerHTML=""}};qa.prototype.Lt=function(){window.scrollTo(0,
uf(this.sb)-50)};qa.prototype.ss=function(){window.scrollTo(0,uf(this.md)-50);if(this.Rg){var a=l(this.Rg);if(a&&!a.disabled)a.focus()}};qa.prototype.ts=function(a){if(this.Tn)return;a.value="";a.style.color="#000";this.Tn=true};var ti=function(){var a=new w(_loginUrl);a.$a("continue",location.href);var b=new w(_signUpUrl);b.$a("continue",location.href);return ys('<a href="'+a.toString()+'">','<a href="'+b.toString()+'">',"</a>")};qa.yA=ti;var an='<tr class="{lhcl_ownerclass}" ><td rowspan="2" class="lhcl_commentimg">{lhui_linkstart}<img src="{portrait}" />{lhui_linkend}</td><th width="100%">{lhui_linkstart}{nickname}{lhui_linkend}</th><th>{lhui_date}</th><th>{lhui_deletelink}</th></tr><tr><td colspan="3" class="lhcl_commenttext">{lhui_comment}</td></tr>';
qa.COMMENT_HTML=an;var dn='<div class="lhcl_toolbox"><div class="lhcl_tools"><div id="{lhui_commentbox}"></div><div id="{lhui_addcommentbox}"><a href="javascript:_d(\'{lhui_focuscomment}\')">'+li+'</a></div><div id="{lhui_unauthcommentbox}"><b>'+li+"</b><div>{signInStr}</div></div></div></div>";qa.LAST_COMMENT_BOX_HTML=dn;var en='<div class="lhcl_lastcomment"><table><tr><td width="100%"><b>Latest comment</b></td><td id="{lhui_viewallbox}"></td></tr></table><div class="lhcl_pseudo_hr"></div><div>&#8220;{lhui_comment}&#8221;</div><div class="lhcl_commentauthor">{nickname} &#8211; {lhui_date}</div><div class="lhcl_pseudo_hr"></div></div>';
qa.LAST_COMMENT_HTML=en;var fn='<a class="lhcl_toollink" href="javascript:_d(\'{lhui_viewallfunc}\')">view all</a>';qa.VIEW_ALL_COMMENTS_HTML=fn;var $m='<form class="lhcl_commentform" id="{lhui_formId}" action="javascript:_d(\'{lhui_formId}\')"><div class="lhcl_title">Add a comment</div><textarea id="{lhui_id}" onfocus="_d(\'{lhui_focusFunc}\', this)" onkeydown="_d(\'{lhui_sizeId}\', this)" onkeyup="_d(\'{lhui_sizeId}\', this)"></textarea><table><tr><td width="100%"><div id="{lhui_sizeId}">&nbsp;</div></td><td><input type="submit" id="{lhui_submitId}" value="Post Comment"  /></td></tr></table></form>';
qa.COMMENT_FORM_HTML=$m;var bn='<div id="{lhui_signInBoxId}" class="lhcl_toolbox lhcl_photoCommentSignIn"><div class="lhcl_tools"><b>'+li+"</b><div>{signInStr}</div></div></div>";qa.COMMENT_SIGNIN_HTML=bn;var cn='<span class="lhcl_fakelink" tabindex="0" onclick="_d(\'{lhui_func}\', \'{lhui_commentId}\')">delete</span>';qa.DELETE_COMMENT_HTML=cn;function Lb(a,b,c){this.$=a;this.Ba=m.createElement("div");this.Ba.className="lhcl_caption";b.appendChild(this.Ba);this.Ce=m.createElement("div");c.appendChild(this.Ce);this.Nj=p("edit_caption");q(this.Nj,o(this,this.ot))}Lb.prototype.aa=function(){y(this.Nj);if(this.Ce)m.removeNode(this.Ce);if(this.Ba)m.removeNode(this.Ba);for(var a in this)this[a]=null};Lb.prototype.we=function(){this.Ba.innerHTML="&nbsp;";this.Ce.innerHTML="";if(this.Ga&&this.Ga.id){y(this.Ga.id);y(this.Ga.cancelID);y(this.Ga.sizeID)}};
Lb.prototype.Pc=function(a){this.Ia=a.id;var b=a.c||"",c=Xe(Co(b));c=c.replace(/  /g,"&nbsp; ").replace(/\n/g,"<br />");var d={caption:c},e=false;if(!a.user){e=_authuser.isOwner}if(e){d.id=this.Nj;d.text=b?"edit":"Add a Caption";d.addtext=ja(Xm,d);this.Ga={caption:b}}this.we();this.Ba.innerHTML=ja(Zm,d);this.Ba.style.display=""};Lb.prototype.ot=function(){this.Ba.style.display="none";this.Ga={caption:this.Ga.caption,id:p("lhid_capform"),saveID:p("lhid_capsave"),sizeID:p("lhid_capsize"),cancelID:p("lhid_capcancel")};
this.Ce.appendChild(D(Ym,this.Ga));this.Am();q(this.Ga.id,o(this,this.bt));q(this.Ga.cancelID,o(this,this.Xl));q(this.Ga.sizeID,o(this,this.Am));l(this.Ga.id).focus()};Lb.prototype.Xl=function(){this.Ba.style.display="";this.Ce.innerHTML=""};Lb.prototype.Am=function(a){var b=l(this.Ga.sizeID),c=l(this.Ga.id),d=l(this.Ga.saveID);if(!(b&&c&&d))return;if(c.value.length>992){var e=c.value.length,f=1024,g=m.createElement("span");g.appendChild(m.createTextNode(Yr(e,f)));if(e>f){g.style.color="red"}tb(b,
g)}else{b.innerHTML=""}};Lb.prototype.bt=function(){var a=l(this.Ga.id);if(!a)return;var b=rc(a.value);if(b==this.Ga.caption){this.Xl();return}if(b.length>1024){alert(Em);return}var c=["description="+Bc(b),"noredir=true"];l(this.Ga.saveID).disabled=true;l(this.Ga.cancelID).disabled=true;var d=this.Ia,e=Tb(this,this.Xr,d,b),f=_updatePhotoPath+"&uname="+_user.name+"&aname="+_album.name+"&iid="+d;Q.Aa(f,e,c.join("&"))};Lb.prototype.Xr=function(a,b,c){if(!this.$)return;if(this.$.gc(c)||this.$.Nc(c)){l(this.Ga.saveID).disabled=
false;l(this.Ga.cancelID).disabled=false;return}this.$.Im(a,za(b))};var Zm="<b>{caption}</b>{addtext}";Lb.CAPTION_HTML=Zm;var Xm='&nbsp;<span id="{id}" class="lhcl_fakelink" onclick="_d(\'{id}\')">{text}</span>';Lb.ADD_CAPTION_HTML=Xm;var Ym='<div class="lhcl_captionform"><div id="{sizeID}" style="color:#999"></div><textarea name="description" id="{id}" rows="0" comments="0" onkeydown="_d(\'{sizeID}\')" onkeyup="_d(\'{sizeID}\')">{caption}</textarea><div><input type="button" value="Save Caption"class="lhcl_default" id="{saveID}" onclick="_d(\'{id}\')" /><input type="button" value="Cancel" id="{cancelID}" onclick="_d(\'{cancelID}\')"/></div></div>';
Lb.CAPTION_FORM_HTML=Ym;function Oe(){P.Pa(this);q("ClearCart",o(this,this.bs))}Oe.prototype.aa=function(){P.Sa(this);y("ClearCart")};Oe.prototype.bs=function(){if(confirm("Are you sure you want to clear your order?")){var a=l("lhid_clearform"),b=new w(_updateCartPath);b.$a("cartop","clear");b.$a("rtok",bc("_rtok",""));a.action=b.toString();a.submit()}};function ut(a,b,c){var d="uname="+a+"&iid="+c+"&cartop=remove&noredir=true",e=bc("_rtok","");d+="&rtok="+e;Q.Aa(_updateCartPath,null,d);var f=l("lhid_cart_"+c);if(f)m.removeNode(f);
cartPhotoCount--;l("lhid_cartcount").innerHTML=cartPhotoCount;cartAlbumCount[b]--;if(cartAlbumCount[b]<=0){var g=l("lhid_cartalbum_"+b);if(g)m.removeNode(g)}if(cartPhotoCount<=0){l("lhid_emptycart").style.display="";l("lhid_instructions3_photos").style.display="";l("lhid_nonemptycart").style.display="none";l("lhid_instructions3_none").style.display="none";l("lhid_instructions3").style.display="none";l("lhid_instructions").className="lhcl_cartinstructions lhcl_instep1"}}function vt(a){var b=bc("printProvider");
if(!b){return true}pc(cg,"1");var c="/lh/sendToProvider?provider="+b;if(a){window.open(c,"selectProviderWnd");var d='<a href="javascript:void(0)" onclick="return window._sendToProvider(false);">';l("msg").innerHTML=os(d,"</a>");l("lhid_feedback").style.display=""}else{window.location=c}return false}function Ir(a,b){var c=l("lhid_orderform"),d=bc("_rtok",""),e=new w(c.action);e.$a("rtok",d);e.$a("uname",a);e.$a("aid",b);c.action=e.toString();c.submit()}function Fr(){if(Zd){return}Zd=(ub.dialogIsOpen=
true);Q.Aa("/lh/selectProvider",Er)}function Er(a){if(a.status==200&&a.text.length==0){alert("We're sorry.  Picasa Web Albums does not currently work with any photo processing providers that ship to your country.");Zd=(ub.dialogIsOpen=false);return}else if(a.status>=400||a.text.length==0){alert("Failed to retrieve list of Print Providers.  Please try again later.");Zd=(ub.dialogIsOpen=false);return}qb("hideVideo");new ub(a.text)}function ub(a){P.Pa(this);var b={lhui_ok_func:p("func"),lhui_cancel_func:p("func")};
this.b=b;this.lb=m.createElement("div");this.lb.className="lhcl_cover";document.body.appendChild(this.lb);this.Ub();this.ec=o(this,this.Ub);wa(window,"resize",this.ec);window.scrollTo(0,0);Bf();this.e=D(ym+a+xm,this.b);document.body.insertBefore(this.e,document.body.firstChild);var c=bc("printProvider");if(!c){document.getElementById("lhid_accept_provider").disabled=true}q(this.b.lhui_ok_func,o(this,this.Pr));q(this.b.lhui_cancel_func,o(this,this.Wl));this.qc=Ma(this,this.Tb);wa(document,"keydown",
this.qc)}ub.prototype.Tb=function(a){if(a.keyCode==bt){this.Wl()}};ub.prototype.aa=function(){P.Sa(this);if(this.b){y(this.b.lhui_ok_func);y(this.b.lhui_cancel_func)}Aa(document,"keydown",this.qc);Aa(window,"resize",this.ec);Zd=(ub.dialogIsOpen=false);for(var a in this)this[a]=null};ub.prototype.jb=function(){m.removeNode(this.e);m.removeNode(this.lb);qb("restoreVideo");this.aa()};ub.prototype.Ub=function(){var a=Math.max(document.body.offsetHeight,document.body.scrollHeight);a=Math.max(a,document.body.clientHeight);
a=Math.max(a,document.documentElement.clientHeight);this.lb.style.height=a+"px"};ub.prototype.Wl=function(){this.jb()};function sk(a){pc("printProvider",a,2592000);var b=m.createElement("img");b.width=150;b.height=50;b.src="/lh/providerLogo/"+a;var c=l("lhid_currentprovider");tb(c,b);l("lhid_hasprovider").style.display="";l("lhid_noprovider").style.display="none";c=l("lhid_instructions3");if(c){l("lhid_instructions3_none").style.display="none";if(cartPhotoCount>0){c.style.display="";l("lhid_instructions").className=
"lhcl_cartinstructions lhcl_instep3"}}}ub.prototype.Pr=function(){var a=l("lhid_chooseProviderForm").provider;if(typeof a.length=="undefined"){sk(a.value)}else{for(var b=0;b<a.length;b++){if(a[b].checked){sk(a[b].value);break}}}this.jb()};function $d(){var a=0,b="";for(var c=1;c<=Ul;c++){var d=bc(Vl+c);if(d){b+=d}}var e=b.split("@");if(e.length>=2){var f=e[1].match(/\:/g);if(f){a=f.length}}if(a>0){l("lhid_cartDiv").style.display="";l("lhid_cartCount").innerHTML=a}}var Ul=4;Oe.COOKIE_COUNT=Ul;var Vl=
"_cart";Oe.COOKIE_PREFIX=Vl;var Zd=false;ub.dialogIsOpen=Zd;var cg="_lh_cartRedirect";ub.REDIRECT_COOKIE=cg;var ym='<div class="lhcl_dialog" style="width:400px; top:100px"><div class="lhcl_dialog_body"><form id="lhid_chooseProviderForm"><div class="lhcl_selectProviderTitle">Please select a print provider from the list below:</div><div style="padding:0 25px 15px 0;">';ub.DIALOG_FRAME_START=ym;var xm='</div><table style="width:100%"><tr><td style="width:50%; text-align:right;"><input type="button" value="Cancel" onclick="_d(\'{lhui_cancel_func}\')"/></td><td><input id="lhid_accept_provider" type="button" value="OK" onclick="_d(\'{lhui_ok_func}\')"/></td></tr></table></form></div></div>';
ub.DIALOG_FRAME_END=xm;function V(a){P.Pa(this);this.q=_photo;var b=l("lhid_main"),c=l("lhid_tools");this.hi=l("lhid_login");this.Fi=l("lhid_signup");this.hb=new vb(this,b);this.Vb=m.createElement("div");this.Vb.className="lhcl_photobox";b.appendChild(this.Vb);this.e=m.createElement("div");this.Vb.appendChild(this.e);this.Xa=new fa(this,c);this.Ba=new Lb(this,this.Vb,b);if(_authuser.isOwner){this.Fd=new Qa(this,c)}else{var d=m.createElement("div");d.className="lhcl_toolbox";c.appendChild(d);var e=m.createElement("div");
e.className="lhcl_tools";d.appendChild(e);this.Wd=new Pa(e);this.$f=d}this.sb=new qa(this,b,c);this.Oa=null;if(_features.tags){this.Oa=new ga(this,c)}var f=new La(this,this.e,this.q);f.onshow=o(this,this.Ws);f.onload=o(this,this.eh);f.onloadstart=o(this,this.Wi);f.onstopped=o(this,this.Xs);f.onresize=o(this,this.Ub);this.fa=f;this.Ze=Ma(this,this.Tb);this.vg=Ma(this,this.Id);this.Of=o(this,this.Rc);wa(document,"keydown",this.Ze);wa(document,"keyup",this.vg);wa(window,"blur",this.Of);this.dc=new xb(o(this,
this.fh));this.Dc=false;this.cc=0;this.Su=o(this,this.gs);this.ka=-1;this.cd=Oi(this.q,"id");this.Fp={};this.xa(a);q("hideSlideshow",o(this,this.dh));q("hideVideo",o(this,this.zs));q("restoreVideo",o(this,this.vt))}V.prototype.aa=function(){P.Sa(this);if(this.Bb)window.clearTimeout(this.Bb);y("hideSlideshow");y("hideVideo");y("restoreVideo");if(this.Xa)this.Xa.aa();if(this.Fd)this.Fd.aa();if(this.Ba)this.Ba.aa();if(this.sb)this.sb.aa();if(this.hb)this.hb.aa();if(this.fa)this.fa.aa();if(this.Oa)this.Oa.aa();
if(this.e)m.removeNode(this.e);if(this.Vb)m.removeNode(this.Vb);if(this.Wd)this.Wd.jb();if(this.$f)m.removeNode(this.$f);Aa(document,"keydown",this.Ze);Aa(document,"keyup",this.vg);Aa(window,"blur",this.Of);for(var a in this)this[a]=null};V.prototype.jb=function(){Bf();this.dc.reset();if(this.pe)Q.Vl(this.pe);this.aa()};V.prototype.xa=function(a){var b=a[1],c=this.cd[b];if(c==undefined){location.replace(location.href.replace(/#.*/,"#unknown-"+b));return}this.ka=c;this.title=" - "+this.q[c].t;var d=
this.q,e=c>0?d[c-1].id:null,f=c<d.length-1?d[c+1].id:null;this.hb.Hm(e,f);if(this.Wd)this.Wd.cj(_user.name,_album.id,b,!(!this.q[c].vsurl));this.Xa.Pc(c);if(this.Oa)this.Oa.we();this.fa.bh(c);if(this.hi){this.hi.href=this.hi.href.replace(/photo(%23\d+)?/,"photo%23"+b)}if(this.Fi){this.Fi.href=this.Fi.href.replace(/photo(%23\d+)?/,"photo%23"+b)}};V.prototype.Nb=function(a,b){var c=this.ka+a,d=this.q.length;if(b){while(c<0)c+=d;c%=d}if(c<0||c>=d)return false;location=location.href.replace(/#.*/,"#"+
this.q[c].id);return true};var An=function(){this.Nb(1)};V.prototype.Df=An;var Dn=function(){this.Nb(-1)};V.prototype.Ef=Dn;V.prototype.ah=function(){location=_album.link};var xn=function(a){return Cd()-uf(this.Vb.firstChild)-50};V.prototype.Ri=xn;V.prototype.Wi=function(){};V.prototype.Ws=function(){var a=this.fa.Oc();this.Kd();this.hb.Pc(a);this.Ba.Pc(this.q[a]);if(this.Fd)this.Fd.Pc(a);this.Qi();if(this.Dc)this.Nb(this.lf)};V.prototype.eh=function(){};V.prototype.Xs=function(){this.Cf(this.q[this.fa.Oc()].id)};
V.prototype.Ub=function(){this.Qi()};var wn=function(){var a=this.fa.Nh();if(!a||a.fb()||a.Co()>=1){this.hb.xe(false,true);if(a)a.Ff(false)}else{this.hb.xe(a.Qo(),false)}};V.prototype.Qi=wn;V.prototype.Cf=function(a,b){var c=this.cd[a],d=this.q[c],e=(new Date).getTime(),f=this.Fp[a];if(!b&&f&&e-f<60000)e=f;this.Fp[a]=e;var g="/lh/rssPhoto?uname="+_user.name+"&iid="+d.id+"&v="+e+"&js=1";this.pe=Q.Aa(g,this.Su)};V.prototype.ls=function(a){var b=this.fa.Oc(),c=this.cd[a];this.q.splice(c,1);this.cd=Oi(this.q,
"id");this.fa.nn();Bf(true);if(b==c){if(this.q.length==0){location.replace(_album.link)}else if(this.q.length==c){location.replace(location.href.replace(/#.*$/,"#"+this.q[c-1].id))}else{location.replace(location.href.replace(/#.*$/,"#"+this.q[c].id))}}else{var d=this.q[b].id;location.replace(location.href.replace(/#.*$/,"#"+d));this.xa(["",d])}};V.prototype.gs=function(a){if(this.gc(a)){this.Kd();return}var b=Q.bm(a);if(!b){alert(Gm);location.replace(_album.link);return}var c=this.cd[b.id];if(c<0)return;
var d=this.fa.Oc(),e=this.q[c];if(e.v!=b.version){e.v=b.version;e.w=parseInt(b.width,10);e.h=parseInt(b.height,10);e.s=b.imgsrc;if(c==d){this.fa.rm()}return}if(c==d){this.Xa.xa(b);if(this.Oa)this.Oa.xa(b.tags,b.id);this.sb.xa(b)}};var Hn=function(){var a=this.fa.Nh(),b=a.Co(),c=a.Qo();if(c){this.hb.xe(false);a.Ff(false)}else if(!a.fb()&&b<1){this.hb.xe(true);a.Ff(true)}};V.prototype.Gm=Hn;var In=function(a,b){var c=this.cd[a],d=this.q[c];if(!d)return;d.c=b;this.Ba.Pc(d)};V.prototype.Im=In;V.prototype.Ti=
function(){if(this.yr)return false;this.yr=true;this.hb.jd(true);if(this.Fd)this.Fd.jd(true);return true};V.prototype.Kd=function(){this.yr=false;this.hb.jd(false);if(this.Fd)this.Fd.jd(false)};var un=function(a){var b=a.status;if(b>=400){var c;if(b==403){c=Km}else if(b==404){c=Mm}else if(b>=500){c=Pm+"\n"+jg(b)}else{c=Qm+"\n"+jg(b)}alert(c);return true}return false};V.prototype.gc=un;var vn=function(a){var b=a.text;if(a.target&&a.target.hg){b=a.target.hg()}if(b.indexOf("success")<0){var c=b.replace(/\<[^>]*\>/g,
"");alert(c);return true}return false};V.prototype.Nc=vn;var Bn=function(a){if(a.altKey||a.metaKey||a.ctrlKey)return;var b=a.target.nodeName.toLowerCase();if(b=="textarea"||b=="input"||b=="select")return;switch(a.keyCode){case 27:this.ah();cc(a);break;case 37:if(this.cc!=37){this.Ef();this.ye(-1)}this.cc=37;cc(a);break;case 39:if(this.cc!=39){this.Df();this.ye(1)}this.cc=39;cc(a);break}};V.prototype.Tb=Bn;var Cn=function(a){if(a.keyCode==37||a.keyCode==39){this.Rc()}};V.prototype.Id=Cn;var Fn=function(a){this.Rc();
this.lf=a;if(a!=0)this.dc.ma(400)};V.prototype.ye=Fn;var Gn=function(){this.dc.reset();this.Dc=false;this.cc=0};V.prototype.Rc=Gn;var vi=function(){this.Dc=true;this.Nb(this.lf)};V.prototype.fh=vi;V.prototype.fb=function(){if(!this.fa)return false;var a=this.fa.Nh();if(!a)return false;return a.fb()};V.prototype.Ul=function(){if(this.fb())return false;var a=this.fa.Oc();if(this.q[a].br)return false;return true};var zn=function(){if(this.fa.ca)this.fa.ca.ve()};V.prototype.dh=zn;var yn=function(){if(this.fb()&&
this.fa.ca&&this.fa.ca.ic){this.fa.ca.ic.style.visibility="hidden"}};V.prototype.zs=yn;var En=function(){if(this.fb()&&this.fa.ca&&this.fa.ca.ic){this.fa.ca.ic.style.visibility=""}};V.prototype.vt=En;function zo(a,b,c,d){this.Ox=a;this.Gr=b;this.uq=c;this.He=null;this.ny=d}var Is=function(a){var b=a.currentTarget;if(this.He.name==b.name){this.uq.src=b.icon}};zo.prototype.pA=function(a){if(this.He==a){return}this.He=a;Mc(this.Ox,Ob(a.nickname));this.uq.src=a.icon;this.Gr.href="/"+this.He.name+"/";Mc(this.Gr,zs(Ob(this.He.nickname)));this.ny.href="/"+this.He.name+"/";if(!a.loaded){a.addEventListener("userDataReady",Is.p(this));a.bf()}};function Gf(a,b,c,d,e,f){this.Nf=a;this.Xa=b;this.Ba=c;this.Oa=
d;this.sb=e;this.hb=f;this.Wb=null;cb(l("email"),false);var g=l("lhid_tools"),h=m.createElement("div");h.className="lhcl_toolbox";g.appendChild(h);var i=m.createElement("div");i.className="lhcl_tools";h.appendChild(i);this.Wd=new Pa(i);this.$f=h;g.insertBefore(this.Oa.e,h);g.insertBefore(this.Xa.g,this.sb.$e);this.Kp=l("lhid_main_albumtitle");this.wx=l("lhid_main_albumtitle_text")}Gf.prototype.Wk=function(a,b){this.Wb=a;this.Xa.qf(a);if(this.Wd){if(a.user.name==this.Nf.name){cb(this.$f,false)}else{cb(this.$f,
true);var c=!(!a.vsurl);this.Wd.cj(a.user.name,a.album.id,a.id,c)}}this.hb.jd(!(!a.vsurl));this.hb.q=a;if(b&&this.Xa.totalPhotoCount>0){this.hb.qf(a);this.hb.Hm(a.ka>0,a.ka+1<this.Xa.yb.length)}if(b){if(a.b){this.Wg({currentTarget:a})}else{a.addEventListener("photoDataReady",Ak.p(this));a.bf()}}};Gf.prototype.qz=function(a){this.Xa.yb=a;this.hb.yb=a};var Ak=function(a){var b=a.currentTarget;if(!b){return}if(this.Wb!==b){return}var c=b.b;if(!c){alert(Gm);return}this.Ba.Pc(b);this.Xa.qf(b);if(this.Oa){this.Oa.q=
b;this.Oa.xa(c.tags,c.id)}if(this.sb&&c.comment){this.sb.Gt(b)}var d=b.album;if(this.Kp&&d){this.Kp.href=d.link;Mc(this.wx,Ob(d.title))}};Gf.prototype.Wg=Ak;function K(a){P.Pa(this);$a.remove(Dh);$a.remove(Ch);this.Na=null;if(K.LANDING_PHOTO){var b=K.LANDING_PHOTO.photo,c=b.user,d=b.album;this.Na=new Se(null,null,-1);var e=new Ve(c.uname,c.nickname);e.icon=c.icon;var f=new uk(d.username,d.id,d.title,d.ctitle,d.prints);this.Na.user=e;this.Na.album=f;this.Na.s=b.s;this.Na.id=b.id;this.Na.w=Number(b.w);
this.Na.h=Number(b.h);this.Na.c=b.c;this.Na.t=b.t;this.Na.vsurl=b.vsurl;this.Na.vdurl=b.vdurl;this.Na.b=null}var g=w.parse(j.global.document.location.href);this.Hc=g.eg("q");this.Db=g.eg("psc");this.ka=-1;this.Ee=g.eg("cuname");this.gu=_authuser;this.$n=g.eg("filter")==1?true:false;this.rc=24;this.kB=g.eg("id");this.Ra=null;this.q=[];var h=l("lhid_main"),i=l("lhid_tools");this.hi=l("lhid_login");this.Fi=l("lhid_signup");var k=l("lhid_user_nickname"),n=k.parentNode,s=m.createElement("a");Fg(s,{id:"lhid_user_gallery_link"});
n.appendChild(s);var u=l("lhid_portraitlink"),z=l("lhcl_portrait_id");this.Gd=new zo(k,s,z,u);var v=l("lhid_query"),A=v?v.firstChild:null;if(A&&this.Hc){if(!A.innerHTML){Mc(A,Ob(this.Hc))}}var T=new vb(this,h,true);this.Cr();this.Vb=m.createElement("div");this.Vb.className="lhcl_photobox";h.appendChild(this.Vb);this.e=m.createElement("div");this.Vb.appendChild(this.e);var J=_features.tags?new ga(this,i,true):null;J.searchCorpus=this.Db;var hc=new qa(this,h,i);this.Xa=new Gf(this.gu,new fa(this,i,
[],true,true),new Lb(this,this.Vb,h),J,hc,T);this.hb=T;this.fa=new La(this,this.e,this.q);this.fa.onshow=Zq.p(this);this.fa.onloadstart=Xq.p(this);this.fa.onload=Yq.p(this);this.fa.onstopped=$q.p(this);this.fa.onresize=yk.p(this);t(document,ke,this.Tb,false,this);t(document,Ng,this.Id,false,this);t(document,Kd,this.Rc,false,this);this.dc=new xb(vi.p(this));this.Dc=false;this.cc=0;this.xa(a);this.addEventListener("onLoadStart",Wq.p(this));this.addEventListener("onstop",ar.p(this));q("hideSlideshow",
zn.p(this));q("hideVideo",yn.p(this));q("restoreVideo",En.p(this))}K.la(Sa);var xk="/data/feed/api/search";K.BASE=xk;var Wq=function(a){var b=a.photo;if(!b){return}if(!b.b){b.addEventListener("photoDataReady",this.Wg.p(this))}this.Xa.Wk(b,false);this.Gd.pA(b.user)};var ar=function(a){var b=a.photo;if(!b){return}this.Xa.Wk(b,true)};K.prototype.gr=function(){if(this.ka>=this.Ra.totalPhotos){this.ka=this.Ra.totalPhotos-1;window.location.hash=this.ka;this.wc=this.ka}this.fa.bh(this.ka)};K.prototype.aa=
function(){P.Sa(this);if(this.fa)this.fa.aa();if(this.r)this.r.aa();if(this.dc)this.dc.aa()};K.prototype.xa=function(a){this.ka=Number(a[1])||0;if(!window.location.hash){window.location.hash=this.ka}var b=this.ka>this.q.length-1;if(!this.Ra){this.Ra=new pb(xk);if(this.Na){this.Na.ka=this.ka;this.Ra.ky(this.Na);this.Na.addEventListener("photoDataReady",Eh.p(this));this.Na.bf();b=false}this.q=this.Ra.yb;this.fa.q=this.q;this.Ra.tz(this.Hc);this.Ra.cz(this.Db);this.Ra.wh=this.$n==1;this.Ra.Ee=this.Ee;
this.Ra.mz(24);this.cd=this.Ra.ep;this.qC=this.Ra.addEventListener("itemsAdded",this.jy.p(this))}if(b){this.Ra.Ro(this.ka)}else{this.gr()}};K.prototype.jy=function(a){this.q=a.currentTarget.yb;this.fa.q=this.q;this.Xa.Xa.totalPhotoCount=this.Ra.uf;this.Xa.qz(this.q);this.gr()};K.prototype.Nb=function(a,b){var c=this.ka+a,d=this.q.length;if(b){while(c<0)c+=d;c%=d}if(c<0||c>=d)return false;this.ka=c;location.replace(location.href.replace(/#.*/,"#"+this.ka));return true};K.prototype.Df=An;K.prototype.Ef=
Dn;K.prototype.Ri=xn;K.prototype.fb=function(){var a=this.dg();if(a&&a.vsurl){return true}};var yk=wn;K.prototype.Qi=yk;K.prototype.Gm=Hn;K.prototype.Im=In;K.prototype.Tb=Bn;K.prototype.Id=Cn;K.prototype.ye=Fn;K.prototype.Rc=Gn;K.prototype.fh=vi;K.prototype.gc=un;K.prototype.Nc=vn;K.prototype.Ti=function(){return true};K.prototype.Kd=function(){};K.prototype.Ul=function(){return false};K.prototype.Cf=function(a,b){var c=this.dg();if(c){c.b=null;c.bf()}};K.prototype.jb=function(){this.dc.reset();this.aa()};
var Zq=function(){var a=this.dg();if(!a){return}if(this.Dc)this.Nb(this.lf);this.Ra.Ro(this.fa.Oc());this.dispatchEvent({type:"onShow",photo:a})};var Xq=function(){this.xb=true;this.Cr();var a=this.dg();if(!a){return}this.dispatchEvent({type:"onLoadStart",photo:a})};var Yq=function(){this.xb=false};var $q=function(){var a=this.dg();if(!a){return}this.dispatchEvent({type:"onstop",photo:a})};K.prototype.dg=function(){var a=this.fa.Oc(),b=this.q[a];if(!b&&this.Na&&this.Na.ka==a){b=this.Na}return b};
K.prototype.Wk=function(a){if(a.b){this.Wg({currentTarget:a})}else{a.addEventListener("photoDataReady",Eh.p(this));a.bf()}};var Eh=function(a){var b=a.currentTarget;if(!b){return}if(b.vsurl){this.fa.ca.xm(b.s,b.w,b.h,b.vsurl);this.fa.rm()}if(b.b){this.Xa.Wg({currentTarget:b})}};K.prototype.Wg=Eh;K.prototype.Cr=function(){var a=["q="+this.Hc];if(this.Db){a.push("psc="+this.Db)}if(this.Ee){a.push("uname="+this.Ee)}if(this.fa){var b=this.fa.Oc();if(b>this.rc){var c=Math.floor(b/this.rc)*this.rc;a.push("start="+
c)}}a.push("filter="+(this.$n?"1":"0"));var d=l("lhid_backlink"),e="/lh/search?"+a.join("&");d.href=e;this.lA(e)};K.prototype.Ku=function(){if("G"==this.Db){return"Community Photos"}else if("S"==this.Db){return"My Photos"}else if("C"==this.Db){return"My Favorites"}else if("F"==this.Db){var a=this.Ra.Nl[this.Ee];if(a){return hs(a.nickname)}}return"Unknown"};K.prototype.lA=function(a){if(!this.Ra){return}var b=l("lhid_active_tab_link"),c=l("lhid_active_tab_count");Mc(b,Ob(this.Ku()));b.href=a;c.innerHTML=
this.Ra.uf};var zk=function(a,b){pc(Dh,a);pc(Ch,b)};K.setLandingCookie=zk;var Dh="_lh_sl_u";K.LANDING_COOKIE_UNAME=Dh;var Ch="_lh_sl_p";K.LANDING_COOKIE_PHOTOID=Ch;function uk(a,b,c,d,e){this.username=a;this.id=b;this.title=c;this.ctitle=d;this.link="/lh/sredir?uname="+this.username+"&target=ALBUM&id="+this.id;this.prints="1"==e};function Ve(a,b){this.name=a;this.nickname=b;this.icon="img/noportrait.jpg";this.galleryName=this.nickname+"'s Gallery";this.loaded=false}Ve.la(Sa);Ve.prototype.bf=function(){var a="/data/feed/base/user/"+this.name+"?alt=json";N.send(a,$n.p(this))};var $n=function(a){var b=a.target,c=b.dk();if(c){this.loaded=true;var d=c.feed.icon.$t;
this.icon=d?d:this.icon;this.galleryName=c.feed.title.$t;this.dispatchEvent({type:"userDataReady"})}};Ve.prototype.lw=$n;function Se(a,b,c){this.ga=null;this.Sg=144;this.Pu=64;this.An=true;this.uC=0;this.b=null;if(a&&b){var d=b.author[0].email.$t,e=b.author[0].name.$t;this.s=b.media$group.media$content[0].url;this.id=b.gphoto$id.$t;this.w=Number(b.gphoto$width.$t);this.h=Number(b.gphoto$height.$t);this.c=za(b.media$group.media$description.$t);this.t=za(b.title.$t);this.user=a.cw(d,e);this.album=a.rv(d,
b.gphoto$albumid.$t,b.gphoto$albumtitle.$t,b.gphoto$albumctitle.$t,b.gphoto$allowprints.$t)}this.ka=c}Se.la(Sa);Se.prototype.bf=function(){if(this.b){this.dispatchEvent({type:"photoDataReady"})}else{var a="/lh/rssPhoto?uname="+this.user.name+"&iid="+this.id+"&v="+Bb()+"&js=1";N.send(a,Ds.p(this))}};var Ds=function(a){var b=a.target;try{this.b=b.dk();if(this.b.video){this.vsurl=this.b.video.streamer_url;this.vdurl=this.b.video.download_url}}catch(a){return}this.dispatchEvent({type:"photoDataReady"})};
Se.prototype.Gl=function(){if(!this.ga){var a=1;if(this.Hw&&this.Iw){a=this.Iw/this.Hw}var b=0,c=0,d=this.Sg;if(this.An){d=this.Pu;b=d;c=d}else{if(a<1){b=Math.max(Math.floor(this.Sg*a),1);c=this.Sg}else{b=this.Sg;c=Math.max(Math.floor(this.Sg/a),1)}}this.ga={url:this.s+"?imgmax="+d+(this.An?Sm:""),width:b,height:c}}return this.ga};function pb(a){this.iu=a;this.rc=24;this.wh=true;this.el();this.Nl={};this.Od={};this.ep={};this.ei=new Array(Math.ceil(Um/this.rc))}pb.la(Sa);var Vm="category=photo&alt=json&hl=en_US";
pb.PHOTO_SUFFIX=Vm;var Sm="&crop=1";pb.CROP=Sm;var Tm="filter=1";pb.CROWD=Tm;var Um=1000;pb.MAX=Um;pb.prototype.el=function(){this.Hc="";this.Db="G";this.uf=null;this.yb=[];this.iy=[]};pb.prototype.tz=function(a,b){if(this.Hc!=a){this.el();this.Hc=a}if(Y(b)){this.wh=b}};pb.prototype.cz=function(a){if(this.Db!=a){var b=this.Hc;this.el();this.Hc=b;this.Db=a;this.wh=this.Db=="G"}};pb.prototype.mz=function(a){this.rc=a};pb.prototype.Ro=function(a){var b=a/this.rc,c=Math.floor(b);if(!this.ei[c]){this.Ep(c)}var d=
b-c;if(d<0.1){c=Math.max(0,c-1)}if(d>0.9){c=Math.min(this.ei.length-1,c+1)}if(!this.ei[c]){Ho(this.Ep.p(this,c))}};pb.prototype.Ep=function(a){this.ei[a]=true;var b=["q="+Bc(this.Hc),"psc="+this.Db,"start-index="+(a*this.rc+1),"max-results="+this.rc,Vm];if(this.wh){b.push(Tm)}if(this.Db!="G"){b.push("uname="+this.Ee)}N.send(this.iu+"?"+b.join("&"),Cs.p(this,a*this.rc,this.rc))};var Cs=function(a,b,c){var d=c.target,e=d.dk();if(e){this.uf=Number(e.feed.openSearch$totalResults.$t);this.Yt(a,e.feed.entry);
Mb(this.SC)}};pb.prototype.cw=function(a,b){var c=this.Nl[a];if(!c){c=new Ve(a,b);this.Nl[a]=c;this.iy.push(c)}return c};pb.prototype.rv=function(a,b,c,d,e){var f=a+b,g=this.Od[f];if(!g){g=new uk(a,b,c,d,e);this.Od[f]=g}return g};pb.prototype.Yt=function(a,b){if(!b){return}var c=Math.min(a+b.length,this.uf),d=c-a;this.yb.length=Math.max(this.yb.length,c);if(this.zd){var e=this.zd.ka-a,f=this.zd.id,g=-1;if(e>=0&&e<d){if(b[e].id==f){g=e}else{for(var h=0;h<d;++h){if(b[h].gphoto$id.$t==f){g=h;break}}}}if(g>=
0&&g!=e){var i=b[e];b[e]=b[g];b[g]=i}}for(var h=0;h<d;++h){var k=a+h,n=null;if(this.zd&&this.zd.ka==k){n=this.zd}else{n=new Se(this,b[h],k)}this.ep[n.id]=n;n.Gp=true;this.yb[k]=n}this.dispatchEvent({type:"itemsAdded",offset:a,count:d})};pb.prototype.ky=function(a){this.zd=a;this.yb[this.zd.ka]=this.zd};function lc(a,b){this.name=a;this.weight=b}var uo=function(a,b){if(a.name==b.name){return 0}else if(a.name<b.name){return-1}else{return 1}};lc.Compare=uo;lc.prototype.toString=function(){return"["+this.name+","+this.weight+"]"};var wo=function(a){var b=[];if(a){for(var c=0;c<a.length;++c){var d=a[c],e=d.name;b.push(e)}}return b};lc.TagArrayToStringArray=wo;var Ji=function(a){var b=[];if(a){for(var c=0;c<a.length;++c){var d=new lc(a[c],0);b.push(d)}}return b};lc.StringArrayToTagArray=Ji;var xo=function(a){var b=
[];if(a){for(var c=0;c<a.length;++c){var d=a[c].name;if(d.indexOf(" ")!=-1){b.push('"'+d+'"')}else{b.push(d)}}}return b.join(" ")};lc.TagArrayToTagString=xo;lc.StringArrayToTagString=function(a){var b=[];if(a){for(var c=0;c<a.length;++c){var d=a[c];if(d.indexOf(" ")!=-1){b.push('"'+d+'"')}else{b.push(d)}}}return b.join(" ")};lc.TagStringToTagArray=function(a){return Ji(this.TagStringToStringArray(a))};var vo=/[^,'" \t\r\n][^, \t\r\n]*|\"[^"]*(?:\"|$)|\'[^']*(?:\'|$)/g;lc.UA=vo;var yo=function(a){var b=
a.match(vo),c={},d=[];if(b){for(var e=0;e<b.length;e++){var f=Ki(Ki(tq(b[e]),"'"),'"');if(f.length>0&&!c[f]){d.push(f);c[f]=1}}}return d};lc.TagStringToStringArray=yo;var Ki=function(a,b){if(a.charAt(0)==b&&a.charAt(a.length-1)==b){if(a.length>1){return a.substring(1,a.length-1)}else{return""}}return a};lc.TA=Ki;function ga(a,b,c){this.Nf=_authuser;this.q=null;this.kl=c;this.searchCorpus=mg;this.r={pnlListID:p("lhid_listPanel"),pnlAddID:p("lhid_addPanel"),pnlInputID:p("lhid_inputPanel"),pnlAlterID:p("lhid_alterPanel"),btnAddID:p("lhid_addButton"),btnDeleteID:p("lhid_deleteButton"),btnSaveID:p("lhid_saveButton"),btnCancelID:p("lhid_cancelButton"),txtNewTagsID:p("lhid_newTagsText")};this.e=D(Rn,this.r);b.appendChild(this.e);this.Yk=l(this.r.pnlListID);this.nq=l(this.r.pnlAddID);this.pq=l(this.r.pnlInputID);
this.oq=l(this.r.pnlAlterID);this.Ug=l(this.r.txtNewTagsID);this.cB=l(this.r.btnAddID);this.nu=l(this.r.btnSaveID);this.mu=l(this.r.btnCancelID);q(this.r.btnAddID,o(this,this.ws));q(this.r.btnDeleteID,o(this,this.ys));q(this.r.btnSaveID,o(this,this.em));q(this.r.btnCancelID,o(this,this.xs));this.nD=t(this.Ug,le,this.zt,true,this);this.$=a;this.Oa=[];this.Ia=0;this.Gf(false);if(!this.Hg()){this.oq.style.display="none"}}ga.prototype.zt=function(a){if(a.keyCode==at){this.xk=true;this.em();a.preventDefault()}};
ga.prototype.Hg=function(){if(this.q){return this.q.uname==this.Nf.name}return this.Nf.isOwner};ga.prototype.aa=function(){if(this.e)m.removeNode(this.e);if(this.r.btnAddID){y(this.r.btnAddID)}if(this.r.btnDeleteID){y(this.r.btnDeleteID)}if(this.r.btnSaveID){y(this.r.btnSaveID)}if(this.r.btnCancelID){y(this.r.btnCancelID)}for(var a in this){this[a]=null}};ga.prototype.we=function(){this.Gf(false);tb(this.Yk,D(wi,{}))};ga.prototype.xa=function(a,b){if(!a){if(!this.Hg()){this.we()}else{tb(this.Yk,D("<div></div>",
{}))}}else{this.Ia=b;this.It(a);this.e.style.display=""}if(a&&a.length||this.Hg()){this.e.style.display="";cb(this.oq,this.Hg())}else{this.e.style.display="none"}};ga.prototype.It=function(a){var b=[];if(a){this.Oa=a.sort(uo);var c=_user.name;if(this.q&&this.q.user){c=this.q.user.name}var d;this.searchCorpus=c?Jn:mg;if(this.kl){d=Qn}else if(this.Hg()){d=Pn;this.searchCorpus=Kn;c=this.Nf.name}else{d=Tn}var e="&"+["psc="+this.searchCorpus,"uname="+c].join("&");for(var f=0;f<a.length;++f){var g=a[f];
if(!Y(g.tagId)){g.tagId=p("lhcl_tag_");g.name=Ob(g.name)}var h=g.name,i=h.length<=30?za(h):za(h.substring(0,30))+"&#8230;",k=ja(d,{tagid:g.tagId,aname:Bc(h),name:za(h),displayName:i,username:c,searchParams:e,func:this.r.btnDeleteID});b.push(k)}}var n='<ul class="lhcl_taglist">'+b.join("")+"</ul>";tb(this.Yk,D(n,{}))};ga.prototype.Gf=function(a){this.xk=false;this.bD=a;if(a){this.pq.style.display="";this.nq.style.display="none";this.Ug.value="";this.Ug.focus()}else{this.nq.style.display="";this.pq.style.display=
"none"}};ga.prototype.Rr=function(a){var b=rc(a);if(b.length<=0){return}if(b.length>4096){alert(ms(4096,b.length));return}var c=yo(b),d=wo(this.Oa);for(var e=0;e<c.length;++e){xh(d,c[e])}this.um(Ji(d))};ga.prototype.ms=function(a){var b=[];for(var c=0;c<this.Oa.length;++c){var d=this.Oa[c];if(d["tagId"]!=a){b.push(d)}}this.um(b)};ga.prototype.Kt=function(a){if(a.length>100){alert(ks(100,a.length));return false}if(a.length==this.Oa.length){var b=0;for(var c=0;c<a.length;++c){if(this.Oa[c]==a[c]){++b}else{break}}if(b==
this.Oa.length){return false}}for(var c=0;c<a.length;++c){var d=a[c].name;if(d.length>128){alert(ls(128,d.length));return false}}return true};ga.prototype.um=function(a){if(!this.Kt(a)){return}l(this.r.btnSaveID).disabled=true;l(this.r.btnCancelID).disabled=true;var b=["tags="+Bc(xo(a)),"noredir=true"].join("&"),c=this.Ia,d=Tb(this,this.jt,c,a),e=_updatePhotoPath+"&uname="+_user.name+"&aname="+_album.name+"&iid="+c;Q.Aa(e,d,b)};ga.prototype.ws=function(){this.Gf(true)};ga.prototype.xs=function(){this.Gf(false)};
ga.prototype.em=function(){this.Rr(this.Ug.value)};ga.prototype.ys=function(a){this.ms(a)};ga.prototype.jt=function(a,b,c){if(!this.$){return}this.nu.disabled=false;this.mu.disabled=false;if(this.$.gc(c)||this.$.Nc(c)){return}if(this.xk){this.Ug.value=""}else{this.Gf(false)}this.xk=false;this.xa(b,a)};var Sn="<div><b>Tags</b></div>";ga.HTML_TAGS_LABEL=Sn;var wi='<div class="lhcl_photoinfo">Loading&#8230;<br />&nbsp;</div>';ga.HTML_TAGSDATA_LOADING=wi;var On='<div style="text-align:right"><span class="lhcl_fakelink" id="{btnAddID}" onclick="_d(\'{btnAddID}\')">Add Tag</span></div>';
ga.HTML_ADD_TAG_LINK=On;var Qn='<li><div class="lhcl_tagname"><a href="/lh/search?q={aname}{searchParams}" title="{name}">{displayName}</a></div></li>';ga.HTML_SEARCH_TAG_ROW=Qn;var Tn='<li><div class="lhcl_tagname"><a href="/lh/search?q={aname}{searchParams}" title="{name}">{displayName}</a></div></li>';ga.HTML_TAG_ROW=Tn;var Pn='<li><a href="/lh/search?q={aname}{searchParams}" title="{name}">{displayName}</a><a class="lhcl_tagdelete" href="javascript:_d(\'{func}\', \'{tagid}\')"id="{btnDeleteID}" > &nbsp;&nbsp;</a></li>';
ga.HTML_OWNER_TAG_ROW=Pn;var Nn='<div class="lhcl_addtagform"><table class="lhcl_addtag"><tr><td width="100%"><input class="lhcl_taginputfield" type="text" id="{txtNewTagsID}" maxlength="4096" /></td><td class="lhcl_addtagbuttoncell"><input id="{btnSaveID}" onclick="_d(\'{btnSaveID}\')" type="button" value="Add" /><input id="{btnCancelID}" onclick="_d(\'{btnCancelID}\')" type="button" value="Cancel" /></td></tr></table></div>';ga.HTML_ADD_TAG_INPUT=Nn;var Mn='<div class="lhcl_addtaghelp">You can enter a space separated list of tags.<br>For example: beach "pacific ocean"</div>';
ga.HTML_ADD_TAG_HELP=Mn;var Rn='<div id="lhcl_tagbox" class="lhcl_toolbox" style="display: none;"><div class="lhcl_tools lhcl_hideoverflow"><div id="{lhui_tagsHeaderPanel}" style="margin: 0 0 1em 0">'+Sn+'</div><div id="{pnlListID}">'+wi+'</div><div id="{pnlAlterID}"><div class="lhcl_pseudo_hr"></div><div id="{pnlAddID}">'+On+'</div><div id="{pnlInputID}">'+Nn+Mn+"</div></div></div></div>";ga.HTML_TAGS_BOX=Rn;function Ai(a){if((!location.hash||location.hash=="#")&&_photo.length){var b="http://"+location.host+location.pathname+location.search+"#"+_photo[0].id;location.replace(b);return}window.setTimeout('location.replace("'+_album.link+'")',1000);var c=l("lhid_main");this.e=m.createElement("div");c.appendChild(this.e);this.e.innerHTML="The requested photo is invalid or unavailable.<br />You will be redirected to the album page."}Ai.prototype.jb=function(){if(this.e)m.removeNode(this.e)};function sc(a,b){this.Mb=a;this.g=b;this.Ae=m.createElement("div");this.Ae.className="lhcl_bandselect";Qd(this.Ae,0.2);this.ad=this.xd.p(this);this.Ib=this.je.p(this);this.Gc=this.Jb.p(this);this.ge=this.pc.p(this);this.Qg=[];this.Ja={};this.nr=j.userAgent.IE||j.userAgent.SAFARI;this.Hp=false;t(this.g,"mousedown",this.ad);this.g.onselectstart=function(){return false}}sc.prototype.xd=function(a){$(this.g,"mousedown",this.ad);t(document,"mousemove",this.Ib);t(document,"mouseup",this.Gc);t(document,
"mouseout",this.ge);var b=Pb(),c=a.clientX+b.scrollLeft,d=a.clientY+b.scrollTop;this.xf=c;this.zf=d;var e=this.Ae.style;e.left=c+"px";e.top=d+"px";e.width="0";e.height="0";this.Bk=new Na(d,c,d,c);this.Qg.length=0;if(!(a.shiftKey||a.ctrlKey)){this.Mb.Hj()}document.body.appendChild(this.Ae);a.stopPropagation();a.preventDefault()};sc.prototype.je=function(a){var b=Pb(),c=a.clientX+b.scrollLeft,d=a.clientY+b.scrollTop,e=new Na(Math.min(d,this.zf),Math.max(c,this.xf),Math.max(d,this.zf),Math.min(c,this.xf)),
f=this.Ae.style;f.left=e.left+"px";f.top=e.top+"px";f.width=e.right-e.left+"px";f.height=e.bottom-e.top+"px";var g=j.math.Box.boundingBox(e,this.Bk),h=Pj(g,this.Bk),i=Pj(g,e),k=a.ctrlKey?Bh:wk;for(var n=0;n<h.length;n++){this.Nq(e,h[n],k)}for(var n=0;n<i.length;n++){this.Nq(e,i[n],Ah)}this.Bk=e};var Ah=0;sc.RESTORE=Ah;var wk=1;sc.SELECT=wk;var Bh=2;sc.TOGGLE=Bh;sc.prototype.Nq=function(a,b,c){var d=this.Mb.Hh(b.right,b.top),e=this.Mb.Hh(b.left,b.bottom),f=this.Mb.slide,g=false;for(var h=d.row;h<=
e.row;h++){var i=h*d.rowLength+e.col,k=Math.min(h*d.rowLength+d.col,(h+1)*d.rowLength-1);k=Math.min(k,f.length-1);for(var n=i;n<=k;n++){var s=f[n],u=s.Ev(),z=pa(u),v=new Na(z.y,z.x+u.offsetWidth,z.y+u.offsetHeight,z.x);if(c==Ah){if(!Wg(a,v)){x.remove(this.Qg,s);g=true;this.Ja[s.iid]=[s,s.selected]}}else if(Wg(b,v)){vg(this.Qg,s);g=true;this.Ja[s.iid]=[s,c==Bh?!s.selected:true]}}}if(g){if(this.nr&&!this.lock){sg(this,this.bp,0)}else{this.bp()}}};sc.prototype.bp=function(){for(var a in this.Ja){var b=
this.Ja[a];b[0].ap(b[1]);delete this.Ja[a]}if(this.nr){this.Hp=true;sg(this,function(){this.Hp=false},0)}};sc.prototype.Jb=function(a){t(this.g,"mousedown",this.ad);$(document,"mousemove",this.Ib);$(document,"mouseup",this.Gc);$(document,"mouseout",this.ge);for(var b=0;b<this.Qg.length;b++){var c=this.Qg[b];if(a.ctrlKey){this.Mb.Cd(c,!c.selected)}else{this.Mb.Cd(c,true)}}document.body.removeChild(this.Ae)};sc.prototype.pc=function(a){if(!a.relatedTarget){this.Jb(a)}};function Db(a,b,c,d,e,f,g){this.Mb=a;this.e=D(go,{url:e});this.ca=this.e.firstChild;this.ad=this.xd.p(this);this.Ib=this.je.p(this);this.Gc=this.Jb.p(this);t(this.ca,"mousedown",this.ad);this.wd=f;this.xh=new Date(g);this.iid=d;this.old_layout=c;this.layout_num=b;this.src=e;this.selected=false}Db.prototype.remove=function(){m.removeNode(this.e)};Db.prototype.eb=function(){return this.e};Db.prototype.Ev=function(){return this.ca};Db.prototype.xd=function(a){if(!this.selected||a.shiftKey||a.ctrlKey){this.Mb.pw(this,
a.shiftKey,a.ctrlKey)}if(this.selected){t(document,"mousemove",this.Ib);t(document,"mouseup",this.Gc);$(this.ca,"mousedown",this.ad);this.xf=a.clientX;this.zf=a.clientY}a.stopPropagation();a.preventDefault()};Db.prototype.je=function(a){var b=a.clientX-this.xf,c=a.clientY-this.zf;if(b*b+c*c>=fo){this.Jb(a);b+=this.ca.offsetTop;c+=this.ca.offsetLeft;this.Mb.kw(this,a.clientX,a.clientY,b,c)}a.stopPropagation();a.preventDefault()};Db.prototype.Jb=function(a){$(document,"mousemove",this.Ib);$(document,
"mouseup",this.Gc);t(this.ca,"mousedown",this.ad)};Db.prototype.select=function(a){this.selected=!(!a);this.ap(a)};Db.prototype.ap=function(a){this.ca.firstChild.style.visibility=a?"":"hidden"};var jo=function(a,b){if(a.layout_num<b.layout_num){return-1}else if(a.layout_num>b.layout_num){return 1}else{return 0}};Db.sortFunc=jo;var io=function(a,b){return uq(a.wd,b.wd)};Db.nameSort=io;var ho=function(a,b){if(a.xh<b.xh){return-1}else if(a.xh==b.xh){return 0}else{return 1}};Db.dateSort=ho;var fo=16;
Db.DRAG_RADIUS_SQUARED=fo;var go='<div class="lhcl_slide" style="left:0"><div class="lhcl_slideImage"style="background-image:url({url})"><div class="lhcl_selectBox" style="visibility:hidden"><div class="lhcl_innerSelectBox"></div></div></div></div>';Db.TEMPLATE=go;function Jc(a){this.Mb=a;this.qh=false;this.Um=this.eu.p(this);this.oa=[]}Jc.prototype.vi=function(a){var b=a.first,c=a.last,d=a.mid;a.t0=Bb();a.x0.length=(a.x1.length=c-b);var e=this.Mb.slide;for(var f=b;f<c;f++){var g=f-b,h=parseInt(e[f].eb().style.left,10);a.x0[g]=h;if(d>=0){a.x1[g]=f<d?-Ci:Ci}else{a.x1[g]=0}}};var Ci=10;Jc.SLIDE_OFFSET=Ci;Jc.prototype.Pz=function(a,b,c){var d=a*c,e=d+b;if(this.oa.length){var f=this.oa[0];if(f.first==d){if(f.mid!=e){f.mid=e;this.vi(f);this.Dl()}return}else{if(f.mid>=
0){f.mid=-1;this.vi(f)}for(var g=1;g<this.oa.length;g++){var h=this.oa[g];if(h.first==d){this.oa.splice(g,1);this.oa.unshift(h);this.vi(h);this.Dl();return}}}}var i=Math.min(d+c,this.Mb.slide.length),a={first:d,last:i,mid:e,x0:[],x1:[],t0:-1};this.vi(a);this.oa.unshift(a);this.Dl()};Jc.prototype.Dl=function(){if(!this.qh){this.qh=true;qg(this.Um)}};Jc.prototype.qr=function(){if(this.qh){this.qh=false;kk(this.Um)}};Jc.prototype.reset=function(){var a=this.Mb.slide;while(this.oa.length){var b=this.oa.pop(),
c=b.first+b.x0.length;for(var d=b.first;d<c;d++){a[d].eb().style.left="0"}}this.qr()};Jc.prototype.eu=function(a){var b=this.Mb.slide,c=false;for(var d=this.oa.length-1;d>=0;d--){var e=this.oa[d];if(e.t0<0)continue;c=true;var f=a-e.t0;if(f<Bi){var g=f/Bi;for(var h=0;h<e.x0.length;h++){b[e.first+h].eb().style.left=e.x0[h]+(e.x1[h]-e.x0[h])*g+"px"}}else{for(var h=0;h<e.x1.length;h++){b[e.first+h].eb().style.left=e.x1[h]+"px"}e.t0=-1;if(e.mid==-1)this.oa.splice(d,1)}}if(!c)this.qr()};var Bi=100;Jc.DURATION=
Bi;function U(a,b,c){this.e=m.createElement("div");this.fo=m.createElement("div");this.fo.className="lhcl_tableEnd";a.appendChild(this.e);a.appendChild(this.fo);this.bB=new sc(this,a);this.Kq=new Jc(this);this.za=[];this.hc=null;this.slide=[];this.Ib=this.je.p(this);this.Gc=this.Jb.p(this);this.ge=this.pc.p(this);q(p("reorder"),this.jl.p(this));q(p("copyToAlbum"),this.Ju.p(this));q(p("moveToAlbum"),this.Jx.p(this));q(p("deleteSelected"),this.Yu.p(this));q(p("sortSlides"),this.Zx.p(this));this.av=b;this.Sn=
c;this.Ij(true)}U.prototype.Zt=function(a,b,c,d,e){c+="?crop=1&imgmax=64";var f=new Db(this,this.slide.length,a,b,c,d,e);this.slide.push(f);this.e.appendChild(f.eb())};U.prototype.Uw=function(a,b){b.sort(jo);if(a>=this.slide.length){for(var c=0;c<b.length;c++){this.slide.push(b[c]);this.e.appendChild(b[c].eb())}}else{var d=this.e.childNodes[a];for(var c=0;c<b.length;c++){this.e.insertBefore(b[c].eb(),d);this.slide.splice(a,0,b[c]);a++}}for(var c=0;c<this.slide.length;c++){this.slide[c].layout_num=
c}};U.prototype.No=function(){return Yi(this.za,function(a){return a.iid})};U.prototype.Hy=function(a){var b=Pb(),c=a.clientX+b.scrollLeft,d=a.clientY+b.scrollTop,e=this.Hh(c,d,true),f=e.index;for(var g=this.slide.length-1;g>=0;g--){var h=this.slide[g];if(h.selected){this.slide.splice(g,1);h.remove();if(g<f)f--}}this.Uw(f,this.za)};U.prototype.Hj=function(){while(this.za.length){this.Cd(this.za.pop(),false)}};U.prototype.Cd=function(a,b,c){x.remove(this.za,a);if(b){if(c){this.za.unshift(a)}else{this.za.push(a)}}a.select(b);
if(this.za.length<2){this.Ij(this.za.length==0)}};U.prototype.pw=function(a,b,c){if(F.contains(j.userAgent.PLATFORM,"Mac")){c=b;b=false}if(b){if(this.za.length){var d=this.za[0].layout_num,e=a.layout_num;if(!c)this.Hj();if(d<e){for(var f=d;f<=e;f++){this.Cd(this.slide[f],true)}}else{for(var f=d;f>=e;f--){this.Cd(this.slide[f],true)}}}else{this.Cd(a,true)}}else if(c){this.Cd(a,!a.selected,true)}else{this.Hj();this.Cd(a,true)}};U.prototype.kw=function(a,b,c,d,e){if(this.hc)m.removeNode(this.hc);var f=
pa(a.eb());this.xf=b;this.zf=c;this.Mj=f.x+d;this.Ah=f.y+e;var g=D(Cm,{x:this.Mj,y:this.Ah,src:a.src});Qd(g.firstChild,0.5);document.body.appendChild(g);if(this.za.length>1){var h=m.createElement("div");h.className="lhcl_draginfo";g.appendChild(h);h.innerHTML=us(this.za.length-1)}t(document,"mousemove",this.Ib);t(document,"mouseup",this.Gc);t(document,"mouseout",this.ge);this.Mp=document.documentElement.scrollHeight-Cd();this.hc=g};U.prototype.je=function(a){var b=a.clientX,c=a.clientY,d=b-this.xf,
e=c-this.zf;this.Sp(d,e);var f=Pb(),g=b+f.scrollLeft,h=c+f.scrollTop,i=this.Hh(g,h,true);this.Kq.Pz(i.row,i.col,i.rowLength);var k=Cd(),n=0;if(c<ae){n=c-ae}else if(k-c<ae){n=ae-(k-c)}if(n){n=hg*(n/ae);n=Qc(n,-hg,hg)}this.nj(n)};U.prototype.pc=function(a){if(!a.relatedTarget)this.nj(0)};U.prototype.Sp=function(a,b){this.hc.style.left=this.Mj+a+"px";this.hc.style.top=this.Ah+b+"px"};U.prototype.Jb=function(a){$(document,"mousemove",this.Ib);$(document,"mouseup",this.Gc);$(document,"mouseout",this.ge);
this.Kq.reset();this.Hy(a);this.nj(0);if(this.hc)m.removeNode(this.hc);this.hc=null};U.prototype.nj=function(a){if(a==0){if(this.Kg){kk(this.Kg);this.Kg=null}}else{this.Qy=a;if(!this.Kg&&this.Mp>0){this.yp=Bb();this.Kg=this.Ry.p(this);qg(this.Kg)}}};U.prototype.Ry=function(a){var b=(a-this.yp)*0.0010;this.yp=a;var c=this.Qy*b,d=Pb(),e=d.scrollTop;if(c!=0){d.scrollTop=Qc(e+c,0,this.Mp);if(this.hc){var f=this.hc.offsetLeft-this.Mj,g=this.hc.offsetTop-this.Ah;this.Ah+=d.scrollTop-e;this.Sp(f,g)}}};U.prototype.Oy=
function(){if(this.slide.length==0)return 0;var a=this.e.offsetWidth,b=Math.floor(a/this.slide[0].eb().offsetWidth);return Math.max(b,1)};U.prototype.Hh=function(a,b,c){var d=0,e=0,f=this.Oy();if(f>0){var g=this.slide[0].eb(),h=g.offsetWidth,i=g.offsetHeight,k=pa(g),n=Math.max(a-k.x,0),s=Math.max(b-k.y,0);if(c)n+=h/2;var u=Math.floor((this.slide.length-1)/f);d=Math.min(Math.floor(s/i),u);var z=d!=u?f:this.slide.length%f||f;e=Math.min(Math.floor(n/h),z)}var v=d*f+e;return{index:v,row:d,col:e,rowLength:f}};
U.prototype.dr=function(a){this.jl();var b=this.No();if(b.length>100){alert(pi(b.length,Dm));return}this.Wf(true);this.lr(false);new R(a,b,this.wu.p(this))};U.prototype.wu=function(){this.Wf(false);this.lr(true)};U.prototype.lr=function(a){var b=Dg("select");for(var c=0;c<b.length;c++){b[c].style.visibility=a?"":"hidden"}};U.prototype.Ju=function(){this.dr(3)};U.prototype.Jx=function(){if(!_album.blogger||confirm("Are you sure you want to move these photos? They will no longer appear in your blog if you move them.")){this.dr(4)}};
U.prototype.Yu=function(){this.jl();this.Wf(true);if(!confirm(_album.blogger?"Are you sure you want to delete the selected photos? They will no longer appear in your blog if you delete them.":"Are you sure you want to delete the selected photos?\n\nImportant: deleting photos cannot be undone.")){this.Wf(false);return}var a=["noredir=true","optgt=DELETE","aid="+_album.id,"selectedphotos="+this.No()];document.body.style.cursor="wait";Q.Aa(_selectedPhotosPath,this.Xu.p(this,this.za.length),a.join("&"))};
U.prototype.Xu=function(a,b){if(b.status>=400||b.text.indexOf("success")<0){alert(ni);document.body.style.cursor="";return}if(a>=this.slide.length){location.href=_album.link}else{location.reload()}};U.prototype.jl=function(a){if(a)this.Wf(true);var b=Infinity,c=-1;for(var d=0;d<this.slide.length;d++){if(this.slide[d].old_layout!=d){b=d;break}}for(var d=this.slide.length-1;d>b&&d>0;d--){if(this.slide[d].old_layout!=d){c=d+1;break}}var e=[],f=Infinity,g=-1;for(var d=b;d<c;d++){var h=this.slide[d];e.push(h.iid);
f=Math.min(f,h.old_layout);g=Math.max(g,h.old_layout)}if(e.length){var i=["aid="+_album.id,"uname="+Bc(_authuser.name),"start="+f,"stop="+g,"iids="+e.join(",")];Q.Aa(_reorderPath,Tb(this,this.Iy,a),i.join("&"))}else{if(a){document.location=a}}};U.prototype.Iy=function(a,b){if(b.status>=400||b.text.indexOf("success")<0){alert(ni);return}if(a){document.location=a}};U.prototype.Wf=function(a){this.av.disabled=a;this.Ij(a)};U.prototype.Ij=function(a){if(this.za.length==0)a=true;for(var b=0;b<this.Sn.length;b++){this.Sn[b].disabled=
a}};U.prototype.or=function(a){this.slide.sort(a);for(var b=0;b<this.slide.length;b++){var c=this.slide[b];c.remove();this.e.appendChild(c.eb());c.layout_num=b}};U.prototype.Zx=function(a){if(a.value=="name"){this.or(io)}else if(a.value=="date"){this.or(ho)}a.value="default"};var ae=40;U.SCROLL_THRESHHOLD=ae;var hg=2000;U.MAX_SCROLL_SPEED=hg;var Dm=100;U.MAX_PHOTOS_TO_COPY=Dm;var Cm='<div style="position:absolute;left:{x}px;top:{y}px"><div class="lhcl_slideImage" style="background-image:url({src})"></div></div>';
U.DRAG_PROXY_HTML=Cm;function Te(a,b){M.call(this,"lhcl_menu");this.Ni=1000;this.wc=a;this.zg=b;this.DC=false;this.Wq(this.wc,qh);Mb(this.Ne);this.Ne=t(this.zg,Xb,this.Sk.p(this));t(this.zg,Ys,this.Tu,false,this)}Te.la(M);Te.prototype.Sk=function(a){Gq.call(this);a.preventDefault()};Te.prototype.Tu=function(){if(this.gb){this.Rb(false)}};var ce=function(a){kb.call(this,a);this.Uc=false};Te.Item=ce;ce.la(kb);ce.prototype.nl=function(a){this.Uc=a;if(this.g){this.Dr()}};ce.prototype.Dr=function(){if(!this.g){return}if(this.Uc){I.add(this.g,
"lhcl_active")}else{I.remove(this.g,"lhcl_active")}};ce.prototype.vh=function(){if(!this.mc){throw Error("MenuItem is not attached to a menu");}this.g=Vb("div",{className:this.mc.vo()},this.Ba,this.Sb?Vb("span",null,"\u25b6"):null);this.g.onselectstart=function(){return false};return this.g};function Ca(a){Oc.call(this);var b=a.query,c=null;this.oa=[];for(var d in a){if("primary"==d||"query"==d){continue}this.oa.push(a[d])}this.ob=l("lhid_searchbox");this.mi=l("lhid_querytext");this.Hd=!Pd(rc(b));
this.UC=l("lhid_searchbox_context");this.Sy=l("lhid_psc");this.Ty=l("lhid_crowdfilter");this.zg=l("lhid_btn");var e=l("lhid_searchanchor");if(!e){e=l("lhid_searchanchor_on")}this.mc=new Te(e,this.zg);this.ob.value=Ob(b);this.mi.value=this.Hd?this.ob.value:"";var f=null;for(var g=0;g<this.oa.length;++g){var d=this.oa[g],h=d.name;d.name=h;var i=null;if(h=="-"){i=new mh}else{i=new ce(h);i.sf(d)}this.mc.add(i);if(d.is_primary){i.nl(true);this.ta=i;c=d}i.Dr();if(mg==d.search_corpus){f=i}}this.Ec(this.mc,
oh,this.Dz,true,this);this.Ec(this.ob,Xb,this.qn,true,this);this.Ec(this.ob,je,this.qn,true,this);this.Ec(this.ob,Ng,this.qk,true,this);this.Ec(this.ob,ke,this.qk,true,this);this.Ec(this.ob,yj,this.qk,true,this);this.Ec(this.ob,Kd,this.Er,true,this);this.Ec(document,"selectstart",this.Uy,true,this);if(f){this.sf(f)}else{var k=c?c.search_corpus:"G",n=c?c.name:"Community Photos";this.$q(k,n)}}Ca.la(Oc);var mg="G";Ca.GLOBAL=mg;var Jn="F";Ca.FOREIGN=Jn;var Kn="S";Ca.SELF=Kn;Ca.CONTACTS="C";Ca.UNKNOWN=
"U";var Ln=function(){if(this.Yb())return;Bp.call(this)};Ca.prototype.qa=Ln;Ca.aD=function(a,b){if(j.userAgent.IE){if(!Ca.pj){Ca.pj=document.getElementsByTagName("base")[0].href}a.src=Ca.pj+"img/spacer.png";a.style.filter="progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+Ca.pj+b+"', sizingMethod='crop')"}else{a.src=b}};Ca.prototype.Uy=function(a){if(this.mc.gb){a.preventDefault()}};Ca.prototype.Dz=function(a){this.sf(a.item)};Ca.prototype.qn=function(){this.ob.focus();if(!this.Hd){this.ob.value=
"";this.mi.value="";I.remove(this.ob,"lhcl_nosearch")}};Ca.prototype.qk=function(a){var b=rc(this.ob.value),c=Pd(b);this.mi.value="";if(this.Hd&&c){this.Hd=false}else{this.Hd=!c;if(this.Hd){this.mi.value=b}}};Ca.prototype.Er=function(){if(!this.Hd){I.add(this.ob,"lhcl_nosearch");var a=this.ta.$b().name;if(a){a=Ob(a);this.ob.value=a}}else{I.remove(this.ob,"lhcl_nosearch")}};Ca.prototype.sf=function(a){if(this.ta){this.ta.nl(false)}a.nl(true);this.ta=a;var b=this.ta.$b();this.$q(b.search_corpus,b.name)};
Ca.prototype.$q=function(a,b){this.YA=a;var c=ss(b);this.zg.title=c;if(!this.Hd){this.ob.value=Ob(b)}this.Sy.value=a;this.Ty.value="G"==a?1:0;this.Er()};function B(a,b,c,d,e){Oa(a,"element passed to DP_DatePicker constructor is null");this.e=a;this.Ha=c?c:this.e.id+"_";this.Ma=d?d:"DP_";Ud[this.Ha]=this;if(e){Rc(e,Ka,"opt_today is not an ICAL_Date");this.Ed=e}else{this.Ed=Ll()}this.Qd=nb(this.Ed.n,this.Ed.j,1);this.Zf=0;this.hv=!(!b);this.Ll=false;this.zq=null;this.Wp=null;this.Sf={};this.ce={};this.kg={};this.va={};this.Vd=null;this.wg=null;this.Sq=new Ad(this);this.Gx=new Ad(this);this.yl=false;this.gb=false;this.Lb=new Tc;this.he=0;this.yh=null;
this.En=null;this.Iz=true;this.$k=null;this.Bj=null;this.Jk=null;this.Ig();this.Mz=false;this.wz(0);this.bz(0);this.mk=false;this.cg=null;this.db=null;this.Wc=null;this.hf=null;this.gf=null;this.vp=null;this.mg=false;this.Kr=null;this.Jr=null;var f=this,g=function(h){var i=h.startDate,k=h.endDate,n;if(!i){n=Td[this.of]}else if(!k||i.Fa(k)){n="Selected: "+f.Jh(i,true)}else{n="Selected: "+f.Jh(i)+" - "+f.Jh(k)}f.sy(n)};if(this.yl)this.Qm(g);this.Jp=new Ad(this)}var Td={};B.MSG_DATE_SELECTION=Td;Td[0]=
"Select a date";Td[1]="Select a range of dates";Td[2]="Select dates";Td[3]="&nbsp;";B.prototype.bz=function(a,b){if(a!=0&&a!=1&&a!=7&&a!=30&&a!=-1&&!(b instanceof Function)){throw new Error("Invalid click mode: "+a);}this.Bu=a;this.rn=b};B.prototype.Cz=function(a){if(a!=this.Ll){this.Ll=a;this.Ig()}};B.prototype.tv=function(){return this.Bu};B.prototype.wz=function(a){if(!(0<=a&&a<=3)){Le("Invalid selection mode: "+a)}if(this.of==a){return}this.of=a;this.De()};B.prototype.ek=function(){return this.of};
B.prototype.hd=function(){this.gb=true;this.Ig()};B.prototype.Zc=function(){this.e.innerHTML="";this.gb=false};B.prototype.ug=function(){return this.gb};B.prototype.hk=function(){return eb(this.Ha+"tbl")};B.prototype.iz=function(a){Oa(0<=a&&a<=6,a+" not a valid first day of week");this.Zf=a;this.Ig()};B.prototype.so=function(){return this.Zf};B.prototype.rz=function(a){Rc(a,Function);this.$k=a};B.prototype.dz=function(a){Rc(a,Function);this.Bj=a};B.prototype.kz=function(a){Rc(a,Function);this.Jk=
a};B.prototype.Ig=function(){if(!this.gb){return}var a=this.Ha,b,c=this.Qd.j,d=this.Qd.n,e=[c==1?12:c-1,c,c==12?1:c+1],f=nb(this.Ed.n,this.Ed.j,1),g=uh(d,c-1,1).fc(),h=uh(d,c+1,1).fc();if(this.$k){e[0]=this.$k(g)}else{var i=g.na()>=f.na()?"&laquo;":"&lsaquo;&nbsp;";e[0]=i+mb.MONTHS[e[0]]}if(this.Bj){e[1]=this.Bj(this.Qd)}else{e[1]=mb.MONTHS[e[1]]+" "+d}if(this.Jk){e[2]=this.Jk(h)}else{var k=h.na()-f.na()<=0?"&raquo;":"&nbsp;&rsaquo;";e[2]=mb.MONTHS[e[2]]+k}var n=Ec(d,c),s=Ec(g.n,g.j),u=new Array(49),
z=this.Qd.vv()-this.Zf;if(z<0)z+=7;if(n<30||z<5)z+=7;for(var v=0;v<z;++v){u[v]=nb(g.n,g.j,s-z+v+1)}for(var v=z,A=0;A<n;++v){u[v]=nb(d,c,++A)}for(var v=z+n,A=0;v<u.length;++v){u[v]=nb(h.n,h.j,++A)}this.Kr=u[0];this.Jr=u[u.length-1];var T=[],J=this.hv?[2,3,2]:[1,5,1];T.push('<table cols=7 cellspacing="0" cellpadding="3" id="',a,'tbl"',' class="',this.Ma,'monthtable" ',' style="-moz-user-select:none; cursor:pointer;">','<tr class="',this.Ma,'heading" id="',a,'header">',"<td colspan=",J[0]," unselectable=on",
' onmousedown="'+Rh(or)+"(",Li(this.Ha),')"',' id="',a,'mhl" class="',this.Ma,'prev">',e[0],"</td>","<td colspan=",J[1],' unselectable="on"',' id="',a,'mhc" class="',this.Ma,'cur">',e[1],"</td>","<td colspan=",J[2],' unselectable="on"',' onmousedown="'+Rh(nr)+"(",Li(this.Ha),')"',' id="',a,'mhr" class="',this.Ma,'next">',e[2],"</td>","</tr>");if(this.Ll){T.push('<tr class="',this.Ma,'days" id="',a,'dow">');for(var v=0;v<mb.NARROWWEEKDAYS.length;++v){T.push('<td unselectable="on"',' class="',this.Ma,
'dayh" id="',a,"day_",v,'">',mb.NARROWWEEKDAYS[(v+this.Zf)%7],"</td>")}T.push("</tr>")}var hc=(7-this.Zf)%7,Fc=(hc+6)%7;this.Sf={};var b=null,Ba=null,Xh=Rh(mr);for(var v=0,A=-1;v<7;++v){T.push('<tr id="',a,"week_",v,'">');for(var ic=0;ic<mb.WEEKDAYS.length;++ic){++A;var Tf=this.Lb.contains(u[A]);Ba=[];if(v==0)Ba.push(this.Ma+"day_top");if(ic==0)Ba.push(this.Ma+"day_left");else if(ic==6)Ba.push(this.Ma+"day_right");Ba.push(this.Ma+"week"+(ic==hc||ic==Fc?"end":"day")+(Tf?"_selected":""));if(A<z||A>=
z+n){Ba.push(this.Ma+"offmonth");if(u[A].o<=7){Ba.push(this.Ma+"month_top");if(u[A].o==1&&ic!=0){Ba.push(this.Ma+"month_left")}}}else{Ba.push(this.Ma+"onmonth");if(u[A].o<=7){Ba.push(this.Ma+"month_top");if(u[A].o==1&&ic!=0){Ba.push(this.Ma+"month_left")}}if(u[A].o==this.Ed.o&&c==this.Ed.j&&d==this.Ed.n){Ba.push(this.Ma+"today"+(Tf?"_selected":""))}}var wd="";if(this.En){var Gc=this.En(u[A]);if(Gc){wd=' style="'+Gc+'"'}}T.push('<td id="',a,"day_",v,"_",ic,'"',' class="',Ba.join(" "),'"',wd,' onclick="',
Xh,'(this)"',' unselectable="on">',u[A].o,"</td>")}T.push("</tr>")}if(this.yl){T.push('<tr class="',this.Ma,'months">','<td colspan="7" id="',a,'sel"></td></tr>')}T.push("</table>");this.e.innerHTML=T.join("");this.Vd=eb(a+"day_0_0");this.wg=eb(a+"day_6_6");var b=this.Vd,Qb=b.parentNode,xd=null,Uf=null,A=-1,Ne=-1;while(Qb!=null){++Ne;if(Ne==7)break;var Vf=-1;while(b!=null){++A;++Vf;var Yh=a+"day_"+Ne+"_"+Vf;this.va[Yh]=u[A];this.Sf[u[A].toString()]=b;this.kg[Yh]=xd;if(xd)this.ce[Uf]=b;xd=b;Uf=Yh;
b=b.nextSibling}Qb=Qb.nextSibling;if(Qb!=null){b=Qb.firstChild}}this.he=7;if(!this.Iz){var Cr=eb(a+"week_4"),Tl=eb(a+"week_5"),Zh=eb(a+"week_6");if(this.va[a+"day_4_0"].j!=c){Cr.style.display="none";Tl.style.display="none";Zh.style.display="none";this.he=4}else if(this.va[a+"day_5_0"].j!=c){Tl.style.display="none";Zh.style.display="none";this.he=5}else if(this.va[a+"day_6_0"].j!=c){Zh.style.display="none";this.he=6}}this.zq=g;this.Wp=h;if(this.yh){this.yh.call(null,this)}this.Vt()};B.prototype.refresh=
function(){if(this.yh){this.yh.call(null,this)}};B.prototype.Qm=function(a){return this.Sq.add(a)};B.prototype.De=function(a){a=arguments.length===0||a;var b=this.Lb.lj();for(var c=0;c<b.length;++c){var d=this.Sf[b[c].toString()];this.Dd(d,false)}this.Lb.clear();if(!this.mg){this.Yq(null);this.pl(null)}if(a)this.Ud()};B.prototype.pn=function(a){if(this.rn){this.rn.call(null,a);return}var b=eb(a),c=this.Lb;switch(this.of){case 1:var d=this.tv();if(d==0)break;if(d!=1&&(d!=-1||!c.contains(this.va[a]))){var e=
this.va[b.id],f;switch(d){case -1:if(c.Zd()>7&&this.Zh()){var g=b.id.substr(b.id.length-3,1);e=this.va[this.Ha+"day_"+g+"_0"]}f=c.Zd()-1;break;case 7:var g=b.id.substr(b.id.length-3,1);e=this.va[this.Ha+"day_"+g+"_0"];f=6;break;case 30:e=this.va[b.id];e=nb(e.n,e.j,1);var h=Cf(e);f=Ec(e.n,e.j)-1;break;default:Le("Invalid click mode: "+d)}Oa(f!==undefined,"duration should have been defined");var h=Cf(e);h.o+=f;var i=h.fc();this.rf(e,i);return}Oa(d==1||d==-1&&c.contains(this.va[a]),"not a case for single date selection");
this.De(false);case 0:if(c.Zd()>0){var k=c.lj()[0];c.remove(k);var n=this.Sf[k.toString()];if(n)this.Dd(n,false)}c.add(this.va[b.id]);this.Dd(b);this.Ud(this.va[b.id]);break;case 2:break;case 3:default:break}};B.prototype.Yq=function(a){this.db=a;this.hf=a?this.va[a.id]:null};B.prototype.pl=function(a){this.Wc=a;this.gf=a?this.va[a.id]:null};B.prototype.Jw=function(){return this.mg};B.prototype.Pg=function(a,b){this.De(false);this.mg=true;this.Yq(this.Dh(a));var c=this.va[this.db.id];this.Lb.add(c);
this.Dd(this.db);this.rf(c);this.pl(this.db)};B.prototype.Ih=function(a,b,c){this.mg=false;this.Wc=this.Dh(a);if(this.Zh()){this.Ud(this.hf,this.gf,false);return}var d,e;if(this.va[this.Wc.id].na()<this.va[this.db.id].na()){d=this.va[this.Wc.id];e=this.va[this.db.id]}else{d=this.va[this.db.id];e=this.va[this.Wc.id]}this.Ud(d,e,false)};B.prototype.Te=function(a,b,c,d){this.vp=Bk(a);if(this.of!=1||this.mk)return;this.mk=true;var e=this;window.setTimeout(function(){try{if(e.mg){e.pv.call(e,b,c,d)}}finally{e.mk=
false}},50)};B.prototype.Zh=function(){return this.Mz};B.prototype.pv=function(a,b,c){var d=this.vp,e=this.Dh(d);if(e===this.Wc)return;var f=this.Wc;this.pl(e);Oa(f!=e);var g=this.va,h=g[f.id].na()<g[e.id].na(),i=g[f.id].na()<g[this.db.id].na(),k=g[e.id].na()<g[this.db.id].na(),n=g[this.db.id].na()<g[e.id].na(),s=g[this.db.id].na()<g[f.id].na(),u,z,v,A,T=k?this.Wc:this.db,J=k?this.db:this.Wc;if(this.Zh()){var hc=Pl(g[J.id],g[T.id]);if(hc>=7){var Fc,Ba;Fc=parseInt(T.id.charAt(T.id.length-3),10);Ba=
parseInt(J.id.charAt(J.id.length-3),10);T=eb(this.Ha+"day_"+Fc+"_0");J=eb(this.Ha+"day_"+Ba+"_6")}this.qe(this.Vd,T,false);this.qe(J,this.wg,false);this.qe(T,J,true);this.hf=g[T.id];this.gf=g[J.id]}else{if(h){if(i){z=k?this.kg[e.id]:this.kg[this.db.id];this.qe(f,z,false)}if(n){u=s?this.ce[f.id]:this.ce[this.db.id];this.qe(u,e,true)}}else{if(s){u=n?this.ce[e.id]:this.ce[this.db.id];this.qe(u,f,false)}if(k){z=k?this.kg[this.db.id]:this.kg[f.id];this.qe(e,z,true)}}}v=g[T.id];A=g[J.id];this.Ud(v,A,true)};
B.prototype.qe=function(a,b,c){Oa(a);Oa(b);Rc(c,Boolean);var d=false;while(a){if(c){d=this.Lb.add(this.va[a.id])}else{d=this.Lb.remove(this.va[a.id])}if(d){this.Dd(a,c)}if(a.id===b.id)break;a=this.ce[a.id];Oa(a,"did not find endCell: "+b.id)}};var Ih={4:"day_3_6",5:"day_4_6",6:"day_5_6",7:"day_6_6"};B.LAST_DAY_OF_WEEK=Ih;B.prototype.fu=function(a,b){if(!this.cg)return;if(b){a.x-=this.cg.x;a.y-=this.cg.y}else{a.x+=this.cg.x;a.y+=this.cg.y}};B.prototype.Dh=function(a){var b=dc(this.Vd),c=this.$v(),
d=Wc(a);this.fu(d);var e=7,f=this.ao(c.x,b.w,e,d.x),g=this.ao(c.y,b.h,this.he,d.y);return eb(this.Ha+"day_"+g+"_"+f)};B.prototype.ao=function(a,b,c,d){if(d<a)return 0;var e=Math.floor((d-a)/b);return e>=c?c-1:e};B.prototype.$v=function(){var a=this.Ha,b=this.he,c=dc(this.Vd),d=dc(eb(a+Ih[b]));return new Ic(c.x,c.y,d.x+d.w-c.x,d.y+d.h-c.y,c.coordinateFrame)};B.prototype.Jh=function(a,b){return mb.MONTHS[a.j]+" "+a.o};B.prototype.Ud=function(a,b,c){var d={};d.startDate=a;d.endDate=b||a;d.Jw=!(!c);d.mode=
this.ek();this.Sq.fireEvent(d)};B.prototype.Wm=function(a){if(a instanceof Ka)return a;if(a instanceof ua){return nb(a.n,a.j,a.o)}else{Oa(false,"Invalid arg: "+a)}};B.prototype.rf=function(a,b,c){var d=this.ek();c=c!==false;if(a)a=this.Wm(a);if(b)b=this.Wm(b);if(a)this.hr(a);if(!a||d==3){this.De(c);return}if(d==0){this.De(false);var e=this.Sf[a.toString()];this.Lb.add(a);this.Dd(e);if(c)this.Ud(a)}else if(d==1){if(!b)b=a;var f=Pl(b,a),g=false;if(this.Zh()&&f>=7){var h=Wh(a)+7,i=Wh(b)+7;h=(h-this.so())%
7;i=(i-this.so())%7;var k;k=uh(a.n,a.j,a.o-h);a=k.fc();k=uh(b.n,b.j,b.o+(6-i));b=k.fc();g=this.hr(a)}if(g){this.De(false)}var e=this.Vd;this.hf=a;this.gf=b;var n=this.wg,s=a.na(),u=b.na();for(;e;e=this.ce[e.id]){var z=this.va[e.id],v=this.Lb.contains(z),A=z.na()>=s&&z.na()<=u;if(v!=A){if(A){this.Lb.add(z);this.Dd(e)}else{this.Lb.remove(z);this.Dd(e,false)}}if(e===n)break}if(!e){n=this.wg;var k=Cf(this.va[this.wg.id]),T=null;do{k.o+=1;T=k.fc();this.Lb.add(T)}while(!T.Fa(b))}if(c)this.Ud(a,b)}};B.prototype.xl=
function(a,b){if(this.Qd.j==a.j&&this.Qd.n==a.n)return false;b=arguments.length==1||b;this.Qd=nb(a.n,a.j,1);this.Ig();if(b)this.Gx.fireEvent();return true};B.prototype.hr=function(a,b){if(a.na()>=this.Kr.na()&&a.na()<=this.Jr.na()){return false}return this.xl(a,b)};B.prototype.getSelection=function(){switch(this.ek()){case 0:if(this.Lb.Zd()){return this.Lb.lj()[0]}else{return null}case 1:var a=this.hf?this.hf:null,b=this.gf?this.gf:null;if(!a||!b)return null;return[a,b];case 2:return null;case 3:default:return null}};
B.prototype.sy=function(a){if(this.yl){eb(this.Ha+"sel").innerHTML=a}};B.prototype.Dd=function(a,b){if(!a)return;if(!Me(b))b=true;var c=[],d=[],e=" "+a.className+" ",f=" "+this.Ma;if(b){if(-1!=e.indexOf(f+"today ")){c.push(f+"today ");d.push(f+"today_selected ")}if(-1!=e.indexOf(f+"weekday ")){c.push(f+"weekday ");d.push(f+"weekday_selected ")}else if(-1!=e.indexOf(f+"weekend ")){c.push(f+"weekend ");d.push(f+"weekend_selected ")}}else{if(-1!=e.indexOf(f+"today_selected ")){d.push(f+"today ");c.push(f+
"today_selected ")}if(-1!=e.indexOf(f+"weekday_selected ")){d.push(f+"weekday ");c.push(f+"weekday_selected ")}else if(-1!=e.indexOf(f+"weekend_selected ")){d.push(f+"weekend ");c.push(f+"weekend_selected ")}}for(var g=0;g<c.length;++g){e=e.replace(c[g],d[g])}if(c.length!=0){a.className=e}};var Ud={};B.nB=Ud;B.staticGetPickerById=function(a){return Ud[a]};function or(a){var b=Ud[a];return b.xl(b.zq)}function nr(a){var b=Ud[a];return b.xl(b.Wp)}function mr(a){var b=a.id,c=b.match(/(.*)day_\d+_\d+/),
d=Ud[c[1]];return d.pn(b)};B.prototype.Vt=function(){if(this.nx===true)return;this.nx=true;var a=this.Ha,b=this,c=this.e;lr(function(d){if(b.of==1&&d===c){var e=new Va(d);e.escapedStartPoint=false;e.Pg=function(f,g){var h=Wc(f),i=dc(b.Vd),k=dc(eb(a+Ih[b.he]));if(h.x<i.x||h.x>=k.x+k.w||h.y<i.y||h.y>=k.y+k.h)return false;this.startPoint=h.Ca();this.startEvent=f;var n=eb(a+"lasso");if(!n){n=document.createElement("div");n.id=a+"lasso";n.style.position="absolute";n.style.display="none";document.body.appendChild(n)}ka=
5;da=3;r=n;return true};e.Te=function(f,g,h,i){if(!this.escapedStartPoint){var k=vr(this.startPoint,Wc(f));if(k>5){this.escapedStartPoint=true;b.Pg.call(b,this.startEvent,g)}else{return true}}b.Te.apply(b,arguments);return true};e.Ih=function(f,g,h){if(this.escapedStartPoint){b.Ih.apply(b,arguments)}else{if(this.startPoint){var i=b.Dh(this.startEvent).id;b.pn.call(b,i)}}return true};return e}else{return undefined}})};B.prototype.log=function(){this.Jp.fireEvent(arguments)};function Tc(){this.od={};
this.qb=0}Tc.prototype.Zd=function(){return this.qb};Tc.prototype.add=function(a){var b=this.Ol(a);if(b in this.od)return false;this.od[b]=a.fc();++this.qb;return true};Tc.prototype.remove=function(a){var b=this.Ol(a);if(!(b in this.od))return false;delete this.od[b];--this.qb;return true};Tc.prototype.clear=function(a){this.od={};this.qb=0};Tc.prototype.contains=function(a){var b=this.Ol(a);return b in this.od};Tc.prototype.lj=function(){var a=new Array(this.Zd()),b=-1;for(var c in this.od)a[++b]=
this.od[c];return a};Tc.prototype.Ol=function(a){Oa(a instanceof Ka||a instanceof ua,"expected a date or datetime: "+a);return a.toString().substr(0,9)};function Ad(a){this.wy=a;this.Fc=[]}Ad.prototype.add=function(a){Rc(a,Function);if(!a)return false;for(var b=0;b<this.Fc.length;++b){if(a===this.Fc[b])return false}this.Fc.push(a);return true};Ad.prototype.remove=function(a){if(!a)return false;for(var b=0;b<this.Fc.length;++b){if(a===this.Fc[b]){this.Fc.splice(b,1);return true}}return false};Ad.prototype.fireEvent=
function(a){for(var b=0;b<this.Fc.length;++b){this.Fc[b].apply(this.wy,arguments)}};Ad.prototype.Zd=function(){return this.Fc.length};function Pr(a){this.vd=a;this.ka=0;this.ub=null};Pr.prototype.remove=function(){if(!this.ub)throw new Error("no current element!");this.vd.remove(this.ub);this.ub=null;--this.ka};function R(a,b,c){P.Pa(this);this.Ea=a;var d={body_id:p("dlg"),toggle_id:p("toggle"),form_id:p("form"),submit_id:p("input"),cancel_id:p("input"),album_id:p("input"),title_id:p("input"),desc_id:p("input"),dayselect:p("select"),monthselect:p("select"),yearselect:p("select"),albumlist:p("list"),datefunc:p("func"),choosefunc:p("func"),createfunc:p("func"),selectfunc:p("func"),onsubmit:p("func"),oncancel:p("func"),title:"Untitled Album",description:"",location:"",publicChecked:"checked",privateChecked:"",
uname:_user.name};switch(a){case 5:d.header="Edit album information";d.action=_editAlbumPath;d.dialog="updateAlbumDialog";d.redir="SAME_ALBUM";d.aid=_album.id;d.title=_album.title;d.description=_album.description;d.location=_album.location;d.publicChecked=_album.unlisted?"":"checked";d.privateChecked=_album.unlisted?"checked":"";break;case 3:d.header=bs(b.length);d.action=_copyOrMovePath;d.dialog="CopyOrMovePhotosDialog";d.selected=b.join(",");d.photoop="copy";d.uname=_user.name;break;case 4:d.header=
ns(b.length);d.action=_copyOrMovePath;d.dialog="CopyOrMovePhotosDialog";d.selected=b.join(",");d.photoop="move";break;case 0:d.header="Create a new album";d.action=_createAlbumPath;d.dialog="NewOrExistingDialog";d.dest="new";break;case 2:d.header="Upload Photos: Create Album";d.action=_createAlbumPath;d.dialog="NewOrExistingDialog";d.redir="upload";d.dest="new";break;case 1:default:d.header="Upload Photos: Create or Select Album";d.action=_createAlbumPath;d.dialog="NewOrExistingDialog";d.redir="upload";
d.dest="new";break}if(a==5||a==0||a==2)this.bl=true;this.b=d;this.gC=b;this.cf=c;this.za=-1;this.lb=m.createElement("div");this.lb.className="lhcl_cover";document.body.appendChild(this.lb);this.Ub();this.ec=o(this,this.Ub);wa(window,"resize",this.ec);window.scrollTo(0,0);Bf();qb("hideVideo");this.e=D(cm,this.b);document.body.insertBefore(this.e,document.body.firstChild);q(this.b.oncancel,o(this,this.jb));q(this.b.onsubmit,o(this,this.Ys));q(this.b.datefunc,o(this,this.zm));q(this.b.choosefunc,o(this,
this.km));q(this.b.createfunc,o(this,this.Vi));q(this.b.selectfunc,o(this,this.gh));this.qc=Ma(this,this.Tb);wa(document,"keydown",this.qc);if(_album&&_album.id&&a==1)this.km();else this.Vi();if(_LH.dl)this.As()};R.prototype.aa=function(){P.Sa(this);if(this.b){y(this.b.oncancel);y(this.b.onsubmit);y(this.b.datefunc);y(this.b.choosefunc);y(this.b.createfunc);y(this.b.selectfunc)}Aa(document,"keydown",this.qc);Aa(window,"resize",this.ec);for(var a in this)this[a]=null};R.prototype.jb=function(){if(this.e)m.removeNode(this.e);
if(this.lb)m.removeNode(this.lb);if(this.cf)this.cf();this.aa()};R.prototype.Vi=function(){this.Md=null;if(this.Ea==3||this.Ea==4)this.b.albumop="new";var a=l(this.b.submit_id);if(this.Ea==5){a.value="Save changes"}else if(this.Ea==0){a.value="Create"}else{a.value="Continue"}a.disabled=false;this.ym(!_user.noalbums);var b=l(this.b.body_id),c=ja(dm,_user);this.b.publicSearchable="";if(_features.globalsearch){this.b.public_desc=ws(c);if(_user.searchable){this.b.publicSearchable="_searchable"}}else{this.b.public_desc=
vs(c)}tb(b,D(Zl(_LH.dl),this.b));var d=l(this.b.title_id);if(_album.blogger&&this.Ea==5){d.disabled=true;d=l(this.b.desc_id)}d.focus();d.select();if(!_LH.dl){var e=this.Ea==5?wh(_album.datestring):new Date;if(e==null){e=new Date}var f=e.getMonth(),g=e.getFullYear(),h=(new Date).getFullYear(),i,k=l(this.b.monthselect);k.innerHTML="";for(i=0;i<yd.length;i++){var n=m.createElement("option");k.appendChild(n);n.value=i;n.innerHTML=yd[i];if(i==f)n.selected=true}var s=l(this.b.yearselect);s.innerHTML="";
for(i=Wf;i<=h;i++){var u=m.createElement("option");s.appendChild(u);u.value=(u.innerHTML=i);if(i==g)u.selected=true}this.zm()}};R.prototype.km=function(){this.za=-1;if(typeof Q=="undefined"||!Q.Hf()){if(this.bl){this.jb()}else{this.bl=true;this.Vi()}return}if(this.Ea==3||this.Ea==4)this.b.albumop="existing";var a=l(this.b.submit_id);a.value="Select Album";a.disabled=true;this.ym(false);var b=l(this.b.body_id);tb(b,D(Xl,this.b));if(this.ab){this.hm()}else{var c="/data/feed/back_compat/user/"+_user.name+
"?alt=json&kind=album";Q.Aa(c,o(this,this.vs))}};R.prototype.ym=function(a){var b=l(this.b.toggle_id);if(this.bl){b.innerHTML="";b.style.display="none"}else{b.style.display="";tb(b,D(a?$l:Yl,this.b))}};R.prototype.vs=function(a){var b=Q.bm(a);if(!b){return}this.ab=b.feed.entry;this.hm()};R.prototype.zm=function(){var a=l(this.b.dayselect),b=l(this.b.yearselect).value,c=l(this.b.monthselect).value,d;if(a.value>=1){d=a.value}else{var e=this.Ea==5?wh(_album.datestring):new Date;if(e==null){e=new Date}d=
e.getDate()}var f,g;for(g=31;g>0;g--){var h=new Date(b,c,g);if(h.getMonth()==c){f=g;break}}a.innerHTML="";for(g=1;g<=f;g++){var i=m.createElement("option");a.appendChild(i);i.value=(i.innerHTML=g);if(g==d)i.selected=true}};R.prototype.hm=function(){if(!this.ab){return}var a=l(this.b.albumlist);a.innerHTML="";var b=-1;for(var c=0;c<this.ab.length;++c){var d=this.ab[c];if(_album&&_album.id==d.gphoto$id.$t){if(this.Ea==4||this.Ea==3){this.ab.splice(c,1);c--;continue}b=c}var e=false;for(var f=0;f<d.link.length;f++){e|=
d.link[f].rel=="edit"}if(!e){if(this.Ea==4||this.Ea==3||this.Ea==1){this.ab.splice(c,1);c--;continue}}d.selectfunc=this.b.selectfunc;d.onsubmit=this.b.onsubmit;d.name=d.title.$t;d.icon=d.photo$thumbnail.$t;if(d.rights.$t!="public"){d.access='<span class="lhcl_unlisted">Unlisted</span>'}else{d.access='<span class="lhcl_public">Public</span>'}d.num=c;a.appendChild(D(Wl,d))}if(!this.ab){return}if(b>=0)this.gh(b)};R.prototype.Ys=function(){var a=l(this.b.form_id);if(!a)return;var b=l(this.b.title_id);
if(b&&rc(b.value)==""){alert("The title of your album must not be blank. Please enter a title.");return}var c=l("lhid_datefield");if(c){var d=l(this.b.yearselect).value,e=parseInt(l(this.b.monthselect).value,10)+1,f=l(this.b.dayselect).value;c.value=e+"/"+f+"/"+d}var g=l(this.b.desc_id);if(g&&g.value.length>1000){alert(pt(Tr(g.value.length,1000),Ur(g.value.length,1000)));return}l(this.b.submit_id).disabled=true;l(this.b.cancel_id).disabled=true;if(this.Ea==1&&this.Md){location.href="/lh/webUpload?uname="+
_user.name+"&aid="+this.Md}else{a.submit()}};R.prototype.Tb=function(a){if(this.za<0)return;switch(a.keyCode){case 38:window.scrollTo(0,0);this.gh(Math.max(this.za-1,0));cc(a);break;case 40:window.scrollTo(0,0);this.gh(Math.min(this.za+1,this.ab.length-1));cc(a);break}};R.prototype.gh=function(a){var b=l(this.b.albumlist);if(this.za>=0)b.childNodes[this.za].className="lhcl_fakelink";b.childNodes[a].className="lhcl_selected lhcl_fakelink";this.za=a;this.Md=this.ab[a].gphoto$id.$t;l(this.b.album_id).value=
this.Md;var c=l(this.b.submit_id);c.disabled=false;c.focus();c.parentNode.style.textAlign="right";var d=b.childNodes[this.za],e=d.offsetTop,f=e+d.offsetHeight,g=b.scrollTop,h=g+b.offsetHeight;if(e<g)b.scrollTop=Math.max(e-(f-e)*0.3,0);else if(f>h)b.scrollTop=e+(f-e)*1.3-(h-g)};R.prototype.Ub=function(){var a=Math.max(document.body.offsetHeight,document.body.scrollHeight);a=Math.max(a,document.body.clientHeight);a=Math.max(a,document.documentElement.clientHeight);this.lb.style.height=a+"px"};R.prototype.As=
function(){kl(mb);Lh(mb);this.Lh=l("lhid_date");this.tq=l("lhid_dp");var a=this.Ea==5?wh(_album.datestring):new Date;if(a==null){a=new Date}this.Eb=Fo(a);var b=new B(this.tq,false,"lhid_dp_","DP_",this.Eb);b.iz(_LH.calDay);b.Cz(true);this.$i();this.jh();Pc(this.Lh,"focus",o(this,this.Hs),false);Pc(this.Lh,"blur",o(this,this.Gs),false);b.Fj=o(this,this.Is);b.Qm(o(this,this.Ht));b.dz(function(c){return ds(yd[c.j-1],c.n)});b.rz(function(c){return"&laquo;"});b.kz(function(c){return"&raquo;"});this.Xb=
b};R.prototype.Hs=function(){this.tq.style.display="";this.Xb.hd();As(this.Xb);return true};R.prototype.Gs=function(a){if(!this.Xb.ug()){this.kh();return true}var a=a||window.event,b=false;if(j.userAgent.IE){var c=dc(this.Xb.hk());b=c.contains(Wc(a))}else{var d=a.explicitOriginalTarget;b=Br(this.Xb.hk(),d)}if(!b){this.Xb.Zc();this.kh()}return true};R.prototype.Is=function(a){if(!this.Xb.ug()){this.kh();return true}var b=dc(this.Xb.hk()),c=Wc(a);if(!b.contains(c)){this.kh();return true}return false};
R.prototype.Ht=function(){var a=this.Xb.getSelection();if(a){if(a.n<Wf){alert(Fm);this.Xb.rf(this.Eb)}else{this.Eb=a;this.jh();this.$i()}this.Xb.Zc()}};R.prototype.kh=function(){var a=this.Lh.value,b=new Date,c=ll($h,a,0,b,null);if(c>0){if(b.getFullYear()<Wf){alert(Fm);this.jh()}else{this.Eb=Fo(b);this.Xb.rf(this.Eb);this.$i()}}else{this.jh()}};R.prototype.$i=function(){l(this.b.dayselect).value=this.Eb.o;l(this.b.monthselect).value=this.Eb.j-1;l(this.b.yearselect).value=this.Eb.n;l("lhid_datefield").value=
this.Eb.j+"/"+this.Eb.o+"/"+this.Eb.n};R.prototype.jh=function(){var a=new Date(this.Eb.n,this.Eb.j-1,this.Eb.o);this.Lh.value=sd(mb.DATEFORMATS[$h],a,null)};var em=function(){var a="";for(var b=0;b<yd.length;b++){if(yd[b].length>a.length){a=yd[b]}}return a};R.yC=em;function Fo(a){return nb(a.getFullYear(),a.getMonth()+1,a.getDate())}var $h=3;R.DATE_TYPE=$h;var yd=["January","February","March","April","May","June","July","August","September","October","November","December"];R.MONTHS=yd;R.USE_DATEPICKER=
true;var Wf=1970;R.MIN_YEAR=Wf;var cm='<div class="lhcl_dialog"><form id="{form_id}" method="post" action="{action}" onsubmit="_d(\'{onsubmit}\'); return false"><input type="hidden" name="uname" value="{uname}" /><input type="hidden" name="dialogName" value="{dialog}" /><input type="hidden" name="redir" value="{redir}" /><input type="hidden" name="dest" value="{dest}" /><input type="hidden" name="photoop" value="{photoop}" /><input type="hidden" name="selectedphotos" value="{selected}" /><div class="lhcl_dialog_body"><h1>{header}</h1><div id="{toggle_id}"></div><div id="{body_id}"></div></div><div class="lhcl_buttons"><input type="submit" class="lhcl_default" id="{submit_id}" /><input type="button" id="{cancel_id}" value="Cancel" onclick="_d(\'{oncancel}\')" /></div></form></div>';
R.DIALOG_FRAME=cm;var am='<select id="{monthselect}" name="dateMonth" onchange="_d(\'{datefunc}\')"><option>'+em()+'</option></select> <select id="{dayselect}" name="dateDay"><option>00</option></select> <select id="{yearselect}" name="dateYear" onchange="_d(\'{datefunc}\')"><option>0000</option></select><input type="hidden" id="lhid_datefield" name="date" />';R.DATEFORM_HTML=am;var bm='<div><input id="lhid_date" class="lhcl_input" type="text" autocomplete="off" /></div><div id="lhid_dp" style="position:absolute;width:20em;"></div><input type="hidden" id="lhid_datefield" name="date" /><input type="hidden" id="{dayselect}" name="dateDay" /><input type="hidden" id="{monthselect}" name="dateMonth" /><input type="hidden" id="{yearselect}" name="dateYear" />';
R.DATEPICKER_HTML=bm;var Zl=function(a){return'<div><h2>Title</h2><input type="hidden" name="aid" value="{aid}" /><input type="hidden" name="albumop" value="{albumop}" /><input type="text" class="lhcl_input" id="{title_id}" name="title" value="{title}" maxlength="100"/><h2>Date</h2><div style="position:relative;">'+(a?bm:am)+'</div><h2>Description <em>(optional)</em></h2><textarea class="lhcl_input" name="description" id="{desc_id}">{description}</textarea><h2>Place Taken <em>(optional)</em></h2><input type="text" class="lhcl_input" name="location" value="{location}" maxlength="100" /><p><input type="radio" name="access" value="public" id="lhid_publicaccess" {publicChecked} /> <label for="lhid_publicaccess"><span class="lhcl_public{publicSearchable}_label">Public</span></label> <em>(default)</em> &#8211; For albums you want to show publicly.</p><p class="lhcl_mini_text">{public_desc}</p><p><input type="radio" name="access" value="private" id="lhid_unlistedaccess" {privateChecked} /> <label for="lhid_unlistedaccess"><span class="lhcl_unlisted_label">Unlisted</span></label> &#8211; For albums that you only want to share with select people</p></div>'};
R.CREATE_ALBUM_HTML_T=Zl;var dm='<a href="{link}">{link}</a>';R.USER_GALLERY_HTML=dm;var Xl='<div><input type="hidden" name="albumop" value="{albumop}" /><input id="{album_id}" type="hidden" name="aid" /><div class="lhcl_albumlist" id=\'{albumlist}\'>'+be+"</div></div>";R.CHOOSE_ALBUM_HTML=Xl;var Wl='<table class="lhcl_fakelink" onmousedown="_d(\'{selectfunc}\', {num}); return false" ondblclick="_d(\'{onsubmit}\')" onselectstart="return false"><tr><td><img src="{icon}" width="32" height="32" /></td><td width="100%">{name}<br />{access}</td></tr></table>';
R.ALBUM_ITEM_HTML=Wl;var $l="<p>"+cs("<a href=\"javascript:_d('{choosefunc}')\">","</a>")+"</p>";R.CREATE_TOGGLE_HTML=$l;var Yl="<p>"+Zr("<a href=\"javascript:_d('{createfunc}')\">","</a>")+"</p>";R.CHOOSE_TOGGLE_HTML=Yl;function Rb(a,b,c,d,e){this.Od=a;this.ze=null;this.$A=null;this.Nz=b;this.Sm=c;this.Zz=d;this.Yz=e;q("sortAlbums",o(this,this.Cm));this.Cm(Zf.param)}Rb.prototype.Cm=function(a){var b=[];if(a==Zf.param){this.Zl(this.Od);b.push(Zf.label);b.push(ja(fi,ei))}else if(a==ei.param){if(this.ze==null){this.ze=[];this.ze.length=this.Od.length;for(var c=0;c<this.Od.length;c++){this.ze[c]=this.Od[c]}this.ze.sort(tm)}this.Zl(this.ze);b.push(ja(fi,Zf));b.push(ei.label)}var d=um+" "+b.join(" | ");this.Nz.innerHTML=
d};Rb.prototype.Zl=function(a){this.Sm.innerHTML="";for(var b=0;b<a.length;b++){var c=a[b];c.width=this.Zz;c.height=this.Yz;c.photo_count=c.count;if(c.unlisted){c.listing='<span class="lhcl_status">Unlisted</span>'}c.i=b;var d=c.blogger?sm:rm;c.image_html=ja(d,c);this.Sm.appendChild(D(qm,c));var e=l("url"+b);Mi(e,2,c.title,225)}};var gi=function(a){Fs("_lhmessageid",a?"INDEX_SET_ON":"INDEX_SET_OFF",-1,"/");window.location.reload()};Rb.SetPrefHandler=gi;var tm=function(a,b){return b.upload_secs-a.upload_secs};
Rb.vA=tm;var um='<span class="lhcl_notbold">Sort by:</span>';Rb.SORT_SELECTOR_HTML=um;var fi="<a href=\"javascript:_d('sortAlbums', '{param}');\">{label}</a>";Rb.SORT_OPTION_HTML=fi;var di={album:{param:"none",label:"Album date"},upload:{param:"upload",label:"Upload date"},name:{param:"name",label:"Name"}},Zf=di.album,ei=di.upload;Rb.SORT_DATA=di;var qm='<div class="lhcl_album"><div class="lhcl_imagebox"><div class="lhcl_frame"><div class="lhcl_padding"><a href="{url}" onclick="_d(\'AlbumClearPaging\')">{image_html}</a></div></div></div><div class="lhcl_desc"><table class="lhcl_title" style="height:4em;"><tr><td><div class="lhcl_titlebox"><a href="{url}" id="url{i}"></a> <span class="lhcl_info">({photo_count})</span></div><div class="lhcl_info">{date} {listing}</div></td></tr></table></div></div>';
Rb.ALBUM_COVER_HTML=qm;var rm='<img src="{src}" width="{width}" height="{height}"/>';Rb.ALBUM_IMAGE_HTML=rm;var sm='<div class="lhcl_blogger" style="background: url({src}) no-repeat left; width: {width}px; height: {height}px"><img src="img/blogger.gif" /></div>';Rb.BLOGGER_ALBUM_IMAGE_HTML=sm;Rb.SET_PREF_MSG_HTML='  <a href="{settings_url}">Change this setting</a>  <a href="{learnmore_url}">Learn More</a>';function Nr(){l("lhid_emailtofield").focus();q("CancelMail",Kr);_initEmailAutocomplete(l("lhid_emailtofield"),"/lh/contacts?out=js",true);if(_features.contactpicker){nf=(mf.serverBase="/lh/contacts/ui/");t(l("lhid_pick"),rb,Mr)}}function Mr(a){var b="toolbar=no,location=no,menubar=no,scrollbars=no,resizable=yes,status=no,width=315,height=610,top="+a.screenY+",left="+a.screenX+",screenY="+a.screenY+",screenX="+a.screenX,c=Qg("lhid_emailtofield",false).toString();window.open(c,"_picker",b)}function Or(){var a=
l("lhid_emailtofield"),b=l("lhid_emailto");if(!(a&&b))return false;var c=wr(a.value),d=[];for(var e=0;e<c.length;e++){var f=c[e];if(!f)continue;var g=Wm(c[e])[1];if(!g||!nt(g)){alert(Wr(f));return false}d.push(f)}if(!d.length){alert("Please specify at least one recipient.");return false}b.value=d.join(",");return true}function Kr(a){var b=l("lhid_emailform");for(var c=0;c<b.elements.length;c++){var d=b.elements[c];if(d.type!="textarea")continue;if(rc(d.value)!=""){if(confirm('Your email has not been sent. Press "Okay" to discard your message, or "Cancel" to continue writing.')){break}else{return}}}window.location=
a};function Dr(a,b,c,d){Q.Aa(a,Hr.p(null,b,c))}function Hr(a,b,c){if(c.status>=400||c.text.indexOf("success")<0){alert(qi);return}l("lhid_addFav").style.display="none";l("lhid_inFav").style.display="";l("lhid_nolink").style.display="";qb("hideVideo");new Hc(a,b)}function Gr(a){if(a.status>=400||a.text.indexOf("success")<0){alert(qi);return}var b=l("lhid_nolink");b.style.display="none";b=l("lhid_link");b.style.display=""}function Hc(a,b){P.Pa(this);this.xy=a;var c={lhui_username:b,lhui_yes_func:p("func"),
lhui_no_func:p("func")};this.b=c;this.lb=m.createElement("div");this.lb.className="lhcl_cover";document.body.appendChild(this.lb);this.Ub();this.ec=o(this,this.Ub);wa(window,"resize",this.ec);window.scrollTo(0,0);Bf();this.e=D(fm,this.b);document.body.insertBefore(this.e,document.body.firstChild);q(this.b.lhui_yes_func,o(this,this.ps));q(this.b.lhui_no_func,o(this,this.wt));this.qc=Ma(this,this.Tb);wa(document,"keydown",this.qc);this.Bt()}Hc.prototype.aa=function(){P.Sa(this);if(this.b){y(this.b.lhui_yes_func);
y(this.b.lhui_no_func)}Aa(document,"keydown",this.qc);Aa(window,"resize",this.ec);for(var a in this)this[a]=null};Hc.prototype.jb=function(){if(this.e)m.removeNode(this.e);if(this.lb)m.removeNode(this.lb);qb("restoreVideo");this.aa()};Hc.prototype.Bt=function(){if(typeof Q=="undefined"||!Q.Hf()){window.location=this.gD+"&redir="+encodeURIComponent(window.location);this.jb()}};Hc.prototype.Ub=function(){var a=Math.max(document.body.offsetHeight,document.body.scrollHeight);a=Math.max(a,document.body.clientHeight);
a=Math.max(a,document.documentElement.clientHeight);this.lb.style.height=a+"px"};Hc.prototype.wt=function(){this.jb()};Hc.prototype.ps=function(){Q.Aa(this.xy,Gr);this.jb()};var ai="{lhui_username}";Hc.USERNAME_PLACEHOLDER=ai;var fm='<div class="lhcl_dialog"><div class="lhcl_dialog_body lhcl_addfavorite"><p><img src="img/favorites_checked.gif" />'+Qr(ai)+"</p><br /><hr /><p>Now that this user is one of your favorites, you can link to their public gallery from your public gallery.</p><p>"+Vr(ai)+'</p><br /><table><tr><td class="lhcl_halfwidth lhcl_align_right""><input type="button" value="Yes" onclick="_d(\'{lhui_yes_func}\')" /></td><td class="lhcl_halfwidth lhcl_dialog_button"><input type="button" value="No, Skip this" onclick="_d(\'{lhui_no_func}\')" /></td></tr><tr><td></td><td class="lhcl_dialog_button"><span class="lhcl_mini_text">(you can always do this later)</span></td></tr></table></div></div>';
Hc.FAVDIALOG_FRAME=fm;function Ib(a,b,c){this.ua=a;this.Qa=b;this.xg=c;this.$o=l("lhid_header");this.Pm=l("lhid_activity");this.jq=l("lhid_favorites");this.Vz=l("lhid_teaser");this.vC=l("lhid_lastshown");this.ua.sort(this.Du);this.ly();this.rq(false);var d=window.location.hash;if(d==""){this.Di("")}else{this.Di(d)}this.xc=o(this,this.nA);qg(this.xc);q("call",hm);q("toggleNotify",o(this,this.gA));q("toggleLink",o(this,this.eA))}var hm=function(a){Q.Aa(a,gm)};Ib.makeUpdate=hm;var gm=function(a){if(a.status>=400||a.text.indexOf("success")<
0){alert(qi);window.location.reload()}};Ib.handleResponseError=gm;Ib.prototype.nA=function(){var a=window.location.hash;if(this.Ru==a){return}this.Di(a)};Ib.prototype.ly=function(){var a=[];a.push('<table class="lhcl_fullwidth"><tr>');for(var b=0;b<this.Qa.length;++b){if(null==this.Qa[b]||this.Qa[b].deleted){continue}a.push('<td class="lhcl_halfcol">',"<table><tr>",'<td><a href="',this.Qa[b].link,'">','<img class="lhcl_activity" src="',this.Qa[b].src,'"></a></td>','<td><a href="',this.Qa[b].link,
'" class="lhcl_plain">');var c=this.Qa[b].type;switch(this.Qa[b].reason){case "starred":a.push('<div class="lhcl_title">',this.Qa[b].album,"</div>",'<div class="lhcl_info">By ',this.Qa[b].person,".</div>");break;case "photos_added":a.push('<div class="lhcl_title">',this.Qa[b].album,"</div>",'<div class="lhcl_info">',Rr(this.Qa[b].person,this.Qa[b].photo_count),"</div>");break;case "email_notification":switch(c){case "album":a.push('<div class="lhcl_title">',this.Qa[b].album,"</div>",'<div class="lhcl_info">',
xs(this.Qa[b].person),"</div>");break;case "photo":a.push('<div class="lhcl_title">',this.Qa[b].person,"</div>",'<div class="lhcl_info">',"Shared a photo with you.","</div>");break;case "account":a.push('<div class="lhcl_title">',this.Qa[b].person,"</div>",'<div class="lhcl_info">',"Shared gallery with you.","</div>");break}break}a.push('<div class="lhcl_info">',this.Qa[b].o,"</div>","</a></td></tr></table></td>");if((b+1)%2==0){a.push("</tr><tr>")}}a.push("</tr></table>");this.Pm.innerHTML=a.join("")};
Ib.prototype.rq=function(a){$a.remove("AddFavoriteId");if(this.zj==a)return;this.zj=a;var b=[];if(_features.contacts){b.push("<p>");if(a){b.push(es('<a href="'+this.xg+Yf+'">',"</a>"))}else{b.push(fs('<a href="'+this.xg+Xf+'">',"</a>"))}b.push("</p>")}b.push('<table class="lhcl_fullwidth">');var c=a?Xf:Yf,d=encodeURIComponent(this.xg+c),e=false;for(var f=0;f<this.ua.length;++f){if(!_features.contacts||a||this.ua[f].notify){if(e){b.push('<tr><td colspan="2" class="lhcl_listEnd"></td></tr>')}else{e=
true}b.push('<tr class="lhcl_favoritePersonListed">','<td class="lhcl_host"><a href="',this.ua[f].link,'"><img class="lhcl_portrait" src="',this.ua[f].src,'" ></a></td>','<td class="lhcl_data"><table><tr>','<td><table style="width:100%;"><tr><td><a href="',this.ua[f].link,'">',this.ua[f].name,"</a>");b.push("</td>");if(_features.contacts){b.push('<td class="lhcl_starProperty"><input type="checkbox" ');if(this.ua[f].notify){b.push('checked="true"')}b.push("onclick=\"_d('toggleNotify', '",f,"'); ",
"_d('call', '",this.ua[f].notifylink,"');\"/>","Receive updates","</td>")}b.push('<td class="lhcl_starProperty">');b.push('<div><input type="checkbox" ');b.push("onclick=\"_d('toggleLink', '",f,"'); _d('call', '");if(this.ua[f].linked){b.push(this.ua[f].removelink,'\');" checked="true" ')}else{b.push(this.ua[f].addlink,"');\" ")}b.push("/>","show link on my gallery");b.push("</div></td></tr></table></td>");if(this.ua[f].unstar){b.push('<td class="lhcl_starProperty">',"<a");if(_features.newStrings){b.push(" onclick=\"return confirm('",
Om,"');\"")}b.push(' href="',this.ua[f].unstar,"&redir=",d,'">',"remove user","</a></td>")}else{b.push("<td>&nbsp;</td>")}b.push("</tr>");if(this.ua[f].albums.length>0){b.push('<tr><td colspan="2"><div class="lhcl_unlistedListing">',"Unlisted albums you have seen",":</div></td></tr>");for(var g=0;g<this.ua[f].albums.length;++g){var h="";if((g+1)%2){h=" lhcl_colorbar"}b.push('<tr><td class="lhcl_starred',h,'">');if(this.ua[f].albums[g].deleted){b.push(this.ua[f].albums[g].name," (deleted)")}else{b.push('<a href="',
this.ua[f].albums[g].link,'">',this.ua[f].albums[g].name,"</a>")}b.push('</td><td class="lhcl_starProperty',h,'">',"<a");if(_features.newStrings){b.push(" onclick=\"return confirm('",Om,"');\"")}b.push(' href="',this.ua[f].albums[g].unstar,"&redir=",d,'">',"remove album","</a></td></tr>")}}b.push("</table>")}}b.push("</table>");this.jq.innerHTML=b.join("")};Ib.prototype.Di=function(a){this.Ru=a;var b=a==bi,c=this.Pm.style,d=this.jq.style,e=this.Vz.style;c.display="none";d.display="none";e.display=
"none";if(b){(this.Qa.length==0?e:c).display="";this.$o.innerHTML='<span class="lhcl_notbold">View:</span> <a href="'+this.xg+Yf+'">List</a> | Activity'}else{(this.ua.length==0?e:d).display="";this.$o.innerHTML='<span class="lhcl_notbold">View:</span> List | <a href="'+this.xg+bi+'">Activity</a>';if(_features.contacts){this.rq(a==Xf)}}};Ib.prototype.gA=function(a){this.ua[a].notify=!this.ua[a].notify;this.zj=!this.zj;this.Di(window.location.hash)};Ib.prototype.eA=function(a){this.ua[a].linked=!this.ua[a].linked};
Ib.prototype.Du=function(a,b){if(a.name<b.name){return-1}else if(a.name>b.name){return 1}return 0};var bi="#activity";Ib.ACTIVITY_URL_SUFFIX=bi;var Yf="#list";Ib.PEOPLE_URL_SUFFIX=Yf;var Xf="#all";Ib.ALLCONTACTS_URL_SUFFIX=Xf;function W(a,b,c){P.Pa(this);this.ga=a;this.sa={};this.Tf="Click to add a caption";this.kA=b;this.g=c;this.oi="";this.r={lhui_nextfunc:p("func"),lhui_promptfunc:p("func"),lhui_savefunc:p("func"),lhui_undofunc:p("func"),lhui_checkfunc:p("func")};q(this.r.lhui_nextfunc,o(this,this.us));q(this.r.lhui_promptfunc,o(this,this.rs));q(this.r.lhui_savefunc,o(this,this.xu));q(this.r.lhui_undofunc,o(this,this.ft));q(this.r.lhui_checkfunc,o(this,this.Ct));q("ReturnToAlbum",o(this,this.sm));this.os()}W.prototype.aa=
function(){P.Sa(this);if(this.Bb)window.clearTimeout(this.Bb);if(this.r){y(this.r.lhui_nextfunc);y(this.r.lhui_promptfunc);y(this.r.lhui_savefunc);y(this.r.lhui_undofunc);y(this.r.lhui_checkfunc);y("ReturnToAlbum")}for(var a in this)this[a]=null};W.prototype.os=function(){var a=Math.min(ec,_album.photoCount);if(_album.photoCount>ec){this.$l(0,ec)}for(var b=0;b<a;b++){var c=this.ga[b];this.sa[c.id]={};c.lhui_promptfunc=this.r.lhui_promptfunc;c.lhui_savefunc=this.r.lhui_savefunc;c.lhui_checkfunc=this.r.lhui_checkfunc;
c.index=b;c.tabindex=b+1;c.cid="lhid_caption_"+c.id;if(c.c){c.active="lhcl_active";c.caption=c.c}else{c.active="";this.sa[c.id].empty=true;c.caption=this.Tf}var d=D(Qh,c);this.g.appendChild(d);if(b<a-1){var e=m.createElement("div");e.className="lhcl_captionspacer";this.g.appendChild(e)}}};W.prototype.us=function(a,b){var c=Re(),d=["off="+a,"max="+b,"v="+c],e="http://"+document.domain+":"+document.location.port+"/data/feed/back_compat/user/"+_authuser.name+"/albumid/"+_album.id+"?kind=photo&alt=rss&"+
d.join("&"),f=Tb(this,this.Sr,a,b);Q.Aa(e,f)};W.prototype.Bf=function(a,b){var c=b,d=b.split(":");if(d.length>1){if(!j.userAgent.IE){c=d[1]}}var e=a.getElementsByTagName(c);for(var f=0;f<e.length;f++){if(e[f].nodeName!=b)continue;var g=e[f].firstChild;if(g!=null){var h=g.nodeValue;if(h!=null){return h}}}return null};W.prototype.Vr=function(a){var b={};b.id=this.Bf(a,"gphoto:id");b.s=this.Bf(a,"photo:thumbnail");b.l=this.Bf(a,"link");b.c=this.Bf(a,"description");b.a=this.Bf(a,"title");return b};W.prototype.Sr=
function(a,b,c){if(!c||c.status>=400){if(!c){alert(ig+"\nPlease check your connection and try again.")}else{alert(ig+"\n\n"+jg(c.status))}return}if(c.text.substring(0,5)!="<?xml"){alert(ig);return}var d;if(j.userAgent.IE){try{d=new ActiveXObject("Microsoft.XMLDOM");d.async=false;var e=d.loadXML(c.text);if(!e){alert(ig+"\n\n"+jg(c.status))}}catch(f){}}else{d=c.xml}var g=d.getElementsByTagName("item");if(_album.photoCount>ec){this.$l(a,g.length)}this.g.innerHTML="";window.scrollTo(0,0);for(var h=0;h<
g.length;h++){var i=this.Vr(g[h]);this.sa[i.id]={};i.lhui_checkfunc=this.r.lhui_checkfunc;i.lhui_promptfunc=this.r.lhui_promptfunc;i.lhui_savefunc=this.r.lhui_savefunc;i.z=_album.photoCount-a-h;i.index=a+h;i.tabindex=h+1;i.selected=false;i.cid="lhid_caption_"+i.id;if(i.c){i.active="lhcl_active";i.caption=i.c}else{i.active="";this.sa[i.id].empty=true;i.caption=this.Tf}var k=D(Qh,i);this.g.appendChild(k);if(h<b-1){var n=m.createElement("div");n.className="lhcl_captionspacer";this.g.appendChild(n)}}};
W.prototype.$l=function(a,b){var c={};c.lhui_nextfunc=this.r.lhui_nextfunc;var d="",e="";if(a>0){c.offset=a-ec;c.interval=ec;d=ja(wl,c)}if(_album.photoCount>a+ec){c.offset=a+ec;c.interval=Math.min(ec,_album.photoCount-(a+ec));c.tabindex=b+1;e=ja(ul,c)}var f={};f.msg=_features.newStrings?ps(a+1,a+b,_album.photoCount):a+1+" - "+(a+b)+" ( "+_album.photoCount+")";var g=ja(vl,f),h=[d,g,e].join("");l("lhid_batchnav_top").innerHTML=h;l("lhid_batchnav_bottom").innerHTML=h};W.prototype.sm=function(){if(this.oi){if(this.Bb){window.clearTimeout(this.Bb);
this.Bb=0}this.Bb=sg(this,this.sm,200)}else{window.location=_album.link}};W.prototype.rs=function(a){var b=this.ga[a].id;this.ga[a].input=l("lhid_caption_"+b);if(this.sa[b].empty){this.ga[a].input.className="lhcl_active";this.ga[a].input.value=""}};W.prototype.ns=function(a){var b=this.ga[a].id,c=this.ga[a].input,d=rq(c.value),e=this.ga[a].c;c.value=d;if(e==Rq(d)){if(Pd(d)){c.value=this.Tf;c.className="";this.sa[b].state="default";this.Sc(a)}return false}if(Pd(d)){this.sa[b].empty=true}else{this.sa[b].empty=
false}if(d.length>1024){this.sa[b].state="error";this.Sc(a);return false}return true};W.prototype.tm=function(a){var b=this.ga[a].id,c=this.ga[a].input,d=rc(c.value),e=l("aid").value,f=this.kA+"&aid="+e,g=Tb(this,this.it,a),h=["optgt=SAVE_PHOTO_CAPTIONS","noredir=true","caption_"+b+"="+Bc(d)];Q.Aa(f,g,h.join("&"));this.oi=true;if(this.sa[b].state=="reverting"){this.sa[b].state="reverting"}else{this.sa[b].state="saving"}this.Sc(a)};W.prototype.it=function(a,b){if(this.gc(b)||this.Nc(b)){var c=this.ga[a].id,
d=this.ga[a].input;d.className="";d.value=this.Tf;this.sa[c].state="";this.Sc(a);this.oi=false;return}var c=this.ga[a].id,d=this.ga[a].input,e=d.value;this.sa[c].undo=this.ga[a].c;this.ga[a].c=Rq(e);if(this.sa[c].empty){d.className="";d.value=this.Tf}else{d.className="lhcl_active"}if(this.sa[c].state=="reverting"){this.sa[c].state="reverted";this.Sc(a)}else{this.sa[c].state="saved";this.Sc(a)}this.oi=false};W.prototype.ft=function(a){var b=this.ga[a].id,c=this.ga[a].input,d=this.sa[b].undo;c.value=
Ob(d);if(Pd(d)){this.sa[b].empty=true}else{this.sa[b].empty=false}this.sa[b].state="reverting";this.tm(a)};W.prototype.Ct=function(a){var b=this.ga[a].id,c=this.ga[a].input,d=c.value,e=this.ga[a].c;if(d!=e&&this.sa[b].state!="prompt"&&!Pd(d)){this.sa[b].state="prompt";this.Sc(a)}this.$r(a)};W.prototype.$r=function(a){var b=this.ga[a].id,c=this.ga[a].input,d=l("status_"+b);if(!(c&&d))return;if(c.value.length>992){this.sa[b].state="warning";this.Sc(a)}else if(this.sa[b].state=="error"){this.sa[b].state=
"prompt";this.Sc(a)}};W.prototype.Sc=function(a){var b=this.ga[a].id,c=this.ga[a].input,d=this.sa[b].state,e=l("status_"+b),f,g={};g.lhui_undofunc=this.r.lhui_undofunc;g.index=a;e.style.color="#666";switch(d){case "prompt":f=zl;break;case "saving":f=Dl;break;case "saved":f=Cl;break;case "reverting":f=Bl;break;case "reverted":f=Al;break;case "warning":g.num=c.value.length;g.max=1024;if(g.num>g.max){e.style.color="#f00"}g.msg=_features.newStrings?Xr(g.num,g.max):"";f=El;break;case "error":f=yl;break;
default:f=xl;break}var h=D(f,g);tb(e,h)};W.prototype.xu=function(a){if(this.ns(a)){this.tm(a)}};var ec=50;W.BATCH_PAGING_INTERVAL=ec;var wl='<span><a id="lhid_previous" class="lhcl_navlink" href="javascript: _d(\'{lhui_nextfunc}\', {offset}, {interval})">&lt; Previous</a></span>';W.PREVIOUS_LINK_HTML=wl;var vl="<span>&nbsp; {msg} &nbsp;</span>";W.PHOTOCOUNT_HTML=vl;var ul='<span><a class="lhcl_navlink" href="javascript:_d(\'{lhui_nextfunc}\', {offset}, {interval})" tabindex="{tabindex}">Next&gt;</a></span>';
W.NEXT_LINK_HTML=ul;var xl="<span> </span>";W.STATE_DEFAULT_HTML=xl;var zl='<span class="lhcl_statusdefault">Changes to captions are automatically saved.</span>';W.STATE_PROMPT_HTML=zl;var Dl='<table><tr><td class="lhcl_status"><img src="img/progressanim.gif" class="lhcl_statusimg" /></td><td class="lhcl_status">Saving caption&#8230;</td></tr></table>';W.STATE_SAVING_HTML=Dl;var Bl='<table><tr><td class="lhcl_status"><img src="img/progressanim.gif" class="lhcl_statusimg" /></td><td class="lhcl_status">Reverting caption&#8230;</td></tr></table>';
W.STATE_REVERTING_HTML=Bl;var Al='<table><tr><td class="lhcl_status"><img src="img/check.gif" class="lhcl_statusimg" /></td><td class="lhcl_status">This caption has been reverted.</td></tr></table>';W.STATE_REVERTED_HTML=Al;var Cl='<table><tr><td class="lhcl_status"><img src="img/check.gif" class="lhcl_statusimg" /></td><td class="lhcl_status">This caption has been saved.</td><td class="lhcl_undo"><a href="javascript:_d(\'{lhui_undofunc}\', \'{index}\')">Undo</a></td></tr></table>';W.STATE_SAVED_HTML=
Cl;var El="<span>{msg}</span>";W.STATE_WARNING_HTML=El;var yl='<span class="lhcl_warning">'+Em+"</span>";W.STATE_ERROR_HTML=yl;var Qh='<div><table class="lhcl_onebatchcaption"><tr><td class="lhcl_photo"><img src="{s}" alt="{a}"/></td><td class="lhcl_textbox"><textarea id="lhid_caption_{id}" name="caption_{id}" onkeydown="_d(\'{lhui_checkfunc}\', \'{index}\')" onfocus="_d(\'{lhui_promptfunc}\', \'{index}\')" onblur="_d(\'{lhui_savefunc}\', \'{index}\')" onkeyup="_d(\'{lhui_checkfunc}\', \'{index}\')" class="{active}" tabindex="{tabindex}">{caption}</textarea><div id="status_{id}" class="lhcl_statusbox"></div></td></tr></table></div>';
W.CAPTION_THUMBNAIL_HTML=Qh;W.prototype.gc=function(a){var b=a.status;if(b>=400){var c;if(b==403)c="403 "+Km;else if(b==404)c="404 "+Mm;else if(b>=500)c="500 "+Pm;else c="unknown "+Qm;alert(ja(c,{status:b}));return true}return false};W.prototype.Nc=function(a){if(a.text.indexOf("success")<0){var b=a.text.replace(/\<[^>]*\>/g,"");alert(b);return true}return false};function S(a,b,c,d){P.Pa(this);this.ga=a;this.e=b;this.Vk=c;this.Pq=d;this.Fg=false;this.lastClicked=-1;this.shiftDown=false;this.Lk=0;this.Ge=_thumbSize;q("thumbClick",o(this,this.Dt));q("thumbHover",o(this,this.Et));this.qc=Ma(this,this.Tb);this.eq=Ma(this,this.Id);this.Rk=Ma(this,this.om);this.fq=o(this,this.Us);this.ci=new xb(this.Rk);wa(document,"keydown",this.qc);wa(document,"keyup",this.eq);wa(window,"resize",this.Rk);wa(window,"scroll",this.fq);q("getSnippet",o(this,this.st));q("getLink",
o(this,this.tt));this.am()}S.prototype.aa=function(){P.Sa(this);y("thumbClick");y("thumbHover");Aa(document,"keydown",this.qc);Aa(document,"keyup",this.eq);Aa(window,"resize",this.Rk);Aa(window,"scroll",this.fq);for(var a in this)this[a]=null};S.prototype.am=function(){if(!this.e)return;if(!this.sc){this.sc=0;this.e.innerHTML="";this.vr=this.ga.length}var a=this.sc;this.sc=Math.min(a+Bm,this.ga.length);for(var b=a;b<this.sc;b++){var c=this.ga[b];if(c.c)c.caption='<p id="lhid_c'+b+'">'+c.c+"</p>";
c.index=b;c.selected=false;var d=D(zm,c);d.style.zIndex=this.ga.length-b;this.e.appendChild(d);c.div=l("lhid_t"+b);c.box=l("lhid_b"+b);this.gm(c)}if(this.sc<this.ga.length){sg(this,this.am,0)}if(!this.ci.mp()){this.ci.ma(ki)}};S.prototype.gm=function(a){a.voff=-1;a.loaded=false;var b=Ts(a.w,a.h,this.Ge);a.iw=b.w;a.ih=b.h;lk(a.div,this.Ge+10,b.h+10);lk(a.box,b.w,b.h);if(a.box.hasChildNodes())lk(a.box.firstChild,b.w,b.h);var c=(this.Ge-b.w)/2;if(!j.userAgent.IE)a.box.style.left=c+"px";var d=l("lhid_c"+
a.index);if(d){var e=this.Ge+10;d.style.width=e+"px";Ao(d)}};S.prototype.as=function(a){if(a.loaded)return;var b=a.voff;if(b>this.gq)return;var c=b+this.Ge;if(c<this.Uk)return;var d=D(Am,a);a.loaded=true;a.box.innerHTML="";a.box.appendChild(d)};S.prototype.Yl=function(){if(!this.ii)return;this.ii=false;for(var a=0;a<this.sc;a++){if(this.ii)return;var b=this.ga[a];if(!b.loaded){if(b.voff>this.gq)return;this.as(b)}}};S.prototype.ct=function(a,b){this.Ge=b;this.vr=this.ga.length;for(var c=0;c<this.sc;c++){var d=
this.ga[c];this.gm(d);d.s=d.s.replace("imgmax="+a,"imgmax="+b)}this.ci.ma(ki)};S.prototype.Mm=function(){this.ii=true;if(j.userAgent.SAFARI){this.Uk=document.body.scrollTop}else{this.Uk=Pb().scrollTop}this.gq=2*Cd()+this.Uk};S.prototype.Jt=function(){this.ii=true;for(var a=0;a<this.sc;a++){var b=this.ga[a];if(!b.loaded){b.voff=uf(b.div)}}};S.prototype.Us=function(){this.Mm();this.Yl()};S.prototype.om=function(){this.ci.reset();if(this.vr==0)return;this.Mm();this.Jt();this.Yl()};S.prototype.tt=function(){var a=
l("lhid_embed"),b=l("lhid_zippy");if(a.className=="lhcl_embed_on"){a.className="lhcl_embed";l("lhid_embedform").style.display="none";b.src="img/triangle.gif"}else{a.className="lhcl_embed_on";l("lhid_embedform").style.display="";l("lhid_link").value=_album.link;var c=Nm(_album.count),d=_album.src.replace(/\/([^?\/]*)\?.*$/,"/s160-c/$1"),e={url:_album.link,src:d,title:_album.title_wb,wb:_album.dateonly+" - "+_album.count+" "+c},f=ja(ji,e);l("lhid_snippet").value=f;b.src="img/opentriangle.gif"}};S.prototype.st=
function(a,b,c){var d=a.style,e=l("lhid_zippy");if(d.display==""){d.display="none";b.style.display="none";e.src="img/triangle.gif"}else{d.display="";var f=Nm(c.count),g=c.src.replace(/\/([^?\/]*)\?.*$/,"/s160-c/$1"),h={url:c.link,src:g,title:c.title_wb,wb:c.dateonly+" - "+c.count+" "+f},i=ja(ji,h);b.style.display="";b.value=i;b.focus();b.select();e.src="img/opentriangle.gif"}};S.prototype.Zs=function(){this.Fg=!this.Fg;_album.organize=this.Fg;var a="";if(this.Fg){a="lhcl_organize_mode";this.lastClicked=
-1}else{this.vm()}this.Vk.className=a;this.om()};S.prototype.es=function(){var a=this.Si();if(!a)return;if(a.length>Qe){alert(pi(a.length,Qe));return}LH_copyDialog(a)};S.prototype.Es=function(){var a=this.Si();if(!a)return;if(a.length>Qe){alert(pi(a.length,Qe));return}LH_moveDialog(a)};S.prototype.hs=function(){var a=this.Si();if(!a||!confirm("Are you sure you want to delete the selected items?"))return;var b=l("lhid_albumactionsform"),c=l("lhid_selectedphotos"),d=l("lhid_albumop");if(!(b&&c&&d))return;
d.value="DELETE";b.action=_selectedPhotosPath;c.value=a.join(",");b.submit();this.$g(false)};S.prototype.is=function(){if(!confirm("Are you sure you want to delete this album?"))return;var a=l("lhid_albumactionsform"),b=l("lhid_albumop");if(!(a&&b))return;b.value="DELETE";a.action=_deleteAlbumPath;a.submit();this.$g(false)};S.prototype.kt=function(){this.Yi(0,this.sc-1,true)};S.prototype.vm=function(){this.Yi(0,this.sc-1,false)};S.prototype.wm=function(a,b){if(this.ga[a].selected==b)return;this.ga[a].selected=
b;var c=this.e.childNodes[a],d=c.getElementsByTagName("input")[0];d.checked=b;var e="lhcl_thumbnail";if(b)e+=" lhcl_selected";c.className=e;this.Lk+=b?1:-1;if(this.Lk==0){this.Ck=-1;this.$g(false)}else if(this.Lk==1){this.$g(true)}};S.prototype.Yi=function(a,b,c){var d=Math.min(a,b),e=Math.max(a,b);for(var f=d;f<=e;f++)this.wm(f,c)};S.prototype.Si=function(){var a=[];for(var b=0;b<this.sc;b++){var c=this.ga[b];if(c.selected)a.push(c.id)}return a};S.prototype.$g=function(a){for(var b=0;b<this.Pq.length;b++){var c=
this.Pq[b];if(!c)continue;c.disabled=!a}};S.prototype.Dt=function(a,b){if(this.Fg){var c=!this.ga[b].selected;if(this.fr&&this.Ck>=0){this.Yi(b,this.Ck,c)}else{this.wm(b,c)}this.Ck=b}else{window.location=this.ga[b].l}};S.prototype.Et=function(a,b,c){var d="lhcl_thumbnail";if(this.ga[b].selected)d+=" lhcl_selected";if(c)d+=" lhcl_hover";a.className=d};S.prototype.Tb=function(a){this.fr=a.shiftKey};S.prototype.Id=function(a){this.fr=a.shiftKey};function lk(a,b,c){a.style.width=b+"px";a.style.height=
c+"px"}function Ts(a,b,c){var d={};d.w=a;d.h=b;if(a>c||b>c){if(a<b){d.h=c;d.w=Math.round(a*c/b)}else{d.w=c;d.h=Math.round(b*c/a)}}return d}var Bm=50;S.MAX_SIMULTANEOUS_THUMBNAILS=Bm;var ki=500;S.LAYOUT_DELAY=ki;var Qe=100;S.MAX_PHOTOS_TO_COPY=Qe;var Am='<img src="{s}" style="width:{iw}px;height:{ih}px;">';S.IMAGE_HTML=Am;var zm='<div class="lhcl_thumbnail" onclick="_d(\'thumbClick\', this, {index});" ondblclick="return false;" onmouseover="_d(\'thumbHover\', this, {index}, true)" onmouseout="_d(\'thumbHover\', this, {index}, false)"><div class="lhcl_thumb_row" id="lhid_t{index}"><div id="lhid_b{index}" class="lhcl_greybox"></div></div><div class="lhcl_thumb_row"><div class="lhcl_thumb_captionbox"><input type="checkbox" class="lhcl_checkbox" name="iid_{id}" />{caption}</div></div></div>';
S.ALBUM_THUMBNAIL_HTML=zm;var ji='<table style="width:194px;"><tr><td align="center" style="height:194px;background:url(http://picasaweb.google.com/f/img/transparent_album_background.gif) no-repeat left"><a href="{url}"><img src="{src}" width="160" height="160" style="margin:1px 0 0 4px;"></a></td></tr><tr><td style="text-align:center;font-family:arial,sans-serif;font-size:11px"><a href="{url}" style="color:#4D4D4D;font-weight:bold;text-decoration:none;">{title}</a></td></tr></table>';S.ALBUM_SNIPPET_HTML=
ji;S.PAGING_INTERVAL=60;S.MOREPHOTOS_HTML='<div id="lhid_more" class="lhcl_thumbnail"><div class="lhcl_thumb_row"><div class="lhcl_morephotos"><div onclick="_d(\'more\', {o})">{batch}</div><span onclick="_d(\'allphotos\')">See all</span></div></div><div class="lhcl_thumb_captionbox" style="height:1em;"></div></div></div>';function uc(a,b,c,d){this.Uq=a;this.kp=b;this.Yp=[];this.yd=[];for(var e=0;e<Pe.length;e++){var f=e+1;this.Yp[e]=D(hi,{s:e,size:Pe[e],src:"img/zoom"+f+"off.gif"});this.yd[e]=D(hi,{s:e,size:Pe[e],src:"img/zoom"+f+"on.gif"})}var g=bc(ii),h=1;for(var e=0;e<fg.length;e++){if(g==fg[e]){h=e}}this.lm(h);I.add(this.kp,eg[h]);this.ub=h;q("SetThumb",o(this,this.nt));for(var e=0;e<c.length;e++){c[e].s=c[e].s.replace(/(imgmax=)\d+/,"imgmax="+gg[h])}this.du=d}uc.prototype.nt=function(a){if(this.ub==a){return}pc(ii,
fg[a]);this.lm(a);this.dt(this.ub,a);this.ub=a};uc.prototype.lm=function(a){this.Uq.innerHTML="";for(var b=0;b<Pe.length;b++){var c=a==b?this.yd[b]:this.Yp[b];this.Uq.appendChild(c)}};uc.prototype.dt=function(a,b){var c=gg[a],d=gg[b];this.du.ct(c,d);ep(this.kp,eg[a],eg[b])};var ii="_thumbnail";uc.THUMB_SETTING_COOKIE=ii;var hi='<img src="{src}" width=18" height="18" alt="{size}" title="{size}" onclick="_d(\'SetThumb\', {s});" />';uc.THUMB_SELECTOR_HTML=hi;var Pe=["Small thumbnails","Medium thumbnails",
"Large thumbnails"];uc.THUMB_LABELS=Pe;var eg=["lhcl_smallthumb","lhcl_mediumthumb","lhcl_largethumb"];uc.THUMB_CLASSES=eg;var fg=["SMALL","MEDIUM","LARGE"];uc.THUMB_PARAMS=fg;var gg=[72,144,288];uc.THUMB_SIZES=gg;var P=new Nf,Q=new mc(1),lb=null,Mf=Pq("7");function Bf(a){if(lb)lb.Zc();if(a)lb=null}(function(){var a=window;a._d=qb;function b(){var f=l("lhid_settingsform"),g=l("lhid_personaurl");if(!f||!g)return;var h=f["urlnick"];if(!h)return;if(h.length){for(var i=0;i<h.length;i++){if(h[i].checked){Mc(g,h[i].value);break}}}else{Mc(g,h.value)}}function c(){Lh(mb);a._fd=function(f){return Rs(f,2)};a._pd=function(f,g,h){rt(f,g,h,2)}}a._fd=function(f){c();return a._fd(f)};a._pd=function(f,g,h){c();a._pd(f,g,h)};
a._ps=function(f){Ca.prototype.aa=Ln;P.Pa(new Ca(f))};a._sr=function(){q("setland",zk);$d();Lr()};a._st=function(){q("updateGalleryUrl",b);b();var f=function(g){cb(l("lhid_publicalbumindexing_set"),true);cb(l("lhid_publicalbumindexing_unset"),false);l("lhid_publicalbumindexing").checked=g};q("index",dg.p(null,f))};a._sl=function(){var f=function(g,h){g=g||"/home";pc("_lhmessageid",h?"INDEX_SET_ON":"INDEX_SET_OFF",-1,"/");window.location=g};q("index",dg.p(null,f.p(null,document.referrer)))};a._w=ok;
a._e=Nr;a._v=Or;a._g=function(){for(var f=0;f<_user.albums.length;f++){Mi(l("title_"+_user.albums[f].id),2,_user.albums[f].title,225)}$d();q("index",dg.p(null,gi))};a._h=function(f,g){if(_user.albums.length>0){new Rb(_user.albums,l("lhid_albumsort"),l("lhid_albums"),f,g)}ok();$d();q("index",dg.p(null,gi))};a._a=function(f){var g=[l("lhid_copybutton"),l("lhid_movebutton"),l("lhid_deletebutton")],h=new S(f,l("lhid_test"),l("lhid_albummainbox"),g);if(f.length>0){new uc(l("lhid_thumbnailsizechooser"),
l("lhid_test"),f,h)}q("Organize",o(h,h.Zs));q("SelectAll",o(h,h.kt));q("DeselectAll",o(h,h.vm));q("CopyPhotos",o(h,h.es));q("MovePhotos",o(h,h.Es));q("DeletePhotos",o(h,h.hs));q("DeleteAlbum",o(h,h.is));Ii(false);ok();$d()};a._setUpdateCartAction=Ir;a._b=function(){new W(_thumbnail,_updateCaptionsPath,l("lhid_captions"))};a._s=function(){if(!Q.Hf())return _redirect();var f=new Xc(Ai);f.Pi(V,/^#(\d+)$/);f.Pi(ia,/^#s(\d+)$/);f.Dm();if(typeof _addStarPath!="undefined"){Q.Aa(_addStarPath+"&redir=/",null)}$d()};
a._pc=function(f){if(!Q.Hf())return _redirect();K.LANDING_PHOTO=f;var g=new Xc(Ai);g.Pi(K,/^(?:#(\d*))?$/);g.Dm();$d()};a._f=function(f,g,h){var f=new Ib(f,g,h)};a._vc=function(){a._selectProvider=Fr;a._sendToProvider=vt;a._removeCart=ut;new Oe};window._sp=function(f,g){if(Rj(cg)){$a.remove(cg);f.submit()}else{window.location=g}};q("closeSetPref",function(){l("lhid_searchSettingWidget").style.display="none";Q.Aa(_setPrefUrl,null,"pref=HIDE_SEARCHSETTINGS_WIDGET")});q("ProfilePicker",function(){if(lb==
null){lb=new H(_selectedPhotosPath,_user.name,_album.id,"PORTRAIT")}lb.tl("PORTRAIT",false);qb("hideVideo");lb.hd(function(){qb("restoreVideo")})});q("SettingsPicker",function(){if(lb==null){lb=new H(_selectedPhotosPath,_user.name,_album.id,"PORTRAIT")}lb.tl("PORTRAIT",true);lb.hd()});q("CoverPicker",function(){if(lb==null){lb=new H(_selectedPhotosPath,_user.name,_album.id,"BANNER")}lb.tl("BANNER",false);lb.hd()});a._reorganize=function(f){var g=l("lhid_edit_frame"),h=m.createElement("div");h.className=
"lhcl_lighttable";g.appendChild(h);var i=[l("lhid_copy"),l("lhid_move"),l("lhid_delete")],k=new U(h,l("lhid_done"),i);for(var n=0;n<f.length;n++){var s=f[n];k.Zt(s.l,s.id,s.s,s.t,s.d)}};a._userSettingsForm=function(f){l("save").disabled=true;l("cancel").disabled=true;if(lb){return lb.Py(f)}return true};a._flag=function(f,g,h){var i=l("lhid_flagger");if(i)new Pa(i,f,g,h)};a._setVisibility=xt;a._addFavorite=Dr;var d=["BR_IsIE",function(){return j.userAgent.IE},"BR_IsMac",function(){return F.contains(j.userAgent.PLATFORM,
"Mac")},"BR_IsWin",function(){return F.contains(j.userAgent.PLATFORM,"Win")},"DeleteArrayElement",x.remove,"InsertArray",vg,"SetCookie",pc,"UrlEncode",Bc,"addWrangler",wa,"get",l,"getCallback",o,"getWrangler",Ma,"killEvent",cc,"minmax",Qc,"offset",pa,"removeWrangler",Aa,"sortedInsert",xh,"sortedRemove",Tq,"squaredDistance",At,"templatize",ja,"LH_Dialog",R,"DIALOG_CREATE",0,"DIALOG_UPLOAD_FIRST",2,"DIALOG_UPLOAD",1,"DIALOG_EDIT",5,"DIALOG_COPY",3,"DIALOG_MOVE",4,"FlashRequest",qb.p(null,"f")];for(var e=
0;e<d.length;e+=2){a[d[e]]=d[e+1]}Q._s=Q.Hf;Q._r=Q.Aa;a._xmlhttp=Q;a._setBackLink=wt;eval("_xmlhttp.Supported = _xmlhttp._s");eval("_xmlhttp.Request = _xmlhttp._r")})();;var Hb={ERAS:["BC","AD"],ERANAMES:["Before Christ","Anno Domini"],NARROWMONTHS:["J","F","M","A","M","J","J","A","S","O","N","D"],MONTHS:["January","February","March","April","May","June","July","August","September","October","November","December"],SHORTMONTHS:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],WEEKDAYS:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],SHORTWEEKDAYS:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],NARROWWEEKDAYS:["S","M","T",
"W","T","F","S"],SHORTQUARTERS:["Q1","Q2","Q3","Q4"],QUARTERS:["1st quarter","2nd quarter","3rd quarter","4th quarter"],AMPMS:["AM","PM"],DATEFORMATS:["EEEE, MMMM d, yyyy","MMMM d, yyyy","MMM d, yyyy","M/d/yy"],TIMEFORMATS:["h:mm:ss a v","h:mm:ss a z","h:mm:ss a","h:mm a"],ZONESTRINGS:null},pr=Hb.MONTHS,qr=Hb.NARROWMONTHS,rr=Hb.NARROWWEEKDAYS,sr=Hb.SHORTMONTHS,tr=Hb.SHORTWEEKDAYS,ur=Hb.WEEKDAYS;Hb.STANDALONENARROWMONTHS=qr;Hb.STANDALONEMONTHS=pr;Hb.STANDALONESHORTMONTHS=sr;Hb.STANDALONEWEEKDAYS=ur;
Hb.STANDALONESHORTWEEKDAYS=tr;Hb.STANDALONENARROWWEEKDAYS=rr;tt(Hb,"en");


