forked from ftde0/yt2009
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathwww-core-vflhGADTg.js
More file actions
474 lines (472 loc) · 230 KB
/
Copy pathwww-core-vflhGADTg.js
File metadata and controls
474 lines (472 loc) · 230 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
var _____WB$wombat$assign$function_____=function(name){return (self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init(name))||self[name];};if(!self.__WB_pmw){self.__WB_pmw=function(obj){this.__WB_source=obj;return this;}}{
let window = _____WB$wombat$assign$function_____("window");
let self = _____WB$wombat$assign$function_____("self");
let document = _____WB$wombat$assign$function_____("document");
let location = _____WB$wombat$assign$function_____("location");
let top = _____WB$wombat$assign$function_____("top");
let parent = _____WB$wombat$assign$function_____("parent");
let frames = _____WB$wombat$assign$function_____("frames");
let opens = _____WB$wombat$assign$function_____("opens");
(function(){function h(a){throw a;}
var i=void 0,j=!0,k=null,l=!1,n,o=this,q=function(a){for(var a=a.split("."),b=o,c;c=a.shift();)if(b[c]!=k)b=b[c];else return k;return b},aa=function(){},ba=function(a){a.getInstance=function(){return a.ql||(a.ql=new a)}},ca=function(a){var b=typeof a;if("object"==b)if(a){if(a instanceof Array)return"array";if(a instanceof Object)return b;var c=Object.prototype.toString.call(a);if("[object Window]"==c)return"object";if("[object Array]"==c||"number"==typeof a.length&&"undefined"!=typeof a.splice&&"undefined"!=
typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("splice"))return"array";if("[object Function]"==c||"undefined"!=typeof a.call&&"undefined"!=typeof a.propertyIsEnumerable&&!a.propertyIsEnumerable("call"))return"function"}else return"null";else if("function"==b&&"undefined"==typeof a.call)return"object";return b},da=function(a){return a!==i},ea=function(a){return"array"==ca(a)},fa=function(a){var b=ca(a);return"array"==b||"object"==b&&"number"==typeof a.length},ga=function(a){return"string"==
typeof a},ha=function(a){a=ca(a);return"object"==a||"array"==a||"function"==a},ia="closure_uid_"+Math.floor(2147483648*Math.random()).toString(36),ja=0,ka=function(a,b,c){return a.call.apply(a.bind,arguments)},la=function(a,b,c){a||h(Error());if(2<arguments.length){var d=Array.prototype.slice.call(arguments,2);return function(){var c=Array.prototype.slice.call(arguments);Array.prototype.unshift.apply(c,d);return a.apply(b,c)}}return function(){return a.apply(b,arguments)}},r=function(a,b,c){r=Function.prototype.bind&&
-1!=Function.prototype.bind.toString().indexOf("native code")?ka:la;return r.apply(k,arguments)},ma=function(a,b){var c=Array.prototype.slice.call(arguments,1);return function(){var b=Array.prototype.slice.call(arguments);b.unshift.apply(b,c);return a.apply(this,b)}},na=Date.now||function(){return+new Date},s=function(a,b){var c=a.split("."),d=o;!(c[0]in d)&&d.execScript&&d.execScript("var "+c[0]);for(var e;c.length&&(e=c.shift());)!c.length&&da(b)?d[e]=b:d=d[e]?d[e]:d[e]={}},t=function(a,b){function c(){}
c.prototype=b.prototype;a.yf=b.prototype;a.prototype=new c};Function.prototype.bind=Function.prototype.bind||function(a,b){if(1<arguments.length){var c=Array.prototype.slice.call(arguments,1);c.unshift(this,a);return r.apply(k,c)}return r(this,a)};var pa=function(a){this.stack=Error().stack||"";if(a)this.message=""+a};t(pa,Error);pa.prototype.name="CustomError";var qa=function(a,b){for(var c=1;c<arguments.length;c++)var d=(""+arguments[c]).replace(/\$/g,"$$$$"),a=a.replace(/\%s/,d);return a},ra=function(a){return a.replace(/^[\s\xa0]+|[\s\xa0]+$/g,"")},ta=/^[a-zA-Z0-9\-_.!~*'()]*$/,ua=function(a){a=""+a;return!ta.test(a)?encodeURIComponent(a):a},Aa=function(a){if(!va.test(a))return a;-1!=a.indexOf("&")&&(a=a.replace(wa,"&"));-1!=a.indexOf("<")&&(a=a.replace(xa,"<"));-1!=a.indexOf(">")&&(a=a.replace(ya,">"));-1!=a.indexOf('"')&&(a=a.replace(za,
"""));return a},wa=/&/g,xa=/</g,ya=/>/g,za=/\"/g,va=/[&<>\"]/,Da=function(a){return-1!=a.indexOf("&")?"document"in o?Ba(a):Ca(a):a},Ba=function(a){var b={"&":"&","<":"<",">":">",""":'"'},c=document.createElement("div");return a.replace(Ea,function(a,e){var f=b[a];if(f)return f;if("#"==e.charAt(0)){var g=Number("0"+e.substr(1));isNaN(g)||(f=String.fromCharCode(g))}if(!f)c.innerHTML=a+" ",f=c.firstChild.nodeValue.slice(0,-1);return b[a]=f})},Ca=function(a){return a.replace(/&([^;]+);/g,
function(a,c){switch(c){case "amp":return"&";case "lt":return"<";case "gt":return">";case "quot":return'"';default:if("#"==c.charAt(0)){var d=Number("0"+c.substr(1));if(!isNaN(d))return String.fromCharCode(d)}return a}})},Ea=/&([^;\s<&]+);?/g,Fa=function(a,b){a.length>b&&(a=a.substring(0,b-3)+"...");return a},Ga={"\x00":"\\0","\u0008":"\\b","\u000c":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\u000b":"\\x0B",'"':'\\"',"\\":"\\\\"},Ha={"'":"\\'"},Ia=function(a){var p;for(var b=[],c=0;c<a.length;c++){var d=
b,e=c,f;f=a.charAt(c);if(f in Ha)f=Ha[f];else if(f in Ga)p=Ha[f]=Ga[f],f=p;else{var g=f,m=f.charCodeAt(0);if(31<m&&127>m)g=f;else{if(256>m){if(g="\\x",16>m||256<m)g+="0"}else g="\\u",4096>m&&(g+="0");g+=m.toString(16).toUpperCase()}f=Ha[f]=g}d[e]=f}return b.join("")},Ja=function(a,b){for(var c=0,d=ra(""+a).split("."),e=ra(""+b).split("."),f=Math.max(d.length,e.length),g=0;0==c&&g<f;g++){var m=d[g]||"",p=e[g]||"",x=RegExp("(\\d*)(\\D*)","g"),D=RegExp("(\\d*)(\\D*)","g");do{var H=x.exec(m)||["","",
""],M=D.exec(p)||["","",""];if(0==H[0].length&&0==M[0].length)break;c=((0==H[1].length?0:parseInt(H[1],10))<(0==M[1].length?0:parseInt(M[1],10))?-1:(0==H[1].length?0:parseInt(H[1],10))>(0==M[1].length?0:parseInt(M[1],10))?1:0)||((0==H[2].length)<(0==M[2].length)?-1:(0==H[2].length)>(0==M[2].length)?1:0)||(H[2]<M[2]?-1:H[2]>M[2]?1:0)}while(0==c)}return c},Ka=function(a){for(var b=0,c=0;c<a.length;++c)b=31*b+a.charCodeAt(c),b%=4294967296;return b},La={},Ma=function(a){return La[a]||(La[a]=(""+a).replace(/\-([a-z])/g,
function(a,c){return c.toUpperCase()}))},Na={};var Oa=function(a,b){b.unshift(a);pa.call(this,qa.apply(k,b));b.shift();this.Rl=a};t(Oa,pa);Oa.prototype.name="AssertionError";
var Pa=function(a,b,c,d){var e="Assertion failed";if(c)var e=e+(": "+c),f=d;else a&&(e+=": "+a,f=b);h(new Oa(""+e,f||[]))},Qa=function(a,b,c){!a&&Pa("",k,b,Array.prototype.slice.call(arguments,2))},Ra=function(a,b){h(new Oa("Failure"+(a?": "+a:""),Array.prototype.slice.call(arguments,1)))},Sa=function(a,b,c){!ga(a)&&Pa("Expected string but got %s: %s.",[ca(a),a],b,Array.prototype.slice.call(arguments,2));return a};var Ta=Array.prototype,Ua=Ta.indexOf?function(a,b,c){Qa(a.length!=k);return Ta.indexOf.call(a,b,c)}:function(a,b,c){c=c==k?0:0>c?Math.max(0,a.length+c):c;if(ga(a))return!ga(b)||1!=b.length?-1:a.indexOf(b,c);for(;c<a.length;c++)if(c in a&&a[c]===b)return c;return-1},u=Ta.forEach?function(a,b,c){Qa(a.length!=k);Ta.forEach.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=ga(a)?a.split(""):a,f=0;f<d;f++)f in e&&b.call(c,e[f],f,a)},Va=Ta.filter?function(a,b,c){Qa(a.length!=k);return Ta.filter.call(a,
b,c)}:function(a,b,c){for(var d=a.length,e=[],f=0,g=ga(a)?a.split(""):a,m=0;m<d;m++)if(m in g){var p=g[m];b.call(c,p,m,a)&&(e[f++]=p)}return e},Wa=Ta.map?function(a,b,c){Qa(a.length!=k);return Ta.map.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=Array(d),f=ga(a)?a.split(""):a,g=0;g<d;g++)g in f&&(e[g]=b.call(c,f[g],g,a));return e},Xa=Ta.some?function(a,b,c){Qa(a.length!=k);return Ta.some.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=ga(a)?a.split(""):a,f=0;f<d;f++)if(f in e&&b.call(c,e[f],
f,a))return j;return l},Za=function(a,b){var c=Ya(a,b,i);return 0>c?k:ga(a)?a.charAt(c):a[c]},Ya=function(a,b,c){for(var d=a.length,e=ga(a)?a.split(""):a,f=0;f<d;f++)if(f in e&&b.call(c,e[f],f,a))return f;return-1},$a=function(a,b){for(var c=ga(a)?a.split(""):a,d=a.length-1;0<=d;d--)if(d in c&&b.call(i,c[d],d,a))return d;return-1},ab=function(a,b){return 0<=Ua(a,b)},bb=function(a){if(!ea(a))for(var b=a.length-1;0<=b;b--)delete a[b];a.length=0},cb=function(a,b){Qa(a.length!=k);Ta.splice.call(a,b,1)},
db=function(a){return Ta.concat.apply(Ta,arguments)},eb=function(a){if(ea(a))return db(a);for(var b=[],c=0,d=a.length;c<d;c++)b[c]=a[c];return b},gb=function(a){return ea(a)?db(a):eb(a)},hb=function(a,b){for(var c=1;c<arguments.length;c++){var d=arguments[c],e;if(ea(d)||(e=fa(d))&&d.hasOwnProperty("callee"))a.push.apply(a,d);else if(e)for(var f=a.length,g=d.length,m=0;m<g;m++)a[f+m]=d[m];else a.push(d)}},jb=function(a,b,c,d){Qa(a.length!=k);Ta.splice.apply(a,ib(arguments,1))},ib=function(a,b,c){Qa(a.length!=
k);return 2>=arguments.length?Ta.slice.call(a,b):Ta.slice.call(a,b,c)},lb=function(a,b){Qa(a.length!=k);Ta.sort.call(a,b||kb)},mb=function(a){var b=kb;lb(a,function(a,d){return b(a.key,d.key)})},kb=function(a,b){return a>b?1:a<b?-1:0};var nb,ob=function(a){return(a=a.className)&&"function"==typeof a.split?a.split(/\s+/):[]},v=function(a,b){var c=ob(a),d=ib(arguments,1),d=pb(c,d);a.className=c.join(" ");return d},w=function(a,b){var c=ob(a),d=ib(arguments,1),d=qb(c,d);a.className=c.join(" ");return d},pb=function(a,b){for(var c=0,d=0;d<b.length;d++)ab(a,b[d])||(a.push(b[d]),c++);return c==b.length},qb=function(a,b){for(var c=0,d=0;d<a.length;d++)ab(b,a[d])&&(jb(a,d--,1),c++);return c==b.length},y=function(a,b,c){var d=ob(a);ga(b)?
(b=Ua(d,b),0<=b&&cb(d,b)):ea(b)&&qb(d,b);ga(c)&&!ab(d,c)?d.push(c):ea(c)&&pb(d,c);a.className=d.join(" ")},z=function(a,b){return ab(ob(a),b)},A=function(a,b,c){c?v(a,b):w(a,b)},rb=function(a,b){var c=!z(a,b);A(a,b,c);return c};var sb=function(a,b){this.x=da(a)?a:0;this.y=da(b)?b:0};sb.prototype.Na=function(){return new sb(this.x,this.y)};sb.prototype.toString=function(){return"("+this.x+", "+this.y+")"};var tb=function(a,b){return new sb(a.x-b.x,a.y-b.y)};var ub=function(a,b){this.width=a;this.height=b};n=ub.prototype;n.Na=function(){return new ub(this.width,this.height)};n.toString=function(){return"("+this.width+" x "+this.height+")"};n.ceil=function(){this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};n.floor=function(){this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};n.round=function(){this.width=Math.round(this.width);this.height=Math.round(this.height);return this};
n.scale=function(a){this.width*=a;this.height*=a;return this};var vb=function(a,b){for(var c in a)b.call(i,a[c],c,a)},wb=function(a){for(var b in a)return a[b]},xb=function(a){var b=[],c=0,d;for(d in a)b[c++]=d;return b},yb=function(a,b,c){for(var d in a)if(b.call(c,a[d],d,a))return d},zb=function(a,b){var c=yb(a,b,i);return c&&a[c]},Ab=function(a){var b={},c;for(c in a)b[c]=a[c];return b},Bb="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(","),Cb=function(a,b){for(var c,d,e=1;e<arguments.length;e++){d=arguments[e];
for(c in d)a[c]=d[c];for(var f=0;f<Bb.length;f++)c=Bb[f],Object.prototype.hasOwnProperty.call(d,c)&&(a[c]=d[c])}};var Db,Eb,Fb,Gb,Hb,Ib,Jb,Kb=function(){return o.navigator?o.navigator.userAgent:k},Lb=function(){return o.navigator};Hb=Gb=Fb=Eb=Db=l;var Mb;if(Mb=Kb()){var Nb=Lb();Db=0==Mb.indexOf("Opera");Eb=!Db&&-1!=Mb.indexOf("MSIE");Gb=(Fb=!Db&&-1!=Mb.indexOf("WebKit"))&&-1!=Mb.indexOf("Mobile");Hb=!Db&&!Fb&&"Gecko"==Nb.product}var Ob=Db,B=Eb,Pb=Hb,Qb=Fb,Rb=Gb,Sb=Lb(),Tb=Sb&&Sb.platform||"";Ib=-1!=Tb.indexOf("Mac");Jb=-1!=Tb.indexOf("Win");var Ub=!!Lb()&&-1!=(Lb().appVersion||"").indexOf("X11"),Vb;
a:{var Wb="",Xb;if(Ob&&o.opera)var Yb=o.opera.version,Wb="function"==typeof Yb?Yb():Yb;else if(Pb?Xb=/rv\:([^\);]+)(\)|;)/:B?Xb=/MSIE\s+([^\);]+)(\)|;)/:Qb&&(Xb=/WebKit\/(\S+)/),Xb)var Zb=Xb.exec(Kb()),Wb=Zb?Zb[1]:"";if(B){var $b,ac=o.document;$b=ac?ac.documentMode:i;if($b>parseFloat(Wb)){Vb=""+$b;break a}}Vb=Wb}var bc=Vb,cc={},dc=function(a){return cc[a]||(cc[a]=0<=Ja(bc,a))},ec={},fc=function(a){return ec[a]||(ec[a]=B&&document.documentMode&&document.documentMode>=a)};var gc=!B||fc(9);!Pb&&!B||B&&fc(9)||Pb&&dc("1.9.1");var hc=B&&!dc("9");var kc=function(a){return a?new ic(jc(a)):nb||(nb=new ic)},C=function(a){return ga(a)?document.getElementById(a):a},F=function(a,b){var c=b||document;return lc(c)?c.querySelectorAll("."+a):c.getElementsByClassName?c.getElementsByClassName(a):E("*",a,b)},G=function(a,b){var c=b||document,d=k;return(d=lc(c)?c.querySelector("."+a):F(a,b)[0])||k},lc=function(a){return a.querySelectorAll&&a.querySelector&&(!Qb||mc(document)||dc("528"))},E=function(a,b,c){c=c||document;a=a&&"*"!=a?a.toUpperCase():"";if(lc(c)&&
(a||b))return c.querySelectorAll(a+(b?"."+b:""));if(b&&c.getElementsByClassName){c=c.getElementsByClassName(b);if(a){for(var d={},e=0,f=0,g;g=c[f];f++)a==g.nodeName&&(d[e++]=g);d.length=e;return d}return c}c=c.getElementsByTagName(a||"*");if(b){d={};for(f=e=0;g=c[f];f++)a=g.className,"function"==typeof a.split&&ab(a.split(/\s+/),b)&&(d[e++]=g);d.length=e;return d}return c},oc=function(a,b){vb(b,function(b,d){"style"==d?a.style.cssText=b:"class"==d?a.className=b:"for"==d?a.htmlFor=b:d in nc?a.setAttribute(nc[d],
b):0==d.lastIndexOf("aria-",0)?a.setAttribute(d,b):a[d]=b})},nc={cellpadding:"cellPadding",cellspacing:"cellSpacing",colspan:"colSpan",rowspan:"rowSpan",valign:"vAlign",height:"height",width:"width",usemap:"useMap",frameborder:"frameBorder",maxlength:"maxLength",type:"type"},pc=function(a){var b=a.document;if(Qb&&!dc("500")&&!Rb){"undefined"==typeof a.innerHeight&&(a=window);var b=a.innerHeight,c=a.document.documentElement.scrollHeight;a==a.top&&c<b&&(b-=15);return new ub(a.innerWidth,b)}a=mc(b)?
b.documentElement:b.body;return new ub(a.clientWidth,a.clientHeight)},qc=function(){var a=window,b=a.document,c=0;if(b){var a=pc(a).height,c=b.body,d=b.documentElement;if(mc(b)&&d.scrollHeight)c=d.scrollHeight!=a?d.scrollHeight:d.offsetHeight;else{var b=d.scrollHeight,e=d.offsetHeight;if(d.clientHeight!=e)b=c.scrollHeight,e=c.offsetHeight;c=b>a?b>e?b:e:b<e?b:e}}return c},rc=function(a){var b=!Qb&&mc(a)?a.documentElement:a.body,a=a.parentWindow||a.defaultView;return new sb(a.pageXOffset||b.scrollLeft,
a.pageYOffset||b.scrollTop)},tc=function(a,b,c){return sc(document,arguments)},sc=function(a,b){var c=b[0],d=b[1];if(!gc&&d&&(d.name||d.type)){c=["<",c];d.name&&c.push(' name="',Aa(d.name),'"');if(d.type){c.push(' type="',Aa(d.type),'"');var e={};Cb(e,d);d=e;delete d.type}c.push(">");c=c.join("")}c=a.createElement(c);if(d)ga(d)?c.className=d:ea(d)?v.apply(k,[c].concat(d)):oc(c,d);2<b.length&&uc(a,c,b,2);return c},uc=function(a,b,c,d){function e(c){c&&b.appendChild(ga(c)?a.createTextNode(c):c)}for(;d<
c.length;d++){var f=c[d];fa(f)&&!(ha(f)&&0<f.nodeType)?u(vc(f)?eb(f):f,e):e(f)}},wc=function(a){return document.createTextNode(a)},xc=function(a){var b=document,c=b.createElement("div");B?(c.innerHTML="<br>"+a,c.removeChild(c.firstChild)):c.innerHTML=a;if(1==c.childNodes.length)return c.removeChild(c.firstChild);for(a=b.createDocumentFragment();c.firstChild;)a.appendChild(c.firstChild);return a},mc=function(a){return"CSS1Compat"==a.compatMode},yc=function(a,b){uc(jc(a),a,arguments,1)},zc=function(a){for(var b;b=
a.firstChild;)a.removeChild(b)},Ac=function(a){a&&a.parentNode&&a.parentNode.removeChild(a)},Bc=function(a,b){var c=b.parentNode;c&&c.replaceChild(a,b)},Dc=function(a){return a.firstElementChild!=i?a.firstElementChild:Cc(a.firstChild)},Cc=function(a){for(;a&&1!=a.nodeType;)a=a.nextSibling;return a},Ec=function(a,b){if(a.contains&&1==b.nodeType)return a==b||a.contains(b);if("undefined"!=typeof a.compareDocumentPosition)return a==b||Boolean(a.compareDocumentPosition(b)&16);for(;b&&a!=b;)b=b.parentNode;
return b==a},jc=function(a){return 9==a.nodeType?a:a.ownerDocument||a.document},Fc=function(a,b){if("textContent"in a)a.textContent=b;else if(a.firstChild&&3==a.firstChild.nodeType){for(;a.lastChild!=a.firstChild;)a.removeChild(a.lastChild);a.firstChild.data=b}else zc(a),a.appendChild(jc(a).createTextNode(b))},Hc=function(a,b){var c=[];return Gc(a,b,c,j)?c[0]:i},Gc=function(a,b,c,d){if(a!=k)for(a=a.firstChild;a;){if(b(a)&&(c.push(a),d))return j;if(Gc(a,b,c,d))return j;a=a.nextSibling}return l},Ic=
{SCRIPT:1,STYLE:1,HEAD:1,IFRAME:1,OBJECT:1},Jc={IMG:" ",BR:"\n"},Lc=function(a){if(hc&&"innerText"in a)a=a.innerText.replace(/(\r\n|\r|\n)/g,"\n");else{var b=[];Kc(a,b,j);a=b.join("")}a=a.replace(/ \xAD /g," ").replace(/\xAD/g,"");a=a.replace(/\u200B/g,"");hc||(a=a.replace(/ +/g," "));" "!=a&&(a=a.replace(/^\s*/,""));return a},Kc=function(a,b,c){if(!(a.nodeName in Ic))if(3==a.nodeType)c?b.push((""+a.nodeValue).replace(/(\r\n|\r|\n)/g,"")):b.push(a.nodeValue);else if(a.nodeName in Jc)b.push(Jc[a.nodeName]);
else for(a=a.firstChild;a;)Kc(a,b,c),a=a.nextSibling},vc=function(a){if(a&&"number"==typeof a.length){if(ha(a))return"function"==typeof a.item||"string"==typeof a.item;if("function"==ca(a))return"function"==typeof a.item}return l},I=function(a,b,c){var d=b?b.toUpperCase():k;return Nc(a,function(a){return(!d||a.nodeName==d)&&(!c||z(a,c))},j)},Nc=function(a,b,c,d){if(!c)a=a.parentNode;for(var c=d==k,e=0;a&&(c||e<=d);){if(b(a))return a;a=a.parentNode;e++}return k},ic=function(a){this.r=a||o.document||
document};ic.prototype.al=function(a,b,c){return sc(this.r,arguments)};ic.prototype.createElement=function(a){return this.r.createElement(a)};ic.prototype.createTextNode=function(a){return this.r.createTextNode(a)};var Oc=function(a){return mc(a.r)},Pc=function(a){return rc(a.r)};ic.prototype.appendChild=function(a,b){a.appendChild(b)};ic.prototype.append=yc;ic.prototype.contains=Ec;var Qc="StopIteration"in o?o.StopIteration:Error("StopIteration"),Rc=function(){};Rc.prototype.next=function(){h(Qc)};Rc.prototype.ib=function(){return this};
var Sc=function(a){if(a instanceof Rc)return a;if("function"==typeof a.ib)return a.ib(l);if(fa(a)){var b=0,c=new Rc;c.next=function(){for(;;){b>=a.length&&h(Qc);if(b in a)return a[b++];b++}};return c}h(Error("Not implemented"))},Tc=function(a,b){if(fa(a))try{u(a,b,i)}catch(c){c!==Qc&&h(c)}else{a=Sc(a);try{for(;;)b.call(i,a.next(),i,a)}catch(d){d!==Qc&&h(d)}}},Uc=function(a){if(fa(a))return gb(a);var a=Sc(a),b=[];Tc(a,function(a){b.push(a)});return b};var Vc=function(a,b){this.S={};this.C=[];var c=arguments.length;if(1<c){c%2&&h(Error("Uneven number of arguments"));for(var d=0;d<c;d+=2)this.set(arguments[d],arguments[d+1])}else if(a){if(a instanceof Vc)c=a.zf(),d=a.Af();else{var c=xb(a),e=[],f=0;for(d in a)e[f++]=a[d];d=e}for(e=0;e<c.length;e++)this.set(c[e],d[e])}};n=Vc.prototype;n.Ja=0;n.Lb=0;n.P=function(){return this.Ja};n.Af=function(){Wc(this);for(var a=[],b=0;b<this.C.length;b++)a.push(this.S[this.C[b]]);return a};
n.zf=function(){Wc(this);return this.C.concat()};n.Xf=function(a){return Xc(this.S,a)};n.clear=function(){this.S={};this.Lb=this.Ja=this.C.length=0};n.remove=function(a){return Xc(this.S,a)?(delete this.S[a],this.Ja--,this.Lb++,this.C.length>2*this.Ja&&Wc(this),j):l};var Wc=function(a){if(a.Ja!=a.C.length){for(var b=0,c=0;b<a.C.length;){var d=a.C[b];Xc(a.S,d)&&(a.C[c++]=d);b++}a.C.length=c}if(a.Ja!=a.C.length){for(var e={},c=b=0;b<a.C.length;)d=a.C[b],Xc(e,d)||(a.C[c++]=d,e[d]=1),b++;a.C.length=c}};
Vc.prototype.get=function(a,b){return Xc(this.S,a)?this.S[a]:b};Vc.prototype.set=function(a,b){Xc(this.S,a)||(this.Ja++,this.C.push(a),this.Lb++);this.S[a]=b};Vc.prototype.Na=function(){return new Vc(this)};Vc.prototype.ib=function(a){Wc(this);var b=0,c=this.C,d=this.S,e=this.Lb,f=this,g=new Rc;g.next=function(){for(;;){e!=f.Lb&&h(Error("The map has changed since the iterator was created"));b>=c.length&&h(Qc);var g=c[b++];return a?g:d[g]}};return g};
var Xc=function(a,b){return Object.prototype.hasOwnProperty.call(a,b)};var $c=function(a){var b=[];Yc(a,b,Zc);return b.join("&")},Yc=function(a,b,c){for(var d=a.elements,e,f=0;e=d[f];f++)if(!(e.disabled||"fieldset"==e.tagName.toLowerCase())){var g=e.name;switch(e.type.toLowerCase()){case "file":case "submit":case "reset":case "button":break;case "select-multiple":e=ad(e);if(e!=k)for(var m,p=0;m=e[p];p++)c(b,g,m);break;default:m=ad(e),m!=k&&c(b,g,m)}}d=a.getElementsByTagName("input");for(f=0;e=d[f];f++)if(e.form==a&&"image"==e.type.toLowerCase())g=e.name,c(b,g,e.value),
c(b,g+".x","0"),c(b,g+".y","0")},bd=function(a,b,c){var d=a.get(b);d||(d=[],a.set(b,d));d.push(c)},Zc=function(a,b,c){a.push(encodeURIComponent(b)+"="+encodeURIComponent(c))},ad=function(a){var b=a.type;if(!da(b))return k;switch(b.toLowerCase()){case "checkbox":case "radio":return a.checked?a.value:k;case "select-one":return b=a.selectedIndex,0<=b?a.options[b].value:k;case "select-multiple":for(var b=[],c,d=0;c=a.options[d];d++)c.selected&&b.push(c.value);return b.length?b:k;default:return da(a.value)?
a.value:k}},cd=function(a){a=a.elements.is_private;if(a.type)return ad(a);for(var b=0;b<a.length;b++){var c=ad(a[b]);if(c)return c}return k};var dd=/<[^>]*>|&[^;]+;/g,ed=RegExp("^[^\u0591-\u07ff\ufb1d-\ufdff\ufe70-\ufefc]*[A-Za-z\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u02b8\u0300-\u0590\u0800-\u1fff\u2c00-\ufb1c\ufe00-\ufe6f\ufefd-\uffff]"),fd=RegExp("^[^A-Za-z\u00c0-\u00d6\u00d8-\u00f6\u00f8-\u02b8\u0300-\u0590\u0800-\u1fff\u2c00-\ufb1c\ufe00-\ufe6f\ufefd-\uffff]*[\u0591-\u07ff\ufb1d-\ufdff\ufe70-\ufefc]"),gd=function(a,b){return fd.test(b?a.replace(dd," "):a)};var hd=function(a){this.r=a},id=/\s*;\s*/;n=hd.prototype;n.set=function(a,b,c,d,e,f){/[;=\s]/.test(a)&&h(Error('Invalid cookie name "'+a+'"'));/[;\r\n]/.test(b)&&h(Error('Invalid cookie value "'+b+'"'));da(c)||(c=-1);e=e?";domain="+e:"";d=d?";path="+d:"";f=f?";secure":"";c=0>c?"":0==c?";expires="+(new Date(1970,1,1)).toUTCString():";expires="+(new Date(na()+1E3*c)).toUTCString();this.r.cookie=a+"="+b+e+d+c+f};
n.get=function(a,b){for(var c=a+"=",d=(this.r.cookie||"").split(id),e=0,f;f=d[e];e++)if(0==f.indexOf(c))return f.substr(c.length);return b};n.remove=function(a,b,c){var d=this.Xf(a);this.set(a,"",0,b,c);return d};n.zf=function(){return jd(this).keys};n.Af=function(){return jd(this).vi};n.P=function(){return!this.r.cookie?0:(this.r.cookie||"").split(id).length};n.Xf=function(a){return da(this.get(a))};n.clear=function(){for(var a=jd(this).keys,b=a.length-1;0<=b;b--)this.remove(a[b])};
var jd=function(a){for(var a=(a.r.cookie||"").split(id),b=[],c=[],d,e,f=0;e=a[f];f++)d=e.indexOf("="),-1==d?(b.push(""),c.push(e)):(b.push(e.substring(0,d)),c.push(e.substring(d+1)));return{keys:b,vi:c}},kd=new hd(document);kd.Pl=3950;var ld=function(a,b,c,d,e){kd.set(""+a,b,c,d||"/",e||"youtube.com")},md=function(a,b){return kd.get(""+a,b)},nd=function(a,b,c){return kd.remove(""+a,b||"/",c||"youtube.com")};var K=function(){var a=md(this.Yf);if(a)for(var a=unescape(a).split("&"),b=0;b<a.length;b++){var c=a[b].split("="),d=c[0];(c=c[1])&&(od[d]=c.toString())}};ba(K);var od=q("yt.prefs.UserPrefs.prefs_")||{};s("yt.prefs.UserPrefs.prefs_",od);K.prototype.Yf="PREF";
var pd=function(a){/^f([1-9][0-9]*)$/.test(a)&&h("ExpectedRegexMatch: "+a)},qd=function(a){/^\w+$/.test(a)||h("ExpectedRegexMismatch: "+a)},rd=function(a){a=od[a]!==i?od[a].toString():k;return a!=k&&/^[A-Fa-f0-9]+$/.test(a)?parseInt(a,16):k},sd=function(a,b,c){var d=rd(a),d=d!=k?d:0,b=c?d|b:d&~b;0==b?delete od[a]:(b=b.toString(16),od[a]=b.toString())},td=function(a,b){var c=rd(a);return 0<((c!=k?c:0)&b)};n=K.prototype;
n.get=function(a,b){qd(a);pd(a);var c=od[a]!==i?od[a].toString():k;return c!=k?c:b?b:""};n.set=function(a,b){qd(a);pd(a);b==k&&h("ExpectedNotNull");od[a]=b.toString()};n.Xc=function(a){return td("f1",a)};n.Zd=function(a,b){sd("f1",a,b)};n.Wb=function(a){return td("f2",a)};n.Ha=function(a,b){sd("f2",a,b)};n.Yc=function(a){return td("f3",a)};n.qc=function(a,b){sd("f3",a,b)};n.kl=function(a){return td("f4",a)};n.xf=function(a,b){sd("f4",a,b)};n.remove=function(a){qd(a);pd(a);delete od[a]};
n.save=function(a){var a=86400*(a||7),b=this.Yf,c=[],d;for(d in od)c.push(d+"="+escape(od[d]));ld(b,c.join("&"),a)};n.clear=function(){od={}};var L={Fk:1};L.FLAG_SAFE_SEARCH=L.Fk;L.sk=2;L.FLAG_GRID_VIEW_SEARCH_RESULTS=L.sk;L.Vc=4;L.FLAG_EMBED_NO_RELATED_VIDEOS=L.Vc;L.zk=8;L.FLAG_HTML5_THREED=L.zk;L.tk=16;L.FLAG_GRID_VIEW_VIDEOS_AND_CHANNELS=L.tk;L.Rk=32;L.FLAG_WATCH_EXPAND_ABOUT_PANEL=L.Rk;L.Tk=64;L.FLAG_WATCH_EXPAND_MOREFROM_PANEL=L.Tk;L.Qk=128;L.FLAG_WATCH_COLLAPSE_RELATED_PANEL=L.Qk;L.Ok=256;L.FLAG_WATCH_COLLAPSE_PLAYLIST_PANEL=L.Ok;L.Pk=512;L.FLAG_WATCH_COLLAPSE_QUICKLIST_PANEL=L.Pk;L.Sk=1024;
L.FLAG_WATCH_EXPAND_ALSOWATCHING_PANEL=L.Sk;L.Nk=2048;L.FLAG_WATCH_COLLAPSE_COMMENTS_PANEL=L.Nk;L.Kk=4096;L.FLAG_STATMODULES_INBOX_COLLAPSED=L.Kk;L.Jk=8192;L.FLAG_STATMODULES_ABOUTYOU_COLLAPSED=L.Jk;L.Ik=16384;L.FLAG_STATMODULES_ABOUTVIDEOS_COLLAPSED=L.Ik;L.fe=32768;L.FLAG_HIDE_WATCH_AUTOSHARE_PROMOTION=L.fe;L.Ak=65536;L.FLAG_PERSONALIZED_HOMEPAGE_FEED_FEATURED_COLLAPSED=L.Ak;L.Dk=131072;L.FLAG_PERSONALIZED_HOMEPAGE_FEED_RECOMMENDED_COLLAPSED=L.Dk;L.Ek=262144;
L.FLAG_PERSONALIZED_HOMEPAGE_FEED_SUBSCRIPTIONS_COLLAPSED=L.Ek;L.Ck=524288;L.FLAG_PERSONALIZED_HOMEPAGE_FEED_POPULAR_COLLAPSED=L.Ck;L.Bk=1048576;L.FLAG_PERSONALIZED_HOMEPAGE_FEED_FRIENDTIVITY_COLLAPSED=L.Bk;L.Lk=2097152;L.FLAG_SUGGEST_ENABLED=L.Lk;L.wk=4194304;L.FLAG_HAS_SUGGEST_ENABLED=L.wk;L.Mk=8388608;L.FLAG_WATCH_BETA_PLAYER=L.Mk;L.vk=16777216;L.FLAG_HAS_REDIRECTED_TO_LOCAL_SITE=L.vk;L.rk=33554432;L.FLAG_ACCOUNT_SHOW_PLAYLIST_INFO=L.rk;L.xk=67108864;L.FLAG_HAS_TAKEN_CHANNEL_SURVEY=L.xk;L.yk=134217728;
L.FLAG_HIDE_TOOLBAR=L.yk;L.Hk=268435456;L.FLAG_SHOWN_LANG_OPT_OUT=L.Hk;L.uk=536870912;L.FLAG_HAS_REDIRECTED_TO_LOCAL_LANG=L.uk;L.Gk=1073741824;L.FLAG_SHOWN_COUNTRY_OPT_OUT=L.Gk;L.Jj=1;L.FLAG2_UPLOAD_BETA_OPTSET=L.Jj;L.Ij=2;L.FLAG2_UPLOAD_BETA_OPTIN=L.Ij;L.qj=4;L.FLAG2_HIDE_MASTHEAD=L.qj;L.Gj=8;L.FLAG2_TV_PARITY=L.Gj;L.Dj=16;L.FLAG2_TV_AUTO_FULLSCREEN_OFF=L.Dj;L.Ej=32;L.FLAG2_TV_AUTO_PLAY_NEXT_OFF=L.Ej;L.Fj=64;L.FLAG2_TV_ENABLE_MULTIPLE_CONTROLLERS=L.Fj;L.Hj=128;L.FLAG2_TV_RESERVED=L.Hj;L.uj=256;
L.FLAG2_LIGHT_HOMEPAGE=L.uj;L.zj=512;L.FLAG2_REDLINE_HIDE_TOAST=L.zj;L.mj=1024;L.FLAG2_ANNOTATIONS_EDITOR_WATCH_PAGE_DEFAULT_OFF=L.mj;L.yj=2048;L.FLAG2_REDLINE_HIDE_START_MESSAGE=L.yj;L.nj=4096;L.FLAG2_ANNOTATIONS_LOAD_POLICY_BY_DEMAND=L.nj;L.Rc=8192;L.FLAG2_EMBED_DELAYED_COOKIES=L.Rc;L.pj=16384;L.FLAG2_HD_TIP_DEMOTE=L.pj;L.wj=32768;L.FLAG2_NEWS_TIP_DEMOTE=L.wj;L.Kj=65536;L.FLAG2_UPLOAD_RESTRICT_TIP_DEMOTE=L.Kj;L.qf=131072;L.FLAG2_YPP_HIDE_INVITE_SPAM_BOX=L.qf;L.rf=262144;
L.FLAG2_YPP_HIDE_NEEDS_ADSENSE_BOX=L.rf;L.sf=524288;L.FLAG2_YPP_HIDE_NEEDS_TRAINING_BOX=L.sf;L.Cj=1048576;L.FLAG2_SKIP_CONTRINTER=L.Cj;L.Qc=2097152;L.FLAG2_EMBED_DEFAULT_HD=L.Qc;L.oj=4194304;L.FLAG2_ENABLE_FILTER_WORDS=L.oj;L.xj=8388608;L.FLAG2_OPTED_IN_FOR_COMMENTS=L.xj;L.sj=16777216;L.FLAG2_HQ_SETTING_SAVED=L.sj;L.be=33554432;L.FLAG2_HAS_TAKEN_WATCH_PAGE_SURVEY=L.be;L.Bj=67108864;L.FLAG2_SERVE_MOBILE_HQ_VIDEO=L.Bj;L.Aj=134217728;L.FLAG2_SAFETY_CONTENT_MODE=L.Aj;L.rj=268435456;
L.FLAG2_HIDE_PROMO_ACTIVITY_SUBSCRIPTIONS=L.rj;L.vj=536870912;L.FLAG2_MOBILE_APP_OPTOUT=L.vj;L.tj=1073741824;L.FLAG2_HTML5_BETA=L.tj;L.ck=1;L.FLAG3_LITE_WATCH=L.ck;L.Mj=2;L.FLAG3_ANNOTATIONS_EDITOR_WATCH_PAGE_DEFAULT_ON=L.Mj;L.lk=4;L.FLAG3_WATCH5_OPTIN=L.lk;L.Oj=8;L.FLAG3_CAPTIONS_DEFAULT_OFF=L.Oj;L.Nj=16;L.FLAG3_AUTO_CAPTIONS_DEFAULT_ON=L.Nj;L.dk=32;L.FLAG3_LITE_WATCH_OPT_OUT=L.dk;L.Sj=64;L.FLAG3_FBPROMO_OPT_OUT=L.Sj;L.Tj=128;L.FLAG3_HIDE_CHROME_PROMOS=L.Tj;L.Wj=256;
L.FLAG3_HOMEPAGE_ALL_VS_SUB_VIEW=L.Wj;L.gk=512;L.FLAG3_MYVIDEOSMANAGER_BETA_OPTOUT=L.gk;L.Vj=1024;L.FLAG3_HIDE_VIDEO_EDITOR_GUIDED_HELP=L.Vj;L.jk=2048;L.FLAG3_SAFETY_MODE_CHANGED_MANUALLY=L.jk;L.ek=4096;L.FLAG3_LIVE_COMMENTS_SCROLL=L.ek;L.Tc=8192;L.FLAG3_USE_FLASH_EMBED_CODE=L.Tc;L.Ef=16384;L.FLAG3_AUTOPLAY_PLAYLISTS_OFF=L.Ef;L.Sd=32768;L.FLAG3_QUICKLIST_COLLAPSED=L.Sd;L.Uj=65536;L.FLAG3_HIDE_CMS_DETAIL_GUIDED_HELP=L.Uj;L.kk=131072;L.FLAG3_USE_IFRAME_EMBED_CODE=L.kk;L.bk=262144;
L.FLAG3_HTML5_OPT_OUT=L.bk;L.Rj=524288;L.FLAG3_EMERALD_SEA_YT_OPT_OUT=L.Rj;L.fk=1048576;L.FLAG3_MINIMIZE_SIGNUP_PROMO=L.fk;L.Xj=2097152;L.FLAG3_HOMEPAGE_FEED_OPT_IN=L.Xj;L.Zj=4194304;L.FLAG3_HOMEPAGE_FEED_OPT_OUT=L.Zj;L.Yj=8388608;L.FLAG3_HOMEPAGE_FEED_OPT_IN_PROMO_DISMISSED=L.Yj;L.$j=16777216;L.FLAG3_HOMEPAGE_FEED_VIEW1=L.$j;L.ak=33554432;L.FLAG3_HOMEPAGE_FEED_VIEW2=L.ak;L.Pj=67108864;L.FLAG3_CREATE_PROMO_OPT_OUT=L.Pj;L.Lj=134217728;L.FLAG3_240P_LIGHT_OPT_IN=L.Lj;L.Qj=268435456;
L.FLAG3_CREATIVE_COMMONS_PROMO_OPT_OUT=L.Qj;L.ik=536870912;L.FLAG3_PARTNER_EMAIL_UPDATES_PROMO_OPT_OUT=L.ik;L.hk=1073741824;L.FLAG3_MY_REV_SHARE_MOVE_NOTIFICATION=L.hk;L.mk=1;L.FLAG4_ENHANCE_PROMO_OPT_OUT=L.mk;L.tf=2;L.FLAG4_YPP_HIDE_NEEDS_SIGNED_CONTRACT_BOX=L.tf;L.ok=4;L.FLAG4_HIDE_IVPE_PROMO_BOX=L.ok;L.nk=8;L.FLAG4_HIDE_HOMEPAGE_GUIDED_HELP=L.nk;L.pk=16;L.FLAG4_HIDE_MONETIZATION_CONGRATULATIONS=L.pk;L.qk=32;L.FLAG4_HTML5_PREFERRED=L.qk;var ud=window.yt&&window.yt.config_||{};s("yt.config_",ud);var vd=window.yt&&window.yt.globals_||{};s("yt.globals_",vd);var wd=window.yt&&window.yt.msgs_||{};s("yt.msgs_",wd);var xd=window.yt&&window.yt.timeouts_||[];s("yt.timeouts_",xd);var yd=window.yt&&window.yt.intervals_||[];s("yt.intervals_",yd);
var Ad=function(a){zd(ud,arguments)},N=function(a,b){return a in ud?ud[a]:b},Bd=function(a){for(var b=0,c=arguments.length;b<c;++b)vd[arguments[b]]=1},O=function(a,b){var c=window.setTimeout(a,b);xd.push(c);return c},Cd=function(a,b){var c=window.setInterval(a,b);yd.push(c);return c},Dd=function(a){window.clearTimeout(a)},Ed=function(a){window.clearInterval(a)},P=function(a,b,c){var d=b||{};if(a=a in wd?wd[a]:c)for(var e in d)a=a.replace(RegExp("\\$"+e,"gi"),function(){return d[e]});return a},zd=
function(a,b){if(1<b.length){var c=b[0];a[c]=b[1]}else{var d=b[0];for(c in d)a[c]=d[c]}},Fd=!!eval("/*@cc_on!@*/false");var Gd={},Hd=function(a,b,c,d){if(N("EVENTS_TRACKER_INSTALLED")){var e=Gd[a];if(!e){var f=window._gaq._getAsyncTracker("eventsPageTracker");if(!f)return;window._gaq.push(function(){e=f._createEventTracker(a);Gd[a]=e})}var g=c||i,m=d||i;window._gaq.push(function(){e._trackEvent(b,g,m)})}};var Q=function(a,b,c){a.dataset?a.dataset[Id(b)]=c:a.setAttribute("data-"+b,c)},R=function(a,b){return a.dataset?a.dataset[Id(b)]:a.getAttribute("data-"+b)},Jd=function(a,b){a.dataset?delete a.dataset[Id(b)]:a.removeAttribute("data-"+b)},Kd=function(a,b){return a.dataset?Id(b)in a.dataset:a.hasAttribute?!!a.hasAttribute("data-"+b):!!a.getAttribute("data-"+b)},Ld={},Id=function(a){return Ld[a]||(Ld[a]=(""+a).replace(/\-([a-z])/g,function(a,c){return c.toUpperCase()}))};var Nd=function(a){var b=a.__yt_uid_key;if(!b)b=Md(),a.__yt_uid_key=b;return b},Md=q("yt.dom.getNextId_");if(!Md){Md=function(){return++Od};s("yt.dom.getNextId_",Md);var Od=0}
var Pd=function(a){var b=a.cloneNode(l);"TR"==b.tagName||"SELECT"==b.tagName?u(a.childNodes,function(a){b.appendChild(Pd(a))}):b.innerHTML=a.innerHTML;return b},Qd=function(a){a=Pd(C(a));a.removeAttribute("id");return a},Rd=function(a,b,c){a=C(a);b=C(b);return!!Nc(a,function(a){return a===b},j,c)},Sd=function(a,b){return I(a,k,b)},Td=function(a,b,c){a=E(a,b,c);return a.length?a[0]:k},Ud=function(a){a=F("comment-list",a);return a.length?a[a.length-1]:k},Vd=function(a,b){if("disabled"in a)a.disabled=
!b;1==a.nodeType&&A(a,"disabled",!b);if(a.hasChildNodes())for(var c=0,d;d=a.childNodes[c];++c)Vd(d,b)},Xd=function(a){var b=C(a),c=Pd(b);a.parentNode.appendChild(c);c.style.whiteSpace="normal";c.style.lineHeight="1.5em";var d=R(b,"original-html");d||(d=b.innerHTML.replace(/^\s+|\s+$/,""),Q(b,"original-html",d));for(var a=/<[^>]+>/g,e=d.match(a)||[],f=d.replace(a,"<wbr>").split("<wbr>"),g=function(a){var b=[],c;for(c=0;c<a.length;c++)b.push(a[c]),e[c]&&b.push(e[c]);e[c]&&e[c].match(/^<\s*\//)&&b.push(e[c]);
b=b.join("");return b.length<d.length?b+"…":b},m=Wd(c),a=function(a){c.innerHTML=g(a);a=(c.clientHeight||c.offsetHeight)<=m;c.innerHTML="";return a},b=function(a){for(var b=[],c=0,d=f.length;c<d&&0<a;c++){var e=f[c];b.push(e.substring(0,a));a-=e.length}return b},p=0,x=f.join("").length+1,D=[];p<x;){var H=p+Math.round((x-p)/2),M=b(H);a(M)?(D=M,p=H+1):x=H-1}Ac(c);return g(D)},Wd=function(a){for(var b=a.innerHTML,c="",d=0;1>d;d++)c+=" <br>";a.innerHTML=c;c=a.clientHeight||a.offsetHeight;
a.innerHTML=b;return c};var Yd=function(a){if(a=a||q("window.event")){this.type=a.type;var b=a.target||a.srcElement;if(b&&3==b.nodeType)b=b.parentNode;this.target=b;if(b=a.relatedTarget)try{b=b.nodeName&&b}catch(c){b=k}else if("mouseover"==this.type)b=a.fromElement;else if("mouseout"==this.type)b=a.toElement;this.relatedTarget=b;this.data=a.data;this.source=a.source;this.origin=a.origin;this.state=a.state;this.clientX=a.clientX!==i?a.clientX:a.pageX;this.clientY=a.clientY!==i?a.clientY:a.pageY;if(a.pageX||a.pageY)this.pageX=
a.pageX,this.pageY=a.pageY;else if((a.clientX||a.clientY)&&document.body&&document.documentElement)this.pageX=a.clientX+document.body.scrollLeft+document.documentElement.scrollLeft,this.pageY=a.clientY+document.body.scrollTop+document.documentElement.scrollTop;this.keyCode=a.keyCode?a.keyCode:a.which;this.charCode=a.charCode||("keypress"==this.type?this.keyCode:0);if(0==this.type.indexOf("touch"))this.touches=a.touches,this.changedTouches=a.changedTouches;if(0==this.type.indexOf("gesture"))this.scale=
a.scale,this.rotation=a.rotation;this.Pa=a}};n=Yd.prototype;n.type="";n.target=k;n.relatedTarget=k;n.currentTarget=k;n.data=k;n.source=k;n.origin=k;n.state=k;n.keyCode=0;n.charCode=0;n.Pa=k;n.clientX=0;n.clientY=0;n.pageX=0;n.pageY=0;n.touches=k;n.changedTouches=k;n.preventDefault=function(){this.Pa.returnValue=l;this.Pa.preventDefault&&this.Pa.preventDefault()};n.stopPropagation=function(){this.Pa.cancelBubble=j;this.Pa.stopPropagation&&this.Pa.stopPropagation()};var Zd=q("yt.events.listeners_")||{};s("yt.events.listeners_",Zd);var $d=q("yt.events.counter_")||{count:0};s("yt.events.counter_",$d);
var ae=function(a,b,c,d){return yb(Zd,function(e){return e[0]==a&&e[1]==b&&e[2]==c&&e[4]==!!d})},S=function(a,b,c,d){if(!a||!a.addEventListener&&!a.attachEvent)return"";var d=!!d,e=ae(a,b,c,d);if(e)return e;var e=++$d.count+"",f=function(b){b=new Yd(b);b.currentTarget=a;return c.call(a,b)};Zd[e]=[a,b,c,f,d];a.addEventListener?a.addEventListener(b,f,d):a.attachEvent("on"+b,f);return e},ce=function(a,b,c,d){var e;e=S(a,b,function(){be(e);c.apply(a,arguments)},d)},ee=function(a,b){de(a,"click",b,function(a){return"li"===
a.nodeName.toLowerCase()&&j})},fe=function(a,b,c,d){return de(a,b,c,function(a){return z(a,d)})},de=function(a,b,c,d){var e=a||document;return S(e,b,function(a){var b=Nc(a.target,function(a){return a===e||d(a)},j);if(b&&b!==e)a.currentTarget=b,c.call(b,a)})},ge=function(a,b,c,d){(a=ae(a,b,c,!!d))&&be(a)},be=function(a){if(a in Zd){var b=Zd[a],c=b[0],d=b[1],e=b[3],b=b[4];c.removeEventListener?c.removeEventListener(d,e,b):c.detachEvent("on"+d,e);delete Zd[a]}},he=function(a){a=a||window.event;a=a.target||
a.srcElement;if(3==a.nodeType)a=a.parentNode;return a},ie=function(a){a=a||window.event;a.cancelBubble=j;a.stopPropagation&&a.stopPropagation()},je=function(a){a=a||window.event;a.returnValue=l;a.preventDefault&&a.preventDefault();return l},ke=function(a){if(document.createEvent){var b=document.createEvent("HTMLEvents");b.initEvent("click",j,j);a.dispatchEvent(b)}else b=document.createEventObject(),a.fireEvent("onclick",b)};var le=function(a,b,c,d,e,f,g){var m=[];a&&m.push(a,":");c&&(m.push("//"),b&&m.push(b,"@"),m.push(c),d&&m.push(":",d));e&&m.push(e);f&&m.push("?",f);g&&m.push("#",g);return m.join("")},me=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([\\w\\d\\-\\u0100-\\uffff.%]*)(?::([0-9]+))?)?([^?#]+)?(?:\\?([^#]*))?(?:#(.*))?$"),ne=function(){var a=document.location.href.match(me);return le(a[1],a[2],a[3],a[4])},oe=function(a){a=a.match(me);return le(k,k,k,k,a[5],a[6],a[7])},pe=function(a){if(a[1]){var b=a[0],
c=b.indexOf("#");0<=c&&(a.push(b.substr(c)),a[0]=b=b.substr(0,c));c=b.indexOf("?");0>c?a[1]="?":c==b.length-1&&(a[1]=i)}return a.join("")},qe=function(a,b,c){if(ea(b))for(var d=0;d<b.length;d++)c.push("&",a),""!==b[d]&&c.push("=",ua(b[d]));else b!=k&&(c.push("&",a),""!==b&&c.push("=",ua(b)))},re=function(a,b,c){Qa(0==Math.max(b.length-(c||0),0)%2,"goog.uri.utils: Key/value lists must be even in length.");for(c=c||0;c<b.length;c+=2)qe(b[c],b[c+1],a);return a},se=function(a,b){for(var c in b)qe(c,b[c],
a);return a},te=function(a){a=se([],a);a[0]="";return a.join("")},ue=function(a,b){return pe(2==arguments.length?re([a],arguments[1],0):re([a],arguments,1))},ve=function(a,b){return pe(se([a],b))};var we=function(a){"?"==a.charAt(0)&&(a=a.substr(1));for(var a=a.split("&"),b={},c=0,d=a.length;c<d;c++){var e=a[c].split("=");if(1==e.length&&e[0]||2==e.length){var f=e[0],e=decodeURIComponent((e[1]||"").replace(/\+/g," "));f in b?ea(b[f])?hb(b[f],e):b[f]=[b[f],e]:b[f]=e}}return b},xe=function(a){return-1!=a.indexOf("?")?(a=(a||"").split("#")[0],a=a.split("?",2),we(1<a.length?a[1]:a[0])):{}},ye=function(a){"#"==a.charAt(0)&&(a="!"==a.charAt(1)?a.substr(2):a.substr(1));return we(a)},ze=function(a,
b){var c=a.split("?",2),a=c[0],c=we(c[1]||""),d;for(d in b)c[d]=b[d];return ve(a,c)},Ae=function(a){var b;b=(a=a.match(me)[3]||k)&&decodeURIComponent(a),a=b;a=a===k?k:a.split(".").reverse();return(a===k?l:"com"==a[0]&&a[1].match(/^youtube(?:-nocookie)?$/)?j:l)||(a===k?l:"google"==a[1]?j:"google"==a[2]?"au"==a[0]&&"com"==a[1]?j:"uk"==a[0]&&"co"==a[1]?j:l:l)};var Ee=function(a){a=a||{};this.url=a.url||this.url;this.Ib=a.url_v8||this.Ib;this.Jb=a.url_v9as2||this.Jb;this.Fb=a.min_version||this.Fb;this.kc=a.args||Ab(Be);this.Ll=a.assets||{};this.Re=a.attrs||Ab(Ce);this.H=a.params||Ab(De);this.Hb=a.fallback||this.Hb;this.ef=a.html5||this.ef;this.disable=a.disable||{}},Be={enablejsapi:1},Ce={width:"640",height:"385"},De={allowscriptaccess:"always",allowfullscreen:"true",bgcolor:"#000000"};n=Ee.prototype;n.url="";n.Ib="";n.Jb="";n.Fb="8.0.0";n.ef=l;var Ge=function(){this.Fc=[];Fe(this)};ba(Ge);n=Ge.prototype;n.G=0;n.va=0;n.rev=0;n.Rd="";n.ui="";n.ua=0;n.load=function(a){3<=this.ua?a(this):this.Fc.push(a)};n.setVersion=function(a){this.G=a[0];this.va=a[1];this.rev=a[2]};n.isSupported=function(a,b,c){a="string"==typeof a?a.split("."):[a,b,c];a[0]=parseInt(a[0],10)||0;a[1]=parseInt(a[1],10)||0;a[2]=parseInt(a[2],10)||0;return this.G>a[0]||this.G==a[0]&&this.va>a[1]||this.G==a[0]&&this.va==a[1]&&this.rev>=a[2]};
var He=function(a){return-1<a.Rd.indexOf("Gnash")&&-1==a.Rd.indexOf("AVM2")?l:9==a.G&&1==a.va?l:9==a.G&&0==a.va&&1==a.rev?l:9<=a.G},Ie=function(a){return-1<navigator.userAgent.indexOf("Sony/COM2")&&!a.isSupported(9,1,58)?l:j},Fe=function(a){if(3>a.ua)if(1>a.ua){var b=q("window.navigator.plugins"),c=q("window.navigator.mimeTypes"),b=b&&b["Shockwave Flash"],c=c&&c["application/x-shockwave-flash"],c=b&&c&&c.enabledPlugin&&b.description||"";if(b=c){var d=b.indexOf("Shockwave Flash");0<=d&&(b=b.substr(d+
15));for(var d=b.split(" "),e="",b="",f=0,g=d.length;f<g;f++)if(e)if(b)break;else b=d[f];else e=d[f];e=e.split(".");d=parseInt(e[0],10)||0;e=parseInt(e[1],10)||0;f=0;if("r"==b.charAt(0)||"d"==b.charAt(0))f=parseInt(b.substr(1),10)||0;b=[d,e,f]}else b=[0,0,0];a.Rd=c;a.setVersion(b);a.ua=1;0<a.G?Je(a):Fe(a)}else 2>a.ua?Ke(a):Je(a)};
Ge.prototype.Zf=function(a){var b;a?(b=a.split(" ")[1].split(","),b=[parseInt(b[0],10)||0,parseInt(b[1],10)||0,parseInt(b[2],10)||0]):b=[0,0,0];this.ui=a;this.setVersion(b);this.ua=2;0<this.G?Je(this):Fe(this)};
var Je=function(a){if(3>a.ua){a.ua=3;for(var b=0,c=a.Fc.length;b<c;b++)a.Fc[b](a);a.Fc=[]}},Ke=function(a){var b,c,d,e;if(Fd){try{b=new ActiveXObject("ShockwaveFlash.ShockwaveFlash")}catch(f){b=k}b||a.Zf("")}else d=document.getElementsByTagName("body")[0],e=document.createElement("object"),e.setAttribute("type","application/x-shockwave-flash"),b=d.appendChild(e);var g=r(a.Zf,a),m=0,p=function(){if(b&&"GetVariable"in b)try{c=b.GetVariable("$version")}catch(a){c=""}c||10<=m?(d&&e&&d.removeChild(e),
g(c||"")):(m++,O(p,10))};O(p,0)};var Le=function(a,b,c){if((a=C(a))&&b&&c){c instanceof Ee||(c=new Ee(c));var d=Ab(c.Re),e=Ab(c.H);e.flashvars=te(c.kc);c=[];if(Fd){d.classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000";e.movie=b;c.push("<object ");for(var f in d)c.push(f,'="',d[f],'"');c.push(">");for(f in e)c.push('<param name="',f,'" value="',e[f],'">');c.push("</object>")}else{d.type="application/x-shockwave-flash";d.src=b;c.push("<embed ");for(f in d)c.push(f,'="',d[f],'"');for(f in e)c.push(f,'="',e[f],'"');c.push(" />")}a.innerHTML=
c.join("")}},Me=function(a,b){if(a){a instanceof Ee||(a=new Ee(a));var c=!!b,d=C(a.Re.id),e=d?d.parentNode:k;if(!d||!e)O(function(){Me(a)},50);else{if(window!=window.top){var f=k;if(document.referrer){var g=document.referrer.substring(0,128);Ae(g)||(f=g)}else f="unknown";if(f)c=j,a.kc.framer=f}Pe(function(b){if(b.isSupported(a.Fb)){var f="";-1<navigator.userAgent.indexOf("Sony/COM2")||(f=d.src||d.movie);He(b)?(f!=a.url||c)&&Le(e,a.url,a):Ie(b)?(f!=a.Jb||c)&&Le(e,a.Jb,a):(f!=a.Ib||c)&&Le(e,a.Ib,a)}else Fd&&
b.isSupported(6,0,65)?(b=new Ee({url:"//web.archive.org/web/20111228172059/http://s.ytimg.com/yt/swf/expressInstall-vflIE9HEf.swf",args:{MMredirectURL:window.location,MMplayerType:"ActiveX",MMdoctitle:document.title}}),Le(e,b.url,b)):0==b.G&&a.Hb?a.Hb():0==b.G&&a.Kd?a.Kd():e.innerHTML='<div id="flash-upgrade">'+P("FLASH_UPGRADE")+"</div>"})}}},Pe=function(a){Ge.getInstance().load(function(b){var c=K.getInstance();c.set("fv",[b.G,b.va,b.rev].join("."));c.save();a(b)})};var Qe=function(a,b,c,d){this.top=a;this.right=b;this.bottom=c;this.left=d};Qe.prototype.Na=function(){return new Qe(this.top,this.right,this.bottom,this.left)};Qe.prototype.toString=function(){return"("+this.top+"t, "+this.right+"r, "+this.bottom+"b, "+this.left+"l)"};Qe.prototype.contains=function(a){return!this||!a?l:a instanceof Qe?a.left>=this.left&&a.right<=this.right&&a.top>=this.top&&a.bottom<=this.bottom:a.x>=this.left&&a.x<=this.right&&a.y>=this.top&&a.y<=this.bottom};
Qe.prototype.expand=function(a,b,c,d){ha(a)?(this.top-=a.top,this.right+=a.right,this.bottom+=a.bottom,this.left-=a.left):(this.top-=a,this.right+=b,this.bottom+=c,this.left-=d);return this};var Re=function(a,b,c,d){this.left=a;this.top=b;this.width=c;this.height=d};Re.prototype.Na=function(){return new Re(this.left,this.top,this.width,this.height)};Re.prototype.toString=function(){return"("+this.left+", "+this.top+" - "+this.width+"w x "+this.height+"h)"};
Re.prototype.contains=function(a){return a instanceof Re?this.left<=a.left&&this.left+this.width>=a.left+a.width&&this.top<=a.top&&this.top+this.height>=a.top+a.height:a.x>=this.left&&a.x<=this.left+this.width&&a.y>=this.top&&a.y<=this.top+this.height};var Se=function(a,b,c){a.style[Ma(c)]=b},Te=function(a,b){var c=jc(a);return c.defaultView&&c.defaultView.getComputedStyle&&(c=c.defaultView.getComputedStyle(a,k))?c[b]||c.getPropertyValue(b):""},Ue=function(a,b){return a.currentStyle?a.currentStyle[b]:k},Ve=function(a,b){return Te(a,b)||Ue(a,b)||a.style&&a.style[b]},We=function(a){var b=a.getBoundingClientRect();if(B)a=a.ownerDocument,b.left-=a.documentElement.clientLeft+a.body.clientLeft,b.top-=a.documentElement.clientTop+a.body.clientTop;return b},
Xe=function(a){if(B&&!fc(8))return a.offsetParent;for(var b=jc(a),c=Ve(a,"position"),d="fixed"==c||"absolute"==c,a=a.parentNode;a&&a!=b;a=a.parentNode)if(c=Ve(a,"position"),d=d&&"static"==c&&a!=b.documentElement&&a!=b.body,!d&&(a.scrollWidth>a.clientWidth||a.scrollHeight>a.clientHeight||"fixed"==c||"absolute"==c||"relative"==c))return a;return k},$e=function(a){for(var b=new Qe(0,Infinity,Infinity,0),c=kc(a),d=c.r.body,e=c.r.documentElement,f=!Qb&&mc(c.r)?c.r.documentElement:c.r.body;a=Xe(a);)if((!B||
0!=a.clientWidth)&&(!Qb||0!=a.clientHeight||a!=d)&&a!=d&&a!=e&&"visible"!=Ve(a,"overflow")){var g=Ye(a),m;m=a;if(Pb&&!dc("1.9")){var p=parseFloat(Te(m,"borderLeftWidth"));if(Ze(m))var x=m.offsetWidth-m.clientWidth-p-parseFloat(Te(m,"borderRightWidth")),p=p+x;m=new sb(p,parseFloat(Te(m,"borderTopWidth")))}else m=new sb(m.clientLeft,m.clientTop);g.x+=m.x;g.y+=m.y;b.top=Math.max(b.top,g.y);b.right=Math.min(b.right,g.x+a.clientWidth);b.bottom=Math.min(b.bottom,g.y+a.clientHeight);b.left=Math.max(b.left,
g.x)}d=f.scrollLeft;f=f.scrollTop;b.left=Math.max(b.left,d);b.top=Math.max(b.top,f);c=pc(c.r.parentWindow||c.r.defaultView||window);b.right=Math.min(b.right,d+c.width);b.bottom=Math.min(b.bottom,f+c.height);return 0<=b.top&&0<=b.left&&b.bottom>b.top&&b.right>b.left?b:k},Ye=function(a){var b,c=jc(a),d=Ve(a,"position"),e=Pb&&c.getBoxObjectFor&&!a.getBoundingClientRect&&"absolute"==d&&(b=c.getBoxObjectFor(a))&&(0>b.screenX||0>b.screenY),f=new sb(0,0),g;b=c?9==c.nodeType?c:jc(c):document;g=B&&!fc(9)&&
!Oc(kc(b))?b.body:b.documentElement;if(a==g)return f;if(a.getBoundingClientRect)b=We(a),a=Pc(kc(c)),f.x=b.left+a.x,f.y=b.top+a.y;else if(c.getBoxObjectFor&&!e)b=c.getBoxObjectFor(a),a=c.getBoxObjectFor(g),f.x=b.screenX-a.screenX,f.y=b.screenY-a.screenY;else{b=a;do{f.x+=b.offsetLeft;f.y+=b.offsetTop;b!=a&&(f.x+=b.clientLeft||0,f.y+=b.clientTop||0);if(Qb&&"fixed"==Ve(b,"position")){f.x+=c.body.scrollLeft;f.y+=c.body.scrollTop;break}b=b.offsetParent}while(b&&b!=a);if(Ob||Qb&&"absolute"==d)f.y-=c.body.offsetTop;
for(b=a;(b=Xe(b))&&b!=c.body&&b!=g;)if(f.x-=b.scrollLeft,!Ob||"TR"!=b.tagName)f.y-=b.scrollTop}return f},af=function(a,b){"number"==typeof a&&(a=(b?Math.round(a):a)+"px");return a},cf=function(a){if("none"!=Ve(a,"display"))return bf(a);var b=a.style,c=b.display,d=b.visibility,e=b.position;b.visibility="hidden";b.position="absolute";b.display="inline";a=bf(a);b.display=c;b.position=e;b.visibility=d;return a},bf=function(a){var b=a.offsetWidth,c=a.offsetHeight,d=Qb&&!b&&!c;return(!da(b)||d)&&a.getBoundingClientRect?
(a=We(a),new ub(a.right-a.left,a.bottom-a.top)):new ub(b,c)},df=function(a){var b=Ye(a),a=cf(a);return new Re(b.x,b.y,a.width,a.height)},Ze=function(a){return"rtl"==Ve(a,"direction")},ef=function(a,b){if(/^\d+px?$/.test(b))return parseInt(b,10);var c=a.style.left,d=a.runtimeStyle.left;a.runtimeStyle.left=a.currentStyle.left;a.style.left=b;var e=a.style.pixelLeft;a.style.left=c;a.runtimeStyle.left=d;return e},ff={thin:2,medium:4,thick:6},gf=function(a,b){if("none"==Ue(a,b+"Style"))return 0;var c=Ue(a,
b+"Width");return c in ff?ff[c]:ef(a,c)};var hf=function(a,b){if((a=C(a))&&a.style)a.style.display=b?"":"none",A(a,"hid",!b)},jf=function(a){a=C(a);return!a?l:!("none"==a.style.display||z(a,"hid"))},kf=function(a){if(a=C(a))jf(a)?(a.style.display="none",v(a,"hid")):(a.style.display="",w(a,"hid"))},T=function(a){u(arguments,function(a){hf(a,j)})},U=function(a){u(arguments,function(a){hf(a,l)})},lf=function(a){u(arguments,kf)},mf=function(){var a=document.body;return a.style.transitionDuration!=i||a.style.MozTransitionDuration!=i||a.style.WebkitTransitionDuration!=
i||a.style.MsTransitionDuration!=i||a.style.OTransitionDuration!=i};var nf=0,qf=function(a,b){window.guidedhelp&&window.guidedhelp.loaded?of(a,b):(window.guidedhelp=window.guidedhelp||{},window.guidedhelp.onLoad=function(){var c=q("help.guide.init");c&&(c("http://web.archive.org/web/20111228172059/http://www.google.com/support/youtube",N("GUIDED_HELP_LOCALE")||"en_US","v2"),of(a,b))},pf())},pf=function(){var a=document.createElement("script");a.type="text/javascript";a.src="//web.archive.org/web/20111228172059/http://ssl.gstatic.com/inproduct_help/guide/guide_inproduct.js";document.body.appendChild(a)},of=function(a,b){nf=a;q("guidedhelp").onFlowDismiss=
function(){var b=rf(a);sf();(b=b.dismiss_callback)&&b(a)};b?q("help.guide.optionallyResume")(a):q("help.guide.loadFlow")(a)},sf=function(a){a=a||nf;U(rf(a).alert_id);(a=rf(a).cookie_name)&&ld(a,"true",7776E3)},uf=function(a){a=a||tf();U(rf(a).alert_id);qf(a)},tf=function(){var a;a:{var b=N("GUIDED_HELP_FLOWS"),c;for(c in b){a=c;break a}}return parseInt(a,10)},rf=function(a){var b=N("GUIDED_HELP_FLOWS");return b&&b[a]};s("yt.help.guide.dismissGuidedHelp",sf);s("yt.help.guide.startGuidedHelp",uf);
s("yt.help.guide.resumeGuidedHelp",function(){var a=tf();kd.get("GuidedHelpResume")&&qf(a,j)});s("yt.help.guide.init",function(){vb(N("GUIDED_HELP_FLOWS"),function(a,b){switch(a.status){case "prompt":T(rf(b).alert_id);break;case "start":uf(b);break;case "hide":sf(b);break;default:var c;var d=rf(b).cookie_name;d&&(c=!!md(d));c||T(rf(b).alert_id)}})});s("yt.help.guide.addSettings",function(a,b){var c=N("GUIDED_HELP_FLOWS");c||(c={});c[a]=b;Ad("GUIDED_HELP_FLOWS",c)});var vf=function(){};var wf=function(){this.da=[];this.ca={}};t(wf,vf);n=wf.prototype;n.Gf=1;n.uc=0;n.Eb=function(a,b,c){var d=this.ca[a];d||(d=this.ca[a]=[]);var e=this.Gf;this.da[e]=a;this.da[e+1]=b;this.da[e+2]=c;this.Gf=e+3;d.push(e);return e};n.Td=function(a){if(0!=this.uc){if(!this.tc)this.tc=[];this.tc.push(a);return l}var b=this.da[a];if(b){var c=this.ca[b];if(c){var d=Ua(c,a);0<=d&&cb(c,d)}delete this.da[a];delete this.da[a+1];delete this.da[a+2]}return!!b};
n.Pb=function(a,b){var c=this.ca[a];if(c){this.uc++;for(var d=ib(arguments,1),e=0,f=c.length;e<f;e++){var g=c[e];this.da[g+1].apply(this.da[g+2],d)}this.uc--;if(this.tc&&0==this.uc)for(;c=this.tc.pop();)this.Td(c);return 0!=e}return l};n.clear=function(a){if(a){var b=this.ca[a];b&&(u(b,this.Td,this),delete this.ca[a])}else this.da.length=0,this.ca={}};n.P=function(a){if(a){var b=this.ca[a];return b?b.length:0}a=0;for(b in this.ca)a+=this.P(b);return a};var xf=q("yt.pubsub.instance_")||new wf;wf.prototype.subscribe=wf.prototype.Eb;wf.prototype.unsubscribeByKey=wf.prototype.Td;wf.prototype.publish=wf.prototype.Pb;wf.prototype.clear=wf.prototype.clear;s("yt.pubsub.instance_",xf);var yf=function(a,b,c){var d=q("yt.pubsub.instance_");return d?d.subscribe(a,function(){var a=arguments;O(function(){b.apply(c||o,a)},0)},c):0},zf=function(a,b){var c=q("yt.pubsub.instance_");return c?c.publish.apply(c,arguments):l};var Af,Cf=function(a,b,c){this.ma=a;if(Bf)this.z=b;this.ab=c||window;this.qa=this.ab.location;this.Qh=this.qa.href.split("#")[0];this.Qe=r(this.Uh,this)},Df=B&&8<=document.documentMode||Pb&&dc("1.9.2")||Qb&&dc("532.1"),Bf=B&&!Df;
Cf.prototype.je=function(a,b){this.Hd&&(be(this.Hd),delete this.Hd);this.bb&&(Ed(this.bb),delete this.bb);if(a){this.ba=Ef(this);if(Bf){var c=this.z.contentWindow.document.body;(!c||!c.innerHTML)&&Ff(this,this.ba)}b||this.ma(this.ba);Df?this.Hd=S(this.ab,"hashchange",this.Qe):this.bb=Cd(this.Qe,200)}};
Cf.prototype.Uh=function(){if(Bf){var a;a=(a=this.z.contentWindow.document.body)?decodeURIComponent(a.innerHTML.substring(1).replace(/\+/g," ")):"";if(a!=this.ba)this.ba=a,Gf(this,a),this.ma(a);else if(a=Ef(this),a!=this.ba)this.ba=a,Ff(this,a),this.ma(a)}else if(a=Ef(this),a!=this.ba)this.ba=a,this.ma(a)};
var Ef=function(a){var a=a.qa.href,b=a.indexOf("#");return 0>b?"":a.substring(b+1)},Gf=function(a,b){var c=a.Qh+"#"+b,d=a.qa.href;if(!(d==c||d+"#"==c))a.qa.href=c},Ff=function(a,b){var c=a.z.contentWindow.document,d=c.body?c.body.innerHTML:"",e="#"+ua(b);d!=e&&(d=["<title>",Aa(window.document.title||""),"</title><body>",e,"</body>"],c.open("text/html"),c.write(d.join("")),c.close())};Cf.prototype.add=function(a,b,c){this.ba=""+a;Bf&&Ff(this,a);Gf(this,a);c||this.ma(this.ba)};var Hf=function(){this.bg=na()},If=new Hf;Hf.prototype.set=function(a){this.bg=a};Hf.prototype.reset=function(){this.set(na())};Hf.prototype.get=function(){return this.bg};var Jf=function(a){this.Zh=a||"";this.$h=If};n=Jf.prototype;n.df=j;n.bi=j;n.ai=j;n.Gd=l;n.ci=l;var Kf=function(a){return 10>a?"0"+a:""+a},Lf=function(a,b){var c=(a.af-b)/1E3,d=c.toFixed(3),e=0;if(1>c)e=2;else for(;100>c;)e++,c*=10;for(;0<e--;)d=" "+d;return d},Mf=function(a){Jf.call(this,a)};t(Mf,Jf);var Pf=function(a){return Of(a||arguments.callee.caller,[])},Of=function(a,b){var c=[];if(ab(b,a))c.push("[...circular reference...]");else if(a&&50>b.length){c.push(Qf(a)+"(");for(var d=a.arguments,e=0;e<d.length;e++){0<e&&c.push(", ");var f;f=d[e];switch(typeof f){case "object":f=f?"object":"null";break;case "string":break;case "number":f=""+f;break;case "boolean":f=f?"true":"false";break;case "function":f=(f=Qf(f))?f:"[fn]";break;default:f=typeof f}40<f.length&&(f=f.substr(0,40)+"...");c.push(f)}b.push(a);
c.push(")\n");try{c.push(Of(a.caller,b))}catch(g){c.push("[exception trying to get caller]\n")}}else a?c.push("[...long stack...]"):c.push("[end]");return c.join("")},Qf=function(a){if(Rf[a])return Rf[a];a=""+a;if(!Rf[a]){var b=/function ([^\(]+)/.exec(a);Rf[a]=b?b[1]:"[Anonymous]"}return Rf[a]},Rf={};var Sf=function(a,b,c,d,e){this.reset(a,b,c,d,e)};Sf.prototype.si=0;Sf.prototype.Ed=k;Sf.prototype.Dd=k;var Tf=0;Sf.prototype.reset=function(a,b,c,d,e){this.si="number"==typeof e?e:Tf++;this.af=d||na();this.Ma=a;this.ri=b;this.Ze=c;delete this.Ed;delete this.Dd};Sf.prototype.getLevel=function(){return this.Ma};Sf.prototype.Ec=function(a){this.Ma=a};Sf.prototype.getMessage=function(){return this.ri};var Uf=function(a){this.sa=a};Uf.prototype.Bc=k;Uf.prototype.Ma=k;Uf.prototype.ie=k;Uf.prototype.Qb=k;var Vf=function(a,b){this.name=a;this.value=b};Vf.prototype.toString=function(){return this.name};var Wf=new Vf("SHOUT",1200),Xf=new Vf("SEVERE",1E3),Yf=new Vf("WARNING",900),Zf=new Vf("INFO",800),$f=new Vf("CONFIG",700);Uf.prototype.getName=function(){return this.sa};Uf.prototype.getParent=function(){return this.Bc};Uf.prototype.Ec=function(a){this.Ma=a};Uf.prototype.getLevel=function(){return this.Ma};
var ag=function(a){if(a.Ma)return a.Ma;if(a.Bc)return ag(a.Bc);Ra("Root logger has no level set.");return k};Uf.prototype.log=function(a,b,c){if(a.value>=ag(this).value){a=this.cj(a,b,c);b="log:"+a.getMessage();o.console&&(o.console.timeStamp?o.console.timeStamp(b):o.console.markTimeline&&o.console.markTimeline(b));o.msWriteProfilerMark&&o.msWriteProfilerMark(b);for(b=this;b;){var c=b,d=a;if(c.Qb)for(var e=0,f=i;f=c.Qb[e];e++)f(d);b=b.getParent()}}};
Uf.prototype.cj=function(a,b,c){var d=new Sf(a,""+b,this.sa);if(c){d.Ed=c;var e;var f=arguments.callee.caller;try{var g;var m=q("window.location.href");if(ga(c))g={message:c,name:"Unknown error",lineNumber:"Not available",fileName:m,stack:"Not available"};else{var p,x,D=l;try{p=c.lineNumber||c.Nl||"Not available"}catch(H){p="Not available",D=j}try{x=c.fileName||c.filename||c.sourceURL||m}catch(M){x="Not available",D=j}g=D||!c.lineNumber||!c.fileName||!c.stack?{message:c.message,name:c.name,lineNumber:p,
fileName:x,stack:c.stack||"Not available"}:c}e="Message: "+Aa(g.message)+'\nUrl: <a href="view-source:'+g.fileName+'" target="_new">'+g.fileName+"</a>\nLine: "+g.lineNumber+"\n\nBrowser stack:\n"+Aa(g.stack+"-> ")+"[end]\n\nJS stack traversal:\n"+Aa(Pf(f)+"-> ")}catch(oa){e="Exception trying to expose exception! You win, we lose. "+oa}d.Dd=e}return d};Uf.prototype.info=function(a,b){this.log(Zf,a,b)};
var bg={},cg=k,dg=function(){cg||(cg=new Uf(""),bg[""]=cg,cg.Ec($f))},eg=function(a){dg();var b;if(!(b=bg[a])){b=new Uf(a);var c=a.lastIndexOf("."),d=a.substr(c+1),c=eg(a.substr(0,c));if(!c.ie)c.ie={};c.ie[d]=b;b.Bc=c;bg[a]=b}return b};var fg=function(){this.ni=r(this.ti,this);this.lc=new Mf;this.lc.df=l;this.Cf=this.lc.Gd=l;this.cf="";this.Mh={}},hg=function(){var a=gg;if(j!=a.Cf){dg();var b=cg,c=a.ni;if(!b.Qb)b.Qb=[];b.Qb.push(c);a.Cf=j}};
fg.prototype.ti=function(a){if(!this.Mh[a.Ze]){var b;b=this.lc;var c=[];c.push(b.Zh," ");if(b.df){var d=new Date(a.af);c.push("[",Kf(d.getFullYear()-2E3)+Kf(d.getMonth()+1)+Kf(d.getDate())+" "+Kf(d.getHours())+":"+Kf(d.getMinutes())+":"+Kf(d.getSeconds())+"."+Kf(Math.floor(d.getMilliseconds()/10)),"] ")}b.bi&&c.push("[",Lf(a,b.$h.get()),"s] ");b.ai&&c.push("[",a.Ze,"] ");b.ci&&c.push("[",a.getLevel().name,"] ");c.push(a.getMessage(),"\n");b.Gd&&a.Ed&&c.push(a.Dd,"\n");b=c.join("");if(ig&&ig.firebug)switch(a.getLevel()){case Wf:ig.info(b);
break;case Xf:ig.error(b);break;case Yf:ig.warn(b);break;default:ig.debug(b)}else ig?ig.log(b):window.opera?window.opera.postError(b):this.cf+=b}};var gg=k,ig=window.console,jg=function(){gg||(gg=new fg);-1!=window.location.href.indexOf("Debug=true")&&hg()};var kg=k,lg=function(a){if(!kg)jg(),hg(),gg.lc.Gd=j,kg=eg("yt.debug"),kg.Ec(Zf);kg.log(Zf,"yt.history.StateMonitor: "+a,i)};var mg=function(a,b){this.ma=a;this.ab=b||window;this.qa=this.ab.location;this.Wh=r(this.pi,this)},ng=!!window.history.pushState&&(!Qb||Qb&&dc("534.11"));mg.prototype.je=function(a,b){lg("setEnabled "+a);this.Pd&&(be(this.Pd),delete this.Pd);this.bb&&(Ed(this.bb),delete this.bb);!a||!ng?lg("disabling (supported = "+ng+")"):(lg("enabling"),this.rc=this.qa.href,b||this.ma(this.rc),this.Pd=S(this.ab,"popstate",this.Wh))};
mg.prototype.pi=function(a){var b=this.qa.href,a=a.state;lg("handlePopState_ "+b+" "+a);if(a||b!=this.rc)lg("handlePopState_ navCallback"),this.rc=b,this.ma(b,a)};mg.prototype.add=function(a,b,c){if(a||b)a=a||this.qa.href,this.ab.history.pushState(b,"",a),this.rc=a,c||this.ma(a,b)};var pg=function(a){var a=a||"hash",b=q("yt.history.instance_");if(!b)"state"==a?(b=new mg(og),mg.prototype.setEnabled=mg.prototype.je,mg.prototype.add=mg.prototype.add):(b=new Cf(og,C("legacy-history-iframe")),Cf.prototype.setEnabled=Cf.prototype.je,Cf.prototype.add=Cf.prototype.add),Af=b,s("yt.history.instance_",Af);return b},og=function(a,b){zf("navigate",a,b)};var qg={GOOGLE_IMA:"//web.archive.org/web/20111228172059/http://www.google.com/jsapi",GOOGLE_MAPS_API:"//web.archive.org/web/20111228172059/http://maps.google.com/maps/api/js?sensor=false",GOOGLE_LANGUAGE_API_VIRTUAL_KEYBOARD:"//web.archive.org/web/20111228172059/http://www.google.com/jsapi?key=youtube-internal-vk",GOOGLE_LANGUAGE_API_INPUT_TOOLS:"//web.archive.org/web/20111228172059/http://www.google.com/jsapi?key=youtube-internal-it"},rg={},sg={},tg={},vg=function(a){s("yt.net.apiloader.onApiLoaded_"+a,function(){ug(a)})},ug=function(a){sg[a]=j;u(tg[a],function(a){a.call()});delete tg[a]},wg=function(a,b){var c=qg[a];if(c)if(sg[a])b.call();else if(tg[a]||(tg[a]=
[]),tg[a].push(b),!rg[a]){vg(a);var c=ve(c,{callback:"yt.net.apiloader.onApiLoaded_"+a}),d=document.createElement("script");d.src=c;document.body.appendChild(d);rg[a]=j}};var xg,yg,zg=k,Ag=l,Bg="";var Cg,Dg,Eg=l,Fg="";var Gg=function(a){a=""+a;if(/^\s*$/.test(a)?0:/^[\],:{}\s\u2028\u2029]*$/.test(a.replace(/\\["\\\/bfnrtu]/g,"@").replace(/"[^"\\\n\r\u2028\u2029\x00-\x08\x10-\x1f\x80-\x9f]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:[\s\u2028\u2029]*\[)+/g,"")))try{return eval("("+a+")")}catch(b){}h(Error("Invalid JSON string: "+a))},Hg=function(a){return eval("("+a+")")},Ig=function(a){this.Hc=a},Kg=function(a,b){var c=[];Jg(a,b,c);return c.join("")},Jg=function(a,b,c){switch(typeof b){case "string":Lg(b,
c);break;case "number":c.push(isFinite(b)&&!isNaN(b)?b:"null");break;case "boolean":c.push(b);break;case "undefined":c.push("null");break;case "object":if(b==k){c.push("null");break}if(ea(b)){var d=b.length;c.push("[");for(var e="",f=0;f<d;f++)c.push(e),e=b[f],Jg(a,a.Hc?a.Hc.call(b,""+f,e):e,c),e=",";c.push("]");break}c.push("{");d="";for(f in b)Object.prototype.hasOwnProperty.call(b,f)&&(e=b[f],"function"!=typeof e&&(c.push(d),Lg(f,c),c.push(":"),Jg(a,a.Hc?a.Hc.call(b,f,e):e,c),d=","));c.push("}");
break;case "function":break;default:h(Error("Unknown type: "+typeof b))}},Mg={'"':'\\"',"\\":"\\\\","/":"\\/","\u0008":"\\b","\u000c":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\u000b":"\\u000b"},Ng=/\uffff/.test("\uffff")?/[\\\"\x00-\x1f\x7f-\uffff]/g:/[\\\"\x00-\x1f\x7f-\xff]/g,Lg=function(a,b){b.push('"',a.replace(Ng,function(a){if(a in Mg)return Mg[a];var b=a.charCodeAt(0),e="\\u";16>b?e+="000":256>b?e+="00":4096>b&&(e+="0");return Mg[a]=e+b.toString(16)}),'"')};var Og=k;"undefined"!=typeof XMLHttpRequest?Og=function(){return new XMLHttpRequest}:"undefined"!=typeof ActiveXObject&&(Og=function(){return new ActiveXObject("Microsoft.XMLHTTP")});var Pg=function(a){switch(a&&"status"in a?a.status:-1){case 0:case 200:case 204:case 304:return j;default:return l}};var Qg=function(a,b,c,d,e){var f=Og&&Og();if("open"in f){f.onreadystatechange=function(){4==(f&&"readyState"in f?f.readyState:0)&&b&&b(f)};c=(c||"GET").toUpperCase();d=d||"";f.open(c,a,j);a="POST"==c;if(e)for(var g in e)f.setRequestHeader(g,e[g]),"content-type"==g.toLowerCase()&&(a=l);a&&f.setRequestHeader("Content-Type","application/x-www-form-urlencoded");f.send(d)}},V=function(a,b){var c=b.format||"JSON";b.Kc&&(a=ne()+a);var d=b.g;d&&(a=ze(a,d));var d=b.Ra||"",e=b.j;d&&e&&h(Error());e&&(d=te(e));
Qg(a,function(a){var d=Pg(a),e=k;if(d||400<=a.status&&500>a.status)e=Rg(c,a);if(d)a:{switch(c){case "XML":d=0==parseInt(e&&e.return_code,10);break a;case "RAW":d=j;break a}d=!!e}var e=e||{},p=b.n||o;d?b.c&&b.c.call(p,a,e):b.l&&b.l.call(p,a,e);b.fa&&b.fa.call(p,a,e)},b.method,d,b.headers)},Rg=function(a,b){var c=k;switch(a){case "JSON":var d=b.responseText,e=b.getResponseHeader("Content-Type")||"";d&&0<=e.indexOf("json")&&(c=Hg(d));break;case "XML":if(d=(d=b.responseXML)?Sg(d):k)c={},u(d.getElementsByTagName("*"),
function(a){c[a.tagName]=Tg(a)})}return c},W=function(a,b){var c=b.onComplete||k,d=b.onException||k,e=b.onError||k,f=b.update||k,g=b.json||l;Qg(a,function(a){if(Pg(a)){var b=a.responseXML,x=b?Sg(b):k,b=!(!b||!x),D,H;if(b&&(D=Ug(x,"return_code"),H=Ug(x,"html_content"),0==D)){if(f&&H)C(f).innerHTML=H;var M=Ug(x,"js_content");if(M){var oa=document.createElement("script");oa.text=M;document.getElementsByTagName("head")[0].appendChild(oa)}}if(c)b?(b=Ug(x,"redirect_on_success"),D&&b?window.location=b:((x=
Ug(x,0==D?"success_message":"error_message"))&&alert(x),a=g?eval("("+H+")"):a,0==D?c(a):d&&d(a))):a.responseText&&c(a)}else e&&e(a)},b.method||"POST",b.postBody||k,b.headers||k)},Sg=function(a){return!a?k:(a=("responseXML"in a?a.responseXML:a).getElementsByTagName("root"))&&0<a.length?a[0]:k},Ug=function(a,b){if(!a)return k;var c=a.getElementsByTagName(b);return c&&0<c.length?Tg(c[0]):k},Tg=function(a){var b="";u(a.childNodes,function(a){b+=a.nodeValue});return b},Vg=q("yt.net.ajax.tokenMap_")||{};
s("yt.net.ajax.tokenMap_",Vg);var Wg={},Xg={},Yg=function(a,b,c){a=C(a);c=c||a[ia]||(a[ia]=++ja);c in Wg||(Wg[c]=[]);Wg[c].push([a,b]);Xg[c]=l;return c},Zg=function(a,b){var a=C(a),c=b||a[ia]||(a[ia]=++ja),d=Wg[c];d&&(Wg[c]=Va(d,function(b){return b[0]!=a}))},$g=function(a){a in Wg&&!Xg[a]&&(u(Wg[a],function(a){var c=a[0],a=a[1];if(c&&"IMG"==c.tagName)c.onload="",c.src=a}),Wg[a]=[],Xg[a]=j)};var bh=function(a,b,c){var d="scriptload-"+Ka(a),e=document.getElementById(d),f=e&&R(e,"loaded"),g=e&&!f;if(f&&!c)return b&&b(),e;if(g&&!c)return b&&yf(d,b),e;e&&(d="scriptload-"+(Math.floor(2147483648*Math.random()).toString(36)+Math.abs(Math.floor(2147483648*Math.random())^na()).toString(36)));b&&yf(d,b);var m=ah(a,d,function(){if(!R(m,"loaded")){Q(m,"loaded","true");zf(d);var a=d,b=q("yt.pubsub.instance_");b&&b.clear(a)}});return m},ah=function(a,b,c){var d=document.createElement("script");d.id=
b;d.onload=c;d.onreadystatechange=function(){if("loaded"==d.readyState||"complete"==d.readyState)d.onload()};d.src=a;a=document.getElementsByTagName("head")[0];a.insertBefore(d,a.firstChild);return d};var ch=function(a,b,c){b||(b={});var d=c||window,c="undefined"!=typeof a.href?a.href:""+a,a=b.target||a.target,e=[],f;for(f in b)switch(f){case "width":case "height":case "top":case "left":e.push(f+"="+b[f]);break;case "target":case "noreferrer":break;default:e.push(f+"="+(b[f]?1:0))}f=e.join(",");if(b.noreferrer){if(b=d.open("",a,f))B&&-1!=c.indexOf(";")&&(c="'"+c.replace(/'/g,"%27")+"'"),b.opener=k,Qb?b.location.href=c:(c=Aa(c),b.document.write('<META HTTP-EQUIV="refresh" content="0; url='+c+'">'),
b.document.close())}else b=d.open(c,a,f);return b};var dh=function(a,b,c){window.location=ve(a,b||{})+(c||"")},eh=function(a,b){var c=b||{};c.target=c.target||a.target||"YouTube";c.width=c.width||600;c.height=c.height||600;c=ch(a,c);if(!c)return j;if(!c.opener)c.opener=window;c.focus();return l};var X=function(a,b,c,d,e,f,g){this.uh=a;this.Ab="session_token="+a;if((this.A=b)&&"/"!=this.A.charAt(this.A.length-1))this.A+="/";this.oh=c;this.R=d;this.td=e;this.nh=f;this.vh=g;this.nd=l;this.jc=k;this.Bd=[];this.zd=[];this.ud=[];this.wb=N("ENABLE_FACEBOOK_OAUTH");this.vd={}};s("yt.sharing.AutoShare",X);X.prototype.vl=function(a,b,c,d){S(a,"click",r(this.Uf,this));a.id?(this.vd[a.id]={serviceName:b,connectOnly:c},d&&(this.vd[a.id].connectOnlyCallback=d)):h("Connect dialog launch buttons must have an id.")};
X.prototype.registerConnectDialogLauncher=X.prototype.vl;X.prototype.Uf=function(a){if(a=this.vd[a.currentTarget.id]){var b=a.connectOnly;a.connectOnlyCallback&&(b=(0,a.connectOnlyCallback)());this.oc(a.serviceName,b)}};X.prototype.handleConnectService=X.prototype.Uf;X.prototype.jl=function(a){a&&this.ra();this.wb||this.mc()};X.prototype.doOnLoad=X.prototype.jl;X.prototype.Xk=function(a){this.Bd.push(a)};X.prototype.addServiceChangedCallback=X.prototype.Xk;X.prototype.Wk=function(a){this.zd.push(a)};
X.prototype.addGaiaChangedCallback=X.prototype.Wk;X.prototype.Vk=function(a){this.ud.push(a)};X.prototype.addCanConnectCallback=X.prototype.Vk;X.prototype.rl=function(){return this.td};X.prototype.isGaiaUser=X.prototype.rl;X.prototype.El=function(){this.Id(this.A+"autoshare?action_link_start=1&root_url="+encodeURIComponent(this.A),{height:660,width:1E3})};X.prototype.upgradeToGoogleAccount=X.prototype.El;X.prototype.Fl=function(a,b){this.td=a;this.ej();b&&b()};
X.prototype.upgradeToGoogleAccountDone=X.prototype.Fl;X.prototype.ll=function(){return this.R};X.prototype.getServiceInfo=X.prototype.ll;
X.prototype.oc=function(a,b,c){this.td||W(this.A+"autoshare?action_ajax_stats_ping=1&stat=connect_no_google&service="+a,{method:"GET",onComplete:function(){}});for(var d in this.ud)if(!(0,this.ud[d])(this,a,b))return;W(this.A+"autoshare?action_ajax_stats_ping=1&stat=connect_has_google&service="+a,{method:"GET",onComplete:function(){}});if("facebook"==a&&!this.wb)this.jf(b);else{d=this.A+"autoshare?action_popup_auth=1&service="+a+"&connect_only="+(b?"True":"False")+"&root_url="+encodeURIComponent(this.A);
if("facebook"==a){var e="read_stream,offline_access";b||(e=[e,"publish_stream"].join());c&&(e=[e,"email"].join());d+="&permissions="+encodeURIComponent(e)}this.Id(d,{height:430,width:860});"es"==a?hf("autoshare-info-box-es",j):"twitter"==a&&hf("autoshare-info-box-twitter",j)}};X.prototype.connectService=X.prototype.oc;X.prototype.sl=function(a){W(this.A+"autoshare?action_ajax_stats_ping=1&stat=launch_facebook_onboarding",{method:"GET",onComplete:function(){}});this.jf(!a,j)};
X.prototype.launchFacebookOnboarding=X.prototype.sl;X.prototype.$k=function(a,b,c){var d=!!c,c=r(function(a){d?window.parent.location=a.target:(this.R=a,this.ra(),this.mc());b&&b()},this),e=r(function(){b&&b();this.ra()},this),f=d?"display_hybrid_onboarding":"ajax_connect_service",g={};g["action_"+f]=1;g.return_url=a;W(this.A+"autoshare?"+f,{postBody:te(g)+"&"+this.Ab,onComplete:c,onException:e,json:j})};X.prototype.connectServiceDone=X.prototype.$k;
X.prototype.el=function(a){"facebook"==a&&!this.wb?this.Vi():this.Of(a)};X.prototype.disconnectService=X.prototype.el;X.prototype.yl=function(a,b){var c=r(function(a){this.R=a;this.ra();this.mc()},this),d=r(function(){this.ra()},this),e={action_ajax_set_connect_only:1};e.service=a;e.connect_only=b?"True":"False";W(this.A+"autoshare?ajax_set_connect_only",{postBody:te(e)+"&"+this.Ab,onComplete:c,onException:d,json:j})};X.prototype.setConnectOnly=X.prototype.yl;
X.prototype.Of=function(a){var b=r(function(a){this.R=a;this.ra();this.mc()},this),c=r(function(){this.ra()},this),d={action_ajax_disconnect_service:1};d.service=a;W(this.A+"autoshare?ajax_disconnect_service",{postBody:te(d)+"&"+this.Ab,onComplete:b,onException:c,json:j})};X.prototype._disconnectService=X.prototype.Of;n=X.prototype;n.ej=function(){for(var a in this.zd)(0,this.zd[a])(this)};n.ra=function(){for(var a in this.Bd)(0,this.Bd[a])(this)};
n.mc=function(){for(var a in this.R){var b=this.R[a];"facebook"==a&&!this.wb&&b.is_connected&&this.yi()}};n.Id=function(a,b){if(this.jc)try{this.jc.close()}catch(c){this.jc=k}this.jc=eh(a,b)};
n.jf=function(a,b){this.wb&&this.oc("facebook",a,b);var c=!!a,d=!!b;this.nd=j;var e=this.nh,f=encodeURIComponent(this.A+"autoshare?action_popup_end=1&service=facebook&connect_only="+(c?"True":"False")+"&hybrid_onboarding="+(d?"True":"False")),g=encodeURIComponent(this.A+"autoshare?action_popup_end=1&service=facebook&cancel=1"),m="read_stream,offline_access";c||(m=[m,"publish_stream"].join());d&&(m=[m,"email"].join());this.Id("http://web.archive.org/web/20111228172059/http://www.facebook.com/login.php?return_session=1&nochrome=1&fbconnect=1&extern=1&connect_display=popup&api_key="+
e+"&v=1.0&next="+f+"&cancel_url="+g+"&req_perms="+encodeURIComponent(m)+"&locale="+this.oh,{height:535,width:530,location:"yes",Ml:"yes"})};n.Vi=function(){var a=r(function(a){a.responseXML&&this.Bf(Ug(Sg(a),"html_content"),"disconnect")},this);this.nd=j;W(this.A+"autoshare?ajax_facebook_get_disconnect_url",{postBody:te({action_ajax_facebook_get_disconnect_url:1})+"&"+this.Ab,onComplete:a})};
n.yi=function(){var a=r(function(a){a.responseXML&&this.Bf(Ug(Sg(a),"html_content"),"get_permissions_url_and_info")},this),b={action_ajax_facebook_get_info_url:1};b.facebook_critical=this.nd?"True":"False";W(this.A+"autoshare?ajax_facebook_get_info_url",{postBody:te(b)+"&"+this.Ab,onComplete:a})};
n.Bf=function(a,b){var c=C("autoshare-facebook-connect");c||(c=tc("DIV"),c.setAttribute("id","autoshare-facebook-connect"),c.setAttribute("style","display:none;"),document.body.appendChild(c));var d=C("autoshare-facebook-connect-iframe");d||(d=tc("IFRAME"));d.setAttribute("id","autoshare-facebook-connect-iframe");d.setAttribute("scrolling","no");d.setAttribute("frameborder","0");d.setAttribute("allowTransparency","true");d.setAttribute("width","1");d.setAttribute("height","1");d.setAttribute("style",
"border: none;");d.setAttribute("src","http://"+this.vh+"/ytfb_connect.html?xsrf="+this.uh+"&base_url="+this.A+"&tpmethod="+b+"&"+a);c.appendChild(d)};n.Uk=function(a,b,c,d,e){this.R.facebook.is_connected=a;this.R.facebook.connected_as=b;this.R.facebook.has_publish=c;this.R.facebook.has_feed=d;this.R.facebook.has_offline=e;this.ra()};X.prototype._facebookUpdateServiceInfo=X.prototype.Uk;X.prototype.Ql=function(){this.oc("facebook",!this.R.facebook.is_autosharing)};var fh={},gh=0,hh=function(a,b){var c=new Image,d=""+gh++;fh[d]=c;c.onload=c.onerror=function(){b&&fh[d]&&b();delete fh[d]};c.src=a;c=eval("null")};var Y=q("yt.timing")||{};s("yt.timing",Y);Y.Wi=0;Y.Pf=0;Y.Cc=function(a,b){var c=Y.timer||{};c[a]=b?b:na();Y.timer=c};Y.info=function(a,b){var c=Y.info_args||{};c[a]=b;Y.info_args=c};
Y.Ic=function(a){var a=a||N("TIMING_ACTION"),b=Y.timer||{},c=Y.info_args||{},d=b.start,e="",f=[],g=[];delete b.start;Y.srt&&(e="&srt="+Y.srt);b.aft&&b.plev&&(b.aft=Math.min(b.aft,b.plev));for(var m in b)f.push(m+"."+Math.round(b[m]-d));for(m in c)g.push(m+"="+c[m]);b.vr&&b.gv&&f.push("vl."+Math.round(b.vr-b.gv));!b.aft&&b.vr&&b.cl?b.cl>b.vr?f.push("aft."+Math.round(b.cl-d)):f.push("aft."+Math.round(b.vr-d)):!b.aft&&b.vr?f.push("aft."+Math.round(b.vr-d)):b.aft||f.push("aft."+Math.round(b.ol-d));hh(["https:"==
window.location.protocol?"http://web.archive.org/web/20111228172059/https://gg.google.com/csi":"http://web.archive.org/web/20111228172059/http://csi.gstatic.com/csi","?v=2&s=youtube&action=",a,e,"&",g.join("&"),"&rt=",f.join(",")].join(""))};Y.he=function(){var a=N("TIMING_ACTION"),b=Y.timer||{};a&&b.start&&(Y.wff&&-1!=a.indexOf("ajax")&&b.vr&&b.cl?Y.Ic():Y.wff&&-1==a.indexOf("ajax")&&b.vr?Y.Ic():!Y.wff&&(b.ol||b.aft)&&Y.Ic())};Y.$f=function(){Y.Cc("ol");Y.he()};
Y.nl=function(a){var b=++Y.Wi;"undefined"!=typeof a&&4>a&&Y.Pf++;4==Y.Pf&&Y.Cc("tn_c4");1!=b&&5!=b&&10!=b&&20!=b&&30!=b||Y.Cc("tn"+b)};var jh=function(a,b,c){Hd(a,b||"null");ih("a="+a+(b?"&"+b:"").replace(/\//g,"&"),c)},ih=function(a,b){hh("/gen_204?"+a,b)},kh=function(a,b,c,d){a=ve("/sharing_services",{name:a,v:b,locale:c,feature:d});hh(a)};var lh=[/ytimg\.com\/\S+\/(hq)?default.jpg$/,/\/master-[^/]+png$/,/\/pixel-[^/]+gif$/,/\/www-core-[^/]+(js|css)$/],mh=l,oh=function(){var a=Math.random();0.66<a?ih(nh("script")):0.33<a?ih(nh("img")):(a=nh("link",function(a){if("stylesheet"==a.rel)return a.href}),ih(a))},nh=function(a,b){var c=Wa(ph(a,b),qh),c=c.join(","),c=c.substring(0,1948),d=qh(document.location.href);return te({a:"included-resources",tag:a,source:d,resources:c})},ph=function(a,b){var c=b||function(a){return a.src},d=E(a,k,document),
e={};u(d,function(a){a=c(a);!(a in e)&&!rh(a)&&(e[a]=j)});return xb(e)},rh=function(a){return!a||Xa(lh,function(b){return b.test(a)})},qh=function(a){a=a.substring(0,100);return a.replace(",","")};var sh={},th="ontouchstart"in document,uh=function(a,b){var c=sh[a].maxNumParents[b],d;0<c?d=c:-1!=a.indexOf("mouse")&&(d=2);return d},vh=function(a,b,c){return Nc(b,function(b){return z(b,a)},j,c)||k},wh=function(a){if("HTML"!=a.target.tagName&&a.type in sh){var b=sh[a.type],c;for(c in b.ca){var d=uh(a.type,c),e=vh(c,a.target,d);if(e){var f=j;b.checkRelatedTarget[c]&&a.relatedTarget&&Nc(a.relatedTarget,function(a){return a==e},j,d)&&(f=l);f&&b.Pb(c,e,a.type,a)}}}};S(document,"click",wh);
S(document,"mouseover",wh);S(document,"mouseout",wh);S(document,"keydown",wh);S(document,"keyup",wh);S(document,"keypress",wh);S(document,"cut",wh);S(document,"paste",wh);th&&(S(document,"touchstart",wh),S(document,"touchend",wh),S(document,"touchcancel",wh));var xh=window.yt&&window.yt.uix&&window.yt.uix.widgets_||{};s("yt.uix.widgets_",xh);var yh=function(a){var a=a.getInstance(),b=Z(a);!(b in xh)&&a.de()&&(a.X(),xh[b]=a)};var zh=function(){this.N={}};n=zh.prototype;n.ce=!!eval("/*@cc_on!@*/false");n.de=function(){return j};n.addBehavior=function(a,b,c,d,e){var c=Z(this,c),f=r(b,this);if(!(a in sh))sh[a]=new wf,sh[a].maxNumParents={},sh[a].checkRelatedTarget={};a=sh[a];a.Eb(c,f);a.maxNumParents[c]=d;a.checkRelatedTarget[c]=e;this.N[b]=f};n.ta=function(a,b,c){var d=this.getData(a,b);if(d&&(d=q(d))){var e=ib(arguments,2);jb(e,0,0,a);d.apply(k,e)}};n.getData=function(a,b){return R(a,b)};
n.setData=function(a,b,c){Q(a,b,c)};var Ah=function(a,b){return Sd(b,Z(a))},Z=function(a,b){return"yt-uix"+(a.T?"-"+a.T:"")+(b?"-"+b:"")};var Bh=function(a,b,c,d,e,f,g,m){var p,x=c.offsetParent;if(x){var D="HTML"==x.tagName||"BODY"==x.tagName;if(!D||"static"!=Ve(x,"position"))p=Ye(x),D||(p=tb(p,new sb(x.scrollLeft,x.scrollTop)))}x=df(a);if(D=$e(a)){var H=new Re(D.left,D.top,D.right-D.left,D.bottom-D.top),D=Math.max(x.left,H.left),M=Math.min(x.left+x.width,H.left+H.width);if(D<=M){var oa=Math.max(x.top,H.top),H=Math.min(x.top+x.height,H.top+H.height);if(oa<=H)x.left=D,x.top=oa,x.width=M-D,x.height=H-oa}}D=kc(a);oa=kc(c);if(D.r!=oa.r){var M=
D.r.body,oa=oa.r.parentWindow||oa.r.defaultView,H=new sb(0,0),Mc=jc(M)?jc(M).parentWindow||jc(M).defaultView:window,Nf=M;do{var fb;if(Mc==oa)fb=Ye(Nf);else{var sa=Nf;fb=new sb;if(1==sa.nodeType)if(sa.getBoundingClientRect)sa=We(sa),fb.x=sa.left,fb.y=sa.top;else{var Ne=Pc(kc(sa)),sa=Ye(sa);fb.x=sa.x-Ne.x;fb.y=sa.y-Ne.y}else{var Ne="function"==ca(sa.Df),Oe=sa;sa.targetTouches?Oe=sa.targetTouches[0]:Ne&&sa.Df().targetTouches&&(Oe=sa.Df().targetTouches[0]);fb.x=Oe.clientX;fb.y=Oe.clientY}}H.x+=fb.x;H.y+=
fb.y}while(Mc&&Mc!=oa&&(Nf=Mc.frameElement)&&(Mc=Mc.parent));M=tb(H,Ye(M));B&&!Oc(D)&&(M=tb(M,Pc(D)));x.left+=M.x;x.top+=M.y}a=(b&4&&Ze(a)?b^2:b)&-5;b=new sb(a&2?x.left+x.width:x.left,a&1?x.top+x.height:x.top);p&&(b=tb(b,p));e&&(b.x+=(a&2?-1:1)*e.x,b.y+=(a&1?-1:1)*e.y);var J;if(g&&(J=$e(c))&&p)J.top-=p.y,J.right-=p.x,J.bottom-=p.y,J.left-=p.x;a:{p=b.Na();e=0;a=(d&4&&Ze(c)?d^2:d)&-5;d=cf(c);m=m?m.Na():d.Na();if(f||0!=a)a&2?p.x-=m.width+(f?f.right:0):f&&(p.x+=f.left),a&1?p.y-=m.height+(f?f.bottom:0):
f&&(p.y+=f.top);if(g){if(J){f=p;e=0;if(65==(g&65)&&(f.x<J.left||f.x>=J.right))g&=-2;if(132==(g&132)&&(f.y<J.top||f.y>=J.bottom))g&=-5;if(f.x<J.left&&g&1)f.x=J.left,e|=1;if(f.x<J.left&&f.x+m.width>J.right&&g&16)m.width=Math.max(m.width-(f.x+m.width-J.right),0),e|=4;if(f.x+m.width>J.right&&g&1)f.x=Math.max(J.right-m.width,J.left),e|=1;g&2&&(e|=(f.x<J.left?16:0)|(f.x+m.width>J.right?32:0));if(f.y<J.top&&g&4)f.y=J.top,e|=2;if(f.y>=J.top&&f.y+m.height>J.bottom&&g&32)m.height=Math.max(m.height-(f.y+m.height-
J.bottom),0),e|=8;if(f.y+m.height>J.bottom&&g&4)f.y=Math.max(J.bottom-m.height,J.top),e|=2;g&8&&(e|=(f.y<J.top?64:0)|(f.y+m.height>J.bottom?128:0));g=e}else g=256;e=g;if(e&496){c=e;break a}}f=Pb&&(Ib||Ub)&&dc("1.9");p instanceof sb?(g=p.x,p=p.y):(g=p,p=i);c.style.left=af(g,f);c.style.top=af(p,f);if(!(d==m||(!d||!m?0:d.width==m.width&&d.height==m.height)))f=Oc(kc(jc(c))),B&&(!f||!dc("8"))?(g=c.style,f?(B?(f=ef(c,Ue(c,"paddingLeft")),d=ef(c,Ue(c,"paddingRight")),p=ef(c,Ue(c,"paddingTop")),J=ef(c,Ue(c,
"paddingBottom")),f=new Qe(p,d,J,f)):(f=Te(c,"paddingLeft"),d=Te(c,"paddingRight"),p=Te(c,"paddingTop"),J=Te(c,"paddingBottom"),f=new Qe(parseFloat(p),parseFloat(d),parseFloat(J),parseFloat(f))),B?(d=gf(c,"borderLeft"),p=gf(c,"borderRight"),J=gf(c,"borderTop"),c=gf(c,"borderBottom"),c=new Qe(J,p,c,d)):(d=Te(c,"borderLeftWidth"),p=Te(c,"borderRightWidth"),J=Te(c,"borderTopWidth"),c=Te(c,"borderBottomWidth"),c=new Qe(parseFloat(J),parseFloat(p),parseFloat(c),parseFloat(d))),g.pixelWidth=m.width-c.left-
f.left-f.right-c.right,g.pixelHeight=m.height-c.top-f.top-f.bottom-c.bottom):(g.pixelWidth=m.width,g.pixelHeight=m.height)):(c=c.style,Pb?c.MozBoxSizing="border-box":Qb?c.WebkitBoxSizing="border-box":c.boxSizing="border-box",c.width=Math.max(m.width,0)+"px",c.height=Math.max(m.height,0)+"px");c=e}return c};var Ch=function(){this.N={}};t(Ch,zh);ba(Ch);n=Ch.prototype;n.T="button";n.If=k;n.X=function(){this.addBehavior("click",this.Oa);this.addBehavior("keydown",this.vc);this.addBehavior("keypress",this.ae)};n.Oa=function(a){if(a&&!a.disabled){if(z(a,Z(this,"toggle"))){var b=Sd(a,Z(this,"group"));if(b&&this.getData(b,"button-toggle-group")){var b=F(Z(this),b),c=Z(this,"toggled");u(b,function(b){b!=a?w(b,c):v(a,c)})}else rb(a,Z(this,"toggled"))}Dh(this,a)&&(Eh(this,a),a.focus());this.ta(a,"button-action")}};
n.vc=function(a,b,c){if(b=Dh(this,a)){var d=function(a){var b="";a.tagName&&(b=a.tagName.toLowerCase());return"ul"==b||"table"==b};if(d=d(b)?b:Hc(b,d)){var d=d.tagName.toLowerCase(),e;if("ul"==d)e=this.jj;else if("table"==d)e=this.ij;e&&Fh(this,a,b,c,r(e,this))}}};
var Fh=function(a,b,c,d,e){var f=jf(c),g=9==d.keyCode;g||32==d.keyCode||13==d.keyCode?(d=Gh(a,c))?(b=Dc(d),"a"==b.tagName.toLowerCase()?window.location=b.href:ke(b)):g&&Hh(a,b):f?27==d.keyCode?(Gh(a,c),Hh(a,b)):e(b,c,d):(a=z(b,Z(a,"reverse"))?38:40,d.keyCode==a&&(ke(b),d.preventDefault()))};Ch.prototype.ae=function(a,b,c){a=Dh(this,a);jf(a)&&c.preventDefault()};
var Gh=function(a,b){var c=Z(a,"menu-item-highlight"),d=G(c,b);d&&w(d,c);return d},Ih=function(a,b,c){v(c,Z(a,"menu-item-highlight"));b.setAttribute("aria-activedescendant",c.getAttribute("id"))};Ch.prototype.ij=function(a,b,c){var d=Gh(this,b),b=Td("table",k,b),e=Td("tr",k,b),e=E("td",k,e).length,b=E("td",k,b),d=Jh(d,b,e,c);-1!=d&&(Ih(this,a,b[d]),c.preventDefault())};Ch.prototype.jj=function(a,b,c){if(40==c.keyCode||38==c.keyCode){var d=Gh(this,b),b=E("li",k,b),d=Jh(d,b,1,c);Ih(this,a,b[d]);c.preventDefault()}};
var Jh=function(a,b,c,d){var e=b.length,a=Ua(b,a);if(-1==a)if(38==d.keyCode)a=e-c;else{if(37==d.keyCode||38==d.keyCode||40==d.keyCode)a=0}else 39==d.keyCode?(a%c==c-1&&(a-=c),a+=1):37==d.keyCode?(0==a%c&&(a+=c),a-=1):38==d.keyCode?(a<c&&(a+=e),a-=c):40==d.keyCode&&(a>=e-c&&(a-=e),a+=c);return a},Eh=function(a,b){var c=Dh(a,b),d=Kh(a,c);d&&d!=b?(Hh(a,d),O(r(a.ke,a,b),1)):jf(c)?Hh(a,b):a.ke(b)};
Ch.prototype.Nb=function(a){if(!Jb||!z(a,Z(this,"masked")))return k;var b=a.iframeMask;if(!b)b=document.createElement("iframe"),b.src='javascript:""',b.className=Z(this,"menu-mask"),a.iframeMask=b;return b};
var Lh=function(a,b,c){var d=Sd(b,Z(a,"group")),e=!!a.getData(b,"button-menu-ignore-group"),d=d&&!e?d:b,e=5,f=4;z(b,Z(a,"reverse"))&&(e=4,f=5);z(b,"flip")&&(z(b,Z(a,"reverse"))?(e=6,f=7):(e=7,f=6));var g;if(a.getData(b,"button-has-sibling-menu")){var m=Xe(d);B&&!dc("8")&&(m=k);m&&(g=df(m),g=new Qe(-g.top,g.left,g.top,-g.left))}m=new sb(0,1);if(a=a.Nb(b))b=cf(c),a.style.width=b.width+"px",a.style.height=b.height+"px",Bh(d,e,a,f,m,g);Bh(d,e,c,f,m,g)};
Ch.prototype.ke=function(a){if(a){var b=Dh(this,a);if(b){a.setAttribute("aria-pressed","true");a.setAttribute("aria-expanded","true");b.originalParentNode=b.parentNode;b.activeButtonNode=a;b.parentNode.removeChild(b);this.getData(a,"button-has-sibling-menu")?a.parentNode.appendChild(b):document.body.appendChild(b);var c=Sd(a,Z(this,"group")),d=!!this.getData(a,"button-menu-ignore-group");b.style.minWidth=(c&&!d?c.offsetWidth-2:a.offsetWidth-2)+"px";(d=this.Nb(a))&&document.body.appendChild(d);Lh(this,
a,b);T(b);this.ta(a,"button-menu-action",j);v(a,Z(this,"active"));c&&v(c,Z(this,"group-active"));c=r(this.zi,this,a);b=S(document,"click",c);c=S(document,"contextmenu",c);this.setData(a,"button-listener",b);this.setData(a,"button-context-menu-listener",c);this.If=a}}};
var Hh=function(a,b){if(b){var c=Dh(a,b);if(c){a.If=k;b.setAttribute("aria-pressed","false");b.setAttribute("aria-expanded","false");U(c);a.ta(b,"button-menu-action",l);var d=a.Nb(b);O(function(){d&&d.parentNode&&d.parentNode.removeChild(d);if(c.originalParentNode)c.parentNode.removeChild(c),c.originalParentNode.appendChild(c),c.originalParentNode=k,c.activeButtonNode=k},1)}var e=Sd(b,Z(a,"group"));w(b,Z(a,"active"));e&&w(e,Z(a,"group-active"));if(e=a.getData(b,"button-listener"))be(e),Jd(b,"button-listener");
if(e=a.getData(b,"button-context-menu-listener"))be(e),Jd(b,"button-context-menu-listener")}};Ch.prototype.getContent=function(a){return G(Z(this,"content"),a)};var Kh=function(a,b){return Sd(b.activeButtonNode||b.parentNode,Z(a))};
Ch.prototype.zi=function(a,b){var c=he(b),d=Sd(c,Z(this));if(d){var d=Dh(this,d),e=Dh(this,a);if(d==e)return}if(!Sd(c,Z(this,"menu"))||z(c,Z(this,"menu-item"))||z(c,Z(this,"menu-close")))if(Hh(this,a),(d=Sd(c,Z(this,"menu")))&&this.getData(a,"button-menu-indicate-selected"))e=G(Z(this,"content"),a),Fc(e,Lc(c)),e=Z(this,"menu-item-selected"),(d=G(e,d))&&w(d,e),v(c.parentNode,e)};
var Dh=function(a,b){if(!b.widgetMenu){var c=a.getData(b,"button-menu-id"),c=c&&C(c),d=Z(a,"menu");c?v(c,d):c=G(d,b);b.widgetMenu=c}return b.widgetMenu};var Mh=function(){this.N={}};t(Mh,zh);ba(Mh);Mh.prototype.T="char-counter";Mh.prototype.X=function(){this.addBehavior("keydown",this.le,"input");this.addBehavior("paste",this.le,"input");this.addBehavior("cut",this.le,"input")};
Mh.prototype.le=function(a){var b=Ah(this,a);if(b){var c="true"==this.getData(b,"count-char-by-size"),d=parseInt(this.getData(b,"char-limit"),10);isNaN(d)||0>=d||O(r(function(){var e=parseInt(a.getAttribute("maxlength"),10);if(!isNaN(e)){var f=Nh(a,c);if(c){if(f>e){var g=a.value,m=g.length,p=0,e=f-e,f="",x=0;do f+=g[m-p],x=unescape(encodeURIComponent(f)).length,p++;while(x<e);a.value=a.value.substring(0,m-p)}}else if(f>e)a.value=a.value.substring(0,e)}g=parseInt(this.getData(b,"warn-at-chars-remaining"),
10);isNaN(g)&&(g=0);m=d-Nh(a,c);A(b,Z(this,"maxed-out"),m<g);G(Z(this,"remaining"),b).innerHTML=m},this),0)}};var Nh=function(a,b){var c=a.value;return b?unescape(encodeURIComponent(c)).length:c.length};var Oh=function(){this.N={}};t(Oh,zh);Oh.prototype.de=function(){return this.ce&&0==bc.indexOf("6")?l:j};Oh.prototype.show=function(a){var b=Ah(this,a);if(b){v(b,Z(this,"active"));var c=Ph(this,a,b);if(c){c.cardTargetNode=a;c.cardRootNode=b;Qh(this,a,c);var d=Z(this,"card-visible");O(function(){T(c);v(c,d)},10);this.ta(b,"card-action",a)}}};
var Ph=function(a,b,c){var d=Z(a,"card"),e=d+Nd(c),f=C(e);if(f)return f;c=a.vb(c);if(!c)return k;f=document.createElement("div");f.id=e;f.className=d;d=document.createElement("div");d.className=Z(a,"card-border");b=a.getData(b,"orientation")||"horizontal";e=document.createElement("div");e.className="yt-uix-card-border-arrow yt-uix-card-border-arrow-"+b;var g=document.createElement("div");g.className=Z(a,"card-body");a=document.createElement("div");a.className="yt-uix-card-body-arrow yt-uix-card-body-arrow-"+
b;Ac(c);g.appendChild(c);d.appendChild(a);d.appendChild(g);f.appendChild(e);f.appendChild(d);document.body.appendChild(f);return f},Qh=function(a,b,c){var d=a.getData(b,"orientation")||"horizontal",e=a.getData(b,"position"),f=!!a.getData(b,"force-position"),d="horizontal"==d,g="bottomright"==e||"bottomleft"==e,e="topright"==e||"bottomright"==e,m,p;e&&g?(p=7,m=4):e&&!g?(p=6,m=5):!e&&g?(p=5,m=6):(p=4,m=7);var x=Ze(document.body),D=Ze(b);x!=D&&(p^=2);var H;d?(D=b.offsetHeight/2-24,H=new sb(-12,b.offsetHeight+
6)):(D=b.offsetWidth/2-12,H=new sb(b.offsetWidth+6,-12));var M=k;f||(M=10);var oa=Z(a,"card-flip"),a=Z(a,"card-reverse");A(c,oa,e);A(c,a,g);M=Bh(b,p,c,m,H,k,M);!f&&M&&(M&48&&(e=!e,p^=2,m^=2),M&192&&(g=!g,p^=1,m^=1),A(c,oa,e),A(c,a,g),Bh(b,p,c,m,H));b=G("yt-uix-card-body-arrow",c);f=G("yt-uix-card-border-arrow",c);c=cf(c);D=Math.max(6,Math.min(D,(d?c.height:c.width)-24-6));c=d?g?"top":"bottom":!x&&e||x&&!e?"left":"right";b.setAttribute("style","");f.setAttribute("style","");b.style[c]=D+"px";f.style[c]=
D+"px"};Oh.prototype.ja=function(a){var b=Ah(this,a);if(b&&(a=Ph(this,a,b)))w(b,Z(this,"active")),w(a,Z(this,"card-visible")),U(a),a.cardTargetNode=k,a.cardRootNode=k};var Rh=function(a,b){var c=Ah(a,b);return!c?l:z(c,Z(a,"active"))};Oh.prototype.vb=function(a){var b=a.cardContentNode;if(!b){var c=Z(this,"content"),d=Z(this,"card-content"),b=G(c,a);y(b,c,d);a.cardContentNode=b}return b};Oh.prototype.Jf={Pi:200,bj:200};var Sh=function(){this.N={}};t(Sh,Oh);ba(Sh);Sh.prototype.T="clickcard";Sh.prototype.X=function(){this.addBehavior("click",this.hj,"target");this.addBehavior("click",this.gj,"close")};Sh.prototype.hj=function(a){var b=Ah(this,a);z(b,Z(this,"active"))?(this.ja(a),w(b,Z(this,"active"))):(this.show(a),v(b,Z(this,"active")))};Sh.prototype.gj=function(a){(a=Sd(a,Z(this,"card")))&&this.ja(a.cardTargetNode)};var Th=function(){this.N={}};t(Th,zh);ba(Th);Th.prototype.T="expander";Th.prototype.X=function(){this.addBehavior("click",this.Oa,"head");this.addBehavior("keypress",this.ae,"head")};Th.prototype.Oa=function(a){Uh(this,a)};Th.prototype.ae=function(a,b,c){c&&13==c.keyCode&&Uh(this,a)};var Uh=function(a,b){var c=Ah(a,b);c&&(rb(c,Z(a,"collapsed")),a.ta(c,"expander-action"))};Th.prototype.collapse=function(a){if(a=Ah(this,a))v(a,Z(this,"collapsed")),this.ta(a,"expander-action")};
Th.prototype.expand=function(a){if(a=Ah(this,a))w(a,Z(this,"collapsed")),this.ta(a,"expander-action")};Th.prototype.Ka=function(a){return G(Z(this,"body"),a)};var Vh=function(){this.N={}};t(Vh,zh);ba(Vh);n=Vh.prototype;n.T="form-input";n.X=function(){B&&!dc(9)&&(this.addBehavior("click",this.Qf,"checkbox"),this.addBehavior("keypressed",this.Qf,"checkbox"),this.addBehavior("click",this.Rf,"radio"),this.addBehavior("keypressed",this.Rf,"radio"));this.addBehavior("keyup",this.ge,"text");this.addBehavior("keyup",this.ge,"textarea");this.addBehavior("keyup",this.ge,"bidi")};n.Qf=function(a){var b=I(a,k,Z(this,"checkbox-container"));A(b,"checked",a.checked)};
n.Rf=function(){var a=F(Z(this,"radio")),b=Z(this,"radio-container");u(a,function(a){var d=I(a,k,b);d&&A(d,"checked",a.checked)})};n.ge=function(a){var b=a.value,c="";gd(b)?c="rtl":ed.test(b)&&(c="ltr");a.dir=c};var Wh=function(){this.N={}};t(Wh,Oh);ba(Wh);n=Wh.prototype;n.T="hovercard";n.X=function(){this.addBehavior("mouseover",this.Zi,"target",5,j);this.addBehavior("mouseout",this.Xi,"target",5,j);this.addBehavior("mouseover",this.$i,"card",100);this.addBehavior("mouseout",this.Yi,"card",100)};
n.Zi=function(a){if(Xh!=a){Xh&&(this.ja(Xh),Xh=k);var b=r(this.show,this,a),c=parseInt(this.getData(a,"delay-show"),10),b=O(b,-1<c?c:this.Jf.Pi);this.setData(a,"card-timer",b.toString());Xh=a;if(a.alt)this.setData(a,"card-alt",a.alt),a.alt="";if(a.title)this.setData(a,"card-title",a.title),a.title=""}};
n.Xi=function(a){var b=parseInt(this.getData(a,"card-timer"),10);Dd(b);Ah(this,a).isCardHidable=j;b=parseInt(this.getData(a,"delay-hide"),10);b=-1<b?b:this.Jf.bj;O(r(this.dj,this,a),b);if(b=this.getData(a,"card-alt"))a.alt=b;if(b=this.getData(a,"card-title"))a.title=b};n.dj=function(a){Ah(this,a).isCardHidable&&(this.ja(a),Xh=k)};n.$i=function(a){a&&(a.cardRootNode.isCardHidable=l)};n.Yi=function(a,b,c){if(a)b=a.cardTargetNode,Ec(a,c.relatedTarget)||this.ja(b)};var Xh=k;var Yh=function(){this.N={}};t(Yh,zh);ba(Yh);n=Yh.prototype;n.T="overlay";n.X=function(){this.addBehavior("click",this.Tf,"target");this.addBehavior("click",this.yc,"close")};
n.Tf=function(a){if(a=Ah(this,a)){var b=Z(this,"fg"),c=C(b);if(!c){var d=this.vb(a);if(d){c=document.createElement("div");c.id=b;c.className=b;b=this.getData(a,"overlay-class")||"";v(c,b);var e=document.createElement("div");e.className=Z(this,"fg-content");var b=document.createElement("div"),f=Z(this,"base");b.id=f;v(b,f);var g=Z(this,"bg"),f=document.createElement("div");f.id=g;f.className=g;f.style.height=qc()+"px";g=document.createElement("span");v(g,Z(this,"align"));b.appendChild(g);e.innerHTML=
d.innerHTML;d=E("iframe",k,e);u(d,function(a){var b=this.getData(a,"onload");if(b)(b=q(b))&&S(a,"load",b),a.src=this.getData(a,"src")||a.src},this);c.appendChild(e);d=document.getElementsByTagName("embed");e=document.getElementsByTagName("object");g=r(function(a){var b=a.style.visibility;if("hidden"!=b)this.setData(a,"overlay-hidden","true"),b&&this.setData(a,"overlay-visibility-value",b),a.style.visibility="hidden"},this);u(d,g);u(e,g);b.appendChild(c);document.body.appendChild(f);document.body.appendChild(b);
this.getData(a,"disable-shortcuts")||(c=r(function(a){z(a.target,Z(this,"base"))&&this.yc()},this),S(b,"click",c),S(document,"keydown",r(this.vc,this)));this.ta(a,"overlay-shown")}}}};
n.yc=function(){var a=Z(this,"bg"),b=C(Z(this,"fg"));if(b){if(z(b,Z(this,"unclosable")))return;U(b);document.body.removeChild(b.parentNode)}(a=C(a))&&document.body.removeChild(a);var a=document.getElementsByTagName("embed"),b=document.getElementsByTagName("object"),c=r(function(a){if(this.getData(a,"overlay-hidden")){Jd(a,"overlay-hidden");var b=this.getData(a,"overlay-visibility-value");a.style.visibility=b?b:k}},this);u(a,c);u(b,c);ge(document,"keydown",r(this.vc,this))};
n.vc=function(a){27==a.keyCode&&this.yc()};n.vb=function(a){return G(Z(this,"content"),a)};n.ja=function(){this.yc()};n.show=function(a){this.Tf(a)};var Zh=function(){this.N={}};t(Zh,zh);ba(Zh);Zh.prototype.T="redirect-link";Zh.prototype.X=function(){this.addBehavior("click",this.Oa)};Zh.prototype.Oa=function(a){if(!R(a,"redirect-href-updated")){Q(a,"redirect-href-updated","true");var b=N("XSRF_REDIRECT_TOKEN"),c=N("XSRF_FIELD_NAME");if(b&&c){var d={};d.q=a.href;d[c]=b;a.href=ve("/redirect",d)}}};var $h=function(){this.N={}};t($h,zh);ba($h);n=$h.prototype;n.T="slider";n.X=function(){this.addBehavior("click",this.Ti,"num");this.addBehavior("click",this.Ui,"prev");this.addBehavior("click",this.Si,"next");this.addBehavior("mouseover",this.zc,"ajax-trigger")};n.Ti=function(a){if(a){var b=Ah(this,a),a=parseInt(this.getData(a,"slider-num"),10);if(isNaN(a)||0>a)a=0;this.Ac(b,a)}};
n.Si=function(a,b,c){if(a){a=Ah(this,a);if(z(a,Z(this,"fluid"))){if(a){var d=this.Ka(a),e=ai(this,bi(this,d)),f=0<e.length,b=parseInt(this.getData(a,"scroll-offset"),10);if(isNaN(b)||0<b)b=0;var g=d.offsetWidth;f?(d=ci(e),g=Math.floor(g/d),b=Math.abs(Math.floor(b/d))-1,di(this,a,(0<=b?b:0)+g)):(this.ce&&8>document.documentMode?Math.abs(b-g)<d.scrollWidth&&(b-=g):d.offsetWidth<d.scrollWidth&&(b-=g),ei(this,a,b))}}else if(a){b=parseInt(this.getData(a,"slider-current"),10);if(isNaN(b)||0>b)b=0;g=parseInt(this.getData(a,
"slider-slides"),10);if(isNaN(g)||0>g)g=0;b=Math.min(b+1,g-1);this.Ac(a,b)}c.preventDefault()}};
n.Ui=function(a,b,c){if(a){a=Ah(this,a);if(z(a,Z(this,"fluid"))){if(a){var d=this.Ka(a),e=ai(this,bi(this,d)),f=0<e.length,b=parseInt(this.getData(a,"scroll-offset"),10);if(isNaN(b)||0<b)b=0;d=d.offsetWidth;f?(e=ci(e),f=Math.floor(d/e),b=Math.abs(Math.floor(b/e))-1,di(this,a,(0<=b?b:0)-f)):(b+=d,0<b&&(b=0),ei(this,a,b))}}else if(a){b=parseInt(this.getData(a,"slider-current"),10);if(isNaN(b)||0>b)b=0;b=Math.max(b-1,0);this.Ac(a,b)}c.preventDefault()}};
n.zc=function(a){if(a=Ah(this,a)){var b=Z(this,"ajax-trigger"),c=F(b,a);u(c,function(a){w(a,b)});fi(this,a)}};var fi=function(a,b,c){var d=a.getData(b,"slider-ajax-url");d&&!a.getData(b,"slider-loaded")&&(a.setData(b,"slider-loaded","true"),V(d,{n:a,c:function(a,d){var g=xc(d.slides_html),m=G(Z(this,"slides"),b);m&&g&&yc(m,g);c&&c()}}))};$h.prototype.Ac=function(a,b){a&&(this.getData(a,"slider-ajax-url")&&!this.getData(a,"slider-loaded")?fi(this,a,r(this.Ac,this,a,b)):gi(this,a,b))};
var gi=function(a,b,c){var d=E(k,Z(a,"num"),b),e=Z(a,"num-current"),f;u(d,function(a){f=this.getData(a,"slider-num")==c;A(a,e,f);A(a,"yt-uix-pager-selected",f);z(a,"yt-uix-button")&&A(a,"yt-uix-button-toggled",f)},a);if(d=G(Z(a,"slides"),b)){var g=bi(a,d);if(g){var m=-1*c*g.offsetWidth+"px";Ze(g)?d.style.right=m:d.style.left=m}}if(d=G("yt-uix-pager-current-page",b))d.innerHTML=c+1;a.setData(b,"slider-current",c+"");hi(a,b)},hi=function(a,b){if(b){var c=parseInt(a.getData(b,"slider-current"),10),d=
parseInt(a.getData(b,"slider-slides"),10),e=F(Z(a,"next"),b),f=F(Z(a,"prev"),b);u(e,function(a){a.disabled=l});u(f,function(a){a.disabled=l});0==c&&u(f,function(a){a.disabled=j});c==d-1&&u(e,function(a){a.disabled=j})}},di=function(a,b,c){if(b){var d=a.Ka(b),e=ai(a,bi(a,d));if(!(0>=e.length)){c>=e.length&&(c=e.length-1);var f=parseInt(a.getData(b,"scroll-offset"),10);if(isNaN(f)||0<f)f=0;var d=d.offsetWidth,g=ci(e),f=Math.abs(Math.floor(f/g))-1;if(c>(0<=f?f:0)){var f=Math.floor(d/g),m=e.length;c+
f>m&&(c=m-f+1)}0>c&&(c=0);c=e[c];f=Ze(b)?c.offsetLeft-d+g+10:-1*(c.offsetLeft-10);ei(a,b,f)}}},ei=function(a,b,c){if(b){isNaN(c)&&(c=0);var d=a.Ka(b),e=bi(a,d),f=E(k,Z(a,"title"),e),g=z(b,Z(a,"scroll")),m=Ze(b);if(g)d.scrollLeft=m?Pb?c:d.scrollWidth-d.offsetWidth+c:-c;else{var p=m?"right":"left";e.style[p]=c+"px";u(f,function(a){a.style[p]=-1*c+"px"})}a.setData(b,"scroll-offset",c+"")}};$h.prototype.Ka=function(a){return G(Z(this,"body"),a)};
var bi=function(a,b){return G(Z(a,"slide"),b)},ai=function(a,b){return E(k,Z(a,"slide-unit"),b)},ci=function(a){if(0==a.length)return 0;var b=a[0],c=b.offsetWidth;1<a.length&&(a=a[1],c=Ze(b)?b.offsetLeft-a.offsetLeft:a.offsetLeft-b.offsetLeft);return c},ii=function(a,b){var c=a.Ka(b),d=ai(a,bi(a,c));if(!d.length)return[];var e=parseInt(a.getData(b,"scroll-offset"),10);if(isNaN(e)||0<e)e=0;var f=c.offsetWidth,g=ci(d),c=Math.floor(-e/g),c=Math.max(0,c),e=Math.ceil((-e+f)/g),e=Math.min(e,d.length);return ib(gb(d),
c,e)};var ji=function(){this.N={}};t(ji,zh);ba(ji);ji.prototype.T="tile";ji.prototype.X=function(){this.addBehavior("click",this.Oa)};ji.prototype.Oa=function(a,b,c){!I(c.target,"a")&&!I(c.target,"button")&&(a=G(Z(this,"link"),a))&&(B&&!dc(9)?a.click():dh(a.href))};var ki=function(){this.N={}};t(ki,zh);ba(ki);n=ki.prototype;n.T="tooltip";n.Dc=0;n.X=function(){this.addBehavior("mouseover",this.zc);this.addBehavior("mouseout",this.Yd);this.addBehavior("click",this.Yd);this.addBehavior("touchstart",this.Ri);this.addBehavior("touchend",this.Mf);this.addBehavior("touchcancel",this.Mf)};n.de=function(){return!(this.ce&&0==bc.indexOf("6"))};
n.zc=function(a){if(!(this.Dc&&1E3>na()-this.Dc)){var b=parseInt(this.getData(a,"tooltip-hide-timer"),10);b&&(Jd(a,"tooltip-hide-timer"),Dd(b));var b=r(function(){li(this,a);Jd(a,"tooltip-show-timer")},this),c=parseInt(this.getData(a,"tooltip-show-delay"),10)||0,b=O(b,c);this.setData(a,"tooltip-show-timer",b.toString());if(a.title)this.setData(a,"tooltip-text",a.title),a.title=""}};
n.Yd=function(a){var b=parseInt(this.getData(a,"tooltip-show-timer"),10);Dd(b);Jd(a,"tooltip-show-timer");b=r(function(){mi(this,a);Jd(a,"tooltip-hide-timer")},this);b=O(b,50);this.setData(a,"tooltip-hide-timer",b.toString());if(b=this.getData(a,"tooltip-text"))a.title=b};n.Ri=function(a,b,c){this.Dc=0;this.zc(vh(Z(this),c.changedTouches[0].target,uh(b,Z(this))),b)};n.Mf=function(a,b,c){this.Dc=na();this.Yd(vh(Z(this),c.changedTouches[0].target,uh(b,Z(this))))};
var ni=function(a,b,c,d){a.setData(b,"tooltip-text",c);var e=a.getData(b,"content-id");if(e=C(e))e.innerHTML=c,d&&mi(a,b)};ki.prototype.fc=function(a){return this.getData(a,"tooltip-text")||a.title};
var li=function(a,b){if(b){var c=a.fc(b);if(c){var d=C(oi(a,b));if(!d){d=document.createElement("div");d.id=oi(a,b);d.className=Z(a,"tip");var e=document.createElement("div");e.className=Z(a,"tip-body");var f=document.createElement("div");f.className=Z(a,"tip-arrow");var g=document.createElement("div");g.className=Z(a,"tip-content");var m=a.Nb(b),p=oi(a,b,"content");g.id=p;a.setData(b,"content-id",p);e.appendChild(g);m&&d.appendChild(m);d.appendChild(e);d.appendChild(f);document.body.appendChild(d);
ni(a,b,c);c=z(b,Z(a,"reverse"));pi(a,b,d,e,m,f,5,c)&2&&pi(a,b,d,e,m,f,1,!c);var x=Z(a,"tip-visible");O(function(){v(d,x)},0)}}}},pi=function(a,b,c,d,e,f,g,m){A(c,Z(a,"tip-reverse"),m);var p=0,x=1;m&&(p=1,x=0);m=cf(d);d.style.left="3px";if(e)e.style.left="3px",e.style.height=m.height+"px",e.style.width=m.width+"px";m.width+=6;d=b.offsetWidth/2;g=Bh(b,p,c,x,new sb(d-m.width/2,0),k,g,m);e=df(c);p=df(b);x=p.left-e.left+d-5;m=m.width-10-6;a=a.getData(b,"force-tooltip-direction");x="left"==a?m:"right"==
a?6:Math.max(Math.min(x,m),6);f.style.left=x+"px";f=e.left+x+5;a=p.left;b=p.left+p.width;if(f>b)c.style.left=b-x+"px";else if(f<a)c.style.left=a-x+"px";return g},mi=function(a,b){if(b){var c=C(oi(a,b));c&&(qi(c),document.body.removeChild(c),Jd(b,"content-id"))}},oi=function(a,b,c){a=Z(a)+Nd(b);c&&(a+="-"+c);return a};
ki.prototype.Nb=function(a){var b=k;if(Jb&&z(a,Z(this,"masked")))(b=C("yt-uix-tooltip-shared-mask"))?(b.parentNode.removeChild(b),T(b)):(b=document.createElement("iframe"),b.src='javascript:""',b.id="yt-uix-tooltip-shared-mask",b.className=Z(this,"tip-mask"));return b};var qi=function(a){var b=C("yt-uix-tooltip-shared-mask"),c=b&&Nc(b,function(b){return b==a},l,2);b&&c&&(b.parentNode.removeChild(b),U(b),document.body.appendChild(b))};var ri=0,si=0,ti=0,ui=0,vi=l,wi=function(){var a=pc(window);return rc(document).y+a.height+si},yi=function(){var a=wi(),b=ti;ui=a;var c=Math.abs(b-a);if(!b||400<=c){c=xi(a);for(b=xi(b);b<c;)$g("thumb-group-"+c),c--;ti=a}},zi=function(){for(var a=xi(ui);0<=a;a--)$g("thumb-group-"+a)},Bi=function(a){Ai(function(a,c){var d=R(a,"group-key");d&&(Zg(a,d),Jd(a,"group-key"));a.src=c},a)},Ci=function(a,b){vi&&Ai(function(a,d){var e=R(a,"group-key");if(!(R(a,"thumb-manual")||e&&!b)){e&&Zg(a,e);if(e=C(a)){var f=
0,g=0;if(e.offsetParent){do f+=e.offsetLeft,g+=e.offsetTop;while(e=e.offsetParent)}e=new sb(f,g)}else e=k;e="thumb-group-"+xi(e.y);Yg(a,d,e);Q(a,"group-key",e)}},a)},Ai=function(a,b){var c=E("img",k,b);u(c,function(b){var c=R(b,"thumb");c&&a.call(o,b,c)})},xi=function(a){return Math.ceil(Math.max(0,a-ri)/400)};var Di=function(a,b,c){this.Li=b;this.Ni=c;this.Oi="ad_creative_"+a;this.Mi="ad_creative_expand_btn_"+a;this.Ki="ad_creative_collapse_btn_"+a};Di.prototype.collapse=function(){U(this.Oi);Ci(C("page"),j);zi();this.Ni||U(this.Ki);T(this.Mi);var a=K.getInstance();a.set("HIDDEN_MASTHEAD_ID",this.Li);a.save();jh("homepage_collapse_masthead_ad",i,i)};Di.prototype.expand=function(){var a=K.getInstance();a.set("HIDDEN_MASTHEAD_ID",l);a.save();jh("homepage_expand_masthead_ad",i,i);dh(document.location.href)};var Ei=function(a,b){var c;try{c="number"==typeof a.selectionStart}catch(d){c=l}if(c)a.selectionStart=b,a.selectionEnd=b;else if(B){c=b;if("textarea"==a.type)c=a.value.substring(0,c).replace(/(\r\n|\r|\n)/g,"\n").length;b=c;c=a.createTextRange();c.collapse(j);c.move("character",b);c.select()}};var Fi=function(a){var b;switch(a){case "PENDING":b=P("COMMENT_PENDING");break;case "BLOCKED":b=P("COMMENT_BLOCKED");break;case "EMAIL":b=P("COMMENT_ERROR_EMAIL");break;case "INLINE_CAPTCHAFAIL":b=P("COMMENT_CAPTCHAFAIL")}return b||k},Gi=function(a,b){this.i=a;this.Wa=Td("button",k,a);this.$=Td("textarea",k,a);this.Ca=k;this.xd=G("comments-remaining-count",this.i);this.rh=parseInt(this.xd.innerHTML,10);this.Xa=G("comments-post-message",this.i);this.te=G("yt-alert-content",this.Xa);S(this.$,"focus",
r(this.Pe,this));S(this.$,"blur",r(this.sh,this));S(this.i,"submit",r(this.cd,this));var c=r(this.th,this);S(this.$,"change",c);S(this.$,"keyup",c);b&&this.Pe()};Gi.prototype.reset=function(){Hi(this);this.$.blur();w(this.i,"has-focus");this.Wa.disabled=l;this.setValue("")};Gi.prototype.focus=function(){this.$.focus()};Gi.prototype.setValue=function(a){this.$.value=a;Ei(this.$,a.length);Ii(this)};
var Hi=function(a){if(a.Ca)a.Ca.innerHTML=""},Ii=function(a){var b=a.rh-a.$.value.length;a.xd.innerHTML=b+"";b=0>b;A(a.xd,"too-many",b);a.Wa.disabled=b};Gi.prototype.th=function(){Ii(this)};Gi.prototype.Pe=function(){z(this.i,"has-focus")||U(this.Xa);v(this.i,"has-focus");zf("comments-focus",this.i)};Gi.prototype.sh=function(){zf("comments-blur",this.i)};
Gi.prototype.cd=function(a){a.preventDefault();if(!this.Wa.disabled){this.Wa.disabled=j;a=we($c(this.i));a.screen=te({h:window.screen.height,w:window.screen.width,d:window.screen.colorDepth});var b=a.comment,b={return_ajax:"true",len:b.length,wc:b.split(/\s+/).length};this.i.reply_parent_id.value&&(b.reply=1);V(this.i.action,{format:"XML",method:"POST",g:b,j:a,fa:function(a,b){var e=b.str_code;switch(e){case "OK":e=document.createElement("ul");e.innerHTML=b.html_content;e=Dc(e);if(this.i.reply_parent_id.value){var f=
I(this.i,k,"comments-post-container"),g=I(f,k,"comment");Ac(f);y(g,"replying","has-child");v(e,"child");A(e,"last",!(g.nextElementSibling!=i?g.nextElementSibling:Cc(g.nextSibling)));g.parentNode&&g.parentNode.insertBefore(e,g.nextSibling)}else f=I(this.i,k,"comments-section"),f=G("comment-list",f),f.insertBefore(e,f.childNodes[0]||k),this.reset();Bi(e);break;case "PENDING":Hi(this);this.te.innerHTML=P("COMMENT_PENDING");y(this.Xa,"yt-alert-error","yt-alert-info");T(this.Xa);break;default:Ji(this,
e)}},n:this})}};
var Ji=function(a,b){a.te.innerHTML=Fi(b)||P("COMMENT_ERROR");y(a.Xa,"yt-alert-info","yt-alert-error");T(a.Xa);switch(b){case "INLINE_CAPTCHA":case "INLINE_CAPTCHAFAIL":V("/comment_servlet?gimme_captcha=1",{format:"XML",method:"POST",j:{session_token:Vg.comment_servlet},c:function(a,b){if(!this.Ca){this.Ca=document.createElement("div");this.Ca.className="comment-captcha";var e=this.$;e.parentNode&&e.parentNode.insertBefore(this.Ca,e.nextSibling)}this.Ca.innerHTML=b.html_content;this.Wa.disabled=l},
n:a});break;default:a.Wa.disabled=l,Hi(a)}};var Ri=function(a){var b=a.currentTarget,a=I(b,k,"comment");switch(R(b,"action")){case "approve":Ki(a);break;case "block":confirm(P("BLOCK_USER"))&&(Li(a,j),v(a,"blocked"));break;case "unblock":Li(a,l);w(a,"blocked");break;case "flag":Mi(a);break;case "unflag":a=R(a,"id");V("/comment_servlet",{format:"XML",method:"POST",j:{unmark_comment_as_spam:a,entity_id:N("VIDEO_ID"),session_token:Vg.comment_servlet}});break;case "hide":v(a,"hidden");break;case "show":w(a,"hidden");break;case "remove":Ni(a);break;
case "reply":if(Oi()&&!z(a,"replying")){v(a,"replying");var b=G("comments-post",C("comments-view")),b=Qd(b),c=document.createElement("div");c.className="comments-post-container";a.appendChild(c);c.appendChild(b);b=new Gi(b);b.reset();c=R(a,"author");a=R(a,"id");b.setValue("@"+c+" ");b.i.reply_parent_id.value=a;b.focus()}break;case "share":Pi(a);break;case "vote-up":Qi(a,j);break;case "vote-down":Qi(a,l)}},Oi=function(){return N("COMMENTS_SIGNIN_URL")?(dh(N("COMMENTS_SIGNIN_URL")),l):!N("COMMENTS_YPC_CAN_POST_OR_REACT_TO_COMMENT")?
l:j},Ki=function(a){var b=R(a,"id"),c=N("VIDEO_ID");w(a,"pending");V("/comment_servlet?field_approve_comment=1",{format:"XML",method:"POST",j:{comment_id:b,entity_id:c,session_token:Vg.comment_servlet},$e:function(){v(a,"pending")}})},Li=function(a,b){var c={};c[(b?"":"un")+"block_user"]=1;var d=R(a,"author");V("/link_servlet",{format:"XML",method:"POST",g:c,j:{session_token:Vg.link_servlet,friend_username:d}})},Mi=function(a){if(Oi()){var b=R(a,"id"),c=N("VIDEO_ID");U(a);v(a,"flagged");V("/comment_servlet",
{format:"XML",method:"POST",g:{mark_comment_as_spam:b,entity_id:c},j:{session_token:Vg.comment_servlet},$e:function(){T(a);w(a,"flagged")}})}},Ni=function(a){var b=R(a,"id"),c=N("VIDEO_ID");U(a);V("/comment_servlet?remove_comment=1",{format:"XML",method:"POST",j:{comment_id:b,entity_id:c,session_token:Vg.comment_servlet},$e:function(){T(a)}})},Pi=function(a){if(!z(a,"sharing")){v(a,"sharing");var b=Qd(C("watch-comment-share-area")),c=document.createElement("div");c.className="comments-post-container";
a.appendChild(c);c.appendChild(b);var d=R(a,"id"),c=N("COMMENT_SHARE_URL"),c=c.replace("_COMMENT_ID_",d);G("watch-comment-share-url",b).value=c;var a=G("comment-text",a),e=Ia(Lc(Dc(a))),a=F("icon-watch-comment-share",b);u(a,function(a){var b=a.getAttribute("action"),b=b.replace("_COMMENT_ID_",d),c;c=-1!=b.indexOf("twitter")?Fa(e,80):Fa(e,150);b=b.replace("_COMMENT_TEXT_",c);S(a,"click",r(function(a){eval(a)},o,b))});T(b)}},Qi=function(a,b){if(Oi()&&!R(a,"voted")){var c=R(a,"id"),d=N("VIDEO_ID"),e=
R(a,"score"),f=b?1:-1;Q(a,"voted",f+"");b?y(a,"voted-down","voted-up"):y(a,"voted-up","voted-down");c={a:f,id:c,video_id:d,old_vote:e};(d=R(a,"tag"))&&(c.tag=d);V("/comment_voting",{format:"XML",method:"POST",g:c,j:{session_token:Vg.comment_voting}})}};var Ti=function(){Si("convUnsubscribeUrl")},Si=function(a){var b=N("CONVERSION_URLS_DICT");b&&a in b&&hh(b[a])};var Ui=new wf,Vi=k,Wi=k,Xi=function(){return N("COMMENTS_SIGNIN_URL")?(dh(N("COMMENTS_SIGNIN_URL")),l):j},Zi=function(a){var b=I(a,"FORM");if(b){var c=z(b,"comments-reply-form"),d=z(b,"input-expanded");v(b,"input-focused");w(b,"input-collapsed");v(b,"input-expanded");if(!c){T("comments-attach-video");if(!d)a.value="";(b=I(a,"div","comments-section"))&&v(b,"comment-input-focused")}}S(a,"input",Yi);S(a,"propertychange",Yi)},Yi=function(a){$i(a.target)},$i=function(a){var b=a.parentNode,a=G("comments-post-count-textbox",
b),c=G("comments-post-count",b),d=G("comments-textarea",b),b=G("watch-comments-post",b),d=500-d.value.length;a.value=Math.max(d,0);0>d?(b.disabled=j,v(c,"error")):(b.disabled=l,w(c,"error"))},aj=function(a){for(var b=N("COMMENTS_PAGE_SIZE"),c=F("comment",a).length;c-- >=b;)a.removeChild(a.lastChild)},ej=function(a){T("comments-loading");var b=C("comments-view"),c=N("VIDEO_ID"),d=N("COMMENTS_THRESHHOLD"),e=N("COMMENTS_FILTER"),f=N("COMMENTS_PAGE_SIZE"),g=N("ENABLE_LIVE_COMMENTS"),m=N("COMMENT_SOURCE");
Q(b,"type","everything");c=bj(c,a,d,e,f,m,g);W(c,{method:"GET",onComplete:function(c){if(c=Ug(c.responseXML,"html_content")){var d=cj();d&&(Ac(d),document.body.appendChild(d));b.innerHTML=c;Bi(b);c=G("comment-list",b);d=G("live-comments-setting",b);c&&Ui.Pb("live-comments-page-changed",c,d,a)}U("comments-loading");dj()}})},bj=function(a,b,c,d,e,f,g){return ve("/watch_ajax",{v:a,action_get_comments:1,p:b,commentthreshold:c,commentfilter:d,commenttype:"everything",enable_live_comments:g?"yes":k,page_size:e,
source:f})},cj=function(){Wi||(Wi=C("comments-actions"));return Wi},fj=function(a){dj();Vi=a;var b=cj();b&&(b.parentNode&&Ac(b),G("comment-container",a).appendChild(b))},dj=function(){var a=cj(),b=Ch.getInstance(),a=E("button","yt-uix-button",a);u(a,function(a){Hh(b,a)})},gj=function(a,b){if(confirm(P(b?"BLOCK_USER":"UNBLOCK_USER")))W("/link_servlet",{postBody:(b?"":"un")+"block_user=1&"+N("BLOCK_USER_XSRF")+"&friend_username="+a})},hj=function(){var a=C("captcha_div");if(a){var b=a.parentNode;b.removeChild(a);
T(b.comment)}},ij=function(a){var b=cj(),c=a.currentTarget,a=Nc(a.relatedTarget,function(a){return a==c||a==b},j,6);c&&!a&&fj(c)},jj=function(a){a.preventDefault();var b=a.target,a=parseInt(b.getAttribute("data-children-missing"),10),c=I(b,"li"),d=I(b,"ul"),b=I(c.parentNode,"li").getAttribute("data-id");W("/comment_servlet?gimme_children=1",{postBody:"comment_id="+b+"&number_to_get="+a+"&video_id="+N("VIDEO_ID"),onComplete:function(a){Ac(c);a=Ug(a.responseXML,"html_content");d.innerHTML=a+d.innerHTML}})};var kj=l,lj=l;var nj=function(a,b,c){b||(b={});var d=l;"in"==b.fadeDirection&&(d=j);v(a,"yt-ani-fade yt-ani-fade-zero");var e=2E3;if(b.fadeDuration)e=b.fadeDuration,mj(a,e),e=1E3*parseFloat(e);d&&w(a,"yt-ani-fade-zero");if(!d)a.style.opacity=0;O(function(){w(a,"yt-ani-fade");c!=k&&c(a,b)},e)},mj=function(a,b){a.style.mozTransitionDuration=b;a.style.webkitTransitionDuration=b;a.style.oTransitionDuration=b};var oj=function(a,b,c,d,e){e=ue("/channel_recommendations_ajax","feature",e||"");W(e,{postBody:te({subrecdismiss:j,replacement_pub_id:b,dismissed_pub_id:a,module:"ALL",session_token:Vg.channel_recommendations_token,template:d}),onComplete:c||aa})};var pj,qj,sj=function(a,b){this.o=a;this.ac=b||k;this.Va=R(a,"subscription-type")||"user";this.Wc=R(a,"subscription-value")||"";this.Hh=!!R(a,"enable-tooltip");this.Zb=!!R(a,"enable-hovercard");this.Kl=Dc(a);this.ub=l;S(this.o,"click",r(this.Jh,this));yf("SUBSCRIBE",this.Ye,this);yf("SUBSCRIBE",this.ye,this);yf("UNSUBSCRIBE",this.Ye,this);this.Zb&&S(this.o,"mouseover",r(this.Kh,this));rj(this)},tj=function(a,b){var c=F("yt-subscription-button-js-default",a);u(c,function(a){R(a,"subscription-initialized")||
(new sj(a,b),Q(a,"subscription-initialized","true"))})};sj.prototype.getId=function(){return R(this.o,"subscription-id")||k};var uj=function(a,b){b?Q(a.o,"subscription-id",b):Jd(a.o,"subscription-id");rj(a)};sj.prototype.getValue=function(){return this.Wc};sj.prototype.getType=function(){return this.Va};
var rj=function(a){A(a.o,"subscribed",!!a.getId());var b=Z(Wh.getInstance(),"target");A(a.o,b,!!a.getId()&&a.Zb);a.Hh&&(b=(a.getId()?"un":"")+"subscribe-tooltip",b=R(a.o,b)||"",ni(ki.getInstance(),a.o,b))};sj.prototype.Ye=function(a,b,c){c!=this.getId()&&this.getValue()==a&&this.getType()==b&&uj(this,c)};sj.prototype.ye=function(){this.Zb&&Wh.getInstance().ja(this.o)};sj.prototype.Jh=function(){if(this.ub)return l;mi(ki.getInstance(),this.o);this.getId()?vj(this):wj(this)};
sj.prototype.Kh=function(){this.getId()&&O(r(function(){xj(this)},this),350)};
var xj=function(a){var b=Wh.getInstance();if(!a.ze&&Rh(b,a.o)){a.ze=j;var c={hovercard:1};c["action_get_subscription_form_for_"+a.Va]=1;var d={session_token:Vg.subscription_ajax};d[yj(a)]=a.Wc;V("/subscription_ajax",{method:"POST",g:c,j:d,n:a,c:function(a,c){var d=this.o,m=c.response.html_content,p=Ah(b,d);if(p){var x=b.vb(p);if(x)x.innerHTML=m,z(p,Z(b,"active"))&&(m=Ph(b,d,p),Qh(b,d,m))}zj(this)},l:function(){this.ze=l}})}},zj=function(a){var b=Wh.getInstance(),c=Ah(b,a.o),d=b.vb(c);u(d.getElementsByTagName("input"),
function(a){S(a,"change",r(function(){var a=d.getElementsByTagName("form")[0],b=a.action||document.location.href,c=a.method.toUpperCase()||"GET",a=$c(a);Qg(b,i,c,a,i)},this))},a)},wj=function(a){if(N("LOGGED_IN")){var b=yj(a),c={};c["action_create_subscription_to_"+a.Va]=1;var d=R(a.o,"subscription-feature");d&&(c.feature=d);d={session_token:Vg.subscription_ajax};d[b]=a.Wc;a.ub=j;a.o.disabled=j;V("/subscription_ajax",{method:"POST",n:a,g:c,j:d,c:function(a,b){uj(this,b.response.id);zf("SUBSCRIBE",
this.getValue(),this.getType(),this.getId());this.Zb&&(Wh.getInstance().show(this.o),xj(this));this.ac&&this.ac(this.o,j)},fa:function(){this.ub=l;this.o.disabled=l}});Si("convSubscribeUrl")}},vj=function(a){var b={s:a.getId(),session_token:Vg.subscription_ajax},c={action_remove_subscriptions:1},d=R(a.o,"subscription-feature");d&&(c.feature=d);a.ub=j;a.o.disabled=j;V("/subscription_ajax",{method:"POST",n:a,g:c,j:b,c:function(){uj(this,k);this.ye();zf("UNSUBSCRIBE",this.getValue(),this.getType(),k);
this.ac&&this.ac(this.o,l)},fa:function(){this.ub=l;this.o.disabled=l}});Ti()},yj=function(a){return"playlist"==a.Va?"p":"blog"==a.Va?"b":"topic"==a.Va?"l":"u"};var Aj=l,Bj=function(){zf("init");O(function(){a:if("www.youtube.com"===document.domain){for(var a=[],b=(document.cookie||"").split(/\s*;\s*/),c=0,d;d=b[c];c++)0==d.indexOf("PREF=")&&a.push(d.substr(5));for(b=0;b<a.length;b++)if(0==a[b].indexOf("ID=")){nd("PREF","/",".www.youtube.com");jh("bad_pref_cookie_removed",i,i);break a}}},500)},Cj=function(){zf("dispose")},Ej=function(a,b,c){var d=C("www-core-js");!Aj&&d&&-1!=d.src.indexOf("/debug-")&&(c=Dj(c),jh("jserror","error="+encodeURIComponent(a)+"&script="+
encodeURIComponent(b)+"&linenumber="+encodeURIComponent(c)+"&url="+encodeURIComponent(window.location.href),i),Aj=j)},Dj=function(a){if(Pb)try{eval("(0)()")}catch(b){return b.stack.replace(/(.*):/g,"").replace(/\n/g,",")}else return a};var $=function(a,b,c){this.Gi=[];this.Ya=a;this.Ol=b;this.Ge=c;yf("init",r(this.Hi,this))};s("yt.www.home.ModuleHelper",$);var Fj={uf:"ypp-invite-box",pf:"ypp-needs-adsense-box",wf:"ypp-needs-training-box",vf:"ypp-needs-signed-contract-box"};$.prototype.Hi=function(){this.Ge||Gj(this)};var Gj=function(a){u(a.Gi,function(){},a)};
$.prototype.Bl=function(a,b,c,d,e,f){var g=C("feeditem-"+a+"-show-more-videos-was-called");if(""==g.innerHTML){var m=aa;U("feeditem-"+a+"-show-more-videos");f?(T("feeditem-"+a+"-more-videos"),T("feeditem-"+a+"-show-less-videos"),m=r(function(){g.innerHTML="y"},this)):(T("feeditem-"+a+"-loading-msg"),m=r(function(b,c){C("feeditem-"+a+"-more-videos").innerHTML=c.html_content;g.innerHTML="y";T("feeditem-"+a+"-more-videos");T("feeditem-"+a+"-show-less-videos");U("feeditem-"+a+"-loading-msg")},this));
V("/index_ajax",{format:"XML",method:"POST",g:{show_more_videos:j},j:{module:"ALL",item_type:b,atype:c,feature:d,feedvids:e,session_token:this.Ya},c:m})}else T("feeditem-"+a+"-more-videos"),T("feeditem-"+a+"-show-less-videos"),U("feeditem-"+a+"-show-more-videos")};$.prototype.showMoreVideos=$.prototype.Bl;$.prototype.Al=function(a){U("feeditem-"+a+"-more-videos");U("feeditem-"+a+"-show-less-videos");T("feeditem-"+a+"-show-more-videos")};$.prototype.showLessVideos=$.prototype.Al;
$.prototype.Cl=function(a){lf("feeditem-"+a+"-contracted-bulletin");lf("feeditem-"+a+"-expanded-bulletin")};$.prototype.toggleExpandableBulletin=$.prototype.Cl;
$.prototype.Yk=function(a,b,c){if(a.parentNode)this.Ge?hf("feed-helptext",j):(E(k,"current",C("user-navbar"))[0].className="",a.parentNode.className="current",hf("feed-view-picker",l),hf("feed-view-loading-msg",j),V("/index_ajax",{format:"XML",method:"POST",g:{feedview:c},j:{alter:j,module:b,session_token:this.Ya},c:r(function(a,c){var f=C("feedmodule-"+b);f.innerHTML=c.html_content;if(N("HOMEPAGE_AJAX_RECOMMENDATIONS")){var g=C("homepage-side-content"),m=C("homepage-side-rec"),p=C("sidebar-recommendations");
p?(f.removeChild(p),v(g,"display-recommendation"),m.innerHTML=p.innerHTML):w(g,"display-recommendation")}tj()},this)}))};$.prototype.changeFeedFilter=$.prototype.Yk;
$.prototype.tl=function(a){U("feed-items-button");T("feed-items-loading");V("/index_ajax",{format:"XML",method:"POST",g:{feedmore:j},j:{module:"ALL",end_time:a,session_token:this.Ya},c:r(function(a,c){var d=C("feed-items-button-div");d&&Ac(d);d=F("feedmodule-body",C("ALL-data"));if(0<d.length&&d[0]){var d=d[0],e=xc(c.html_content);yc(d,e)}},this),l:r(function(){U("feed-items-loading");T("feed-items-button")},this)})};$.prototype.loadMoreFeedItems=$.prototype.tl;
$.prototype.bl=function(a,b){var c=C("feedvid-"+a+"-"+b);c&&Ac(c);V("/index_ajax",{method:"POST",g:{"delete":b},j:{xfeedvid:a,module:"ALL",item_type:b,session_token:this.Ya}})};$.prototype.deleteFeedVideo=$.prototype.bl;$.prototype.ul=function(a){var b=C("chan-recs");a?(v(b,"full"),V("/index_ajax",{method:"POST",g:{subrecsmore:j},j:{module:"ALL",session_token:this.Ya}})):w(b,"full")};$.prototype.moreSubscriptionRecommendations=$.prototype.ul;
$.prototype.fl=function(a){function b(a,b){mf()?nj(a,d,function(){Bc(b,a);nj(b,e);c()}):(Bc(b,a),c())}function c(){var a=C("personalized-sub-recs"),b=C("chan-recs"),c=F("channel-cell",b).length;if(0==c)Ac(a.parentNode.parentNode);else if(3==c)b.style.height=af(96,j),v(C("chan-recs-more-link"),"hid"),v(C("chan-recs-less-link"),"hid")}var d={fadeDuration:"1s"},e={fadeDirection:"in",fadeDuration:"1s"},f=C("channel-rec-"+a);if(f){var g=f.parentNode,m=C("chan-recs-more-link");if(12<g.childNodes.length||
12>=g.childNodes.length&&!z(m,"hid")){var p=g.lastChild.previousSibling;b(f,p)}else nj(f,d,function(){Ac(f);c()});p&&Ac(p.parentNode.lastChild);var x;if(g=C("remaining-chan-rec-ids"))if(m=g.innerHTML.split(","),m[0])x=m.shift(),g.innerHTML=m.join(",");oj(a,x,r(this.gl,this,C("chan-recs")),"homepage","dissmissRecHomepage")}};$.prototype.dismissSingleSubscriptionRecommendation=$.prototype.fl;
$.prototype.gl=function(a,b){if(a.responseText&&b){var c=xc(a.responseText);""!=Lc(c)&&b.appendChild(c);var c=F("channel-cell",b).length,d=C("chan-recs-more-link"),e=C("chan-recs-less-link");3<c&&z(d,"hid")&&z(e,"hid")&&w(d,"hid")}};$.prototype.il=function(){V("/index_ajax",{method:"POST",g:{subrecsclose:j},j:{module:"ALL",session_token:this.Ya}})};$.prototype.dismissSubscriptionRecommendations=$.prototype.il;
var Hj=function(a){var b=a.target;if(b)a=b.dataset?b.dataset.dismiss:b.getAttribute("data-"+(Na.dismiss||(Na.dismiss="dismiss".replace(/([A-Z])/g,"-$1").toLowerCase()))),b=I(b,k,"channel-recommendation"),a&&(oj(a,k,k,k,"hp-sidebar"),Ac(b))};$.prototype.wl=function(a,b){var c=I(a,k,"feedmodule-item-with-x");c&&Ac(c);V("/addto_ajax",{method:"POST",g:{action_delete_from_watch_later_list:1,feature:"hp"},j:{video_ids:b,session_token:Vg.addto_ajax}})};$.prototype.removeWatchLaterVideo=$.prototype.wl;
$.prototype.dl=function(a){var b=K.getInstance();a==Fj.uf?(b.Ha(L.qf,j),hf(Fj.uf,l)):a==Fj.pf?(b.Ha(L.rf,j),hf(Fj.pf,l)):a==Fj.wf?(b.Ha(L.sf,j),hf(Fj.wf,l)):a==Fj.vf&&(b.xf(L.tf,j),hf(Fj.vf,l));b.save()};$.prototype.disableYppPromo=$.prototype.dl;var Ij=function(a,b){this.wi=a;this.xi=b;this.ea=l;this.gb=k};s("yt.www.home.Subscriptions",Ij);Ij.prototype.zl=function(a){this.gb=a};Ij.prototype.setCurrentLink=Ij.prototype.zl;Ij.prototype.ml=function(a){if(this.gb&&!C("edit-subscription-bubble")&&!this.ea&&(a=E("A","edit-subscription-recent-activity-link",a),0!=a.length&&(a=a[0],this.gb!=a)))this.gb&&hf(this.gb,l),hf(a,j),this.gb=a};Ij.prototype.handleActivityItemMouseover=Ij.prototype.ml;
Ij.prototype.Dl=function(a,b,c,d){if(!this.ea){this.ea=j;var e=C("edit-subscription-bubble");e?(Ac(e),this.ea=l):W("/iyt_ajax?action_get_inline_subscription_edit_markup",{postBody:["publisher_id="+c,"publisher_username="+b,"session_token="+d].join("&"),onComplete:r(function(b){var b=Ug(b.responseXML,"html_content"),c=document.createElement("DIV");c.innerHTML=b;a.parentNode.parentNode.insertBefore(c.firstChild,a.parentNode.nextSibling);this.ea=l},this),onException:r(function(){this.ea=l},this)})}};
Ij.prototype.toggleInlineSubscriptionEditBubble=Ij.prototype.Dl;
Ij.prototype.pl=function(a,b,c){if(!this.ea){var d=C("edit-subscription-uploads-only").checked,e=C("edit-subscription-unsubscribe").checked,f="";C("edit-subscription-all-activity").checked?f="all_activity":d?f="uploads":e&&(f="unsubscribe");if(f)this.ea=j,W("/ajax_subscriptions?edit_subscription="+b+"&subscription_level="+f,{postBody:["username="+a,"session_token="+c].join("&"),onComplete:r(function(){Ac(C("edit-subscription-bubble"));if("unsubscribe"==f)for(var b=E("DIV","username_"+a,C("hp-feed-items-container")),
c=0;c<b.length;c++)hf(b[c],l);this.ea=l},this),onException:r(function(){this.ea=l},this)})}};Ij.prototype.handleUpdateClick=Ij.prototype.pl;Ij.prototype.Zk=function(){Ac(C("edit-subscription-bubble"))};Ij.prototype.closeInlineSubscriptionEditBubble=Ij.prototype.Zk;var Jj={Fi:"success",Ai:"already_subscribed",Bi:"email_not_confirmed",Ei:"self_subscribe",Di:"over_limit",Lf:"failure",Ci:"logging_in"};
Ij.prototype.cg=function(a,b,c){var c=c||"",b=b.replace(/[^a-zA-Z0-9]\s*/g,""),c=c.replace(/[^a-zA-Z0-9._-]\s*/g,""),d={target:b,user:N("USERNAME"),extraData:c};if(N("LOGGED_IN")){var e=function(a){if(a.errors){var b=Jj.Lf;switch(a.error_code){case 3:b=Jj.Bi;break;case 4:b=Jj.Ei;break;case 5:b=Jj.Ai;break;case 6:b=Jj.Di}a=b}else a=Jj.Fi;d.status=a;return d},b={u:b,session_token:N("SUBS_XSRF")},c=ve("/subscription_ajax",{action_create_subscription_to_user_via_masthead:1,feature:"masthead_oneoff"});
W(c,{postBody:te(b),onComplete:function(b){b=eval("("+b.responseText+")");d=e(b);a(d)},onException:function(){d.status=Jj.Lf;a(d)},onError:function(b){b=eval("("+b.responseText+")");b.errors||(b.errors=j);d=e(b);a(d)},json:j})}else Kj(this,b,c),d.status=Jj.Ci,a(d)};Ij.prototype.subscribeFromMasthead=Ij.prototype.cg;s("yt.www.home.Subscriptions.subscribeFromMasthead",function(a,b,c){window.subui_.cg(a,b,c)});
var Kj=function(a,b,c){b="/subscribe_widget?action_finish_subscription_login_via_masthead=1&subch="+b;c&&(b+="&extra="+c);c=ve("/signin",{action_handle_signin:"true",nomobiletemp:"1",link_prompt:"false",next:b});a=ue(a.wi+"/accounts/ServiceLogin?service=youtube&btmpl=popup&passive=true&rm=false","continue","http://"+document.domain+c,"hl",a.xi);(a=window.open(a,"loginPopup","width=415,height=440,resizable=yes,scrollbars=yes",j))&&a.moveTo((screen.width-415)/2,(screen.height-440)/2)};var Lj=["FL","LL","QL","SV","WL"],Mj=function(){return parseInt(N("SHUFFLE_VALUE"),10)||0};var Nj=function(){var a=md("watch_queue_new");return a?a.split(","):[]},Oj=function(a){a=ib(a,0,100);(a=a.join(","))?ld("watch_queue_new",a):nd("watch_queue_new")};var Pj=function(a,b){a.length&&V("/video_info_ajax",{method:"POST",g:{action_get_videos_data:1,count:a.length},j:{video_ids:a.join(",")},c:function(a,d){d.data&&b(d.data)}})};var Qj=function(a){var b=Mj(),c=function(a){for(var c=1,d=[],a=a.split("");a.length;){var c=(b+c)%a.length,e=a[c];cb(a,c);d.push(e)}return d.join("")},d=[];u(a,function(a,b){d.push({id:a,key:c(a),index:b})});mb(d);var e=b>>8;Ya(d,function(a){return e==a.index});a=ib(d,e).concat(ib(d,0,e));return Wa(a,function(a){return{id:a.id,Fd:a.index}})};var Rj=function(a,b,c){this.ha=a;this.D=b;this.ga=this.Ub=l;this.Sc=new wf;this.B=c||[];this.nb={};this.Tb=!c;this.lb="";this.F=-1;this.pb=1;this.Sb=this.ia=0;this.jb=this.kb="";this.Da=this.Qa=this.wa=k},Sj=function(a){a.Sc.Pb("LIST_UPDATED")};Rj.prototype.isEqual=function(a){return this.ha!=a.ha?l:this.za()==a.za()};Rj.prototype.wd=function(a){this.lb=a.lb||"";this.F=a.V();this.ia=a.ia;this.pb=a.pb;this.kb=a.kb;this.jb=a.jb};Rj.prototype.oa=function(){return this.ha};
Rj.prototype.za=function(){return this.ha+(this.D||"")};var Uj=function(a,b){return Tj(a,"occurrences",function(){var a={};u(this.pa(),function(b){a[b]=(a[b]||0)+1});return a})[b]||0},Wj=function(a){return a.W()?Vj(a):a.pa()};Rj.prototype.Jd=function(a){var b=Wj(this);if(!b.length)return"";a=this.V()+a;a>=b.length&&(a%=b.length);return b[a]};var Xj=function(a,b){var c=Wj(a);return Wa(b,function(a){return $a(c,function(b){return b==a})})};Rj.prototype.pa=function(){return eb(this.B)};
var Vj=function(a){return Tj(a,"shuffled_ids",function(){return Wa(Yj(this),function(a){return a.id})})},Yj=function(a){return Tj(a,"shuffled_videos",function(){var a=this.pa();return Qj(a)})};n=Rj.prototype;n.getVideoData=function(a){return this.nb[a]||{}};n.P=function(){return this.pa().length};n.V=function(){return this.W()?Ya(Yj(this),function(a){return a.Fd==this.F},this):this.F};n.W=function(){return 0<this.ia};n.na=function(){return 0<=this.F};n.ob=function(){return!!this.Ub};n.ad=function(){return!!N("LIST_COPY_ON_EDIT_ENABLED")};
n.Ua=function(){return l};var Zj=function(a){a.wa=k;a.Qa=k},ak=function(a,b){var c=a.V()-1;0>c&&(c=a.P()-1);return $j(a,c,l,b)},$j=function(a,b,c,d){var e=Wj(a)[b];if(!e)return k;var f={v:e};if(1<Uj(a,e))e=b+1+a.Sb,a.W()&&(e=Yj(a)[b].Fd+1),f.index=e;if(c)f.playnext=a.pb;if(a.W())f.shuffle=a.ia;d&&(f.feature=d);return ze(a.lb,f)};Rj.prototype.clear=function(){this.Wf();Sj(this)};
Rj.prototype.removeItem=function(a){if(this.W())a=Yj(this)[a].Fd;var b=this.pa()[a];this.hf(a);if(this.F>a)this.F-=1;else if(this.F==a)this.F=-1;Sj(this);return b};Rj.prototype.hf=function(a){var b=this.B[a];cb(this.B,a);V(this.cc(),{format:"XML",method:"POST",j:{video_ids:b,session_token:Vg.addto_ajax||"",playlist_id:this.D||"",index:a},c:function(a,b){this.wa=b.html_content},l:function(a,b){this.Qa=b.error_message||P("ERROR_OCCURRED")},fa:function(){Sj(this)},n:this})};
Rj.prototype.load=function(a){this.Tb&&!this.Ub?bk(this,a):a&&(Sj(this),a());ck(this)};
var ck=function(a){var b=Wj(a),b=Va(b,function(a){return!(a in this.nb)},a);u(b,function(a){this.nb[a]={}},a);Pj(b,r(function(a){for(var b in a)this.nb[b]=a[b];Sj(this)},a))},bk=function(a,b,c){a.Ub=j;a.Tb=l;var d={style:"bottomfeedr_json",action_get_list:1,list:a.za()};c&&Cb(d,c);V("/list_ajax",{g:d,c:function(a,b){var c=b.data;this.B=eb(c.videos);this.D=c.list_id;this.ga=!!c.editable;this.lb=c.video_url||"";this.kb=c.menu_title_html;this.jb=c.menu_html;this.Sb=c.index_offset;var c=c.video_data,
d;for(d in c)this.nb[d]=c[d]},l:function(){},fa:function(){this.Ub=l;ck(this);Sj(this);b&&b()},n:a})},dk=function(a,b,c){a.Da={};try{b.call(c)}finally{a.Da=k}},Tj=function(a,b,c){if(a.Da&&b in a.Da)return a.Da[b];c=c.call(a);a.Da&&(a.Da[b]=c);return c};var ek=function(a,b){Rj.call(this,"FL",a,b)};t(ek,Rj);ek.prototype.cc=function(){return"/addto_ajax?action_delete_from_favorites=1"};var fk=function(a,b){Rj.call(this,"LL",a,b)};t(fk,Rj);fk.prototype.cc=function(){return"/addto_ajax?action_delete_from_liked=1"};var gk=function(a,b){Rj.call(this,"ML",a,b)};t(gk,Rj);gk.prototype.ad=function(){return!!this.ga};gk.prototype.Ua=function(){return!!this.ga};var hk=function(a,b,c){Rj.call(this,a,b,c)};t(hk,Rj);n=hk.prototype;n.dd=function(a){hb(this.B,a);V("/addto_ajax",{format:"XML",method:"POST",g:{action_add_to_playlist:1},j:{playlist_id:this.D,video_ids:a.join(","),session_token:Vg.addto_ajax},l:function(){this.Qa=P("ERROR_OCCURRED");Sj(this)},n:this})};n.cc=function(){return"/addto_ajax?action_delete_from_playlist=1"};
n.Wf=function(){var a=this.B.length;bb(this.B);V("/addto_ajax",{format:"XML",method:"POST",g:{action_clear_playlist:1,list_length:a,type:this.ha},j:{playlist_id:this.D,session_token:Vg.addto_ajax},l:function(){this.Qa=P("ERROR_OCCURRED");Sj(this)},n:this})};
n.Je=function(a,b){var c=this.B[a];cb(this.B,a);jb(this.B,b,0,c);var d=eb(this.B);V("/addto_ajax?action_move_playlist_video=1",{format:"XML",method:"POST",j:{video_ids:c,playlist_id:this.D,source_index:a,target_index:b,session_token:Vg.addto_ajax},l:function(){var e;a:if(e=this.B,!fa(e)||!fa(d)||e.length!=d.length)e=l;else{for(var f=e.length,g=0;g<f;g++)if(e[g]!==d[g]){e=l;break a}e=j}e&&(cb(this.B,b),jb(this.B,a,0,c));this.Qa=P("ERROR_OCCURRED");Sj(this)},n:this})};n.Ua=function(){return!!this.ga};var ik=function(a){Rj.call(this,"QL",k);this.ga=j;this.Tb=!a};t(ik,Rj);n=ik.prototype;n.wd=function(a){ik.yf.wd.call(this,a);this.Tb=l};n.pa=function(){return Nj()};n.dd=function(a){var b=Nj();hb(b,a);Oj(b)};n.hf=function(a){var b=Wj(this)[a],a=Nj(),b=Ua(a,b);0<=b&&(cb(a,b),Oj(a))};n.Wf=function(){Oj([])};n.Je=function(a,b){var c=Nj(),d=c[a];cb(c,a);jb(c,b,0,d);Oj(c)};n.Ua=function(){return!!this.ga};var jk=function(a,b){Rj.call(this,"SV",a,b);this.ga=j};t(jk,Rj);jk.prototype.load=function(a){jk.yf.load.call(this,a);!this.ob()&&this.na()&&(a=Wj(this),this.V()>=a.length-1&&bk(this,k,{load_more:"1"}))};jk.prototype.cc=function(){return"/addto_ajax?action_delete_from_station=1"};var kk=function(a,b,c){var d=k;switch(a){case "PL":case "SP":case "BP":case "WL":d=new hk(a,b,c);break;case "FL":d=new ek(b,c);break;case "LL":d=new fk(b,c);break;case "AV":case "BB":case "ML":case "MC":d=new gk(b,c);break;case "QL":d=new ik;break;case "SV":d=new jk(b,c);break;default:d=new Rj(a,b,c)}return d};!B||fc(9);!B||fc(9);B&&dc("8");!Qb||dc("528");Pb&&dc("1.9b")||B&&dc("8")||Ob&&dc("9.5")||Qb&&dc("528");!Pb||dc("8");B||Pb&&dc("1.9.3");new wf;var mk=function(a,b){this.Vf=a;var c=b||k;c||(c=lk(this.Vf));c=qa("__%s__","("+c.join("|")+")");this.fj=RegExp(c,"g")},nk=/__([a-z]+(?:_[a-z]+)*)__/g,ok=function(a,b){var c=C(a).innerHTML,c=c.replace(/^\s*(<\!--\s*)?/,""),c=c.replace(/(\s*--\>)?\s*$/,"");return new mk(c,b)},lk=function(a){var b=[],c={};a.replace(nk,function(a,e){e in c||(c[e]=j,b.push(e))});return b};mk.prototype.sb=function(a,b,c){return this.Vf.replace(this.fj,r(function(d,e){b&&(e=b(e));return c?a[e]||"":Aa(a[e]||"")},this))};var qk=function(a,b){this.O=!!b;this.k=a;this.Ia=this.O?C("watch-tray-playlist-slider"):C("playlist-bar-tray");this.U=Td("ol",k,this.Ia);this.xh=C("playlist-bar-title");this.wh=C("playlist-bar-extras-menu");var c=xb(pk),d=C("playlist-bar-template");this.O&&(d=C("watch-tray-playlist-item-template"));this.Eh=ok(d,c);d=R(d,"video-thumb-url")||"";this.Fh=new mk(d,c);fe(this.Ia,"click",r(function(){O(r(this.Se,this),0)},this),"playlist-bar-tray-button")},pk={classes:"classes",list_position:"index",video_encrypted_id:"id",
video_title:"title",video_url:"url",video_username:"username",video_thumb_url:"thumb_url"};qk.prototype.sb=function(a,b,c,d,e){var f=c.kb;if(f)this.xh.innerHTML=f,this.wh.innerHTML=c.jb;var g=[];u(a,function(a,d){var f=d==b,D=c.getVideoData(a);D.id=a;D.url=$j(c,d);g.push(rk(this,D,d+1+e,f))},this);this.U.innerHTML=g.join("");d?this.scroll(3):this.O||this.scroll(5);d=F("item-count",this.k);u(d,function(b){b.innerHTML=a.length})};
var rk=function(a,b,c,d){var e=function(a){return pk[a]};b.index=c;b.thumb_url=a.Fh.sb(b,e);c=[];b.title||c.push("loading");d&&c.push("playlist-bar-item-playing");b.classes=c.join(" ");return a.Eh.sb(b,e)};qk.prototype.Se=function(){var a=ii($h.getInstance(),this.Ia);u(a,function(a){Bi(a)})};
qk.prototype.scroll=function(a,b){var c=$h.getInstance();switch(a){case 3:var d=Td("li","playlist-bar-item-playing",this.U);if(d){var e=this.Ia;if(e){var f=ai(c,bi(c,c.Ka(e))),d=Ua(f,d);0<=d&&di(c,e,d)}}else di(c,this.Ia,0);break;case 4:b&&di(c,this.Ia,b);break;case 5:e=this.Ia,d=c.getData(e,"scroll-offset"),ei(c,e,parseInt(d,10)||0)}this.Se()};
qk.prototype.ec=function(a){var b=0,c=r(function(){var d=E("li","playlist-bar-item",this.U),e=!(b%2);u(a,function(a){A(d[a],"playlist-bar-item-highlight",e)});b++;6>b&&O(c,150)},this);c()};var tk=function(a,b,c){this.k=a;this.O=!!c;this.Sa=new qk(this.k,this.O);this.rb=b;this.Jc=this.qe=l;this.og=C("playlist-bar-bar");S(this.og,"click",r(this.qg,this));this.Ag=C("playlist-bar-play-button");S(this.Ag,"click",r(this.wg,this));this.O?(this.xe=C("watch-prev"),this.Pc=C("watch-next")):(this.xe=C("playlist-bar-prev-button"),this.Pc=C("playlist-bar-next-button"));S(this.xe,"click",r(this.xg,this));S(this.Pc,"click",r(this.ug,this));this.Oc=C("playlist-bar-autoplay-button");S(this.Oc,"click",
r(this.pg,this));this.ne=C("playlist-bar-shuffle-button");S(this.ne,"click",r(this.yg,this));this.oe=C("playlist-bar-toggle-button");S(this.oe,"click",r(this.zg,this));this.Lc=C("playlist-bar-options-menu");fe(this.Lc,"click",r(this.vg,this),"yt-uix-button-menu-item");this.U=C("playlist-bar-tray-content");if(this.O)this.U=C("watch-tray-playlist-content");fe(this.U,"click",r(this.rg,this),"delete");fe(this.U,"click",r(this.sg,this),"load-lists");fe(this.U,"click",r(this.tg,this),"load-more");this.dg=
ok(C("playlist-bar-next-up-template"),["video_encrypted_id"]);sk(this,b);this.b.P()?this.show():this.ja();if(Jb&&!this.O)a=document.createElement("iframe"),a.id="playlist-bar-mask",a.frameBorder="0",a.src='javascript:""',this.k.insertBefore(a,this.k.firstChild)},sk=function(a,b,c,d){if(a.b&&(a.b.Sc.clear("LIST_UPDATED"),a.rb.isEqual(b)||d))b.wd(a.rb),a.rb=b;a.b=b;a.b.Sc.Eb("LIST_UPDATED",a.tb,a);a.b.load(c);a.tb(j)};tk.prototype.oa=function(){return this.b.oa()};tk.prototype.za=function(){return this.b.za()};
tk.prototype.na=function(){return this.b.na()};var uk=function(a){return a.na()&&z(a.k,"autoplay-on")};tk.prototype.W=function(){return z(this.k,"shuffle-on")};tk.prototype.ob=function(){return z(this.k,"loading")};tk.prototype.show=function(){K.getInstance().Yc(L.Sd)?vk(this):wk(this)};tk.prototype.ja=function(){y(this.k,["min","max"],"hid")};var vk=function(a){y(a.k,["hid","max"],"min");xk(a,j)},wk=function(a){y(a.k,["hid","min"],"max");xk(a,j)};n=tk.prototype;
n.toggle=function(){var a;z(this.k,"min")?(wk(this),a=l):(vk(this),a=j);jh("bf","toggleBar=1&collapsed="+a,i);var b=K.getInstance();b.qc(L.Sd,a);b.save();yk(this,j)};n.qg=function(a){Nc(a.target,function(a){a=a.tagName&&a.tagName.toLowerCase();return"a"==a||"button"==a},j)||this.toggle()};n.vg=function(a){a.stopPropagation();switch(R(a.currentTarget,"action")){case "clear":this.clear();break;case "load-lists":zk(this);break;case "show-active":this.rb&&sk(this,this.rb);break;case "save":Ak(this)}};
n.zg=function(){this.toggle()};n.pg=function(){var a=!uk(this);a?y(this.k,"autoplay-off","autoplay-on"):y(this.k,"autoplay-on","autoplay-off");var b=K.getInstance();b.qc(L.Ef,!a);b.save();Ad("LIST_AUTO_PLAY_ON",a);xk(this)};n.yg=function(){var a=!this.W(),b=0;Ad("SHUFFLE_ENABLED",a);a&&Ad("SHUFFLE_VALUE",Math.max(1,1E6*Math.random()));a?(y(this.k,"shuffle-off","shuffle-on"),b=Mj()):y(this.k,"shuffle-on","shuffle-off");this.b.ia=b;this.tb();this.Sa.scroll(3)};n.wg=function(){this.next(j,"bf_play")};
n.xg=function(){var a=ak(this.b,"bf_prev");a&&dh(a)};n.ug=function(){this.next(j,"bf_next")};
n.rg=function(a){a.preventDefault();a.stopPropagation();var b=this.O?"watch-tray-playlist-item":"playlist-bar-item",c=E("li",b,this.U),a=I(a.currentTarget,"li",b),c=Ua(c,a);this.b.ad()&&(a=this.b.oa(),Bk(this),jh("bf","copyFrom=1&action=delete&list_type="+a,i));var d=this.b.oa(),e=Wj(this.b)[c];this.b.removeItem(c);Ck(this,P("PLAYLIST_VIDEO_DELETED"),l,l,function(){this.b.dd([e]);this.tb();var a=this.b.P()-1;this.Sa.scroll(4,a);this.Sa.ec([a]);jh("bf","undo_delete=1&list_type="+d,i)});jh("bf","delete=1&list_type="+
d,i)};var Dk=function(a){if(!a.qe)a.qe=j,bh((N("DRAGDROP_BINARY_URL")||"")+"",r(function(){S(this.U,"mouseover",r(function(){if(!this.Jc)this.Jc=j,this.b.Ua()&&!this.b.W()&&q("yt.www.lists.dragdrop").createDraggables()},this));var a=this.O?"watch-tray-playlist-item":"playlist-bar-item",c=q("yt.www.lists.dragdrop");c.init(this.U,a);c.subscribe("DROPPED_AT_INDEX",this.Yg,this)},a))};
tk.prototype.Yg=function(a){var b=a.sourceIndex,a=a.targetIndex;if(!(b==a||0>b||0>a)){if(this.b.ad()){var c=this.b.oa();Bk(this);jh("bf","copyFrom=1&action=drag&list_type="+c,i)}c=this.b;if(!c.W()&&c.Ua()){var d=Wj(c);if(d[b]&&d[a])c.Je(b,a),d=c.F,d==b?c.F=a:d>b&&d<=a?c.F-=1:d<b&&d>=a&&(c.F+=1);Sj(c)}b=te({moved_item_delta:Math.abs(a-b),list_type:this.b.oa()});jh("bf",b,i)}};
tk.prototype.next=function(a,b){a||jh("bf","autoplay=1&playcount="+this.b.pb,i);var c;c=this.b;var d=c.V()+1;d>=c.P()&&(d=0);(c=$j(c,d,!a,b))&&dh(c)};var Ek=function(a,b){if(!(1>b||5<b)){jh("bf","delayedautoplay="+b,i);li(ki.getInstance(),a.Oc);var c=P("AUTOPLAY_WARNING"+b);c&&Ck(a,c,l,j)}};
tk.prototype.clear=function(){var a=this.b.pa();this.b.clear();Ck(this,P("LIST_CLEARED"),l,l,function(){this.b.dd(a);this.tb();jh("bf","undo_clear=1&list_type="+b,i)});var b=this.b.oa();jh("bf","clear=1&list_type="+b,i)};tk.prototype.Jd=function(a){return this.b.Jd(a)};
tk.prototype.tb=function(a){var b=this.b.ob(),c=!b&&!!this.b.ga,d=!this.b.P(),e=this.b.na();e?y(this.Lc,"passive","active"):y(this.Lc,"active","passive");var f=[],g=[];(e?g:f).push("active");(!e?g:f).push("passive");(b?g:f).push("loading");(c?g:f).push("editable");(d?g:f).push("empty");y(this.k,f,g);b||dk(this.b,function(){var b=Wj(this.b),c=this.b.V();this.Sa.sb(b,c,this.b,!!a,this.b.Sb);this.Jc=l},this);b=this.b.Qa;c=this.b.wa;b?Ck(this,b,j,l):c&&Ck(this,c,l,j);Zj(this.b);xk(this);this.b.Ua()&&
this.b.P()&&Dk(this)};
var xk=function(a,b){var m;if(!a.O){var c=P("AUTOPLAY_OFF_TOOLTIP");uk(a)&&(c=P("AUTOPLAY_ON_TOOLTIP"));var d=P("SHUFFLE_OFF_TOOLTIP");a.W()&&(d=P("SHUFFLE_ON_TOOLTIP"));var e=P("NEXT_VIDEO_NOTHUMB_TOOLTIP");if(a.b.na()){var f=Wj(a.b),g=a.b.V();if((m=(g=f[f.length==g+1?0:g+1])&&a.b.getVideoData(g),f=m)&&f.title)e=a.dg.sb({video_encrypted_id:g}),e=P("NEXT_VIDEO_TOOLTIP",{"{next_video_title}":f.title})+" "+e}f="";f=z(a.k,"min")?P("SHOW_PLAYLIST_TOOLTIP"):P("HIDE_PLAYLIST_TOOLTIP");g=ki.getInstance();
ni(g,a.Pc,e);ni(g,a.Oc,c);ni(g,a.ne,d);ni(g,a.oe,f,b)}};tk.prototype.Mb=k;tk.prototype.xc=k;
var Fk=function(a){if(a.Mb)Dd(a.Mb),a.Mb=k},Ck=function(a,b,c,d,e){if(b){if(!a.La)a.La=a.O?C("watch-bar-notifications"):C("playlist-bar-notifications"),fe(a.La,"click",r(a.oi,a),"playlist-bar-undo");a.xc=e||k;a.xc&&(b+=' <a class="playlist-bar-undo">'+P("UNDO_LINK")+"</a>");G("yt-alert-content",a.La).innerHTML=b;A(a.La,"yt-alert-error",!!c);A(a.La,"yt-alert-success",!c);T(a.La);Fk(a);if(d)b=r(function(){yk(this)},a),a.Mb=O(b,1E4)}};tk.prototype.showError=function(a,b){Ck(this,a,j,b)};
var yk=function(a,b){var c=!!a.Mb;if(!b||!c)U(a.La),a.xc=k,Fk(a)};tk.prototype.oi=function(a){a.stopPropagation();a.preventDefault();a=this.xc;yk(this);a.call(this)};tk.prototype.ec=function(a){a=Xj(this.b,a);a.length&&(this.Sa.ec(a),this.Sa.scroll(4,a[0]))};
var Ak=function(a){a.ob()||(wk(a),Gk(a,{g:{action_get_save_playlist_form:1},c:function(a,c){y(this.k,"lists","save");var d=c.html;this.Ae=C("playlist-bar-save");this.Ae.innerHTML=d;d=C("playlist-bar-title-edit");d.focus();d.select();S(C("playlist-bar-save-cancel"),"click",r(this.Xg,this));S(C("playlist-bar-save-form"),"submit",r(this.Zg,this))}}))};tk.prototype.Xg=function(a){a.preventDefault();w(this.k,"save")};
tk.prototype.Zg=function(a){a.preventDefault();var b=Wj(this.b).join(",");b&&(yk(this),a=$c(a.target),Gk(this,{g:{action_save_playlist:1},method:"POST",Ra:a+("&video_ids="+b),c:function(a,b){this.Ae.innerHTML="";w(this.k,"save");sk(this,kk("PL",b.list_id),k,j);Ck(this,P("PLAYLIST_BAR_PLAYLIST_SAVED"),l,j)}}))};tk.prototype.sg=function(a){a.preventDefault();zk(this)};tk.prototype.tg=function(){var a=this.b;bk(a,k,{load_more:"1"});Sj(a)};
var zk=function(a){a.ob()||(wk(a),Gk(a,{g:{action_get_playlists:1},c:function(a,c){y(this.k,"save","lists");this.Qg=C("playlist-bar-lists-back");this.Og=S(this.Qg,"click",r(this.Rg,this));var d=c.html;this.zb=C("playlist-bar-lists");this.zb.innerHTML=d;Bi(this.zb);this.Pg=fe(this.zb,"click",r(this.Sg,this),"playlist-bar-playlist-item")}}))};tk.prototype.Sg=function(a){a.preventDefault();var b=a.currentTarget;b&&(Hk(this),a=R(b,"list-type")||"",b=R(b,"list-id")||"",sk(this,kk(a,b)))};
tk.prototype.Rg=function(a){a.preventDefault();Hk(this)};
var Hk=function(a){w(a.k,"lists");if(a.zb)a.zb.innerHTML="";be(a.Pg);be(a.Og)},Gk=function(a,b){v(a.k,"loading");Cb(b,{format:"JSON",l:function(a,b){var e=P("ERROR_OCCURRED");b&&b.errors&&(e=b.errors[0]);this.showError(e,j)},fa:function(){w(this.k,"loading")},n:a});V("/playlist_bar_ajax",b)},Jk=function(){var a=Ik(),b=Wj(a.b),c={};u(b,function(a){c[a]=this.b.getVideoData(a)},a);var d=a.V(),e=uk(a),a=a.W()?a.b.ia:0;return{autoPlay:e,index:d,shuffle:a,videoData:c,videoIds:b||[]}};tk.prototype.V=function(){return this.b.V()};
var Bk=function(a){var b=a.b.pa();Oj([]);var c=Nj();hb(c,b);Oj(c);b=new ik;c=a.b.V();b.F=c;b.ia=a.b.ia;sk(a,b)};var Kk=k,Lk=l,Ik=function(){if(!Kk){var a=C("playlist-bar"),b=l;!a&&N("ENABLE_WATCH6")&&(a=C("watch-tray-playlist"),b=j);if(a){var c=a,d;if(z(c,"active")){d=R(c,"list-type")||"";if("QL"==d)d=new ik(j);else{var e=R(c,"list-id")||"",f=(R(c,"video-ids")||"").split(",");d=kk(d,e,f)}e=parseInt(R(c,"index-offset"),10)||0;d.Sb=e;d.F=parseInt(N("PLAYLIST_BAR_PLAYING_INDEX"),10)||0;d.pb=parseInt(N("LIST_AUTO_PLAY_VALUE"),10)||0;e=0;N("SHUFFLE_ENABLED")&&(e=Mj());d.ia=e}else d=new ik(j);e=R(c,"video-url");
d.lb=e||"";c=z(c,"editable");d.ga=c;d.kb=C("playlist-bar-title").innerHTML;d.jb=C("playlist-bar-extras-menu").innerHTML;Kk=new tk(a,d,b)}}return Kk},Mk=function(a){var b=Ik();uk(b)&&(0<a?(Ek(b,a),O(function(){Mk(a-1)},1E3)):b.next(l,"mr_meh"))},Nk=function(a,b,c,d){if(Lk){var e=Ik();e&&(a=kk(a,b),b=j,e.na()&&(b=e.b.isEqual(a)),b?(sk(e,a,function(){e.ec(c);Ck(e,d,l,j)}),e.show()):Ck(e,d,l,j))}},Ok=function(a){for(var b=a.getDuration(),c=5;0<c;c--)a.addCueRange("NEAR_END"+c,b-c,b-c+1);a.addEventListener("onCueRangeEnter",
"yt.www.lists.handleNearPlaybackEnd")},Pk=function(){if(!Lk||!Ik().na())return l;var a=Ik().oa();return!ab(Lj,a)};var Rk=function(a,b,c){Qk({se:a,re:"WL",Zc:b,c:c,l:i,n:i})},Qk=function(a){var b={video_ids:a.se,playlist_id:a.jg||"",new_playlist_name:a.ve||"",session_token:Vg.addto_ajax},c={};if(a.ue)c["private"]=a.ue;if(a.Zc)c.feature=a.Zc;var d="";switch(a.re){case "PL":d=a.ve?"action_add_to_new_playlist":"action_add_to_playlist";break;case "FL":d="action_add_to_favorites";break;case "WL":d="action_add_to_watch_later_list"}c[d]=1;V("/addto_ajax",{Kc:j,format:"XML",method:"POST",g:c,j:b,n:a.n,l:a.l,c:a.c})};var Sk=function(a,b,c,d,e,f,g){this.f=a;this.Gh=b;this.Gb=c;this.Yb=d;this.Ue=!isNaN(parseInt(e,10));this.Ta=k;if(this.Ue)this.Ta=e;this.Dh=f||{};this.Te=!!g;window.__GOOGLEAPIS=window.__GOOGLEAPIS||{};window.__GOOGLEAPIS.gwidget=window.__GOOGLEAPIS.gwidget||{};window.__GOOGLEAPIS.gwidget.lang=this.Yb;if(this.Ue)window.__GOOGLEAPIS["googleapis.config"]=window.__GOOGLEAPIS["googleapis.config"]||{},window.__GOOGLEAPIS["googleapis.config"].sessionIndex=this.Ta;this.Cb()};
Sk.prototype.Cb=function(){bh("http://web.archive.org/web/20111228172059/https://apis.google.com/js/plusone.js",r(this.xl,this))};Sk.prototype.xl=function(){var a=q("gapi.plusone.render");if(a){var b=Math.floor(1E4*Math.random()),c="__PLUS_ONE_CALLBACK_"+b,b="plusone-button-"+b;window[c]=r(this.Vh,this);var d=document.createElement("div");d.id=b;c={callbackName:c,count:"false",href:this.Gb,size:"medium",source:"google:youtube"};this.Te&&(c.db=1);Cb(c,this.Dh);this.f.appendChild(d);T(this.f);a(b,c)}};
Sk.prototype.Vh=function(a){"off"!=a.state&&(kh("PLUS_ONE",this.Gh+""),this.Te&&eh(ve("http://web.archive.org/web/20111228172059/https://plusone.google.com/_/+1/confirm",{url:a.url,source:"google:youtube"}),{width:480,height:550}))};var Uk=function(a,b){var c=!!a,d=C("content"),e=C("watch-sidebar"),f=C("watch-video"),g=C("baseDiv"),m=N("WIDE_PLAYER_STYLES"),p=0;"webkitTransition"in e.style?(p=document.defaultView.getComputedStyle(e,k),p=1E3*parseFloat(p["-webkit-transition-duration"])):"MozTransition"in e.style?(p=document.defaultView.getComputedStyle(e,k),p=1E3*parseFloat(p.getPropertyValue("-moz-transition-duration"))):"OTransition"in e.style&&(p=document.defaultView.getComputedStyle(e,k),p=1E3*parseFloat(p.getPropertyValue("-o-transition-duration")));
var x=Tk();if(c){var D=p;v(d,"watch-wide");O(function(){v(f,"wide");for(var a=0;a<m.length;++a)v(g,m[a])},D);x&&"medium"==x.getPlaybackQuality()&&!N("PREFER_LOW_QUALITY")&&x.setPlaybackQuality("large")}else{D=p/2;w(f,"wide");for(var H=0;H<m.length;++H)w(g,m[H]);O(function(){w(d,"watch-wide")},D);x&&"large"==x.getPlaybackQuality()&&x.setPlaybackQuality("medium");Bi(e)}hf("masthead-utility-menulink-short",c);hf("masthead-utility-menulink-long",!c);c=function(){var a=cf(x);x.setSize(a.width,a.height)};
b?c():O(c,p+200);(c=q("yt.www.watch.experimental.updateWide"))&&c.call()},Tk=function(){return N("PLAYER_REFERENCE")||C("movie_player")||C("video-player")},Vk=function(a){I(a.target,"BUTTON")||a.currentTarget.click()},Wk=function(a){var b=C("subscribeDiv");b||(b=G("subscribe-button",C("watch-headline-user-info")));if(b){var c=ki.getInstance();c.setData(b,"tooltip",a);li(c,b);O(function(){mi(c,b);c.setData(b,"tooltip","")},6E3)}},Xk=function(){var a=C("watch-player-rental-still-frame");U(C("watch-player"));
T(a)};var Zk=function(a,b,c,d){this.f=a;this.Uc=l;a=ne()+"/share_ajax";V(a,{format:"JSON",g:{action_get_email:1,video_id:c,list:d},c:function(a,c){this.f.innerHTML=c.email_html;this.ya();this.focus();var d=c.sharing_binary_url;d&&Yk(this,d,c.contacts,b)},n:this})};
Zk.prototype.ya=function(){this.i=this.f.getElementsByTagName("form")[0];S(this.i,"submit",r(this.cd,this));this.Jl=G("share-email-send",this.i);this.wa=G("share-email-success",this.f);this.qh=G("share-email-remail",this.wa);S(this.qh,"click",r(function(){$k(this);this.focus()},this));this.sd=G("share-email-recipients",this.f);this.od=G("share-email-note",this.f);this.Ke=G("share-email-preview-note",this.f);S(this.od,"keyup",r(this.ph,this))};
var Yk=function(a,b,c,d){bh(b,r(function(){var a=q("yt.sharing.ContactTools");a&&a.createContactTools(this.sd,k,c,d)},a))};Zk.prototype.xa=function(){this.i&&(this.Uc&&$k(this),this.focus())};Zk.prototype.focus=function(){this.sd.focus()};var $k=function(a){a.Uc=l;a.sd.value="";a.od.value="";a.Ke.innerHTML="";U(a.wa);T(a.i)};Zk.prototype.ph=function(){var a=this.od.value,a=a.substring(0,300),a=Aa(a),a=a.replace(/\n/g,"<br>");this.Ke.innerHTML=a};
Zk.prototype.cd=function(a){a.preventDefault();var b=E("button",k,this.i)[0];b.disabled=j;var c=G("share-email-captcha",this.f),d=G("share-email-error",this.f),e=G("yt-alert-content",d),a=ne()+oe(this.i.action);V(a,{format:"JSON",method:"POST",Ra:$c(this.i),c:function(){this.Uc=j;T(this.wa);U(this.i);U(d);U(c)},l:function(a,b){if(b.captcha_html)c.innerHTML=b.captcha_html,T(c);if(b.errors)e.innerHTML=b.errors.join("<br>"),T(d)},fa:function(){b.disabled=l},n:this})};var bl=function(a,b,c){this.f=a;a=ne()+"/share_ajax";V(a,{format:"JSON",g:{action_get_embed:1,video_id:b,list:c},c:function(a,b){this.f.innerHTML=b.embed_html;this.hg=b.legacy_url;this.gg=b.legacy_code;this.fg=b.iframe_url;this.eg=b.iframe_code;this.ya();var c=K.getInstance();if(this.Ba)this.Ba.checked=!c.Xc(L.Vc);this.Vb.checked=c.Wb(L.Rc);if(this.Y)this.Y.checked=c.Wb(L.Qc);if(this.Aa)this.Aa.checked=c.Yc(L.Tc);c=c.get("ems");(c in this.J?this.J[c]:wb(this.J)).select();al(this);this.xa()},n:this})};
bl.prototype.ya=function(){this.$a=G("share-embed-code",this.f);S(this.$a,"click",r(this.ii,this));cl(this);dl(this)};
var cl=function(a){var b=G("share-embed-size-list",a.f),c=F("share-embed-size-radio",b);a.J={};u(c,function(a){z(a,"share-embed-size-radio-custom")||(a=new el(a),this.J[a.name]=a)},a);var c=wb(a.J).width/(wb(a.J).height-30),d=G("share-embed-size-radio-custom",b),c=new fl(d,c);a.J[c.name]=c;a.Nh=c;fe(b,"click",r(a.Oh,a),"share-embed-size");b=G("share-embed-customize",b);S(b,"keyup",r(a.Ph,a))},dl=function(a){var b={},c=F("share-embed-option",a.f);u(c,function(a){b[a.name]=a});a.Ba=b["show-related"];
a.Ba&&S(a.Ba,"click",r(a.zh,a));a.Vb=b["delayed-cookies"];S(a.Vb,"click",r(a.yh,a));a.Ee=b["use-https"];S(a.Ee,"click",r(a.Ch,a));a.Y=b["use-hd"]||k;a.Y&&S(a.Y,"click",r(a.Bh,a));a.Aa=b["use-flash-code"]||k;a.Aa&&S(a.Aa,"click",r(a.Ah,a))};bl.prototype.xa=function(){this.focus()};bl.prototype.focus=function(){this.$a&&(this.$a.focus(),this.$a.select())};
var al=function(a){var b=a.eg,c=a.fg;if(a.Aa&&a.Aa.checked)b=a.gg,c=a.hg;a.Vb.checked&&(c=c.replace("youtube.com","youtube-nocookie.com"));a.Ee.checked&&(c=c.split("//"),c[0]="https:",c=c.join("//"));var d={};a.Ba&&!a.Ba.checked&&(d.rel=0);a.Y&&a.Y.checked&&(d.hd=1);c=ze(c,d);d=gl(a);if(!d.width||200>d.width)d=wb(a.J);b=b.replace(/__url__/g,Aa(c));b=b.replace(/__width__/g,d.width+"");b=b.replace(/__height__/g,d.height+"");b=Aa(b);if(b!=a.$a.innerHTML)a.$a.innerHTML=b},gl=function(a){return zb(a.J,
function(a){return a.Ob.checked})||k};n=bl.prototype;n.zh=function(){var a=this.Ba.checked,b=K.getInstance();b.Zd(L.Vc,!a);b.save();al(this)};n.yh=function(){var a=this.Vb.checked,b=K.getInstance();b.Ha(L.Rc,a);b.save();al(this)};n.Ch=function(){al(this)};n.Bh=function(){var a=this.Y.checked,b=K.getInstance();b.Ha(L.Qc,a);b.save();if(a)for(var c in this.J)if(this.J[c].ji){this.J[c].select();break}al(this)};n.Ah=function(){var a=this.Aa.checked,b=K.getInstance();b.qc(L.Tc,a);b.save();al(this)};
n.ii=function(){this.focus()};n.Oh=function(a){a=this.J[G("share-embed-size-radio",a.currentTarget).value];a.select();var b=K.getInstance();b.set("ems",a.name);b.save();al(this);a!=this.Nh&&this.focus()};n.Ph=function(){al(this)};var el=function(a){this.name=a.value;this.Ob=a;this.ji=-1<this.name.indexOf("hd");this.width=parseInt(R(this.Ob,"width"),10);this.height=parseInt(R(this.Ob,"height"),10)};
el.prototype.select=function(){this.Ob.checked=j;var a=I(this.Ob,"li"),b=I(a,"ul"),b=E("li","selected",b);u(b,function(a){w(a,"selected")});v(a,"selected")};var fl=function(a,b){el.call(this,a);this.Kf=b;var c=I(a,"li");this.Xd=G("share-embed-size-custom-width",c);this.Wd=G("share-embed-size-custom-height",c);S(this.Xd,"keyup",r(this.Ji,this));S(this.Wd,"keyup",r(this.Ii,this))};t(fl,el);
fl.prototype.Ji=function(){this.width=parseInt(this.Xd.value,10);this.height=(Math.floor(this.width/this.Kf)||0)+30;this.Wd.value=this.height+""};fl.prototype.Ii=function(){this.height=parseInt(this.Wd.value,10)-30;this.width=Math.ceil(this.height*this.Kf)||0;this.Xd.value=this.width+""};var hl=function(a,b,c,d,e,f){this.f=a;this.Z=b||k;this.D=c||k;this.Ne=l;this.mg=e||k;this.ng=f||l;this.Cb(d)},il=function(a){var b=["h","m","s"],c=eb(b);c.reverse();var d={},a=a.toLowerCase().match(/\d+\s*[hms]?/g)||[],a=Va(a,function(a){var b=(a.match(/[hms]/)||[""])[0];return b?(d[b]=parseInt(a.match(/\d+/)[0],10),l):j});for(a.reverse();a.length&&c.length;){var e=c.shift();e in d||(d[e]=parseInt(a.shift(),10))}if(a.length||59<d.s||59<d.m||9<d.h)return k;var f="";u(b,function(a){d[a]&&(f+=d[a]+a)});
return f||k};hl.prototype.Cb=function(a){var b=ne()+"/share_ajax";V(b,{format:"JSON",g:{action_get_share_box:1,video_id:this.Z,list:this.D,new_share_layout:j},c:function(b,d){this.f.innerHTML=d.share_html;this.ig=d.url_short;this.pe=d.url_long;this.Yb=d.lang;this.Ta=k;if("session_index"in d)this.Ta=d.session_index;this.ya();var e=G("share-panel-services-dynamic",this.f);e&&new Sk(e,(this.Z||this.D)+"",this.pe,this.Yb,this.Ta,this.mg,this.ng);a&&a();this.xa()},n:this})};
hl.prototype.ya=function(){var a=G("share-panel-show-url-options");S(a,"click",r(this.Lg,this));a=G("share-panel-show-more");S(a,"click",r(this.Ig,this));a=G("share-panel-embed",this.f);S(a,"click",r(this.Gg,this));a=G("share-panel-email",this.f);S(a,"click",r(this.Fg,this));(a=G("share-panel-hangout",this.f))&&S(a,"click",r(this.Hg,this));this.K=G("share-panel-url",this.f);S(this.K,"click",r(this.Mg,this));S(this.K,"focus",r(function(){v(this.K,"focused")},this));S(this.K,"blur",r(function(){w(this.K,
"focused")},this));this.Dg=G("share-panel-long-url",this.f);this.bd=G("share-panel-start-at",this.f);this.Q=G("share-panel-start-at-time",this.f);S(this.Q,"keyup",r(this.Ng,this));S(this.Q,"click",r(this.Kg,this));S(this.Q,"focus",r(function(){v(this.Q,"focused")},this));S(this.Q,"blur",r(function(){w(this.Q,"focused")},this));this.Y=G("share-panel-hd",this.f);this.Be=G("share-panel-include-list",this.f);this.$b=G("share-panel-url-options",this.f);S(this.$b,"click",r(this.fd,this));this.$c=G("share-panel-services",
this.f);this.we=G("share-panel-buttons",this.f);a=G("share-panel-show-more",this.f);S(a,"click",r(this.Jg,this))};hl.prototype.xa=function(){this.K&&!z(this.K,"focused")&&(this.K.focus(),this.K.select())};var kl=function(a){var b=jl;if(b.Q&&!z(b.Q,"focused")&&!b.Ne)b.Q.value=a,b.fd()};n=hl.prototype;
n.fd=function(){if(!z(this.K,"focused")){var a=this.ig;if(this.Dg.checked)a=this.pe;var b={};this.Y&&this.Y.checked&&(b.hd=1);if(this.Be&&this.Be.checked)b.list=this.D;var c=this.bd.checked&&il(this.Q.value);c&&(b.t=c);a=ve(a,b);if(this.K.value!=a)this.K.value=a}};n.Ng=function(){this.Ne=j;this.bd.checked=j;this.fd()};n.Kg=function(){this.bd.checked=j;if(!this.Q.value.match(/[1-9]/))this.Q.value=""};n.Mg=function(){this.K.select()};
n.Fg=function(){var a=Th.getInstance();a.collapse(this.we);a.collapse(this.$b);a.collapse(this.$c);this.M&&U(this.M);if(!this.L)this.L=G("share-panel-email-container",this.f);kf(this.L);if(!R(this.L,"disabled")&&jf(this.L))this.De?this.De.xa():this.De=new Zk(this.L,this.Ta,this.Z,this.D)};
n.Hg=function(){var a=Tk();a&&a.pauseVideo&&a.pauseVideo();var a=ve("http://web.archive.org/web/20111228172059/https://talkgadget.google.com/hangouts",{hl:this.Yb,gid:"youtube",gd:this.Z}),b=window.screen.height,c=Math.min(0.9*window.screen.width,1E3),b=Math.min(0.9*b,800);kh("HANGOUT",this.Z+"");eh(a,{width:c,height:b})};
n.Gg=function(){var a=Th.getInstance();a.collapse(this.we);a.collapse(this.$b);a.collapse(this.$c);this.L&&U(this.L);if(!this.M)this.M=G("share-panel-embed-container",this.f);kf(this.M);if(!R(this.M,"disabled")&&jf(this.M))this.Fe?this.Fe.xa():this.Fe=new bl(this.M,this.Z,this.D)};n.Lg=function(){Th.getInstance().collapse(this.$c);this.L&&U(this.L);this.M&&U(this.M)};n.Ig=function(){Th.getInstance().collapse(this.$b);this.L&&U(this.L);this.M&&U(this.M)};n.Jg=function(){this.L&&U(this.L);this.M&&U(this.M)};var ll=function(a,b){var c=N("VIDEO_ID"),d={};a?d.action_like_video=1:d.action_dislike_video=1;b=b||{};d.video_id=c;d.plid=b.Eg;c={screen:te({h:screen.height,w:screen.width,d:screen.colorDepth}),session_token:Vg.watch_actions_ajax};if(b.Ce)c.station_id=b.Ce;V("/watch_actions_ajax",{format:"XML",method:"POST",g:d,j:c,c:b.c,l:b.l});a?Si("convLikeUrl"):Si("convDislikeUrl")};var ml=["left","right","center"],nl={id:0,Ld:0,dh:7,hh:50,Tl:80,jh:95,ih:15,eh:100,isVisible:j,textAlign:ml[2],Le:0,backgroundColor:"#080808",fh:"#FFF",opacity:0.8};var ol=function(a){this.Ea=a.kd;this.qi=a.Ld;this.aa=a.aa||this.aa};ol.prototype.Ea=0;ol.prototype.qi=0;ol.prototype.aa=0;ol.prototype.toString=function(){return this.Ea+", "+this.aa};var pl=function(a){ol.call(this,a);this.pc=a.text||this.pc;this.jd=a.ed||this.jd;this.lf=a.H.append||this.lf;this.nf=a.H.row||this.nf;this.mf=a.H.Lh||this.mf};t(pl,ol);n=pl.prototype;n.pc="";n.lf=l;n.nf=0;n.mf=0;n.jd=0;n.fc=function(){return this.pc};n.toString=function(){return this.Ea+", "+this.aa+": "+this.pc};
var ql=function(a){var b=a.firstChild&&a.firstChild.nodeValue||"",c=1E3*parseFloat(a.getAttribute("start")||0);a.getAttribute("t")&&(c=parseInt(a.getAttribute("t"),10));var d=1E3*parseFloat(a.getAttribute("dur")||0);a.getAttribute("d")&&(d=parseFloat(a.getAttribute("d")));var e=parseInt(a.getAttribute("w"),10)||0,b={kd:c,aa:d,text:b,ed:e,Ld:5,H:{}};if(a.getAttribute("r"))b.H.row=parseInt(a.getAttribute("r"),10);if(a.getAttribute("c"))b.H.Lh=parseInt(a.getAttribute("c"),10);if(a.getAttribute("append"))b.Ld=
6,b.H.append=j;return new pl(b)},rl=function(a){ol.call(this,a);this.id=a.ed||this.id;this.H=a.H};t(rl,ol);rl.prototype.id=0;rl.prototype.H=k;rl.prototype.pd="";rl.prototype.gh=l;var sl=function(){return new rl({kd:-2147483648,aa:4294967295,H:nl})};var tl=function(a){this.Bb=[];this.rd=[];this.Db={};if(a&&a&&a.firstChild)switch(this.Fa=a,this.Fa.firstChild.tagName){case "timedtext":for(var a=this.Fa.firstChild.childNodes,b=0,c=a.length;b<c;b++)switch(a[b].tagName){case "window":var d=a[b],e=parseInt(d.getAttribute("id"),10),f=i;a:{var g=this.Db[e];if(!d.getAttribute("t")&&!d.getAttribute("start"))f=k;else{f=parseInt(d.getAttribute("t"),10);d.getAttribute("start")&&(f=1E3*parseFloat(d.getAttribute("start")));if(g)g.Ea+g.aa>=f?g.aa=f:g=k;switch(d.getAttribute("op")){case "kill":f=
k;break a;case "define":g=k}g?g.Gl=j:g=sl();var m={},g=g?g.H:nl,p=i;for(p in g)m[p]=g[p];if(d.getAttribute("id"))m.id=d.getAttribute("id");if(d.getAttribute("op"))m.Hl=d.getAttribute("op");if(d.getAttribute("rc"))m.ih=parseInt(d.getAttribute("rc"),10);if(d.getAttribute("cc"))m.eh=parseInt(d.getAttribute("cc"),10);if(d.getAttribute("ap"))g=parseInt(d.getAttribute("ap"),10),m.dh=0>g||8<g?7:g;if(d.getAttribute("ah"))m.hh=parseInt(d.getAttribute("ah"),10);if(d.getAttribute("av"))m.jh=parseInt(d.getAttribute("av"),
10);if(d.getAttribute("id"))m.id=parseInt(d.getAttribute("id"),10)||0;if(d.getAttribute("vs"))m.isVisible=Boolean(d.getAttribute("vs"));if(d.getAttribute("ju"))m.textAlign=ml[parseInt(d.getAttribute("ju"),10)];if(d.getAttribute("pd")&&(m.Le=1,0==parseInt(d.getAttribute("pd"),10)))m.Le=0;if(d.getAttribute("bc"))m.backgroundColor=parseInt(d.getAttribute("bc"),16);if(d.getAttribute("bo"))m.opacity=parseInt(d.getAttribute("bo"),10)/100;if(d.getAttribute("fc"))m.fh=parseInt(d.getAttribute("fc"),16);if(d.getAttribute("sd"))m.Il=
parseInt(d.getAttribute("sd"),10);g=parseInt(d.getAttribute("d"),10)||1E3*parseFloat(d.getAttribute("dur"))||2147483647;d={kd:f,aa:g,H:m,ed:parseInt(d.getAttribute("id"),10)};f=new rl(d)}}this.Db[e]=f;this.rd.push(f);break;case "text":if(e=ql(a[b]),this.Bb.push(e),d=e.jd,this.Db[d]){d=this.Db[d];e=e.fc();if(""!=d.pd)d.gh=j;d.pd+=e}}break;default:this.rd.push(sl());a=this.Fa.firstChild.childNodes;b=0;for(c=a.length;b<c;b++)this.Bb.push(ql(a[b]))}};tl.prototype.Bb=k;tl.prototype.rd=k;
tl.prototype.Db=k;var vl=function(a,b){this.start=a;this.end=b;this.Sl=ul++},ul=0;vl.prototype.contains=function(a,b){return a>=this.start&&a<this.end&&(b==k||a<b&&b<=this.end)};new vl(0,0);jg();var wl=eg("yt.player.logger");wl.Ec(Zf);var xl=function(a){this.gf=a.languageCode;this.Nd=a.languageName;this.Qi=a.languageOriginal;this.id=a.id;this.nc=a.is_default};n=xl.prototype;n.gf=k;n.Nd=k;n.Qi=k;n.id=k;n.nc=l;var yl=function(a){a=a||{};this.of=a.format;this.Ve=a.languageCode||"";this.ff=a.languageName;this.Ga=a.kind;this.sa=a.name;this.ki=a.id;this.li=a.is_servable;this.nc=a.is_default;this.mi=a.is_translateable};n=yl.prototype;n.ff=k;n.Ga=k;n.sa=k;n.ki=k;n.li=l;n.nc=l;n.mi=l;n.of=1;n.getName=function(){return this.sa};n.getFormat=function(){return this.of};
var zl=function(a){var b=[a.ff];if(a.Ga){var c="asr"==a.Ga?P("HTML5_SUBS_TRANSCRIBED"):a.Ga;b.push(" (",c,")")}a.sa&&b.push(" - ",a.sa);a.Kb&&b.push(" >> ",a.Kb.Nd);return b.join("")};yl.prototype.toString=function(){var a=[this.Ve,": ",this.sa," (",this.Ga,")"];this.Kb&&a.push(" >> ",this.Kb.Nd);return a.join("")};var Al=function(a){this.kf=[];this.Hf=[];this.sc=[];if(a&&a.firstChild){this.Fa=a;for(var a=this.Fa.getElementsByTagName("track"),b=a.length,c=0;c<b;c++){var d=parseInt(a[c].getAttribute("formats"),10)||1,e=a[c].getAttribute("lang_code"),f=a[c].getAttribute("lang_translated"),g=a[c].getAttribute("name"),m=a[c].getAttribute("kind")||"",p=a[c].getAttribute("id"),x="true"==a[c].getAttribute("lang_default"),D="true"==a[c].getAttribute("cantran");this.Ud(new yl({format:d,languageCode:e,languageName:f,
name:g,kind:m,id:p,is_servable:j,is_default:x,is_translateable:D}))}a=this.Fa.getElementsByTagName("target");b=a.length;for(c=0;c<b;c++)d=a[c].getAttribute("lang_code"),e=a[c].getAttribute("lang_translated"),f=a[c].getAttribute("lang_original"),g=a[c].getAttribute("id"),m="true"==a[c].getAttribute("lang_default"),this.Hf.push(new xl({languageCode:d,languageName:e,languageOriginal:f,id:g,is_default:m}))}};n=Al.prototype;n.Fa=k;n.kf=k;n.Hf=k;n.sc=k;n.Vd=-1;n.eb=function(){return this.sc};n.$d=function(){return this.Vd};
n.Ud=function(a){switch(a.Ga){case "asr":this.kf.push(a);break;default:if(a.nc)this.Vd=this.sc.length;this.sc.push(a)}};var Bl=function(a,b,c){this.Md=a;this.Z=b;this.Ff=!!c};n=Bl.prototype;n.Md="";n.Z=k;n.Ff=l;n.Vd=0;n.cb=k;n.eb=function(){return this.cb.eb()};n.$d=function(){return this.cb.$d()};n.Ud=function(a){this.cb.Ud(a)};
var El=function(a){var b=Cl,c=a.cb.$d();0>c||Dl(a,a.cb.eb()[c],b)},Dl=function(a,b,c){var d=a.Md,e={v:a.Z,type:"track",lang:b.Ve,name:b.getName(),kind:b.Ga,fmt:b.getFormat()};if(b.Kb)e.tlang=b.Kb.gf;d=ze(d,e);wl.info("Loading caption track from: "+d);a=r(function(a){a=new tl(a.responseXML);c(a,b)},a);Qg(d,a)},Fl=function(a,b){var c=a.Md,d={type:"list",tlangs:1,v:a.Z,fmts:Number(l)};a.Ff&&(d.asrs=1);c=ze(c,d);wl.info("Getting track list from: "+c);d=r(function(a){this.cb=new Al(a.responseXML);b()},
a);Qg(c,d)};var Gl=k,Hl=k,Il=-1,Jl=l,Kl=0,Ll=0,Nl=function(a){if(Gl)a();else if("true"!=R(C("watch-captions-container"),"disabled")){var b=new Bl(N("TTS_URL"),N("VIDEO_ID"));Fl(b,function(){Ml();a()});Gl=b}},Ml=function(){var a=Gl,b=Gl.eb(),c=b.length;if(0>=c)T("watch-captions-not-found");else{var d=C("watch-captions-container");if(1<c){var e=document.createElement("select");e.id="watch-captions-track-selector";for(var f=0;f<c;++f){var g=b[f],m=document.createElement("option"),g=wc(zl(g));m.appendChild(g);m.value=
f;e.appendChild(m)}S(e,"change",function(){Dl(Gl,Gl.eb()[this.value],Cl)});d.appendChild(e)}b=document.createElement("div");b.id="captions-scrollbox";S(b,"mouseover",function(){Jl=j});S(b,"mouseout",function(){Jl=l});d.appendChild(b);El(a)}},Cl=function(a,b){var c=a.Bb;Il=-1;Hl=a;Ed(Kl);var d=C("captions-scrollbox");d.innerHTML="";var e=C("watch-captions-track-selector");if(e)for(var f=Gl.eb(),g=0,m=f.length;g<m;++g)if(f[g]==b){e.options[g].selected=j;break}g=0;for(m=c.length;g<m;++g){var e=c[g],
f=document.createElement("div"),p=e.Ea/1E3;f.id="cp-"+g;f.className="cpline";Q(f,"time",p+"");f.onmousedown=function(a){Tk().seekTo(parseInt(R(this,"time"),10),j);return je(a)};d.appendChild(f);var x=document.createElement("div");x.className="cptime";x.innerHTML=Math.floor(p/60)+":"+(10>p%60?"0":"")+Math.floor(p%60);f.appendChild(x);p=document.createElement("div");p.className="cptext";p.innerHTML=e.fc();f.appendChild(p)}Kl=Cd(Ol,500)},Ol=function(){for(var a=Tk().getCurrentTime(),b=Hl.Bb,c=Il,d=c;;){var e=
0<=d?b[d].Ea/1E3:-1;if(a+0.5<e)d-=1;else if(e=d+1<b.length?b[d+1].Ea/1E3:1E6,a+0.5>e)d+=1;else break}d!=c&&(0<=c&&(a=C("cp-"+c),w(a,"cpline-highlight")),0<=d&&(a=C("cp-"+d),v(a,"cpline-highlight")),Il=d,Jl||Pl(C("cp-"+(3<=d?d-3:0))))},Pl=function(a){Ed(Ll);var b=C("captions-scrollbox"),c=Math.min(a.offsetTop-b.offsetTop,b.scrollHeight-b.offsetHeight),d=0;Ll=Cd(function(){var a=c-b.scrollTop,f=Math.round(100*a/(1E3-50*d));Math.abs(a)<=Math.abs(f)||20<d?(b.scrollTop=c,Ed(Ll)):(b.scrollTop+=f,d++)},
50)};var Rl=function(a,b){var c=C("flag-video-form"),d=C("flag-video-menu");c&&d&&new Ql(c,d,a,b)},Ql=function(a,b,c,d){this.i=a;this.I=b;S(this.i,"submit",r(this.Th,this));ee(this.I,r(this.Sh,this));S(C("flag-video-cancel"),"click",function(a){a.preventDefault();c()});this.dc=d};
Ql.prototype.Sh=function(a){var b;b=a.currentTarget;var c=Sl(this,b),a=R(b,"show-textbox-with-label"),d=!!R(b,"include-time"),e=!!R(b,"show-hate-group"),f=R(b,"popup-url"),g=R(b,"result-message")||"default";b=!!R(b,"no-post");var m=c.di;this.i.reason.value=c.reason;this.i.sub_reason.value=m;c=C("flag-video-more-info-comment");if(a)C("flag-video-more-info-textarea-label").innerHTML=a;hf(c,!!a);hf(C("flag-video-more-info-time"),d);hf(C("flag-video-more-info-hate-group"),e);f&&eh(f,{target:"atmfc",width:900,
height:700,left:0,top:0,status:"yes",toolbar:"no",menubar:"no",location:"no"});b?(U(this.i),Tl(g)):(Q(this.i,"result-message",g),T(this.i))};var Sl=function(a,b){var c=Ch.getInstance(),d=Kh(c,a.I);Hh(c,d);c=c.getContent(d);d=G("label",b);c.innerHTML=Lc(d);c=F("selected",a.I);u(c,function(a){w(a,"selected","child-selected")});v(b,"selected");c="";if(d=R(b,"subreason")||""){var e=I(b.parentNode,"li"),c=R(e,"reason")||"";v(e,"selected","child-selected")}else c=R(b,"reason")||"";return{reason:c,di:d}};
Ql.prototype.Th=function(a){a.preventDefault();var b=C("flag-video-submit");b.disabled=j;var c=R(this.i,"result-message");V(this.i.action,{format:"XML",method:"POST",Ra:$c(this.i),c:function(){Tl(c);this.dc.call(o)},l:function(a,c){Ul();var f=C("flag-video-error");if(c&&c.error_message)G("yt-alert-content",f).innerHTML=c.error_message;T(f);b.disabled=l},n:this})};
var Tl=function(a){Ul();U("flag-video-form-container");T("flag-video-result-"+a)},Ul=function(){var a=F("flag-video-result",C("flag-video-results-container"));u(a,function(a){U(a)})};var jl,am=function(a){if(N("ALLOW_RATINGS")){var b;if(b=!Vl())N("YPC_CAN_RATE_VIDEO")?b=l:(Wl("watch-actions-rental-required"),b=j),b=!b;b&&(N("YPC_SHOW_VPPA_CONFIRM_RATING")&&!confirm(P("VPPA_CONFIRM"))?Xl():(Yl(),ll(a,{Eg:N("PLAYBACK_ID"),Ce:N("STATION_ID"),c:function(b,d){y(C("watch-like-unlike"),a?"unliked":"liked",a?"liked":"unliked");Zl(d.html_content);var e=C("watch-like-share-plusone");e&&new Sk(e,d.video_id,d.video_url,d.lang,d.session_index);Bi(C("watch-actions-ajax"))},l:$l})))}else Wl("watch-actions-ratings-disabled")},
cm=function(a,b){var c=a||C("watch-flag");if(bm(c)&&!Vl()){Yl();var d=0,e=Tk();e&&e.pauseVideo&&(e.pauseVideo(),d=e.getCurrentTime());d=Math.floor(d);e=Math.floor(d/60);d={action_get_flag_video_component:1,video_id:N("VIDEO_ID"),t_mins:e,t_secs:d-60*e};b&&(d.from_dislike=1);V("/watch_ajax",{format:"XML",method:"GET",g:d,c:function(a,b){Zl(b.html_content);Rl(function(){Xl()},function(){c.disabled=j})},l:$l})}},em=function(a,b){if(bm(a)){var c=dm("watch-actions-share");if(jl)Wl("watch-actions-share"),
jl.xa();else{var d=N("VIDEO_ID"),e=k;Pk()&&(e=Lk?Ik().za():k);Yl();jl=new hl(c,d,e,function(){Wl("watch-actions-share")})}b?jh("shareOpenedFromFlash",i,i):jh("shareOpenedFromActionBar",i,i);var f=Tk(),g=Cd(function(){var b=z(a,"active");if(!f||!b)Ed(g);else{for(var b=[],c=Math.floor(f.getCurrentTime());0<c;)b.unshift(c%60),c=Math.floor(c/60);for(;2>b.length;)b.unshift(0);b=Wa(b,function(a,b){return 0<b&&10>a?"0"+a:a});kl(b.join(":"))}},1E3);Si("convShareUrl")}},fm=function(a,b){var c={action_get_addto_success:1,
video_id:a};b&&(c.favorite=j);V("/watch_ajax",{format:"XML",method:"GET",g:c,c:function(a,b){Zl(b.html_content)},l:$l})},bm=function(a){var b=!z(a,"active");Xl();b&&(v(a,"active"),mi(ki.getInstance(),a));return b},Yl=function(){Wl("watch-actions-loading")},Zl=function(a){dm("watch-actions-ajax").innerHTML=a;Wl("watch-actions-ajax")},$l=function(a,b){var c=b&&b.error_message;c||(c=P("WATCH_ERROR_MESSAGE"));dm("watch-error-string").innerHTML=c;Wl("watch-actions-error")},gm={},dm=function(a){a in gm||
(gm[a]=C(a));return gm[a]},Wl=function(a){var b=dm("watch-actions-area-container"),a=dm(a),c=dm("watch-actions-loading"),d=dm("watch-actions-area");if(!jf(b))b.style.height="0px",T(b);U(c);T(a);v(b,"transitioning");var e=d.offsetHeight+"px";O(function(){b.style.height=e},0);O(function(){if(b.style.height==e)w(b,"transitioning"),b.style.height="auto"},500)},Xl=function(){var a=dm("watch-actions-area-container");U(a);a=F("watch-actions-panel",a);u(a,function(a){U(a)});dm("watch-actions-ajax").innerHTML=
"";var a=dm("watch-actions"),b=dm("watch-subactions"),a=E("button",k,a);b&&(b=E("button",k,b),hb(gb(a),gb(b)));u(a,function(a){w(a,"active")})},Vl=function(){return!N("LOGGED_IN")?(Wl("watch-actions-logged-out"),j):l};var hm,im,km=function(a){this.qb=a;this.I=C("shared-addto-menu");this.Xb=R(this.qb,"feature")||"";this.Nc=z(this.qb,"watch");this.mb=R(this.qb,"video-ids")||"";this.B=this.mb.split(",");(a=G("sign-in",this.I))?S(a,"click",r(this.Rh,this)):jm(this)},jm=function(a){var b={action_get_dropdown:"1"};if(a.Xb)b.feature=a.Xb;V("/addto_ajax",{Kc:j,format:"XML",method:"GET",n:a,g:b,c:function(a,b){this.I.innerHTML=b.html_content||"";A(this.I,"ie",B);this.ya();lm(this)}})};
km.prototype.ya=function(){this.e={};this.e.list=C("addto-list-panel");this.e.hc=C("addto-list-error-panel");this.e.ka=C("addto-note-input-panel");this.e.me=C("addto-note-saving-panel");this.e.Me=C("addto-note-saved-panel");this.e.qd=C("addto-note-error-panel");this.e.la=C("addto-create-panel");this.ic=this.e.list;fe(this.e.list,"click",r(this.lh,this),"yt-uix-button-menu-item");this.bc=G("playlist-save-note",this.e.ka);S(this.bc,"click",r(this.mh,this));var a=G("close-button",this.I);S(a,"click",
r(this.kh,this))};var lm=function(a){a=F("playlist-name",a.e.list);u(a,function(a){var c=C(a),d=Xd(c),e=c.innerHTML!=d;c.innerHTML=d;if(e)a=Sd(a,"yt-uix-button-menu-item"),a.title=R(a,"possible-tooltip")})};
km.prototype.lh=function(a){a.stopPropagation();var b=a.currentTarget;mi(ki.getInstance(),b);this.ld=l;var c=a=k,d="";if(d=R(b,"list-action"))"create-playlist"==d?mm(this):"favorites"==d?(this.ld=j,nm(this,"FL"),om(this)):("watch-later"==d?(c="WL",d=b.innerHTML):(c="PL",a=d,b=G("playlist-name",b),d=R(b,"original-html")),nm(this,c,a),1<this.B.length?om(this):pm(this,d))};
var pm=function(a,b){G("addto-note-title",a.e.ka).innerHTML=b;qm(a,a.e.ka,j);var c=G("close-note",a.I);T(c);var d=C("addto-note");S(d,"keydown",r(a.bf,a));S(d,"paste",r(a.bf,a));rm(a.e.ka,function(){d.focus()})},rm=function(a,b){if(b){var c=Qb?"webkitTransitionEnd":Ob?"oTransitionEnd":Pb?"transitionend":k;c?ce(a,c,function(){b()}):b()}};
km.prototype.bf=function(a){var b=a.target,c=G("addto-note-label",this.e.ka);O(r(function(){var a=/^[\s\xa0]*$/.test(b.value);a?T(c):U(c);!a&&this.D&&this.Mc?Vd(this.bc,j):Vd(this.bc,l)},this),0)};
var qm=function(a,b,c){var c=c?"slide":"fade",d=["fade","slide"];y(a.ic,d,c);y(b,d,c);if(z(b,"dismissed-panel"))w(b,"dismissed-panel"),w(a.ic,"active-panel");else{for(var c=a.ic,d=ob(c),e=l,f=0;f<d.length;f++)"active-panel"==d[f]&&(jb(d,f--,1),e=j);if(e)d.push("dismissed-panel"),c.className=d.join(" ")}v(b,"active-panel");a.ic=b},mm=function(a){qm(a,a.e.la,j);sm(a);Jd(a.I,"video-ids");var b=C("addto-create-playlist");S(b,"keydown",r(a.Cd,a));S(b,"paste",r(a.Cd,a));rm(a.e.la,function(){b.focus()});
var c=G("addto-create-cancel-button",a.e.la);S(c,"click",r(function(){om(this)},a));c=G("create-playlist-button",a.e.la);S(c,"click",r(a.Ih,a))},sm=function(a){a.Oe=G("addto-create-playlist",a.e.la);a.Xe=G("addto-create-playlist-label",a.e.la);a.We=G("create-playlist-button",a.e.la);a.yd=G("privacy-form",a.e.la);fe(a.yd,"click",r(a.Cd,a),"playlist-privacy-option")};
km.prototype.Ih=function(){var a=this.Oe.value;this.bh=j;var b=parseInt(cd(this.yd),10);nm(this,"PL",k,a,b);1<this.B.length?om(this):pm(this,a)};km.prototype.Cd=function(){O(r(function(){var a=/^[\s\xa0]*$/.test(this.Oe.value);a?T(this.Xe):U(this.Xe);var b=cd(this.yd);a||!b?Vd(this.We,l):Vd(this.We,j)},this),0)};km.prototype.kh=function(){om(this)};
var om=function(a){var b=Ch.getInstance(),c=Kh(b,a.I);c&&R(c,"video-ids")==a.mb&&Hh(b,c)},nm=function(a,b,c,d,e){a.ha=b;a.Nc&&(Xl(),Yl());Qk({se:a.mb,re:a.ha,jg:c,ve:d,ue:e,Zc:a.Xb,c:a.Cg,l:a.Bg,n:a});Jd(a.I,"video-ids");b="";switch(a.ha){case "PL":b=d?"new_pl":"pl";break;case "FL":b="fav";break;case "WL":b="wl"}d={list:b,feature:a.Xb};if((a=I(a.qb,"a",k))&&a.href)a=xe(a.href),d.link_feature=a.feature||"";a=te(d);jh("addto",a,i)};n=km.prototype;
n.Cg=function(a,b){this.D=b.list_id||"";this.Mc=b.setvideo_id||"";var c=b.html_content||"",d=b.list_url||"";if(this.D&&this.Mc){var e=G("addto-note-title",this.e.ka),f=document.createElement("a");f.href=d;f.innerHTML=e.innerHTML;zc(e);e.appendChild(f);/^[\s\xa0]*$/.test(C("addto-note").value)||Vd(this.bc,j)}if(this.Nc)fm(this.B[0],this.ld);else if(d=Sd(this.qb,"ux-thumb-wrap"))(e=G("video-in-quicklist",d))&&Ac(e),e=document.createElement("span"),e.className="video-in-quicklist",e.innerHTML=c,d.appendChild(e);
c=P("PLAYLIST_BAR_ADDED_TO_PLAYLIST");this.ld&&(c=P("PLAYLIST_BAR_ADDED_TO_FAVORITES"));Nk(this.ha,this.D,this.B,c)};
n.Bg=function(a,b){var c=b&&b.error_message;if(c){G("error-details",this.e.hc).innerHTML=c;var c=G("show-menu-link",this.e.hc),d=S(c,"click",r(function(a){a.preventDefault();be(d);w(this.e.ka,"dismissed-panel","fade","slide");a=G("close-note",this.I);U(a);this.bh?qm(this,this.e.la,j):qm(this,this.e.list,j)},this));if(c=C("addto-create-name"))c.disabled=l;w(this.e.hc,"dismissed-panel","fade","slide");qm(this,this.e.hc)}else om(this);this.Nc&&$l(0,b)};
n.mh=function(){V("/playlist_bar_ajax",{method:"POST",Kc:j,g:{action_set_playlist_item_annotation:1},j:{annotation:C("addto-note").value,video_id:this.mb,playlist_id:this.D,setvideo_id:this.Mc,session_token:Vg.playlist_bar_ajax},c:this.lg,l:this.kg,n:this});qm(this,this.e.me)};n.lg=function(){var a=G("addto-note-title",this.e.ka),b=Pd(a);v(b,"yt-uix-tooltip-reverse");G("panel-content",this.e.Me).appendChild(b);qm(this,this.e.Me);O(r(function(){mi(ki.getInstance(),b);om(this)},this),3E3)};
n.kg=function(a,b){var c=b&&b.errors;if(c){var d=G("error-details",this.e.qd);zc(d);u(c,function(a){var b=document.createElement("li");b.innerHTML=a;d.appendChild(b)});var c=G("add-note-link",this.e.qd),e=S(c,"click",r(function(a){a.preventDefault();be(e);w(this.e.me,"dismissed-panel");qm(this,this.e.ka)},this));qm(this,this.e.qd)}else om(this)};
n.Rh=function(){var a=ze("/addto_ajax",{action_redirect_to_signin_with_add:1,list_type:"WL",video_ids:this.mb,next_url:document.location}),b=document.createElement("form");b.action=a;b.method="POST";a=document.createElement("input");a.type="hidden";a.name="session_token";a.value=Vg.addto_ajax_logged_out;b.appendChild(a);document.body.appendChild(b);b.submit()};var tm=l;var um=-1,xm=function(){-1==um&&(um=parseInt(md("ACTIVITY","0"),10),S(document,"keypress",vm),S(document,"click",wm))},vm=function(){ym()},wm=function(){ym()},ym=function(){var a=na();1E3>a-um||(um=a,ld("ACTIVITY",""+a))},zm=function(){return na()-um};var Am=function(a,b,c,d,e){this.z=k;this.hi=c;this.Xh=a;this.Yh=b;this.ei=d;this.gi=N("GOOGLEPLUS_HOST")+(e!=k?"/u/"+e:"")+"/_/notifications/frame#pid=36";this.fi=C(a);this.xb=C(b)},Bm=function(a,b,c,d){return{onOpen:r(function(a){return a.openInto(c)},a),onReady:r(function(){b.showOnepick&&d&&b.showOnepick()},a),onClose:function(a){b.hideOnepick&&d&&b.hideOnepick();a.remove()}}},Cm=function(a,b,c){if("undefined"===typeof c)a[b]();else a[b](c)};n=Am.prototype;
n.Cb=function(a){var b={setNotificationWidgetHeight:r(function(a){this.fi.style.height=a},this),setNotificationText:r(function(a){this.hi(parseInt(a,10))},this),hideNotificationWidget:function(){a.hideNotificationWidget&&a.hideNotificationWidget()},openSharebox:function(){},onError:function(){}};this.z=iframes.open(this.gi,{style:"iframe-style"},{origin:window.location.protocol+"//"+window.location.hostname,source:"yt",hl:this.ei},b,function(){})};
n.load=function(a){iframes.setHandler("iframe-style",Bm(this,a,this.Xh,l));iframes.setHandler("onepick",Bm(this,a,this.Yh,j));this.Cb(a)};n.close=function(){Cm(this.z,"onHide")};n.Od=function(){Cm(this.z,"onShowNotificationsOnly",{maxWidgetHeight:600})};n.Qd=function(){var a=window.location.href;-1!=a.indexOf("/watch?")&&Cm(this.z,"setPrefill",{items:[{type:"http://web.archive.org/web/20111228172059/http://schema.org/VideoObject",id:a,properties:{url:[a]}}]});Cm(this.z,"onShowShareboxOnly",{maxWidgetHeight:600})};
var Dm=function(a,b){b?Cm(a.z,"onActive"):Cm(a.z,"onIdle")};var Em=function(a,b){this.yb=this.Za=l;this.md=0;this.f=C("sb-container");this.gc=C("sb-button-notify");this.Tg=Td("SPAN","yt-uix-button-content",C("sb-button-notify"));this.xb=C("sb-onepick-target");this.z=new Am("sb-target","sb-onepick-target",r(this.ah,this),a,b);this.z.load({hideNotificationWidget:r(this.He,this),showOnepick:r(this.$g,this),hideOnepick:r(this.Wg,this)});this.Ug=cf(this.xb);this.Ie();S(window,"resize",r(this.Ie,this));S(window,"click",r(this.He,this));xm();Cd(r(this.Vg,this),12E4)};
Em.prototype.kj=function(a){this.Za?(Fm(this),Dm(this.z,j)):(this.yb&&Gm(this),this.Od(),Dm(this.z,l));ie(a)};Em.prototype.lj=function(a){this.yb?Gm(this):(this.Za&&Fm(this),this.Qd());ie(a)};Em.prototype.Od=function(){this.z.close();Hm(this,j,"notif");v(this.gc,"sb-notif-clicked");this.z.Od();this.Za=j};Em.prototype.Qd=function(){this.z.close();Hm(this,j,"sharebox");this.z.Qd();this.yb=j};
var Hm=function(a,b,c){c="sb-card-"+c;b?(y(a.f,"sb-off","sb-on"),v(a.f,c)):(y(a.f,"sb-on","sb-off"),w(a.f,c))},Gm=function(a){Hm(a,l,"sharebox");a.yb=l},Fm=function(a){Hm(a,l,"notif");a.Za=l;w(a.gc,"sb-notif-clicked")};Em.prototype.He=function(){if(this.Za||this.yb)this.z.close(),Fm(this),Gm(this),Im(this)};Em.prototype.ah=function(a){this.md=a;Im(this)};var Im=function(a){a.Za||(Fc(a.Tg,a.md),0==a.md?y(a.gc,"sb-notif-on","sb-notif-off"):y(a.gc,"sb-notif-off","sb-notif-on"))};
Em.prototype.$g=function(){y(this.xb,"sb-off","sb-on")};Em.prototype.Wg=function(){y(this.xb,"sb-on","sb-off")};Em.prototype.Ie=function(){var a=Math.max((pc(window).height-this.Ug.height)/2,0),b=this.xb;ga("top")?Se(b,a+"px","top"):vb("top",ma(Se,b))};Em.prototype.Vg=function(){6E5<zm()?Dm(this.z,l):Dm(this.z,j)};var Jm=function(a){for(var b=Dc(C("picker-container"));b;)a&&a!=b.id&&U(b),b=b.nextElementSibling!=i?b.nextElementSibling:Cc(b.nextSibling)},Km=l;var Lm=k,Mm=k,Nm=function(a){if(!Rd(a.relatedTarget,a.currentTarget)&&(a=I(a.target,k,"lego"),a=R(a,"lego-name")))Lm.innerHTML="",Lm.innerHTML=", "+a},Om=function(a){if(!Rd(a.relatedTarget,a.currentTarget))Lm.innerHTML=""},Pm=function(a){if(!Rd(a.relatedTarget,a.currentTarget)){var a=I(a.target,k,"lego"),b=R(a,"lego-name");if(b)z(a,"append-lego")?(Lm.innerHTML="",Lm.innerHTML=", "+b):(Lm.innerHTML="",v(Mm,"replace-lego-preview"),Lm.innerHTML=b)}},Qm=function(a){if(!Rd(a.relatedTarget,a.currentTarget))Lm.innerHTML=
"",w(Mm,"replace-lego-preview")};var Rm=function(a,b){this.dc=a;this.Gc=b;this.userData={}};Rm.prototype.Nf=function(){return{}};Rm.prototype.ag=function(a){this.dc(this,a)};Rm.prototype.ee=function(a){this.Gc(this,a)};var Sm=function(a,b){Rm.call(this,a,b)};t(Sm,Rm);Sm.prototype.Gb="/subscription_ajax";Sm.prototype.fb={};var Tm=function(a,b){a.Gb=ve(a.Gb,b)};Sm.prototype.Nf=function(){return this.fb};Sm.prototype.ag=function(a){var b=k,c=[P("SUBSCRIBE_SERVER_ERROR")];try{b=Gg(a.responseText)}catch(d){}(a=b&&b.response)?this.dc(this,a):this.Gc(this,c)};Sm.prototype.ee=function(a,b){var c=b?[b]:[P("SUBSCRIBE_SERVER_ERROR")];try{var d=Gg(a.responseText)}catch(e){this.Gc(this,c);return}this.Gc(this,d.errors)};var Um=function(a){pj=W;qj=a},Vm=k,Wm=[],Ym=function(a){Wm.push(a);Vm||Xm()},Xm=function(){if(Wm.length&&!Vm){var a=Wm.shift();if(a){var b=a.Nf();b||(b={});b.session_token=qj;try{var c={method:"POST",postBody:te(b),onComplete:Zm,onException:$m,onError:$m}}catch(d){a.ee({},P("SUBSCRIBE_JS_ERROR"));return}Vm=a;pj(a.Gb,c)}}},Zm=function(a){var b=Vm;Vm=k;Xm();b&&b.ag(a)},$m=function(a){var b=Vm;Vm=k;Xm();b&&b.ee(a)};var cn=function(a){var b=an(a);if("button"==R(b,"subscription-menu-type")){b=Ch.getInstance();b=Dh(b,a);if(G("subscription-menu-loader",b))a.loader=b.innerHTML;bn(a)}else b=an(a),b=C(R(b,"subscription-expandable-id")),jf(b)?(U(b),v(a,"yt-uix-expander-collapsed")):(bn(a),T(b),w(a,"yt-uix-expander-collapsed"))},bn=function(a){if(!R(a,"loaded")){var b=an(a),c=R(b,"subscription-type"),d=R(b,"subscription-xsrf")||"",e=R(b,"subscription-menu-type"),f={},g=R(b,"subscription-value");"playlist"==c?(f.action_get_subscription_form_for_playlist=
1,c="p"):"blog"==c?(f.action_get_subscription_form_for_blog=1,c="b"):"topic"==c?(f.action_get_subscription_form_for_topic=1,c="l"):(f.action_get_subscription_form_for_user=1,c="u");Um(d);d=new Sm(dn,function(){en(b,j)});Tm(d,f);f={};f[c]=g;f.menu_type=e;d.fb=f||{};d.userData.eventTrigger=a;d.userData.subscription=b;Ym(d)}},an=function(a){return I(a,k,"subscription-container")},fn=function(a){var b=I(a,k,"subscription-menu-expandable");if(b)return b.expandableMenuSubscription;a=I(a,k,"yt-uix-button-menu");
b=Ch.getInstance();a=Kh(b,a);return an(a)},gn=function(a){var b=F("subscription-container"),c=R(a,"subscription-type"),d=R(a,"subscription-value");return b=Va(b,function(a){if(R(a,"subscription-type")==c&&R(a,"subscription-value")==d)return j})},en=function(a,b){var c=R(a,"subscription-id"),d=gn(a);u(d,function(a){if(b){"button"==R(a,"subscription-menu-type")?hn(a):jn(a,j);var d=Td(k,"subscription-subscribed-container",a),g=Td(k,"subscribe-button",a),m=Td(k,"subscription-options-button",a);Jd(a,"subscription-id");
U(d);T(g);Jd(m,"loaded")}else d=Td(k,"subscription-subscribed-container",a),g=Td(k,"subscribe-button",a),Q(a,"subscription-id",c),U(g),T(d)})},kn=function(a,b){if("button"==R(a,"subscription-menu-type")){var c=G("subscription-options-button",a),d=Ch.getInstance(),e=Dh(d,c);if(e)e.innerHTML=b,Lh(d,c,e)}else c=C(R(a,"subscription-expandable-id")),d=G("subscription-menu-loader",c),e=G("subscription-menu-body",c),e.innerHTML=b,c.expandableMenuSubscription=a,U(d),T(e)},hn=function(a){var a=G("subscription-options-button",
a),b=Ch.getInstance();Dh(b,a);Hh(b,a);if(a.loader){var c=a.loader,d=Dh(b,a);if(d)d.innerHTML=c,Lh(b,a,d)}Jd(a,"loaded")},jn=function(a,b){var c=Th.getInstance(),d=G("yt-uix-expander",a),e=C(R(a,"subscription-expandable-id"));if(b){var f=G("subscription-menu-loader",e),g=G("subscription-menu-body",e);Jd(d,"loaded");T(f);U(g);g.innerHTML=""}jf(e)&&c.collapse(d)},ln=function(a,b){var c=a.userData.subscription,d=b.html_content;a.userData.eventTrigger.disabled=l;Q(c,"subscription-id",b.id);en(c,l);d&&
(kn(c,d),d=G("subscription-options-button",c),Q(d,"loaded","true"),cn(d),"button"==R(c,"subscription-menu-type")&&Ch.getInstance().ke(d))},mn=function(a){Ac(a.userData.collection)},nn=function(a){en(a.userData.subscription,j)},dn=function(a,b){var c=a.userData.eventTrigger,d=a.userData.subscription,e=b.html_content;Q(d,"subscription-id",b.id);kn(d,e);Q(c,"loaded","true")},on=function(a){var b=a.userData.subscription;a.userData.eventTrigger.disabled=l;a=gn(b);u(a,function(a){"button"==R(a,"subscription-menu-type")?
hn(a):jn(a,j)})},pn=function(a){if(a=a.userData.eventTrigger)a.disabled=l};var qn=function(){};var rn=function(){};t(rn,qn);rn.prototype.P=function(){var a=0;Tc(this.ib(j),function(b){Sa(b);a++});return a};rn.prototype.clear=function(){var a=Uc(this.ib(j)),b=this;u(a,function(a){b.remove(a)})};var sn=function(){};t(sn,rn);n=sn.prototype;n.set=function(a,b){try{window.localStorage.setItem(a,b)}catch(c){h("Storage mechanism: Quota exceeded")}};n.get=function(a){a=window.localStorage.getItem(a);if(ga(a)||a===k)return a;h("Storage mechanism: Invalid value was encountered")};n.remove=function(a){window.localStorage.removeItem(a)};n.P=function(){return window.localStorage.length};
n.ib=function(a){var b=0,c=new Rc;c.next=function(){b>=window.localStorage.length&&h(Qc);var c=Sa(window.localStorage.key(b++));if(a)return c;c=window.localStorage.getItem(c);if(ga(c))return c;h("Storage mechanism: Invalid value was encountered")};return c};n.clear=function(){window.localStorage.clear()};var tn=function(a){this.Rb=a;this.Sf=new Ig};n=tn.prototype;n.Rb=k;n.Sf=k;n.set=function(a,b){da(b)?this.Rb.set(a,Kg(this.Sf,b)):this.Rb.remove(a)};n.get=function(a){a=this.Rb.get(a);if(a!==k)try{return Gg(a)}catch(b){h("Storage: Invalid value was encountered")}};n.remove=function(a){this.Rb.remove(a)};var un=function(){var a=new sn,b;if(b=a)a:{try{b=!!window.localStorage.getItem;break a}catch(c){}b=l}if(b)this.aj=new tn(a),this.hb=new tn(a)};un.prototype.hb=k;un.prototype.aj=k;un.prototype.getVolume=function(){var a={volume:100,muted:l};if(this.hb){var b={};try{b=this.hb.get("yt-player-volume")||{}}catch(c){this.hb.remove("yt-player-volume")}a.volume=isNaN(b.volume)?100:Math.min(Math.max(b.volume,0),100);a.muted=b.muted==i?l:b.muted}return a};if(!document.getElementById&&document.all)document.getElementById=function(a){return document.all[a]};var vn=l,wn=-1,xn="",yn={},zn=new wf,An=k,Bn=function(){return N("RESUME_COOKIE_NAME")},Cn=function(a,b){var c=Bn();if(c){var d=md(c,"").split(","),d=Va(d,function(b){return 0!=b.indexOf(a)&&b.length});4<=d.length&&d.shift();d.push(a+":"+b);ld(c,d.join(","),1814400)}},Dn=function(a){var b=Bn();if(b){var c=md(b,"").split(","),c=Va(c,function(b){return 0!=b.indexOf(a)});0==c.length?nd(b):ld(b,c.join(","),1814400)}},En=function(){var a=Tk(),b=a.getDuration(),a=Math.floor(a.getCurrentTime()),c=N("VIDEO_ID");
120>=a||a+120>=b?Dn(c):Cn(c,Math.floor(a))},Fn=function(a,b){if(Fd&&!a.addEventListener){var c=b?2*b:50;O(function(){Fn(a,c)},c)}else b&&jh("ael_delayed","delay="+b,i),Gn(a),zn.Pb("READY_STATE_TOPIC",a)},Gn=function(a){a.addEventListener("onStateChange","handleWatchPagePlayerStateChange");a.addEventListener("onPlaybackQualityChange","onPlayerFormatChanged");a.addEventListener("NEXT_CLICKED","yt.www.watch.player.onPlayerNextClicked");a.addEventListener("SETTINGS_CHANGED","yt.www.watch.player.onPlayerSettingsChanged");
a.addEventListener("SIZE_CLICKED","yt.www.watch.player.onPlayerSizeClicked");a.addEventListener("onVolumeChange","yt.www.watch.player.onVolumeChange");a.addEventListener("NEXT_CLICKED","yt.www.watch.player.onPlayerNextClicked");a.addEventListener("SHARE_CLICKED","yt.www.watch.player.onPlayerShareClicked");Bn()&&S(window,"beforeunload",En);ye(window.location.hash).q&&N("WIDE_PLAYER_STYLES")&&Uk(l);var b=C("watch-player");if(b)b.style.background="transparent";Ok(a);An=new un},Hn=function(a,b){var c=
b!=k?b:j,d=Tk();d.seekTo(a,j);if(c)C("watch-video-container")?window.scroll(0,0):window.location.href="#movie_player";d.playVideo()},Jn=function(){if(vn){var a=window.location.hash;a!=xn&&(xn=a,a=ye(a),"t"in a&&a.t!=yn.t&&Hn(In(a.t),l),yn=a)}},In=function(a){var b=0;-1!=a.indexOf("h")&&(a=a.split("h"),b=3600*a[0],a=a[1]);-1!=a.indexOf("m")&&(a=a.split("m"),b=60*a[0]+b,a=a[1]);-1!=a.indexOf("s")?(a=a.split("s"),b=1*a[0]+b):b=1*a+b;return b};var Kn=l,Ln=k,Mn=k,Nn=k,On=k,Pn=function(a){a.addEventListener("onStateChange","yt.www.watch.abandonment.onPlayerStateChange");a.addEventListener("onError","yt.www.watch.abandonment.onError")},Qn=function(a){var b=On,a={event:a,aplid:Ln,abt:Mn,evtm:Math.round(na()-b)};(b=N("PLAYER_CONFIG"))&&b.args&&b.args.plid&&(a.plid=b.args.plid);b&&b.args&&b.args.video_id&&(a.v=b.args.video_id);hh("/player_204?"+te(a))},Rn=function(){Nn&&Qn("userwaiting");Nn=k},Sn=function(){Kn&&Qn("unload")};var Tn,Un;var Vn=function(){var a=C("watch-video-annotation-editable"),b=ra(C("watch-video-annotation-content").innerHTML);b?y(a,["unannotated","editing"],["annotated","not-editing"]):y(a,["annotated","not-editing"],["unannotated","editing"]);C("watch-video-annotation-textarea").value=b},Wn=function(a){if(!R(a,"saving")){Q(a,"saving","true");var b=C("watch-video-annotation-content"),c=Td("textarea",k,a),d=ra(c.value),e={};d||(e["delete"]=1);V(a.action,{format:"JSON",method:"POST",g:e,Ra:$c(a),c:function(){b.innerHTML=
Aa(d)},l:function(){c.value=b.innerHTML},fa:function(){Jd(a,"saving");Vn()}})}};var Xn=function(a,b){rb(a,"selected");var c=parseInt(R(a,"reaction-count"),10)+b;Q(a,"reaction-count",""+c);var d=G("count",a);if(d)d.innerHTML=c},Zn=function(a,b){Yn(a).innerHTML=b},Yn=function(a){var b=Ch.getInstance(),a=Sd(a,Z(b,"menu")),a=Kh(b,a);return b.getContent(a)},$n=function(a,b,c,d){u(c,function(a){Xn(a,1)});Xn(a,b?1:-1);Zn(a,d)};var ao=function(a){var b=a.target;if(!("INPUT"==b.tagName||"TEXTAREA"==b.tagName||"SELECT"==b.tagName))switch(a.keyCode){case 110:Ik().next(j,"keys");break;case 112:a=Ik();(a=ak(a.b,"keys"))&&dh(a);break;case 106:if(a=Tk())b=a.getCurrentTime(),a.seekTo(b-10);break;case 108:if(a=Tk())b=a.getCurrentTime(),a.seekTo(b+10);break;case 107:(a=Tk())&&(2==wn?a.playVideo():a.pauseVideo())}};var bo=function(){var a=K.getInstance();a.Ha(L.be,j);a.save();U("watch_page_survey")};var co=function(a,b,c){var d=a.serverUri||"//web.archive.org/web/20111228172059/http://www.google.com/tools/feedback",e=o.GOOGLE_FEEDBACK_START;o.GOOGLE_FEEDBACK_START_ARGUMENTS=arguments;e?e.apply(o,arguments):(e=document.createElement("script"),e.src=d+"/load.js",document.body.appendChild(e))};var eo;
(function(){function a(a){a=a.match(/[\d]+/g);a.length=3;return a.join(".")}var b=l,c="";if(navigator.plugins&&navigator.plugins.length){var d=navigator.plugins["Shockwave Flash"];d&&(b=j,d.description&&(c=a(d.description)));navigator.plugins["Shockwave Flash 2.0"]&&(b=j,c="2.0.0.11")}else if(navigator.mimeTypes&&navigator.mimeTypes.length)(b=(d=navigator.mimeTypes["application/x-shockwave-flash"])&&d.enabledPlugin)&&(c=a(d.enabledPlugin.description));else try{d=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7"),b=
j,c=a(d.GetVariable("$version"))}catch(e){try{d=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6"),b=j,c="6.0.21"}catch(f){try{d=new ActiveXObject("ShockwaveFlash.ShockwaveFlash"),b=j,c=a(d.GetVariable("$version"))}catch(g){}}}eo=c})();var fo,go,ho,io,jo,ko,lo;lo=ko=jo=io=ho=go=fo=l;var mo=Kb();mo&&(-1!=mo.indexOf("Firefox")?fo=j:-1!=mo.indexOf("Camino")?go=j:-1!=mo.indexOf("iPhone")||-1!=mo.indexOf("iPod")?ho=j:-1!=mo.indexOf("iPad")?io=j:-1!=mo.indexOf("Android")?jo=j:-1!=mo.indexOf("Chrome")?ko=j:-1!=mo.indexOf("Safari")&&(lo=j));var no=fo,oo=go,po=ho,qo=io,ro=jo,so=ko,to=lo;var uo;a:{var vo="",wo,xo;if(no)wo=/Firefox\/([0-9.]+)/;else{if(B||Ob){uo=bc;break a}so?wo=/Chrome\/([0-9.]+)/:to?wo=/Version\/([0-9.]+)/:po||qo?(wo=/Version\/(\S+).*Mobile\/(\S+)/,xo=j):ro?wo=/Android\s+([0-9.]+)(?:.*Version\/([0-9.]+))?/:oo&&(wo=/Camino\/([0-9.]+)/)}if(wo)var yo=wo.exec(Kb()),vo=yo?xo?yo[1]+"."+yo[2]:yo[2]||yo[1]:"";uo=vo}var zo=uo;var Ao=function(){(B?0<=Ja(zo,"7")&&0<=Ja(eo,"9"):no?0<=Ja(zo,"3.5"):to?0<=Ja(zo,"5"):so)||U("reportbug")};var Co=function(){ce(C("help-button"),"click",Bo,j)},Bo=function(){var a=C("help-button");if(a){var b=R(a,"iph-topic-id"),c=N("LOCALE"),d=R(a,"iph-title-text"),e=R(a,"iph-search-button-text"),f=R(a,"iph-anchor-text"),g=document.location.protocol+R(a,"iph-js-url"),m=document.location.protocol+R(a,"iph-css-url");g&&m&&(m=tc("link",{href:m,rel:"stylesheet"}),document.getElementsByTagName("head")[0].appendChild(m),bh(g,function(){var g=q("yt.www.help.init"),m=q("yt.www.help.onButtonClick");g(b,"http://web.archive.org/web/20111228172059/http://www.google.com",
"/support/youtube",c,d,e,f);S(a,"click",m);m()}))}};var Do=function(){(function(){try{for(var a=this;!(a.parent==a);){"$"==a.frameElement.src&&h("odd");a=a.parent}a.frameElement!=k&&h("busted")}catch(b){document.write("--\><plaintext style=display:none><\!--"),window.open("/","_top"),top.location="/"}})()},Eo=function(a){"block"==a.responseText&&Do()};if(window!=window.top){var Fo=document.referrer;window.parent!=window.top?Do():Ae(Fo)||W("/roger_rabbit?"+("location="+encodeURIComponent(Fo)+"&self="+encodeURIComponent(window.location.href)),{onComplete:Eo})};var Go=function(a,b){var c=i,c=b==k?N("XSRF_TOKEN"):b,d=document.createElement("input");d.setAttribute("name",N("XSRF_FIELD_NAME"));d.setAttribute("type","hidden");d.setAttribute("value",c);a.appendChild(d)},Ho=[];var Io=function(a,b,c,d){window.google_ad_client=a;window.google_ad_channel=b;window.google_max_num_ads=1;window.google_ad_output="js";window.google_ad_type="text";window.google_only_pyv_ads=j;if(c)window.google_kw=c,window.google_kw_type="broad";window.dclk_language&&(window.google_language=window.dclk_language);window.google_ad_request_done=d;document.write('<script language="JavaScript" src="http://web.archive.org/web/20111228172059/http://pagead2.googlesyndication.com/pagead/show_ads.js"><\/script>')},Jo=function(){window.dclk_language&&
(window.google_language=window.dclk_language);window.google_ad_client="pub-6219811747049371";window.google_ad_channel="1802068507";window.google_ad_format="300x250_as";window.google_ad_type="text_image";window.google_ad_width=300;window.google_ad_height=250;window.google_alternate_color="FFFFFF";window.google_color_border="FFFFFF";window.google_color_bg="FFFFFF";window.google_color_link="0033CC";window.google_color_text="444444";window.google_color_url="0033CC";document.write('<script language="JavaScript" src="http://web.archive.org/web/20111228172059/http://pagead2.googlesyndication.com/pagead/show_ads.js"><\/script>')},
Lo=function(){if(!window.ppv_fallback_rendered)Ko(),U("pyv-placeholder"),T(window.ppv_fallback_placeholder_id||"ppv-placeholder"),window.ppv_fallback_rendered=j},Ko=function(){U(window.pyv_google_ad_collapse_id||"ad_creative_2")},Mo=function(a,b,c,d,e){var f=Za(b.media_template_data,function(a){return!!a.imageUrl});f&&(a={video_id:f.videoId,ad_type:a,headline:Da(b.line1),image_url:f.imageUrl,description1:Da(b.line2),description2:Da(b.line3),channel_title:f.channelName,test_mode:(!!e).toString(),destination_url:Da(b.url)},
W("/pyv?"+te(a),{method:"GET",update:c,onComplete:d}))},No=function(){var a=C("ppv-container");a&&T(a)},Po=function(){U("ad_creative_2");N("PYV_IS_ALLOWED")?Io("ca-youtube-homepage",N("PYV_AD_CHANNEL")||"",N("PYV_KW")||"",Oo):Lo()},Oo=function(a){var b=C("pyv-placeholder");0==a.length||!b?Lo():Mo("homepage",a[0],b,function(){Ko()})},Ro=function(){if(N("PYV_IS_ALLOWED")){var a="pyvOnBrowse";N("PYV_CATEGORY")&&(a+=" pyvBrowse_"+N("PYV_CATEGORY"));Io("ca-youtube-browse",a,"",Qo)}else Jo()},Qo=function(a){var b=
C("pyv-placeholder");0==a.length||!b?Jo():Mo(N("PYV_NEW_BROWSE")?"new_browse":"browse",a[0],b,function(){U("ad_creative_1")})},So=function(a,b){var c=C(a);c&&(c=E("li","video-list-item",c),u(c,function(a,c){var f=E("a",k,a);u(f,function(a){var d=a.getAttribute("href");if(d&&unescape(d).match(/\/watch(\?|#!)v=/))a.href=b?a.href+("&pvpos="+c):a.href+("&pvnpos="+c)})}))};var Uo=function(a){a=a.replace(";dc_seed=",";kmyd=watch-channel-brand-div;dc_seed=");U("instream_google_companion_ad_div");U("google_companion_ad_div");T("ad300x250");T("watch-channel-brand-div");var b=C("ad300x250");if(b!==k){var c=Math.round(1E4*Math.random());b.innerHTML=['<iframe src="',a,'" name="ifr_300x250ad',c,'" id="ifr_300x250ad',c,'" width="300" height="250" marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling="no"></iframe>'].join("")}To()},Vo=function(a){a=
a.replace(";dc_seed=",";kmyd=watch-longform-ad;dc_seed=");U("instream_google_companion_ad_div");T("watch-longform-ad");T("watch-longform-text");T("watch-longform-ad-placeholder");var b=C("watch-longform-ad-placeholder"),c=Math.round(1E4*Math.random());b.innerHTML=['<iframe src="',a,'" name="ifr_300x60ad',c,'" id="ifr_300x60ad',c,'" width="300" height="60" marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling="no"></iframe>'].join("");To()},Wo=function(a){var b=C("watch-longform-ad-placeholder");
a?(U("instream_google_companion_ad_div"),T("watch-longform-ad"),T("watch-longform-text"),T("watch-longform-ad-placeholder"),b.innerHTML=a):U("watch-longform-ad");To()},Xo=function(a,b){var c="watch-channel-brand-div",d="ad300x250",e=300,f=250;"video"==a&&(c="watch-longform-ad",d="watch-longform-ad-placeholder",e=300,f=60,U("instream_google_companion_ad_div"));var g=decodeURIComponent(b);C(d).innerHTML=['<iframe name="fw_ad" id="fw_ad" ','width="'+e+'" height="'+f+'" ','marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling="no"></iframe>'].join("");
var m=C("fw_ad"),m=m.contentWindow?m.contentWindow:m.contentDocument.document?m.contentDocument.document:m.contentDocument,e=navigator.userAgent.toLowerCase(),d=-1!=e.indexOf("msie"),e=-1!=e.indexOf("opera");m.document.open();m.document.write(g);d||e?O(function(){m.document.close()},7500):m.document.close();T(c);To()},Yo=function(){T("watch-channel-brand-div");U("ad300x250");C("google_companion_ad_div").style.height="250px";To()},Zo=function(){U("watch-longform-ad");To()},$o=function(){U("watch-channel-brand-div");
To()},To=function(){var a=q("yt.www.watch.ads.handleAdLoaded");a&&a.call()},ap=function(a){Ad("POPOUT_AD_SLOTS",a)},bp=function(){var a=C("watch-longform-popup");if(a)a.disabled=j},cp=function(a){var b=C("watch-longform-popup");if(b)b.disabled=l;ap(a)},dp=function(a){window.google_ad_output="html";a?(window.google_ad_height="60",window.google_ad_format="300x60_as",window.google_container_id="instream_google_companion_ad_div"):(window.google_ad_height="250",window.google_ad_format="300x250_as",window.google_container_id=
"google_companion_ad_div")},ep=function(a){a?(U("watch-longform-ad-placeholder"),U("watch-channel-brand-div"),T("watch-longform-text"),T("watch-longform-ad"),T("instream_google_companion_ad_div")):(U("ad300x250"),U("watch-longform-ad"),T("google_companion_ad_div"),T("watch-channel-brand-div"));To()},fp=function(){U("instream_google_companion_ad_div");U("watch-longform-text");U("watch-longform-ad-placeholder");To()};s("yt.www.watch.ads.showForcedMpu",function(a){C("ad300x250").innerHTML=['<iframe src="',a,'" name="ifr_300x250ad" id="ifr_300x250ad" width="300" height="250" marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling="no"></iframe>'].join("");T("ad300x250")});
s("yt.www.watch.ads.handleMoveGutCompanion",function(a){var a=a?C("instream_google_companion_ad_div"):C("google_companion_ad_div"),b=C("yt-gut-content");b?b.innerHTML="":(b=document.createElement("div"),b.id="yt-gut-content");if(a)a.innerHTML="",a.appendChild(b);To()});s("yt.www.watch.ads.setGutSlotSizes",function(a,b){var c=N("gut_slot");c&&(c=c.getSizes(),bb(c),b&&c.push(N("yt_gut_invideo_size")),a&&c.push(N("yt_gut_instream_size")))});s("yt.www.watch.ads.handleSetCompanion",Uo);
s("yt.www.watch.ads.handleSetCompanionForInstream",Vo);s("yt.www.watch.ads.handleSetCompanionForLongform",Wo);s("yt.www.watch.ads.handleSetCompanionForFreewheel",Xo);s("yt.www.watch.ads.handleHideCompanion",Yo);s("yt.www.watch.ads.handleHideCompanionForInstream",Zo);s("yt.www.watch.ads.disablePopoutButton",bp);s("yt.www.watch.ads.enablePopoutButton",cp);s("yt.www.watch.ads.handleCloseMpuCompanion",$o);s("yt.www.watch.ads.updatePopoutAds",ap);s("yt.www.watch.ads.handleSetAfvCompanionVars",dp);
s("yt.www.watch.ads.handleShowAfvCompanionAdDiv",ep);s("yt.www.watch.ads.handleHideAfvInstreamCompanionAdDiv",fp);
s("yt.www.ads.pyv.pyvWatchAfcCallback",function(a){if(0==a.length)No(),N("PYV_TRACK_RELATED_CTR")&&(So("watch-related-grid",l),So("watch-related",l),So("watch-channel-videos-panel",l));else{var b=C("watch-channel-videos-panel");b&&!N("IS_BRANDED_WATCH")&&v(b,"yt-uix-expander-collapsed");Mo("watch_related",a[0],k,function(a){var a=Ug(Sg(a.responseXML),"html_content")||"",b=C(window.pyv_related_box_id||"watch-related");b&&0!=b.innerHTML.indexOf(a)&&(b.insertBefore(xc(a),b.firstChild),N("PYV_TRACK_RELATED_CTR")&&
(So("watch-related",j),So("watch-channel-videos-panel",j)));if((b=C("watch-related-grid"))&&0!=b.innerHTML.indexOf(a))b.insertBefore(xc(a),b.firstChild),N("PYV_TRACK_RELATED_CTR")&&So("watch-related-grid",j)},window.google_adtest&&"on"==window.google_adtest)}});
s("yt.www.ads.pyv.pyvSearchAfcCallback",function(a){var b=C("pyv-ads");0!=a.length&&b&&(u(a,function(a){var b=a.media_template_data[0];a.line1=Da(a.line1);a.line2=Da(a.line2);a.line3=Da(a.line3);a.url=Da(a.url);b.imageUrl=Da(b.imageUrl);b.channelName=Da(b.channelName)}),a={pyv_ads:Kg(new Ig(i),a),ad_type:"search"},W("/pyv",{method:"POST",postBody:te(a),update:b}))});s("yt.www.ads.pyv.pyvHomeAfcCallback",Oo);s("yt.www.ads.pyv.showPpvAdInYvaSpot",Lo);s("yt.www.ads.pyv.pyvHomeRequestAds",Po);
s("yt.www.ads.pyv.pyvBrowseRequestAds",Ro);s("yt.www.ads.pyv.showPpvOnWatch",No);
s("yt.www.ads.pyv.loadPyvIframe",function(a){var b=window.location.href;if(b.indexOf("#")==b.length-1&&Qb)window.location.hash="#!";var b=document.body,c=kc(b),d=[];d.push("<!DOCTYPE html>");d.push("<html><head>",a,"</head><body>",i,"</body></html>");a=c.al("iframe",{frameborder:0,style:"border:0;vertical-align:bottom;",src:'javascript:""'});b.appendChild(a);b=d.join("");a=a.contentDocument||a.contentWindow.document;a.open();a.write(b);a.close()});
s("yt.www.ads.pyv.loadPyvAfsScript",function(a){bh("/pyv_afs_ads?query="+a)});Bd("pyv_related_box_id");s("setCompanion",Uo);s("setInstreamCompanion",Vo);s("setLongformCompanion",Wo);s("setFreewheelCompanion",Xo);s("closeInPageAdIframe",Yo);s("hideInstreamCompanion",Zo);s("disablePopout",bp);s("enablePopout",cp);s("closeMpuCompanion",$o);s("updatePopAds",ap);s("setAfvCompanionVars",dp);s("showAfvCompanionAdDiv",ep);s("hideAfvInstreamCompanionAdDiv",fp);s("show_ppv_in_yva_spot",Lo);
s("requestPyvAds",Po);s("pyvHomeRequestAds",Po);s("pyvBrowseRequestAds",Ro);window.yt=window.yt||{};s("_gel",C);s("_hasclass",z);s("_addclass",v);s("_removeclass",w);s("_toggleclass",rb);s("_showdiv",T);s("_hidediv",U);s("_ajax",Qg);s("goog.bind",r);s("goog.dom.getElementsByTagNameAndClass",function(a,b,c){return E(a,b,c)});s("goog.dom.getFirstElementChild",Dc);s("goog.array.forEach",u);s("goog.array.indexOf",Ua);s("goog.array.contains",ab);s("yt.dom.hasAncestor",Rd);s("yt.setConfig",Ad);s("yt.getConfig",N);s("yt.registerGlobal",Bd);s("yt.setTimeout",O);
s("yt.setInterval",Cd);s("yt.clearTimeout",Dd);s("yt.clearInterval",Ed);s("yt.setMsg",function(a){zd(wd,arguments)});s("yt.getMsg",P);s("yt.events.listen",S);s("yt.events.unlisten",ge);s("yt.events.stopPropagation",ie);s("yt.events.preventDefault",je);s("yt.events.getTarget",he);s("yt.events.clear",function(){for(var a in Zd)be(a)});s("yt.events.Event",Yd);Yd.prototype.preventDefault=Yd.prototype.preventDefault;Yd.prototype.stopPropagation=Yd.prototype.stopPropagation;s("yt.pubsub.subscribe",yf);
s("yt.pubsub.unsubscribeByKey",function(a){var b=q("yt.pubsub.instance_");return b?b.unsubscribeByKey(a):l});s("yt.pubsub.publish",zf);s("yt.www.init",Bj);s("yt.www.dispose",Cj);S(window,"load",Bj);S(window,"unload",Cj);s("yt.www.logError",Ej);window.onerror=Ej;var gp=function(a,b){var c=b.value,d="";gd(c)?d="rtl":gd(c)||(d="ltr");b.dir=d};s("goog.i18n.bidi.isRtlText",gd);s("goog.i18n.bidi.setDirAttribute",gp);
s("yt.i18n.virtualkeyboard.toggle",function(a,b){a&&(Dg=a,wg("GOOGLE_LANGUAGE_API_VIRTUAL_KEYBOARD",function(){if(Cg){var a=Cg;a.isVisible()?a.setVisible(l):a.setVisible(j)}else Eg||(Eg=j,Fg=b,google.load("elements","1",{packages:"keyboard",callback:"yt.i18n.virtualkeyboard.finishLoading"}))}))});
s("yt.i18n.virtualkeyboard.finishLoading",function(){google.elements.keyboard.setAutoHide(l);google.elements.keyboard.setSendShiftKeyUpEventUponInput(j);google.elements.keyboard.enableMinMaxMode(l);google.elements.keyboard.enableGoogleLogo(l);google.elements.keyboard.enableKeyCodeScheme(l);google.elements.keyboard.helpLink(["http://web.archive.org/web/20111228172059/http://www.google.com/support/youtube/bin/answer.py?answer=1047939&hl=",Fg].join(""));Cg=new google.elements.keyboard.Keyboard(Dg,["masthead-search-term"]);Eg=l});
s("yt.i18n.inputtools.loadInputTools",function(a,b,c){a&&b&&(xg=a,wg("GOOGLE_LANGUAGE_API_INPUT_TOOLS",function(){!zg&&!Ag&&(Ag=j,yg=b,Bg=c,google.load("elements","1",{packages:"inputtools",callback:"yt.i18n.inputtools.finishLoading"}))}))});
s("yt.i18n.inputtools.finishLoading",function(){zg=new google.elements.inputtools.InputToolsController;vb(yg,function(a,c){zg.addPageElements([c])});zg.addInputTools(xg);Bg&&-1!=Bg.indexOf("hi")&&zg.setCurrentInputTool("im_t13n_hi");vb(yg,function(a){a&&zg.showControl(a)});var a=l;u(xg,function(b){0==b.lastIndexOf("vdk",0)&&(a=j)});a&&google.elements.keyboard.helpLink(["http://web.archive.org/web/20111228172059/http://www.google.com/support/youtube/bin/answer.py?answer=1047939&hl=",Bg].join(""));zg.setApplicationName("youtube");Ag=l});
s("yt.style.toggle",lf);s("yt.style.setDisplayed",hf);s("yt.style.isDisplayed",jf);s("yt.style.setVisible",function(a,b){if(a=C(a))a.style.visibility=b?"visible":"hidden"});s("yt.net.ajax.sendRequest",W);s("yt.net.ajax.getRootNode",Sg);s("yt.net.ajax.getNodeValue",Ug);s("yt.net.ajax.setToken",function(a,b){Vg[a]=b});s("yt.net.delayed.register",Yg);s("yt.net.delayed.load",$g);s("yt.net.delayed.markAsLoaded",function(a){a in Wg&&(Xg[a]=j)});s("yt.net.scriptloader.load",bh);
s("goog.dom.forms.getFormDataString",$c);s("yt.uri.buildQueryData",te);s("yt.uri.appendQueryData",ve);s("yt.www.feedback.start",function(a,b,c,d){try{var c=(c||"59")+"",b=b||{},e=N("SESSION_INDEX");try{var f=Tk();f&&f.pauseVideo();var g=Ge.getInstance();b.flashVersion=[g.G,g.va,g.rev].join(".")}catch(m){}a={productId:c,locale:a};e&&(a.authuser=e+"");d&&(a.bucket=d);co(a,b);return l}catch(p){return j}});s("yt.www.feedback.displayLink",Ao);yf("init",Ao);s("yt.www.help.bootstrap.init",Co);
yf("init",Co);s("yt.net.cookies.set",ld);s("yt.net.cookies.get",md);s("yt.net.cookies.remove",nd);s("yt.UserPrefs",K.getInstance());s("yt.UserPrefs.Flags",L);s("yt.UserPrefs.getFlag",K.getInstance().Xc);s("yt.UserPrefs.setFlag",K.getInstance().Zd);s("yt.UserPrefs.getFlag2",K.getInstance().Wb);s("yt.UserPrefs.setFlag2",K.getInstance().Ha);s("yt.UserPrefs.getFlag3",K.getInstance().Yc);s("yt.UserPrefs.setFlag3",K.getInstance().qc);s("yt.UserPrefs.getFlag4",K.getInstance().kl);
s("yt.UserPrefs.setFlag4",K.getInstance().xf);s("yt.window.redirect",dh);s("yt.window.popup",eh);s("yt.www.displayLoading",function(a){C(a).innerHTML='<img src="//web.archive.org/web/20111228172059/http://s.ytimg.com/yt/img/icn_loading_animated-vflff1Mjj.gif">'});yh(Ch);yh(Mh);yh(Sh);yh(Vh);yh(Th);yh(Wh);yh(Yh);yh(Zh);yh($h);yh(ji);yh(ki);s("onYouTubePlayerReady",function(){vn=j;var a=Tk();a&&Fn(a)});s("handleWatchPagePlayerStateChange",function(a){wn=a;switch(a){case 0:uk(Ik())&&Ik().next(l,"autoplay"),N("SHOW_SUBSCRIBE_UPSELL")&&Wk(P("SUBSCRIBE_UPSELL_MESSAGE"))}});
Bd("onYouTubePlayerReady","handleWatchPagePlayerStateChange");s("yt.www.watch.activity.getTimeSinceActive",zm);s("yt.www.watch.activity.setTimestamp",ym);s("yt.www.watch.player.handleEndPreview",function(){var a=Tk(),b=C("watch-checkout-button");a&&a.stopVideo&&a.stopVideo();b?b.click():C("rental-gadget")?Xk():C("rental-overlay-target")&&(a=C("rental-overlay-target"),Yh.getInstance().show(a))});s("yt.www.watch.player.onPlayerSettingsChanged",function(a){Ad("PREFER_LOW_QUALITY",a)});
s("yt.www.watch.player.onPlayerSizeClicked",function(a){N("FULLSCREEN_EXPAND")?A(document.body,"fullscreen",a):(a?ld("wide","1"):ld("wide","0"),Uk(a))});s("yt.www.watch.player.onPlayerNextClicked",function(){Ik().next(j,i)});s("yt.www.watch.player.onVolumeChange",function(a){var b=An;if(b.hb){var c={};c.volume=isNaN(a.volume)?b.getVolume().volume:Math.min(Math.max(a.volume,0),100);c.muted=a.muted==i?b.getVolume().muted:a.muted;try{b.hb.set("yt-player-volume",c)}catch(d){}}});
s("yt.www.watch.player.openPopup",function(a,b,c){var d=k,e=Tk(),a="/watch_popup?v="+a;e&&(a+="&vq="+e.getPlaybackQuality(),d=Math.round(e.getCurrentTime()),e.stopVideo());N("POPOUT_AD_SLOTS")&&(a+="&pop_ads="+N("POPOUT_AD_SLOTS"));d&&10<d&&(a+="#t="+d);eh(a,{width:b,height:c,resizable:j,location:l,statusbar:l,menubar:l,scrollbars:l,toolbar:l})});s("yt.www.watch.player.onPlayerShareClicked",function(){em(C("watch-share"),j)});s("yt.www.watch.activity.init",xm);
s("yt.www.watch.player.updateConfig",function(a){var a=a instanceof Ee?a.kc:a.args,b;var c=ye(window.location.hash);(b=c.t||c.at)?(yn.t=c.t,yn.at=c.at,c=window.location.hash.replace(/\bat=[^&]*&?/,""),window.location.hash=c&&"#"!=c?c:"#!",b=In(b)):b=0;return b?(a.start=b,j):l});s("yt.www.watch.player.init",function(){Jn();Cd(Jn,1E3)});s("yt.www.watch.player.seekTo",Hn);
s("openFull",function(){eh("/watch_popup?v="+N("VIDEO_ID"),{target:"FullScreenVideo",width:screen.availWidth,height:screen.availHeight,resizable:j,fullscreen:j})});s("checkCurrentVideo",function(a,b,c){var d=N("VIDEO_ID"),e=d==a,f=Lk?Ik().za():k,b=!b||b==f;if(d&&(!e||!b))d=k,b&&(d=Ik(),e=Xj(d.b,[a])[0],d=e===i?"":$j(d.b,e)),d||(d=c?c:ze(window.location.href,{v:a,feature:k})),d&&dh(d)});
s("trackAnnotationsEvent",function(a,b,c){var d=N("ANALYTICS_ANNOTATIONS_TRACKER");window._gaq.push(function(){d._trackEvent(a,b,c)})});s("reportFlashTiming",function(){});s("reportTimingMaps",function(a,b){for(var c in a)Y.Cc(c,a[c]);for(var d in b)Y.info(d,b[d]);Y.he();if(N("ENABLE_GPU_PREWARMING")&&(c=C("gpu-pilot-light"),!c))c=document.createElement("canvas"),c.id="gpu-pilot-light",c.style.cssText="width:0px; height:0px; -webkit-transform:rotateY(0deg)",document.body.appendChild(c)});
s("yt.www.watch.playlists.editAnnotation",function(){y(C("watch-video-annotation-editable"),"not-editing","editing");C("watch-video-annotation-textarea").focus();var a=C("watch-video-annotation-form");R(a,"setup")||(Q(a,"setup","true"),a=G("cancel-button",a),S(a,"click",function(a){a.preventDefault();Vn()}))});s("yt.www.watch.playlists.removeAnnotation",function(){var a=C("watch-video-annotation-form");C("watch-video-annotation-textarea").value="";Wn(a)});s("yt.www.watch.playlists.submitForm",function(a){Wn(a)});
s("yt.www.watch.abandonment.init",function(a,b){Ln=a;Mn=b;var c=N("PLAYER_CONFIG"),c=new Ee(c);Pe(function(a){var e=Y.timer||{};if(e.start&&a.isSupported(c.Fb))On=e.start,vn?Pn(Tk()):zn.Eb("READY_STATE_TOPIC",Pn),S(window,"beforeunload",Sn),a=na()-On,a=b-a,0<=a&&(Nn=O(Rn,a),Qn("attempt"));Kn=j})});s("yt.www.watch.abandonment.onPlayerStateChange",function(a){if(Nn)switch(a){case 1:Qn("play");Dd(Nn);Nn=k;Kn=l;break;case 0:Qn("ended"),Dd(Nn),Nn=k,Kn=l}});
s("yt.www.watch.abandonment.onError",function(){Nn&&(Qn("error"),Dd(Nn),Nn=k,Kn=l)});s("yt.www.watch.autoshare.triggerAutosharePromo",function(a){var b=K.getInstance().Xc(L.fe);N("SHOW_AUTOSHARE")&&!b&&(T("autoshare-promo-"+a),Ad("SHOW_AUTOSHARE",l))});s("yt.www.watch.autoshare.dismissAutosharePromo",function(a){var b=K.getInstance();b.Zd(L.fe,j);b.save();Ad("SHOW_AUTOSHARE",l);U("autoshare-promo-"+a);a=E(k,"autoshare-promo",i);for(b=0;b<a.length;b++)Ac(a[b])});
s("yt.www.watch.autoshare.initAutoshareWidget",function(a,b,c){Tn=b;U("autoshare-widget-"+a);var d=l,e=l;if(b){for(var f in b){var g=E("*","autoshare-widget-service-"+f,i),m=E("*","autoshare-widget-service-auto-"+f,i),p=C("autoshare-widget-service-checkbox-"+f);b[f].is_connected?(u(g,T),d=j,b[f].is_autosharing?(u(m,T),e=p.checked=j):(u(m,U),p.checked=l)):(u(g,U),u(m,U),p.checked=l)}if(e)T("autoshare-widget-"+a+"-auto"),Un=O(function(){U("autoshare-widget-"+a+"-auto");T("autoshare-widget-"+a+"-auto-sharing")},
7E3);else if(d){for(f in b)if(b[f].is_connected)p=C("autoshare-widget-service-checkbox-"+f),p.checked=j;T("autoshare-widget-"+a+"-oneoff")}else N("SHOW_AUTOSHARE")&&(T("autoshare-widget-"+a+"-wizard"),Ad("SHOW_AUTOSHARE",l))}if(c)C("autoshare-widget-"+a+"-message").value=c,C("autoshare-widget-"+a+"-message-counter").innerHTML=130-c.length;T("autoshare-widget-"+a)});s("yt.www.watch.autoshare.toggleShareToService",function(a){a=C("autoshare-widget-service-checkbox-"+a);a.checked=!a.checked});
s("yt.www.watch.autoshare.updateMessageCount",function(a,b){if(130<b.value.length)b.value=b.value.slice(0,130);var c=C(b.id+"-counter");if(c)c.innerHTML=130-b.value.length;gp(0,b)});s("yt.www.watch.autoshare.customizePost",function(a){Dd(Un);U("autoshare-widget-"+a+"-auto");T("autoshare-widget-"+a+"-oneoff");if(a=C("autoshare-widget-"+a+"-message"))a.focus(),a.select()});
s("yt.www.watch.autoshare.cancelPost",function(a){Dd(Un);U("autoshare-widget-"+a+"-auto");U("autoshare-widget-"+a+"-oneoff");T("autoshare-widget-"+a+"-cancelling");C("autoshare-widget-"+a+"-cancelled-input").value="true";var b={method:"POST",postBody:$c(document.forms["autoshareWidgetForm-"+a]),onComplete:function(){U("autoshare-widget-"+a+"-cancelling");T("autoshare-widget-"+a+"-cancelled")}};W("/autoshare?action_ajax_share=1&cancelled=1",b)});
s("yt.www.watch.autoshare.share",function(a){var b=l,c;for(c in Tn){var d=C("autoshare-widget-service-checkbox-"+c),e=E("*","autoshare-widget-service-auto-"+c,i);d.checked?(u(e,T),b=j):u(e,U)}b?(U("autoshare-widget-"+a+"-auto"),U("autoshare-widget-"+a+"-oneoff"),T("autoshare-widget-"+a+"-sharing"),b={method:"POST",postBody:$c(document.forms["autoshareWidgetForm-"+a]),onComplete:function(){U("autoshare-widget-"+a+"-sharing");T("autoshare-widget-"+a+"-shared")}},W("/autoshare?action_ajax_share=1",b)):
alert("No services selected.")});s("yt.history.enable",function(a,b){var c=pg(b);c.setEnabled.call(c,j,a)});s("yt.history.disable",function(){var a=pg();a.setEnabled.call(a,l)});
s("yt.flash.embed",function(a,b){a=C(a);b instanceof Ee||(b=new Ee(b));if(window!=window.top){var c=k;document.referrer&&(c=document.referrer.substring(0,128));b.kc.framer=c}Pe(function(c){c.isSupported(b.Fb)||N("IS_OPERA_MINI")?(c=He(c)&&b.url||Ie(c)&&b.Jb||b.Ib||b.url,Le(a,c,b)):Fd&&c.isSupported(6,0,65)?(c=new Ee({url:"//web.archive.org/web/20111228172059/http://s.ytimg.com/yt/swf/expressInstall-vflIE9HEf.swf",args:{MMredirectURL:window.location,MMplayerType:"ActiveX",MMdoctitle:document.title}}),Le(a,c.url,c)):0==c.G&&b.Hb?b.Hb():0==c.G&&b.Kd?b.Kd():a.innerHTML=
'<div id="flash-upgrade">'+P("FLASH_UPGRADE")+"</div>"})});s("yt.flash.update",Me);s("yt.www.lists.addto.toggleMenu",function(a,b){var c=ki.getInstance(),d=Z(c);if(b){var e=C("shared-addto-menu"),f=G("addto-menu",e);mi(c,a);im=w(a,d);if(!hm)hm=f.innerHTML;c=R(e,"video-ids");if((d=R(a,"video-ids"))&&c!=d)Q(e,"video-ids",d),f.innerHTML=hm,new km(a)}else im&&v(a,d)});
s("yt.www.lists.data.addto.saveToWatchLater",function(a,b){Rk(a,b,function(b,d){var e=d.list_id||"",f=[a],g=P("PLAYLIST_BAR_ADDED_TO_PLAYLIST");Nk("WL",e,f,g)})});s("yt.www.watch.watch5.enableWide",Uk);s("yt.www.watch.watch5.handleLoadMoreRelated",function(){U("watch-more-related-button");T("watch-more-related","watch-more-related-loading");V(N("MORE_RELATED_SERVLET"),{g:{video_id:N("VIDEO_ID"),action_more_related_videos:1},c:function(a,b){var c=C("watch-more-related");c.innerHTML=b.html;Bi(c)}})});
s("yt.www.watch.watch5.handleToggleMoreFromUser",function(a){var b=z(a,"yt-uix-expander-collapsed"),c=C("watch-more-from-user");!b&&"true"!=R(c,"loaded")&&(a={user_id:R(a,"video-user-id"),video_id:R(a,"video-id"),action_channel_videos:"1"},V("/watch_ajax",{format:"XML",method:"GET",g:a,c:function(a,b){c.innerHTML=b.html_content;Q(c,"loaded","true");Bi(c);var f=parseInt(R(C("watch-channel-discoverbox"),"slider-slide-selected"),10);E("button","yt-uix-slider-num",i)[f].click()}}));A(c,"collapsed",b)});
s("yt.www.watch.watch5.handleToggleDescription",function(a){if(z(a,"yt-uix-expander-collapsed"))jh("descriptionClosed",i,i);else{if((a=C("watch-source-videos-list"))&&"true"!=R(a,"loaded")){Q(a,"loaded","true");var b=ve("/watch_ajax",{action_get_video_attributions_component:1,v:N("VIDEO_ID")});W(b,{method:"GET",update:a})}jh("descriptionOpened",i,i)}});
s("yt.www.watch.watch5.updateLikesCount",function(a,b,c,d){var e=C("watch-description-extra-info");if(e){var f=G("likes",e);if(f)f.innerHTML=a;if(a=G("dislikes",e))a.innerHTML=b;if(b=G("watch-sparkbar-likes",e))b.style.width=c+"%";if(c=G("watch-sparkbar-dislikes",e))c.style.width=d+"%"}});s("yt.www.watch.watch5.purchaseComplete",function(){T(C("watch-player-rental-play-button"));Xk()});
s("yt.www.watch.actions.init",function(){var a=ye(window.location.hash),b=a.action;if(b){switch(b){case "flag":cm()}O(function(){dm("watch-actions-area-container").scrollIntoView()},0);delete a.action;a=te(a)||"#!";window.location.hash=a}});s("yt.www.watch.shortcuts.init",function(){S(document,"keypress",ao)});s("yt.www.watch.actions.captions",function(a){bm(a)&&(Yl(),Nl(function(){U("watch-actions-loading");Wl("watch-actions-captions")}))});s("yt.www.watch.actions.flag",cm);
s("yt.www.watch.actions.hide",function(){Xl()});s("yt.www.watch.actions.like",function(a){bm(a)&&am(j)});s("yt.www.watch.actions.share",em);s("yt.www.watch.actions.showSigninOrCreateChannelWarning",function(a){bm(a)&&Wl("watch-actions-logged-out")});s("yt.www.watch.actions.stats",function(a){bm(a)&&(Yl(),V("/insight_ajax",{format:"XML",method:"GET",g:{action_get_statistics_and_data:1,v:N("VIDEO_ID")},c:function(a,c){Zl(c.html_content)},l:$l}))});
s("yt.www.watch.actions.unlike",function(a){bm(a)&&am(l)});s("yt.www.watch.watch5.showIE9WebMPromo",function(a){var b=document.createElement("video");b.canPlayType&&!b.canPlayType("video/webm")&&T(a)});
s("yt.www.watch.reactions.toggleReaction",function(a){var b=z(a,"selected"),c=R(a,"reaction-enum-value"),d=[],e=[];Ch.getInstance();var f=Yn(a).innerHTML;if(b)g=P("REACTION_NONE_SELECTED");else{d=[c];g=F("yt-uix-button-menu-item",C("reactions-input-menu"));u(g,function(a){z(a,"selected")&&(Xn(a,-1),e.push(a))});G("yt-uix-button-menu-item",a);var g=R(a,"reaction-name")||""}Xn(a,b?-1:1);Zn(a,g);V("/reactions_ajax",{method:"POST",format:"JSON",j:{session_token:Vg.reactions_ajax},g:{action_react_to_video:1,
user_reactions:d.join(),video_id:N("VIDEO_ID"),reaction_clicked:c},c:function(){},l:function(){$n(a,b,e,f)}})});s("yt.www.watch.watch5.getMoviePlayer",Tk);s("yt.www.watch.watch5.showFlashUpgradePromo",function(a,b){Pe(function(c){if(!c.isSupported(b[0],b[1],b[2])){T(a);var c=K.getInstance(),d=parseInt(c.get("ftuc")||0,10)+1;c.set("ftuc",d);c.save()}})});s("yt.www.comments.init",function(){fe(C("comments-view"),"click",Ri,"comment-action")});
s("yt.www.comments.initForm",function(a,b){var c=I(a,"form");Kd(c,"initialized")||(Q(c,"initialized","true"),c=new Gi(c,!b),b&&c.focus())});s("yt.www.comments.watch5.focusCommentsBox",function(){var a=Td("textarea","comments-textarea");Sd(a,"comments-section").scrollIntoView();a.focus()});s("yt.www.comments.watch5.inputFocus",Zi);s("yt.www.comments.watch5.inputBlur",function(a){var b=I(a,"FORM");b&&w(b,"input-focused");ge(a,"input",Yi);ge(a,"propertychange",Yi)});
s("yt.www.comments.watch5.cancelPost",function(a){hj();var b=I(a,"FORM");if(b)if("comments-post-form"==b.id)G("comments-textarea",b).value="",w(b,"input-expanded"),v(b,"input-collapsed"),U("comments-attach-video"),b=E("BUTTON","comments-reaction-button",C("reaction-buttons")),u(b,function(a){a.disabled=l});else{var c=b.parentNode;w(c,"replying");c.removeChild(b)}(a=I(a,"div","comments-section"))&&w(a,"comment-input-focused")});
s("yt.www.comments.watch5.post",function(a){var b=I(a,"FORM"),c=b.comment,d=G("watch-comments-post",b),e=G("comments-post-result",b);e.innerHTML="";if(a=C("screen"))a.value="h="+screen.height+"&w="+screen.width+"&d="+screen.colorDepth;if(!d.disabled){var f=N("ENABLE_LIVE_COMMENTS"),a=b.action,g={postBody:$c(b),onComplete:function(a){var g=Ug(a.responseXML,"str_code");e.innerHTML="OK"==g?P("COMMENT_OK"):P("COMMENT_ERROR");"INLINE_CAPTCHAFAIL"!=g&&hj();if("OK"==g){w(e,"comments-bad-post");v(e,"comments-good-post");
d.disabled=j;if(f)c.value="",c.innerHTML="";var g=C("comments-view"),x=R(g,"type"),a=Ug(a.responseXML,"html_content")||"",D=G("comment-list",g);if("everything"==x){if(D)D.innerHTML=a+D.innerHTML,aj(D)}else if("highlights"==x&&(x=Sd(b,"comments-section"),(D=Ud(x))||(D=Ud(g)),D))D.innerHTML=a+D.innerHTML,aj(D)}else if("INLINE_CAPTCHA"==g){e.innerHTML="";var H=document.createElement("DIV");H.id="captcha_div";W("/comment_servlet?gimme_captcha=1&watch5=1",{method:"POST",postBody:N("COMMENT_ACTIONS_XSRF"),
update:H,onComplete:function(){hf(c,l);d.disabled=l;c.parentNode&&c.parentNode.insertBefore(H,c)}})}else if("INLINE_CAPTCHAFAIL"==g)e.innerHTML="",g=C("fail_warning"),C("fail_warning_text").innerHTML=P("COMMENT_CAPTCHAFAIL"),T(g),d.disabled=l},onException:function(a){a=Ug(a.responseXML,"str_code");"PENDING"==a?e.innerHTML=P("COMMENT_PENDING"):(e.innerHTML="BLOCKED"==a?P("COMMENT_BLOCKED"):"EMAIL"==a?P("COMMENT_ERROR_EMAIL"):P("COMMENT_ERROR"),d.disabled=l);v(e,"comments-bad-post");w(e,"comments-good-post");
hj()}},a=a+("&len="+c.value.length+"&wc="+c.value.split(" ").length);W(a,g);d.disabled=j;Si("convCommentUrl")}});s("yt.www.comments.watch5.showPage",ej);s("yt.www.comments.watch5.showPageFromElement",function(a){a=parseInt(a.getAttribute("data-page"),10);ej(a);return l});
s("yt.www.comments.watch5.showMoreComments",function(){var a=C("watch-more-comments-button"),b=parseInt(R(a,"page"),10),c=N("VIDEO_ID"),d=N("COMMENTS_THRESHHOLD"),e=N("COMMENTS_FILTER"),f=N("COMMENTS_PAGE_SIZE"),g=N("ENABLE_LIVE_COMMENTS"),m=N("COMMENT_SOURCE");U(a);T("watch-more-comments","watch-more-comments-loading");Q(a,"type","everything");a=bj(c,b,d,e,f,m,g);V(a,{format:"XML",c:function(a,c){if(c.html_content){var d=C("watch-more-comments");d.innerHTML+=c.html_content;Bi(d);d=C("watch-more-comments-button");
Q(d,"page",b+1);T(d)}U("watch-more-comments-loading")}})});
s("yt.www.comments.watch5.react",function(a,b){if(!a.disabled){var c=G("comments-textarea",C("comments-post-form")),d="#"+b+" ";if(document.selection)c.focus(),document.selection.createRange().text=d;else if(c.selectionStart||"0"==c.selectionStart){var e=c.selectionStart;c.value=c.value.substring(0,e)+d+c.value.substring(c.selectionEnd,c.value.length);c.selectionStart=e+d.length;c.selectionEnd=c.selectionStart}else c.value+=d;a.disabled=j;O(function(){c.focus()},1)}});
s("yt.www.comments.watch5.vote",function(a){if(Xi()&&N("COMMENTS_YPC_CAN_POST_OR_REACT_TO_COMMENT")){var b=Vi;if(!R(b,"voted")){var c=N("VIDEO_ID"),d=R(b,"id"),e=R(b,"score"),a=R(a,"vote-increment"),c="/comment_voting?a="+a+"&id="+d+"&video_id="+c+"&old_vote="+e;Kd(b,"tag")&&(c+="&tag="+R(b,"tag"));W(c,{method:"POST",onComplete:function(){},postBody:N("COMMENT_VOTE_XSRF")});Q(b,"voted",a);0<a?y(b,"voted-down","voted-up"):y(b,"voted-up","voted-down");fj(b)}}});
s("yt.www.comments.watch5.reply",function(){if(Xi()&&N("COMMENTS_YPC_CAN_POST_OR_REACT_TO_COMMENT")){hj();var a=Vi;y(a,"sharing","replying");var b=F("watch-comment-share-area",a);u(b,function(a){Ac(a)});b=C("comments-post-form").cloneNode(j);b.id="";b.className="comments-reply-form";G("watch-comments-post",b).disabled=l;G("comments-post-result",b).innerHTML="";G("comment-parent-id",b).value=R(a,"id");b.action+="&reply=1";var c=R(a,"tag");c&&(b.action+="&tag="+c);c=F("comments-reply-form",a);u(c,function(a){Ac(a)});
a.appendChild(b);Zi(b.firstChild);var c=R(a,"author"),d=G("comments-textarea",b);d.value="@"+c+" ";d.focus();Ei(d,d.innerHTML.length);$i(b.firstChild);fj(a)}});s("yt.www.comments.watch5.flag",function(){if(Xi()&&N("COMMENTS_YPC_CAN_POST_OR_REACT_TO_COMMENT")){var a=Vi,b=N("VIDEO_ID"),b="/comment_servlet?mark_comment_as_spam="+R(a,"id")+"&entity_id="+b;W(b,{method:"POST",postBody:N("COMMENT_ACTIONS_XSRF"),onComplete:function(){U(a)}});v(a,"flagged")}});
s("yt.www.comments.watch5.share",function(){hj();var a=Vi;y(a,"replying","sharing");var b=F("comments-reply-form",a);u(b,function(a){Ac(a)});b=F("watch-comment-share-area",a);u(b,function(a){Ac(a)});b=C("watch-comment-share-area").cloneNode(j);b.id="";var c=R(Vi,"id"),d=N("COMMENT_SHARE_URL"),d=d.replace("_COMMENT_ID_",c);F("watch-actions-share-input",b)[0].value=d;var d=F("comment-text",a)[0],e=Lc(Dc(d)),e=Ia(e),d=F("icon-watch-comment-share",b);u(d,function(a){var b=a.getAttribute("action"),b=b.replace("_COMMENT_ID_",
c),d=-1!=b.indexOf("twitter")?Fa(e,80):Fa(e,150),b=b.replace("_COMMENT_TEXT_",d);S(a,"click",r(function(a){eval(a)},o,b))});a.appendChild(b);hf(b,j);fj(a)});s("yt.www.comments.watch5.cancelShare",function(a){hj();var a=I(a,k,"watch-comment-share-area"),b=a.parentNode;Ac(a);w(b,"sharing")});s("yt.www.comments.watch5.block",function(){var a=R(Vi,"author");a&&gj(a,j)});s("yt.www.comments.watch5.unblock",function(){var a=R(Vi,"author");a&&gj(a,l)});s("yt.www.comments.watch5.showActions",fj);
s("yt.www.comments.watch5.hideActions",dj);s("yt.www.comments.watch5.approve",function(a,b){var c=Vi,d=R(c,"id");W("/comment_servlet?field_approve_comment=1",{postBody:"comment_id="+d+"&entity_id="+N("VIDEO_ID")+"&"+b,onComplete:function(){w(c,"pending")}})});s("yt.www.comments.watch5.remove",function(a){var b=Vi,c=R(b,"id");W("/comment_servlet?remove_comment=1&entity_id="+N("VIDEO_ID"),{postBody:"comment_id="+c+"&"+a,onComplete:function(){U(b);dj()}})});s("yt.www.comments.watch5.updateCount",$i);
s("yt.www.comments.watch5.display",function(a,b){b?(w(Vi,"hidden"),w(a.parentNode,"hide-mode"),v(a.parentNode,"show-mode")):(v(Vi,"hidden"),v(a.parentNode,"hide-mode"),w(a.parentNode,"show-mode"))});s("yt.www.comments.watch5.addCommentMouseListener",function(){var a=C("comments-view");a&&(fe(a,"click",jj,"expand-thread"),fe(a,"mouseover",ij,"comment"))});s("yt.www.comments.watch5.menuToggled",function(a,b){var c=I(a,k,"comment");c&&A(c,"highlighted",b)});
s("yt.www.comments.watch5.subscribeToPageChange",function(a,b){Ui.Eb("live-comments-page-changed",a,b)});s("yt.www.comments.watch5.popupComments",function(){eh(N("COMMENTS_POPUP_URL"),{width:350,height:500,resizable:j})});s("yt.www.lists.init",function(){if(-1<parseInt(N("PLAYLIST_BAR_PLAYING_INDEX"),10)){Ik();var a=N("AUTOPLAY_DELAY");a&&Mk(a)}Lk=j});s("yt.www.lists.getState",function(){var a=Jk();a.autoPlayMax=N("PLAY_ALL_MAX");return a});s("yt.www.lists.registerNearEndEventsWithPlayer",Ok);
s("yt.www.lists.handleNearPlaybackEnd",function(a){Lk&&uk(Ik())&&"NEAR_END"==a.slice(0,-1)&&(a=parseInt(a.slice(-1),10),Ek(Ik(),a))});s("yt.dom.datasets.get",R);s("yt.dom.datasets.set",Q);s("yt.uri.parseFragmentData",ye);s("yt.www.watch.watch5.promoteSubscribe",Wk);
s("yt.www.watch.watch5.reportAProblemForPaidContent",function(a){Pe(function(b){var b=[b.G,b.va,b.rev].join("."),c=Tk(),b=ve("http://web.archive.org/web/20111228172059/http://www.google.com/support/youtube/bin/answer.py?answer=1084880",{vid:N("VIDEO_ID"),currentTime:c&&c.getCurrentTime?c.getCurrentTime():-1,totalTime:c&&c.getDuration?c.getDuration():-1,quality:c&&c.getPlaybackQuality?c.getPlaybackQuality():-1,flashVersion:b,plid:a});ch(b,{},window)})});
Bd("openFull","checkCurrentVideo","trackAnnotationsEvent","reportFlashTiming","shareVideoFromFlash","setCompanion","setInstreamCompanion","setLongformCompanion","setFreewheelCompanion","closeInPageAdIframe","hideInstreamCompanion","disablePopout","enablePopout","closeMpuCompanion","updatePopAds","setAfvCompanionVars","showAfvCompanionAdDiv","hideAfvInstreamCompanionAdDiv","show_ppv_in_yva_spot","requestPyvAds","pyvHomeRequestAds","pyvBrowseRequestAds","showGutCompanion");
s("yt.www.recos.removeRecommendation",function(a){U("reco-"+a);a=ve("/remove_recommendation_ajax",{video_id:a});W(a,{method:"GET"});return l});s("yt.www.search.legos.toggleExpandedRefinements",function(){kf(C("search-lego-refinements"));return l});s("yt.www.search.legos.initLegos",function(){Lm=C("lego-preview");Mm=C("search-header");var a=C("lego-refine-block");fe(a,"mouseover",Pm,"lego-content");fe(a,"mouseout",Qm,"lego-content");fe(a,"mouseover",Nm,"lego-action");fe(a,"mouseout",Om,"lego-action")});
s("yt.www.search.toggleToolbelt",function(){var a=C("toolbelt-top"),b=C("search-option-expander"),c=!z(b,"expanded");A(b,"expanded",c);c?(T(a),a.style.height=C("toolbelt-container").offsetHeight+"px"):(a.style.height=0,O(function(){U(a)},300));return l});s("yt.www.thumbnaildelayload.init",function(a){si=a||0;ri=wi();vi=j;Ci(i,i);zi();S(window,"scroll",yi);S(window,"resize",yi)});s("yt.www.xsrf.dynamicAppendSessionToken",Go);s("yt.www.xsrf.sessionExcludedForms",Ho);
s("yt.www.xsrf.populateSessionToken",function(){for(var a=0;a<document.forms.length;a++){for(var b=l,c=0;c<Ho.length;c++)document.forms[a].name==Ho[c]&&(b=j);c=document.forms[a];if("post"==c.method.toLowerCase()&&b==l){for(var b=l,d=0;d<c.elements.length;d++)c.elements[d].name==N("XSRF_FIELD_NAME")&&(b=j);b||Go(c)}}});s("yt.www.home.ModuleHelper.initDismissRec",function(){fe(C("baseDiv"),"click",Hj,"channel-recommendation")});
s("yt.www.masthead.performSearch",function(a,b){var c=C("masthead-search"),d=R(b,a)||"";"rentals"==d?(c.rental.value=1,c.search_type.value=""):(c.search_type.value=d,c.rental.value=0);if(c.search_query.value)c.submit();else{var c=b.innerHTML,e=C("search-btn"),f=e.innerHTML,g=R(e,a)||"";e.innerHTML=c;Q(e,a,d);b.innerHTML=f;Q(b,a,g)}return l});
s("yt.www.masthead.loadPicker",function(a,b,c){var d=C(a);d?c?T(d):lf(d):(d=document.createElement("div"),d.id=a,U(d),C("picker-container").appendChild(d),c="/masthead_ajax?action_get_"+a.replace("-","_")+"=1",b&&(c=b+c),W(c,{method:"GET",update:a,onComplete:function(){U("picker-loading");T(a);C(a).scrollIntoView()}}),T("picker-loading"));v(d,"yt-tile-static");Jm(a);C(a).scrollIntoView()});
s("yt.www.masthead.searchBarFocusTest",function(a){!Km&&(40==a.keyCode||32==a.keyCode||34==a.keyCode)&&C("masthead-search-term").blur();Km=j});s("yt.www.masthead.dismissGAPlusMessage",function(){var a=md("FML","").split(","),b=new Date,b=Math.round(b.getTime()/1E3),c="",c=2!=a.length?"1,"+b:parseInt(a[0],10)+1+","+b;ld("FML",c,31536E4)});s("yt.www.masthead.dismissPostLinkingMessage",function(){nd("FML")});
s("yt.www.masthead.toggleExpandedMasthead",function(){var a=C("masthead-expanded");kf(a);hf("masthead-expanded-menu",j);hf("masthead-expanded-acct-sw-container",l);tm||w(C("masthead-expanded-container"),"accountswitch");if(!R(a,"loaded")){var b=C("masthead-expanded-menu-gaia-photo");if(b&&!b.src)b.src=R(b,"src");b=ne()+"/playlist_bar_ajax";V(b,{g:{action_get_playlists_masthead:1,feature:"mhee",new_slider:1},format:"JSON",c:function(b,d){C("masthead-expanded-lists-container").innerHTML=d.html;Q(a,
"loaded","true")}})}});s("yt.www.masthead.accountswitch.init",function(a){tm=a});
s("yt.www.masthead.accountswitch.toggle",function(){kf("masthead-expanded-acct-sw-container");var a=C("masthead-expanded-container"),b=C("masthead-expanded-acct-sw-container");if(jf(b)){b.style.top=a.offsetTop+"px";b=C("masthead-expanded-menu-acct-sw-list");if(b.offsetHeight<a.offsetHeight)b.style.height=a.offsetHeight-11+"px";var c=C("masthead-expanded-acct-sw-iframe");if(!c){var d=C("masthead-expanded-menu-acct-sw-list"),c=tc("iframe",{id:"masthead-expanded-acct-sw-iframe",frameborder:0,src:'javascript:""'});
d.parentNode&&d.parentNode.insertBefore(c,d)}c.style.height=b.offsetHeight-11+"px";tm||v(a,"accountswitch")}else tm||w(a,"accountswitch")});s("yt.www.masthead.initSandbar",function(a,b){if(!window.__loadSandbar)window.__loadSandbar=function(){var c=C("sb-button-notify"),d=C("sb-button-share"),e=new Em(a,b);S(c,"click",r(e.kj,e));S(d,"click",r(e.lj,e))},bh("http://web.archive.org/web/20111228172059/https://apis.google.com/js/plusone.js?onload=__loadSandbar&googleapis=1")});s("yt.www.ads.MastheadAd",Di);Di.prototype.collapse_ad=Di.prototype.collapse;
Di.prototype.expand_ad=Di.prototype.expand;s("yt.www.home.ads.workaroundIE",function(a){!lj&&kj&&(lj=j,O(function(){a.focus()},0))});s("yt.www.home.ads.workaroundLoad",function(){kj=j});s("yt.www.home.ads.workaroundReset",function(){lj=l});s("yt.www.home.ads.yvaCollapse",function(){var a=C("yva-bin");if(a){var b=C("yva-bg");b&&y(b,"yva-360-bg","yva-250-bg");y(a,"yva-expanded","yva-collapsed")}});s("yt.www.home.ads.yvaExpand",function(){var a=C("yva-bin");a&&y(a,"yva-collapsed","yva-expanded")});
s("yt.tracking.doubleclick.trackActivity",function(a,b,c){a=("https:"==document.location.protocol?"https://":"http://")+"fls.doubleclick.net/activityi;src="+ua(N("DBLCLK_ADVERTISER_ID"))+";type="+ua(a)+";cat="+ua(b);c&&!c.ord&&(a+=";ord=1");for(var d in c)a+=";"+ua(d)+"="+ua(c[d]);a+=";num="+na();c=document.createElement("iframe");c.src=a;c.style.display="none";document.body.appendChild(c)});s("yt.tracking.track",function(a,b,c){jh(a,b,c)});
s("yt.tracking.resolution",function(){hh("/mac_204?"+("action_scr2=1&height="+screen.height+"&width="+screen.width+"&depth="+screen.colorDepth),i)});s("yt.tracking.share",kh);s("yt.tracking.resources.init",function(){mh||(mh=j,O(oh,4E3))});s("yt.analytics.urchinTracker",function(){});s("yt.analytics.trackEvent",Hd);s("yt.timing.report",Y.Ic);s("yt.timing.maybeReport",Y.he);s("yt.timing.handlePageLoad",Y.$f);s("yt.timing.handleThumbnailLoad",Y.nl);yf("init",Y.$f);
Fd&&(!document.documentMode||8>document.documentMode)&&fe(C("ie"),"click",Vk,"video-thumb");
s("yt.www.subscriptions.edit.onUpdateSubscription",function(a,b,c,d){var c=c||"",e=l;(b=C("subscription_level_unsubscribe"))&&b.checked&&(e=j);b=$c(C("subscription_level_uploads"+c).form);W("/ajax_subscriptions?"+b,{postBody:"session_token="+a,onComplete:function(a){C("subscribeMessage"+c).innerHTML=Ug(Sg(a),"html_content");U("edit_subscription_wrapper"+c);U("edit_subscription_arrow"+c);T("subscribeMessage"+c);if(c)C("edit_subscription_opener"+c).style.visibility="",O(function(){U("subscribeMessage"+
c)},5E3);if(e){var b=C("channel-body"),a=E("div","subscribe-div",b),b=E("div","unsubscribe-div",b);u(a,function(a){lf(a)});u(b,function(a){lf(a)});d()}}})});s("yt.www.subscriptions.edit.onCancelUpdateSubscription",function(a){a=a||"";U("edit_subscription_wrapper"+a);U("edit_subscription_arrow"+a);if(a)C("edit_subscription_opener"+a).style.visibility="";U("alerts")});
s("yt.www.subscriptions.edit.onEditSubscriptionFromRecentActivity",function(a,b,c,d){window["edit_subscription_download_"+c]?(U("subscribeMessage"+c),lf("edit_subscription_wrapper"+c),lf("edit_subscription_arrow"+c),a=C("edit_subscription_opener"+c),a.style.visibility="visible"==a.style.visibility?"":"visible"):(window["edit_subscription_download_"+c]=j,W("/ajax_subscriptions?get_edit_subscription_form="+b+"&i="+c,{postBody:"session_token="+a,onComplete:function(a){C("edit_subscription_opener"+c).style.visibility=
"visible";var b=document.createElement("div");b.innerHTML=Ug(a.responseXML,"html_content");d.parentNode.insertBefore(b,d);T("edit_subscription_wrapper"+c);T("edit_subscription_arrow"+c)}}))});s("yt.www.subscriptions.SubscriptionButton.init",tj);
s("yt.www.subscriptions.button.subscribe",function(a){var b=an(a),c=R(b,"subscription-type"),d=R(b,"subscription-xsrf")||"",e=R(b,"subscription-menu-type"),f=R(b,"subscription-channels-container"),g=R(b,"subscription-feature"),m=R(b,"subscription-value"),p={};"playlist"==c?(p.action_create_subscription_to_playlist=1,c="p"):"blog"==c?(p.action_create_subscription_to_blog=1,c="b"):"topic"==c?(p.action_create_subscription_to_topic=1,c="l"):(p.action_create_subscription_to_user=1,c="u");g&&(p.feature=
g);a.disabled=j;Um(d);d=new Sm(ln,pn);Tm(d,p);p={};p[c]=m;p.menu_type=e;(e=N("PLAYBACK_ID"))&&(p.plid=e);f&&(p.show_channels=j);d.fb=p||{};d.userData.eventTrigger=a;d.userData.subscription=b;Si("convSubscribeUrl");Ym(d)});
s("yt.www.subscriptions.button.subscribeToCollection",function(a){for(var b=fn(a),c=I(a,k,"subscription-recommendations"),d=R(b,"subscription-xsrf")||"",e=[],f=E("input","username",c),g=0;g<f.length;g++)f[g].checked&&e.push(f[g].value);0==e.length?Ac(c):(a.disabled=j,Um(d),d=new Sm(mn,pn),Tm(d,{action_create_subscription_to_users:1}),f={},f.usernames=e.join(","),d.fb=f||{},d.userData.eventTrigger=a,d.userData.subscription=b,d.userData.collection=c,Ym(d))});
s("yt.www.subscriptions.button.unsubscribe",function(a){var b=fn(a),c=R(b,"subscription-id"),d=R(b,"subscription-xsrf")||"";if(!a.disabled){a.disabled=j;Um(d);d=new Sm(nn,pn);Tm(d,{action_remove_subscription:1});var e={};e.subscription_id=c;(c=N("PLAYBACK_ID"))&&(e.plid=c);d.fb=e||{};d.userData.eventTrigger=a;d.userData.subscription=b;Ti();Ym(d)}});
s("yt.www.subscriptions.button.update",function(a){var b=fn(a),c=R(b,"subscription-id"),d=R(b,"subscription-xsrf")||"";a.disabled=j;Um(d);var d=new Sm(on,pn),e=I(a,k,"subscription-menu-form"),f=new Vc;Yc(e,f,bd);Wc(f);for(var e={},g=0;g<f.C.length;g++){var m=f.C[g];e[m]=f.S[m]}e.email_on_upload||(e.email_on_upload=l);e.action_update_subscription_preferences=1;Tm(d,e);d.fb={subscription_id:c};d.userData.eventTrigger=a;d.userData.subscription=b;Ym(d)});s("yt.www.subscriptions.button.toggleMenu",cn);
s("yt.www.subscriptions.button.closeMenu",function(a){a=fn(a);"button"==R(a,"subscription-menu-type")?hn(a):jn(a)});Bd("yt","goog","_gel","googleapisv0","_hasclass","_addclass","_removeclass","_showdiv","_hidediv","_ajax");s("yt.www.masthead.extended.redirectWithNewParam",function(a,b){var c,d,e;c=window.location.href;c=c.split("#");d=2==c.length?"#"+c[1]:"";c=c[0];e=xe(c);e[b]=a;e["persist_"+b]="1";c=c.split("?");c=c[0];dh(c,e,d)});
s("yt.www.watch.stats.extended.setInsightOptOut",function(a){a?(v(C("insight-private"),"selected"),w(C("insight-public"),"selected")):(v(C("insight-public"),"selected"),w(C("insight-private"),"selected"));var b=C("insight-optout-form");b&&(a=ve(b.action,{opt_out:a}),b=$c(b),W(a,{postBody:b,onComplete:function(){}}));return l});s("yt.www.watch.stats.extended.toggleReferrer",function(a){lf(a);return l});
s("yt.www.watch.survey.takeWatchPageSurvey",function(){bo();window.open("/watch_page_survey?r2="+N("SURVEY_REFERER")+"&r1="+N("SURVEY_SERVLET_NAME")+"&name="+N("SURVEY_TYPE"),"YouTube_User_Happiness_Survey","toolbar=no,width=800,height=768,status=no,resizable=yes,fullscreen=no,scrollbars=yes").focus()});s("yt.www.watch.survey.watchPageSurveyGoAway",bo);s("yt.www.watch.survey.checkSurveyCompletedAndShow",function(){K.getInstance().Wb(L.be)||T("watch_page_survey")});
s("yt.www.watch.user.unblockUserLinkByUsername",function(a,b){if(!confirm(P("UNBLOCK_USER")))return l;var c={postBody:"unblock_user=0&"+N("BLOCK_USER_XSRF")+"&friend_username="+a};b&&(c.onComplete=function(){window.location.reload()});W("/link_servlet",c);return l});
s("yt.www.watch.user.blockUserLinkByUsername",function(a,b){if(!confirm(P("BLOCK_USER")))return l;var c={postBody:"block_user=1&"+N("BLOCK_USER_XSRF")+"&friend_username="+a};b&&(c.onComplete=function(){window.location.reload()});W("/link_servlet",c);return l});s("yt.www.watch.user.unblockUserLinkByExternalId",function(a,b){confirm(P("UNBLOCK_USER"))&&V("/link_ajax?action_unblock_user=1",{format:"XML",method:"POST",Ra:N("BLOCK_USER_AJAX_XSRF")+"&uid="+a,c:function(){b&&window.location.reload()}})});
s("yt.www.watch.user.blockUserLinkByExternalId",function(a,b){confirm(P("BLOCK_USER"))&&V("/link_ajax?action_block_user=1",{format:"XML",method:"POST",Ra:N("BLOCK_USER_AJAX_XSRF")+"&uid="+a,c:function(){b&&window.location.reload()}})});s("getNextVideoId",function(a){var b=Ik(),c=uk(b),d=a<=N("PLAY_ALL_MAX");return c&&d?b.Jd(a):""});Bd("getNextVideoId");})();
}
/*
FILE ARCHIVED ON 17:20:59 Dec 28, 2011 AND RETRIEVED FROM THE
INTERNET ARCHIVE ON 09:45:33 Dec 06, 2025.
JAVASCRIPT APPENDED BY WAYBACK MACHINE, COPYRIGHT INTERNET ARCHIVE.
ALL OTHER CONTENT MAY ALSO BE PROTECTED BY COPYRIGHT (17 U.S.C.
SECTION 108(a)(3)).
*/
/*
playback timings (ms):
captures_list: 0.877
exclusion.robots: 0.079
exclusion.robots.policy: 0.064
esindex: 0.016
cdx.remote: 22.395
LoadShardBlock: 165.833 (3)
PetaboxLoader3.datanode: 141.45 (5)
PetaboxLoader3.resolve: 199.302 (3)
load_resource: 253.516 (2)
*/