]> Raphaël G. Git Repositories - youtubedl/commitdiff
Merge tag 'upstream/2013.10.23'
authorRogério Brito <rbrito@ime.usp.br>
Wed, 23 Oct 2013 23:24:02 +0000 (21:24 -0200)
committerRogério Brito <rbrito@ime.usp.br>
Wed, 23 Oct 2013 23:24:02 +0000 (21:24 -0200)
Upstream version 2013.10.23

75 files changed:
Makefile
README.md
README.txt
devscripts/bash-completion.in
devscripts/gh-pages/update-sites.py
devscripts/release.sh
setup.py
test/__init__.py [new file with mode: 0644]
test/helper.py
test/test_YoutubeDL.py [new file with mode: 0644]
test/test_age_restriction.py [new file with mode: 0644]
test/test_all_urls.py
test/test_dailymotion_subtitles.py
test/test_download.py
test/test_playlists.py
test/test_utils.py
test/test_write_annotations.py [new file with mode: 0644]
test/test_write_info_json.py
test/test_youtube_lists.py
test/test_youtube_signature.py
test/test_youtube_subtitles.py
test/testdata/html5player-vflHOr_nV.js [deleted file]
test/testdata/html5player-vflUKrNpT.js [deleted file]
test/testdata/html5player-vfldJ8xgI.js [deleted file]
test/testdata/watch_as3-vflg5GhxU.swf [deleted file]
youtube-dl
youtube-dl.1
youtube-dl.bash-completion
youtube_dl/FileDownloader.py
youtube_dl/PostProcessor.py
youtube_dl/YoutubeDL.py
youtube_dl/__init__.py
youtube_dl/extractor/__init__.py
youtube_dl/extractor/arte.py
youtube_dl/extractor/bliptv.py
youtube_dl/extractor/brightcove.py
youtube_dl/extractor/cinemassacre.py [new file with mode: 0644]
youtube_dl/extractor/comedycentral.py
youtube_dl/extractor/common.py
youtube_dl/extractor/dailymotion.py
youtube_dl/extractor/faz.py [new file with mode: 0644]
youtube_dl/extractor/flickr.py
youtube_dl/extractor/francetv.py
youtube_dl/extractor/gamespot.py
youtube_dl/extractor/generic.py
youtube_dl/extractor/googleplus.py
youtube_dl/extractor/internetvideoarchive.py [new file with mode: 0644]
youtube_dl/extractor/jeuxvideo.py
youtube_dl/extractor/mtv.py
youtube_dl/extractor/nhl.py [new file with mode: 0644]
youtube_dl/extractor/nowvideo.py [new file with mode: 0644]
youtube_dl/extractor/pornotube.py
youtube_dl/extractor/redtube.py
youtube_dl/extractor/rottentomatoes.py [new file with mode: 0644]
youtube_dl/extractor/rtlnow.py
youtube_dl/extractor/rutube.py [new file with mode: 0644]
youtube_dl/extractor/sztvhu.py [new file with mode: 0644]
youtube_dl/extractor/techtalks.py [new file with mode: 0644]
youtube_dl/extractor/ted.py
youtube_dl/extractor/tudou.py
youtube_dl/extractor/vevo.py
youtube_dl/extractor/viddler.py [new file with mode: 0644]
youtube_dl/extractor/videodetective.py [new file with mode: 0644]
youtube_dl/extractor/videopremium.py [new file with mode: 0644]
youtube_dl/extractor/vimeo.py
youtube_dl/extractor/websurg.py [new file with mode: 0644]
youtube_dl/extractor/xhamster.py
youtube_dl/extractor/xnxx.py
youtube_dl/extractor/xvideos.py
youtube_dl/extractor/yahoo.py
youtube_dl/extractor/youku.py
youtube_dl/extractor/youporn.py
youtube_dl/extractor/youtube.py
youtube_dl/utils.py
youtube_dl/version.py

index 85dacfa4c31f2b83860891d6339b8b4a0e48c6b7..c6d09932bcd4f45b8910e828255703403c2df0d7 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -13,13 +13,13 @@ PYTHON=/usr/bin/env python
 
 # set SYSCONFDIR to /etc if PREFIX=/usr or PREFIX=/usr/local
 ifeq ($(PREFIX),/usr)
-    SYSCONFDIR=/etc
+       SYSCONFDIR=/etc
 else
-    ifeq ($(PREFIX),/usr/local)
-        SYSCONFDIR=/etc
-    else
-        SYSCONFDIR=$(PREFIX)/etc
-    endif
+       ifeq ($(PREFIX),/usr/local)
+               SYSCONFDIR=/etc
+       else
+               SYSCONFDIR=$(PREFIX)/etc
+       endif
 endif
 
 install: youtube-dl youtube-dl.1 youtube-dl.bash-completion
@@ -71,6 +71,7 @@ youtube-dl.tar.gz: youtube-dl README.md README.txt youtube-dl.1 youtube-dl.bash-
                --exclude '*~' \
                --exclude '__pycache' \
                --exclude '.git' \
+               --exclude 'testdata' \
                -- \
                bin devscripts test youtube_dl \
                CHANGELOG LICENSE README.md README.txt \
index 14d62b189c3dec1ceaeac35aa497f9f66628506f..2b8db0cfc2c9f7f78be5f3fb69fdeb345562d1b5 100644 (file)
--- a/README.md
+++ b/README.md
@@ -21,6 +21,8 @@ which means you can modify it, redistribute it or use it however you like.
                                sudo if needed)
     -i, --ignore-errors        continue on download errors, for example to to
                                skip unavailable videos in a playlist
+    --abort-on-error           Abort downloading of further videos (in the
+                               playlist or the command line) if an error occurs
     --dump-user-agent          display the current browser identification
     --user-agent UA            specify a custom user agent
     --referer REF              specify a custom referer, use if the video access
@@ -30,7 +32,7 @@ which means you can modify it, redistribute it or use it however you like.
     --extractor-descriptions   Output descriptions of all supported extractors
     --proxy URL                Use the specified HTTP/HTTPS proxy
     --no-check-certificate     Suppress HTTPS certificate validation.
-    --cache-dir None           Location in the filesystem where youtube-dl can
+    --cache-dir DIR            Location in the filesystem where youtube-dl can
                                store downloaded information permanently. By
                                default $XDG_CACHE_HOME/youtube-dl or ~/.cache
                                /youtube-dl .
@@ -52,11 +54,15 @@ which means you can modify it, redistribute it or use it however you like.
     --datebefore DATE          download only videos uploaded before this date
     --dateafter DATE           download only videos uploaded after this date
     --no-playlist              download only the currently playing video
+    --age-limit YEARS          download only videos suitable for the given age
+    --download-archive FILE    Download only videos not present in the archive
+                               file. Record all downloaded videos in it.
 
 ## Download Options:
-    -r, --rate-limit LIMIT     maximum download rate (e.g. 50k or 44.6m)
+    -r, --rate-limit LIMIT     maximum download rate in bytes per second (e.g.
+                               50K or 4.2M)
     -R, --retries RETRIES      number of retries (default is 10)
-    --buffer-size SIZE         size of download buffer (e.g. 1024 or 16k)
+    --buffer-size SIZE         size of download buffer (e.g. 1024 or 16K)
                                (default is 1024)
     --no-resize-buffer         do not automatically adjust the buffer size. By
                                default, the buffer size is automatically resized
@@ -72,15 +78,17 @@ which means you can modify it, redistribute it or use it however you like.
                                %(uploader_id)s for the uploader nickname if
                                different, %(autonumber)s to get an automatically
                                incremented number, %(ext)s for the filename
-                               extension, %(upload_date)s for the upload date
-                               (YYYYMMDD), %(extractor)s for the provider
-                               (youtube, metacafe, etc), %(id)s for the video id
-                               , %(playlist)s for the playlist the video is in,
-                               %(playlist_index)s for the position in the
-                               playlist and %% for a literal percent. Use - to
-                               output to stdout. Can also be used to download to
-                               a different directory, for example with -o '/my/d
-                               ownloads/%(uploader)s/%(title)s-%(id)s.%(ext)s' .
+                               extension, %(format)s for the format description
+                               (like "22 - 1280x720" or "HD")%(upload_date)s for
+                               the upload date (YYYYMMDD), %(extractor)s for the
+                               provider (youtube, metacafe, etc), %(id)s for the
+                               video id , %(playlist)s for the playlist the
+                               video is in, %(playlist_index)s for the position
+                               in the playlist and %% for a literal percent. Use
+                               - to output to stdout. Can also be used to
+                               download to a different directory, for example
+                               with -o '/my/downloads/%(uploader)s/%(title)s-%(i
+                               d)s.%(ext)s' .
     --autonumber-size NUMBER   Specifies the number of digits in %(autonumber)s
                                when it is present in output filename template or
                                --autonumber option is given
@@ -97,6 +105,7 @@ which means you can modify it, redistribute it or use it however you like.
                                file modification time
     --write-description        write video description to a .description file
     --write-info-json          write video metadata to a .info.json file
+    --write-annotations        write video annotations to a .annotation file
     --write-thumbnail          write thumbnail image to disk
 
 ## Verbosity / Simulation Options:
@@ -163,6 +172,7 @@ which means you can modify it, redistribute it or use it however you like.
                                processed files are overwritten by default
     --embed-subs               embed subtitles in the video (only for mp4
                                videos)
+    --add-metadata             add metadata to the files
 
 # CONFIGURATION
 
index fc84c9b6982648c857860f04e6c6e8f7c8688a82..b773576051a69521382eda4a3314d89334e04487 100644 (file)
@@ -28,6 +28,8 @@ OPTIONS
                                sudo if needed)
     -i, --ignore-errors        continue on download errors, for example to to
                                skip unavailable videos in a playlist
+    --abort-on-error           Abort downloading of further videos (in the
+                               playlist or the command line) if an error occurs
     --dump-user-agent          display the current browser identification
     --user-agent UA            specify a custom user agent
     --referer REF              specify a custom referer, use if the video access
@@ -37,7 +39,7 @@ OPTIONS
     --extractor-descriptions   Output descriptions of all supported extractors
     --proxy URL                Use the specified HTTP/HTTPS proxy
     --no-check-certificate     Suppress HTTPS certificate validation.
-    --cache-dir None           Location in the filesystem where youtube-dl can
+    --cache-dir DIR            Location in the filesystem where youtube-dl can
                                store downloaded information permanently. By
                                default $XDG_CACHE_HOME/youtube-dl or ~/.cache
                                /youtube-dl .
@@ -61,13 +63,17 @@ Video Selection:
     --datebefore DATE          download only videos uploaded before this date
     --dateafter DATE           download only videos uploaded after this date
     --no-playlist              download only the currently playing video
+    --age-limit YEARS          download only videos suitable for the given age
+    --download-archive FILE    Download only videos not present in the archive
+                               file. Record all downloaded videos in it.
 
 Download Options:
 -----------------
 
-    -r, --rate-limit LIMIT     maximum download rate (e.g. 50k or 44.6m)
+    -r, --rate-limit LIMIT     maximum download rate in bytes per second (e.g.
+                               50K or 4.2M)
     -R, --retries RETRIES      number of retries (default is 10)
-    --buffer-size SIZE         size of download buffer (e.g. 1024 or 16k)
+    --buffer-size SIZE         size of download buffer (e.g. 1024 or 16K)
                                (default is 1024)
     --no-resize-buffer         do not automatically adjust the buffer size. By
                                default, the buffer size is automatically resized
@@ -85,15 +91,17 @@ Filesystem Options:
                                %(uploader_id)s for the uploader nickname if
                                different, %(autonumber)s to get an automatically
                                incremented number, %(ext)s for the filename
-                               extension, %(upload_date)s for the upload date
-                               (YYYYMMDD), %(extractor)s for the provider
-                               (youtube, metacafe, etc), %(id)s for the video id
-                               , %(playlist)s for the playlist the video is in,
-                               %(playlist_index)s for the position in the
-                               playlist and %% for a literal percent. Use - to
-                               output to stdout. Can also be used to download to
-                               a different directory, for example with -o '/my/d
-                               ownloads/%(uploader)s/%(title)s-%(id)s.%(ext)s' .
+                               extension, %(format)s for the format description
+                               (like "22 - 1280x720" or "HD")%(upload_date)s for
+                               the upload date (YYYYMMDD), %(extractor)s for the
+                               provider (youtube, metacafe, etc), %(id)s for the
+                               video id , %(playlist)s for the playlist the
+                               video is in, %(playlist_index)s for the position
+                               in the playlist and %% for a literal percent. Use
+                               - to output to stdout. Can also be used to
+                               download to a different directory, for example
+                               with -o '/my/downloads/%(uploader)s/%(title)s-%(i
+                               d)s.%(ext)s' .
     --autonumber-size NUMBER   Specifies the number of digits in %(autonumber)s
                                when it is present in output filename template or
                                --autonumber option is given
@@ -110,6 +118,7 @@ Filesystem Options:
                                file modification time
     --write-description        write video description to a .description file
     --write-info-json          write video metadata to a .info.json file
+    --write-annotations        write video annotations to a .annotation file
     --write-thumbnail          write thumbnail image to disk
 
 Verbosity / Simulation Options:
@@ -186,6 +195,7 @@ Post-processing Options:
                                processed files are overwritten by default
     --embed-subs               embed subtitles in the video (only for mp4
                                videos)
+    --add-metadata             add metadata to the files
 
 CONFIGURATION
 =============
index bd10f63c2f2615168a482085ad156a9f4e330ddd..ce893fcbe1a681e535452c35f5b833eea54b2d95 100644 (file)
@@ -1,4 +1,4 @@
-__youtube-dl()
+__youtube_dl()
 {
     local cur prev opts
     COMPREPLY=()
@@ -15,4 +15,4 @@ __youtube-dl()
     fi
 }
 
-complete -F __youtube-dl youtube-dl
+complete -F __youtube_dl youtube-dl
index 33f242480e7c967ec0ca89fe57b5392dda0a524f..153e15c8ab674f44e3681e5440c9372634b272d8 100755 (executable)
@@ -16,10 +16,11 @@ def main():
     ie_htmls = []
     for ie in sorted(youtube_dl.gen_extractors(), key=lambda i: i.IE_NAME.lower()):
         ie_html = '<b>{}</b>'.format(ie.IE_NAME)
-        try:
+        ie_desc = getattr(ie, 'IE_DESC', None)
+        if ie_desc is False:
+            continue
+        elif ie_desc is not None:
             ie_html += ': {}'.format(ie.IE_DESC)
-        except AttributeError:
-            pass
         if ie.working() == False:
             ie_html += ' (Currently broken)'
         ie_htmls.append('<li>{}</li>'.format(ie_html))
index 796468b4b3aee3e603ddb919535bfde281cd71e5..2766174c1a8477519eb818f287897ebc93d04a72 100755 (executable)
@@ -88,10 +88,6 @@ ROOT=$(pwd)
     "$ROOT/devscripts/gh-pages/update-sites.py"
     git add *.html *.html.in update
     git commit -m "release $version"
-    git show HEAD
-    read -p "Is it good, can I push? (y/n) " -n 1
-    if [[ ! $REPLY =~ ^[Yy]$ ]]; then exit 1; fi
-    echo
     git push "$ROOT" gh-pages
     git push "$ORIGIN_URL" gh-pages
 )
index 3b6dc2d40f0f551630dac1007aaf72e0af819724..2391c527298299a616551d77a3a7a07d764df38d 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -63,6 +63,7 @@ setup(
     ' YouTube.com and other video sites.',
     url='https://github.com/rg3/youtube-dl',
     author='Ricardo Garcia',
+    author_email='ytdl@yt-dl.org',
     maintainer='Philipp Hagemeister',
     maintainer_email='phihag@phihag.de',
     packages=['youtube_dl', 'youtube_dl.extractor'],
diff --git a/test/__init__.py b/test/__init__.py
new file mode 100644 (file)
index 0000000..e69de29
index a2b468b509b3effc6ff61c2b00cb9ca1d59f3711..777119ea5fa6fe7b43ae5efe53e9c7685be347b8 100644 (file)
@@ -1,38 +1,63 @@
+import errno
 import io
+import hashlib
 import json
 import os.path
+import re
+import types
 
 import youtube_dl.extractor
-from youtube_dl import YoutubeDL, YoutubeDLHandler
-from youtube_dl.utils import (
-    compat_cookiejar,
-    compat_urllib_request,
-)
-
-# General configuration (from __init__, not very elegant...)
-jar = compat_cookiejar.CookieJar()
-cookie_processor = compat_urllib_request.HTTPCookieProcessor(jar)
-proxy_handler = compat_urllib_request.ProxyHandler()
-opener = compat_urllib_request.build_opener(proxy_handler, cookie_processor, YoutubeDLHandler())
-compat_urllib_request.install_opener(opener)
-
-PARAMETERS_FILE = os.path.join(os.path.dirname(os.path.abspath(__file__)), "parameters.json")
-with io.open(PARAMETERS_FILE, encoding='utf-8') as pf:
-    parameters = json.load(pf)
+from youtube_dl import YoutubeDL
+
+
+def global_setup():
+    youtube_dl._setup_opener(timeout=10)
+
+
+def get_params(override=None):
+    PARAMETERS_FILE = os.path.join(os.path.dirname(os.path.abspath(__file__)),
+                                   "parameters.json")
+    with io.open(PARAMETERS_FILE, encoding='utf-8') as pf:
+        parameters = json.load(pf)
+    if override:
+        parameters.update(override)
+    return parameters
+
+
+def try_rm(filename):
+    """ Remove a file if it exists """
+    try:
+        os.remove(filename)
+    except OSError as ose:
+        if ose.errno != errno.ENOENT:
+            raise
+
 
 class FakeYDL(YoutubeDL):
-    def __init__(self):
-        self.result = []
+    def __init__(self, override=None):
         # Different instances of the downloader can't share the same dictionary
         # some test set the "sublang" parameter, which would break the md5 checks.
-        self.params = dict(parameters)
-    def to_screen(self, s):
+        params = get_params(override=override)
+        super(FakeYDL, self).__init__(params)
+        self.result = []
+        
+    def to_screen(self, s, skip_eol=None):
         print(s)
+
     def trouble(self, s, tb=None):
         raise Exception(s)
+
     def download(self, x):
         self.result.append(x)
 
+    def expect_warning(self, regex):
+        # Silence an expected warning matching a regex
+        old_report_warning = self.report_warning
+        def report_warning(self, message):
+            if re.match(regex, message): return
+            old_report_warning(message)
+        self.report_warning = types.MethodType(report_warning, self)
+
 def get_testcases():
     for ie in youtube_dl.extractor.gen_extractors():
         t = getattr(ie, '_TEST', None)
@@ -42,3 +67,6 @@ def get_testcases():
         for t in getattr(ie, '_TESTS', []):
             t['name'] = type(ie).__name__[:-len('IE')]
             yield t
+
+
+md5 = lambda s: hashlib.md5(s.encode('utf-8')).hexdigest()
diff --git a/test/test_YoutubeDL.py b/test/test_YoutubeDL.py
new file mode 100644 (file)
index 0000000..f8cd1bd
--- /dev/null
@@ -0,0 +1,133 @@
+#!/usr/bin/env python
+
+# Allow direct execution
+import os
+import sys
+import unittest
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+
+from test.helper import FakeYDL
+
+
+class YDL(FakeYDL):
+    def __init__(self, *args, **kwargs):
+        super(YDL, self).__init__(*args, **kwargs)
+        self.downloaded_info_dicts = []
+        self.msgs = []
+
+    def process_info(self, info_dict):
+        self.downloaded_info_dicts.append(info_dict)
+
+    def to_screen(self, msg):
+        self.msgs.append(msg)
+
+
+class TestFormatSelection(unittest.TestCase):
+    def test_prefer_free_formats(self):
+        # Same resolution => download webm
+        ydl = YDL()
+        ydl.params['prefer_free_formats'] = True
+        formats = [
+            {u'ext': u'webm', u'height': 460},
+            {u'ext': u'mp4',  u'height': 460},
+        ]
+        info_dict = {u'formats': formats, u'extractor': u'test'}
+        ydl.process_ie_result(info_dict)
+        downloaded = ydl.downloaded_info_dicts[0]
+        self.assertEqual(downloaded[u'ext'], u'webm')
+
+        # Different resolution => download best quality (mp4)
+        ydl = YDL()
+        ydl.params['prefer_free_formats'] = True
+        formats = [
+            {u'ext': u'webm', u'height': 720},
+            {u'ext': u'mp4', u'height': 1080},
+        ]
+        info_dict[u'formats'] = formats
+        ydl.process_ie_result(info_dict)
+        downloaded = ydl.downloaded_info_dicts[0]
+        self.assertEqual(downloaded[u'ext'], u'mp4')
+
+        # No prefer_free_formats => keep original formats order
+        ydl = YDL()
+        ydl.params['prefer_free_formats'] = False
+        formats = [
+            {u'ext': u'webm', u'height': 720},
+            {u'ext': u'flv', u'height': 720},
+        ]
+        info_dict[u'formats'] = formats
+        ydl.process_ie_result(info_dict)
+        downloaded = ydl.downloaded_info_dicts[0]
+        self.assertEqual(downloaded[u'ext'], u'flv')
+
+    def test_format_limit(self):
+        formats = [
+            {u'format_id': u'meh'},
+            {u'format_id': u'good'},
+            {u'format_id': u'great'},
+            {u'format_id': u'excellent'},
+        ]
+        info_dict = {
+            u'formats': formats, u'extractor': u'test', 'id': 'testvid'}
+
+        ydl = YDL()
+        ydl.process_ie_result(info_dict)
+        downloaded = ydl.downloaded_info_dicts[0]
+        self.assertEqual(downloaded[u'format_id'], u'excellent')
+
+        ydl = YDL({'format_limit': 'good'})
+        assert ydl.params['format_limit'] == 'good'
+        ydl.process_ie_result(info_dict)
+        downloaded = ydl.downloaded_info_dicts[0]
+        self.assertEqual(downloaded[u'format_id'], u'good')
+
+        ydl = YDL({'format_limit': 'great', 'format': 'all'})
+        ydl.process_ie_result(info_dict)
+        self.assertEqual(ydl.downloaded_info_dicts[0][u'format_id'], u'meh')
+        self.assertEqual(ydl.downloaded_info_dicts[1][u'format_id'], u'good')
+        self.assertEqual(ydl.downloaded_info_dicts[2][u'format_id'], u'great')
+        self.assertTrue('3' in ydl.msgs[0])
+
+        ydl = YDL()
+        ydl.params['format_limit'] = 'excellent'
+        ydl.process_ie_result(info_dict)
+        downloaded = ydl.downloaded_info_dicts[0]
+        self.assertEqual(downloaded[u'format_id'], u'excellent')
+
+    def test_format_selection(self):
+        formats = [
+            {u'format_id': u'35', u'ext': u'mp4'},
+            {u'format_id': u'45', u'ext': u'webm'},
+            {u'format_id': u'47', u'ext': u'webm'},
+            {u'format_id': u'2', u'ext': u'flv'},
+        ]
+        info_dict = {u'formats': formats, u'extractor': u'test'}
+
+        ydl = YDL({'format': u'20/47'})
+        ydl.process_ie_result(info_dict)
+        downloaded = ydl.downloaded_info_dicts[0]
+        self.assertEqual(downloaded['format_id'], u'47')
+
+        ydl = YDL({'format': u'20/71/worst'})
+        ydl.process_ie_result(info_dict)
+        downloaded = ydl.downloaded_info_dicts[0]
+        self.assertEqual(downloaded['format_id'], u'35')
+
+        ydl = YDL()
+        ydl.process_ie_result(info_dict)
+        downloaded = ydl.downloaded_info_dicts[0]
+        self.assertEqual(downloaded['format_id'], u'2')
+
+        ydl = YDL({'format': u'webm/mp4'})
+        ydl.process_ie_result(info_dict)
+        downloaded = ydl.downloaded_info_dicts[0]
+        self.assertEqual(downloaded['format_id'], u'47')
+
+        ydl = YDL({'format': u'3gp/40/mp4'})
+        ydl.process_ie_result(info_dict)
+        downloaded = ydl.downloaded_info_dicts[0]
+        self.assertEqual(downloaded['format_id'], u'35')
+
+
+if __name__ == '__main__':
+    unittest.main()
diff --git a/test/test_age_restriction.py b/test/test_age_restriction.py
new file mode 100644 (file)
index 0000000..d500c6e
--- /dev/null
@@ -0,0 +1,55 @@
+#!/usr/bin/env python
+
+# Allow direct execution
+import os
+import sys
+import unittest
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+
+from test.helper import global_setup, try_rm
+global_setup()
+
+
+from youtube_dl import YoutubeDL
+
+
+def _download_restricted(url, filename, age):
+    """ Returns true iff the file has been downloaded """
+
+    params = {
+        'age_limit': age,
+        'skip_download': True,
+        'writeinfojson': True,
+        "outtmpl": "%(id)s.%(ext)s",
+    }
+    ydl = YoutubeDL(params)
+    ydl.add_default_info_extractors()
+    json_filename = filename + '.info.json'
+    try_rm(json_filename)
+    ydl.download([url])
+    res = os.path.exists(json_filename)
+    try_rm(json_filename)
+    return res
+
+
+class TestAgeRestriction(unittest.TestCase):
+    def _assert_restricted(self, url, filename, age, old_age=None):
+        self.assertTrue(_download_restricted(url, filename, old_age))
+        self.assertFalse(_download_restricted(url, filename, age))
+
+    def test_youtube(self):
+        self._assert_restricted('07FYdnEawAQ', '07FYdnEawAQ.mp4', 10)
+
+    def test_youporn(self):
+        self._assert_restricted(
+            'http://www.youporn.com/watch/505835/sex-ed-is-it-safe-to-masturbate-daily/',
+            '505835.mp4', 2, old_age=25)
+
+    def test_pornotube(self):
+        self._assert_restricted(
+            'http://pornotube.com/c/173/m/1689755/Marilyn-Monroe-Bathing',
+            '1689755.flv', 13)
+
+
+if __name__ == '__main__':
+    unittest.main()
index ff1c86efebe31f2d6477cbfe6246baa50607d6a7..56e5f80e1f6ddb17fef3ee5c499c238996c12051 100644 (file)
@@ -1,14 +1,20 @@
 #!/usr/bin/env python
 
+# Allow direct execution
+import os
 import sys
 import unittest
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
 
-# Allow direct execution
-import os
-sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
 
-from youtube_dl.extractor import YoutubeIE, YoutubePlaylistIE, YoutubeChannelIE, JustinTVIE, gen_extractors
-from helper import get_testcases
+from test.helper import get_testcases
+
+from youtube_dl.extractor import (
+    gen_extractors,
+    JustinTVIE,
+    YoutubeIE,
+)
+
 
 class TestAllURLsMatching(unittest.TestCase):
     def setUp(self):
index 83c65d57e60870be10b25c116ebad6fd20cc8122..c596415c4189624d254f72afd7b7bd7452d9fe50 100644 (file)
@@ -1,20 +1,16 @@
 #!/usr/bin/env python
 
+# Allow direct execution
+import os
 import sys
 import unittest
-import json
-import io
-import hashlib
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
 
-# Allow direct execution
-import os
-sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+from test.helper import FakeYDL, global_setup, md5
+global_setup()
 
-from youtube_dl.extractor import DailymotionIE
-from youtube_dl.utils import *
-from helper import FakeYDL
 
-md5 = lambda s: hashlib.md5(s.encode('utf-8')).hexdigest()
+from youtube_dl.extractor import DailymotionIE
 
 class TestDailymotionSubtitles(unittest.TestCase):
     def setUp(self):
@@ -45,15 +41,18 @@ class TestDailymotionSubtitles(unittest.TestCase):
         subtitles = self.getSubtitles()
         self.assertEqual(len(subtitles.keys()), 5)
     def test_list_subtitles(self):
+        self.DL.expect_warning(u'Automatic Captions not supported by this server')
         self.DL.params['listsubtitles'] = True
         info_dict = self.getInfoDict()
         self.assertEqual(info_dict, None)
     def test_automatic_captions(self):
+        self.DL.expect_warning(u'Automatic Captions not supported by this server')
         self.DL.params['writeautomaticsub'] = True
         self.DL.params['subtitleslang'] = ['en']
         subtitles = self.getSubtitles()
         self.assertTrue(len(subtitles.keys()) == 0)
     def test_nosubtitles(self):
+        self.DL.expect_warning(u'video doesn\'t have subtitles')
         self.url = 'http://www.dailymotion.com/video/x12u166_le-zapping-tele-star-du-08-aout-2013_tv'
         self.DL.params['writesubtitles'] = True
         self.DL.params['allsubtitles'] = True
index 23a66254d86ed2a68ee3ea54339838fda7d5dc71..b9a9be11d9686243ed2a1d5b748db4bc04712c54 100644 (file)
@@ -1,43 +1,31 @@
 #!/usr/bin/env python
 
-import errno
+# Allow direct execution
+import os
+import sys
+import unittest
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+
+from test.helper import get_params, get_testcases, global_setup, try_rm, md5
+global_setup()
+
+
 import hashlib
 import io
-import os
 import json
-import unittest
-import sys
 import socket
-import binascii
-
-# Allow direct execution
-sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
 
 import youtube_dl.YoutubeDL
-from youtube_dl.utils import *
-
-PARAMETERS_FILE = os.path.join(os.path.dirname(os.path.abspath(__file__)), "parameters.json")
+from youtube_dl.utils import (
+    compat_str,
+    compat_urllib_error,
+    DownloadError,
+    ExtractorError,
+    UnavailableVideoError,
+)
 
 RETRIES = 3
 
-# General configuration (from __init__, not very elegant...)
-jar = compat_cookiejar.CookieJar()
-cookie_processor = compat_urllib_request.HTTPCookieProcessor(jar)
-proxy_handler = compat_urllib_request.ProxyHandler()
-opener = compat_urllib_request.build_opener(proxy_handler, cookie_processor, YoutubeDLHandler())
-compat_urllib_request.install_opener(opener)
-socket.setdefaulttimeout(10)
-
-def _try_rm(filename):
-    """ Remove a file if it exists """
-    try:
-        os.remove(filename)
-    except OSError as ose:
-        if ose.errno != errno.ENOENT:
-            raise
-
-md5 = lambda s: hashlib.md5(s.encode('utf-8')).hexdigest()
-
 class YoutubeDL(youtube_dl.YoutubeDL):
     def __init__(self, *args, **kwargs):
         self.to_stderr = self.to_screen
@@ -54,17 +42,12 @@ def _file_md5(fn):
     with open(fn, 'rb') as f:
         return hashlib.md5(f.read()).hexdigest()
 
-from helper import get_testcases
 defs = get_testcases()
 
-with io.open(PARAMETERS_FILE, encoding='utf-8') as pf:
-    parameters = json.load(pf)
-
 
 class TestDownload(unittest.TestCase):
     maxDiff = None
     def setUp(self):
-        self.parameters = parameters
         self.defs = defs
 
 ### Dynamically generate tests
@@ -84,8 +67,7 @@ def generator(test_case):
             print_skipping(test_case['skip'])
             return
 
-        params = self.parameters.copy()
-        params.update(test_case.get('params', {}))
+        params = get_params(test_case.get('params', {}))
 
         ydl = YoutubeDL(params)
         ydl.add_default_info_extractors()
@@ -97,9 +79,9 @@ def generator(test_case):
 
         test_cases = test_case.get('playlist', [test_case])
         for tc in test_cases:
-            _try_rm(tc['file'])
-            _try_rm(tc['file'] + '.part')
-            _try_rm(tc['file'] + '.info.json')
+            try_rm(tc['file'])
+            try_rm(tc['file'] + '.part')
+            try_rm(tc['file'] + '.info.json')
         try:
             for retry in range(1, RETRIES + 1):
                 try:
@@ -145,9 +127,9 @@ def generator(test_case):
                     self.assertTrue(key in info_dict.keys() and info_dict[key])
         finally:
             for tc in test_cases:
-                _try_rm(tc['file'])
-                _try_rm(tc['file'] + '.part')
-                _try_rm(tc['file'] + '.info.json')
+                try_rm(tc['file'])
+                try_rm(tc['file'] + '.part')
+                try_rm(tc['file'] + '.info.json')
 
     return test_template
 
index c33511333bd82c2e180bf295587fad3078a755f5..d6a8d56df99609e50ea5885d2f5a3eb48b72cf37 100644 (file)
@@ -1,13 +1,16 @@
 #!/usr/bin/env python
 # encoding: utf-8
 
-import sys
-import unittest
-import json
 
 # Allow direct execution
 import os
-sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+import sys
+import unittest
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+
+from test.helper import FakeYDL, global_setup
+global_setup()
+
 
 from youtube_dl.extractor import (
     DailymotionPlaylistIE,
@@ -16,10 +19,9 @@ from youtube_dl.extractor import (
     UstreamChannelIE,
     SoundcloudUserIE,
     LivestreamIE,
+    NHLVideocenterIE,
 )
-from youtube_dl.utils import *
 
-from helper import FakeYDL
 
 class TestPlaylists(unittest.TestCase):
     def assertIsPlaylist(self, info):
@@ -74,5 +76,14 @@ class TestPlaylists(unittest.TestCase):
         self.assertEqual(result['title'], u'TEDCity2.0 (English)')
         self.assertTrue(len(result['entries']) >= 4)
 
+    def test_nhl_videocenter(self):
+        dl = FakeYDL()
+        ie = NHLVideocenterIE(dl)
+        result = ie.extract('http://video.canucks.nhl.com/videocenter/console?catid=999')
+        self.assertIsPlaylist(result)
+        self.assertEqual(result['id'], u'999')
+        self.assertEqual(result['title'], u'Highlights')
+        self.assertEqual(len(result['entries']), 12)
+
 if __name__ == '__main__':
     unittest.main()
index ff2e9885bdba233699edd69457aed91de35c8708..f3fbff042ccc8193d8d08527fdc04421c9832305 100644 (file)
@@ -1,14 +1,15 @@
 #!/usr/bin/env python
+# coding: utf-8
 
-# Various small unit tests
-
+# Allow direct execution
+import os
 import sys
 import unittest
-import xml.etree.ElementTree
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
 
-# Allow direct execution
-import os
-sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+
+# Various small unit tests
+import xml.etree.ElementTree
 
 #from youtube_dl.utils import htmlentity_transform
 from youtube_dl.utils import (
@@ -20,6 +21,9 @@ from youtube_dl.utils import (
     unified_strdate,
     find_xpath_attr,
     get_meta_content,
+    xpath_with_ns,
+    smuggle_url,
+    unsmuggle_url,
 )
 
 if sys.version_info < (3, 0):
@@ -141,5 +145,31 @@ class TestUtil(unittest.TestCase):
         self.assertEqual(get_meta('description'), u'foo & bar')
         self.assertEqual(get_meta('author'), 'Plato')
 
+    def test_xpath_with_ns(self):
+        testxml = u'''<root xmlns:media="http://example.com/">
+            <media:song>
+                <media:author>The Author</media:author>
+                <url>http://server.com/download.mp3</url>
+            </media:song>
+        </root>'''
+        doc = xml.etree.ElementTree.fromstring(testxml)
+        find = lambda p: doc.find(xpath_with_ns(p, {'media': 'http://example.com/'}))
+        self.assertTrue(find('media:song') is not None)
+        self.assertEqual(find('media:song/media:author').text, u'The Author')
+        self.assertEqual(find('media:song/url').text, u'http://server.com/download.mp3')
+
+    def test_smuggle_url(self):
+        data = {u"ö": u"ö", u"abc": [3]}
+        url = 'https://foo.bar/baz?x=y#a'
+        smug_url = smuggle_url(url, data)
+        unsmug_url, unsmug_data = unsmuggle_url(smug_url)
+        self.assertEqual(url, unsmug_url)
+        self.assertEqual(data, unsmug_data)
+
+        res_url, res_data = unsmuggle_url(url)
+        self.assertEqual(res_url, url)
+        self.assertEqual(res_data, None)
+
+
 if __name__ == '__main__':
     unittest.main()
diff --git a/test/test_write_annotations.py b/test/test_write_annotations.py
new file mode 100644 (file)
index 0000000..35defb8
--- /dev/null
@@ -0,0 +1,80 @@
+#!/usr/bin/env python
+# coding: utf-8
+
+# Allow direct execution
+import os
+import sys
+import unittest
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+
+from test.helper import get_params, global_setup, try_rm
+global_setup()
+
+
+import io
+
+import xml.etree.ElementTree
+
+import youtube_dl.YoutubeDL
+import youtube_dl.extractor
+
+
+class YoutubeDL(youtube_dl.YoutubeDL):
+    def __init__(self, *args, **kwargs):
+        super(YoutubeDL, self).__init__(*args, **kwargs)
+        self.to_stderr = self.to_screen
+
+params = get_params({
+    'writeannotations': True,
+    'skip_download': True,
+    'writeinfojson': False,
+    'format': 'flv',
+})
+
+
+
+TEST_ID = 'gr51aVj-mLg'
+ANNOTATIONS_FILE = TEST_ID + '.flv.annotations.xml'
+EXPECTED_ANNOTATIONS = ['Speech bubble', 'Note', 'Title', 'Spotlight', 'Label']
+
+class TestAnnotations(unittest.TestCase):
+    def setUp(self):
+        # Clear old files
+        self.tearDown()
+
+
+    def test_info_json(self):
+        expected = list(EXPECTED_ANNOTATIONS) #Two annotations could have the same text.
+        ie = youtube_dl.extractor.YoutubeIE()
+        ydl = YoutubeDL(params)
+        ydl.add_info_extractor(ie)
+        ydl.download([TEST_ID])
+        self.assertTrue(os.path.exists(ANNOTATIONS_FILE))
+        annoxml = None
+        with io.open(ANNOTATIONS_FILE, 'r', encoding='utf-8') as annof:
+                annoxml = xml.etree.ElementTree.parse(annof)
+        self.assertTrue(annoxml is not None, 'Failed to parse annotations XML')
+        root = annoxml.getroot()
+        self.assertEqual(root.tag, 'document')
+        annotationsTag = root.find('annotations')
+        self.assertEqual(annotationsTag.tag, 'annotations')
+        annotations = annotationsTag.findall('annotation')
+
+        #Not all the annotations have TEXT children and the annotations are returned unsorted.
+        for a in annotations:
+                self.assertEqual(a.tag, 'annotation')
+                if a.get('type') == 'text':
+                        textTag = a.find('TEXT')
+                        text = textTag.text
+                        self.assertTrue(text in expected) #assertIn only added in python 2.7
+                        #remove the first occurance, there could be more than one annotation with the same text
+                        expected.remove(text)
+        #We should have seen (and removed) all the expected annotation texts.
+        self.assertEqual(len(expected), 0, 'Not all expected annotations were found.')
+        
+
+    def tearDown(self):
+        try_rm(ANNOTATIONS_FILE)
+
+if __name__ == '__main__':
+    unittest.main()
index de6d5180fc0a88a66b747548352fdf72775d7c00..a5b6f6972df48f6b7cdcfebc3ea32d11c6a27afa 100644 (file)
@@ -1,37 +1,34 @@
 #!/usr/bin/env python
 # coding: utf-8
 
-import json
+# Allow direct execution
 import os
 import sys
 import unittest
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
 
-# Allow direct execution
-sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+from test.helper import get_params, global_setup
+global_setup()
+
+
+import io
+import json
 
 import youtube_dl.YoutubeDL
 import youtube_dl.extractor
-from youtube_dl.utils import *
-
-PARAMETERS_FILE = os.path.join(os.path.dirname(os.path.abspath(__file__)), "parameters.json")
 
-# General configuration (from __init__, not very elegant...)
-jar = compat_cookiejar.CookieJar()
-cookie_processor = compat_urllib_request.HTTPCookieProcessor(jar)
-proxy_handler = compat_urllib_request.ProxyHandler()
-opener = compat_urllib_request.build_opener(proxy_handler, cookie_processor, YoutubeDLHandler())
-compat_urllib_request.install_opener(opener)
 
 class YoutubeDL(youtube_dl.YoutubeDL):
     def __init__(self, *args, **kwargs):
         super(YoutubeDL, self).__init__(*args, **kwargs)
         self.to_stderr = self.to_screen
 
-with io.open(PARAMETERS_FILE, encoding='utf-8') as pf:
-    params = json.load(pf)
-params['writeinfojson'] = True
-params['skip_download'] = True
-params['writedescription'] = True
+params = get_params({
+    'writeinfojson': True,
+    'skip_download': True,
+    'writedescription': True,
+})
+
 
 TEST_ID = 'BaW_jenozKc'
 INFO_JSON_FILE = TEST_ID + '.mp4.info.json'
@@ -42,6 +39,7 @@ This is a test video for youtube-dl.
 
 For more information, contact phihag@phihag.de .'''
 
+
 class TestInfoJSON(unittest.TestCase):
     def setUp(self):
         # Clear old files
index 53e65816dfb9268c40831a57c781a169fbb050b7..4b7a7847bd3a33a9a2bff3e99f9f4cff0de7eebf 100644 (file)
@@ -1,20 +1,26 @@
 #!/usr/bin/env python
 
+# Allow direct execution
+import os
 import sys
 import unittest
-import json
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+
+from test.helper import FakeYDL, global_setup
+global_setup()
 
-# Allow direct execution
-import os
-sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
 
-from youtube_dl.extractor import YoutubeUserIE, YoutubePlaylistIE, YoutubeIE, YoutubeChannelIE, YoutubeShowIE
-from youtube_dl.utils import *
+from youtube_dl.extractor import (
+    YoutubeUserIE,
+    YoutubePlaylistIE,
+    YoutubeIE,
+    YoutubeChannelIE,
+    YoutubeShowIE,
+)
 
-from helper import FakeYDL
 
 class TestYoutubeLists(unittest.TestCase):
-    def assertIsPlaylist(self,info):
+    def assertIsPlaylist(self, info):
         """Make sure the info has '_type' set to 'playlist'"""
         self.assertEqual(info['_type'], 'playlist')
 
@@ -100,7 +106,7 @@ class TestYoutubeLists(unittest.TestCase):
         dl = FakeYDL()
         ie = YoutubeShowIE(dl)
         result = ie.extract('http://www.youtube.com/show/airdisasters')
-        self.assertTrue(len(result) >= 4)
+        self.assertTrue(len(result) >= 3)
 
 if __name__ == '__main__':
     unittest.main()
index 5007d9a16305f055d38231cf2626dedcbd0c70ee..5e1ff5eb0ede5bcb020cd027ca00d5b4159f9812 100644 (file)
@@ -1,14 +1,18 @@
 #!/usr/bin/env python
 
-import io
-import re
-import string
+# Allow direct execution
+import os
 import sys
 import unittest
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
 
-# Allow direct execution
-import os
-sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+from test.helper import global_setup
+global_setup()
+
+
+import io
+import re
+import string
 
 from youtube_dl.extractor import YoutubeIE
 from youtube_dl.utils import compat_str, compat_urlretrieve
index 168e6c66cbf089d72622ab6cc20f2c66d19a8c2b..00430a338af7edfcdc7ea5f0380b888e86563ec4 100644 (file)
@@ -1,76 +1,87 @@
 #!/usr/bin/env python
 
+# Allow direct execution
+import os
 import sys
 import unittest
-import json
-import io
-import hashlib
+sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
+
+from test.helper import FakeYDL, global_setup, md5
+global_setup()
 
-# Allow direct execution
-import os
-sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
 
 from youtube_dl.extractor import YoutubeIE
-from youtube_dl.utils import *
-from helper import FakeYDL
 
-md5 = lambda s: hashlib.md5(s.encode('utf-8')).hexdigest()
 
 class TestYoutubeSubtitles(unittest.TestCase):
     def setUp(self):
         self.DL = FakeYDL()
         self.url = 'QRS8MkLhQmM'
+
     def getInfoDict(self):
         IE = YoutubeIE(self.DL)
         info_dict = IE.extract(self.url)
         return info_dict
+
     def getSubtitles(self):
         info_dict = self.getInfoDict()
-        return info_dict[0]['subtitles']        
+        return info_dict[0]['subtitles']
+
     def test_youtube_no_writesubtitles(self):
         self.DL.params['writesubtitles'] = False
         subtitles = self.getSubtitles()
         self.assertEqual(subtitles, None)
+
     def test_youtube_subtitles(self):
         self.DL.params['writesubtitles'] = True
         subtitles = self.getSubtitles()
         self.assertEqual(md5(subtitles['en']), '4cd9278a35ba2305f47354ee13472260')
+
     def test_youtube_subtitles_lang(self):
         self.DL.params['writesubtitles'] = True
         self.DL.params['subtitleslangs'] = ['it']
         subtitles = self.getSubtitles()
         self.assertEqual(md5(subtitles['it']), '164a51f16f260476a05b50fe4c2f161d')
+
     def test_youtube_allsubtitles(self):
         self.DL.params['writesubtitles'] = True
         self.DL.params['allsubtitles'] = True
         subtitles = self.getSubtitles()
         self.assertEqual(len(subtitles.keys()), 13)
+
     def test_youtube_subtitles_sbv_format(self):
         self.DL.params['writesubtitles'] = True
         self.DL.params['subtitlesformat'] = 'sbv'
         subtitles = self.getSubtitles()
         self.assertEqual(md5(subtitles['en']), '13aeaa0c245a8bed9a451cb643e3ad8b')
+
     def test_youtube_subtitles_vtt_format(self):
         self.DL.params['writesubtitles'] = True
         self.DL.params['subtitlesformat'] = 'vtt'
         subtitles = self.getSubtitles()
         self.assertEqual(md5(subtitles['en']), '356cdc577fde0c6783b9b822e7206ff7')
+
     def test_youtube_list_subtitles(self):
+        self.DL.expect_warning(u'Video doesn\'t have automatic captions')
         self.DL.params['listsubtitles'] = True
         info_dict = self.getInfoDict()
         self.assertEqual(info_dict, None)
+
     def test_youtube_automatic_captions(self):
         self.url = '8YoUxe5ncPo'
         self.DL.params['writeautomaticsub'] = True
         self.DL.params['subtitleslangs'] = ['it']
         subtitles = self.getSubtitles()
         self.assertTrue(subtitles['it'] is not None)
+
     def test_youtube_nosubtitles(self):
+        self.DL.expect_warning(u'video doesn\'t have subtitles')
         self.url = 'sAjKT8FhjI8'
         self.DL.params['writesubtitles'] = True
         self.DL.params['allsubtitles'] = True
         subtitles = self.getSubtitles()
         self.assertEqual(len(subtitles), 0)
+
     def test_youtube_multiple_langs(self):
         self.url = 'QRS8MkLhQmM'
         self.DL.params['writesubtitles'] = True
diff --git a/test/testdata/html5player-vflHOr_nV.js b/test/testdata/html5player-vflHOr_nV.js
deleted file mode 100644 (file)
index 5bdfcfd..0000000
+++ /dev/null
@@ -1,886 +0,0 @@
-(function(){var f,aa=aa||{},l=this;function n(a,b){for(var c=a.split("."),d=b||l,e;e=c.shift();)if(null!=d[e])d=d[e];else return null;return d}function ba(){}function ca(a){a.getInstance=function(){return a.pq?a.pq:a.pq=new a}}
-function da(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}function q(a){return void 0!==a}function ea(a){return null!=a}function t(a){return"array"==da(a)}function fa(a){var b=da(a);return"array"==b||"object"==b&&"number"==typeof a.length}function u(a){return"string"==typeof a}function ga(a){return"number"==typeof a}function ha(a){return"function"==da(a)}function ia(a){var b=typeof a;return"object"==b&&null!=a||"function"==b}function ja(a){return a[ka]||(a[ka]=++la)}
-var ka="closure_uid_"+(1E9*Math.random()>>>0),la=0;function ma(a,b,c){return a.call.apply(a.bind,arguments)}function na(a,b,c){if(!a)throw 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)}}
-function v(a,b,c){v=Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?ma:na;return v.apply(null,arguments)}function oa(a,b){var c=Array.prototype.slice.call(arguments,1);return function(){var b=c.slice();b.push.apply(b,arguments);return a.apply(this,b)}}function pa(a,b){for(var c in b)a[c]=b[c]}var w=Date.now||function(){return+new Date};
-function qa(a,b){var c=a.split("."),d=l;c[0]in d||!d.execScript||d.execScript("var "+c[0]);for(var e;c.length&&(e=c.shift());)c.length||void 0===b?d=d[e]?d[e]:d[e]={}:d[e]=b}function y(a,b){function c(){}c.prototype=b.prototype;a.C=b.prototype;a.prototype=new c;a.prototype.constructor=a}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 v.apply(null,c)}return v(this,a)};function ra(a){Error.captureStackTrace?Error.captureStackTrace(this,ra):this.stack=Error().stack||"";a&&(this.message=String(a))}y(ra,Error);ra.prototype.name="CustomError";function sa(a,b){for(var c=a.split("%s"),d="",e=Array.prototype.slice.call(arguments,1);e.length&&1<c.length;)d+=c.shift()+e.shift();return d+c.join("%s")}function ua(a){return decodeURIComponent(a.replace(/\+/g," "))}function va(a){if(!wa.test(a))return a;-1!=a.indexOf("&")&&(a=a.replace(xa,"&amp;"));-1!=a.indexOf("<")&&(a=a.replace(ya,"&lt;"));-1!=a.indexOf(">")&&(a=a.replace(za,"&gt;"));-1!=a.indexOf('"')&&(a=a.replace(Aa,"&quot;"));return a}var xa=/&/g,ya=/</g,za=/>/g,Aa=/\"/g,wa=/[&<>\"]/;
-function Ba(a,b){for(var c=0,d=String(a).replace(/^[\s\xa0]+|[\s\xa0]+$/g,"").split("."),e=String(b).replace(/^[\s\xa0]+|[\s\xa0]+$/g,"").split("."),g=Math.max(d.length,e.length),h=0;0==c&&h<g;h++){var k=d[h]||"",m=e[h]||"",p=RegExp("(\\d*)(\\D*)","g"),s=RegExp("(\\d*)(\\D*)","g");do{var r=p.exec(k)||["","",""],x=s.exec(m)||["","",""];if(0==r[0].length&&0==x[0].length)break;c=((0==r[1].length?0:parseInt(r[1],10))<(0==x[1].length?0:parseInt(x[1],10))?-1:(0==r[1].length?0:parseInt(r[1],10))>(0==x[1].length?
-0:parseInt(x[1],10))?1:0)||((0==r[2].length)<(0==x[2].length)?-1:(0==r[2].length)>(0==x[2].length)?1:0)||(r[2]<x[2]?-1:r[2]>x[2]?1:0)}while(0==c)}return c}function Ca(a){var b=Number(a);return 0==b&&/^[\s\xa0]*$/.test(a)?NaN:b}function Da(a){return String(a).replace(/\-([a-z])/g,function(a,c){return c.toUpperCase()})}
-function Ea(a){var b=u(void 0)?"undefined".replace(/([-()\[\]{}+?*.$\^|,:#<!\\])/g,"\\$1").replace(/\x08/g,"\\x08"):"\\s";return a.replace(RegExp("(^"+(b?"|["+b+"]+":"")+")([a-z])","g"),function(a,b,e){return b+e.toUpperCase()})};function Fa(a){return a[a.length-1]}
-var Ga=Array.prototype,Ha=Ga.indexOf?function(a,b,c){return Ga.indexOf.call(a,b,c)}:function(a,b,c){c=null==c?0:0>c?Math.max(0,a.length+c):c;if(u(a))return u(b)&&1==b.length?a.indexOf(b,c):-1;for(;c<a.length;c++)if(c in a&&a[c]===b)return c;return-1},z=Ga.forEach?function(a,b,c){Ga.forEach.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)g in e&&b.call(c,e[g],g,a)},Ia=Ga.filter?function(a,b,c){return Ga.filter.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=[],g=
-0,h=u(a)?a.split(""):a,k=0;k<d;k++)if(k in h){var m=h[k];b.call(c,m,k,a)&&(e[g++]=m)}return e},Ja=Ga.map?function(a,b,c){return Ga.map.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=Array(d),g=u(a)?a.split(""):a,h=0;h<d;h++)h in g&&(e[h]=b.call(c,g[h],h,a));return e},Ka=Ga.some?function(a,b,c){return Ga.some.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)if(g in e&&b.call(c,e[g],g,a))return!0;return!1},La=Ga.every?function(a,b,c){return Ga.every.call(a,b,c)}:function(a,
-b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)if(g in e&&!b.call(c,e[g],g,a))return!1;return!0};function Ma(a,b){var c=0;z(a,function(a,e,g){b.call(void 0,a,e,g)&&++c},void 0);return c}function Na(a,b,c){b=Oa(a,b,c);return 0>b?null:u(a)?a.charAt(b):a[b]}function Oa(a,b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)if(g in e&&b.call(c,e[g],g,a))return g;return-1}function Pa(a,b){var c=Qa(a,b,void 0);return 0>c?null:u(a)?a.charAt(c):a[c]}
-function Qa(a,b,c){for(var d=u(a)?a.split(""):a,e=a.length-1;0<=e;e--)if(e in d&&b.call(c,d[e],e,a))return e;return-1}function A(a,b){return 0<=Ha(a,b)}function Ra(a){return 0==a.length}function Sa(a){if(!t(a))for(var b=a.length-1;0<=b;b--)delete a[b];a.length=0}function Ta(a,b){A(a,b)||a.push(b)}function Ua(a,b){var c=Ha(a,b),d;(d=0<=c)&&Va(a,c);return d}function Va(a,b){Ga.splice.call(a,b,1)}function Wa(a,b){var c=Oa(a,b,void 0);0<=c&&Va(a,c)}
-function Xa(a){return Ga.concat.apply(Ga,arguments)}function Ya(a){var b=a.length;if(0<b){for(var c=Array(b),d=0;d<b;d++)c[d]=a[d];return c}return[]}function Za(a,b){for(var c=1;c<arguments.length;c++){var d=arguments[c],e;if(t(d)||(e=fa(d))&&Object.prototype.hasOwnProperty.call(d,"callee"))a.push.apply(a,d);else if(e)for(var g=a.length,h=d.length,k=0;k<h;k++)a[g+k]=d[k];else a.push(d)}}function $a(a,b,c,d){Ga.splice.apply(a,ab(arguments,1))}
-function ab(a,b,c){return 2>=arguments.length?Ga.slice.call(a,b):Ga.slice.call(a,b,c)}function bb(a){for(var b={},c=0,d=0;d<a.length;){var e=a[d++],g=ia(e)?"o"+ja(e):(typeof e).charAt(0)+e;Object.prototype.hasOwnProperty.call(b,g)||(b[g]=!0,a[c++]=e)}a.length=c}function cb(a,b,c){for(var d=0,e=a.length,g;d<e;){var h=d+e>>1,k;k=b(c,a[h]);0<k?d=h+1:(e=h,g=!k)}return g?d:~d}function db(a,b){Ga.sort.call(a,b||eb)}function fb(a,b){var c=eb;db(a,function(a,e){return c(a[b],e[b])})}
-function gb(a,b,c){if(!fa(a)||!fa(b)||a.length!=b.length)return!1;var d=a.length;c=c||hb;for(var e=0;e<d;e++)if(!c(a[e],b[e]))return!1;return!0}function eb(a,b){return a>b?1:a<b?-1:0}function hb(a,b){return a===b}function ib(a,b,c){c=cb(a,c||eb,b);0>c&&$a(a,-(c+1),0,b)}function jb(a){for(var b=[],c=0;c<arguments.length;c++){var d=arguments[c];t(d)?b.push.apply(b,jb.apply(null,d)):b.push(d)}return b};function kb(a){a=String(a);if(/^\s*$/.test(a)?0:/^[\],:{}\s\u2028\u2029]*$/.test(a.replace(/\\["\\\/bfnrtu]/g,"@").replace(/"[^"\\\n\r\u2028\u2029\x00-\x08\x0a-\x1f]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:[\s\u2028\u2029]*\[)+/g,"")))try{return eval("("+a+")")}catch(b){}throw Error("Invalid JSON string: "+a);}function lb(a){return eval("("+a+")")}function mb(a){return nb(new ob(void 0),a)}function ob(a){this.a=a}
-function nb(a,b){var c=[];pb(a,b,c);return c.join("")}
-function pb(a,b,c){switch(typeof b){case "string":qb(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(null==b){c.push("null");break}if(t(b)){var d=b.length;c.push("[");for(var e="",g=0;g<d;g++)c.push(e),e=b[g],pb(a,a.a?a.a.call(b,String(g),e):e,c),e=",";c.push("]");break}c.push("{");d="";for(g in b)Object.prototype.hasOwnProperty.call(b,g)&&(e=b[g],"function"!=typeof e&&(c.push(d),qb(g,c),c.push(":"),
-pb(a,a.a?a.a.call(b,g,e):e,c),d=","));c.push("}");break;case "function":break;default:throw Error("Unknown type: "+typeof b);}}var rb={'"':'\\"',"\\":"\\\\","/":"\\/","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\x0B":"\\u000b"},sb=/\uffff/.test("\uffff")?/[\\\"\x00-\x1f\x7f-\uffff]/g:/[\\\"\x00-\x1f\x7f-\xff]/g;
-function qb(a,b){b.push('"',a.replace(sb,function(a){if(a in rb)return rb[a];var b=a.charCodeAt(0),e="\\u";16>b?e+="000":256>b?e+="00":4096>b&&(e+="0");return rb[a]=e+b.toString(16)}),'"')};function tb(a,b,c){return Math.min(Math.max(a,b),c)};function B(a,b){this.x=q(a)?a:0;this.y=q(b)?b:0}f=B.prototype;f.clone=function(){return new B(this.x,this.y)};function ub(a,b){var c=a.x-b.x,d=a.y-b.y;return Math.sqrt(c*c+d*d)}function vb(a,b){return new B(a.x-b.x,a.y-b.y)}f.ceil=function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);return this};f.floor=function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);return this};f.round=function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this};
-f.scale=function(a,b){var c=ga(b)?b:a;this.x*=a;this.y*=c;return this};function wb(a,b,c,d){this.top=a;this.right=b;this.bottom=c;this.left=d}f=wb.prototype;f.clone=function(){return new wb(this.top,this.right,this.bottom,this.left)};f.contains=function(a){return this&&a?a instanceof wb?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:!1};
-f.ceil=function(){this.top=Math.ceil(this.top);this.right=Math.ceil(this.right);this.bottom=Math.ceil(this.bottom);this.left=Math.ceil(this.left);return this};f.floor=function(){this.top=Math.floor(this.top);this.right=Math.floor(this.right);this.bottom=Math.floor(this.bottom);this.left=Math.floor(this.left);return this};f.round=function(){this.top=Math.round(this.top);this.right=Math.round(this.right);this.bottom=Math.round(this.bottom);this.left=Math.round(this.left);return this};
-f.scale=function(a,b){var c=ga(b)?b:a;this.left*=a;this.right*=a;this.top*=c;this.bottom*=c;return this};function C(a,b){this.width=a;this.height=b}function xb(a,b){return a==b?!0:a&&b?a.width==b.width&&a.height==b.height:!1}f=C.prototype;f.clone=function(){return new C(this.width,this.height)};function yb(a){return a.width/a.height}f.isEmpty=function(){return!(this.width*this.height)};f.ceil=function(){this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};f.floor=function(){this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};
-f.round=function(){this.width=Math.round(this.width);this.height=Math.round(this.height);return this};f.scale=function(a,b){var c=ga(b)?b:a;this.width*=a;this.height*=c;return this};function zb(a,b){return a.scale(yb(a)>yb(b)?b.width/a.width:b.height/a.height)};function Ab(a,b,c,d){this.left=a;this.top=b;this.width=c;this.height=d}f=Ab.prototype;f.clone=function(){return new Ab(this.left,this.top,this.width,this.height)};function Bb(a){return new Ab(a.left,a.top,a.right-a.left,a.bottom-a.top)}f.contains=function(a){return a instanceof Ab?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};
-f.ceil=function(){this.left=Math.ceil(this.left);this.top=Math.ceil(this.top);this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};f.floor=function(){this.left=Math.floor(this.left);this.top=Math.floor(this.top);this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};f.round=function(){this.left=Math.round(this.left);this.top=Math.round(this.top);this.width=Math.round(this.width);this.height=Math.round(this.height);return this};
-f.scale=function(a,b){var c=ga(b)?b:a;this.left*=a;this.width*=a;this.top*=c;this.height*=c;return this};function Cb(a,b,c){for(var d in a)b.call(c,a[d],d,a)}function Db(a,b){for(var c in a)if(!b.call(void 0,a[c],c,a))return!1;return!0}function Eb(a){var b=[],c=0,d;for(d in a)b[c++]=a[d];return b}function Fb(a){var b=[],c=0,d;for(d in a)b[c++]=d;return b}function Gb(a,b){for(var c in a)if(a[c]==b)return!0;return!1}function Hb(a,b){for(var c in a)if(b.call(void 0,a[c],c,a))return c}function Ib(a){for(var b in a)return!1;return!0}function Jb(a){var b={},c;for(c in a)b[c]=a[c];return b}
-function Kb(a){var b=da(a);if("object"==b||"array"==b){if(a.clone)return a.clone();var b="array"==b?[]:{},c;for(c in a)b[c]=Kb(a[c]);return b}return a}var Lb="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");function Mb(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 g=0;g<Lb.length;g++)c=Lb[g],Object.prototype.hasOwnProperty.call(d,c)&&(a[c]=d[c])}}
-function Nb(a){var b=arguments.length;if(1==b&&t(arguments[0]))return Nb.apply(null,arguments[0]);if(b%2)throw Error("Uneven number of arguments");for(var c={},d=0;d<b;d+=2)c[arguments[d]]=arguments[d+1];return c};function Ob(a){return function(){throw a;}};var Pb,Qb,Rb,Sb,Tb,Ub,Vb;function Wb(){return l.navigator?l.navigator.userAgent:null}function Xb(){return l.navigator}Tb=Sb=Rb=Qb=Pb=!1;var Yb;if(Yb=Wb()){var Zb=Xb();Pb=0==Yb.lastIndexOf("Opera",0);Qb=!Pb&&(-1!=Yb.indexOf("MSIE")||-1!=Yb.indexOf("Trident"));Sb=(Rb=!Pb&&-1!=Yb.indexOf("WebKit"))&&-1!=Yb.indexOf("Mobile");Tb=!Pb&&!Rb&&!Qb&&"Gecko"==Zb.product}var $b=Pb,D=Qb,ac=Tb,bc=Rb,cc=Sb,dc=Xb(),ec=dc&&dc.platform||"";Ub=-1!=ec.indexOf("Mac");Vb=-1!=ec.indexOf("Win");
-var fc=!!Xb()&&-1!=(Xb().appVersion||"").indexOf("X11");function gc(){var a=l.document;return a?a.documentMode:void 0}var hc;t:{var ic="",jc;if($b&&l.opera)var kc=l.opera.version,ic="function"==typeof kc?kc():kc;else if(ac?jc=/rv\:([^\);]+)(\)|;)/:D?jc=/\b(?:MSIE|rv)[: ]([^\);]+)(\)|;)/:bc&&(jc=/WebKit\/(\S+)/),jc)var lc=jc.exec(Wb()),ic=lc?lc[1]:"";if(D){var mc=gc();if(mc>parseFloat(ic)){hc=String(mc);break t}}hc=ic}var nc=hc,oc={};function pc(a){return oc[a]||(oc[a]=0<=Ba(nc,a))}
-function qc(a){return D&&rc>=a}var sc=l.document,rc=sc&&D?gc()||("CSS1Compat"==sc.compatMode?parseInt(nc,10):5):void 0;var tc,uc=!D||qc(9),vc=!ac&&!D||D&&qc(9)||ac&&pc("1.9.1"),wc=D&&!pc("9"),xc=D||$b||bc;function yc(a){a=a.className;return u(a)&&a.match(/\S+/g)||[]}function zc(a,b){for(var c=yc(a),d=ab(arguments,1),e=c.length+d.length,g=c,h=0;h<d.length;h++)A(g,d[h])||g.push(d[h]);g=c.join(" ");a.className=g;return c.length==e}function Ac(a,b){var c=yc(a),d=ab(arguments,1),c=Bc(c,d).join(" ");a.className=c}function Bc(a,b){return Ia(a,function(a){return!A(b,a)})}function Cc(a,b){return A(yc(a),b)}function Dc(a,b,c){c?zc(a,b):Ac(a,b)}function Ec(a,b){var c=!Cc(a,b);Dc(a,b,c)};function Fc(a){return a?new Gc(Hc(a)):tc||(tc=new Gc)}function Ic(a){return u(a)?document.getElementById(a):a}function Jc(a,b){var c=b||document;return c.querySelectorAll&&c.querySelector?c.querySelectorAll("."+a):c.getElementsByClassName?c.getElementsByClassName(a):Kc("*",a,b)}function E(a,b){var c=b||document,d=null;return(d=c.querySelectorAll&&c.querySelector?c.querySelector("."+a):Jc(a,b)[0])||null}
-function Kc(a,b,c){var d=document;c=c||d;a=a&&"*"!=a?a.toUpperCase():"";if(c.querySelectorAll&&c.querySelector&&(a||b))return c.querySelectorAll(a+(b?"."+b:""));if(b&&c.getElementsByClassName){c=c.getElementsByClassName(b);if(a){for(var d={},e=0,g=0,h;h=c[g];g++)a==h.nodeName&&(d[e++]=h);d.length=e;return d}return c}c=c.getElementsByTagName(a||"*");if(b){d={};for(g=e=0;h=c[g];g++)a=h.className,"function"==typeof a.split&&A(a.split(/\s+/),b)&&(d[e++]=h);d.length=e;return d}return c}
-function Lc(a,b){Cb(b,function(b,d){"style"==d?a.style.cssText=b:"class"==d?a.className=b:"for"==d?a.htmlFor=b:d in Mc?a.setAttribute(Mc[d],b):0==d.lastIndexOf("aria-",0)||0==d.lastIndexOf("data-",0)?a.setAttribute(d,b):a[d]=b})}var Mc={cellpadding:"cellPadding",cellspacing:"cellSpacing",colspan:"colSpan",frameborder:"frameBorder",height:"height",maxlength:"maxLength",role:"role",rowspan:"rowSpan",type:"type",usemap:"useMap",valign:"vAlign",width:"width"};
-function Nc(a){a=a.document;a="CSS1Compat"==a.compatMode?a.documentElement:a.body;return new C(a.clientWidth,a.clientHeight)}function Oc(a){var b=bc||"CSS1Compat"!=a.compatMode?a.body:a.documentElement;a=a.parentWindow||a.defaultView;return D&&pc("10")&&a.pageYOffset!=b.scrollTop?new B(b.scrollLeft,b.scrollTop):new B(a.pageXOffset||b.scrollLeft,a.pageYOffset||b.scrollTop)}
-function Pc(a,b,c){var d=arguments,e=document,g=d[0],h=d[1];if(!uc&&h&&(h.name||h.type)){g=["<",g];h.name&&g.push(' name="',va(h.name),'"');if(h.type){g.push(' type="',va(h.type),'"');var k={};Mb(k,h);delete k.type;h=k}g.push(">");g=g.join("")}g=e.createElement(g);h&&(u(h)?g.className=h:t(h)?zc.apply(null,[g].concat(h)):Lc(g,h));2<d.length&&Qc(e,g,d,2);return g}
-function Qc(a,b,c,d){function e(c){c&&b.appendChild(u(c)?a.createTextNode(c):c)}for(;d<c.length;d++){var g=c[d];!fa(g)||ia(g)&&0<g.nodeType?e(g):z(Rc(g)?Ya(g):g,e)}}function Sc(a){return document.createElement(a)}function Tc(a){return document.createTextNode(String(a))}function Uc(a,b){Qc(Hc(a),a,arguments,1)}function Vc(a){for(var b;b=a.firstChild;)a.removeChild(b)}function F(a){a&&a.parentNode&&a.parentNode.removeChild(a)}
-function Wc(a){if(void 0!=a.firstElementChild)a=a.firstElementChild;else for(a=a.firstChild;a&&1!=a.nodeType;)a=a.nextSibling;return a}function Xc(a){if(xc&&!(D&&pc("9")&&!pc("10")&&l.SVGElement&&a instanceof l.SVGElement))return a.parentElement;a=a.parentNode;return ia(a)&&1==a.nodeType?a:null}
-function Yc(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}function Hc(a){return 9==a.nodeType?a:a.ownerDocument||a.document}
-function Zc(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 Vc(a),a.appendChild(Hc(a).createTextNode(String(b)))}function $c(a,b){var c=[];return ad(a,b,c,!0)?c[0]:void 0}function ad(a,b,c,d){if(null!=a)for(a=a.firstChild;a;){if(b(a)&&(c.push(a),d)||ad(a,b,c,d))return!0;a=a.nextSibling}return!1}var bd={SCRIPT:1,STYLE:1,HEAD:1,IFRAME:1,OBJECT:1},cd={IMG:" ",BR:"\n"};
-function dd(a,b,c){if(!(a.nodeName in bd))if(3==a.nodeType)c?b.push(String(a.nodeValue).replace(/(\r\n|\r|\n)/g,"")):b.push(a.nodeValue);else if(a.nodeName in cd)b.push(cd[a.nodeName]);else for(a=a.firstChild;a;)dd(a,b,c),a=a.nextSibling}function Rc(a){if(a&&"number"==typeof a.length){if(ia(a))return"function"==typeof a.item||"string"==typeof a.item;if(ha(a))return"function"==typeof a.item}return!1}function ed(a,b){return b?fd(a,function(a){return!b||Cc(a,b)},!0):null}
-function fd(a,b,c,d){c||(a=a.parentNode);c=null==d;for(var e=0;a&&(c||e<=d);){if(b(a))return a;a=a.parentNode;e++}return null}function Gc(a){this.a=a||l.document||document}f=Gc.prototype;f.M=function(a){return u(a)?this.a.getElementById(a):a};f.createElement=function(a){return this.a.createElement(a)};function gd(a){return"CSS1Compat"==a.a.compatMode}function hd(a){return Oc(a.a)}f.appendChild=function(a,b){a.appendChild(b)};f.append=Uc;
-f.getChildren=function(a){return vc&&void 0!=a.children?a.children:Ia(a.childNodes,function(a){return 1==a.nodeType})};f.contains=Yc;function id(a,b,c){u(b)?jd(a,c,b):Cb(b,oa(jd,a))}function jd(a,b,c){var d;t:if(d=Da(c),void 0===a.style[d]&&(c=(bc?"Webkit":ac?"Moz":D?"ms":$b?"O":null)+Ea(c),void 0!==a.style[c])){d=c;break t}d&&(a.style[d]=b)}function kd(a,b){var c=Hc(a);return c.defaultView&&c.defaultView.getComputedStyle&&(c=c.defaultView.getComputedStyle(a,null))?c[b]||c.getPropertyValue(b)||"":""}function ld(a,b){return kd(a,b)||(a.currentStyle?a.currentStyle[b]:null)||a.style&&a.style[b]}
-function md(a,b,c){var d,e=ac&&(Ub||fc)&&pc("1.9");b instanceof B?(d=b.x,b=b.y):(d=b,b=c);a.style.left=nd(d,e);a.style.top=nd(b,e)}function od(a){return new B(a.offsetLeft,a.offsetTop)}function pd(a){var b;try{b=a.getBoundingClientRect()}catch(c){return{left:0,top:0,right:0,bottom:0}}D&&a.ownerDocument.body&&(a=a.ownerDocument,b.left-=a.documentElement.clientLeft+a.body.clientLeft,b.top-=a.documentElement.clientTop+a.body.clientTop);return b}
-function qd(a){if(D&&!qc(8))return a.offsetParent;var b=Hc(a),c=ld(a,"position"),d="fixed"==c||"absolute"==c;for(a=a.parentNode;a&&a!=b;a=a.parentNode)if(c=ld(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 null}
-function rd(a){for(var b=new wb(0,Infinity,Infinity,0),c=Fc(a),d=c.a.body,e=c.a.documentElement,g=bc||"CSS1Compat"!=c.a.compatMode?c.a.body:c.a.documentElement;a=qd(a);)if(!(D&&0==a.clientWidth||bc&&0==a.clientHeight&&a==d||a==d||a==e||"visible"==ld(a,"overflow"))){var h=sd(a),k;k=a;if(ac&&!pc("1.9")){var m=parseFloat(kd(k,"borderLeftWidth"));if(td(k))var p=k.offsetWidth-k.clientWidth-m-parseFloat(kd(k,"borderRightWidth")),m=m+p;k=new B(m,parseFloat(kd(k,"borderTopWidth")))}else k=new B(k.clientLeft,
-k.clientTop);h.x+=k.x;h.y+=k.y;b.top=Math.max(b.top,h.y);b.right=Math.min(b.right,h.x+a.clientWidth);b.bottom=Math.min(b.bottom,h.y+a.clientHeight);b.left=Math.max(b.left,h.x)}d=g.scrollLeft;g=g.scrollTop;b.left=Math.max(b.left,d);b.top=Math.max(b.top,g);c=Nc(c.a.parentWindow||c.a.defaultView||window);b.right=Math.min(b.right,d+c.width);b.bottom=Math.min(b.bottom,g+c.height);return 0<=b.top&&0<=b.left&&b.bottom>b.top&&b.right>b.left?b:null}
-function sd(a){var b,c=Hc(a),d=ld(a,"position"),e=ac&&c.getBoxObjectFor&&!a.getBoundingClientRect&&"absolute"==d&&(b=c.getBoxObjectFor(a))&&(0>b.screenX||0>b.screenY),g=new B(0,0),h;b=c?Hc(c):document;h=!D||qc(9)||gd(Fc(b))?b.documentElement:b.body;if(a==h)return g;if(a.getBoundingClientRect)b=pd(a),a=hd(Fc(c)),g.x=b.left+a.x,g.y=b.top+a.y;else if(c.getBoxObjectFor&&!e)b=c.getBoxObjectFor(a),a=c.getBoxObjectFor(h),g.x=b.screenX-a.screenX,g.y=b.screenY-a.screenY;else{b=a;do{g.x+=b.offsetLeft;g.y+=
-b.offsetTop;b!=a&&(g.x+=b.clientLeft||0,g.y+=b.clientTop||0);if(bc&&"fixed"==ld(b,"position")){g.x+=c.body.scrollLeft;g.y+=c.body.scrollTop;break}b=b.offsetParent}while(b&&b!=a);if($b||bc&&"absolute"==d)g.y-=c.body.offsetTop;for(b=a;(b=qd(b))&&b!=c.body&&b!=h;)g.x-=b.scrollLeft,$b&&"TR"==b.tagName||(g.y-=b.scrollTop)}return g}function ud(a,b){var c=vd(a),d=vd(b);return new B(c.x-d.x,c.y-d.y)}
-function wd(a){var b;if(a.getBoundingClientRect)b=pd(a),b=new B(b.left,b.top);else{b=hd(Fc(a));var c=sd(a);b=new B(c.x-b.x,c.y-b.y)}if(ac&&!pc(12)){var d;D?d="-ms-transform":bc?d="-webkit-transform":$b?d="-o-transform":ac&&(d="-moz-transform");var e;d&&(e=ld(a,d));e||(e=ld(a,"transform"));a=e?(a=e.match(xd))?new B(parseFloat(a[1]),parseFloat(a[2])):new B(0,0):new B(0,0);a=new B(b.x+a.x,b.y+a.y)}else a=b;return a}
-function vd(a){if(1==a.nodeType)return wd(a);var b=ha(a.$x),c=a;a.targetTouches?c=a.targetTouches[0]:b&&a.re.targetTouches&&(c=a.re.targetTouches[0]);return new B(c.clientX,c.clientY)}function yd(a,b,c){if(b instanceof C)c=b.height,b=b.width;else if(void 0==c)throw Error("missing height argument");zd(a,b);a.style.height=nd(c,!0)}function nd(a,b){"number"==typeof a&&(a=(b?Math.round(a):a)+"px");return a}function zd(a,b){a.style.width=nd(b,!0)}
-function Ad(a){var b=Bd;if("none"!=ld(a,"display"))return b(a);var c=a.style,d=c.display,e=c.visibility,g=c.position;c.visibility="hidden";c.position="absolute";c.display="inline";a=b(a);c.display=d;c.position=g;c.visibility=e;return a}function Bd(a){var b=a.offsetWidth,c=a.offsetHeight,d=bc&&!b&&!c;return q(b)&&!d||!a.getBoundingClientRect?new C(b,c):(a=pd(a),new C(a.right-a.left,a.bottom-a.top))}function Cd(a){var b=sd(a);a=Ad(a);return new Ab(b.x,b.y,a.width,a.height)}
-function Dd(a,b){var c=a.style;"opacity"in c?c.opacity=b:"MozOpacity"in c?c.MozOpacity=b:"filter"in c&&(c.filter=""===b?"":"alpha(opacity="+100*b+")")}function td(a){return"rtl"==ld(a,"direction")}
-function Ed(a){var b=Hc(a),c=D&&a.currentStyle;if(c&&gd(Fc(b))&&"auto"!=c.width&&"auto"!=c.height&&!c.boxSizing)return b=Fd(a,c.width,"width","pixelWidth"),a=Fd(a,c.height,"height","pixelHeight"),new C(b,a);c=new C(a.offsetWidth,a.offsetHeight);b=Gd(a);a=Hd(a);return new C(c.width-a.left-b.left-b.right-a.right,c.height-a.top-b.top-b.bottom-a.bottom)}
-function Fd(a,b,c,d){if(/^\d+px?$/.test(b))return parseInt(b,10);var e=a.style[c],g=a.runtimeStyle[c];a.runtimeStyle[c]=a.currentStyle[c];a.style[c]=b;b=a.style[d];a.style[c]=e;a.runtimeStyle[c]=g;return b}function Id(a,b){var c=a.currentStyle?a.currentStyle[b]:null;return c?Fd(a,c,"left","pixelLeft"):0}
-function Gd(a){if(D){var b=Id(a,"paddingLeft"),c=Id(a,"paddingRight"),d=Id(a,"paddingTop");a=Id(a,"paddingBottom");return new wb(d,c,a,b)}b=kd(a,"paddingLeft");c=kd(a,"paddingRight");d=kd(a,"paddingTop");a=kd(a,"paddingBottom");return new wb(parseFloat(d),parseFloat(c),parseFloat(a),parseFloat(b))}var Jd={thin:2,medium:4,thick:6};
-function Kd(a,b){if("none"==(a.currentStyle?a.currentStyle[b+"Style"]:null))return 0;var c=a.currentStyle?a.currentStyle[b+"Width"]:null;return c in Jd?Jd[c]:Fd(a,c,"left","pixelLeft")}function Hd(a){if(D){var b=Kd(a,"borderLeft"),c=Kd(a,"borderRight"),d=Kd(a,"borderTop");a=Kd(a,"borderBottom");return new wb(d,c,a,b)}b=kd(a,"borderLeftWidth");c=kd(a,"borderRightWidth");d=kd(a,"borderTopWidth");a=kd(a,"borderBottomWidth");return new wb(parseFloat(d),parseFloat(c),parseFloat(a),parseFloat(b))}
-var Ld=/[^\d]+$/,Md={cm:1,"in":1,mm:1,pc:1,pt:1},Nd={em:1,ex:1};
-function Od(a){var b=ld(a,"fontSize"),c;c=(c=b.match(Ld))&&c[0]||null;if(b&&"px"==c)return parseInt(b,10);if(D){if(c in Md)return Fd(a,b,"left","pixelLeft");if(a.parentNode&&1==a.parentNode.nodeType&&c in Nd)return a=a.parentNode,c=ld(a,"fontSize"),Fd(a,b==c?"1em":b,"left","pixelLeft")}c=Pc("span",{style:"visibility:hidden;position:absolute;line-height:0;padding:0;margin:0;border:0;height:1em;"});a.appendChild(c);b=c.offsetHeight;F(c);return b}var xd=/matrix\([0-9\.\-]+, [0-9\.\-]+, [0-9\.\-]+, [0-9\.\-]+, ([0-9\.\-]+)p?x?, ([0-9\.\-]+)p?x?\)/;var Pd="StopIteration"in l?l.StopIteration:Error("StopIteration");function Qd(){}Qd.prototype.next=function(){throw Pd;};Qd.prototype.Kd=function(){return this};function Rd(a){if(a instanceof Qd)return a;if("function"==typeof a.Kd)return a.Kd(!1);if(fa(a)){var b=0,c=new Qd;c.next=function(){for(;;){if(b>=a.length)throw Pd;if(b in a)return a[b++];b++}};return c}throw Error("Not implemented");}
-function Sd(a,b,c){if(fa(a))try{z(a,b,c)}catch(d){if(d!==Pd)throw d;}else{a=Rd(a);try{for(;;)b.call(c,a.next(),void 0,a)}catch(e){if(e!==Pd)throw e;}}}function Td(a){if(fa(a))return Ya(a);a=Rd(a);var b=[];Sd(a,function(a){b.push(a)});return b};function Ud(a,b){this.b={};this.a=[];this.g=this.Q=0;var c=arguments.length;if(1<c){if(c%2)throw Error("Uneven number of arguments");for(var d=0;d<c;d+=2)this.set(arguments[d],arguments[d+1])}else if(a){a instanceof Ud?(c=a.nc(),d=a.hc()):(c=Fb(a),d=Eb(a));for(var e=0;e<c.length;e++)this.set(c[e],d[e])}}f=Ud.prototype;f.fb=function(){return this.Q};f.hc=function(){Vd(this);for(var a=[],b=0;b<this.a.length;b++)a.push(this.b[this.a[b]]);return a};f.nc=function(){Vd(this);return this.a.concat()};
-f.equals=function(a,b){if(this===a)return!0;if(this.Q!=a.fb())return!1;var c=b||Wd;Vd(this);for(var d,e=0;d=this.a[e];e++)if(!c(this.get(d),a.get(d)))return!1;return!0};function Wd(a,b){return a===b}f.isEmpty=function(){return 0==this.Q};f.clear=function(){this.b={};this.g=this.Q=this.a.length=0};f.remove=function(a){return Xd(this.b,a)?(delete this.b[a],this.Q--,this.g++,this.a.length>2*this.Q&&Vd(this),!0):!1};
-function Vd(a){if(a.Q!=a.a.length){for(var b=0,c=0;b<a.a.length;){var d=a.a[b];Xd(a.b,d)&&(a.a[c++]=d);b++}a.a.length=c}if(a.Q!=a.a.length){for(var e={},c=b=0;b<a.a.length;)d=a.a[b],Xd(e,d)||(a.a[c++]=d,e[d]=1),b++;a.a.length=c}}f.get=function(a,b){return Xd(this.b,a)?this.b[a]:b};f.set=function(a,b){Xd(this.b,a)||(this.Q++,this.a.push(a),this.g++);this.b[a]=b};f.clone=function(){return new Ud(this)};
-f.Kd=function(a){Vd(this);var b=0,c=this.a,d=this.b,e=this.g,g=this,h=new Qd;h.next=function(){for(;;){if(e!=g.g)throw Error("The map has changed since the iterator was created");if(b>=c.length)throw Pd;var h=c[b++];return a?h:d[h]}};return h};function Xd(a,b){return Object.prototype.hasOwnProperty.call(a,b)};function Yd(a){if("function"==typeof a.hc)return a.hc();if(u(a))return a.split("");if(fa(a)){for(var b=[],c=a.length,d=0;d<c;d++)b.push(a[d]);return b}return Eb(a)}function Zd(a,b,c){if("function"==typeof a.forEach)a.forEach(b,c);else if(fa(a)||u(a))z(a,b,c);else{var d;if("function"==typeof a.nc)d=a.nc();else if("function"!=typeof a.hc)if(fa(a)||u(a)){d=[];for(var e=a.length,g=0;g<e;g++)d.push(g)}else d=Fb(a);else d=void 0;for(var e=Yd(a),g=e.length,h=0;h<g;h++)b.call(c,e[h],d&&d[h],a)}};function $d(a,b,c,d,e){var g="";a&&(g+=a+":");c&&(g+="//",b&&(g+=b+"@"),g+=c,d&&(g+=":"+d));e&&(g+=e);return g}var ae=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([^/#?]*?)(?::([0-9]+))?(?=[/#?]|$))?([^?#]+)?(?:\\?([^#]*))?(?:#(.*))?$");function be(a){if(ce){ce=!1;var b=l.location;if(b){var c=b.href;if(c&&(c=de(c))&&c!=b.hostname)throw ce=!0,Error();}}return a.match(ae)}var ce=bc;function de(a){return(a=be(a)[3]||null)&&decodeURIComponent(a)}
-function ee(a){return(a=be(a)[5]||null)&&decodeURIComponent(a)}function fe(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]=void 0)}return a.join("")}function ge(a,b,c){if(t(b))for(var d=0;d<b.length;d++)ge(a,String(b[d]),c);else null!=b&&c.push("&",a,""===b?"":"=",encodeURIComponent(String(b)))}function he(a,b,c){Math.max(b.length-(c||0),0);for(c=c||0;c<b.length;c+=2)ge(b[c],b[c+1],a);return a}
-function ie(a,b){for(var c in b)ge(c,b[c],a);return a}function je(a,b){return fe(2==arguments.length?he([a],arguments[1],0):he([a],arguments,1))}function ke(a,b,c){a=[a,"&",b];null!=c&&a.push("=",encodeURIComponent(String(c)));return fe(a)}function le(a,b,c,d){for(var e=c.length;0<=(b=a.indexOf(c,b))&&b<d;){var g=a.charCodeAt(b-1);if(38==g||63==g)if(g=a.charCodeAt(b+e),!g||61==g||38==g||35==g)return b;b+=e+1}return-1}var me=/#|$/,ne=/[?&]($|#)/;
-function oe(a,b){for(var c=a.search(me),d=0,e,g=[];0<=(e=le(a,d,b,c));)g.push(a.substring(d,e)),d=Math.min(a.indexOf("&",e)+1||c,c);g.push(a.substr(d));return g.join("").replace(ne,"$1")};function pe(a,b){var c;if(a instanceof pe)this.Ze=q(b)?b:a.Ze,qe(this,a.Vf),this.Qi=a.Qi,re(this,a.Oe),se(this,a.oh),this.ph=a.ph,te(this,a.a.clone()),ue(this,a.Al);else if(a&&(c=be(String(a)))){this.Ze=!!b;qe(this,c[1]||"",!0);var d=c[2]||"";this.Qi=d?decodeURIComponent(d):"";re(this,c[3]||"",!0);se(this,c[4]);this.ph=(d=c[5]||"")?decodeURIComponent(d):"";te(this,c[6]||"",!0);ue(this,c[7]||"",!0)}else this.Ze=!!b,this.a=new ve(null,0,this.Ze)}f=pe.prototype;f.Vf="";f.Qi="";f.Oe="";f.oh=null;
-f.ph="";f.Al="";f.Ze=!1;f.toString=function(){var a=[],b=this.Vf;b&&a.push(we(b,xe),":");if(b=this.Oe){a.push("//");var c=this.Qi;c&&a.push(we(c,xe),"@");a.push(encodeURIComponent(String(b)));b=this.oh;null!=b&&a.push(":",String(b))}if(b=this.ph)this.Oe&&"/"!=b.charAt(0)&&a.push("/"),a.push(we(b,"/"==b.charAt(0)?ye:ze));(b=this.a.toString())&&a.push("?",b);(b=this.Al)&&a.push("#",we(b,Ae));return a.join("")};f.clone=function(){return new pe(this)};
-function qe(a,b,c){a.Vf=c?b?decodeURIComponent(b):"":b;a.Vf&&(a.Vf=a.Vf.replace(/:$/,""))}function re(a,b,c){a.Oe=c?b?decodeURIComponent(b):"":b}function se(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.oh=b}else a.oh=null}function te(a,b,c){b instanceof ve?(a.a=b,Be(a.a,a.Ze)):(c||(b=we(b,Ce)),a.a=new ve(b,0,a.Ze))}function De(a,b,c){a.a.set(b,c)}function Ee(a,b,c){t(c)||(c=[String(c)]);Fe(a.a,b,c)}function ue(a,b,c){a.Al=c?b?decodeURIComponent(b):"":b;return a}
-function Ge(a){De(a,"zx",Math.floor(2147483648*Math.random()).toString(36)+Math.abs(Math.floor(2147483648*Math.random())^w()).toString(36));return a}function He(a){return a instanceof pe?a.clone():new pe(a,void 0)}function Ie(a,b,c,d){var e=new pe(null,void 0);a&&qe(e,a);b&&re(e,b);c&&se(e,c);d&&(e.ph=d);return e}function we(a,b){return u(a)?encodeURI(a).replace(b,Je):null}function Je(a){a=a.charCodeAt(0);return"%"+(a>>4&15).toString(16)+(a&15).toString(16)}
-var xe=/[#\/\?@]/g,ze=/[\#\?:]/g,ye=/[\#\?]/g,Ce=/[\#\?@]/g,Ae=/#/g;function ve(a,b,c){this.a=a||null;this.b=!!c}function Ke(a){if(!a.Ha&&(a.Ha=new Ud,a.Q=0,a.a))for(var b=a.a.split("&"),c=0;c<b.length;c++){var d=b[c].indexOf("="),e=null,g=null;0<=d?(e=b[c].substring(0,d),g=b[c].substring(d+1)):e=b[c];e=ua(e);e=Le(a,e);a.add(e,g?ua(g):"")}}f=ve.prototype;f.Ha=null;f.Q=null;f.fb=function(){Ke(this);return this.Q};
-f.add=function(a,b){Ke(this);this.a=null;a=Le(this,a);var c=this.Ha.get(a);c||this.Ha.set(a,c=[]);c.push(b);this.Q++;return this};f.remove=function(a){Ke(this);a=Le(this,a);return Xd(this.Ha.b,a)?(this.a=null,this.Q-=this.Ha.get(a).length,this.Ha.remove(a)):!1};f.clear=function(){this.Ha=this.a=null;this.Q=0};f.isEmpty=function(){Ke(this);return 0==this.Q};function Me(a,b){Ke(a);b=Le(a,b);return Xd(a.Ha.b,b)}
-f.nc=function(){Ke(this);for(var a=this.Ha.hc(),b=this.Ha.nc(),c=[],d=0;d<b.length;d++)for(var e=a[d],g=0;g<e.length;g++)c.push(b[d]);return c};f.hc=function(a){Ke(this);var b=[];if(u(a))Me(this,a)&&(b=Xa(b,this.Ha.get(Le(this,a))));else{a=this.Ha.hc();for(var c=0;c<a.length;c++)b=Xa(b,a[c])}return b};f.set=function(a,b){Ke(this);this.a=null;a=Le(this,a);Me(this,a)&&(this.Q-=this.Ha.get(a).length);this.Ha.set(a,[b]);this.Q++;return this};
-f.get=function(a,b){var c=a?this.hc(a):[];return 0<c.length?String(c[0]):b};function Fe(a,b,c){a.remove(b);0<c.length&&(a.a=null,a.Ha.set(Le(a,b),Ya(c)),a.Q+=c.length)}f.toString=function(){if(this.a)return this.a;if(!this.Ha)return"";for(var a=[],b=this.Ha.nc(),c=0;c<b.length;c++)for(var d=b[c],e=encodeURIComponent(String(d)),d=this.hc(d),g=0;g<d.length;g++){var h=e;""!==d[g]&&(h+="="+encodeURIComponent(String(d[g])));a.push(h)}return this.a=a.join("&")};
-f.clone=function(){var a=new ve;a.a=this.a;this.Ha&&(a.Ha=this.Ha.clone(),a.Q=this.Q);return a};function Le(a,b){var c=String(b);a.b&&(c=c.toLowerCase());return c}function Be(a,b){b&&!a.b&&(Ke(a),a.a=null,Zd(a.Ha,function(a,b){var e=b.toLowerCase();b!=e&&(this.remove(b),Fe(this,e,a))},a));a.b=b};var Ne={};function Oe(a,b,c){a.dataset?a.dataset[Pe(b)]=c:a.setAttribute("data-"+b,c)}function G(a,b){return a.dataset?a.dataset[Pe(b)]:a.getAttribute("data-"+b)}var Qe={};function Pe(a){return Qe[a]||(Qe[a]=String(a).replace(/\-([a-z])/g,function(a,c){return c.toUpperCase()}))};var Re=n("yt.dom.getNextId_");if(!Re){Re=function(){return++Se};qa("yt.dom.getNextId_",Re);var Se=0}function Te(a,b){a=Ic(a);b=Ic(b);return!!fd(a,function(a){return a===b},!0,void 0)}function Ue(a,b){var c=Kc(a,null,b);return c.length?c[0]:null}function Ve(a,b){if(a in b)return b[a];var c=a.charAt(0).toUpperCase()+a.substr(1);if("moz"+c in b)return b["moz"+c];if("ms"+c in b)return b["ms"+c];if("o"+c in b)return b["o"+c];if("webkit"+c in b)return b["webkit"+c]}
-function We(a,b){var c;Ka(a,function(a){c=Ve(a,b);return!!c});return c}function Xe(a,b){return"on"+a in b?a:"onmoz"+a in b?"moz"+a:"onms"+a in b?"ms"+a:"ono"+a in b?"o"+a:"onwebkit"+a in b?"webkit"+a:null};var Ye=window.yt&&window.yt.config_||{};qa("yt.config_",Ye);var Ze=window.yt&&window.yt.tokens_||{};qa("yt.tokens_",Ze);var $e=window.yt&&window.yt.msgs_||{};qa("yt.msgs_",$e);var af=window.yt&&window.yt.timeouts_||[];qa("yt.timeouts_",af);var bf=window.yt&&window.yt.intervals_||[];qa("yt.intervals_",bf);function cf(a){df(Ye,arguments)}function ef(a,b){return a in Ye?Ye[a]:b}function ff(a){df(Ze,arguments)}function gf(a){return a in Ze?Ze[a]:void 0}
-function H(a,b){ha(a)&&(a=hf(a));var c=window.setTimeout(a,b);af.push(c);return c}function jf(a,b){ha(a)&&(a=hf(a));var c=window.setInterval(a,b);bf.push(c);return c}function I(a){window.clearTimeout(a)}function kf(a){window.clearInterval(a)}function hf(a){return a&&window.yterr?function(){try{return a.apply(this,arguments)}catch(b){throw lf(b),b;}}:a}function lf(a){if(window&&window.yterr){var b=n("yt.www.errors.log");b?b(a):(b=ef("ERRORS")||[],b.push(a),cf("ERRORS",b))}}
-function mf(a){df($e,arguments)}function J(a,b,c){var d=b||{};if(a=a in $e?$e[a]:c)for(var e in d)a=a.replace(RegExp("\\$"+e,"gi"),function(){return d[e]});return a}function nf(a,b){return of(a in $e?$e[a]:{},b)}function of(a,b){var c=ef("I18N_PLURAL_RULES")||function(a){return 1==a?"one":"other"};return(c=a["case"+b]||a[c(b)])?c.replace("#",b.toString()):b+""}function df(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]}};function pf(a){if(a=a||window.event){for(var b in a)b in qf||(this[b]=a[b]);this.scale=a.scale;this.rotation=a.rotation;this.gf=a;(b=a.target||a.srcElement)&&3==b.nodeType&&(b=b.parentNode);this.target=b;if(b=a.relatedTarget)try{b=b.nodeName&&b}catch(c){b=null}else"mouseover"==this.type?b=a.fromElement:"mouseout"==this.type&&(b=a.toElement);this.relatedTarget=b;this.clientX=void 0!=a.clientX?a.clientX:a.pageX;this.clientY=void 0!=a.clientY?a.clientY:a.pageY;if(document.body&&document.documentElement){b=
-document.body.scrollLeft+document.documentElement.scrollLeft;var d=document.body.scrollTop+document.documentElement.scrollTop;this.pageX=void 0!=a.pageX?a.pageX:a.clientX+b;this.pageY=void 0!=a.pageY?a.pageY:a.clientY+d}this.keyCode=a.keyCode?a.keyCode:a.which;this.charCode=a.charCode||("keypress"==this.type?this.keyCode:0);this.altKey=a.altKey;this.ctrlKey=a.ctrlKey;this.shiftKey=a.shiftKey;"MozMousePixelScroll"==this.type?(this.wheelDeltaX=a.axis==a.HORIZONTAL_AXIS?a.detail:0,this.wheelDeltaY=a.axis==
-a.HORIZONTAL_AXIS?0:a.detail):window.opera?(this.wheelDeltaX=0,this.wheelDeltaY=a.detail):0==a.wheelDelta%120?"WebkitTransform"in document.documentElement.style?window.chrome&&0==navigator.platform.indexOf("Mac")?(this.wheelDeltaX=a.wheelDeltaX/-30,this.wheelDeltaY=a.wheelDeltaY/-30):(this.wheelDeltaX=a.wheelDeltaX/-1.2,this.wheelDeltaY=a.wheelDeltaY/-1.2):(this.wheelDeltaX=0,this.wheelDeltaY=a.wheelDelta/-1.6):(this.wheelDeltaX=a.wheelDeltaX/-3,this.wheelDeltaY=a.wheelDeltaY/-3)}}f=pf.prototype;
-f.gf=null;f.type="";f.target=null;f.relatedTarget=null;f.currentTarget=null;f.data=null;f.source=null;f.state=null;f.keyCode=0;f.charCode=0;f.altKey=!1;f.ctrlKey=!1;f.shiftKey=!1;f.clientX=0;f.clientY=0;f.pageX=0;f.pageY=0;f.wheelDeltaX=0;f.wheelDeltaY=0;f.rotation=0;f.scale=1;f.preventDefault=function(){this.gf.returnValue=!1;this.gf.preventDefault&&this.gf.preventDefault()};f.stopPropagation=function(){this.gf.cancelBubble=!0;this.gf.stopPropagation&&this.gf.stopPropagation()};
-var qf={stopPropagation:1,preventMouseEvent:1,preventManipulation:1,preventDefault:1,layerX:1,layerY:1,scale:1,rotation:1};var rf=n("yt.events.listeners_")||{};qa("yt.events.listeners_",rf);var sf=n("yt.events.counter_")||{count:0};qa("yt.events.counter_",sf);function tf(a,b,c,d){return Hb(rf,function(e){return e[0]==a&&e[1]==b&&e[2]==c&&e[4]==!!d})}
-function K(a,b,c,d){if(!a||!a.addEventListener&&!a.attachEvent)return"";d=!!d;var e=tf(a,b,c,d);if(e)return e;var e=++sf.count+"",g=!("mouseenter"!=b&&"mouseleave"!=b||!a.addEventListener||"onmouseenter"in document),h;h=g?function(d){d=new pf(d);if(!fd(d.relatedTarget,function(b){return b==a},!0))return d.currentTarget=a,d.type=b,c.call(a,d)}:function(b){b=new pf(b);b.currentTarget=a;return c.call(a,b)};h=hf(h);rf[e]=[a,b,c,h,d];a.addEventListener?"mouseenter"==b&&g?a.addEventListener("mouseover",
-h,d):"mouseleave"==b&&g?a.addEventListener("mouseout",h,d):"mousewheel"==b&&"MozBoxSizing"in document.documentElement.style?a.addEventListener("MozMousePixelScroll",h,d):a.addEventListener(b,h,d):a.attachEvent("on"+b,h);return e}function uf(a,b){var c;return c=K(a,"timeupdate",function(){vf(c);b.apply(a,arguments)},void 0)}
-function wf(a,b,c){b=b.toLowerCase();var d=c,e="mouse"+b;if(Ve("pointerEnabled",window.navigator))e="MSPointer"+b.charAt(0).toUpperCase()+b.substr(1);else if(Xe("touchstart",document)){d=b;switch(b){case "down":d="start";break;case "up":d="end";break;case "over":d="enter";break;case "out":d="leave"}e="touch"+d;d=function(a){z(null,function(b){var d=new pf(a);pa(d,b);c(d)})}}return K(a,e,d)}function xf(a,b,c){yf(a,"change",b,function(a){return a.nodeName.toLowerCase()===c.toLowerCase()&&!0})}
-function zf(a,b,c){return yf(a,"click",b,function(a){return Cc(a,c)})}function yf(a,b,c,d){var e=a||document;return K(e,b,function(a){var b=fd(a.target,function(a){return a===e||d(a)},!0);b&&b!==e&&!b.disabled&&(a.currentTarget=b,c.call(b,a))})}function vf(a){a&&("string"==typeof a&&(a=[a]),z(a,function(a){if(a in rf){var c=rf[a],d=c[0],e=c[1],g=c[3],c=c[4];d.removeEventListener?d.removeEventListener(e,g,c):d.detachEvent&&d.detachEvent("on"+e,g);delete rf[a]}}))}
-function Af(a){for(var b in rf)rf[b][0]==a&&vf(b)}function Bf(a,b){if(document.createEvent){var c=document.createEvent("HTMLEvents");c.initEvent(b,!0,!0);a.dispatchEvent(c)}else c=document.createEventObject(),a.fireEvent("on"+b,c)};function Cf(){return!!We(["fullscreenEnabled","fullScreenEnabled"],document)}function Df(){return We(["fullscreenElement","fullScreenElement"],document)};function Ef(a){a=a||{};this.url=a.url||"";this.urlV8=a.url_v8||"";this.urlV9As2=a.url_v9as2||"";this.args=a.args||Jb(Ff);this.assets=a.assets||{};this.attrs=a.attrs||Jb(Gf);this.params=a.params||Jb(Hf);this.minVersion=a.min_version||"8.0.0";this.fallback=a.fallback||null;this.fallbackMessage=a.fallbackMessage||null;this.html5=!!a.html5;this.disable=a.disable||{};this.loaded=!!a.loaded}var Ff={enablejsapi:1},Gf={},Hf={allowscriptaccess:"always",allowfullscreen:"true",bgcolor:"#000000"};
-Ef.prototype.clone=function(){var a=new Ef,b;for(b in this){var c=this[b];"object"==da(c)?a[b]=Jb(c):a[b]=c}return a};var If={},Jf=0;function Kf(a,b){if(a){var c=new Image,d=""+Jf++;If[d]=c;c.onload=c.onerror=function(){b&&If[d]&&b();delete If[d]};c.src=a;c=eval("null")}};function Lf(){}Lf.prototype.Pc=!1;Lf.prototype.ha=function(){return this.Pc};Lf.prototype.dispose=function(){this.Pc||(this.Pc=!0,this.F())};function L(a,b){Mf(a,oa(Nf,b))}function Mf(a,b){a.rb||(a.rb=[]);a.rb.push(v(b,void 0))}Lf.prototype.F=function(){if(this.rb)for(;this.rb.length;)this.rb.shift()()};function Nf(a){a&&"function"==typeof a.dispose&&a.dispose()}function Of(a){for(var b=0,c=arguments.length;b<c;++b){var d=arguments[b];fa(d)?Of.apply(null,d):Nf(d)}};function Pf(a,b){this.app=a;this.b=null;this.g={};this.j={};this.o={};this.k={};this.i=null;this.a=b;N(this,"cueVideoById",this.Xr);N(this,"loadVideoById",this.Uj);N(this,"cueVideoByUrl",this.Yr);N(this,"loadVideoByUrl",this.ys);N(this,"playVideo",this.qg);N(this,"pauseVideo",this.mn);N(this,"stopVideo",this.Jj);N(this,"clearVideo",this.Vr);N(this,"getVideoBytesLoaded",this.js);N(this,"getVideoBytesTotal",this.ks);N(this,"getVideoLoadedFraction",this.ms);N(this,"getVideoStartBytes",this.os);N(this,
-"cuePlaylist",this.Wr);N(this,"loadPlaylist",this.xs);N(this,"nextVideo",this.As);N(this,"previousVideo",this.Bs);N(this,"playVideoAt",this.sj);N(this,"setShuffle",this.Gs);N(this,"setLoop",this.Ds);N(this,"getPlaylist",this.ub);N(this,"getPlaylistIndex",this.Wj);N(this,"getPlaylistId",this.hs);N(this,"loadModule",this.ws);N(this,"unloadModule",this.ln);N(this,"setOption",this.jn);N(this,"getOption",this.Ij);N(this,"getOptions",this.cs);N(this,"mute",this.Vm);N(this,"unMute",this.Xm);N(this,"isMuted",
-this.us);N(this,"setVolume",this.Wm);N(this,"getVolume",this.Um);N(this,"seekTo",this.Th);N(this,"getPlayerState",this.gs);N(this,"getPlaybackRate",this.es);N(this,"setPlaybackRate",this.Fs);N(this,"getAvailablePlaybackRates",this.$r);N(this,"getPlaybackQuality",this.ds);N(this,"setPlaybackQuality",this.Es);N(this,"getAvailableQualityLevels",this.as);N(this,"getCurrentTime",this.getCurrentTime);N(this,"getDuration",this.Ph);N(this,"addEventListener",this.addEventListener);N(this,"removeEventListener",
-this.removeEventListener);N(this,"getVideoUrl",this.rs);N(this,"getDebugText",this.bs);N(this,"getVideoEmbedCode",this.ls);N(this,"getVideoData",this.getVideoData);N(this,"addCueRange",this.Ur);N(this,"removeCueRange",this.Cs);N(this,"setSize",this.Hs);N(this,"getApiInterface",this.Zr);N(this,"destroy",this.destroy);N(this,"showVideoInfo",this.Is);N(this,"hideVideoInfo",this.ts);this.j.logFallback=v(this.zs,this);this.j.isNotServable=v(this.vs,this);this.j.getUpdatedConfigurationData=v(this.is,this)}
-y(Pf,Lf);function N(a,b,c){a.g[b]=v(c,a)}f=Pf.prototype;f.Zr=function(){return Fb(this.g)};f.M=function(){return this.b};f.addEventListener=function(a,b){var c=b;u(b)&&(c=function(){n(b).apply(window,arguments)},this.o[b]=c);this.app.D(a,c)};f.bu=function(a,b){var c=u(b)?a+b:a+ja(b);if(!this.k[c]){u(b)&&(b=function(){n(b).apply(window,arguments)});var d=v(function(a){b({target:this.i,data:a})},this);this.k[c]=d;this.addEventListener(a,d)}};
-f.removeEventListener=function(a,b){var c=b;if(u(b)&&b in this.o){var c=this.o[b],d=this.o;b in d&&delete d[b]}this.app.W(a,c)};f.cu=function(a,b){var c=u(b)?a+b:a+ja(b);this.k[c]&&this.removeEventListener(a,this.k[c])};f.gs=function(){return this.app.ea};f.Th=function(a,b){Qf(this.app,!0,this.a);Rf(this.app,a,b,void 0,this.a)};f.getCurrentTime=function(){var a=this.app.Wd;return a&&O(this.app).b!=a?a.getCurrentTime():this.app.getCurrentTime(this.a)};
-f.Ph=function(){var a=this.app.Wd;return a?a.Qd:0};f.Um=function(){return this.app.xa.volume};f.Wm=function(a){var b=this.app;b.xa.volume=a;b.u("internalvolumechange",b.xa)};f.us=function(){return this.app.xa.muted};f.Vm=function(){Sf(this.app)};f.Xm=function(){Tf(this.app)};f.qg=function(){Qf(this.app,!0,this.a);Uf(this.app,this.a)};f.mn=function(){Vf(this.app,this.a)};f.Jj=function(){var a=this.app;Wf(a,"play_pause")||Xf(a,this.a)};f.Vr=function(){};f.es=function(){return this.app.Dg};
-f.Fs=function(a){Yf(this.app,a)};f.$r=function(){return this.app.a.jg?Zf:[1]};f.ds=function(){return $f(this.app,this.a)};f.Es=function(a){var b=O(this.app,this.a);b&&ag(b,"m",a)};f.as=function(){return bg(this.app,this.a)};f.js=function(){var a=cg(this.app.Wd);return Math.floor(1E3*a)};f.ks=function(){return 1E3};f.ms=function(){return cg(this.app.Wd)};f.os=function(){return 0};f.Hs=function(){this.app.P.Gi()};f.ws=function(a){(a=dg(this.app.k,a))&&a.load()};
-f.ln=function(a){(a=dg(this.app.k,a))&&a.unload()};f.Uj=function(a,b,c){var d=this.app,e=this.a;a=eg(d,fg(a,d.list,b,c),e);Qf(d,a,e)};f.Xr=function(a,b,c){var d=this.app,e=this.a;gg(d,new hg(fg(a,d.list,b,c)),e)};f.ys=function(a,b,c){var d=this.app,e=this.a;a=ig(a,d.list,b,c);b=eg(d,a,e);Qf(d,b,e);jg(d,a.mediaContentUrl)};f.Yr=function(a,b,c){var d=this.app,e=this.a;a=ig(a,d.list,b,c);gg(d,new hg(a),e);jg(d,a.mediaContentUrl)};f.rs=function(){return kg(this.app)};f.bs=function(){return lg(this.app)};
-f.ls=function(){return""};f.Ur=function(){return!1};f.Cs=function(){};f.xs=function(a,b,c,d){var e=this.app;e.Xe=!1;mg(e,a,b,c,d)};f.Wr=function(a,b,c,d){var e=this.app;e.Xe=!0;mg(e,a,b,c,d)};f.As=function(){ng(this.app)};f.Bs=function(){og(this.app)};f.sj=function(a){var b=this.app;b.g&&(b.g.be?pg(b,qg(b.g,a)):b.Xe=!1,rg(b.g,a))};f.Gs=function(a){var b=this.app;b.g&&sg(b.g,a)};f.Ds=function(a){var b=this.app;b.g&&(b.g.loop=a)};
-f.ub=function(){var a=this.app.g;if(!a)return null;for(var b=[],c=0;c<a.Pa;c++)b[c]=qg(a,c).L;return b};f.Wj=function(){var a=this.app.g?this.app.g.pa:null;return null==a?-1:a};f.hs=function(){return this.app.g&&this.app.g.g?this.app.g.g.toString():null};f.jn=function(a,b,c){return tg(this.app.k,a,b,c)};f.Ij=function(a,b,c){return tg(this.app.k,a,b,c)};f.cs=function(a){return ug(this.app.k,a)};f.getVideoData=function(){var a=this.app.getVideoData(this.a)||{};return{video_id:a.L,author:a.author,title:a.title}};
-f.Is=function(){vg(this.app.P)};f.ts=function(){this.app.P.mk()};f.zs=function(){wg(this.app.b,204)};f.vs=function(){var a=xg(this.app);return!(!a||!P(a,128)||5!=a.a.errorCode)};f.is=function(){var a=this.app,b=a.K.clone();if(a=a.b.getVideoData()){var c=b.args,d=Jb(a.b);d.start=a.ya;pa(c,d)}return b};f.destroy=function(){this.app.dispose()};f.F=function(){if(this.b){for(var a in this.g)this.b[a]=null;for(a in this.j)this.b[a]=null}this.o=this.k=this.b=null;Pf.C.F.call(this)};function yg(a,b){Pf.call(this,a,b);N(this,"cueVideoByPlayerVars",this.Ex);N(this,"loadVideoByPlayerVars",this.No);N(this,"preloadVideoByPlayerVars",this.Hx);N(this,"seekBy",this.Up);N(this,"enableLicenseIntercept",this.Fx);N(this,"updatePlaylist",this.Kx);N(this,"resumeLicenseSession",this.Ix);N(this,"updateLastActiveTime",this.Jx);N(this,"updateRemoteReceivers",this.Lx);N(this,"updateVideoData",this.Mx);N(this,"getStoryboardFormat",this.Gx)}y(yg,Pf);f=yg.prototype;
-f.Ex=function(a){var b=this.a;gg(this.app,new hg(a),b)};f.No=function(a){eg(this.app,a,this.a)};f.Hx=function(){};f.Up=function(a,b,c){Qf(this.app,!0,this.a);var d=this.app,e=this.a;Rf(d,d.getCurrentTime()+a,b,c,e)};f.Fx=function(){var a=this.app;a.Uk||(a.Uk=!0,a.Bi={})};f.Kx=function(){var a=this.app;zg(a);a.cb("onPlaylistUpdate")};f.Ix=function(a,b){var c=this.app,d=c.Bi[a];d&&(Ag(d,b),d.start(),delete c.Bi[a])};f.Jx=function(){this.app.a.gb=w()};
-f.Lx=function(a){var b=this.app;Bg(b.a)&&6!=b.o&&(b.a.Ig=!Ra(a),b.a.Ig?1!=b.o&&3!=b.o&&Cg(b):Dg(b.H))};f.Mx=function(a){var b=O(this.app,this.a||1);b&&(b=b.a,Eg(b,a),b.u("dataupdated"))};f.Gx=function(){return this.app.getVideoData().b.storyboard_spec};f.getVideoData=function(){var a=yg.C.getVideoData.call(this),b=this.app.getVideoData(this.a)||{};a.cpn=b.Ca;return a};f.getCurrentTime=function(a){return a?this.app.getCurrentTime(a):yg.C.getCurrentTime.call(this)};
-f.Ph=function(a){return a?Fg(this.app,a):yg.C.Ph.call(this)};function Gg(a,b){yg.call(this,a,b)}y(Gg,yg);f=Gg.prototype;f.Uj=function(a,b,c){eg(this.app,fg(a,this.app.list,b,c),this.a)};f.qg=function(){Uf(this.app,this.a)};f.Th=function(a,b){Rf(this.app,a,b,void 0,this.a)};function Q(a){return a.app.P.a}f.J=function(){return this.app.J()};f.ub=function(){return this.app.g};f.getVideoData=function(){return this.app.getVideoData(this.a)};function Hg(a){this.j=Math.exp(Math.log(0.5)/a);this.a=this.i=0}Hg.prototype.g=function(a,b){var c=Math.pow(this.j,a);this.a=b*(1-c)+c*this.a;this.i+=a};Hg.prototype.b=function(){return this.a/(1-Math.pow(this.j,this.i))};function Ig(a,b){this.o=0;this.j=a;this.G=b||0.5;this.k="index";this.a=0;this.i=[]}Ig.prototype.g=function(a,b){Jg(this,"index");this.i.push({index:this.o++,ih:a,value:b});this.a+=a;for(Jg(this,"index");this.a>this.j;){var c=this.a-this.j,d=this.i[0];d.ih<=c?(this.a-=d.ih,this.i.shift()):(this.a-=c,d.ih-=c)}};function Kg(a,b){Jg(a,"value");var c=b*a.a,d=0,e=NaN;a.i.some(function(a){d+=a.ih;e=a.value;if(d>=c)return!0});return e}Ig.prototype.b=function(){return Kg(this,this.G)};
-function Jg(a,b){a.k!=b&&(a.k=b,fb(a.i,b))};function Lg(){};function Mg(){}y(Mg,Lg);Mg.prototype.fb=function(){var a=0;Sd(this.Kd(!0),function(){a++});return a};Mg.prototype.clear=function(){var a=Td(this.Kd(!0)),b=this;z(a,function(a){b.remove(a)})};function Ng(a){this.a=a}y(Ng,Mg);f=Ng.prototype;f.isAvailable=function(){if(!this.a)return!1;try{return this.a.setItem("__sak","1"),this.a.removeItem("__sak"),!0}catch(a){return!1}};f.set=function(a,b){try{this.a.setItem(a,b)}catch(c){if(0==this.a.length)throw"Storage mechanism: Storage disabled";throw"Storage mechanism: Quota exceeded";}};f.get=function(a){a=this.a.getItem(a);if(!u(a)&&null!==a)throw"Storage mechanism: Invalid value was encountered";return a};f.remove=function(a){this.a.removeItem(a)};
-f.fb=function(){return this.a.length};f.Kd=function(a){var b=0,c=this.a,d=new Qd;d.next=function(){if(b>=c.length)throw Pd;var d;d=c.key(b++);if(a)return d;d=c.getItem(d);if(!u(d))throw"Storage mechanism: Invalid value was encountered";return d};return d};f.clear=function(){this.a.clear()};f.key=function(a){return this.a.key(a)};function Og(){var a=null;try{a=window.localStorage||null}catch(b){}this.a=a}y(Og,Ng);function Pg(a){this.Pf=a;this.jq=new ob}f=Pg.prototype;f.Pf=null;f.jq=null;f.set=function(a,b){q(b)?this.Pf.set(a,nb(this.jq,b)):this.Pf.remove(a)};f.get=function(a){var b;try{b=this.Pf.get(a)}catch(c){return}if(null!==b)try{return kb(b)}catch(d){throw"Storage: Invalid value was encountered";}};f.remove=function(a){this.Pf.remove(a)};function Qg(){var a=null;try{a=window.sessionStorage||null}catch(b){}this.a=a}y(Qg,Ng);function Rg(a){Pg.call(this,a)}y(Rg,Pg);function Sg(a){this.data=a}function Tg(a){return!q(a)||a instanceof Sg?a:new Sg(a)}Rg.prototype.set=function(a,b){Rg.C.set.call(this,a,Tg(b))};Rg.prototype.a=function(a){a=Rg.C.get.call(this,a);if(!q(a)||a instanceof Object)return a;throw"Storage: Invalid value was encountered";};Rg.prototype.get=function(a){if(a=this.a(a)){if(a=a.data,!q(a))throw"Storage: Invalid value was encountered";}else a=void 0;return a};function Ug(a){Pg.call(this,a)}y(Ug,Rg);function Vg(a){var b=a.creation;a=a.expiration;return!!a&&a<w()||!!b&&b>w()}Ug.prototype.set=function(a,b,c){if(b=Tg(b)){if(c){if(c<w()){Ug.prototype.remove.call(this,a);return}b.expiration=c}b.creation=w()}Ug.C.set.call(this,a,b)};Ug.prototype.a=function(a,b){var c=Ug.C.a.call(this,a);if(c)if(!b&&Vg(c))Ug.prototype.remove.call(this,a);else return c};function Wg(a){Pg.call(this,a)}y(Wg,Ug);function Xg(a,b){var c=[];Sd(b,function(a){var b;try{b=Wg.prototype.a.call(this,a,!0)}catch(g){if("Storage: Invalid value was encountered"==g)return;throw g;}q(b)?Vg(b)&&c.push(a):c.push(a)},a);return c}function Yg(a,b){var c=Xg(a,b);z(c,function(a){Wg.prototype.remove.call(this,a)},a)};function Zg(a,b,c){var d=c&&0<c?c:0;c=d?w()+1E3*d:0;if((d=d?$g:ah)&&window.JSON){u(b)||(b=JSON.stringify(b,void 0));try{d.set(a,b,c)}catch(e){d.remove(a)}}}function bh(a){if(!ah&&!$g||!window.JSON)return null;var b;try{b=ah.get(a),b=u(b)?b:$g.get(a)}catch(c){return null}if(!u(b))return null;try{b=JSON.parse(b,void 0)}catch(d){}return b}function ch(a){ah&&ah.remove(a);$g&&$g.remove(a)}var $g,dh=new Og;$g=dh.isAvailable()?new Wg(dh):null;var ah,eh=new Qg;ah=eh.isAvailable()?new Wg(eh):null;function fh(a){var b=bh(a);if(!b){var c=new Og;c.isAvailable()&&(b=(new Pg(c)).get(a))}return b}function gh(){var a={volume:100,muted:!1,nonNormalized:100},b=fh("yt-player-volume")||{};a.volume=isNaN(b.volume)?100:tb(b.volume,0,100);a.nonNormalized=isNaN(b.nonNormalized)?a.volume:b.nonNormalized;a.muted=void 0==b.muted?!1:b.muted;return a};function hh(a){this.g=this.i=0;a.Oc?this.j=new Hg(16):this.j=new Ig(16,0.6);a.od||"play"==a.Ja?this.b=new Hg(4):this.b=new Ig(16,0.6);a.Yl?this.a=new Ig(8,0.6):a.Zl?this.a=new Ig(16,0.6):a.jm?this.a=new Ig(24,0.6):"play"==a.Ja?this.a=new Hg(15):this.a=new Ig(15,0.6);var b=fh("yt-player-bandwidth");a=a.Nc?0.1:0.5;b&&!isNaN(b.byterate)?this.a.g(a,b.byterate):this.a.g(a,75E3)}function ih(a){a=a.j.b();return a=isNaN(a)?0.5:a}function jh(a){a=a.a.b();return 0<a?a:1};function kh(){this.a=[];this.Qb={}}y(kh,Lf);f=kh.prototype;f.mp=1;f.Mi=0;f.D=function(a,b,c){var d=this.Qb[a];d||(d=this.Qb[a]=[]);var e=this.mp;this.a[e]=a;this.a[e+1]=b;this.a[e+2]=c;this.mp=e+3;d.push(e);return e};f.W=function(a,b,c){if(a=this.Qb[a]){var d=this.a;if(a=Na(a,function(a){return d[a+1]==b&&d[a+2]==c}))return this.Wc(a)}return!1};
-f.Wc=function(a){if(0!=this.Mi)return this.b||(this.b=[]),this.b.push(a),!1;var b=this.a[a];if(b){var c=this.Qb[b];c&&Ua(c,a);delete this.a[a];delete this.a[a+1];delete this.a[a+2]}return!!b};f.u=function(a,b){var c=this.Qb[a];if(c){this.Mi++;for(var d=ab(arguments,1),e=0,g=c.length;e<g;e++){var h=c[e];this.a[h+1].apply(this.a[h+2],d)}this.Mi--;if(this.b&&0==this.Mi)for(;c=this.b.pop();)this.Wc(c);return 0!=e}return!1};
-f.clear=function(a){if(a){var b=this.Qb[a];b&&(z(b,this.Wc,this),delete this.Qb[a])}else this.a.length=0,this.Qb={}};f.fb=function(a){if(a){var b=this.Qb[a];return b?b.length:0}a=0;for(b in this.Qb)a+=this.fb(b);return a};f.F=function(){kh.C.F.call(this);delete this.a;delete this.Qb;delete this.b};function lh(a,b){this.start=a;this.end=b;this.a=ja(this)}function mh(a,b){return a.start!=b.start?a.start-b.start:a.end!=b.end?a.end-b.end:a.a!=b.a?a.a-b.a:0}lh.prototype.contains=function(a,b){return a>=this.start&&(a<this.end||a==this.end&&this.start==this.end)&&(null==b||a<b&&b<=this.end)};lh.prototype.toString=function(){return"Interval["+this.start+", "+this.end+"]"};function nh(a,b,c){lh.call(this,a,b);a=c||{};this.Ba=a.id||"";void 0!=a.priority&&(this.sh=a.priority);this.namespace=a.namespace||"";this.jl=a.visible||!1;this.yb=new kh}y(nh,lh);f=nh.prototype;f.Ba="";f.sh=7;f.active=!0;f.jl=!1;f.yb=null;f.namespace="";f.getId=function(){return this.Ba};function oh(a,b){return a.start==b.start?a.sh==b.sh?0:a.sh<b.sh?-1:1:a.start<b.start?-1:1};function ph(a,b){this.type=a;this.currentTarget=this.target=b}f=ph.prototype;f.dispose=function(){};f.se=!1;f.defaultPrevented=!1;f.Qp=!0;f.stopPropagation=function(){this.se=!0};f.preventDefault=function(){this.defaultPrevented=!0;this.Qp=!1};function qh(a){qh[" "](a);return a}qh[" "]=ba;var rh=!D||qc(9),sh=D&&!pc("9");!bc||pc("528");ac&&pc("1.9b")||D&&pc("8")||$b&&pc("9.5")||bc&&pc("528");ac&&!pc("8")||D&&pc("9");function th(a,b){a&&this.init(a,b)}y(th,ph);f=th.prototype;f.target=null;f.relatedTarget=null;f.clientX=0;f.clientY=0;f.keyCode=0;f.charCode=0;f.ctrlKey=!1;f.altKey=!1;f.shiftKey=!1;f.re=null;
-f.init=function(a,b){var c=this.type=a.type;ph.call(this,c);this.target=a.target||a.srcElement;this.currentTarget=b;var d=a.relatedTarget;if(d){if(ac){var e;t:{try{qh(d.nodeName);e=!0;break t}catch(g){}e=!1}e||(d=null)}}else"mouseover"==c?d=a.fromElement:"mouseout"==c&&(d=a.toElement);this.relatedTarget=d;this.clientX=void 0!==a.clientX?a.clientX:a.pageX;this.clientY=void 0!==a.clientY?a.clientY:a.pageY;this.keyCode=a.keyCode||0;this.charCode=a.charCode||("keypress"==c?a.keyCode:0);this.ctrlKey=a.ctrlKey;
-this.altKey=a.altKey;this.shiftKey=a.shiftKey;this.state=a.state;this.re=a;a.defaultPrevented&&this.preventDefault();delete this.se};f.stopPropagation=function(){th.C.stopPropagation.call(this);this.re.stopPropagation?this.re.stopPropagation():this.re.cancelBubble=!0};f.preventDefault=function(){th.C.preventDefault.call(this);var a=this.re;if(a.preventDefault)a.preventDefault();else if(a.returnValue=!1,sh)try{if(a.ctrlKey||112<=a.keyCode&&123>=a.keyCode)a.keyCode=-1}catch(b){}};f.$x=function(){return this.re};var uh="closure_listenable_"+(1E6*Math.random()|0);function vh(a){try{return!(!a||!a[uh])}catch(b){return!1}}var wh=0;function xh(a,b,c,d,e){this.cf=a;this.proxy=null;this.src=b;this.type=c;this.capture=!!d;this.eb=e;this.key=++wh;this.removed=this.Pi=!1}function yh(a){a.removed=!0;a.cf=null;a.proxy=null;a.src=null;a.eb=null};function zh(a){this.src=a;this.$a={};this.a=0}zh.prototype.add=function(a,b,c,d,e){var g=this.$a[a];g||(g=this.$a[a]=[],this.a++);var h=Ah(g,b,d,e);-1<h?(a=g[h],c||(a.Pi=!1)):(a=new xh(b,this.src,a,!!d,e),a.Pi=c,g.push(a));return a};zh.prototype.remove=function(a,b,c,d){if(!(a in this.$a))return!1;var e=this.$a[a];b=Ah(e,b,c,d);return-1<b?(yh(e[b]),Va(e,b),0==e.length&&(delete this.$a[a],this.a--),!0):!1};
-function Bh(a,b){var c=b.type;if(!(c in a.$a))return!1;var d=Ua(a.$a[c],b);d&&(yh(b),0==a.$a[c].length&&(delete a.$a[c],a.a--));return d}zh.prototype.removeAll=function(a){var b=0,c;for(c in this.$a)if(!a||c==a){for(var d=this.$a[c],e=0;e<d.length;e++)++b,yh(d[e]);delete this.$a[c];this.a--}return b};function Ch(a,b,c,d,e){a=a.$a[b];b=-1;a&&(b=Ah(a,c,d,e));return-1<b?a[b]:null}
-function Ah(a,b,c,d){for(var e=0;e<a.length;++e){var g=a[e];if(!g.removed&&g.cf==b&&g.capture==!!c&&g.eb==d)return e}return-1};var Dh={},Eh={},Fh={};function Gh(a,b,c,d,e){if(t(b)){for(var g=0;g<b.length;g++)Gh(a,b[g],c,d,e);return null}c=Hh(c);if(vh(a))a=a.listen(b,c,d,e);else{g=c;if(!b)throw Error("Invalid event type");c=!!d;var h=ja(a),k=Eh[h];k||(Eh[h]=k=new zh(a));d=k.add(b,g,!1,d,e);d.proxy||(e=Ih(),d.proxy=e,e.src=a,e.cf=d,a.addEventListener?a.addEventListener(b,e,c):a.attachEvent(b in Fh?Fh[b]:Fh[b]="on"+b,e),Dh[d.key]=d);a=d}return a}
-function Ih(){var a=Jh,b=rh?function(c){return a.call(b.src,b.cf,c)}:function(c){c=a.call(b.src,b.cf,c);if(!c)return c};return b}function Kh(a,b,c,d,e){if(t(b))for(var g=0;g<b.length;g++)Kh(a,b[g],c,d,e);else c=Hh(c),vh(a)?a.Vc(b,c,d,e):a&&(d=!!d,(a=Lh(a))&&(b=Ch(a,b,c,d,e))&&Mh(b))}
-function Mh(a){if(ga(a)||!a||a.removed)return!1;var b=a.src;if(vh(b))return Bh(b.jd,a);var c=a.type,d=a.proxy;b.removeEventListener?b.removeEventListener(c,d,a.capture):b.detachEvent&&b.detachEvent(c in Fh?Fh[c]:Fh[c]="on"+c,d);(c=Lh(b))?(Bh(c,a),0==c.a&&(c.src=null,delete Eh[ja(b)])):yh(a);delete Dh[a.key];return!0}function Nh(a,b){var c=Eh[a];if(!c)return 0;var d=0,e;for(e in c.$a)if(!b||e==b)for(var g=Ya(c.$a[e]),h=0;h<g.length;++h)Mh(g[h])&&++d;return d}
-function Oh(a,b,c,d){var e=1;if(a=Lh(a))if(b=a.$a[b])for(b=Ya(b),a=0;a<b.length;a++){var g=b[a];g&&g.capture==c&&!g.removed&&(e&=!1!==Ph(g,d))}return Boolean(e)}function Ph(a,b){var c=a.cf,d=a.eb||a.src;a.Pi&&Mh(a);return c.call(d,b)}
-function Jh(a,b){if(a.removed)return!0;if(!rh){var c=b||n("window.event"),d=new th(c,this),e=!0;if(!(0>c.keyCode||void 0!=c.returnValue)){t:{var g=!1;if(0==c.keyCode)try{c.keyCode=-1;break t}catch(h){g=!0}if(g||void 0==c.returnValue)c.returnValue=!0}c=[];for(g=d.currentTarget;g;g=g.parentNode)c.push(g);for(var g=a.type,k=c.length-1;!d.se&&0<=k;k--)d.currentTarget=c[k],e&=Oh(c[k],g,!0,d);for(k=0;!d.se&&k<c.length;k++)d.currentTarget=c[k],e&=Oh(c[k],g,!1,d)}return e}return Ph(a,new th(b,this))}
-function Lh(a){return a[ka]?Eh[ja(a)]||null:null}var Qh="__closure_events_fn_"+(1E9*Math.random()>>>0);function Hh(a){return ha(a)?a:a[Qh]||(a[Qh]=function(b){return a.handleEvent(b)})};function Rh(){this.jd=new zh(this);this.U=this}y(Rh,Lf);Rh.prototype[uh]=!0;f=Rh.prototype;f.Ml=null;f.addEventListener=function(a,b,c,d){Gh(this,a,b,c,d)};f.removeEventListener=function(a,b,c,d){Kh(this,a,b,c,d)};
-function Sh(a,b){var c,d=a.Ml;if(d){c=[];for(var e=1;d;d=d.Ml)c.push(d),++e}var d=a.U,e=b,g=e.type||e;if(u(e))e=new ph(e,d);else if(e instanceof ph)e.target=e.target||d;else{var h=e,e=new ph(g,d);Mb(e,h)}var h=!0,k;if(c)for(var m=c.length-1;!e.se&&0<=m;m--)k=e.currentTarget=c[m],h=Th(k,g,!0,e)&&h;e.se||(k=e.currentTarget=d,h=Th(k,g,!0,e)&&h,e.se||(h=Th(k,g,!1,e)&&h));if(c)for(m=0;!e.se&&m<c.length;m++)k=e.currentTarget=c[m],h=Th(k,g,!1,e)&&h}
-f.F=function(){Rh.C.F.call(this);this.jd&&this.jd.removeAll(void 0);this.Ml=null};f.listen=function(a,b,c,d){return this.jd.add(a,b,!1,c,d)};f.Vc=function(a,b,c,d){return this.jd.remove(a,b,c,d)};function Th(a,b,c,d){b=a.jd.$a[b];if(!b)return!0;b=Ya(b);for(var e=!0,g=0;g<b.length;++g){var h=b[g];if(h&&!h.removed&&h.capture==c){var k=h.cf,m=h.eb||h.src;h.Pi&&Bh(a.jd,h);e=!1!==k.call(m,d)&&e}}return e&&!1!=d.Qp};function Uh(a,b){Rh.call(this);this.a=a||1;this.b=b||l;this.g=v(this.ku,this);this.i=w()}y(Uh,Rh);f=Uh.prototype;f.Xc=!1;f.gc=null;function Vh(a,b){a.a=b;a.gc&&a.Xc?(a.stop(),a.start()):a.gc&&a.stop()}f.ku=function(){if(this.Xc){var a=w()-this.i;0<a&&a<0.8*this.a?this.gc=this.b.setTimeout(this.g,this.a-a):(this.gc&&(this.b.clearTimeout(this.gc),this.gc=null),Sh(this,"tick"),this.Xc&&(this.gc=this.b.setTimeout(this.g,this.a),this.i=w()))}};
-f.start=function(){this.Xc=!0;this.gc||(this.gc=this.b.setTimeout(this.g,this.a),this.i=w())};f.stop=function(){this.Xc=!1;this.gc&&(this.b.clearTimeout(this.gc),this.gc=null)};f.F=function(){Uh.C.F.call(this);this.stop();delete this.b};function Wh(a,b,c){if(ha(a))c&&(a=v(a,c));else if(a&&"function"==typeof a.handleEvent)a=v(a.handleEvent,a);else throw Error("Invalid listener argument");return 2147483647<b?-1:l.setTimeout(a,b||0)};function Xh(){this.a=[]}function Yh(a,b){for(var c=[],d=0;d<a.a.length;++d){var e=a.a[d];e.contains(b)&&c.push(e);if(e.start>b)break}return c}function Zh(a,b,c){for(var d=[],e=0;e<a.a.length;++e){var g=a.a[e];if(null!=c&&g.start>c)break;g.start>b&&d.push(g)}return d}function $h(a,b){for(var c=[],d=0;d<a.a.length;++d){var e=a.a[d];e.contains(b)&&c.push(e.end);if(e.start>b){c.push(e.start);break}}c.sort(eb);return c[0]};var ai,bi,ci,di,ei;ei=di=ci=bi=ai=!1;var fi=Wb();fi&&(-1!=fi.indexOf("Firefox")||-1!=fi.indexOf("Camino")||(-1!=fi.indexOf("iPhone")||-1!=fi.indexOf("iPod")?ai=!0:-1!=fi.indexOf("iPad")?bi=!0:-1!=fi.indexOf("Chrome")?di=!0:-1!=fi.indexOf("Android")?ci=!0:-1!=fi.indexOf("Safari")&&(ei=!0)));var gi=ai,hi=bi,ii=ci,ji=di,ki=ei;var li,mi;var ni=Wb(),oi=ni.match(/\((iPad|iPhone|iPod)( Simulator)?;/);if(!oi||2>oi.length)li=void 0;else{var pi=ni.match(/\((iPad|iPhone|iPod)( Simulator)?; (U; )?CPU (iPhone )?OS (\d_\d)[_ ]/);li=pi&&6==pi.length?Number(pi[5].replace("_",".")):0}(mi=0<=li)&&0<=Wb().search("Safari")&&Wb().search("Version");var qi=gi||hi;function ri(){return si("(ps3; leanback shell)")}function si(a){var b=Wb();return b?0<=b.toLowerCase().indexOf(a.toLowerCase()):!1};function ti(){}var ui=mi&&4>li?0.1:0,vi=new ti;f=ti.prototype;f.yd=null;f.Jk=!1;f.Qd=0;f.Sl=0;function wi(a,b){var c="";b&&(a.yd=b,c=xi(b));a.src&&""==c||(c&&a.src!=c&&(a.src=c),b&&b.a||a.load())}function yi(a,b){0<a.readyState&&(a.currentTime=Math.max(ui,b))}f.getType=function(){return this.type};f.Va=function(a){this.Qd=a};f.getCurrentTime=function(){return this.Sl||this.currentTime};f.pp=function(){this.Sl=this.currentTime};
-function cg(a){var b=a.Qd;if(Infinity==b)return 1;if(b&&a.buffered&&0<a.buffered.length){var c=zi(a);return a.buffered.end(c)/b}return 0}function Ai(a){a.ended&&yi(a,0);!a.hasAttribute("src")&&a.yd&&(a.src=xi(a.yd),a.yd.a||a.load());a.play()}function Bi(a){a.currentSrc&&(qi&&yi(a,0),Vc(a),a.removeAttribute("src"),a.load(),a.yd&&a.yd.a&&(a.yd=null))}function Ci(a){Bi(a);a.Qd=0;a.Sl=0;a.yd=null}function Di(a,b){a.defaultPlaybackRate=b;a.playbackRate=b}
-function zi(a){var b=a.buffered;a=a.getCurrentTime();for(var c=0;c<b.length&&!(b.start(c)>a);c++)if(a<=b.end(c))return c;return 0}f.inUnbufferedArea=function(){var a=this.buffered;if(!a||!a.length)return!0;var b=zi(this);if(0<b)return!1;var c=this.getCurrentTime();return a.start(b)>c||a.end(b)<c};function Ei(a,b){b?a.setAttribute("crossorigin","true"):a.removeAttribute("crossorigin")}f.dw=function(){this.hasAttribute("controls")&&this.setAttribute("controls","true")};
-f.ew=function(){this.Jk&&!this.muted&&(this.muted=!0)};var Fi=[2,5,100,101,150],Gi=[202,203];function Hi(a,b){a=a||64;a&128&&!b||a&2&&a&16||(this.b=a,this.a=b||null)}Hi.prototype.b=64;Hi.prototype.a=null;function Ii(a,b,c){return b==a.b&&c==a.a||b&128&&!c||b&2&&b&16?a:new Hi(b,c)}function Ji(a,b){return Ii(a,a.b|b)}function P(a,b){return!!(a.b&b)}function Ki(a){return P(a,128)?-1:P(a,2)?0:P(a,1)&&!P(a,32)?3:P(a,64)?-1:P(a,8)?1:P(a,4)?2:-1}function Li(){var a;return a=14};function R(){this.G=new kh;L(this,this.G)}y(R,Lf);R.prototype.D=function(a,b,c){return this.ha()?0:this.G.D(a,b,c)};R.prototype.W=function(a,b,c){return this.ha()?!1:this.G.W(a,b,c)};R.prototype.Wc=function(a){return this.ha()?!1:this.G.Wc(a)};R.prototype.u=function(a,b){return this.ha()?!1:this.G.u.apply(this.G,arguments)};function Mi(a,b,c){R.call(this);this.A=a;this.o=b;this.B=c;this.j=new Uh(250);this.j.addEventListener("tick",this.Xb,!1,this);L(this,this.j);this.i=[];this.a=[];this.b=new Xh}y(Mi,R);f=Mi.prototype;f.Qh=!1;f.sg=!1;f.Bk=!1;f.Ak=!1;f.Jg=null;f.ux=function(a){this.Xb();z(arguments,function(a){this.i.push(a);var c=this.b.a;!c.length||0<mh(a,c[c.length-1])?c.push(a):ib(c,a,mh);this.u("onAdd",a)},this);this.Xb()};f.vx=function(a){z(arguments,function(a){a=this.i.indexOf(a);0<=a&&Ni(this,a)},this);this.Xb()};
-function Ni(a,b){var c=a.i.splice(b,1)[0],d=a.b.a,e=cb(d,mh||eb,c);0<=e&&Va(d,e);b=a.a.indexOf(c);0<=b&&a.a.splice(b,1);a.u("onRemove",c)}f.reset=function(){this.sg=this.Qh=!1;Oi(this);for(var a=this.i.length-1;0<=a;a--)Ni(this,a);this.Xb();this.k=null};
-function Pi(a,b){if(a.sg&&!a.Qh)if(Oi(a),P(b.state,2)){a.k=null;for(var c=[],d=0;d<a.a.length;d++){var e=a.a[d];e.active&&2147483647>e.end&&(c.push(e),a.a.splice(d--,1))}d=Yh(a.b,2147483646);d=d.concat(Zh(a.b,2147483646));e=[];if(c.length)for(var g=0;g<c.length;g++)e.push(["onExit",c[g]]);c=e.concat(Qi(a,d));for(d=0;d<c.length;d++)g=c[d],e=g[1],e.yb.u.apply(e.yb,g)}else P(b.state,16)?(a.g=Ri(a),a.j.stop(),a.j.start(),a.Xb()):(a.j.stop(),P(b.a,16)?(a.g=Ri(a),null!=$h(a.b,Math.max(a.g-2E3,0))&&(a.Jg=
-Wh(v(a.Xb,a)))):a.Xb())}function Qi(a,b){var c=[];if(!b.length)return c;b.sort(oh);for(var d=0;d<b.length;d++){var e=b[d];e.active&&-1==a.a.indexOf(e)&&(a.a.push(e),c.push(["onEnter",e]))}return c}
-f.Xb=function(){this.Ak=!0;if(!this.Bk)for(var a=3;this.Ak&&a;){this.Ak=!1;this.Bk=!0;if(this.sg&&!this.Qh){Oi(this);for(var b=Ri(this),c=[],d=0;d<this.a.length;d++){var e=this.a[d];e.active&&!e.contains(b)&&(c.push(["onExit",e]),this.a.splice(d--,1))}d=Yh(this.b,b);e=this.o();!P(e,48)&&b>this.g&&(d=d.concat(Zh(this.b,this.g,b)));c=c.concat(Qi(this,d));this.g=b;!this.Qh&&this.k&&(c.unshift(["onLockBlockExit",this.k]),this.k=null,P(e,2)&&(this.g=2147483647));this.B()&&(b=$h(this.b,this.g),null!=b&&
-(this.Jg=Wh(v(this.Xb,this),b-this.g)));for(d=0;d<c.length;d++)b=c[d],e=b[1],"onLockBlockExit"==b[0]||"onLockBlockEnter"==b[0]?this.u.apply(this,b):e.yb.u.apply(e.yb,b)}this.Bk=!1;a--}};function Oi(a){null!=a.Jg&&(l.clearTimeout(a.Jg),a.Jg=null)}function Ri(a){return P(a.o(),2)?2147483647:1E3*a.A()}f.F=function(){this.j.removeEventListener("tick",this.Xb,!1,this);Oi(this);this.k=this.b=this.a=this.i=null;Mi.C.F.call(this)};function Si(a,b){for(var c=a.split(b),d={},e=0,g=c.length;e<g;e++){var h=c[e].split("=");if(1==h.length&&h[0]||2==h.length){var k=ua(h[0]||""),h=ua(h[1]||"");k in d?t(d[k])?Za(d[k],h):d[k]=[d[k],h]:d[k]=h}}return d}function Ti(a,b){var c=[];Cb(a,function(a,b){var g=encodeURIComponent(String(b)),h;h=t(a)?a:[a];z(h,function(a){""==a?c.push(g):c.push(g+"="+encodeURIComponent(String(a)))})});return c.join(b)}function Ui(a){"?"==a.charAt(0)&&(a=a.substr(1));return Si(a,"&")}
-function Vi(a){return-1!=a.indexOf("?")?(a=(a||"").split("#")[0],a=a.split("?",2),Ui(1<a.length?a[1]:a[0])):{}}function Wi(a){a=ie([],a);a[0]="";return a.join("")}function S(a,b){return fe(ie([a],b))}var Xi=de;function Yi(){var a=be(document.location.href);return $d(a[1],a[2],a[3],a[4])}function Zi(a,b){var c=a.split("#",2);a=c[0];var c=1<c.length?"#"+c[1]:"",d=a.split("?",2);a=d[0];var d=Ui(d[1]||""),e;for(e in b)d[e]=b[e];return S(a,d)+c};var $i=null;"undefined"!=typeof XMLHttpRequest?$i=function(){return new XMLHttpRequest}:"undefined"!=typeof ActiveXObject&&($i=function(){return new ActiveXObject("Microsoft.XMLHTTP")});function aj(a){switch(a&&"status"in a?a.status:-1){case 0:case 200:case 201:case 202:case 203:case 204:case 205:case 206:case 304:return!0;default:return!1}};function bj(a,b,c,d,e,g,h){var k=$i&&$i();if("open"in k){k.onreadystatechange=function(){4==(k&&"readyState"in k?k.readyState:0)&&b&&hf(b)(k)};c=(c||"GET").toUpperCase();d=d||"";k.open(c,a,!0);g&&(k.responseType=g);h&&(k.withCredentials=!0);g="POST"==c;if(e=cj(a,e))for(var m in e)k.setRequestHeader(m,e[m]),"content-type"==m.toLowerCase()&&(g=!1);g&&k.setRequestHeader("Content-Type","application/x-www-form-urlencoded");k.send(d);return k}}
-function cj(a,b){b=b||{};var c;if(c=ef("PAGE_CL"))if(c=ef("PAGE_BUILD_TIMESTAMP")){var d;d||(d=window.location.href);c=be(a)[1]||null;var e=Xi(a);c&&e?(c=d,d=be(a),c=be(c),d=d[3]==c[3]&&d[1]==c[1]&&d[4]==c[4]):d=e?Xi(d)==e&&(Number(be(d)[4]||null)||null)==(Number(be(a)[4]||null)||null):!0;c=d||dj(a)}c&&(b["X-YouTube-Page-CL"]=ef("PAGE_CL"),b["X-YouTube-Page-Timestamp"]=ef("PAGE_BUILD_TIMESTAMP"));return b}
-function dj(a){var b=["X-YouTube-Page-CL","X-YouTube-Page-Timestamp"],c=ef("CORS_HEADER_WHITELIST")||{};a=Xi(a);if(!a)return!0;var d=c[a];return d?La(b,function(a){return A(d,a)}):!1}
-function ej(a,b){var c=b.format||"JSON";b.Bv&&(a=document.location.protocol+"//"+document.location.hostname+(document.location.port?":"+document.location.port:"")+a);var d=b.zf;d&&(a=Zi(a,d));var e=b.Sw||"";(d=b.Nf)&&u(e)&&(e=Ui(e),Mb(e,d),e=Wi(e));var g=!1,h,k=bj(a,function(a){if(!g){g=!0;h&&I(h);var d=aj(a),e=null;if(d||400<=a.status&&500>a.status)e=fj(c,a);if(d)t:{switch(c){case "XML":d=0==parseInt(e&&e.return_code,10);break t;case "RAW":d=!0;break t}d=!!e}var e=e||{},k=b.X||l;d?b.Oa&&b.Oa.call(k,
-a,e):b.onError&&b.onError.call(k,a,e);b.td&&b.td.call(k,a,e)}},b.method,e,b.headers,b.responseType,b.withCredentials);b.al&&0<b.timeout&&(h=H(function(){g||(g=!0,k.abort(),I(h),b.al.call(b.X||l,k))},b.timeout));return k}function fj(a,b){var c=null;switch(a){case "JSON":var d=b.responseText,e=b.getResponseHeader("Content-Type")||"";d&&0<=e.indexOf("json")&&(c=lb(d));break;case "XML":if(d=(d=b.responseXML)?gj(d):null)c={},z(d.getElementsByTagName("*"),function(a){c[a.tagName]=hj(a)})}return c}
-function gj(a){return a?(a=("responseXML"in a?a.responseXML:a).getElementsByTagName("root"))&&0<a.length?a[0]:null:null}function hj(a){var b="";z(a.childNodes,function(a){b+=a.nodeValue});return b}var ij={html5_ajax:"action_get_html5_token",watch_actions_ajax:"action_get_watch_actions_token",addto_ajax:"action_get_wl_token"},jj={html5_ajax:"html5_ajax_token",watch_actions_ajax:"watch_actions_ajax_token",addto_ajax:"addto_ajax_token"};
-function kj(a,b,c,d,e){if(gf(a))d&&window.setTimeout(d,0);else{var g=Yi()+"/token_ajax",h={};b&&(h.Hy=b);c&&(h.Iy=c);h[ij[a]]=1;ej(g,{format:"RAW",method:"GET",zf:h,td:function(b){var c=Ui(b.responseText),g=c[jj[a]];g?(ff(a,g),d&&d()):e&&e(b,c)}})}};function lj(a){a=a.split("");a=mj(a,58);a=a.reverse();a=mj(a,50);a=a.slice(1);a=a.reverse();a=a.slice(1);a=a.reverse();a=mj(a,11);a=a.slice(3);return a.join("")}function mj(a,b){var c=a[0];a[0]=a[b%a.length];a[b]=c;return a};function nj(){this.lang=""};function oj(a,b,c,d,e,g){this.Sa=a;this.i=0<=b.indexOf("/mp4")?1:0<=b.indexOf("/webm")?2:0<=b.indexOf("/x-flv")?3:0;this.mb=b;this.b=g||0;this.j=c||null;this.a=d||null;this.g=e||null}function pj(a){return 2==a.i}function qj(a){return 0<=a.indexOf("opus")||0<=a.indexOf("vorbis")||0<=a.indexOf("mp4a")}function rj(a){return 0<=a.indexOf("vp9")||0<=a.indexOf("vp8")||0<=a.indexOf("avc1")};var sj={my:"auto",aD:"tiny",dC:"light",SMALL:"small",nC:"medium",LARGE:"large",JB:"hd720",IB:"hd1080",QB:"highres",fD:"unknown"};function tj(a,b,c){this.width=a;this.height=b;t:if(a||b){for(var d=1;d<uj.length;d++){var e=uj[d],g=vj[e];if(a>=g[0]||b>=g[1]){a=e;break t}}a="tiny"}else a="auto";this.i=a;this.a=c||0}var uj="auto highres hd1080 hd720 large medium small tiny".split(" "),vj={auto:[0,0],tiny:[256,144],light:[320,240],small:[320,240],medium:[640,360],large:[854,480],hd720:[1280,720],hd1080:[1920,1080],highres:[2048,1536]};function wj(a,b){this.start=a;this.end=b;this.length=b-a+1}function xj(a){a=a.split("-");return 2==a.length&&(a=new wj(parseInt(a[0],10),parseInt(a[1],10)),!isNaN(a.start)&&!isNaN(a.end)&&!isNaN(a.length)&&0<a.length)?a:null}wj.prototype.toString=function(){return this.start+"-"+(null==this.end?"":this.end)};var yj="corp.google.com youtube.com youtube-nocookie.com prod.google.com sandbox.google.com docs.google.com drive.google.com mail.google.com play.google.com".split(" "),zj=["2mdn.net"],Aj="www.google.com/aclk www.google.com/pagead/conversion googleadservices.com/aclk googleadservices.com/pagead/conversion googleads.g.doubleclick.net/aclk googleads.g.doubleclick.net/pagead/conversion".split(" ");function Bj(){return-1!=document.location.toString().indexOf("/embed/")}
-function Cj(a,b){return RegExp("^https?://([a-z0-9-]{1,63}\\.)*("+b.join("|").replace(/\./g,".")+")(:[0-9]+)?([/?#]|$)","i").test(a)}function Dj(a){a=new pe(a);qe(a,document.location.protocol);re(a,document.location.hostname);document.location.port&&se(a,document.location.port);return a.toString()};function Ej(a,b,c,d,e,g,h,k,m){this.a=a;this.ka=b;this.type=c;this.i=0<=d?d:-1;this.startTime=e||0;this.duration=g||0;this.Yb=h||0;this.kb=0<=k?k:this.ka.length;this.g=!!m;this.b=this.Yb+this.kb==this.ka.length;this.o=this.startTime+this.duration*this.Yb/this.ka.length;this.j=this.duration*this.kb/this.ka.length;this.k=this.o+this.j}function Fj(a){return 1==a.type||2==a.type}function Gj(a,b){return a.a==b.a&&a.ka.start+a.Yb+a.kb==b.ka.start+b.Yb}Ej.prototype.Uh=function(a){return this.a.Uh(this,a)};function Hj(a,b){this.info=a;this.data=b}function Ij(a){if(a.info.kb!=a.data.length)return!1;if(1==a.info.a.info.i){if(8>a.info.kb||4==a.info.type)return!0;var b=new DataView(a.data.buffer,a.data.byteOffset,a.data.byteLength),c=b.getUint32(0,!1),b=b.getUint32(4,!1);if(2==a.info.type)return c==a.info.kb&&1936286840==b;if(3==a.info.type&&0==a.info.Yb)return 1836019558==b}return!0};function Jj(a){this.a=a;this.b=0;this.g=-1}var Kj=0;function Lj(a,b){a.a=Zi(a.a,b)};function Mj(){this.Q=0;this.a=new Float64Array(128);this.b=new Float32Array(128);this.g=!1}Mj.prototype.fb=function(){return this.Q};function Nj(a,b){var c=cb(a.b.subarray(0,a.Q),eb,b);return 0<=c?c:Math.max(0,-c-2)}function Oj(a){if(a.a.length<a.Q+1){var b=2*a.a.length,b=b+2,c=a.a;a.a=new Float64Array(b+1);var d=a.b;a.b=new Float32Array(b+1);for(b=0;b<a.Q+1;b++)a.a[b]=c[b],a.b[b]=d[b]}}function Pj(a,b){this.b=a;this.a=0;this.g=b||0}
-function Qj(a){for(var b=Rj(a,!1);236==b;)Sj(a),b=Rj(a,!1);return b}function Tj(a){var b=Rj(a,!0),c=a.b.byteOffset+a.a,d=Math.min(b,a.b.buffer.byteLength-c),c=new DataView(a.b.buffer,c,d),c=new Pj(c,a.g+a.a);a.a+=b;return c}function Uj(a){for(var b=Rj(a,!0),c=Vj(a),d=1;d<b;d++)c=(c<<8)+Vj(a);return c}function Sj(a){var b=Rj(a,!0);a.a+=b}function Rj(a,b){var c=Vj(a);if(1==c){for(var d=c=0;7>d;d++)c=256*c+Vj(a);return c}for(var e=128,d=0;6>d&&e>c;d++)c=256*c+Vj(a),e*=128;return b?c-e:c}
-function Vj(a){return a.b.getUint8(a.a++)};function Wj(a,b,c,d){this.info=b;this.j=new Jj(a);this.o=c;this.k=d;this.g=this.b=null;this.i=!1;this.index=new Mj;b=parseInt;c=a.search(me);d=le(a,0,"clen",c);if(0>d)a=null;else{var e=a.indexOf("&",d);if(0>e||e>c)e=c;d+=5;a=ua(a.substr(d,e-d))}this.a=b(a,10)}function Xj(a){return!(!a.b||!a.index.fb())}
-function Yj(a,b){var c=new Ej(a,a.o,1),d=new Ej(a,a.k,2),e=[],g=[c];Gj(c,d)?g.push(d):e.push([d]);isNaN(a.a)?b=0:b>a.a&&(b=a.a);c=g[g.length-1];d=c.ka.end-g[0].ka.start+1;b>d&&(c=new wj(c.ka.end+1,c.ka.end+1+(b-d)-1),g.push(new Ej(a,c,4)));e.push(g);return e}
-function Zj(a,b,c,d){for(var e=[];b<a.index.fb();b++){var g;g=a.index.a[b];g=new wj(g,g+(b+1<a.index.Q||a.index.g?a.index.a[b+1]-a.index.a[b]:-1)-1);var h=a.index.b[b],k;k=a.index;var m=b;k=m+1<k.Q||k.g?k.b[m+1]-k.b[m]:-1;var m=Math.max(0,c-g.start),p=Math.min(g.end+1,c+d)-(g.start+m),s=b==a.index.fb()-1&&m+p==g.length;e.push(new Ej(a,g,3,b,h,k,m,p,s));if(g.start+m+p>=c+d)break}return e}
-function ak(a,b){for(var c=0;c+1<a.index.fb()&&b.ka.start>=a.index.a[c+1];)c++;return Zj(a,c,b.ka.start,b.ka.length)}Wj.prototype.Uh=function(a,b){Xj(this);if(!Xj(this)){var c=new wj(a.ka.end+1,a.ka.end+1+b-1);c.end+1>this.a&&(c=new wj(c.start,this.a-1));return[new Ej(a.a,c,4)]}4==a.type&&(c=ak(this,a),a=c[c.length-1]);var c=0,d=a.ka.start+a.Yb+a.kb;3==a.type&&(c=a.i,d==a.ka.end+1&&(c+=1));return Zj(this,c,d,b)};function bk(a,b,c){b=Nj(a.index,b);return Zj(a,b,a.index.a[b],c)};function ck(){this.duration=0;this.a={}}var dk=/PT(([0-9]*)H)?(([0-9]*)M)?(([0-9.]*)S)?/;function ek(a){var b=new ck;z(a,function(a){var d=a.type,e=a.itag,g=null;rj(d)&&(g=a.size.split("x"),g=new tj(parseInt(g[0],10),parseInt(g[1],10)));var h=null;qj(d)&&(h=new nj);d=new oj(e,d,h,g,null,parseInt(a.bitrate,10)/8);g=xj(a.init);h=xj(a.index);(a=fk(a.url,d,a.s))&&(b.a[e]=new Wj(a,d,g,h))});return b}
-function gk(a,b){for(var c=a;c;c=c.parentNode)if(c.attributes){var d=c.attributes[b];if(d)return d.value}return""}function hk(a,b){for(var c=a;c;c=c.parentNode){var d=c.getElementsByTagName(b);if(0<d.length)return d[0]}return null}function fk(a,b,c){if(!Cj(a,yj))return"";b={alr:"yes",mime:b.mb.split(";")[0]};c&&(b.signature=lj(c));return Zi(a,b)};function ik(a,b,c,d,e,g,h,k,m){this.i={};this.o=a;this.G=b;this.b=c;this.a=d;this.g=e;this.A=g;this.j=h;this.k=k;this.B=m}function jk(a,b){var c=a.A,c=c.replace("$N",a.j),c=c.replace("$L",a.B.toString()),c=c.replace("$M",b.toString());a.k&&(c=S(c,{sigh:a.k}));return c}function kk(a,b){var c=Math.floor(b/(a.a*a.g)),d=a.a*a.g,e=b%d,g=e%a.a,e=Math.floor(e/a.a),h=a.g,k=a.b-d*c;k<d&&(h=Math.ceil(k/a.a));return{url:jk(a,c),su:g,wi:a.a,row:e,rows:h,eo:a.o*a.a,co:a.G*h}};function lk(a){var b=[];a=a.split("|");for(var c=a[0],d,e,g,h,k,m,p,s,r=1;r<a.length;r++)d=a[r].split("#"),e=r-1,g=parseInt(d[0],10),h=parseInt(d[1],10),k=parseInt(d[2],10),m=parseInt(d[3],10),p=parseInt(d[4],10),s=d[6],d=d[7],b.push(new ik(g,h,k,m,p,c,s,d,e));this.a=b;this.b={};1<this.a.length&&-1!=this.a[0].j.indexOf("default")&&this.a.splice(0,1)}function mk(a,b){var c=a.a[0].b-1;return tb(Math.round(c*b),0,c)}
-function nk(a,b){var c=a.b[b];if(c)return c;for(var c=a.a.length,d=0;d<c;d++)if(a.a[d].o>=b)return a.b[b]=d;a.b[b]=c-1;return c-1};var ok={0:"MONO",1:"LEFT_RIGHT",2:"RIGHT_LEFT",3:"TOP_BOTTOM",4:"BOTTOM_TOP"};var pk={hC:1,iC:2,jC:3};var qk;var rk=Wb(),rk=rk.toLowerCase();if(-1!=rk.indexOf("android")){var sk=rk.match(/android\D*(\d\.\d)[^\;|\)]*[\;\)]/);if(sk)qk=Number(sk[1]);else{var tk={cupcake:1.5,donut:1.6,eclair:2,froyo:2.2,gingerbread:2.3,honeycomb:3,"ice cream sandwich":4,jellybean:4.1},uk=rk.match("("+Fb(tk).join("|")+")");qk=uk?tk[uk[0]]:0}}else qk=void 0;var vk,wk;function xk(){var a=n("yt.player.utils.videoElement_");a||(a=document.createElement("video"),qa("yt.player.utils.videoElement_",a));return a}function yk(){if(2.2==qk)return!0;var a=xk();try{return!(!a||!a.canPlayType||!a.canPlayType('video/mp4; codecs="avc1.42001E, mp4a.40.2"')&&!a.canPlayType('video/webm; codecs="vp8.0, vorbis"'))}catch(b){return!1}}
-function zk(){var a=Pc("div",{"class":"html5-player-css-loaded"});document.body.appendChild(a);var b="none"==kd(a,"display");F(a);return b};function Ak(){var a;if(void 0==vk&&(vk=!1,window.crypto&&window.crypto.wy))try{a=new Uint8Array(1),window.crypto.wy(a),vk=!0}catch(b){}if(vk){a=Array(16);var c=new Uint8Array(16);window.crypto.getRandomValues(c);for(var d=0;d<a.length;d++)a[d]=c[d]}else for(a=Array(16),c=0;16>c;c++){for(var d=w(),e=0;e<d%23;e++)a[c]=Math.random();a[c]=Math.floor(256*Math.random())}return a}
-function Bk(){for(var a=Ak(),b=[],c=0;c<a.length;c++)b.push("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-_"[a[c]&63]);return b.join("")}function Ck(){return Ja(Ak(),function(a){return(a&15).toString(16)}).join("")};function Dk(a,b,c){b={cpn:b};c&&(b.ibw="1369843");return{url:S(a,b),type:"application/x-mpegURL",quality:"auto",itag:"93"}};function T(a,b){return void 0==b?a:"1"==b?!0:!1}function Ek(a,b,c){for(var d in c)if(c[d]==b)return c[d];return a}function U(a,b){return void 0==b?a:b}function Fk(a,b){var c=U(a,b);c&&(c=Dj(c));return c}function Gk(a){if(!a)return 0;a=a.split(":");var b=parseFloat(a[0]),c=1;2==a.length&&(c=parseFloat(a[1]));return isNaN(b)||isNaN(c)||0==c?0:b/c};function Hk(a,b){this.a=a;this.b=b}Hk.prototype.clone=function(){return new Hk(this.a,this.b)};function Ik(a){this.a=[];if(a)t:{var b,c;if(a instanceof Ik){if(b=a.nc(),c=a.hc(),0>=a.fb()){a=this.a;for(var d=0;d<b.length;d++)a.push(new Hk(b[d],c[d]));break t}}else b=Fb(a),c=Eb(a);for(d=0;d<b.length;d++)Jk(this,b[d],c[d])}}function Jk(a,b,c){var d=a.a;d.push(new Hk(b,c));b=d.length-1;a=a.a;for(c=a[b];0<b;)if(d=b-1>>1,a[d].a>c.a)a[b]=a[d],b=d;else break;a[b]=c}f=Ik.prototype;
-f.remove=function(){var a=this.a,b=a.length,c=a[0];if(!(0>=b)){if(1==b)Sa(a);else{a[0]=a.pop();for(var a=0,b=this.a,d=b.length,e=b[a];a<d>>1;){var g=2*a+1,h=2*a+2,g=h<d&&b[h].a<b[g].a?h:g;if(b[g].a>e.a)break;b[a]=b[g];a=g}b[a]=e}return c.b}};f.hc=function(){for(var a=this.a,b=[],c=a.length,d=0;d<c;d++)b.push(a[d].b);return b};f.nc=function(){for(var a=this.a,b=[],c=a.length,d=0;d<c;d++)b.push(a[d].a);return b};f.clone=function(){return new Ik(this)};f.fb=function(){return this.a.length};
-f.isEmpty=function(){return Ra(this.a)};f.clear=function(){Sa(this.a)};function Kk(){Ik.call(this)}y(Kk,Ik);function Lk(a){R.call(this);this.a=a;this.g=new Kk;this.i={}}y(Lk,R);Lk.prototype.b=!1;function Mk(a,b,c){var d;for(c=nk(a.a,c);0<=c;){d=a.a.a[c];if(d=d.i[Math.floor(b/(d.a*d.g))]?kk(d,b):null)return d;c--}return kk(a.a.a[0],b)}function Nk(a){if(!a.b)if(a.g.isEmpty())a.b=!1;else{a.b=!0;var b=a.g.remove(),c=new Image;c.src=jk(a.a.a[b.zn],b.An);c.onload=v(a.j,a,b.zn,b.An)}}
-Lk.prototype.j=function(a,b){this.b=!1;var c=this.a.a[a];c.i[b]=!0;Nk(this);var d,e=c.a*c.g;d=b*e;c=Math.min(d+e-1,c.b-1);d=[d,c];this.u("l",d[0],d[1])};function Ok(a,b,c){this.b=a;this.a=b;this.g=c}var Pk={playready:["com.youtube.playready"],widevine:["com.widevine.alpha"],clearkey:["org.w3.clearkey","webkit-org.w3.clearkey"]},Qk=["widevine","playready"];function Rk(a,b,c){if(!a.addKey&&!a.webkitAddKey)return null;for(var d=0;d<Qk.length;d++){var e=Qk[d];if(c[e])for(var g=Pk[e],h=0;h<g.length;h++){var k=g[h];if(a.canPlayType(b,k))return new Ok(e,k,c[e])}}return null};function Sk(a,b){this.a=a;this.b=b;this.i=0;Object.defineProperty(this,"timestampOffset",{get:this.Su,set:this.Tu});Object.defineProperty(this,"buffered",{get:this.Ru})}f=Sk.prototype;f.append=function(a){this.a.webkitSourceAppend(this.b,a)};f.abort=function(){this.a.webkitSourceAbort(this.b)};f.Ru=function(){return this.a.webkitSourceState==this.a.SOURCE_CLOSED?new Tk:this.a.webkitSourceBuffered(this.b)};f.Su=function(){return this.i};
-f.Tu=function(a){this.i=a;this.a.webkitSourceTimestampOffset(this.b,a)};function Tk(){this.length=0};function Uk(a){this.activeSourceBuffers=this.sourceBuffers=[];this.a=a;this.b=NaN;this.g=0;Object.defineProperty(this,"duration",{get:this.Nu,set:this.Qu});Object.defineProperty(this,"readyState",{get:this.Ou});this.a.addEventListener("webkitsourceclose",v(this.Pu,this),!0)}function Vk(a){return window.MediaSource?new window.MediaSource:window.WebKitMediaSource?new window.WebKitMediaSource:HTMLMediaElement.prototype.webkitSourceAddId?new Uk(a):null}f=Uk.prototype;
-f.addEventListener=function(a,b,c){this.a.addEventListener(a,b,c)};f.on=function(){return this.a.webkitMediaSourceURL};f.addSourceBuffer=function(a){var b=(this.g++).toString();this.a.webkitSourceAddId(b,a);a=new Sk(this.a,b);this.sourceBuffers.push(a);return a};
-f.removeSourceBuffer=function(a){for(var b in this.sourceBuffers)if(a===this.sourceBuffers[b]){this.a.webkitSourceRemoveId(a.b);for(a=b+1;a<this.sourceBuffers.length;a++)this.sourceBuffers[a-1]=this.sourceBuffers[a];this.sourceBuffers.pop();break}};f.Ou=function(){switch(this.a.webkitSourceState){case this.a.SOURCE_CLOSED:return"closed";case this.a.SOURCE_OPEN:return"open";case this.a.SOURCE_ENDED:return"ended"}return""};
-f.endOfStream=function(a){var b=this.a.EOS_NO_ERROR;"network"==a?b=this.a.EOS_NETWORK_ERR:"decode"==a&&(b=this.a.EOS_DECODE_ERR);this.a.webkitSourceEndOfStream(b)};f.Pu=function(){Sa(this.sourceBuffers)};f.Nu=function(){return this.b};f.Qu=function(a){this.b=a;this.a.webkitSourceSetDuration&&this.a.webkitSourceSetDuration(a)};function Wk(){this.a=[]}Wk.prototype.listen=function(a,b,c){if(t(b))for(var d=0;d<b.length;d++)this.listen(a,b[d],c);else c=v(c,this),a.addEventListener(b,c,!1),this.a.push(a,b,c)};Wk.prototype.removeAll=function(){if(this.a)for(;this.a.length;){var a=this.a.shift(),b=this.a.shift(),c=this.a.shift();a.removeEventListener&&a.removeEventListener(b,c)}};Wk.prototype.ha=function(){return null===this.a};Wk.prototype.dispose=function(){this.removeAll();this.a=null};function Xk(a,b,c,d){this.a=[];this.Af=this.zd=null;this.i=b;this.g=Vk(a);this.b="";this.j=null;this.listen(this.g,["sourceopen","webkitsourceopen"],oa(this.Vt,d,c));this.listen(this.g,["sourceclose","webkitsourceclose"],this.Ut)}y(Xk,Wk);var Yk={};f=Xk.prototype;f.Va=function(a){this.isOpen()?this.g.duration=a:this.i=a};f.isOpen=function(){return"open"==this.g.readyState};f.xc=function(){return"closed"==this.g.readyState};
-f.Vt=function(a,b){isNaN(this.i)||(this.g.duration=this.i,this.i=NaN,this.zd=this.g.addSourceBuffer(a),this.Af=this.g.addSourceBuffer(b),this.j&&(this.j(this),this.j=null))};f.Ut=function(){this.dispose()};f.dispose=function(){Zk(this.b);this.b="";Xk.C.dispose.call(this)};function Zk(a){if(a)try{window.URL.revokeObjectURL(a)}catch(b){}}
-function $k(a,b){var c={};if(window.MediaSource&&window.MediaSource.isTypeSupported)Ja(a,function(a){c[a]=window.MediaSource.isTypeSupported(a)}),H(oa(b,c),0);else{for(var d=!1,e=0;e<a.length;e++){var g=Yk[a[e]];if(void 0!=g)c[a[e]]=g;else{d=!0;break}}if(d){var d=xk(),e=Vk(d),g=e.on?e.a.webkitMediaSourceURL:window.URL.createObjectURL(e),h=oa(al,a,b,d,e,g);e.addEventListener("sourceopen",h,!1);e.addEventListener("webkitsourceopen",h,!1);d.src=g}else H(oa(b,c),0)}}
-function al(a,b,c,d,e){for(var g={},h=0;h<a.length;h++){var k=Yk[a[h]];if(void 0==k){try{var m=d.addSourceBuffer(a[h]);d.removeSourceBuffer(m);k=!0}catch(p){p.code==DOMException.NOT_SUPPORTED_ERR&&(k=!1)}Yk[a[h]]=k}g[a[h]]=k}c.src="";Zk(e);b(g)};function bl(a,b,c,d){this.a=c;this.b=a;this.j=d||"";this.i=b;this.g={}}function xi(a){if(a.a)a=a.b;else if(a.i){var b;b=(new pe(a.b)).a.get("id");b="http://www.youtube.com/api/manifest/t2b/source/youtube/id/"+encodeURIComponent(b);b+="/itag/"+a.j;b+="/mfmt/amf";a=ue(new pe(S(a.b,a.g)),b).toString()}else a=S(a.b,a.g);return a};function cl(a,b){var c=b.Sa in dl&&ri();this.i=(this.a=!!(a instanceof Array))?null:new bl(a,c,this.a,b.Sa);this.b=this.a?a[0]:null;this.g=this.a?a[1]:null;this.mc=b}cl.prototype.getInfo=function(){return this.mc};var el={'video/mp4; codecs="avc1.42001E, mp4a.40.2"':"maybe"},fl={"application/x-mpegURL":"maybe"},gl={"application/x-mpegURL":"maybe"};
-function hl(a,b,c){if(!yk())return[];var d=il(a,b);a=!d.length&&b?il(a,!1):d;var e={};b=xk();c=c||(ii||ji&&si("crkey")?!0:!1);for(d=0;d<a.length;d++){var g=a[d];if((b.canPlayType(g.getInfo().mb)||jl(g))&&!(g.mc.Sa in kl||ri()&&"5"==g.mc.Sa)){var h=g.mc.a.i;if(!e[h]||pj(g.getInfo())&&!c||!pj(g.getInfo())&&c)e[h]=g}}var k=[];z(uj,function(a){(g=e[a])&&k.push(g)});return k}function jl(a){var b;a=a.getInfo().mb;hi?b=gl[a]:2.2==qk?b=el[a]:ii&&si("chrome")&&(b=fl[a]);return b||""}
-var dl={5:!0,34:!0,35:!0},kl={52:!0,53:!0,54:!0,55:!0,60:!0,79:!0,87:!0},ll={EB:160,AB:133,CB:134,uB:135,qB:136,mB:137,vB:138,kB:140,BB:142,DB:143,xB:144,zB:222,yB:223,rB:145,tB:224,sB:225,nB:146,pB:226,oB:227,wB:147,lB:149,jB:261,FB:161,wD:171,vD:172,DD:194,AD:195,CD:220,BD:221,zD:196,yD:197,xD:198,JD:242,KD:243,GD:244,ID:245,HD:246,FD:247,ED:248};function ml(a){var b=[];z(a,function(a){a.url&&b.push(nl(a.url,a.type,"auto","0"))});return b}
-function nl(a,b,c,d,e){var g=new nj;(c=vj[c])||(c=vj.small);e=new tj(c[0],c[1],e?-1:0);b=unescape(b.replace(/&quot;/g,'"'));return new cl(a,new oj(d,b,g,e))}function il(a,b){for(var c=[],d=0;d<a.length;d++){var e=a[d],g;if(g=ac)if(g=0!=e.mc.a.a)g=1==e.getInfo().i;g||0!=e.mc.a.a==b&&c.push(e)}return c}
-function ol(a,b,c){for(var d=[],e=0;e<a.length;e++){var g=a[e];if(g.sig||g.s){var h=g.sig||lj(g.s);g.url=Zi(g.url,{signature:h})}g.url&&d.push(nl(g.url,g.type,g.quality,g.itag,g.stereo3d))}return hl(d,!!b,!!c)}function pl(a,b){var c=ml(a);return hl(c,!1,!!b)}
-function ql(a,b,c,d,e,g){if(a){var h=[];if(g){g={};for(var k in a.a)h=a.a[k].info.mb,g[h]=window.MediaSource&&window.MediaSource.isTypeSupported?window.MediaSource.isTypeSupported(h):!!xk().canPlayType(h);rl(a,b,c,d,e,g)}else{for(k in a.a)h.push(a.a[k].info.mb);$k(h,v(rl,null,a,b,c,d,e))}}else c([])}
-function rl(a,b,c,d,e,g){var h=null,k={},m={},p;for(p in ll){var s=ll[p],r=a.a[s];if(r&&g[r.info.mb]&&!(0<=r.info.mb.indexOf("vp9")&&si("cros armv7"))){if(r.info.g){h||(h=xk());if(!Rk(h,r.info.mb,r.info.g))continue;if(!e&&r.info.a&&(1280<=r.info.a.width||720<=r.info.a.height))continue;if(261==s&&!h.canPlayType('audio/mp4; codecs="aac51"',"com.widevine.alpha"))continue}if(s=0<r.info.mb.indexOf("/webm")?r.info.g?3:1:0<r.info.mb.indexOf("/mp4")?r.info.g?4:2:null){Lj(r.j,b);var x=r.info.j?k:m;x[s]=x[s]||
-[];x[s].push(r)}}}a=[3,4,1,2];d&&(a=[4,3,2,1]);d=null;for(p=0;p<a.length;p++)if(k[a[p]]&&m[a[p]]){d=a[p];break}a=[];if(null!=d)for(fb(k[d],"itag"),k=k[d].pop(),p=0;p<m[d].length;p++)a.push(new cl([k,m[d][p]],m[d][p].info));db(a,function(a,b){var c=a.getInfo(),d=b.getInfo();return d.a.height-c.a.height||d.b-c.b});c(a)};function hg(a){R.call(this);this.k=[];this.da=new C(0,0);this.O=[];this.I=[];this.b={};this.va={};this.i={};sl(this,a)}y(hg,R);var tl=/\/img\/watermark\/youtube_(hd_)?watermark(-vfl\S{6})?.png$/,ul="author cc_asr cc_load_policy iv_new_window iv_load_policy keywords subscribed rvs title ttsurl ypc_buy_url ypc_full_video_length ypc_item_thumbnail ypc_item_title ypc_item_url ypc_offer_button_text ypc_offer_description ypc_offer_headline ypc_offer_id ypc_price_string ypc_preview ypc_video_rental_bar_text".split(" ");
-f=hg.prototype;f.ga=!1;f.Ho=!0;f.bb=!1;f.Pk="";f.Ok="";f.Nk="";f.Lj=!1;f.zh=1;f.Ym=!1;f.pm=0;f.ue=0;f.xo=!1;f.vk=!1;f.Tm=3;f.li="";f.Ca="";f.Qk=!1;f.gg=!1;f.Vl=!1;f.rf=0;f.Ue=!1;f.Zm=!1;f.cg=0;f.hf=!1;f.Wl=!0;f.kj=!1;f.wo=!1;f.Fb=!1;f.Wk=!1;f.Nd=!1;f.Sn=!1;f.Xk=!1;f.Nj=0;f.wa=0;f.uh=0;f.dk=!1;f.nm=!1;f.gj=!1;f.vm=0;f.ig=!1;f.sm=!1;f.ya=0;f.ej=null;f.kf=null;f.Kj=!1;f.Jf=!1;f.mf=null;f.Oj=1;f.ye=0;f.Gl=null;f.Xl=!1;f.Mj=NaN;f.Qm=NaN;
-function Eg(a,b){var c=b||{};c.iv_read_url&&(a.Pk=Dj(c.iv_read_url));c.iv_invideo_url&&(a.Ok=Dj(c.iv_invideo_url));c.iv_cta_url&&(a.Nk=Dj(c.iv_cta_url));a.author=U(a.author,c.author);a.vk=T(a.vk,c.cc_asr);a.li=Fk(a.li,c.ttsurl);a.Ca=U(a.Ca,c.cpn);a.g=U(a.g,c.subscribed);a.title=U(a.title,c.title);a.ba=U(a.ba,c.ypc_preview);a.dk=T(a.dk,c.paygated);c.keywords&&(a.va=vl(c.keywords));c.rvs&&(a.Kc=wl(c.rvs));z(ul,function(a){a in c&&(this.b[a]=c[a])},a)}
-function sl(a,b){var c=b||{};a.bb="1"!=c.hlsdvr||ki||hi&&5>li?!1:!0;a.Lj="1"==c.infringe||"1"==c.muted;a.vo=c.authkey;a.Da=c.authuser;a.Ca||(a.Ca=c.cpn||Bk());a.Fc=c.csi_page_type;a.La=c.sw;a.gb=T(a.gb,c.dto);a.qb=c.t;a.Qk=T(a.Qk,c.cenchd);a.gg="1"==c.enable_cardio;a.Vl="1"==c.enable_cardio_before_playback;a.rf=void 0==(c.end||c.endSeconds)?a.rf:Number(c.end||c.endSeconds);a.Wl="1"!=c.no_get_video_log;a.kj="1"==c.tmi;a.wo="1"==c.livemonitor;a.Fb="1"==c.live_playback;a.Wk=T(a.Wk,c.mdx);a.Xk=T(a.Xk,
-c.utpsa);a.Io=c.iurlmaxres;a.H=U(a.H,c.oauth_token);a.U=U(a.U,c.vvt);a.nd=c.osig;a.Hc=c.ptchn;a.Dc=c.oid;a.A=c.ptk;a.Gc=c.pltype;a.ab=c.plid;a.j=c.eventid;a.Na=U(a.Na,c.list);a.Lc=c.pyv_beacon_url;a.pd=c.purchase_id;a.fa=c.sdetail;a.od=c.sourceid;a.ea=U(a.ea,c.feature);a.Nc=1==(void 0==c.is_fling?a.Nc?1:0:Number(c.is_fling));a.oa=U(a.oa,c.ytr);a.Jo=c.iurlsd;a.Xl="1"==c.skip_kansas_logging;a.kf=Ek(a.kf,c.vq||c.suggestedQuality,sj);a.te=c.approx_threed_layout||0;a.Kj="1"==c.threed_converted;a.Ji=c.iurl;
-a.gj="1"==c.sendtmp;a.ig=!!a.La||a.gj;a.ya=void 0==(c.start||c.startSeconds)?a.ya:Number(c.start||c.startSeconds);a.L=c.docid||c.video_id||c.videoId;xl(a,c.watermark);a.Ic=U(a.Ic,c.ypc_gid);a.Mc=U(a.Mc,c.ypc_license_session_token);if(c.ad3_module||c.ad_module)"1"==c.allow_html5_ads?(a.ga=!0,"1"==c.ad_preroll&&a.I.push("ad")):"1"==c.supported_without_ads||c.cta&&c.fexp&&(-1!=c.fexp.indexOf("924604")||-1!=c.fexp.indexOf("924610"))||(a.Zm=!0);c.adaptive_fmts&&(a.Ra=yl(a,c.adaptive_fmts));c.allow_embed&&
-(a.Ho="1"==c.allow_embed);c.autoplay&&(a.hf="1"==c.autoplay);c.iv_load_policy&&(a.ca=zl(c.iv_load_policy,a.ca));c.cc_load_policy&&(a.Tm=zl(c.cc_load_policy,2));c.dash&&void 0===a.$&&(a.$="1"==c.dash);if(c.dashmpd){a.N=S(c.dashmpd,{cpn:a.Ca});var d=/\/s\/([0-9A-F.]+)/,e=d.exec(a.N);e&&(e=lj(e[1]),a.N=a.N.replace(d,"/signature/"+e))}c.delay&&(a.K=Ca(c.delay));c.idpj&&(a.cg=Ca(c.idpj));c.url_encoded_fmt_stream_map&&(a.O=yl(a,c.url_encoded_fmt_stream_map));c.hlsvp&&(d=Dk(c.hlsvp,a.Ca,c.fexp&&-1!=c.fexp.indexOf("934005")&&
-!c.on3g),a.O.push(d));c.length_seconds&&(a.wa=Ca(c.length_seconds));c.ldpj&&(a.uh=Ca(c.ldpj));c.loudness&&(a.za=c.loudness,a.zh=-15<a.za&&0>a.za?Math.pow(10,(-18-a.za)/20):1);c.partnerid&&(a.qd=Ca(c.partnerid));c.pyv_billable_url&&Cj(c.pyv_billable_url,Aj)&&(a.R=c.pyv_billable_url);c.pyv_conv_url&&Cj(c.pyv_conv_url,Aj)&&(a.Ia=c.pyv_conv_url);c.url_encoded_third_party_media&&(a.mf=wl(c.url_encoded_third_party_media));c.threed_module&&!c.threed_converted&&(a.S=c.threed_module,a.Jc=6);if("1"==c.track_embed||
-c.tk)a.nm=!0;c.watch_ajax_token&&ff("watch_actions_ajax",c.watch_ajax_token);c.fresca_preroll&&a.I.push("fresca");c.ypc_clickwrap_preroll&&a.I.push("ypc_clickwrap");void 0!=c.start&&(a.Mj=c.start);void 0!=c.end&&(a.Qm=c.end);a.Ec=U(a.Ec,c.ucid);z(["baseUrl","uid","oeid","ieid","ppe"],function(a){this.i[a]=c[a]},a);a.i.focEnabled="1"==c.focEnabled;a.i.rmktEnabled="1"==c.rmktEnabled;a.pm=Al(c.rmktPingThreshold,c.length_seconds);a.b=c;Eg(a,c);a.$&&Bl(a)}
-function Bl(a){if(ii&&si("chrome")&&!pc(29)?0:window.MediaSource||window.WebKitMediaSource||HTMLMediaElement.prototype.webkitSourceAddId)if(a.Ra)a.B=ek(a.Ra);else if(a.N){var b={format:"RAW",method:"GET",X:a,Oa:a.jx,onError:a.ul};a.Ue=!0;a=Dj(a.N);ej(a,b)}}
-f.jx=function(a){if(!this.ha()){if(200<=a.status&&400>a.status){var b=new ck;t:{a=a.responseText;a=(new DOMParser).parseFromString(a,"text/xml").getElementsByTagName("MPD")[0];var c;if(c=gk(a,"mediaPresentationDuration")){var d=dk.exec(c);c=d?3600*parseFloat(d[2]||0)+60*parseFloat(d[4]||0)+parseFloat(d[6]||0):parseFloat(c)}else c=0;b.duration=c;a=a.getElementsByTagName("Representation");for(c=0;c<a.length;c++){var d=a[c],e=gk(d,"id"),g=gk(d,"mimeType"),h=gk(d,"codecs"),g=h?g+'; codecs="'+h+'"':g,
-h=parseInt(gk(d,"bandwidth"),10)/8,k=null;rj(g)&&(k=new tj(parseInt(gk(d,"width"),10),parseInt(gk(d,"height"),10)));var m=null;qj(g)&&(m=new nj);var p=null,s=hk(d,"ContentProtection");if(s)if((p=s.attributes.schemeIdUri)&&"http://youtube.com/drm/2012/10/10"==p.textContent)for(p={},s=s.firstChild;null!=s;s=s.nextSibling)"yt:SystemURL"==s.nodeName&&(p[s.attributes.type.textContent]=s.textContent.trim());else p=null;e=new oj(e,g,m,k,p,h);g=fk(hk(d,"BaseURL").textContent,e);h=hk(d,"SegmentBase");d=xj(h.attributes.indexRange.value);
-h=xj(h.getElementsByTagName("Initialization")[0].attributes.range.value);d=new Wj(g,e,h,d);if(!d){a=!1;break t}b.a[d.info.Sa]=d}a=!0}if(this.B=a?b:null)this.wa=this.B.duration||this.wa}this.ul()}};f.ul=function(){this.ha()||(this.Ue=!1,this.u("dataloaded",this.b))};function Cl(a,b,c,d){ql(a.B,Dl(a),v(function(a){this.ha()||(a.length?(this.k=a,this.u("dataupdated"),b()):(this.$=!1,El(this,b,c)))},a),c,a.Qk,d)}
-function El(a,b,c){a.k=a.mf&&a.Sn?pl(a.mf,c):ol(a.O,!!a.S||a.Jf,c);H(v(function(){this.ha()||(this.u("dataupdated"),b&&b())},a),0)}function Fl(a){return Ja(a.k,function(a){return a.mc.a.i}).concat(["auto"])}function Gl(a,b){var c=null;a.k.some(function(a){if(a.mc.a.i==b)return c=a,!0});return c}function Hl(a){var b=a.o&&a.o.i;if(!b)return null;pa(b.g,Dl(a));return b}function Dl(a){var b={};a.A&&(b.ptk=a.A,b.oid=a.Dc,b.ptchn=a.Hc,b.pltype=a.Gc);return b}
-function Il(a,b){return u(a.va[b])?a.va[b]:null}function Jl(a){!a.Gl&&a.b.storyboard_spec&&(a.Gl=new lk(a.b.storyboard_spec));return a.Gl}function Kl(a){var b=Jl(a);!a.ej&&b&&(a.ej=new Lk(b),L(a,a.ej));return a.ej}function Ll(a,b){var c={format:"RAW",method:"GET",X:a,Oa:a.yx};a.Ue=!0;ej(b,c)}f.yx=function(a){this.ha()||(this.Ue=!1,a=Ui(a.responseText),"fail"==a.status?this.u("onStatusFail",a):(sl(this,a),this.Ue||this.ul()))};function zl(a,b){var c=parseInt(a,10);return Gb(pk,c)?c:b}
-function wl(a){a=a.split(",");return a=a.map(function(a){return Ui(a)})}function yl(a,b){var c=wl(b);z(c,function(a){a.url&&(a.url=S(a.url,{cpn:this.Ca}))},a);return c}function vl(a){var b={};z(a.split(","),function(a){var d=a.split("=");2==d.length?b[d[0]]=d[1]:b[a]=!0});return b}function xl(a,b){if(b){var c=b.split(",");2<=c.length&&(a.Ma=c[1],a.Oc=c[0])}}function Ml(a,b){return!!a.b[b]}function Al(a,b){var c=Ca(b),d=Ca(a);return isNaN(d)||isNaN(c)?0:Math.min(d,c)};function Nl(a,b){this.type=a||"";this.id=b||""}Nl.prototype.toString=function(){return this.type+this.id};function Ol(a){R.call(this);this.a=[];this.b=[];this.pa=Math.max(0,a.index||0);this.loop=!!a.loop;this.ya=a.startSeconds||0;this.Nn="1"==a.mob;this.title=a.playlist_title||"";a.video_id&&(this.a[this.pa]=new hg(a));a.api&&("string"==typeof a.api&&16==a.api.length?a.list="PL"+a.api:a.playlist=a.api);if(a.list)switch(a.listType){case "user_uploads":Pl(this,a.list);break;case "user_favorites":Ql(this,a.list);break;case "search":Rl(this,a.list);break;default:a.playlist_length&&(this.Pa=a.playlist_length),
-this.g=new Nl(a.list.substr(0,2),a.list.substr(2)),this.Vg||Sl(this,"/list_ajax?style=json&action_get_list=1",{list:this.g})}else if(a.playlist){var b=a.playlist.toString().split(",");0<this.pa&&(this.a=[]);z(b,function(a){a&&this.a.push(new hg({video_id:a}))},this);this.Pa=this.a.length;this.be=!0}else a.videoList&&(0<this.pa&&(this.a=[]),z(a.videoList,function(a){this.a.push(new hg(a))},this),this.Pa=this.a.length,this.be=!0);sg(this,!!a.shuffle);a.suggestedQuality&&(this.i=a.suggestedQuality)}
-y(Ol,R);f=Ol.prototype;f.loop=!1;f.ya=0;f.Po=!1;f.pa=0;f.title="";f.Pa=0;f.Nn=!1;f.be=!1;f.Vg=!1;f.Ne=null;function Tl(a){if(++a.pa>=a.Pa)if(a.loop)a.pa=0;else return null;rg(a,a.pa);return qg(a,a.pa)}function Ul(a){if(0>--a.pa)if(a.loop)a.pa=a.Pa-1;else return null;rg(a,a.pa);return qg(a,a.pa)}function qg(a,b){var c=void 0!=b?b:a.pa;if(c=a.a&&c in a.a?a.a[a.b[c]]:null)c.ya=a.ya||c.Mj;return c}
-function sg(a,b){a.Po=b;var c=a.b&&null!=a.b[a.pa]?a.b[a.pa]:a.pa;a.b=[];for(var d=0;d<a.a.length;d++)a.b.push(d);a.pa=c;if(a.Po){c=a.b[a.pa];for(d=1;d<a.b.length;d++){var e=Math.floor(Math.random()*(d+1)),g=a.b[d];a.b[d]=a.b[e];a.b[e]=g}for(d=0;d<a.b.length;d++)a.b[d]==c&&(a.pa=d)}a.u("shuffle")}function rg(a,b){a.pa=tb(b,0,a.Pa-1);a.ya=0}function Vl(a){return a.Pa}function Pl(a,b){a.Vg||(a.g=new Nl("UU","PLAYER_"+b),Sl(a,"/list_ajax?style=json&action_get_user_uploads_by_user=1",{username:b}))}
-function Ql(a,b){a.Vg||(a.g=new Nl("FL","PLAYER_"+b),Sl(a,"/list_ajax?style=json&action_get_favorited_by_user=1",{username:b}))}function Rl(a,b){if(!a.Vg){a.g=new Nl("SR",b);var c={search_query:b};a.Nn&&(c.mob="1");Sl(a,"/search_ajax?style=json&embeddable=1",c)}}function Sl(a,b,c){ej(S(b,c),{format:"JSON",Oa:function(a,b){Wl(this,b)},X:a})}
-function Wl(a,b){if(b.video&&b.video.length){a.title=b.title;a.description=b.description;a.views=b.views;a.author=b.author;var c=qg(a);a.pa=0;a.a=[];z(b.video,function(a){a&&(a.video_id=a.encrypted_id,c&&a.video_id==c.L&&(this.pa=this.a.length),this.a.push(new hg(a)))},a);a.Pa=a.a.length;sg(a,!1);a.Vg=!1;a.be=!0;a.Ne&&a.Ne()}}f.F=function(){this.Ne=null;Of(this.a);Ol.C.F.call(this)};var Xl=!!l.DOMTokenList,Yl=Xl?function(a){return a.classList}:function(a){a=a.className;return u(a)&&a.match(/\S+/g)||[]},Zl=Xl?function(a,b){return a.classList.contains(b)}:function(a,b){return A(Yl(a),b)},V=Xl?function(a,b){a.classList.add(b)}:function(a,b){Zl(a,b)||(a.className+=0<a.className.length?" "+b:b)},$l=Xl?function(a,b){z(b,function(b){V(a,b)})}:function(a,b){var c={};z(Yl(a),function(a){c[a]=!0});z(b,function(a){c[a]=!0});a.className="";for(var d in c)a.className+=0<a.className.length?
-" "+d:d},W=Xl?function(a,b){a.classList.remove(b)}:function(a,b){Zl(a,b)&&(a.className=Ia(Yl(a),function(a){return a!=b}).join(" "))},am=Xl?function(a,b){z(b,function(b){W(a,b)})}:function(a,b){a.className=Ia(Yl(a),function(a){return!A(b,a)}).join(" ")};function X(a,b,c){c?V(a,b):W(a,b)}function bm(a,b){var c=!Zl(a,b);X(a,b,c);return c};function cm(a,b){this.$f=a;this.ef=b+"::"}y(cm,Mg);f=cm.prototype;f.$f=null;f.ef="";f.set=function(a,b){this.$f.set(this.ef+a,b)};f.get=function(a){return this.$f.get(this.ef+a)};f.remove=function(a){this.$f.remove(this.ef+a)};f.Kd=function(a){var b=this.$f.Kd(!0),c=this,d=new Qd;d.next=function(){for(var d=b.next();d.substr(0,c.ef.length)!=c.ef;)d=b.next();return a?d.substr(c.ef.length):c.$f.get(d)};return d};function dm(a){R.call(this);this.a=a;if(this.yl){a="yt-html5-player-modules::"+this.yl;var b=new Og;if(a=b.isAvailable()?a?new cm(b,a):b:null)this.o=new Pg(a)}}y(dm,R);f=dm.prototype;f.na="";f.kd="";f.Hd=!1;f.Z=!1;f.uc=null;f.yf=function(a){var b=Ya(arguments),c=v(this.vc,this),d=v(this.dd,this);z(b,function(a){a.namespace=this.na;a.yb.D("onEnter",c);a.yb.D("onExit",d)},this);this.u("command_add_cuerange",b,this.a.a)};f.Av=function(a){var b=Ya(arguments);this.u("command_remove_cuerange",b,this.a.a)};
-function em(a){a.u("command_remove_cuerange_all",a.na,a.a.a)}function fm(a){a.u("command_preroll_ready",a.na,a.a.a)}function gm(a,b){V(b,a.na);a.a.app.P.U.appendChild(b)}function hm(a){a.u("command_show_dialog_area")}function im(a){a.u("command_hide_all_dialogs")}f.create=function(){var a=this.na+"-created";this.Xa(this.a);Zl(Q(this.a),a);V(Q(this.a),a);this.Hd=!0};f.destroy=function(){this.unload();W(Q(this.a),this.na+"-created");this.Hd=!1};
-f.load=function(){V(Q(this.a),this.na+"-loaded");this.u("loaded",this.na)};f.unload=function(){W(Q(this.a),this.na+"-loaded");this.u("unloaded",this.na)};f.vc=function(){};f.dd=function(){};f.oe=function(){};f.log=function(a){this.u("command_log",this.kd,a)};function jm(a,b,c){var d={},e;for(e in b)d[a.na+"_"+e]=b[e];b={};for(var g in c)b[a.na+"_"+g]=c[g];a.u("command_log_timing",d,b)}f.Oi=function(){return null};
-function km(a,b){if(!a.o)return null;var c;try{c=a.o.get(b)}catch(d){a.o&&a.o.remove(b)}return c}function lm(a,b,c){if(a.o)try{a.o.set(b,c)}catch(d){}}function mm(a,b){a.u("command_disable_controls",b,a.na)}function nm(a,b){a.u("command_enable_controls",b,a.na)}function om(a){a.u("command_stop_redirect_controls")}function pm(a){a.u("command_play",!1,a.a.a)}function qm(a){a.u("command_pause",!1,a.a.a)}f.jb=function(a){this.u("command_redirected_show_is_playing",a)};f.rq=function(){};f.jp=function(){return[]};
-f.Xa=function(){return!1};f.Mo=function(a,b){this.uc&&this.uc.oe&&this.uc.oe.apply(this.uc,arguments)};f.Xh=function(){};function rm(a,b){this.a=a;this.yb=b;this.Lf=E("html5-endscreen",Q(this.a));V(this.Lf,this.Cl);this.Uf=E("html5-endscreen-content",Q(this.a))}f=rm.prototype;f.Cl="base-endscreen";f.Lf=null;f.Uf=null;f.yb=null;f.Hd=!1;f.create=function(){this.Hd=!0};f.destroy=function(){this.Hd=!1};f.load=function(){};function sm(a){this.a={};this.g={};this.i={};this.b=tm(this,a)}y(sm,Lf);function tm(a,b,c){var d=0,e=Sc(b[d++]);if(u(b[d])||t(b[d])||null===b[d]){var g=b[d++];t(g)&&(g=g.join(" "));if(g=um(a,e,"className",g))vm(a,e,"className",g),wm(a,g,e)}for(;d<b.length;d++){var h=b[d];if(t(h))tm(a,h,e);else if(ia(h)){var g=a,k=e,m=void 0;for(m in h)h[m]&&vm(g,k,m,um(g,k,m,h[m]))}else u(h)&&vm(a,e,"child",um(a,e,"child",h))}c&&c.appendChild(e);return e}f=sm.prototype;f.M=function(){return this.b};
-function wm(a,b,c){var d=b.split(" ");if(1<d.length)for(b=0;b<d.length;b++)wm(a,d[b],c);else a.a[b]=c}f.T=function(a,b){q(b)?a.insertBefore(this.b,a.childNodes[b]||null):a.appendChild(this.b)};f.Ek=function(){F(this.b)};function um(a,b,c,d){return u(d)&&"{{"==d.substr(0,2)?(a.g[d]=[b,c],null):d}f.update=function(a){for(var b in a)xm(this,b,a[b])};function xm(a,b,c){if(c!=a.i[b]){var d=a.g["{{"+b+"}}"];d&&(a.i[b]=c,vm(a,d[0],d[1],c))}}
-function vm(a,b,c,d){if("child"==c){Vc(b);if(!t(d)||t(d)&&u(d[0]))d=[d];c=[];for(var e=0;e<d.length;e++){var g=d[e];null===g||(!g.nodeType||1!=g.nodeType&&3!=g.nodeType?t(g)&&u(g[0])?c.push(tm(a,g)):g.M?c.push(g.M()):c.push(Tc(g.toString())):c.push(g))}for(a=0;a<c.length;a++)b.appendChild(c[a])}else"className"==c?b.className=d:null===d?b.removeAttribute(c):b.setAttribute(c,d.toString())}f.F=function(){this.a={};this.g={};this.i={};this.Ek();this.b=null;sm.C.F.call(this)};function ym(a){a&&(a.style.display="block")}function zm(a){a&&(a.style.display="none")}function Am(a,b){var c=Ve("requestAnimationFrame",window);return H(function(){c?c.call(window,a):a()},b||0)};function Z(a){this.template=new sm(a);L(this,this.template);this.element=this.template.M();this.A=[];this.k={}}y(Z,Lf);f=Z.prototype;f.M=function(){return this.element};f.T=function(a,b){this.template.T(a,b)};f.Ek=function(){this.template.Ek()};f.Aa=function(a){xm(this.template,"content",a)};f.show=function(){ym(this.element)};f.hide=function(){zm(this.element)};f.listen=function(a,b,c,d){a=K(a,b,v(c,this));this.A.push(a);u(d)&&this.k[d].push(a);return a};f.Vc=function(a){vf(a)};
-f.stopPropagation=function(a){this.listen(this,a,function(a){a.stopPropagation()})};f.addEventListener=function(a,b,c){this.element.addEventListener?this.element.addEventListener(a,b,c):this.element.attachEvent&&this.element.attachEvent("on"+a,b)};f.removeEventListener=function(a,b,c){this.element.removeEventListener?this.element.removeEventListener(a,b,c):this.element.detachEvent&&this.element.detachEvent("on"+a,b)};f.dispatchEvent=function(a){return this.element.dispatchEvent(a)};
-f.F=function(){this.Vc(this.A);this.element=null;Z.C.F.call(this)};function Bm(){Z.call(this,["div","",["div","ytp-channel-banner-container",["img","ytp-channel-banner",{src:"{{banner}}"}],["div","ytp-subscribe-curtain"]],["div","ytp-subscribe-card",["img","ytp-author-image",{src:"{{image}}"}],["div","ytp-subscribe-card-right",["div","ytp-author-name","{{author}}"],["div","html5-subscribe-button-container"]]]])}y(Bm,Z);function Cm(a,b,c,d,e,g,h){a&&(a={video_id:a,html5:1,page_subscribe:b?1:0},g&&(a.authuser=g),h&&(a.pageid=h),ej("/get_video_metadata",{method:"GET",onError:d,Oa:c,zf:a,X:e}))};function Dm(a,b){rm.call(this,a,b);this.b=new Bm;this.b.T(this.Lf);Cm(this.a.getVideoData().L,!0,this.g,ba,this,this.a.J().Da,this.a.J().Ta)}y(Dm,rm);Dm.prototype.Cl="subscribecard-endscreen";
-Dm.prototype.g=function(a,b){var c=b.user_info,d=this.a.getVideoData();d&&(d.ua=c.external_id);xm(this.b.template,"banner",c.channel_banner_url);xm(this.b.template,"image",c.channel_logo_url||c.image_url);xm(this.b.template,"author",c.channel_title||c.username);d=b.video_info;d.subscription_ajax_token&&ff("subscription_ajax",d.subscription_ajax_token);c=c.subscription_button_html;this.b.template.a["html5-subscribe-button-container"].innerHTML=c?c:""};function Em(a,b,c){c=c||{};var d=c.Ib;d||(d=document.createElement("style"),document.getElementsByTagName("head")[0].appendChild(d),d=d.sheet||d.styleSheet);c.reset&&Fm(d);b=b instanceof Array?b.join(";"):b;d.insertRule?d.insertRule(a+"{"+b+"}",d.cssRules.length):d.addRule(a,b,-1);return d}function Fm(a){for(var b=(a.cssRules||a.rules).length;0<b;b--){var c=a;c.deleteRule?c.deleteRule(0):c.removeRule(0)}};function Gm(a){this.V=a}y(Gm,Lf);Gm.prototype.g=null;Gm.prototype.b=null;Gm.prototype.a=null;function Hm(a){a.g||(a.g=E("ad-container",Q(a.V)),a.V.J().tb&&V(a.g,"ad-container-single-media-element"));return a.g}function Im(a){a.a&&(a.V.J().tb?(W(a.a,"ad-video"),Jm(a.V.app,a.a),a.a=null):(F(a.a),Ci(a.a)))}
-function Km(a){if(!a.b){if(a.V.J().Gb){var b=Sc("button");V(b,"video-click-tracking");Uc(b,J("VISIT_ADVERTISERS_SITE"));var c=Sc("div");V(c,"video-click-tracking-container");c.appendChild(b);Hm(a).appendChild(c)}else b=Sc("div"),$l(b,["video-click-tracking","ad-video"]),Hm(a).appendChild(b);a.b=b}return a.b}Gm.prototype.F=function(){Gm.C.F.call(this);this.a&&(Jm(this.V.app,this.a),this.a=null);Im(this);Vc(Hm(this));this.g=this.b=null;delete this.V};
-function Lm(a){if(!a.a){var b;b=a.V.app;if(b.a.tb){var c=od(b.i),d=Ad(b.i);b.N=new Ab(c.x,c.y,d.width,d.height);Mm(b.j);Di(b.i,1);Ci(b.i);b=b.i}else b=Nm.getTag();a.a=b;$l(a.a,["video-stream","ad-video"])}return a.a};function Om(a,b,c,d){Z.call(this,["div",{className:"ytp-button",role:"button","aria-label":"{{label}}"},"{{content}}"]);this.g=a;this.a=this.i=null;K(this.element,"keypress",v(this.O,this));a=this.g;var e=v(this.N,this);a.a&&Pm(a.a,this.element,e);b&&Qm(this,b);c&&Rm(this,c);d&&(this.a=d)}y(Om,Z);function Qm(a,b){b&&""!=b&&(a.i&&W(a.element,a.i),a.i=b,V(a.element,b))}function Rm(a,b){xm(a.template,"label",b)}Om.prototype.N=function(){return this.a?Tc(this.a):null};
-Om.prototype.show=function(){var a=this.element;a&&(a.style.display="inline-block")};Om.prototype.O=function(a){if(13==a.keyCode||32==a.keyCode)Bf(this.element,"click"),a.preventDefault()};Om.prototype.F=function(){var a=this.g;if(a.a){var a=a.a,b=ja(this.element);Nf(a.a[b]);a.a[b]=null}this.g=null;Af(this.element);Om.C.F.call(this)};function Sm(a,b){Z.call(this,["canvas"]);this.element.width=a;this.element.height=b;this.width=a;this.height=b;this.X=this.element.getContext("2d");this.a=0;this.j=null}y(Sm,Z);Sm.prototype.g=function(a,b){I(this.a);this.a=Am(v(this.g,this,a,b),b);a.call(this,new Date-this.j)};Sm.prototype.F=function(){I(this.a);this.X=null;Sm.C.F.call(this)};function Tm(){Sm.call(this,84,84);this.b=this.width/2;this.o=this.height/2;this.i=Um}y(Tm,Sm);var Um=3*Math.PI/2,Vm=2*Math.PI;function Wm(a,b){var c=b*Vm+Um;a.X.beginPath();a.X.arc(a.b,a.o,40,a.i,c,!1);a.X.lineWidth=4;a.X.strokeStyle="#b8b8b8";a.X.stroke();a.i=c}
-Tm.prototype.show=function(){this.X.globalAlpha=0.8;this.X.beginPath();this.X.arc(this.b,this.o,42,0,Vm);this.X.fillStyle="#333";this.X.fill();var a=35*(Math.sqrt(3)/2);this.X.save();this.X.fillStyle="#fff";this.X.globalAlpha=0.9;this.X.translate(a,this.b);this.X.beginPath();this.X.lineTo(0,a/2);this.X.lineTo(28,0);this.X.lineTo(0,-a/2);this.X.closePath();this.X.fill();this.X.restore();Wm(this,0)};function Xm(a){var b=Math.floor(a/86400),c=Math.floor(a%86400/3600),d=Math.floor(a%3600/60);a=Math.floor(a%60);var e="";0<b&&(e+=b+":",10>c&&(e+="0"));0<c&&(e+=c+":",10>d&&(e+="0"));e+=d+":";10>a&&(e+="0");return e+a};var Ym={UC:"html5-stop-propagation",uA:"html5-chromeless",eC:"html5-live-dvr-disabled",fC:"html5-live-dvr-engaged",gC:"html5-live-playback",oC:"html5-mobile",qC:"modest-branding",sC:"html5-native-controls",ZC:"html5-tablet",YC:"html5-tablet-body",lC:"html5-main-video",jD:"html5-video-container",kD:"html5-video-content",lD:"html5-video-controls",mD:"ytp-fallback",nD:"ytp-fallback-content",pD:"html5-video-loader",uD:"html5-watermark",dA:"html5-branded-watermark",tD:"html5-viewport-sheet",AA:"html5-context-menu",
-Fr:"html5-context-menu-copy-debug-info",Gr:"html5-context-menu-copy-embed-html",Hr:"html5-context-menu-copy-video-url",Ir:"html5-context-menu-copy-video-url-at-current-time",Jr:"html5-context-menu-link",Kr:"html5-context-menu-report-playback-issue",Lr:"html5-context-menu-show-video-info",BA:"html5-show-video-info-template",pC:"html5-modal-panel",WB:"html5-info-bar",Yz:"autohide-off",Zz:"autohide-on",Xz:"autohide-fade",Vz:"autohide-auto",Wz:"autohide-embeds",$z:"autohide-seekbar",Uz:"autohide-aspect",
-KB:"hide-controls",LB:"hide-info-bar",MB:"html5-hide-share",NB:"html5-hide-volume",sD:"video-thumbnail",DC:"html5-popup-dialog",Oz:"html5-async-progress",Pz:"html5-async-success",Nz:"html5-async-error",pA:"html5-center-overlay",NC:"ytp-scalable-icon-shrink",MC:"ytp-scalable-icon-grow",RB:"house-brand"};function Zm(a,b){(a=Ic(a))&&a.style&&(a.style.display=b?"":"none",Dc(a,"hid",!b))}function $m(a){return(a=Ic(a))?!("none"==a.style.display||Cc(a,"hid")):!1}function an(a){z(arguments,function(a){Zm(a,!0)})}function bn(a){z(arguments,function(a){Zm(a,!1)})}function cn(a){var b=document.body;if(void 0!=b.style[a])return a;a=a.charAt(0).toUpperCase()+a.substr(1);for(var c=["Moz","Webkit","ms","O"],d=0;d<c.length;d++)if(void 0!=b.style[c[d]+a])return c[d]+a}
-function dn(a,b,c){(a=Ic(a))&&a.style&&(b=cn(b))&&(a.style[b]=c)};var en=window.location.protocol+"//i.ytimg.com/",fn=4/3;function gn(a,b,c){var d;switch(b.qd){case 30:d=hn;break;default:d=jn}return d(a,b,c)}function jn(a,b,c){if(!c){c=a.clientHeight;a=a.clientWidth;if((900<a||600<c)&&b.Io)return b.Io;if((430<a||320<c)&&b.Jo)return b.Jo}return b.Ji?b.Ji:b.L?kn(b.L):""}function hn(a,b){return b.Ji?b.Ji:b.L?S("//docs.google.com/vt",{id:b.L,authuser:b.Da,authkey:b.vo}):"//docs.google.com/images/doclist/cleardot.gif"}
-function kn(a,b){return(en+"vi/"+escape(a)+"/"+escape(b||"hqdefault.jpg")).replace("i.","i"+(a.charCodeAt(0)%ef("THUMBNAIL_NUM_SHARDS",1)+1)+".")};function ln(a,b,c){this.b=a;(a=b||null)||(a=mn(this.b));a="("+a.join("|")+")";a=sa("__%s__",a);this.g=RegExp(a,"g");this.a=c||{}}var nn=/__([a-z]+(?:_[a-z]+)*)__/g;function on(a,b){var c=Ic(a).innerHTML,c=c.replace(/^\s*(\x3c!--\s*)?/,""),c=c.replace(/(\s*--\x3e)?\s*$/,"");return new ln(c,b,void 0)}function mn(a){var b=[],c={};a.replace(nn,function(a,e){e in c||(c[e]=!0,b.push(e))});return b}
-function pn(a,b,c,d){var e=v(function(a,e){c&&(e=c(e));return d?b[e]||this.a[e]||"":va(b[e]||this.a[e]||"")},a);return a.b.replace(a.g,e)};function qn(a,b){this.V=a;this.G=b;var c=E("videowall-still-content-template",Q(this.V));this.B=on(c);c=Sc("a");c.tabIndex=0;V(c,"videowall-still");K(c,"click",v(this.yv,this));K(c,"keypress",v(this.zv,this));this.a=c;this.o=this.V.app.P.A}f=qn.prototype;
-f.update=function(a,b){this.g=a.feature_type||"endscreen";this.j=a.id||a.video_id;this.i=a.list;var c=!1,d=!1;a.endscreen_autoplay||("episodic"==this.g?d=!0:this.i&&(c=!0));var e=Jb(a);c||d?(e.index=parseInt(e.index,10)+1,e.title||(e.title=a.playlist_title,e.author=a.playlist_author),e.playlist_length||(e.playlist_length=0)):e.duration=Xm(a.length_seconds);var g=kn(c&&a.thumbnail_ids?a.thumbnail_ids.split(",")[0]:this.j,b?"hqdefault.jpg":"mqdefault.jpg");this.a.style.backgroundImage="url("+g+")";
-this.a.innerHTML=pn(this.B,e,void 0,!0);X(this.a,"videowall-still-featured",!!a.featured);X(this.a,"videowall-still-list",c);X(this.a,"videowall-still-episodic",d)};f.M=function(){return this.a};f.select=function(a){this.i?rn(this.V.app,this.j,a||this.g,this.i):rn(this.V.app,this.j,a||this.g)};f.Hu=function(){var a=new Date-this.A;1E4>a?(Wm(this.b,a/1E4),a=1E4-a,E("videowall-still-listlabel-autoplay-message",this.a).innerHTML=nf("AUTOPLAY_MESSAGE",Math.ceil(a/1E3))):(kf(this.k),this.select("autoplay"))};
-f.Iu=function(a){var b=ed(a.target,"videowall-still-listlabel-autoplay"),c=E("autoplay-play-canvas",this.a);V(b,"videowall-still-listlabel-autoplay-hide");V(c,"autoplay-play-canvas-hide");X(this.a,"videowall-still-autoplay",!1);a.stopPropagation();this.G.log({cancelButtonClick:"1"});kf(this.k)};f.yv=function(){this.select()};f.zv=function(a){switch(a.keyCode){case 13:case 32:this.select(),a.preventDefault()}};function sn(a,b,c){rm.call(this,a,b);this.kl=[];this.yb.D("onResize",this.$v,this);this.yb.D("videodatachange",this.aw,this);this.b=c}y(sn,rm);f=sn.prototype;f.Cl="videowall-endscreen";f.mh=null;f.pb=null;f.kl=null;f.ip=!1;f.nh=0;f.create=function(){sn.C.create.call(this);this.pb=this.a.getVideoData().Kc;tn(this)};f.destroy=function(){this.Uf.innerHTML="";delete this.pb;sn.C.destroy.call(this)};
-f.load=function(){if(this.pb&&this.pb.length&&this.pb[0].endscreen_autoplay){var a=un(this,0);a.b=new Tm;V(a.b.element,"autoplay-play-canvas");a.b.T(a.a);a.b.show();X(a.a,"videowall-still-autoplay",!0);var b=E("videowall-still-listlabel-autoplay",a.a),c=new Om(a.o);c.T(b);Qm(c,"videowall-still-listlabel-autoplay-cancel");c.Aa(a.o.getMsg("YTP_BUTTON_CANCEL"));c.show();K(c,"click",v(a.Iu,a));a.G.log({cancelButtonShow:"1"});a.A=new Date;a.k=jf(v(a.Hu,a),50)}};
-function tn(a){if(a.pb&&a.pb.length){X(a.Lf,"endscreen-enable-layout",!0);a.Uf.innerHTML="";var b=Ad(a.Lf);Zl(Q(a.a),"ad-showing")&&(b.height-=200);b.height-=30;var c=Math.floor(b.width/158),d=Math.floor(b.height/(158/1.45));if(1>d||1>c)a.nh=0;else{var e=a.pb.length,g=!1,h="episodic"==a.pb[0].feature_type,k=a.pb[0].endscreen_autoplay;(a.pb[0].featured||h||k)&&2<d&&2<c&&(g=!0,e+=3);X(a.Uf,"feature-video",g);for(var k=h=0,m=yb(b),p=!0;0<=e&&(h<c||k<d);){var s=e>=k,r=e>=h;if(p&&r||!s&&r)e-=h,k++;else if(s)e-=
-k,h++;else break;p=1.45*(h/k)>m}a.ip=p;c=new C(h,k);a.ip?(d=1/c.width,b=b.width*d,d=b/1.45):(d=1/c.height,d*=b.height,b=1.45*d);b=new C(Math.floor(b),Math.floor(d));a.nh=c.width*c.height;g&&(a.nh-=3);a.mh&&Fm(a.mh);g=vn(b);d={Ib:a.mh};a.mh=Em(".videowall-still",g,d);g=vn(b.clone().scale(2));d.Ib=a.mh;Em(".feature-video .videowall-still:first-child",g,d);yd(a.Uf,b.width*c.width,b.height*c.height)}g=0;for(b=a.nh;g<b;g++)c=un(a,g),a.Uf.appendChild(c.M());X(a.Lf,"endscreen-enable-layout",!1)}}
-function un(a,b){var c=a.kl[b];c||(c=new qn(a.a,a.b),a.kl[b]=c);c.update(a.pb[b],0==b&&a.pb[0].featured);return c}function vn(a){return["width:"+a.width+"px","height:"+a.height+"px"]}f.$v=function(){tn(this)};f.aw=function(){var a=this.a.getVideoData().Kc;this.pb!=a&&(this.pb=a,tn(this))};function wn(a){dm.call(this,a);a.J().xl?this.Tf=new Dm(this.a,this.G):a.J().qc?this.Tf=new sn(this.a,this.G,this):this.Tf=new rm(this.a,this.G)}y(wn,dm);f=wn.prototype;f.na="endscreen";f.kd="end";f.Tf=null;function xn(a){var b=a.J(),c=a.getVideoData();a=1==O(a.app).B;return yn(b)&&!Ml(c,"ypc_module")&&a}f.Xa=function(a){return xn(a)};
-f.create=function(){wn.C.create.call(this);var a=Math.max(1E3*(this.a.getVideoData().wa-10),0),a=new nh(a,2147483647,{id:"preload"}),b=new nh(2147483647,2147483647,{id:"load",priority:6});this.yf(a,b)};f.destroy=function(){em(this);this.Tf.destroy();wn.C.destroy.call(this)};f.load=function(){wn.C.load.call(this);this.Tf.load();this.Z=!0};f.unload=function(){wn.C.unload.call(this);this.Z=!1};f.vc=function(a){wn.C.vc.call(this,a);"preload"==a.getId()?this.Tf.create():zn(this.a.app)||this.load()};
-f.dd=function(a){"load"==a.getId()&&this.unload();wn.C.dd.call(this,a)};function An(a){return xn(a)?new wn(a):null};var Bn={created:1,ready:2,testing:4,"testing-starting":3,live:6,"live-starting":5,complete:8,"complete-starting":7};/*
- Portions of this code are from MochiKit, received by
- The Closure Authors under the MIT license. All other code is Copyright
- 2005-2009 The Closure Authors. All Rights Reserved.
-*/
-function Cn(a,b){this.o=[];this.N=a;this.K=b||null;this.k=this.g=!1;this.j=void 0;this.H=this.uv=this.A=!1;this.G=0;this.i=null;this.B=0}Cn.prototype.cancel=function(a){if(this.g)this.j instanceof Cn&&this.j.cancel();else{if(this.i){var b=this.i;delete this.i;a?b.cancel(a):(b.B--,0>=b.B&&b.cancel())}this.N?this.N.call(this.K,this):this.H=!0;this.g||this.a(new Dn)}};Cn.prototype.I=function(a,b){this.A=!1;En(this,a,b)};function En(a,b,c){a.g=!0;a.j=c;a.k=!b;Fn(a)}
-function Gn(a){if(a.g){if(!a.H)throw new Hn;a.H=!1}}Cn.prototype.b=function(a){Gn(this);En(this,!0,a)};Cn.prototype.a=function(a){Gn(this);En(this,!1,a)};function In(a,b,c,d){a.o.push([b,c,d]);a.g&&Fn(a);return a}function Jn(a){var b=new Cn;In(a,b.b,b.a,b);return b}function Kn(a){return Ka(a.o,function(a){return ha(a[1])})}
-function Fn(a){a.G&&a.g&&Kn(a)&&(l.clearTimeout(a.G),delete a.G);a.i&&(a.i.B--,delete a.i);for(var b=a.j,c=!1,d=!1;a.o.length&&!a.A;){var e=a.o.shift(),g=e[0],h=e[1],e=e[2];if(g=a.k?h:g)try{var k=g.call(e||a.K,b);q(k)&&(a.k=a.k&&(k==b||k instanceof Error),a.j=b=k);b instanceof Cn&&(d=!0,a.A=!0)}catch(m){b=m,a.k=!0,Kn(a)||(c=!0)}}a.j=b;d&&(In(b,v(a.I,a,!0),v(a.I,a,!1)),b.uv=!0);c&&(a.G=l.setTimeout(Ob(b),0))}function Hn(){ra.call(this)}y(Hn,ra);Hn.prototype.message="Deferred has already fired";
-Hn.prototype.name="AlreadyCalledError";function Dn(){ra.call(this)}y(Dn,ra);Dn.prototype.message="Deferred was canceled";Dn.prototype.name="CanceledError";function Ln(a,b){var c=b||{},d=c.document||document,e=Sc("SCRIPT"),g={Xo:e,oc:void 0},h=new Cn(Mn,g),k=null,m=null!=c.timeout?c.timeout:5E3;0<m&&(k=window.setTimeout(function(){Nn(e,!0);h.a(new On(1,"Timeout reached for loading script "+a))},m),g.oc=k);e.onload=e.onreadystatechange=function(){e.readyState&&"loaded"!=e.readyState&&"complete"!=e.readyState||(Nn(e,c.lv||!1,k),h.b(null))};e.onerror=function(){Nn(e,!0,k);h.a(new On(0,"Error while loading script "+a))};Lc(e,{type:"text/javascript",charset:"UTF-8",
-src:a});Pn(d).appendChild(e);return h}function Pn(a){var b=a.getElementsByTagName("HEAD");return!b||Ra(b)?a.documentElement:b[0]}function Mn(){if(this&&this.Xo){var a=this.Xo;a&&"SCRIPT"==a.tagName&&Nn(a,!0,this.oc)}}function Nn(a,b,c){null!=c&&l.clearTimeout(c);a.onload=ba;a.onerror=ba;a.onreadystatechange=ba;b&&window.setTimeout(function(){F(a)},0)}function On(a,b){var c="Jsloader error (code #"+a+")";b&&(c+=": "+b);ra.call(this,c);this.code=a}y(On,ra);function Qn(a,b){this.b=new pe(a);this.a=b?b:"callback";this.oc=5E3}var Rn=0;Qn.prototype.send=function(a,b,c,d){a=a||null;d=d||"_"+(Rn++).toString(36)+w().toString(36);l._callbacks_||(l._callbacks_={});var e=this.b.clone();if(a)for(var g in a)a.hasOwnProperty&&!a.hasOwnProperty(g)||Ee(e,g,a[g]);b&&(l._callbacks_[d]=Sn(d,b),Ee(e,this.a,"_callbacks_."+d));b=Ln(e.toString(),{timeout:this.oc,lv:!0});In(b,null,Tn(d,a,c),void 0);return{Ba:d,ic:b}};
-Qn.prototype.cancel=function(a){a&&(a.ic&&a.ic.cancel(),a.Ba&&Un(a.Ba,!1))};function Tn(a,b,c){return function(){Un(a,!1);c&&c(b)}}function Sn(a,b){return function(c){Un(a,!0);b.apply(void 0,arguments)}}function Un(a,b){l._callbacks_[a]&&(b?delete l._callbacks_[a]:l._callbacks_[a]=ba)};function Vn(a){R.call(this);this.g=pn(new ln("http://gdata.youtube.com/feeds/api/users/live/broadcasts/__video_id__/states?v=2&alt=json-in-script"),{video_id:a});this.a=new Uh(15E3+Math.floor(3E4*Math.random()));this.a.addEventListener("tick",v(this.b,this));this.b();this.a.start()}y(Vn,R);Vn.prototype.F=function(){this.a.dispose();Vn.C.F.call(this)};Vn.prototype.b=function(){(new Qn(this.g)).send(null,v(this.j,this),v(this.i,this))};
-Vn.prototype.j=function(a){this.u("payload",a);Vh(this.a,15E3+Math.floor(3E4*Math.random()))};Vn.prototype.i=function(){this.u("error");var a=this.a.a;192E4>a&&Vh(this.a,2*a)};function Wn(){this.g=new sm(["div","html5-fresca-module",["div","html5-fresca-band-slate",["hgroup","html5-fresca-message",["h2","html5-fresca-heading","{{heading}}"],["h3","html5-fresca-subheading","{{subheading}}"],["h4","html5-fresca-long-test","{{long_text}}"]],["span","html5-fresca-countdown","{{countdown}}"]]]);L(this,this.g);this.b=this.g.a["html5-fresca-module"];V(this.b,"html5-stop-propagation");this.i=0;this.a=null}y(Wn,Lf);Wn.prototype.M=function(){return this.b};
-Wn.prototype.update=function(a){if(!this.k||this.a.state!=a.state||this.a.startTime!=a.startTime||this.a.b!=a.b||this.a.a.join()!=a.a.join()){this.a=a;this.b.style.backgroundImage=this.a.b||"none";a=this.a.a;if(!a.length){t:switch(this.a.state){case 6:a="";break t;case 8:case 7:a=J("FRESCA_COMPLETE_MESSAGE");break t;default:a=J("FRESCA_STAND_BY_MESSAGE")}a=[a]}this.g.update({heading:a[0]||"",subheading:a[1]||"",long_text:a[2]||""});this.j()}};
-function Xn(a){var b=Math.floor((new Date).valueOf()/1E3);return b>a?J("FRESCA_STARTING_SOON_MESSAGE"):Xm(a-b)}Wn.prototype.j=function(){var a;a=this.a;a.startTime?(a=a.state,a=6==a||8==a||7==a?!1:!0):a=!1;X(this.b,"html5-fresca-show-countdown",a);a&&(this.g.update({countdown:Xn(this.a.startTime)}),I(this.i),this.i=H(v(this.j,this),1E3))};Wn.prototype.F=function(){I(this.i);this.b=null;Wn.C.F.call(this)};function Yn(a){this.a=[];a&&Zn(this,a)}Yn.prototype.state=-1;function Zn(a,b){var c=b.feed;if(c){var d=c.yt$lifeCycleState;d&&(a.state=Bn[d.$t]||-1);(d=c.yt$when)&&d.start&&(d=new Date(d.start),a.startTime=Math.floor(d.valueOf()/1E3));if(c=c.yt$slate)c.imgUrl&&(a.b="url("+c.imgUrl+")"),(c=c.content)&&c.length&&(c=c.splice(0,3),a.a=Ja(c,function(a){return a.$t}))}};function $n(a){dm.call(this,a)}y($n,dm);f=$n.prototype;f.na="fresca";f.kd="fresca";f.fi=!1;f.Lg=!1;f.Xa=function(){return Ml(this.a.getVideoData(),"fresca_module")};f.create=function(a){$n.C.create.call(this);this.fi=this.Lg=!1;nm(this,["play_pause","seek"]);this.i=new Wn;this.a.app.P.g.appendChild(this.i.M());this.g=a||new Vn(this.a.getVideoData().L);this.g.D("payload",this.Vu,this);this.g.D("error",this.Uu,this);this.D("onStateChange",this.Ao,this)};
-f.destroy=function(){this.Z&&this.unload();this.W("onStateChange",this.Ao,this);Of(this.g,this.i);$n.C.destroy.call(this)};f.load=function(){$n.C.load.call(this);this.Z=!0};f.unload=function(){this.Z=!1;$n.C.unload.call(this)};f.Ao=function(a){this.b&&(this.fi=P(a.state,2),(ao(a,16)||this.fi)&&bo(this,this.b))};f.Uu=function(){this.Lg||(this.b=new Yn,bo(this,this.b))};f.Vu=function(a){this.b=new Yn(a);6!=this.b.state||this.a.getVideoData().O.length?bo(this,this.b):this.a.Uj(this.a.getVideoData().L)};
-function bo(a,b){var c=6>b.state;!c&&a.a.app.b.ca&&(b.b||b.a.length)&&(c=!0);a.fi&&!a.a.J().qc&&(c=!0);if(!a.Lg)switch(b.state){case 6:a.Lg=!0;nm(a,["play_pause","seek"]);fm(a);break;case 8:case 7:c=a.Lg=!0}c&&a.i.update(b);c&&!a.Z?a.load():!c&&a.Z&&a.unload()}function co(a){return Ml(a.getVideoData(),"fresca_module")?new $n(a):null};function eo(a){this.Kg=a||window;this.ee=[]}f=eo.prototype;f.Kg=null;f.ee=null;f.listen=function(a,b,c,d){c=v(c,d||this.Kg);a=K(a,b,c);this.ee.push(a);return a};function fo(a,b,c,d){d=v(d,a.Kg);b=wf(b,c,d);a.ee.push(b);return b}function go(a,b,c){c=v(c,a.Kg);b=zf(b,c,"yt-uix-button-menu-item");a.ee.push(b)}f.Vc=function(a){vf(a);Ua(this.ee,a)};f.removeAll=function(){vf(this.ee);this.ee=[]};function ho(a,b,c){this.a=a;this.i=b||0;this.b=c;this.g=v(this.iu,this)}y(ho,Lf);f=ho.prototype;f.Ba=0;f.F=function(){ho.C.F.call(this);this.stop();delete this.a;delete this.b};f.start=function(a){this.stop();this.Ba=Wh(this.g,q(a)?a:this.i)};f.stop=function(){0!=this.Ba&&l.clearTimeout(this.Ba);this.Ba=0};f.iu=function(){this.Ba=0;this.a&&this.a.call(this.b)};var io={},jo=null;function ko(a){a=ja(a);delete io[a];Ib(io)&&jo&&jo.stop()}function lo(){jo||(jo=new ho(function(){mo()},20));var a=jo;0!=a.Ba||a.start()}function mo(){var a=w();Cb(io,function(b){no(b,a)});Ib(io)||lo()};function oo(){Rh.call(this);this.a=0;this.k=this.startTime=null}y(oo,Rh);f=oo.prototype;f.rk=function(){this.Gd("begin")};f.Ni=function(){this.Gd("end")};f.td=function(){this.Gd("finish")};f.onStop=function(){this.Gd("stop")};f.Gd=function(a){Sh(this,a)};function po(a,b,c,d){oo.call(this);if(!t(a)||!t(b))throw Error("Start and end parameters must be arrays");if(a.length!=b.length)throw Error("Start and end points must be the same length");this.g=a;this.o=b;this.duration=c;this.j=d;this.b=[]}y(po,oo);f=po.prototype;f.gd=0;
-function qo(a){if(0==a.a)a.gd=0,a.b=a.g;else if(1==a.a)return;ko(a);var b=w();a.startTime=b;-1==a.a&&(a.startTime-=a.duration*a.gd);a.k=a.startTime+a.duration;a.gd||a.rk();a.Gd("play");-1==a.a&&a.Gd("resume");a.a=1;var c=ja(a);c in io||(io[c]=a);lo();no(a,b)}f.stop=function(a){ko(this);this.a=0;a&&(this.gd=1);ro(this,this.gd);this.onStop();this.Ni()};f.F=function(){0==this.a||this.stop(!1);this.Gd("destroy");po.C.F.call(this)};f.destroy=function(){this.dispose()};
-function no(a,b){a.gd=(b-a.startTime)/(a.k-a.startTime);1<=a.gd&&(a.gd=1);ro(a,a.gd);1==a.gd?(a.a=0,ko(a),a.td(),a.Ni()):1==a.a&&a.pl()}function ro(a,b){ha(a.j)&&(b=a.j(b));a.b=Array(a.g.length);for(var c=0;c<a.g.length;c++)a.b[c]=(a.o[c]-a.g[c])*b+a.g[c]}f.pl=function(){this.Gd("animate")};f.Gd=function(a){Sh(this,new so(a,this))};function so(a,b){ph.call(this,a);this.x=b.b[0];this.y=b.b[1];this.duration=b.duration;this.state=b.a}y(so,ph);var to=/#(.)(.)(.)/;function uo(a){if(!vo.test(a))throw Error("'"+a+"' is not a valid hex color");4==a.length&&(a=a.replace(to,"#$1$1$2$2$3$3"));a=a.toLowerCase();return[parseInt(a.substr(1,2),16),parseInt(a.substr(3,2),16),parseInt(a.substr(5,2),16)]}var vo=/^#(?:[0-9a-f]{3}){1,2}$/i;function wo(a,b,c,d,e){po.call(this,b,c,d,e);this.element=a}y(wo,po);wo.prototype.i=ba;wo.prototype.pl=function(){this.i();wo.C.pl.call(this)};wo.prototype.Ni=function(){this.i();wo.C.Ni.call(this)};wo.prototype.rk=function(){this.i();wo.C.rk.call(this)};function xo(a,b,c,d,e){if(2!=b.length||2!=c.length)throw Error("Start and end points must be 2D");wo.apply(this,arguments)}y(xo,wo);
-xo.prototype.i=function(){this.element.style.left=Math.round(this.b[0])+"px";this.element.style.top=Math.round(this.b[1])+"px"};function yo(a){return a*a*a}function zo(a){return 1-Math.pow(1-a,3)};function Ao(a,b,c,d,e){this.ob=a;this.element=b;this.g=c;this.j=d;this.uk=e;this.xc=this.a=!1}function Bo(a,b){var c=Pc("div","annotation-x-button-container"),d=Pc("div","annotation-x-button");c.appendChild(d);a.g.listen(c,"click",v(function(a){var c=this.uk,d=this.ob;d&&d.i&&c.log_(Co(c,d,4));b(a);a.stopPropagation();this.xc=!0},a));return c}f=Ao.prototype;f.M=function(){return this.element};f.show=function(){};f.hide=function(){};f.destroy=function(){F(this.element)};
-f.Oo=function(){var a=this.j.ug,b=this.j.Sc,c=Ad(this.element),d=b.height-a.top,e=c.width<b.width&&c.height<b.height;md(this.element,a.width-b.width+a.left,this.a&&e?d-c.height:d)};function Do(a,b,c,d,e){Ao.call(this,a,b,c,d,e);this.b=Pc("div","invideo-video-text-container");this.i=!1}y(Do,Ao);function Eo(a){var b=new xo(a.element,[a.element.offsetLeft,a.element.offsetTop],[a.element.offsetLeft,a.element.offsetTop-a.element.offsetHeight],300,zo);Gh(b,"begin",v(function(){this.a=!0},a));qo(b)}
-function Fo(a){var b=new xo(a.element,[a.element.offsetLeft,a.element.offsetTop],[a.element.offsetLeft,a.element.offsetTop+a.element.offsetHeight+4],300,yo);Gh(b,"end",v(function(){this.a=!1;bn(this.element)},a));qo(b)}
-function Go(a){yd(a.element,444,56);var b=a.ob.data,c={src:b.image_url,"class":"invideo-video-img"},d=Pc("div","invideo-video-img-container"),c=Pc("img",c);yd(c,100,56);d.appendChild(c);a.element.appendChild(d);yd(a.b,244,56);d=Pc("span","iv-subtitle-text");Zc(d,b.text_line_1);a.b.appendChild(d);d=Pc("span","iv-title-text");Zc(d,b.text_line_2);a.b.appendChild(d);a.element.appendChild(a.b);b=Bo(a,v(function(){Fo(this)},a));a.element.appendChild(b);a.g.listen(a.element,"click",v(function(){var a=Ho(this.ob);
-Io(this.uk,this.ob);window.open(a.value)},a))}Do.prototype.show=function(){if(!this.a){this.i||(Go(this),this.i=!0);this.Oo();an(this.element);var a=this.uk,b=this.ob;b&&b.i&&a.log_(Co(a,b,2));Eo(this)}};Do.prototype.hide=function(){this.a&&Fo(this)};function Jo(a,b,c){Z.call(this,["div","ytp-segmented-control"]);this.g=a;this.b=-1;this.a=[];q(b)&&Ko(this,b,c)}y(Jo,Z);function Ko(a,b,c){Of(a.a);a.a=[];for(var d=0;d<b.length;d++){var e=new Om(a.g);a.a[d]=e;c?e.Aa(["div",b[d]]):e.Aa(b[d]);0!=d&&V(e.M(),"ytp-segmented-control-other");Lo(e,d==a.b);K(e,"click",v(a.i,a));e.T(a.element)}}
-Jo.prototype.T=function(a,b){Jo.C.T.call(this,a,b);for(var c=0,d=0;d<this.a.length;d++)c=Math.max(c,Ad(this.a[d].M()).width);if(c)for(d=0;d<this.a.length;d++)zd(this.a[d].M(),c)};function Mo(a,b){a.b=b;for(var c=0;c<a.a.length;c++)Lo(a.a[c],c==b)}Jo.prototype.getSelected=function(){return this.b};
-function Lo(a,b){if(b){var c=a.M();W(c,"ytp-segmented-control-deselected");V(c,"ytp-segmented-control-selected")}else c=a.M(),W(c,"ytp-segmented-control-selected"),V(c,"ytp-segmented-control-deselected")}Jo.prototype.i=function(a){for(var b=0;b<this.a.length;b++)if(this.a[b]==a.currentTarget){var c=!1;this.b!=b?(c=!0,Mo(this,b)):2==this.a.length&&(c=!0,Mo(this,0==b?1:0));if(c){Bf(this.element,"change");break}}};Jo.prototype.F=function(){Ko(this,[]);this.g=null;Jo.C.F.call(this)};function No(a,b){return null!=b&&!!b.match(a)}function Oo(a,b){for(var c in a)if(a[c]==b)return!0;return!1}function Po(a,b,c,d){var e=new Qo;e.type=c;e.defaultValue=d;e.b=oa(No,/.+/);return Ro(a[b],e)}function So(a,b,c){var d=new Qo;d.type="OPTIONAL";d.a=function(a){if(isNaN(parseInt(a,0)))return null;a=parseInt(a,0).toString(16);return"#"+"000000".substring(0,6-a.length)+a};d.b=function(a){return!!a};d.defaultValue=c;return Ro(a[b],d)}
-function To(a,b,c,d){var e=new Qo;e.type=c;e.defaultValue=d;return Ro(a[b],e)}function Uo(a,b,c,d,e){var g=new Qo;g.type=d;g.defaultValue=e;g.b=oa(Oo,c);return Ro(a[b],g)}function Vo(a,b,c){var d=new Qo;d.type="OPTIONAL";d.defaultValue=c;d.b=function(a){return!0==a||!1==a};d.a=function(a){return"true"==a||"false"==a?"true"==a:a};return Ro(a[b],d)}function Wo(a,b,c){var d=new Qo;d.type="OPTIONAL";d.defaultValue=c;d.a=function(a){return parseFloat(a)};return Ro(a[b],d)}
-function Xo(a){var b=new Qo;b.type="OPTIONAL";b.defaultValue=0;b.a=function(a){return parseInt(a,10)};return Ro(a.d,b)}function Yo(a,b,c,d,e,g,h){var k=new Qo;k.type="OPTIONAL";k.a=function(a){a=10==c?parseFloat(a):parseInt(a,c);return g&&null!=a&&!isNaN(a)?tb(a,d,e):a};k.defaultValue=h;k.b=function(a){return null!=a&&!isNaN(a)&&a>=d&&a<=e};return Ro(a[b],k)}
-function Zo(a,b){var c=new Qo;c.type="OPTIONAL";c.defaultValue=0;c.a=function(a){if("never"==a)return-1;a=a.split(":");if(3<a.length)return null;var b=0,c=1;z(a,function(a){a=parseFloat(a);0>a&&(c=-c);b=60*b+Math.abs(a)});return c*b};return Ro(a[b],c)}function $o(a,b){return null==b?null:a(b)}function ap(a,b,c,d,e){if(null==a||null==a[b])return null;var g=new Qo;g.type=d;g.defaultValue=e;g.b=function(a){return!!a};g.a=oa($o,c);return Ro(a[b],g)}
-function Ro(a,b){var c;if("OPTIONAL"==b.type||"REQUIRED"==b.type){if(c=null==a?null:b.a(t(a)&&a.length?a[0]:a),!b.b(c)){if("REQUIRED"==b.type)throw"Required field missing.";c=null==b.defaultValue?null:b.defaultValue}}else c="REPEATED"==b.type?null!=a?bp(t(a)?a:[a],b):null!=b.defaultValue?t(b.defaultValue)?b.defaultValue:[b.defaultValue]:[]:"IDLIST"==b.type?cp(a,b):null;return c}
-function cp(a,b){function c(a){return Ia(a.split(/ +/),function(a){return""!=a})}return null!=a?bp(c(a),b):null!=b.defaultValue?t(b.defaultValue)?b.defaultValue:[b.defaultValue]:[]}function bp(a,b){for(var c=[],d=0;d<a.length;++d){var e=b.a(a[d]);b.b(e)&&c.push(e)}return c.length?c:null!=b.defaultValue?t(b.defaultValue)?b.defaultValue:[b.defaultValue]:[]}function Qo(){this.a=dp;this.b=ep}Qo.prototype.type="OPTIONAL";Qo.prototype.defaultValue=null;function dp(a){return null==a?null:a.toString()}
-function ep(a){return null!=a};function fp(a){this.value=a}function gp(a){a=Zo(a,"value");return new fp(a)};function hp(){}function ip(a){var b=To(a,"external_user_id","OPTIONAL");a=To(a,"subscription_token","OPTIONAL");return b&&a?new hp:null};function jp(a,b,c,d){this.value=a;this.target=b;this.a=c;this.b=d}var kp={DA:"current",tC:"new"};function lp(a){var b=To(a,"value","OPTIONAL");if(null==b||null==Vi(b))return null;var c=Uo(a,"target",kp,"OPTIONAL","current");if(null==c)return null;Vo(a,"trusted",!1);var d=To(a,"link_class","OPTIONAL","");a=Vo(a,"show_link_icon",!0);return new jp(b,c,d,a)}function mp(a){return a.value?a.value:null};function np(a,b,c,d){this.type=a;this.trigger=b;this.url=c;this.duration=d}var op={ny:"close",kC:"log",xC:"openUrl",PAUSE:"pause",ry:"subscribe"},pp={CLICK:"click",ny:"close",oy:"hidden",LC:"rollOut",py:"rollOver",qy:"shown"};function qp(a){var b=Uo(a,"type",op,"OPTIONAL"),c=Uo(a,"trigger",pp,"OPTIONAL"),d=ap(a,"url",lp,"OPTIONAL");ap(a,"subscribeData",ip,"OPTIONAL");a=ap(a,"duration",gp,"OPTIONAL");return b?new np(b,c,d,a):null};function rp(a,b,c,d,e,g,h,k,m,p,s,r,x,M){this.k=a;this.j=b;this.o=c;this.G=d;this.a=e;this.H=g;this.i=h;this.textAlign=k;this.I=m;this.A=p;this.padding=s;this.b=r;this.g=x;this.B=M}
-function sp(a){var b=So(a,"fgColor","#1A1A1A"),c=So(a,"bgColor","#FFF"),d=So(a,"borderColor","#000"),e=Yo(a,"borderWidth",10,0,5,!1,0),g=Yo(a,"bgAlpha",10,0,1,!1,0.8);Yo(a,"borderAlpha",10,0,1,!1,0.2);Yo(a,"gloss",16,0,255,!1,0);var h=So(a,"highlightFontColor","#F2F2F2"),k=Yo(a,"highlightWidth",10,0,5,!1,3),m=To(a,"textAlign","OPTIONAL",""),p=Yo(a,"textSize",10,3.3,30.1,!0,3.6107),s=To(a,"fontWeight","OPTIONAL",""),r;r=(r=a?a.padding&&a.padding.length?a.padding[0]:a.padding:null)?new wb(parseFloat(r.top),
-parseFloat(r.right),parseFloat(r.bottom),parseFloat(r.left)):null;r=!r||null==r.top||isNaN(r.top)||null==r.right||isNaN(r.right)||null==r.bottom||isNaN(r.bottom)||null==r.left||isNaN(r.left)?null:r;var x=To(a,"effects","IDLIST"),M=Yo(a,"cornerRadius",10,0,10,!0,0);a=ap(a,"gradient",tp,"OPTIONAL");return new rp(b,c,d,e,g,h,k,m,p,s,r,x,M,a)}function up(a,b,c,d,e,g,h,k){this.j=a;this.o=b;this.k=c;this.G=d;this.a=e;this.b=g;this.g=h;this.i=k}
-function tp(a){var b=Yo(a,"x1",10,0,100,!0,0),c=Yo(a,"y1",10,0,100,!0,0),d=Yo(a,"x2",10,0,100,!0,100),e=Yo(a,"y2",10,0,100,!0,100),g=So(a,"color1","#FFF"),h=So(a,"color2","#000"),k=Yo(a,"opacity1",10,0,100,!0,100);a=Yo(a,"opacity2",10,0,100,!0,0);return new up(b,c,d,e,g,h,k,a)};function vp(a,b){this.a=a;this.L=b}function wp(a){var b=To(a,"standard_url","OPTIONAL","");To(a,"rollover_url","OPTIONAL","");To(a,"click_url","OPTIONAL","");a=To(a,"video_id","OPTIONAL","");return new vp(b,a)};function xp(a,b,c){var d=a.G,e=a.A,g=a.a?a.a:"xy",h=yp(c,a.j,g);a=zp(c,a.g,g);var g=640*b.width*h/100,k=360*b.height*a/100;return new Ab(0==d?640*b.left*h/100:0<d?d:c.width+d-g,0==e?360*b.top*a/100:0<e?e:c.height+e-k,g,k)}function yp(a,b,c){var d=(c="xx"==c||"xy"==c)?640:360;return(d+((c?a.width:a.height)-d)*b)/d}function zp(a,b,c){var d=(c="xy"==c||"yy"==c)?360:640;return(d+((c?a.height:a.width)-d)*b)/d};function Ap(a,b,c,d,e,g,h,k,m,p,s){this.x=a;this.y=b;this.k=c;this.i=d;this.b=e;this.o=g;this.G=h;this.A=k;this.j=m;this.g=p;this.a=s}function Bp(a,b){var c=Wo(a,"x",0),d=Wo(a,"y",0),e=Wo(a,"w",0),g=Wo(a,"h",0),h=Zo(a,"t"),k=Xo(a),m=Wo(a,"px",0),p=Wo(a,"py",0),s=Wo(a,"scaleSlope",1),r=Wo(a,"scaleSlopeX",s),s=Wo(a,"scaleSlopeY",s),x=To(a,"scaleDimension","OPTIONAL","xy");return b(c,d,e,g,h,k,m,p,r,s,x)}
-function Cp(a,b,c){c=c?Cp(c,b):null;a=xp(a,new Ab(a.x,a.y,a.k,a.i),b);c?(a.top+=c.top,a.left+=c.left):(a.top+=b.top,a.left+=b.left);c=a.clone();b&&!b.contains(a)&&(a.width<b.width?c.left=tb(a.left,b.left,b.left+b.width-a.width):(c.left=b.left,c.width=b.width),a.height<b.height?c.top=tb(a.top,b.top,b.top+b.height-a.height):(c.top=b.top,c.height=b.height));return c}function Dp(a){return Bp(a,function(a,c,d,e,g,h,k,m,p,s,r){return new Ap(a,c,d,e,g,h,k,m,p,s,r)})};function Ep(a,b,c,d,e,g,h,k,m,p,s,r,x){Ap.call(this,a,b,c,d,e,k,m,p,s,r,x);this.B=g;this.H=h}y(Ep,Ap);function Fp(a){var b=Wo(a,"sx",0),c=Wo(a,"sy",0);return Bp(a,function(a,e,g,h,k,m,p,s,r,x,M){return new Ep(a,e,g,h,k,b,c,m,p,s,r,x,M)})};function Gp(a,b,c){this.type=a;this.b=b;this.a=c}var Hp={ly:"anchored",HC:"rect"};function Ip(a){var b=Uo(a,"type",Hp,"OPTIONAL","rect"),c=ap(a,"rectRegion",Dp,"REPEATED");a=ap(a,"anchoredRegion",Fp,"REPEATED");return new Gp(b,c,a)}function Jp(a){return a.b&&a.b.length?a.b[0]:a.a&&a.a.length?a.a[0]:null};function Kp(a,b){this.b=a;this.a=b}function Lp(a){Po(a,"timeRelative","OPTIONAL");var b=Po(a,"spaceRelative","OPTIONAL");return(a=ap(a,"movingRegion",Ip,"REPEATED"))?new Kp(b,a):null};function Mp(a,b){this.state=a;this.a=b}var Np={AC:"playerControlShow",py:"rollOver",qy:"shown"};function Op(a){var b=Uo(a,"state",Np,"OPTIONAL");a=Po(a,"ref","OPTIONAL","");return b?new Mp(b,a):null};function Pp(a,b,c,d){this.a=a||[];this.g=b||[];this.i=c;this.b=d}function Qp(a){var b=ap(a,"condition",Op,"REPEATED"),c=ap(a,"notCondition",Op,"REPEATED"),d=Vo(a,"show_delay",!1);a=Vo(a,"hide_delay",!1);return b||c?new Pp(b,c,d,a):null}function Rp(a,b,c){z(a.a,oa(b,!1),c);z(a.g,oa(b,!0),c)};function Sp(a,b,c,d,e,g,h,k,m,p,s,r,x,M,ta,Y){this.id=a;this.author=b;this.type=c;this.style=d;this.o=e;this.a=g;this.g=h||[];this.B=k||[];this.b=m;this.H=p;this.j=s;this.G=r;this.i=x;this.k=M;this.data=ta;this.A=Y}var Tp={ly:"anchored",sA:"channel",PB:"highlightText",bC:"label",CC:"popup",RC:"speech",ry:"subscribe",bD:"title",VIDEO:"video"},Up={EA:"custom",OB:"highlight",IMAGE:"image",PAUSE:"pause",TEXT:"text",MD:"widget"},Vp={rD:"video_relative",BC:"player_relative"};
-function Wp(a){var b=Po(a,"id","REQUIRED"),c=Po(a,"author","OPTIONAL"),d=Uo(a,"type",Up,"REQUIRED"),e=Uo(a,"style",Tp,"OPTIONAL"),g=To(a,"TEXT","OPTIONAL"),h=ap(a,"data",function(a){return 0!=a.length?kb(a):{}},"OPTIONAL",{}),k=ap(a,"segment",Lp,"OPTIONAL"),m=ap(a,"action",qp,"REPEATED"),p=ap(a,"trigger",Qp,"REPEATED"),s=ap(a,"appearance",sp,"OPTIONAL");s||(s=sp({}));var r=Uo(a,"coordinate_system",Vp,"OPTIONAL","video_relative"),x=ap(a,"image_source",wp,"OPTIONAL"),M=Vo(a,"closeable",!0),ta=Vo(a,
-"logable",!0),Y=To(a,"html_blob","OPTIONAL","");a=To(a,"log_data","OPTIONAL","");return b&&d?new Sp(b,c,d,e,g,k,m,p,s,r,x,M,ta,Y,h,a):null}function Ho(a){return(a=Na(a.g,function(a){return null!=a.url},void 0))?a.url:null}function Xp(a){return Ka(a.g,function(a){return null!=a.url&&a.url.b},void 0)}function Yp(a){return Ka(a.g,function(a){return"click"==a.trigger},void 0)}function Zp(a,b,c){z(a.g,b,c)}function $p(a,b,c){z(a.B,b,c)}function aq(a,b){Ja(a.B,b,void 0)}
-function bq(a){return(a=a.a?a.a.a.length?a.a.a[0]:null:null)?Jp(a):null}function cq(a,b){var c=bq(a);return c&&b?yp(b,c.j,c.a?c.a:"xy"):1}function dq(a,b){var c=bq(a);return c&&b?zp(b,c.g,c.a?c.a:"xy"):1};function eq(a,b,c){this.a={};this.b=!1;this.j="ivTrigger:"+a;this.g=c;Rp(b,function(a,b){var c=fq(b.state,b.a);this.g.D(c,v(this.i,this,c,a));this.a[c]=!1},this)}eq.prototype.i=function(a,b,c,d){this.a[a]=b?!c:c;a=Db(this.a,function(a){return a});this.b!=a&&(this.b=a,this.g.u(this.j,a,d))};function fq(a,b){var c="ivTriggerCondition:"+a;return b?c+":"+b:c};function gq(a,b,c){this.i=a;this.ob=b;this.b=c;this.a=null;this.xc=this.isVisible=!1;hq(b,a)}function hq(a,b){aq(a,function(c){return new eq(a.id,c,b)})}gq.prototype.hide=function(){this.isVisible=!1;this.i.W("onResize",this.g,this);this.b.hide()};gq.prototype.show=function(){this.isVisible=!0;this.b.show();this.i.D("onResize",this.g,this)};gq.prototype.destroy=function(){this.i.W("onResize",this.g,this);var a=this.b;a.i.removeAll();a.la&&F(a.la);a.Ea&&a.Ea.M()&&F(a.Ea.M());iq(this)};
-function iq(a){a.a&&(a.a.stop(),a.a=null)}gq.prototype.g=function(){jq(this.b)};function kq(){};function lq(a,b,c,d,e,g,h,k){this.j=a;this.o=b;this.k=c;this.G=d;this.a=e;this.b=g;this.g=q(h)?h:null;this.i=q(k)?k:null}y(lq,kq);function mq(){this.Rb=[];this.Q=[];this.Md=[]}mq.prototype.Zf=null;mq.prototype.md=null;mq.prototype.aj=!0;var nq=[2,2,6,6,0];f=mq.prototype;f.clear=function(){this.Rb.length=0;this.Q.length=0;this.Md.length=0;delete this.Zf;delete this.md;delete this.aj;return this};function oq(a,b,c){0==Fa(a.Rb)?a.Md.length-=2:(a.Rb.push(0),a.Q.push(1));a.Md.push(b,c);a.md=a.Zf=[b,c]}
-f.Fa=function(a){var b=Fa(this.Rb);if(null==b)throw Error("Path cannot start with lineTo");1!=b&&(this.Rb.push(1),this.Q.push(0));for(b=0;b<arguments.length;b+=2){var c=arguments[b],d=arguments[b+1];this.Md.push(c,d)}this.Q[this.Q.length-1]+=b/2;this.md=[c,d]};f.close=function(){var a=Fa(this.Rb);if(null==a)throw Error("Path cannot start with close");4!=a&&(this.Rb.push(4),this.Q.push(1),this.md=this.Zf);return this};
-function pq(a,b,c,d,e){var g=a.md[0]-b*Math.cos(d*Math.PI/180),h=a.md[1]-c*Math.sin(d*Math.PI/180),g=g+b*Math.cos((d+e)*Math.PI/180),h=h+c*Math.sin((d+e)*Math.PI/180);a.Rb.push(3);a.Q.push(1);a.Md.push(b,c,d,e,g,h);a.aj=!1;a.md=[g,h]}function qq(a,b){for(var c=a.Md,d=0,e=0,g=a.Rb.length;e<g;e++){var h=a.Rb[e],k=nq[h]*a.Q[e];b(h,c.slice(d,d+k));d+=k}}
-f.clone=function(){var a=new this.constructor;a.Rb=this.Rb.concat();a.Q=this.Q.concat();a.Md=this.Md.concat();a.Zf=this.Zf&&this.Zf.concat();a.md=this.md&&this.md.concat();a.aj=this.aj;return a};f.isEmpty=function(){return 0==this.Rb.length};function rq(a,b){this.A=a;this.B=null==b?1:b}y(rq,kq);function sq(a,b){this.a=a;this.b=b};function tq(a){this.b=a;this.a={}}y(tq,Lf);var uq=[];f=tq.prototype;f.listen=function(a,b,c,d,e){t(b)||(uq[0]=b,b=uq);for(var g=0;g<b.length;g++){var h=Gh(a,b[g],c||this,d||!1,e||this.b||this);if(!h)break;this.a[h.key]=h}return this};f.Vc=function(a,b,c,d,e){if(t(b))for(var g=0;g<b.length;g++)this.Vc(a,b[g],c,d,e);else e=e||this.b||this,c=Hh(c||this),d=!!d,b=vh(a)?Ch(a.jd,b,c,d,e):a?(a=Lh(a))?Ch(a,b,c,d,e):null:null,b&&(Mh(b),delete this.a[b.key]);return this};
-f.removeAll=function(){Cb(this.a,Mh);this.a={}};f.F=function(){tq.C.F.call(this);this.removeAll()};f.handleEvent=function(){throw Error("EventHandler.handleEvent not implemented");};function vq(){}ca(vq);vq.prototype.a=0;vq.getInstance();function wq(a){Rh.call(this);this.o=a||Fc()}y(wq,Rh);f=wq.prototype;f.Mv=vq.getInstance();f.Ba=null;f.Ye=!1;f.Of=null;f.Kl=null;f.getId=function(){return this.Ba||(this.Ba=":"+(this.Mv.a++).toString(36))};f.M=function(){return this.Of};f.Op=function(){this.Of=this.o.createElement("div")};f.Ti=function(){xq(this,function(a){a.Ye&&a.Ti()});this.j&&this.j.removeAll();this.Ye=!1};
-f.F=function(){this.Ye&&this.Ti();this.j&&(this.j.dispose(),delete this.j);xq(this,function(a){a.dispose()});this.Of&&F(this.Of);this.Of=this.Kl=null;wq.C.F.call(this)};function xq(a,b){a.Kl&&z(a.Kl,b,void 0)};function yq(a,b,c,d,e){wq.call(this,e);this.width=a;this.height=b;this.g=c||null;this.k=d||null}y(yq,wq);yq.prototype.b=null;yq.prototype.kh=function(){return this.Ye?Ad(this.M()):ga(this.width)&&ga(this.height)?new C(this.width,this.height):null};function zq(a){var b=a.kh();return b?b.width/(a.g?new C(a.g,a.k):a.kh()).width:0};function Aq(a,b){Rh.call(this);this.rh=a;this.Qj=b;this[uh]=!1}y(Aq,Rh);f=Aq.prototype;f.Qj=null;f.rh=null;f.M=function(){return this.rh};f.addEventListener=function(a,b,c,d){Gh(this.rh,a,b,c,d)};f.removeEventListener=function(a,b,c,d){Kh(this.rh,a,b,c,d)};f.F=function(){Aq.C.F.call(this);var a=this.rh;if(a)vh(a)?a.jd&&a.jd.removeAll(void 0):Nh(ja(a),void 0);else{var a=0,b;for(b in Eh)a+=Nh(b)}};function Bq(a,b,c,d){Aq.call(this,a,b);a=this.Qj;b=this.M();c?(b.setAttribute("stroke",c.b),c=c.a,u(c)&&-1!=c.indexOf("px")?b.setAttribute("stroke-width",parseFloat(c)/zq(a)):b.setAttribute("stroke-width",c)):b.setAttribute("stroke","none");c=this.Qj;a=this.M();if(d instanceof rq)a.setAttribute("fill",d.A),a.setAttribute("fill-opacity",d.B);else if(d instanceof lq){b="lg-"+d.j+"-"+d.o+"-"+d.k+"-"+d.G+"-"+d.a+"-"+d.b;var e=b in c.a?c.a[b]:null;if(!e){var e=Cq(c,"linearGradient",{x1:d.j,y1:d.o,x2:d.k,
-y2:d.G,gradientUnits:"userSpaceOnUse"}),g="stop-color:"+d.a;ga(d.g)&&(g+=";stop-opacity:"+d.g);g=Cq(c,"stop",{offset:"0%",style:g});e.appendChild(g);g="stop-color:"+d.b;ga(d.i)&&(g+=";stop-opacity:"+d.i);d=Cq(c,"stop",{offset:"100%",style:g});e.appendChild(d);e=Dq(c,b,e)}a.setAttribute("fill","url(#"+e+")")}else a.setAttribute("fill","none")}y(Bq,Aq);function Eq(a,b){Aq.call(this,a,b)}y(Eq,Aq);function Fq(a,b){Aq.call(this,a,b)}y(Fq,Aq);function Gq(a,b,c,d){Bq.call(this,a,b,c,d)}y(Gq,Bq);function Hq(a,b){Aq.call(this,a,b)}y(Hq,Eq);Hq.prototype.clear=function(){Vc(this.M())};function Iq(a,b,c,d){Bq.call(this,a,b,c,d)}y(Iq,Gq);function Jq(a,b){Aq.call(this,a,b)}y(Jq,Fq);function Kq(a,b,c,d,e){yq.call(this,a,b,c,d,e);this.a={};this.G=bc&&!pc(526);this.A=new tq(this)}var Lq;y(Kq,yq);var Mq=0;function Cq(a,b,c){a=a.o.a.createElementNS("http://www.w3.org/2000/svg",b);if(c)for(var d in c)a.setAttribute(d,c[d]);return a}f=Kq.prototype;
-f.Op=function(){var a=Cq(this,"svg",{width:this.width,height:this.height,overflow:"hidden"}),b=Cq(this,"g");this.i=Cq(this,"defs");this.b=new Hq(b,this);a.appendChild(this.i);a.appendChild(b);this.Of=a;this.g&&(this.M().setAttribute("preserveAspectRatio","none"),this.G?this.Vo():this.M().setAttribute("viewBox","0 0 "+(this.g?this.g+" "+this.k:"")))};
-f.Vo=function(){if(this.Ye){var a=this.kh();0==a.width?this.M().style.visibility="hidden":(this.M().style.visibility="",this.b.M().setAttribute("transform","scale("+a.width/this.g+" "+a.height/this.k+") translate(0 0)"))}};
-f.kh=function(){if(!ac)return this.Ye?Ad(this.M()):Kq.C.kh.call(this);var a=this.width,b=this.height,c=u(a)&&-1!=a.indexOf("%"),d=u(b)&&-1!=b.indexOf("%");if(!this.Ye&&(c||d))return null;var e,g;c&&(e=this.M().parentNode,g=Ad(e),a=parseFloat(a)*g.width/100);d&&(e=e||this.M().parentNode,g=g||Ad(e),b=parseFloat(b)*g.height/100);return new C(a,b)};f.clear=function(){this.b.clear();Vc(this.i);this.a={}};function Nq(a,b,c,d){b=Cq(a,"path",{d:Oq(b)});c=new Iq(b,a,c,d);a.b.M().appendChild(c.M())}
-function Oq(a){var b=[];qq(a,function(a,d){switch(a){case 0:b.push("M");Array.prototype.push.apply(b,d);break;case 1:b.push("L");Array.prototype.push.apply(b,d);break;case 2:b.push("C");Array.prototype.push.apply(b,d);break;case 3:var e=d[3];b.push("A",d[0],d[1],0,180<Math.abs(e)?1:0,0<e?1:0,d[4],d[5]);break;case 4:b.push("Z")}});return b.join(" ")}function Dq(a,b,c){if(b in a.a)return a.a[b];var d="_svgdef_"+Mq++;c.setAttribute("id",d);a.a[b]=d;a.i.appendChild(c);return d}
-f.Ti=function(){Kq.C.Ti.call(this);this.G&&this.A.Vc(Pq(),"tick",this.Vo)};f.F=function(){delete this.a;delete this.i;delete this.b;Kq.C.F.call(this)};function Pq(){Lq||(Lq=new Uh(400),Lq.start());return Lq};function Qq(a,b,c){this.a=a;this.b=0;this.i=b;c&&(this.vn=c)}f=Qq.prototype;f.vn=70;f.ik=!1;f.start=function(a){this.k=w();this.b=a;this.j=this.k+this.b;this.ik=!0;an(this.a);kf(this.g);this.g=jf(v(this.eu,this),this.vn)};f.stop=function(){this.ik=!1;bn(this.a);this.g&&kf(this.g)};
-f.eu=function(){if(this.ik){var a=w(),b;b=0==this.b||a>=this.j?0:1-(a-this.k)/this.b;var c=E("countdowntimer-diminishing-pieslice",this.a),d=Ue("svg",this.a);!d&&this.a.querySelectorAll&&(d=this.a.querySelectorAll("svg"),d=d.length?d[0]:null);var d=parseInt(d.getAttribute("width"),10),e=new mq,g=d/2-5;oq(e,d/2,d/2);e.Fa(d/2,5);pq(e,g,g,-90,360*-b);e.Fa(d/2,d/2);e.close();c.setAttribute("d",Oq(e));a>=this.j&&(this.stop(),this.i&&this.i())}};function Rq(a){this.a=a}var Sq=/\s*;\s*/;f=Rq.prototype;f.set=function(a,b,c,d,e,g){if(/[;=\s]/.test(a))throw Error('Invalid cookie name "'+a+'"');if(/[;\r\n]/.test(b))throw Error('Invalid cookie value "'+b+'"');q(c)||(c=-1);e=e?";domain="+e:"";d=d?";path="+d:"";g=g?";secure":"";c=0>c?"":0==c?";expires="+(new Date(1970,1,1)).toUTCString():";expires="+(new Date(w()+1E3*c)).toUTCString();this.a.cookie=a+"="+b+e+d+c+g};
-f.get=function(a,b){for(var c=a+"=",d=(this.a.cookie||"").split(Sq),e=0,g;g=d[e];e++){if(0==g.lastIndexOf(c,0))return g.substr(c.length);if(g==a)return""}return b};f.remove=function(a,b,c){var d=q(this.get(a));this.set(a,"",0,b,c);return d};f.nc=function(){return Tq(this).keys};f.hc=function(){return Tq(this).Sv};f.isEmpty=function(){return!this.a.cookie};f.fb=function(){return this.a.cookie?(this.a.cookie||"").split(Sq).length:0};f.clear=function(){for(var a=Tq(this).keys,b=a.length-1;0<=b;b--)this.remove(a[b])};
-function Tq(a){a=(a.a.cookie||"").split(Sq);for(var b=[],c=[],d,e,g=0;e=a[g];g++)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,Sv:c}}var Uq=new Rq(document);Uq.b=3950;var Vq=n("yt.prefs.UserPrefs.prefs_")||{};qa("yt.prefs.UserPrefs.prefs_",Vq);function Wq(a){var b=null;"transition"in a.style?b="transition-duration":"webkitTransition"in a.style?b="-webkit-transition-duration":"MozTransition"in a.style?b="-moz-transition-duration":"OTransition"in a.style?b="-o-transition-duration":"msTransition"in a.style&&(b="-ms-transition-duration");a=b?(document.defaultView?document.defaultView.getComputedStyle(a,null):document.parentWindow.getComputedStyle(a,null)).getPropertyValue(b):"0";return 1E3*parseFloat(a)};var Xq=n("yt.pubsub.instance_")||new kh;kh.prototype.subscribe=kh.prototype.D;kh.prototype.unsubscribeByKey=kh.prototype.Wc;kh.prototype.publish=kh.prototype.u;kh.prototype.clear=kh.prototype.clear;qa("yt.pubsub.instance_",Xq);function Yq(a,b,c){var d=Zq();return d?d.subscribe(a,function(){var a=arguments;try{H(function(){b.apply(c||l,a)},0)}catch(d){lf(d)}},c):0}
-function $q(){var a=ef("LOGGED_IN_PUBSUB_KEY"),b=Zq();b&&("number"==typeof a?a=[a]:"string"==typeof a&&(a=[parseInt(a,10)]),z(a,function(a){b.unsubscribeByKey(a)}))}function ar(a,b){var c=Zq();return c?c.publish.apply(c,arguments):!1}function Zq(){return n("yt.pubsub.instance_")};function br(a,b,c,d,e,g){var h,k;if(h=c.offsetParent){var m="HTML"==h.tagName||"BODY"==h.tagName;m&&"static"==ld(h,"position")||(k=sd(h),m||(m=(m=td(h))&&ac?-h.scrollLeft:!m||D&&pc("8")||"visible"==ld(h,"overflowX")?h.scrollLeft:h.scrollWidth-h.clientWidth-h.scrollLeft,k=vb(k,new B(m,h.scrollTop))))}h=k||new B;k=Cd(a);if(m=rd(a)){var p=Bb(m),m=Math.max(k.left,p.left),s=Math.min(k.left+k.width,p.left+p.width);if(m<=s){var r=Math.max(k.top,p.top),p=Math.min(k.top+k.height,p.top+p.height);r<=p&&(k.left=
-m,k.top=r,k.width=s-m,k.height=p-r)}}m=Fc(a);r=Fc(c);if(m.a!=r.a){var s=m.a.body,r=r.a.parentWindow||r.a.defaultView,p=new B(0,0),x=Hc(s)?Hc(s).parentWindow||Hc(s).defaultView:window,M=s;do{var ta=x==r?sd(M):wd(M);p.x+=ta.x;p.y+=ta.y}while(x&&x!=r&&(M=x.frameElement)&&(x=x.parent));s=vb(p,sd(s));D&&!gd(m)&&(s=vb(s,hd(m)));k.left+=s.x;k.top+=s.y}a=(b&4&&td(a)?b^2:b)&-5;b=new B(a&2?k.left+k.width:k.left,a&1?k.top+k.height:k.top);b=vb(b,h);e&&(b.x+=(a&2?-1:1)*e.x,b.y+=(a&1?-1:1)*e.y);if(e=rd(c))e.top-=
-h.y,e.right-=h.x,e.bottom-=h.y,e.left-=h.x;cr(b,c,d,g,e,65,void 0)}
-function cr(a,b,c,d,e,g,h){a=a.clone();var k=(c&4&&td(b)?c^2:c)&-5;c=Ad(b);h=h?h.clone():c.clone();if(d||0!=k)k&2?a.x-=h.width+(d?d.right:0):d&&(a.x+=d.left),k&1?a.y-=h.height+(d?d.bottom:0):d&&(a.y+=d.top);if(g&&(e?(d=a,k=0,65==(g&65)&&(d.x<e.left||d.x>=e.right)&&(g&=-2),132==(g&132)&&(d.y<e.top||d.y>=e.bottom)&&(g&=-5),d.x<e.left&&g&1&&(d.x=e.left,k|=1),d.x<e.left&&d.x+h.width>e.right&&g&16&&(h.width=Math.max(h.width-(d.x+h.width-e.right),0),k|=4),d.x+h.width>e.right&&g&1&&(d.x=Math.max(e.right-
-h.width,e.left),k|=1),g&2&&(k=k|(d.x<e.left?16:0)|(d.x+h.width>e.right?32:0)),d.y<e.top&&g&4&&(d.y=e.top,k|=2),d.y<=e.top&&d.y+h.height<e.bottom&&g&32&&(h.height=Math.max(h.height-(e.top-d.y),0),d.y=e.top,k|=8),d.y>=e.top&&d.y+h.height>e.bottom&&g&32&&(h.height=Math.max(h.height-(d.y+h.height-e.bottom),0),k|=8),d.y+h.height>e.bottom&&g&4&&(d.y=Math.max(e.bottom-h.height,e.top),k|=2),g&8&&(k=k|(d.y<e.top?64:0)|(d.y+h.height>e.bottom?128:0)),e=k):e=256,e&496))return;md(b,a);xb(c,h)||(e=gd(Fc(Hc(b))),
-!D||e&&pc("8")?(b=b.style,ac?b.MozBoxSizing="border-box":bc?b.WebkitBoxSizing="border-box":b.boxSizing="border-box",b.width=Math.max(h.width,0)+"px",b.height=Math.max(h.height,0)+"px"):(a=b.style,e?(e=Gd(b),b=Hd(b),a.pixelWidth=h.width-b.left-e.left-e.right-b.right,a.pixelHeight=h.height-b.top-e.top-e.bottom-b.bottom):(a.pixelWidth=h.width,a.pixelHeight=h.height)))};var dr={},er="ontouchstart"in document;function fr(a,b,c){var d;switch(a){case "mouseover":case "mouseout":d=3;break;case "mouseenter":case "mouseleave":d=9}return fd(c,function(a){return Cc(a,b)},!0,d)}
-function gr(a){var b="mouseover"==a.type&&"mouseenter"in dr||"mouseout"==a.type&&"mouseleave"in dr,c=a.type in dr||b;if("HTML"!=a.target.tagName&&c){if(b){var b="mouseover"==a.type?"mouseenter":"mouseleave",c=dr[b],d;for(d in c.Qb){var e=fr(b,d,a.target);e&&!fd(a.relatedTarget,function(a){return a==e},!0)&&c.u(d,e,b,a)}}if(b=dr[a.type])for(d in b.Qb)(e=fr(a.type,d,a.target))&&b.u(d,e,a.type,a)}}K(document,"blur",gr,!0);K(document,"change",gr,!0);K(document,"click",gr);K(document,"focus",gr,!0);
-K(document,"mouseover",gr);K(document,"mouseout",gr);K(document,"mousedown",gr);K(document,"keydown",gr);K(document,"keyup",gr);K(document,"keypress",gr);K(document,"cut",gr);K(document,"paste",gr);er&&(K(document,"touchstart",gr),K(document,"touchend",gr),K(document,"touchcancel",gr));var hr=window.yt&&window.yt.uix&&window.yt.uix.widgets_||{};qa("yt.uix.widgets_",hr);function ir(a){a=a.getInstance();var b=$(a);b in hr||!a.qq()||(a.register(),hr[b]=a)};function jr(){this.a={}}jr.prototype.g=!!eval("/*@cc_on!@*/false");jr.prototype.qq=function(){return!0};function kr(a,b,c){var d=$(a,void 0),e=v(c,a);b in dr||(dr[b]=new kh);dr[b].D(d,e);a.a[c]=e}jr.prototype.b=function(a,b,c){var d=G(a,b);if(d&&(d=n(d))){var e=ab(arguments,2);$a(e,0,0,a);d.apply(null,e)}};function lr(a,b){Oe(a,"tooltip-text",b)}jr.prototype.removeData=function(a,b){a.dataset?delete a.dataset[Pe(b)]:a.removeAttribute("data-"+b)};
-function $(a,b){return"yt-uix"+(a.dj?"-"+a.dj:"")+(b?"-"+b:"")};function mr(){this.a={}}y(mr,jr);ca(mr);f=mr.prototype;f.dj="button";f.Ef=null;f.register=function(){kr(this,"click",this.gy);kr(this,"keydown",this.ey);kr(this,"keypress",this.fy)};f.gy=function(a){a&&!a.disabled&&(nr(this,a),this.click(a))};
-f.ey=function(a,b,c){if(!(c.altKey||c.ctrlKey||c.shiftKey)&&(b=or(this,a))){var d=function(a){var b="";a.tagName&&(b=a.tagName.toLowerCase());return"ul"==b||"table"==b};if(d=d(b)?b:$c(b,d)){var d=d.tagName.toLowerCase(),e;"ul"==d?e=this.ky:"table"==d&&(e=this.jy);e&&pr(this,a,b,c,v(e,this))}}};
-function pr(a,b,c,d,e){var g=$m(c),h=9==d.keyCode;h||32==d.keyCode||13==d.keyCode?(d=qr(a,c))?(b=Wc(d),"a"==b.tagName.toLowerCase()?window.location=b.href:Bf(b,"click")):h&&rr(a,b):g?27==d.keyCode?(qr(a,c),rr(a,b)):e(b,c,d):(a=Cc(b,$(a,"reverse"))?38:40,d.keyCode==a&&(Bf(b,"click"),d.preventDefault()))}f.fy=function(a,b,c){c.altKey||c.ctrlKey||c.shiftKey||(a=or(this,a),$m(a)&&c.preventDefault())};function qr(a,b){var c=$(a,"menu-item-highlight"),d=E(c,b);d&&Ac(d,c);return d}
-function sr(a,b,c){zc(c,$(a,"menu-item-highlight"));b.setAttribute("aria-activedescendant",c.getAttribute("id"))}f.jy=function(a,b,c){var d=qr(this,b);b=Ue("table",b);var e=Ue("tr",b),e=Kc("td",null,e).length;b=Kc("td",null,b);d=tr(d,b,e,c);-1!=d&&(sr(this,a,b[d]),c.preventDefault())};f.ky=function(a,b,c){if(40==c.keyCode||38==c.keyCode){var d=qr(this,b);b=Kc("li",null,b);d=tr(d,b,1,c);sr(this,a,b[d]);c.preventDefault()}};
-function tr(a,b,c,d){var e=b.length;a=Ha(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}function ur(a,b){var c=b.iframeMask;c||(c=document.createElement("iframe"),c.src='javascript:""',c.className=$(a,"menu-mask"),b.iframeMask=c);return c}
-function vr(a,b,c,d){var e=ed(b,$(a,"group")),g=!!G(b,"button-menu-ignore-group"),e=e&&!g?e:b,g=5,h=4,k=Cd(b);if(Cc(b,$(a,"reverse"))){g=4;h=5;k=k.top+"px";try{c.style.maxHeight=k}catch(m){}}Cc(b,"flip")&&(Cc(b,$(a,"reverse"))?(g=6,h=7):(g=7,h=6));var p;G(b,"button-has-sibling-menu")?p=qd(e):G(b,"button-menu-root-container")&&(p=wr(b));D&&!pc("8")&&(p=null);var s;p&&(s=Cd(p),s=new wb(-s.top,s.left,s.top,-s.left));p=new B(0,1);Cc(b,$(a,"center-menu"))&&(p.x-=Math.round((Ad(c).width-Ad(b).width)/2));
-d&&(p.y+=Oc(document).y);if(a=ur(a,b))b=Ad(c),a.style.width=b.width+"px",a.style.height=b.height+"px",br(e,g,a,h,p,s),d&&dn(a,"position","fixed");br(e,g,c,h,p,s)}function wr(a){if(G(a,"button-menu-root-container")){var b=G(a,"button-menu-root-container");return ed(a,b)}return document.body}
-f.Bp=function(a){if(a){var b=or(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);var c;c=G(a,"button-has-sibling-menu")?a.parentNode:wr(a);c.appendChild(b);b.style.minWidth=a.offsetWidth-2+"px";var d=ur(this,a);d&&c.appendChild(d);c=!!G(a,"button-menu-fixed");vr(this,a,b,c);an(b);this.b(a,"button-menu-action",!0);zc(a,$(this,"active"));c=v(this.gw,this,a);b=K(document,"click",
-c);c=K(document,"contextmenu",c);Oe(a,"button-listener",b);Oe(a,"button-context-menu-listener",c);this.Ef=a}}};
-function rr(a,b){if(b){var c=or(a,b);if(c){a.Ef=null;b.setAttribute("aria-pressed","false");b.setAttribute("aria-expanded","false");b.removeAttribute("aria-activedescendant");bn(c);a.b(b,"button-menu-action",!1);var d=ur(a,b);H(function(){d&&d.parentNode&&d.parentNode.removeChild(d);c.originalParentNode&&(c.parentNode.removeChild(c),c.originalParentNode.appendChild(c),c.originalParentNode=null,c.activeButtonNode=null)},1)}var e=ed(b,$(a,"group"));Ac(b,$(a,"active"));e&&Ac(e,$(a,"group-active"));if(e=
-G(b,"button-listener"))vf(e),a.removeData(b,"button-listener");if(e=G(b,"button-context-menu-listener"))vf(e),a.removeData(b,"button-context-menu-listener")}}function xr(a,b){var c=or(a,b);c&&vr(a,b,c)}function yr(a,b){return or(a,b)}
-f.gw=function(a,b){var c;c=b||window.event;c=c.target||c.srcElement;3==c.nodeType&&(c=c.parentNode);var d=ed(c,$(this));if(d){var d=or(this,d),e=or(this,a);if(d==e)return}if(!ed(c,$(this,"menu"))||Cc(c,$(this,"menu-item"))||Cc(c,$(this,"menu-close")))if(rr(this,a),(d=ed(c,$(this,"menu")))&&G(a,"button-menu-indicate-selected")){if(e=E($(this,"content"),a)){var g;wc&&"innerText"in c?g=c.innerText.replace(/(\r\n|\r|\n)/g,"\n"):(g=[],dd(c,g,!0),g=g.join(""));g=g.replace(/ \xAD /g," ").replace(/\xAD/g,
-"");g=g.replace(/\u200B/g,"");wc||(g=g.replace(/ +/g," "));" "!=g&&(g=g.replace(/^\s*/,""));Zc(e,g)}e=$(this,"menu-item-selected");(d=E(e,d))&&Ac(d,e);zc(c.parentNode,e)}};function or(a,b){if(!b.widgetMenu){var c=G(b,"button-menu-id"),c=c&&Ic(c),d=$(a,"menu");c?(zc(c,d),zc(c,$(a,"menu-external"))):c=E(d,b);b.widgetMenu=c}return b.widgetMenu}
-function nr(a,b){if(G(b,"button-toggle")){var c=ed(b,$(a,"group"));if(c&&G(c,"button-toggle-group")){var d=G(c,"button-toggle-group"),c=Jc($(a),c),e=$(a,"toggled"),g=Cc(b,e);z(c,function(a){a!=b||"optional"==d&&g?Ac(a,e):zc(b,e)})}else Ec(b,$(a,"toggled"))}}f.click=function(a){if(or(this,a)){var b=or(this,a),c=ed(b.activeButtonNode||b.parentNode,$(this));c&&c!=a?(rr(this,c),H(v(this.Bp,this,a),1)):$m(b)?rr(this,a):this.Bp(a);a.focus()}this.b(a,"button-action")};function zr(a,b,c){this.i=a;this.g=b;this.b=c;this.a=v(this.ju,this)}y(zr,Lf);f=zr.prototype;f.bj=!1;f.If=null;function Ar(a){a.If?a.bj=!0:Br(a)}f.stop=function(){this.If&&(l.clearTimeout(this.If),this.If=null,this.bj=!1)};f.F=function(){zr.C.F.call(this);this.stop()};f.ju=function(){this.If=null;this.bj&&(this.bj=!1,Br(this))};function Br(a){a.If=Wh(a.a,a.g);a.i.call(a.b)};function Cr(a,b,c){b||(b={});var d=c||window;c="undefined"!=typeof a.href?a.href:String(a);a=b.target||a.target;var e=[],g;for(g in b)switch(g){case "width":case "height":case "top":case "left":e.push(g+"="+b[g]);break;case "target":case "noreferrer":break;default:e.push(g+"="+(b[g]?1:0))}g=e.join(",");if(b.noreferrer){if(b=d.open("",a,g))D&&-1!=c.indexOf(";")&&(c="'"+c.replace(/'/g,"%27")+"'"),b.opener=null,c=va(c),b.document.write('<META HTTP-EQUIV="refresh" content="0; url='+c+'">'),b.document.close()}else b=
-d.open(c,a,g);return b}function Dr(a,b){var c;c=b||{};c.target=c.target||a.target||"YouTube";c.width=c.width||600;c.height=c.height||600;(c=Cr(a,c))?(c.opener||(c.opener=window),c.focus()):c=null;return!c};function Er(a,b){Fr().tick[a]=b||w()}function Gr(a){var b=Fr().tick;return a in b}function Hr(a){var b="https:"==window.location.protocol?"https://gg.google.com/csi":"http://csi.gstatic.com/csi",c="",d;for(d in a)c+="&"+d+"="+a[d];Kf(b+"?"+c.substring(1))}function Ir(){return Fr().info}function Fr(){return n("ytcsi.data_")||Jr()}function Jr(){var a={tick:{},span:{},info:{}};qa("ytcsi.data_",a);return a};function Kr(a){if(!a)return!1;a=a.replace(/https?:\/\//g,"");var b=a.split("/",1);if(!b||1>b.length||!b[0])return!1;b=b[0].toLowerCase().split(".").reverse();return 2>b.length?!1:("com"==b[0]&&"youtube"==b[1]||"be"==b[0]&&"youtu"==b[1])&&-1==a.indexOf("/redirect?")}
-function Lr(a,b){if("new"==a.target)return-1;var c=mp(a);if(!c)return-1;var c=c.replace(/https?:\/\//g,""),d;(d=!Kr(c))||(d=ee(c)||"",d=d.split("/"),d="/"+(1<d.length?d[1]:""),d="/watch"!=d);if(d)return-1;d=Vi(c);if(!d||d.v!=b.L||d.list||d.p)return-1;c=c.split("#",2);if(!c||2>c.length)return-1;(c=Ui(c[1]))&&c.t?(d=c.t,c=0,-1!=d.indexOf("h")&&(d=d.split("h"),c=3600*d[0],d=d[1]),-1!=d.indexOf("m")&&(d=d.split("m"),c=60*d[0]+c,d=d[1]),-1!=d.indexOf("s")?(d=d.split("s"),c=1*d[0]+c):c=1*d+c):c=-1;return c}
-;function Mr(a,b){this.b=a;this.a=b}function Io(a,b,c){b&&b.i&&Ho(b)&&a.log_(Co(a,b,3),c)}function Co(a,b,c){var d={};d["iv-event"]=c;d["a-id"]=b.id;d["a-type"]=Nr(b);if(c=Ho(b))d.link=escape(mp(c)),c.a&&(d["l-class"]=c.a);d.ps=a.a.Ja;if(b.A){var e=new ve(b.A);z(e.nc(),function(a){d[a]=e.get(a)})}return d}
-function Nr(a){switch(a.type){case "text":switch(a.style){case "popup":return 1;case "speech":return 2;case "anchored":return 8;case "label":return 9;case "title":return 4;default:return 0}case "highlight":return 3;case "image":switch(a.style){case "video":return 11;case "channel":return 10;default:return 0}default:return 0}}Mr.prototype.log_=function(a,b){this.b.u("command_log","iv",a,b)};function Or(a,b){this.start=a<b?a:b;this.end=a<b?b:a}Or.prototype.clone=function(){return new Or(this.start,this.end)};function Pr(){}f=Pr.prototype;f.Tc=!1;f.bf=null;f.Pl=null;function Qr(a,b,c){a.bf?(yd(a.bf.M(),b,c),a.bf.clear()):(b=new Kq(b,c,void 0,void 0,void 0),a.bf=b,a.bf.Op(),a.Pl=Pc("div"),a.Pl.appendChild(a.bf.M()));return a.bf}f.M=function(){return this.Pl};f.ae=function(){};function Rr(a,b,c){var d=document.createElementNS("http://www.w3.org/2000/svg",a);b&&Cb(b,function(a,b){d.setAttribute(b,a)});for(var e=2;e<arguments.length;e++)d.appendChild(arguments[e]);return d}function Sr(a,b){var c;c=":"+(vq.getInstance().a++).toString(36);b.setAttribute("result",c);a.appendChild(b);return c};function Tr(a,b){var c=Sr(a,Rr("feGaussianBlur",{"in":b,stdDeviation:"1.8"})),c=Sr(a,Rr("feDiffuseLighting",{"in":c,surfaceScale:"4",diffuseConstant:"1"},Rr("feDistantLight",{azimuth:"270",elevation:"15","lighting-color":"white"}))),c=Sr(a,Rr("feComposite",{"in":c,in2:b,operator:"in"}));return Sr(a,Rr("feComposite",{in2:c,"in":b,operator:"arithmetic",k2:1,k3:0.5,k4:0}))}
-function Ur(a,b){var c=Sr(a,Rr("feOffset",{"in":b,dx:"-7",dy:"-7"})),c=Sr(a,Rr("feGaussianBlur",{"in":c,stdDeviation:"3"})),c=Sr(a,Rr("feColorMatrix",{"in":c,type:"matrix",values:"0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.5 0"})),d=Sr(a,Rr("feColorMatrix",{"in":b,type:"matrix",values:"0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 100 0"})),d=Sr(a,Rr("feGaussianBlur",{"in":d,stdDeviation:"1"})),c=Sr(a,Rr("feComposite",{operator:"out","in":c,in2:d}));return Sr(a,Rr("feComposite",{operator:"over","in":b,in2:c}))}
-function Vr(a,b){return b}function Wr(a){var b=Rr("filter",{filterUnits:"userSpaceOnUse"}),c="SourceGraphic";z(a,function(a){t:{switch(a){case "bevel":a=Tr;break t;case "dropshadow":a=Ur;break t}a=Vr}c=a(b,c)});return b}function Xr(a){a=Ia(a,function(a){return a in Yr});db(a,function(a,c){return Yr[a]-Yr[c]});return a}function Zr(a,b){if(!b)return null;var c="effects:"+(b?b.join("|"):""),d=c in a.a?a.a[c]:null;if(d)return d;d=Wr(b);return 0<d.childNodes.length?Dq(a,c,d):null}
-function $r(a){return Na(a,function(a){return"dropshadow"==a})?new wb(0,7,7,0):new wb(0,0,0,0)}var Yr={bevel:1,dropshadow:2};function as(a,b,c,d,e){b=bs(b,c,d?d.a/2+1:0);Nq(a,b,d,e)}function bs(a,b,c){var d=new mq;oq(d,a.left+b+c,a.top+c);d.Fa(a.left+a.width-b-c,a.top+c);pq(d,b,b,-90,90);d.Fa(a.left+a.width-c,a.top+a.height-b-c);pq(d,b,b,0,90);d.Fa(a.left+b+c,a.top+a.height-c);pq(d,b,b,90,90);d.Fa(a.left+c,a.top+b+c);pq(d,b,b,180,90);d.close();return d}function cs(a,b,c){b&&c&&a.setAttribute(b,"url(#"+c+")")}
-function ds(a,b,c,d){var e=a.B;e?a=new lq(e.j*b/100,e.o*c/100,e.k*b/100,e.G*c/100,e.a,e.b,e.g,e.i):(b=d?Math.max(a.a,0.9):a.a,a=new rq(a.j,b));return a}function es(a,b){var c=new wb(a.top,a.left+a.width,a.top+a.height,a.left),d=$r(b);ia(d)?(c.top-=d.top,c.right+=d.right,c.bottom+=d.bottom,c.left-=d.left):(c.top-=d,c.right+=void 0,c.bottom+=void 0,c.left-=NaN);return Bb(c)}function fs(a,b,c){c.length&&(b=Na(b.childNodes,function(a){return"g"==a.tagName}))&&(a=Zr(a,Xr(c)),cs(b,"filter",a))};function gs(){}y(gs,Pr);gs.prototype.a=0;
-gs.prototype.ae=function(a,b,c){var d=a.b,e=d.G,g=this.Tc&&Yp(a),e=(e+=g?1:0)?new sq(e,g?d.k:d.o):null;if(g=bq(a)){var h=Cp(g,b,c);if(!(0>=h.width||0>=h.height)){var k;if(k=(a=(a=a.a?a.a.a.length?a.a.a[0]:null:null)&&a.a?a.a:null)&&a.length?a[0]:null){var m;c=c?Cp(c,b):null;a=xp(k,new Ab(k.B,k.H,k.k,k.i),b);c?(a.top+=c.top,a.left+=c.left):(a.top+=b.top,a.left+=b.left);m=new B(a.left,a.top);c=h.clone();a=new Ab(m.x,m.y,1,1);var g=Math.max(c.left+c.width,a.left+a.width),p=Math.max(c.top+c.height,a.top+
-a.height);c.left=Math.min(c.left,a.left);c.top=Math.min(c.top,a.top);c.width=g-c.left;c.height=p-c.top;c=es(c,d.b);a=Qr(this,c.width,c.height);var g=ds(d,c.width,c.height,this.Tc),h=new Ab(h.left-c.left,h.top-c.top,h.width,h.height),s=new B(m.x-c.left,m.y-c.top);this.a=17*zp(b,k.g,k.a?k.a:"xy");b=d.g;k=e?e.a/2:0;m=hs(h,s);var p=this.b(h,b,s,m),r=s.x,s=s.y,x=h.width,M=h.height,ta=h.left,h=h.top,Y=new mq;oq(Y,ta+b+k,h+k);"t"==m&&(Y.Fa(p.start,h+k),Y.Fa(r,s),Y.Fa(p.end,h+k));Y.Fa(ta+x-b-k,h+k);pq(Y,
-b,b,-90,90);"r"==m&&(Y.Fa(ta+x-k,p.start),Y.Fa(r,s),Y.Fa(ta+x-k,p.end));Y.Fa(ta+x-k,h+M-b-k);pq(Y,b,b,0,90);"b"==m&&(Y.Fa(p.end,h+M-k),Y.Fa(r,s),Y.Fa(p.start,h+M-k));Y.Fa(ta+b+k,h+M-k);pq(Y,b,b,90,90);"l"==m&&(Y.Fa(ta+k,p.end),Y.Fa(r,s),Y.Fa(ta+k,p.start));Y.Fa(ta+k,h+b+k);pq(Y,b,b,180,90);Y.close();Nq(a,Y,e,g);if(e=this.M())V(e,"annotation-shape"),V(e,"annotation-speech-shape"),md(e,c.left,c.top),yd(e,c.width,c.height),fs(a,e,d.b)}}}};
-function hs(a,b){var c=a.top-b.y,d=b.x-a.left-a.width,e=b.y-a.top-a.height,g=a.left-b.x,h=Math.max(c,d,e,g);if(0>h)return"i";switch(h){case c:return"t";case d:return"r";case e:return"b";case g:return"l"}return"i"}gs.prototype.b=function(a,b,c,d){function e(a,c,d){h=Math.min(Math.max(d-2*b,0),g);k=tb(a-h/2,c+b,c+d-h-b)}var g=this.a,h=0,k=0;"t"==d||"b"==d?e(c.x,a.left,a.width):"l"!=d&&"r"!=d||e(c.y,a.top,a.height);return new Or(k,k+h)};function is(){}y(is,Pr);is.prototype.ae=function(a,b,c){var d=bq(a);d&&(b=Cp(d,b,c),0>=b.width||0>=b.height||(a=a.b,c=es(b,a.b),d=Qr(this,c.width,c.height),as(d,new Ab(0,0,b.width,b.height),a.g,new sq(!a.i&&this.Tc?1:a.i,a.j),new rq("#000",0)),b=this.M(),V(b,"annotation-shape"),Dd(b,this.Tc?Math.max(a.a,0.9):a.a),md(b,c.left,c.top),yd(b,c.width,c.height)))};function js(a,b,c){this.a=a||0;this.g=b||0;this.b=c||!1}y(js,Pr);function ks(a,b){var c=a.width,d=a.height,e=0,g=0;0<b&&(a.width/a.height>b?(d=a.width/b,g=(a.height-d)/2):(c=a.height*b,e=(a.width-c)/2));return new Ab(e,g,c,d)}
-js.prototype.ae=function(a,b,c){var d=Cp(bq(a),b,c);if(!(0>=d.width||0>=d.height)){var e=ks(d,this.g);e.left+=d.left;e.top+=d.top;b=a.b;c=es(e,b.b);var g=Qr(this,c.width,c.height),h=new rq("#000",0),e=ks(e,this.a);a=a.j?a.j.a?a.j.a:a.j.L?kn(a.j.L,"hqdefault.jpg"):"":"";e=Cq(g,"image",{x:e.left,y:e.top,width:e.width,height:e.height,"image-rendering":"optimizeQuality",preserveAspectRatio:"none"});e.setAttributeNS("http://www.w3.org/1999/xlink","href",a);a=new Jq(e,g);g.b.M().appendChild(a.M());if(e=
-this.M()){var k=this.Tc?Math.max(b.a,0.9):b.a;Dd(e,k);if(this.b&&0<b.i){var k=new sq(b.i,b.j),d=new Ab(0,0,d.width,d.height),m;m=bs(d,b.g,k.a/2+1);var p="mask"in g.a?g.a.mask:null;if(p)m=p;else{var p=document.createElementNS("http://www.w3.org/2000/svg","mask"),s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",Oq(m));s.setAttribute("fill","#FFF");p.appendChild(s);m=Dq(g,"mask",p)}cs(a.M(),"mask",m);as(g,d,b.g,k,h)}V(e,"annotation-shape");V(e,"annotation-image-shape");
-md(e,c.left,c.top);yd(e,c.width,c.height);fs(g,e,b.b)}}};function ls(){}y(ls,Pr);ls.prototype.ae=function(a,b,c){var d=bq(a);if(d){var e=Cp(d,b,c);if(!(0>=e.width||0>=e.height)){b=a.b;c=es(e,b.b);var d=Qr(this,c.width,c.height),g=b.G;a=this.Tc&&Yp(a);a=(g+=a?1:0)?new sq(g,a?b.k:b.o):null;g=new Ab(0,0,e.width,e.height);e=ds(b,e.width,e.height,this.Tc);as(d,g,b.g,a,e);if(a=this.M())V(a,"annotation-shape"),V(a,"annotation-popup-shape"),md(a,c.left,c.top),yd(a,c.width,c.height),fs(d,a,b.b)}}};function ms(){}y(ms,gs);ms.prototype.b=function(a,b,c,d){function e(a,c,d){h=Math.min(Math.max(d-2*b,0),g);k=a<=c+d/2?Math.max(c+d/4-h/2,c+b):Math.min(c+3*d/4-h/2,c+d-h-b)}var g=this.a,h=0,k=0;"t"==d||"b"==d?e(c.x,a.left,a.width):"l"!=d&&"r"!=d||e(c.y,a.top,a.height);return new Or(k,k+h)};function ns(a,b){this.b=Ic(a);this.a=on(this.b,b)}
-function os(a,b){var c=pn(a.a,b,void 0),c=c.replace(/^[\s\xa0]+/,""),d;d=String(c.substr(0,3)).toLowerCase();(d=0==("<tr"<d?-1:"<tr"==d?0:1))&&(c="<table><tbody>"+c+"</tbody></table>");var e=c,g=document,c=g.createElement("div");D?(c.innerHTML="<br>"+e,c.removeChild(c.firstChild)):c.innerHTML=e;if(1==c.childNodes.length)c=c.removeChild(c.firstChild);else{for(e=g.createDocumentFragment();c.firstChild;)e.appendChild(c.firstChild);c=e}d&&(c=Wc(Wc(c)));return c};function ps(a,b,c,d,e){this.a=a;this.j=b;this.g=c;this.o=d;this.k=e;this.i=new eo(this)}f=ps.prototype;f.la=null;f.Yc=null;f.cc=null;f.Ea=null;f.$k=null;function qs(a,b){var c=v(function(a,c,g){c=g?rs(this,c,v(g,this)):rs(this,c);this.i.listen(b,a,c)},a);c("mouseover","e",a.ax);c("mouseout","d",a.$w);c("click","b");c("mousedown","a");c("touchend","b")}
-function ss(a){if(a.a.G){var b;if(Ka(a.a.g,function(a){return"close"==a.type},void 0))b=a.la;else{b=os(new ns("annotation-close-button-template",[]),{});if(!(b instanceof Element))return;a.cc=b;Oe(a.cc,"annotation_id",a.a.id);a.la.appendChild(a.cc);b=a.cc}var c=function(a){a.stopPropagation()};a.i.listen(b,"click",rs(a,"c",c));a.i.listen(b,"touchend",rs(a,"c",c))}}
-function rs(a,b,c){return v(function(a){if(this.k)c&&c(a);else if(a.target instanceof Element){bn(a.target);var e=document.elementFromPoint(a.x,a.y);an(a.target);Zl(e,"annotation")&&Bf(e,a.type)}this.o.u(b,this.a)},a)}f.ax=function(){this.cc&&an(this.cc);this.Yc&&Dd(this.Yc,1);var a=ts(this);this.Ea&&(this.Ea.Tc=!0,Dd(this.la,us(this)?1:0),a&&this.Ea.ae(this.a,a,vs(this)))};
-f.$w=function(){this.cc&&bn(this.cc);this.Yc&&Dd(this.Yc,0);var a=ts(this);this.Ea&&(this.Ea.Tc=!1,Dd(this.la,us(this)?1:0),a&&this.Ea.ae(this.a,a,vs(this)))};function vs(a){return a.$k?bq(a.$k):null}
-function jq(a){if(a.la||a.Ea){var b=bq(a.a);if(b){var c=ts(a),d=vs(a);if(a.la&&c){b=Cp(b,c,d);yd(a.la,b.width,b.height);md(a.la,b.left,b.top);var e=a.g.ug;e&&(e=new wb(360*ws(a).top*dq(a.a,e)/100,640*ws(a).right*cq(a.a,e)/100,360*ws(a).bottom*dq(a.a,e)/100,640*ws(a).left*cq(a.a,e)/100),a.Yc&&(e.right+=1.5*c.height/100),a.la.style.padding=e.top+"px "+e.right+"px "+e.bottom+"px "+e.left+"px");"label"==a.a.style&&a.b&&(a.b.style.padding=a.la.style.padding);if(a.Yc){e=4.2*c.height/100;e=new C(e,e);yd(a.Yc,
-e);if("highlight"==a.a.type||"label"==a.a.style)var g=1.5*c.height/100,e=new B(b.width-e.width-g,b.height-e.height-g);else e=new B(b.width-e.width-3*c.height/100,(b.height-e.height)/2);md(a.Yc,e)}if(a.cc){yd(a.cc,new C(18,18));var e=a.cc,g=Ad(a.cc),h=9<=c.left+c.width-(b.left+b.width),k=9<=b.top-c.top;md(e,h&&k?new B(b.width-9,-9):h?new B(b.width-9,b.height>27+g.height?9:b.height-9):k?new B(b.width>27+g.width?b.width-9-g.width:-9,-9):b.width/c.width>b.height/c.height?new B(b.width>27+g.width?b.width-
-9-g.width:-9,b.height-9):new B(-9,b.height>27+g.height?9:b.height-9))}}a.Ea&&c&&a.Ea.ae(a.a,c,d);if(a.la){c=a.la;d=a.a.b;c.style.color="highlightText"==a.a.style?d.H:d.k;c.style.fontSize=360*d.I*dq(a.a,a.g.ug)/100+"px";c.style.textAlign=d.textAlign?d.textAlign:"title"==a.a.style||"highlightText"==a.a.style?"center":"left";d.A&&(c.style.fontWeight=d.A);a=a.la;c=a.style.overflow;(d=E("annotation-link-icon",a))&&bn(d);a.style.overflow="scroll";for(b=100;0<b&&!(a.scrollHeight<=a.offsetHeight&&a.scrollWidth<=
-a.offsetWidth);b--){e=Od(a);if(5>e)break;e--;a.style.fontSize=e+"px"}a.style.overflow=c;d&&an(d)}}}}function ws(a){var b=a.a.b;return b.padding?b.padding:new wb("speech"==a.a.style?1.6:0.8,"speech"==a.a.style?1.6:0.8,"speech"==a.a.style?1.6:0.8,"speech"==a.a.style?1.6:0.8)}
-f.show=function(){var a=this.a.b,a=(a&&0==a.a||"title"==this.a.style||"highlightText"==this.a.style||"pause"==this.a.type?!1:!0)&&!this.Ea,b=!this.la,c="widget"==this.a.type;if(a){var d=ts(this);if(d){var e=null;"highlight"==this.a.type||"label"==this.a.style?e=new is:"popup"==this.a.style?e=new ls:"anchored"==this.a.style?e=new gs:"speech"==this.a.style?e=new ms:"image"==this.a.type&&("video"==this.a.style?e=new js(4/3,16/9,!0):"channel"==this.a.style&&(e=new js));e&&(e.ae(this.a,d,vs(this)),this.Ea=
-e,d=e.M())&&(bn(d),V(d,"annotation-type-"+this.a.type.toLowerCase()),this.j(d))}}if(b){d=["annotation","hid"];"highlightText"!=this.a.style||d.push("annotation-no-mouse");d.push("annotation-type-"+this.a.type.toLowerCase());this.la=Pc("div",d);this.a.o&&("label"==this.a.style?(this.b=Pc("div",["label-text"]),this.b.style.backgroundColor=this.a.b.j,Zc(this.b,this.a.o),this.la.appendChild(this.b)):Zc(this.la,this.a.o));Oe(this.la,"annotation_id",this.a.id);this.j(this.la);qs(this,this.la);if(Yp(this.a)&&
-"image"!=this.a.type&&Xp(this.a)){if(d=Ho(this.a))this.la.title=mp(d);this.Yc=Pc("span","annotation-link-icon");this.la.appendChild(this.Yc)}ss(this);Yp(this.a)||(this.la.style.cursor="default")}c&&("subscribe"==this.a.style?E("yt-uix-subscription-button",this.la)||(this.la.innerHTML=this.a.k):this.a.k&&(this.la.innerHTML=this.a.k));if(a||b){t:{a=this.a.a.a;if(a.length&&(a=Jp(a[0]))){a=a.o;break t}a=0}this.la&&(this.la.style.zIndex=a);this.Ea&&this.Ea.M()&&(this.Ea.M().style.zIndex=a)}an(this.la);
-Dd(this.la,us(this)?1:0);jq(this);this.Ea&&an(this.Ea.M())};f.hide=function(){bn(this.la);this.Ea&&bn(this.Ea.M())};function us(a){return"label"!=a.a.style||a.Ea.Tc}function ts(a){var b=a.g.ug;return b?"player_relative"==a.a.H?(a=a.g.Sc)?new Ab(-b.left,-b.top,a.width,a.height):null:new Ab(0,0,b.width,b.height):null};function xs(a){dm.call(this,a);this.b={};this.i={};this.j=new Mr(this.G,this.a.J());var b=Q(a),c=E("html5-annotations-button",b);this.g=this.k=null;a.J().La?(F(c),a=this.a.app.P.A,this.g=new Jo(a,[a.getMsg("YTP_ON"),a.getMsg("YTP_OFF")]),K(this.g,"change",v(this.wr,this)),this.k={label:this.a.app.P.A.getMsg("YTP_ANNOTATIONS_TITLE"),element:this.g,priority:2}):K(c,"click",v(this.ur,this));this.D("onHideControls",this.tr,this);this.D("onShowControls",this.yr,this);this.D("onStateChange",this.xr,this);
-this.D("e",this.Ar,this);this.D("d",this.zr,this);this.D("a",this.rr,this);this.D("b",this.qr,this);this.D("c",this.sr,this);b=E("video-annotations",b);b=E("countdowntimer",b);this.A=Pc("DIV",["video-annotations","html5-stop-propagation"]);gm(this,this.A);gm(this,b);this.B=new Qq(b,v(this.Aj,this))}y(xs,dm);f=xs.prototype;f.na="iv-module";f.Jl=!1;f.Dp=!0;f.Z=!1;f.Cd=0;function ys(a){return E("video-annotations",Q(a))&&zs(a)?new xs(a):null}
-function zs(a){return"leanback"==a.J().Y?!1:Ml(a.getVideoData(),"iv3_module")}f.Xa=function(){return zs(this.a)};f.create=function(){xs.C.create.call(this);this.k&&this.u("module_menu_add",this.k);1==(this.a.J().ca||this.a.getVideoData().ca)?this.load():As(this,"tooltip-default")};f.destroy=function(){this.unload();this.k&&this.u("module_menu_remove",this.k);xs.C.destroy.call(this)};f.ur=function(){this.Z||this.Cd?this.unload():this.load()};
-f.wr=function(){var a=this.Z||this.Cd,b=0==this.g.getSelected();a&&!b?this.unload():!a&&b&&this.load()};f.xr=function(a){this.Dp=P(a.state,8);0>ao(a,4)&&this.B.stop()};
-f.load=function(){xs.C.load.call(this);As(this,"tooltip-alt");var a={format:"XML",method:"GET",td:v(this.Yo,this,null)},b=this.a.getVideoData();b.Pk&&(this.Cd++,ej(b.Pk,a));b.Ok&&(this.Cd++,ej(b.Ok,a));b.Nk&&(this.a.J().Gc||this.a.J().Lc)&&(a={format:"XML",method:"GET",td:v(this.Yo,this,v(this.sv,this,b.Ia))},this.Cd++,ej(b.Nk,a));this.g&&Mo(this.g,0)};
-f.unload=function(){this.g&&Mo(this.g,1);this.j.log_({"iv-event":1});this.Aj();em(this);Cb(this.b,function(a){a.destroy()});Cb(this.i,function(a){a.destroy()});this.Cd=0;this.Z=!1;this.b={};this.i={};As(this,"tooltip-default");xs.C.unload.call(this)};function As(a,b){var c=E("html5-annotations-button",Q(a.a));if(c){var d=G(c,b)||"";Oe(c,"tooltip",d);c.setAttribute("aria-label",d)}}
-function Bs(a,b){for(var c={},d=0;d<b.attributes.length;d++){var e=b.attributes[d];c[e.name]=e.nodeValue}for(d=0;d<b.childNodes.length;d++)if(e=b.childNodes[d],e.tagName){var g;if(c[e.tagName])g=c[e.tagName];else if("html_blob"==e.tagName||"data"==e.tagName){c[e.tagName]=e.childNodes[0].nodeValue.trim();continue}else g=[],c[e.tagName]=g;e&&"TEXT"==e.tagName?1==e.childNodes.length&&3==e.childNodes[0].nodeType?g.push(e.childNodes[0].nodeValue):g.push(""):e&&g.push(Bs(a,e))}return c}
-f.Yo=function(a,b){if(this.Cd&&!this.Z){this.Cd--;var c=b.responseXML?b.responseXML.getElementsByTagName("annotations"):null;if(aj(b)&&c){c=c[0];a&&a(c);Cs(this,c);V(Q(this.a),this.na+"-loaded");0==this.Cd&&(this.Z=!0);var c=[],d;for(d in this.b){var e=this.b[d].ob;if(e.a)if(e=e.a,e.a.length)if(e=e.a[0].b||e.a[0].a,!e||2>e.length)e=null;else var g=e.length-1,e=0>=e[0].b&&0>=e[g].b?null:{start:e[0].b,end:e[g].b};else e=null;else e=null;if(g=e)e=1E3*g.start,g=1E3*g.end,0==e&&(e++,g++),e==g&&g++,g<e||
-(e=new nh(e,g,{id:d}),c.push(e))}for(d in this.i)e=this.i[d].ob,e=new nh(e.data.start_ms,e.data.end_ms,{id:d}),c.push(e);this.yf.apply(this,c)}}};function Ds(a,b){var c=Es(a,b);if(!c)return null;$p(b,function(a){a=v(this.sx,this,b.id,a);this.D("ivTrigger:"+b.id,a)},a);return new gq(a.G,b,c)}
-function Fs(a,b){var c=Pc("div",["annotation","annotation-type-custom","hid"]);a.A.appendChild(c);var d=null;switch(b.style){case "video":d=new Do(b,c,new eo(a),a.a.J(),a.j)}d&&a.G.D("onResize",d.Oo,d);return d}function Cs(a,b){for(var c=b.getElementsByTagName("annotation"),d=0;d<c.length;d++){var e=Bs(a,c[d]),g=null;try{g=Wp(e)}catch(h){}g&&("custom"==g.type?(e=Fs(a,g))&&(a.i[g.id]=e):(e=Ds(a,g))&&(a.b[g.id]=e))}Cb(a.b,function(a){var b=a.ob;b.a&&b.a.b&&(b=this.b[b.a.b])&&(a.b.$k=b.ob)},a)}
-f.vc=function(a){xs.C.vc.call(this,a);a=a.getId();var b=this.b[a],c=this.i[a];c&&!c.xc?c.show():b&&!b.xc&&(b=b.ob,"pause"==b.type?Gs(this,b):(Hs(this,a),a=this.j,b&&b.i&&a.log_(Co(a,b,2))))};f.dd=function(a){xs.C.dd.call(this,a);Is(this,a.getId())};function Gs(a,b){if(a.Dp){var c=Na(b.g,function(a){return"pause"==a.type&&!!a.duration&&!!a.duration.value},void 0);c&&(a.Jl=!0,a.u("command_pause"),a.B.start(1E3*c.duration.value))}}
-function Is(a,b,c,d){var e=a.i[b];if(e&&!e.xc)e.hide();else if(b=a.b[b])iq(b),d=d&&a.b[d]&&a.b[d].isVisible,c&&c.b&&d?(a=v(a.Bo,a,b),b.a=new ho(a,2E3),b.a.start()):a.Bo(b)}f.Bo=function(a){if(a){a.hide();var b=a.ob.id;this.u(fq("shown",b),!1,b);Js(this,a.ob,"hidden")}};function Hs(a,b,c,d){if(b=a.b[b])iq(b),d=d&&a.b[d]&&a.b[d].isVisible,c&&c.i&&d?(a=v(a.Co,a,b),b.a=new ho(a,2E3),b.a.start()):a.Co(b)}f.Co=function(a){if(a){a.show();var b=a.ob.id;this.u(fq("shown",b),!0,b);Js(this,a.ob,"shown")}};
-f.sx=function(a,b,c,d){c?Hs(this,a,b,d):Is(this,a,b,d)};f.rr=function(a){if(a&&a.id){var b=this.j;a&&a.i&&Ho(a)&&b.log_(Co(b,a,8))}};f.qr=function(a){if(a&&a.id){var b=Ho(a),c=v(function(){b&&Js(this,a,"click")},this);Kr(mp(b))&&"new"!=b.target||(c(),c=null);Io(this.j,a,c)}};
-function Js(a,b,c){Zp(b,function(a){if(a.trigger==c)switch(a.type){case "log":a.url&&Kf(a.url.value);break;case "openUrl":var e=this.a.getVideoData(),g=Lr(a.url,e);if(-1!=g){this.u("command_seek",g);this.Aj();break}if(e=(g=mp(a.url))?Kr(g)?Zi(g,{src_vid:e.L,feature:"iv",annotation_id:b.id}):g:null)qm(this),window.open(e,a.url.target?"new"==a.url.target?"_blank":"_top":Kr(mp(a.url))?"_top":"_blank")}},a)}f.tr=function(){this.u(fq("playerControlShow",void 0),!1,void 0)};
-f.yr=function(){this.u(fq("playerControlShow",void 0),!0,void 0)};f.Ar=function(a){a=a.id;this.u(fq("rollOver",a),!0,a)};f.zr=function(a){a=a.id;this.u(fq("rollOver",a),!1,a)};f.sr=function(a){if(a||a.id)if(this.b[a.id].xc=!0,Is(this,a.id),a){var b=this.j;a&&a.i&&b.log_(Co(b,a,4));Js(this,a,"close")}};f.Aj=function(){this.B.stop();this.Jl&&(this.Jl=!1,this.u("command_play"))};
-function Es(a,b){if(Ks(b)){var c=b.G||Ka(b.g,function(a){return"click"==a||"rollOut"==a||"rollOut"==a},void 0);return new ps(b,v(a.A.appendChild,a.A),a.a.J(),a.G,c)}return null}function Ks(a){if("highlight"==a.type||"image"==a.type||"widget"==a.type)return!0;if("text"==a.type)for(var b in Tp)if(a.style==Tp[b])return!0;return!1}
-function Ls(a,b,c,d,e){var g=a.ownerDocument.createElement("action");g.setAttribute("type","log");g.setAttribute("trigger",d);a=a.ownerDocument.createElement("url");d={};d.value="a_id="+c;d.label="cta_annotation_"+e;b=Zi(b,d);a.setAttribute("value",b);g.appendChild(a);return g}
-f.sv=function(a,b){if(a)for(var c=b.getElementsByTagName("annotation"),d=0;d<c.length;d++){var e=c[d],g=Bs(this,e);if(Vo(g,"logable",!0)){var g=Po(g,"id","REQUIRED"),h=e.getElementsByTagName("action"),h=h.length?h[0]:null;e.insertBefore(Ls(e,a,g,"shown","shown"),h);e.insertBefore(Ls(e,a,g,"click","clicked"),h);e.insertBefore(Ls(e,a,g,"close","closed"),h)}}};var Ms;function Ns(a,b){fa(b)&&(b=b.join(" "));if(""===b||void 0==b){var c;Ms||(Ms={atomic:!1,autocomplete:"none",dropeffect:"none",haspopup:!1,live:"off",multiline:!1,multiselectable:!1,orientation:"vertical",readonly:!1,relevant:"additions text",required:!1,sort:"none",busy:!1,disabled:!1,hidden:!1,invalid:"false"});c=Ms;"pressed"in c?a.setAttribute("aria-pressed",c.pressed):a.removeAttribute("aria-pressed")}else a.setAttribute("aria-pressed",b)};function Os(a,b,c,d,e){Om.call(this,a,b,c,c);this.B=b;this.I=this.H=c;this.j=d||null;this.o=e||null;this.G=e||null;this.b=!1}y(Os,Om);function Ps(a){Qm(a,a.b&&a.j?a.j:a.B);Rm(a,a.b&&a.o?a.o:a.H);a.a=a.b&&a.G?a.G:a.I;X(a.element,"ytp-button-pressed",a.b)}function Qs(a){a.b=!0;Ns(a.element,!0);Ps(a)}function Rs(a){a.b=!1;Ns(a.element,!1);Ps(a)}Os.prototype.F=function(){this.G=this.o=this.j=null;vf(this.K);this.K=null;Os.C.F.call(this)};function Ss(a){Z.call(this,["div","ytp-action-buttons"]);this.g=new Os(a,"ytp-button-info",a.getMsg("YTP_BUTTON_INFO"));L(this,this.g);this.g.T(this.element);this.i=new Os(a,"ytp-button-share",a.getMsg("YTP_BUTTON_SHARE"));L(this,this.i);this.i.T(this.element);this.a=new Os(a,"ytp-button-dislike",a.getMsg("YTP_BUTTON_DISLIKE"));L(this,this.a);this.listen(this.a,"click",this.j);this.a.T(this.element);this.b=new Os(a,"ytp-button-like",a.getMsg("YTP_BUTTON_LIKE"));L(this,this.b);this.listen(this.b,"click",
-this.o);this.b.T(this.element);this.b.hide();this.a.hide()}y(Ss,Z);Ss.prototype.o=function(){Qs(this.b);Rs(this.a)};Ss.prototype.j=function(){Qs(this.a);Rs(this.b)};function Ts(a){var b=je("/signin?context=popup","next",document.location.protocol+"//"+document.domain+"/post_login"),b=je(b,"feature","sub_button");if(b=window.open(b,"loginPopup","width=375,height=440,resizable=yes,scrollbars=yes",!0)){var c=Yq("LOGGED_IN",function(b){$q();a(b)});cf("LOGGED_IN_PUBSUB_KEY",c);b.moveTo((screen.width-375)/2,(screen.height-440)/2)}}qa("yt.pubsub.publish",ar);function Us(){this.a={}}y(Us,jr);ca(Us);f=Us.prototype;f.dj="tooltip";f.cj=0;f.register=function(){kr(this,"mouseover",this.aq);kr(this,"mouseout",this.Tl);kr(this,"click",this.Tl);kr(this,"touchstart",this.Yx);kr(this,"touchend",this.hq);kr(this,"touchcancel",this.hq)};f.qq=function(){return!(this.g&&0==nc.indexOf("6"))};
-f.aq=function(a){if(!(this.cj&&1E3>w()-this.cj)){var b=parseInt(G(a,"tooltip-hide-timer"),10);b&&(this.removeData(a,"tooltip-hide-timer"),I(b));var b=v(function(){Vs(this,a);this.removeData(a,"tooltip-show-timer")},this),c=parseInt(G(a,"tooltip-show-delay"),10)||0,b=H(b,c);Oe(a,"tooltip-show-timer",b.toString());a.title&&(lr(a,Ws(a)),a.title="")}};
-f.Tl=function(a){var b=parseInt(G(a,"tooltip-show-timer"),10);b&&(I(b),this.removeData(a,"tooltip-show-timer"));b=v(function(){Xs(this,a);this.removeData(a,"tooltip-hide-timer")},this);b=H(b,50);Oe(a,"tooltip-hide-timer",b.toString());if(b=G(a,"tooltip-text"))a.title=b};f.Yx=function(a,b){this.cj=0;var c=fr(b,$(this),null[0].target);this.aq(c)};f.hq=function(a,b){this.cj=w();var c=fr(b,$(this),null[0].target);this.Tl(c)};function Ys(a,b){lr(a,b);var c=G(a,"content-id");if(c=Ic(c))c.innerHTML=b}
-function Ws(a){return G(a,"tooltip-text")||a.title}
-function Vs(a,b){if(b){var c=Ws(b);if(c){var d=Ic(Zs(a,b));if(!d){d=document.createElement("div");d.id=Zs(a,b);d.className=$(a,"tip");var e=document.createElement("div");e.className=$(a,"tip-body");var g=document.createElement("div");g.className=$(a,"tip-arrow");var h=document.createElement("div");h.className=$(a,"tip-content");var k=$s(a,b),m=Zs(a,b,"content");h.id=m;Oe(b,"content-id",m);e.appendChild(h);k&&d.appendChild(k);d.appendChild(e);d.appendChild(g);(Df()||document.body).appendChild(d);Ys(b,
-c);(c=parseInt(G(b,"tooltip-max-width"),10))&&e.offsetWidth>c&&(e.style.width=c+"px",zc(h,$(a,"normal-wrap")));h=Cc(b,$(a,"reverse"));at(a,b,d,e,k,h)||at(a,b,d,e,k,!h);var p=$(a,"tip-visible");H(function(){zc(d,p)},0)}}}}
-function at(a,b,c,d,e,g){Dc(c,$(a,"tip-reverse"),g);var h=0;g&&(h=1);a=Ad(b);g=new B((a.width-10)/2,g?a.height:0);var k=sd(b);cr(new B(k.x+g.x,k.y+g.y),c,h);h=Nc(window);k=vd(c);c=Ad(d);var m=Math.floor(c.width/2);e&&(e.style.left="3px",e.style.height=c.height+"px",e.style.width=c.width+"px");e=!!(h.height<k.y+a.height);a=!!(k.y<a.height);g=!!(k.x<m);h=!!(h.width<k.x+m);k=(c.width+3)/-2- -5;b=G(b,"force-tooltip-direction");if("left"==b||g)k=-5;else if("right"==b||h)k=20-c.width-3;d.style.left=Math.floor(k)+
-"px";return!(e||a)}function Xs(a,b){if(b){var c=Ic(Zs(a,b));c&&(bt(c),F(c),a.removeData(b,"content-id"))}}function Zs(a,b,c){a=$(a);var d=b.__yt_uid_key;d||(d=Re(),b.__yt_uid_key=d);b=a+d;c&&(b+="-"+c);return b}function $s(a,b){var c=null;Vb&&Cc(b,$(a,"masked"))&&((c=Ic("yt-uix-tooltip-shared-mask"))?(c.parentNode.removeChild(c),an(c)):(c=document.createElement("iframe"),c.src='javascript:""',c.id="yt-uix-tooltip-shared-mask",c.className=$(a,"tip-mask")));return c}
-function bt(a){var b=Ic("yt-uix-tooltip-shared-mask"),c=b&&fd(b,function(b){return b==a},!1,2);b&&c&&(b.parentNode.removeChild(b),bn(b),document.body.appendChild(b))};function ct(){this.a={};this.i=[]}y(ct,jr);ca(ct);ct.prototype.dj="subscription-button";
-ct.prototype.register=function(){kr(this,"click",this.Lp);this.i.push(Yq("subscription-subscribe-loading",this.Kp,this),Yq("subscription-subscribe-loaded",this.Jp,this),Yq("subscription-unsubscirbe-loading",this.Kp,this),Yq("subscription-unsubscribe-loaded",this.Jp,this),Yq("subscription-subscribe-success",this.Yw,this),Yq("subscription-unsubscribe-success",this.Zw,this),Yq("subscription-enable-ypc",this.Xw,this),Yq("subscription-disable-ypc",this.Ww,this))};
-var dt={$p:"hover-enabled",Sx:"yt-uix-button-subscribe",Tx:"yt-uix-button-subscribed",fA:"ypc-enabled",hy:"yt-uix-button-subscription-container",iy:"yt-subscription-button-disabled-mask-container"},et={tA:"channel-external-id",Ux:"subscriber-count-show-when-subscribed",Vx:"subscriber-count-tooltip",Wx:"subscriber-count-title",SB:"href",mq:"is-subscribed",zC:"parent-url",QC:"sessionlink",Xx:"style-type",nq:"subscription-id",$C:"target",Zx:"ypc-enabled",fq:"ypc-item-type",dq:"ypc-item-id",gq:"ypc-offers-url"};
-f=ct.prototype;f.Lp=function(a){var b=G(a,"href"),c=!!gf("subscription_ajax");if(b)a=G(a,"target")||"_self",window.open(b,a);else if(c){var b=G(a,"channel-external-id"),c=G(a,"sessionlink"),d;if(G(a,"ypc-enabled")){d=G(a,et.fq);var e=G(a,et.dq),g=G(a,et.gq);d={itemType:d,itemId:e,offersUrl:g,subscriptionElement:a}}else d=null;e=G(a,"parent-url");G(a,"is-subscribed")?(g=G(a,"subscription-id"),ar("subscription-unsubscribe",b,g,d,a,c,e)):ar("subscription-subscribe",b,d,a,c,e)}else ft(this,a)};
-f.Kp=function(a){this.ag(a,this.kq,!0)};f.Jp=function(a){this.ag(a,this.kq,!1)};f.Yw=function(a,b){this.ag(a,this.lq,!0,b)};f.Zw=function(a){this.ag(a,this.lq,!1)};f.Xw=function(a){this.ag(a,this.by)};f.Ww=function(a){this.ag(a,this.ay)};f.lq=function(a,b,c){b?(Oe(a,et.mq,"true"),c&&Oe(a,et.nq,c)):(this.removeData(a,et.mq),this.removeData(a,et.nq));gt(a)};f.kq=function(a,b){var c=ed(a,dt.hy);Dc(c,dt.iy,b);a.setAttribute("aria-busy",b?"true":"false");a.disabled=b};
-function gt(a){var b=G(a,et.Xx),c=!!G(a,"is-subscribed"),b="-"+b,d=dt.Tx+b;Dc(a,dt.Sx+b,!c);Dc(a,d,c);G(a,et.Vx)&&!G(a,et.Ux)&&(b=$(Us.getInstance()),Dc(a,b,!c),a.title=c?"":G(a,et.Wx));c?H(function(){zc(a,dt.$p)},1E3):Ac(a,dt.$p)}f.by=function(a){var b=!!G(a,et.fq),c=!!G(a,et.dq),d=!!G(a,et.gq);!G(a,"ypc-enabled")&&b&&c&&d&&(zc(a,"ypc-enabled"),Oe(a,et.Zx,"true"))};f.ay=function(a){G(a,"ypc-enabled")&&(Ac(a,"ypc-enabled"),this.removeData(a,"ypc-enabled"))};
-function ht(a,b){var c=Jc($(a));return Ia(c,function(a){return b==G(a,"channel-external-id")},a)}f.sy=function(a,b,c){var d=ab(arguments,2);z(a,function(a){b.apply(this,Xa(a,d))},this)};f.ag=function(a,b,c){var d=ht(this,a),d=Xa([d],ab(arguments,1));this.sy.apply(this,d)};function ft(a,b){var c=v(function(a){a.subscription_ajax&&ff("subscription_ajax",a.subscription_ajax);this.Lp(b)},a);Ts(c)};function it(a){this.b=a||1;Sm.call(this,30*this.b,30*this.b);this.o=this.width/2;this.i=this.height/2;this.G=0;this.X.translate(this.o,this.i)}y(it,Sm);it.prototype.show=function(){it.C.show.call(this);var a=this.B;this.j=new Date;this.g(a,125)};
-it.prototype.B=function(){this.X.clearRect(-this.o,-this.i,this.width,this.height);for(var a=this.G++%8,b=0;8>b;b++){var c=2*Math.PI/8*(a+b),d=11*this.b*Math.cos(c),c=11*this.b*Math.sin(c),e=(b+1)/9;this.X.beginPath();this.X.arc(d,c,4*this.b,0,2*Math.PI,!1);this.X.fillStyle="rgba(189, 189, 189, "+e+")";this.X.fill()}};it.prototype.hide=function(){I(this.a);it.C.hide.call(this)};function jt(){Z.call(this,["div","ytp-sentiment-display",["div","ytp-sentiment-bar",["div","ytp-sentiment-bar-likes"],["div","ytp-sentiment-bar-dislikes"]],["div","ytp-sentiment-text","{{sentiment}}"]]);this.b=this.template.a["ytp-sentiment-bar-likes"];this.a=this.template.a["ytp-sentiment-bar-dislikes"]}y(jt,Z);jt.prototype.F=function(){this.a=this.b=null;jt.C.F.call(this)};function kt(a){a=["button","ytp-button-share-more",["div","ytp-button-share-more-icon yt-uix-button-icon-new-window"],["span","ytp-button-share-more-content",a.getMsg("YTP_BUTTON_MORE_SHARE")]];Z.call(this,a)}y(kt,Z);function lt(a,b,c,d){Om.call(this,a,"share-service-icon-"+d+"-sharebar",b,c);V(this.element,"share-service-icon-sharebar")}y(lt,Om);function mt(){Z.call(this,["div","ytp-share-url-container",["input","ytp-share-url"]]);this.a=this.template.a["ytp-share-url"]}y(mt,Z);mt.prototype.F=function(){this.a=null;mt.C.F.call(this)};function nt(a,b,c){R.call(this);this.a=a;this.g=b;this.i=c;this.eb=new eo(this);this.j=this.b=this.k=this.ia=null;this.A=this.o=!1}y(nt,R);f=nt.prototype;f.Rj=function(){var a=E("html5-title",this.a);this.k=E("html5-title-text",a);this.eb.listen(this.k,"click",this.Fn);this.b=new Ss(this.i);this.b.T(a,1);this.eb.listen(this.b.g,"click",this.ek);this.g.nf&&this.b.g.hide();this.eb.listen(this.b.i,"click",this.ai)};f.reset=function(){};
-f.update=function(a){this.ia=a;this.reset();Zc(this.k,a.title||"");an(this.a)};f.Fn=function(){this.Ki(this.ia.Oc||ot(this.g,this.ia))};f.ek=function(){if(!this.o){this.o=!0;Cm(this.ia?this.ia.L:void 0,!1,this.Ns,ba,this,this.g.Da,this.g.Ta);if(!this.j){var a=E("html5-info-panel-loading-icon",this.a);this.j=new it;V(this.j.element,"html5-info-panel-loader");this.j.T(a);L(this,this.j)}this.j.show()}Rs(this.b.i);W(this.a,"show-share");a=this.b.g;a.b?Rs(a):Qs(a);return bm(this.a,"show-more-info")};
-f.ai=function(a){Rs(this.b.g);W(this.a,"show-more-info");if("detailpage"!=this.g.Y){if(!this.A){this.A=!0;var b={action_get_share_info:1,feature:"player_embedded",video_id:this.ia?this.ia.L:void 0};this.g.Da&&(b.authuser=this.g.Da);this.g.Ta&&(b.pageid=this.g.Ta);ej("/share_ajax",{X:this,method:"GET",onError:this.Xt,Oa:this.Yt,zf:b})}a&&a.stopPropagation();a=this.b.i;a.b?Rs(a):Qs(a);bm(this.a,"show-share")}};
-f.Ns=function(a,b){if(!this.ha()){var c=E("html5-info-panel",this.a),d=b.user_info;this.ia&&(this.ia.ua=d.external_id);var e=E("html5-author-img",c).getElementsByTagName("img")[0];e.src=d.image_url;this.eb.listen(e,"click",this.Wn);e=E("html5-author-name",c);Zc(e,d.username);this.eb.listen(e,"click",this.Wn);e=b.video_info;e.subscription_ajax_token&&ff("subscription_ajax",e.subscription_ajax_token);var g=E("html5-subscribe-button-container",c);g.innerHTML=d.subscription_button_html?d.subscription_button_html:
-"";d=ct.getInstance();(d=E($(d),g))&&pt(this.i,d);E("html5-view-count",c).innerHTML=e.view_count_string;var h=parseInt(e.likes_count_unformatted,10),g=parseInt(e.dislikes_count_unformatted,10),d=new jt,k=0,m=0;0<h+g&&(k=100*h/(h+g),m=100*g/(h+g));d.b.style.width=k+"%";d.a.style.width=m+"%";h=nf("YTP_SENTIMENT_LIKE",h);g=nf("YTP_SENTIMENT_DISLIKE",g);xm(d.template,"sentiment",h+", "+g);d.T(E("html5-video-info",c),2);d=E("html5-description-text",c);Zc(d,e.description);this.j.hide();c=E("html5-info-panel-content",
-c);an(c)}};
-f.Yt=function(a,b){if(!this.ha()){var c=E("share-bar"),d=new mt;Lc(d.a,{value:b.url_short});d.T(c);Zl(this.a,"show-share")&&(d.a.focus(),d.a.select());for(var d=b.links,e=0;e<Math.min(3,d.length);e++){var g=new lt(this.i,d[e].name,d[e].sname,d[e].img);g.T(c);this.eb.listen(g,"click",oa(Dr,d[e].url,{}))}d=new kt(this.i);this.eb.listen(d,"click",v(this.Ki,this,b.more));d.T(c);d=new Om(this.i,"yt-uix-button-icon-share-bar-close",this.i.getMsg("YTP_BUTTON_CLOSE"),this.i.getMsg("YTP_BUTTON_CLOSE"));d.T(c);
-this.eb.listen(d,"click",this.ai)}};f.Xt=function(){};f.Wn=function(){var a=this.g,b=this.ia,c="",c=b.ua?a.ib+"channel/UC"+b.ua:a.ib+"user/"+b.author;this.Ki(c)};f.Ki=function(a){Cr(a)};f.F=function(){this.eb.removeAll();this.ia=this.k=this.g=this.a=null;nt.C.F.call(this)};function qt(){Z.call(this,["div","ytp-playlist-tray-index-length",["span","ytp-playlist-tray-index","{{index}}"],["span",""," / "],["span","ytp-playlist-tray-length","{{length}}"]])}y(qt,Z);qt.prototype.Hg=function(a){xm(this.template,"index",a+1)};function rt(a){Os.call(this,a,"ytp-button-expand",a.getMsg("YTP_BUTTON_EXPAND"),"ytp-button-collapse",a.getMsg("YTP_BUTTON_COLLAPSE"));this.Aa([["div","ytp-button-playlist-icon"],["div","ytp-button-playlist-text",a.getMsg("YTP_BUTTON_PLAYLIST")]])}y(rt,Os);function st(a){Z.call(this,["div","ytp-playlist-tray-controller"]);this.b=new rt(a);this.b.T(this.template.M());L(this,this.b);this.a=new qt;this.a.T(this.template.M());L(this,this.a)}y(st,Z);function tt(a,b,c,d){a=["div","ytp-playlist-tray-action-info",["div","ytp-playlist-tray-playlist-title",b],["div","ytp-playlist-tray-author-name",a.getMsg("YTP_AUTHOR_ATTRIBUTION",{author:c})],["div","ytp-playlist-tray-description-text",d]];Z.call(this,a)}y(tt,Z);function ut(a){var b=["div","ytp-playlist-tray-action-share",["div","ytp-playlist-tray-action-share-heading",a.getMsg("YTP_SHARE_PLAYLIST")],["div","share-bar-services"]];Z.call(this,b);this.i=a;this.g=new eo(this);this.b=this.a=null}y(ut,Z);ut.prototype.F=function(){this.g.removeAll();this.g=null;ut.C.F.call(this)};function vt(a){R.call(this);this.g=new eo;this.A=E("html5-playlist",a);this.b=E("html5-playlist-message",a);this.i=E("html5-playlist-title",a);this.j=E("html5-playlist-pager",a);this.k=E("html5-playlist-pager-button-left",this.j);this.o=E("html5-playlist-pager-button-right",this.j);K(this.k,"click",v(this.Dr,this));K(this.o,"click",v(this.Er,this));this.a=E("html5-playlist-strip",a);this.wf=Ad(this.A).width;this.B=E("html5-playlist-thumbnail",this.a);F(this.B)}y(vt,R);f=vt.prototype;f.wf=0;f.Ua=null;
-function wt(a,b){b!=a.Ua&&(a.Ua&&a.Ua.W("shuffle",a.gh,a),a.Ua=b,a.Ua.D("shuffle",a.gh,a),Zc(a.b,"Playlist"),""==a.Ua.title?Zc(a.i,"unknown"):Zc(a.i,a.Ua.title+" ("+a.Ua.Pa+(1==a.Ua.Pa?" video)":" videos)")),a.gh())}f.hv=function(a){this.u("playvideoat",a.currentTarget["playlist-index"])};f.iv=function(a){a=a.currentTarget["playlist-index"];var b=qg(this.Ua,a);a==this.Ua.pa?Zc(this.b,"Currently playing"):Zc(this.b,"Switch to");Zc(this.i,b.title)};
-f.jv=function(){Zc(this.b,"Playlist");Zc(this.i,this.Ua.title+" ("+this.Ua.Pa+(1==this.Ua.Pa?" video)":" videos)"))};function xt(a){var b=Jc("html5-playlist-thumbnail"),c=a.Ua.pa;z(b,function(a){X(a,"html5-playlist-thumbnail-current",a["playlist-index"]==c)})}f.Dr=function(){this.a.style.left=Math.min(od(this.a).x+this.wf,0)+"px";this.gh()};f.Er=function(){this.a.style.left=Math.max(od(this.a).x-this.wf,this.wf-(92*this.Ua.Pa+2))+"px";this.gh()};
-f.gh=function(){this.g.removeAll();for(var a=this.a.cloneNode(!1),b=Math.max(0,Math.floor((-1*od(this.a).x-2)/92)),c=Math.min(this.Ua.Pa-1,Math.ceil(b+this.wf/92));b<=c;b++){var d=this.B.cloneNode(!1),e=qg(this.Ua,b);d.src=kn(e.L);d["playlist-index"]=b;d.style.left=92*b+2+"px";this.g.listen(d,"click",v(this.hv,this));this.g.listen(d,"mouseenter",v(this.iv,this));this.g.listen(d,"mouseleave",v(this.jv,this));a.appendChild(d)}xt(this);this.j.style.display=92*this.Ua.Pa+2>this.wf?"block":"none";c=this.a;
-(b=c.parentNode)&&b.replaceChild(a,c);this.a=a;xt(this)};f.F=function(){Af(this.k);Af(this.o);this.g.removeAll();this.o=this.k=this.j=this.i=this.b=this.A=null;vt.C.F.call(this)};function zt(a,b){Z.call(this,["div","ytp-playlist-tray-item",["span","ytp-playlist-tray-item-index","{{index}}"],["span","ytp-playlist-tray-item-now-playing","\u25b6"],["img","ytp-playlist-tray-item-thumbnail",{src:"{{image}}"}],["span","ytp-playlist-tray-item-title","{{title}}"],["span","ytp-playlist-tray-item-author","{{author}}"]]);this.a=b;this.template.update({index:b+1,title:a.title,author:a.author,image:kn(a.L)})}y(zt,Z);
-zt.prototype.Hg=function(a){X(this.element,"ytp-playlist-tray-item-current",this.a==a)};function At(){Z.call(this,["div","ytp-playlist-tray-tray"]);this.a=null;this.i=new eo(this);this.b=[]}y(At,Z);function Bt(a,b){b!=a.a&&(a.a&&a.a.W("shuffle",a.g,a),a.a=b,a.a.D("shuffle",a.g,a),a.g())}At.prototype.g=function(){this.i.removeAll();this.b=[];Vc(this.element);for(var a=0;a<=this.a.Pa-1;++a){var b=new zt(qg(this.a,a),a);b.Hg(this.a.pa);this.b.push(b);this.i.listen(b,"click",oa(this.j,a));b.T(this.element)}};
-At.prototype.j=function(a){a={index:a};var b=document.createEvent("CustomEvent");b.initCustomEvent("playvideoat",!0,!0,a||null);this.dispatchEvent(b)};At.prototype.F=function(){this.i.removeAll();At.C.F.call(this)};function Ct(a){dm.call(this,a);var b=Q(a);this.A=new eo(this);this.B=a.app.P.A;this.i=new vt(b);this.i.D("playvideoat",a.sj,a);L(this,this.i);this.j=new sm(["div",["ytp-playlist-tray-container","html5-stop-propagation"],["div",["ytp-playlist-tray-info","show-more-info"]]]);L(this,this.j);this.g=new At;this.A.listen(this.g,"playvideoat",v(function(b){a.sj(b.detail.index)},a));L(this,this.g);this.k=E("html5-playlist-button",b);K(this.k,"click",v(this.Lm,this));this.I=this.H=null;this.K=!1;this.b=null;
-this.D("fullscreentoggled",this.gr,this);this.a.ub()&&a.J().Ma&&(F(E("html5-playlist",Q(this.a))),F(this.k),this.a.app.P.g.appendChild(this.j.M()),this.g.T(this.j.M(),0),this.b=new st(this.B),this.xm(),this.b.T(E("html5-title",void 0),0),this.A.listen(this.b.b,"click",this.Lm),this.D("videodatachange",this.jr,this),this.D("onResize",this.wm,this),this.D("clearvideooverlays",this.unload,this))}y(Ct,dm);f=Ct.prototype;f.na="playlist";
-f.create=function(){var a=this.a.ub();wt(this.i,a);xt(this.i);Bt(this.g,a);for(var b=this.g,c=0;c<b.b.length;c++)b.b[c].Hg(b.a.pa);a.D("shuffle",this.xm,this);Ct.C.create.call(this)};f.xm=function(){this.b.a.Hg(this.a.Wj());var a=Vl(this.a.ub());xm(this.b.a.template,"length",a)};f.destroy=function(){this.a.ub()||(wt(this.i,null),Bt(this.g,null),Ct.C.destroy.call(this))};f.load=function(){this.Z=!0;Ct.C.load.call(this);Qs(this.b.b)};f.unload=function(){this.Z=!1;Ct.C.unload.call(this);Rs(this.b.b)};
-f.Lm=function(){if(this.Z)this.unload();else if(this.u("command_clear_video_overlays"),this.load(),this.wm(),!this.H){var a=E("ytp-playlist-tray-info"),b=new Ss(this.B);b.T(a,0);this.A.listen(b.g,"click",this.Ku);this.A.listen(b.i,"click",this.Lu);b=this.a.ub();this.H=new tt(this.B,b.title,b.author,b.description);this.H.T(a)}};f.Ku=function(){var a=E("ytp-playlist-tray-info");zc(a,"show-more-info");Ac(a,"show-share")};
-f.Lu=function(){var a=E("ytp-playlist-tray-info");Ac(a,"show-more-info");zc(a,"show-share");this.K||(this.I=new ut(this.B),this.I.T(a),this.K=!0,ej("/share_ajax",{X:this,method:"GET",onError:this.mv,Oa:this.nv,zf:{action_get_share_info:1,feature:"player_embedded",video_id:this.a.getVideoData().L,list:this.a.ub().g}}))};f.hide=function(){var a=E("ytp-playlist-tray-info");Ac(a,"show-more-info");Ac(a,"show-share")};
-f.nv=function(a,b){var c=this.I;c.g.removeAll();var d=b.links,e=c.template.a["share-bar-services"];Vc(e);for(var g=0;g<Math.min(3,d.length);g++){var h=new lt(c.i,d[g].name,d[g].sname,d[g].img);h.T(e);c.g.listen(h,"click",oa(Dr,d[g].url))}c.a&&F(c.a.element);c.a=new kt(c.i);c.g.listen(c.a,"click",oa(Cr,b.more));c.a.T(c.element);c.b&&F(c.b.element);c.b=new mt;Lc(c.b.a,{value:b.url_short});c.b.T(c.element)};f.mv=function(){};f.gr=function(a){var b=this.a.J().Y;this.Z&&!a&&"detailpage"==b&&this.unload()};
-f.jr=function(){this.b.a.Hg(this.a.Wj());var a=Vl(this.a.ub());xm(this.b.a.template,"length",a)};f.wm=function(){var a=Ad(this.j.M());X(this.j.M(),"show-tray-panel",560<a.width)};f.Xa=function(){return!this.Hd&&!!this.a.ub()};f.F=function(){Af(this.k);this.k=null;Ct.C.F.call(this)};function Dt(a){return new Ct(a)};var Et=RegExp("^(ar|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Arab|Hebr|Thaa|Nkoo|Tfng))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)","i");function Ft(a,b){am(a,["html5-async-progress","html5-async-success","html5-async-error"]);b&&V(a,b);Xs(Us.getInstance(),a)};function Gt(a,b,c,d){if(this.g=!!c)this.gl=Math.max(800,this.gl);this.element=a;this.H=b;this.k=d;Ht?a.ontouchstart=v(this.kw,this):a.onmousedown=v(this.jw,this);a.onclick=v(this.Tn,this)}var Ht="ontouchstart"in document,It=[],Jt=!1;function Kt(){Ht&&!Jt&&(Jt=!0,document.addEventListener("click",function(a){for(var b=new B(a.clientX,a.clientY),c=0,d;d=It[c];c++)if(25>ub(d,b)){a.stopPropagation();a.preventDefault();It.splice(c,1);break}},!0))}
-function Lt(a){It.push(a);window.setTimeout(function(){var b=It.indexOf(a);-1!=b&&It.splice(b,1)},2500)}f=Gt.prototype;f.gl=1E3;
-f.kw=function(a){if(!(1<a.touches.length||a._stop)){this.a=a._stop=!0;this.g||(this.element.ontouchend=v(this.Tn,this),document.body.addEventListener("touchend",Mt(this),!1));document.body.addEventListener("touchmove",Nt(this),!1);document.body.addEventListener("touchcancel",Mt(this),!1);Ot(this,a);this.G=window.setTimeout(v(this.qi,this,!0),100);var b=a.touches[0];this.b=new B(b.clientX,b.clientY);this.g||this.k&&!this.k(a)||Lt(this.b)}};
-f.jw=function(a){a.stopPropagation();this.a=!0;Ot(this,a);this.qi(!0)};f.Tn=function(a){"touchend"==a.type&&!this.a||a._stop||(a._stop=!0,this.qi(!0),window.setTimeout(v(function(){this.Hi();this.H(a)},this),0))};f.bx=function(a){1<a.touches.length?this.Hi():(a=a.touches[0],a=new B(a.clientX,a.clientY),this.b&&12<ub(this.b,a)&&this.Hi())};function Nt(a){a.i||(a.i=v(a.bx,a));return a.i}
-f.Hi=function(){window.clearTimeout(this.G);window.clearTimeout(this.A);this.qi(!1);this.a=!1;document.body.removeEventListener("touchmove",Nt(this),!1);document.body.removeEventListener("touchend",Mt(this),!1);document.body.removeEventListener("touchcancel",Mt(this),!1)};function Mt(a){a.j||(a.j=v(a.Hi,a));return a.j}f.qi=function(a){this.B&&Dc(this.element,this.B,a)};function Ot(a,b){a.o&&(a.A=window.setTimeout(v(function(){this.a=!1;this.o(b)},a),a.gl))};function Pt(a){Om.call(this,a);this.element.setAttribute("tabindex",15);Qt(this)}y(Pt,Om);function Qt(a){Qm(a,"ytp-button-fullscreen-enter");var b=a.g.getMsg("YTP_BUTTON_FULLSCREEN_ENTER");Rm(a,b);a.a=b};function Rt(){Z.call(this,["div",["ytp-menu","html5-stop-propagation"],"{{content}}"]);this.a=[];this.stopPropagation("click")}y(Rt,Z);Rt.prototype.add=function(a){for(var b=this.a.length,c=0;c<this.a.length;c++){if(this.a[c]==a)return;if(c<b&&this.a[c].priority<a.priority){b=c;break}}$a(this.a,b,0,a);St(this)};Rt.prototype.remove=function(a){Ua(this.a,a);St(this)};
-function St(a){var b;if(1==a.a.length)b=new Z(["div","ytp-menu-content",["div","ytp-menu-row",["div","ytp-menu-cell",a.a[0].label]],["div","ytp-menu-row",["div","ytp-menu-cell","{{content}}"]]]),b.Aa(a.a[0].element);else{b=new Z(["div","ytp-menu-content"]);for(var c=0;c<a.a.length;c++){var d=new Z(["div","ytp-menu-row",["div",["ytp-menu-cell","ytp-menu-title"],a.a[c].label],["div","ytp-menu-cell","{{content}}"]]);d.Aa(a.a[c].element);d.T(b.M())}}a.Aa(b)}Rt.prototype.F=function(){this.a=null;Rt.C.F.call(this)};function Tt(a){Om.call(this,a);this.element.setAttribute("tabindex",3);Ut(this)}y(Tt,Om);function Ut(a){Qm(a,"ytp-button-play");var b=a.g.getMsg("YTP_BUTTON_PLAY");Rm(a,b);a.a=b};function Vt(a){Z.call(this,["div","ytp-playlist-controls","{{content}}"]);this.b=new Om(a,"ytp-button-prev",a.getMsg("YTP_BUTTON_PREV"),a.getMsg("YTP_BUTTON_PREV"));L(this,this.b);this.a=new Om(a,"ytp-button-next",a.getMsg("YTP_BUTTON_NEXT"),a.getMsg("YTP_BUTTON_NEXT"));L(this,this.a);this.Aa([this.b,this.a])}y(Vt,Z);function Wt(a,b,c,d){var e=Math.min(c/(b.eo/b.wi),d/(b.co/b.rows)),g=b.eo*e,e=b.co*e,g=Math.floor(g/b.wi)*b.wi,e=Math.floor(e/b.rows)*b.rows,h=g/b.wi,k=e/b.rows,m=Math.floor((c-h)/2);c=Math.ceil((c-h)/2);d=Math.floor((d-k)/2);id(a,{width:h+"px",height:k+"px","margin-top":d+"px","margin-bottom":d+"px","margin-left":m+"px","margin-right":c+"px","background-image":"url("+b.url+")","background-position":-1*b.su*h+"px "+-1*b.row*k+"px","background-size":g+"px "+e+"px"})};function Xt(){this.a=new zr(this.Rv,250,this);L(this,this.a)}y(Xt,Lf);f=Xt.prototype;f.Go=!1;f.wd=null;f.$b=null;f.Wh=null;f.Yj=null;f.Zj=null;f.wg=null;f.Fe=0;f.Dk=0;f.fl=0;f.Uo=10;f.Lb=0;f.Ii=0;f.ll=0;f.$c=null;f.Le=null;f.Pe=0;f.disable=function(){this.Go=!0};f.Va=function(a){this.Pe=a};f.Eo=function(a,b){this.$b.style.display="none";for(var c,d,e=a;e<=b;e++)if(d=this.$b.children[e])c=Mk(this.Le,e,this.Lb),Wt(d,c,this.Lb,this.Ii);this.$b.style.display=""};
-function Yt(a,b){if(b!=a.ll){var c=Mk(a.Le,b,2*a.Lb),d=Math.round(2*a.Lb),e=Math.round(2*a.Ii);Wt(a.Yj,c,d,e);a.ll=b}}f.Rv=function(){for(var a=this.Dk,b=Math.max(Math.floor(a/this.Lb),0),a=Math.min(Math.ceil((a+this.Fe)/this.Lb),this.$c.a[0].b-1);b<=a;b++){for(var c=this.Le,d=b,e=nk(c.a,2*this.Lb),g=void 0,h=void 0;0<=e;e--)if(g=c.a.a[e],h=Math.floor(d/(g.a*g.g)),!g.i[h]){var g=c,k=e,m=k+"-"+h;g.i[m]||(g.i[m]=!0,Jk(g.g,k,{zn:k,An:h}))}Nk(c)}};
-function Zt(a,b){a.Uo=Math.min(10,Math.ceil(a.Fe/72));a.Lb=Math.floor(a.Fe/a.Uo);a.Ii=0.555*a.Lb;a.fl=a.Lb*a.$c.a[0].b;zd(a.$b,a.fl);var c=Math.round(2*a.Lb),d=0.555*c+12;yd(a.Wh,c,d);md(a.Wh,(a.Fe-c)/2);a.wd.style.height=nd(d+20,!0);b&&(a.Eo(0,a.$c.a[0].b-1),Yt(a,a.ll))}f.F=function(){this.wg=this.Zj=this.Yj=this.Wh=this.$b=this.wd=this.Le=this.$c=null;Xt.C.F.call(this)};function $t(a,b,c,d){this.width=b;this.a=c;this.i=d;this.b=b-c-d;this.g=tb(a-c,0,this.b);this.position=this.g+c;this.vd=this.g/this.b};function au(){Z.call(this,["div",["ytp-progress-magnifier","html5-draggable"],["div","ytp-progress-magnifier-play-progress"],["div","ytp-progress-magnifier-load-progress"],["div","ytp-progress-magnifier-scrubber-button"]]);this.i=this.template.a["ytp-progress-magnifier-load-progress"];this.o=0;this.j=this.template.a["ytp-progress-magnifier-play-progress"];this.G=0;this.b=[];this.g=this.template.a["ytp-progress-magnifier-scrubber-button"]}y(au,Z);
-function bu(a,b){var c=a.a,d=c.width-4,e=d-2*a.Pe;if(ga(b))var d=cu(a).position,g=a.M().offsetWidth/2,d=tb(b,d-g,d+g);else d=2+c.vd*d;return new $t(d,c.width,2+c.vd*e,2+(1-c.vd)*e)}function cu(a){var b=a.a;a=a.M().offsetWidth/2+2;return new $t(b.position,b.width,a,a)}au.prototype.disable=function(){this.a=null};
-function du(a,b){if(a.a){var c=a.M(),d=cu(a),e=bu(a),g=c.offsetWidth/2,h=d.position-g,d=d.position+g;c.style.left=h+"px";var k=a.o*e.b+e.a,m=a.G*e.b+e.a,p=a.g.offsetWidth,s=m-h-p/2;s>-p&&s<2*g+p?(a.g.style.left=s+"px",ym(a.g)):zm(a.g);m-=h;0<=m?(zd(a.j,Math.min(m,2*g)),ym(a.j)):zm(a.j);k-=h;0<=k?(zd(a.i,Math.min(k,2*g)),ym(a.i)):zm(a.i);if(b){g=(h-e.a)/2/60;e=(d-e.a)/2/60;h=0;for(d=Math.ceil(g);d<=e;d++)h<a.b.length?k=a.b[h]:(k=document.createElement("div"),a.b[h]=k,c.appendChild(k)),k.className=
-0==d%60?"ytp-progress-magnifier-60m":0==d%30?"ytp-progress-magnifier-30m":0==d%15?"ytp-progress-magnifier-15m":"ytp-progress-magnifier-1m",k.style.left=120*(d-g)+"px",h++;for(;h<a.b.length;)F(a.b.pop())}}}au.prototype.Va=function(a){this.Pe=a;du(this,!0)};au.prototype.F=function(){this.g=this.b=this.j=this.i=null;au.C.F.call(this)};function eu(){}y(eu,Lf);f=eu.prototype;f.ii=!1;f.Pe=0;f.Hb=null;f.Jh=null;f.$j=null;f.zj=null;f.Eg=null;f.hh=null;f.disable=function(){this.ii=!0};f.show=function(){this.ii||an(this.Hb)};f.hide=function(){bn(this.Hb)};f.Va=function(a){this.Pe=a};f.reset=function(){W(this.Hb,"with-thumbnail");this.hh=this.Eg=null};f.Zu=function(a,b){(a<=this.a||this.a<=b)&&fu(this)};function fu(a){var b=Mk(a.hh,a.a,108);Wt(a.$j,b,108,60)}f.F=function(){this.zj=this.$j=this.Jh=this.Hb=this.hh=this.Eg=null;eu.C.F.call(this)};function gu(a){R.call(this);this.hb=a;this.ua=null;this.K={};this.ea=NaN;this.$=this.U=this.N=null;this.ba=NaN;this.o=this.g=this.H=null;this.k=new eo(this);this.Ra="";this.La=null;this.fa=0;this.qb=null;this.va=0;this.a=this.b=this.gb=this.i=this.S=this.da=null;this.za=new eo(this);this.ra=null;this.Ia=new eo(this);this.A=this.I=!1;this.O=this.R=this.ca=null;this.j=this.Ma=this.oa=this.B=0}y(gu,R);
-function hu(a,b){a.g=b;a.i=E("html5-progress-bar",a.g);a.k.listen(a.i,"click",a.Rh);fo(a.k,a.i,"down",a.Lv);a.Ra=fo(a.k,a.i,"over",a.sn);a.S=E("html5-progress-list",a.i);a.qb=E("html5-play-progress",a.S);a.La=E("html5-load-progress",a.S);a.da=E("html5-highlight",a.S);a.ua=E("html5-ad-progress-list",a.i);a.ra=E("html5-scrubber-button",a.i);a.U=E("html5-clip-exclusion",a.i);a.$=a.U.cloneNode(!1);a.U.parentNode.appendChild(a.$);a.H=E("html5-clip-start",a.i);fo(a.k,a.H,"over",a.lp);fo(a.k,a.H,"out",a.kp);
-a.k.listen(a.H,"click",a.rl);a.N=E("html5-clip-end",a.i);fo(a.k,a.N,"over",a.lp);fo(a.k,a.N,"out",a.kp);a.k.listen(a.N,"click",a.rl);a.gb=E("html5-progress-screenreader",a.i)}f=gu.prototype;
-f.sn=function(a){if(!this.I){this.k.Vc(this.Ra);this.A=!1;this.R=this.ca=a=new B(a.pageX,a.pageY);if(this.a&&5400<=this.B){I(this.oa);this.a.show();an(this.da);a=this.a;var b=iu(this);a.a=b;du(a,!0);a=oa(V,this.g,"html5-progress-magnifier-hover");this.oa=H(a,0)}this.b&&this.b.show();fo(this.za,this.g,"move",this.yn);fo(this.za,this.g,"out",this.au)}};function ju(a){a.A=!1;I(a.oa);W(a.g,"html5-progress-magnifier-hover");var b=Wq(a.a.M());a.oa=H(v(function(){this.a.hide();bn(this.da)},a),b)}
-f.au=function(a){this.I||a.relatedTarget&&!(this.b&&Yc(this.b.Hb,a.relatedTarget)||!Yc(this.g,a.relatedTarget))||ku(this)};
-f.yn=function(a){var b=new B(a.pageX,a.pageY);if(this.a&&this.a.a)if(this.I)this.A?this.O=b:this.R=b;else{var c=Cd(this.a.M());if(c.contains(b))this.O=b,this.A=!0;else{var d=Cd(this.S),e=this.ca.y-a.pageY;if(a.pageX>=c.left&&a.pageY>=c.top&&a.pageX<c.left+c.width||d.contains(b)){c=6*e-6;if(a.pageX>=this.ca.x-c&&a.pageX<=this.ca.x+c)return;this.A=!1;this.ca=this.R=b}else{ku(this);return}}}else this.R=b;lu(this)};
-function lu(a){if(a.a&&a.a.a){var b=Cd(a.a.M());if(a.I&&a.A){var c=b.left,b=c+b.width;a.j=c>a.O.x?a.O.x-c:b<a.O.x?a.O.x-b:0}c=a.a;b=iu(a);c.a=b;du(c,!0);var d=a.a,c=bu(d),b=cu(d),d=d.M().offsetWidth,e=b.position-d/2,c=new $t(c.position,d,c.a-e,c.i-(b.width-e-d)),b=Math.max(c.width/c.b,0.015);a.da.style.left=Math.round(1E3*((c.width/2-c.a)/c.b-b/2))/10+"%";a.da.style.width=Math.round(1E3*b)/10+"%"}a.b&&(c=a.b,a=mu(a),c.ii||(b=c.Hb.offsetWidth/2,d=new $t(a.position,a.width,b,b),c.Hb.style.left=d.position-
-b+"px",b=c.Jh.offsetWidth/2,d=new $t(a.position,a.width,b,b),c.Jh.style.left=d.position-c.Hb.offsetLeft-b+"px",Zc(c.zj,Xm(a.vd*c.Pe)),c.Eg&&(a=mk(c.Eg,a.vd),a!=c.a&&(c.a=a,fu(c)))))}f.cx=function(){var a;if(0>this.j)a=0.15*this.j-0.1,this.j-=a,0<this.j&&(this.j=0);else if(0<this.j)a=0.15*this.j+0.1,this.j-=a,0>this.j&&(this.j=0);else return;var b=sd(this.g).x;this.R.x=tb(this.R.x+a,b,b+iu(this).width);lu(this);a=mu(this);nu(this,a.vd,this.fa);this.u("seekto",a.vd*this.B,!1)};
-function ku(a){a.za.removeAll();a.b&&a.b.hide();a.a&&a.a.a&&(a.a.disable(),ju(a));a.Ra=fo(a.k,a.i,"over",a.sn)}f.Lv=function(a){a.stopPropagation();a.preventDefault();this.b&&this.b.hide();this.a&&this.a.a&&ju(this);ou(this);this.Rh(a)};f.Os=function(a){a.stopPropagation();a.preventDefault();this.A=!0;ou(this);this.Rh(a)};function ou(a){a.I=!0;a.u("beginseeking");fo(a.Ia,document,"move",a.Rh);fo(a.Ia,document,"up",a.fx);a.A&&(a.Ma=jf(v(a.cx,a),20))}
-f.fx=function(a){a.stopPropagation();this.I=!1;this.Ia.removeAll();kf(this.Ma);ku(this);this.u("endseeking")};f.Rh=function(a){a.stopPropagation();a.preventDefault();this.yn(a);a=this.A?mu(this):iu(this);var b=a.vd*this.B;nu(this,a.vd,this.fa);(b<this.ba||b>this.ea)&&this.rl();this.u("seekto",b,!this.I)};function mu(a){return a.a&&a.a.a?a.A?bu(a.a,a.O.x-sd(a.g).x):bu(a.a):iu(a)}function iu(a){return new $t(a.R.x-sd(a.g).x,a.S.clientWidth,a.ra.clientWidth/2,a.ra.clientWidth/2)}
-function pu(a,b,c){nu(a,q(b)&&!a.I?b:a.va,q(c)?c:a.fa)}function nu(a,b,c){a.va=b;var d=Math.round(1E3*b)/10;id(a.qb,"transform","scalex("+b+")");a.ra.style.left=d+"%";a.fa=Math.max(a.va,c);id(a.La,"transform","scalex("+a.fa+")");a.a&&(a=a.a,a.G=b,a.o=c,du(a,!1))}f.Va=function(a){this.B=a;qu(this);this.a&&this.a.Va(a)};
-function qu(a){var b=!(!a.B||isNaN(a.ba)),c=!(!a.B||isNaN(a.ea));X(a.H,"html5-clip-enabled",b);X(a.U,"html5-clip-enabled",b);X(a.N,"html5-clip-enabled",c);X(a.$,"html5-clip-enabled",c);b&&(a.H.style.left=100*a.ba/a.B+"%",a.U.style.width=a.H.style.left);c&&(b=Math.min(100,100*a.ea/a.B),a.N.style.left=b+"%",a.$.style.left=b+"%",a.$.style.width=100-b+"%")}f.lp=function(){V(this.g,"html5-clip-marker-hover")};f.kp=function(){W(this.g,"html5-clip-marker-hover")};
-f.rl=function(a){a&&a.stopPropagation();this.ba=NaN;qu(this);this.ea=NaN;qu(this)};f.F=function(){I(this.oa);kf(this.Ma);this.k.removeAll();this.za.removeAll();this.Ia.removeAll();this.ua=null;this.K={};this.ra=this.gb=this.S=this.i=this.qb=this.La=this.g=this.H=this.$=this.U=this.N=null;gu.C.F.call(this)};function ru(a,b,c){Z.call(this,["div","ytp-drop-down","{{content}}"]);this.G=a;this.g=!1;this.o=0;this.a=new Z(["div","ytp-drop-down-menu","{{content}}"]);L(this,this.a);this.b=new Om(this.G,"ytp-drop-down-label");L(this,this.b);this.listen(this.b,"click",this.B);this.j=new Z(["div","ytp-drop-down-label-content","{{content}}"]);L(this,this.j);this.b.Aa([this.j,["div","ytp-drop-down-arrow"]]);this.Aa([this.a,this.b]);this.stopPropagation("click");q(b)&&su(this,b);q(c)&&(this.a.Aa(c),tu(this));tu(this)}
-y(ru,Z);function su(a,b){a.j.Aa(b);tu(a)}ru.prototype.i=function(){this.g=!1;tu(this)};ru.prototype.B=function(){this.g=!this.g;tu(this)};function uu(a,b){b>a.o&&(a.o=b,a.element.style.minWidth=a.o+"px")}function tu(a){a.g?(a.a.show(),a.listen(window,"blur",a.i,"menu"),a.listen(document,"click",a.i,"menu")):(a.a.hide(),a.Vc(a.k.menu),a.k.menu=[]);var b=Ad(a.b.M());a.a.M().style.bottom=b.height-1+"px";uu(a,b.width)}ru.prototype.F=function(){this.G=null;ru.C.F.call(this)};function vu(a){Om.call(this,a,"ytp-drop-down-menu-button");this.j=new Z(["div","ytp-drop-down-menu-button-check"]);L(this,this.j)}y(vu,Om);vu.prototype.Aa=function(a){vu.C.Aa.call(this,[this.j,a])};function wu(a,b){X(a.element,"ytp-drop-down-menu-button-selected",b)};function xu(a){Z.call(this,["span"]);this.element.innerHTML=a}y(xu,Z);function yu(a){R.call(this);this.g=a;this.b={};this.j=new Z(["div","ytp-menu-drop-down-content"]);L(this,this.j);this.a="auto";this.i=!0;this.label=this.g.getMsg("YTP_QUALITY_TITLE");this.element=new ru(a,void 0,this.j);L(this,this.element);uu(this.element,100);zu(this,this.a,this.a);this.priority=-1}y(yu,R);function Au(a,b){Bu(a);z(b,function(a){var b=new vu(this.g);b.Aa(new xu(Cu(this,a)));b.T(this.j.M());this.b[a]=b;K(b,"click",v(this.k,this,a))},a);a.b[a.a]&&wu(a.b[a.a],!0)}
-function zu(a,b,c){a.a&&a.b[a.a]&&wu(a.b[a.a],!1);a.a=b;a.b[a.a]&&wu(a.b[a.a],!0);a.i="auto"==c;a.i&&c!=b?(c=a.element,a=a.g.getMsg("YTP_QUALITY_AUTO_WITH_QUALITY",{video_quality:Cu(a,b)}),a=new xu(a),su(c,a)):su(a.element,new xu(Cu(a,c)))}function Cu(a,b){return a.g.getMsg("YTP_QUALITY_"+b.toUpperCase())}function Bu(a){Cb(a.b,function(a){Nf(a)});a.b={}}yu.prototype.k=function(a){this.element.i();this.i&&"auto"==a||this.u("qualitychanged",a)};yu.prototype.F=function(){Bu(this);this.g=null;yu.C.F.call(this)};function Du(a){R.call(this);this.g=a;this.a={};this.b=1;this.i=new Z(["div","ytp-menu-drop-down-content"]);L(this,this.i);this.label=this.g.getMsg("YTP_PLAYER_SPEED_TITLE");this.element=new ru(a,void 0,this.i);L(this,this.element);uu(this.element,100);this.priority=1}y(Du,R);function Eu(a,b){Fu(a);z(b,function(a){var b=new vu(this.g);b.Aa(Gu(this,a));b.T(this.i.M());this.a[a]=b;K(b,"click",v(this.j,this,a))},a);a.a[a.b]&&wu(a.a[a.b],!0)}
-function Hu(a,b){a.b&&a.a[a.b]&&wu(a.a[a.b],!1);a.b=b;a.a[a.b]&&wu(a.a[a.b],!0);su(a.element,Gu(a,b))}function Gu(a,b){return 1==b?a.g.getMsg("YTP_PLAYER_SPEED_NORMAL"):b.toString()}function Fu(a){Cb(a.a,function(a){Nf(a)});a.a={}}Du.prototype.j=function(a){this.element.i();Hu(this,a);this.u("speedchanged",a)};Du.prototype.F=function(){Fu(this);this.g=null;Du.C.F.call(this)};function Iu(){Z.call(this,["div",["ytp-time-display","html5-control"],["span","ytp-time-current","{{current}}"],["span","ytp-time-separator"," / "],["span","ytp-time-duration","{{duration}}"],["span","ytp-time-live-badge","Live"]]);this.a=this.template.a["ytp-time-live-badge"]}y(Iu,Z);Iu.prototype.Va=function(a){xm(this.template,"duration",Xm(a))};Iu.prototype.F=function(){this.a=null;Iu.C.F.call(this)};function Ju(a){R.call(this);this.b=a;this.a=new eo(this);this.A=new eo(this);this.k=this.j=null;this.o=new eo(this)}y(Ju,R);f=Ju.prototype;f.kg=null;f.Zc=null;f.Ie=null;f.fk=null;f.Yd=null;f.tc=null;f.uf=null;f.ac=null;f.yg=null;f.Vd=null;f.ze=null;f.Vh=null;f.ud=null;f.Qc=null;f.vb=null;f.vf=null;f.Ee=null;f.Rl=!1;f.Uc=null;f.ce=null;f.hk=null;f.de=null;f.bo=!1;f.tg=null;f.wb=null;
-function Ku(a,b){a.kg=b;var c=E("html5-player-chrome",b);a.Zc=new Tt(a.b);a.Zc.T(c,0);L(a,a.Zc);new Gt(a.Zc.M(),v(a.St,a),!1,function(){return!0});a.Ie=new Vt(a.b);a.Ie.T(c,1);L(a,a.Ie);a.a.listen(a.Ie.a,"click",oa(a.u,"nextvideo"));a.a.listen(a.Ie.b,"click",oa(a.u,"previousvideo"));var d=E("html5-progress-bar-container",b);a.fk=new gu(a.b);hu(a.fk,d);a.g=new Iu;a.g.T(c,4);L(a,a.g);a.a.listen(a.g.a,"click",oa(a.u,"seekto",Infinity));a.Yd=E("html5-volume-control",b);a.a.listen(a.Yd,"keydown",a.Tt);
-a.tc=E("html5-volume-button",a.Yd);a.a.listen(a.tc,"click",a.Dn);a.uf=E("html5-volume-panel",a.Yd);a.ac=E("html5-volume-slider",a.Yd);fo(a.a,a.ac,"down",a.Pt);a.yg=E("html5-volume-slider-foreground",a.Yd);a.Vh=E("html5-threed-popup-menu",b);a.ze=E("html5-small-player-button",b);a.a.listen(a.ze,"click",a.Cn);a.Vd=E("html5-large-player-button",b);a.a.listen(a.Vd,"click",a.Cn);a.i=new Pt(a.b);a.i.T(c,7);L(a,a.i);a.a.listen(a.i,"click",a.Ot);a.ud=E("html5-quality-button",b);a.Ee=E("html5-quality-popup-menu",
-a.ud);go(a.a,a.Ee,a.Mt);a.vf=E("html5-speed-popup-menu",a.ud);go(a.a,a.vf,a.Nt);a.wb=E("html5-watch-later-button",b);a.a.listen(a.wb,"click",a.Qt);a.wb&&pt(a.b,a.wb,a.b.getMsg("YTP_TOOLTIP_WATCH_LATER"),!0);a.tg=E("html5-watch-on-youtube-button",b);a.a.listen(a.tg,"click",a.Rt)}f.disable=function(a){Lu(this,a,!0)};f.enable=function(a){Lu(this,a,!1)};function Lu(a,b,c){z(b,function(a){X(this.kg,"disabled-control-"+a,c)},a)}
-function Mu(a,b){if(a.Uc)Au(a.Uc,b),b.length?a.vb.add(a.Uc):a.vb.remove(a.Uc);else{var c=Jc("yt-uix-button-menu-item",a.Ee);z(c,function(a){a.style.display="none";for(var c=0,g=b.length;c<g;c++)G(a,"value")==b[c]&&(a.style.display="list-item")},a);a.Rl=!!b.length;Zm(a.Ee,a.Rl);Zm(a.ud,a.Rl)}}f.Tt=function(a){var b=a.keyCode;if(32==b||13==b)this.Dn(),a.preventDefault()};f.Va=function(a){this.g.Va(a)};function Nu(a,b,c){a.Uc?zu(a.Uc,b,c):a.Ee&&(a=a.Ee,Ou(a,"active",b),Ou(a,"selected",c||b))}
-function Ou(a,b,c){var d=E("yt-uix-button-menu-item."+b,a);d&&W(d,b);a=a.querySelector(".yt-uix-button-menu-item"+('[data-value="'+c+'"]'));V(a,b)}f.Dn=function(){this.u("mutetoggled")};function Pu(a,b){if(b){if(a.bo){var c=a.Zc;Qm(c,"ytp-button-stop");var d=c.g.getMsg("YTP_BUTTON_STOP")}else c=a.Zc,Qm(c,"ytp-button-pause"),d=c.g.getMsg("YTP_BUTTON_PAUSE");Rm(c,d);c.a=d}else Ut(a.Zc)}f.St=function(){this.u("playpausetoggled")};
-f.Pt=function(a){this.u("beginvolume");V(this.tc,"changing");var b=this.ac.clientWidth;a=100*(ud(a,this.ac).x/b);Qu(this,a);fo(this.A,document,"move",this.hx);fo(this.A,document,"up",this.ix)};f.hx=function(a){var b=this.ac.clientWidth,b=100*(ud(a,this.ac).x/b);Qu(this,b);a.preventDefault()};function Qu(a,b){var c={volume:tb(b,0,100),muted:!1};a.u("volumechanged",c)}f.ix=function(){W(this.tc,"changing");this.A.removeAll();this.u("endvolume")};
-f.Cn=function(a){this.u("sizechangerequested",a.currentTarget==this.Vd)};f.vt=function(){this.u("sizechangerequested",1==this.ce.getSelected())};f.Mt=function(a){a=G(a.currentTarget,"value");this.u("qualitychanged",a)};f.Ot=function(){this.u("fullscreentoggled")};function Ru(a,b){if(a.de)Hu(a.de,parseFloat(b));else if(a.vf){var c=a.vf;Ou(c,"active",b);Ou(c,"selected",b)}}f.Nt=function(a){a=G(a.currentTarget,"value");this.u("speedchanged",parseFloat(a));Ru(this,a)};
-f.Qt=function(){Zl(this.wb,"html5-async-progress")||(Ft(this.wb,"html5-async-progress"),this.u("watchlater"))};f.Rt=function(){this.u("watchonyoutube")};f.Qg=function(){this.o.removeAll();this.j&&(this.j.hide(),this.j=null);this.k&&(Rs(this.k),this.k=null)};f.ut=function(a){a.stopPropagation();if(this.Qc.b)this.Qg();else{a=this.vb;var b=this.Qc;this.Qg();this.j=a;this.j.show();b&&(this.k=b,Qs(this.k));this.o.listen(window,"blur",this.Qg);this.o.listen(document,"click",this.Qg)}};
-f.tt=function(a){var b=a.target,c="unknown",c=b==this.Zc.M()?"playpause":b==this.tc||b==this.uf||b==this.ac||b==this.Yd||b==this.yg?"volume":b==this.g?"time":b==this.ud?"settings":b==this.Qc?"settings-redesign":b==this.wb?"watchlater":b==this.tg?"youtube":b==this.i.M()?"fullscreen":b==this.ze||b==this.Vd?"size":a.target;this.u("controlclick",c)};
-f.F=function(){this.a.removeAll();this.A.removeAll();this.o.removeAll();this.Qg();this.vb=this.Qc=this.Uc=this.wb=this.tg=this.Ee=this.vf=this.ud=this.Vh=this.ze=this.Vd=this.yg=this.ac=this.uf=this.tc=this.Yd=this.kg=null;Ju.C.F.call(this)};var Su=["left","right","center"],Tu={id:0,priority:0,ji:7,ki:50,By:80,he:95,Bd:15,qk:100,isVisible:!0,textAlign:Su[2],Je:0,backgroundColor:"#080808",gi:"#fff",ty:1,Nl:1},Uu={id:99,priority:1,ji:0,ki:5,he:7,Bd:2,qk:32,textAlign:Su[0]},Vu=["CA","MX","US"];function Wu(a){a=a||Tu;pa(this,a)}f=Wu.prototype;f.ji=7;f.ki=50;f.he=95;f.By=80;f.Je=0;f.textAlign="center";f.backgroundColor="#080808";f.gi="#fff";f.ty=1;f.Nl=1;f.Bd=15;f.qk=32;f.isVisible=!0;f.fontFamily='"Arial Unicode Ms", Arial';f.xx="100%";function Xu(a,b){this.id=a;this.qa=new Wu(b);var c="caption-window";0==this.id&&(c="standard-caption-window");this.ma=Pc("div",{id:"caption-window-"+this.id,"class":c});this.Eb=Pc("span",{"class":"captions-text",style:"visibility: hidden"});this.Eb.innerHTML="C";this.ja=Pc("span",{"class":"captions-text",tabindex:"4","aria-live":"assertive"});this.Zi=Pc("div",{"class":"caption-window-transform"});this.Zi.appendChild(this.ja);this.ma.appendChild(this.Zi)}f=Xu.prototype;f.id=0;f.qa=null;f.eh="";
-f.Cc=null;f.ma=null;f.Zi=null;f.ja=null;f.Eb=null;f.type=1;f.getType=function(){return this.type};f.Ui=function(){var a;this.Eb.style.fontFamily=this.ja.style.fontFamily;this.ma.appendChild(this.Eb);a=this.Eb.offsetHeight;this.ma.removeChild(this.Eb);return a};f.Xf=function(){this.ja&&(0!=this.id&&(zd(this.ma,"100%"),zd(this.ma,this.ja.offsetWidth)),Yu(this),Zm(this.ma,this.qa.isVisible))};
-function Yu(a){md(a.ma,a.qa.ki+"%",a.qa.he+"%");for(var b=0;8>=b;b++)W(a.ma,"anchor-point-"+b);V(a.ma,"anchor-point-"+a.qa.ji)}f.$o=function(a){var b=[];z(a,function(a){a.Yi?b[b.length-1]+=a.ge:b.push(a.ge)});this.Te(b.join("\n"));this.Cc=a};f.Te=function(a){this.eh=a=Zu(a);this.ja.innerHTML=this.eh;this.Ol();this.Xf()};
-f.Ol=function(){this.ma.style.textAlign=this.qa.textAlign;this.ja.style.backgroundColor=this.qa.backgroundColor;this.ja.style.color=this.qa.gi;this.ja.style.opacity=this.qa.Nl;this.ja.style.fontFamily=this.qa.fontFamily;this.ja.style.fontSize=this.qa.xx;1==this.qa.Je?this.ja.setAttribute("dir","rtl"):this.ja.removeAttribute("dir")};f.toString=function(){var a="Caption window ("+this.id+"): "+this.eh,b;for(b in this.qa)a+=b+" "+this.qa[b]+" | ";return a};
-function Zu(a){a=a.split("\n");for(var b=0,c=a.length;b<c;b++)a[b]=a[b]?"&nbsp;"+a[b]+"&nbsp;":"";return a.join("<br>")}f.$i=function(){this.Cc=[];this.Te("")};function $u(a,b){Xu.call(this,a,b);this.ja.style.display="block";this.ja.style.padding="0";this.Ob=[];var c=this.ja;W(c,"captions-text");V(c,"caption-painton-text-rows")}y($u,Xu);f=$u.prototype;f.type=0;f.ko="";f.dh=!1;f.Bb=null;f.Ob=null;f.Ui=function(){return this.Ob[0]?this.Ob[0].offsetHeight:0};function av(a){return a.Ob.reduce(function(a,c){return Math.max(a,c.offsetWidth)},0)}
-f.Xf=function(){0!=this.id&&(zd(this.ma,"100%"),zd(this.ma,this.dh?av(this):this.Bb.width));var a=Math.round(this.qa.Bd*this.Ui());id(this.ma,"max-height",a+"px");Yu(this);Zm(this.ma,this.qa.isVisible)};
-f.Te=function(a){this.$i();a=Zu(a);this.dh||(this.eh=a);a=a.split("<br>");for(var b=0,c=a.length;b<c;b++)if(a[b]){var d=Pc("div",{"class":"caption-row-holder"}),e=Pc("span",{"class":"caption-row captions-text"});d.appendChild(e);e.innerHTML=a[b];this.dh||(this.ja.style.height=this.Bb.height+"px",this.ja.style.width=this.Bb.width+"px",d.style.position="absolute",d.style.top=this.Bb.jo[b]+"px",d.style.left=this.Bb.ho[b]+"px");this.ja.appendChild(d);this.Ob.push(e)}this.Ol();this.Xf()};
-f.$i=function(){for(var a=0,b=this.Ob.length;a<b;a++){var c=ed(this.Ob[a],"caption-row-holder");F(c)}this.Ob=[]};f.Ol=function(){this.ma.style.textAlign=this.qa.textAlign;for(var a=0,b=this.Ob.length;a<b;a++)this.Ob[a].style.backgroundColor=this.qa.backgroundColor;this.ja.style.color=this.qa.gi;this.ja.style.opacity=this.qa.Nl;this.ja.style.fontFamily=this.qa.fontFamily;1==this.qa.Je?this.ja.setAttribute("dir","rtl"):this.ja.removeAttribute("dir")};function bv(a,b){Xu.call(this,a,b);this.Cc=[];this.pe=[];this.Db=[];this.Yf=new Uh(433);this.Yf.stop();K(this.Yf,"tick",v(this.Cx,this))}y(bv,Xu);f=bv.prototype;f.type=2;f.Ax=32;f.Db=null;f.qe=0;f.pe=null;f.Yf=null;f.Xf=function(){zd(this.ma,"100%");var a=this.ma.offsetWidth,a=Math.min(cv(this),a);zd(this.ma,a+"px");zd(this.Zi,"100%");this.ja.style.whiteSpace="nowrap";Yu(this);Zm(this.ma,this.qa.isVisible)};
-f.$o=function(a){var b=a.length;if(0>=b)this.$i();else{for(var c=0;c<b&&0<=this.Cc.indexOf(a[c]);)c++;this.Cc=this.Cc.concat(a.slice(c));dv(this)}};f.$i=function(){this.Cc=[];this.Db=[];this.qe=0;this.Db=[];this.pe=[];ev(this)};
-function dv(a){if(!fv(a))if(a.qe>=a.Cc.length)ev(a);else{var b=a.Db.length-1;0>b&&(a.pe.push(0),a.qe=0,a.Db.push(""),b=0);for(var c=a.Cc.length,d=a.qe;d<c;d++){var e=a.Cc[d];if("\n"==e.ge){a.qe++;a.pe[b]++;break}if(e.Yi||0==a.Db[b].length)a.Db[b]+=e.ge,a.qe++,a.pe[b]++;else break}ev(a);d<c&&!fv(a)&&(b=a.Ui(),V(a.ja,"caption-rollup"),a.ma.style.overflow="hidden",a.ja.style.top=-b+"px",a.Yf.start())}}function fv(a){return a.Yf.Xc||Zl(a.ja,"caption-rollup")}
-f.Cx=function(){this.ma.style.overflow="visible";this.ja.style.top=0;this.Yf.stop();W(this.ja,"caption-rollup");this.Db.push("");this.pe.push(0);dv(this)};function ev(a){if(!fv(a)){for(;a.Db.length<a.qa.Bd;)a.Db.unshift(""),a.pe.unshift(0);for(;a.Db.length>a.qa.Bd;){a.Db.shift();var b=a.pe.shift();0<b&&(a.qe-=b,a.Cc.splice(0,b))}a.Te(a.Db.join("\n"))}}
-function cv(a){a.Eb.style.fontFamily=a.ja.style.fontFamily;a.Eb.style.fontSize=a.ja.style.fontSize;a.ja.appendChild(a.Eb);a.Eb.innerHTML="\u2014";var b=a.Eb.offsetWidth;a.Eb.innerHTML="&nbsp;";b=2*a.Eb.offsetWidth+b*a.Ax;a.ja.removeChild(a.Eb);return b};function gv(a){this.a=a.pk;this.i=a.priority;this.zc=a.zc||this.zc}gv.prototype.a=0;gv.prototype.i=0;gv.prototype.zc=0;gv.prototype.toString=function(){return this.a+", "+this.zc};function hv(a){gv.call(this,a);this.ge=a.text||this.ge;this.Zh=a.windowId||this.Zh;this.Yi=a.params.append||this.Yi;this.Wp=a.params.row||this.Wp;this.Vp=a.params.Bx||this.Vp}y(hv,gv);f=hv.prototype;f.ge="";f.Yi=!1;f.Wp=0;f.Vp=0;f.Zh=0;f.toString=function(){return this.a+", "+this.zc+": "+this.ge};
-function iv(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={pk:c,zc:d,text:b,windowId:e,priority:5,params:{}};a.getAttribute("r")&&(b.params.row=parseInt(a.getAttribute("r"),10));a.getAttribute("c")&&(b.params.Bx=parseInt(a.getAttribute("c"),10));
-a.getAttribute("append")&&(b.priority=6,b.params.append=!0);return new hv(b)}function jv(a){gv.call(this,a);this.id=a.windowId||this.id;this.params=a.params}y(jv,gv);jv.prototype.id=0;jv.prototype.params=null;jv.prototype.g="";jv.prototype.b=!1;function kv(){return new jv({pk:-2147483648,zc:4294967295,params:Tu})};function lv(a){if("undefined"!=typeof DOMParser)return(new DOMParser).parseFromString(a,"application/xml");if("undefined"!=typeof ActiveXObject){var b=new ActiveXObject("MSXML2.DOMDocument");if(b){b.resolveExternals=!1;b.validateOnParse=!1;try{b.setProperty("ProhibitDTD",!0),b.setProperty("MaxXMLSize",2048),b.setProperty("MaxElementDepth",256)}catch(c){}}b.loadXML(a);return b}throw Error("Your browser does not support loading xml documents");};function mv(a){this.b=[];this.g=[];this.a={};if(a&&(a=lv(a))&&a.firstChild)switch(this.i=a,this.i.firstChild.tagName){case "timedtext":a=this.i.firstChild.childNodes;for(var b=0,c=a.length;b<c;b++)switch(a[b].tagName){case "window":var d=a[b],e=parseInt(d.getAttribute("id"),10),g=void 0;t:{var h=this.a[e];if(d.getAttribute("t")||d.getAttribute("start")){g=parseInt(d.getAttribute("t"),10);d.getAttribute("start")&&(g=1E3*parseFloat(d.getAttribute("start")));h&&(h.a+h.zc>=g?h.zc=g:h=null);switch(d.getAttribute("op")){case "kill":g=
-null;break t;case "define":h=null}h?h.j=!0:h=kv();var k={};pa(k,h?h.params:Tu);d.getAttribute("id")&&(k.id=d.getAttribute("id"));d.getAttribute("op")&&(k.Ey=d.getAttribute("op"));d.getAttribute("rc")&&(k.Bd=parseInt(d.getAttribute("rc"),10));d.getAttribute("cc")&&(k.qk=parseInt(d.getAttribute("cc"),10));d.getAttribute("ap")&&(h=parseInt(d.getAttribute("ap"),10),k.ji=0>h||8<h?7:h);d.getAttribute("ah")&&(k.ki=parseInt(d.getAttribute("ah"),10));d.getAttribute("av")&&(k.he=parseInt(d.getAttribute("av"),
-10));d.getAttribute("id")&&(k.id=parseInt(d.getAttribute("id"),10)||0);d.getAttribute("vs")&&(k.isVisible=Boolean(d.getAttribute("vs")));d.getAttribute("ju")&&(k.textAlign=Su[parseInt(d.getAttribute("ju"),10)]);d.getAttribute("pd")&&(k.Je=1,0==parseInt(d.getAttribute("pd"),10)&&(k.Je=0));d.getAttribute("bc")&&(k.backgroundColor=parseInt(d.getAttribute("bc"),16));d.getAttribute("bo")&&(k.opacity=parseInt(d.getAttribute("bo"),10)/100);d.getAttribute("fc")&&(k.gi=parseInt(d.getAttribute("fc"),16));d.getAttribute("sd")&&
-(k.jk=parseInt(d.getAttribute("sd"),10));h=parseInt(d.getAttribute("d"),10)||1E3*parseFloat(d.getAttribute("dur"))||2147483647;d={pk:g,zc:h,params:k,windowId:parseInt(d.getAttribute("id"),10)};g=new jv(d)}else g=null}this.a[e]=g;this.g.push(g);break;case "text":e=iv(a[b]),this.b.push(e),d=e.Zh,this.a[d]&&(d=this.a[d],e=e.ge,""!=d.g&&(d.b=!0),d.g+=e)}break;default:for(this.g.push(kv()),a=this.i.firstChild.childNodes,b=0,c=a.length;b<c;b++)e=iv(a[b]),this.b.push(e)}}mv.prototype.b=null;
-mv.prototype.g=null;mv.prototype.a=null;function nv(a){this.a=a.languageCode;this.b=a.languageName||null;this.g=a.languageOriginal||null;this.id=a.id||null;this.i=a.is_default||!1};function ov(a){a=a||{};this.Ik=a.format;this.b=a.languageCode||"";this.Yg=a.languageName;this.Kb=a.kind||"";this.fc=a.name;this.Ba=a.id;this.zk=a.is_servable;this.oi=a.is_default;this.pi=a.is_translateable;a.translationLanguage&&(this.a=new nv(a.translationLanguage))}
-function pv(a){var b={format:a.Ik,languageCode:a.b,languageName:a.Yg,displayName:qv(a),kind:a.Kb,name:a.fc,id:a.Ba,is_servable:a.zk,is_default:a.oi,is_translateable:a.pi};a.a&&(b.translationLanguage={languageCode:a.a.a,languageName:a.a.b,languageOriginal:a.a.g,id:a.a.id,is_default:a.a.i});return b}f=ov.prototype;f.Yg=null;f.Kb=null;f.fc=null;f.Ba=null;f.zk=!1;f.oi=!1;f.pi=!1;f.Ik=1;
-function qv(a){var b=[a.Yg];if("asr"==a.Kb){var c=J("HTML5_SUBS_ASR");b.push(" (",c,")")}a.fc&&b.push(" - ",a.fc);a.a&&b.push(" >> ",a.a.b);return b.join("")}f.toString=function(){var a=[this.b,": ",this.fc," (",this.Kb,")"];this.a&&a.push(" >> ",this.a.a);return a.join("")};f.equals=function(a){if(!a)return!1;var b=this.a,c=a.a;if(b&&c){if(b.a!=c.a)return!1}else if(b||c)return!1;return this.b==a.b&&this.fc==a.fc&&this.Kb==a.Kb};function rv(){this.g=[];this.a=[]}rv.prototype.g=null;rv.prototype.a=null;rv.prototype.b=-1;function sv(a,b){return b?a.a.concat(a.g):a.a}function tv(a,b){switch(b.Kb){case "asr":return uv(b,a.g);default:if(b.oi||0>a.b)a.b=a.a.length;return uv(b,a.a)}}function uv(a,b){return Na(b,v(a.equals,a))?!1:(b.push(a),!0)};function vv(a,b,c,d){this.Ld=a;c?this.Ld=Zi(this.Ld,{hl:c}):(a=Vi(this.Ld).hl||"",a=a.split("_").join("-"),this.Ld=Zi(this.Ld,{hl:a}));this.Li=b;this.Sp=!!d;this.Jd=new rv;this.zi=[];this.Tp={}}f=vv.prototype;f.Ld="";f.Li=null;f.Sp=!1;f.Jd=null;f.zi=null;f.Tp=null;function wv(a,b){return Na(sv(a.Jd,!0),function(a){return a.toString()==b})}function xv(a,b){var c=a.Ld,d={v:a.Li,type:"track",lang:b.b,name:b.fc,kind:b.Kb,fmt:b.Ik};b.a&&(d.tlang=b.a.a);return c=Zi(c,d)}
-function yv(a,b,c){var d=xv(a,b);a=v(function(a){a=new mv(a.responseText);c(a,b)},a);bj(d,a)}function zv(a){var b=a.Jd.b;a=sv(a.Jd,!0);return 0>b?null:a[b]}
-function Av(a,b){var c=a.Ld,d={type:"list",tlangs:1,v:a.Li,fmts:Number(!0)};a.Sp&&(d.asrs=1);c=Zi(c,d);d=v(function(a){if((a=a.responseXML)&&a.firstChild){for(var c=this.Jd,d=a.getElementsByTagName("track"),k=d.length,m=0;m<k;m++){var p=parseInt(d[m].getAttribute("formats"),10)||1,s=d[m].getAttribute("lang_code"),r=d[m].getAttribute("lang_translated"),x=d[m].getAttribute("name"),M=d[m].getAttribute("kind")||"",ta=d[m].getAttribute("id"),Y="true"==d[m].getAttribute("lang_default"),xC="true"==d[m].getAttribute("cantran");
-tv(c,new ov({format:p,languageCode:s,languageName:r,name:x,kind:M,id:ta,is_servable:!0,is_default:Y,is_translateable:xC}))}a=a.getElementsByTagName("target");c=a.length;for(d=0;d<c;d++)k=a[d].getAttribute("lang_code"),m=a[d].getAttribute("lang_translated"),p=a[d].getAttribute("lang_original"),s=a[d].getAttribute("id"),r="true"==a[d].getAttribute("lang_default"),k={languageCode:k,languageName:m,languageOriginal:p,id:s,is_default:r},this.Tp[k.languageCode]=k.languageName,this.zi.push(new nv(k))}b()},
-a);bj(c,d)};function Bv(a){dm.call(this,a);var b=Q(a);this.Fd=a.J();this.$n=a.app.P;this.ne=[];this.Ga={};this.fe={};this.Me=[];this.i=E("captions-translation-select",b);this.Il=E("captions-translation-dialog",b);this.Hl=E("captions-settings-dialog",b);this.ed=E("html5-captions-button",b);K(this.ed,"click",v(this.qw,this));K(E("captions-translation-confirm",b),"click",v(this.Aw,this));K(E("captions-translation-cancel",b),"click",v(this.ao,this));xf(E("captions-settings-background-opacity",b),v(this.mw,this),
-"INPUT");xf(E("captions-settings-text-opacity",b),v(this.zw,this),"INPUT");xf(E("captions-settings-window-opacity",b),v(this.Bw,this),"INPUT");xf(E("captions-settings-char-edge-style",b),v(this.rw,this),"SELECT");K(E("captions-settings-font-family",b),"change",v(this.xw,this));K(E("captions-settings-font-inc",b),"click",v(this.Gp,this));K(E("captions-settings-font-dec",b),"click",v(this.Fp,this));K(E("captions-settings-confirm",b),"click",v(this.lw,this));K(E("captions-settings-cancel",b),"click",
-v(this.yw,this));a=E("captions-settings-dialog",b);zf(a,v(this.tw,this),"html5-color-picker-button");this.ed&&(this.ld=E("html5-captions-tracks",this.ed),this.Ff=yr(mr.getInstance(),this.ed),a=E("html5-captions-track-template",this.Ff),this.Ep=new ns(a,["track_id","track_display_name"]),zf(this.Ff,v(this.ow,this),"yt-uix-button-menu-item"));this.Sf=new Uh;this.Sf.stop();K(this.Sf,"tick",v(this.il,this));this.D("onResize",v(this.Qn,this));this.D("onBackgroundChange",v(this.Dw,this));this.D("onTextOpacityChange",
-v(this.Ew,this));this.D("onWindowOpacityChange",v(this.Fw,this));this.D("onFontSizeIncrease",v(this.Gp,this));this.D("onFontSizeDecrease",v(this.Fp,this));this.D("onShowControls",v(this.ww,this));this.D("onHideControls",v(this.uw,this));"detailpage"==this.Fd.Y&&(b=E("captions-account-settings-link",b))&&an(b);this.ti=new Xu(99,Uu);this.ah=new Uh(2E3);this.ah.stop();K(this.ah,"tick",v(this.Cw,this))}y(Bv,dm);f=Bv.prototype;f.na="captions";f.kd="cc";f.yl="subtitlesModuleData";f.Ci=!1;f.Rk=!1;f.hd=null;
-f.Fd=null;f.$n=null;f.ed=null;f.Ff=null;f.Ep=null;f.Il=null;f.Hl=null;f.ld=null;f.Me=null;f.ne=null;f.Ga=null;f.fe=null;f.Sf=null;f.ti=null;f.ah=null;f.Mb=null;f.yi=!1;f.ap=1;var Cv={background:"#080808",backgroundOpacity:1,charEdgeStyle:"uniform",color:"#fff",fontFamily:'"Arial Unicode Ms", Arial',fontFamilyOption:"propSans",fontSizeIncrement:0,textOpacity:1,windowColor:"#080808",windowOpacity:0};f=Bv.prototype;f.dc=null;f.Un=!1;
-f.create=function(){Bv.C.create.call(this);this.hd=this.a.getVideoData();var a=this.a.J().S;-1==Vu.indexOf(a)&&V(Q(this.a),"cc-international");this.b=Jb(Cv);pa(this.b,km(this,"display-settings"));1==this.Fd.a.cc_load_policy||1==this.hd.Tm||"alwayson"==Il(this.hd,"yt:cc")?a=!0:(a=km(this,"module-enabled"),a=null!=a?!!a:"on"==Il(this.hd,"yt:cc")||this.Fd.a.cc_prefer_on);a&&this.load()};f.destroy=function(){this.unload();Bv.C.destroy.call(this)};
-f.load=function(){if(this.Ci)this.Z&&(Bv.C.load.call(this),this.yi="alwayson"==Il(this.hd,"yt:cc"),this.Ff&&X(this.Ff,"captions-always-on",this.yi),lm(this,"module-enabled",!0),this.Ci=!1,Dv(this),this.Qn());else{this.Ci=!0;this.Z=!1;var a=this.hd.b.cc_lang_pref||this.Fd.a.cc_lang_pref||Il(this.hd,"yt:cc_default_lang")||this.Fd.i,a=a&&a.split("_").join("-");this.Mb=new vv(this.hd.li,this.hd.L,a,this.hd.vk);a=v(this.po,this);Av(this.Mb,a)}};
-f.unload=function(){this.uc&&(Ev(this,!1),this.Mo("control_subtitles_set_track"));Fv(this);im(this);lm(this,"module-enabled",!1);this.Ci=!1;this.Z&&(this.Z=!1,Bv.C.unload.call(this))};f.log_=function(){};function Gv(a,b){a.i&&(Vc(a.i),z(b,function(a){var b=Sc("option");b.setAttribute("value",a.a);b.appendChild(Tc(a.b+" -- "+a.g));this.i.appendChild(b)},a))}
-f.po=function(){this.ld&&Vc(this.ld);Gv(this,this.Mb.zi);var a=sv(this.Mb.Jd,!0);if(0<a.length){this.log_("Caption track list loaded, found "+a.length+" tracks.");z(a,function(a){if(a.zk){var b=a.toString();a=qv(a);Hv(this,b,a)}},this);var b=this.Mb.Jd.b;(a=a[b]&&a[b].toString())&&Iv(this,a);this.ed&&xr(mr.getInstance(),this.ed);(a=zv(this.Mb))?(this.Rk=!0,Jv(this,a)):(this.Z||(this.Z=!0,this.load()),this.u("publish_external_event","onCaptionsTrackListChanged"))}else this.log_("No captions found."),
-this.unload(),bn(this.Ff),bn(this.ed)};f.kv=function(a,b){var c=a.g.concat(a.b);this.log_("Caption track loaded with "+c.length+" events.");Fv(this);this.Me=Ya(c);this.dc=b;this.Un=Et.test(b.b);this.Z||(this.Z=!0,this.load());this.Rk&&(this.Rk=!1,this.u("publish_external_event","onCaptionsTrackListChanged"));c=Ja(c,function(a,b){return new nh(a.a,a.a+a.zc,{id:"caption"+b})});this.yf.apply(this,c);this.fo(b)};
-f.fo=function(a){var b={trackName:a.fc,trackKind:a.Kb};a.a?(b.trackLangCode=a.a.a,b.fromLangCode=a.b):b.trackLangCode=a.b;this.log(b);var b=this.ti,c=qv(a);c&&(c=c.replace(/<[^>]*>?/g,""),b.Te(c));gm(this,this.ti.ma);this.ah.start();this.u("publish_external_event","captionschanged",pv(a))};f.vc=function(a){0==a.getId().indexOf("caption")&&(a=parseInt(a.getId().split("caption")[1],10),!isNaN(a)&&this.Me[a]&&(this.ne.push(this.Me[a]),this.Sf.start()))};
-f.dd=function(a){0==a.getId().indexOf("caption")&&(a=parseInt(a.getId().split("caption")[1],10),!isNaN(a)&&this.Me[a]&&(a=this.ne.indexOf(this.Me[a]),0<=a&&this.ne.splice(a,1),this.Sf.start()))};
-function Kv(a,b){if(b instanceof jv){var c=a.Ga[b.id];pa(b.params,a.b);c&&c.getType()!=(b.params.jk?2:b.b?0:1)&&(F(c.ma),delete a.Ga[b.id]);if(!a.Ga[b.id]){var c=a.Ga,d=b.id,e;t:{e=b.id;var g=b.params;switch(b.params.jk?2:b.b?0:1){case 0:e=new $u(e,g);break t;case 2:e=new bv(e,g);break t;default:e=new Xu(e,g)}}c[d]=e;c=a.Ga[b.id].ma;X(c,"captions-asr","asr"==a.dc.Kb);null!=b.params.Je&&(b.params.Je=a.Un?1:0);0==a.Ga[b.id].id?(V(c,a.na),Lv(a.a.app.P,c)):gm(a,c)}pa(a.Ga[b.id].qa,b.params);if(0==(b.params.jk?
-2:b.b?0:1)){c=a.Ga[b.id];c.ko=b.g;c.Bb={};c.dh=!0;c.Te(c.ko);c.Bb.Bd=c.Ob.length;c.Bb.width=c.ma.offsetWidth;c.Bb.height=c.ma.offsetHeight;c.Bb.ho=[];c.Bb.jo=[];for(d=0;d<c.Bb.Bd;d++)c.Bb.jo.push(c.Ob[d].offsetTop),c.Bb.ho.push(c.Ob[d].offsetLeft);c.dh=!1;c.Te(c.eh)}}else c=b.Zh,a.fe[c]||(a.fe[c]=[]),a.fe[c].push(b)}f.Qn=function(){if(this.Z){im(this);this.ap=Mv(this.Fd).height/360;Dv(this);for(var a in this.Ga)this.Ga[a].Xf()}};
-function Nv(a){var b=[],c;for(c in a.Ga){var d=a.Ga[c];d instanceof $u&&b.push(a.Ga[c])}if(0!=b.length){b.sort(function(a,b){return b.qa.he-a.qa.he});c=Mv(a.Fd).height;var e=a.Ga[b[0].id].qa.he,g;for(g in b){d=a.Ga[b[g].id];d.qa.he=e;var h=Math.round(d.qa.Bd*d.Ui()),e=e-Math.round(100*(h/c));d.Xf()}}}f.Cw=function(){this.ah.stop();F(this.ti.ma)};
-f.il=function(){this.Sf.stop();var a=this.ne.length,b;for(b in this.fe)delete this.fe[b];this.ne.sort(function(a,b){return a.a==b.a?a.i-b.i:a.a-b.a});for(var c=0;c<a;c++)Kv(this,this.ne[c]);for(b in this.Ga)this.fe[b]?this.Ga[b].$o(this.fe[b]):(F(this.Ga[b].ma),delete this.Ga[b]);Nv(this);this.log_("Refreshing caption display...")};function Ov(a,b){var c=E(a).querySelectorAll("."+b+" input[type=radio]"),d=Qa(c,function(a){return a.checked}),d=(-1==d?1:d+1)%c.length;c[d].click()}
-f.Dw=function(){Ov("captions-settings-background-opacity","captions-settings-background-opacity-radio")};f.Ew=function(){Ov("captions-settings-text-opacity","captions-settings-text-opacity-radio")};f.Fw=function(){Ov("captions-settings-window-opacity","captions-settings-window-opacity-radio")};f.mw=function(a){a=parseFloat(a.target.getAttribute("value"));isNaN(a)||(this.b.backgroundOpacity=a,Dv(this))};f.zw=function(a){a=parseFloat(a.target.getAttribute("value"));isNaN(a)||(this.b.textOpacity=a,Dv(this))};
-f.Bw=function(a){a=parseFloat(a.target.getAttribute("value"));isNaN(a)||(this.b.windowOpacity=a,Dv(this))};f.rw=function(a){a.target&&(this.b.charEdgeStyle=a.target.value,Dv(this))};f.xw=function(a){a.target&&(this.b.fontFamilyOption=a.target.value,Dv(this))};f.ww=function(){var a=this.Ga[0];a&&a.ma&&(a=a.ma,W(a,"controls-hidden"),V(a,"controls-visible"))};f.uw=function(){var a=this.Ga[0];a&&a.ma&&(a=a.ma,Zl(a,"controls-visible")&&(W(a,"controls-visible"),V(a,"controls-hidden")))};
-f.Fp=function(){Pv(this,-1)};f.Gp=function(){Pv(this,1)};function Pv(a,b){a.b.fontSizeIncrement+=b;Dv(a)}function Qv(a,b){var c=E(b);c&&(c.querySelector('input[value="'+a.toFixed(1)+'"]').checked=!0)}function Rv(a,b,c){var d=E(b);d&&(b=d.querySelector("span.yt-uix-form-input-select-value"),d=d.querySelector("select"),d.value=a.b[c],Zc(b,d.options[d.selectedIndex].text))}function Fv(a){em(a);a.ne=[];a.Me=[];a.dc=null;a.il()}
-function Jv(a,b){if(b)if(a.uc)a.dc=b,Ev(a,!0),a.Mo("control_subtitles_set_track",pv(b));else if(a.Fd.hj){var c=a.Mb,d=a.$n.b,e=v(a.fo,a),g=c.Ld,c={v:c.Li,type:"track",lang:b.b,name:b.fc,kind:b.Kb,fmt:"vtt"};b.a&&(c.tlang=b.a.a);var h=document.createElement("track");h.src=Zi(g,c);h.mode="showing";h.setAttribute("kind","captions");h.setAttribute("default","");d.appendChild(h);e(b)}else yv(a.Mb,b,v(a.kv,a))}f.qw=function(){this.Z?H(v(this.Rp,this),1):this.load()};
-f.ow=function(a){a=a.currentTarget;var b=G(a,"action");if(b)switch(b){case "translate":this.yi||(im(this),hm(this),an(this.Il));break;case "settings":im(this);hm(this);Sv(this);an(this.Hl);break;case "captions-off":this.unload()}else(a=G(a,"trackid"))?(Iv(this,a),b=wv(this.Mb,a),Jv(this,b),this.log_("Caption change failed for "+a)):this.log_("onCaptionTrackClicked_ empty, ignoring")};
-function Iv(a,b){if(a.ld){var c=E("yt-uix-button-menu-item.active",a.ld);c&&W(c,"active");if(c=a.ld.querySelector(".yt-uix-button-menu-item"+('[data-trackid="'+b+'"]')))V(c,"active"),a.Rp()}}f.Rp=function(){var a=E("yt-uix-button-menu-item.active",this.ld);if(a){var b=this.ld,c=D&&!pc(8)?0:b.offsetTop,d=a.offsetTop+a.offsetHeight-c-(b.clientHeight+b.scrollTop)+1;b.scrollTop+=Math.max(d,0);d=b.scrollTop-(a.offsetTop-c)+1;b.scrollTop-=Math.max(d,0)}};f.ao=function(){bn(this.Il)};
-f.Aw=function(){if(!this.yi){this.ao();var a;t:{var b=this.Mb.zi;for(a=0;a<b.length;a++){var c=b[a];if(c.a==this.i.value){a=c;break t}}a=null}a&&(c=this.dc,b=new ov,b.b=c.b,b.Yg=c.Yg,b.fc=c.fc,b.Kb=c.Kb,b.oi=!1,b.pi=c.pi,b.a=a,tv(this.Mb.Jd,b)&&(a=b.toString(),Hv(this,a,qv(b)),Iv(this,a),this.ed&&xr(mr.getInstance(),this.ed)),Jv(this,b))}};f.lw=function(){bn(this.Hl)};f.yw=function(){delete this.b;this.b=Jb(Cv);lm(this,"display-settings",this.b);Dv(this)};
-function Dv(a){Tv(a);var b=uo(a.b.background),c=a.b.backgroundOpacity;lm(a,"display-settings",a.b);a.k=Em(".captions-text, .caption-row","background-color: rgba("+b[0]+","+b[1]+","+b[2]+","+c+") !important;",{Ib:a.k,reset:!0});Qv(c,"captions-settings-background-opacity");b=uo(a.b.color);c=a.b.textOpacity;lm(a,"display-settings",a.b);a.H=Em(".captions-text","color: rgba("+b[0]+","+b[1]+","+b[2]+","+c+") !important;",{Ib:a.H,reset:!0});Qv(c,"captions-settings-text-opacity");b=uo(a.b.windowColor);c=
-a.b.windowOpacity;lm(a,"display-settings",a.b);a.K=Em(".caption-window-transform","background-color: rgba("+b[0]+","+b[1]+","+b[2]+","+c+") !important;",{Ib:a.K,reset:!0});Qv(c,"captions-settings-window-opacity");lm(a,"display-settings",a.b);var b=a.b.charEdgeStyle,d=a.b.textOpacity;if("none"==b)Fm(a.j);else{var c="",e="rgba(34, 34, 34, "+d+")",d="rgba(204, 204, 204, "+d+")";switch(b){case "dropShadow":c="text-shadow: 2px 2px 3px "+e+", 2px 2px 4px "+e+", 2px 2px 5px "+e+";";break;case "raised":c=
-"text-shadow: 1px 1px "+e+", 2px 2px "+e+", 3px 3px "+e+";";break;case "depressed":c="text-shadow: 1px 1px "+d+", 0 1px "+d+", -1px -1px "+e+", 0 -1px "+e+";";break;case "uniform":c="text-shadow: 0 0 4px "+e+", 0 0 4px "+e+", 0 0 4px "+e+", 0 0 4px "+e+";"}a.j=Em(".captions-text",c,{Ib:a.j,reset:!0})}Rv(a,"captions-settings-char-edge-style","charEdgeStyle");c=b="";switch(a.b.fontFamilyOption){case "monoSerif":b='"Courier New", Courier, "Nimbus Mono L", monospace';break;case "propSerif":b='"Times New Roman", Times, Georgia, Cambria, serif';
-break;case "monoSans":b='"Deja Vu Sans Mono", "Lucida Console", Monaco, Consolas, monospace';break;case "propSans":b='"Arial Unicode Ms", Arial, Helvetica, Verdana, sans-serif';break;case "casual":b='"Comic Sans MS", Impact, fantasy';break;case "cursive":b='"Monotype Corsiva", "URW Chancery L", "Apple Chancery", cursive';break;case "smallCaps":b='"Arial Unicode Ms", Arial, Helvetica, Verdana, sans-serif',c="font-variant: small-caps;"}a.A=Em(".captions-text",c+"font-family: "+b+" !important;",{Ib:a.A,
-reset:!0});a.b.fontFamily=b;lm(a,"display-settings",a.b);Rv(a,"captions-settings-font-family","fontFamilyOption");lm(a,"display-settings",a.b);b="font-size: "+Math.round(((a.b.fontSizeIncrement||0)+16)*a.ap)+"px;";a.B=Em(".caption-window-transform",b,{Ib:a.B,reset:!0});a.il()}f.tw=function(a){var b=v(function(b){var d=G(a.currentTarget,b.toLowerCase());d&&(this.b[b]=d)},this);b("color");b("background");b("windowColor");Dv(this);lm(this,"display-settings",this.b)};
-function Sv(a){var b={Ib:a.g},c=a.b.color,d=a.b.background,e=a.b.windowColor;c&&(a.g=Em('.html5-popup-dialog button[data-color="'+c+'"]',"border: 3px solid #992121;",b));d&&(a.g=Em('.html5-popup-dialog button[data-background="'+d+'"]',"border: 3px solid #992121;",b));e&&(a.g=Em('.html5-popup-dialog button[data-windowcolor="'+e+'"]',"border: 3px solid #992121;",b))}
-function Tv(a){var b=[],c=v(function(a){var c=this.b[a];c&&b.push(a+": "+c+" !important")},a);c("color");c("background");c={Ib:a.g,reset:!0};a.g=Em(".captions-text",b,c);var d=uo(a.b.windowColor),c={Ib:a.I,reset:!0};a.I=Em(".caption-window-transform","background-color: rgba("+d[0]+","+d[1]+","+d[2]+", 1)",c);Sv(a)}function Hv(a,b,c){a.ld&&(b=os(a.Ep,{track_id:b,track_display_name:c}),a.ld.appendChild(b))}function Uv(a){return Bv.prototype.Xa(a)?new Bv(a):null}
-f.rq=function(a,b){switch(a){case "fontSize":return isNaN(b)||(this.b.fontSizeIncrement=b,Dv(this)),this.b.fontSizeIncrement;case "reload":b&&Av(this.Mb,v(this.po,this));break;case "track":if(b){if(!ia(b))break;var c=new ov(b);c.equals(this.dc)||(Jv(this,c),Iv(this,c.toString()))}else return this.dc?pv(this.dc):{};return"";case "tracklist":return this.Z?Ja(sv(this.Mb.Jd,b&&b.includeAsr),function(a){return pv(a)}):[]}};f.jp=function(){return["reload","fontSize","track","tracklist"]};f.Xa=function(a){return!!a.getVideoData().li};
-f.Xh=function(a){a?(a=this.dc,Fv(this),this.dc=a):(Ev(this,this.Z),this.dc&&Jv(this,this.dc))};function Ev(a,b){X(Q(a.a),a.na+"-loaded",b)};function Vv(){var a=Wb(),b;if(b=yk()){t:{if(navigator.plugins&&0<navigator.plugins.length)for(b=0;b<navigator.plugins.length;b++)if(0<=navigator.plugins[b].name.indexOf("NVIDIA 3D Vision")){b=!0;break t}b=!1}if(b)t:{var c=navigator.userAgent.match(/Firefox[\/\s](\d+\.\d+)/);if(c&&1<c.length&&4<=c[1]){c=document.createElement("embed");c.setAttribute("id","NvImageDetectionFFID");c.setAttribute("style","visibility: hidden");c.setAttribute("width",25);c.setAttribute("height",25);c.setAttribute("type",
-"image/jps");Uc(document.documentElement,c);c=Ic("NvImageDetectionFFID");try{if(null!=c){b=27527<=c.NvGetDriverVersion();break t}}catch(d){}}b=!1}}return b||!(!a||-1==a.indexOf("Sony"))};function Wv(a){dm.call(this,a);var b=a.getVideoData();b.S&&Xv(this);Yv(this,"html5-threed-conversion-on",v(this.Iv,this));Yv(this,"html5-threed-conversion-off",v(this.Hv,this));var c=Q(this.a);a=E("html5-threed-popup-menu-change-mode-link",c);c=E("html5-threed-dialog-change-mode-button",c);b="/select_3d_mode?video_id="+b.L;a.setAttribute("href",b);c.setAttribute("href",b)}y(Wv,dm);f=Wv.prototype;f.yl="threeDModuleData";f.$e=null;function Yv(a,b,c){a=E(b,Q(a.a));K(a,"click",c)}f.na="threed";f.kd="threed";
-f.create=function(){Zv(this.a.app,void 0);Wv.C.create.call(this)};f.destroy=function(){Zv(this.a.app,!0);this.unload();Wv.C.destroy.call(this)};function $v(a){return Wv.prototype.Xa(a)?new Wv(a):null}f.Xa=function(a){a=a.getVideoData();return!!a.S||!!a.Kj};f.Iv=function(){aw(this,!0)};f.Hv=function(){aw(this,!1)};function aw(a,b){var c=a.a.getVideoData();if(c.Kj&&c.Jf!=b){var c=a.a.app,d=O(c),e=d.a;e.Jf=!e.Jf;e.k=[];e.u("dataupdated");ag(d,"m");Zv(c);b?Xv(a):im(a)}}
-function Xv(a){km(a,"warning-shown")||Vv()||(a.$e=E("threed-html5-warning-dialog",Q(a.a)),an(a.$e),H(v(function(){bw(this)},a),0),K(a.$e,"mouseover",v(function(){W(this.$e,"hide-dialog")},a)),K(a.$e,"mouseout",v(function(){bw(this)},a)),Yv(a,"threed-html5-warning-close",v(a.Qv,a)))}function bw(a){V(a.$e,"hide-dialog");H(v(function(){Zl(this.$e,"hide-dialog")&&im(this)},a),9E3)}f.Qv=function(){lm(this,"warning-shown",!0);im(this)};function cw(a){dm.call(this,a);this.b=new sm(["div","ytp-ypc-clickwrap-overlay",["h2","header",J("YPC_CLICKWRAP_HEADER")],["div","description",J("YPC_CLICKWRAP_DESCRIPTION")],["button","confirm-button",J("YPC_CLICKWRAP_BUTTON")]]);zm(this.b.M());this.a.app.P.g.appendChild(this.b.M());L(this,this.b);this.g=this.b.a["confirm-button"]}y(cw,dm);f=cw.prototype;f.na="ypc_clickwrap";f.kd="ypc-clickwrap";f.Xa=function(){return Ml(this.a.getVideoData(),"ypc_clickwrap_module")};
-function dw(a){return Ml(a.getVideoData(),"ypc_clickwrap_module")?new cw(a):null}f.create=function(){cw.C.create.call(this);this.load()};f.destroy=function(){this.Z&&this.unload()};f.load=function(){cw.C.load.call(this);E("html5-video-container",Q(this.a));ym(this.b.M());K(this.g,"click",v(this.xu,this));this.Z=!0};f.unload=function(){zm(this.b.M());Af(this.g);this.Z=!1;cw.C.unload.call(this)};f.xu=function(){fm(this);this.destroy()};function ew(a){a=a.b;this.j=a.ypc_offer_button_text;this.description=a.ypc_offer_description;this.heading=a.ypc_offer_headline;this.k=a.ypc_full_video_message;this.b=a.ypc_offer_id;this.a=a.ypc_buy_url;this.g=a.ypc_item_thumbnail;this.title=a.ypc_item_title;this.i=a.ypc_item_url;this.L=a.ypc_vid};function fw(){Z.call(this,["div",["ytp-drawer","html5-stop-propagation"],["div","ytp-drawer-content","{{content}}"],["a","ytp-drawer-close-button"],["a","ytp-drawer-open-button"]]);this.b=this.template.a["ytp-drawer-close-button"];K(this.b,"click",v(this.hide,this));this.a=this.template.a["ytp-drawer-open-button"];K(this.a,"click",v(this.show,this));this.Aa(null);this.hide()}y(fw,Z);fw.prototype.hide=function(){V(this.element,"ytp-drawer-closed")};
-fw.prototype.Aa=function(a){a?(fw.C.Aa.call(this,a),ym(this.element)):zm(this.element)};fw.prototype.show=function(){H(oa(W,this.element,"ytp-drawer-closed"),0)};fw.prototype.F=function(){Af(this.b);Af(this.a);this.a=this.b=null;fw.C.F.call(this)};function gw(a,b){R.call(this);this.a=new fw;L(this,this.a);this.b=document.createElement("div");$l(this.b,["html5-stop-propagation","html5-ypc-endscreen"]);this.i=document.createElement("div");V(this.i,"html5-ypc-overlay");this.g=new sm(["div","html5-ypc-module",["div","html5-ypc-action-heading","{{heading}}"],["div","html5-ypc-thumbnail","{{thumbnail_element}}"],["div","html5-ypc-title","{{title}}"],["div","html5-ypc-description","{{description}}"],["button","html5-ypc-purchase","{{button_label}}"]]);
-L(this,this.g);this.j=this.g.a["html5-ypc-purchase"];K(this.j,"click",v(this.k,this));Zc(this.i,b.k);var c=b.title;b.i&&(c=["a",{href:b.i,target:"blank_"},b.title]);var d="";b.g&&(d=["img",{src:b.g}]);this.g.update({heading:b.heading,title:c,thumbnail_element:d,description:b.description,button_label:b.j});this.a.T(a);this.a.Aa(this.g.M());a.appendChild(this.b)}y(gw,R);gw.prototype.F=function(){gw.C.F.call(this);this.j&&Af(this.j);F(this.b);F(this.i);this.i=this.b=this.a=null};gw.prototype.k=function(){this.u("ypcContentRequest")};function hw(a){dm.call(this,a);this.g=this.b=null;this.i=NaN}y(hw,dm);f=hw.prototype;f.na="ypc";f.kd="ypc";function iw(a){var b=a.getVideoData();return a.J().Mc&&Ml(b,"ypc_module")}f.Xa=function(){return iw(this.a)};function jw(a){return iw(a)?new hw(a):null}f.create=function(){hw.C.create.call(this);var a=this.a.getVideoData();this.b=new ew(a);a.ba?this.load():this.a.No({video_id:this.b.L,ypc_preview:1})};f.destroy=function(){this.Z&&this.unload();this.b=null};
-f.load=function(){hw.C.load.call(this);var a=E("html5-video-container",Q(this.a));this.g=new gw(a,this.b);this.g.D("ypcContentRequest",this.Wt,this);Lv(this.a.app.P,this.g.i);yn(this.a.J())&&(a=new nh(2147483647,2147483647,{priority:2}),this.yf(a));this.g.a.show();I(this.i);this.i=H(v(function(){this.g.a.hide()},this),1E4);this.Z=!0};f.unload=function(){em(this);Of(this.g);this.g=null;this.Z=!1;hw.C.unload.call(this)};
-f.vc=function(a){hw.C.vc.call(this,a);a=this.g;a.b.appendChild(a.g.M());a.a.Aa(null);ym(a.b)};f.dd=function(a){hw.C.dd.call(this,a);a=this.g;zm(a.b);a.a.Aa(a.g.M())};f.Wt=function(){if(this.b.a)"embedded"==this.a.J().Y?Cr(this.b.a):window.location=S(this.b.a,{})+"";else if(this.b.b){var a=n("yt.www.watch.player.handleEndPreview");a&&a(this.b.b)}};var kw={Mz:"ERROR_ALREADY_PINNED_ON_A_DEVICE",Rz:"ERROR_AUTHENTICATION_EXPIRED",Sz:"ERROR_AUTHENTICATION_MALFORMED",Tz:"ERROR_AUTHENTICATION_MISSING",cA:"ERROR_BAD_REQUEST",iA:"ERROR_CANNOT_ACTIVATE_RENTAL",qA:"ERROR_CGI_PARAMS_MALFORMED",rA:"ERROR_CGI_PARAMS_MISSING",cB:"DEVICE_FALLBACK",fB:"ERROR_LICENSE",iB:"FLASH_FALLBACK",HB:"ERROR_GEO_FAILURE",TB:"HTML5_DEFAULT_FALLBACK",UB:"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",ZB:"ERROR_INVALID_DRM_MESSAGE",cC:"LEARN_MORE",uC:"ERROR_NOT_SIGNED_IN",FC:"ERROR_PURCHASE_NOT_FOUND",
-GC:"ERROR_PURCHASE_REFUNDED",JC:"ERROR_RENTAL_EXPIRED",jA:"ERROR_CAST_SESSION_DEVICE_MISMATCHED",kA:"ERROR_CAST_SESSION_VIDEO_MISMATCHED",mA:"ERROR_CAST_TOKEN_FAILED",lA:"ERROR_CAST_TOKEN_EXPIRED",nA:"ERROR_CAST_TOKEN_MALFORMED",PC:"ERROR_SERVER_ERROR",TC:"ERROR_STOPPED_BY_ANOTHER_PLAYBACK",VC:"ERROR_STREAMING_DEVICES_QUOTA_PER_24H_EXCEEDED",WC:"ERROR_STREAMING_NOT_ALLOWED",XC:"ERROR_STREAMING_UNAVAILABLE",KC:"ERROR_RETRYABLE_ERROR",dD:"ERROR_TOO_MANY_STREAMS_PER_USER",cD:"ERROR_TOO_MANY_STREAMS_PER_ENTITLEMENT",
-gD:"ERROR_UNSUPPORTED_DEVICE",hD:"ERROR_UNUSUAL_ACTIVITY",oD:"ERROR_VIDEO_FORBIDDEN",qD:"ERROR_VIDEO_NOT_FOUND"},lw={300:"ERROR_STREAMING_DEVICES_QUOTA_PER_24H_EXCEEDED",301:"ERROR_ALREADY_PINNED_ON_A_DEVICE",303:"ERROR_STOPPED_BY_ANOTHER_PLAYBACK",304:"ERROR_TOO_MANY_STREAMS_PER_USER",305:"ERROR_TOO_MANY_STREAMS_PER_ENTITLEMENT",400:"ERROR_VIDEO_NOT_FOUND",401:"ERROR_GEO_FAILURE",402:"ERROR_STREAMING_NOT_ALLOWED",403:"ERROR_UNSUPPORTED_DEVICE",405:"ERROR_VIDEO_FORBIDDEN",500:"ERROR_PURCHASE_NOT_FOUND",
-501:"ERROR_RENTAL_EXPIRED",502:"ERROR_PURCHASE_REFUNDED",5E3:"ERROR_BAD_REQUEST",5001:"ERROR_CGI_PARAMS_MISSING",5002:"ERROR_CGI_PARAMS_MALFORMED",5100:"ERROR_AUTHENTICATION_MISSING",5101:"ERROR_AUTHENTICATION_MALFORMED",5102:"ERROR_AUTHENTICATION_EXPIRED",5200:"ERROR_CAST_TOKEN_MALFORMED",5201:"ERROR_CAST_TOKEN_EXPIRED",5202:"ERROR_CAST_TOKEN_FAILED",5203:"ERROR_CAST_SESSION_VIDEO_MISMATCHED",5204:"ERROR_CAST_SESSION_DEVICE_MISMATCHED",6E3:"ERROR_INVALID_DRM_MESSAGE",7E3:"ERROR_SERVER_ERROR",8E3:"ERROR_RETRYABLE_ERROR"};function mw(a){dm.call(this,a);this.na="ypc_license_checker";this.kd="ypc_license";this.j=!1;this.i=0;this.g=!1;this.b=null;this.B=Ck();this.A=a.J().ib+"ypc_license_server"}y(mw,dm);
-var nw={LICENSE_DENIED_CANNOT_ACTIVATE_RENTAL:"ERROR_CANNOT_ACTIVATE_RENTAL",LICENSE_DENIED_NOT_SIGNED_IN:"ERROR_NOT_SIGNED_IN",LICENSE_DENIED_NO_ACTIVE_PURCHASE_AGREEMENT:"ERROR_RENTAL_EXPIRED",LICENSE_DENIED_CONCURRENT_PLAYBACK:"ERROR_STOPPED_BY_ANOTHER_PLAYBACK",LICENSE_DENIED_UNUSUAL_ACTIVITY:"ERROR_UNUSUAL_ACTIVITY",LICENSE_DENIED_STREAMING_UNAVAILABLE:"ERROR_STREAMING_UNAVAILABLE",LICENSE_DENIED_PLAYBACK_CAP:"ERROR_LICENSE"};
-function ow(a){return Ml(a.getVideoData(),"ypc_license_checker_module")}f=mw.prototype;f.Xa=function(){return ow(this.a)};f.create=function(){mw.C.create.call(this);var a=new nh(1E3,2147483646,{priority:0});this.yf(a);this.D("onStateChange",this.qx,this)};function pw(a){return ow(a)?new mw(a):null}f.vc=function(){this.j=!0;qw(this,6E4)};f.qx=function(a){P(a.state,2)?(this.i=0,this.b=null,this.g=!1):(P(a.state,1)||P(a.state,8))&&qw(this,6E4)};
-function qw(a,b){if(!a.b&&a.j){var c=b;void 0==c&&(c=a.g?6E4:1E3);var d=a.a.getVideoData();d.a&&d.a.g||(a.b={video_id:d.L,player_id:a.B,request_id:Ck(),purchase_id:d.pd,version:"4",player_time_seconds:a.a.getCurrentTime().toString(),gid:d.Ic,session_token:d.Mc},a.k=d.Ca,0==c?a.En():H(v(a.En,a),c))}}f.En=function(){if(this.b){var a=S(this.A,{cpn:this.k});ej(a,{format:"RAW",method:"POST",Nf:this.b,timeout:3E4,Oa:v(this.Wv,this),onError:v(this.Vv,this),al:v(this.Xv,this)})}};
-f.Wv=function(a){if(this.b){a=a.responseText;var b=a in nw?1:64<=a.length&&a.match(/[0-9a-fA-f]+/)?0:-1;-1==b?rw(this,"decode"):(this.i=0,this.b=null,1==b?(this.g=!1,a=a in nw?J(nw[a]):J("ERROR_LICENSE"),sw(this.a.app.b,150,a,void 0)):(this.g=!0,qw(this)))}};f.Vv=function(a){rw(this,"net-"+a.status)};f.Xv=function(){rw(this,"timeout")};function rw(a,b){if(a.b)if(a.log({errorType:b}),a.b=null,5<++a.i){var c=J("ERROR_LICENSE");sw(a.a.app.b,150,c,void 0)}else qw(a)};function tw(){this.a=[];this.i={};this.o={};this.G={};this.b=this.j=null;this.g=[];this.k=null}y(tw,Lf);tw.prototype.B=function(a){if(this.b){var b;var c=ja(a);b=this.i[c];if(!b)if(this.b){if(b=a(this.b)){a=this.i[c]=b;for(var d in this.j)a.D(d,this.j[d]);a.D("command_log_timing",this.A,this);L(this,b)}}else b=null;b&&b.Xa(this.b)&&!A(this.a,b)&&(b.create(),this.a.push(b),A(this.g,b.na)&&(b.uc=this.k,b.Xh(!!b.uc)))}};function uw(a){z(a.a,function(a){a.destroy()});a.a=[]}
-function vw(a,b,c){ww(a);a.k=b;a.g=Ya(c);z(a.a,function(a){0<=Ha(c,a.na)&&(a.uc=b,a.Xh(!!a.uc))})}function ww(a){z(a.g,function(a){if(a=dg(this,a))a.uc=null,a.Xh(!1)},a);a.k=null;a.g=[]}function tg(a,b,c,d){return b&&c?(a=dg(a,b))?a.rq(c,d):null:null}function ug(a,b){if(!b)return Ja(a.a,function(a){return a.na});var c=dg(a,b);return c?c.jp():[]}function dg(a,b){return Na(a.a,function(a){return a.na==b})}tw.prototype.H=function(a,b){z(this.a,function(c){c.u(a,b)})};
-function xw(a){var b=[];z(a.a,function(a){(a=a.Oi())&&b.push(a)});return b}tw.prototype.A=function(a,b){pa(this.G,a||null);pa(this.o,b||null)};function yw(a){this.a={};for(var b=0;b<a.length;b++){var c=a[b];this.a[c.a]=c}}function zw(a){a=Eb(a.a);db(a,function(a,c){return a.a-c.a});return a};function Aw(a,b,c){this.b=a;this.a=b;this.i=!!c.Hf;this.g=c.aa};function Bw(){this.ke={};this.a=this.Za().a;this.fd=null}f=Bw.prototype;f.Za=function(){var a=this.constructor,b;if(!(b=a.Yp)){var c;b=a.Qx;var d=[];for(c in b)b.hasOwnProperty(c)&&(0==c||d.push(new Aw(a,c,b[c])));c=new yw(d);b=a.Yp=c}return b};f.has=function(a){a.b.Za();this.Za();return null!=this.ke[a.a]};f.get=function(a,b){a.b.Za();this.Za();var c;c=this.a[a.a];var d=Cw(this,c);c.i?(t(d),c=d[b||0]):(t(d),c=d);return c};
-f.set=function(a,b){a.b.Za();this.Za();var c=a.a;this.ke[c]=b;this.fd&&(this.fd[c]=b)};f.add=function(a,b){a.b.Za();this.Za();var c=a.a;this.ke[c]||(this.ke[c]=[]);this.ke[c].push(b);this.fd&&delete this.fd[c]};f.clear=function(a){a.b.Za();this.Za();a=a.a;delete this.ke[a];this.fd&&delete this.fd[a]};
-f.equals=function(a){if(!a||this.constructor!=a.constructor)return!1;for(var b=zw(this.Za()),c=0;c<b.length;c++){var d=b[c];if(this.has(d)!=a.has(d))return!1;if(this.has(d)){var e=11==d.g||10==d.g,g=Cw(this,d),h=Cw(a,d);if(d.i){if(g.length!=h.length)return!1;for(d=0;d<g.length;d++)if(e?!g[d].equals(h[d]):g[d]!=h[d])return!1}else if(e?!g.equals(h):g!=h)return!1}}return!0};
-function Dw(a,b){for(var c=zw(a.Za()),d=0;d<c.length;d++){var e=c[d];if(b.has(e)){a.fd&&delete a.fd[e.a];var g=11==e.g||10==e.g;if(e.i){var h,k=b;h=e;h.b.Za();k.Za();h=Cw(k,k.a[h.a]);null==h||t(h);h=h||[];for(k=0;k<h.length;k++)a.add(e,g?h[k].clone():h[k])}else h=Cw(b,e),g?(g=Cw(a,e))?Dw(g,h):a.set(e,h.clone()):a.set(e,h)}}}f.clone=function(){var a=new this.constructor;a!=this&&(a.ke={},a.fd&&(a.fd={}),Dw(a,this));return a};function Cw(a,b){var c=a.ke[b.a];return null==c?null:c}
-function Ew(a,b){a.Qx=b;a.Za=function(){return a.Yp||(new a).Za()}};var Fw={Xy:0,HA:1,SA:2,Wy:3,ez:4,FA:5,QA:6,NA:7,OA:8,PA:9,LA:10,MA:11,gz:12,fz:13,Vy:14,Py:15,GA:20,UA:21,Oy:22,IA:23,TA:24,RA:25,bz:30,VA:31,az:32,cz:33,KA:40,JA:41,hz:42,iz:43,Qy:50,Ty:51,Yy:52,Zy:53,$y:54,Ly:55,My:56,dz:57,Uy:58,Sy:60,Ry:61,Ny:70,Ky:80,jz:90};function Gw(){Bw.apply(this)}y(Gw,Bw);function Hw(){Bw.apply(this)}y(Hw,Bw);function Iw(){Bw.apply(this)}y(Iw,Bw);function Jw(){Bw.apply(this)}y(Jw,Bw);function Kw(){Bw.apply(this)}y(Kw,Bw);function Lw(){Bw.apply(this)}y(Lw,Bw);
-Ew(Gw,{0:{name:"YtAdType",th:"video.YtAdType"},1:{name:"ad_namespace",required:!0,aa:14,defaultValue:0,type:{Kz:0,dB:1,Lz:2,oA:3,GB:4,bB:5,aB:6,eA:7,ZA:8,gA:9,YA:10,$A:11,Qz:12,ND:13}},2:{name:"ad_format",required:!0,aa:14,defaultValue:0,type:{Hz:0,$B:1,YB:2,rC:3,iD:4,aC:5,VB:6,XB:7,OD:8,eB:9}},3:{name:"ad_invideo",aa:14,defaultValue:0,type:{Jz:0,wA:1,xA:2,yA:3,zA:4,vA:5,hA:6}},4:{name:"invideo_autoplay",aa:14,defaultValue:0,type:{aA:0,EC:1}},5:{name:"ad_instream",aa:14,defaultValue:0,type:{Iz:0,
-eD:1}},6:{name:"ad_instream_long",aa:8,type:Boolean}});Ew(Hw,{0:{name:"AdId",th:"video.AdId"},1:{name:"ad_network",aa:14,defaultValue:1,type:{yC:1,Jy:2}},2:{name:"ad_network_name",aa:9,type:String},3:{name:"ad_id",required:!0,aa:9,type:String}});
-Ew(Iw,{0:{name:"YtAdEvent",th:"video.YtAdEvent"},1:{name:"ad_event_type",required:!0,aa:14,defaultValue:0,type:{tz:0,Az:1,uz:2,Dz:3,vz:4,wz:5,pz:6,nz:7,WA:8,kz:9,Bz:10,Cz:11,lz:12,XA:13,Ez:14,qz:15,mz:16,rz:17,oz:18,Fz:100,Gz:101,yz:130,xz:131,zz:132}},2:{name:"wall_time",required:!0,aa:2,type:Number},3:{name:"media_time",required:!0,aa:2,type:Number},4:{name:"logentry_time_usec",required:!0,aa:3,type:String},5:{name:"ad_error_type",aa:14,defaultValue:0,type:Fw}});
-Ew(Jw,{0:{name:"YtAdSlot",th:"video.YtAdSlot"},1:{name:"slot_time",required:!0,aa:2,type:Number},2:{name:"ad_type",required:!0,aa:11,type:Gw},3:{name:"ad_events",Hf:!0,aa:11,type:Iw},4:{name:"ad_video_duration",aa:2,type:Number},5:{name:"ad_id",aa:9,type:String},6:{name:"slot_index",aa:5,type:Number}});
-Ew(Kw,{0:{name:"YtVideoMetadata",th:"video.YtVideoMetadata"},1:{name:"content_owner_ids",Hf:!0,aa:9,type:String},2:{name:"video_duration_seconds",aa:2,type:Number},3:{name:"all_content_owner_ids",aa:9,type:String}});
-Ew(Lw,{0:{name:"YtWatchAdInfo",th:"video.YtWatchAdInfo"},1:{name:"video_id",required:!0,aa:9,type:String},2:{name:"allowed_ads",Hf:!0,aa:11,type:Gw},3:{name:"ad_slots",Hf:!0,aa:11,type:Jw},4:{name:"ps",aa:9,type:String},5:{name:"el",aa:9,type:String},6:{name:"country",aa:9,type:String},7:{name:"feature",aa:9,type:String},8:{name:"blocked",aa:8,type:Boolean},9:{name:"plid",aa:9,type:String},10:{name:"video_metadata",aa:11,type:Kw},11:{name:"experiment_id",Hf:!0,aa:3,type:String},12:{name:"ad_flags",
-aa:4,type:String},13:{name:"all_experiment_ids",aa:9,type:String},14:{name:"no_ads_returned",aa:8,type:Boolean},15:{name:"ad_errors",Hf:!0,aa:14,defaultValue:0,type:Fw},16:{name:"ad_slot_with_event",aa:11,type:Jw}});function Mw(a,b){yg.call(this,a,b)}y(Mw,yg);f=Mw.prototype;f.qg=function(){Qf(this.app,!0,this.a);this.app.Ud(!1,this.a)};f.mn=function(){this.app.Sd(!1,this.a)};f.Up=function(a,b,c){Qf(this.app,!0,this.a);var d=this.app,e=this.a;d.sf(d.getCurrentTime()+a,b,c,e)};f.Th=function(a,b){Qf(this.app,!0,this.a);this.app.sf(a,b,void 0,this.a)};f.Jj=function(){Xf(this.app,this.a)};function Nw(a){this.app=a;dm.call(this,a.I)}y(Nw,dm);var Ow={vC:"0",wC:"1",gB:"2",my:"3",bA:"4",OC:"5"};var Pw={IC:"red",LD:"white"};var Qw={oy:"0",SC:"1",CA:"2"};var Rw={"ad-trueview-indisplay-pv":6,"ad-trueview-insearch":7},Sw={"ad-trueview-indisplay-pv":2,"ad-trueview-insearch":2},Tw={detailpage:{Tb:!0}};Tw.embedded={Ch:Cf(),Bh:"4",sc:!0};Tw.profilepage={xl:!0};
-var Uw="ad blogger books docs google-live play picasaweb".split(" "),Vw={ad:{Rd:!1,ff:!1,lc:!1,Wb:!1,Tb:!1,sc:!1,Vb:"adt"},blazer:{lj:"youtube_mobile",Sb:!1,uy:!1,Fg:!1,Gg:!1,kc:!0,Ub:!1,tb:!1,Gb:!0},blogger:{Rd:!1,ff:!1,lc:!1,Wb:!1,qc:!1,Tb:!1,sc:!1,Vb:"bl"},books:{Rd:!1,ff:!1,lc:!1,Wb:!1,qc:!1,Tb:!0,sc:!1,Vb:"gb"},docs:{Rd:!1,ff:!1,lc:!1,Wb:!1,qc:!1,Tb:!1,sc:!1,Vb:"gd"},"google-live":{Rd:!1,ff:!1,lc:!1,Wb:!1,qc:!1,Tb:!1,sc:!1,Vb:"gl"},play:{Wb:!1,qc:!1,Tb:!1,sc:!1,Vb:"gp"},"native":{Fg:!1,Gg:!1,
-Ub:!0},olympics:{Fg:!1,Gg:!1,Mh:!0,Gb:!0},picasaweb:{Rd:!1,ff:!1,lc:!1,Wb:!1,qc:!1,Tb:!1,sc:!1,Vb:"pw"},touch:{Fg:!1,Gg:!1,Gb:!0}};
-function Ww(a){this.g=[];this.a={};Xw(this,a.fexp);this.fa=U(this.fa,a.origin);this.Y=a.el||this.Y;var b=Tw[this.Y];b&&pa(this,b);b=a.ps||this.Ja;0<navigator.msMaxTouchPoints&&(b="touch");this.Ja=b;(b=Vw[this.Ja])&&pa(this,b);this.nf=Yw(this)&&A(Uw,this.Ja);this.jg=!(!xk().defaultPlaybackRate||$b||hi||gi||ii);if(a.use_media_volume)b=!1;else{var b=xk(),c=b.muted;b.muted=!c;b=b.muted!=c}this.om=b;this.Im=ii;if(hi||gi)this.tm=this.Kc||"blazer"!=this.Ja;this.um="0"!=a.add_player_event_listeners;b=T(this.Ch,
-a.fs);this.Ch="detailpage"==this.Y||"olympics"==this.Ja?b:b&&Cf();this.Da=U(this.Da,a.authuser);this.Bh=Ek(this.Bh,a.autohide,Ow);this.Sb=T(this.Sb,a.autoplay);this.Fj=T(this.Fj,a.autoplayoverride);this.color=Ek(this.color,a.color,Pw);this.o=U(this.o,a.content_v);this.Gj=Ek(this.Gj,a.controls,Qw);this.G=U(this.G,a.cbrand);this.A=U(this.A,a.cbr);this.B=U(this.B,a.cbrver);this.eg=U(this.eg,a.c);this.jf=U(this.jf,a.cver);this.H=U(this.H,a.cmodel);this.I=U(this.I,a.cnetwork);this.K=U(this.K,a.cos);this.N=
-U(this.N,a.cosver);this.O=U(this.O,a.cplatform);this.Lh=T(this.Lh,a.edu_mode);this.b=U(this.b,a.eurl);this.R=U(this.R,a.framer);this.ca=Ek(this.ca,a.iv_load_policy,pk);this.i=U(this.i,a.hl);this.Jm=T(this.Jm,a.bwlogging);this.kc=T(this.kc,a.is_html5_mobile_device);this.Od=T(this.Od,a.player_wide);this.Km=T(this.Km,a.is_playground);this.loop=T(this.loop,a.loop);this.of=T(this.of,a.modestbranding);"red"!=this.color&&(this.of=!1);this.wh=T(this.wh,a.noadapt);this.dg=T(this.dg,a.on3g);this.Ta=U(this.Ta,
-a.pageid);this.Dh=Ek(this.Dh,a.vq,sj);this.qj=U(this.qj,a.playerapiid);this.Ah=T(this.Ah,a.playsinline);this.S=U(this.S,a.cr);this.oa=U(this.oa,a.q);this.lc=T(this.lc,a.logwatch);this.vj=T(this.vj,a.canplaylive);this.wj=T(this.wj,a.canplaypaid);this.Wb=T(this.Wb,a.showinfo);this.qc=T(this.qc,a.rel);this.Tb=T(this.Tb,a.enablesizebutton);this.oj=T(this.oj,a.ss);this.U=U(this.U,a.theme);this.Ub=T(this.Ub,a.use_native_controls);this.tb=!gi&&T(this.tb,a.svt);Yw(this)&&(this.Kh=T(this.Kh,a.altf),this.lg=
-T(this.lg,a.retryneterr),this.Mh=T(this.Mh,a.nologo));this.lg=this.lg||this.nd;this.Ub&&(this.of=!0,this.ca=3);this.Hj=T(this.Hj,a.ssl);if(this.Gb=T(this.Gb,a.use_tablet_controls))this.U="dark";b=this.Fh;if(c=a.video_container_override){var d=c.split("x");2==d.length&&(c=parseInt(d[0],10),d=parseInt(d[1],10),b=isNaN(c)||isNaN(d)||0>=c*d?b:new C(c,d))}this.Fh=b;this.hb=U(this.hb,a.attrib);this.$=U(this.$,a.sk);this.protocol=this.Hj?"https":"http";this.ve="0"!=this.Gj;this.pj=T(this.ve,a.store_user_volume);
-this.Pd=T(this.Pd,a.use_media_volume);(b=a.BASE_YT_URL)&&Cj(b,yj)&&(this.ib=b);Zw(this,a);$w(this,a);"detailpage"==this.Y&&delete this.b;this.fj=ax(this)+"s";this.sc=this.of&&!this.Ub?!this.Wb:this.Wb||this.ve?!1:this.sc;b=this.Sb||"detailpage"==this.Y;c=!0;this.kc&&(c=!1);si("nintendo wiiu")&&(c=!1);this.Fj&&(c=!0);this.qm=b&&c;this.a=a}y(Ww,Lf);f=Ww.prototype;f.um=!0;f.Ch=!0;f.Da="";f.Bh="2";f.Sb=!1;f.Fj=!1;f.ib="/";f.uy=!0;f.color="red";f.Gj="1";f.eg="web";f.jf="html5";f.Lh=!1;f.Fg=!0;f.Gg=!0;
-f.jg=!1;f.om=!1;f.Y="detailpage";f.Jm=!1;f.Lk=!1;f.nf=!1;f.kc=!1;f.Ab=!1;f.Od=!1;f.Rd=!0;f.Km=!1;f.ff=!0;f.Ig=!1;f.loop=!1;f.of=!1;f.wh=!1;f.Dh=null;f.qj="";f.dg=!1;f.Ta="";f.Ja=null;f.Ah=!1;f.Kh=!1;f.Im=!1;f.lg=!1;f.qm=!1;f.lc=!1;f.vj=!0;f.wj=!0;f.ve=!0;f.pj=!0;f.Pd=!1;f.Wb=!0;f.qc=!0;f.xl=!1;f.Tb=!1;f.sc=!1;f.oj=!1;f.Mh=!1;f.tm=!1;f.Ub=!1;f.tb=!0;f.Hj=!1;f.Gb=!1;f.Sc=null;f.Fh=null;f.xv=null;f.ug=null;f.Wa=null;f.nk=null;f.Vb="yt";
-function Zw(a,b){a.lc=T(a.lc,b.logwatch);a.ra=void 0==b.user_age?a.ra:Number(b.user_age);a.Pp=U(a.Pp,b.user_display_image);a.Ql=U(a.Ql,b.user_display_name);a.ua=U(a.ua,b.user_gender)}
-function $w(a,b){var c;t:{if(b&&((c=b.adformat)||(c=(c=b.attrib)&&c in Rw&&c in Sw?Sw[c]+"_"+Rw[c]:void 0),c)){var d=c.match(/^(\d*)_((\d*)_?(\d*))$/);if(d&&5==d.length&&(d=d[3],d=6==d||7==d||9==d||11==d,Cj(a.fa,zj)||d))break t}c=void 0}c&&(a.j=c,a.a.adformat=b.adformat);c=b.agcid;a.qb=c;a.a.agcid=c;c=b.feature;a.k=c;a.a.feature=c;if(c=b.referrer)a.referrer=c,a.a.referrer=c;"1"==b.enablecsi&&(a.Lk=!1)}
-function bx(a){var b={};b.c=a.eg;a.jf&&(b.cver=a.jf);a.O&&(b.cplatform=a.O);a.G&&(b.cbrand=a.G);a.H&&(b.cmodel=a.H);a.I&&(b.cnetwork=a.I);a.A&&(b.cbr=a.A);a.B&&(b.cbrver=a.B);a.K&&(b.cos=a.K);a.N&&(b.cosver=a.N);return b}
-function Xw(a,b){if(b){a.g=b.split(",");var c={};z(a.g,function(a){c[a]=!0});a.Kc=!!c["918108"];a.Mc=!!c["912711"];a.hj=!!c["925900"];a.jj=!!c["913559"];a.Ma=!!c["913428"];a.ba=!!c["904828"]||!!c["904830"];a.Ra=!!c["913424"];a.za=!!c["932206"];a.Fc=!!c["932217"];a.od=!!c["932225"];a.Oc=!!c["932246"];a.Ec=!!c["932245"];a.Jc=!!c["932240"];a.te=!!c["932236"];a.Ic=!!c["932237"];a.Hc=!!c["932242"];a.Dc=!!c["932243"];a.Nc=!!c["932247"];a.bg=!!c["932248"];a.Ia=!!c["932239"];a.pd=!!c["932249"];a.Gc=!!c["924604"];
-a.Lc=!!c["924610"];a.nd=!!c["918117"];a.La=!!c["907226"]&&"leanback"!=a.Y;a.ea=!!c["938600"]}}
-function cx(a,b){switch(b.qd){case 38:var c=b.L.indexOf(":"),d=b.L.slice(0,c),c=b.L.slice(c+1);return S("//play.google.com/books/volumes/"+d+"/content/media",{aid:c,sig:b.nd});case 30:return d="//docs.google.com/",a.ib!=Ww.prototype.ib&&(d=a.ib),S(d+"get_video_info",{docid:b.L,authuser:b.Da,authkey:b.vo,eurl:a.b});case 33:return S("//google-liveplayer.appspot.com/get_video_info",{key:b.L});default:return d={html5:"1",video_id:b.L,cpn:b.Ca,eurl:a.b,ps:a.Ja,el:a.Y,hl:a.i,list:b.Na,agcid:a.qb,sts:15947},
-b.U?d.vvt=b.U:b.H&&(d.access_token=b.H),a.j&&(d.adformat=a.j),b.ca&&(d.iv_load_policy=b.ca),b.hf&&(d.autoplay="1"),b.Wk&&(d.mdx="1"),b.Xk&&(d.utpsa="1"),b.Nc&&(d.is_fling="1"),c=dx(a),c.width&&(d.width=c.width),c.height&&(d.height=c.height),b.ba&&(d.ypc_preview="1"),b.Nd&&(d.splay="1"),a.o&&(d.content_v=a.o),b.wo&&(d.livemonitor=1),a.Da&&(d.authuser=a.Da),a.Ta&&(d.pageid=a.Ta),pa(d,bx(a)),S(a.ib+"get_video_info",d)}}
-function ax(a){return a.Lh?"//s.youtubeeducation.com/":a.ff?"//s.youtube.com/":"//video.google.com/"}function ex(a){return a.referrer?a.referrer.slice(0,128):""}
-function ot(a,b,c,d){b={v:b.L,list:b.Na};a.Y&&(b.feature="player_"+a.Y);c&&pa(b,c);a=S(a.protocol+"://"+("www.youtube-nocookie.com"==window.location.host||a.Lh?"www.youtube.com":window.location.host)+"/watch",b);if(d){c="";c="!"=="#".charAt(1)?"#".substr(0,2):"#";b="#";"#"==b.charAt(0)&&(b="!"==b.charAt(1)?b.substr(2):b.substr(1));b=Ui(b);for(var e in d)b[e]=d[e];d=c+Wi(b);a=a+d}return a}
-function fx(a){var b={contact_type:"playbackissue",html5:1,plid:a.ab,ei:a.j,v:a.L};a.a&&(b.fmt=a.a.Sa);return S("//www.google.com/support/youtube/bin/request.py",b)}function dx(a){return(a=a.nk)?new C(a.clientWidth,a.clientHeight):new C(Number.NaN,Number.NaN)}function Mv(a){return a.Wa?new C(a.Wa.clientWidth,a.Wa.clientHeight):new C(Number.NaN,Number.NaN)}
-function gx(a){var b={};if(!a.Wa)return b;a.Wa.webkitDecodedFrameCount&&(b.hmewdfc=a.Wa.webkitDecodedFrameCount,b.hmewdrop=a.Wa.webkitDroppedFrameCount,b.hmewvdbc=a.Wa.webkitVideoDecodedByteCount,b.hmewadbc=a.Wa.webkitAudioDecodedByteCount);a.Wa.mozParsedFrames&&(b.hmempf=a.Wa.mozParsedFrames,b.hmemdf=a.Wa.mozDecodedFrames,b.hmempresented=a.Wa.mozPresentedFrames,b.hmempainted=a.Wa.mozPaintedFrames,b.hmempaintdelay=a.Wa.mozPaintDelay);return b}
-function hx(a){var b=n("yt.www.watch.activity.getTimeSinceActive",window);if("detailpage"==a.Y&&b)return b();var c;a.gb&&(c=w()-a.gb);return c}function yn(a){return"leanback"==a.Y||a.nf||!a.qc&&!a.xl?!1:!0}function Bg(a){return"detailpage"!=a.Y?!1:!0}function Yw(a){a=Cj(a.fa,yj)&&Bj();var b=Cj(document.location.toString(),yj)&&!Bj();return a||b}f.F=function(){this.nk=this.Wa=null;Ww.C.F.call(this)};function ix(a){this.a=a;this.pendingRequests_=[];this.g=[];this.b=this.i=null;this.j=0}function jx(a,b){a.pendingRequests_.push(b);a.i=b.g[b.g.length-1];a.j+=b.ka.length}function kx(a){for(;a.pendingRequests_.length&&5==a.pendingRequests_[0].state;){var b=a.pendingRequests_.shift();z(b.o,a.G,a)}}
-ix.prototype.G=function(a){if(4==a.info.type){for(var b=ak(a.info.a,a.info),c=[],d=0;d<b.length;d++){var e=b[d].ka.start+b[d].Yb-a.info.ka.start;c.push(new Hj(b[d],a.data.subarray(e,e+b[d].kb)))}Za(this.g,c)}else 3==a.info.type&&this.g.push(a)};function lx(a){a.pendingRequests_.length?a.i=Fa(a.pendingRequests_[a.pendingRequests_.length-1].g):a.g.length?a.i=Fa(a.g).info:a.i=a.b}function mx(a){return Xj(a.a)?a.a.index.g?a.a.index.b[a.a.index.Q]:-1:NaN}
-function nx(a,b){Xj(a.a);a.i=bk(a.a,b,0)[0];a.b&&a.b.g&&(a.b=null);return a.i.startTime}function ox(a){px(a);if(a.a.info.a&&a.b&&!a.b.b){var b=Oa(a.g,function(a){return a.info.b});a.g=ab(a.g,0,b+1);a.k=!0}else a.g=[];if(a.g.length)for(a.j=a.g[0].data.buffer.byteLength,b=1;b<a.g.length;b++)a.g[b].data.buffer!=a.g[b-1].data.buffer&&(a.j+=a.g[b].data.buffer.byteLength);else a.j=0}
-function qx(a){var b=!1,c;for(c=0;c<a.pendingRequests_.length;c++)if(7==a.pendingRequests_[c].state){b=!0;break}if(b){for(;c<a.pendingRequests_.length;)a.o(a.pendingRequests_.pop());lx(a)}}function rx(a){var b=a.b;a.g.length&&(b=Fa(a.g).info);b=a.i||b;return b.Uh(b.ka.length-(b.kb+b.Yb))}function sx(a){return Ka(a.g,function(a){return a.info.b})}function tx(a){return Ma(a.pendingRequests_,function(a){return!(!a.b||1!=a.b.priority)&&!(4<=a.state)})}
-ix.prototype.o=function(a){Fj(a.g[0])||a.dispose();this.j-=a.ka.length};function px(a){z(a.pendingRequests_,a.o,a);a.pendingRequests_=[];a.i=null};function ux(a,b){this.state=1;this.g=b;this.k=a;this.o=null;for(var c=1;c<b.length;c++);c=b[b.length-1];this.ka=new wj(b[0].ka.start+b[0].Yb,c.ka.start+c.Yb+c.kb-1);this.G=this.g[0].a.j;this.H=NaN;this.A=this.j=0;this.i=NaN;this.b=this.B=null;this.I=""}f=ux.prototype;
-f.start=function(){var a=6==this.state;1==this.state||3==this.state||a&&vx(this);wx(this,2);if(a){if(this.j<this.k.k){this.j++;a=0.5+Math.random();H(v(this.Gn,this),1E4*a);return}a=this.G;if(!(this.H<=a.g)){a.b++;a.g=Kj-1;var b;b=He(a.a).Oe;var c=Dj(a.a);a.a=Zi(c,{cmo:"pf="+a.b,shost:b})}this.j=0}H(v(this.Gn,this),0)};
-f.Gn=function(){if(!this.ha()){this.H=Kj++;var a={range:this.ka.toString(),keepalive:"yes"};4==this.g[this.g.length-1].type&&(a.fr="yes");a=S(this.G.a,a);this.j&&(a=ke(oe(a,"playerretry"),"playerretry",this.j.toString()));this.I=a;var b={format:"RAW",method:"GET",responseType:"arraybuffer",withCredentials:!0,td:v(this.mr,this)};this.a=ej(a,b);this.A=0;this.b&&(a=this.b,a.a=w(),a.j=a.a,a.b=0,a.o=0,a.i=!1,a.k={Mm:ih(a.g),lr:a.g.b.b()||0,kr:jh(a.g)},xx(a),this.a.addEventListener("progress",v(this.nr,
-this),!1),0<this.k.a&&!Fj(this.g[0])&&(this.i=H(v(this.Pm,this),this.k.a)))}};f.nr=function(a){if(!this.ha()){var b=this.b,c=a.timeStamp,d=a.loaded;c<b.a&&(c=w());if(!(20>c-b.j)){if(32768<d){yx(b,c);var e=(c-b.j)/1E3,g=d-b.b;if(0<g)if(0.2<e||1024>g)b.o+=e;else{var h=b.g,e=Math.max(e,0.05);h.a.g(e,g/e)}}b.j=c;b.b=d}this.b.b>this.b.A&&4>this.state&&wx(this,4);4==a.target.readyState&&zx(this.b,a.timeStamp)}};
-f.mr=function(a){if(!this.ha()&&a==this.a){this.i&&(I(this.i),this.i=NaN);var b=null==a.response||400<=a.status;if(!b){a=a.response;var c;t:{if(2048>a.byteLength&&(c=String.fromCharCode.apply(String,new Uint8Array(a)),Cj(c,yj)))break t;c=""}if(c)a=this.G,c=oe(c,"keepalive"),c=oe(c,"playerretry"),c=oe(c,"range"),c=oe(c,"shost"),a.a=c,wx(this,3);else if(a.byteLength!=this.ka.length)b=!0;else{c=this.g;for(var d=new Uint8Array(a),e=[],g=0,h=0;h<c.length;h++){var k=c[h],m;m=Fj(k)?a.slice?new Uint8Array(a.slice(g,
-g+k.kb)):new Uint8Array(d.subarray(g,g+k.kb)):d.subarray(g,g+k.kb);e.push(new Hj(k,m));g+=k.kb}this.o=e;wx(this,5)}}b&&(vx(this),wx(this,6))}};function vx(a){return a.j<a.k.k?!0:!(a.H>a.G.g&&1<=a.G.b)}function wx(a,b){a.state=b;3<=a.state&&a.B&&a.B(a)}
-f.Pm=function(){this.i=NaN;if(!this.ha()&&this.b){var a=!1;if(this.b.i){var b=this.b.G;xx(this.b);this.b.G-b>=0.8*(this.k.a/1E3)?(this.A++,a=5<=this.A):this.A=0}else a=5<w()/1E3-(this.b.a/1E3+this.b.k.Mm);a?(wx(this,7),Ax(this),zx(this.b,Date.now())):this.i=H(v(this.Pm,this),this.k.a)}};f.ha=function(){return-1==this.state};f.dispose=function(){wx(this,-1);this.B=this.o=null;Ax(this);I(this.i);this.i=NaN};function Ax(a){if(a.a){var b=a.a;a.a=null;b.abort()}};function Bx(a,b,c,d){this.priority=b;this.g=a;this.A=d;this.b=this.j=this.a=NaN;this.o=0;this.B=c;this.G=NaN;this.i=!1}function zx(a,b){b<a.a&&(b=w());yx(a,b);var c=a.g,d=a.b,e=a.o,d=Math.max(d,32768);c.b.g(1,e/d);c=a.g;d=b-a.a;e=a.b;isNaN(e)||(c.g+=e);isNaN(d)||(c.i+=d/1E3)}function xx(a){var b=a.B-a.b,b=b*a.k.lr+b/a.k.kr,c=w()/1E3,b=a.i?b+c:b+Math.max(c,a.a/1E3+a.k.Mm);a.G=b}function yx(a,b){a.i||(a.g.j.g(1,(b-a.a)/1E3),a.i=!0)};function Cx(a,b,c,d){R.call(this);this.k=a;this.a=b;this.i=new ix(c);this.b=new ix(d);this.j=this.A=this.B=NaN;this.N=this.K=this.I=!1;this.o=NaN;this.O=!1}y(Cx,R);var Dx=2/24;f=Cx.prototype;f.Ks=function(a){this.g=a;a.zd.appendBuffer&&(a.zd.addEventListener("updateend",v(this.Wf,this),!1),a.Af.addEventListener("updateend",v(this.Wf,this),!1));Ex(this)};
-function Fx(a){a.g&&a.g.zd&&a.g.zd.removeEventListener&&(a.g.zd.removeEventListener("updateend",v(a.Wf,a)),a.g.Af.removeEventListener("updateend",v(a.Wf,a)));a.g=null}function Gx(a){if(0<a.a.i){var b=(a.i.a.info.b+a.b.a.info.b+12500)*a.a.i;if(0<a.a.g){if(b>a.a.g)return;b=a.a.g}b={cwndbw:(8*b/1024).toFixed(0)};Lj(a.i.a.j,b);Lj(a.b.a.j,b)}}function Hx(a,b,c){c-=2;c-=c*b*(a.k.b.b()||0);c=Math.max(a.a.I,Math.min(a.a.N,c));a=Math.max(a.a.K,Math.ceil(a.a.I*b));return Math.min(a,Math.ceil(c*b))}
-function Ix(a,b){var c=Math.min(2.5,ih(a.k));return Math.ceil(b*c+32768)}
-function Jx(a,b){if(!b.i){if(!Xj(b.a))return;nx(b,a.j)}if(!(b.j>a.a.G)){var c=b.i;4==c.type&&Xj(c.a)&&(b.i=Fa(ak(c.a,c)),c=b.i);if(!c.g&&(Xj(c.a)||(isNaN(c.a.a)?0:c.ka.end+1<c.a.a))&&(3==c.type||!c.a.info.j)){var d=a.j+a.a.A;if(!(3==c.type&&c.k>d||2<=tx(b)+1)){var d=c.k-a.j,e=c.a.info.b,g=Xj(c.a)?Hx(a,e,d):a.a.H,h=Ix(a,c.a.info.b),k=!1,e=!1;if(c&&3==c.type&&Xj(b.a)&&c.a!=b.a){var d=Hx(a,b.a.info.b,d+(c.startTime+c.duration-c.k)),m=Ix(a,b.a.info.b),e=c.a.info.b<b.a.info.b;if(!e||d>=m)k=!0,g=d,h=m}d=
-h;0<g&&(d=Math.max(a.a.H,g,Math.min(2*g,h)));if(k){c=b.i?b.i.startTime+b.i.duration+Dx:0;if(a.a.b&&e)t:{e=ih(a.k)+d*(a.k.b.b()||0)+d/jh(a.k)+a.j+2,e=Math.min(e,c),e=Nj(b.a.index,e),e+1<b.a.index.fb()&&(c=b.a.index.b[e+1]),e=c;if(b.pendingRequests_.length){if(b.pendingRequests_[0].g[0].startTime<=e)break t;px(b)}for(g=b.g.length-1;0<=g;g--)h=b.g[g],h.info.startTime>e&&(b.g.pop(),b.g.length&&b.g[g-1].data.buffer==h.data.buffer||(b.j-=h.data.buffer.byteLength));lx(b)}b.i&&!b.i.b&&(e=new ux(a.a,rx(b)),
-Kx(a,e,!0),jx(b,e));b.i&&(c=b.i?b.i.startTime+b.i.duration+Dx:0);d=new ux(a.a,bk(b.a,c,d))}else d=new ux(a.a,c.Uh(d));Kx(a,d,!1);jx(b,d)}}}}function Kx(a,b,c){c=c?2:1;a.a.O&&(c=0);var d=Math.min(2.5,ih(a.k)),e=jh(a.k);b.b=new Bx(a.k,c,b.ka.length,0.95*b.ka.length-d*e);a=v(a.Wu,a);b.B=a;b.start()}
-f.Wu=function(a){if(!this.ha()){var b=6==a.state&&vx(a);3==a.state||b?(b&&this.u("softerror",209),a.start()):5==a.state?(this.H||(this.H=a.I),Lx(this),z(a.o,function(a){if(Fj(a.info))t:{var b=a.info.a;if(1==a.info.type){if(b.b)break t;b.b=a.data}else if(2==a.info.type){if(b.g||b.index.fb())break t;if(1==b.info.i){var e=b.index,g=a.info.ka.start;a=new DataView(a.data.buffer);var h=0,k=a.getUint32(0,!1),m=a.getUint8(h+8),h=h+12,p=a.getUint32(h+4,!1),h=h+8,s;0==m?(m=a.getUint32(h,!1),s=a.getUint32(h+
-4,!1),h+=8):(m=(a.getUint32(h,!1)<<32)+a.getUint32(h+4,!1),s=(a.getUint32(h+8,!1)<<32)+a.getUint32(h+12,!1),h+=16);e.a[0]=s+(k+g);e.b[0]=m;e.g=!0;g=a.getUint16(h+2,!1);h+=4;for(k=0;k<g;k++){var r=a.getUint32(h,!1);s=a.getUint32(h+4,!1);h+=12;m=e;s=s/p;m.Q++;Oj(m);m.a[m.Q]=m.a[m.Q-1]+r;m.b[m.Q]=m.b[m.Q-1]+s}}else b.g=a.data}if(pj(b.info)&&b.b&&b.g){e=b.index;k=b.g.buffer;h=new Pj(new DataView(b.b.buffer));if(440786851==Qj(h)&&(Sj(h),408125543==Qj(h))){p=h;g=p.a;a=Rj(p,!0);p.a=g;h=Tj(h);p=h.g+h.a;for(r=
-Qj(h);357149030!=r;)Sj(h),r=Qj(h);h=Tj(h);m=1E6;s=1E9;for(g=0;!(h.a>=h.b.byteLength);)if(r=Qj(h),2807729==r)m=Uj(h);else if(2807730==r)s=Uj(h);else if(17545==r){var g=h,r=Rj(g,!0),x=0;4==r?x=g.b.getFloat32(g.a):8==r&&(x=g.b.getFloat64(g.a));g.a+=r;g=x}else Sj(h);m/=s;g*=m;h=new Pj(new DataView(k));if(475249515==Qj(h)){for(h=Tj(h);!(h.a>=h.b.byteLength);)if(r=Qj(h),187==r){k=Tj(h);r=m;s=p;if(179!=Qj(k))r=null;else if(r*=Uj(k),183!=Qj(k))r=null;else{k=Tj(k);for(x=s;!(k.a>=k.b.byteLength);)241==Qj(k)?
-x=Uj(k)+s:Sj(k);r=[x,r]}k=e;s=r[0];r=r[1];Oj(k);k.a[k.Q]=s;k.b[k.Q]=r;k.Q++}else Sj(h);h=g;a=a+p;Oj(e);e.g=!0;e.b[e.Q]=h;e.a[e.Q]=a}}b.g=null}}}),!La(a.o,function(a){return Ij(a)})||Xj(a.g[0].a)&&!isNaN(a.g[0].a.a)&&(a.g[0].a.index.g?a.g[0].a.index.a[a.g[0].a.index.Q]:-1)!=a.g[0].a.a?Mx(this,126):Ex(this)):7==a.state||4==a.state?(7==a.state&&this.u("softerror",210),Ex(this)):Mx(this,121)}};
-function Lx(a){if(!a.O&&a.H&&window.performance&&window.performance.getEntriesByName){var b=window.performance.getEntriesByName(a.H);if(b.length){var b=b[0],c=window.performance.timing.navigationStart;Er("vrst",c+b.fetchStart);Er("vdns",c+b.domainLookupEnd);Er("vreq",c+b.requestStart);Er("fvb",c+b.responseStart);a.O=!0}}}function Ex(a){isNaN(a.B)&&(a.B=H(v(a.Wf,a),0))}function Nx(a){isNaN(a.A)&&(a.A=H(v(function(){this.Wf();this.A=NaN},a),1E3))}
-f.Wf=function(){this.B=NaN;if(!this.K&&this.g){var a=Math.floor(Math.max(mx(this.i),mx(this.b)));isNaN(a)||(this.g.Va(a),this.K=!0)}if(!this.ha())if("prerender"==window.document.webkitVisibilityState)Nx(this);else{this.g&&this.g.xc()&&Fx(this);kx(this.b);kx(this.i);qx(this.b);qx(this.i);if(this.g){a=Ox(this,this.b,this.g.Af);if(!a){var b=Px(this.g.Af,this.j);if(!isNaN(b)||this.b.b&&this.b.b.g)this.b.b&&this.b.b.g&&(b=NaN),a=Ox(this,this.i,this.g.zd,b)}if(a){this.g.zd.appendBuffer||Ex(this);return}if(this.b.b&&
-this.b.b.g&&this.i.b&&this.i.b.g&&this.g.isOpen()){a=this.g;a.isOpen()&&a.g.endOfStream();return}}this.rm();Jx(this,this.b);Jx(this,this.i)}};f.rm=function(){if(!this.ha()&&!isNaN(this.a.o)){var a;a=jh(this.k);var b=ih(this.k)+1048576*(this.k.b.b()||0);a=a*Math.min(1,1048576/(a*b));!isNaN(this.o)&&Math.abs(this.o-a)/a<this.a.o||(Math.round(a/1024),Math.round(this.o/1024),this.u("bandwidthchange",a),Zg("yt-player-bandwidth",{byterate:a},2592E3),this.o=a)}};
-function Ox(a,b,c,d){if(c.updating)return!0;var e=b.g.length?b.g[0].info:null;if(!e)return!1;!b.b||b.b.b||Gj(b.b,e)||(b.b=null,a.g.isOpen()&&c.abort(),c.g=null);var g;g=e.a;Xj(g);c.g!=g.b?(c.g=g.b,c.appendBuffer?(c.appendBuffer(g.b),g=c.updating):(c.append(g.b),g=!0)):g=!1;if(g)return!0;g=!1;if(d){if(e.o>=d)return!1;g=1.5<e.j}if(!b.k&&(g?e.o+1:e.k)-a.j>a.a.B)return!1;a=e.o-a.j;if(b.a.info.a&&!(sx(b)||b.b&&!b.b.b||b.k||2>=a))return!1;g?(a=b.g[0],d=Math.min(1,a.info.j),d=Math.floor(a.data.length*(d/
-a.info.j)),e=new Ej(a.info.a,a.info.ka,a.info.type,a.info.i,a.info.startTime,a.info.duration,a.info.Yb,d,!1),g=a.data.subarray(0,d),a.info=new Ej(a.info.a,a.info.ka,a.info.type,a.info.i,a.info.startTime,a.info.duration,a.info.Yb+d,a.info.kb-d,a.info.g),a.data=a.data.subarray(d),a=new Hj(e,g),b.b=a.info):(a=b.g.shift(),b.g.length&&b.g[0].data.buffer==a.data.buffer||(b.j-=a.data.buffer.byteLength),b.b=a.info);b.k&&b.b.b&&(b.k=!1);b=a;c.appendBuffer?(c.appendBuffer(b.data),c=c.updating):(c.append(b.data),
-c=!0);return c}function Px(a,b){for(var c=0;c<a.buffered.length;c++)if(a.buffered.start(c)<=b&&a.buffered.end(c)>=b)return a.buffered.end(c);return NaN}function Qx(a,b){if(!a.ha()){var c=Rx(a,a.b,b,a.g&&a.g.Af),d=Rx(a,a.i,c,a.g&&a.g.zd);a.j=Math.max(b,c,d);a.I=!0;Ex(a)}}
-function Rx(a,b,c,d){if(Xj(b.a))if(d){if(a.N&&a.a.b)return ox(b),nx(b,c);var e=Px(d,c),g=NaN,h=b.b;h&&(g=Px(d,h.a.index.b[h.i]));if(e==g)return c;ox(b);b.a.info.a&&b.b&&!b.b.b&&!sx(b)&&(d=new ux(a.a,rx(b)),Kx(a,d,!0),jx(b,d));if(isNaN(e))return nx(b,c);nx(b,e+Dx)}else nx(b,c);else b.a.i?0!=c&&px(b):Sx(a,b,!1);return c}
-function Sx(a,b,c){var d=c?65536:0;c&&!isNaN(a.a.j)&&(d=Math.floor(Math.max(d,a.a.j*b.a.info.b)));c=Yj(b.a,d);z(c,function(a){var c=new ux(this.a,a);Kx(this,c,!0);Fj(a[a.length-1])||jx(b,c)},a);b.a.i=!0}f.F=function(){Fx(this);px(this.i);px(this.b);this.b=this.i=null;Cx.C.F.call(this)};function Mx(a,b){a.u("fatalerror",b);if(a.g&&a.g.isOpen()){var c=a.g;c.isOpen()&&c.g.endOfStream("network")}a.dispose()};function Tx(){this.B=30;this.A=40;this.G=20971520;this.I=this.j=2;this.H=131072;this.N=15;this.K=2097152;this.o=0.1;this.k=2;this.b=!0;this.g=this.i=this.a=NaN};function Ux(a,b,c){this.a=a;this.headers=b;this.message=c};function Vx(a,b,c,d,e,g,h){this.a=[];this.g=a;this.k=b.g;this.j=b;this.i=c;this.H=d;this.I=e;this.b=[];this.K=h||null;this.B=this.N=!1;this.A=null;this.o=!0;this.G={};this.listen(this.g,["keymessage","webkitkeymessage"],this.Ej);this.listen(this.g,["keyadded","webkitkeyadded"],this.hr);this.listen(this.g,["keyerror","webkitkeyerror"],this.ir);g&&this.b.push(g)}y(Vx,Wk);function Ag(a,b){if(Cj(b,yj)){for(var c in a.G)b=ke(oe(b,c),c,a.G[c]);a.k=b}else Wx(a,"u")}f=Vx.prototype;
-f.start=function(){this.ha()||(this.N=!0,this.b.length&&this.Ej(this.b.shift()))};f.dispose=function(){Vx.C.dispose.call(this);this.I=this.g=null};f.Ej=function(a){this.ha()||a.sessionId!=this.i||(this.B&&a.defaultURL&&Ag(this,a.defaultURL),this.N?(this.A=a,Xx(this,a)):this.b.push(a))};f.hr=function(a){this.ha()||a.sessionId!=this.i||(this.B=!0,this.b.length&&this.Ej(this.b.shift()))};
-function Xx(a,b){var c={format:"RAW",method:"POST",Sw:b.message.buffer,responseType:"arraybuffer",withCredentials:!0,Oa:a.Tw,onError:a.Rn,X:a};a.K&&(c.headers={Authorization:"Bearer "+a.K});var d=a.k;a.o||(d=ke(oe(d,"exclude_customdata"),"exclude_customdata","1"));ej(d,c)}
-f.Tw=function(a){if(!this.ha())if(0!=a.status&&a.response){t:{a=new Uint8Array(a.response);var b=0,c=String.fromCharCode.apply(String,a.subarray(0,16384)).split("\r\n"),d=c[0];Va(c,0);c.pop();var b=b+(d.length+2),e=d.match(/^GLS\/1.\d ([0-9]{1,3}) (\w+)$/);if(null!=e){d=e[1];isFinite(d)&&(d=String(d));for(var d=u(d)?/^\s*-?0x/i.test(d)?parseInt(d,16):parseInt(d,10):NaN,g={},h=0;h<c.length;h++){e=c[h];b+=e.length+2;if(0==e.length){a=new Ux(d,g,a.subarray(b));break t}e=e.match(/([^:]+):\s+([^]+)/);
-if(null==e)break;g[e[1]]=e[2]}}a=null}0!=a.a?(b=lw[a.a.toString()],Wx(this,"f"+a.a,b?b:"ERROR_LICENSE")):(a=a.message,this.g.addKey?this.g.addKey(this.j.a,a,this.H,this.i):this.g.webkitAddKey(this.j.a,a,this.H,this.i))}else this.Rn(a)};f.ir=function(a){this.ha()||a.sessionId!=this.i||("playready"==this.j.b&&a.errorCode==a.MEDIA_KEYERR_UNKNOWN&&2==a.systemCode&&this.o?(this.o=!1,Xx(this,this.A)):Wx(this,"s"+a.errorCode.code+"."+a.systemCode))};f.Rn=function(a){Wx(this,"r"+a.status)};
-function Wx(a,b,c){a.ha()||a.I(b,c);a.dispose()};function Yx(a,b,c,d){this.a=[];this.b=a;this.g=b;this.B=c;this.o=d;this.A=null;this.j={};this.G={};this.i=null;this.k=[];this.listen(this.b,["needkey","webkitneedkey"],this.H);this.listen(this.b,["keymessage","webkitkeymessage"],this.K);this.listen(this.b,["keyerror","webkitkeyerror"],this.I)}y(Yx,Wk);Yx.prototype.dispose=function(){Yx.C.dispose.call(this);this.b=null;Cb(this.j,function(a){a.dispose()})};
-Yx.prototype.H=function(a){a=a.initData;if(!this.i&&Ib(this.j)||"widevine"!=this.g.b){var b=String.fromCharCode.apply(String,a);if(!this.G[b]){this.G[b]=!0;b="clearkey"==this.g.b;if(112==a[4]&&115==a[5]&&115==a[6]&&104==a[7]&&b){t:{for(var c=new DataView(a.buffer),b=0;b<c.byteLength;){var d=c.getUint32(b,!1);if(1886614376!=c.getUint32(b+4,!1))break;if(1477738184==c.getUint32(b+12,!1)&&69420633==c.getUint32(b+16,!1)&&2464609580==c.getUint32(b+20,!1)&&1558758348==c.getUint32(b+24,!1)){c=c.getUint32(b+
-28,!1);if(16!=c)break;a=a.subarray(b+32,b+32+c);break t}b+=d}a=null}if(!a)return}this.i?this.k.push(a):Zx(this,a)}}};function Zx(a,b){if(!a.ha()){try{a.b.generateKeyRequest?a.b.generateKeyRequest(a.g.a,b):a.b.webkitGenerateKeyRequest(a.g.a,b)}catch(c){var d="g";c instanceof DOMException&&(d+=c.code);a.o(d,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",!0);return}a.i=b}}
-Yx.prototype.K=function(a){if(!this.ha()&&this.b&&!this.j[a.sessionId]){var b=new Vx(this.b,this.g,a.sessionId,this.i,this.o,a,this.A);this.j[a.sessionId]=b;this.i=null;this.B(b);this.k.length&&Zx(this,this.k.shift())}};Yx.prototype.I=function(a){!this.ha()&&this.b&&(this.j[a.sessionId]||this.o("s"+a.errorCode.code+"."+a.systemCode))};function $x(a){this.a=a;this.b=NaN}function ay(a,b){var c=b.kf;return c&&c&&"unknown"!=c?c:(c=a.a.Dh)&&c&&"unknown"!=c?c:"auto"}
-function by(a,b){var c,d=ay(a,b);if(d&&"auto"!=d&&(c=null,d=uj.indexOf(d),0<=d))for(;d<uj.length&&!(c=Gl(b,uj[d]));d++);if(!c){c=b.k;var e;a.a.Sc?(d=a.a.Sc.clone(),gi&&!a.a.Ah&&(d=(window.screen&&window.screen.width?new C(window.screen.width,window.screen.height):null)||d),d.scale(gi||Ub?window.devicePixelRatio||1:1),e=a.a.Fh||d):e=a.a.Fh;t:{var d=a.b,g=0,h=0;null!==e&&(g=e.width,h=e.height);e=16/9;g>Math.round(e*h)&&(g=Math.round(e*h));g*=h;e=null;for(h=0;h<c.length;h++){e=c[h];var k=e.getInfo(),
-k=k.a.width*k.a.height*("medium"==e.mc.a.i?0.26:0.85)>g,m=!0;e.a&&d&&(m=e.b.info.b+e.g.info.b<d);if(!k&&m){c=e;break t}}c=e}c||(c=b.k[0])}return c};function cy(){this.b=this.a=NaN}function dy(a,b,c){if(a.a==b)return 500<c-a.b;a.a=b;a.b=c;return!1};var ey=[102,107,108];var Zf=[0.25,0.5,1,1.5,2];function fy(a,b){this.state=a;this.a=b}function ao(a,b){return P(a.state,b)&&!P(a.a,b)?1:!P(a.state,b)&&P(a.a,b)?-1:0};function gy(a,b){R.call(this);this.oa=new cy;this.A=new Mi(v(this.getCurrentTime,this),v(this.Dq,this),v(this.hg,this));L(this,this.A);this.O=NaN;this.R=this.I=null;this.o=a;this.ba=new $x(a);this.da=NaN;this.ca=!1;this.g=this.k=null;this.S=[];this.U=!1;this.fa=NaN;this.i=new Hi;this.B=b;this.K=this.ea=null;this.H=NaN;this.N=new eo(this);this.b=this.a=null;this.$=NaN;this.j=null}y(gy,R);f=gy.prototype;
-f.F=function(){I(this.$);I(this.va);kf(this.fa);hy(this);Mm(this);Of(this.k,this.K,this.N,this.a);this.a=this.N=this.i=this.k=this.R=this.oa=null};function iy(a,b){a.U=!1;a.O=NaN;a.b&&Ci(a.b);jy(a);hy(a);Of(a.k,a.a);a.k=null;a.A.reset();2==a.B&&(b.$=!1,b.Sn=!0);a.a=b;a.a.D("dataupdated",a.wu,a);a.a.D("dataloaded",a.vu,a);a.a.D("onStatusFail",a.uu,a);if(b.rf&&b.rf>b.ya){var c=b.rf;a.R&&(a.bi(a.ua),a.ua=null);a.R=new nh(1E3*c,2147483646);a.R.yb.D("onEnter",a.pg,a);a.Mk(a.R)}ky(a,"newdata")}
-function hy(a){kf(a.da);a.j&&(Nf(a.j),a.j=null)}f.getVideoData=function(){return this.a};f.J=function(){return this.o};function ly(a){return!(!a.a||!a.a.k.length)}function my(a){if(a.a&&(a.a.L||a.a.mf))return!0;sw(a,2);return!1}function ny(a){a.U||(oy(a,Ji(new Hi,8)),a.j&&py(a.j),a.U=!0,!my(a)||a.a&&a.a.Ue||qy(a,v(function(){if(ly(this))ry(this);else if(!this.a.Ue)if(sy(this))ry(this);else{var a=cx(this.o,this.a);Ll(this.a,a)}},a)))}
-function ty(a){if(!a.S.length){if(!a.A.sg){var b=a.A;b.g=Ri(b);b.sg=!0;b.Xb()}a.S.length||0<Yh(a.A.b,-2147483648).length||a.u("playbackready",a)}}f.Cq=function(){var a=this.j,b=this.a.Nj;a.bp!=b&&(uy(a,{metric:"heartbeat",tpmt:this.a.ye}),a.bp=b)};function ry(a){a.S=Ya(a.a.I);a.a.bb&&(vy(a,a.a.wa),wy(a,!0));ag(a,"i");a.u("playbackdataloaded")}f.pg=function(a){xy(this);oy(this,!1==a?new Hi:new Hi(Li()))};
-function wg(a,b,c){b={event:"streamingerror",ec:b,v:a.a.L};c&&(b.em=c);pa(b,bx(a.o));a.j&&yy(a.j,b,void 0)}function sw(a,b,c,d){if(Gb(kw,c))var e=c;else var g=c;oy(a,Ii(a.i,128,{errorCode:b,errorDetail:d,message:g,messageKey:e}))}function zy(a,b){a.S=a.S.filter(function(a){return b!=a});ty(a)}f.hg=function(){return P(this.i,8)&&!P(this.i,64)&&!P(this.i,2)};function sy(a){return!(!a.a||!a.a.L&&!a.a.mf||a.a.L)}f.Dq=function(){return this.i};function Ay(a,b){a.b&&Mm(a);a.b=b;By(a)}
-function Mm(a){a.g=null;a.b&&(jy(a),a.N.removeAll(),Ci(a.b),a.b=null)}function Cy(a){if(a.b){var b=Hl(a.a);if(a.a.o&&a.a.o.a){var c=a.a.o,b=c.g,c=c.b;a.g||(a.g=new Xk(a.b,a.a.wa,b.info.mb,c.info.mb),b=a.g,b.b||(b.b=b.g.on?b.g.a.webkitMediaSourceURL:window.URL.createObjectURL(b.g)),a.za=new bl(b.b,!1,!0),b=v(a.k.Ks,a.k),a.g.j=b);b=a.za}a.b.yd!=b?Dy(a,b):(P(a.i,64)&&oy(a,Ji(a.i,8)),Ai(a.b),a.a.Fb&&!a.a.bb&&Ey(a,Infinity))}}
-function ag(a,b,c){if(!a.ha()&&ly(a)&&!P(a.i,128)){var d=NaN;!a.ea||a.o.za||a.o.wh||(d=jh(a.ea),"i"==b&&(d=a.o.Ec?0.4*d:0.6*d));a.ba.b=d;var e=by(a.ba,a.a),d=e.getInfo(),g=e.a?e.b.info:d;if(a.a.a!=d||a.a.ra!=g||a.a.hb!=b||c&&a.a.kf!=c){a.a.o=e;a.a.a=d;a.a.ra=g;a.a.hb=b;c&&(a.a.kf=c);c="m"==a.a.hb;if(e.a)if(a.k){var h=a.k,e=e.g;h.ha()||(h.N=c,h.b.a!=e&&(h.b.a=e,Gx(h),c&&ox(h.b),e.i||Sx(h,h.b,!1)))}else{var g=a.o,k=new Tx;if(g.za||g.wh)k.o=NaN;g.Fc&&(k.k=0);g.Jc&&(k.j=3);g.Ul&&(k.I=1,k.H=49152);g.Ic&&
-(k.N=30);g.te&&(k.a=700);g.Hc&&(k.i=3);g.Dc&&(k.i=1.5,k.g=1048576);"play"==g.Ja&&(k=Jb(k),k.B=10,k.A=20,k.G=10485760,k.K=1048576,k.b=!1,g.bg&&(k.b=!0));ji&&si("crkey")&&(g=Jb(k),g.j=3.5,g.B=20,g.A=40,g.G=20971520,g.b=!0,g.a=700,g.k=2,k=g);g=k;a.a.gb&&(g.a=NaN);a.k=new Cx(a.ea,g,e.b,e.g);a.k.D("bandwidthchange",a.wq,a);a.k.D("fatalerror",a.xq,a);a.k.D("softerror",a.yq,a);e=a.k;g=a.a.ya;Gx(e);0==g&&(e.b.a.i||Sx(e,e.b,!0),e.i.a.i||Sx(e,e.i,!0));Qx(e,g);Er("gv");H(v(e.rm,e),0);t:{e=xk();for(h in Yk)if(!!e.canPlayType(h)!=
-Yk[h]){h=!1;break t}h=!0}h||wg(a,211)}else a.hg()&&Cy(a);a.j&&(h=a.j.j,g=a.a,e=Fy(h),isNaN(e)||(e=e.toFixed(3),g=by(h.K,g).mc.Sa,h.A&&(b="i",h.A=!1),b=[e,d.Sa,g,h.I,b].join(":"),h.a.vfs.push(b),b=Mv(h.g),0<b.width&&0<b.height&&h.a.view.push(e+":"+Math.round(b.width)+":"+Math.round(b.height)),h.I=d.Sa),d=Fy(h),isNaN(d)||Gy(h,d,h.G),h.k());a.u("internalvideoformatchange",a.a,c)}}}f.wq=function(a){this.ba.b=a;ag(this,"a");if(this.j){var b=this.j.j,c=Fy(b);isNaN(c)||b.a.bwe.push(c.toFixed(3)+":"+a.toFixed(3))}};
-f.xq=function(a){sw(this,a)};f.yq=function(a){wg(this,a);if(this.j)this.j.onError(a)};function xy(a){P(a.i,64)&&oy(a,Ii(a.i,a.i.b&-9));a.b&&a.b.pause()}
-function Ey(a,b,c,d){if(a.b){if(a.b){b=b||0;var e=1>a.b.seekable.length?NaN:a.b.seekable.end(a.b.seekable.length-1);a.k&&!isNaN(Math.floor(Math.min(mx(a.k.i),mx(a.k.b))))&&(e=Math.floor(Math.min(mx(a.k.i),mx(a.k.b))));b>e&&(b=e,wy(a,!0));0>b&&(b=0)}else b=0;a.a.ya=b;a.H=b;c?a.ri():(Hy(a),d&&(a.K||(a.K=new ho(a.ri,d,a)),a.K.start()),Iy(a,!0));a.R&&b>a.a.rf&&(a.bi(a.ua),a.ua=null);a.u("seekto",a,b)}else a.a.ya=b||0}function Hy(a){P(a.i,32)||(oy(a,Ji(a.i,32)),P(a.i,8)&&xy(a),a.u("beginseeking",a))}
-f.ri=function(){if(!isNaN(this.H)&&this.b){var a=this.rd();!this.a.Fb&&this.H>=Math.floor(a)?(this.H=a,this.u("endseeking",this),xy(this),this.pg()):(this.k&&Qx(this.k,this.H),yi(this.b,this.H))}this.K&&(this.K.dispose(),this.K=null);P(this.i,32)&&(oy(this,Ii(this.i,this.i.b&-33)),this.u("endseeking",this))};f.getCurrentTime=function(){if(!isNaN(this.H))return this.H;var a=0;this.b?a=this.b.getCurrentTime():this.a&&(a=this.a.ue);return a};
-f.rd=function(){var a=0;this.b&&(a=this.b.Qd);0==a&&this.a&&(a=this.a.wa);return a};function Jy(a,b){var c=isNaN(b)?a.getCurrentTime():b,d=a.rd();return Infinity==d?1:d?c/d:0}
-f.pr=function(){var a;if(this.a){a=this.a;var b={};a.a&&(b.fmt=a.a.Sa,a.ra&&(b.afmt=a.ra.Sa));a.S&&(b.threed=a.Jc);b.plid=a.ab;b.ei=a.j;b.list=a.Na;b.cpn=a.Ca;a.L&&(b.v=a.L);a.Lj&&(b.infringe=1);a.Nd&&(b.splay=1);a.Fb&&(b.live=a.bb?"dvr":"live");a.hf&&(b.autoplay=1);a.fa&&(b.sdetail=a.fa);a.qd&&(b.partnerid=a.qd);a=b}else a={};return a};f.Mk=function(a){this.A.ux(a)};f.bi=function(a){this.A.vx(a)};
-f.vu=function(a){this.u("commoninfoloaded",a);ky(this,"dataloaded");qy(this,v(function(){this.U&&ry(this)},this))};f.wu=function(){ky(this)};f.uu=function(a){sw(this,parseInt(a.errorcode,10),unescape(a.reason),a.errordetail)};function ky(a,b){a.u("internalvideodatachange",b||"dataupdated",a,a.a)}function qy(a,b){if(ly(a))H(b,0);else{var c=a.a,d=a.o.Kh;c.B?Cl(c,b,!!d,!!a.o.pd):El(c,b,!!d)}}
-function By(a){z("loadstart loadeddata loadedmetadata play playing pause ended suspend progress seeking seeked timeupdate durationchange error waiting abort".split(" "),function(a){this.N.listen(this.b,a,this.bw)},a)}
-f.bw=function(a){var b=a.target;if(b.currentSrc){switch(a.type){case "durationchange":this.a.bb||(b.Va(b.duration||0),b=b.Qd,(!this.g||isFinite(b)&&0<b)&&vy(this,b));break;case "ended":oy(this,Ii(this.i,4));break;case "loadedmetadata":this.a.ya&&(this.b.currentTime=this.a.ya),this.o.tm&&this.a.ya&&(this.O=this.a.ya,this.b.pause());case "loadeddata":this.$&&I(this.$);break;case "loadstart":kf(this.fa);this.fa=jf(v(this.un,this),100);var b=this.N,c=this.b,d=v(this.un,b.Kg),c=uf(c,d);b.ee.push(c);break;
-case "progress":this.O&&this.b.seekable.length&&this.b.seekable.end(0)>this.O&&(this.b.currentTime=this.O,this.O=NaN,this.ra=this.N.listen(this.b,"canplay",this.Gt));case "suspend":Iy(this);this.u("onLoadProgress",this,this.b?cg(this.b):0);break;case "seeking":Ky(this);break;case "timeupdate":Ky(this),Iy(this),this.u("onVideoProgress",this,b.getCurrentTime())}this.u("videoelementevent",a);t:if(b=this.i,d=this.oa,P(b,128))a=b;else{var c=b.b,e=b.a,g=a.target;switch(a.type){case "ended":if(0>=g.networkState)break;
-c=Li();e=null;break;case "pause":P(b,32)||P(b,2)||(c=4,e=null);break;case "playing":c=8;e=null;break;case "abort":case "error":c|=256;a=g.error;d=107;if(a&&a.code)switch(a.code){case a.MEDIA_ERR_ABORTED:d=200;break;case a.MEDIA_ERR_NETWORK:d=201;break;case a.MEDIA_ERR_DECODE:d=202;break;case a.MEDIA_ERR_SRC_NOT_SUPPORTED:d=203}e={errorCode:d};A(Gi,e.errorCode)&&(c|=128);break;case "canplay":c&=-2;break;case "progress":P(b,8)&&(g=a.target.getCurrentTime(),d&&dy(d,g,a.timeStamp)&&(c|=1));break;case "seeked":c&=
--18;break;case "seeking":c|=16;g.inUnbufferedArea()&&(c|=1);c&=-3;break;case "waiting":P(b,2)||(c|=1);break;case "timeupdate":P(b,16)||(c&=-2);c&=-65;break;default:a=b;break t}a=Ii(b,c,e)}oy(this,a)}};
-f.un=function(){if(this.b&&0<this.b.getCurrentTime()&&0<this.b.Qd&&!this.a.sm){kf(this.fa);this.a.sm=!0;if(this.j){var a=this.j;if(a.i)a.log_("Attempted to start sending initial pings twice.");else{a.a.ig&&(a.G=[10+a.a.cg,10,10,40+a.a.uh-a.a.cg,40],a.g=a.G[0]);var b=Ly(a,"playback");b.k=a.g;b.fg=!0;a.Rc=a.lf();a.mg=a.Rc;a.b.ba?(a.o=[a.Rc],a.k=[a.Rc]):(b.i=[a.Rc],b.j=b.i);a.tj=(w()-a.pf)/1E3;b.send();a.a.ig&&(void 0!=a.A&&kf(a.A),a.A=jf(v(a.Bq,a),100),a.we?a.log_("Do not call startSendingDetailedPings_ twice"):
-(b=a.g,My(a),a.we=jf(v(a.rj,a),1E3*b)));if(a.b.lc)if(a.i)a.log_("Tried to logUserWatch inappropriately.",Ne.debug.zq.Aq);else{var b=a.b,c=a.a,b={noflv:"1",html5:"1",video_id:c.L,cpn:c.Ca,plid:c.ab,ei:c.j,referrer:ex(b),eurl:b.b,framer:b.R,feature:b.k,fmt:c.a?c.a.Sa:0,ptk:c.A,skl:c.Xl,access_token:c.H,ucid:c.Ec};pa(b,Ny(a));b=S(a.b.ib+"user_watch",b);Kf(b)}a.a.A&&Kf(S(a.b.ib+"ptracking",{html5:"1",video_id:a.a.L,cpn:a.a.Ca,plid:a.a.ab,ei:a.a.j,ptk:a.a.A,oid:a.a.Dc,ptchn:a.a.Hc,pltype:a.a.Gc,content_v:a.b.o}));
-if(a.a.Wl&&a.b.Rd)if(a.i)a.log_("Tried to logGetVideo inappropriately.",Ne.debug.zq.Aq);else{var b=a.b,c=a.a,d={noflv:1,video_id:c.L,cpn:c.Ca,el:b.Y,ps:b.Ja,referrer:ex(b),eurl:b.b,framer:b.R,fmt:c.a?c.a.Sa:0,ptk:c.A,subscribed:c.g,t:c.qb};b.Sb&&(d.autoplay="1");c.Nd&&(d.splay="1");0<c.ya&&(d.start=1E3*c.ya);c.kj&&(d.tmi="1");b=S(a.lm,d);Kf(b)}a.a.gg&&uy(a,{metric:"playback"});a.i=!0}}kf(this.da);this.a.gg&&(this.j.i||this.a.Vl)&&(this.da=jf(v(this.Cq,this),3E4));this.u("playbackstarted")}};
-f.Gt=function(){this.ra&&(this.N.Vc(this.ra),this.ra=void 0,Ai(this.b))};
-function Iy(a,b){if(a.b){var c=a.getCurrentTime();if(a.k){var d=a.k;if(!d.I||d.j<=c&&c<d.j+10)d.j=c,d.I=!1;Nx(d)}a.a.bb&&c>a.rd()&&(d=a.rd(),0==d&&(d=c),vy(a,1.2*d));var d=Jy(a),e=0;a.b.buffered&&0<a.b.buffered.length&&(a.a.bb?a.ca||(e=(1>a.b.seekable.length?NaN:a.b.seekable.end(a.b.seekable.length-1))/a.rd()):e=a.b?cg(a.b):0);5<c&&(a.a.ya=c);a.va&&I(a.va);a.b.paused||a.b.ended||(a.va=a.b.played&&0==a.b.played.length?H(v(a.Rm,a),100):H(v(a.Rm,a),1E3));a.a.ue=c;if(!b&&a.hg()){var g=a.a.Nj,h=a.a.ue;
-0<g&&h>g&&(a.a.ye+=h-g);a.a.wa&&a.a.K&&a.a.ye>=a.a.K&&(g=a.j,g.i&&g.a.K&&(h=Ly(g,"delayplay"),h.nj=!0,Oy(g,h)),a.a.K=NaN)}if(a.a.nm&&(g=a.a.Oj,h=a.a.ue,1==g&&0<h||2==g&&20<=h||3==g&&30<=h)){g=a.j;if(g.i){var h=g.b,k=g.a,g={ns:"yt",html5:"1",docid:k.L,plid:k.ab,ei:k.j,cpn:k.Ca,fmt:k.a?k.a.Sa:0,el:h.Y,ps:h.Ja,subscribed:k.g,yttk:"1",st:g.lf(),et:g.lf(),ctp:k.Oj,vid:h.$},g=S("//s2.youtube.com/s",g);Kf(g)}a.a.Oj++}a.u("progresssync",a,c,d,e,b);a.a.Nj=c}}
-f.Rm=function(){this.b&&(this.b.pp(),P(this.i,8)&&dy(this.oa,this.getCurrentTime(),Date.now())&&oy(this,Ji(this.i,1)),Iy(this))};
-function oy(a,b){if(b.b!=a.i.b||b.a!=a.i.a){var c=new fy(b,a.i);a.i=b;a.o.lg&&P(b,8)&&0<ao(c,256)&&201==b.a.errorCode&&setTimeout(v(function(){this.b&&(this.a.o&&!this.a.o.a&&this.b.load(),Cy(this))},a),500);0>ao(c,8)&&wy(a,!1);0<ao(c,32)&&wy(a,!1);a.a&&a.a.Fb&&a.a.bb&&P(c.state,2)&&(vy(a,a.getCurrentTime()),Iy(a,!0));P(b,256)&&Py(a,b);a.j&&Qy(a.j,c);Pi(a.A,c);a.u("statechange",c)}}
-function Py(a,b){var c=b.a;kf(a.da);if(a.a.gg&&A(ey,c.errorCode)){var d=a.j,c=c.errorCode;d.H||(d.H=new ln("error-__ec__"));c={metric:pn(d.H,{ec:c})};uy(d,c)}}function Ky(a){P(a.i,2)||P(a.i,32)||(a.H=NaN)}function wy(a,b){a.a&&a.a.bb&&a.ca!=b&&(a.ca=b,a.u("liveviewshift",b))}function Dy(a,b){a.o.Ia&&Ei(a.b,b.a||Cj(b.b,yj));wi(a.b,b);a.g&&!b.a&&(a.g=null);a.a.a&&a.a.a.g&&Ry(a);I(a.$);a.$=H(v(a.tu,a),15E3);a.o.Im?H(v(function(){Ai(this.b)},a),0):Ai(a.b)}
-function Ry(a){var b=a.a.a&&a.a.a.g||null;b&&!a.I&&a.b&&((b=Rk(a.b,a.a.a.mb,b))?(a.I=new Yx(a.b,b,v(a.ru,a),v(a.qu,a)),a.I.A=a.a.H,L(a,a.I)):sw(a,203,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK"))}function jy(a){a.I&&(a.I.dispose(),a.I=null)}f.ru=function(a){var b=bx(this.o);b.cpn=this.a.Ca;this.a.U&&(b.vvt=this.a.U);Mb(a.G,b);Ag(a,a.k);this.u("newlicensesession",a)};f.qu=function(a,b,c){sw(this,c?5:206,q(b)?b:"ERROR_LICENSE",a)};f.tu=function(){wg(this,102);if(this.j)this.j.onError(102);this.u("loadsofttimeout")};
-function vy(a,b){a.b&&a.b.Va(b);a.a.wa!=b&&(a.a.wa=b,ky(a))};function Sy(){}ca(Sy);f=Sy.prototype;f.ic=null;f.Ri=null;f.load=function(a){if(this.ic)return Jn(this.ic);this.ic=new Cn;this.Ri=a?a:"3";In(Ln("3.1"==this.Ri?"//s0.2mdn.net/instream/html5/ima3.js":"//s0.2mdn.net/instream/html5/ima.js"),this.Rx,this.Zp,this);return this.ic};f.getVersion=function(){return this.Ri};f.Rx=function(){"3.1"==this.Ri&&this.ic?this.ic.b():(google.ima.SdkLoader.setCallbacks(v(this.ic.b,this.ic),v(this.cw,this)),google.ima.SdkLoader.load("3",void 0))};
-f.cw=function(a){this.Zp(Error("Google Ads SDK Failed to load: "+a))};f.Zp=function(a){this.ic.a(a)};function Ty(a){return a?-1!=a.toString().search(/(?:true|1)/i):!1}function Uy(a,b){if(a){var c="getErrorCode"in a?a.getErrorCode():null;c?b.error_code=c:(c=a.message,50<c.length&&(c=c.substring(0,47)+"..."),b.error_message=c)}}function Vy(a,b){if(a&&"3.1"==Sy.getInstance().getVersion()){var c=a.getAdId();if(c){var d=a.getWrapperAdIds()||[];b.ad_id=Xa(d,c).join(",");if(c=a.getAdSystem())d=a.getWrapperAdSystems()||[],b.ad_sys=Xa(d,c).join(",");a.isSkippable()&&(b.skip=1)}}}
-function Wy(a,b){if(a[b])return Ty(a[b]);var c=b.toLowerCase(),d;for(d in a)if(d&&d.toLowerCase()==c)return Ty(a[d]);return!1};function Xy(a){var b=n("yt.www.watch.ads.handleMoveGutCompanion");b&&b(1==a?!0:!1)}function Yy(a){var b=n("yt.www.watch.ads.handleShowAfvCompanionAdDiv");b&&b(0<(a&3))};function Zy(a,b){this.a=a;this.g=b}Zy.prototype.j=null;Zy.prototype.b=NaN;function $y(a,b,c){a.a.u("AD_LOGGING_EVENT",b,c)}function az(a){bz(a);var b=cz(a);if(a.i){var c=dz(a.g),d=a.i.y-c.top,d=Math.round(a.i.x-c.left)+"x"+Math.round(d);b.ck_xy=d;b.ck_wh=c.width+"x"+c.height}$y(a,15,b)}function ez(a){bz(a);var b=cz(a);if(isNaN(a.b))bz(a);else{var c=w()-a.b;b.ad_stl=c}$y(a,4,b)}function fz(a){bz(a);var b=cz(a),c=a.a.np();c?b.ad_fmt=c:bz(a);$y(a,5,b)}
-function cz(a){var b={},c=a.a.ia,d=a.a.Cf(),e=a.a.Zo();Vy(a.a.Zg(),b);d&&0<d&&(b.ad_len=d);c&&c.L?b.ad_v=c.L:e&&(c=Xi(e),b.ad_dom=c,(c=a.g.ta.g)||(c=a.g.J(),(c=A(c.g,"921806"))||(c=a.g.J(),c=A(c.g,"921805"))),c&&(b.ad_v_url=e));b.at=a.a.getType();return b}function bz(a){a.j||(a.j="InstreamAdDisplay ("+a.a.getType()+")")};function gz(a,b,c,d){R.call(this);this.a=b;this.a.D("onVolumeChange",this.Ps,this);this.a.D("control_toggle_play_pause",this.nn,this);this.a.D("control_play",this.Oh,this);this.a.D("control_pause",this.Xj,this);this.b=c;this.j=d;this.i=new Zy(this,this.a);this.o=a+"_2";this.g=new eo(this)}y(gz,R);f=gz.prototype;f.Ya=null;f.ia=null;f.Rf=!1;f.Ug=null;f.Tg=null;f.Xg=null;
-f.show=function(){this.i.b=w();var a="";if("3.1"==hz())a=this.j;else{var b=null;try{b=this.b.getSelectedCreative(),a=b.getMediaUrl("video/x-flv")||b.getMediaUrl("video/mp4")||b.getMediaUrl("video/webm")}catch(c){iz(this,c);return}}if(a){b=Vi(a);b=b.v||b.video_id;if(!b){var d=ee(a).match(/^\/watch\/([^\/]*)$/i);d&&(b=d[1])}b||(a=a.match(/yt_vid\/([a-zA-Z0-9_-]{11})/),null!=a&&1<a.length&&(b=a[1]));a=b?new hg({video_id:b,dash:"0"}):null}else a=null;this.ia=a;var e;this.ia?(this.ia.Nd=!0,e={video_id:this.ia.L},
-this.ia.D("onStatusFail",this.Mn,this),this.ia.D("dataloaded",this.Ln,this),a=this.a.J(),a=new Ww(a.a),a.Y="adunit",a.Sb=!0,a=cx(a,this.ia),Ll(this.ia,a)):jz(this);kz(this.a,-1,e);this.qn()};function lz(a){a.ia&&(a.ia.W("onStatusFail",a.Mn,a),a.ia.W("dataloaded",a.Ln,a))}f.Ln=function(){lz(this);var a=this.a.J(),b=this.ia,c=v(this.Gv,this),a=a.Kh;b.B?Cl(b,c,!!a,!1):El(b,c,!!a)};
-f.Gv=function(){var a=by(new $x(this.a.J()),this.ia);a?(a=a.i)?(a=new pe(xi(a)),a.a.set("autoplay","1"),a=a.toString(),"3.1"==hz()?this.b.setMediaUrl(a):this.b.getSelectedCreative().setMediaUrl(a),jz(this)):iz(this,Error("Failed to determine ad media resource.")):iz(this,Error("Failed to determine ad media format."))};
-function jz(a){Xy(1);Yy(1);a.a.J();var b=a.a.b,c=Lm(b);b.V.J().tb||Xc(c)||Hm(b).appendChild(c);a.Ya=c;a.Xg=Q(a.a.a);a.a.ta.N?F(E("video-ad-status-bar")):(b=Q(a.a.a),a.Ug=E("video-ad-time-left",b),b=E("html5-ad-progress-list",b),c=Sc("div"),$l(c,["html5-ad-progress","html5-progress-section"]),b.appendChild(c),a.Tg=c,a.g.listen(a.Ya,"timeupdate",a.lu));$l(a.Xg,["ad-showing","ad-interrupting"]);a.g.listen(Km(a.a.b),"mouseup",a.pu);a.g.listen(a.Ya,"waiting",a.qn);a.a.D("onResize",a.Gk,a);try{a.g.listen(a.b,
-google.ima.AdErrorEvent.Type.AD_ERROR,a.nu);a.g.listen(a.b,google.ima.AdEvent.Type.CLICK,a.mu);a.g.listen(a.b,google.ima.AdEvent.Type.COMPLETE,a.ou);a.g.listen(a.b,google.ima.AdEvent.Type.PAUSED,a.Xn);a.g.listen(a.b,google.ima.AdEvent.Type.STARTED,a.Yn);a.Gk();var d=a.a,e=d.b,g=mz(d);e.V.J().tb&&(yd(e.a,g),md(e.a,0,0));a.b.start()}catch(h){iz(a,h)}}
-f.Yn=function(){this.Rf=!0;this.k||(this.k=!0,ez(this.i),nz(this.a,1));if(0==this.Cf()){var a=this.Ya;a.Va(a.duration||0)}this.a.jb(!0);kz(this.a,1);this.u("adPlay",this)};f.Xn=function(){this.Rf=!1;this.a.jb(!1);kz(this.a,2)};f.ou=function(){fz(this.i);this.Rf=!1;kz(this.a,0);nz(this.a,2);this.u("adEnd",this)};f.nu=function(a){iz(this,a.getError())};function iz(a,b){a.Rf=!1;kz(a.a,0);a.u("adError",b)}f.Mn=function(){lz(this);iz(this,Error("Request to get video data failed."))};
-f.mu=function(){az(this.i);"3.1"==hz()||this.a.ta.B||H(v(this.Oh,this),0);this.u("select")};f.pu=function(a){this.i.i=new B(a.pageX,a.pageY)};f.lu=function(){var a=Xm(this.b.getRemainingTime());this.Ug.innerHTML=a;0==this.Cf()&&(a=this.Ya,a.Va(a.duration||0));a=this.Cf()?this.Ya.getCurrentTime()/this.Cf():0;a=Math.round(1E3*a)/10;this.Tg.style.width=a+"%"};f.qn=function(){!this.Rf&&this.k||kz(this.a,3)};
-f.F=function(){this.a.W("control_toggle_play_pause",this.nn,this);this.a.W("control_play",this.Oh,this);this.a.W("control_pause",this.Xj,this);this.a.W("onResize",this.Gk,this);this.g.removeAll();lz(this);this.b.destroy();this.Ya&&(Im(this.a.b),this.Ya=null);this.Ug&&(this.Ug.innerHTML="",this.Ug=null);this.Tg&&(F(this.Tg),this.Tg=null);this.Xg&&(am(this.Xg,["ad-showing","ad-interrupting"]),this.Xg=null);gz.C.F.call(this)};f.getType=function(){return this.o};f.Zg=function(){return this.b.getCurrentAd()};
-f.Cf=function(){return this.Ya?this.Ya.Qd:null};f.np=function(){return this.Ya?this.Ya.getType():null};f.Zo=function(){return this.Ya&&this.Ya.currentSrc?this.Ya.currentSrc:null};f.Ps=function(a){a=a.muted?0:a.volume;isNaN(a)||(a=tb(a/100,0,1),this.b.setVolume(a))};f.nn=function(){this.Rf?this.Xj():this.Oh()};f.Oh=function(){this.Ya&&(this.b.resume(),this.Yn())};f.Xj=function(){this.Ya&&(this.b.pause(),this.Xn())};f.Gk=function(){var a=mz(this.a);this.b.resize(a.width,a.height,google.ima.ViewMode.NORMAL)};function oz(a,b,c){R.call(this);this.a=b;this.a.D("control_toggle_play_pause",this.cn,this);this.a.D("control_play",this.Nh,this);this.a.D("control_pause",this.Vj,this);this.b=c;this.j=new Zy(this,this.a);this.o=a+"_2";this.i=new eo(this);this.g=pz(b);this.g.D("statechange",this.an,this);this.g.D("internalvideodatachange",this.bn,this);this.ia=null}y(oz,R);f=oz.prototype;f.ql=!1;f.Bg=null;f.Ag=null;f.Cg=null;
-f.show=function(){var a=this.a;qz(a.app,pz(a));this.j.b=w();Xy(1);Yy(1);this.Cg=Q(this.a.a);if(this.a.ta.N)F(E("video-ad-status-bar"));else{a=Q(this.a.a);this.Bg=E("video-ad-time-left",a);var a=E("html5-ad-progress-list",a),b=Sc("div");$l(b,["html5-ad-progress","html5-progress-section"]);a.appendChild(b);this.Ag=b;this.g.D("progresssync",this.rn,this)}$l(this.Cg,["ad-showing","ad-interrupting"]);this.i.listen(Km(this.a.b),"mouseup",this.Kt);this.a.D("onResize",this.ck,this);try{this.i.listen(this.b,
-google.ima.AdErrorEvent.Type.AD_ERROR,this.It),this.i.listen(this.b,google.ima.AdEvent.Type.CLICK,this.Ht),this.i.listen(this.b,google.ima.AdEvent.Type.COMPLETE,this.Jt),this.i.listen(this.b,google.ima.AdEvent.Type.PAUSED,this.wn),this.i.listen(this.b,google.ima.AdEvent.Type.STARTED,this.xn),this.ck(),this.b.start()}catch(c){rz(this,c)}};f.bn=function(a,b,c){"newdata"==a&&this.ia!=c&&kz(this.a,-1,{video_id:c.L});this.ia=c};f.an=function(a){a=a.state;P(a,128)&&rz(this,Error(a.a.message||"Video player error."))};
-f.xn=function(){this.ql=!0;this.k||(this.k=!0,ez(this.j),nz(this.a,1));kz(this.a,1);this.u("adPlay",this)};f.wn=function(){this.ql=!1;kz(this.a,2)};f.Jt=function(){fz(this.j);kz(this.a,0);nz(this.a,2);this.u("adEnd",this)};f.It=function(a){rz(this,a.getError())};function rz(a,b){a.g.pg();kz(a.a,0);a.u("adError",b)}f.Ht=function(){az(this.j);"3.1"==hz()||this.a.ta.B||H(v(this.Nh,this),0);this.u("select")};f.Kt=function(a){this.j.i=new B(a.pageX,a.pageY)};
-f.rn=function(a,b,c){this.Bg.innerHTML=Xm(a.rd()-b);a=Math.round(1E3*c)/10;this.Ag.style.width=a+"%"};
-f.F=function(){this.a.W("control_toggle_play_pause",this.cn,this);this.a.W("control_play",this.Nh,this);this.a.W("control_pause",this.Vj,this);this.a.W("onResize",this.ck,this);this.i.removeAll();this.g.D("statechange",this.an,this);this.g.W("internalvideodatachange",this.bn,this);this.g.W("progresssync",this.rn,this);var a=this.a;a.g&&sz(a.app,a.g);this.b.destroy();this.Bg&&(this.Bg.innerHTML="",this.Bg=null);this.Ag&&(F(this.Ag),this.Ag=null);this.Cg&&(am(this.Cg,["ad-showing","ad-interrupting"]),
-this.Cg=null);oz.C.F.call(this)};f.getType=function(){return this.o};f.Zg=function(){return this.b.getCurrentAd()};f.Cf=function(){return this.g.rd()};f.np=function(){return this.ia&&this.ia.a?this.ia.a.mb:null};f.Zo=function(){if(!this.ia)return null;var a=Hl(this.ia);return a?xi(a):null};f.cn=function(){this.ql?this.Vj():this.Nh()};f.Nh=function(){this.b.resume();this.xn()};f.Vj=function(){this.b.pause();this.wn()};f.ck=function(){var a=mz(this.a);this.b.resize(a.width,a.height,google.ima.ViewMode.NORMAL)};function tz(a,b){this.b=a;this.a=b;this.b.getType()}function uz(a,b,c){a.b.u("AD_LOGGING_EVENT",b,c)}function vz(a){var b={};Vy(a.b.Zg(),b);a.j&&a.g&&(b.ot=a.g-a.j);var c;c=a.a.a.app.J().Ab||a.a.ta.g?2:a.a.J().Od?1:0;b.ad_ps=c;b.at=a.b.getType();return b};function wz(a,b,c){R.call(this);this.b=b;this.a=c;this.i=new tz(this,b);this.k=a+"_1";this.g=new eo(this)}y(wz,R);f=wz.prototype;f.Zd=null;f.tn=!1;
-f.show=function(){V(Q(this.b.a),"ad-showing");this.Zd=Hm(this.b.b);V(this.Zd,"ad-overlay");this.g.listen(this.Zd,"mouseup",this.Et);try{Ed(this.Zd);this.g.listen(this.a,google.ima.AdEvent.Type.USER_CLOSE,this.Bt);this.g.listen(this.a,google.ima.AdEvent.Type.CLICK,this.Dt);this.g.listen(this.a,google.ima.AdErrorEvent.Type.AD_ERROR,this.Ct);xz(this,google.ima.ViewMode.NORMAL);this.zg();this.a.start();var a=this.i;a.j=w();var b=vz(a);uz(a,3,b);this.tn=!0;this.b.D("onResize",this.zg,this);this.b.D("onStateChange",
-this.pn,this);this.u("adEnd",this)}catch(c){this.u("adError",c)}};f.Zg=function(){return this.a.getCurrentAd()};f.getType=function(){return this.k};f.F=function(){this.g.removeAll();this.b.W("onResize",this.zg,this);this.b.W("onStateChange",this.pn,this);W(Q(this.b.a),"ad-showing");this.a&&(this.a.destroy(),this.a=null);this.Zd&&W(this.Zd,"ad-overlay");this.Zd=null;wz.C.F.call(this)};f.Bt=function(){var a=this.i;a.g=w();var b=vz(a);uz(a,6,b)};
-f.Dt=function(){qm(this.b);var a=this.i;a.g=w();var b=vz(a);if(a.i){var c=dz(a.a),d=a.i.y-c.top,d=Math.round(a.i.x-c.left)+"x"+Math.round(d);b.ck_xy=d;b.ck_wh=c.width+"x"+c.height}uz(a,100,b)};f.Et=function(a){this.i.i=a.target==a.currentTarget?null:new B(a.pageX,a.pageY)};f.Ct=function(a){a=a.getError();this.u("adError",a)};f.pn=function(a){P(a.state,16)&&xz(this,google.ima.ViewMode.NORMAL)};function xz(a,b){a.j!=b&&(a.j=b,a.tn&&a.zg())}
-f.zg=function(){var a=Ed(this.Zd);this.a.resize(a.width,a.height,this.j)};function yz(a,b){R.call(this);this.ga=a;this.a=b}y(yz,R);yz.prototype.show=function(){var a=n("afcAdCall");a&&a();a={};a.ad_id=this.a;a.at=this.getType();this.u("AD_LOGGING_EVENT",3,a);this.u("adEnd",this)};function zz(a,b){wz.call(this,1,a,b)}y(zz,wz);zz.prototype.zg=function(){};zz.prototype.getType=function(){return"1_3"};function Az(a,b,c,d){R.call(this);this.Ba=b;this.b=a;this.start=c;this.g=d;this.a=null}y(Az,R);f=Az.prototype;f.Bl=!0;f.Se=!1;f.isVisible=!0;f.Re="unloaded";f.Vk=!1;function Bz(a){return 0==a.start?Cz(a)&&Dz(a)?-2147483648:0:-1==a.start||-2==a.start?2147483647:1E3*a.start}function Cz(a){return"loaded"==a.Re||"error"==a.Re}function Dz(a){if(!Cz(a))throw Error("Preroll status is undefined before ad load.");return 0==a.start&&a.Se}
-function Ez(a){a.Re="loading";var b=a.g.shift();b?(0==a.start&&Fz(a.b,"nl"),b=b.create(a.start,a.Ba,a.b),L(a,b),In(b.load(),a.Uv,a.Tv,a)):(Gz(a.b,2,Hz(a,{})),a.Re="error",Iz(a))}f.getId=function(){return this.Ba};function Jz(a){a.a.W("adEnd",a.Qo,a);a.a.W("adError",a.To,a);a.a.W("AD_LOGGING_EVENT",a.Ro,a);a.a.W("select",a.So,a)}f.Tv=function(a){a instanceof Dn||Ez(this)};
-f.Uv=function(a){this.start=a.startTime;this.a=a.hu;L(this,this.a);0==this.Ba&&(a=this.a.getType(),this.b.i.at=a);this.a instanceof gz||this.a instanceof oz?this.Se=!0:this.a instanceof yz?this.isVisible=!1:this.a instanceof zz&&(this.isVisible=!1);this.Re="loaded";Iz(this)};function Iz(a){a.u("adBreakComplete",a)}
-f.show=function(){this.Vk?this.a instanceof wz&&xz(this.a,google.ima.ViewMode.NORMAL):(this.Vk=!0,this.a instanceof gz&&Fz(this.b,"bs"),this.a.D("adEnd",this.Qo,this),this.a.D("adError",this.To,this),this.a.D("AD_LOGGING_EVENT",this.Ro,this),this.a.D("select",this.So,this),this.a.show())};f.Qo=function(){if(this.Se){Jz(this);var a=this.b;a.ta.Fc&&!a.bk&&(Kf(a.J().ib+"mac_204?action_fcts=1"),a.bk=!0)}Iz(this)};f.To=function(a){if(a){var b={};Uy(a,b);Hz(this,b);Kz(this.b,32,b)}Jz(this);Iz(this)};
-f.Ro=function(a,b){Hz(this,b);Gz(this.b,a,b)};f.So=function(){this.Bl=!1};function Hz(a,b){b.sst=a.start;b.sidx=0};function Lz(a){this.Ls=a}function Mz(a){try{var b=lv(a).getElementsByTagName("AdBreak"),c=Ja(b,function(a){a=a.getAttribute("time");return Ca(a)});return new Lz(c)}catch(d){return new Lz([0])}};function Nz(a,b,c,d){this.i=a;this.j=b;this.b=c;this.k=d}Nz.prototype.g="";Nz.prototype.a="";function Oz(a){var b={};b.l_ns=a.j;b.l_state=a.k;b.sst=a.i;b.sidx=0;a.g&&(b.at=a.g);a.a&&(b.ad_id=a.a);return b};function Pz(a,b,c,d,e){this.j=a;this.g=b;this.A=c;this.ga=d;this.b=e;this.a=new Nz(b,this.j,d,e);this.G=new eo(this);this.i=new eo(this)}y(Pz,Lf);f=Pz.prototype;f.yo=null;f.Dd=null;
-f.load=function(){if(this.Dd)return this.Dd;this.Dd=new Cn;var a=this.ga.ta.g?this.ga.J().Sc||Qz:Ad(Q(this.ga.a)),b;this.ga.ta.a?b=!1:(b=0<(this.b&3)?190:200,b=200>a.width||a.height<b);if(b){b=this.a;var c=Oz(b);c.ck_wh=a.width+"x"+a.height;Kz(b.b,14,c);this.Qe(Error("The player size is too small."))}else In(this.ga.rg,this.Gu,this.Ed,this);return this.Dd};
-f.Tk=function(){var a=new google.ima.AdsRenderingSettings;a.baseYouTubeUrl=this.ga.J().ib;a.contentId=this.ga.getVideoData().L;a.useStyledNonLinearAds=!0;a.useVideoAdUi=this.ga.ta.N;a.youTubeAdNamespace=this.j;return a};function Rz(a,b){a.yo=b;var c=b.getType();a.a.g=c}
-f.Gu=function(a){var b=this.a;Gz(b.b,9,Oz(b));b=new google.ima.AdsRequest;b.adTagUrl=this.o();var c=this.ga.J().Sc||Qz;b.linearAdSlotWidth=c.width;b.linearAdSlotHeight=c.height;b.nonLinearAdSlotWidth=c.width;b.nonLinearAdSlotHeight=100;"3.1"==hz()&&(b.useLatestAdsLoader=this.ga.ta.bg);var c=this.b,d=n("yt.www.watch.ads.setGutSlotSizes");d&&d(0<(c&3),0<(c&12));this.G.listen(a,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,this.Yu);this.G.listen(a,google.ima.AdErrorEvent.Type.AD_ERROR,this.Xu);
-this.Do(a,b)};
-f.Yu=function(a){if(a.getUserRequestContext()===this){try{var b;if("3.1"==hz()){var c=this.Tk();b=a.getAdsManager({},c)}else b=a.getAdsManager({})}catch(d){this.Ed(d);return}this.i.listen(b,google.ima.AdEvent.Type.LOADED,v(this.Vw,this,b));this.i.listen(b,google.ima.AdErrorEvent.Type.AD_ERROR,v(this.Uw,this,b));z([google.ima.AdEvent.Type.ALL_ADS_COMPLETED,google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED,google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED],function(a){this.i.listen(b,a,ba)},this);a=mz(this.ga);
-try{b.init(a.width,a.height,google.ima.ViewMode.NORMAL)}catch(e){b.destroy(),this.Ed(e)}}};f.Vw=function(a,b){this.i.removeAll();var c=b.getAd(),d=c.isLinear(),e=this.a,g=Oz(e);g.ad_man=d?"instream":"overlay";Gz(e.b,12,g);e="";"3.1"==hz()&&(e=b.getAdData().mediaUrl);switch(d?this.Fk(a,c,e):this.Rg(a,c)){case 0:Sz(this);break;case 1:a.destroy();this.Qe(Error("Unable to create a display state."));break;case 2:c=this.a;Kz(c.b,21,Oz(c));a.destroy();this.Qe(Error("Fallback to next ad."));break;default:a.destroy()}};
-f.Uw=function(a,b){this.i.removeAll();a.destroy();this.Ed(b.getError())};f.Xu=function(a){var b=a.getError();b.getType()==google.ima.AdError.Type.AD_LOAD&&a.getUserRequestContext()===this&&this.Ed(b)};f.Fk=function(a,b,c){b=b.getAdId();this.a.a=b;a=this.ga.ta.ca?new oz(this.j,this.ga,a):new gz(this.j,this.ga,a,c);Rz(this,a);return 0};f.Rg=function(a,b){var c=b.getAdId();this.a.a=c;Rz(this,new wz(this.j,this.ga,a));return 0};
-f.Ed=function(a){if(a instanceof Dn)this.Dd.cancel();else{var b=this.a,c=Oz(b);a&&Uy(a,c);Kz(b.b,32,c);this.Qe(a)}};function Sz(a){a.Dd.b({hu:a.yo,startTime:a.g})}f.Qe=function(a){this.Dd.a(a)};f.F=function(){this.G.removeAll();this.i.removeAll();this.Dd&&this.Dd.cancel();Pz.C.F.call(this)};f.Do=function(a,b){try{a.requestAds(b,this)}catch(c){this.Ed(c)}};function Tz(a,b){this.a=a;this.b=b};function Uz(a){yz.call(this,a,"")}y(Uz,yz);Uz.prototype.getType=function(){return"2_3"};Uz.prototype.Zg=function(){return null};function Vz(a,b,c,d){Pz.call(this,2,a,b,c,d);this.k=new Tz(this.ga.ta,this.ga.J());(a=n("yt.www.watch.ads.handleSetAfvCompanionVars"))&&a(0<(d&3))}y(Vz,Pz);Vz.prototype.Tk=function(){var a=Vz.C.Tk.call(this);a.a=0==this.A;a.b=!0;return a};
-Vz.prototype.o=function(){var a=this.k,b=this.b,c=0==this.g||-1==this.g?this.g:1E3*this.g,d={};d.eid=a.a.hb;d.videoad_start_delay=c;d.scs=a.a.Jc;d.client=a.a.te;d.description_url=a.a.ba;d.loeid=a.a.nd;d.cust_gender=a.a.qb;d.host=a.a.host;d.hl=a.b.i;d.max_ad_duration=a.a.pd;d.url="embedded"==a.b.Y&&a.b.b?a.b.b:a.a.ba;a.a.Hc&&(d.adtest="on");isNaN(a.a.U)||(d.cust_age=a.a.U);isNaN(a.a.fa)||(d.hostTierId=a.a.fa);a.a.Ma&&(d.yt_pt=a.a.Ma);a.a.La&&(d.video_cpm=a.a.La);a.a.o&&(d.as_dbp=a.a.o);d.ytdevice=
-a.a.od;c="";b&2&&b&1?c="video":b&2?c="skippablevideo":b&1&&(c="standardvideo");b&4&&(c&&(c+="_"),c+="text_image_flash");d.ad_type=c;0<(b&3)?a.a.oa&&(d.channel=a.a.oa.join("+")):b&4&&a.a.Ia&&(d.channel=a.a.Ia.join("+"));a.a.Mc&&(d.lsv=1);var a=d,b={},e;for(e in a)ea.call(void 0,a[e])&&(b[e]=a[e]);return"//googleads.g.doubleclick.net/pagead/ads?"+Ti(b,"&")};Vz.prototype.Rg=function(a,b){if(this.ga.ta.a)return 1;0==this.g&&(this.g=10,this.a.i=10,Gz(this.ga,1));Yy(this.b);return Vz.C.Rg.call(this,a,b)};
-Vz.prototype.Qe=function(a){var b=this.ga.ta;b.a?Vz.C.Qe.call(this,a):b.rb||this.b&4?(Rz(this,new Uz(this.ga)),Sz(this)):Vz.C.Qe.call(this,a)};function Wz(a,b){if(a){this.Xp=a;this.rp=b;var c,d=this.Xp,e=d.indexOf(";sz=");c=Si(d.substring(e),";");d=d.substring(0,e).split("pfadx");if(c=2!=d.length?null:{Nx:d[0],Ox:d[1],Px:c})this.qp=c.Nx,this.vp=c.Ox,this.wp=c.Px}}f=Wz.prototype;f.Xp="";f.qp="";f.rp=!1;f.El="";f.vp="";f.wp=null;function Xz(a,b,c,d){Pz.call(this,1,a,b,c,d);this.k=new Wz(this.ga.ta.Nc,this.ga.ta.Kc)}y(Xz,Pz);
-Xz.prototype.o=function(){var a=this.k,b=this.b,c=[];b&1&&c.push("480x360");b&2&&c.push("480x361");b&12&&c.push("480x70");var d=[],e,g;b&12&&(d.push("300x250"),e="watch-channel-brand-div",g=1);0<(b&3)&&(d.push("300x60"),e="watch-longform-ad",g=1);b={xp:e,qh:c,yp:g,Zv:!0,Dl:d};c=Kb(a.wp);b.Yv&&(c.pos=b.Yv);b.yp&&(c.tile=b.yp.toString());b.xp&&(c.kmyd=b.xp);b.Zv&&(t(c["!c"])?c["!c"].push("html5"):c["!c"]=c["!c"]?[c["!c"],"html5"]:"html5");b.Dl&&0<b.Dl.length&&a.rp&&(c.ciu_szs=b.Dl.join(","));c.dcmt=
-"text/xml";ri()&&(c.kmob="ps3");a.El||(a.El=Math.floor(999999999*Math.random()).toString());c.ord=a.El;b.qh&&b.qh.length&&"sz"in c&&delete c.sz;c=Ti(c,";");b.qh&&b.qh.length&&(c="sz="+b.qh.join(",")+";"+c);return[a.qp,"pfadx",a.vp,";",c,"?"].join("")};
-Xz.prototype.Rg=function(a,b){var c=b.getAdId();this.a.a=c;c=b.getTraffickingParameters();return Wy(c,"rm")?(1!=this.b&&(c=n("yt.www.watch.ads.handleHideCompanion"))&&c(),Yz(a),2):Wy(c,"blockAllAds")?(Yz(a),Rz(this,new zz(this.ga,a)),0):Wy(c,"hideMaster")?(Rz(this,new zz(this.ga,a)),0):this.ga.ta.a?1:"3.1"==hz()?(Rz(this,new wz(this.j,this.ga,a)),0):1};function Yz(a){a.sendImpressionUrls&&a.sendImpressionUrls()};function Zz(a,b,c){var d=c.ta;this.k=d.Lc;var e=0,d=d.Gc.toUpperCase();"INVIDEO"==d?e=4:"INSTREAM"==d?e=1:"MPU"==d&&(e=8);Pz.call(this,2,a,b,c,e)}y(Zz,Pz);function $z(a){var b=new Cn;ej(a,{format:"RAW",method:"GET",timeout:5E3,al:function(){b.a(Error(a+" timed out"))},onError:function(c){b.a(Error("Problem loading "+a+" with status code "+c.status))},Oa:function(a){b.b(a)}});return b}Zz.prototype.o=function(){return""};
-Zz.prototype.Do=function(a,b){var c=this.b;c&1||c&4?this.k&&"goo.gl"==Xi(this.k)?(c=$z("https://www.googleapis.com/urlshortener/v1/url?key=AIzaSyBbSB-E7SYd1iggX6r2b5C7ljvO6fVqaj0&shortUrl="+this.k),In(c,function(a){a=kb(a.responseText);if(!a||!a.longUrl)throw Error("Invalid expanded forced ad URL");a=Zi(a.longUrl,{video_format:"43"});return $z(a)},null,this),In(c,function(c){b.adsResponse=c.responseText;a.requestAds(b,this)},null,this),In(c,null,this.Ed,this)):this.Ed(Error("Invalid URL: "+this.k)):
-this.Ed(Error("Invalid request type: "+c))};function aA(a,b,c){this.a=a;this.g=b;this.b=gi||hi?"html5_ios":ii?"html5_android":ri()?"html5_ps3":"leanback"==c?"html5_tv_leanback":"html5"};function bA(a,b,c,d){Pz.call(this,4,a,b,c,d);this.k=new aA(this.ga.ta,this.ga.getVideoData().wa,this.ga.J().Y)}y(bA,Pz);
-bA.prototype.o=function(){var a;a=this.k;if(a.a.K&&a.a.Pc){var b="10613:10613_youtube_"+a.b,c="youtube_watch_"+a.b,d="10613:10613_youtube_"+a.b.split("_")[0],e={nw:"10613"};e.asnw=a.a.K;e.ssnw=a.a.K;e.caid=a.a.Pc;e.prof=b;e.vdur=a.g;e.csid=c;e.resp="vast2";e.crtp="vast2s";e.flag="+emcr";b={};isNaN(a.a.$)||(b._fw_d_001=a.a.$);a.a.Ra&&(b._fw_d_002=a.a.Ra);a.a.za&&(b["_fwu:10613:lang"]=a.a.za);a.a.o&&(b._fw_dbp=a.a.o);b._fw_yt_type=a.a.I?"short":"long";var c={ptgt:"a",slid:"preroll"},g="";a.a.i&&!a.a.b?
-g=";linear-skippable":!a.a.i&&a.a.b&&(g=";video");c.slau="preroll"+g;c.w="480";c.h="360";c.tpos="0";c.tpcl="preroll";c.envp=d;c.cd="1440,900";a="//2975c.v.fwmrm.net/ad/g/1?"+Ti(e,"&")+";"+Ti(b,"&")+";"+Ti(c,"&")}else a="";return a};bA.prototype.Fk=function(a,b){return 0!=this.g?1:bA.C.Fk.call(this,a,b,null)};bA.prototype.Rg=function(){return 1};function cA(a,b){this.b=a;this.a=b}cA.prototype.create=function(a,b,c){switch(this.b){case 1:return new Vz(a,b,c,this.a);case 2:return new Xz(a,b,c,this.a);case 4:return new bA(a,b,c,this.a);case 3:return new Zz(a,b,c);default:return null}};function dA(a){this.a=a};function eA(a,b){this.O=a;this.B=this.O.kc;this.g="leanback"==this.O.Y;this.a=this.B||this.g;var c="3.1"==Sy.getInstance().getVersion();this.N=!this.a&&c;this.ca=a.tb&&c&&!this.a;this.apply(b)}var fA={mC:"m",hB:"f"};
-eA.prototype.apply=function(a){var b=A(this.O.g,"908301"),c="3.1"==Sy.getInstance().getVersion(),d=Ty(a.instream),e=(!this.a||b)&&c&&Ty(a.trueview),g=Ty(a.aftv)&&(!this.a||b);this.R=a.ad_slots;this.S=a.ad_breaks;this.gb=a.ad_flags||0;this.U=parseInt(a.cust_age,10);this.hb=a.cafe_experiment_id;var h=parseInt(a.cust_gender,10);isNaN(h)||(this.qb=h);this.Nc=a.ad_tag;this.Hc=!!a.adtest;this.$=parseInt(a.ad_age,10);this.Dc=a.cid;this.ba=a.ad_eurl;this.da=a.excluded_ads;this.Gc=a.force_ad_type;this.Lc=
-a.force_ad_url;this.Ra=Hb(fA,function(b){return b==a.ad_gender});this.o=a.dbp;this.Kc=!!a.mpu;this.host=a.ad_host;this.fa=parseInt(a.ad_host_tier,10);this.Ec=1==a.ad_logging_flag;this.G=Ty(a.afv)&&!this.a;this.j=g&&e;this.k=g&&d&&!Ty(a.no_afv_instream);this.H=Ty(a.dclk);this.Mc=1==a.livestream;this.ra=Ty(a.forced_ad)&&b&&c;this.A=1==parseInt(a.tpas_ad_type_id,10);this.Ic=!!a.fqsf;this.b=d;this.ua=Ty(a.invideo)&&!this.a;this.va=Ty(a.mpu)&&!this.a;this.Fc=Ty(a.shortform);this.I=Ty(a.sffb);this.Jc="1"==
-a.as_launched_in_country;this.ea=!this.a&&!this.A;this.i=e;b=a.ad_channel_code_instream;this.oa=u(b)?b.split(","):[];this.za=a.ad_language_iso639_2;this.nd=a.loeid;b=parseInt(a.afv_instream_max,10);isNaN(b)&&(b=15E3);this.pd=b;b=a.ad_channel_code_overlay;this.Ia=u(b)?b.split(","):[];this.Ma=a.yt_pt;this.te=a.ad_video_pub_id;this.La=parseInt(a.afv_video_min_cpm,10);this.rb=g&&this.I&&!this.G;this.Oc=this.G||this.rb;this.od=parseInt(a.ad_device,10);this.Pc=a.tpas_video_id;this.K=a.tpas_partner_id;this.bg=
-a.new_html5_ad_loader};eA.prototype.ea=!0;function gA(a,b){this.b=b;this.g=[];this.i={};this.j={};this.a=a}y(gA,Lf);f=gA.prototype;f.je=null;function hA(a){a.g.length||(db(a.b,function(a,c){return a.getId()-c.getId()}),a.g=Ia(a.b,function(a){return"unloaded"==a.Re}),0==a.g.length?fm(a.a):(null===Na(a.g,function(a){return 0==a.start})&&fm(a.a),iA(a)))}function iA(a){if(a.g.length){var b=a.g.shift();b.D("adBreakComplete",a.tl,a);Ez(b)}}f.tl=function(a){a.W("adBreakComplete",this.tl,this);H(v(this.zx,this,a),0)};
-f.zx=function(a){var b=Ha(this.b,a),c=this.b[b+1],b=this.b[b-1],d=2147483646;-2==a.start||-1==a.start?d=2147483647:c&&2147483647!=c.start&&(d=Bz(c)-1);0==a.Ba&&(Fz(this.a,"bl"),Dz(a)||Fz(this.a,"fb"));if(c="loaded"!=a.Re){if(b&&Cz(b)){var e=Bz(b);e>d&&(d=e);jA(this,b);kA(this,b,d)}}else this.i[a.getId()]=a,kA(this,a,d);fm(this.a);c&&this.$g(a);iA(this)};
-function kA(a,b,c){var d=Bz(b);if(!isNaN(d)){var e={};e.priority=-2!=b.start?2:3;e.id=String(b.getId());e.visible=b.isVisible;c=new nh(d,c,e);a.j[b.getId()]=c;a.a.yf(c)}}function jA(a,b){a.j[b.getId()]&&(a.a.Av(a.j[b.getId()]),delete a.j[b.getId()])}f.$g=function(a){a.W("adBreakComplete",this.tl,this);this.je&&a==this.je&&(this.je=null);jA(this,a);Ua(this.b,a);delete this.i[a.getId()];Nf(a)};
-f.rv=function(a){if(a.Se){if(-1!=a.start&&a.Bl){var b=this.a;lA(b);pm(b)}else Dz(a)&&!a.Bl?(b=this.a,lA(b),pm(b)):(lA(this.a),this.a.jb(!1));this.$g(a)}else a.isVisible||this.$g(a)};f.F=function(){z(this.b,this.$g,this);gA.C.F.call(this)};function mA(a,b){this.g=a;b&&(this.b=b)}function nA(a){var b={};b.allowed=a.g;a.b&&(b.ex_ads=a.b);a.a&&(b.at=a.a);return b};function oA(a,b){this.g=a;this.V=b;this.o=w();this.a=a.ta;this.b={};var c=[];this.a.A&&this.a.b&&c.push("4_2");this.a.H&&(this.a.b&&c.push("1_2"),this.a.i&&c.push("1_2_1"),this.a.ua&&c.push("1_1"),this.a.va&&c.push("1_3"));this.a.j&&c.push("2_2_1");this.a.k&&c.push("2_2");this.a.G&&c.push("2_1");this.a.Oc&&c.push("2_3");this.i=c.join(",");this.k=new mA(this.i,this.a.da);this.b.allowed=this.i;(c=this.a.da)&&(this.b.ex_ads=c)}var pA=[9,10,11,12],qA=[21,30],rA=[1009];oA.prototype.j=0;
-function sA(a,b){if(!a.a.Ec)return!1;var c=a.g.J();if(A(c.g,"906335"))return!0;c=b.ad_event;return A(pA,c)||7==c&&(c=b.ad_error,A(qA,c)||32==c&&A(rA,b.error_code))?!1:!0};function tA(a){Nw.call(this,a);this.j={};this.i={at:"0"};this.b=new Gm(this.a);this.g=null;a=this.getVideoData().b.html5_sdk_version;this.k=Sy.getInstance().load(a)}y(tA,Nw);var Qz=new C(0,0);f=tA.prototype;f.na="ad";f.kd="ad";f.xe=null;f.Td=null;f.ta=null;f.bk=!1;f.lk=!1;f.rg=null;f.ni=null;f.Xa=function(){return!!this.app.I.getVideoData().ga};
-f.create=function(){tA.C.create.call(this);this.Z=!0;Fz(this,"i");this.ta=new eA(this.J(),this.a.getVideoData().b||{});this.xe=new oA(this,this.a);Xy();this.bk=!1;var a=Jn(this.k);this.rg=In(a,this.Ms,null,this);t:{var a=new dA(this),b=[];try{var c=a.a.ta,d;if(c.ea){var e;if(c.S)e=Mz(c.S);else{var g;if(c.R){var h=Ja(c.R.split(","),Ca);g=new Lz(h)}else g=new Lz([0]);e=g}d=e}else d=new Lz([0]);for(var k=d.Ls,c=0;c<k.length;c++){var m=a.a;d=c;var p=k[c],s;if(a.a.ta.I){e=[];var r=a.a.ta;if(r.ra)e.push(new cA(3,
-0));else{r.A&&(r.b||r.i)&&e.push(new cA(4,1));r.H&&(g=0,r.b&&(g|=1),r.i&&(g|=2),r.ua&&(g|=4),r.va&&(g|=8),0<g&&e.push(new cA(2,g)));if(r.k||r.j)g=0,r.k&&(g|=1),r.j&&(g|=2),e.push(new cA(1,g));r.G&&e.push(new cA(1,4))}}else{e=[];var x=a.a.ta;if(x.ra)e.push(new cA(3,0));else{x.A&&x.b&&e.push(new cA(4,1));if(x.H){var M=0;x.b&&(M|=1);x.i&&(M|=2);0<M&&e.push(new cA(2,M))}if(x.k||x.j)M=0,x.k&&(M|=1),x.j&&(M|=2),e.push(new cA(1,M))}}s=e;var ta=new Az(m,d,p,s);b.push(ta)}}catch(Y){}finally{break t}}k=b;Fz(this,
-"bd");this.Td=new gA(this,k);hA(this.Td);k={};k.allowed=this.xe.i;jm(this,{},k)};f.destroy=function(){this.lk&&lA(this);this.Z=!1;this.g&&sz(this.app,this.g);Of(this.Td,this.g);this.g=this.Td=null;this.rg&&(this.rg.cancel(),this.rg=null);this.xe=null;var a=this.b;Im(a);Vc(Hm(a));a.b=null;tA.C.destroy.call(this)};f.getVideoData=function(){return this.app.getVideoData(1)};f.J=function(){return this.app.J()};
-function Gz(a,b,c){a=a.xe;c=c||{};var d=(w()-a.o)/1E3;c.art=d;d=a.g.J();d.k&&(c.feature=d.da);c.ad_flags=a.a.gb;var e=a.a.Dc;e&&(c.cid=e);c.mt=a.V.getCurrentTime();(d=hx(d))&&(c.lact=d);(d=a.V.Ph())&&(c.len=d);a.a.Ic&&(c.fqsf=1);(d=Sy.getInstance().getVersion())&&(c.sdkv=d);c.ad_event=b;if(3==b||4==b)a.k.a=c.at;b=c;if(sA(a,b)){var g;t:{c=a.b;d=Jb(b);for(g in c){if(g in d){g=null;break t}d[g]=c[g]}g=d}null===g?a.g.log(a.b):b=g;a.g.log(b);a.b={}}}function Kz(a,b,c){c=c||{};c.ad_error=b;Gz(a,7,c)}
-f.Oi=function(){return this.xe?this.xe.k:tA.C.Oi.call(this)};function hz(){return Sy.getInstance().getVersion()}function pz(a){if(!a.g){var b=new Ww(a.J().a);b.Y="adunit";b.Sb=!0;a.g=new gy(b,2)}return a.g}function mz(a){var b=a.ta.g?a.J().Sc||Qz:Ed(Q(a.a));a.ta.a||(b.height-=27);return b}function dz(a){return a.ta.g?(a=a.J().Sc||Qz,new Ab(0,0,a.width,a.height)):Cd(Q(a.a))}function lA(a){Im(a.b);a.lk=!1;om(a);nm(a,["seek","settings"]);a.J().Pd&&nm(a,["audio"])}
-function nz(a,b){switch(b){case 1:a.u("publish_external_event","onAdStart");break;case 2:a.u("publish_external_event","onAdEnd")}}function kz(a,b,c){a.u("publish_external_event","onAdStateChange",b,a.b.V.J().tb?a.b.V.app.P.b:Lm(a.b),c)}
-f.vc=function(a){tA.C.vc.call(this,a);var b=parseInt(a.getId(),10);if(this.Td&&!isNaN(b)&&(a=this.Td,q(b)&&(b=a.i[b]))){if(a.je!=b||b.Se||!b.isVisible)a.je&&a.$g(a.je),a.je=b,b.D("adBreakComplete",a.rv,a),b.Se&&(a=a.a,a.lk=!0,a.u("command_redirect_controls",a,["play_pause"],void 0),mm(a,["seek","settings"]),a.J().Pd&&mm(a,["audio"]),qm(a));b.show()}};
-f.dd=function(a){tA.C.dd.call(this,a);var b=parseInt(a.getId(),10),c=1E3*this.a.getCurrentTime();this.Td&&!isNaN(b)&&c>a.start&&(2147483647==a.end||2147483646==a.end)&&(a=this.Td,(b=a.i[b])&&a.je==b&&!b.Se&&b.isVisible&&b.Vk&&b.a instanceof wz&&xz(b.a,google.ima.ViewMode.FULLSCREEN))};
-f.Ms=function(){Fz(this,"sdk");if(this.ni)return this.ni;var a;if(this.ta.ca){a=new Mw(this.app,2);var b=google.ima.AdDisplayContainer,c=Hm(this.b),d=Km(this.b);a.i||(a.i=Jb(a.g),a.i.addEventListener=v(a.bu,a),a.i.removeEventListener=v(a.cu,a));a=new b(c,void 0,d,a.i)}else{a=this.b.V.J().tb?this.b.V.app.P.b:Lm(this.b);if(!a)return a=Error("AdModule.getVideoElement returned an invalid element."),b=new Cn,b.a(a),b;a=new google.ima.AdDisplayContainer(Hm(this.b),a,Km(this.b))}return this.ni=new google.ima.AdsLoader(a)};
-function Fz(a,b){var c=b;"nl"==b&&(c=a.xe,c.j++,c=c.j.toString());a.j[c]=w();"bs"!=c&&"fb"!=c||jm(a,a.j,a.i)}f.oe=function(a){this.u(a)};function uA(a){a&&(this.name=va(a.name),this.lb=a.screenId,this.jc=a.loungeToken,this.Cb=a.dialId||"")}f=uA.prototype;f.name="";f.lb="";f.jc="";f.Cb="";f.oq=function(){return{key:this.lb,name:this.name}};f.toString=function(){var a=this.jc?this.jc.slice(-6):"null";return"{name:"+this.name+",screenId:"+this.lb+",loungeToken:..."+a+",dialId:"+this.Cb+"}"};function vA(a){return a?a.toString():"null"}function wA(a){a=a||[];return"["+Ja(a,function(a){return vA(a)}).join(",")+"]"};function xA(a){a&&(this.id=a.id||"",this.name=va(a.name||""),this.activityId=a.activityId||"",this.status=a.status||"UNKNOWN")}f=xA.prototype;f.id="";f.name="";f.activityId="";f.status="UNKNOWN";f.oq=function(){return{key:this.id,name:this.name}};function yA(a){return{id:a.id,name:a.name,activityId:a.activityId,status:a.status}}f.toString=function(){return"{id:"+this.id+",name:"+this.name+",activityId:"+this.activityId+",status:"+this.status+"}"};
-function zA(a){a=a||[];return"["+Ja(a,function(a){return a?a.toString():"null"}).join(",")+"]"};function AA(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(a){var b=16*Math.random()|0;return("x"==a?b:b&3|8).toString(16)})}function BA(a,b){return Na(a,function(a){return a.key==b})}function CA(a){return Ja(a,function(a){return a.oq()})}function DA(a){return Ja(a,function(a){return yA(a)})}function EA(a){return Ja(a,function(a){return new xA(a)})}function FA(a,b){return a||b?a&&b?a.id==b.id&&a.name==b.name:!1:!0}
-function GA(a,b){return Na(a,function(a){return a.id==b})}function HA(a){return Ja(a,function(a){return{name:a.name,screenId:a.lb,loungeToken:a.jc,dialId:a.Cb}})}function IA(a){return Ja(a,function(a){return new uA(a)})}function JA(a,b){return a||b?a&&b?a.lb==b.lb:!1:!0}function KA(a,b){return a||b?a&&b?a.lb==b.lb&&a.jc==b.jc&&a.name==b.name&&a.Cb==b.Cb:!1:!0}function LA(a,b){return Na(a,function(a){return JA(a,b)})}function MA(a,b){return Na(a,function(a){return b==a.lb||b==a.Cb})};function NA(){var a=OA(),b=PA();A(a,b);QA()&&ib(a,b);a=RA(a);Ra(a)?Uq.remove("remote_sid","/","youtube.com"):(a=a.join(","),Uq.set("remote_sid",a,void 0,"/","youtube.com"))}function OA(){var a=bh("yt-remote-connected-devices")||[];db(a);return a}function RA(a){if(Ra(a))return[];var b=a[0].indexOf("#"),c=-1==b?a[0]:a[0].substring(0,b);return Ja(a,function(a,b){return 0==b?a:a.substring(c.length)})}function SA(a){Zg("yt-remote-connected-devices",a,86400)}
-function PA(){if(TA)return TA;var a=bh("yt-remote-device-id");a||(a=AA(),Zg("yt-remote-device-id",a,31536E3));for(var b=OA(),c=1,d=a;A(b,d);)c++,d=a+"#"+c;return TA=d}function UA(){return bh("yt-remote-session-browser-channel")}function QA(){return bh("yt-remote-session-screen-id")}
-function VA(a){5<a.length&&(a=a.slice(a.length-5));var b=Ja(WA(),function(a){return a.loungeToken}),c=Ja(a,function(a){return a.loungeToken});La(c,function(a){return!A(b,a)})&&Zg("yt-remote-lounge-token-expiration",!0,86400);Zg("yt-remote-local-screens",a,31536E3)}function WA(){return bh("yt-remote-local-screens")||[]}function XA(){return bh("yt-remote-online-screens")||[]}function YA(a){Zg("yt-remote-online-dial-devices",a,30)}function ZA(){return bh("yt-remote-online-dial-devices")||[]}
-function $A(a,b){a?Zg("yt-remote-session-video-id",a):ch("yt-remote-session-video-id");b?Zg("yt-remote-session-list-id",b):ch("yt-remote-session-list-id")}function aB(a){a||(ch("yt-remote-session-screen-id"),ch("yt-remote-session-video-id"),ch("yt-remote-session-list-id"));NA();a=OA();Ua(a,PA());SA(a)}var TA="";function bB(){var a=IA(XA()),b=EA(ZA()),b=Ia(b,function(b){return!MA(a,b.id)});return CA(Xa(a,b))};function cB(a){return dB(a||arguments.callee.caller,[])}
-function dB(a,b){var c=[];if(A(b,a))c.push("[...circular reference...]");else if(a&&50>b.length){c.push(eB(a)+"(");for(var d=a.arguments,e=0;e<d.length;e++){0<e&&c.push(", ");var g;g=d[e];switch(typeof g){case "object":g=g?"object":"null";break;case "string":break;case "number":g=String(g);break;case "boolean":g=g?"true":"false";break;case "function":g=(g=eB(g))?g:"[fn]";break;default:g=typeof g}40<g.length&&(g=g.substr(0,40)+"...");c.push(g)}b.push(a);c.push(")\n");try{c.push(dB(a.caller,b))}catch(h){c.push("[exception trying to get caller]\n")}}else a?
-c.push("[...long stack...]"):c.push("[end]");return c.join("")}function eB(a){if(fB[a])return fB[a];a=String(a);if(!fB[a]){var b=/function ([^\(]+)/.exec(a);fB[a]=b?b[1]:"[Anonymous]"}return fB[a]}var fB={};function gB(a,b,c,d,e){this.reset(a,b,c,d,e)}gB.prototype.b=null;gB.prototype.a=null;var hB=0;gB.prototype.reset=function(a,b,c,d,e){"number"==typeof e||hB++;this.i=d||w();this.j=a;this.k=b;this.g=c;delete this.b;delete this.a};gB.prototype.getMessage=function(){return this.k};function iB(a){this.b=a}iB.prototype.a=null;function jB(a,b){this.name=a;this.value=b}jB.prototype.toString=function(){return this.name};var kB=new jB("SHOUT",1200),lB=new jB("SEVERE",1E3),mB=new jB("WARNING",900),nB=new jB("INFO",800);f=iB.prototype;f.ov=function(){};f.qv=function(){return!1};f.getChildren=function(){this.a||(this.a={});return this.a};f.log=function(){};
-f.pv=function(a,b,c){var d=new gB(a,String(b),this.b);if(c){d.b=c;var e;var g=arguments.callee.caller;try{var h;var k=n("window.location.href");if(u(c))h={message:c,name:"Unknown error",lineNumber:"Not available",fileName:k,stack:"Not available"};else{var m,p,s=!1;try{m=c.lineNumber||c.Gy||"Not available"}catch(r){m="Not available",s=!0}try{p=c.fileName||c.filename||c.sourceURL||l.$googDebugFname||k}catch(x){p="Not available",s=!0}h=!s&&c.lineNumber&&c.fileName&&c.stack&&c.message&&c.name?c:{message:c.message||
-"Not available",name:c.name||"UnknownError",lineNumber:m,fileName:p,stack:c.stack||"Not available"}}e="Message: "+va(h.message)+'\nUrl: <a href="view-source:'+h.fileName+'" target="_new">'+h.fileName+"</a>\nLine: "+h.lineNumber+"\n\nBrowser stack:\n"+va(h.stack+"-> ")+"[end]\n\nJS stack traversal:\n"+va(cB(g)+"-> ")}catch(M){e="Exception trying to expose exception! You win, we lose. "+M}d.a=e}return d};f.info=function(){};var oB={},pB=null;function qB(){pB||(pB=new iB(""),oB[""]=pB)}
-function rB(a){qB();var b;if(!(b=oB[a])){b=new iB(a);var c=a.lastIndexOf("."),d=a.substr(c+1);rB(a.substr(0,c)).getChildren()[d]=b;oB[a]=b}return b};function sB(){this.a=w()}var tB=new sB;sB.prototype.set=function(a){this.a=a};sB.prototype.reset=function(){this.set(w())};sB.prototype.get=function(){return this.a};function uB(a){this.g=a||"";this.i=tB}uB.prototype.b=!0;uB.prototype.a=!1;function vB(a){return 10>a?"0"+a:String(a)}function wB(a,b){var c=(a.i-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}function xB(a){uB.call(this,a)}y(xB,uB);
-function yB(a,b){var c=[];c.push(a.g," ");if(a.b){var d=new Date(b.i);c.push("[",vB(d.getFullYear()-2E3)+vB(d.getMonth()+1)+vB(d.getDate())+" "+vB(d.getHours())+":"+vB(d.getMinutes())+":"+vB(d.getSeconds())+"."+vB(Math.floor(d.getMilliseconds()/10)),"] ")}c.push("[",wB(b,a.i.get()),"s] ");c.push("[",b.g,"] ");c.push(b.getMessage());a.a&&b.b&&c.push("\n",b.a);c.push("\n");return c.join("")};function zB(a,b){this.b=new ob(a);this.a=b?lb:kb}zB.prototype.stringify=function(a){return nb(this.b,a)};zB.prototype.parse=function(a){return this.a(a)};function AB(){};function BB(){}BB.prototype.a=null;var CB;function DB(){}y(DB,BB);function EB(a){return(a=FB(a))?new ActiveXObject(a):new XMLHttpRequest}function GB(a){var b={};FB(a)&&(b[0]=!0,b[1]=!0);return b}
-function FB(a){if(!a.b&&"undefined"==typeof XMLHttpRequest&&"undefined"!=typeof ActiveXObject){for(var b=["MSXML2.XMLHTTP.6.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"],c=0;c<b.length;c++){var d=b[c];try{return new ActiveXObject(d),a.b=d}catch(e){}}throw Error("Could not create ActiveXObject. ActiveX might be disabled, or MSXML might not be installed");}return a.b}CB=new DB;function HB(a,b,c,d,e){this.b=a;this.a=b;this.j=c;this.g=d;this.i=e||1;this.oc=45E3;this.o=new tq(this);this.k=new Uh;Vh(this.k,250)}f=HB.prototype;f.Be=null;f.yc=!1;f.Qf=null;f.nl=null;f.xg=null;f.Mf=null;f.Xd=null;f.Jb=null;f.$d=null;f.Qa=null;f.Og=0;f.Ac=null;f.Bf=null;f.He=null;f.vg=-1;f.Bn=!0;f.Ke=!1;f.gk=0;f.ci=null;
-function IB(a,b){switch(a){case 0:return"Non-200 return code ("+b+")";case 1:return"XMLHTTP failure (no data)";case 2:return"HttpConnection timeout";default:return"Unknown error"}}var JB={},KB={};f=HB.prototype;f.setTimeout=function(a){this.oc=a};function LB(a,b,c){a.Mf=1;a.Xd=Ge(b.clone());a.$d=c;a.G=!0;MB(a,null)}function NB(a,b,c,d,e){a.Mf=1;a.Xd=Ge(b.clone());a.$d=null;a.G=c;e&&(a.Bn=!1);MB(a,d)}
-function MB(a,b){a.xg=w();OB(a);a.Jb=a.Xd.clone();Ee(a.Jb,"t",a.i);a.Og=0;a.Qa=a.b.yk(a.b.mi()?b:null);0<a.gk&&(a.ci=new zr(v(a.Hn,a,a.Qa),a.gk));a.o.listen(a.Qa,"readystatechange",a.Zt);var c=a.Be?Jb(a.Be):{};a.$d?(a.Bf="POST",c["Content-Type"]="application/x-www-form-urlencoded",a.Qa.send(a.Jb,a.Bf,a.$d,c)):(a.Bf="GET",a.Bn&&!bc&&(c.Connection="close"),a.Qa.send(a.Jb,a.Bf,null,c));a.b.wc(1);var d=a.$d;if(d)for(var c="",d=d.split("&"),e=0;e<d.length;e++){var g=d[e].split("=");if(1<g.length)var h=
-g[0],g=g[1],k=h.split("_"),c=2<=k.length&&"type"==k[1]?c+(h+"="+g+"&"):c+(h+"=redacted&")}else c=null;a.a.info("XMLHTTP REQ ("+a.g+") [attempt "+a.i+"]: "+a.Bf+"\n"+a.Jb+"\n"+c)}f.Zt=function(a){a=a.target;var b=this.ci;b&&3==PB(a)?(this.a.debug("Throttling readystatechange."),Ar(b)):this.Hn(a)};
-f.Hn=function(a){try{if(a==this.Qa)t:{var b=PB(this.Qa),c=this.Qa.i,d=QB(this.Qa);if(D&&!qc(10)||bc&&!pc("420+")){if(4>b)break t}else if(3>b||3==b&&!$b&&!RB(this.Qa))break t;this.Ke||4!=b||7==c||(8==c||0>=d?this.b.wc(3):this.b.wc(2));SB(this);var e=QB(this.Qa);this.vg=e;var g=RB(this.Qa);g||this.a.debug("No response text for uri "+this.Jb+" status "+e);this.yc=200==e;this.a.info("XMLHTTP RESP ("+this.g+") [ attempt "+this.i+"]: "+this.Bf+"\n"+this.Jb+"\n"+b+" "+e);this.yc?(4==b&&TB(this),this.G?(UB(this,
-b,g),$b&&this.yc&&3==b&&(this.o.listen(this.k,"tick",this.Ft),this.k.start())):(VB(this.a,this.g,g,null),WB(this,g)),this.yc&&!this.Ke&&(4==b?this.b.$h(this):(this.yc=!1,OB(this)))):(this.He=400==e&&0<g.indexOf("Unknown SID")?3:0,XB(),TB(this),YB(this))}}catch(h){this.a.debug("Failed call to OnXmlHttpReadyStateChanged_"),this.Qa&&RB(this.Qa)&&RB(this.Qa)}finally{}};
-function UB(a,b,c){for(var d=!0;!a.Ke&&a.Og<c.length;){var e=ZB(a,c);if(e==KB){4==b&&(a.He=4,XB(),d=!1);VB(a.a,a.g,null,"[Incomplete Response]");break}else if(e==JB){a.He=4;XB();VB(a.a,a.g,c,"[Invalid Chunk]");d=!1;break}else VB(a.a,a.g,e,null),WB(a,e)}4==b&&0==c.length&&(a.He=1,XB(),d=!1);a.yc=a.yc&&d;d||(VB(a.a,a.g,c,"[Invalid Chunked Response]"),TB(a),YB(a))}f.Ft=function(){var a=PB(this.Qa),b=RB(this.Qa);this.Og<b.length&&(SB(this),UB(this,a,b),this.yc&&4!=a&&OB(this))};
-function ZB(a,b){var c=a.Og,d=b.indexOf("\n",c);if(-1==d)return KB;c=Number(b.substring(c,d));if(isNaN(c))return JB;d+=1;if(d+c>b.length)return KB;var e=b.substr(d,c);a.Og=d+c;return e}
-function $B(a,b){a.xg=w();OB(a);var c=b?window.location.hostname:"";a.Jb=a.Xd.clone();De(a.Jb,"DOMAIN",c);De(a.Jb,"t",a.i);try{a.Ac=new ActiveXObject("htmlfile")}catch(d){TB(a);a.He=7;XB();YB(a);return}var e="<html><body>";b&&(e+='<script>document.domain="'+c+'"\x3c/script>');e+="</body></html>";a.Ac.open();a.Ac.write(e);a.Ac.close();a.Ac.parentWindow.m=v(a.gu,a);a.Ac.parentWindow.d=v(a.On,a,!0);a.Ac.parentWindow.rpcClose=v(a.On,a,!1);c=a.Ac.createElement("div");a.Ac.parentWindow.document.body.appendChild(c);
-c.innerHTML='<iframe src="'+a.Jb+'"></iframe>';a.a.info("TRIDENT REQ ("+a.g+") [ attempt "+a.i+"]: GET\n"+a.Jb);a.b.wc(1)}f.gu=function(a){aC(v(this.zy,this,a),0)};f.zy=function(a){if(!this.Ke){var b=this.a;b.info("TRIDENT TEXT ("+this.g+"): "+bC(b,a));SB(this);WB(this,a);OB(this)}};f.On=function(a){aC(v(this.yy,this,a),0)};f.yy=function(a){this.Ke||(this.a.info("TRIDENT TEXT ("+this.g+"): "+a?"success":"failure"),TB(this),this.yc=a,this.b.$h(this),this.b.wc(4))};f.cancel=function(){this.Ke=!0;TB(this)};
-function OB(a){a.nl=w()+a.oc;cC(a,a.oc)}function cC(a,b){if(null!=a.Qf)throw Error("WatchDog timer not null");a.Qf=aC(v(a.cy,a),b)}function SB(a){a.Qf&&(l.clearTimeout(a.Qf),a.Qf=null)}f.cy=function(){this.Qf=null;var a=w();0<=a-this.nl?(this.a.info("TIMEOUT: "+this.Jb),2!=this.Mf&&this.b.wc(3),TB(this),this.He=2,XB(),YB(this)):cC(this,this.nl-a)};function YB(a){a.b.xc()||a.Ke||a.b.$h(a)}
-function TB(a){SB(a);Nf(a.ci);a.ci=null;a.k.stop();a.o.removeAll();if(a.Qa){var b=a.Qa;a.Qa=null;b.abort();b.dispose()}a.Ac&&(a.Ac=null)}function WB(a,b){try{a.b.Ap(a,b),a.b.wc(4)}catch(c){}};function dC(){}function VB(a,b,c,d){a.info("XMLHTTP TEXT ("+b+"): "+bC(a,c)+(d?" "+d:""))}dC.prototype.debug=function(a){this.info(a)};dC.prototype.info=function(){};
-function bC(a,b){if(!b||"y2f%"==b)return b;try{var c=lb(b);if(c)for(var d=0;d<c.length;d++)if(t(c[d])){var e=c[d];if(!(2>e.length)){var g=e[1];if(t(g)&&!(1>g.length)){var h=g[0];if("noop"!=h&&"stop"!=h)for(var k=1;k<g.length;k++)g[k]=""}}}return mb(c)}catch(m){return a.debug("Exception parsing expected JS array - probably was not JS"),b}};function eC(a,b,c,d,e){(new dC).debug("TestLoadImageWithRetries: "+e);if(0==d)c(!1);else{var g=e||0;d--;fC(a,b,function(e){e?c(!0):l.setTimeout(function(){eC(a,b,c,d,g)},g)})}}
-function fC(a,b,c){var d=new dC;d.debug("TestLoadImage: loading "+a);var e=new Image;e.onload=function(){try{d.debug("TestLoadImage: loaded"),gC(e),c(!0)}catch(a){}};e.onerror=function(){try{d.debug("TestLoadImage: error"),gC(e),c(!1)}catch(a){}};e.onabort=function(){try{d.debug("TestLoadImage: abort"),gC(e),c(!1)}catch(a){}};e.ontimeout=function(){try{d.debug("TestLoadImage: timeout"),gC(e),c(!1)}catch(a){}};l.setTimeout(function(){if(e.ontimeout)e.ontimeout()},b);e.src=a}
-function gC(a){a.onload=null;a.onerror=null;a.onabort=null;a.ontimeout=null};function hC(a,b){this.a=a;this.b=b;this.g=new zB(null,!0)}f=hC.prototype;f.Hk=null;f.Nb=null;f.Ei=!1;f.lo=null;f.Di=null;f.Yk=null;f.dl=null;f.Pb=null;f.Ve=-1;f.bh=null;f.fh=null;f.connect=function(a){this.dl=a;a=iC(this.a,this.dl);XB();this.lo=w();var b=this.a.A;null!=b?(this.bh=b[0],(this.fh=b[1])?(this.Pb=1,jC(this)):(this.Pb=2,kC(this))):(Ee(a,"MODE","init"),this.Nb=new HB(this,this.b,void 0,void 0,void 0),this.Nb.Be=this.Hk,NB(this.Nb,a,!1,null,!0),this.Pb=0)};
-function jC(a){var b=lC(a.a,a.fh,"/mail/images/cleardot.gif");Ge(b);eC(b.toString(),5E3,v(a.Nv,a),3,2E3);a.wc(1)}f.Nv=function(a){if(a)this.Pb=2,kC(this);else{XB();var b=this.a;b.a.debug("Test Connection Blocked");b.xd=b.le.Ve;mC(b,9)}a&&this.wc(2)};
-function kC(a){a.b.debug("TestConnection: starting stage 2");var b=a.a.B;if(null!=b)a.b.debug("TestConnection: skipping stage 2, precomputed result is "+b?"Buffered":"Unbuffered"),XB(),b?(XB(),nC(a.a,a,!1)):(XB(),nC(a.a,a,!0));else if(a.Nb=new HB(a,a.b,void 0,void 0,void 0),a.Nb.Be=a.Hk,b=oC(a.a,a.bh,a.dl),XB(),!D||qc(10))Ee(b,"TYPE","xmlhttp"),NB(a.Nb,b,!1,a.bh,!1);else{Ee(b,"TYPE","html");var c=a.Nb;a=Boolean(a.bh);c.Mf=3;c.Xd=Ge(b.clone());$B(c,a)}}f.yk=function(a){return this.a.yk(a)};
-f.abort=function(){this.Nb&&(this.Nb.cancel(),this.Nb=null);this.Ve=-1};f.xc=function(){return!1};
-f.Ap=function(a,b){this.Ve=a.vg;if(0==this.Pb)if(this.b.debug("TestConnection: Got data for stage 1"),b){try{var c=this.g.parse(b)}catch(d){pC(this.a,this);return}this.bh=c[0];this.fh=c[1]}else this.b.debug("TestConnection: Null responseText"),pC(this.a,this);else if(2==this.Pb)if(this.Ei)XB(),this.Yk=w();else if("11111"==b){if(XB(),this.Ei=!0,this.Di=w(),c=this.Di-this.lo,!D||qc(10)||500>c)this.Ve=200,this.Nb.cancel(),this.b.debug("Test connection succeeded; using streaming connection"),XB(),nC(this.a,
-this,!0)}else XB(),this.Di=this.Yk=w(),this.Ei=!1};
-f.$h=function(){this.Ve=this.Nb.vg;if(!this.Nb.yc)this.b.debug("TestConnection: request failed, in state "+this.Pb),0==this.Pb?XB():2==this.Pb&&XB(),pC(this.a,this);else if(0==this.Pb)this.b.debug("TestConnection: request complete for initial check"),this.fh?(this.Pb=1,jC(this)):(this.Pb=2,kC(this));else if(2==this.Pb){this.b.debug("TestConnection: request complete for stage 2");var a=!1;(a=!D||qc(10)?this.Ei:200>this.Yk-this.Di?!1:!0)?(this.b.debug("Test connection succeeded; using streaming connection"),XB(),
-nC(this.a,this,!0)):(this.b.debug("Test connection failed; not using streaming"),XB(),nC(this.a,this,!1))}};f.mi=function(){return this.a.mi()};f.wc=function(a){this.a.wc(a)};function qC(a){Rh.call(this);this.headers=new Ud;this.j=a||null;this.b=!1;this.I=this.a=null;this.O=this.A="";this.i=0;this.k="";this.g=this.N=this.G=this.K=!1;this.o=0;this.B=null;this.R="";this.H=this.S=!1}y(qC,Rh);var rC=/^https?$/i,sC=["POST","PUT"];f=qC.prototype;
-f.send=function(a,b,c,d){if(this.a)throw Error("[goog.net.XhrIo] Object is active with another request="+this.A+"; newUri="+a);b=b?b.toUpperCase():"GET";this.A=a;this.k="";this.i=0;this.O=b;this.K=!1;this.b=!0;this.a=this.j?EB(this.j):EB(CB);this.I=this.j?this.j.a||(this.j.a=GB(this.j)):CB.a||(CB.a=GB(CB));this.a.onreadystatechange=v(this.$m,this);try{AB(tC(this,"Opening Xhr")),this.N=!0,this.a.open(b,a,!0),this.N=!1}catch(e){AB(tC(this,"Error opening Xhr: "+e.message));uC(this,e);return}a=c||"";
-var g=this.headers.clone();d&&Zd(d,function(a,b){g.set(b,a)});d=Na(g.nc(),vC);c=l.FormData&&a instanceof l.FormData;!A(sC,b)||d||c||g.set("Content-Type","application/x-www-form-urlencoded;charset=utf-8");Zd(g,function(a,b){this.a.setRequestHeader(b,a)},this);this.R&&(this.a.responseType=this.R);"withCredentials"in this.a&&(this.a.withCredentials=this.S);try{wC(this),0<this.o&&(this.H=D&&pc(9)&&ga(this.a.timeout)&&q(this.a.ontimeout),AB(tC(this,"Will abort after "+this.o+"ms if incomplete, xhr2 "+
-this.H)),this.H?(this.a.timeout=this.o,this.a.ontimeout=v(this.oc,this)):this.B=Wh(this.oc,this.o,this)),AB(tC(this,"Sending request")),this.G=!0,this.a.send(a),this.G=!1}catch(h){AB(tC(this,"Send error: "+h.message)),uC(this,h)}};function vC(a){return"content-type"==a.toLowerCase()}f.oc=function(){"undefined"!=typeof aa&&this.a&&(this.k="Timed out after "+this.o+"ms, aborting",this.i=8,tC(this,this.k),Sh(this,"timeout"),this.abort(8))};
-function uC(a,b){a.b=!1;a.a&&(a.g=!0,a.a.abort(),a.g=!1);a.k=b;a.i=5;yC(a);zC(a)}function yC(a){a.K||(a.K=!0,Sh(a,"complete"),Sh(a,"error"))}f.abort=function(a){this.a&&this.b&&(tC(this,"Aborting"),this.b=!1,this.g=!0,this.a.abort(),this.g=!1,this.i=a||7,Sh(this,"complete"),Sh(this,"abort"),zC(this))};f.F=function(){this.a&&(this.b&&(this.b=!1,this.g=!0,this.a.abort(),this.g=!1),zC(this,!0));qC.C.F.call(this)};f.$m=function(){this.ha()||(this.N||this.G||this.g?AC(this):this.Gw())};f.Gw=function(){AC(this)};
-function AC(a){if(a.b&&"undefined"!=typeof aa)if(a.I[1]&&4==PB(a)&&2==QB(a))tC(a,"Local request error detected and ignored");else if(a.G&&4==PB(a))Wh(a.$m,0,a);else if(Sh(a,"readystatechange"),4==PB(a)){tC(a,"Request complete");a.b=!1;try{var b=QB(a),c,d;t:switch(b){case 200:case 201:case 202:case 204:case 206:case 304:case 1223:d=!0;break t;default:d=!1}if(!(c=d)){var e;if(e=0===b){var g=be(String(a.A))[1]||null;if(!g&&self.location)var h=self.location.protocol,g=h.substr(0,h.length-1);e=!rC.test(g?
-g.toLowerCase():"")}c=e}if(c)Sh(a,"complete"),Sh(a,"success");else{a.i=6;var k;try{k=2<PB(a)?a.a.statusText:""}catch(m){k=""}a.k=k+" ["+QB(a)+"]";yC(a)}}finally{zC(a)}}}function zC(a,b){if(a.a){wC(a);var c=a.a,d=a.I[0]?ba:null;a.a=null;a.I=null;b||Sh(a,"ready");try{c.onreadystatechange=d}catch(e){}}}function wC(a){a.a&&a.H&&(a.a.ontimeout=null);ga(a.B)&&(l.clearTimeout(a.B),a.B=null)}function PB(a){return a.a?a.a.readyState:0}function QB(a){try{return 2<PB(a)?a.a.status:-1}catch(b){return-1}}
-function RB(a){try{return a.a?a.a.responseText:""}catch(b){return""}}function tC(a,b){return b+" ["+a.O+" "+a.A+" "+QB(a)+"]"};function BC(a,b,c){this.G=a||null;this.b=1;this.g=[];this.i=[];this.a=new dC;this.k=new zB(null,!0);this.A=b||null;this.B=null!=c?c:null}function CC(a,b){this.a=a;this.map=b;this.X=null}f=BC.prototype;f.jh=null;f.zb=null;f.Ka=null;f.Ck=null;f.di=null;f.Zn=null;f.vi=null;f.Mg=0;f.Mu=0;f.nb=null;f.ie=null;f.Id=null;f.We=null;f.le=null;f.hi=null;f.xf=-1;f.uo=-1;f.xd=-1;f.Ng=0;f.Kf=0;f.Ge=8;var DC=new Rh;function EC(a){ph.call(this,"statevent",a)}y(EC,ph);
-function FC(a,b){ph.call(this,"timingevent",a);this.size=b}y(FC,ph);function GC(a){ph.call(this,"serverreachability",a)}y(GC,ph);f=BC.prototype;f.connect=function(a,b,c,d,e){this.a.debug("connect()");XB();this.Ck=b;this.jh=c||{};d&&q(e)&&(this.jh.OSID=d,this.jh.OAID=e);this.a.debug("connectTest_()");this.le=new hC(this,this.a);this.le.Hk=null;this.le.g=this.k;this.le.connect(a)};
-f.disconnect=function(){this.a.debug("disconnect()");HC(this);if(3==this.b){var a=this.Mg++,b=this.di.clone();De(b,"SID",this.j);De(b,"RID",a);De(b,"TYPE","terminate");IC(this,b);a=new HB(this,this.a,this.j,a,void 0);a.Mf=2;a.Xd=Ge(b.clone());(new Image).src=a.Xd;a.xg=w();OB(a)}JC(this)};function HC(a){a.le&&(a.le.abort(),a.le=null);a.Ka&&(a.Ka.cancel(),a.Ka=null);a.Id&&(l.clearTimeout(a.Id),a.Id=null);KC(a);a.zb&&(a.zb.cancel(),a.zb=null);a.ie&&(l.clearTimeout(a.ie),a.ie=null)}
-f.xc=function(){return 0==this.b};function LC(a){var b=0;a.Ka&&b++;a.zb&&b++;return b}function MC(a){a.zb||a.ie||(a.ie=aC(v(a.zo,a),0),a.Ng=0)}
-f.zo=function(a){this.ie=null;this.a.debug("startForwardChannel_");if(1==this.b){if(!a){this.a.debug("open_()");this.Mg=Math.floor(1E5*Math.random());a=this.Mg++;var b=new HB(this,this.a,"",a,void 0);b.Be=null;var c=NC(this),d=this.di.clone();De(d,"RID",a);this.G&&De(d,"CVER",this.G);IC(this,d);LB(b,d,c);this.zb=b;this.b=2}}else 3==this.b&&(a?OC(this,a):0==this.g.length?this.a.debug("startForwardChannel_ returned: nothing to send"):this.zb||(OC(this),this.a.debug("startForwardChannel_ finished, sent request")))};
-function OC(a,b){var c,d;b?6<a.Ge?(a.g=a.i.concat(a.g),a.i.length=0,c=a.Mg-1,d=NC(a)):(c=b.g,d=b.$d):(c=a.Mg++,d=NC(a));var e=a.di.clone();De(e,"SID",a.j);De(e,"RID",c);De(e,"AID",a.xf);IC(a,e);c=new HB(a,a.a,a.j,c,a.Ng+1);c.Be=null;c.setTimeout(Math.round(1E4)+Math.round(1E4*Math.random()));a.zb=c;LB(c,e,d)}function IC(a,b){if(a.nb){var c=a.nb.bq(a);c&&Zd(c,function(a,c){De(b,c,a)})}}
-function NC(a){var b=Math.min(a.g.length,1E3),c=["count="+b],d;6<a.Ge&&0<b?(d=a.g[0].a,c.push("ofs="+d)):d=0;for(var e=0;e<b;e++){var g=a.g[e].a,h=a.g[e].map,g=6>=a.Ge?e:g-d;try{Zd(h,function(a,b){c.push("req"+g+"_"+b+"="+encodeURIComponent(a))})}catch(k){c.push("req"+g+"_type="+encodeURIComponent("_badmap"))}}a.i=a.i.concat(a.g.splice(0,b));return c.join("&")}function PC(a){a.Ka||a.Id||(a.o=1,a.Id=aC(v(a.ep,a),0),a.Kf=0)}
-function QC(a){if(a.Ka||a.Id||3<=a.Kf)return!1;a.a.debug("Going to retry GET");a.o++;a.Id=aC(v(a.ep,a),RC(a,a.Kf));a.Kf++;return!0}
-f.ep=function(){this.Id=null;this.a.debug("Creating new HttpRequest");this.Ka=new HB(this,this.a,this.j,"rpc",this.o);this.Ka.Be=null;this.Ka.gk=0;var a=this.Zn.clone();De(a,"RID","rpc");De(a,"SID",this.j);De(a,"CI",this.hi?"0":"1");De(a,"AID",this.xf);IC(this,a);if(!D||qc(10))De(a,"TYPE","xmlhttp"),NB(this.Ka,a,!0,this.vi,!1);else{De(a,"TYPE","html");var b=this.Ka,c=Boolean(this.vi);b.Mf=3;b.Xd=Ge(a.clone());$B(b,c)}this.a.debug("New Request created")};
-function nC(a,b,c){a.a.debug("Test Connection Finished");a.hi=c;a.xd=b.Ve;a.a.debug("connectChannel_()");a.Kv(1,0);a.di=iC(a,a.Ck);MC(a)}function pC(a,b){a.a.debug("Test Connection Failed");a.xd=b.Ve;mC(a,2)}
-f.Ap=function(a,b){if(0!=this.b&&(this.Ka==a||this.zb==a))if(this.xd=a.vg,this.zb==a&&3==this.b)if(7<this.Ge){var c;try{c=this.k.parse(b)}catch(d){c=null}if(t(c)&&3==c.length){var e=c;if(0==e[0])t:if(this.a.debug("Server claims our backchannel is missing."),this.Id)this.a.debug("But we are currently starting the request.");else{if(this.Ka)if(this.Ka.xg+3E3<this.zb.xg)KC(this),this.Ka.cancel(),this.Ka=null;else break t;QC(this);XB()}else this.uo=e[1],c=this.uo-this.xf,0<c&&(e=e[2],this.a.debug(e+" bytes (in "+
-c+" arrays) are outstanding on the BackChannel"),37500>e&&this.hi&&0==this.Kf&&!this.We&&(this.We=aC(v(this.Ju,this),6E3)))}else this.a.debug("Bad POST response data returned"),mC(this,11)}else"y2f%"!=b&&(this.a.debug("Bad data returned - missing/invald magic cookie"),mC(this,11));else if(this.Ka==a&&KC(this),!/^[\s\xa0]*$/.test(b))for(c=this.k.parse(b),t(c),e=0;e<c.length;e++){var g=c[e];this.xf=g[0];g=g[1];2==this.b?"c"==g[0]?(this.j=g[1],this.vi=g[2],g=g[3],null!=g?this.Ge=g:this.Ge=6,this.b=3,
-this.nb&&this.nb.to(this),this.Zn=oC(this,this.vi,this.Ck),PC(this)):"stop"==g[0]&&mC(this,7):3==this.b&&("stop"==g[0]?mC(this,7):"noop"!=g[0]&&this.nb&&this.nb.ro(this,g),this.Kf=0)}};f.Ju=function(){null!=this.We&&(this.We=null,this.Ka.cancel(),this.Ka=null,QC(this),XB())};function KC(a){null!=a.We&&(l.clearTimeout(a.We),a.We=null)}
-f.$h=function(a){this.a.debug("Request complete");var b;if(this.Ka==a)KC(this),this.Ka=null,b=2;else if(this.zb==a)this.zb=null,b=1;else return;this.xd=a.vg;if(0!=this.b)if(a.yc)1==b?(w(),Sh(DC,new FC(DC,a.$d?a.$d.length:0)),MC(this),this.i.length=0):PC(this);else{var c=a.He;if(3==c||7==c||0==c&&0<this.xd)this.a.debug("Not retrying due to error type");else{this.a.debug("Maybe retrying, last error: "+IB(c,this.xd));var d;if(d=1==b)this.zb||this.ie?d=!1:1==this.b||2<=this.Ng?d=!1:(this.a.debug("Going to retry POST"),
-this.ie=aC(v(this.zo,this,a),RC(this,this.Ng)),this.Ng++,d=!0);if(d||2==b&&QC(this))return;this.a.debug("Exceeded max number of retries")}this.a.debug("Error: HTTP request failed");switch(c){case 1:mC(this,5);break;case 4:mC(this,10);break;case 3:mC(this,6);break;case 7:mC(this,12);break;default:mC(this,2)}}};function RC(a,b){var c=5E3+Math.floor(1E4*Math.random());a.nb||(a.a.debug("Inactive channel"),c*=2);return c*b}
-f.Kv=function(a){if(!A(arguments,this.b))throw Error("Unexpected channel state: "+this.b);};function mC(a,b){a.a.info("Error code "+b);if(2==b||9==b){var c=null;a.nb&&(c=null);var d=v(a.Ov,a);c||(c=new pe("//www.google.com/images/cleardot.gif"),Ge(c));fC(c.toString(),1E4,d)}else XB();SC(a,b)}f.Ov=function(a){a?(this.a.info("Successfully pinged google.com"),XB()):(this.a.info("Failed to ping google.com"),XB(),SC(this,8))};
-function SC(a,b){a.a.debug("HttpChannel: error - "+b);a.b=0;a.nb&&a.nb.Wo(a,b);JC(a);HC(a)}function JC(a){a.b=0;a.xd=-1;if(a.nb)if(0==a.i.length&&0==a.g.length)a.nb.Kk(a);else{a.a.debug("Number of undelivered maps, pending: "+a.i.length+", outgoing: "+a.g.length);var b=Ya(a.i),c=Ya(a.g);a.i.length=0;a.g.length=0;a.nb.Kk(a,b,c)}}function iC(a,b){var c=lC(a,null,b);a.a.debug("GetForwardChannelUri: "+c);return c}function oC(a,b,c){b=lC(a,a.mi()?b:null,c);a.a.debug("GetBackChannelUri: "+b);return b}
-function lC(a,b,c){var d=He(c);if(""!=d.Oe)b&&re(d,b+"."+d.Oe),se(d,d.oh);else var e=window.location,d=Ie(e.protocol,b?b+"."+e.hostname:e.hostname,e.port,c);a.jh&&Zd(a.jh,function(a,b){De(d,b,a)});De(d,"VER",a.Ge);IC(a,d);return d}f.yk=function(a){if(a)throw Error("Can't create secondary domain capable XhrIo object.");a=new qC;a.S=!1;return a};function aC(a,b){if(!ha(a))throw Error("Fn must not be null and must be a function");return l.setTimeout(function(){a()},b)}f.wc=function(){Sh(DC,new GC(DC))};
-function XB(){Sh(DC,new EC(DC))}f.mi=function(){return!(!D||qc(10))};function TC(){}f=TC.prototype;f.to=function(){};f.ro=function(){};f.Wo=function(){};f.Kk=function(){};f.bq=function(){return{}};function UC(){v(this.i,this);this.a=new xB;this.a.b=!1;this.b=this.a.a=!1;this.g="";this.j={}}function VC(){var a=WC;!0!=a.b&&(qB(),a.b=!0)}UC.prototype.i=function(a){if(!this.j[a.g]){var b=yB(this.a,a),c=XC;if(c)switch(a.j){case kB:YC(c,"info",b);break;case lB:YC(c,"error",b);break;case mB:YC(c,"warn",b);break;default:YC(c,"debug",b)}else window.opera?window.opera.postError(b):this.g+=b}};var WC=null,XC=window.console;function YC(a,b,c){if(a[b])a[b](c);else a.log(c)};var ZC=null,$C=null,aD=Array(50),bD=-1,cD=!1;function dD(a){var b=(bD+1)%50;bD=b;aD[b]=a;cD||(cD=49==b)}function eD(a){var b=aD;if(b[0]){var c=bD,d=cD?c:-1;do{var d=(d+1)%50,e=b[d];z(a,function(a){a(e)})}while(d!=c);aD=Array(50);bD=-1;cD=!1}}function fD(a,b){var c=n("yt.remote.debug.logger_"),d=n("yt.remote.debug.handlers_");if(c){if(c.log(nB,a+": "+b,void 0),d&&!Ra(d)){eD(d);var e=c.getLogRecord(nB,a+": "+b,void 0);z(d,function(a){a(e)})}}else d&&!Ra(d)||dD(new gB(nB,String(b),"yt.remote"))};function gD(a){fD("CAST",a)}function hD(a){var b=iD();b&&b.logMessage&&(a=yB(jD,a),b.logMessage(a))}
-function kD(){if(!lD){Ra(mD)&&Za(mD,ZA());var a;"cast"in window?(a=window.cast||{},a="ActivityStatus"in a&&"Api"in a&&"LaunchRequest"in a&&"Receiver"in a):a=!1;if(a){if(a=iD())a.removeReceiverListener("YouTube",nD),a.addReceiverListener("YouTube",nD),gD("API initialized in the other binary");else{a=new cast.Api;qa("yt.remote.castapi.api_",a);a.addReceiverListener("YouTube",nD);jD=new xB;jD.b=!1;jD.a=!1;a=n("yt.remote.debug.logger_");var b=n("yt.remote.debug.handlers_");a&&b||(WC||(WC=new UC),-1!=
-window.location.href.indexOf("Debug=true")&&VC(),VC(),WC.a.a=!0,ZC=n("yt.remote.debug.logger_")||rB("yt.remote"),iB.prototype.log=iB.prototype.log,iB.prototype.getLogRecord=iB.prototype.pv,iB.prototype.addHandler=iB.prototype.ov,iB.prototype.removeHandler=iB.prototype.qv,qa("yt.remote.debug.logger_",ZC),$C=n("yt.remote.debug.handlers_")||[],qa("yt.remote.debug.handlers_",$C),n("yt.remote.debug.logger_"),b=n("yt.remote.debug.handlers_"));b&&(b.push(hD),eD(b));gD("API initialized")}lD=!0}}}
-function oD(a){var b=Oa(mD,function(b){return b.id==a.id});0<=b&&(mD[b]=yA(a))}function nD(a){gD("Updating receivers: "+mb(a));pD(a);ar("yt-remote-cast-device-list-update",qD());z(qD(),function(a){rD(a.id)});z(a,function(a){a.isTabProjected&&(a=sD(a.id),gD("Detected device: "+a.id+" is tab projected. Firing DEVICE_TAB_PROJECTED event."),ar("yt-remote-cast-device-tab-projected",a))})}
-function tD(a,b){gD("Updating "+a+" activity status: "+mb(b));var c=sD(a);c?(b.activityId&&(c.activityId=b.activityId),c.status="running"==b.status?"RUNNING":"stopped"==b.status?"STOPPED":"error"==b.status?"ERROR":"UNKNOWN","RUNNING"!=c.status&&(c.activityId=""),oD(c),ar("yt-remote-cast-device-status-update",c)):gD("Device not found")}function qD(){kD();return EA(mD)}
-function pD(a){a=Ja(a,function(a){var c={id:a.id,name:a.name};if(a=sD(a.id))c.activityId=a.activityId,c.status=a.status;return c});Sa(mD);Za(mD,a)}function sD(a){var b=qD();return Na(b,function(b){return b.id==a})||null}function rD(a){var b=sD(a),c=iD();c&&b&&b.activityId&&c.getActivityStatus(b.activityId,function(b){"error"==b.status&&(b.status="stopped");tD(a,b)})}
-function uD(a){kD();var b=sD(a),c=iD();c&&b&&b.activityId?(gD("Stopping cast activity"),c.stopActivity(b.activityId,oa(tD,a))):gD("Dropping cast activity stop")}function iD(){return n("yt.remote.castapi.api_")}var jD=null,lD=!1,mD=n("yt.remote.castapi.devices_")||[];qa("yt.remote.castapi.devices_",mD);function vD(a){a&&(this.id=a.id||a.name,this.name=a.name,this.app=a.app,this.type=a.type||"REMOTE_CONTROL",this.Cp=a.user||"")}f=vD.prototype;f.id="";f.name="";f.app="";f.type="REMOTE_CONTROL";f.Cp="";f.equals=function(a){return a?this.id==a.id:!1};function wD(a,b){this.action=a;this.params=b||null};function xD(a,b){Uh.call(this);if(ha(a))b&&(a=v(a,b));else if(a&&ha(a.handleEvent))a=v(a.handleEvent,a);else throw Error("Invalid listener argument");this.o=a;Gh(this,"tick",v(this.k,this));this.stop();Vh(this,5E3+2E4*Math.random())}y(xD,Uh);xD.prototype.j=0;xD.prototype.k=function(){if(500<this.a){var a=this.a;24E4>2*a&&(a*=2);Vh(this,a)}this.o()};xD.prototype.start=function(){xD.C.start.call(this);this.j=w()+this.a};xD.prototype.stop=function(){this.j=0;xD.C.stop.call(this)};function yD(a,b){this.k=a;this.j=b;this.g=new kh;this.b=new xD(this.fu,this);this.a=null}y(yD,TC);f=yD.prototype;f.Yh="";f.Sg=0;f.Fi=0;f.debug=function(){};f.D=function(a,b,c){return this.g.D(a,b,c)};f.W=function(a,b,c){return this.g.W(a,b,c)};f.Wc=function(a){return this.g.Wc(a)};f.u=function(a,b){return this.g.u.apply(this.g,arguments)};
-f.connect=function(a,b,c){if(!this.a||2!=this.a.b){this.Yh="";this.b.stop();this.i=a||null;this.Sg=b||0;a=this.k+"/test";b=this.k+"/bind";var d=new BC("1",c?c.firstTestResults:null,c?c.secondTestResults:null),e=this.a;e&&(e.nb=null);d.nb=this;this.a=d;e?(3!=e.b&&0==LC(e)||this.debug("BrowserChannelServices.Channel: unexpected reconnect state: "+e.b),this.a.connect(a,b,this.j,e.j,e.xf)):c?this.a.connect(a,b,this.j,c.sessionId,c.arrayId):this.a.connect(a,b,this.j)}};
-f.disconnect=function(a){this.Fi=a||0;this.b.stop();this.a&&0!=this.a.b&&this.a.disconnect();this.Fi=0};f.sendMessage=function(a,b){if(!this.a||0==this.a.b||2!=this.a.b&&3!=this.a.b&&!this.b.Xc)this.debug("Ignoring message: "+a);else{var c={_sc:a};b&&Mb(c,b);this.debug("Sending message: "+mb(c));var d=this.a;if(0==d.b)throw Error("Invalid operation: sending map when state is closed");1E3==d.g.length&&mb(c);d.g.push(new CC(d.Mu++,c));2!=d.b&&3!=d.b||MC(d)}};
-f.to=function(){var a=this.b;a.stop();Vh(a,5E3+2E4*Math.random());this.i=null;this.Sg=0;this.u("handlerOpened")};f.Wo=function(a,b){var c=2==b&&401==this.a.xd;4==b||c||(6==b&&(c=this.b,c.stop(),Vh(c,500)),this.b.start());this.u("handlerError",b)};f.Kk=function(){this.b.Xc||this.u("handlerClosed")};f.bq=function(){var a={v:2};this.Yh&&(a.gsessionid=this.Yh);0!=this.Sg&&(a.ui=""+this.Sg);0!=this.Fi&&(a.ui=""+this.Fi);this.i&&Mb(a,this.i);return a};
-f.ro=function(a,b){this.debug("Channel received array: "+b);"S"==b[0]?this.Yh=b[1]:this.g.u("handlerMessage",new wD(b[0],b[1]))};function zD(a,b){(a.j.loungeIdToken=b)||a.b.stop()}function AD(a){return a.b.Xc?a.b.j-w():NaN}f.fu=function(){this.b.stop();0!=LC(this.a)?this.b.start():this.connect(this.i,this.Sg)};function BD(){this.xb=[];this.index=-1;CD(this)}function CD(a){a.volume=-1;a.muted=!1;a.b=null;a.a=-1;a.g=null;a.i=0;a.j=w()}function DD(a){return a.xb[a.index]}function ED(a,b){a.i=b;a.j=w()}function FD(a){switch(a.a){case 1:return(w()-a.j)/1E3+a.i;case -1E3:return 0}return a.i}function GD(a,b){var c=a.index;a.index=Ha(a.xb,b);c!=a.index&&CD(a)}function HD(a,b,c){c=c||DD(a);if(gb(a.xb,b)&&c==DD(a))return!1;a.xb=Ya(b);GD(a,c);return!0}
-BD.prototype.add=function(a,b){return a&&!A(this.xb,a)?(!b||-1<this.index&&this.index>=this.xb.length-1?this.xb.push(a):this.xb.splice(this.index+1,0,a),!0):!1};BD.prototype.remove=function(a){var b=DD(this);return Ua(this.xb,a)?(this.index=Ha(this.xb,b),!0):!1};function ID(){R.call(this);this.Bc=IA(WA());this.log_("Initializing local screens: "+wA(this.Bc));this.g=[];this.wk=null;this.b=[];this.a=[];this.Ai(qD());this.log_("Initializing DIAL devices: "+zA(this.a));var a=IA(XA());JD(this,a);this.log_("Initializing online screens: "+wA(this.b));KD(this)}y(ID,R);var LD=[2E3,2E3,1E3,1E3,1E3,2E3,2E3,5E3,1E4,15E3,2E4];f=ID.prototype;f.lh=NaN;f.log_=function(a){fD("RM",a)};
-function MD(a){var b=navigator.userAgent;if(0<=b.search("MSIE")&&(b=b.match(/MSIE ([\d.]+)/)[1],0>Ba(b,"10.0")))return a;b=be(document.location.href);return $d("https",null,b[3],null,a)}function KD(a){Yq("yt-remote-cast-device-list-update",a.Ai,a);Yq("yt-remote-cast-device-status-update",a.tx,a);Yq("yt-remote-cast-device-tab-projected",function(a){this.u("connectToReceiver",a.id)},a);a.Np();jf(v(a.Np,a),1E4)}
-f.u=function(a,b){if(this.ha())return!1;this.log_("Firing "+a);return this.G.u.apply(this.G,arguments)};f.Np=function(){var a=qD();Ra(a)||this.Ai(a);a=ND(this);Ra(a)||(bh("yt-remote-lounge-token-expiration")?OD(this,a):PD(this))};f.bl=function(){var a=ND(this),b=Ia(a,function(a){return!!LA(this.b,a)},this);JD(this,b);this.Ai(qD());this.u("managedScreenChange",a)};function QD(a,b){return Ia(b,function(a){return a.Cb?(a=GA(this.a,a.Cb),!!a&&"RUNNING"==a.status):!0},a)}
-f.Ai=function(a){var b=!1;z(a,function(a){var c=MA(this.Bc,a.id);c&&c.name!=a.name&&(this.log_("Renaming screen id "+c.id+" from "+c.name+" to "+a.name),c.name=a.name,b=!0)},this);b&&(this.log_("Renaming due to DIAL."),RD(this));YA(DA(a));var c=!gb(this.a,a,FA);c&&this.log_("Updating DIAL devices: "+zA(this.a)+" to "+zA(a));this.a=a;JD(this,this.b);c&&this.u("onlineReceiverChange")};
-f.tx=function(a){var b=GA(this.a,a.id);b&&(this.log_("Updating DIAL device: "+b.id+"("+b.name+") from status: "+b.status+" to status: "+a.status+" and from activityId: "+b.activityId+" to activityId: "+a.activityId),b.activityId=a.activityId,b.status=a.status,YA(DA(this.a)));JD(this,this.b)};function JD(a,b,c){b=QD(a,b);var d=!gb(a.b,b,KA);if(d||c)c=HA(b),Zg("yt-remote-online-screens",c,60);d&&(a.log_("Updating online screens: "+wA(a.b)+" -> "+wA(b)),a.b=b,a.u("onlineReceiverChange"))}
-function OD(a,b){var c=[],d={};z(b,function(a){a.jc&&(d[a.jc]=a,c.push(a.jc))});var e={method:"POST",Nf:{lounge_token:c.join(",")},X:a,Oa:function(a,b){var c=[];z(b.screens||[],function(a){"online"==a.status&&c.push(d[a.loungeToken])});var e=this.wk?SD(this,this.wk):null;e&&!LA(c,e)&&c.push(e);JD(this,c,!0)}};ej(MD("/api/lounge/pairing/get_screen_availability"),e)}
-function PD(a){var b=ND(a),c=Ja(b,function(a){return a.lb});Ra(c)||(a.log_("Updating lounge tokens for: "+mb(c)),ej(MD("/api/lounge/pairing/get_lounge_token_batch"),{Nf:{screen_ids:c.join(",")},method:"POST",X:a,Oa:function(a,c){TD(this,c.screens||[]);this.Bc=Ia(this.Bc,function(a){return!!a.jc});RD(this);OD(this,b)}}))}function TD(a,b){z(Xa(a.Bc,a.g),function(a){var d=Na(b,function(b){return a.lb==b.screenId});d&&(a.jc=d.loungeToken)})}
-function RD(a){var b=IA(WA());gb(a.Bc,b,KA)||(a.log_("Saving local screens: "+wA(b)+" to "+wA(a.Bc)),VA(HA(a.Bc)),a.bl())}function UD(a,b,c){var d=Oa(b,function(a){return JA(c,a)}),e=0>d?!0:!1;0>d?b.push(c):b[d]=c;LA(a.b,c)||a.b.push(c);return e}
-f.fp=function(a,b,c){var d=!1;b>=LD.length&&(this.log_("Pairing DIAL device "+a+" with "+c+" timed out."),d=!0);var e=GA(this.a,a);if(!e)this.log_("Pairing DIAL device "+a+" with "+c+" failed: no device for "+a),d=!0;else if("ERROR"==e.status||"STOPPED"==e.status)this.log_("Pairing DIAL device "+a+" with "+c+" failed: launch error on "+a),d=!0;d?(VD(this),this.u("screenPair",null)):ej(MD("/api/lounge/pairing/get_screen"),{method:"POST",Nf:{pairing_code:c},X:this,Oa:function(a,b){VD(this);var d=new uA(b.screen);
-d.name=e.name;d.Cb=e.id;var m=UD(this,this.Bc,d);this.log_("Paired with "+(m?"a new":"an old")+" local screen:"+vA(d));RD(this);this.u("screenPair",d);this.log_("Pairing "+c+" succeeded.");this.u("screenPair",d)},onError:function(){this.log_("Polling pairing code: "+c);I(this.lh);this.lh=H(v(this.fp,this,a,b+1,c),LD[b])}})};
-function WD(a,b,c,d,e){VD(a);if(GA(a.a,b)){if(!c){var g=c=AA();kD();var h=sD(b),k=iD();if(k&&h){var m=new cast.Receiver(h.id,h.name),m=new cast.LaunchRequest("YouTube",m);m.parameters="pairingCode="+g;m.description=new cast.LaunchDescription;m.description.text=document.title;d&&(m.parameters+="&v="+d,e&&(m.parameters+="&t="+Math.round(e)),m.description.url="http://i.ytimg.com/vi/"+d+"/default.jpg");"UNKNOWN"!=h.status&&(h.status="UNKNOWN",oD(h),ar("yt-remote-cast-device-status-update",h));gD("Sending a cast launch request with params: "+
-m.parameters);k.launch(m,oa(tD,b))}else gD("No cast API or no cast device. Dropping cast launch.")}a.lh=H(v(a.fp,a,b,0,c),LD[0])}else a.log_("No DIAL device with id: "+b)}function VD(a){I(a.lh);a.lh=NaN}function SD(a,b){var c=MA(ND(a),b);a.log_("Found screen: "+vA(c)+" with key: "+b);return c}function XD(a,b){var c=MA(a.b,b);a.log_("Found online screen: "+vA(c)+" with key: "+b);return c}
-function YD(a,b){var c=GA(a.a,b);if(!c){var d=MA(a.Bc,b);d&&(c=GA(a.a,d.Cb))}a.log_("Found DIAL: "+(c?c.toString():"null")+" with key: "+b);return c}function ND(a){return Xa(a.g,Ia(a.Bc,function(a){return!LA(this.g,a)},a))};function ZD(a,b){R.call(this);if($g){var c=$g;Yg(c,c.Pf.Kd(!0))}NA();rB("goog.net.BrowserChannel");this.i=new ID;c=PA();this.g=new yD("/api/lounge/bc",{device:"REMOTE_CONTROL",id:c,name:a,app:b});this.a=null;this.A=[];this.g.D("handlerOpened",this.dv,this);this.g.D("handlerClosed",this.$u,this);this.g.D("handlerError",this.av,this);this.g.D("handlerMessage",this.cv,this);this.i.D("managedScreenChange",this.bl,this);this.log_("Initializing with device id = "+c+", name = "+a+", app = "+b)}y(ZD,R);
-f=ZD.prototype;f.Wg=NaN;f.Zk=NaN;f.Wi=NaN;f.Xi=NaN;f.log_=function(a){fD("RC",a)};function $D(a){var b=QA();return b?SD(a.i,b):null}function aE(a,b,c){a.W("connectionOpened",b,c);a.W("connectionClosed",b,c);a.W("connectionError",b,c)}function bE(a,b){"connectionError"==b&&ch("yt-remote-session-screen-id");a.log_("Firing "+b);a.u(b,"connectionOpened"==b);a.o=null}
-function cE(a,b){"playerChange"==b?(I(a.Wi),a.Wi=H(v(function(){this.u("playerChange");this.Wi=NaN},a),2E3)):"playlistChange"==b&&(I(a.Xi),a.Xi=H(v(function(){this.u("playlistChange");this.Xi=NaN},a),2E3))}function dE(a,b){"playerChange"==b&&isNaN(a.Wi)&&a.u("playerChange");"playlistChange"==b&&isNaN(a.Xi)&&a.u("playlistChange")}function eE(a,b){b?(a.log_("Changing current screen id from: "+a.j+" to "+b.lb),a.j=b.lb,zD(a.g,b.jc)):(a.log_("Removing current screen id: "+a.j),a.j="",zD(a.g,""))}
-function fE(a){return a.j?SD(a.i,a.j):null}f.connect=function(a){this.log_("Connecting to the receiver: "+mb(a));var b=XD(this.i,a.key);b?gE(this,b):(a=YD(this.i,a.key))?hE(this,a):H(v(function(){bE(this,"connectionError")},this),0)};function iE(a){a=a||0;5>=a&&(a=0);return a}
-function gE(a,b){a.log_("Connecting to screen: "+vA(b));var c=$D(a);c&&!JA(b,c)?a.disconnect():jE(a);a.a=null;eE(a,b);c={};if(a.b){c.videoIds=kE(a.b).join(",");c.videoId=a.b.a.getVideoData().L;c.videoSources=lE(a.b).join(",");var d=a.o?a.o.currentTime:a.b.a.getCurrentTime();c.currentTime=iE(d)}Ib(c)?a.log_("Connecting with empty params"):a.log_("Connecting with setPlaylist and params: "+mb(c));a.b?$A(a.b.a.getVideoData().L,mE(a.b)):$A("","");a.g.connect(Ib(c)?{}:{method:"setPlaylist",params:mb(c)},
-1,UA());a.a=new BD;Ib(c)||(a.a.xb=c.videoIds.split(","),GD(a.a,c.videoId));nE(a)}function hE(a,b){a.log_("Connecting to DIAL device: "+(b?b.toString():"null"));oE(a);pE(a);var c=a.o?a.o.pairingCode:"";c?WD(a.i,b.id,c):a.b?WD(a.i,b.id,"",a.b.a.getVideoData().L,a.b.a.getCurrentTime()):WD(a.i,b.id,"");a.k=b.id;a.i.D("screenPair",a.Pn,a)}f.Pn=function(a){this.log_("Paired with a DIAL screen: "+vA(a));oE(this);a?gE(this,a):(this.k="",bE(this,"connectionError"))};
-f.disconnect=function(){this.log_("Disconnecting with user intent.");pE(this);aB();this.g.disconnect(1)};function pE(a){VD(a.i);var b=Na(a.A,function(a){return"REMOTE_CONTROL"==a.type});b?(a.log_("Did not stop DIAL device, because another remote is connected: "+mb(b?{id:b.id,name:b.name,app:b.app,type:b.type,user:b.Cp}:null)),a.k=""):(b=fE(a),a.k?(a.log_("Stopping DIAL device: "+a.k),uD(a.k),a.k=""):b&&b.Cb&&(a.log_("Stopping DIAL device: "+b.Cb),uD(b.Cb)))}
-function jE(a){a.log_("Disconnecting from screen.");a.g.disconnect(2)}function qE(a,b){var c=fE(a),d=Na(b,function(a){return c&&(a.key==c.lb||a.key==c.Cb)||this.k&&(a=YD(this.i,a.key))&&a.id==this.k?!0:!1},a);a.log_("Found current receiver: "+mb(d)+" in "+mb(b));return d}function rE(a){return sE(a)?a.a:null}function tE(a,b,c){c?a.log_("Sending: action="+b+", params="+mb(c)):a.log_("Sending: action="+b);uE(a)?a.log_("Action = "+b+" was ignored due to reconnecting."):a.g.sendMessage(b,c)}
-function vE(a,b,c,d){d=iE(d);a.a.add(b,!0)&&tE(a,"insertVideo",{videoId:b,videoSource:c});ED(a.a,d);GD(a.a,b);cE(a,"playlistChange");tE(a,"setVideo",{currentTime:d,videoId:b})}function wE(a,b,c,d,e){e=iE(e);tE(a,"setPlaylist",{videoIds:c.join(","),videoId:b,videoSources:Ja(c,function(){return d}),currentTime:e});ED(a.a,e);HD(a.a,c,b);cE(a,"playlistChange")}
-function xE(a){var b=bh("yt-remote-session-video-id"),c=bh("yt-remote-session-list-id"),d=a.b.a.getVideoData().L,e=mE(a.b);$A(d,e);a.log_("Watch context changed: videoId from "+b+" to "+d+" listId from "+c+" to "+e);var g=!1,h=!1;d&&d!=b&&(g=!0);e&&e!=c&&(h=!0);g?(b=lE(a.b),c=a.b.a.ub(),b=b[c?c.pa:0],c=a.b.a.getCurrentTime(),h?wE(a,d,kE(a.b),b,c):vE(a,d,b,c)):h&&(d=kE(a.b),h=lE(a.b),tE(a,"updatePlaylist",{videoIds:d.join(","),videoSources:h.join(",")}),HD(a.a,d),cE(a,"playlistChange"))}
-function yE(a){tE(a,"play");ED(a.a,FD(a.a));-1E3!=a.a.a&&(a.a.a=1);cE(a,"playerChange")}f.qo=function(){tE(this,"getNowPlaying")};function sE(a){var b=a.g.a;return!!b&&3==b.b&&!!a.j&&isNaN(a.Wg)}function nE(a){zE(a);a.Wg=H(v(function(){zE(this);eE(this,null);this.k="";this.a=null;this.log_("Connecting timeout");bE(this,"connectionError");aB();this.g.disconnect(1)},a),1E4)}function zE(a){I(a.Wg);a.Wg=NaN}function AE(a){I(a.Zk);a.Zk=NaN}function oE(a){a.i.W("screenPair",a.Pn,a)}
-f.dv=function(){this.log_("Channel opened");var a=this.j;Zg("yt-remote-session-browser-channel",{firstTestResults:[""],secondTestResults:!this.g.a.hi,sessionId:this.g.a.j,arrayId:this.g.a.xf});Zg("yt-remote-session-screen-id",a);var a=OA(),b=PA();A(a,b)||a.push(b);SA(a);NA();this.b&&(this.b.a.getVideoData().Na&&!mE(this.b)?this.log_("Wait for playlist data to be loaded."):xE(this))};function BE(a){aB(!0);AE(a);a.i.wk=null;eE(a,null);a.k=""}
-f.$u=function(){this.log_("Channel closed");var a=!!this.j&&isNaN(this.Wg);BE(this);a&&bE(this,"connectionClosed")};f.av=function(a){uE(this)?this.log_("Channel error: "+a+" with reconnection in "+AD(this.g)+" ms"):this.log_("Channel error: "+a+" without reconnection");uE(this)||BE(this);zE(this);bE(this,"connectionError")};
-function CE(a,b){switch(b.action){case "loungeStatus":var c=kb(b.params.devices);a.A=Ja(c,function(a){return new vD(a)});break;case "loungeScreenDisconnected":Wa(a.A,function(a){return"LOUNGE_SCREEN"==a.type});break;case "remoteConnected":var d=new vD(kb(b.params.device));Na(a.A,function(a){return a.equals(d)})||Ta(a.A,d);break;case "remoteDisconnected":d=new vD(kb(b.params.device)),Wa(a.A,function(a){return a.equals(d)})}}
-function DE(a,b){var c=!1;if("loungeStatus"==b.action)c=!!Na(a.A,function(a){return"LOUNGE_SCREEN"==a.type});else if("loungeScreenConnected"==b.action)c=!0;else if("loungeScreenDisconnected"==b.action)c=!1;else return;c!=sE(a)&&(c?(zE(a),bE(a,"connectionOpened"),a.qo()):a.disconnect())}function uE(a){return!isNaN(AD(a.g))}
-f.cv=function(a){a.params?this.log_("Received: action="+a.action+", params="+mb(a.params)):this.log_("Received: action="+a.action);CE(this,a);DE(this,a);if(sE(this)){var b=!1,c=!1,d,e,g,h,k,m,p;a.params&&(d=a.params.videoId||a.params.video_id,e=a.params.videoIds||a.params.video_ids,g=a.params.state,h=a.params.currentTime||a.params.current_time,k=a.params.volume,m=a.params.muted,q(a.params.currentError)&&(p=kb(a.params.currentError)));if("onSubtitlesTrackChanged"==a.action)d==DD(this.a)&&(delete a.params.videoId,
-Ib(a.params)?this.a.b=null:this.a.b=a.params,dE(this,"playerChange"));else if(DD(this.a)||'"onStateChange"'!=a.action)"playlistModified"!=a.action&&"nowPlayingPlaylist"!=a.action||e?(d||"nowPlaying"!=a.action&&"nowPlayingPlaylist"!=a.action?d?d!=DD(this.a)&&(b=!0):d=DD(this.a):(GD(this.a,""),b=!0),e&&(e=e.split(","),HD(this.a,e,d)&&(b=!0))):(HD(this.a,[]),b=!0),this.a.add(d)&&tE(this,"getPlaylist"),d&&GD(this.a,d),b&&dE(this,"playlistChange"),q(g)&&(b=parseInt(g,10),b=isNaN(b)?-1:b,-1==b&&-1E3==this.a.a&&
-(b=-1E3),c=c||b!=this.a.a,this.a.a=b,d=null,-1E3==b&&(d=this.a.g||"unknown",p&&(d=p.reason||d)),c=c||this.a.g!=d,this.a.g=d,1==this.a.a?(AE(this),this.Zk=H(v(this.qo,this),2E4)):AE(this)),"onError"!=a.action||-1!=this.a.a&&-1E3!=this.a.a||(a=kb(a.params.errors)||[],1==a.length&&"PLAYER_ERROR"==a[0].error&&a[0].videoId==DD(this.a)&&(this.a.a=-1E3,this.a.g=a[0].reason||"unknown",c=!0)),h&&(b=parseInt(h,10),ED(this.a,isNaN(b)?0:b),c=!0),q(k)&&(b=parseInt(k,10),isNaN(b)||(c=c||this.a.volume!=b,this.a.volume=
-b),q(m)&&(m="true"==m,c=c||this.a.muted!=m,this.a.muted=m)),c&&dE(this,"playerChange")}};f.bl=function(){this.j&&!fE(this)?(this.log_("Dropping current screen with id: "+this.j),this.disconnect(),this.a=null):$D(this)||aB()};function EE(){ZD.call(this,"Desktop","youtube-desktop");K(window,"unload",v(this.B,this));K(window,"beforeunload",v(this.B,this))}y(EE,ZD);ca(EE);EE.prototype.B=function(){jE(this)};function FE(a,b){this.a=a;this.a.D("onVolumeChange",this.Sh,this);this.a.D("onPlaylistUpdate",this.en,this);this.i=NaN;this.b=b;this.b.D("playerChange",this.fn,this);this.b.D("playlistChange",this.gn,this);this.k=0;this.g={};this.j=new zr(this.Js,1E3,this);L(this,this.j);this.o=0}y(FE,Lf);f=FE.prototype;
-f.F=function(){GE(this);this.a.W("onVolumeChange",this.Sh,this);this.a.W("onPlaylistUpdate",this.en,this);this.a=null;this.b.W("playerChange",this.fn,this);this.b.W("playlistChange",this.gn,this);this.b=null};f.gx=function(a,b){rE(this.b)&&(HE(this)?this.hw.apply(this,arguments):this.iw.apply(this,arguments))};
-f.iw=function(a,b){var c=Array.prototype.slice.call(arguments,1);switch(a){case "control_toggle_play_pause":case "control_play":case "control_pause":IE(this,this.a.a.getCurrentTime());break;case "control_seek":IE(this,c[0])}};
-f.hw=function(a,b){var c=rE(this.b),d=Array.prototype.slice.call(arguments,1);switch(a){case "control_toggle_play_pause":1==c.a?JE(this):(yE(this.b),this.a.jb(!0));break;case "control_play":yE(this.b);this.a.jb(!0);break;case "control_pause":JE(this);break;case "control_seek":this.o=d[0];Ar(this.j);break;case "control_subtitles_set_track":KE(this,d[0])}};function JE(a){var b=a.b;tE(b,"pause");ED(b.a,FD(b.a));-1E3!=b.a.a&&(b.a.a=2);cE(b,"playerChange");LE(a,FD(rE(a.b)));GE(a);a.a.jb(!1)}
-f.Js=function(){var a=this.o,b=rE(this.b);GE(this);LE(this,a);-1==b.a?IE(this,a):(b=this.b,tE(b,"seekTo",{newTime:a}),ED(b.a,a),-1E3!=b.a.a&&(b.a.a=3),cE(b,"playerChange"))};
-function KE(a,b){if(HE(a)){var c=a.b,d=a.a.a.getVideoData().L;b?(c.a.b={trackName:b.name,languageCode:b.languageCode,sourceLanguageCode:b.translationLanguage?b.translationLanguage.languageCode:"",languageName:b.languageName,format:b.format,kind:b.kind},d={videoId:d},Mb(d,c.a.b),tE(c,"setSubtitlesTrack",d)):tE(c,"setSubtitlesTrack");cE(c,"playerChange");a.g=rE(a.b).b}}function IE(a,b){vE(a.b,a.a.a.getVideoData().L,"VI",b);var c=a.a;ME(c);NE(c.g)}
-f.Sh=function(a){if(HE(this)){var b=Math.round(a.volume),c=this.b;a=!!a.muted;var d={volume:b,muted:a};-1!=c.a.volume&&(d.delta=b-c.a.volume);c.a.muted=a;c.a.volume=b;tE(c,"setVolume",d);cE(c,"playerChange")}};f.en=function(){xE(this.b)};
-f.fn=function(){if(HE(this)){var a=rE(this.b);GE(this);switch(a.a){case 1:OE(this);this.a.jb(!0);break;case 3:var b=this.a;ME(b);NE(b.g);break;case 0:this.a.jb(!1);this.j.stop();b=this.a.a;(b=O(b.app,b.a||1))&&b.pg(!0);LE(this,this.a.a.getVideoData().wa);break;case 2:this.a.jb(!1);LE(this,FD(a));break;case -1:this.a.jb(!1);break;case -1E3:var b=this.a,c=J("REMOTE_PLAYER_ERROR");ME(b);PE(b.g,c)}0==this.k&&(b=this.a.a,(b=O(b.app,b.a||1))&&b.pg(!1));this.k=a.a;QE(this);b=Math.round(this.a.a.Um());-1!=
-a.volume&&b!=a.volume&&(this.a.W("onVolumeChange",this.Sh,this),this.a.a.Wm(a.volume),a.muted?this.a.a.Vm():this.a.a.Xm(),this.a.D("onVolumeChange",this.Sh,this))}else this.a.jb(!1)};
-function QE(a){var b=rE(a.b).b;if(!(b||a.g?b&&a.g&&b.trackName==a.g.trackName&&b.languageCode==a.g.languageCode&&b.languageName==a.g.languageName&&b.format==a.g.format&&b.kind==a.g.kind:1))if(a.g=b){var c=a.a.a.Ij("captions","tracklist",{Fy:1}),c=Na(c,function(a){return a.languageCode==b.languageCode&&a.name==b.trackName});a.a.a.jn("captions","track",c)}else a.a.a.ln("captions")}f.gn=function(){HE(this)||(LE(this,0),GE(this),this.a.jb(!1))};
-function HE(a){var b=rE(a.b);return!!b&&DD(b)==a.a.a.getVideoData().L}function OE(a){GE(a);uE(a.b)||(LE(a,FD(rE(a.b))),a.i=H(v(function(){OE(this)},a),500))}function GE(a){I(a.i);a.i=NaN}function LE(a,b){var c=a.a.a.getVideoData().wa;a.a.u("command_progress",b,b/c,void 0)};function RE(){Z.call(this,["div",["html5-bezel","html5-center-overlay"],["div","{{icon}}"]]);this.a=NaN;this.hide()}y(RE,Z);RE.prototype.hide=function(){RE.C.hide.call(this);SE(this)};RE.prototype.setIcon=function(a){xm(this.template,"icon",a)};RE.prototype.show=function(a){SE(this);a&&this.setIcon(a);RE.C.show.call(this)};function SE(a){I(a.a);W(a.element,"html5-bezel-fade")};function TE(a){Z.call(this,["div","ytp-thumbnail"]);this.a=a}y(TE,Z);
-TE.prototype.show=function(a){if(a||this.element.childNodes.length){if(a){Vc(this.element);var b=this.element,c=this.a;if(void 0!=cn("backgroundSize"))d=document.createElement("div"),d.style.backgroundImage="url("+gn(b,a,c)+")";else{var d=document.createElement("img");d.src=gn(b,a,c);a=d;b.clientWidth/b.clientHeight<fn?(a.style.height="100%",a.style.width="auto"):(a.style.height="auto",a.style.width="100%")}V(d,"video-thumbnail");this.element.appendChild(d)}TE.C.show.call(this)}};function UE(a,b,c,d){R.call(this);this.R=d;this.b=this.a=null;this.I=c;this.O=new ln(J("REMOTE_PLAYER_RECONNECT_TIME"),["formatted_time"]);this.B=new ln(J("REMOTE_CONNECTED_STATUS"),["receiver_name"]);this.H=new ln(J("REMOTE_CONNECTING_STATUS"),["receiver_name"]);this.N=new ln(J("REMOTE_ERROR_STATUS"),["receiver_name"]);this.j=this.H;this.g=this.A=this.k=this.i=null;this.K="";this.o=null;this.k=E("ytp-remote-display-container",b);this.i=E("html5-remote-display-status-bar",b);VE(this);b=E("html5-remote-display-error",
-b);c=Sc("div");b.appendChild(c);V(c,"html5-remote-display-error-icon");this.A=Sc("div");b.appendChild(this.A);this.g=new Om(this.R,"ytp-button-remote-reconnect");this.g.Aa(J("REMOTE_PLAYER_RECONNECT_BUTTON"));this.g.T(b);this.K=K(this.g,"click",v(this.u,this,"reconnectclicked"));this.o=new TE(a.a.J().kc);this.o.T(this.k);this.o.show(a.a.getVideoData());L(this,this.o);this.a=new RE;this.a.T(this.k);this.a.hide();L(this,this.a);this.b=new it;V(this.b.element,"html5-center-overlay");V(this.b.element,
-"html5-center-transform");this.b.T(this.k);this.b.show();L(this,this.b)}y(UE,R);UE.prototype.F=function(){vf(this.K);this.i.innerHTML="";UE.C.F.call(this);this.o=this.i=this.a=null};function WE(a){a.j=a.H;VE(a);XE(a,!1);a.a.hide();a.b.show()}function NE(a){a.j=a.B;VE(a);XE(a,!1);a.a.hide();a.b.show()}function PE(a,b){a.j=a.N;VE(a);a.a.hide();a.b.hide();a.g.hide();a.A.innerHTML=b;XE(a,!0)}function XE(a,b){X(a.k,"ytp-remote-error",b)}
-function YE(a,b){PE(a,pn(a.O,{formatted_time:Xm(b/1E3)}));a.g.show()}function VE(a){a.i&&(a.i.innerHTML=pn(a.j,{receiver_name:'<span class="mdx-receiver">'+a.I+"</span>"},void 0,!0))};function ZE(a){R.call(this);this.k=this.g="";this.j=null;this.i=a;this.a=this.b=null;$E(this,a)}y(ZE,R);ZE.prototype.F=function(){vf(this.g);vf(this.k)};function aF(a,b){var c="";z(b,function(a){c+=pn(this.j,{receiver_key:a.key,receiver_name:a.name})},a);a.a.innerHTML=c;xr(mr.getInstance(),a.i)}function bF(a,b){var c=E("active",a.a);if(c){if(G(c,"value")==b)return;am(c,["active","selected"])}(c=a.a.querySelector('[data-value="'+b+'"]'))&&$l(c,["active","selected"])}
-function $E(a,b){a.b=yr(mr.getInstance(),b);var c=E("html5-remote-receiver-template",a.b);a.j=on(c,["receiver_key","receiver_name"]);a.a=E("html5-remote-receivers",a.b);a.a.innerHTML="";a.g=zf(a.b,v(a.o,a),"yt-uix-button-menu-item");a.k=K(b,"click",v(function(){this.u("menushown")},a))}ZE.prototype.o=function(a){(a=a.currentTarget)&&"remote-select-receiver"==G(a,"action")&&(a=G(a,"value"),bF(this,a),this.u("selectreceiver",a))};function cF(a){Nw.call(this,a);var b=Q(this.a);this.H=a.P.A;this.k={key:AA(),name:J("REMOTE_LOCAL_SCREEN")};this.g=this.j=null;this.b=dF(this);this.B=NaN;a=this.b;a.o=bh("yt-remote-delayed-connect-key");if(a.o)a.log_("Connecting with the delayed connect data: "+mb(a.o)),a.connect({key:a.o.key}),ch("yt-remote-delayed-connect-key");else{var c=$D(a);c?c.lb==a.j?a.log_("Skipping connecting because current connection exists."):(a.log_("Resuming MDx session: "+vA(c)),eE(a,c),a.g.connect({},0,UA()),a.a=
-new BD,nE(a)):(aB(),a.log_("Skipping connecting because no session screen found."))}this.A=new ZE(E("html5-remote-button",b));this.A.D("selectreceiver",this.Dj,this);L(this,this.A);this.i=this.k;this.ng()}y(cF,Nw);var eF=["play_pause","seek"],fF=["captions"];f=cF.prototype;f.na="remote";f.kd="remote";f.Xa=function(){return this.app.I.J().Ig};
-f.create=function(){cF.C.create.call(this);var a=this.b=dF(this),b=this.Kn;aE(a,b,this);a.D("connectionOpened",b,this);a.D("connectionClosed",b,this);a.D("connectionError",b,this);this.b.i.D("onlineReceiverChange",this.ng,this);this.b.i.D("connectToReceiver",this.Dj,this);this.ng();this.i!=this.k&&3<this.a.app.o&&this.load()};function gF(a){a.b&&(aE(a.b,a.Kn,a),a.b.i.W("onlineReceiverChange",a.ng,a),a.b.i.W("connectToReceiver",a.Dj,a),a.b.b=null,a.b=null)}
-f.destroy=function(){var a=this.A;rr(mr.getInstance(),a.i);gF(this);cF.C.destroy.call(this)};
-f.load=function(){if(!this.Z){cF.C.load.call(this);this.ng();var a=E("html5-remote-module",Q(this.a));this.g=new UE(this,a,this.i.name,this.H);this.g.D("reconnectclicked",this.Nm,this);this.j=new FE(this,this.b);KE(this.j,this.a.Ij("captions","track"));this.a.Jj();this.u("command_redirect_controls",this,eF,fF);var b=this.b.o?this.b.o.currentTime:0;0!=b&&H(v(function(){LE(this.j,b)},this),0);rE(this.b)&&!Ra(rE(this.b).xb)&&this.a.qg();this.Z=!0}};
-f.unload=function(){this.Z&&(this.Z=!1,hF(this,this.k),this.jb(!1),om(this),this.g.W("reconnectclicked",this.Nm,this),ME(this),Of(this.j,this.g),this.g=this.j=null,cF.C.unload.call(this))};f.F=function(){gF(this);ME(this);Of(this.j,this.g);this.g=this.j=null;cF.C.F.call(this)};function mE(a){return a.a.ub()?a.a.getVideoData().Na:""}function kE(a){var b=a.a.ub();if(b){a=[];for(var c=0;c<b.Pa;c++)a[c]=qg(b,c).L;return a}return[a.a.getVideoData().L]}
-function lE(a){var b=mE(a);if(b){b=b.substr(0,2);a=Vl(a.a.ub());for(var c=[],d=0;d<a;d++)c[d]=b;b=c}else b=["VI"];return b}function dF(a){var b=EE.getInstance();b.b=a;return b}f.Kn=function(){ME(this);this.Z&&uE(this.b)?iF(this):rE(this.b)?this.load():this.unload()};f.Nm=function(){var a=this.b;uE(a)&&(a=a.g.b,a.Xc&&(a.stop(),a.start(),a.k()));WE(this.g)};f.oe=function(a,b){this.j.gx.apply(this.j,arguments)};
-f.Dj=function(a){if(this.i.key!=a)if(this.k.key==a){var b=rE(this.b);a=!!b&&1==b.a&&DD(b)==this.a.getVideoData().L;b=b?FD(b):0;this.i=this.k;this.b.disconnect();this.unload();a&&(this.a.Th(b),this.a.qg())}else if(a=BA(bB(),a))hF(this,a),this.b.connect(a),this.load()};function hF(a,b){(a.i||b?a.i&&b&&a.i.key==b.key:1)||(a.i=b,bF(a.A,b.key))}f.ng=function(){var a=bB();this.b&&(this.i=qE(this.b,a)||this.k);a.unshift(this.k);aF(this.A,a);bF(this.A,this.i.key);this.g&&(a=this.g,a.I=this.i.name,VE(a))};
-function iF(a){ME(a);uE(a.b)?(YE(a.g,AD(a.b.g)),a.B=H(v(function(){iF(this)},a),1E3)):WE(a.g)}function ME(a){I(a.B);a.B=NaN}f.jb=function(a){ME(this);var b=this.g;b.j=b.B;VE(b);XE(b,!1);b.b.hide();b.a.show();b.a.setIcon(a?"html5-bezel-pause":"html5-bezel-play");cF.C.jb.call(this,a)};function jF(){Z.call(this,["div","html5-video-info-panel",["span","html5-video-info-panel-close",{role:"button",title:"close"},"[x]"],["div","html5-video-info-panel-content",["table","html5-video-info-table",["tr","",["th","","Video ID:"],["td","","{{video_id}}"]],["tr","",["th","","Dimensions:"],["td","","{{dimensions}}"]],["tr","",["th","","Resolution:"],["td","","{{resolution}}"]],["tr","",["th","","Volume:"],["td","","{{volume}}"]],["tr","",["th","","Stream Type:"],["td","","{{stream_type}}"]],
-["tr","",["th","","Mime Type:"],["td","","{{mime}}"]],["tr","",["th","","DASH:"],["td","","{{dash}}"]],["tr","",["th","","DRM:"],["td","","{{drm}}"]]],["table",["html5-video-info-table","html5-video-element-info-table"],["tr","",["th","","Decoded Frames"],["th","","Dropped Frames"],["th","","Parsed Frames"],["th","","Presented Frames"]],["tr","",["td","","{{decoded_frames}}"],["td","","{{dropped_frames}}"],["td","","{{parsed_frames}}"],["td","","{{presented_frames}}"]],["tr","",["th","","Video Bytes Decoded"],
-["th","","Audio Bytes Decoded"],["th","","Painted Frames"],["th","","Paint Delay"]],["tr","",["td","","{{video_bytes_decoded}}"],["td","","{{audio_bytes_decoded}}"],["td","","{{painted_frames}}"],["td","","{{paint_delay}}"]]]]]);this.a=this.template.a["html5-video-info-panel-close"]}y(jF,Z);jF.prototype.update=function(a){a.dimensions=a.video_element_width+" x "+a.video_element_height;a.resolution=a.video_width+" x "+a.video_height;a.volume+="%";a.drm=a.drm_flavor+" / "+a.drm_key_system;this.template.update(a)};
-jF.prototype.F=function(){this.a=null;jF.C.F.call(this)};function kF(a){R.call(this);this.app=a;this.ea=this.U=this.b=this.R=this.g=this.a=this.fa=null;this.Ma=this.Ra=0;this.S=null;a=a.J();this.La=Bj()||"blazer"==a.Ja;this.va=0;this.j=null;this.ok()}y(kF,R);var lF=null;f=kF.prototype;f.ok=function(){this.app.D("videodatachange",this.Ll,this)};f.xj=function(){var a=Ic(this.fa);(a=Zl(a,"html5-video-player")?a:E("html5-video-player",a))||(a=lF||E("html5-video-player"));if(!a)return!1;mF(this,a);this.u("templateready");return!0};
-function mF(a,b){lF=b.cloneNode(!0);a.a=b;a.a.setAttribute("id",a.app.K.attrs.id);var c=Ic(a.fa);c!=a.a&&c.appendChild(a.a);(c=Ic("html5-player-messages"))&&z(c.children,function(a){try{var b=JSON.parse(a.innerHTML);mf(a.id,b)}catch(c){mf(a.id,a.innerHTML)}})}f.addClass=function(a){$l(this.a,arguments)};f.removeClass=function(a){am(this.a,arguments)};
-f.yj=function(){var a=this.app.J(),b=this.a;this.addClass("el-"+a.Y);this.addClass("ps-"+a.Ja);X(b,"html5-native-controls",a.Ub);X(b,"html5-mobile",a.kc);a.ve||this.addClass("html5-chromeless");a.tb||this.addClass("tag-pool-enabled");b.style.display="";this.g=E("html5-video-container",b);this.U=E("html5-video-content",b);this.ea=E("html5-video-controls",b);this.j=new jF;this.j.T(b);K(this.j.a,"click",v(this.mk,this));L(this,this.j);this.La?this.S=K(window,"resize",v(this.Gi,this)):this.S=jf(v(this.Gi,
-this),250)};f.Gi=function(){this.R&&xb(nF(this),this.R)||this.tf()};f.tf=function(){if(this.b){var a=nF(this);if(!a.isEmpty()){var b=oF(this),c=nF(this),d=1,e=pF(this);if(e){var g=qF(this,c,b,e,!1),d=g.width/g.height/yb(b);yd(this.b,g.width/d,g.height);md(this.b,g.left+g.width/2*(1-1/d),g.top)}else yd(this.b,c),md(this.b,0,0);b=qF(this,c,b,e,!0);yd(this.U,b.width,b.height);md(this.U,b.left,b.top);dn(this.b,"transform",1==d?"none":"scaleX("+d+")");this.R&&xb(a,this.R)||(this.R=a,this.zl(a));this.u("resize")}}};
-f.zl=function(){};f.xk=function(){};f.Ll=function(a,b){this.b.setAttribute("data-youtube-id",b.L);qi&&(b.title?this.b.setAttribute("title",b.title):this.b.removeAttribute("title"));var c=Il(b,"yt:bgcolor");this.g.style.backgroundColor=c?c:"";this.Ra=Gk(Il(b,"yt:stretch"));this.Ma=Gk(Il(b,"yt:crop"))};f.Bj=function(){};f.Ip=function(){};f.Ko=function(){};function nF(a){return a.g?new C(a.g.clientWidth,a.g.clientHeight):new C(0,0)}
-function oF(a){return a.b?new C(a.b.videoWidth,a.b.videoHeight):new C(0,0)}function qF(a,b,c,d,e){c.isEmpty()?e=b:d?(c=new C(a.Ra||yb(c),1),a=new C(a.Ma||yb(c),1),zb(a,c),d=yb(a)>yb(b)?b.width/a.width:b.height/a.height,e=e?a.scale(d):c.scale(d)):e=zb(c.clone(),b);return new Ab((b.width-e.width)/2,(b.height-e.height)/2,e.width,e.height)}function pF(a){return!a.app.J().Ub&&!oF(a).isEmpty()}function Lv(a,b){var c=a.ea;c.insertBefore(b,c.childNodes[0]||null)}f.Cj=function(){};
-function vg(a){a.j&&(a.j.show(),a.Mp(),kf(a.va),a.va=jf(v(a.Mp,a),500))}
-f.Mp=function(){var a=O(this.app),b=this.app.getVideoData(),c=this.app.uj(),d=this.b,c={video_id:b.L,video_width:d.videoWidth,video_height:d.videoHeight,video_element_width:d.clientWidth,video_element_height:d.clientHeight,dash:"no",mime:"",drm_flavor:"",drm_key_system:"",volume:Math.round(this.app.xa.volume),stream_type:this.app.J().protocol,decoded_frames:c.hmewdfc||c.hmemdf||"-",dropped_frames:c.hmewdrop||"-",parsed_frames:c.hmempf||"-",presented_frames:c.hmempresented||"-",video_bytes_decoded:c.hmewvdbc||
-"-",audio_bytes_decoded:c.hmewadbc||"-",painted_frames:c.hmempainted||"-",paint_delay:c.hmempaintdelay||"-"};b.a&&(c.dash=b.a.j&&b.a.a?"no":"yes",c.mime=b.a.mb);if(a=a.I?a.I.g:null)c.drm_flavor=a.b,c.drm_key_system=a.a;this.j.update(c)};f.mk=function(a){a&&a.stopPropagation();this.j&&(kf(this.va),this.j.hide())};f.F=function(){this.S&&(this.La?vf(this.S):kf(this.S));this.mk();this.j&&Af(this.j.a);F(this.a);this.ea=this.U=this.b=this.g=this.a=this.fa=null;kF.C.F.call(this)};function rF(){this.a=[];this.b=[]}ca(rF);var Nm=n("yt.player.utils.VideoTagPool.instance_")||rF.getInstance();qa("yt.player.utils.VideoTagPool.instance_",Nm);f=rF.prototype;f.vy=function(a){if(!(this.a.length>=a)){a-=this.a.length;for(var b=0;b<a;b++){var c=sF(this);this.a.push(c)}}};
-function sF(a){var b=document.createElement("video");pa(b,vi);K(b,"loadeddata",v(b.dw,b));K(b,"volumechange",v(b.ew,b));K(b,"timeupdate",v(b.pp,b));gi&&6<=li&&K(b,"webkitbeginfullscreen",v(b.play,b));wi(b);if(a.b.length){var c=a.b[0],d=c.muted;b.volume=100*c.volume/100;b.muted=d}a.b.push(b);K(b,"volumechange",v(a.fw,a));return b}f.fw=function(a){a=a.target;var b=a.volume,c=a.muted;z(this.a,function(a){a.volume=b;a.muted=c})};f.Cy=function(){return this.a.length?this.a.pop():sF(this)};
-f.Ay=function(a){a&&A(this.b,a)&&(Ci(a),Af(a),Ua(this.b,a))};f.xy=function(a){return this.a.length>=(a||1)};rF.prototype.fillPool=rF.prototype.vy;rF.prototype.getTag=rF.prototype.Cy;rF.prototype.releaseTag=rF.prototype.Ay;rF.prototype.hasTags=rF.prototype.xy;function tF(a,b){var c,d;d||(d=0);c||(c=rd(document.body));cr(new B(b.pageX,b.pageY),a,d,null,c,5)};function uF(){this.a=new eo(this)}y(uF,Lf);f=uF.prototype;f.Sj=null;f.Ce=null;f.Tj=null;f.Si=null;f.De=null;f.Mr=function(){this.hide()};f.Nr=function(a){a.stopPropagation()};f.hide=function(){bn(this.De);ar("panelhidden")};f.Or=function(a){27==a.keyCode&&this.hide()};f.dn=function(){this.Ce.select()};f.show=function(){an(this.De)};f.F=function(){this.a.removeAll();this.Ce=this.Sj=this.Tj=this.De=null;uF.C.F.call(this)};function vF(a){this.V=a;this.V.D("internalvideodatachange",this.Vn,this);this.g=new eo(this);this.a=new eo(this);this.b=new uF;L(this,this.b)}y(vF,Lf);f=vF.prototype;f.Zb=null;function wF(a,b,c){for(var d=Jc(Ym[b],a.Zb),e=0;e<d.length;e++)fo(a.g,d[e],"down",function(a){c.call(this,a);this.hide(a);a=b.replace("CONTEXT_MENU_","").toLowerCase();xF(this.V,"contextmenu."+a)})}f.Vn=function(a,b){var c=E("html5-context-menu-copy-embed-html",this.Zb);Zm(c,b.Ho)};
-f.hn=function(a){a=kg(this.V,a);yF(this,a,"URL")};f.Qr=function(){var a=ef("EMBED_HTML_TEMPLATE"),b=ef("EMBED_HTML_URL"),c=dx(this.V.J()),d=this.V.getVideoData().L,b=b.replace(/__videoid__/g,d),a=a.replace(/__url__/g,va(b)),a=a.replace(/__width__/g,c.width),a=a.replace(/__height__/g,c.height);yF(this,a,"Text")};
-function yF(a,b,c){window.clipboardData&&window.clipboardData.setData(c,b)||(a=a.b,$m(a.De)&&a.hide(),a.Si&&W(a.De,a.Si),a.Si="html5-modal-panel-clipboard-substitute",V(a.De,a.Si),a.show(),a.Ce.value=b,a.Ce.focus(),H(v(a.dn,a),100))}f.Rr=function(a){zF(this.V,a.target.getAttribute("href"))};
-f.Sr=function(){var a=this.V.getVideoData(),b=this.V.J(),c=dx(b),d=Mv(b),e=Hl(a),e=e?xi(e):"",c={cr:b.S,csipt:a.Fc,ec:108,feature:b.k,h:d.height,hl:b.i,playerh:c.height,playerw:c.width,ptk:a.A,referrer:b.referrer,screenh:window.screen.height,screenw:window.screen.width,sdetail:a.fa,shost:Xi(e),sourceid:a.od,vid:b.$,vq:b.Dh,w:d.width};pa(c,this.V.uj());c.videoId&&(c.v=c.videoId,delete c.videoId);b.kc&&(c.mobile="1");this.V.qf("streamingerror",c);window.open(fx(a))};
-f.Pr=function(){yF(this,lg(this.V,!0),"Text")};f.Tr=function(){vg(this.V.P)};f.yu=function(a){a.preventDefault();$m(this.Zb)?a.stopPropagation():(tF(this.Zb,a),an(this.Zb),this.a.listen(this.Zb,"contextmenu",function(a){a.preventDefault()}),a=v(function(){this.a.listen(window,"blur",this.hide);fo(this.a,document,"down",this.hide)},this),H(a,0),this.a.listen(document,"keydown",this.Pv))};f.Pv=function(a){27==a.keyCode&&this.hide(a)};f.hide=function(a){bn(this.Zb);this.a.removeAll();a&&a.stopPropagation()};
-f.F=function(){this.g.removeAll();this.a.removeAll();this.V.W("internalvideodatachange",this.Vn,this);this.V=null;F(this.Zb);this.Zb=null;vF.C.F.call(this)};function AF(a,b){Sm.call(this,a,b);this.o=null;this.G=this.B=this.i=this.b=0;V(this.element,"ytp-tv-static");BF(this,a,b)}y(AF,Sm);function CF(a){for(var b=Math.floor(0.6*a),c=b;c<a;++c){for(var d=!1,e=2;e<Math.sqrt(c);e++){if(!(c%e)){d=!1;break}d=!0}if(d)return c}return b}
-function BF(a,b,c){if(b&&c){a.width=a.element.width=b;a.height=a.element.height=c;var d=document.createElement("canvas");d.width=b;d.height=c;for(var e=d.getContext("2d"),g=e.getImageData(0,0,b,c),h=b*c,k=0;k<h;k++){var m=4*k;g.data[m]=g.data[m+1]=g.data[m+2]=Math.floor(35*Math.random());g.data[m+3]=255}e.putImageData(g,0,0);a.o=d;a.B=CF(b);a.G=CF(c/10);a.X.scale(1.5,1.5)}}AF.prototype.show=function(){AF.C.show.call(this);var a=this.H;this.j=new Date;this.g(a,75)};
-AF.prototype.H=function(){var a=1-1/1.5;this.b=(this.b+this.B)%(this.width*a);this.i=(this.i+this.G)%(this.height*a);this.X.drawImage(this.o,-1*this.b,-1*this.i)};AF.prototype.hide=function(){I(this.a);AF.C.hide.call(this)};function DF(){Z.call(this,["div",["ytp-error","html5-stop-propagation"],["div","ytp-error-content",["div","ytp-error-content-wrap","{{content}}"]]]);this.b=[];if(void 0==wk){var a=document.createElement("canvas");wk=!(!a.getContext||!a.getContext("2d"))}wk&&(this.a=new AF(1,1),this.a.T(this.element,0),L(this,this.a))}y(DF,Z);DF.prototype.show=function(){var a=this.element;a&&(a.style.display="table");EF(this);this.a&&this.a.show()};DF.prototype.hide=function(){DF.C.hide.call(this);this.a&&this.a.hide()};
-function EF(a){a.a&&BF(a.a,a.element.clientWidth,a.element.clientHeight)}DF.prototype.F=function(){vf(this.b);this.b=[];DF.C.F.call(this)};function FF(){this.b=this.a=null}FF.prototype.getMsg=function(a,b,c){return J(a,b,c)};function pt(a,b,c,d){a.a&&GF(a.a,b,c,d)};function HF(a,b){var c;var d="followon_"+a;if(b.baseUrl&&b.uid){var e=b.rmktEnabled;c=b.focEnabled&&!b.isAd;if(e||c){d={label:c?d:"default"};if(e){e={utuid:b.uid,type:a};b.vid&&(e.utvid=b.vid);b.eventLabel&&(e.el=b.eventLabel);b.playerStyle&&(e.ps=b.playerStyle);b.feature&&(e.feature=b.feature);b.ppe&&(e.ppe=b.ppe);var g,h=[];for(g in e)h.push(encodeURIComponent(g)+"="+encodeURIComponent(e[g]));g=h.join(";");d.data=g}c&&"view"==a&&b.vid&&b.uid&&(b.oeid||b.ieid)&&(b.oeid&&(d.oeid=b.oeid),b.ieid&&(d.ieid=
-b.ieid),d.evid=b.vid);c&&(d.foc_id=b.uid);c=S(b.baseUrl,d)}else c=null}else c=null;c&&Kf(c)}function IF(a){var b=ef("CONVERSION_CONFIG_DICT");if(b){if(u(void 0)){var c=24==(void 0).length&&"UC"==(void 0).slice(0,2)?(void 0).substr(2):22==(void 0).length?void 0:null;if(b.uid!=c)return}HF(a,b)}};function JF(a,b,c){c=c||{};kj("watch_actions_ajax",c.Da,c.Ta,v(KF,l,a,b,c),c.onError)}
-function KF(a,b,c){var d={};0===b?d.action_like_video=1:1===b?d.action_dislike_video=1:d.action_indifferent_video=1;d.video_id=a;d.plid=c.ab;c.Na&&(d.list=c.Na);c.Da&&(d.authuser=c.Da);c.Ta&&(d.pageid=c.Ta);a={screen:Wi({h:screen.height,w:screen.width,d:screen.colorDepth}),session_token:gf("watch_actions_ajax")};c.wx&&(a.station_id=c.wx);ej("/watch_actions_ajax",{format:"XML",method:"POST",zf:d,Nf:a,Oa:c.Oa,onError:c.onError,td:c.td});0===b?IF("like"):1===b&&IF("dislike")};function LF(a,b,c,d,e){if(Zl(c,"html5-async-progress"))return null;X(c,"sentiment-like",b);X(c,"sentiment-dislike",!b);if(!a)return null;Ft(c,"html5-async-progress");c={ab:a.ab,Oa:function(a){return function(){Ft(a,"html5-async-success")}}(c),onError:function(a){return function(){Ft(a)}}(c)};d&&(c.authUser=d);e&&(c.pageId=e);JF(a.L,b?0:1,c);ef("CONVERSION_CONFIG_DICT")||HF(b?"like":"dislike",a.i);return b?0:1};function MF(a,b,c){nt.call(this,a,c.J(),b);this.V=c}y(MF,nt);f=MF.prototype;f.Rj=function(){MF.C.Rj.call(this);this.eb.listen(this.b.b,"click",this.fv);this.eb.listen(this.b.a,"click",this.ev);this.V.D("presentingplayerstatechange",this.Fo,this)};f.update=function(a){MF.C.update.call(this,a);!("watch_actions_ajax"in Ze)||this.V.g&&this.g.Ma?(a=this.b,a.b.hide(),a.a.hide()):(a=this.b,a.b.show(),a.a.show())};f.ai=function(a){var b=Cc(this.a,"show-share");this.u("share-click");b||MF.C.ai.call(this,a)};
-f.Fn=function(a){this.u("title-click",a)};f.ek=function(){var a=Cc(this.a,"show-more-info");this.u("info-click");if(a)this.B&&this.V.Ud();else{MF.C.ek.call(this);var b=xg(this.V);this.B=P(b,8)&&!P(b,2);this.V.Sd()}return!a};f.fv=function(){NF(this,!0)};f.ev=function(){NF(this,!1)};f.Fo=function(a){P(a.state,8)&&W(this.a,"show-more-info")};function NF(a,b){var c=LF(a.ia,b,a.a,a.g.Da,a.g.Ta);null!=c&&(0==c?a.b.o():a.b.j(),a.V.u("RATE_SENTIMENT",c))}f.Ki=function(a){zF(this.V,a)};
-f.F=function(){this.V.W("presentingplayerstatechange",this.Fo,this);this.V=null;MF.C.F.call(this)};function OF(a,b,c,d,e,g,h,k){this.j=[];z(jb(b),function(b){this.j.push(K(a,b,v(this.Cr,this)))},this);z(jb(d),function(b){this.j.push(K(a,b,v(this.Br,this)))},this);this.k=g||null;this.B=c;this.A=h||0;this.g=0;this.i=!1;this.G=e;this.o=k||0;this.a=0;this.b=!1}f=OF.prototype;f.Cr=function(a){I(this.a);this.a=0;this.g=H(v(this.wv,this,a),this.A)};f.Br=function(a){I(this.g);this.g=0;this.a=H(v(this.vv,this,a),this.o)};f.wv=function(a){this.b||this.i||(this.i=!0,this.B.call(this.k||l,a))};
-f.vv=function(a){!this.b&&this.i&&(this.i=!1,this.G.call(this.k||l,a))};f.dispose=function(){this.b=!0;I(this.g);I(this.a);vf(this.j)};f.ha=function(){return this.b};var PF=null,QF=null;function RF(){Z.call(this,["div","ytp-tooltip",["div","ytp-tooltip-body",["div","ytp-tooltip-content","{{content}}"]],["div","ytp-tooltip-arrow"]]);this.a=this.template.a["ytp-tooltip-body"];this.b=this.template.a["ytp-tooltip-content"]}y(RF,Z);RF.prototype.hide=function(){RF.C.hide.call(this);md(this.a,0)};function SF(a,b){X(a.b,"ytp-tooltip-content-text",!b.tagName);xm(a.template,"content",b)}RF.prototype.F=function(){Vc(this.b);this.b=this.a=null;RF.C.F.call(this)};function TF(a,b){this.a={};this.wl=a;this.hp=b}y(TF,Lf);
-function Pm(a,b,c){var d,e=new OF(b,"mouseover",function(){if(this.wl){var a=new RF;a.T(this.wl);d=a}else d=null;if(d&&(a=c&&c(b),!c||a)){a?SF(d,a):(a=G(b,"tooltip")||"",SF(d,Tc(a)));var e=!!G(b,"tooltip-below"),a=d,k=Ad(b),k=new B(k.width/2,e?k.height:0),m=sd(b),k=new B(m.x+k.x,m.y+k.y),e=!!e;X(a.element,"ytp-tooltip-below",e);if(m=qd(a.element))var p=sd(m),s=Hd(m),k=vb(k,new B(p.x+s.left,p.y+s.top));cr(k,a.element,e?1:0);a.show();var s=Ad(a.a),e=-1*(s.width/2),r=Nc(window),x=Oc(document),k=x.x,
-r=r.width+x.x,x=k,M=r;m&&(m=Ad(m),x=p.x,M=m.width+p.x);m=sd(a.a);p=m.x+e;m=m.x+s.width+e;p<Math.max(k,x)?e-=p-Math.max(k,x):m>Math.min(r,M)&&(e-=m-Math.min(r,M));md(a.a,e)}},["mouseout","mousedown"],function(){d&&(d.hide(),Nf(d),d=null)},a,10,50);a.a[ja(b)]=e}
-function GF(a,b,c,d){Pm(a,b,function(){var a=this.hp,b;if(a&&a.Ql){b=a.Ql;var h=a.Pp;PF||(PF=new ln(J("YTP_TOOLTIP_IDENTITY")),QF=new ln(J("YTP_TOOLTIP_IDENTITY_WATCH_LATER")));a=Sc("div");V(a,"ytp-identity-tooltip");var k=Sc("img");k.src=h;var h=Sc("span"),m=null;d?(V(h,"ytp-idt-watch-later"),m=[Tc(pn(QF,{user_name:""})),Sc("br"),Tc(b)]):m=Tc(pn(PF,{user_name:b}));Uc(h,m);Uc(a,k,h);b=a}else b=c;return b})}
-TF.prototype.F=function(){this.hp=this.wl=null;for(var a in this.a)Nf(this.a[a]);this.a={};TF.C.F.call(this)};function UF(a,b){this.k=a;this.i=[];this.o=b;this.j=[]}y(UF,Lf);function VF(a,b,c){a.i.push(a.k.D(b,c,a))}function WF(a,b,c){a.j.push(a.o.D(b,c,a))}function XF(a){for(var b=0;b<a.i.length;b++)a.k.Wc(a.i[b]);for(b=0;b<a.j.length;b++)a.o.Wc(a.j[b])}UF.prototype.F=function(){XF(this)};function YF(a,b){UF.call(this,a,b);this.g=!1;this.b=a;this.a=b;var c=a.J();c.color&&V(this.a.i,c.color);if(c.Fg){var d=this.a,e=E("html5-progress-tooltip",d.g);d.b=new eu;var g=d.b;g.Hb=e;g.Jh=E("html5-progress-tooltip-arrow",g.Hb);g.$j=E("html5-progress-tooltip-thumbnail",g.Hb);g.zj=E("html5-progress-tooltip-timestamp",g.Hb);L(d,d.b);d=this.a;d.a=new au;d.a.T(d.g);fo(d.k,d.a.M(),"down",d.Os);d.a.hide();L(d,d.a)}c.Gg&&(c=this.a,d=E("html5-storyboard",c.g),c.o=new Xt,e=c.o,g=c.hb.b.a?new C(c.hb.b.a.clientWidth,
-c.hb.b.a.clientHeight):new C(0,0),e.wd=d,e.Fe=g.width,e.$b=E("html5-storyboard-filmstrip",e.wd),e.Wh=E("html5-storyboard-lens",e.wd),e.Yj=E("html5-storyboard-lens-thumbnail",e.wd),e.Zj=E("html5-storyboard-lens-timestamp",e.wd),e.wg=E("html5-storyboard-thumbnail",e.$b),F(e.wg),L(c,c.o));ZF(this)}y(YF,UF);
-function ZF(a){XF(a);a.g=!0;VF(a,"cuerangesadded",a.Jw);VF(a,"cuerangesremoved",a.Kw);VF(a,"presentingplayerstatechange",a.Pw);VF(a,"progresssync",a.Qw);VF(a,"resize",a.Mw);VF(a,"seekto",a.Nw);VF(a,"videodatachange",a.Rw);VF(a,"videoplayerchange",a.Hp);VF(a,"videoready",a.Ow);WF(a,"beginseeking",a.Iw);WF(a,"endseeking",a.Lw);WF(a,"seekto",a.Hw)}f=YF.prototype;f.Jw=function(a){var b=O(this.b).getVideoData();!b||0>=b.wa||$F(this,a,b)};
-function $F(a,b,c){var d=c.wa;z(b,function(a){if(a.jl){var b=this.a;a=a.start/(1E3*d);a=tb(Math.round(100*a),0,100);if(!b.K[a]){var c=document.createElement("div");c.style.left=a+"%";$l(c,["html5-ad-progress","html5-progress-section"]);b.ua.appendChild(c);b.K[a]=c}}},a)}f.Kw=function(a){var b=O(this.b).getVideoData();if(b&&!(0>=b.wa)){var c=b.wa;z(a,function(a){if(a.jl){var b=this.a;a=a.start/(1E3*c);a=tb(Math.round(100*a),0,100);b.K[a]&&(F(b.K[a]),b.K[a]=null)}},this)}};
-f.Mw=function(a){if(this.a.o){var b=this.a.o;b.$c&&(b.Fe=a.width,Zt(b,!0))}};f.Nw=function(a){pu(this.a,a);if(this.a.o){var b=this.a.o;if(b.$c){b.Dk=b.fl*a-b.Fe/2;md(b.$b,-1*b.Dk);var c=mk(b.$c,a);Yt(b,c);Zc(b.Zj,Xm(b.Pe*a));Ar(b.a)}}};f.Pw=function(a){if(0>ao(a,16)){a=this.a;var b=this.b.getCurrentTime();a.gb.innerHTML=Math.floor(100*a.va)+"% at "+Math.floor(b)+" of "+Math.floor(a.B)+" seconds"}};f.Hp=function(a){1!=a.B?this.g&&(XF(this),this.g=!1,VF(this,"videoplayerchange",this.Hp)):this.g||ZF(this)};
-f.Rw=function(a,b,c){"newdata"==a&&(pu(this.a,(b.ya||0)/b.wa,0),a=this.a,Vc(a.ua),a.K={},(c=O(this.b,c))&&$F(this,c.A.i||[],b),this.a.b&&this.a.b.reset());this.a.Va(b.wa);this.a.b&&this.a.b.Va(b.wa);this.a.o&&this.a.o.Va(b.wa);c=this.a;c.ba=b.Mj;qu(c);c=this.a;c.ea=b.Qm;qu(c)};
-f.Ow=function(a){if(this.a.b){var b=this.a.b;if(!b.ii)if(Jl(a)){V(b.Hb,"with-thumbnail");b.Eg=Jl(a);b.hh=Kl(a);var c=v(b.Zu,b);b.hh.D("l",c)}else b.reset()}if(this.a.o&&(b=this.a.o,b.wg&&Vc(b.$b),W(b.wd,"enabled"),b.$c=Jl(a),b.Le=Kl(a),b.$c&&!b.Go)){V(b.wd,"enabled");a=v(b.Eo,b);b.Le.D("l",a);Zt(b);a=b.$b.cloneNode(!0);for(var c=b.$c.a[0].b,d,e,g=0;g<c;g++)e=b.wg.cloneNode(!1),d=Mk(b.Le,g,b.Lb),Wt(e,d,b.Lb,b.Ii),a.appendChild(e);c=b.$b;(d=c.parentNode)&&d.replaceChild(a,c);b.$b=a}};
-f.Qw=function(a,b,c){pu(this.a,b,c)};f.Iw=function(){Hy(this.b.b)};f.Lw=function(){this.b.b.ri()};f.Hw=function(a,b){Rf(this.b,a,b)};function aG(a,b){UF.call(this,a,b);VF(this,"applicationplayerstatechange",this.Qs);VF(this,"controlsdisabled",this.Ss);VF(this,"controlsenabled",this.Ts);VF(this,"liveviewshift",this.Ws);VF(this,"fullscreentoggled",this.Vs);VF(this,"presentingplayerstatechange",this.xt);VF(this,"progresssync",this.zt);VF(this,"threedenabled",this.kt);VF(this,"videodatachange",this.At);VF(this,"onPlaybackQualityChange",this.ft);VF(this,"onVolumeChange",this.lt);VF(this,"menu_add",this.Xs);VF(this,"menu_remove",this.Ys);
-WF(this,"fullscreentoggled",this.Us);WF(this,"mutetoggled",this.Zs);WF(this,"nextvideo",this.$s);WF(this,"playpausetoggled",this.ct);WF(this,"previousvideo",this.dt);WF(this,"qualitychanged",this.gt);WF(this,"sizechangerequested",this.ht);WF(this,"speedchanged",this.jt);WF(this,"volumechanged",this.nt);WF(this,"watchlater",this.wt);WF(this,"watchonyoutube",this.qt);WF(this,"controlclick",this.Rs);this.a=a;this.b=b;this.g=new YF(a,b.fk);L(this,this.g);var c=a.J();if(c.La){var d=this.b;d.Qc=new Os(d.b,
-"ytp-settings-button",d.b.getMsg("YTP_TOOLTIP_SETTINGS"),"ytp-settings-button-active");L(d,d.Qc);d.Qc.element.setAttribute("tabindex",10);var e=d.ud;e.parentNode&&e.parentNode.insertBefore(d.Qc.M(),e.nextSibling);F(d.ze);F(d.Vd);F(d.ud);Xc(d.wb).appendChild(d.wb);d.vb=new Rt;L(d,d.vb);d.vb.hide();d.vb.T(d.kg);d.a.listen(d.Qc,"click",d.ut);d.Uc=new yu(d.b);L(d,d.Uc);d.Uc.D("qualitychanged",v(d.u,d,"qualitychanged"));d.ce=new Jo(d.b,["ytp-size-control-small","ytp-size-control-large"],!0);d.a.listen(d.ce,
-"change",d.vt);L(d,d.ce);d.hk={label:d.b.getMsg("YTP_PLAYER_SIZE_TITLE"),element:d.ce,priority:0};d.de=new Du(d.b);L(d,d.de);d.de.D("speedchanged",v(d.u,d,"speedchanged"))}c.Tb&&(d=this.b,e=this.a.J().Od,d.hk?(Mo(d.ce,e?1:0),d.vb.add(d.hk)):(an(d.ze),an(d.Vd)));c.Ch&&this.b.i.show();c.jg&&(d=this.b,e=this.a.a.jg?Zf:[1],d.de?(Eu(d.de,e),d.vb.add(d.de)):an(d.vf));if(c.Ra)for(c=this.b,d=[c.Zc,c.tc,c.uf,c.g,c.ud,c.wb,c.tg,c.i,c.ze,c.Vd,c.Qc],e=0;e<d.length;e++)c.a.listen(d[e],"click",c.tt)}y(aG,UF);
-f=aG.prototype;f.Ss=function(a){this.b.disable(a)};f.Ts=function(a){this.b.enable(a)};f.Ws=function(a){X(this.b.g.element,"ytp-time-live-dvr",!a)};f.Vs=function(a){var b=this.b,c=this.a.J().Od;if(a){var d=b.i;Qm(d,"ytp-button-fullscreen-exit");var e=d.g.getMsg("YTP_BUTTON_FULLSCREEN_EXIT");Rm(d,e);d.a=e}else Qt(b.i);b.ce&&Mo(b.ce,a?-1:c?1:0)};f.xt=function(a){P(a.state,2)||(0<ao(a,8)?Pu(this.b,!0):0>ao(a,8)?Pu(this.b,!1):0>ao(a,2)&&Pu(this.b,P(a.state,8)));0>ao(a,16)&&bG(this,this.a.getCurrentTime())};
-f.Qs=function(a){if(P(a.state,2)){a=this.b.Zc;Qm(a,"ytp-button-replay");var b=a.g.getMsg("YTP_BUTTON_REPLAY");Rm(a,b);a.a=b}};f.kt=function(){var a=this.b,b=this.a.getVideoData().Jf,c=E("html5-threed-conversion-on",a.Vh),a=E("html5-threed-conversion-off",a.Vh);Zm(c,!b);Zm(a,b)};
-f.At=function(a,b){if(1==O(this.a).B){"newdata"==a&&(bG(this,b.ya||0),Ft(this.b.wb),Ru(this.b,"1.0"));this.b.Va(b.wa);Mu(this.b,Fl(b));var c=this.b,d=b.Fb,e=b.bb;c.bo=d&&!e;c=c.g;X(c.element,"ytp-time-liveonly",d&&!e);X(c.element,"ytp-time-live",d&&e);this.a.g&&"detailpage"!=this.a.J().Y?this.b.Ie.show():this.b.Ie.hide()}};f.ft=function(a){1==O(this.a).B&&Nu(this.b,a,cG(this.a))};
-f.lt=function(a){var b=this.b,c=a.volume;a=a.muted;Oe(b.tc,"value",a||0==c?"off":20>c?"min":40>c?"quiet":60>c?"normal":80>c?"loud":"max");Oe(b.tc,"volume",c);var d=b.ac.clientWidth-6,e=b.ac.style.backgroundPosition.split(" "),e=1<e.length?e[1]:"0px";if(a)b.ac.style.backgroundPosition="-"+d+"px "+e,b.yg.style.left="0px";else{var g;0>=c?g=0:100<=c?g=d:(g=(d-0)*c/100,g=0>=g?0:g>=d?d:0+Math.round(g));b.yg.style.left=g+"px";b.ac.style.backgroundPosition="-"+(d-g)+"px "+e}c=Math.round(c);d=c+"% "+J("HTML5_VOLUME_SETTING")+
-(a?" "+J("HTML5_VOLUME_MUTED"):"");b.uf.setAttribute("aria-valuenow",c);b.uf.setAttribute("aria-valuetext",d);c=b.tc;d=G(c,a?"tooltip-alt":"tooltip-default")||"";Oe(c,"tooltip",d);c.setAttribute("aria-label",d);b.tc.setAttribute("aria-label",(a?J("HTML5_VOLUME_UNMUTE"):J("HTML5_VOLUME_MUTE"))+" "+J("HTML5_CONTROL_TOGGLE"))};f.Xs=function(a){var b=this.b;b.vb&&b.vb.add(a)};f.Ys=function(a){var b=this.b;b.vb&&b.vb.remove(a)};f.zt=function(a){bG(this,a)};f.Us=function(){dG(this.a,!this.a.J().Ab)};
-f.Zs=function(){this.a.xa.muted?Tf(this.a):Sf(this.a)};f.$s=function(){ng(this.a)};f.ct=function(){eG(this.a)};f.dt=function(){og(this.a)};f.gt=function(a){"auto"==a&&Nu(this.b,$f(this.a),a);"auto"==cG(this.a)&&Nu(this.b,a,a);var b=O(this.a,1);b&&ag(b,"m",a)};f.ht=function(a){var b=this.a;dG(b,!1);a!=b.a.Od&&(b.a.Od=a,b.u("SIZE_CLICKED",a),b.P.Gi())};f.jt=function(a){Yf(this.a,a)};f.nt=function(a){fG(this.a,a)};f.qt=function(){zF(this.a,kg(this.a,!0))};f.Rs=function(a){xF(this.a,a)};
-f.wt=function(){kj("addto_ajax",this.a.J().Da,this.a.J().Ta,v(this.Jv,this),v(this.dp,this))};
-f.Jv=function(){var a={Dv:"WL",xb:this.a.getVideoData(1).L,Da:this.a.J().Da,Ta:this.a.J().Ta,Oa:this.Ev,onError:this.dp,X:this},b={video_ids:a.xb,playlist_id:a.Na||"",new_playlist_name:a.Fv||"",session_token:gf("addto_ajax")},c=ef("PLAYBACK_ID");c&&(b.plid=c);c={};a.privacy&&(c.privacy=a.privacy);a.Cv&&(c.feature=a.Cv);a.Da&&(c.authuser=a.Da);a.Ta&&(c.pageid=a.Ta);var d="";switch(a.Dv){case "PL":d=a.Fv?"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;ej("/addto_ajax",{Bv:!0,format:"XML",method:"POST",zf:c,Nf:b,X:a.X,onError:a.onError,Oa:a.Oa})};f.Ev=function(){Ft(this.b.wb,"html5-async-success");this.a.u("WATCH_LATER")};f.dp=function(a,b){var c=this.b.wb,d=b&&b.error_message;Ft(c,"html5-async-error");if(d){var e=Us.getInstance(),g=Ws(c);Ys(c,d);Vs(e,c);lr(c,g)}};function bG(a,b){1==O(a.a).B&&xm(a.b.g.template,"current",Xm(b))};var gG={0:"autohide-off",1:"autohide-on",2:"autohide-fade",3:"autohide-auto",4:"autohide-embeds",5:"autohide-seekbar"};function hG(a){kF.call(this,a);this.O=this.o=this.N=this.Ia=this.B=this.da=this.ca=this.$=this.I=this.H=this.k=this.i=null;this.ra=!1;this.oa=this.A=null;this.za=!0;this.ua=this.K=!1;a=this.app.J().Gb?4E3:3E3;this.ba=new ho(this.ak,a,this);L(this,this.ba);this.ba.start()}y(hG,kF);f=hG.prototype;
-f.ok=function(){hG.C.ok.call(this);this.app.D("appstatechange",this.kx,this);this.app.D("applicationplayerstatechange",this.lx,this);this.app.D("clearvideooverlays",this.px,this);this.app.D("initializingmode",this.nx,this);this.app.D("presentingplayerstatechange",this.mx,this);this.app.D("onDetailedError",this.ox,this)};
-f.xj=function(){var a=this.app.K.assets;if(a.css&&!zk()){var b={rel:"stylesheet",type:"text/css",href:a.css},c=document.getElementById("www-player-css");b.id="www-player-css";var d=c||document.createElement("link");Lc(d,b);c||document.getElementsByTagName("head")[0].appendChild(d);this.gp(200)}else this.ra=!0;hG.C.xj.call(this)||ej(a.html,{format:"RAW",method:"GET",Oa:v(this.rx,this)});return!0};
-f.rx=function(a){if(a.responseText){var b=Sc("div");b.innerHTML=a.responseText;mF(this,E("html5-video-player",b));this.u("templateready")}else this.u("templateerror")};f.gp=function(a){0>=a||zk()?(this.ra=!0,this.a&&ym(this.a)):H(v(this.gp,this,a-1),50)};
-f.yj=function(){hG.C.yj.call(this);this.ra||zm(this.a);iG(this);var a=this.app.J();a.U&&this.addClass(a.U+"-theme");a.nf&&this.addClass("house-brand");!a.of&&a.ve||this.addClass("modest-branding");a.oj&&this.addClass("html5-hide-share");a.om||this.addClass("html5-hide-volume");a.Gb&&(this.addClass("html5-tablet"),V(document.body,"html5-tablet-body"));a.Wb||this.addClass("hide-info-bar");a.Gb||a.Ub||this.addClass(gG[a.Bh]);var b=yb(new C(this.a.clientWidth,this.a.clientHeight)).toFixed(1);"1.3"!=b&&
-"1.8"!=b||this.addClass("autohide-aspect");a.Tb&&this.tf();this.H=E("html5-watermark",this.a);jG(this.app)&&an(this.H);a.ve&&!a.Ub&&(this.B=new Ju(this.A),Ku(this.B,this.ea),L(this,this.B),this.Ia=new aG(this.app,this.B),L(this,this.Ia));var b=E("html5-context-menu",this.a),c=E("html5-modal-panel",this.a),d=this.N=new vF(this.app);d.Zb=b;F(d.Zb);document.body.appendChild(d.Zb);var e=d.b;e.De=c;e.Tj=E("html5-modal-panel-close-button",c);e.Sj=E("html5-modal-panel-clipboard-substitute-content",c);e.Ce=
-Ue("input",e.Sj);cc&&e.Ce.removeAttribute("readonly");e.a.listen(document,"keydown",e.Or);e.a.listen(c,"contextmenu",e.Nr);fo(e.a,e.Tj,"down",e.Mr);fo(e.a,e.Ce,"down",e.dn);var c={Fr:d.Pr,Gr:d.Qr,Hr:v(d.hn,d,!1),Ir:v(d.hn,d,!0),Kr:d.Sr,Lr:d.Tr,Jr:d.Rr},g;for(g in c)wF(d,g,c[g]);L(this,this.N);a.nf&&V(b,"house-brand");this.k=new it(2);V(this.k.element,"html5-video-loader");V(this.k.element,"html5-center-overlay");V(this.k.element,"ytp-scalable-icon-grow");this.k.T(this.g);L(this,this.k);g=E("html5-info-bar",
-this.a);this.o=new MF(g,this.A,this.app);this.o.Rj();L(this,this.o);this.I=new TE(a.kc);this.I.T(this.g);L(this,this.I);this.$=new RE;this.$.T(this.g);L(this,this.$);kG(this)};f.zl=function(a){hG.C.zl.call(this,a);lG(this,a);this.i&&EF(this.i)};f.xk=function(){hG.C.xk.call(this);lG(this,nF(this))};f.Ll=function(a,b){hG.C.Ll.call(this,a,b);"newdata"==a&&this.o.reset();this.o&&this.o.update(b);if(jG(this.app)){var c=b.Ma;c&&(this.H.src=c);an(this.H)}};
-f.kx=function(a){2==a?mG(this):(this.I.hide(),this.removeClass("cued-mode"));3==a?this.k.show():P(xg(this.app),1)||this.k.hide()};
-f.mx=function(a){var b;b=a.state;if(P(b,2))b=["ended-mode"];else{var c=[];P(b,8)?c.push("playing-mode"):P(b,4)&&c.push("paused-mode");P(b,1)&&!P(b,32)&&c.push("buffering-mode");P(b,32)&&c.push("seeking-mode");P(b,64)&&c.push("unstarted-mode");b=c}this.oa&&am(this.a,this.oa);$l(this.a,b);this.oa=b;P(a.state,1)?this.k.show():0>ao(a,1)&&this.k.hide();this.za=P(a.state,8)&&!P(a.state,4);0>ao(a,64)&&nG(this.app)};f.lx=function(a){P(a.state,2)?mG(this):0>ao(a,2)&&(this.I.hide(),this.removeClass("cued-mode"))};
-function kG(a){var b=a.app.J();if(b.um){if(b.Gb){var c=v(function(a){return oG(a)||Zl(a.target,"html5-draggable")},a);a.O=new Gt(a.a,v(function(a){Zl(this.a,"cued-mode")?Nm.hasTags(void 0)&&this.mo(a):oG(a)&&(this.K?this.Sk():this.ak(),this.B&&(a=mr.getInstance(),a.Ef&&rr(a,a.Ef)))},a),!1,c);K(a.a,"gesturechange",v(a.Bu,a));K(a.a,"gestureend",v(a.Cu,a))}else K(a.a,"click",v(a.mo,a)),K(a.a,"dblclick",v(a.Au,a)),K(a.a,"click",v(a.Sk,a)),K(a.a,"mousemove",v(a.Sk,a)),K(a.a,"mouseout",v(a.ak,a));var d=
-v(function(){var a=this.b;a&&(wi(a),Nm.fillPool(4),b.Gb&&Kt(),(a=tf(this.a,"click",d,!0))&&vf(a))},a);K(a.a,"click",d,!0);K(a.a,"keypress",v(a.Eu,a));K(a.a,"keydown",v(a.zu,a));c=v(a.N.yu,a.N);qi&&a.O?a.O.o=c:K(a.a,"contextmenu",c);K(a.H,"click",v(a.no,a));a.o.D("title-click",v(a.no,a));a.o.D("share-click",v(a.Fu,a));a.o.D("info-click",v(a.Du,a))}}f.mo=function(a){var b=this.app.J();oG(a)&&(this.a.focus(),!Zl(this.a,"cued-mode")&&b.Ub||eG(this.app,!0));xF(this.app,"screenclick")};
-f.Au=function(a){6!=this.app.o&&(oG(a)&&(a=this.app,dG(a,!a.a.Ab)),xF(this.app,"screendoubleclick"))};f.Bu=function(a){var b=a.scale,c=this.app.J().Ab;b*(c?-1:1)>(c?-0.7:1.3)&&(b=this.app,dG(b,!b.a.Ab));a.preventDefault()};f.Cu=function(a){a=a.scale;var b=this.app.J().Ab;a*(b?-1:1)>(b?-0.9:1.1)&&(a=this.app,dG(a,!a.a.Ab))};function oG(a){return!ed(a.target,"html5-stop-propagation")}
-f.Eu=function(a){var b=a.keyCode;if(179==b||178==b)179==b&&(this.u("playpausetoggled",!0),a.preventDefault()),178==b&&(Vf(this.app),a.preventDefault());98==b&&this.app.af("onBackgroundChange");111==b&&this.app.af("onTextOpacityChange");119==b&&this.app.af("onWindowOpacityChange");61!=b&&43!=b||this.app.af("onFontSizeIncrease");45!=b&&95!=b||this.app.af("onFontSizeDecrease");32==b&&oG(a)&&(eG(this.app,!0),a.preventDefault());48<=b&&57>=b&&(Rf(this.app,(b-48)/10*Fg(this.app)),a.preventDefault())};
-f.zu=function(a){var b=a.keyCode;if(38==b||40==b||37==b||39==b){var c=5;a.ctrlKey&&(c*=2);if(38==b)c=this.app,fG(c,{volume:c.xa.volume+5,muted:!1});else if(40==b)c=this.app,fG(c,{volume:c.xa.volume-5,muted:!1});else if(37==b){var d=this.app,c=-1*c;Rf(d,d.getCurrentTime()+c,!1,250,void 0)}else 39==b&&(d=this.app,Rf(d,d.getCurrentTime()+c,!1,250,void 0));a.preventDefault()}36==b&&(Rf(this.app,0),a.preventDefault());35==b&&(Rf(this.app,Infinity),a.preventDefault());27==b&&(dG(this.app,!1),a.preventDefault())};
-f.no=function(a){a.preventDefault();a=this.app;var b;b=a.getVideoData();b=b.Oc||ot(a.a,b);zF(a,b)};f.Fu=function(){this.app.Gh();dG(this.app,!1);var a=this.app,b=a.getVideoData();a.u("SHARE_CLICKED",{videoId:b.L,listId:b.Na,feature:"player_"+a.a.Y})};f.Du=function(){this.app.Gh()};f.px=function(){var a=this.o;W(a.a,"show-share");W(a.a,"show-more-info")};f.Sk=function(){this.ua=!0;this.ba.start();this.K&&(this.K=!1,this.removeClass("hide-controls"),this.app.cb("onShowControls"))};
-f.ak=function(){this.ua=!0;this.ba.stop();if(!this.K){var a;if(a=this.B){a=this.B;var b=mr.getInstance();a=!!b.Ef&&Te(b.Ef,a.kg)||null!=a.j}b=(b=dg(this.app.k,"playlist"))&&b.Z;this.za&&this.ua&&!a&&!b&&(this.K=!0,this.addClass("hide-controls"),this.app.cb("onHideControls"))}};function mG(a){a.I.show(a.app.getVideoData());a.addClass("cued-mode")}f.Bj=function(){var a=Jc("html5-popup-dialog",this.a);z(a,function(a){bn(a)},this)};
-f.ox=function(a){this.i||(this.i=new DF,this.i.T(this.a),L(this,this.i));var b=this.app.J(),c=a.message;a=a.messageKey;if(!b.nf&&"HTML5_DEFAULT_FALLBACK"==a){c+=J("LEARN_MORE");a=this.i;for(var d=v(this.app.qf,this.app,"",{errorHelpClick:1}),e=a.element.getElementsByTagName("a"),g=0;g<e.length;g++)a.b.push(K(e[g],"click",d));this.app.qf("",{errorHelpShown:1})}a=this.i;b="embedded"==b.Y;vf(a.b);a.b=[];xm(a.template,"content",new xu(c));if(b)for(b=a.element.getElementsByTagName("a"),c=0;c<b.length;c++)b[c].setAttribute("target",
-"_blank");this.i.show()};f.nx=function(){this.i&&this.i.hide()};f.Ip=function(a){var b=this.$;b.show(a);H(oa(V,b.element,"html5-bezel-fade"),0);b.a=H(v(b.hide,b),300)};f.Ko=function(a){E("html5-viewport-sheet").disabled=!a};f.tf=function(){var a=this.app.J();Oe(document.body,"player-size",a.Ab?"fullscreen":a.Od?"large":"small");hG.C.tf.call(this)};
-function pG(a,b){var c="scale("+a+") !important;";b&&(c="translate(-50%, -50%) "+c);return["transform: "+c,"-webkit-transform: "+c,"-moz-transform: "+c,"-o-transform: "+c,"-ms-transform: "+c]}function lG(a,b){if(!b.isEmpty()){var c=b.width,d=b.height,e=0,g=0;c/d>480/360?(e=d,g=360):(e=c,g=480);c=tb(e/g,0.5,1);d={Ib:a.ca,reset:!0};a.ca=Em(".ytp-scalable-icon-shrink",pG(c,!1),d);c=tb(0.33*(e/g),0.5,1);d={Ib:a.da,reset:!0};a.da=Em(".ytp-scalable-icon-grow",pG(c,!0),d)}}
-f.Cj=function(a){this.B&&Pu(this.B,a)};function iG(a){a.A=new FF;a.A.b=a;var b=new TF(a.a,a.app.J());L(a,b);a.A.a=b;a=Jc("ytp-tooltip-anchor",a.a);z(a,function(a){Pm(b,a)})}f.F=function(){this.k.hide();Fm(this.ca);Fm(this.da);Af(this.a);Af(this.H);Nf(this.O);hG.C.F.call(this);this.H=this.I=this.da=this.ca=this.O=this.$=null};function ig(a,b,c,d){"string"==typeof a&&(a={mediaContentUrl:a});var e=a,g=/\/([ve]|embed)\/([^#?]+)/.exec(a.mediaContentUrl);e.video_id=g&&g[2]?g[2]:null;return fg(a,b,c,d)}function fg(a,b,c,d){b={endSeconds:void 0,list:b,mediaContentUrl:void 0,startSeconds:c,suggestedQuality:d,video_id:a};if(ia(a)){for(var e in b)b[e]=b[e]||a[e];b.video_id=a.video_id||a.videoId}return b};function qG(){this.a={};this.i=this.j=NaN;this.B=0;this.A=!0}var rG={"-1":"N",3:"B",0:"EN",2:"PA",1:"PL"};function Fy(a){return(w()-a.B)/1E3}
-qG.prototype.k=function(){var a={},b;for(b in this.a)0<this.a[b].length&&(a[b]=this.a[b].join(","),this.a[b]=[]);if(!Ib(a)){var c={},d=Fy(this);if(!isNaN(d)){d=d.toFixed(3);if(this.o){var e=this.o.g,g=this.o.i;0<e&&(a.bwm=d+":"+e+":"+g.toFixed(3));e=this.o;e.i=0;e.g=0}e=gx(this.g);"hmewdrop"in e&&(a.df=d+":"+e.hmewdrop)}c.event="streamingstats";this.b.a&&(c.fmt=this.b.a.Sa);c.cpn=this.b.Ca;c.ei=this.b.j;c.docid=this.b.L;c.ns=this.g.Vb;this.g.j&&(c.adformat=this.g.j);this.b.Fb&&(c.live=this.b.bb?"dvr":
-"live");c.html5="1";c=S(ax(this.g)+"stream_204",c);for(b in a)c+="&"+b+"="+a[b];Kf(c);sG(this)}tG(this)};function uG(a){vG(a);wG(a);for(var b in a.a)a.a[b]=[]}qG.prototype.onError=function(a){var b=Fy(this);isNaN(b)||this.a.error.push(b.toFixed(3)+":"+a+":"+this.b.ue.toFixed(3))};function tG(a){vG(a);a.j=jf(v(a.k,a),1E4)}function vG(a){isNaN(a.j)||(kf(a.j),a.j=NaN)}function sG(a){wG(a);a.i=jf(v(a.H,a),3E4)}function wG(a){isNaN(a.i)||(kf(a.i),a.i=NaN)}
-function Gy(a,b,c){void 0!=c&&(a.a.vps.push(b.toFixed(3)+":"+c),a.G=c)}qG.prototype.H=function(){if("PL"==this.G){var a=Fy(this);isNaN(a)||(Gy(this,a,this.G),this.k())}};function xG(a,b,c,d){c=c||"";this.i=[];this.j=[];this.H=[];this.B="watchtime"==c;this.pd=ax(b)+"api/stats/"+c;d&&(this.gm=d.fs,this.R=d.nbe,this.S=d.bc,this.U=d.bd,this.Lc=d.bt,d.rtn&&(this.k=d.rtn),this.B?(this.oa=d.state,0<d.rti&&(this.o=d.rti)):(this.ca=d.mos,this.rb=d.volume,d.at&&(this.K=d.at),d.allowed&&(this.O=d.allowed),d.ex_ads&&(this.da=d.ex_ads)));this.I=b.j;this.yh=b.Sb;this.$=b.o;this.Pc=b.G;this.La=b.A;this.Ra=b.B;this.gb=b.eg;this.hb=b.jf;this.qb=b.H;this.Nc=b.I;this.Hc=b.K;this.Dc=
-b.N;this.Gc=b.O;this.b=b.b;this.Ec=b.Y;this.H=b.g;this.ea=b.ea;this.Ic=b.i;this.im=b.Vb;this.Fc=b.Ja;this.referrer=b.referrer;this.Jc=b.S;this.A=b.k;this.nd=b.oa;this.ua=b.ra;this.va=b.ua;this.od=hx(b);!a.a||a.da.isEmpty();this.yh=a.hf||this.yh;this.za=a.Ca;this.Ia=a.ue;this.ba=a.K;this.Ma=a.La;this.a=a.a;this.hm=a.Nd;this.Oc=a.cg;a.Fb&&(this.fa=a.bb?"dvr":"live");this.Mc=a.uh;this.qd=a.qd;this.ab=a.ab;this.Kc=a.j;this.Na=a.Na;this.A=a.ea||this.A;this.ra=a.oa;this.g=a.g;this.L=a.L}f=xG.prototype;
-f.yh=!1;f.nj=!1;f.km=!1;f.gm=!1;f.fg=!1;f.hm=!1;f.im="yt";f.cq=!1;f.send=function(){if(!this.cq){var a=this.xi(),a=S(this.pd,a);Kf(a);this.cq=!0}};
-f.xi=function(){var a={ns:this.im,el:this.Ec,hl:this.Ic,cr:this.Jc,cpn:this.za,docid:this.L,ver:2,referrer:this.referrer,cmt:this.Ae(this.Ia),plid:this.ab,ei:this.Kc,fmt:this.a?this.a.Sa:0,fs:this.gm?"1":"0",rt:this.Ae(this.N),c:this.gb,cver:this.hb,subscribed:this.g,lact:this.od,cplatform:this.Gc,cbrand:this.Pc,cmodel:this.qb,cnetwork:this.Nc,cbr:this.La,cbrver:this.Ra,cos:this.Hc,cosver:this.Dc,q:this.nd};this.yh&&(a.autoplay="1");this.km&&(a["final"]="1");this.hm&&(a.splay="1");this.ij&&(a.ssrt=
-"1");this.ba&&(a.delay=this.ba);this.I&&(a.adformat=this.I);this.$&&(a.content_v=this.$);void 0!=this.ua&&this.va&&(a.uga=this.va+this.ua);void 0!=this.G&&(a.len=this.Ae(this.G));!this.B&&0<this.H.length&&(a.fexp=this.H.toString());void 0!=this.ca&&(a.mos=this.ca);void 0!=this.rb&&(a.volume=this.rb);void 0!=this.oa&&(a.state=this.oa);void 0!=this.k&&(a.rtn=this.Ae(this.k));this.A&&(a.feature=this.A);this.Na&&(a.list=this.Na);this.ra&&(a.ytr=this.ra);this.B?(a.idpj=this.Oc,a.ldpj=this.Mc,void 0!=this.o&&
-(a.rti=this.Ae(this.o))):(void 0!=this.K&&(a.at=this.K),void 0!=this.O&&(a.allowed=this.O),void 0!=this.da&&(a.ex_ads=this.da));void 0!=this.fa&&(a.live=this.fa);this.ea||(a.ps=this.Fc,a.sw=this.Ma,this.S&&(a.bc=this.S),this.U&&(a.bd=this.U,a.bt=this.Lc),0<this.R&&(a.nbe=this.R));!this.fg&&0<this.i.length&&(a.st=this.i.map(this.Ae).join(","),a.et=this.j.map(this.Ae).join(","));return a};f.Ae=function(a){return(1*a.toFixed(3)).toString()};function yG(a,b,c,d){this.i=[];this.j=[];this.A=[];this.jm=b.fj;c&&(this.R=c.nbe,this.S=c.bc,this.U=c.bd,this.Kc=c.bt,this.$l=c.fs,this.am=c.mos,this.ij=c.ssrt,this.source=c.sourceid,this.za=c.sd,this.sq=c.hmewadbc,this.va=c.hmewdfc,this.tq=c.hmewdrop,this.uq=c.hmewvdbc,this.Fc=c.hmemdf,this.Jc=c.hmempaintdelay,this.nd=c.hmempainted,this.fa=c.hmempf,this.pd=c.hmempresented,this.te=c.volume);this.lj=b.lj;this.xh=b.Sb;this.$=b.o;this.La=b.G;this.Ra=b.A;this.gb=b.B;this.hb=b.eg;this.qb=b.jf;this.Nc=
-b.H;this.Hc=b.I;this.Dc=b.K;this.Gc=b.N;this.Lc=b.O;this.b=b.b;this.Oc=b.Y;this.A=b.g;this.Ic=b.R;this.Mc=b.i;this.dm=b.Vb;this.dg=b.dg?"1":void 0;this.I=dx(b);this.od=b.Ja;this.referrer=ex(b);this.hj=b.S;this.B=b.k;this.K=new C(window.screen.width,window.screen.height);this.fj=b.oa;this.oa=b.ra;this.rb=b.ua;this.Yl=hx(b);this.O=Mv(b);this.ua=b.hb;this.Ul=b.$;!a.a||a.da.isEmpty();this.xh=a.hf||this.xh;this.Ia=a.Ca;this.Ma=a.Fc;this.ea=a.K;this.Pc=a.La;this.a=a.a;this.bm=a.Nd;this.ba=a.cg;a.Fb&&(this.da=
-a.bb?"dvr":"live");this.ca=a.uh;this.qd=a.qd;this.ab=a.ab;this.Ec=a.j;this.Na=a.Na;this.bg=a.fa;this.B=a.ea||this.B;this.jj=a.oa;this.fm=a.gj;this.g=a.g;this.Zl=a.Jc;this.L=a.L;this.ra=a.da;this.H=d||[]}f=yG.prototype;f.xh=!1;f.nj=!1;f.$l=!1;f.fg=!1;f.am=!1;f.bm=!1;f.ij=!1;f.dm="yt";f.fm=!1;f.iq=!1;f.send=function(){if(!this.iq){var a=this.xi(),a=S(this.jm,a);Kf(a);this.iq=!0}};
-f.xi=function(){var a={html5:"1",ns:this.dm,ps:this.od,el:this.Oc,hl:this.Mc,cr:this.hj,c:this.hb,cpn:this.Ia,docid:this.L,sd:this.za,sourceid:this.source,referrer:this.referrer,q:this.fj,plid:this.ab,ei:this.Ec,fmt:this.a?this.a.Sa:0,fs:this.$l?"1":"0",screenw:this.K.width,screenh:this.K.height,w:this.O.width,h:this.O.height,vw:this.ra.width,vh:this.ra.height,playerw:this.I.width,playerh:this.I.height,vid:this.Ul,rt:this.Eh(this.N),mos:this.am,volume:this.te,app:this.lj,csipt:this.Ma,on3g:this.dg,
-partnerid:this.qd,sdetail:this.bg,subscribed:this.g,sw:this.Pc,list:this.Na,eurl:this.b,framer:this.Ic,feature:this.B,ytr:this.jj,threed:this.Zl,lact:this.Yl,cver:this.qb,cplatform:this.Lc,cbrand:this.La,cmodel:this.Nc,cnetwork:this.Hc,cbr:this.Ra,cbrver:this.gb,cos:this.Dc,cosver:this.Gc};this.fg&&(a.playback="1");this.xh&&(a.autoplay="1");this.bm&&(a.splay="1");this.ij&&(a.ssrt="1");this.ea&&(a.delay=this.ea);this.fm&&!this.fg&&(a.vtmp="1");this.nj&&(a.tv="1");this.$&&(a.content_v=this.$);void 0!=
-this.oa&&this.rb&&(a.uga=this.rb+this.oa);void 0!=this.G&&(a.len=this.Eh(this.G));0<this.A.length&&(a.fexp=this.A.toString());0<this.ba&&(a.idpj=this.ba);0<this.ca&&(a.ldpj=this.ca);void 0!=this.ua&&(a.attrib=this.ua);void 0!=this.da&&(a.live=this.da);this.S&&(a.bc=this.S);this.U&&(a.bd=this.U,a.bt=this.Kc);0<this.R&&(a.nbe=this.R);void 0!=this.va&&(a.hmewdfc=this.va,a.hmewdrop=this.tq,a.hmewvdbc=this.uq,a.hmewadbc=this.sq);void 0!=this.fa&&(a.hmempf=this.fa,a.hmemdf=this.Fc,a.hmempresented=this.pd,
-a.hmempainted=this.nd,a.hmempaintdelay=this.Jc);0<this.i.length&&(a.st=this.i.map(this.Eh).join(","),a.et=this.j.map(this.Eh).join(","));for(var b=0;b<this.H.length;b++)Cb(nA(this.H[b]),function(b,d){d in a||(a[d]=b)});return a};f.Eh=function(a){return(1*a.toFixed(3)).toString()};function zG(){this.o=[];this.k=[];this.G=[10,10,10,40];this.j=new qG;this.B="paused";this.g=this.I=0;this.N=!1}y(zG,Lf);f=zG.prototype;f.we=NaN;f.Fl=0;f.In=0;f.Pj=null;f.Sm=null;f.Om=function(){return[]};f.lf=null;f.lm="";f.Rc=0;f.bp=0;f.Lo=!1;f.tj=0;f.pf=0;f.Pg=0;f.mg=0;function AG(a){var b=a.Sm();a.Pj&&pa(b,a.Pj());return b}
-f.rj=function(a){this.Fl=Math.min(this.Fl+1,this.G.length-1);var b=this.G[this.Fl];this.I=this.g;a&&(this.g=(w()-this.pf)/1E3);this.g+=b;a=Ly(this,"watchtime");a.k=this.g;a.o=this.I;BG(this);Oy(this,a);My(this);this.we=jf(v(this.rj,this),1E3*b)};function My(a){isNaN(a.we)||(kf(a.we),a.we=NaN)}f.Bq=function(){var a=this.lf(),b=(w()-this.pf)/1E3,c=a-this.Rc;if(0!=c){var d=b-this.tj;if(0>c||c>d+0.2)BG(this),this.mg=a;this.tj=b}this.Rc=a};
-function BG(a){if(400<a.In)My(a);else if(3<a.Rc-a.mg||a.b.ba)a.o[a.Pg]=a.mg,a.k[a.Pg]=a.Rc,a.Pg++,a.mg=a.Rc}function Ly(a,b){var c=AG(a),d=a.Om();a.b.ba?(pa(c,{state:a.B}),z(d,function(a){pa(c,nA(a))}),d=new xG(a.a,a.b,b,c)):d=new yG(a.a,a.b,c,d);d.N=(w()-a.pf)/1E3;d.G=a.K();return d}
-function Ny(a){var b=a.b;a=a.a;var c=a.ea||b.k,c={ns:b.Vb,html5:"1",el:b.Y,ps:b.Ja,fexp:b.g.join(",")||void 0,feature:c||void 0,ytr:a.oa||void 0,list:a.Na,d:b.va,f:b.da};b.Sb&&(c.autoplay="1");a.g&&(c.subscribed=a.g);return c}function py(a){a.pf=w();a=a.j;uG(a);a.a.vps.push("0.000:N");a.B=w();tG(a);sG(a)}f.onError=function(a){this.j.onError(a)};
-function Qy(a,b){P(b.state,8)?(a.B="playing",a.i&&!a.we&&a.a.ig&&a.rj(!0)):a.B="paused";if(P(b.state,2)){My(a);var c=Ly(a,"watchtime");c.o=null;c.k=null;BG(a);Oy(a,c)}var c=a.j,d=b.state;t:{var e=Fy(c);if(!isNaN(e)){var g=b.state,h;if(!P(g,32)&&0<ao(b,16)||0<ao(b,32)){if(P(b.a,32))break t;h="S"}P(g,128)&&(h="ER");h||(h=rG[Ki(g)],"B"==h&&P(g,4)&&(h="PB"));null!=h&&Gy(c,e,h)}}P(d,8)&&(isNaN(c.j)&&tG(c),isNaN(c.i)&&sG(c));if(0<ao(b,256)||P(d,128))c.onError(d.a.errorCode);(P(d,2)||P(d,128))&&c.k()}
-function Oy(a,b){if(b||0<a.Pg&&a.a.ig){var c=b||Ly(a,"watchtime"),d=!0;a.o.length&&a.k.length&&(c.i=a.o,c.j=a.k,d=c.i[c.i.length-1]==c.j[c.j.length-1]);a.Lo&&d||(d&&(c.k=null),c.send(),a.In++);a.Lo=d;a.o=[];a.k=[]}a.Pg=0}function yy(a,b,c){b.rt=(w()-a.pf)/1E3;pa(b,AG(a));a=S("streamingerror"==b.event?"//s.youtube.com/stream_204":a.b.ib+"player_204",Ny(a));a=S(a,b);Kf(a,c)}
-function uy(a,b){var c=a.b,d=a.a,e={ns:c.Vb,el:c.Y,eurl:c.b,fmt:d.a?d.a.Sa:0,html5:1,list:d.Na,plid:d.ab,ei:d.j,ps:c.Ja,noflv:1,st:a.lf(),video_id:d.L};c.Sb&&(b.autoplay="1");d.kj&&(b.tmi="1");pa(e,b);pa(e,bx(c));Kf(S("//www.youtube.com/live_204",e))}f.log_=function(){};f.F=function(){zG.C.F.call(this);My(this);void 0!=this.A&&kf(this.A)};function CG(a,b,c){R.call(this);this.o=1;this.$={};this.D("openingpage",v(this.Qq,this));this.D("initializingmode",v(this.Nq,this));this.D("internalenvironmentdatachange",v(this.Mq,this));this.D("internalvolumechange",v(this.ym,this));this.K=null;b instanceof Ef||(b=new Ef(b));this.K=b;b=this.K.args;Nf(this.a);this.a=new Ww(b||{});this.u("internalenvironmentdatachange","newdata");this.ba=Yw(this.a)?new yg(this,1):new Pf(this,1);L(this,this.ba);this.U=new Gg(this);L(this,this.U);this.I=new Gg(this,
-1);L(this,this.I);this.R={};this.da=Nb(["internalvideodatachange",this.Gq,"liveviewshift",this.Oq,"commoninfoloaded",this.Lq,"playbackready",this.Hq,"playbackstarted",this.Iq,"statechange",this.Jq,"videoelementevent",this.er]);this.fa=new hh(this.a);this.k=new tw;L(this,this.k);this.b=null;b=new gy(this.a,1);if(this.b!=b){if(this.b){var d=this.b,e=this.da,g;for(g in e)d.W(g,e[g],this)}b.ea=this.fa;g=this.da;for(var h in g)b.D(h,g[h],this);this.b=b}this.ca=Nb(["beginseeking",this.Kq,"endseeking",this.ar,
-"internalvideodatachange",this.Hm,"internalvideoformatchange",this.Yq,"progresssync",this.Uq,"seekto",this.Vq,"onLoadProgress",this.Pq,"onVideoProgress",this.Zq,"newlicensesession",this.br,"playbackdataloaded",this.Sq,"playbackready",this.Rq,"statechange",this.Tq]);this.j=null;qz(this,this.b);this.ea=-1;this.H=this.A=null;this.B={};this.N=null;this.O={};this.S=null;c?this.P=c(this):this.P=new hG(this);L(this,this.P);this.P.D("templateerror",this.Wq,this);this.P.D("templateready",this.Xq,this);this.P.D("resize",
-this.dr,this);Er("fs");c=this.P;c.fa=a;c.xj()||c.u("templateerror");a=this.k;c={};c.loaded=v(this.Am,this);c.unloaded=v(this.Bm,this);c.command_pause=DG(this.Sd,this);c.command_play=DG(this.Ud,this);c.command_seek=DG(this.sf,this);c.command_disable_controls=v(this.og,this);c.command_enable_controls=v(this.Ih,this);c.command_redirect_controls=v(this.Fm,this);c.command_stop_redirect_controls=v(this.Hh,this);c.command_redirected_show_is_playing=v(this.P.Cj,this.P);c.command_progress=v(this.mj,this);
-c.command_add_cuerange=v(this.zm,this);c.command_remove_cuerange=v(this.Dm,this);c.command_remove_cuerange_all=v(this.Em,this);c.command_preroll_ready=v(this.Gm,this);c.command_hide_all_dialogs=v(this.P.Bj,this.P);c.command_clear_video_overlays=v(this.Gh,this);c.command_log=v(this.qf,this);c.publish_external_event=v(this.Cm,this);c.module_menu_add=v(this.Eq,this);c.module_menu_remove=v(this.Fq,this);a.j=c;c=this.U;a.b!=c&&(uw(a),a.i={},a.b=c)}y(CG,R);f=CG.prototype;f.Wd=null;f.list=null;f.Xe=!0;
-f.xa=null;f.Gf=null;f.Dg=1;f.P=null;f.kk=null;f.Df=null;f.Uk=!1;f.Bi=null;f.oo=0;var EG={};
-function FG(a){var b=Nm.getTag();a.i=b;a.Wd=a.i;a.j&&Ay(a.j,b);Di(a.i,a.Dg);if(a.a.Pd)a.Df&&vf(a.Df),a.Df=K(a.i,"volumechange",v(a.Lt,a),!1);else{var b=a.i,c=a.xa.muted;b.volume=a.xa.volume/100;b.muted=c}b=a.P;b.b=a.i;b.b.parentNode||b.g.appendChild(b.b);V(b.b,"video-stream");V(b.b,"html5-main-video");c=b.app.J();c.Ub&&c.ve&&b.b.setAttribute("controls",!0);c.Ah&&b.b.setAttribute("webkit-playsinline",!0);b.b.setAttribute("x-webkit-airplay","allow");a.a.Wa=a.i}
-function GG(a){if(a.i){a.Df&&(vf(a.Df),a.Df=null);a.j&&Mm(a.j);var b=a.P;b.b&&(F(b.b),b.b=null);a.a.Wa=null;Nm.releaseTag(a.i);a.i=null}}function Jm(a,b){a.a.tb?(a.N&&(md(a.i,a.N.left,a.N.top),yd(a.i,new C(a.N.width,a.N.height)),a.N=null),Ci(a.i),Mm(a.j),Ay(a.j,a.i),Di(a.i,a.Dg)):Nm.releaseTag(b)}function qz(a,b){if(a.j!=b){a.j&&(uw(a.k),sz(a,a.j));a.R[b.B]=b;a.j=b;a.i&&Ay(b,a.i);var c=a.ca,d;for(d in c)b.D(d,c[d],a);a.u("videoplayerchange",b);ly(b)&&HG(a)}}
-function sz(a,b){Mm(b);var c=a.ca,d;for(d in c)b.W(d,c[d],a);b!=a.b&&(c=b.B,a.R[c]==b&&delete a.R[c]);b==a.j&&(a.j=null,b!=a.b&&qz(a,a.b))}function O(a,b){return b?a.R[b]||null:a.j}function HG(a){var b=a.j.getVideoData();a.Hm("newdata",a.j,b);var c=a.k;z([co,Uv,An,pw,Dt,$v,dw,jw,ys],c.B,c);a.u("videoready",b);6!=a.o&&ty(a.j)}f=CG.prototype;f.Hq=function(){IG(this,5)};f.Rq=function(a){a=a.i;P(a,8)&&!P(a,2)&&this.Ud()};
-function Cg(a){!a.H&&a.I.J().Ig&&(a.H=new cF(a),a.H&&JG(a,a.H));var b=a.H;b&&!b.Hd&&b.Xa(a.I)&&b.create()}
-function JG(a,b){L(a,b);b.D("loaded",a.Am,a);b.D("unloaded",a.Bm,a);b.D("command_pause",DG(a.Sd,a));b.D("command_play",DG(a.Ud,a));b.D("command_seek",DG(a.sf,a));b.D("command_disable_controls",a.og,a);b.D("command_enable_controls",a.Ih,a);b.D("command_redirect_controls",a.Fm,a);b.D("command_stop_redirect_controls",a.Hh,a);b.D("command_redirected_show_is_playing",a.P.Cj,a.P);b.D("command_progress",a.mj,a);b.D("command_add_cuerange",a.zm,a);b.D("command_remove_cuerange",a.Dm,a);b.D("command_remove_cuerange_all",
-a.Em,a);b.D("command_preroll_ready",a.Gm,a);b.D("command_hide_all_dialogs",a.P.Bj,a.P);b.D("command_clear_video_overlays",a.Gh,a);b.D("command_log",a.qf,a);b.D("publish_external_event",a.Cm,a);b.D("command_log_timing",a.k.A,a.k)}function Dg(a){a&&a.Hd&&a.destroy()}f.cb=function(a,b){this.u.apply(this,arguments);this.af.apply(this,arguments)};f.Vi=function(a,b){var c=Ya(arguments);Yw(this.a)&&c.push(this.j.B);this.u.apply(this,c)};f.J=function(){return this.a};
-f.getVideoData=function(a){return(a=O(this,a))?a.getVideoData():null};f.log_=function(){};f.Nq=function(){kf(0);this.a.Pd||this.ym(this.xa)};f.uj=function(){var a=gx(this.a);a.fs=this.a.Ab;a.volume=Math.round(this.xa.volume);a.mos=this.xa.muted?1:0;this.a.jj&&this.g&&this.g.g&&"WL"==this.g.g.type&&(a.ssrt=1);return a};f.or=function(){var a=xw(this.k);if(this.A){var b=this.A.Oi();b&&a.push(b)}return a};f.Wq=function(){sw(this.b,5,void 0,void 0)};
-f.Xq=function(){this.a.nk=this.P.a;this.P.yj();var a=this.ba;a.b=this.P.a;for(var b in a.g)a.b[b]=a.g[b];for(b in a.j)a.b[b]=a.j[b];a=v(this.du,this);b=document;var c=Xe("fullscreenchange",b);"msfullscreenchange"==c&&(c="MSFullscreenChange");this.kk=c?K(b,c,a):null;a=this.K.args;this.a.pj?this.xa=gh():this.xa||(this.xa={volume:100,muted:!1,nonNormalized:100});FG(this);b=new hg(a);iy(this.b,b);c=this.getVideoData();if("detailpage"==this.a.Y){var d;d=c.L;var e=fh("yt-player-restore-playhead");d=e?e[d]:
-void 0;d&&(c.ya=d)}ch("yt-player-restore-playhead");this.a.Sc=nF(this.P);"detailpage"!=this.a.Y&&a&&(a.playlist||a.list||a.api)&&(KG(this,a),b.L||b.mf||(a=this.g,b=v(this.Jn,this),a.Ne=b,a.be&&H(a.Ne,0)));if(a=this.K.args.jsapicallback)ha(a)||(a=n(a)),a&&DG(v(a,l,this.a.qj),l);this.a.Ig=Bg(this.a)&&(!Ra(XA())||!Ra(ZA()));yk()?this.a.qm?LG(this):"leanback"!=this.a.Y&&MG(this):sw(this.b,5,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",void 0);this.P.xk()};function MG(a){a.u("initializingmode");IG(a,2)}
-function LG(a){a.u("initializingmode");qz(a,a.b);IG(a,3);a.a.tb||(GG(a),FG(a),Ay(a.b,a.i));ny(a.b);NG(a,3)}function DG(a,b){return function(){var c=Array.prototype.slice.call(arguments);H(function(){a.apply(b||this,c)},0)}}f.qf=function(a,b,c){var d=O(this);b.event=a;d.j&&yy(d.j,b,c)};function Yf(a,b){if(!isNaN(b)&&a.i){var c=1,c=a.a.jg?Zf:[1],c=1>b?Na(c,function(a){return a>=b}):Pa(c,function(a){return a<=b});a.Dg!=c&&(a.Dg=c,a.b==a.j&&Di(a.i,c),a.u("onPlaybackRateChange",c))}}
-function $f(a,b){var c=a.getVideoData(b);return c&&c.a?c.a.a.i:"unknown"}function cG(a){return(a=O(a,void 0))?ay(a.ba,a.a):"unknown"}f.getCurrentTime=function(a){return(a=O(this,a))?a.getCurrentTime():0};function Fg(a,b){var c=O(a,b);return c?c.rd():0}function bg(a,b){var c=a.getVideoData(b);if(!c)return[];c=Ja(c.k,function(a){return a.mc.a.i});bb(c);return c}
-function lg(a,b){var c=a.b,d={};if(b&&c.j){var e=Ly(c.j);e&&pa(d,e.xi())}b&&P(c.i,384)&&(d.debug_error=c.i.a);d.debug_videoId=c.a.L;d.debug_playbackQuality=$f(a);d.debug_date=(new Date).toString();return mb(d)}
-function Zv(a,b){var c=a.getVideoData(),d=!!c.S||!!c.Jf||!b;a.u("threedenabled",d);d&&a.i.setAttribute("mozStereoMode","1");Vv()&&(a.i.setAttribute("mozStereoMode",d?"1":"0"),c=ok[d?c.te:0],d=document.createElement("NvStereoExtDataElement"),d.setAttribute("stereoMode",c),Uc(document.documentElement,d),Bf(d,"3DModeEvent"))}function xg(a){return(a=O(a,1))&&a.i}
-f.er=function(a){var b=a.target;switch(a.type){case "loadedmetadata":Gr("fvb")||Er("fvb");this.P.tf();break;case "loadstart":Gr("gv")||Er("gv");break;case "progress":case "timeupdate":Gr("l2s")||(a=zi(b),a<b.buffered.length&&2<b.buffered.end(a)&&Er("l2s"))}};f.br=function(a){if(this.Uk){var b=this.oo.toString();this.oo++;this.Bi[b]=a;a={request:Ya(a.b[0]?a.b[0].message:null),sessionId:b,system:a.j.a,url:a.k};this.u("onNewLicenseSession",a)}else a.start()};
-f.Pq=function(a,b){this.Vi("onLoadProgress",b)};f.Zq=function(a,b){this.Vi("onVideoProgress",b)};
-f.Uq=function(a,b,c,d,e){if(!e&&a.hg()&&!sy(a)){e=a.getVideoData();if(this.a.Rd&&e.wa&&!e.Ym&&e.ye>=e.vm){var g;g=a.J();var h=tb(e.ue/e.wa,0,1),h={html5:"1",video_id:e.L,eurl:g.b,framer:g.R,feature:g.k,ps:g.Ja,el:g.Y,hl:g.i,list:e.Na,w:h,l:e.wa,plid:e.ab,ei:e.j,t:e.qb,access_token:e.H,tpmt:e.ye,cpn:e.Ca};g.j&&(h.adformat=g.j);g.referrer&&(h.referrer=ex(g));g.Sb&&(h.autoplay="1");g.Da&&(h.authuser=g.Da);g.Ta&&(h.pageid=g.Ta);e.Nd&&(h.splay="1");e.g&&(h.subscribed=e.g);pa(h,bx(g));g=S(g.ib+"set_awesome",
-h);Kf(g);e.Ym=!0}e.wa&&e.ye>=e.pm&&OG(this)}this.mj(b,c,d,a)};f.mj=function(a,b,c,d){this.u("progresssync",a,b,c||0,(d||O(this)).B)};
-f.Jq=function(a){if(!P(a.state,2)||!PG(this)){P(a.state,2)&&(this.Sd(),P(a.a,32)&&this.b.ri(),this.a.kc&&dG(this,!1));if(0<ao(a,256)){var b=a.state.a;wg(this.b,b.errorCode,b.errorDetail)}if(P(a.state,128)&&(b=a.state,kf(0),Xf(this),b=b.a,206==b.errorCode&&wg(this.b,b.errorCode,b.errorDetail),!PG(this))){b.message||(b.messageKey||(b.messageKey="HTML5_DEFAULT_FALLBACK"),b.message=J(b.messageKey));5==b.errorCode&&wg(this.b,208,b.errorDetail);var c=5;206==b.errorCode&&(c=150);A(Fi,b.errorCode)&&(c=b.errorCode);
-this.u("onError",c);this.u("onDetailedError",b)}this.u("applicationplayerstatechange",a);P(a.state,2)&&(a=this.getVideoData(),a.Fb&&!a.bb&&this.og(["play_pause"]))}};f.Tq=function(a){!P(a.state,32)&&0>ao(a,16)&&(!P(a.state,8)||this.i.ended&&!P(a.state,2)||this.Ud());this.u("presentingplayerstatechange",a);this.af("onStateChange",a);NG(this,Ki(a.state))};
-f.Gq=function(a,b,c){if("newdata"==a){Dg(this.A);Dg(this.H);a=[];for(var d in this.B)Wf(this,d)&&a.push(d);this.B={};0<a.length&&this.u("controlsenabled",a);this.Hh();this.$={}}this.getVideoData().Lj?(this.Gf=Jb(this.xa),this.og(["audio"]),d=this.i,d.Jk=!0,d.muted=!0):(Wf(this,"audio")&&this.Ih(["audio"]),this.i.Jk=!1,this.Gf&&(fG(this,this.Gf),this.Gf=null));d=this.getVideoData();d.Fb&&!this.a.vj?sw(this.b,205,"DEVICE_FALLBACK",void 0):d.Fb&&!d.bb?this.og(["seek"]):this.Ih(["seek"]);this.getVideoData().dk&&
-!this.a.wj&&sw(this.b,207,"DEVICE_FALLBACK",void 0);if(c.R||c.i.focEnabled||c.i.rmktEnabled)c=1E3*this.getVideoData().wa,QG(this,"part2viewed",0,c),QG(this,"videoplaytime25",0.25*c,c),QG(this,"videoplaytime50",0.5*c,c),QG(this,"videoplaytime75",0.75*c,c),QG(this,"videoplaytime100",c,2147483647),QG(this,"conversionview",c,2147483647)};
-f.Hm=function(a,b,c){if("newdata"==a&&(uw(this.k),Yf(this,1),!b.j&&!sy(b))){var d=new zG,e=v(this.uj,this);d.Pj=e;e=v(this.or,this);d.Om=e;hy(b);if(b.a&&!sy(b)){b.j=d;d.O=b.ea;e=v(b.rd,b);d.K=e;e=v(b.getCurrentTime,b);d.lf=e;e=v(b.pr,b);d.Sm=e;e=b.o;d.a=b.a;d.b=e;d.lm=d.b.ib+"get_video";d.i=!1;var e=d.j,g=d.b,h=d.O;e.b=d.a;e.g=g;e.o=h;e.K=new $x(e.g);e.a.bwe=[];e.a.error=[];e.a.vfs=[];e.a.vps=[];e.a.view=[];d.N=!0;b.a.gg&&uy(b.j,{metric:"connected"})}}this.xa.volume=(this.xa.nonNormalized||this.xa.volume)*
-this.getVideoData().zh;c.vm=Math.min(0.8*c.wa,180);this.cb("videodatachange",a,c,b.B)};f.Yq=function(a,b){var c=this.j.getVideoData();a==c&&this.u("onPlaybackQualityChange",a.a.a.i,b)};f.Mq=function(){"detailpage"==this.a.Y&&zg(this)};function zg(a){var b=RG();if(b&&0<=b.index){var c=[];z(b.videoIds,function(a){if(a=b.videoData?b.videoData[a]:void 0)a.video_id=a.id,c.push(a)});KG(a,{videoList:c,loop:b.autoPlay,index:b.index})}}function KG(a,b){Nf(a.g);a.g=new Ol(b)}
-function QG(a,b,c,d){b in a.$||(c=new nh(c,d,{id:b,priority:1}),c.yb.D("onEnter",a.zp,a),c.yb.D("onExit",a.zp,a),a.b.Mk(c),a.$[b]=c)}f.zp=function(a){var b=a.getId(),c=this.b.getVideoData();"part2viewed"==b?(c.R&&Kf(c.R),c.Lc&&Kf(c.Lc)):"conversionview"==b&&OG(this);c.Ia&&(b=a.getId(),c=Zi(c.Ia,{label:b}),Kf(c));this.b.bi(a)};
-function OG(a){var b=a.b.getVideoData();b.xo||(b.i.eventLabel=a.a.Y,b.i.playerStyle=a.a.Ja,b.R&&(b.i.feature="pyv"),b.i.vid=b.L,b.i.isAd=!("adunit"!=a.a.Y&&!b.R),HF("view",b.i),b.xo=!0)}function IG(a,b){b!=a.o&&(2==b&&NG(a,5),a.o=b,a.u("appstatechange",b))}function NG(a,b){a.ea!=b&&(a.ea=b,a.Vi("onStateChange",b))}function xF(a,b){if(a.a.Ra){var c={controlClicked:b};a.a.Ab&&(c.fs=1);a.qf("",c)}}f.sf=function(a,b,c,d){(d=O(this,d))&&Ey(d,a,!1!=b,c)};
-f.Vq=function(a,b){var c=a.getVideoData();if(1==this.o||2==this.o)c.ya=b;2==this.o?LG(this):(c=Jy(a,b),this.cb("seekto",c))};f.Kq=function(){this.cb("beginseeking")};f.ar=function(){this.cb("endseeking")};function fG(a,b){a.xa=b;a.u("internalvolumechange",a.xa)}function Sf(a){a.xa.muted=!0;a.u("internalvolumechange",a.xa)}function Tf(a){a.xa.muted=!1;a.u("internalvolumechange",a.xa)}function jg(a,b){var c;if(c=(new pe(b)).a){var d=a.a;d.va=c.get("d",d.va);d.da=c.get("f",d.da)}}
-function eg(a,b,c){b=new hg(b);return SG(a,b,void 0,c)}function SG(a,b,c,d){var e=O(a,d);if(!e)return!1;void 0!=c&&(b.kf=c);Xf(a,d);iy(e,b);if(!my(e))return!1;$w(e.J(),b.b);e==a.b?(IG(a,1),LG(a)):ny(e);return!0}function pg(a,b){var c=SG(a,b);Qf(a,c,void 0)}function Qf(a,b,c){c=O(a,c);b&&c==a.b&&(c.getVideoData().Nd=!0)}function gg(a,b,c){var d=O(a,c);d&&(Xf(a,c),iy(d,b),my(d)&&($w(d.J(),b.b),d==a.b&&(IG(a,1),MG(a))))}
-function rn(a,b,c,d){if(!b&&!d)throw Error("Playback source is invalid");b=fg(b||null,d||null);a.a.Ab||"detailpage"!=a.a.Y?d?(a.Xe=!1,mg(a,b,void 0,void 0,void 0)):eg(a,b,1):(d={},c&&(d.feature=c),b=new hg(b),d=ot(a.a,b,d),c&&a.u("onNavigate",{url:d,feature:c}),window.location.href=d)}function mg(a,b,c,d,e){"string"==typeof b||b instanceof Array?KG(a,{api:b,index:c,startSeconds:d,suggestedQuality:e}):KG(a,b);b=a.g;a=v(a.Jn,a);b.Ne=a;b.be&&H(b.Ne,0)}
-f.Jn=function(){var a=qg(this.g);this.getVideoData().hf||!this.Xe?pg(this,a):gg(this,a)};function zn(a){var b=RG();return!(!a.g||!(a.g.loop||a.g.pa+1<a.g.Pa)||b&&!b.autoPlay)}function PG(a){return a.g&&("embedded"==a.a.Y||a.a.Ab)&&zn(a)?(ng(a),!0):!1}function ng(a){a.g&&(a.g.be?(a.g.loop||a.g.pa+1<a.g.Pa)&&pg(a,Tl(a.g)):(Tl(a.g),a.Xe=!1))}function og(a){a.g&&(a.g.be?(a.g.loop||0<=a.g.pa-1)&&pg(a,Ul(a.g)):(Ul(a.g),a.Xe=!1))}function RG(){var a=n("yt.www.watch.lists.getState");return a?a():null}
-function kg(a,b){var c=null;b&&(c={t:Math.floor(a.getCurrentTime(1))});return ot(a.a,a.getVideoData(1),null,c)}f.zm=function(a,b){var c=O(this,b);c&&(z(a,c.Mk,c),this.u("cuerangesadded",a))};f.Dm=function(a,b){var c=O(this,b);c&&(z(a,c.bi,c),this.u("cuerangesremoved",a))};f.Em=function(a,b){var c=O(this,b);if(c){for(var c=c.A,d=c.i.length-1;0<=d;d--)c.i[d].namespace==a&&Ni(c,d);c.Xb()}};f.Gm=function(a,b){var c=O(this,b);c&&zy(c,a)};f.Iq=function(){TG(this)};
-function TG(a){if(!a.a.Lk){var b=a.b.getVideoData();if(b.L){var c=b.L;Ir().docid=c}b.j&&(c=b.j,Ir().ei=c);b.Ca&&(c=b.Ca,Ir().cpn=c);0<b.ya&&(c=b.ya.toString(),Ir().start=c);b=b.a.Sa.toString();Ir().fmt=b;b=Math.round((a.b.b?cg(a.b.b):0)*Fg(a)).toString();Ir().tds=b;Er("aft");if("detailpage"==a.a.Y){var b=a.k.G,d;for(d in b)Er(d,b[d]);d=a.k.o;for(var e in d)b=e,c=d[e],Ir()[b]=c;b=Fr().tick;e=Fr().span;c=Ir();if(d=n("yt.timing.reportbuilder_")){if(d=d.apply(null,[b,e,c,void 0]))Hr(d),Jr()}else{d={v:2,
-s:"youtube",action:ef("TIMING_ACTION")};var g=ef("TIMING_INFO")||{},h;for(h in g)c[h]=g[h];h=c.srt;delete c.srt;if(!h&&0!==h)try{var k=(window.performance||window.mozPerformance||window.msPerformance||window.webkitPerformance).timing;h=k.responseStart-k.navigationStart}catch(m){c.pt&&(h=c.pt)}if(h||0===h)c.srt=h;b.aft||(b.aft=b.vr&&b.cl&&b.cl>b.vr?b.cl:b.vr?b.vr:b.ol);b.aft&&b.plev&&(b.aft=Math.min(b.aft,b.plev));b.vr&&b.gv&&(e.vl=Math.round(b.vr-b.gv));for(var p in c)"_"!=p.charAt(0)&&(d[p]=c[p]);
-k={};p=[];h=b._start;for(var s in b)"_"!=s.charAt(0)&&(c=Math.max(Math.round(b[s]-h),0),k[s]=c,p.push(s+"."+c));d.rt=p.join(",");s={};p=[];for(var r in e)"_"!=r.charAt(0)&&(s[r]=e[r],p.push(r+"."+e[r]));d.it=p.join(",");Hr(d);(r=n("ytdebug.logTiming"))&&r(d,k,s);Jr()}}a.a.Lk=!0}}f.Am=function(a){"remote"==a?(IG(this,6),Dg(this.A)):this.Vi("onApiChange")};f.Bm=function(a){"remote"==a&&MG(this)};
-f.Lt=function(){if(!Wf(this,"audio")){var a=100*this.i.volume,a={volume:a,nonNormalized:a/this.getVideoData().zh,muted:this.i.muted};this.xa=Jb(a);this.cb("onVolumeChange",a)}};
-f.ym=function(a){a.volume=tb(a.volume,0,100);a.nonNormalized=a.volume/this.getVideoData().zh;if(this.a.pj&&!this.a.Pd){var b={};b.volume=isNaN(a.volume)?gh().volume:tb(a.volume,0,100);b.nonNormalized=a.nonNormalized;b.muted=void 0==a.muted?gh().muted:a.muted;Zg("yt-player-volume",b,2592E3)}if(Wf(this,"audio"))this.Gf&&(this.Gf=Jb(a),this.cb("onVolumeChange",a));else{var b=this.i,c=a.muted;b.volume=a.volume/100;b.muted=c;this.a.Pd||this.cb("onVolumeChange",a)}};f.du=function(){UG(this,!!Df())};
-function UG(a,b){a.P.Ko(b);if("detailpage"==a.a.Y&&!b){var c=a.b.getVideoData(),d=n("checkCurrentVideo");if(d&&ef("VIDEO_ID")!=c.L){var e=a.getCurrentTime(),g={};g[c.L]=e;Zg("yt-player-restore-playhead",g,172800);d(c.L);a.u("openingpage")}}a.a.Ab=b;a.P.tf();a.cb("fullscreentoggled",b)}f.dr=function(){nG(this)};f.Gh=function(){this.cb("clearvideooverlays")};f.Eq=function(a){this.cb("menu_add",a)};f.Fq=function(a){this.cb("menu_remove",a)};f.Oq=function(a){this.cb("liveviewshift",a)};
-f.Cm=function(a,b){if("onAdStateChange"==a){var c=arguments[1],d=arguments[2],e=arguments[3]||{};1==c&&TG(this);"leanback"==this.a.Y&&Yw(this.a)&&(0==c?this.Wd=this.i:this.Wd=d,this.u("onAdStateChange",c,e.video_id))}else this.u.apply(this,arguments)};f.af=function(a,b){this.k.H.apply(this.k,arguments);this.A&&this.A.u.apply(this.A,arguments);this.H&&this.H.u.apply(this.H,arguments)};f.Ud=function(a,b){var c=O(this,b);c&&(2==this.o?LG(this):c.U?(a&&VG(this,c),P(c.i,2)?this.sf(0):Cy(c)):ny(c))};
-f.Sd=function(a,b){var c=O(this,b);c&&(a&&VG(this,c),xy(c))};function Xf(a,b){var c=O(a,b);if(c&&1!=a.o&&2!=a.o){xy(c);if(c.j){var d=c.j,e=Ly(d,"watchtime");e.km=!0;e.o=null;e.k=null;BG(d);Oy(d,e);e=d.j;e.k();uG(e);d.F()}c.U=!1;c.b&&(jy(c),c.g&&(Of(c.k,c.g),c.k=null,c.g=null),c.a&&(c.a.ya=c.getCurrentTime()),c.H=NaN,Bi(c.b),c.o.Ia&&Ei(c.b,!1),P(c.i,128)||oy(c,Ii(c.i)))}}function Uf(a,b){if(!Wf(a,"play_pause")){var c=a.O.play_pause?a.S:null;c?c.oe("control_play"):a.Ud(!1,b)}}
-function Vf(a,b){if(!Wf(a,"play_pause")){var c=a.O.play_pause?a.S:null;c?c.oe("control_pause"):a.Sd(!1,b)}}function eG(a,b){if(!Wf(a,"play_pause")&&(!a.a.Gb||2!=a.o||Nm.hasTags(void 0))){var c=a.O.play_pause?a.S:null;c?c.oe("control_toggle_play_pause"):(c=O(a,void 0))&&(c.hg()?a.Sd(b,void 0):a.Ud(b,void 0))}}function Rf(a,b,c,d,e){if(!Wf(a,"seek")){var g=a.O.seek?a.S:null;g?g.oe("control_seek",b):a.sf(b,c,d,e)}}
-function dG(a,b){if(a.a.Ab!=b)if(Cf())if(b){var c=a.P.a,d=We(["requestFullscreen","requestFullScreen"],c);d&&d.apply(c)}else(c=We(["exitFullscreen","cancelFullscreen","cancelFullScreen"],document))&&c.call(document);else a.u("onFullScreenToggleRequest"),UG(a,b)}function zF(a,b){dG(a,!1);a.u("openingpage");Cr(b)}f.Lq=function(a){Zw(this.a,a)};
-f.Sq=function(){if(this.j==this.b){var a;if(a=Bg(this.a))if(bh("yt-remote-delayed-connect-key"))a=!0;else{a=QA();var b=IA(XA());a=!!MA(b,a)}if(a||!this.getVideoData(1).Zm||this.a.kc)if((b=ly(this.b))||(b=((b=this.getVideoData())&&b.I.length&&!b.O.length?0<=Ha(b.I,"fresca"):!1)||a),b){if(this.b.S.length||0<Yh(this.b.A.b,-2147483648).length)IG(this,4),Dg(this.A);a&&IG(this,6);!this.A&&this.I.getVideoData().ga&&(this.A=new tA(this))&&JG(this,this.A);(a=this.A)&&!a.Hd&&a.Xa(this.I)&&a.create();Cg(this);
-HG(this)}else a=!1,this.getVideoData().ba||this.U&&(a=iw(this.U)),a?(a=this.getVideoData(),eg(this,{video_id:a.b.ypc_vid||a.L,ypc_preview:1},1)):(this.log_("No available formats"),sw(this.b,5,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",void 0));else a="DEVICE_FALLBACK",cc||si("iemobile")||si("xbox")&&si("trident")||si("nintendo wiiu")||(a="FLASH_FALLBACK"),sw(this.b,5,a,void 0)}else HG(this)};f.Qq=function(){this.Sd()};
-function VG(a,b){var c=b.getVideoData(),d="html5-bezel-pause";P(b.i,8)?c.Fb&&!c.bb&&(d="html5-bezel-stop"):d="html5-bezel-play";a.P.Ip(d)}function nG(a){a.a.Sc=nF(a.P);if(a.i){var b=a.getVideoData();0!=a.i.readyState&&(b.da=new C(a.i.videoWidth,a.i.videoHeight));a.a.xv=qF(a.P,nF(a.P),oF(a.P),pF(a.P),void 0);a.a.ug=qF(a.P,nF(a.P),oF(a.P),pF(a.P),!0);ag(O(a),"r");a.u("resize",dx(a.a));a.cb("onResize")}}function Wf(a,b){return!(!a.B[b]||!a.B[b].length)}
-f.og=function(a,b){b=b||"defaultcontext";var c=[];z(a,function(a){this.B[a]?0>this.B[a].indexOf(b)&&this.B[a].push(b):(this.B[a]=[b],c.push(a))},this);0<c.length&&this.u("controlsdisabled",c)};f.Ih=function(a,b){b=b||"defaultcontext";var c=[];z(a,function(a){if(Wf(this,a)){var e=this.B[a].indexOf(b);0<=e&&this.B[a].splice(e,1);0==this.B[a].length&&c.push(a)}},this);0<c.length&&this.u("controlsenabled",c)};
-f.Fm=function(a,b,c){this.Hh();this.S=a;b&&z(b,function(a){this.O[a]=!0},this);c&&vw(this.k,a,c)};f.Hh=function(){this.S=null;this.O={};ww(this.k)};function jG(a){var b=a.getVideoData();return b&&b.Ma&&!tl.test(b.Ma)?!a.a.Mh:a.a.sc}f.F=function(){GG(this);this.kk&&vf(this.kk);kf(0);Of(Eb(this.R));this.R={};this.j=this.b=null;Of(this.a,this.g);this.K=this.I=this.ba=this.U=this.Wd=null;CG.C.F.call(this)};qa("yt.player.Application",CG);function WG(a,b,c,d){a={name:a,locale:c,feature:d};for(var e in b)a[e]=b[e];b=S("/sharing_services",a);Kf(b)}function XG(a,b,c,d,e,g){var h={};b&&(h.v=b);c&&(h.list=c);d&&(h.url=d);WG(a,h,e,g)}function YG(a,b,c,d){WG(a,{v:b},c,d)}function ZG(a,b,c,d,e){WG(a,{list:b,v:c},d,e)};ir(mr);ir(Us);n("yt.tracking.shareVideo")||(qa("yt.tracking.share",XG),qa("yt.tracking.shareVideo",YG),qa("yt.tracking.shareList",ZG));n("yt.window.popup")||(qa("yt.window.popup",Dr),qa("yt.window.open",Cr));qa("yt.player.Application.create",function(a,b){EG[a]&&(EG[a].dispose(),EG[a]=null);var c=new CG(a,b);Mf(c,function(){EG[a]=null});EG[a]=c});})();
diff --git a/test/testdata/html5player-vflUKrNpT.js b/test/testdata/html5player-vflUKrNpT.js
deleted file mode 100644 (file)
index 2f9f436..0000000
+++ /dev/null
@@ -1,889 +0,0 @@
-(function(){var f,aa=aa||{},l=this;function n(a,b){for(var c=a.split("."),d=b||l,e;e=c.shift();)if(null!=d[e])d=d[e];else return null;return d}function ba(){}function ca(a){a.getInstance=function(){return a.Zp?a.Zp:a.Zp=new a}}
-function da(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}function q(a){return void 0!==a}function ea(a){return null!=a}function t(a){return"array"==da(a)}function fa(a){var b=da(a);return"array"==b||"object"==b&&"number"==typeof a.length}function u(a){return"string"==typeof a}function ga(a){return"number"==typeof a}function ha(a){return"function"==da(a)}function ia(a){var b=typeof a;return"object"==b&&null!=a||"function"==b}function ja(a){return a[ka]||(a[ka]=++la)}
-var ka="closure_uid_"+(1E9*Math.random()>>>0),la=0;function ma(a,b,c){return a.call.apply(a.bind,arguments)}function na(a,b,c){if(!a)throw 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)}}
-function v(a,b,c){v=Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?ma:na;return v.apply(null,arguments)}function oa(a,b){var c=Array.prototype.slice.call(arguments,1);return function(){var b=c.slice();b.push.apply(b,arguments);return a.apply(this,b)}}function w(a,b){for(var c in b)a[c]=b[c]}var x=Date.now||function(){return+new Date};
-function pa(a,b){var c=a.split("."),d=l;c[0]in d||!d.execScript||d.execScript("var "+c[0]);for(var e;c.length&&(e=c.shift());)c.length||void 0===b?d=d[e]?d[e]:d[e]={}:d[e]=b}function y(a,b){function c(){}c.prototype=b.prototype;a.C=b.prototype;a.prototype=new c;a.prototype.constructor=a}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 v.apply(null,c)}return v(this,a)};var qa={},ra=0;function sa(a,b){if(a){var c=new Image,d=""+ra++;qa[d]=c;c.onload=c.onerror=function(){b&&qa[d]&&b();delete qa[d]};c.src=a;c=eval("null")}};function ua(a){Error.captureStackTrace?Error.captureStackTrace(this,ua):this.stack=Error().stack||"";a&&(this.message=String(a))}y(ua,Error);ua.prototype.name="CustomError";var va;function wa(a,b){for(var c=a.split("%s"),d="",e=Array.prototype.slice.call(arguments,1);e.length&&1<c.length;)d+=c.shift()+e.shift();return d+c.join("%s")}function xa(a){return decodeURIComponent(a.replace(/\+/g," "))}function ya(a){if(!za.test(a))return a;-1!=a.indexOf("&")&&(a=a.replace(Aa,"&amp;"));-1!=a.indexOf("<")&&(a=a.replace(Ba,"&lt;"));-1!=a.indexOf(">")&&(a=a.replace(Ca,"&gt;"));-1!=a.indexOf('"')&&(a=a.replace(Da,"&quot;"));return a}var Aa=/&/g,Ba=/</g,Ca=/>/g,Da=/\"/g,za=/[&<>\"]/;
-function Ea(a,b){for(var c=0,d=String(a).replace(/^[\s\xa0]+|[\s\xa0]+$/g,"").split("."),e=String(b).replace(/^[\s\xa0]+|[\s\xa0]+$/g,"").split("."),g=Math.max(d.length,e.length),h=0;0==c&&h<g;h++){var k=d[h]||"",m=e[h]||"",p=RegExp("(\\d*)(\\D*)","g"),r=RegExp("(\\d*)(\\D*)","g");do{var s=p.exec(k)||["","",""],D=r.exec(m)||["","",""];if(0==s[0].length&&0==D[0].length)break;c=((0==s[1].length?0:parseInt(s[1],10))<(0==D[1].length?0:parseInt(D[1],10))?-1:(0==s[1].length?0:parseInt(s[1],10))>(0==D[1].length?
-0:parseInt(D[1],10))?1:0)||((0==s[2].length)<(0==D[2].length)?-1:(0==s[2].length)>(0==D[2].length)?1:0)||(s[2]<D[2]?-1:s[2]>D[2]?1:0)}while(0==c)}return c}function Fa(a){var b=Number(a);return 0==b&&/^[\s\xa0]*$/.test(a)?NaN:b};function Ga(){};function Ha(a){return a[a.length-1]}
-var Ia=Array.prototype,Ja=Ia.indexOf?function(a,b,c){return Ia.indexOf.call(a,b,c)}:function(a,b,c){c=null==c?0:0>c?Math.max(0,a.length+c):c;if(u(a))return u(b)&&1==b.length?a.indexOf(b,c):-1;for(;c<a.length;c++)if(c in a&&a[c]===b)return c;return-1},z=Ia.forEach?function(a,b,c){Ia.forEach.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)g in e&&b.call(c,e[g],g,a)},Ka=Ia.filter?function(a,b,c){return Ia.filter.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=[],g=
-0,h=u(a)?a.split(""):a,k=0;k<d;k++)if(k in h){var m=h[k];b.call(c,m,k,a)&&(e[g++]=m)}return e},La=Ia.map?function(a,b,c){return Ia.map.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=Array(d),g=u(a)?a.split(""):a,h=0;h<d;h++)h in g&&(e[h]=b.call(c,g[h],h,a));return e},Ma=Ia.some?function(a,b,c){return Ia.some.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)if(g in e&&b.call(c,e[g],g,a))return!0;return!1},Na=Ia.every?function(a,b,c){return Ia.every.call(a,b,c)}:function(a,
-b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)if(g in e&&!b.call(c,e[g],g,a))return!1;return!0};function Oa(a,b){var c=0;z(a,function(a,e,g){b.call(void 0,a,e,g)&&++c},void 0);return c}function Pa(a,b,c){b=Qa(a,b,c);return 0>b?null:u(a)?a.charAt(b):a[b]}function Qa(a,b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)if(g in e&&b.call(c,e[g],g,a))return g;return-1}function Ra(a,b){var c=Sa(a,b,void 0);return 0>c?null:u(a)?a.charAt(c):a[c]}
-function Sa(a,b,c){for(var d=u(a)?a.split(""):a,e=a.length-1;0<=e;e--)if(e in d&&b.call(c,d[e],e,a))return e;return-1}function Ta(a,b){return 0<=Ja(a,b)}function Ua(a){return 0==a.length}function Va(a){if(!t(a))for(var b=a.length-1;0<=b;b--)delete a[b];a.length=0}function Wa(a,b){Ta(a,b)||a.push(b)}function Xa(a,b){var c=Ja(a,b),d;(d=0<=c)&&Ya(a,c);return d}function Ya(a,b){Ia.splice.call(a,b,1)}function Za(a,b){var c=Qa(a,b,void 0);0<=c&&Ya(a,c)}
-function $a(a){return Ia.concat.apply(Ia,arguments)}function ab(a){var b=a.length;if(0<b){for(var c=Array(b),d=0;d<b;d++)c[d]=a[d];return c}return[]}function bb(a,b){for(var c=1;c<arguments.length;c++){var d=arguments[c],e;if(t(d)||(e=fa(d))&&Object.prototype.hasOwnProperty.call(d,"callee"))a.push.apply(a,d);else if(e)for(var g=a.length,h=d.length,k=0;k<h;k++)a[g+k]=d[k];else a.push(d)}}function cb(a,b,c,d){Ia.splice.apply(a,db(arguments,1))}
-function db(a,b,c){return 2>=arguments.length?Ia.slice.call(a,b):Ia.slice.call(a,b,c)}function eb(a){for(var b={},c=0,d=0;d<a.length;){var e=a[d++],g=ia(e)?"o"+ja(e):(typeof e).charAt(0)+e;Object.prototype.hasOwnProperty.call(b,g)||(b[g]=!0,a[c++]=e)}a.length=c}function fb(a,b,c){for(var d=0,e=a.length,g;d<e;){var h=d+e>>1,k;k=b(c,a[h]);0<k?d=h+1:(e=h,g=!k)}return g?d:~d}function gb(a,b){Ia.sort.call(a,b||hb)}function ib(a,b){var c=hb;gb(a,function(a,e){return c(a[b],e[b])})}
-function jb(a,b,c){if(!fa(a)||!fa(b)||a.length!=b.length)return!1;var d=a.length;c=c||kb;for(var e=0;e<d;e++)if(!c(a[e],b[e]))return!1;return!0}function hb(a,b){return a>b?1:a<b?-1:0}function kb(a,b){return a===b}function lb(a,b,c){c=fb(a,c||hb,b);0>c&&cb(a,-(c+1),0,b)}function mb(a){for(var b=[],c=0;c<arguments.length;c++){var d=arguments[c];t(d)?b.push.apply(b,mb.apply(null,d)):b.push(d)}return b};function nb(a){a=String(a);if(/^\s*$/.test(a)?0:/^[\],:{}\s\u2028\u2029]*$/.test(a.replace(/\\["\\\/bfnrtu]/g,"@").replace(/"[^"\\\n\r\u2028\u2029\x00-\x08\x0a-\x1f]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:[\s\u2028\u2029]*\[)+/g,"")))try{return eval("("+a+")")}catch(b){}throw Error("Invalid JSON string: "+a);}function ob(a){return eval("("+a+")")}function pb(a){return qb(new rb(void 0),a)}function rb(a){this.a=a}
-function qb(a,b){var c=[];sb(a,b,c);return c.join("")}
-function sb(a,b,c){switch(typeof b){case "string":tb(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(null==b){c.push("null");break}if(t(b)){var d=b.length;c.push("[");for(var e="",g=0;g<d;g++)c.push(e),e=b[g],sb(a,a.a?a.a.call(b,String(g),e):e,c),e=",";c.push("]");break}c.push("{");d="";for(g in b)Object.prototype.hasOwnProperty.call(b,g)&&(e=b[g],"function"!=typeof e&&(c.push(d),tb(g,c),c.push(":"),
-sb(a,a.a?a.a.call(b,g,e):e,c),d=","));c.push("}");break;case "function":break;default:throw Error("Unknown type: "+typeof b);}}var ub={'"':'\\"',"\\":"\\\\","/":"\\/","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\x0B":"\\u000b"},vb=/\uffff/.test("\uffff")?/[\\\"\x00-\x1f\x7f-\uffff]/g:/[\\\"\x00-\x1f\x7f-\xff]/g;
-function tb(a,b){b.push('"',a.replace(vb,function(a){if(a in ub)return ub[a];var b=a.charCodeAt(0),e="\\u";16>b?e+="000":256>b?e+="00":4096>b&&(e+="0");return ub[a]=e+b.toString(16)}),'"')};function wb(a,b,c){return Math.min(Math.max(a,b),c)};function A(a,b){this.x=q(a)?a:0;this.y=q(b)?b:0}f=A.prototype;f.clone=function(){return new A(this.x,this.y)};function xb(a,b){var c=a.x-b.x,d=a.y-b.y;return Math.sqrt(c*c+d*d)}function yb(a,b){return new A(a.x-b.x,a.y-b.y)}f.ceil=function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);return this};f.floor=function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);return this};f.round=function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this};
-f.scale=function(a,b){var c=ga(b)?b:a;this.x*=a;this.y*=c;return this};function zb(a,b,c,d){this.top=a;this.right=b;this.bottom=c;this.left=d}f=zb.prototype;f.clone=function(){return new zb(this.top,this.right,this.bottom,this.left)};f.contains=function(a){return this&&a?a instanceof zb?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:!1};
-f.ceil=function(){this.top=Math.ceil(this.top);this.right=Math.ceil(this.right);this.bottom=Math.ceil(this.bottom);this.left=Math.ceil(this.left);return this};f.floor=function(){this.top=Math.floor(this.top);this.right=Math.floor(this.right);this.bottom=Math.floor(this.bottom);this.left=Math.floor(this.left);return this};f.round=function(){this.top=Math.round(this.top);this.right=Math.round(this.right);this.bottom=Math.round(this.bottom);this.left=Math.round(this.left);return this};
-f.scale=function(a,b){var c=ga(b)?b:a;this.left*=a;this.right*=a;this.top*=c;this.bottom*=c;return this};function B(a,b){this.width=a;this.height=b}function Ab(a,b){return a==b?!0:a&&b?a.width==b.width&&a.height==b.height:!1}f=B.prototype;f.clone=function(){return new B(this.width,this.height)};function Bb(a){return a.width/a.height}f.isEmpty=function(){return!(this.width*this.height)};f.ceil=function(){this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};f.floor=function(){this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};
-f.round=function(){this.width=Math.round(this.width);this.height=Math.round(this.height);return this};f.scale=function(a,b){var c=ga(b)?b:a;this.width*=a;this.height*=c;return this};function Cb(a,b){return a.scale(Bb(a)>Bb(b)?b.width/a.width:b.height/a.height)};function Db(a,b,c,d){this.left=a;this.top=b;this.width=c;this.height=d}f=Db.prototype;f.clone=function(){return new Db(this.left,this.top,this.width,this.height)};function Eb(a){return new Db(a.left,a.top,a.right-a.left,a.bottom-a.top)}function Fb(a,b){return a==b?!0:a&&b?a.left==b.left&&a.width==b.width&&a.top==b.top&&a.height==b.height:!1}
-f.contains=function(a){return a instanceof Db?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};function Gb(a){return new B(a.width,a.height)}f.ceil=function(){this.left=Math.ceil(this.left);this.top=Math.ceil(this.top);this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};
-f.floor=function(){this.left=Math.floor(this.left);this.top=Math.floor(this.top);this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};f.round=function(){this.left=Math.round(this.left);this.top=Math.round(this.top);this.width=Math.round(this.width);this.height=Math.round(this.height);return this};f.scale=function(a,b){var c=ga(b)?b:a;this.left*=a;this.width*=a;this.top*=c;this.height*=c;return this};function Hb(a,b,c){for(var d in a)b.call(c,a[d],d,a)}function Ib(a,b){for(var c in a)if(!b.call(void 0,a[c],c,a))return!1;return!0}function Jb(a){var b=[],c=0,d;for(d in a)b[c++]=a[d];return b}function Kb(a){var b=[],c=0,d;for(d in a)b[c++]=d;return b}function Lb(a,b){for(var c in a)if(a[c]==b)return!0;return!1}function Mb(a,b){for(var c in a)if(b.call(void 0,a[c],c,a))return c}function Nb(a){for(var b in a)return!1;return!0}function Ob(a){var b={},c;for(c in a)b[c]=a[c];return b}
-function Pb(a){var b=da(a);if("object"==b||"array"==b){if(a.clone)return a.clone();var b="array"==b?[]:{},c;for(c in a)b[c]=Pb(a[c]);return b}return a}var Qb="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");function Rb(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 g=0;g<Qb.length;g++)c=Qb[g],Object.prototype.hasOwnProperty.call(d,c)&&(a[c]=d[c])}}
-function Sb(a){var b=arguments.length;if(1==b&&t(arguments[0]))return Sb.apply(null,arguments[0]);if(b%2)throw Error("Uneven number of arguments");for(var c={},d=0;d<b;d+=2)c[arguments[d]]=arguments[d+1];return c};function Tb(a){return function(){throw a;}};var Ub,Vb,Wb,Xb,Yb,Zb,$b;function ac(){return l.navigator?l.navigator.userAgent:null}function bc(){return l.navigator}Yb=Xb=Wb=Vb=Ub=!1;var cc;if(cc=ac()){var dc=bc();Ub=0==cc.lastIndexOf("Opera",0);Vb=!Ub&&(-1!=cc.indexOf("MSIE")||-1!=cc.indexOf("Trident"));Xb=(Wb=!Ub&&-1!=cc.indexOf("WebKit"))&&-1!=cc.indexOf("Mobile");Yb=!Ub&&!Wb&&!Vb&&"Gecko"==dc.product}var ec=Ub,C=Vb,fc=Yb,gc=Wb,hc=Xb,ic=bc(),jc=ic&&ic.platform||"";Zb=-1!=jc.indexOf("Mac");$b=-1!=jc.indexOf("Win");
-var kc=!!bc()&&-1!=(bc().appVersion||"").indexOf("X11");function lc(){var a=l.document;return a?a.documentMode:void 0}var mc;t:{var nc="",oc;if(ec&&l.opera)var pc=l.opera.version,nc="function"==typeof pc?pc():pc;else if(fc?oc=/rv\:([^\);]+)(\)|;)/:C?oc=/\b(?:MSIE|rv)[: ]([^\);]+)(\)|;)/:gc&&(oc=/WebKit\/(\S+)/),oc)var qc=oc.exec(ac()),nc=qc?qc[1]:"";if(C){var rc=lc();if(rc>parseFloat(nc)){mc=String(rc);break t}}mc=nc}var sc=mc,tc={};function uc(a){return tc[a]||(tc[a]=0<=Ea(sc,a))}
-function vc(a){return C&&wc>=a}var xc=l.document,wc=xc&&C?lc()||("CSS1Compat"==xc.compatMode?parseInt(sc,10):5):void 0;var yc=!C||vc(9),zc=!fc&&!C||C&&vc(9)||fc&&uc("1.9.1"),Ac=C&&!uc("9"),Bc=C||ec||gc;function Cc(a){a=a.className;return u(a)&&a.match(/\S+/g)||[]}function Dc(a,b){for(var c=Cc(a),d=db(arguments,1),e=c.length+d.length,g=c,h=0;h<d.length;h++)Ta(g,d[h])||g.push(d[h]);g=c.join(" ");a.className=g;return c.length==e}function Ec(a,b){var c=Cc(a),d=db(arguments,1),c=Fc(c,d).join(" ");a.className=c}function Fc(a,b){return Ka(a,function(a){return!Ta(b,a)})}function Gc(a,b){return Ta(Cc(a),b)}function Hc(a,b,c){c?Dc(a,b):Ec(a,b)}function Ic(a,b){var c=!Gc(a,b);Hc(a,b,c)};function Jc(a){return a?new Kc(Lc(a)):va||(va=new Kc)}function Mc(a){return u(a)?document.getElementById(a):a}function Nc(a,b){var c=b||document;return c.querySelectorAll&&c.querySelector?c.querySelectorAll("."+a):c.getElementsByClassName?c.getElementsByClassName(a):Oc("*",a,b)}function E(a,b){var c=b||document,d=null;return(d=c.querySelectorAll&&c.querySelector?c.querySelector("."+a):Nc(a,b)[0])||null}
-function Oc(a,b,c){var d=document;c=c||d;a=a&&"*"!=a?a.toUpperCase():"";if(c.querySelectorAll&&c.querySelector&&(a||b))return c.querySelectorAll(a+(b?"."+b:""));if(b&&c.getElementsByClassName){c=c.getElementsByClassName(b);if(a){for(var d={},e=0,g=0,h;h=c[g];g++)a==h.nodeName&&(d[e++]=h);d.length=e;return d}return c}c=c.getElementsByTagName(a||"*");if(b){d={};for(g=e=0;h=c[g];g++)a=h.className,"function"==typeof a.split&&Ta(a.split(/\s+/),b)&&(d[e++]=h);d.length=e;return d}return c}
-function Pc(a,b){Hb(b,function(b,d){"style"==d?a.style.cssText=b:"class"==d?a.className=b:"for"==d?a.htmlFor=b:d in Qc?a.setAttribute(Qc[d],b):0==d.lastIndexOf("aria-",0)||0==d.lastIndexOf("data-",0)?a.setAttribute(d,b):a[d]=b})}var Qc={cellpadding:"cellPadding",cellspacing:"cellSpacing",colspan:"colSpan",frameborder:"frameBorder",height:"height",maxlength:"maxLength",role:"role",rowspan:"rowSpan",type:"type",usemap:"useMap",valign:"vAlign",width:"width"};
-function Rc(a){a=a.document;a="CSS1Compat"==a.compatMode?a.documentElement:a.body;return new B(a.clientWidth,a.clientHeight)}function Sc(a){var b=Tc(a);a=a.parentWindow||a.defaultView;return C&&uc("10")&&a.pageYOffset!=b.scrollTop?new A(b.scrollLeft,b.scrollTop):new A(a.pageXOffset||b.scrollLeft,a.pageYOffset||b.scrollTop)}function Tc(a){return gc||"CSS1Compat"!=a.compatMode?a.body||a.documentElement:a.documentElement}
-function Uc(a,b,c){var d=arguments,e=document,g=d[0],h=d[1];if(!yc&&h&&(h.name||h.type)){g=["<",g];h.name&&g.push(' name="',ya(h.name),'"');if(h.type){g.push(' type="',ya(h.type),'"');var k={};Rb(k,h);delete k.type;h=k}g.push(">");g=g.join("")}g=e.createElement(g);h&&(u(h)?g.className=h:t(h)?Dc.apply(null,[g].concat(h)):Pc(g,h));2<d.length&&Vc(e,g,d,2);return g}
-function Vc(a,b,c,d){function e(c){c&&b.appendChild(u(c)?a.createTextNode(c):c)}for(;d<c.length;d++){var g=c[d];!fa(g)||ia(g)&&0<g.nodeType?e(g):z(Wc(g)?ab(g):g,e)}}function Xc(a){return document.createElement(a)}function Yc(a){return document.createTextNode(String(a))}function Zc(a,b){Vc(Lc(a),a,arguments,1)}function $c(a){for(var b;b=a.firstChild;)a.removeChild(b)}function F(a){a&&a.parentNode&&a.parentNode.removeChild(a)}
-function ad(a){if(void 0!=a.firstElementChild)a=a.firstElementChild;else for(a=a.firstChild;a&&1!=a.nodeType;)a=a.nextSibling;return a}function bd(a){if(Bc&&!(C&&uc("9")&&!uc("10")&&l.SVGElement&&a instanceof l.SVGElement))return a.parentElement;a=a.parentNode;return ia(a)&&1==a.nodeType?a:null}
-function cd(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}function Lc(a){return 9==a.nodeType?a:a.ownerDocument||a.document}
-function dd(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 $c(a),a.appendChild(Lc(a).createTextNode(String(b)))}function ed(a,b){var c=[];return fd(a,b,c,!0)?c[0]:void 0}function fd(a,b,c,d){if(null!=a)for(a=a.firstChild;a;){if(b(a)&&(c.push(a),d)||fd(a,b,c,d))return!0;a=a.nextSibling}return!1}var gd={SCRIPT:1,STYLE:1,HEAD:1,IFRAME:1,OBJECT:1},hd={IMG:" ",BR:"\n"};
-function id(a,b,c){if(!(a.nodeName in gd))if(3==a.nodeType)c?b.push(String(a.nodeValue).replace(/(\r\n|\r|\n)/g,"")):b.push(a.nodeValue);else if(a.nodeName in hd)b.push(hd[a.nodeName]);else for(a=a.firstChild;a;)id(a,b,c),a=a.nextSibling}function Wc(a){if(a&&"number"==typeof a.length){if(ia(a))return"function"==typeof a.item||"string"==typeof a.item;if(ha(a))return"function"==typeof a.item}return!1}function jd(a,b){return b?kd(a,function(a){return!b||Gc(a,b)},!0):null}
-function kd(a,b,c,d){c||(a=a.parentNode);c=null==d;for(var e=0;a&&(c||e<=d);){if(b(a))return a;a=a.parentNode;e++}return null}function Kc(a){this.a=a||l.document||document}f=Kc.prototype;f.N=function(a){return u(a)?this.a.getElementById(a):a};f.createElement=function(a){return this.a.createElement(a)};function ld(a){return"CSS1Compat"==a.a.compatMode}function md(a){return Sc(a.a)}f.appendChild=function(a,b){a.appendChild(b)};f.append=Zc;
-f.getChildren=function(a){return zc&&void 0!=a.children?a.children:Ka(a.childNodes,function(a){return 1==a.nodeType})};f.contains=cd;function nd(a,b){var c=Lc(a);return c.defaultView&&c.defaultView.getComputedStyle&&(c=c.defaultView.getComputedStyle(a,null))?c[b]||c.getPropertyValue(b)||"":""}function od(a,b){return nd(a,b)||(a.currentStyle?a.currentStyle[b]:null)||a.style&&a.style[b]}function pd(a,b,c){var d,e=fc&&(Zb||kc)&&uc("1.9");b instanceof A?(d=b.x,b=b.y):(d=b,b=c);a.style.left=qd(d,e);a.style.top=qd(b,e)}
-function rd(a){var b;try{b=a.getBoundingClientRect()}catch(c){return{left:0,top:0,right:0,bottom:0}}C&&a.ownerDocument.body&&(a=a.ownerDocument,b.left-=a.documentElement.clientLeft+a.body.clientLeft,b.top-=a.documentElement.clientTop+a.body.clientTop);return b}
-function sd(a){if(C&&!vc(8))return a.offsetParent;var b=Lc(a),c=od(a,"position"),d="fixed"==c||"absolute"==c;for(a=a.parentNode;a&&a!=b;a=a.parentNode)if(c=od(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 null}
-function td(a){for(var b=new zb(0,Infinity,Infinity,0),c=Jc(a),d=c.a.body,e=c.a.documentElement,g=Tc(c.a);a=sd(a);)if(!(C&&0==a.clientWidth||gc&&0==a.clientHeight&&a==d||a==d||a==e||"visible"==od(a,"overflow"))){var h=ud(a),k;k=a;if(fc&&!uc("1.9")){var m=parseFloat(nd(k,"borderLeftWidth"));if(vd(k))var p=k.offsetWidth-k.clientWidth-m-parseFloat(nd(k,"borderRightWidth")),m=m+p;k=new A(m,parseFloat(nd(k,"borderTopWidth")))}else k=new A(k.clientLeft,k.clientTop);h.x+=k.x;h.y+=k.y;b.top=Math.max(b.top,
-h.y);b.right=Math.min(b.right,h.x+a.clientWidth);b.bottom=Math.min(b.bottom,h.y+a.clientHeight);b.left=Math.max(b.left,h.x)}d=g.scrollLeft;g=g.scrollTop;b.left=Math.max(b.left,d);b.top=Math.max(b.top,g);c=Rc(c.a.parentWindow||c.a.defaultView||window);b.right=Math.min(b.right,d+c.width);b.bottom=Math.min(b.bottom,g+c.height);return 0<=b.top&&0<=b.left&&b.bottom>b.top&&b.right>b.left?b:null}
-function ud(a){var b,c=Lc(a),d=od(a,"position"),e=fc&&c.getBoxObjectFor&&!a.getBoundingClientRect&&"absolute"==d&&(b=c.getBoxObjectFor(a))&&(0>b.screenX||0>b.screenY),g=new A(0,0),h;b=c?Lc(c):document;h=!C||vc(9)||ld(Jc(b))?b.documentElement:b.body;if(a==h)return g;if(a.getBoundingClientRect)b=rd(a),a=md(Jc(c)),g.x=b.left+a.x,g.y=b.top+a.y;else if(c.getBoxObjectFor&&!e)b=c.getBoxObjectFor(a),a=c.getBoxObjectFor(h),g.x=b.screenX-a.screenX,g.y=b.screenY-a.screenY;else{b=a;do{g.x+=b.offsetLeft;g.y+=
-b.offsetTop;b!=a&&(g.x+=b.clientLeft||0,g.y+=b.clientTop||0);if(gc&&"fixed"==od(b,"position")){g.x+=c.body.scrollLeft;g.y+=c.body.scrollTop;break}b=b.offsetParent}while(b&&b!=a);if(ec||gc&&"absolute"==d)g.y-=c.body.offsetTop;for(b=a;(b=sd(b))&&b!=c.body&&b!=h;)g.x-=b.scrollLeft,ec&&"TR"==b.tagName||(g.y-=b.scrollTop)}return g}function wd(a,b){var c=xd(a),d=xd(b);return new A(c.x-d.x,c.y-d.y)}
-function yd(a){var b;if(a.getBoundingClientRect)b=rd(a),b=new A(b.left,b.top);else{b=md(Jc(a));var c=ud(a);b=new A(c.x-b.x,c.y-b.y)}if(fc&&!uc(12)){var d;C?d="-ms-transform":gc?d="-webkit-transform":ec?d="-o-transform":fc&&(d="-moz-transform");var e;d&&(e=od(a,d));e||(e=od(a,"transform"));a=e?(a=e.match(zd))?new A(parseFloat(a[1]),parseFloat(a[2])):new A(0,0):new A(0,0);a=new A(b.x+a.x,b.y+a.y)}else a=b;return a}
-function xd(a){if(1==a.nodeType)return yd(a);var b=ha(a.Mx),c=a;a.targetTouches?c=a.targetTouches[0]:b&&a.le.targetTouches&&(c=a.le.targetTouches[0]);return new A(c.clientX,c.clientY)}function Ad(a,b,c){if(b instanceof B)c=b.height,b=b.width;else if(void 0==c)throw Error("missing height argument");Bd(a,b);a.style.height=qd(c,!0)}function qd(a,b){"number"==typeof a&&(a=(b?Math.round(a):a)+"px");return a}function Bd(a,b){a.style.width=qd(b,!0)}
-function Cd(a){var b=Dd;if("none"!=od(a,"display"))return b(a);var c=a.style,d=c.display,e=c.visibility,g=c.position;c.visibility="hidden";c.position="absolute";c.display="inline";a=b(a);c.display=d;c.position=g;c.visibility=e;return a}function Dd(a){var b=a.offsetWidth,c=a.offsetHeight,d=gc&&!b&&!c;return q(b)&&!d||!a.getBoundingClientRect?new B(b,c):(a=rd(a),new B(a.right-a.left,a.bottom-a.top))}function Ed(a){var b=ud(a);a=Cd(a);return new Db(b.x,b.y,a.width,a.height)}
-function Fd(a,b){var c=a.style;"opacity"in c?c.opacity=b:"MozOpacity"in c?c.MozOpacity=b:"filter"in c&&(c.filter=""===b?"":"alpha(opacity="+100*b+")")}function vd(a){return"rtl"==od(a,"direction")}
-function Gd(a){var b=Lc(a),c=C&&a.currentStyle;if(c&&ld(Jc(b))&&"auto"!=c.width&&"auto"!=c.height&&!c.boxSizing)return b=Hd(a,c.width,"width","pixelWidth"),a=Hd(a,c.height,"height","pixelHeight"),new B(b,a);c=new B(a.offsetWidth,a.offsetHeight);b=Id(a);a=Jd(a);return new B(c.width-a.left-b.left-b.right-a.right,c.height-a.top-b.top-b.bottom-a.bottom)}
-function Hd(a,b,c,d){if(/^\d+px?$/.test(b))return parseInt(b,10);var e=a.style[c],g=a.runtimeStyle[c];a.runtimeStyle[c]=a.currentStyle[c];a.style[c]=b;b=a.style[d];a.style[c]=e;a.runtimeStyle[c]=g;return b}function Kd(a,b){var c=a.currentStyle?a.currentStyle[b]:null;return c?Hd(a,c,"left","pixelLeft"):0}
-function Id(a){if(C){var b=Kd(a,"paddingLeft"),c=Kd(a,"paddingRight"),d=Kd(a,"paddingTop");a=Kd(a,"paddingBottom");return new zb(d,c,a,b)}b=nd(a,"paddingLeft");c=nd(a,"paddingRight");d=nd(a,"paddingTop");a=nd(a,"paddingBottom");return new zb(parseFloat(d),parseFloat(c),parseFloat(a),parseFloat(b))}var Ld={thin:2,medium:4,thick:6};
-function Md(a,b){if("none"==(a.currentStyle?a.currentStyle[b+"Style"]:null))return 0;var c=a.currentStyle?a.currentStyle[b+"Width"]:null;return c in Ld?Ld[c]:Hd(a,c,"left","pixelLeft")}
-function Jd(a){if(C&&!vc(9)){var b=Md(a,"borderLeft"),c=Md(a,"borderRight"),d=Md(a,"borderTop");a=Md(a,"borderBottom");return new zb(d,c,a,b)}b=nd(a,"borderLeftWidth");c=nd(a,"borderRightWidth");d=nd(a,"borderTopWidth");a=nd(a,"borderBottomWidth");return new zb(parseFloat(d),parseFloat(c),parseFloat(a),parseFloat(b))}var Nd=/[^\d]+$/,Od={cm:1,"in":1,mm:1,pc:1,pt:1},Pd={em:1,ex:1};
-function Qd(a){var b=od(a,"fontSize"),c;c=(c=b.match(Nd))&&c[0]||null;if(b&&"px"==c)return parseInt(b,10);if(C){if(c in Od)return Hd(a,b,"left","pixelLeft");if(a.parentNode&&1==a.parentNode.nodeType&&c in Pd)return a=a.parentNode,c=od(a,"fontSize"),Hd(a,b==c?"1em":b,"left","pixelLeft")}c=Uc("span",{style:"visibility:hidden;position:absolute;line-height:0;padding:0;margin:0;border:0;height:1em;"});a.appendChild(c);b=c.offsetHeight;F(c);return b}var zd=/matrix\([0-9\.\-]+, [0-9\.\-]+, [0-9\.\-]+, [0-9\.\-]+, ([0-9\.\-]+)p?x?, ([0-9\.\-]+)p?x?\)/;var Rd="StopIteration"in l?l.StopIteration:Error("StopIteration");function Sd(){}Sd.prototype.next=function(){throw Rd;};Sd.prototype.Id=function(){return this};function Td(a){if(a instanceof Sd)return a;if("function"==typeof a.Id)return a.Id(!1);if(fa(a)){var b=0,c=new Sd;c.next=function(){for(;;){if(b>=a.length)throw Rd;if(b in a)return a[b++];b++}};return c}throw Error("Not implemented");}
-function Ud(a,b,c){if(fa(a))try{z(a,b,c)}catch(d){if(d!==Rd)throw d;}else{a=Td(a);try{for(;;)b.call(c,a.next(),void 0,a)}catch(e){if(e!==Rd)throw e;}}}function Vd(a){if(fa(a))return ab(a);a=Td(a);var b=[];Ud(a,function(a){b.push(a)});return b};function Wd(a,b){this.b={};this.a=[];this.g=this.T=0;var c=arguments.length;if(1<c){if(c%2)throw Error("Uneven number of arguments");for(var d=0;d<c;d+=2)this.set(arguments[d],arguments[d+1])}else if(a){a instanceof Wd?(c=a.tc(),d=a.ic()):(c=Kb(a),d=Jb(a));for(var e=0;e<c.length;e++)this.set(c[e],d[e])}}f=Wd.prototype;f.hb=function(){return this.T};f.ic=function(){Xd(this);for(var a=[],b=0;b<this.a.length;b++)a.push(this.b[this.a[b]]);return a};f.tc=function(){Xd(this);return this.a.concat()};
-f.equals=function(a,b){if(this===a)return!0;if(this.T!=a.hb())return!1;var c=b||Yd;Xd(this);for(var d,e=0;d=this.a[e];e++)if(!c(this.get(d),a.get(d)))return!1;return!0};function Yd(a,b){return a===b}f.isEmpty=function(){return 0==this.T};f.clear=function(){this.b={};this.g=this.T=this.a.length=0};f.remove=function(a){return Zd(this.b,a)?(delete this.b[a],this.T--,this.g++,this.a.length>2*this.T&&Xd(this),!0):!1};
-function Xd(a){if(a.T!=a.a.length){for(var b=0,c=0;b<a.a.length;){var d=a.a[b];Zd(a.b,d)&&(a.a[c++]=d);b++}a.a.length=c}if(a.T!=a.a.length){for(var e={},c=b=0;b<a.a.length;)d=a.a[b],Zd(e,d)||(a.a[c++]=d,e[d]=1),b++;a.a.length=c}}f.get=function(a,b){return Zd(this.b,a)?this.b[a]:b};f.set=function(a,b){Zd(this.b,a)||(this.T++,this.a.push(a),this.g++);this.b[a]=b};f.clone=function(){return new Wd(this)};
-f.Id=function(a){Xd(this);var b=0,c=this.a,d=this.b,e=this.g,g=this,h=new Sd;h.next=function(){for(;;){if(e!=g.g)throw Error("The map has changed since the iterator was created");if(b>=c.length)throw Rd;var h=c[b++];return a?h:d[h]}};return h};function Zd(a,b){return Object.prototype.hasOwnProperty.call(a,b)};function $d(a){if("function"==typeof a.ic)return a.ic();if(u(a))return a.split("");if(fa(a)){for(var b=[],c=a.length,d=0;d<c;d++)b.push(a[d]);return b}return Jb(a)}function ae(a,b,c){if("function"==typeof a.forEach)a.forEach(b,c);else if(fa(a)||u(a))z(a,b,c);else{var d;if("function"==typeof a.tc)d=a.tc();else if("function"!=typeof a.ic)if(fa(a)||u(a)){d=[];for(var e=a.length,g=0;g<e;g++)d.push(g)}else d=Kb(a);else d=void 0;for(var e=$d(a),g=e.length,h=0;h<g;h++)b.call(c,e[h],d&&d[h],a)}};function be(a,b,c,d,e){var g="";a&&(g+=a+":");c&&(g+="//",b&&(g+=b+"@"),g+=c,d&&(g+=":"+d));e&&(g+=e);return g}var ce=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([^/#?]*?)(?::([0-9]+))?(?=[/#?]|$))?([^?#]+)?(?:\\?([^#]*))?(?:#(.*))?$");function de(a){if(ee){ee=!1;var b=l.location;if(b){var c=b.href;if(c&&(c=fe(c))&&c!=b.hostname)throw ee=!0,Error();}}return a.match(ce)}var ee=gc;function fe(a){return(a=de(a)[3]||null)&&decodeURIComponent(a)}
-function ge(a){return(a=de(a)[5]||null)&&decodeURIComponent(a)}function he(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]=void 0)}return a.join("")}function ie(a,b,c){if(t(b))for(var d=0;d<b.length;d++)ie(a,String(b[d]),c);else null!=b&&c.push("&",a,""===b?"":"=",encodeURIComponent(String(b)))}function je(a,b,c){Math.max(b.length-(c||0),0);for(c=c||0;c<b.length;c+=2)ie(b[c],b[c+1],a);return a}
-function ke(a,b){for(var c in b)ie(c,b[c],a);return a}function le(a,b){return he(2==arguments.length?je([a],arguments[1],0):je([a],arguments,1))}function me(a,b,c){a=[a,"&",b];null!=c&&a.push("=",encodeURIComponent(String(c)));return he(a)}function ne(a,b,c,d){for(var e=c.length;0<=(b=a.indexOf(c,b))&&b<d;){var g=a.charCodeAt(b-1);if(38==g||63==g)if(g=a.charCodeAt(b+e),!g||61==g||38==g||35==g)return b;b+=e+1}return-1}var oe=/#|$/,pe=/[?&]($|#)/;
-function qe(a,b){for(var c=a.search(oe),d=0,e,g=[];0<=(e=ne(a,d,b,c));)g.push(a.substring(d,e)),d=Math.min(a.indexOf("&",e)+1||c,c);g.push(a.substr(d));return g.join("").replace(pe,"$1")};function re(a,b){var c;if(a instanceof re)this.Ze=q(b)?b:a.Ze,se(this,a.Nf),this.Ii=a.Ii,te(this,a.Ne),ue(this,a.ih),this.jh=a.jh,ve(this,a.a.clone()),we(this,a.ql);else if(a&&(c=de(String(a)))){this.Ze=!!b;se(this,c[1]||"",!0);var d=c[2]||"";this.Ii=d?decodeURIComponent(d):"";te(this,c[3]||"",!0);ue(this,c[4]);this.jh=(d=c[5]||"")?decodeURIComponent(d):"";ve(this,c[6]||"",!0);we(this,c[7]||"",!0)}else this.Ze=!!b,this.a=new xe(null,0,this.Ze)}f=re.prototype;f.Nf="";f.Ii="";f.Ne="";f.ih=null;
-f.jh="";f.ql="";f.Ze=!1;f.toString=function(){var a=[],b=this.Nf;b&&a.push(ye(b,ze),":");if(b=this.Ne){a.push("//");var c=this.Ii;c&&a.push(ye(c,ze),"@");a.push(encodeURIComponent(String(b)));b=this.ih;null!=b&&a.push(":",String(b))}if(b=this.jh)this.Ne&&"/"!=b.charAt(0)&&a.push("/"),a.push(ye(b,"/"==b.charAt(0)?Ae:Be));(b=this.a.toString())&&a.push("?",b);(b=this.ql)&&a.push("#",ye(b,Ce));return a.join("")};f.clone=function(){return new re(this)};
-function se(a,b,c){a.Nf=c?b?decodeURIComponent(b):"":b;a.Nf&&(a.Nf=a.Nf.replace(/:$/,""))}function te(a,b,c){a.Ne=c?b?decodeURIComponent(b):"":b}function ue(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.ih=b}else a.ih=null}function ve(a,b,c){b instanceof xe?(a.a=b,De(a.a,a.Ze)):(c||(b=ye(b,Ee)),a.a=new xe(b,0,a.Ze))}function Fe(a,b,c){a.a.set(b,c)}function Ge(a,b,c){t(c)||(c=[String(c)]);He(a.a,b,c)}function we(a,b,c){a.ql=c?b?decodeURIComponent(b):"":b;return a}
-function Ie(a){Fe(a,"zx",Math.floor(2147483648*Math.random()).toString(36)+Math.abs(Math.floor(2147483648*Math.random())^x()).toString(36));return a}function Je(a){return a instanceof re?a.clone():new re(a,void 0)}function Ke(a,b,c,d){var e=new re(null,void 0);a&&se(e,a);b&&te(e,b);c&&ue(e,c);d&&(e.jh=d);return e}function ye(a,b){return u(a)?encodeURI(a).replace(b,Le):null}function Le(a){a=a.charCodeAt(0);return"%"+(a>>4&15).toString(16)+(a&15).toString(16)}
-var ze=/[#\/\?@]/g,Be=/[\#\?:]/g,Ae=/[\#\?]/g,Ee=/[\#\?@]/g,Ce=/#/g;function xe(a,b,c){this.a=a||null;this.b=!!c}function Me(a){if(!a.Ja&&(a.Ja=new Wd,a.T=0,a.a))for(var b=a.a.split("&"),c=0;c<b.length;c++){var d=b[c].indexOf("="),e=null,g=null;0<=d?(e=b[c].substring(0,d),g=b[c].substring(d+1)):e=b[c];e=xa(e);e=Ne(a,e);a.add(e,g?xa(g):"")}}f=xe.prototype;f.Ja=null;f.T=null;f.hb=function(){Me(this);return this.T};
-f.add=function(a,b){Me(this);this.a=null;a=Ne(this,a);var c=this.Ja.get(a);c||this.Ja.set(a,c=[]);c.push(b);this.T++;return this};f.remove=function(a){Me(this);a=Ne(this,a);return Zd(this.Ja.b,a)?(this.a=null,this.T-=this.Ja.get(a).length,this.Ja.remove(a)):!1};f.clear=function(){this.Ja=this.a=null;this.T=0};f.isEmpty=function(){Me(this);return 0==this.T};function Oe(a,b){Me(a);b=Ne(a,b);return Zd(a.Ja.b,b)}
-f.tc=function(){Me(this);for(var a=this.Ja.ic(),b=this.Ja.tc(),c=[],d=0;d<b.length;d++)for(var e=a[d],g=0;g<e.length;g++)c.push(b[d]);return c};f.ic=function(a){Me(this);var b=[];if(u(a))Oe(this,a)&&(b=$a(b,this.Ja.get(Ne(this,a))));else{a=this.Ja.ic();for(var c=0;c<a.length;c++)b=$a(b,a[c])}return b};f.set=function(a,b){Me(this);this.a=null;a=Ne(this,a);Oe(this,a)&&(this.T-=this.Ja.get(a).length);this.Ja.set(a,[b]);this.T++;return this};
-f.get=function(a,b){var c=a?this.ic(a):[];return 0<c.length?String(c[0]):b};function He(a,b,c){a.remove(b);0<c.length&&(a.a=null,a.Ja.set(Ne(a,b),ab(c)),a.T+=c.length)}f.toString=function(){if(this.a)return this.a;if(!this.Ja)return"";for(var a=[],b=this.Ja.tc(),c=0;c<b.length;c++)for(var d=b[c],e=encodeURIComponent(String(d)),d=this.ic(d),g=0;g<d.length;g++){var h=e;""!==d[g]&&(h+="="+encodeURIComponent(String(d[g])));a.push(h)}return this.a=a.join("&")};
-f.clone=function(){var a=new xe;a.a=this.a;this.Ja&&(a.Ja=this.Ja.clone(),a.T=this.T);return a};function Ne(a,b){var c=String(b);a.b&&(c=c.toLowerCase());return c}function De(a,b){b&&!a.b&&(Me(a),a.a=null,ae(a.Ja,function(a,b){var e=b.toLowerCase();b!=e&&(this.remove(b),He(this,e,a))},a));a.b=b};function Pe(a,b,c){a.dataset?a.dataset[Qe(b)]=c:a.setAttribute("data-"+b,c)}function G(a,b){return a.dataset?a.dataset[Qe(b)]:a.getAttribute("data-"+b)}var Re={};function Qe(a){return Re[a]||(Re[a]=String(a).replace(/\-([a-z])/g,function(a,c){return c.toUpperCase()}))};var Se=n("yt.dom.getNextId_");if(!Se){Se=function(){return++Te};pa("yt.dom.getNextId_",Se);var Te=0}function Ue(a,b){a=Mc(a);b=Mc(b);return!!kd(a,function(a){return a===b},!0,void 0)}function Ve(a,b){var c=Oc(a,null,b);return c.length?c[0]:null}function We(a,b){if(a in b)return b[a];var c=a.charAt(0).toUpperCase()+a.substr(1);if("moz"+c in b)return b["moz"+c];if("ms"+c in b)return b["ms"+c];if("o"+c in b)return b["o"+c];if("webkit"+c in b)return b["webkit"+c]}
-function Xe(a,b){var c;Ma(a,function(a){c=We(a,b);return!!c});return c}function Ye(a,b){return"on"+a in b?a:"onmoz"+a in b?"moz"+a:"onms"+a in b?"ms"+a:"ono"+a in b?"o"+a:"onwebkit"+a in b?"webkit"+a:null};var Ze=window.yt&&window.yt.config_||{};pa("yt.config_",Ze);var $e=window.yt&&window.yt.tokens_||{};pa("yt.tokens_",$e);var af=window.yt&&window.yt.msgs_||{};pa("yt.msgs_",af);function bf(a){cf(Ze,arguments)}function df(a,b){return a in Ze?Ze[a]:b}function ef(a){cf($e,arguments)}function ff(a){return a in $e?$e[a]:void 0}function H(a,b){ha(a)&&(a=gf(a));return window.setTimeout(a,b)}function hf(a,b){ha(a)&&(a=gf(a));return window.setInterval(a,b)}function I(a){window.clearTimeout(a)}
-function jf(a){window.clearInterval(a)}function gf(a){return a&&window.yterr?function(){try{return a.apply(this,arguments)}catch(b){throw kf(b),b;}}:a}function kf(a){if(window&&window.yterr){var b=n("yt.www.errors.log");b?b(a):(b=df("ERRORS")||[],b.push(a),bf("ERRORS",b))}}function lf(a){cf(af,arguments)}function mf(a,b,c){var d=b||{};if(a=a in af?af[a]:c)for(var e in d)a=a.replace(RegExp("\\$"+e,"gi"),function(){return d[e]});return a}function nf(a,b){return of(a in af?af[a]:{},b)}
-function of(a,b){var c=df("I18N_PLURAL_RULES")||function(a){return 1==a?"one":"other"};return(c=a["case"+b]||a[c(b)])?c.replace("#",b.toString()):b+""}function cf(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]}};function pf(a){if(a=a||window.event){for(var b in a)b in qf||(this[b]=a[b]);this.scale=a.scale;this.rotation=a.rotation;this.dd=a;(b=a.target||a.srcElement)&&3==b.nodeType&&(b=b.parentNode);this.target=b;if(b=a.relatedTarget)try{b=b.nodeName&&b}catch(c){b=null}else"mouseover"==this.type?b=a.fromElement:"mouseout"==this.type&&(b=a.toElement);this.relatedTarget=b;this.clientX=void 0!=a.clientX?a.clientX:a.pageX;this.clientY=void 0!=a.clientY?a.clientY:a.pageY;this.keyCode=a.keyCode?a.keyCode:a.which;
-this.charCode=a.charCode||("keypress"==this.type?this.keyCode:0);this.altKey=a.altKey;this.ctrlKey=a.ctrlKey;this.shiftKey=a.shiftKey;"MozMousePixelScroll"==this.type?(this.wheelDeltaX=a.axis==a.HORIZONTAL_AXIS?a.detail:0,this.wheelDeltaY=a.axis==a.HORIZONTAL_AXIS?0:a.detail):window.opera?(this.wheelDeltaX=0,this.wheelDeltaY=a.detail):0==a.wheelDelta%120?"WebkitTransform"in document.documentElement.style?window.chrome&&0==navigator.platform.indexOf("Mac")?(this.wheelDeltaX=a.wheelDeltaX/-30,this.wheelDeltaY=
-a.wheelDeltaY/-30):(this.wheelDeltaX=a.wheelDeltaX/-1.2,this.wheelDeltaY=a.wheelDeltaY/-1.2):(this.wheelDeltaX=0,this.wheelDeltaY=a.wheelDelta/-1.6):(this.wheelDeltaX=a.wheelDeltaX/-3,this.wheelDeltaY=a.wheelDeltaY/-3);this.a=a.pageX;this.b=a.pageY}}function rf(a){if(document.body&&document.documentElement){var b=document.body.scrollTop+document.documentElement.scrollTop;a.a=a.clientX+(document.body.scrollLeft+document.documentElement.scrollLeft);a.b=a.clientY+b}}
-function sf(a){q(a.a)||rf(a);return a.a}function tf(a){q(a.b)||rf(a);return a.b}f=pf.prototype;f.dd=null;f.type="";f.target=null;f.relatedTarget=null;f.currentTarget=null;f.data=null;f.source=null;f.state=null;f.keyCode=0;f.charCode=0;f.altKey=!1;f.ctrlKey=!1;f.shiftKey=!1;f.clientX=0;f.clientY=0;f.wheelDeltaX=0;f.wheelDeltaY=0;f.rotation=0;f.scale=1;f.preventDefault=function(){this.dd.returnValue=!1;this.dd.preventDefault&&this.dd.preventDefault()};
-f.stopPropagation=function(){this.dd.cancelBubble=!0;this.dd.stopPropagation&&this.dd.stopPropagation()};f.stopImmediatePropagation=function(){this.dd.cancelBubble=!0;this.dd.stopImmediatePropagation&&this.dd.stopImmediatePropagation()};var qf={stopImmediatePropagation:1,stopPropagation:1,preventMouseEvent:1,preventManipulation:1,preventDefault:1,layerX:1,layerY:1,scale:1,rotation:1};var uf=n("yt.events.listeners_")||{};pa("yt.events.listeners_",uf);var vf=n("yt.events.counter_")||{count:0};pa("yt.events.counter_",vf);function wf(a,b,c,d){return Mb(uf,function(e){return e[0]==a&&e[1]==b&&e[2]==c&&e[4]==!!d})}
-function J(a,b,c,d){if(!a||!a.addEventListener&&!a.attachEvent)return"";d=!!d;var e=wf(a,b,c,d);if(e)return e;var e=++vf.count+"",g=!("mouseenter"!=b&&"mouseleave"!=b||!a.addEventListener||"onmouseenter"in document),h;h=g?function(d){d=new pf(d);if(!kd(d.relatedTarget,function(b){return b==a},!0))return d.currentTarget=a,d.type=b,c.call(a,d)}:function(b){b=new pf(b);b.currentTarget=a;return c.call(a,b)};h=gf(h);uf[e]=[a,b,c,h,d];a.addEventListener?"mouseenter"==b&&g?a.addEventListener("mouseover",
-h,d):"mouseleave"==b&&g?a.addEventListener("mouseout",h,d):"mousewheel"==b&&"MozBoxSizing"in document.documentElement.style?a.addEventListener("MozMousePixelScroll",h,d):a.addEventListener(b,h,d):a.attachEvent("on"+b,h);return e}function xf(a,b){var c;return c=J(a,"timeupdate",function(){yf(c);b.apply(a,arguments)},void 0)}
-function zf(a,b,c){b=b.toLowerCase();var d=c,e="mouse"+b;if(We("pointerEnabled",window.navigator))e="MSPointer"+b.charAt(0).toUpperCase()+b.substr(1);else if(Ye("touchstart",document)){d=b;switch(b){case "down":d="start";break;case "up":d="end";break;case "over":d="enter";break;case "out":d="leave"}e="touch"+d;d=function(a){z(null,function(b){var d=new pf(a);w(d,b);c(d)})}}return J(a,e,d)}function Af(a,b,c){Bf(a,"change",b,function(a){return a.nodeName.toLowerCase()===c.toLowerCase()&&!0})}
-function Cf(a,b,c){return Bf(a,"click",b,function(a){return Gc(a,c)})}function Bf(a,b,c,d){var e=a||document;return J(e,b,function(a){var b=kd(a.target,function(a){return a===e||d(a)},!0);b&&b!==e&&!b.disabled&&(a.currentTarget=b,c.call(b,a))})}function yf(a){a&&("string"==typeof a&&(a=[a]),z(a,function(a){if(a in uf){var c=uf[a],d=c[0],e=c[1],g=c[3],c=c[4];d.removeEventListener?d.removeEventListener(e,g,c):d.detachEvent&&d.detachEvent("on"+e,g);delete uf[a]}}))}
-function Df(a){for(var b in uf)uf[b][0]==a&&yf(b)}function Ef(a,b){if(document.createEvent){var c=document.createEvent("HTMLEvents");c.initEvent(b,!0,!0);a.dispatchEvent(c)}else c=document.createEventObject(),a.fireEvent("on"+b,c)};function Ff(){return!!Xe(["fullscreenEnabled","fullScreenEnabled"],document)}function Gf(){return Xe(["fullscreenElement","fullScreenElement"],document)};function Hf(a){a=a||{};this.url=a.url||"";this.urlV8=a.url_v8||"";this.urlV9As2=a.url_v9as2||"";this.args=a.args||Ob(If);this.assets=a.assets||{};this.attrs=a.attrs||Ob(Jf);this.params=a.params||Ob(Kf);this.minVersion=a.min_version||"8.0.0";this.fallback=a.fallback||null;this.fallbackMessage=a.fallbackMessage||null;this.html5=!!a.html5;this.disable=a.disable||{};this.loaded=!!a.loaded}var If={enablejsapi:1},Jf={},Kf={allowscriptaccess:"always",allowfullscreen:"true",bgcolor:"#000000"};
-Hf.prototype.clone=function(){var a=new Hf,b;for(b in this){var c=this[b];"object"==da(c)?a[b]=Ob(c):a[b]=c}return a};function Lf(a){a&&(this.name=ya(a.name),this.nb=a.screenId,this.kc=a.loungeToken,this.zb=a.dialId||"")}f=Lf.prototype;f.name="";f.nb="";f.kc="";f.zb="";f.Yp=function(){return{key:this.nb,name:this.name}};f.toString=function(){var a=this.kc?this.kc.slice(-6):"null";return"{name:"+this.name+",screenId:"+this.nb+",loungeToken:..."+a+",dialId:"+this.zb+"}"};function Mf(a){return a?a.toString():"null"}function Nf(a){a=a||[];return"["+La(a,function(a){return Mf(a)}).join(",")+"]"};function Of(a){this.a=a}var Pf=/\s*;\s*/;f=Of.prototype;f.set=function(a,b,c,d,e,g){if(/[;=\s]/.test(a))throw Error('Invalid cookie name "'+a+'"');if(/[;\r\n]/.test(b))throw Error('Invalid cookie value "'+b+'"');q(c)||(c=-1);e=e?";domain="+e:"";d=d?";path="+d:"";g=g?";secure":"";c=0>c?"":0==c?";expires="+(new Date(1970,1,1)).toUTCString():";expires="+(new Date(x()+1E3*c)).toUTCString();this.a.cookie=a+"="+b+e+d+c+g};
-f.get=function(a,b){for(var c=a+"=",d=(this.a.cookie||"").split(Pf),e=0,g;g=d[e];e++){if(0==g.lastIndexOf(c,0))return g.substr(c.length);if(g==a)return""}return b};f.remove=function(a,b,c){var d=q(this.get(a));this.set(a,"",0,b,c);return d};f.tc=function(){return Qf(this).keys};f.ic=function(){return Qf(this).Fv};f.isEmpty=function(){return!this.a.cookie};f.hb=function(){return this.a.cookie?(this.a.cookie||"").split(Pf).length:0};f.clear=function(){for(var a=Qf(this).keys,b=a.length-1;0<=b;b--)this.remove(a[b])};
-function Qf(a){a=(a.a.cookie||"").split(Pf);for(var b=[],c=[],d,e,g=0;e=a[g];g++)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,Fv:c}}var Rf=new Of(document);Rf.b=3950;function Sf(){};function Tf(){}y(Tf,Sf);Tf.prototype.hb=function(){var a=0;Ud(this.Id(!0),function(){a++});return a};Tf.prototype.clear=function(){var a=Vd(this.Id(!0)),b=this;z(a,function(a){b.remove(a)})};function Uf(a){this.a=a}y(Uf,Tf);f=Uf.prototype;f.isAvailable=function(){if(!this.a)return!1;try{return this.a.setItem("__sak","1"),this.a.removeItem("__sak"),!0}catch(a){return!1}};f.set=function(a,b){try{this.a.setItem(a,b)}catch(c){if(0==this.a.length)throw"Storage mechanism: Storage disabled";throw"Storage mechanism: Quota exceeded";}};f.get=function(a){a=this.a.getItem(a);if(!u(a)&&null!==a)throw"Storage mechanism: Invalid value was encountered";return a};f.remove=function(a){this.a.removeItem(a)};
-f.hb=function(){return this.a.length};f.Id=function(a){var b=0,c=this.a,d=new Sd;d.next=function(){if(b>=c.length)throw Rd;var d;d=c.key(b++);if(a)return d;d=c.getItem(d);if(!u(d))throw"Storage mechanism: Invalid value was encountered";return d};return d};f.clear=function(){this.a.clear()};f.key=function(a){return this.a.key(a)};function Vf(){var a=null;try{a=window.localStorage||null}catch(b){}this.a=a}y(Vf,Uf);function Wf(){var a=null;try{a=window.sessionStorage||null}catch(b){}this.a=a}y(Wf,Uf);function Xf(a){this.If=a;this.Tp=new rb}f=Xf.prototype;f.If=null;f.Tp=null;f.set=function(a,b){q(b)?this.If.set(a,qb(this.Tp,b)):this.If.remove(a)};f.get=function(a){var b;try{b=this.If.get(a)}catch(c){return}if(null!==b)try{return nb(b)}catch(d){throw"Storage: Invalid value was encountered";}};f.remove=function(a){this.If.remove(a)};function Yf(a){Xf.call(this,a)}y(Yf,Xf);function Zf(a){this.data=a}function $f(a){return!q(a)||a instanceof Zf?a:new Zf(a)}Yf.prototype.set=function(a,b){Yf.C.set.call(this,a,$f(b))};Yf.prototype.a=function(a){a=Yf.C.get.call(this,a);if(!q(a)||a instanceof Object)return a;throw"Storage: Invalid value was encountered";};Yf.prototype.get=function(a){if(a=this.a(a)){if(a=a.data,!q(a))throw"Storage: Invalid value was encountered";}else a=void 0;return a};function ag(a){Xf.call(this,a)}y(ag,Yf);function bg(a){var b=a.creation;a=a.expiration;return!!a&&a<x()||!!b&&b>x()}ag.prototype.set=function(a,b,c){if(b=$f(b)){if(c){if(c<x()){ag.prototype.remove.call(this,a);return}b.expiration=c}b.creation=x()}ag.C.set.call(this,a,b)};ag.prototype.a=function(a,b){var c=ag.C.a.call(this,a);if(c)if(!b&&bg(c))ag.prototype.remove.call(this,a);else return c};function cg(a){Xf.call(this,a)}y(cg,ag);function dg(a,b){var c=[];Ud(b,function(a){var b;try{b=cg.prototype.a.call(this,a,!0)}catch(g){if("Storage: Invalid value was encountered"==g)return;throw g;}q(b)?bg(b)&&c.push(a):c.push(a)},a);return c}function eg(a,b){var c=dg(a,b);z(c,function(a){cg.prototype.remove.call(this,a)},a)};function fg(a,b,c){var d=c&&0<c?c:0;c=d?x()+1E3*d:0;if((d=d?gg:hg)&&window.JSON){u(b)||(b=JSON.stringify(b,void 0));try{d.set(a,b,c)}catch(e){d.remove(a)}}}function ig(a){if(!hg&&!gg||!window.JSON)return null;var b;try{b=hg.get(a),b=u(b)?b:gg.get(a)}catch(c){return null}if(!u(b))return null;try{b=JSON.parse(b,void 0)}catch(d){}return b}function jg(a){hg&&hg.remove(a);gg&&gg.remove(a)}var gg,kg=new Vf;gg=kg.isAvailable()?new cg(kg):null;var hg,lg=new Wf;hg=lg.isAvailable()?new cg(lg):null;function mg(a){a&&(this.id=a.id||"",this.name=ya(a.name||""),this.activityId=a.activityId||"",this.status=a.status||"UNKNOWN")}f=mg.prototype;f.id="";f.name="";f.activityId="";f.status="UNKNOWN";f.Yp=function(){return{key:this.id,name:this.name}};function ng(a){return{id:a.id,name:a.name,activityId:a.activityId,status:a.status}}f.toString=function(){return"{id:"+this.id+",name:"+this.name+",activityId:"+this.activityId+",status:"+this.status+"}"};
-function og(a){a=a||[];return"["+La(a,function(a){return a?a.toString():"null"}).join(",")+"]"};function pg(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(a){var b=16*Math.random()|0;return("x"==a?b:b&3|8).toString(16)})}function qg(a,b){return Pa(a,function(a){return a.key==b})}function rg(a){return La(a,function(a){return a.Yp()})}function sg(a){return La(a,function(a){return ng(a)})}function tg(a){return La(a,function(a){return new mg(a)})}function ug(a,b){return a||b?a&&b?a.id==b.id&&a.name==b.name:!1:!0}
-function vg(a,b){return Pa(a,function(a){return a.id==b})}function wg(a){return La(a,function(a){return{name:a.name,screenId:a.nb,loungeToken:a.kc,dialId:a.zb}})}function xg(a){return La(a,function(a){return new Lf(a)})}function yg(a,b){return a||b?a&&b?a.nb==b.nb:!1:!0}function zg(a,b){return a||b?a&&b?a.nb==b.nb&&a.kc==b.kc&&a.name==b.name&&a.zb==b.zb:!1:!0}function Ag(a,b){return Pa(a,function(a){return yg(a,b)})}function Bg(a,b){return Pa(a,function(a){return b==a.nb||b==a.zb})};function Cg(){var a=Dg(),b=Eg();Ta(a,b);Fg()&&lb(a,b);a=Gg(a);Ua(a)?Rf.remove("remote_sid","/","youtube.com"):(a=a.join(","),Rf.set("remote_sid",a,void 0,"/","youtube.com"))}function Dg(){var a=ig("yt-remote-connected-devices")||[];gb(a);return a}function Gg(a){if(Ua(a))return[];var b=a[0].indexOf("#"),c=-1==b?a[0]:a[0].substring(0,b);return La(a,function(a,b){return 0==b?a:a.substring(c.length)})}function Hg(a){fg("yt-remote-connected-devices",a,86400)}
-function Eg(){if(Ig)return Ig;var a=ig("yt-remote-device-id");a||(a=pg(),fg("yt-remote-device-id",a,31536E3));for(var b=Dg(),c=1,d=a;Ta(b,d);)c++,d=a+"#"+c;return Ig=d}function Jg(){return ig("yt-remote-session-browser-channel")}function Fg(){return ig("yt-remote-session-screen-id")}
-function Kg(a){5<a.length&&(a=a.slice(a.length-5));var b=La(Lg(),function(a){return a.loungeToken}),c=La(a,function(a){return a.loungeToken});Na(c,function(a){return!Ta(b,a)})&&fg("yt-remote-lounge-token-expiration",!0,86400);fg("yt-remote-local-screens",a,31536E3)}function Lg(){return ig("yt-remote-local-screens")||[]}function Mg(){return ig("yt-remote-online-screens")||[]}function Ng(a){fg("yt-remote-online-dial-devices",a,30)}function Og(){return ig("yt-remote-online-dial-devices")||[]}
-function Pg(a,b){a?fg("yt-remote-session-video-id",a):jg("yt-remote-session-video-id");b?fg("yt-remote-session-list-id",b):jg("yt-remote-session-list-id")}function Qg(a){a||(jg("yt-remote-session-screen-id"),jg("yt-remote-session-video-id"),jg("yt-remote-session-list-id"));Cg();a=Dg();Xa(a,Eg());Hg(a)}var Ig="";function Rg(){var a=xg(Mg()),b=tg(Og()),b=Ka(b,function(b){return!Bg(a,b.id)});return rg($a(a,b))};function K(){}K.prototype.Mc=!1;K.prototype.ka=function(){return this.Mc};K.prototype.dispose=function(){this.Mc||(this.Mc=!0,this.H())};function L(a,b){Sg(a,oa(Tg,b))}function Sg(a,b){a.rb||(a.rb=[]);a.rb.push(v(b,void 0))}K.prototype.H=function(){if(this.rb)for(;this.rb.length;)this.rb.shift()()};function Tg(a){a&&"function"==typeof a.dispose&&a.dispose()}function Ug(a){for(var b=0,c=arguments.length;b<c;++b){var d=arguments[b];fa(d)?Ug.apply(null,d):Tg(d)}};function Vg(a,b){this.app=a;this.b=null;this.i={};this.g={};this.o={};this.k={};this.j=null;this.a=b;M(this,"cueVideoById",this.ls);M(this,"loadVideoById",this.Lj);M(this,"cueVideoByUrl",this.ms);M(this,"loadVideoByUrl",this.Ms);M(this,"playVideo",this.rg);M(this,"pauseVideo",this.Qj);M(this,"stopVideo",this.uj);M(this,"clearVideo",this.js);M(this,"getVideoBytesLoaded",this.Bs);M(this,"getVideoBytesTotal",this.Cs);M(this,"getVideoLoadedFraction",this.Es);M(this,"getVideoStartBytes",this.Fs);M(this,
-"cuePlaylist",this.ks);M(this,"loadPlaylist",this.Ls);M(this,"nextVideo",this.Os);M(this,"previousVideo",this.Ps);M(this,"playVideoAt",this.hm);M(this,"setShuffle",this.Us);M(this,"setLoop",this.Rs);M(this,"getPlaylist",this.vb);M(this,"getPlaylistIndex",this.Tj);M(this,"getPlaylistId",this.zs);M(this,"loadModule",this.Ks);M(this,"unloadModule",this.Tm);M(this,"setOption",this.Sm);M(this,"getOption",this.tj);M(this,"getOptions",this.vs);M(this,"mute",this.Fm);M(this,"unMute",this.Hm);M(this,"isMuted",
-this.Is);M(this,"setVolume",this.Gm);M(this,"getVolume",this.Em);M(this,"seekTo",this.Oh);M(this,"getPlayerState",this.ys);M(this,"getPlaybackRate",this.xs);M(this,"setPlaybackRate",this.Ts);M(this,"getAvailablePlaybackRates",this.rs);M(this,"getPlaybackQuality",this.ws);M(this,"setPlaybackQuality",this.Ss);M(this,"getAvailableQualityLevels",this.ts);M(this,"getCurrentTime",this.getCurrentTime);M(this,"getDuration",this.Gh);M(this,"addEventListener",this.addEventListener);M(this,"removeEventListener",
-this.removeEventListener);M(this,"getVideoUrl",this.Gs);M(this,"getDebugText",this.us);M(this,"getVideoEmbedCode",this.Ds);M(this,"getVideoData",this.getVideoData);M(this,"addCueRange",this.is);M(this,"removeCueRange",this.Qs);M(this,"setSize",this.Vs);M(this,"getApiInterface",this.os);M(this,"destroy",this.destroy);M(this,"showVideoInfo",this.Ws);M(this,"hideVideoInfo",this.Hs);this.g.logFallback=v(this.Ns,this);this.g.isNotServable=v(this.Js,this);this.g.getUpdatedConfigurationData=v(this.As,this);
-this.g.updateRemoteReceivers=v(this.Xs,this)}y(Vg,K);function M(a,b,c){a.i[b]=v(c,a)}f=Vg.prototype;f.os=function(){return Kb(this.i)};f.N=function(){return this.b};f.addEventListener=function(a,b){var c=b;u(b)&&(c=function(){n(b).apply(window,arguments)},this.o[b]=c);this.app.D(a,c)};f.Xt=function(a,b){var c=u(b)?a+b:a+ja(b);if(!this.k[c]){u(b)&&(b=function(){n(b).apply(window,arguments)});var d=v(function(a){b({target:this.j,data:a})},this);this.k[c]=d;this.addEventListener(a,d)}};
-f.removeEventListener=function(a,b){var c=b;if(u(b)&&b in this.o){var c=this.o[b],d=this.o;b in d&&delete d[b]}this.app.$(a,c)};f.Yt=function(a,b){var c=u(b)?a+b:a+ja(b);this.k[c]&&this.removeEventListener(a,this.k[c])};f.ys=function(){return this.app.aa};f.Oh=function(a,b){Wg(this.app,!0,this.a);Xg(this.app,a,b,void 0,this.a)};f.getCurrentTime=function(){var a=this.app.Ud;return a&&N(this.app).b!=a?a.getCurrentTime():this.app.getCurrentTime(this.a)};
-f.Gh=function(){var a=this.app.Ud;return a?a.Rd:0};f.Em=function(){return this.app.wa.volume};f.Gm=function(a){var b=this.app;b.wa.volume=a;b.u("internalvolumechange",b.wa)};f.Is=function(){return this.app.wa.muted};f.Fm=function(){Yg(this.app)};f.Hm=function(){Zg(this.app)};f.rg=function(){Wg(this.app,!0,this.a);$g(this.app,this.a)};f.Qj=function(){ah(this.app,this.a)};f.uj=function(){var a=this.app;bh(a,"play_pause")||ch(a,this.a)};f.js=function(){};f.xs=function(){return this.app.Dg};
-f.Ts=function(a){dh(this.app,a)};f.rs=function(){return this.app.a.gg?eh:[1]};f.ws=function(){return fh(this.app,this.a)};f.Ss=function(a){var b=N(this.app,this.a);b&&gh(b,"m",a)};f.ts=function(){return hh(this.app,this.a)};f.Bs=function(){var a=ih(this.app.Ud);return Math.floor(1E3*a)};f.Cs=function(){return 1E3};f.Es=function(){return ih(this.app.Ud)};f.Fs=function(){return 0};f.Vs=function(){this.app.R.zi()};f.Ks=function(a){(a=jh(this.app.k,a))&&a.load()};
-f.Tm=function(a){(a=jh(this.app.k,a))&&a.unload()};f.Lj=function(a,b,c){var d=this.app,e=this.a;a=kh(d,lh(a,d.list,b,c),e);Wg(d,a,e)};f.ls=function(a,b,c){var d=this.app,e=this.a;mh(d,new nh(lh(a,d.list,b,c)),e)};f.Ms=function(a,b,c){var d=this.app,e=this.a;a=oh(a,d.list,b,c);b=kh(d,a,e);Wg(d,b,e);ph(d,a.mediaContentUrl)};f.ms=function(a,b,c){var d=this.app,e=this.a;a=oh(a,d.list,b,c);mh(d,new nh(a),e);ph(d,a.mediaContentUrl)};f.Gs=function(){return qh(this.app)};f.us=function(){return rh(this.app)};
-f.Ds=function(){return""};f.is=function(){return!1};f.Qs=function(){};f.Ls=function(a,b,c,d){var e=this.app;e.Xe=!1;sh(e,a,b,c,d)};f.ks=function(a,b,c,d){var e=this.app;e.Xe=!0;sh(e,a,b,c,d)};f.Os=function(){th(this.app)};f.Ps=function(){uh(this.app)};f.hm=function(a){var b=this.app;b.g&&(b.g.Vd?vh(b,wh(b.g,a)):b.Xe=!1,xh(b.g,a))};f.Us=function(a){var b=this.app;b.g&&yh(b.g,a)};f.Rs=function(a){var b=this.app;b.g&&(b.g.loop=a)};
-f.vb=function(){var a=this.app.g;if(!a)return null;for(var b=[],c=0;c<a.Mb;c++)b[c]=wh(a,c).M;return b};f.Tj=function(){var a=this.app.g?this.app.g.ua:null;return null==a?-1:a};f.zs=function(){return this.app.g&&this.app.g.g?this.app.g.g.toString():null};f.Sm=function(a,b,c){return zh(this.app.k,a,b,c)};f.tj=function(a,b,c){return zh(this.app.k,a,b,c)};f.vs=function(a){return Ah(this.app.k,a)};f.getVideoData=function(){var a=this.app.getVideoData(this.a)||{};return{video_id:a.M,author:a.author,title:a.title}};
-f.Ws=function(){Bh(this.app.R)};f.Hs=function(){this.app.R.jk()};f.Ns=function(){Ch(this.app.b,204)};f.Js=function(){var a=Dh(this.app);return!(!a||!P(a,128)||5!=a.a.errorCode)};f.As=function(){var a=this.app,b=a.J.clone();if(a=a.b.getVideoData()){var c=b.args,d=Ob(a.b);d.start=a.ya;w(c,d)}return b};f.Xs=function(a){var b=this.app;Eh(b.a)&&6!=b.o&&(b.a.qg=!Ua(a),b.a.qg?1!=b.o&&3!=b.o&&Fh(b):Gh(b.G))};f.destroy=function(){this.app.dispose()};
-f.H=function(){if(this.b){for(var a in this.i)this.b[a]=null;for(a in this.g)this.b[a]=null}this.o=this.k=this.b=null;Vg.C.H.call(this)};function Hh(a,b){Vg.call(this,a,b);M(this,"cueVideoByPlayerVars",this.qx);M(this,"loadVideoByPlayerVars",this.wo);M(this,"preloadVideoByPlayerVars",this.tx);M(this,"seekBy",this.Gp);M(this,"enableLicenseIntercept",this.rx);M(this,"updatePlaylist",this.wx);M(this,"resumeLicenseSession",this.ux);M(this,"updateLastActiveTime",this.vx);M(this,"updateVideoData",this.xx);M(this,"getStoryboardFormat",this.sx)}y(Hh,Vg);f=Hh.prototype;f.qx=function(a){var b=this.a;mh(this.app,new nh(a),b)};
-f.wo=function(a){kh(this.app,a,this.a)};f.tx=function(){};f.Gp=function(a,b,c){Wg(this.app,!0,this.a);var d=this.app,e=this.a;Xg(d,d.getCurrentTime()+a,b,c,e)};f.rx=function(){var a=this.app;a.Mk||(a.Mk=!0,a.ri={})};f.wx=function(){var a=this.app;Ih(a);a.Wa("onPlaylistUpdate")};f.ux=function(a,b){var c=this.app,d=c.ri[a];d&&(Jh(d,b),d.start(),delete c.ri[a])};f.vx=function(){this.app.a.Sa=x()};f.xx=function(a){var b=N(this.app,this.a||1);b&&(b=b.a,Kh(b,a),b.u("dataupdated"))};f.sx=function(){return this.app.getVideoData().b.storyboard_spec};
-f.getVideoData=function(){var a=Hh.C.getVideoData.call(this),b=this.app.getVideoData(this.a)||{};a.cpn=b.Da;return a};f.getCurrentTime=function(a){return a?this.app.getCurrentTime(a):Hh.C.getCurrentTime.call(this)};f.Gh=function(a){return a?Lh(this.app,a):Hh.C.Gh.call(this)};function Mh(a,b){Hh.call(this,a,b)}y(Mh,Hh);f=Mh.prototype;f.Lj=function(a,b,c){kh(this.app,lh(a,this.app.list,b,c),this.a)};f.rg=function(){$g(this.app,this.a)};f.Oh=function(a,b){Xg(this.app,a,b,void 0,this.a)};function Q(a){return a.app.R.a}f.K=function(){return this.app.K()};f.vb=function(){return this.app.g};f.getVideoData=function(){return this.app.getVideoData(this.a)};function Nh(a){this.j=Math.exp(Math.log(0.5)/a);this.a=this.g=0}Nh.prototype.b=function(a,b){var c=Math.pow(this.j,a);this.a=b*(1-c)+c*this.a;this.g+=a};Nh.prototype.i=function(){return this.a/(1-Math.pow(this.j,this.g))};function Oh(a,b){this.o=0;this.j=a;this.F=b||0.5;this.k="index";this.a=0;this.g=[]}Oh.prototype.b=function(a,b){Ph(this,"index");this.g.push({index:this.o++,weight:a,value:b});this.a+=a;for(Ph(this,"index");this.a>this.j;){var c=this.a-this.j,d=this.g[0];d.weight<=c?(this.a-=d.weight,this.g.shift()):(this.a-=c,d.weight-=c)}};function Qh(a,b){Ph(a,"value");var c=b*a.a,d=0,e=NaN;a.g.some(function(a){d+=a.weight;e=a.value;if(d>=c)return!0});return e}Oh.prototype.i=function(){return Qh(this,this.F)};
-function Ph(a,b){a.k!=b&&(a.k=b,ib(a.g,b))};function Rh(a){var b=ig(a);if(!b){var c=new Vf;c.isAvailable()&&(b=(new Xf(c)).get(a))}return b}function Sh(){var a={volume:100,muted:!1,nonNormalized:100},b=Rh("yt-player-volume")||{};a.volume=isNaN(b.volume)?100:wb(b.volume,0,100);a.nonNormalized=isNaN(b.nonNormalized)?a.volume:b.nonNormalized;a.muted=void 0==b.muted?!1:b.muted;return a};function Th(a){this.g=this.i=0;this.j=new Nh(4);a.Kc?this.b=new Nh(16):this.b=new Oh(16,0.6);a.Ll?this.a=new Oh(8,0.6):a.Jl?this.a=new Oh(16,0.6):a.Kl?this.a=new Oh(24,0.6):"play"==a.La?this.a=new Nh(17):this.a=new Oh(17,0.6);var b=Rh("yt-player-bandwidth");a=a.jb?0.1:0.5;b&&!isNaN(b.byterate)?this.a.b(a,b.byterate):this.a.b(a,13E4)}function Uh(a){a=a.b.i();return a=isNaN(a)?0.5:a}function Vh(a){return a.j.i()||0}function Wh(a){a=a.a.i();return 0<a?a:1};function Xh(){this.a=[];this.Sb={}}y(Xh,K);f=Xh.prototype;f.Wo=1;f.Fi=0;f.D=function(a,b,c){var d=this.Sb[a];d||(d=this.Sb[a]=[]);var e=this.Wo;this.a[e]=a;this.a[e+1]=b;this.a[e+2]=c;this.Wo=e+3;d.push(e);return e};f.$=function(a,b,c){if(a=this.Sb[a]){var d=this.a;if(a=Pa(a,function(a){return d[a+1]==b&&d[a+2]==c}))return this.Rc(a)}return!1};
-f.Rc=function(a){if(0!=this.Fi)return this.b||(this.b=[]),this.b.push(a),!1;var b=this.a[a];if(b){var c=this.Sb[b];c&&Xa(c,a);delete this.a[a];delete this.a[a+1];delete this.a[a+2]}return!!b};f.u=function(a,b){var c=this.Sb[a];if(c){this.Fi++;for(var d=db(arguments,1),e=0,g=c.length;e<g;e++){var h=c[e];this.a[h+1].apply(this.a[h+2],d)}this.Fi--;if(this.b&&0==this.Fi)for(;c=this.b.pop();)this.Rc(c);return 0!=e}return!1};
-f.clear=function(a){if(a){var b=this.Sb[a];b&&(z(b,this.Rc,this),delete this.Sb[a])}else this.a.length=0,this.Sb={}};f.hb=function(a){if(a){var b=this.Sb[a];return b?b.length:0}a=0;for(b in this.Sb)a+=this.hb(b);return a};f.H=function(){Xh.C.H.call(this);delete this.a;delete this.Sb;delete this.b};function Yh(a,b){this.start=a;this.end=b;this.a=ja(this)}function Zh(a,b){return a.start!=b.start?a.start-b.start:a.end!=b.end?a.end-b.end:a.a!=b.a?a.a-b.a:0}Yh.prototype.contains=function(a,b){return a>=this.start&&(a<this.end||a==this.end&&this.start==this.end)&&(null==b||a<b&&b<=this.end)};Yh.prototype.toString=function(){return"Interval["+this.start+", "+this.end+"]"};function $h(a,b,c){Yh.call(this,a,b);a=c||{};this.Ba=a.id||"";void 0!=a.priority&&(this.kh=a.priority);this.namespace=a.namespace||"";this.Pc=a.visible||!1;this.Eb=new Xh}y($h,Yh);f=$h.prototype;f.Ba="";f.kh=7;f.active=!0;f.Pc=!1;f.Eb=null;f.namespace="";f.getId=function(){return this.Ba};function ai(a,b){return a.start==b.start?a.kh==b.kh?0:a.kh<b.kh?-1:1:a.start<b.start?-1:1};function bi(a){bi[" "](a);return a}bi[" "]=ba;var ci=!C||vc(9),di=C&&!uc("9");!gc||uc("528");fc&&uc("1.9b")||C&&uc("8")||ec&&uc("9.5")||gc&&uc("528");fc&&!uc("8")||C&&uc("9");function ei(a,b){this.type=a;this.currentTarget=this.target=b}f=ei.prototype;f.dispose=function(){};f.ne=!1;f.defaultPrevented=!1;f.Uo=!0;f.stopPropagation=function(){this.ne=!0};f.preventDefault=function(){this.defaultPrevented=!0;this.Uo=!1};function fi(a,b){a&&this.init(a,b)}y(fi,ei);f=fi.prototype;f.target=null;f.relatedTarget=null;f.clientX=0;f.clientY=0;f.keyCode=0;f.charCode=0;f.ctrlKey=!1;f.altKey=!1;f.shiftKey=!1;f.le=null;
-f.init=function(a,b){var c=this.type=a.type;ei.call(this,c);this.target=a.target||a.srcElement;this.currentTarget=b;var d=a.relatedTarget;if(d){if(fc){var e;t:{try{bi(d.nodeName);e=!0;break t}catch(g){}e=!1}e||(d=null)}}else"mouseover"==c?d=a.fromElement:"mouseout"==c&&(d=a.toElement);this.relatedTarget=d;this.clientX=void 0!==a.clientX?a.clientX:a.pageX;this.clientY=void 0!==a.clientY?a.clientY:a.pageY;this.keyCode=a.keyCode||0;this.charCode=a.charCode||("keypress"==c?a.keyCode:0);this.ctrlKey=a.ctrlKey;
-this.altKey=a.altKey;this.shiftKey=a.shiftKey;this.state=a.state;this.le=a;a.defaultPrevented&&this.preventDefault();delete this.ne};f.stopPropagation=function(){fi.C.stopPropagation.call(this);this.le.stopPropagation?this.le.stopPropagation():this.le.cancelBubble=!0};f.preventDefault=function(){fi.C.preventDefault.call(this);var a=this.le;if(a.preventDefault)a.preventDefault();else if(a.returnValue=!1,di)try{if(a.ctrlKey||112<=a.keyCode&&123>=a.keyCode)a.keyCode=-1}catch(b){}};f.Mx=function(){return this.le};var gi="closure_listenable_"+(1E6*Math.random()|0);function hi(a){try{return!(!a||!a[gi])}catch(b){return!1}}var ii=0;function ji(a,b,c,d,e){this.Ye=a;this.proxy=null;this.src=b;this.type=c;this.capture=!!d;this.gb=e;this.key=++ii;this.removed=this.Ei=!1}function ki(a){a.removed=!0;a.Ye=null;a.proxy=null;a.src=null;a.gb=null};function li(a){this.src=a;this.a={};this.b=0}li.prototype.add=function(a,b,c,d,e){var g=this.a[a];g||(g=this.a[a]=[],this.b++);var h=mi(g,b,d,e);-1<h?(a=g[h],c||(a.Ei=!1)):(a=new ji(b,this.src,a,!!d,e),a.Ei=c,g.push(a));return a};li.prototype.remove=function(a,b,c,d){if(!(a in this.a))return!1;var e=this.a[a];b=mi(e,b,c,d);return-1<b?(ki(e[b]),Ya(e,b),0==e.length&&(delete this.a[a],this.b--),!0):!1};
-function ni(a,b){var c=b.type;if(!(c in a.a))return!1;var d=Xa(a.a[c],b);d&&(ki(b),0==a.a[c].length&&(delete a.a[c],a.b--));return d}li.prototype.removeAll=function(a){var b=0,c;for(c in this.a)if(!a||c==a){for(var d=this.a[c],e=0;e<d.length;e++)++b,ki(d[e]);delete this.a[c];this.b--}return b};function oi(a,b,c,d,e){a=a.a[b];b=-1;a&&(b=mi(a,c,d,e));return-1<b?a[b]:null}function mi(a,b,c,d){for(var e=0;e<a.length;++e){var g=a[e];if(!g.removed&&g.Ye==b&&g.capture==!!c&&g.gb==d)return e}return-1};var pi="closure_lm_"+(1E6*Math.random()|0),qi={},ri=0;function si(a,b,c,d,e){if(t(b)){for(var g=0;g<b.length;g++)si(a,b[g],c,d,e);return null}c=ti(c);if(hi(a))a=a.listen(b,c,d,e);else{if(!b)throw Error("Invalid event type");var g=!!d,h=ui(a);h||(a[pi]=h=new li(a));c=h.add(b,c,!1,d,e);c.proxy||(d=vi(),c.proxy=d,d.src=a,d.Ye=c,a.addEventListener?a.addEventListener(b,d,g):a.attachEvent(b in qi?qi[b]:qi[b]="on"+b,d),ri++);a=c}return a}
-function vi(){var a=wi,b=ci?function(c){return a.call(b.src,b.Ye,c)}:function(c){c=a.call(b.src,b.Ye,c);if(!c)return c};return b}function xi(a,b,c,d,e){if(t(b))for(var g=0;g<b.length;g++)xi(a,b[g],c,d,e);else c=ti(c),hi(a)?a.ac(b,c,d,e):a&&(a=ui(a))&&(b=oi(a,b,c,!!d,e))&&yi(b)}
-function yi(a){if(ga(a)||!a||a.removed)return!1;var b=a.src;if(hi(b))return ni(b.$c,a);var c=a.type,d=a.proxy;b.removeEventListener?b.removeEventListener(c,d,a.capture):b.detachEvent&&b.detachEvent(c in qi?qi[c]:qi[c]="on"+c,d);ri--;(c=ui(b))?(ni(c,a),0==c.b&&(c.src=null,b[pi]=null)):ki(a);return!0}function zi(a,b,c,d){var e=1;if(a=ui(a))if(b=a.a[b])for(b=ab(b),a=0;a<b.length;a++){var g=b[a];g&&g.capture==c&&!g.removed&&(e&=!1!==Ai(g,d))}return Boolean(e)}
-function Ai(a,b){var c=a.Ye,d=a.gb||a.src;a.Ei&&yi(a);return c.call(d,b)}
-function wi(a,b){if(a.removed)return!0;if(!ci){var c=b||n("window.event"),d=new fi(c,this),e=!0;if(!(0>c.keyCode||void 0!=c.returnValue)){t:{var g=!1;if(0==c.keyCode)try{c.keyCode=-1;break t}catch(h){g=!0}if(g||void 0==c.returnValue)c.returnValue=!0}c=[];for(g=d.currentTarget;g;g=g.parentNode)c.push(g);for(var g=a.type,k=c.length-1;!d.ne&&0<=k;k--)d.currentTarget=c[k],e&=zi(c[k],g,!0,d);for(k=0;!d.ne&&k<c.length;k++)d.currentTarget=c[k],e&=zi(c[k],g,!1,d)}return e}return Ai(a,new fi(b,this))}
-function ui(a){a=a[pi];return a instanceof li?a:null}var Bi="__closure_events_fn_"+(1E9*Math.random()>>>0);function ti(a){return ha(a)?a:a[Bi]||(a[Bi]=function(b){return a.handleEvent(b)})};function Ci(){this.$c=new li(this);this.V=this}y(Ci,K);Ci.prototype[gi]=!0;f=Ci.prototype;f.zl=null;f.addEventListener=function(a,b,c,d){si(this,a,b,c,d)};f.removeEventListener=function(a,b,c,d){xi(this,a,b,c,d)};
-function Di(a,b){var c,d=a.zl;if(d){c=[];for(var e=1;d;d=d.zl)c.push(d),++e}var d=a.V,e=b,g=e.type||e;if(u(e))e=new ei(e,d);else if(e instanceof ei)e.target=e.target||d;else{var h=e,e=new ei(g,d);Rb(e,h)}var h=!0,k;if(c)for(var m=c.length-1;!e.ne&&0<=m;m--)k=e.currentTarget=c[m],h=Ei(k,g,!0,e)&&h;e.ne||(k=e.currentTarget=d,h=Ei(k,g,!0,e)&&h,e.ne||(h=Ei(k,g,!1,e)&&h));if(c)for(m=0;!e.ne&&m<c.length;m++)k=e.currentTarget=c[m],h=Ei(k,g,!1,e)&&h}
-f.H=function(){Ci.C.H.call(this);this.$c&&this.$c.removeAll(void 0);this.zl=null};f.listen=function(a,b,c,d){return this.$c.add(String(a),b,!1,c,d)};f.ac=function(a,b,c,d){return this.$c.remove(String(a),b,c,d)};function Ei(a,b,c,d){b=a.$c.a[String(b)];if(!b)return!0;b=ab(b);for(var e=!0,g=0;g<b.length;++g){var h=b[g];if(h&&!h.removed&&h.capture==c){var k=h.Ye,m=h.gb||h.src;h.Ei&&ni(a.$c,h);e=!1!==k.call(m,d)&&e}}return e&&!1!=d.Uo};function Fi(a,b){Ci.call(this);this.a=a||1;this.b=b||l;this.g=v(this.Ut,this);this.i=x()}y(Fi,Ci);f=Fi.prototype;f.Tc=!1;f.hc=null;function Gi(a,b){a.a=b;a.hc&&a.Tc?(a.stop(),a.start()):a.hc&&a.stop()}f.Ut=function(){if(this.Tc){var a=x()-this.i;0<a&&a<0.8*this.a?this.hc=this.b.setTimeout(this.g,this.a-a):(this.hc&&(this.b.clearTimeout(this.hc),this.hc=null),Di(this,"tick"),this.Tc&&(this.hc=this.b.setTimeout(this.g,this.a),this.i=x()))}};
-f.start=function(){this.Tc=!0;this.hc||(this.hc=this.b.setTimeout(this.g,this.a),this.i=x())};f.stop=function(){this.Tc=!1;this.hc&&(this.b.clearTimeout(this.hc),this.hc=null)};f.H=function(){Fi.C.H.call(this);this.stop();delete this.b};function Hi(a,b,c){if(ha(a))c&&(a=v(a,c));else if(a&&"function"==typeof a.handleEvent)a=v(a.handleEvent,a);else throw Error("Invalid listener argument");return 2147483647<b?-1:l.setTimeout(a,b||0)};function Ii(){this.a=[]}function Ji(a,b){for(var c=[],d=0;d<a.a.length;++d){var e=a.a[d];e.contains(b)&&c.push(e);if(e.start>b)break}return c}function Ki(a,b,c){for(var d=[],e=0;e<a.a.length;++e){var g=a.a[e];if(null!=c&&g.start>c)break;g.start>b&&d.push(g)}return d}function Li(a,b){for(var c=[],d=0;d<a.a.length;++d){var e=a.a[d];e.contains(b)&&c.push(e.end);if(e.start>b){c.push(e.start);break}}c.sort(hb);return c[0]};var Mi,Ni,Oi,Pi,Qi;Qi=Pi=Oi=Ni=Mi=!1;var Ri=ac();Ri&&(-1!=Ri.indexOf("Firefox")||-1!=Ri.indexOf("Camino")||(-1!=Ri.indexOf("iPhone")||-1!=Ri.indexOf("iPod")?Mi=!0:-1!=Ri.indexOf("iPad")?Ni=!0:-1!=Ri.indexOf("Chrome")?Pi=!0:-1!=Ri.indexOf("Android")?Oi=!0:-1!=Ri.indexOf("Safari")&&(Qi=!0)));var Si=Mi,Ti=Ni,Ui=Oi,Vi=Pi,Wi=Qi;var Xi,Yi;var Zi=ac(),$i=Zi.match(/\((iPad|iPhone|iPod)( Simulator)?;/);if(!$i||2>$i.length)Xi=void 0;else{var aj=Zi.match(/\((iPad|iPhone|iPod)( Simulator)?; (U; )?CPU (iPhone )?OS (\d_\d)[_ ]/);Xi=aj&&6==aj.length?Number(aj[5].replace("_",".")):0}(Yi=0<=Xi)&&0<=ac().search("Safari")&&ac().search("Version");var bj=Si||Ti;function cj(){return dj("(ps3; leanback shell)")}function dj(a){var b=ac();return b?0<=b.toLowerCase().indexOf(a.toLowerCase()):!1};function ej(){}var fj=Yi&&4>Xi?0.1:0,gj=new ej;f=ej.prototype;f.Bd=null;f.Bk=!1;f.Rd=0;f.Gl=0;function hj(a,b){var c="";b&&(a.Bd=b,c=ij(b));a.src&&""==c||(c&&a.src!=c&&(a.src=c),b&&b.a||a.load())}function jj(a,b){0<a.readyState&&(a.currentTime=Math.max(fj,b))}f.getType=function(){return this.type};f.Xa=function(a){this.Rd=a};f.getCurrentTime=function(){return this.Gl||this.currentTime};f.Yo=function(){this.Gl=this.currentTime};
-function ih(a){var b=a.Rd;if(Infinity==b)return 1;if(b&&a.buffered&&0<a.buffered.length){var c=kj(a);return a.buffered.end(c)/b}return 0}function lj(a){a.ended&&jj(a,0);!a.hasAttribute("src")&&a.Bd&&(a.src=ij(a.Bd),a.Bd.a||a.load());a.play()}function mj(a){a.currentSrc&&(bj&&jj(a,0),$c(a),a.removeAttribute("src"),a.load(),a.Bd&&a.Bd.a&&(a.Bd=null))}function nj(a){mj(a);a.Rd=0;a.Gl=0;a.Bd=null}function oj(a,b){a.defaultPlaybackRate=b;a.playbackRate=b}
-function kj(a){var b=a.buffered;a=a.getCurrentTime();for(var c=0;c<b.length&&!(b.start(c)>a);c++)if(a<=b.end(c))return c;return 0}f.inUnbufferedArea=function(){var a=this.buffered;if(!a||!a.length)return!0;var b=kj(this);if(0<b)return!1;var c=this.getCurrentTime();return a.start(b)>c||a.end(b)<c};function pj(a,b){b?a.setAttribute("crossorigin","true"):a.removeAttribute("crossorigin")}f.Nv=function(){this.hasAttribute("controls")&&this.setAttribute("controls","true")};
-f.Ov=function(){this.Bk&&!this.muted&&(this.muted=!0)};function qj(a){var b="";if(a)for(var c=0;c<a.length;c++)b+=a.start(c).toFixed(3)+"-"+a.end(c).toFixed(3)+",";return b};var rj=[2,5,100,101,150],sj=[202,203];function tj(a,b){a=a||64;a&128&&!b||a&2&&a&16||(this.b=a,this.a=b||null)}tj.prototype.b=64;tj.prototype.a=null;function uj(a,b,c){return b==a.b&&c==a.a||b&128&&!c||b&2&&b&16?a:new tj(b,c)}function P(a,b){return!!(a.b&b)}function vj(a){return P(a,128)?-1:P(a,2)?0:P(a,1)&&!P(a,32)?3:P(a,64)?-1:P(a,8)?1:P(a,4)?2:-1}function wj(){var a;return a=14};function R(){this.F=new Xh;L(this,this.F)}y(R,K);R.prototype.D=function(a,b,c){return this.ka()?0:this.F.D(a,b,c)};R.prototype.$=function(a,b,c){return this.ka()?!1:this.F.$(a,b,c)};R.prototype.Rc=function(a){return this.ka()?!1:this.F.Rc(a)};R.prototype.u=function(a,b){return this.ka()?!1:this.F.u.apply(this.F,arguments)};function xj(a,b,c){R.call(this);this.A=a;this.o=b;this.B=c;this.j=new Fi(250);si(this.j,"tick",this.Xb,!1,this);L(this,this.j);this.i=[];this.a=[];this.b=new Ii}y(xj,R);f=xj.prototype;f.Kh=!1;f.ug=!1;f.qk=!1;f.pk=!1;f.Hg=null;f.cx=function(a){this.Xb();z(arguments,function(a){this.i.push(a);var c=this.b.a;!c.length||0<Zh(a,c[c.length-1])?c.push(a):lb(c,a,Zh);this.u("onAdd",a)},this);this.Xb()};f.fx=function(a){z(arguments,function(a){a=this.i.indexOf(a);0<=a&&yj(this,a)},this);this.Xb()};
-function yj(a,b){var c=a.i.splice(b,1)[0],d=a.b.a,e=fb(d,Zh||hb,c);0<=e&&Ya(d,e);b=a.a.indexOf(c);0<=b&&a.a.splice(b,1);a.u("onRemove",c)}f.reset=function(){this.ug=this.Kh=!1;zj(this);for(var a=this.i.length-1;0<=a;a--)yj(this,a);this.Xb();this.k=null};
-function Aj(a,b){if(a.ug&&!a.Kh)if(zj(a),P(b.state,2)){a.k=null;for(var c=[],d=0;d<a.a.length;d++){var e=a.a[d];e.active&&2147483647>e.end&&(c.push(e),a.a.splice(d--,1))}d=Ji(a.b,2147483646);d=d.concat(Ki(a.b,2147483646));e=[];if(c.length)for(var g=0;g<c.length;g++)e.push(["onExit",c[g]]);c=e.concat(Bj(a,d));for(d=0;d<c.length;d++)g=c[d],e=g[1],e.Eb.u.apply(e.Eb,g)}else P(b.state,16)?(a.g=Cj(a),a.j.stop(),a.j.start(),a.Xb()):(a.j.stop(),P(b.a,16)?(a.g=Cj(a),null!=Li(a.b,Math.max(a.g-2E3,0))&&(a.Hg=
-Hi(v(a.Xb,a)))):a.Xb())}function Bj(a,b){var c=[];if(!b.length)return c;b.sort(ai);for(var d=0;d<b.length;d++){var e=b[d];e.active&&-1==a.a.indexOf(e)&&(a.a.push(e),c.push(["onEnter",e]))}return c}
-f.Xb=function(){this.pk=!0;if(!this.qk)for(var a=3;this.pk&&a;){this.pk=!1;this.qk=!0;if(this.ug&&!this.Kh){zj(this);for(var b=Cj(this),c=[],d=0;d<this.a.length;d++){var e=this.a[d];e.active&&!e.contains(b)&&(c.push(["onExit",e]),this.a.splice(d--,1))}d=Ji(this.b,b);e=this.o();!P(e,48)&&b>this.g&&(d=d.concat(Ki(this.b,this.g,b)));c=c.concat(Bj(this,d));this.g=b;!this.Kh&&this.k&&(c.unshift(["onLockBlockExit",this.k]),this.k=null,P(e,2)&&(this.g=2147483647));this.B()&&(b=Li(this.b,this.g),null!=b&&
-(this.Hg=Hi(v(this.Xb,this),b-this.g)));for(d=0;d<c.length;d++)b=c[d],e=b[1],"onLockBlockExit"==b[0]||"onLockBlockEnter"==b[0]?this.u.apply(this,b):e.Eb.u.apply(e.Eb,b)}this.qk=!1;a--}};function zj(a){null!=a.Hg&&(l.clearTimeout(a.Hg),a.Hg=null)}function Cj(a){return P(a.o(),2)?2147483647:1E3*a.A()}f.H=function(){xi(this.j,"tick",this.Xb,!1,this);zj(this);this.k=this.b=this.a=this.i=null;xj.C.H.call(this)};function Dj(a,b){for(var c=a.split(b),d={},e=0,g=c.length;e<g;e++){var h=c[e].split("=");if(1==h.length&&h[0]||2==h.length){var k=xa(h[0]||""),h=xa(h[1]||"");k in d?t(d[k])?bb(d[k],h):d[k]=[d[k],h]:d[k]=h}}return d}function Ej(a,b){var c=[];Hb(a,function(a,b){var g=encodeURIComponent(String(b)),h;h=t(a)?a:[a];z(h,function(a){""==a?c.push(g):c.push(g+"="+encodeURIComponent(String(a)))})});return c.join(b)}function Fj(a){"?"==a.charAt(0)&&(a=a.substr(1));return Dj(a,"&")}
-function Gj(a){return-1!=a.indexOf("?")?(a=(a||"").split("#")[0],a=a.split("?",2),Fj(1<a.length?a[1]:a[0])):{}}function Hj(a){a=ke([],a);a[0]="";return a.join("")}function S(a,b){return he(ke([a],b))}var Ij=fe;function Jj(){var a=de(document.location.href);return be(a[1],a[2],a[3],a[4])}function Kj(a,b){var c=a.split("#",2);a=c[0];var c=1<c.length?"#"+c[1]:"",d=a.split("?",2);a=d[0];var d=Fj(d[1]||""),e;for(e in b)d[e]=b[e];return S(a,d)+c};var Lj=null;"undefined"!=typeof XMLHttpRequest?Lj=function(){return new XMLHttpRequest}:"undefined"!=typeof ActiveXObject&&(Lj=function(){return new ActiveXObject("Microsoft.XMLHTTP")});function Mj(a){switch(a&&"status"in a?a.status:-1){case 0:case 200:case 201:case 202:case 203:case 204:case 205:case 206:case 304:return!0;default:return!1}};function Nj(a,b,c,d,e,g,h){var k=Lj&&Lj();if("open"in k){k.onreadystatechange=function(){4==(k&&"readyState"in k?k.readyState:0)&&b&&gf(b)(k)};c=(c||"GET").toUpperCase();d=d||"";k.open(c,a,!0);g&&(k.responseType=g);h&&(k.withCredentials=!0);g="POST"==c;if(e=Oj(a,e))for(var m in e)k.setRequestHeader(m,e[m]),"content-type"==m.toLowerCase()&&(g=!1);g&&k.setRequestHeader("Content-Type","application/x-www-form-urlencoded");k.send(d);return k}}
-function Oj(a,b){b=b||{};var c;if(c=df("PAGE_CL"))if(c=df("PAGE_BUILD_TIMESTAMP")){var d;d||(d=window.location.href);c=de(a)[1]||null;var e=Ij(a);c&&e?(c=d,d=de(a),c=de(c),d=d[3]==c[3]&&d[1]==c[1]&&d[4]==c[4]):d=e?Ij(d)==e&&(Number(de(d)[4]||null)||null)==(Number(de(a)[4]||null)||null):!0;c=d||Pj(a)}c&&(b["X-YouTube-Page-CL"]=df("PAGE_CL"),b["X-YouTube-Page-Timestamp"]=df("PAGE_BUILD_TIMESTAMP"));return b}
-function Pj(a){var b=["X-YouTube-Page-CL","X-YouTube-Page-Timestamp"],c=df("CORS_HEADER_WHITELIST")||{};a=Ij(a);if(!a)return!0;var d=c[a];return d?Na(b,function(a){return Ta(d,a)}):!1}
-function Qj(a,b){var c=b.format||"JSON";b.mv&&(a=document.location.protocol+"//"+document.location.hostname+(document.location.port?":"+document.location.port:"")+a);var d=b.rf;d&&(a=Kj(a,d));var e=b.Bw||"";(d=b.Gf)&&u(e)&&(e=Fj(e),Rb(e,d),e=Hj(e));var g=!1,h,k=Nj(a,function(a){if(!g){g=!0;h&&I(h);var d=Mj(a),e=null;if(d||400<=a.status&&500>a.status)e=Rj(c,a);if(d)t:{switch(c){case "XML":d=0==parseInt(e&&e.return_code,10);break t;case "RAW":d=!0;break t}d=!!e}var e=e||{},k=b.S||l;d?b.Pa&&b.Pa.call(k,
-a,e):b.onError&&b.onError.call(k,a,e);b.pd&&b.pd.call(k,a,e)}},b.method,e,b.headers,b.responseType,b.withCredentials);b.Sk&&0<b.timeout&&(h=H(function(){g||(g=!0,k.abort(),I(h),b.Sk.call(b.S||l,k))},b.timeout));return k}function Rj(a,b){var c=null;switch(a){case "JSON":var d=b.responseText,e=b.getResponseHeader("Content-Type")||"";d&&0<=e.indexOf("json")&&(c=ob(d));break;case "XML":if(d=(d=b.responseXML)?Sj(d):null)c={},z(d.getElementsByTagName("*"),function(a){c[a.tagName]=Tj(a)})}return c}
-function Sj(a){return a?(a=("responseXML"in a?a.responseXML:a).getElementsByTagName("root"))&&0<a.length?a[0]:null:null}function Tj(a){var b="";z(a.childNodes,function(a){b+=a.nodeValue});return b}var Uj={html5_ajax:"action_get_html5_token",watch_actions_ajax:"action_get_watch_actions_token",addto_ajax:"action_get_wl_token"},Vj={html5_ajax:"html5_ajax_token",watch_actions_ajax:"watch_actions_ajax_token",addto_ajax:"addto_ajax_token"};
-function Wj(a,b,c,d,e){if(ff(a))d&&window.setTimeout(d,0);else{var g=Jj()+"/token_ajax",h={};b&&(h.sy=b);c&&(h.ty=c);h[Uj[a]]=1;Qj(g,{format:"RAW",method:"GET",rf:h,pd:function(b){var c=Fj(b.responseText),g=c[Vj[a]];g?(ef(a,g),d&&d()):e&&e(b,c)}})}};function Xj(a){a=a.split("");a=a.reverse();a=a.slice(2);a=a.reverse();var b=a[0];a[0]=a[63%a.length];a[63]=b;a=a.reverse();return a.join("")};function Yj(){this.lang=""};function Zj(a,b,c,d,e,g){this.Oa=a;this.j=0<=b.indexOf("/mp4")?1:0<=b.indexOf("/webm")?2:0<=b.indexOf("/x-flv")?3:0;this.Jb=b;this.b=g||0;this.i=c||null;this.a=d||null;this.g=e||null}function ak(a){return 2==a.j}function bk(a){return 0<=a.indexOf("opus")||0<=a.indexOf("vorbis")||0<=a.indexOf("mp4a")}function ck(a){return 0<=a.indexOf("vp9")||0<=a.indexOf("vp8")||0<=a.indexOf("avc1")};var dk={Yx:"auto",OC:"tiny",RB:"light",SMALL:"small",aC:"medium",LARGE:"large",wB:"hd720",uB:"hd1080",vB:"hd1440",DB:"highres",UNKNOWN:"unknown"};function ek(a,b,c){this.width=a;this.height=b;t:if(a||b){for(var d=1;d<fk.length;d++){var e=fk[d],g=gk[e];if(a>=g[0]||b>=g[1]){a=e;break t}}a="tiny"}else a="auto";this.i=a;this.a=c||0}var fk="auto highres hd1440 hd1080 hd720 large medium small tiny".split(" "),gk={auto:[0,0],tiny:[256,144],light:[320,240],small:[320,240],medium:[640,360],large:[854,480],hd720:[1280,720],hd1080:[1920,1080],hd1440:[2560,1440],highres:[2048,1536]};function hk(a,b){this.start=a;this.end=b;this.length=b-a+1}function ik(a){a=a.split("-");return 2==a.length&&(a=new hk(parseInt(a[0],10),parseInt(a[1],10)),!isNaN(a.start)&&!isNaN(a.end)&&!isNaN(a.length)&&0<a.length)?a:null}function jk(a,b){return new hk(a,a+b-1)}hk.prototype.toString=function(){return this.start+"-"+(null==this.end?"":this.end)};var kk="corp.google.com googleplex.com youtube.com youtube-nocookie.com prod.google.com sandbox.google.com docs.google.com drive.google.com mail.google.com play.google.com googlevideo.com".split(" "),lk=["2mdn.net"],mk="www.google.com/aclk www.google.com/pagead/conversion googleadservices.com/aclk googleadservices.com/pagead/conversion googleads.g.doubleclick.net/aclk googleads.g.doubleclick.net/pagead/conversion".split(" ");
-function nk(){return-1!=document.location.toString().indexOf("/embed/")}function ok(a,b){return RegExp("^https?://([a-z0-9-]{1,63}\\.)*("+b.join("|").replace(/\./g,".")+")(:[0-9]+)?([/?#]|$)","i").test(a)}function pk(a){a=new re(a);se(a,document.location.protocol);te(a,document.location.hostname);document.location.port&&ue(a,document.location.port);return a.toString()};function qk(a,b,c,d,e,g,h,k,m){this.a=b;this.U=c;this.type=a;this.j=0<=d?d:-1;this.startTime=e||0;this.duration=g||0;this.ob=h||0;this.Ha=0<=k?k:NaN;this.b=!!m;this.U?(this.U=this.U,this.Ha=0<=this.Ha?this.Ha:this.U.length,this.g=this.ob+this.Ha==this.U.length,this.i=this.startTime+this.duration*this.ob/this.U.length,this.o=this.duration*this.Ha/this.U.length,this.k=this.i+this.o):this.g=!0}function rk(a){return 1==a.type||2==a.type}
-function sk(a,b){return a.a==b.a&&a.U.start+a.ob+a.Ha==b.U.start+b.ob}function tk(a){Ga(1==a.length||Na(a,function(a){return!!a.U}));for(var b=1;b<a.length;b++);b=a[a.length-1];return new hk(a[0].U.start+a[0].ob,b.U.start+b.ob+b.Ha-1)}qk.prototype.qf=function(a){return this.a.qf(this,a)};function uk(a){return"i="+a.a.info.Oa+",r="+(a.U.start+a.ob)+"-"+(a.U.start+a.ob+a.Ha-1)+",t="+a.i.toFixed(1)+"-"+(a.i+a.o).toFixed(1)};function vk(a,b,c,d){this.info=a;this.buffer=b;this.U=c;this.a=d}function wk(a){return new DataView(a.buffer,a.U.start,a.U.length)}function xk(a){if(a.info.Ha!=a.U.length)return!1;if(1==a.info.a.info.j){if(8>a.info.Ha||4==a.info.type)return!0;var b=wk(a),c=b.getUint32(0,!1),b=b.getUint32(4,!1);if(2==a.info.type)return c==a.info.Ha&&1936286840==b;if(3==a.info.type&&0==a.info.ob)return 1836019558==b}return!0};function yk(a){this.a=a;this.b=0;this.g=-1}var zk=0;function Ak(a,b){a.a=Kj(a.a,b)};function Bk(a,b){this.index=null;this.info=b;this.b=null;this.i=!1;this.j=new yk(a)}f=Bk.prototype;f.Do=function(){return!1};f.Yb=function(){return!1};f.Aj=function(){return!1};f.mn=function(){return[]};f.qf=function(){return null};f.Ej=function(){return null};f.Co=function(){};function Ck(a){this.b=a[0].a.j;this.a=a};function Dk(){this.T=0;this.a=new Float64Array(128);this.b=new Float32Array(128);this.g=!1}Dk.prototype.hb=function(){return this.T};function Ek(a,b){var c=fb(a.b.subarray(0,a.T),hb,b);return 0<=c?c:Math.max(0,-c-2)}function Fk(a){if(a.a.length<a.T+1){var b=2*a.a.length,b=b+2,c=a.a;a.a=new Float64Array(b+1);var d=a.b;a.b=new Float32Array(b+1);for(b=0;b<a.T+1;b++)a.a[b]=c[b],a.b[b]=d[b]}}function Gk(a,b){this.b=a;this.a=0;this.g=b||0}
-function Hk(a){for(var b=Ik(a,!1);236==b;)Jk(a),b=Ik(a,!1);return b}function Kk(a){var b=Ik(a,!0),c=a.b.byteOffset+a.a,d=Math.min(b,a.b.buffer.byteLength-c),c=new DataView(a.b.buffer,c,d),c=new Gk(c,a.g+a.a);a.a+=b;return c}function Lk(a){for(var b=Ik(a,!0),c=Mk(a),d=1;d<b;d++)c=(c<<8)+Mk(a);return c}function Jk(a){var b=Ik(a,!0);a.a+=b}function Ik(a,b){var c=Mk(a);if(1==c){for(var d=c=0;7>d;d++)c=256*c+Mk(a);return c}for(var e=128,d=0;6>d&&e>c;d++)c=256*c+Mk(a),e*=128;return b?c-e:c}
-function Mk(a){return a.b.getUint8(a.a++)};function Nk(a,b,c,d){Bk.call(this,a,b);this.o=c;this.k=d;this.g=null;this.index=new Dk;b=parseInt;c=a.search(oe);d=ne(a,0,"clen",c);if(0>d)a=null;else{var e=a.indexOf("&",d);if(0>e||e>c)e=c;d+=5;a=xa(a.substr(d,e-d))}this.a=b(a,10)}y(Nk,Bk);f=Nk.prototype;f.Yb=function(){return!(!this.b||!this.index.hb())};
-f.mn=function(a){var b=new qk(1,this,this.o),c=new qk(2,this,this.k),d=[],e=[b];sk(b,c)?e.push(c):d.push(new Ck([c]));isNaN(this.a)?a=0:a>this.a&&(a=this.a);b=e[e.length-1];c=b.U.end-e[0].U.start+1;a>c&&(a=jk(b.U.end+1,a-c),e.push(new qk(4,this,a)));d.push(new Ck(e));return d};
-f.Co=function(a){if(1==a.info.type){if(this.b)return;this.b=new Uint8Array(a.buffer,a.U.start,a.U.length)}else if(2==a.info.type){if(this.g||this.index.hb())return;if(1==this.info.j){var b=this.index,c=wk(a),d=a.info.U.start;a=0;var e=c.getUint32(0,!1),g=c.getUint8(a+8);a+=12;var h=c.getUint32(a+4,!1);a+=8;var k;0==g?(g=c.getUint32(a,!1),k=c.getUint32(a+4,!1),a+=8):(g=(c.getUint32(a,!1)<<32)+c.getUint32(a+4,!1),k=(c.getUint32(a+8,!1)<<32)+c.getUint32(a+12,!1),a+=16);b.a[0]=k+(e+d);b.b[0]=g;b.g=!0;
-d=c.getUint16(a+2,!1);a+=4;for(e=0;e<d;e++){var m=c.getUint32(a,!1);k=c.getUint32(a+4,!1);a+=12;g=b;k=k/h;g.T++;Fk(g);g.a[g.T]=g.a[g.T-1]+m;g.b[g.T]=g.b[g.T-1]+k}}else this.g=wk(a)}if(ak(this.info)&&this.b&&this.g){c=new DataView(this.b.buffer,this.b.byteOffset,this.b.byteLength);b=this.index;e=this.g;a=new Gk(c);if(440786851==Hk(a)&&(Jk(a),408125543==Hk(a))){h=a;d=h.a;c=Ik(h,!0);h.a=d;a=Kk(a);h=a.g+a.a;for(m=Hk(a);357149030!=m;)Jk(a),m=Hk(a);a=Kk(a);g=1E6;k=1E9;for(d=0;!(a.a>=a.b.byteLength);)if(m=
-Hk(a),2807729==m)g=Lk(a);else if(2807730==m)k=Lk(a);else if(17545==m){var d=a,m=Ik(d,!0),p=0;4==m?p=d.b.getFloat32(d.a):8==m&&(p=d.b.getFloat64(d.a));d.a+=m;d=p}else Jk(a);g/=k;d*=g;a=new Gk(e);if(475249515==Hk(a)){for(a=Kk(a);!(a.a>=a.b.byteLength);)if(m=Hk(a),187==m){e=Kk(a);m=g;k=h;if(179!=Hk(e))m=null;else if(m*=Lk(e),183!=Hk(e))m=null;else{e=Kk(e);for(p=k;!(e.a>=e.b.byteLength);)241==Hk(e)?p=Lk(e)+k:Jk(e);m=[p,m]}e=b;k=m[0];m=m[1];Fk(e);e.a[e.T]=k;e.b[e.T]=m;e.T++}else Jk(a);a=d;c=c+h;Fk(b);
-b.g=!0;b.b[b.T]=a;b.a[b.T]=c}}this.g=null}};function Ok(a,b,c,d){for(var e=[];b<a.index.hb();b++){var g=jk(a.index.a[b],b+1<a.index.T||a.index.g?a.index.a[b+1]-a.index.a[b]:-1),h=a.index.b[b],k;k=a.index;var m=b;k=m+1<k.T||k.g?k.b[m+1]-k.b[m]:-1;var m=Math.max(0,c-g.start),p=Math.min(g.end+1,c+d)-(g.start+m),r=b==a.index.hb()-1&&m+p==g.length;e.push(new qk(3,a,g,b,h,k,m,p,r));if(g.start+m+p>=c+d)break}return new Ck(e)}
-function Pk(a,b){for(var c=0;c+1<a.index.hb()&&b.U.start>=a.index.a[c+1];)c++;return Ok(a,c,b.U.start,b.U.length).a}f.Aj=function(a){return this.Yb()?!0:isNaN(this.a)?!1:a.U.end+1<this.a};f.qf=function(a,b){this.Aj(a);if(!this.Yb()){var c=jk(a.U.end+1,b);c.end+1>this.a&&(c=new hk(c.start,this.a-1));c=[new qk(4,a.a,c)];return new Ck(c)}4==a.type&&(c=Pk(this,a),a=c[c.length-1]);var c=0,d=a.U.start+a.ob+a.Ha;3==a.type&&(c=a.j,d==a.U.end+1&&(c+=1));return Ok(this,c,d,b)};
-f.Ej=function(a,b){var c=Ek(this.index,a);return Ok(this,c,this.index.a[c],b)};f.Do=function(){return this.Yb()&&!isNaN(this.a)&&(this.index.g?this.index.a[this.index.T]:-1)!=this.a};function Qk(){this.duration=0;this.a={}}var Rk=/PT(([0-9]*)H)?(([0-9]*)M)?(([0-9.]*)S)?/;function Sk(a){var b=new Qk;z(a,function(a){var d=a.type,e=a.itag,g=null;ck(d)&&(g=a.size.split("x"),g=new ek(parseInt(g[0],10),parseInt(g[1],10)));var h=null;bk(d)&&(h=new Yj);d=new Zj(e,d,h,g,null,parseInt(a.bitrate,10)/8);g=ik(a.init);h=ik(a.index);(a=Tk(a.url,d,a.s))&&(b.a[e]=new Nk(a,d,g,h))});return b}
-function Uk(a,b){for(var c=a;c;c=c.parentNode)if(c.attributes){var d=c.attributes[b];if(d)return d.value}return""}function Vk(a,b){for(var c=a;c;c=c.parentNode){var d=c.getElementsByTagName(b);if(0<d.length)return d[0]}return null}function Tk(a,b,c){if(!ok(a,kk))return"";b={alr:"yes",mime:b.Jb.split(";")[0]};c&&(b.signature=Xj(c));return Kj(a,b)};function Wk(a,b,c,d,e,g,h,k,m){this.i={};this.o=a;this.F=b;this.b=c;this.a=d;this.g=e;this.A=g;this.j=h;this.k=k;this.B=m}function Xk(a,b){var c=a.A,c=c.replace("$N",a.j),c=c.replace("$L",a.B.toString()),c=c.replace("$M",b.toString());a.k&&(c=S(c,{sigh:a.k}));return c}function Yk(a,b){var c=Math.floor(b/(a.a*a.g)),d=a.a*a.g,e=b%d,g=e%a.a,e=Math.floor(e/a.a),h=a.g,k=a.b-d*c;k<d&&(h=Math.ceil(k/a.a));return{url:Xk(a,c),iu:g,mi:a.a,row:e,rows:h,Rn:a.o*a.a,Qn:a.F*h}};function Zk(a){var b=[];a=a.split("|");for(var c=a[0],d,e,g,h,k,m,p,r,s=1;s<a.length;s++)d=a[s].split("#"),e=s-1,g=parseInt(d[0],10),h=parseInt(d[1],10),k=parseInt(d[2],10),m=parseInt(d[3],10),p=parseInt(d[4],10),r=d[6],d=d[7],b.push(new Wk(g,h,k,m,p,c,r,d,e));this.a=b;this.b={};1<this.a.length&&-1!=this.a[0].j.indexOf("default")&&this.a.splice(0,1)}function $k(a,b){var c=a.a[0].b-1;return wb(Math.round(c*b),0,c)}
-function al(a,b){var c=a.b[b];if(c)return c;for(var c=a.a.length,d=0;d<c;d++)if(a.a[d].o>=b)return a.b[b]=d;a.b[b]=c-1;return c-1};var bl={0:"MONO",1:"LEFT_RIGHT",2:"RIGHT_LEFT",3:"TOP_BOTTOM",4:"BOTTOM_TOP"};var cl={VB:1,WB:2,XB:3};var dl;var el=ac(),el=el.toLowerCase();if(-1!=el.indexOf("android")){var fl=el.match(/android\D*(\d\.\d)[^\;|\)]*[\;\)]/);if(fl)dl=Number(fl[1]);else{var gl={cupcake:1.5,donut:1.6,eclair:2,froyo:2.2,gingerbread:2.3,honeycomb:3,"ice cream sandwich":4,jellybean:4.1},hl=el.match("("+Kb(gl).join("|")+")");dl=hl?gl[hl[0]]:0}}else dl=void 0;var il,jl;function kl(){var a=n("yt.player.utils.videoElement_");a||(a=document.createElement("video"),pa("yt.player.utils.videoElement_",a));return a}function ll(){if(2.2==dl)return!0;var a=kl();try{return!(!a||!a.canPlayType||!a.canPlayType('video/mp4; codecs="avc1.42001E, mp4a.40.2"')&&!a.canPlayType('video/webm; codecs="vp8.0, vorbis"'))}catch(b){return!1}}
-function ml(){var a=Uc("div",{"class":"html5-player-css-loaded"});document.body.appendChild(a);var b="none"==nd(a,"display");F(a);return b};function nl(){var a;if(void 0==il&&(il=!1,window.crypto&&window.crypto.iy))try{a=new Uint8Array(1),window.crypto.iy(a),il=!0}catch(b){}if(il){a=Array(16);var c=new Uint8Array(16);window.crypto.getRandomValues(c);for(var d=0;d<a.length;d++)a[d]=c[d]}else for(a=Array(16),c=0;16>c;c++){for(var d=x(),e=0;e<d%23;e++)a[c]=Math.random();a[c]=Math.floor(256*Math.random())}return a}
-function ol(){for(var a=nl(),b=[],c=0;c<a.length;c++)b.push("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-_".charAt(a[c]&63));return b.join("")}function pl(){return La(nl(),function(a){return(a&15).toString(16)}).join("")};function T(a,b){return void 0==b?a:"1"==b?!0:!1}function ql(a,b,c){for(var d in c)if(c[d]==b)return c[d];return a}function U(a,b){return void 0==b?a:b}function rl(a,b){var c=U(a,b);c&&(c=pk(c));return c}function sl(a){if(!a)return 0;a=a.split(":");var b=parseFloat(a[0]),c=1;2==a.length&&(c=parseFloat(a[1]));return isNaN(b)||isNaN(c)||0==c?0:b/c};function tl(a,b){this.a=a;this.b=b}tl.prototype.clone=function(){return new tl(this.a,this.b)};function ul(a){this.a=[];if(a)t:{var b,c;if(a instanceof ul){if(b=a.tc(),c=a.ic(),0>=a.hb()){a=this.a;for(var d=0;d<b.length;d++)a.push(new tl(b[d],c[d]));break t}}else b=Kb(a),c=Jb(a);for(d=0;d<b.length;d++)vl(this,b[d],c[d])}}function vl(a,b,c){var d=a.a;d.push(new tl(b,c));b=d.length-1;a=a.a;for(c=a[b];0<b;)if(d=b-1>>1,a[d].a>c.a)a[b]=a[d],b=d;else break;a[b]=c}f=ul.prototype;
-f.remove=function(){var a=this.a,b=a.length,c=a[0];if(!(0>=b)){if(1==b)Va(a);else{a[0]=a.pop();for(var a=0,b=this.a,d=b.length,e=b[a];a<d>>1;){var g=2*a+1,h=2*a+2,g=h<d&&b[h].a<b[g].a?h:g;if(b[g].a>e.a)break;b[a]=b[g];a=g}b[a]=e}return c.b}};f.ic=function(){for(var a=this.a,b=[],c=a.length,d=0;d<c;d++)b.push(a[d].b);return b};f.tc=function(){for(var a=this.a,b=[],c=a.length,d=0;d<c;d++)b.push(a[d].a);return b};f.clone=function(){return new ul(this)};f.hb=function(){return this.a.length};
-f.isEmpty=function(){return Ua(this.a)};f.clear=function(){Va(this.a)};function wl(){ul.call(this)}y(wl,ul);function xl(a){R.call(this);this.a=a;this.g=new wl;this.i={}}y(xl,R);xl.prototype.b=!1;function yl(a,b,c){var d;for(c=al(a.a,c);0<=c;){d=a.a.a[c];if(d=d.i[Math.floor(b/(d.a*d.g))]?Yk(d,b):null)return d;c--}return Yk(a.a.a[0],b)}function zl(a){if(!a.b)if(a.g.isEmpty())a.b=!1;else{a.b=!0;var b=a.g.remove(),c=new Image;c.src=Xk(a.a.a[b.nn],b.on);c.onload=v(a.j,a,b.nn,b.on)}}
-xl.prototype.j=function(a,b){this.b=!1;var c=this.a.a[a];c.i[b]=!0;zl(this);var d,e=c.a*c.g;d=b*e;c=Math.min(d+e-1,c.b-1);d=[d,c];this.u("l",d[0],d[1])};function Al(a,b,c){this.b=a;this.a=b;this.g=c}var Bl={playready:["com.youtube.playready"],widevine:["com.widevine.alpha"],clearkey:["org.w3.clearkey","webkit-org.w3.clearkey"]},Cl=["widevine","playready"];function Dl(a,b,c){if(!a.addKey&&!a.webkitAddKey)return null;for(var d=0;d<Cl.length;d++){var e=Cl[d];if(c[e])for(var g=Bl[e],h=0;h<g.length;h++){var k=g[h];if(a.canPlayType(b,k))return new Al(e,k,c[e])}}return null};function El(a,b){this.a=a;this.b=b;this.i=0;Object.defineProperty(this,"timestampOffset",{get:this.Iu,set:this.Ju});Object.defineProperty(this,"buffered",{get:this.Hu})}f=El.prototype;f.append=function(a){this.a.webkitSourceAppend(this.b,a)};f.abort=function(){this.a.webkitSourceAbort(this.b)};f.Hu=function(){return this.a.webkitSourceState==this.a.SOURCE_CLOSED?new Fl:this.a.webkitSourceBuffered(this.b)};f.Iu=function(){return this.i};
-f.Ju=function(a){this.i=a;this.a.webkitSourceTimestampOffset(this.b,a)};function Fl(){this.length=0};function Gl(a){this.activeSourceBuffers=this.sourceBuffers=[];this.a=a;this.b=NaN;this.g=0;Object.defineProperty(this,"duration",{get:this.zu,set:this.Cu});Object.defineProperty(this,"readyState",{get:this.Au});this.a.addEventListener("webkitsourceclose",v(this.Bu,this),!0)}f=Gl.prototype;f.addEventListener=function(a,b,c){this.a.addEventListener(a,b,c)};f.ht=function(){return this.a.webkitMediaSourceURL};
-f.addSourceBuffer=function(a){var b=(this.g++).toString();this.a.webkitSourceAddId(b,a);a=new El(this.a,b);this.sourceBuffers.push(a);return a};f.Au=function(){switch(this.a.webkitSourceState){case this.a.SOURCE_CLOSED:return"closed";case this.a.SOURCE_OPEN:return"open";case this.a.SOURCE_ENDED:return"ended"}return""};f.endOfStream=function(a){var b=this.a.EOS_NO_ERROR;"network"==a?b=this.a.EOS_NETWORK_ERR:"decode"==a&&(b=this.a.EOS_DECODE_ERR);this.a.webkitSourceEndOfStream(b)};f.Bu=function(){Va(this.sourceBuffers)};
-f.zu=function(){return this.b};f.Cu=function(a){this.b=a;this.a.webkitSourceSetDuration&&this.a.webkitSourceSetDuration(a)};function Hl(){this.a=[]}Hl.prototype.listen=function(a,b,c){if(t(b))for(var d=0;d<b.length;d++)this.listen(a,b[d],c);else c=v(c,this),a.addEventListener(b,c,!1),this.a.push(a,b,c)};Hl.prototype.removeAll=function(){if(this.a)for(;this.a.length;){var a=this.a.shift(),b=this.a.shift(),c=this.a.shift();a.removeEventListener&&a.removeEventListener(b,c)}};Hl.prototype.ka=function(){return null===this.a};Hl.prototype.dispose=function(){this.removeAll();this.a=null};function Il(a,b,c,d){this.a=[];this.rd=this.Zb=null;this.i=b;this.g=window.MediaSource?new window.MediaSource:window.WebKitMediaSource?new window.WebKitMediaSource:HTMLMediaElement.prototype.webkitSourceAddId?new Gl(a):null;this.b="";this.j=null;this.listen(this.g,["sourceopen","webkitsourceopen"],oa(this.At,d,c));this.listen(this.g,["sourceclose","webkitsourceclose"],this.zt)}y(Il,Hl);f=Il.prototype;f.Xa=function(a){this.isOpen()?this.g.duration=a:this.i=a};f.isOpen=function(){return"open"==this.g.readyState};
-f.Gb=function(){return"closed"==this.g.readyState};f.At=function(a,b){isNaN(this.i)||(this.g.duration=this.i,this.i=NaN,this.Zb=this.g.addSourceBuffer(a),this.rd=this.g.addSourceBuffer(b),this.j&&(this.j(this),this.j=null))};f.zt=function(){this.dispose()};f.dispose=function(){var a=this.b;if(a)try{window.URL.revokeObjectURL(a)}catch(b){}this.b="";Il.C.dispose.call(this)};
-function Jl(a){if(window.MediaSource&&window.MediaSource.isTypeSupported)return window.MediaSource.isTypeSupported(a);'audio/mp4; codecs="mp4a.40.2"'==a&&(a='video/mp4; codecs="avc1.4d404f"');return!!kl().canPlayType(a)};function Kl(a,b,c,d){this.a=c;this.b=a;this.j=d||"";this.i=b;this.g={}}function ij(a){if(a.a)a=a.b;else if(a.i){var b;b=(new re(a.b)).a.get("id");b="http://www.youtube.com/api/manifest/t2b/source/youtube/id/"+encodeURIComponent(b);b+="/itag/"+a.j;b+="/mfmt/amf";a=we(new re(S(a.b,a.g)),b).toString()}else a=S(a.b,a.g);return a};function Ll(a,b){var c=b.Oa in Ml&&cj();this.i=(this.a=!!(a instanceof Array))?null:new Kl(a,c,this.a,b.Oa);this.b=this.a?a[0]:null;this.g=this.a?a[1]:null;this.xe=b}Ll.prototype.getInfo=function(){return this.xe};Ll.prototype.Re=function(){return this.xe.a.i};var Nl={'video/mp4; codecs="avc1.42001E, mp4a.40.2"':"maybe"},Ol={"application/x-mpegURL":"maybe"},Pl={"application/x-mpegURL":"maybe"};
-function Ql(a,b){if(!ll())return[];var c=Rl(a,b);a=!c.length&&b?Rl(a,!1):c;for(var d={},c=kl(),e=0;e<a.length;e++){var g=a[e];if((c.canPlayType(g.getInfo().Jb)||Sl(g))&&!(g.xe.Oa in Tl||cj()&&"5"==g.xe.Oa)){var h=g.Re();if(!d[h]||ak(d[h].getInfo()))d[h]=g}}var k=[];z(fk,function(a){(g=d[a])&&k.push(g)});return k}function Sl(a){var b;a=a.getInfo().Jb;Ti?b=Pl[a]:2.2==dl?b=Nl[a]:dj("android")&&dj("chrome")&&(b=Ol[a]);return b||""}
-var Ml={5:!0,34:!0,35:!0},Tl={52:!0,53:!0,54:!0,55:!0,60:!0,79:!0,87:!0},Ul={qB:160,mB:133,oB:134,gB:135,cB:136,ZA:137,bB:264,hB:138,XA:140,nB:142,pB:143,jB:144,lB:222,kB:223,dB:145,fB:224,eB:225,$A:146,aB:226,iB:147,YA:149,WA:261,rB:161,iD:171,hD:172,pD:194,mD:195,oD:220,nD:221,lD:196,kD:197,jD:198,tD:242,uD:243,sD:244,rD:247,qD:248};function Vl(a){var b=[];z(a,function(a){a.url&&b.push(Wl(a.url,a.type,"auto","0"))});return b}
-function Wl(a,b,c,d,e){var g=new Yj;(c=gk[c])||(c=gk.small);e=new ek(c[0],c[1],e?-1:0);b=unescape(b.replace(/&quot;/g,'"'));return new Ll(a,new Zj(d,b,g,e))}function Rl(a,b){for(var c=[],d=0;d<a.length;d++){var e=a[d],g;if(g=fc)if(g=0!=e.xe.a.a)g=1==e.getInfo().j;g||0!=e.xe.a.a==b&&c.push(e)}return c}
-function Xl(a,b,c,d){var e=null,g={},h={},k;for(k in Ul){var m=Ul[k],p=a.a[m];if(p&&Jl(p.info.Jb)&&!(0<=p.info.Jb.indexOf("vp9")&&dj("cros armv7"))){if(p.info.g){e||(e=kl());if(!Dl(e,p.info.Jb,p.info.g))continue;if(!d&&p.info.a&&(1280<=p.info.a.width||720<=p.info.a.height))continue;if(261==m)continue}if(m=0<p.info.Jb.indexOf("/webm")?p.info.g?3:1:0<p.info.Jb.indexOf("/mp4")?p.info.g?4:2:null){Ak(p.j,b);var r=p.info.i?g:h;r[m]=r[m]||[];r[m].push(p)}}}a=[3,4,1,2];c&&(a=[4,3,2,1]);c=null;for(k=0;k<a.length;k++)if(g[a[k]]&&
-h[a[k]]){c=a[k];break}a=[];if(null!=c)for(ib(g[c],"itag"),g=g[c].pop(),k=0;k<h[c].length;k++)a.push(new Ll([g,h[c][k]],h[c][k].info));gb(a,function(a,b){var c=a.getInfo(),d=b.getInfo();return d.a.height-c.a.height||d.b-c.b});return a};function nh(a){R.call(this);this.j=[];this.V=new B(0,0);this.I=[];this.b={};this.xa={};this.i={};Yl(this,a)}y(nh,R);var Zl=/\/img\/watermark\/youtube_(hd_)?watermark(-vfl\S{6})?.png$/,$l="author cc_asr cc_load_policy iv_new_window iv_load_policy keywords subscribed rvs title ttsurl ypc_buy_url ypc_full_video_length ypc_item_thumbnail ypc_item_title ypc_item_url ypc_offer_button_text ypc_offer_description ypc_offer_headline ypc_offer_id ypc_price_string ypc_preview ypc_video_rental_bar_text".split(" ");
-f=nh.prototype;f.ca=!1;f.Rk="";f.no=!0;f.eb=!1;f.Jk="";f.Ik="";f.Hk="";f.Dj=!1;f.uh=1;f.en=!1;f.$l=0;f.pe=0;f.fo=!1;f.ok=!1;f.Bm=3;f.di="";f.Da="";f.Fk=!1;f.fg=!1;f.Vl=!1;f.nf=0;f.Fe=!1;f.jm=!1;f.Vf=0;f.df=!1;f.Wl=!0;f.gj=!1;f.Bn=!1;f.Cb=!1;f.Ck=!1;f.Gk=!1;f.Ld=!1;f.rn=!1;f.Dk=!1;f.Rj=0;f.ra=0;f.nh=0;f.ak=!1;f.pl="";f.Zl=!1;f.Zi=!1;f.gm=0;f.Xl=!1;f.Im=!1;f.ya=0;f.Xi=null;f.ff=null;f.rj=!1;f.zf=!1;f.gf=null;f.Jn="";f.Yj=1;f.Ae=0;f.rl=null;f.Yl=!1;f.Cj=0;f.Am=NaN;
-function Kh(a,b){var c=b||{};c.iv_read_url&&(a.Jk=pk(c.iv_read_url));c.iv_invideo_url&&(a.Ik=pk(c.iv_invideo_url));c.iv_cta_url&&(a.Hk=pk(c.iv_cta_url));a.author=U(a.author,c.author);a.ok=T(a.ok,c.cc_asr);a.di=rl(a.di,c.ttsurl);a.Da=U(a.Da,c.cpn);a.g=U(a.g,c.subscribed);a.title=U(a.title,c.title);a.ja=U(a.ja,c.ypc_preview);a.ak=T(a.ak,c.paygated);c.keywords&&(a.xa=am(c.keywords));c.rvs&&(a.mc=bm(c.rvs));c.poster&&(a.pl=c.poster);z($l,function(a){a in c&&(this.b[a]=c[a])},a)}
-function Yl(a,b){var c=b||{};a.eb="1"!=c.hlsdvr||Wi||Ti&&5>Xi?!1:!0;a.Dj="1"==c.infringe||"1"==c.muted;a.An=c.authkey;a.Ea=c.authuser;a.Da||(a.Da=c.cpn||ol());a.Kc=c.csi_page_type;a.Ka=c.sw;a.hd=c.t;a.Fk=T(a.Fk,c.cenchd);a.fg="1"==c.enable_cardio;a.Vl="1"==c.enable_cardio_before_playback;a.nf=void 0==(c.end||c.endSeconds)?a.nf:Number(c.end||c.endSeconds);a.Wl="1"!=c.no_get_video_log;a.gj="1"==c.tmi;a.Bn="1"==c.livemonitor;a.Cb="1"==c.live_playback;a.Ck=T(a.Ck,c.mdx);a.Gk=T(a.Gk,c.on3g);a.Dk=T(a.Dk,
-c.utpsa);a.oo=c.iurlmaxres;a.G=U(a.G,c.oauth_token);a.Q=U(a.Q,c.vvt);a.ld=c.osig;a.Ra=c.ptchn;a.Va=c.oid;a.A=c.ptk;a.jb=c.pltype;a.fb=c.plid;a.k=c.eventid;a.Ta=U(a.Ta,c.list);a.kb=c.pyv_beacon_url;a.jd=c.purchase_id;a.ga=c.sdetail;a.gd=c.sourceid;a.aa=U(a.aa,c.feature);a.Sa=1==(void 0==c.is_fling?a.Sa?1:0:Number(c.is_fling));a.ha=U(a.ha,c.ytr);a.po=c.iurlsd;a.Yl="1"==c.skip_kansas_logging;a.ff=ql(a.ff,c.vq||c.suggestedQuality,dk);a.oe=c.approx_threed_layout||0;a.rj="1"==c.threed_converted;a.Bi=c.iurl;
-a.Zi="1"==c.sendtmp;a.Xl=!!a.Ka||a.Zi;a.ya=void 0==(c.start||c.startSeconds)?a.ya:Number(c.start||c.startSeconds);a.M=c.docid||c.video_id||c.videoId;cm(a,c.watermark);a.Ic=U(a.Ic,c.ypc_gid);a.Jc=U(a.Jc,c.ypc_license_session_token);if(c.ad3_module||c.ad_module)"1"==c.allow_html5_ads?(a.ca=!0,"1"==c.ad_preroll&&a.I.push("ad")):"1"==c.supported_without_ads||c.cta&&c.fexp&&(-1!=c.fexp.indexOf("924604")||-1!=c.fexp.indexOf("924610"))||(a.jm=!0);c.adaptive_fmts&&(a.Rk=c.adaptive_fmts);c.allow_embed&&(a.no=
-"1"==c.allow_embed);c.autoplay&&(a.df="1"==c.autoplay);c.iv_load_policy&&(a.da=dm(c.iv_load_policy,a.da));c.cc_load_policy&&(a.Bm=dm(c.cc_load_policy,2));q(c.dash)&&void 0===a.Y&&(a.Y="1"==c.dash);if(c.dashmpd){a.B=S(c.dashmpd,{cpn:a.Da});var d=/\/s\/([0-9A-F.]+)/,e=d.exec(a.B);e&&(e=Xj(e[1]),a.B=a.B.replace(d,"/signature/"+e))}c.delay&&(a.J=Fa(c.delay));c.idpj&&(a.Vf=Fa(c.idpj));c.url_encoded_fmt_stream_map&&(a.Jn=c.url_encoded_fmt_stream_map);c.hlsvp&&(a.va=c.hlsvp);c.length_seconds&&(a.ra=Fa(c.length_seconds));
-c.ldpj&&(a.nh=Fa(c.ldpj));c.loudness&&(a.za=c.loudness,a.uh=-15<a.za&&0>a.za?Math.pow(10,(-18-a.za)/20):1);c.partnerid&&(a.md=Fa(c.partnerid));c.pyv_billable_url&&ok(c.pyv_billable_url,mk)&&(a.O=c.pyv_billable_url);c.pyv_conv_url&&ok(c.pyv_conv_url,mk)&&(a.Ca=c.pyv_conv_url);c.url_encoded_third_party_media&&(a.gf=bm(c.url_encoded_third_party_media));c.threed_module&&!c.threed_converted&&(a.P=c.threed_module,a.Hc=6);if("1"==c.track_embed||c.tk)a.Zl=!0;c.watch_ajax_token&&ef("watch_actions_ajax",c.watch_ajax_token);
-c.fresca_preroll&&a.I.push("fresca");c.ypc_clickwrap_module&&a.I.push("ypc_clickwrap");void 0!=c.start&&(a.Cj=c.start);void 0!=c.end&&(a.Am=c.end);a.lc=U(a.lc,c.ucid);z(["baseUrl","uid","oeid","ieid","ppe"],function(a){this.i[a]=c[a]},a);a.i.focEnabled="1"==c.focEnabled;a.i.rmktEnabled="1"==c.rmktEnabled;a.$l=em(c.rmktPingThreshold,c.length_seconds);a.b=c;Kh(a,c);a.Y&&fm(a)}
-function fm(a){if(dj("android")&&dj("chrome")&&!uc(29)?0:window.MediaSource||window.WebKitMediaSource||HTMLMediaElement.prototype.webkitSourceAddId)if(a.Rk)a.L=Sk(gm(a,a.Rk));else if(a.B){var b={format:"RAW",method:"GET",S:a,Pa:a.Qw,onError:a.gl};a.Fe=!0;a=pk(a.B);Qj(a,b)}}
-f.Qw=function(a){if(!this.ka()){if(200<=a.status&&400>a.status){var b=new Qk;t:{a=a.responseText;a=(new DOMParser).parseFromString(a,"text/xml").getElementsByTagName("MPD")[0];var c;if(c=Uk(a,"mediaPresentationDuration")){var d=Rk.exec(c);c=d?3600*parseFloat(d[2]||0)+60*parseFloat(d[4]||0)+parseFloat(d[6]||0):parseFloat(c)}else c=0;b.duration=c;a=a.getElementsByTagName("Representation");for(c=0;c<a.length;c++){var d=a[c],e=Uk(d,"id"),g=Uk(d,"mimeType"),h=Uk(d,"codecs"),g=h?g+'; codecs="'+h+'"':g,
-h=parseInt(Uk(d,"bandwidth"),10)/8,k=null;ck(g)&&(k=new ek(parseInt(Uk(d,"width"),10),parseInt(Uk(d,"height"),10)));var m=null;bk(g)&&(m=new Yj);var p=null,r=Vk(d,"ContentProtection");if(r)if((p=r.attributes.schemeIdUri)&&"http://youtube.com/drm/2012/10/10"==p.textContent)for(p={},r=r.firstChild;null!=r;r=r.nextSibling)"yt:SystemURL"==r.nodeName&&(p[r.attributes.type.textContent]=r.textContent.trim());else p=null;e=new Zj(e,g,m,k,p,h);g=Tk(Vk(d,"BaseURL").textContent,e);h=Vk(d,"SegmentBase");d=ik(h.attributes.indexRange.value);
-h=ik(h.getElementsByTagName("Initialization")[0].attributes.range.value);d=new Nk(g,e,h,d);if(!d){a=!1;break t}b.a[d.info.Oa]=d}a=!0}if(this.L=a?b:null)this.ra=this.L.duration||this.ra}this.gl()}};f.gl=function(){this.ka()||(this.Fe=!1,this.u("dataloaded",this.b))};
-function hm(a,b){if(!a.ka()){a.L&&(a.j=Xl(a.L,im(a),!!b,a.Fk));if(!a.j.length){if(a.gf&&a.rn){var c;c=Vl(a.gf);c=Ql(c,!1)}else{c=gm(a,a.Jn);if(a.va){var d;d=a.va;var e={cpn:a.Da};!a.Gk&&(e.ibw="1369843");d={url:S(d,e),type:"application/x-mpegURL",quality:"auto",itag:"93"};c.push(d)}d=!!a.P||a.zf;for(var e=[],g=0;g<c.length;g++){var h=c[g];if(h.sig||h.s){var k=h.sig||Xj(h.s);h.url=Kj(h.url,{signature:k})}h.url&&e.push(Wl(h.url,h.type,h.quality,h.itag,h.stereo3d))}c=Ql(e,!!d)}a.j=c;a.j.length&&(a.Y=
-!1)}a.u("dataupdated")}}function jm(a){a=La(a.j,function(a){return a.Re()});eb(a);return a.concat(["auto"])}function km(a,b){var c=null;a.j.some(function(a){if(a.Re()==b)return c=a,!0});return c}function lm(a){var b=a.o&&a.o.i;if(!b)return null;w(b.g,im(a));return b}function im(a){var b={};a.A&&(b.ptk=a.A,b.oid=a.Va,b.ptchn=a.Ra,b.pltype=a.jb);return b}function mm(a,b){return u(a.xa[b])?a.xa[b]:null}function nm(a){!a.rl&&a.b.storyboard_spec&&(a.rl=new Zk(a.b.storyboard_spec));return a.rl}
-function om(a){var b=nm(a);!a.Xi&&b&&(a.Xi=new xl(b),L(a,a.Xi));return a.Xi}function pm(a,b){var c={format:"RAW",method:"GET",S:a,Pa:a.jx};a.Fe=!0;Qj(b,c)}f.jx=function(a){this.ka()||(this.Fe=!1,a=Fj(a.responseText),"fail"==a.status?this.u("onStatusFail",a):(Yl(this,a),this.Fe||this.gl()))};function dm(a,b){var c=parseInt(a,10);return Lb(cl,c)?c:b}function bm(a){a=a.split(",");return a=a.map(function(a){return Fj(a)})}
-function gm(a,b){var c=bm(b);z(c,function(a){a.url&&(a.url=S(a.url,{cpn:this.Da}))},a);return c}function am(a){var b={};z(a.split(","),function(a){var d=a.split("=");2==d.length?b[d[0]]=d[1]:b[a]=!0});return b}function cm(a,b){if(b){var c=b.split(",");2<=c.length&&(a.Ma=c[1],a.Lc=c[0])}}function qm(a,b){return!!a.b[b]}function em(a,b){var c=Fa(b),d=Fa(a);return isNaN(d)||isNaN(c)?0:Math.min(d,c)};function rm(a,b){this.type=a||"";this.id=b||""}rm.prototype.toString=function(){return this.type+this.id};function sm(a){R.call(this);this.a=[];this.b=[];this.ua=Math.max(0,a.index||0);this.loop=!!a.loop;this.ya=a.startSeconds||0;this.zn="1"==a.mob;this.title=a.playlist_title||"";a.video_id&&(this.a[this.ua]=new nh(a));a.api&&("string"==typeof a.api&&16==a.api.length?a.list="PL"+a.api:a.playlist=a.api);if(a.list)switch(a.listType){case "user_uploads":tm(this,a.list);break;case "user_favorites":um(this,a.list);break;case "search":vm(this,a.list);break;default:a.playlist_length&&(this.Mb=a.playlist_length),
-this.g=new rm(a.list.substr(0,2),a.list.substr(2)),this.Tg||wm(this,"/list_ajax?style=json&action_get_list=1",{list:this.g})}else if(a.playlist){var b=a.playlist.toString().split(",");0<this.ua&&(this.a=[]);z(b,function(a){a&&this.a.push(new nh({video_id:a}))},this);this.Mb=this.a.length;this.Vd=!0}else a.videoList&&(0<this.ua&&(this.a=[]),z(a.videoList,function(a){this.a.push(new nh(a))},this),this.Mb=this.a.length,this.Vd=!0);yh(this,!!a.shuffle);a.suggestedQuality&&(this.i=a.suggestedQuality)}
-y(sm,R);f=sm.prototype;f.loop=!1;f.ya=0;f.xo=!1;f.ua=0;f.title="";f.Mb=0;f.zn=!1;f.Vd=!1;f.Tg=!1;f.ye=null;function xm(a){if(++a.ua>=a.Mb)if(a.loop)a.ua=0;else return null;xh(a,a.ua);return wh(a,a.ua)}function ym(a){if(0>--a.ua)if(a.loop)a.ua=a.Mb-1;else return null;xh(a,a.ua);return wh(a,a.ua)}function wh(a,b){var c=void 0!=b?b:a.ua;if(c=a.a&&c in a.a?a.a[a.b[c]]:null)c.ya=a.ya||c.Cj||0;return c}
-function yh(a,b){a.xo=b;var c=a.b&&null!=a.b[a.ua]?a.b[a.ua]:a.ua;a.b=[];for(var d=0;d<a.a.length;d++)a.b.push(d);a.ua=c;if(a.xo){c=a.b[a.ua];for(d=1;d<a.b.length;d++){var e=Math.floor(Math.random()*(d+1)),g=a.b[d];a.b[d]=a.b[e];a.b[e]=g}for(d=0;d<a.b.length;d++)a.b[d]==c&&(a.ua=d)}a.u("shuffle")}function xh(a,b){a.ua=wb(b,0,a.Mb-1);a.ya=0}function zm(a){return a.Mb}function tm(a,b){a.Tg||(a.g=new rm("UU","PLAYER_"+b),wm(a,"/list_ajax?style=json&action_get_user_uploads_by_user=1",{username:b}))}
-function um(a,b){a.Tg||(a.g=new rm("FL","PLAYER_"+b),wm(a,"/list_ajax?style=json&action_get_favorited_by_user=1",{username:b}))}function vm(a,b){if(!a.Tg){a.g=new rm("SR",b);var c={search_query:b};a.zn&&(c.mob="1");wm(a,"/search_ajax?style=json&embeddable=1",c)}}function wm(a,b,c){Qj(S(b,c),{format:"JSON",Pa:function(a,b){Am(this,b)},S:a})}
-function Am(a,b){if(b.video&&b.video.length){a.title=b.title;a.description=b.description;a.views=b.views;a.author=b.author;var c=wh(a);a.ua=0;a.a=[];z(b.video,function(a){a&&(a.video_id=a.encrypted_id,c&&a.video_id==c.M&&(this.ua=this.a.length),this.a.push(new nh(a)))},a);a.Mb=a.a.length;yh(a,!1);a.Tg=!1;a.Vd=!0;a.ye&&a.ye()}}f.H=function(){this.ye=null;Ug(this.a);sm.C.H.call(this)};var Bm=!!l.DOMTokenList,Cm=Bm?function(a){return a.classList}:function(a){a=a.className;return u(a)&&a.match(/\S+/g)||[]},Dm=Bm?function(a,b){return a.classList.contains(b)}:function(a,b){return Ta(Cm(a),b)},V=Bm?function(a,b){a.classList.add(b)}:function(a,b){Dm(a,b)||(a.className+=0<a.className.length?" "+b:b)},Em=Bm?function(a,b){z(b,function(b){V(a,b)})}:function(a,b){var c={};z(Cm(a),function(a){c[a]=!0});z(b,function(a){c[a]=!0});a.className="";for(var d in c)a.className+=0<a.className.length?
-" "+d:d},W=Bm?function(a,b){a.classList.remove(b)}:function(a,b){Dm(a,b)&&(a.className=Ka(Cm(a),function(a){return a!=b}).join(" "))},Fm=Bm?function(a,b){z(b,function(b){W(a,b)})}:function(a,b){a.className=Ka(Cm(a),function(a){return!Ta(b,a)}).join(" ")};function X(a,b,c){c?V(a,b):W(a,b)}function Gm(a,b){var c=!Dm(a,b);X(a,b,c);return c};function Hm(a,b){this.Sf=a;this.cf=b+"::"}y(Hm,Tf);f=Hm.prototype;f.Sf=null;f.cf="";f.set=function(a,b){this.Sf.set(this.cf+a,b)};f.get=function(a){return this.Sf.get(this.cf+a)};f.remove=function(a){this.Sf.remove(this.cf+a)};f.Id=function(a){var b=this.Sf.Id(!0),c=this,d=new Sd;d.next=function(){for(var d=b.next();d.substr(0,c.cf.length)!=c.cf;)d=b.next();return a?d.substr(c.cf.length):c.Sf.get(d)};return d};function Im(a){R.call(this);this.a=a;if(this.nl){a="yt-html5-player-modules::"+this.nl;var b=new Vf;if(a=b.isAvailable()?a?new Hm(b,a):b:null)this.o=new Xf(a)}}y(Im,R);f=Im.prototype;f.qa="";f.ad="";f.vc=!1;f.ba=!1;f.Ac=null;f.uf=function(a){var b=ab(arguments),c=v(this.yc,this),d=v(this.Vc,this);z(b,function(a){a.namespace=this.qa;a.Eb.D("onEnter",c);a.Eb.D("onExit",d)},this);this.u("command_add_cuerange",b,this.a.a)};f.lv=function(a){var b=ab(arguments);this.u("command_remove_cuerange",b,this.a.a)};
-function Jm(a){a.u("command_remove_cuerange_all",a.qa,a.a.a)}function Km(a){a.u("command_preroll_ready",a.qa,a.a.a)}function Lm(a,b){V(b,a.qa);a.a.app.R.V.appendChild(b)}function Mm(a){a.u("command_show_dialog_area")}function Nm(a){a.u("command_hide_all_dialogs")}f.create=function(){this.vc||(this.$a(this.a),V(Q(this.a),this.qa+"-created"),this.vc=!0)};f.destroy=function(){this.unload();W(Q(this.a),this.qa+"-created");this.vc=!1};f.load=function(){V(Q(this.a),this.qa+"-loaded");this.u("loaded",this.qa)};
-f.unload=function(){W(Q(this.a),this.qa+"-loaded");this.u("unloaded",this.qa)};f.yc=function(){};f.Vc=function(){};f.ie=function(){};f.log=function(a){this.u("command_log",this.ad,a)};function Om(a,b,c){var d={},e;for(e in b)d[a.qa+"_"+e]=b[e];b={};for(var g in c)b[a.qa+"_"+g]=c[g];a.u("command_log_timing",d,b)}f.Hi=function(){return null};function Pm(a,b){if(!a.o)return null;var c;try{c=a.o.get(b)}catch(d){a.o&&a.o.remove(b)}return c}function Qm(a,b,c){if(a.o)try{a.o.set(b,c)}catch(d){}}
-function Rm(a,b){a.u("command_disable_controls",b,a.qa)}function Sm(a,b){a.u("command_enable_controls",b,a.qa)}function Tm(a){a.u("command_stop_redirect_controls")}function Um(a){a.u("command_play",!1,a.a.a)}function Vm(a){a.u("command_pause",!1,a.a.a)}f.mb=function(a){this.u("command_redirected_show_is_playing",a)};f.aq=function(){};f.Vo=function(){return[]};f.$a=function(){return!1};f.vo=function(a,b){this.Ac&&this.Ac.ie&&this.Ac.ie.apply(this.Ac,arguments)};f.Qh=function(){};function Wm(a,b){this.b=a;this.Eb=b;this.vc=!1;this.o="base-endscreen";this.g=this.i=null}Wm.prototype.create=function(){this.i=E("html5-endscreen",Q(this.b));V(this.i,this.o);this.g=E("html5-endscreen-content",Q(this.b));this.vc=!0};Wm.prototype.destroy=function(){this.vc=!1};Wm.prototype.load=function(){};function Xm(a){this.a={};this.g={};this.i={};this.b=Ym(this,a)}y(Xm,K);function Ym(a,b,c){var d=0,e=Xc(b[d++]);if(u(b[d])||t(b[d])||null===b[d]){var g=b[d++];t(g)&&(g=g.join(" "));if(g=Zm(a,e,"className",g))$m(a,e,"className",g),an(a,g,e)}for(;d<b.length;d++){var h=b[d];if(t(h))Ym(a,h,e);else if(ia(h)){var g=a,k=e,m=void 0;for(m in h)h[m]&&$m(g,k,m,Zm(g,k,m,h[m]))}else u(h)&&$m(a,e,"child",Zm(a,e,"child",h))}c&&c.appendChild(e);return e}f=Xm.prototype;f.N=function(){return this.b};
-function an(a,b,c){var d=b.split(" ");if(1<d.length)for(b=0;b<d.length;b++)an(a,d[b],c);else a.a[b]=c}f.W=function(a,b){q(b)?a.insertBefore(this.b,a.childNodes[b]||null):a.appendChild(this.b)};f.ve=function(){F(this.b)};function Zm(a,b,c,d){return u(d)&&"{{"==d.substr(0,2)?(a.g[d]=[b,c],null):d}f.update=function(a){for(var b in a)bn(this,b,a[b])};function bn(a,b,c){if(c!=a.i[b]){var d=a.g["{{"+b+"}}"];d&&(a.i[b]=c,$m(a,d[0],d[1],c))}}
-function $m(a,b,c,d){if("child"==c){$c(b);if(!t(d)||t(d)&&u(d[0]))d=[d];c=[];for(var e=0;e<d.length;e++){var g=d[e];null===g||(!g.nodeType||1!=g.nodeType&&3!=g.nodeType?t(g)&&u(g[0])?c.push(Ym(a,g)):g.N?c.push(g.N()):c.push(Yc(g.toString())):c.push(g))}for(a=0;a<c.length;a++)b.appendChild(c[a])}else"className"==c?b.className=d:null===d?b.removeAttribute(c):b.setAttribute(c,d.toString())}f.H=function(){this.a={};this.g={};this.i={};this.ve();this.b=null;Xm.C.H.call(this)};function cn(a){a&&(a.style.display="block")}function dn(a){a&&(a.style.display="none")}function en(a,b){var c=We("requestAnimationFrame",window);return H(function(){c?c.call(window,a):a()},b||0)};function Y(a){this.template=new Xm(a);L(this,this.template);this.element=this.template.N();this.A="block";this.J=[];this.j={}}y(Y,K);f=Y.prototype;f.N=function(){return this.element};f.W=function(a,b){this.template.W(a,b)};f.ve=function(){this.template.ve()};f.Aa=function(a){bn(this.template,"content",a)};f.show=function(){var a=this.element;a&&(a.style.display=this.A);this.element.removeAttribute("aria-hidden")};f.hide=function(){dn(this.element);this.element.setAttribute("aria-hidden","true")};
-f.listen=function(a,b,c,d,e){a=J(a,b,v(c,d||this));this.J.push(a);u(e)&&(this.j[e]?this.j[e].push(a):this.j[e]=[a]);return a};f.ac=function(a){yf(a)};function fn(a,b){a.ac(a.j[b]);a.j[b]=[]}f.stopPropagation=function(a){this.listen(this,a,function(a){a.stopPropagation()})};f.addEventListener=function(a,b,c){this.element.addEventListener?this.element.addEventListener(a,b,c):this.element.attachEvent&&this.element.attachEvent("on"+a,b)};
-f.removeEventListener=function(a,b,c){this.element.removeEventListener?this.element.removeEventListener(a,b,c):this.element.detachEvent&&this.element.detachEvent("on"+a,b)};f.dispatchEvent=function(a){return this.element.dispatchEvent(a)};f.fireEvent=function(a,b){return this.element.fireEvent(a,b)};f.H=function(){this.ac(this.J);this.element=null;Y.C.H.call(this)};function gn(){Y.call(this,["div","",["div","ytp-channel-banner-container",["img","ytp-channel-banner",{src:"{{banner}}"}],["div","ytp-subscribe-curtain"]],["div","ytp-subscribe-card",["img","ytp-author-image",{src:"{{image}}"}],["div","ytp-subscribe-card-right",["div","ytp-author-name","{{author}}"],["div","html5-subscribe-button-container"]]]])}y(gn,Y);function hn(a,b,c,d,e,g,h){a&&(a={video_id:a,html5:1,page_subscribe:b?1:0},g&&(a.authuser=g),h&&(a.pageid=h),Qj("/get_video_metadata",{method:"GET",onError:d,Pa:c,rf:a,S:e}))};function jn(a,b){Wm.call(this,a,b);this.o="subscribecard-endscreen";this.a=null}y(jn,Wm);jn.prototype.create=function(){jn.C.create.call(this);this.a=new gn;this.a.W(this.i);hn(this.b.getVideoData().M,!0,this.j,ba,this,this.b.K().Ea,this.b.K().Ua)};jn.prototype.destroy=function(){Tg(this.a);jn.C.destroy.call(this)};
-jn.prototype.j=function(a,b){if(this.vc){var c=b.user_info,d=this.b.getVideoData();d&&(d.pa=c.external_id);bn(this.a.template,"banner",c.channel_banner_url);bn(this.a.template,"image",c.channel_logo_url||c.image_url);bn(this.a.template,"author",c.channel_title||c.username);d=b.video_info;d.subscription_ajax_token&&ef("subscription_ajax",d.subscription_ajax_token);c=c.subscription_button_html;this.a.template.a["html5-subscribe-button-container"].innerHTML=c?c:""}};function kn(a,b,c){c=c||{};var d=c.Ib;d||(d=document.createElement("style"),document.getElementsByTagName("head")[0].appendChild(d),d=d.sheet||d.styleSheet);c.reset&&ln(d);b=b instanceof Array?b.join(";"):b;d.insertRule?d.insertRule(a+"{"+b+"}",d.cssRules.length):d.addRule(a,b,-1);return d}function ln(a){for(var b=(a.cssRules||a.rules).length;0<b;b--){var c=a;c.deleteRule?c.deleteRule(0):c.removeRule(0)}};function mn(a){this.X=a}y(mn,K);mn.prototype.b=null;mn.prototype.g=null;mn.prototype.a=null;function nn(a){a.b||(a.b=E("ad-container",Q(a.X)),a.X.K().tb&&V(a.b,"ad-container-single-media-element"));return a.b}function on(a){a.a&&(a.X.K().tb?(W(a.a,"ad-video"),pn(a.X.app,a.a),a.a=null):(F(a.a),nj(a.a)))}
-function qn(a){if(!a.g){if(a.X.K().Db){var b=Xc("button");V(b,"video-click-tracking");Zc(b,mf("VISIT_ADVERTISERS_SITE"));var c=Xc("div");V(c,"video-click-tracking-container");c.appendChild(b);nn(a).appendChild(c)}else b=Xc("div"),Em(b,["video-click-tracking","ad-video"]),nn(a).appendChild(b);a.g=b}return a.g}mn.prototype.H=function(){mn.C.H.call(this);this.a&&(pn(this.X.app,this.a),this.a=null);on(this);$c(nn(this));$c(qn(this));this.g=this.b=null;delete this.X};
-function rn(a){if(!a.a){var b;b=a.X.app;if(b.a.tb){var c=new A(b.i.offsetLeft,b.i.offsetTop),d=Cd(b.i);b.O=new Db(c.x,c.y,d.width,d.height);sn(b.j);oj(b.i,1);nj(b.i);b=b.i}else b=tn.getTag();a.a=b;Em(a.a,["video-stream","ad-video"])}return a.a};function un(a,b,c,d){Y.call(this,["div",{className:"ytp-button",role:"button","aria-label":"{{label}}","aria-disabled":"{{disabled}}",tabindex:"{{tabindex}}"},"{{content}}"]);this.A="inline-block";this.g=a;this.L=this.a=this.F=null;this.k=!1;this.listen(this.element,"click",this.Zu);this.listen(this.element,"keypress",this.$u);a=this.g;var e=v(this.Yu,this);a.a&&vn(a.a,this.element,e);b&&wn(this,b);c&&this.Hb(c);d&&(this.a=d)}y(un,Y);
-function wn(a,b){b&&""!=b&&(a.F&&W(a.element,a.F),a.F=b,V(a.element,b))}f=un.prototype;f.Hb=function(a){bn(this.template,"label",a)};function xn(a,b){a.L=b;bn(a.template,"tabindex",b)}f.Yu=function(){return this.k?null:this.a?Yc(this.a):null};f.enable=function(){this.k=!1;this.template.update({disabled:null,tabindex:this.L});W(this.element,"ytp-disabled")};f.disable=function(){this.k=!0;this.template.update({disabled:"true",tabindex:null});V(this.element,"ytp-disabled")};
-f.Zu=function(a){this.k&&(a.stopImmediatePropagation(),a.preventDefault())};f.$u=function(a){if(13==a.keyCode||32==a.keyCode)a.stopPropagation(),a.preventDefault(),Ef(this.element,"click")};f.H=function(){var a=this.g;if(a.a){var a=a.a,b=ja(this.element);Tg(a.a[b]);a.a[b]=null}this.g=null;un.C.H.call(this)};function yn(a,b){Y.call(this,["canvas"]);this.element.width=a;this.element.height=b;this.width=a;this.height=b;this.S=this.element.getContext("2d");this.a=0;this.k=null}y(yn,Y);yn.prototype.g=function(a,b){I(this.a);this.a=en(v(this.g,this,a,b),b);a.call(this,new Date-this.k)};yn.prototype.H=function(){I(this.a);this.S=null;yn.C.H.call(this)};function zn(){yn.call(this,84,84);this.b=this.width/2;this.F=this.height/2;this.i=An}y(zn,yn);var An=3*Math.PI/2,Bn=2*Math.PI;function Cn(a,b){var c=b*Bn+An;a.S.beginPath();a.S.arc(a.b,a.F,40,a.i,c,!1);a.S.lineWidth=4;a.S.strokeStyle="#b8b8b8";a.S.stroke();a.i=c}
-zn.prototype.show=function(){zn.C.show.call(this);this.S.globalAlpha=0.8;this.S.beginPath();this.S.arc(this.b,this.F,42,0,Bn);this.S.fillStyle="#333";this.S.fill();var a=35*(Math.sqrt(3)/2);this.S.save();this.S.fillStyle="#fff";this.S.globalAlpha=0.9;this.S.translate(a,this.b);this.S.beginPath();this.S.lineTo(0,a/2);this.S.lineTo(28,0);this.S.lineTo(0,-a/2);this.S.closePath();this.S.fill();this.S.restore();Cn(this,0)};function Dn(a){var b=Math.floor(a/86400),c=Math.floor(a%86400/3600),d=Math.floor(a%3600/60);a=Math.floor(a%60);var e="";0<b&&(e+=b+":",10>c&&(e+="0"));0<c&&(e+=c+":",10>d&&(e+="0"));e+=d+":";10>a&&(e+="0");return e+a};var En={HC:"html5-stop-propagation",gA:"html5-chromeless",SB:"html5-live-dvr-disabled",TB:"html5-live-dvr-engaged",UB:"html5-live-playback",bC:"html5-mobile",dC:"modest-branding",fC:"html5-native-controls",MC:"html5-tablet",LC:"html5-tablet-body",ZB:"html5-main-video",WC:"html5-video-container",XC:"html5-video-content",YC:"html5-video-controls",ZC:"ytp-fallback",$C:"ytp-fallback-content",bD:"html5-video-loader",gD:"html5-watermark",Qz:"html5-branded-watermark",fD:"html5-viewport-sheet",mA:"html5-context-menu",
-Tr:"html5-context-menu-copy-debug-info",Ur:"html5-context-menu-copy-embed-html",Vr:"html5-context-menu-copy-video-url",Wr:"html5-context-menu-copy-video-url-at-current-time",Xr:"html5-context-menu-link",Yr:"html5-context-menu-report-playback-issue",Zr:"html5-context-menu-show-video-info",nA:"html5-show-video-info-template",cC:"html5-modal-panel",JB:"html5-info-bar",Kz:"autohide-off",Lz:"autohide-on",Jz:"autohide-fade",Hz:"autohide-auto",Iz:"autohide-embeds",Mz:"autohide-seekbar",Gz:"autohide-aspect",
-xB:"hide-controls",yB:"hide-info-bar",zB:"html5-hide-share",AB:"html5-hide-volume",eD:"video-thumbnail",qC:"html5-popup-dialog",Az:"html5-async-progress",Bz:"html5-async-success",zz:"html5-async-error",bA:"html5-center-overlay",AC:"ytp-scalable-icon-shrink",zC:"ytp-scalable-icon-grow",EB:"house-brand"};function Fn(a,b){(a=Mc(a))&&a.style&&(a.style.display=b?"":"none",Hc(a,"hid",!b))}function Gn(a){return(a=Mc(a))?!("none"==a.style.display||Gc(a,"hid")):!1}function Hn(a){z(arguments,function(a){Fn(a,!0)})}function In(a){z(arguments,function(a){Fn(a,!1)})}function Jn(a){var b=document.body;if(void 0!=b.style[a])return a;a=a.charAt(0).toUpperCase()+a.substr(1);for(var c=["Moz","Webkit","ms","O"],d=0;d<c.length;d++)if(void 0!=b.style[c[d]+a])return c[d]+a}
-function Kn(a,b,c){(a=Mc(a))&&a.style&&(b=Jn(b))&&(a.style[b]=c)};var Ln=window.location.protocol+"//i.ytimg.com/",Mn=4/3;function Nn(a,b,c){var d;switch(b.md){case 30:d=On;break;default:d=Pn}return d(a,b,c)}function Pn(a,b,c){if(!c){c=a.clientHeight;a=a.clientWidth;if((900<a||600<c)&&b.oo)return b.oo;if((430<a||320<c)&&b.po)return b.po}return b.Bi?b.Bi:b.M?Qn(b.M):""}function On(a,b){return b.Bi?b.Bi:b.M?S("//docs.google.com/vt",{id:b.M,authuser:b.Ea,authkey:b.An}):"//docs.google.com/images/doclist/cleardot.gif"}
-function Qn(a,b){return(Ln+"vi/"+escape(a)+"/"+escape(b||"hqdefault.jpg")).replace("i.","i"+(a.charCodeAt(0)%df("THUMBNAIL_NUM_SHARDS",1)+1)+".")};function Rn(a,b,c){this.b=a;(a=b||null)||(a=Sn(this.b));a="("+a.join("|")+")";a=wa("__%s__",a);this.g=RegExp(a,"g");this.a=c||{}}var Tn=/__([a-z]+(?:_[a-z]+)*)__/g;function Un(a,b){var c=Mc(a).innerHTML,c=c.replace(/^\s*(\x3c!--\s*)?/,""),c=c.replace(/(\s*--\x3e)?\s*$/,"");return new Rn(c,b,void 0)}function Sn(a){var b=[],c={};a.replace(Tn,function(a,e){e in c||(c[e]=!0,b.push(e))});return b}
-function Vn(a,b,c,d){var e=v(function(a,e){c&&(e=c(e));return d?b[e]||this.a[e]||"":ya(b[e]||this.a[e]||"")},a);return a.b.replace(a.g,e)};function Wn(a,b){this.X=a;this.F=b;var c=E("videowall-still-content-template",Q(this.X));this.B=Un(c);c=Xc("a");c.tabIndex=0;V(c,"videowall-still");J(c,"click",v(this.jv,this));J(c,"keypress",v(this.kv,this));this.a=c;this.o=this.X.app.R.B}f=Wn.prototype;
-f.update=function(a,b){this.g=a.feature_type||"endscreen";this.j=a.id||a.video_id;this.i=a.list;var c=!1,d=!1;a.endscreen_autoplay||("episodic"==this.g?d=!0:this.i&&(c=!0));var e=Ob(a);c||d?(e.index=parseInt(e.index,10)+1,e.title||(e.title=a.playlist_title,e.author=a.playlist_author),e.playlist_length||(e.playlist_length=0)):e.duration=Dn(a.length_seconds);var g=Qn(c&&a.thumbnail_ids?a.thumbnail_ids.split(",")[0]:this.j,b?"hqdefault.jpg":"mqdefault.jpg");this.a.style.backgroundImage="url("+g+")";
-this.a.innerHTML=Vn(this.B,e,void 0,!0);X(this.a,"videowall-still-featured",!!a.featured);X(this.a,"videowall-still-list",c);X(this.a,"videowall-still-episodic",d)};f.N=function(){return this.a};f.select=function(a,b){this.i?Xn(this.X.app,this.j,a||this.g,this.i,b):Xn(this.X.app,this.j,a||this.g,void 0,b)};f.ju=function(){var a=new Date-this.A;1E4>a?(Cn(this.b,a/1E4),a=1E4-a,E("videowall-still-listlabel-autoplay-message",this.a).innerHTML=nf("AUTOPLAY_MESSAGE",Math.ceil(a/1E3))):(jf(this.k),this.select("autoplay"))};
-f.ku=function(a){var b=jd(a.target,"videowall-still-listlabel-autoplay"),c=E("autoplay-play-canvas",this.a);V(b,"videowall-still-listlabel-autoplay-hide");V(c,"autoplay-play-canvas-hide");X(this.a,"videowall-still-autoplay",!1);a.stopPropagation();this.F.log({cancelButtonClick:"1"});jf(this.k)};f.jv=function(a){this.select(void 0,a.ctrlKey)};f.kv=function(a){switch(a.keyCode){case 13:case 32:this.select(),a.preventDefault()}};function Yn(a,b,c){Wm.call(this,a,b);this.o="videowall-endscreen";this.B=c;this.F=[];this.a=this.j=null;this.A=!1;this.k=0;this.Eb.D("onResize",this.Uu,this);this.Eb.D("videodatachange",this.Vu,this)}y(Yn,Wm);f=Yn.prototype;f.create=function(){Yn.C.create.call(this);this.a=this.b.getVideoData().mc;Zn(this)};f.destroy=function(){this.g&&(this.g.innerHTML="");this.a=[];Yn.C.destroy.call(this)};
-f.load=function(){Yn.C.load.call(this);if(this.a&&this.a.length&&this.a[0].endscreen_autoplay){var a=$n(this,0);a.b=new zn;V(a.b.element,"autoplay-play-canvas");a.b.W(a.a);a.b.show();X(a.a,"videowall-still-autoplay",!0);var b=E("videowall-still-listlabel-autoplay",a.a),c=new un(a.o);c.W(b);wn(c,"videowall-still-listlabel-autoplay-cancel");c.Aa(a.o.getMsg("YTP_BUTTON_CANCEL"));c.show();J(c,"click",v(a.ku,a));a.F.log({cancelButtonShow:"1"});a.A=new Date;a.k=hf(v(a.ju,a),50)}};
-function Zn(a){if(a.vc&&a.a&&a.a.length){X(a.i,"endscreen-enable-layout",!0);a.g.innerHTML="";var b=Cd(a.i);Dm(Q(a.b),"ad-showing")&&(b.height-=200);b.height-=30;var c=Math.floor(b.width/158),d=Math.floor(b.height/(158/1.45));if(1>d||1>c)a.k=0;else{var e=a.a.length,g=!1,h="episodic"==a.a[0].feature_type,k=a.a[0].endscreen_autoplay;(a.a[0].featured||h||k)&&2<d&&2<c&&(g=!0,e+=3);X(a.g,"feature-video",g);for(var k=h=0,m=Bb(b),p=!0;0<=e&&(h<c||k<d);){var r=e>=k,s=e>=h;if(p&&s||!r&&s)e-=h,k++;else if(r)e-=
-k,h++;else break;p=1.45*(h/k)>m}a.A=p;c=new B(h,k);a.A?(d=1/c.width,b=b.width*d,d=b/1.45):(d=1/c.height,d*=b.height,b=1.45*d);b=new B(Math.floor(b),Math.floor(d));a.k=c.width*c.height;g&&(a.k-=3);a.j&&ln(a.j);g=ao(b);d={Ib:a.j};a.j=kn(".videowall-still",g,d);g=ao(b.clone().scale(2));d.Ib=a.j;kn(".feature-video .videowall-still:first-child",g,d);Ad(a.g,b.width*c.width,b.height*c.height)}g=0;for(b=a.k;g<b;g++)c=$n(a,g),a.g.appendChild(c.N());X(a.i,"endscreen-enable-layout",!1)}}
-function $n(a,b){var c=a.F[b];c||(c=new Wn(a.b,a.B),a.F[b]=c);c.update(a.a[b],0==b&&a.a[0].featured);return c}function ao(a){return["width:"+a.width+"px","height:"+a.height+"px"]}f.Uu=function(){Zn(this)};f.Vu=function(){var a=this.b.getVideoData().mc;this.a!=a&&(this.a=a,Zn(this))};function bo(a){Im.call(this,a);a.K().kl?this.Mf=new jn(this.a,this.F):a.K().xc?this.Mf=new Yn(this.a,this.F,this):this.Mf=new Wm(this.a,this.F)}y(bo,Im);f=bo.prototype;f.qa="endscreen";f.ad="end";f.Mf=null;function co(a){var b=a.K(),c=a.getVideoData();a=1==N(a.app).B;return eo(b)&&!qm(c,"ypc_module")&&a}f.$a=function(a){return co(a)};
-f.create=function(){bo.C.create.call(this);var a=Math.max(1E3*(this.a.getVideoData().ra-10),0),a=new $h(a,2147483647,{id:"preload"}),b=new $h(2147483647,2147483647,{id:"load",priority:6});this.uf(a,b)};f.destroy=function(){Jm(this);this.Mf.destroy();bo.C.destroy.call(this)};f.load=function(){bo.C.load.call(this);this.Mf.load();this.ba=!0};f.unload=function(){bo.C.unload.call(this);this.ba=!1};f.yc=function(a){bo.C.yc.call(this,a);"preload"==a.getId()?this.Mf.create():fo(this.a.app)||this.load()};
-f.Vc=function(a){"load"==a.getId()&&this.unload();bo.C.Vc.call(this,a)};function go(a){return co(a)?new bo(a):null};var ho={created:1,ready:2,testing:4,"testing-starting":3,live:6,"live-starting":5,complete:8,"complete-starting":7};/*
- Portions of this code are from MochiKit, received by
- The Closure Authors under the MIT license. All other code is Copyright
- 2005-2009 The Closure Authors. All Rights Reserved.
-*/
-function io(a,b){this.o=[];this.L=a;this.J=b||null;this.k=this.g=!1;this.j=void 0;this.G=this.ev=this.A=!1;this.F=0;this.i=null;this.B=0}io.prototype.cancel=function(a){if(this.g)this.j instanceof io&&this.j.cancel();else{if(this.i){var b=this.i;delete this.i;a?b.cancel(a):(b.B--,0>=b.B&&b.cancel())}this.L?this.L.call(this.J,this):this.G=!0;this.g||this.a(new jo)}};io.prototype.I=function(a,b){this.A=!1;ko(this,a,b)};function ko(a,b,c){a.g=!0;a.j=c;a.k=!b;lo(a)}
-function mo(a){if(a.g){if(!a.G)throw new no;a.G=!1}}io.prototype.b=function(a){mo(this);ko(this,!0,a)};io.prototype.a=function(a){mo(this);ko(this,!1,a)};function oo(a,b,c,d){a.o.push([b,c,d]);a.g&&lo(a);return a}function po(a){var b=new io;oo(a,b.b,b.a,b);return b}function qo(a){return Ma(a.o,function(a){return ha(a[1])})}
-function lo(a){a.F&&a.g&&qo(a)&&(l.clearTimeout(a.F),delete a.F);a.i&&(a.i.B--,delete a.i);for(var b=a.j,c=!1,d=!1;a.o.length&&!a.A;){var e=a.o.shift(),g=e[0],h=e[1],e=e[2];if(g=a.k?h:g)try{var k=g.call(e||a.J,b);q(k)&&(a.k=a.k&&(k==b||k instanceof Error),a.j=b=k);b instanceof io&&(d=!0,a.A=!0)}catch(m){b=m,a.k=!0,qo(a)||(c=!0)}}a.j=b;d&&(oo(b,v(a.I,a,!0),v(a.I,a,!1)),b.ev=!0);c&&(a.F=l.setTimeout(Tb(b),0))}function no(){ua.call(this)}y(no,ua);no.prototype.message="Deferred has already fired";
-no.prototype.name="AlreadyCalledError";function jo(){ua.call(this)}y(jo,ua);jo.prototype.message="Deferred was canceled";jo.prototype.name="CanceledError";function ro(a,b){var c=b||{},d=c.document||document,e=Xc("SCRIPT"),g={Io:e,uc:void 0},h=new io(so,g),k=null,m=null!=c.timeout?c.timeout:5E3;0<m&&(k=window.setTimeout(function(){to(e,!0);h.a(new uo(1,"Timeout reached for loading script "+a))},m),g.uc=k);e.onload=e.onreadystatechange=function(){e.readyState&&"loaded"!=e.readyState&&"complete"!=e.readyState||(to(e,c.cv||!1,k),h.b(null))};e.onerror=function(){to(e,!0,k);h.a(new uo(0,"Error while loading script "+a))};Pc(e,{type:"text/javascript",charset:"UTF-8",
-src:a});vo(d).appendChild(e);return h}function vo(a){var b=a.getElementsByTagName("HEAD");return!b||Ua(b)?a.documentElement:b[0]}function so(){if(this&&this.Io){var a=this.Io;a&&"SCRIPT"==a.tagName&&to(a,!0,this.uc)}}function to(a,b,c){null!=c&&l.clearTimeout(c);a.onload=ba;a.onerror=ba;a.onreadystatechange=ba;b&&window.setTimeout(function(){F(a)},0)}function uo(a,b){var c="Jsloader error (code #"+a+")";b&&(c+=": "+b);ua.call(this,c);this.code=a}y(uo,ua);function wo(a,b){this.b=new re(a);this.a=b?b:"callback";this.uc=5E3}var xo=0;wo.prototype.send=function(a,b,c,d){a=a||null;d=d||"_"+(xo++).toString(36)+x().toString(36);l._callbacks_||(l._callbacks_={});var e=this.b.clone();if(a)for(var g in a)a.hasOwnProperty&&!a.hasOwnProperty(g)||Ge(e,g,a[g]);b&&(l._callbacks_[d]=yo(d,b),Ge(e,this.a,"_callbacks_."+d));b=ro(e.toString(),{timeout:this.uc,cv:!0});oo(b,null,zo(d,a,c),void 0);return{Ba:d,jc:b}};
-wo.prototype.cancel=function(a){a&&(a.jc&&a.jc.cancel(),a.Ba&&Ao(a.Ba,!1))};function zo(a,b,c){return function(){Ao(a,!1);c&&c(b)}}function yo(a,b){return function(c){Ao(a,!0);b.apply(void 0,arguments)}}function Ao(a,b){l._callbacks_[a]&&(b?delete l._callbacks_[a]:l._callbacks_[a]=ba)};function Bo(a){R.call(this);this.g=Vn(new Rn("//gdata.youtube.com/feeds/api/users/live/broadcasts/__video_id__/states?v=2&alt=json-in-script"),{video_id:a});this.a=new Fi(15E3+Math.floor(3E4*Math.random()));si(this.a,"tick",v(this.b,this));this.b();this.a.start()}y(Bo,R);Bo.prototype.H=function(){this.a.dispose();Bo.C.H.call(this)};Bo.prototype.b=function(){(new wo(this.g)).send(null,v(this.j,this),v(this.i,this))};Bo.prototype.j=function(a){this.u("payload",a);Gi(this.a,15E3+Math.floor(3E4*Math.random()))};
-Bo.prototype.i=function(){this.u("error");var a=this.a.a;192E4>a&&Gi(this.a,2*a)};function Co(){this.g=new Xm(["div","html5-fresca-module",["div","html5-fresca-band-slate",["hgroup","html5-fresca-message",["h2","html5-fresca-heading","{{heading}}"],["h3","html5-fresca-subheading","{{subheading}}"],["h4","html5-fresca-long-test","{{long_text}}"]],["span","html5-fresca-countdown","{{countdown}}"]]]);L(this,this.g);this.b=this.g.a["html5-fresca-module"];V(this.b,"html5-stop-propagation");this.i=0;this.a=null}y(Co,K);Co.prototype.N=function(){return this.b};
-Co.prototype.update=function(a){if(!this.k||this.a.state!=a.state||this.a.startTime!=a.startTime||this.a.b!=a.b||this.a.a.join()!=a.a.join()){this.a=a;this.b.style.backgroundImage=this.a.b||"none";a=this.a.a;if(!a.length){t:switch(this.a.state){case 6:a="";break t;case 8:case 7:a=mf("FRESCA_COMPLETE_MESSAGE");break t;default:a=mf("FRESCA_STAND_BY_MESSAGE")}a=[a]}this.g.update({heading:a[0]||"",subheading:a[1]||"",long_text:a[2]||""});this.j()}};
-function Do(a){var b=Math.floor((new Date).valueOf()/1E3);return b>a?mf("FRESCA_STARTING_SOON_MESSAGE"):Dn(a-b)}Co.prototype.j=function(){var a;a=this.a;a.startTime?(a=a.state,a=6==a||8==a||7==a?!1:!0):a=!1;X(this.b,"html5-fresca-show-countdown",a);a&&(this.g.update({countdown:Do(this.a.startTime)}),I(this.i),this.i=H(v(this.j,this),1E3))};Co.prototype.H=function(){I(this.i);this.b=null;Co.C.H.call(this)};function Eo(a){this.a=[];a&&Fo(this,a)}Eo.prototype.state=-1;function Fo(a,b){var c=b.feed;if(c){var d=c.yt$lifeCycleState;d&&(a.state=ho[d.$t]||-1);(d=c.yt$when)&&d.start&&(d=new Date(d.start),a.startTime=Math.floor(d.valueOf()/1E3));if(c=c.yt$slate)c.imgUrl&&(a.b="url("+c.imgUrl+")"),(c=c.content)&&c.length&&(c=c.splice(0,3),a.a=La(c,function(a){return a.$t}))}};function Go(a){Im.call(this,a)}y(Go,Im);f=Go.prototype;f.qa="fresca";f.ad="fresca";f.Zh=!1;f.Kg=!1;f.$a=function(){return qm(this.a.getVideoData(),"fresca_module")};f.create=function(a){Go.C.create.call(this);this.Zh=this.Kg=!1;Sm(this,["play_pause","seek"]);this.i=new Co;this.a.app.R.g.appendChild(this.i.N());this.g=a||new Bo(this.a.getVideoData().M);this.g.D("payload",this.Lu,this);this.g.D("error",this.Ku,this);this.D("onStateChange",this.ko,this)};
-f.destroy=function(){this.ba&&this.unload();this.$("onStateChange",this.ko,this);Ug(this.g,this.i);Go.C.destroy.call(this)};f.load=function(){Go.C.load.call(this);this.ba=!0};f.unload=function(){this.ba=!1;Go.C.unload.call(this)};f.ko=function(a){this.b&&(this.Zh=P(a.state,2),(Ho(a,16)||this.Zh)&&Io(this,this.b))};f.Ku=function(){this.Kg||(this.b=new Eo,Io(this,this.b))};f.Lu=function(a){this.b=new Eo(a);a=this.a.getVideoData();6!=this.b.state||a.va||a.B?Io(this,this.b):this.a.Lj(a.M)};
-function Io(a,b){var c=6>b.state;!c&&a.a.app.b.ga&&(b.b||b.a.length)&&(c=!0);a.Zh&&!a.a.K().xc&&(c=!0);if(!a.Kg)switch(b.state){case 6:a.Kg=!0;Sm(a,["play_pause","seek"]);Km(a);break;case 8:case 7:c=a.Kg=!0}c&&a.i.update(b);c&&!a.ba?a.load():!c&&a.ba&&a.unload()}function Jo(a){return qm(a.getVideoData(),"fresca_module")?new Go(a):null};function Ko(a){this.Ig=a||window;this.ae=[]}f=Ko.prototype;f.Ig=null;f.ae=null;f.listen=function(a,b,c,d){c=v(c,d||this.Ig);a=J(a,b,c);this.ae.push(a);return a};function Lo(a,b,c,d){d=v(d,a.Ig);b=zf(b,c,d);a.ae.push(b);return b}function Mo(a,b,c){c=v(c,a.Ig);b=Cf(b,c,"yt-uix-button-menu-item");a.ae.push(b)}f.ac=function(a){yf(a);Xa(this.ae,a)};f.removeAll=function(){yf(this.ae);this.ae=[]};function No(a,b,c,d,e){this.b=a;this.a=b;this.ia=c;this.He=d;this.g=e};function Oo(a,b,c){this.a=a;this.i=b||0;this.b=c;this.g=v(this.Vt,this)}y(Oo,K);f=Oo.prototype;f.Ba=0;f.H=function(){Oo.C.H.call(this);this.stop();delete this.a;delete this.b};f.start=function(a){this.stop();this.Ba=Hi(this.g,q(a)?a:this.i)};f.stop=function(){0!=this.Ba&&l.clearTimeout(this.Ba);this.Ba=0};f.Vt=function(){this.Ba=0;this.a&&this.a.call(this.b)};var Po={},Qo=null;function Ro(a){a=ja(a);delete Po[a];Nb(Po)&&Qo&&Qo.stop()}function So(){Qo||(Qo=new Oo(function(){To()},20));var a=Qo;0!=a.Ba||a.start()}function To(){var a=x();Hb(Po,function(b){Uo(b,a)});Nb(Po)||So()};function Vo(){Ci.call(this);this.a=0;this.k=this.startTime=null}y(Vo,Ci);f=Vo.prototype;f.kk=function(){this.Ed("begin")};f.Gi=function(){this.Ed("end")};f.pd=function(){this.Ed("finish")};f.onStop=function(){this.Ed("stop")};f.Ed=function(a){Di(this,a)};function Wo(a,b,c,d){Vo.call(this);if(!t(a)||!t(b))throw Error("Start and end parameters must be arrays");if(a.length!=b.length)throw Error("Start and end points must be the same length");this.g=a;this.o=b;this.duration=c;this.j=d;this.b=[]}y(Wo,Vo);f=Wo.prototype;f.Yc=0;
-function Xo(a){if(0==a.a)a.Yc=0,a.b=a.g;else if(1==a.a)return;Ro(a);var b=x();a.startTime=b;-1==a.a&&(a.startTime-=a.duration*a.Yc);a.k=a.startTime+a.duration;a.Yc||a.kk();a.Ed("play");-1==a.a&&a.Ed("resume");a.a=1;var c=ja(a);c in Po||(Po[c]=a);So();Uo(a,b)}f.stop=function(a){Ro(this);this.a=0;a&&(this.Yc=1);Yo(this,this.Yc);this.onStop();this.Gi()};f.H=function(){0==this.a||this.stop(!1);this.Ed("destroy");Wo.C.H.call(this)};f.destroy=function(){this.dispose()};
-function Uo(a,b){a.Yc=(b-a.startTime)/(a.k-a.startTime);1<=a.Yc&&(a.Yc=1);Yo(a,a.Yc);1==a.Yc?(a.a=0,Ro(a),a.pd(),a.Gi()):1==a.a&&a.al()}function Yo(a,b){ha(a.j)&&(b=a.j(b));a.b=Array(a.g.length);for(var c=0;c<a.g.length;c++)a.b[c]=(a.o[c]-a.g[c])*b+a.g[c]}f.al=function(){this.Ed("animate")};f.Ed=function(a){Di(this,new Zo(a,this))};function Zo(a,b){ei.call(this,a);this.x=b.b[0];this.y=b.b[1];this.duration=b.duration;this.state=b.a}y(Zo,ei);var $o=/#(.)(.)(.)/;function ap(a){if(!bp.test(a))throw Error("'"+a+"' is not a valid hex color");4==a.length&&(a=a.replace($o,"#$1$1$2$2$3$3"));a=a.toLowerCase();return[parseInt(a.substr(1,2),16),parseInt(a.substr(3,2),16),parseInt(a.substr(5,2),16)]}var bp=/^#(?:[0-9a-f]{3}){1,2}$/i;function cp(a,b,c,d,e){Wo.call(this,b,c,d,e);this.element=a}y(cp,Wo);cp.prototype.i=ba;cp.prototype.al=function(){this.i();cp.C.al.call(this)};cp.prototype.Gi=function(){this.i();cp.C.Gi.call(this)};cp.prototype.kk=function(){this.i();cp.C.kk.call(this)};function dp(a,b,c,d,e){if(2!=b.length||2!=c.length)throw Error("Start and end points must be 2D");cp.apply(this,arguments)}y(dp,cp);
-dp.prototype.i=function(){this.element.style.left=Math.round(this.b[0])+"px";this.element.style.top=Math.round(this.b[1])+"px"};function ep(a){return a*a*a}function fp(a){return 1-Math.pow(1-a,3)};var gp=n("yt.prefs.UserPrefs.prefs_")||{};pa("yt.prefs.UserPrefs.prefs_",gp);function hp(a){var b=null;"transition"in a.style?b="transition-duration":"webkitTransition"in a.style?b="-webkit-transition-duration":"MozTransition"in a.style?b="-moz-transition-duration":"OTransition"in a.style?b="-o-transition-duration":"msTransition"in a.style&&(b="-ms-transition-duration");a=b?(document.defaultView?document.defaultView.getComputedStyle(a,null):document.parentWindow.getComputedStyle(a,null)).getPropertyValue(b):"0";return 1E3*parseFloat(a)};var ip=n("yt.pubsub.instance_")||new Xh;Xh.prototype.subscribe=Xh.prototype.D;Xh.prototype.unsubscribeByKey=Xh.prototype.Rc;Xh.prototype.publish=Xh.prototype.u;Xh.prototype.clear=Xh.prototype.clear;pa("yt.pubsub.instance_",ip);function jp(a,b,c){var d=kp();return d?d.subscribe(a,function(){var d=arguments;try{lp&&mp[a]?b.apply(c||l,d):H(function(){b.apply(c||l,d)},0)}catch(g){kf(g)}},c):0}
-function np(){var a=df("LOGGED_IN_PUBSUB_KEY"),b=kp();b&&("number"==typeof a?a=[a]:"string"==typeof a&&(a=[parseInt(a,10)]),z(a,function(a){b.unsubscribeByKey(a)}))}function op(a,b){var c=kp();return c?c.publish.apply(c,arguments):!1}function kp(){return n("yt.pubsub.instance_")}var lp=!!df("SYNCHRONOUS_PUBSUB"),mp={};function pp(a,b,c,d,e,g){var h,k;if(h=c.offsetParent){var m="HTML"==h.tagName||"BODY"==h.tagName;m&&"static"==od(h,"position")||(k=ud(h),m||(m=(m=vd(h))&&fc?-h.scrollLeft:!m||C&&uc("8")||"visible"==od(h,"overflowX")?h.scrollLeft:h.scrollWidth-h.clientWidth-h.scrollLeft,k=yb(k,new A(m,h.scrollTop))))}h=k||new A;k=Ed(a);if(m=td(a)){var p=Eb(m),m=Math.max(k.left,p.left),r=Math.min(k.left+k.width,p.left+p.width);if(m<=r){var s=Math.max(k.top,p.top),p=Math.min(k.top+k.height,p.top+p.height);s<=p&&(k.left=
-m,k.top=s,k.width=r-m,k.height=p-s)}}m=Jc(a);s=Jc(c);if(m.a!=s.a){var r=m.a.body,s=s.a.parentWindow||s.a.defaultView,p=new A(0,0),D=Lc(r)?Lc(r).parentWindow||Lc(r).defaultView:window,O=r;do{var ta=D==s?ud(O):yd(O);p.x+=ta.x;p.y+=ta.y}while(D&&D!=s&&(O=D.frameElement)&&(D=D.parent));r=yb(p,ud(r));C&&!ld(m)&&(r=yb(r,md(m)));k.left+=r.x;k.top+=r.y}a=(b&4&&vd(a)?b^2:b)&-5;b=new A(a&2?k.left+k.width:k.left,a&1?k.top+k.height:k.top);b=yb(b,h);e&&(b.x+=(a&2?-1:1)*e.x,b.y+=(a&1?-1:1)*e.y);if(e=td(c))e.top-=
-h.y,e.right-=h.x,e.bottom-=h.y,e.left-=h.x;qp(b,c,d,g,e,65,void 0)}
-function qp(a,b,c,d,e,g,h){a=a.clone();var k=(c&4&&vd(b)?c^2:c)&-5;c=Cd(b);h=h?h.clone():c.clone();if(d||0!=k)k&2?a.x-=h.width+(d?d.right:0):d&&(a.x+=d.left),k&1?a.y-=h.height+(d?d.bottom:0):d&&(a.y+=d.top);if(g&&(e?(d=a,k=0,65==(g&65)&&(d.x<e.left||d.x>=e.right)&&(g&=-2),132==(g&132)&&(d.y<e.top||d.y>=e.bottom)&&(g&=-5),d.x<e.left&&g&1&&(d.x=e.left,k|=1),d.x<e.left&&d.x+h.width>e.right&&g&16&&(h.width=Math.max(h.width-(d.x+h.width-e.right),0),k|=4),d.x+h.width>e.right&&g&1&&(d.x=Math.max(e.right-
-h.width,e.left),k|=1),g&2&&(k=k|(d.x<e.left?16:0)|(d.x+h.width>e.right?32:0)),d.y<e.top&&g&4&&(d.y=e.top,k|=2),d.y<=e.top&&d.y+h.height<e.bottom&&g&32&&(h.height=Math.max(h.height-(e.top-d.y),0),d.y=e.top,k|=8),d.y>=e.top&&d.y+h.height>e.bottom&&g&32&&(h.height=Math.max(h.height-(d.y+h.height-e.bottom),0),k|=8),d.y+h.height>e.bottom&&g&4&&(d.y=Math.max(e.bottom-h.height,e.top),k|=2),g&8&&(k=k|(d.y<e.top?64:0)|(d.y+h.height>e.bottom?128:0)),e=k):e=256,e&496))return;pd(b,a);Ab(c,h)||(e=ld(Jc(Lc(b))),
-!C||e&&uc("8")?(b=b.style,fc?b.MozBoxSizing="border-box":gc?b.WebkitBoxSizing="border-box":b.boxSizing="border-box",b.width=Math.max(h.width,0)+"px",b.height=Math.max(h.height,0)+"px"):(a=b.style,e?(e=Id(b),b=Jd(b),a.pixelWidth=h.width-b.left-e.left-e.right-b.right,a.pixelHeight=h.height-b.top-e.top-e.bottom-b.bottom):(a.pixelWidth=h.width,a.pixelHeight=h.height)))};var rp={},sp="ontouchstart"in document;function tp(a,b,c){var d;switch(a){case "mouseover":case "mouseout":d=3;break;case "mouseenter":case "mouseleave":d=9}return kd(c,function(a){return Gc(a,b)},!0,d)}
-function up(a){var b="mouseover"==a.type&&"mouseenter"in rp||"mouseout"==a.type&&"mouseleave"in rp,c=a.type in rp||b;if("HTML"!=a.target.tagName&&c){if(b){var b="mouseover"==a.type?"mouseenter":"mouseleave",c=rp[b],d;for(d in c.Sb){var e=tp(b,d,a.target);e&&!kd(a.relatedTarget,function(a){return a==e},!0)&&c.u(d,e,b,a)}}if(b=rp[a.type])for(d in b.Sb)(e=tp(a.type,d,a.target))&&b.u(d,e,a.type,a)}}J(document,"blur",up,!0);J(document,"change",up,!0);J(document,"click",up);J(document,"focus",up,!0);
-J(document,"mouseover",up);J(document,"mouseout",up);J(document,"mousedown",up);J(document,"keydown",up);J(document,"keyup",up);J(document,"keypress",up);J(document,"cut",up);J(document,"paste",up);sp&&(J(document,"touchstart",up),J(document,"touchend",up),J(document,"touchcancel",up));var vp=window.yt&&window.yt.uix&&window.yt.uix.widgets_||{};pa("yt.uix.widgets_",vp);function wp(a){a=a.getInstance();var b=Z(a);b in vp||!a.$p()||(a.register(),vp[b]=a)};function xp(){this.a={}}xp.prototype.g=!!eval("/*@cc_on!@*/false");xp.prototype.$p=function(){return!0};function yp(a,b,c){var d=Z(a,void 0),e=v(c,a);b in rp||(rp[b]=new Xh);rp[b].D(d,e);a.a[c]=e}xp.prototype.b=function(a,b,c){var d=G(a,b);if(d&&(d=n(d))){var e=db(arguments,2);cb(e,0,0,a);d.apply(null,e)}};function zp(a,b){Pe(a,"tooltip-text",b)}xp.prototype.removeData=function(a,b){a.dataset?delete a.dataset[Qe(b)]:a.removeAttribute("data-"+b)};
-function Z(a,b){return"yt-uix"+(a.Wi?"-"+a.Wi:"")+(b?"-"+b:"")};function Ap(){this.a={}}y(Ap,xp);ca(Ap);f=Ap.prototype;f.Wi="button";f.Bf=null;f.register=function(){yp(this,"click",this.Sx);yp(this,"keydown",this.Qx);yp(this,"keypress",this.Rx)};f.Sx=function(a){a&&!a.disabled&&(Bp(this,a),this.click(a))};
-f.Qx=function(a,b,c){if(!(c.altKey||c.ctrlKey||c.shiftKey)&&(b=Cp(this,a))){var d=function(a){var b="";a.tagName&&(b=a.tagName.toLowerCase());return"ul"==b||"table"==b};if(d=d(b)?b:ed(b,d)){var d=d.tagName.toLowerCase(),e;"ul"==d?e=this.Wx:"table"==d&&(e=this.Vx);e&&Dp(this,a,b,c,v(e,this))}}};
-function Dp(a,b,c,d,e){var g=Gn(c),h=9==d.keyCode;h||32==d.keyCode||13==d.keyCode?(d=Ep(a,c))?(b=ad(d),"a"==b.tagName.toLowerCase()?window.location=b.href:Ef(b,"click")):h&&Fp(a,b):g?27==d.keyCode?(Ep(a,c),Fp(a,b)):e(b,c,d):(a=Gc(b,Z(a,"reverse"))?38:40,d.keyCode==a&&(Ef(b,"click"),d.preventDefault()))}f.Rx=function(a,b,c){c.altKey||c.ctrlKey||c.shiftKey||(a=Cp(this,a),Gn(a)&&c.preventDefault())};function Ep(a,b){var c=Z(a,"menu-item-highlight"),d=E(c,b);d&&Ec(d,c);return d}
-function Gp(a,b,c){Dc(c,Z(a,"menu-item-highlight"));b.setAttribute("aria-activedescendant",c.getAttribute("id"))}f.Vx=function(a,b,c){var d=Ep(this,b);b=Ve("table",b);var e=Ve("tr",b),e=Oc("td",null,e).length;b=Oc("td",null,b);d=Hp(d,b,e,c);-1!=d&&(Gp(this,a,b[d]),c.preventDefault())};f.Wx=function(a,b,c){if(40==c.keyCode||38==c.keyCode){var d=Ep(this,b);b=Oc("li",null,b);d=Hp(d,b,1,c);Gp(this,a,b[d]);c.preventDefault()}};
-function Hp(a,b,c,d){var e=b.length;a=Ja(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}function Ip(a,b){var c=b.iframeMask;c||(c=document.createElement("iframe"),c.src='javascript:""',c.className=Z(a,"menu-mask"),b.iframeMask=c);return c}
-function Jp(a,b,c,d){var e=jd(b,Z(a,"group")),g=!!G(b,"button-menu-ignore-group"),e=e&&!g?e:b,g=5,h=4,k=Ed(b);if(Gc(b,Z(a,"reverse"))){g=4;h=5;k=k.top+"px";try{c.style.maxHeight=k}catch(m){}}Gc(b,"flip")&&(Gc(b,Z(a,"reverse"))?(g=6,h=7):(g=7,h=6));var p;G(b,"button-has-sibling-menu")?p=sd(e):G(b,"button-menu-root-container")&&(p=Kp(b));C&&!uc("8")&&(p=null);var r;p&&(r=Ed(p),r=new zb(-r.top,r.left,r.top,-r.left));p=new A(0,1);Gc(b,Z(a,"center-menu"))&&(p.x-=Math.round((Cd(c).width-Cd(b).width)/2));
-d&&(p.y+=Sc(document).y);if(a=Ip(a,b))b=Cd(c),a.style.width=b.width+"px",a.style.height=b.height+"px",pp(e,g,a,h,p,r),d&&Kn(a,"position","fixed");pp(e,g,c,h,p,r)}function Kp(a){if(G(a,"button-menu-root-container")){var b=G(a,"button-menu-root-container");return jd(a,b)}return document.body}
-f.bp=function(a){if(a){var b=Cp(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);var c;c=G(a,"button-has-sibling-menu")?a.parentNode:Kp(a);c.appendChild(b);b.style.minWidth=a.offsetWidth-2+"px";var d=Ip(this,a);d&&c.appendChild(d);c=!!G(a,"button-menu-fixed");Jp(this,a,b,c);Hn(b);this.b(a,"button-menu-action",!0);Dc(a,Z(this,"active"));b=v(this.ap,this,a,!1);c=v(this.ap,this,
-a,!0);c=J(document,"click",c);b=J(document,"contextmenu",b);Pe(a,"button-listener",c);Pe(a,"button-context-menu-listener",b);this.Bf=a}}};
-function Fp(a,b){if(b){var c=Cp(a,b);if(c){a.Bf=null;b.setAttribute("aria-pressed","false");b.setAttribute("aria-expanded","false");b.removeAttribute("aria-activedescendant");In(c);a.b(b,"button-menu-action",!1);var d=Ip(a,b);H(function(){d&&d.parentNode&&d.parentNode.removeChild(d);c.originalParentNode&&(c.parentNode.removeChild(c),c.originalParentNode.appendChild(c),c.originalParentNode=null,c.activeButtonNode=null)},1)}var e=jd(b,Z(a,"group"));Ec(b,Z(a,"active"));e&&Ec(e,Z(a,"group-active"));if(e=
-G(b,"button-listener"))yf(e),a.removeData(b,"button-listener");if(e=G(b,"button-context-menu-listener"))yf(e),a.removeData(b,"button-context-menu-listener")}}function Lp(a,b){var c=Cp(a,b);c&&Jp(a,b,c)}function Mp(a,b){return Cp(a,b)}
-f.ap=function(a,b,c){c=c||window.event;c=c.target||c.srcElement;3==c.nodeType&&(c=c.parentNode);var d=jd(c,Z(this));if(d){var d=Cp(this,d),e=Cp(this,a);if(d==e)return}if(!jd(c,Z(this,"menu"))||Gc(c,Z(this,"menu-item"))||Gc(c,Z(this,"menu-close")))if(Fp(this,a),(d=jd(c,Z(this,"menu")))&&b&&G(a,"button-menu-indicate-selected")){if(a=E(Z(this,"content"),a))Ac&&"innerText"in c?b=c.innerText.replace(/(\r\n|\r|\n)/g,"\n"):(b=[],id(c,b,!0),b=b.join("")),b=b.replace(/ \xAD /g," ").replace(/\xAD/g,""),b=b.replace(/\u200B/g,
-""),Ac||(b=b.replace(/ +/g," "))," "!=b&&(b=b.replace(/^\s*/,"")),dd(a,b);a=Z(this,"menu-item-selected");(b=E(a,d))&&Ec(b,a);Dc(c.parentNode,a)}};function Cp(a,b){if(!b.widgetMenu){var c=G(b,"button-menu-id"),c=c&&Mc(c),d=Z(a,"menu");c?(Dc(c,d),Dc(c,Z(a,"menu-external"))):c=E(d,b);b.widgetMenu=c}return b.widgetMenu}
-function Bp(a,b){if(G(b,"button-toggle")){var c=jd(b,Z(a,"group"));if(c&&G(c,"button-toggle-group")){var d=G(c,"button-toggle-group"),c=Nc(Z(a),c),e=Z(a,"toggled"),g=Gc(b,e);z(c,function(a){a!=b||"optional"==d&&g?Ec(a,e):Dc(b,e)})}else Ic(b,Z(a,"toggled"))}}f.click=function(a){if(Cp(this,a)){var b=Cp(this,a),c=jd(b.activeButtonNode||b.parentNode,Z(this));c&&c!=a?(Fp(this,c),H(v(this.bp,this,a),1)):Gn(b)?Fp(this,a):this.bp(a);a.focus()}this.b(a,"button-action")};function Np(a,b,c){this.i=a;this.g=b;this.b=c;this.a=v(this.Wt,this)}y(Np,K);f=Np.prototype;f.Ui=!1;f.Df=null;function Op(a){a.Df?a.Ui=!0:Pp(a)}f.stop=function(){this.Df&&(l.clearTimeout(this.Df),this.Df=null,this.Ui=!1)};f.H=function(){Np.C.H.call(this);this.stop()};f.Wt=function(){this.Df=null;this.Ui&&(this.Ui=!1,Pp(this))};function Pp(a){a.Df=Hi(a.a,a.g);a.i.call(a.b)};function Qp(a,b,c){b||(b={});var d=c||window;c="undefined"!=typeof a.href?a.href:String(a);a=b.target||a.target;var e=[],g;for(g in b)switch(g){case "width":case "height":case "top":case "left":e.push(g+"="+b[g]);break;case "target":case "noreferrer":break;default:e.push(g+"="+(b[g]?1:0))}g=e.join(",");if(b.noreferrer){if(b=d.open("",a,g))C&&-1!=c.indexOf(";")&&(c="'"+c.replace(/'/g,"%27")+"'"),b.opener=null,c=ya(c),b.document.write('<META HTTP-EQUIV="refresh" content="0; url='+c+'">'),b.document.close()}else b=
-d.open(c,a,g);return b}function Rp(a,b){var c;c=b||{};c.target=c.target||a.target||"YouTube";c.width=c.width||600;c.height=c.height||600;(c=Qp(a,c))?(c.opener||(c.opener=window),c.focus()):c=null;return!c};function Sp(a,b){Tp().tick[a]=b||x()}function Up(a){var b=Tp().tick;return a in b}function Vp(a){var b="https:"==window.location.protocol?"https://gg.google.com/csi":"http://csi.gstatic.com/csi",c="",d;for(d in a)c+="&"+d+"="+a[d];sa(b+"?"+c.substring(1))}function Wp(){return Tp().info}function Tp(){return n("ytcsi.data_")||Xp()}function Xp(){var a={tick:{},span:{},info:{}};pa("ytcsi.data_",a);return a};function Yp(a,b){return null!=b&&!!b.match(a)}function Zp(a,b){for(var c in a)if(a[c]==b)return!0;return!1}function $p(a,b,c,d){var e=new aq;e.type=c;e.defaultValue=d;e.b=oa(Yp,/.+/);return bq(a[b],e)}function cq(a,b,c){var d=new aq;d.type="OPTIONAL";d.a=function(a){if(isNaN(parseInt(a,0)))return null;a=parseInt(a,0).toString(16);return"#"+"000000".substring(0,6-a.length)+a};d.b=function(a){return!!a};d.defaultValue=c;return bq(a[b],d)}
-function dq(a,b,c,d){var e=new aq;e.type=c;e.defaultValue=d;return bq(a[b],e)}function eq(a,b,c,d,e){var g=new aq;g.type=d;g.defaultValue=e;g.b=oa(Zp,c);return bq(a[b],g)}function fq(a,b,c){var d=new aq;d.type="OPTIONAL";d.defaultValue=c;d.b=function(a){return!0==a||!1==a};d.a=function(a){return"true"==a||"false"==a?"true"==a:a};return bq(a[b],d)}function gq(a,b,c){var d=new aq;d.type="OPTIONAL";d.defaultValue=c;d.a=function(a){return parseFloat(a)};return bq(a[b],d)}
-function hq(a){var b=new aq;b.type="OPTIONAL";b.defaultValue=0;b.a=function(a){return parseInt(a,10)};return bq(a.d,b)}function iq(a,b,c,d,e,g,h){var k=new aq;k.type="OPTIONAL";k.a=function(a){a=10==c?parseFloat(a):parseInt(a,c);return g&&null!=a&&!isNaN(a)?wb(a,d,e):a};k.defaultValue=h;k.b=function(a){return null!=a&&!isNaN(a)&&a>=d&&a<=e};return bq(a[b],k)}
-function jq(a,b){var c=new aq;c.type="OPTIONAL";c.defaultValue=0;c.a=function(a){if("never"==a)return-1;a=a.split(":");if(3<a.length)return null;var b=0,c=1;z(a,function(a){a=parseFloat(a);0>a&&(c=-c);b=60*b+Math.abs(a)});return c*b};return bq(a[b],c)}function kq(a,b){return null==b?null:a(b)}function lq(a,b,c,d,e){if(null==a||null==a[b])return null;var g=new aq;g.type=d;g.defaultValue=e;g.b=function(a){return!!a};g.a=oa(kq,c);return bq(a[b],g)}
-function bq(a,b){var c;if("OPTIONAL"==b.type||"REQUIRED"==b.type){if(c=null==a?null:b.a(t(a)&&a.length?a[0]:a),!b.b(c)){if("REQUIRED"==b.type)throw"Required field missing.";c=null==b.defaultValue?null:b.defaultValue}}else c="REPEATED"==b.type?null!=a?mq(t(a)?a:[a],b):null!=b.defaultValue?t(b.defaultValue)?b.defaultValue:[b.defaultValue]:[]:"IDLIST"==b.type?nq(a,b):null;return c}
-function nq(a,b){function c(a){return Ka(a.split(/ +/),function(a){return""!=a})}return null!=a?mq(c(a),b):null!=b.defaultValue?t(b.defaultValue)?b.defaultValue:[b.defaultValue]:[]}function mq(a,b){for(var c=[],d=0;d<a.length;++d){var e=b.a(a[d]);b.b(e)&&c.push(e)}return c.length?c:null!=b.defaultValue?t(b.defaultValue)?b.defaultValue:[b.defaultValue]:[]}function aq(){this.a=oq;this.b=pq}aq.prototype.type="OPTIONAL";aq.prototype.defaultValue=null;function oq(a){return null==a?null:a.toString()}
-function pq(a){return null!=a};function qq(a,b,c,d){this.value=a;this.target=b;this.a=c;this.b=d}var rq={pA:"current",gC:"new"};function sq(a){var b=dq(a,"value","OPTIONAL");if(null==b||null==Gj(b))return null;var c=eq(a,"target",rq,"OPTIONAL","current");if(null==c)return null;fq(a,"trusted",!1);var d=dq(a,"link_class","OPTIONAL","");a=fq(a,"show_link_icon",!0);return new qq(b,c,d,a)}function tq(a){return a.value?a.value:null};function uq(a){if(!a)return!1;a=a.replace(/https?:\/\//g,"");var b=a.split("/",1);if(!b||1>b.length||!b[0])return!1;b=b[0].toLowerCase().split(".").reverse();return 2>b.length?!1:("com"==b[0]&&"youtube"==b[1]||"be"==b[0]&&"youtu"==b[1])&&-1==a.indexOf("/redirect?")}
-function vq(a,b){if("new"==a.target)return-1;var c=tq(a);if(!c)return-1;var c=c.replace(/https?:\/\//g,""),d;(d=!uq(c))||(d=ge(c)||"",d=d.split("/"),d="/"+(1<d.length?d[1]:""),d="/watch"!=d);if(d)return-1;d=Gj(c);if(!d||d.v!=b.M||d.list||d.p)return-1;c=c.split("#",2);if(!c||2>c.length)return-1;(c=Fj(c[1]))&&c.t?(d=c.t,c=0,-1!=d.indexOf("h")&&(d=d.split("h"),c=3600*d[0],d=d[1]),-1!=d.indexOf("m")&&(d=d.split("m"),c=60*d[0]+c,d=d[1]),-1!=d.indexOf("s")?(d=d.split("s"),c=1*d[0]+c):c=1*d+c):c=-1;return c}
-function wq(a,b,c){return(a=tq(a))?uq(a)?Kj(a,{src_vid:c.M,feature:"iv",annotation_id:b.id}):a:null}function xq(a){return a.target?"new"==a.target?"_blank":"_top":uq(tq(a))?"_top":"_blank"};function yq(a,b,c){this.ib=a;this.element=b;this.S=c;this.Gb=this.a=!1;this.ll=!0}function zq(a,b){b.D("onHideControls",function(){this.ll=!1;this.dh()},a);b.D("onShowControls",function(){this.ll=!0;this.dh()},a);b.D("onResize",a.dh,a)}function Aq(a,b){var c=Uc("div","annotation-x-button-container"),d=Uc("div","annotation-x-button");c.appendChild(d);a.S.b.listen(c,"click",v(function(a){var c=this.S.He,d=this.ib;d&&d.i&&c.log_(Bq(c,d,4));b(a);a.stopPropagation();this.Gb=!0},a));return c}f=yq.prototype;
-f.N=function(){return this.element};function Cq(a,b){a.S.b.listen(b,"click",v(function(){var a=Dq(this.ib),b=wq(a,this.ib,this.S.ia),e=v(function(){this.S.g.Qj();window.open(b,xq(a))},this);uq(tq(a))&&"new"!=a.target||(e(),e=null);Eq(this.S.He,this.ib,e)},a))}f.show=function(){};f.hide=function(){};f.destroy=function(){F(this.element)};f.dh=function(){};function Fq(a,b,c){yq.call(this,a,b,c);this.b=Uc("div","invideo-video-text-container");this.g=!1}y(Fq,yq);function Gq(a){var b=new dp(a.element,[a.element.offsetLeft,a.element.offsetTop],[a.element.offsetLeft,a.element.offsetTop-a.element.offsetHeight],300,fp);si(b,"begin",v(function(){this.a=!0},a));Xo(b)}
-function Hq(a){var b=new dp(a.element,[a.element.offsetLeft,a.element.offsetTop],[a.element.offsetLeft,a.element.offsetTop+a.element.offsetHeight+4],300,ep);si(b,"end",v(function(){this.a=!1;In(this.element)},a));Xo(b)}
-function Iq(a){Ad(a.element,444,56);var b=a.ib.data,c={src:b.image_url,"class":"invideo-video-img"},d=Uc("div","invideo-video-img-container"),c=Uc("img",c);Ad(c,100,56);d.appendChild(c);a.element.appendChild(d);Ad(a.b,244,56);d=Uc("span","iv-subtitle-text");dd(d,b.text_line_1);a.b.appendChild(d);d=Uc("span","iv-title-text");dd(d,b.text_line_2);a.b.appendChild(d);a.element.appendChild(a.b);b=Aq(a,v(function(){Hq(this)},a));a.element.appendChild(b);Cq(a,a.element)}
-Fq.prototype.show=function(){if(!this.a){this.g||(Iq(this),this.g=!0);this.dh();Hn(this.element);var a=this.S.He,b=this.ib;b&&b.i&&a.log_(Bq(a,b,2));Gq(this)}};Fq.prototype.hide=function(){this.a&&Hq(this)};Fq.prototype.dh=function(){var a=this.S.a.tf,b=this.S.a.Oc;if(a&&b){var c=Cd(this.element),d=b.height-a.top,b=c.width<b.width&&c.height<b.height,e=this.S.a.pb?35:5,e=this.ll?e:0;pd(this.element,-a.left,this.a&&b?d-c.height-e:d)}};function Jq(a){this.value=a}function Kq(a){a=jq(a,"value");return new Jq(a)};function Lq(){}function Mq(a){var b=dq(a,"external_user_id","OPTIONAL");a=dq(a,"subscription_token","OPTIONAL");return b&&a?new Lq:null};function Nq(a,b,c,d){this.type=a;this.trigger=b;this.url=c;this.duration=d}var Oq={Zx:"close",YB:"log",kC:"openUrl",PAUSE:"pause",cy:"subscribe"},Pq={CLICK:"click",Zx:"close",$x:"hidden",yC:"rollOut",ay:"rollOver",by:"shown"};function Qq(a){var b=eq(a,"type",Oq,"OPTIONAL"),c=eq(a,"trigger",Pq,"OPTIONAL"),d=lq(a,"url",sq,"OPTIONAL");lq(a,"subscribeData",Mq,"OPTIONAL");a=lq(a,"duration",Kq,"OPTIONAL");return b?new Nq(b,c,d,a):null};function Rq(a,b,c,d,e,g,h,k,m,p,r,s,D,O){this.k=a;this.j=b;this.o=c;this.F=d;this.a=e;this.B=g;this.i=h;this.textAlign=k;this.G=m;this.A=p;this.padding=r;this.b=s;this.g=D;this.I=O}
-function Sq(a){var b=cq(a,"fgColor","#1A1A1A"),c=cq(a,"bgColor","#FFF"),d=cq(a,"borderColor","#000"),e=iq(a,"borderWidth",10,0,5,!1,0),g=iq(a,"bgAlpha",10,0,1,!1,0.8);iq(a,"borderAlpha",10,0,1,!1,0.2);iq(a,"gloss",16,0,255,!1,0);var h=cq(a,"highlightFontColor","#F2F2F2"),k=iq(a,"highlightWidth",10,0,5,!1,3),m=dq(a,"textAlign","OPTIONAL",""),p=iq(a,"textSize",10,3.3,30.1,!0,3.6107),r=dq(a,"fontWeight","OPTIONAL",""),s;s=(s=a?a.padding&&a.padding.length?a.padding[0]:a.padding:null)?new zb(parseFloat(s.top),
-parseFloat(s.right),parseFloat(s.bottom),parseFloat(s.left)):null;s=!s||null==s.top||isNaN(s.top)||null==s.right||isNaN(s.right)||null==s.bottom||isNaN(s.bottom)||null==s.left||isNaN(s.left)?null:s;var D=dq(a,"effects","IDLIST"),O=iq(a,"cornerRadius",10,0,10,!0,0);a=lq(a,"gradient",Tq,"OPTIONAL");return new Rq(b,c,d,e,g,h,k,m,p,r,s,D,O,a)}function Uq(a,b,c,d,e,g,h,k){this.j=a;this.o=b;this.k=c;this.F=d;this.a=e;this.b=g;this.g=h;this.i=k}
-function Tq(a){var b=iq(a,"x1",10,0,100,!0,0),c=iq(a,"y1",10,0,100,!0,0),d=iq(a,"x2",10,0,100,!0,100),e=iq(a,"y2",10,0,100,!0,100),g=cq(a,"color1","#FFF"),h=cq(a,"color2","#000"),k=iq(a,"opacity1",10,0,100,!0,100);a=iq(a,"opacity2",10,0,100,!0,0);return new Uq(b,c,d,e,g,h,k,a)};function Vq(a,b){this.a=a;this.M=b}function Wq(a){var b=dq(a,"standard_url","OPTIONAL","");dq(a,"rollover_url","OPTIONAL","");dq(a,"click_url","OPTIONAL","");a=dq(a,"video_id","OPTIONAL","");return new Vq(b,a)};function Xq(a,b,c){var d=a.F,e=a.A,g=a.a?a.a:"xy",h=Yq(c,a.j,g);a=Zq(c,a.g,g);var g=640*b.width*h/100,k=360*b.height*a/100;return new Db(0==d?640*b.left*h/100:0<d?d:c.width+d-g,0==e?360*b.top*a/100:0<e?e:c.height+e-k,g,k)}function Yq(a,b,c){var d=(c="xx"==c||"xy"==c)?640:360;return(d+((c?a.width:a.height)-d)*b)/d}function Zq(a,b,c){var d=(c="xy"==c||"yy"==c)?360:640;return(d+((c?a.height:a.width)-d)*b)/d};function $q(a,b,c,d,e,g,h,k,m,p,r){this.x=a;this.y=b;this.k=c;this.i=d;this.b=e;this.o=g;this.F=h;this.A=k;this.j=m;this.g=p;this.a=r}function ar(a,b){var c=gq(a,"x",0),d=gq(a,"y",0),e=gq(a,"w",0),g=gq(a,"h",0),h=jq(a,"t"),k=hq(a),m=gq(a,"px",0),p=gq(a,"py",0),r=gq(a,"scaleSlope",1),s=gq(a,"scaleSlopeX",r),r=gq(a,"scaleSlopeY",r),D=dq(a,"scaleDimension","OPTIONAL","xy");return b(c,d,e,g,h,k,m,p,s,r,D)}
-function br(a,b,c){c=c?br(c,b):null;a=Xq(a,new Db(a.x,a.y,a.k,a.i),b);c?(a.top+=c.top,a.left+=c.left):(a.top+=b.top,a.left+=b.left);c=a.clone();b&&!b.contains(a)&&(a.width<b.width?c.left=wb(a.left,b.left,b.left+b.width-a.width):(c.left=b.left,c.width=b.width),a.height<b.height?c.top=wb(a.top,b.top,b.top+b.height-a.height):(c.top=b.top,c.height=b.height));return c}function cr(a){return ar(a,function(a,c,d,e,g,h,k,m,p,r,s){return new $q(a,c,d,e,g,h,k,m,p,r,s)})};function dr(a,b,c,d,e,g,h,k,m,p,r,s,D){$q.call(this,a,b,c,d,e,k,m,p,r,s,D);this.B=g;this.G=h}y(dr,$q);function er(a){var b=gq(a,"sx",0),c=gq(a,"sy",0);return ar(a,function(a,e,g,h,k,m,p,r,s,D,O){return new dr(a,e,g,h,k,b,c,m,p,r,s,D,O)})};function fr(a,b,c){this.type=a;this.b=b;this.a=c}var gr={Xx:"anchored",uC:"rect"};function hr(a){var b=eq(a,"type",gr,"OPTIONAL","rect"),c=lq(a,"rectRegion",cr,"REPEATED");a=lq(a,"anchoredRegion",er,"REPEATED");return new fr(b,c,a)}function ir(a){return a.b&&a.b.length?a.b[0]:a.a&&a.a.length?a.a[0]:null};function jr(a,b){this.b=a;this.a=b}function kr(a){$p(a,"timeRelative","OPTIONAL");var b=$p(a,"spaceRelative","OPTIONAL");return(a=lq(a,"movingRegion",hr,"REPEATED"))?new jr(b,a):null};function lr(a,b){this.state=a;this.a=b}var mr={nC:"playerControlShow",ay:"rollOver",by:"shown"};function nr(a){var b=eq(a,"state",mr,"OPTIONAL");a=$p(a,"ref","OPTIONAL","");return b?new lr(b,a):null};function or(a,b,c,d){this.a=a||[];this.g=b||[];this.i=c;this.b=d}function pr(a){var b=lq(a,"condition",nr,"REPEATED"),c=lq(a,"notCondition",nr,"REPEATED"),d=fq(a,"show_delay",!1);a=fq(a,"hide_delay",!1);return b||c?new or(b,c,d,a):null}function qr(a,b,c){z(a.a,oa(b,!1),c);z(a.g,oa(b,!0),c)};function rr(a,b,c,d,e,g,h,k,m,p,r,s,D,O,ta,$){this.id=a;this.author=b;this.type=c;this.style=d;this.o=e;this.a=g;this.g=h||[];this.B=k||[];this.b=m;this.G=p;this.j=r;this.F=s;this.i=D;this.k=O;this.data=ta;this.A=$}var sr={Xx:"anchored",eA:"channel",CB:"highlightText",PB:"label",pC:"popup",EC:"speech",cy:"subscribe",PC:"title",VIDEO:"video"},tr={qA:"custom",BB:"highlight",IMAGE:"image",PAUSE:"pause",TEXT:"text",vD:"widget"},ur={dD:"video_relative",oC:"player_relative"};
-function vr(a){var b=$p(a,"id","REQUIRED"),c=$p(a,"author","OPTIONAL"),d=eq(a,"type",tr,"REQUIRED"),e=eq(a,"style",sr,"OPTIONAL"),g=dq(a,"TEXT","OPTIONAL"),h=lq(a,"data",function(a){return 0!=a.length?nb(a):{}},"OPTIONAL",{}),k=lq(a,"segment",kr,"OPTIONAL"),m=lq(a,"action",Qq,"REPEATED"),p=lq(a,"trigger",pr,"REPEATED"),r=lq(a,"appearance",Sq,"OPTIONAL");r||(r=Sq({}));var s=eq(a,"coordinate_system",ur,"OPTIONAL","video_relative"),D=lq(a,"image_source",Wq,"OPTIONAL"),O=fq(a,"closeable",!0),ta=fq(a,
-"logable",!0),$=dq(a,"html_blob","OPTIONAL","");a=dq(a,"log_data","OPTIONAL","");return b&&d?new rr(b,c,d,e,g,k,m,p,r,s,D,O,ta,$,h,a):null}function Dq(a){return(a=Pa(a.g,function(a){return null!=a.url},void 0))?a.url:null}function wr(a){return Ma(a.g,function(a){return null!=a.url&&a.url.b},void 0)}function xr(a){return Ma(a.g,function(a){return"click"==a.trigger},void 0)}function yr(a,b,c){z(a.g,b,c)}function zr(a,b,c){z(a.B,b,c)}function Ar(a,b){La(a.B,b,void 0)}
-function Br(a){return(a=a.a?a.a.a.length?a.a.a[0]:null:null)?ir(a):null}function Cr(a,b){var c=Br(a);return c&&b?Yq(b,c.j,c.a?c.a:"xy"):1}function Dr(a,b){var c=Br(a);return c&&b?Zq(b,c.g,c.a?c.a:"xy"):1};function Er(a,b,c){this.a={};this.b=!1;this.j="ivTrigger:"+a;this.g=c;qr(b,function(a,b){var c=Fr(b.state,b.a);this.g.D(c,v(this.i,this,c,a));this.a[c]=!1},this)}Er.prototype.i=function(a,b,c,d){this.a[a]=b?!c:c;a=Ib(this.a,function(a){return a});this.b!=a&&(this.b=a,this.g.u(this.j,a,d))};function Fr(a,b){var c="ivTriggerCondition:"+a;return b?c+":"+b:c};function Gr(a,b,c){this.i=a;this.ib=b;this.b=c;this.a=null;this.Gb=this.isVisible=!1;Hr(b,a)}function Hr(a,b){Ar(a,function(c){return new Er(a.id,c,b)})}Gr.prototype.hide=function(){this.isVisible=!1;this.i.$("onResize",this.g,this);this.b.hide()};Gr.prototype.show=function(){this.isVisible=!0;this.b.show();this.i.D("onResize",this.g,this)};Gr.prototype.destroy=function(){this.i.$("onResize",this.g,this);var a=this.b;a.i.removeAll();a.na&&F(a.na);a.Fa&&a.Fa.N()&&F(a.Fa.N());Ir(this)};
-function Ir(a){a.a&&(a.a.stop(),a.a=null)}Gr.prototype.g=function(){Jr(this.b)};function Kr(){};function Lr(a,b,c,d,e,g,h,k){this.j=a;this.o=b;this.k=c;this.F=d;this.a=e;this.b=g;this.g=q(h)?h:null;this.i=q(k)?k:null}y(Lr,Kr);function Mr(){this.cb=[];this.T=[];this.Kd=[]}Mr.prototype.Rf=null;Mr.prototype.fd=null;Mr.prototype.Si=!0;var Nr=[2,2,6,6,0];f=Mr.prototype;f.clear=function(){this.cb.length=0;this.T.length=0;this.Kd.length=0;delete this.Rf;delete this.fd;delete this.Si;return this};function Or(a,b,c){0==Ha(a.cb)?a.Kd.length-=2:(a.cb.push(0),a.T.push(1));a.Kd.push(b,c);a.fd=a.Rf=[b,c]}
-f.Ga=function(a){var b=Ha(this.cb);if(null==b)throw Error("Path cannot start with lineTo");1!=b&&(this.cb.push(1),this.T.push(0));for(b=0;b<arguments.length;b+=2){var c=arguments[b],d=arguments[b+1];this.Kd.push(c,d)}this.T[this.T.length-1]+=b/2;this.fd=[c,d]};f.close=function(){var a=Ha(this.cb);if(null==a)throw Error("Path cannot start with close");4!=a&&(this.cb.push(4),this.T.push(1),this.fd=this.Rf);return this};
-function Pr(a,b,c,d,e){var g=a.fd[0]-b*Math.cos(d*Math.PI/180),h=a.fd[1]-c*Math.sin(d*Math.PI/180),g=g+b*Math.cos((d+e)*Math.PI/180),h=h+c*Math.sin((d+e)*Math.PI/180);a.cb.push(3);a.T.push(1);a.Kd.push(b,c,d,e,g,h);a.Si=!1;a.fd=[g,h]}function Qr(a,b){for(var c=a.Kd,d=0,e=0,g=a.cb.length;e<g;e++){var h=a.cb[e],k=Nr[h]*a.T[e];b(h,c.slice(d,d+k));d+=k}}
-f.clone=function(){var a=new this.constructor;a.cb=this.cb.concat();a.T=this.T.concat();a.Kd=this.Kd.concat();a.Rf=this.Rf&&this.Rf.concat();a.fd=this.fd&&this.fd.concat();a.Si=this.Si;return a};f.isEmpty=function(){return 0==this.cb.length};function Rr(a,b){this.A=a;this.B=null==b?1:b}y(Rr,Kr);function Sr(a,b){this.a=a;this.b=b};function Tr(a){this.b=a;this.a={}}y(Tr,K);var Ur=[];f=Tr.prototype;f.listen=function(a,b,c,d,e){t(b)||(Ur[0]=b,b=Ur);for(var g=0;g<b.length;g++){var h=si(a,b[g],c||this,d||!1,e||this.b||this);if(!h)break;this.a[h.key]=h}return this};f.ac=function(a,b,c,d,e){if(t(b))for(var g=0;g<b.length;g++)this.ac(a,b[g],c,d,e);else e=e||this.b||this,c=ti(c||this),d=!!d,b=hi(a)?oi(a.$c,String(b),c,d,e):a?(a=ui(a))?oi(a,b,c,d,e):null:null,b&&(yi(b),delete this.a[b.key]);return this};
-f.removeAll=function(){Hb(this.a,yi);this.a={}};f.H=function(){Tr.C.H.call(this);this.removeAll()};f.handleEvent=function(){throw Error("EventHandler.handleEvent not implemented");};function Vr(){}ca(Vr);Vr.prototype.a=0;Vr.getInstance();function Wr(a){Ci.call(this);this.o=a||Jc()}y(Wr,Ci);f=Wr.prototype;f.xv=Vr.getInstance();f.Ba=null;f.We=!1;f.Hf=null;f.xl=null;f.getId=function(){return this.Ba||(this.Ba=":"+(this.xv.a++).toString(36))};f.N=function(){return this.Hf};f.qp=function(){this.Hf=this.o.createElement("div")};f.Li=function(){Xr(this,function(a){a.We&&a.Li()});this.j&&this.j.removeAll();this.We=!1};
-f.H=function(){this.We&&this.Li();this.j&&(this.j.dispose(),delete this.j);Xr(this,function(a){a.dispose()});this.Hf&&F(this.Hf);this.Hf=this.xl=null;Wr.C.H.call(this)};function Xr(a,b){a.xl&&z(a.xl,b,void 0)};function Yr(a,b,c,d,e){Wr.call(this,e);this.width=a;this.height=b;this.g=c||null;this.k=d||null}y(Yr,Wr);Yr.prototype.b=null;Yr.prototype.fh=function(){return this.We?Cd(this.N()):ga(this.width)&&ga(this.height)?new B(this.width,this.height):null};function Zr(a){var b=a.fh();return b?b.width/(a.g?new B(a.g,a.k):a.fh()).width:0};function $r(a,b){Ci.call(this);this.hh=a;this.Fj=b;this[gi]=!1}y($r,Ci);f=$r.prototype;f.Fj=null;f.hh=null;f.N=function(){return this.hh};f.addEventListener=function(a,b,c,d){si(this.hh,a,b,c,d)};f.removeEventListener=function(a,b,c,d){xi(this.hh,a,b,c,d)};f.H=function(){$r.C.H.call(this);var a=this.hh;if(a)if(hi(a))a.$c&&a.$c.removeAll(void 0);else if(a=ui(a)){var b=0,c;for(c in a.a)for(var d=ab(a.a[c]),e=0;e<d.length;++e)yi(d[e])&&++b}};function as(a,b,c,d){$r.call(this,a,b);a=this.Fj;b=this.N();c?(b.setAttribute("stroke",c.b),c=c.a,u(c)&&-1!=c.indexOf("px")?b.setAttribute("stroke-width",parseFloat(c)/Zr(a)):b.setAttribute("stroke-width",c)):b.setAttribute("stroke","none");c=this.Fj;a=this.N();if(d instanceof Rr)a.setAttribute("fill",d.A),a.setAttribute("fill-opacity",d.B);else if(d instanceof Lr){b="lg-"+d.j+"-"+d.o+"-"+d.k+"-"+d.F+"-"+d.a+"-"+d.b;var e=b in c.a?c.a[b]:null;if(!e){var e=bs(c,"linearGradient",{x1:d.j,y1:d.o,x2:d.k,
-y2:d.F,gradientUnits:"userSpaceOnUse"}),g="stop-color:"+d.a;ga(d.g)&&(g+=";stop-opacity:"+d.g);g=bs(c,"stop",{offset:"0%",style:g});e.appendChild(g);g="stop-color:"+d.b;ga(d.i)&&(g+=";stop-opacity:"+d.i);d=bs(c,"stop",{offset:"100%",style:g});e.appendChild(d);e=cs(c,b,e)}a.setAttribute("fill","url(#"+e+")")}else a.setAttribute("fill","none")}y(as,$r);function ds(a,b){$r.call(this,a,b)}y(ds,$r);function es(a,b){$r.call(this,a,b)}y(es,$r);function fs(a,b,c,d){as.call(this,a,b,c,d)}y(fs,as);function gs(a,b){$r.call(this,a,b)}y(gs,ds);gs.prototype.clear=function(){$c(this.N())};function hs(a,b,c,d){as.call(this,a,b,c,d)}y(hs,fs);function is(a,b){$r.call(this,a,b)}y(is,es);function js(a,b,c,d,e){Yr.call(this,a,b,c,d,e);this.a={};this.F=gc&&!uc(526);this.A=new Tr(this)}var ks;y(js,Yr);var ls=0;function bs(a,b,c){a=a.o.a.createElementNS("http://www.w3.org/2000/svg",b);if(c)for(var d in c)a.setAttribute(d,c[d]);return a}f=js.prototype;
-f.qp=function(){var a=bs(this,"svg",{width:this.width,height:this.height,overflow:"hidden"}),b=bs(this,"g");this.i=bs(this,"defs");this.b=new gs(b,this);a.appendChild(this.i);a.appendChild(b);this.Hf=a;this.g&&(this.N().setAttribute("preserveAspectRatio","none"),this.F?this.Eo():this.N().setAttribute("viewBox","0 0 "+(this.g?this.g+" "+this.k:"")))};
-f.Eo=function(){if(this.We){var a=this.fh();0==a.width?this.N().style.visibility="hidden":(this.N().style.visibility="",this.b.N().setAttribute("transform","scale("+a.width/this.g+" "+a.height/this.k+") translate(0 0)"))}};
-f.fh=function(){if(!fc)return this.We?Cd(this.N()):js.C.fh.call(this);var a=this.width,b=this.height,c=u(a)&&-1!=a.indexOf("%"),d=u(b)&&-1!=b.indexOf("%");if(!this.We&&(c||d))return null;var e,g;c&&(e=this.N().parentNode,g=Cd(e),a=parseFloat(a)*g.width/100);d&&(e=e||this.N().parentNode,g=g||Cd(e),b=parseFloat(b)*g.height/100);return new B(a,b)};f.clear=function(){this.b.clear();$c(this.i);this.a={}};function ms(a,b,c,d){b=bs(a,"path",{d:ns(b)});c=new hs(b,a,c,d);a.b.N().appendChild(c.N())}
-function ns(a){var b=[];Qr(a,function(a,d){switch(a){case 0:b.push("M");Array.prototype.push.apply(b,d);break;case 1:b.push("L");Array.prototype.push.apply(b,d);break;case 2:b.push("C");Array.prototype.push.apply(b,d);break;case 3:var e=d[3];b.push("A",d[0],d[1],0,180<Math.abs(e)?1:0,0<e?1:0,d[4],d[5]);break;case 4:b.push("Z")}});return b.join(" ")}function cs(a,b,c){if(b in a.a)return a.a[b];var d="_svgdef_"+ls++;c.setAttribute("id",d);a.a[b]=d;a.i.appendChild(c);return d}
-f.Li=function(){js.C.Li.call(this);this.F&&this.A.ac(os(),"tick",this.Eo)};f.H=function(){delete this.a;delete this.i;delete this.b;js.C.H.call(this)};function os(){ks||(ks=new Fi(400),ks.start());return ks};function ps(a,b,c){this.a=a;this.b=0;this.i=b;c&&(this.dn=c)}f=ps.prototype;f.dn=70;f.dk=!1;f.start=function(a){this.k=x();this.b=a;this.j=this.k+this.b;this.dk=!0;Hn(this.a);jf(this.g);this.g=hf(v(this.Ft,this),this.dn)};f.stop=function(){this.dk=!1;In(this.a);this.g&&jf(this.g)};
-f.Ft=function(){if(this.dk){var a=x(),b;b=0==this.b||a>=this.j?0:1-(a-this.k)/this.b;var c=E("countdowntimer-diminishing-pieslice",this.a),d=Ve("svg",this.a);!d&&this.a.querySelectorAll&&(d=this.a.querySelectorAll("svg"),d=d.length?d[0]:null);var d=parseInt(d.getAttribute("width"),10),e=new Mr,g=d/2-5;Or(e,d/2,d/2);e.Ga(d/2,5);Pr(e,g,g,-90,360*-b);e.Ga(d/2,d/2);e.close();c.setAttribute("d",ns(e));a>=this.j&&(this.stop(),this.i&&this.i())}};function qs(a,b){this.b=a;this.a=b}function Eq(a,b,c){b&&b.i&&Dq(b)&&a.log_(Bq(a,b,3),c)}function Bq(a,b,c){var d={};d["iv-event"]=c;d["a-id"]=b.id;d["a-type"]=rs(b);if(c=Dq(b))d.link=escape(tq(c)),c.a&&(d["l-class"]=c.a);d.ps=a.a.La;if(b.A){var e=new xe(b.A);z(e.tc(),function(a){d[a]=e.get(a)})}return d}
-function rs(a){switch(a.type){case "text":switch(a.style){case "popup":return 1;case "speech":return 2;case "anchored":return 8;case "label":return 9;case "title":return 4;default:return 0}case "highlight":return 3;case "image":switch(a.style){case "video":return 11;case "channel":return 10;default:return 0}default:return 0}}qs.prototype.log_=function(a,b){this.b.u("command_log","iv",a,b)};function ss(){this.element=this.label=null;this.priority=0}y(ss,K);ss.prototype.listen=function(a,b,c){return this.element.listen(this.element,a,b,c||this)};ss.prototype.ac=function(a){this.element.ac(a)};function ts(a,b,c){Y.call(this,["div","ytp-segmented-control"]);this.g=a;this.b=-1;this.a=[];q(b)&&us(this,b,c)}y(ts,Y);function us(a,b,c){Ug(a.a);a.a=[];for(var d=0;d<b.length;d++){var e=new un(a.g);a.a[d]=e;c?e.Aa(["div",b[d]]):e.Aa(b[d]);0!=d&&V(e.N(),"ytp-segmented-control-other");vs(e,d==a.b);J(e,"click",v(a.xu,a));e.W(a.element)}}f=ts.prototype;
-f.W=function(a,b){ts.C.W.call(this,a,b);for(var c=0,d=0;d<this.a.length;d++)c=Math.max(c,Cd(this.a[d].N()).width);if(c)for(d=0;d<this.a.length;d++)Bd(this.a[d].N(),c)};f.Za=function(a){this.b=a;for(var b=0;b<this.a.length;b++)vs(this.a[b],b==a)};f.getSelected=function(){return this.b};function vs(a,b){if(b){var c=a.N();W(c,"ytp-segmented-control-deselected");V(c,"ytp-segmented-control-selected")}else c=a.N(),W(c,"ytp-segmented-control-selected"),V(c,"ytp-segmented-control-deselected")}
-f.xu=function(a){for(var b=0;b<this.a.length;b++)if(this.a[b]==a.currentTarget){b==this.b&&2==this.a.length?this.Za(0==b?1:0):this.Za(b);Ef(this.element,"change");break}};f.H=function(){us(this,[]);this.g=null;ts.C.H.call(this)};function ws(a){ss.call(this);this.label=a.getMsg("YTP_ANNOTATIONS_TITLE");this.element=new ts(a,[a.getMsg("YTP_ON"),a.getMsg("YTP_OFF")]);L(this,this.element);this.priority=2}y(ws,ss);ws.prototype.getSelected=function(){return this.element.getSelected()};ws.prototype.Za=function(a){this.element.Za(a)};function xs(a,b){this.start=a<b?a:b;this.end=a<b?b:a}xs.prototype.clone=function(){return new xs(this.start,this.end)};function ys(){}f=ys.prototype;f.Qc=!1;f.bf=null;f.Cl=null;function zs(a,b,c){a.bf?(Ad(a.bf.N(),b,c),a.bf.clear()):(b=new js(b,c,void 0,void 0,void 0),a.bf=b,a.bf.qp(),a.Cl=Uc("div"),a.Cl.appendChild(a.bf.N()));return a.bf}f.N=function(){return this.Cl};f.Yd=function(){};function As(a,b,c){var d=document.createElementNS("http://www.w3.org/2000/svg",a);b&&Hb(b,function(a,b){d.setAttribute(b,a)});for(var e=2;e<arguments.length;e++)d.appendChild(arguments[e]);return d}function Bs(a,b){var c;c=":"+(Vr.getInstance().a++).toString(36);b.setAttribute("result",c);a.appendChild(b);return c};function Cs(a,b){var c=Bs(a,As("feGaussianBlur",{"in":b,stdDeviation:"1.8"})),c=Bs(a,As("feDiffuseLighting",{"in":c,surfaceScale:"4",diffuseConstant:"1"},As("feDistantLight",{azimuth:"270",elevation:"15","lighting-color":"white"}))),c=Bs(a,As("feComposite",{"in":c,in2:b,operator:"in"}));return Bs(a,As("feComposite",{in2:c,"in":b,operator:"arithmetic",k2:1,k3:0.5,k4:0}))}
-function Ds(a,b){var c=Bs(a,As("feOffset",{"in":b,dx:"-7",dy:"-7"})),c=Bs(a,As("feGaussianBlur",{"in":c,stdDeviation:"3"})),c=Bs(a,As("feColorMatrix",{"in":c,type:"matrix",values:"0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.5 0"})),d=Bs(a,As("feColorMatrix",{"in":b,type:"matrix",values:"0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 100 0"})),d=Bs(a,As("feGaussianBlur",{"in":d,stdDeviation:"1"})),c=Bs(a,As("feComposite",{operator:"out","in":c,in2:d}));return Bs(a,As("feComposite",{operator:"over","in":b,in2:c}))}
-function Es(a,b){return b}function Fs(a){var b=As("filter",{filterUnits:"userSpaceOnUse"}),c="SourceGraphic";z(a,function(a){t:{switch(a){case "bevel":a=Cs;break t;case "dropshadow":a=Ds;break t}a=Es}c=a(b,c)});return b}function Gs(a){a=Ka(a,function(a){return a in Hs});gb(a,function(a,c){return Hs[a]-Hs[c]});return a}function Is(a,b){if(!b)return null;var c="effects:"+(b?b.join("|"):""),d=c in a.a?a.a[c]:null;if(d)return d;d=Fs(b);return 0<d.childNodes.length?cs(a,c,d):null}
-function Js(a){return Pa(a,function(a){return"dropshadow"==a})?new zb(0,7,7,0):new zb(0,0,0,0)}var Hs={bevel:1,dropshadow:2};function Ks(a,b,c,d,e){b=Ls(b,c,d?d.a/2+1:0);ms(a,b,d,e)}function Ls(a,b,c){var d=new Mr;Or(d,a.left+b+c,a.top+c);d.Ga(a.left+a.width-b-c,a.top+c);Pr(d,b,b,-90,90);d.Ga(a.left+a.width-c,a.top+a.height-b-c);Pr(d,b,b,0,90);d.Ga(a.left+b+c,a.top+a.height-c);Pr(d,b,b,90,90);d.Ga(a.left+c,a.top+b+c);Pr(d,b,b,180,90);d.close();return d}function Ms(a,b,c){b&&c&&a.setAttribute(b,"url(#"+c+")")}
-function Ns(a,b,c,d){var e=a.I;e?a=new Lr(e.j*b/100,e.o*c/100,e.k*b/100,e.F*c/100,e.a,e.b,e.g,e.i):(b=d?Math.max(a.a,0.9):a.a,a=new Rr(a.j,b));return a}function Os(a,b){var c=new zb(a.top,a.left+a.width,a.top+a.height,a.left),d=Js(b);ia(d)?(c.top-=d.top,c.right+=d.right,c.bottom+=d.bottom,c.left-=d.left):(c.top-=d,c.right+=void 0,c.bottom+=void 0,c.left-=NaN);return Eb(c)}function Ps(a,b,c){c.length&&(b=Pa(b.childNodes,function(a){return"g"==a.tagName}))&&(a=Is(a,Gs(c)),Ms(b,"filter",a))};function Qs(){}y(Qs,ys);Qs.prototype.a=0;
-Qs.prototype.Yd=function(a,b,c){var d=a.b,e=d.F,g=this.Qc&&xr(a),e=(e+=g?1:0)?new Sr(e,g?d.k:d.o):null;if(g=Br(a)){var h=br(g,b,c);if(!(0>=h.width||0>=h.height)){var k;if(k=(a=(a=a.a?a.a.a.length?a.a.a[0]:null:null)&&a.a?a.a:null)&&a.length?a[0]:null){var m;c=c?br(c,b):null;a=Xq(k,new Db(k.B,k.G,k.k,k.i),b);c?(a.top+=c.top,a.left+=c.left):(a.top+=b.top,a.left+=b.left);m=new A(a.left,a.top);c=h.clone();a=new Db(m.x,m.y,1,1);var g=Math.max(c.left+c.width,a.left+a.width),p=Math.max(c.top+c.height,a.top+
-a.height);c.left=Math.min(c.left,a.left);c.top=Math.min(c.top,a.top);c.width=g-c.left;c.height=p-c.top;c=Os(c,d.b);a=zs(this,c.width,c.height);var g=Ns(d,c.width,c.height,this.Qc),h=new Db(h.left-c.left,h.top-c.top,h.width,h.height),r=new A(m.x-c.left,m.y-c.top);this.a=17*Zq(b,k.g,k.a?k.a:"xy");b=d.g;k=e?e.a/2:0;m=Rs(h,r);var p=this.b(h,b,r,m),s=r.x,r=r.y,D=h.width,O=h.height,ta=h.left,h=h.top,$=new Mr;Or($,ta+b+k,h+k);"t"==m&&($.Ga(p.start,h+k),$.Ga(s,r),$.Ga(p.end,h+k));$.Ga(ta+D-b-k,h+k);Pr($,
-b,b,-90,90);"r"==m&&($.Ga(ta+D-k,p.start),$.Ga(s,r),$.Ga(ta+D-k,p.end));$.Ga(ta+D-k,h+O-b-k);Pr($,b,b,0,90);"b"==m&&($.Ga(p.end,h+O-k),$.Ga(s,r),$.Ga(p.start,h+O-k));$.Ga(ta+b+k,h+O-k);Pr($,b,b,90,90);"l"==m&&($.Ga(ta+k,p.end),$.Ga(s,r),$.Ga(ta+k,p.start));$.Ga(ta+k,h+b+k);Pr($,b,b,180,90);$.close();ms(a,$,e,g);if(e=this.N())V(e,"annotation-shape"),V(e,"annotation-speech-shape"),pd(e,c.left,c.top),Ad(e,c.width,c.height),Ps(a,e,d.b)}}}};
-function Rs(a,b){var c=a.top-b.y,d=b.x-a.left-a.width,e=b.y-a.top-a.height,g=a.left-b.x,h=Math.max(c,d,e,g);if(0>h)return"i";switch(h){case c:return"t";case d:return"r";case e:return"b";case g:return"l"}return"i"}Qs.prototype.b=function(a,b,c,d){function e(a,c,d){h=Math.min(Math.max(d-2*b,0),g);k=wb(a-h/2,c+b,c+d-h-b)}var g=this.a,h=0,k=0;"t"==d||"b"==d?e(c.x,a.left,a.width):"l"!=d&&"r"!=d||e(c.y,a.top,a.height);return new xs(k,k+h)};function Ss(){}y(Ss,ys);Ss.prototype.Yd=function(a,b,c){var d=Br(a);d&&(b=br(d,b,c),0>=b.width||0>=b.height||(a=a.b,c=Os(b,a.b),d=zs(this,c.width,c.height),Ks(d,new Db(0,0,b.width,b.height),a.g,new Sr(!a.i&&this.Qc?1:a.i,a.j),new Rr("#000",0)),b=this.N(),V(b,"annotation-shape"),Fd(b,this.Qc?Math.max(a.a,0.9):a.a),pd(b,c.left,c.top),Ad(b,c.width,c.height)))};function Ts(a,b,c){this.a=a||0;this.g=b||0;this.b=c||!1}y(Ts,ys);function Us(a,b){var c=a.width,d=a.height,e=0,g=0;0<b&&(a.width/a.height>b?(d=a.width/b,g=(a.height-d)/2):(c=a.height*b,e=(a.width-c)/2));return new Db(e,g,c,d)}
-Ts.prototype.Yd=function(a,b,c){var d=br(Br(a),b,c);if(!(0>=d.width||0>=d.height)){var e=Us(d,this.g);e.left+=d.left;e.top+=d.top;b=a.b;c=Os(e,b.b);var g=zs(this,c.width,c.height),h=new Rr("#000",0),e=Us(e,this.a);a=a.j?a.j.a?a.j.a:a.j.M?Qn(a.j.M,"hqdefault.jpg"):"":"";e=bs(g,"image",{x:e.left,y:e.top,width:e.width,height:e.height,"image-rendering":"optimizeQuality",preserveAspectRatio:"none"});e.setAttributeNS("http://www.w3.org/1999/xlink","href",a);a=new is(e,g);g.b.N().appendChild(a.N());if(e=
-this.N()){var k=this.Qc?Math.max(b.a,0.9):b.a;Fd(e,k);if(this.b&&0<b.i){var k=new Sr(b.i,b.j),d=new Db(0,0,d.width,d.height),m;m=Ls(d,b.g,k.a/2+1);var p="mask"in g.a?g.a.mask:null;if(p)m=p;else{var p=document.createElementNS("http://www.w3.org/2000/svg","mask"),r=document.createElementNS("http://www.w3.org/2000/svg","path");r.setAttribute("d",ns(m));r.setAttribute("fill","#FFF");p.appendChild(r);m=cs(g,"mask",p)}Ms(a.N(),"mask",m);Ks(g,d,b.g,k,h)}V(e,"annotation-shape");V(e,"annotation-image-shape");
-pd(e,c.left,c.top);Ad(e,c.width,c.height);Ps(g,e,b.b)}}};function Vs(){}y(Vs,ys);Vs.prototype.Yd=function(a,b,c){var d=Br(a);if(d){var e=br(d,b,c);if(!(0>=e.width||0>=e.height)){b=a.b;c=Os(e,b.b);var d=zs(this,c.width,c.height),g=b.F;a=this.Qc&&xr(a);a=(g+=a?1:0)?new Sr(g,a?b.k:b.o):null;g=new Db(0,0,e.width,e.height);e=Ns(b,e.width,e.height,this.Qc);Ks(d,g,b.g,a,e);if(a=this.N())V(a,"annotation-shape"),V(a,"annotation-popup-shape"),pd(a,c.left,c.top),Ad(a,c.width,c.height),Ps(d,a,b.b)}}};function Ws(){}y(Ws,Qs);Ws.prototype.b=function(a,b,c,d){function e(a,c,d){h=Math.min(Math.max(d-2*b,0),g);k=a<=c+d/2?Math.max(c+d/4-h/2,c+b):Math.min(c+3*d/4-h/2,c+d-h-b)}var g=this.a,h=0,k=0;"t"==d||"b"==d?e(c.x,a.left,a.width):"l"!=d&&"r"!=d||e(c.y,a.top,a.height);return new xs(k,k+h)};function Xs(a,b){this.b=Mc(a);this.a=Un(this.b,b)}
-function Ys(a,b){var c=Vn(a.a,b,void 0),c=c.replace(/^[\s\xa0]+/,""),d;d=String(c.substr(0,3)).toLowerCase();(d=0==("<tr"<d?-1:"<tr"==d?0:1))&&(c="<table><tbody>"+c+"</tbody></table>");var e=c,g=document,c=g.createElement("div");C?(c.innerHTML="<br>"+e,c.removeChild(c.firstChild)):c.innerHTML=e;if(1==c.childNodes.length)c=c.removeChild(c.firstChild);else{for(e=g.createDocumentFragment();c.firstChild;)e.appendChild(c.firstChild);c=e}d&&(c=ad(ad(c)));return c};function Zs(a,b,c,d,e){this.a=a;this.j=b;this.g=c;this.o=d;this.k=e;this.i=new Ko(this)}f=Zs.prototype;f.na=null;f.Sc=null;f.dc=null;f.Fa=null;f.Tk=null;function $s(a,b){var c=v(function(a,c,g){c=g?at(this,c,v(g,this)):at(this,c);this.i.listen(b,a,c)},a);c("mouseover","e",a.Kw);c("mouseout","d",a.Jw);c("click","b");c("mousedown","a");c("touchend","b")}
-function bt(a){if(a.a.F){var b;if(Ma(a.a.g,function(a){return"close"==a.type},void 0))b=a.na;else{b=Ys(new Xs("annotation-close-button-template",[]),{});if(!(b instanceof Element))return;a.dc=b;Pe(a.dc,"annotation_id",a.a.id);a.na.appendChild(a.dc);b=a.dc}var c=function(a){a.stopPropagation()};a.i.listen(b,"click",at(a,"c",c));a.i.listen(b,"touchend",at(a,"c",c))}}
-function at(a,b,c){return v(function(a){if(this.k)c&&c(a);else if(a.target instanceof Element){In(a.target);var e=document.elementFromPoint(a.clientX,a.clientY);Hn(a.target);jd(e,"annotation")&&Ef(e,a.type)}this.o.u(b,this.a)},a)}f.Kw=function(){this.dc&&Hn(this.dc);this.Sc&&Fd(this.Sc,1);var a=ct(this);this.Fa&&(this.Fa.Qc=!0,Fd(this.na,dt(this)?1:0),a&&this.Fa.Yd(this.a,a,et(this)))};
-f.Jw=function(){this.dc&&In(this.dc);this.Sc&&Fd(this.Sc,0);var a=ct(this);this.Fa&&(this.Fa.Qc=!1,Fd(this.na,dt(this)?1:0),a&&this.Fa.Yd(this.a,a,et(this)))};function et(a){return a.Tk?Br(a.Tk):null}
-function Jr(a){if(a.na||a.Fa){var b=Br(a.a);if(b){var c=ct(a),d=et(a);if(a.na&&c){b=br(b,c,d);Ad(a.na,b.width,b.height);pd(a.na,b.left,b.top);var e=a.g.tf;e&&(e=new zb(360*ft(a).top*Dr(a.a,e)/100,640*ft(a).right*Cr(a.a,e)/100,360*ft(a).bottom*Dr(a.a,e)/100,640*ft(a).left*Cr(a.a,e)/100),a.Sc&&(e.right+=1.5*c.height/100),a.na.style.padding=e.top+"px "+e.right+"px "+e.bottom+"px "+e.left+"px");"label"==a.a.style&&a.b&&(a.b.style.padding=a.na.style.padding);if(a.Sc){e=4.2*c.height/100;e=new B(e,e);Ad(a.Sc,
-e);if("highlight"==a.a.type||"label"==a.a.style)var g=1.5*c.height/100,e=new A(b.width-e.width-g,b.height-e.height-g);else e=new A(b.width-e.width-3*c.height/100,(b.height-e.height)/2);pd(a.Sc,e)}if(a.dc){Ad(a.dc,new B(18,18));var e=a.dc,g=Cd(a.dc),h=9<=c.left+c.width-(b.left+b.width),k=9<=b.top-c.top;pd(e,h&&k?new A(b.width-9,-9):h?new A(b.width-9,b.height>27+g.height?9:b.height-9):k?new A(b.width>27+g.width?b.width-9-g.width:-9,-9):b.width/c.width>b.height/c.height?new A(b.width>27+g.width?b.width-
-9-g.width:-9,b.height-9):new A(-9,b.height>27+g.height?9:b.height-9))}}a.Fa&&c&&a.Fa.Yd(a.a,c,d);if(a.na){c=a.na;d=a.a.b;c.style.color="highlightText"==a.a.style?d.B:d.k;c.style.fontSize=360*d.G*Dr(a.a,a.g.tf)/100+"px";c.style.textAlign=d.textAlign?d.textAlign:"title"==a.a.style||"highlightText"==a.a.style?"center":"left";d.A&&(c.style.fontWeight=d.A);a=a.na;c=a.style.overflow;(d=E("annotation-link-icon",a))&&In(d);a.style.overflow="scroll";for(b=100;0<b&&!(a.scrollHeight<=a.offsetHeight&&a.scrollWidth<=
-a.offsetWidth);b--){e=Qd(a);if(5>e)break;e--;a.style.fontSize=e+"px"}a.style.overflow=c;d&&Hn(d)}}}}function ft(a){var b=a.a.b;return b.padding?b.padding:new zb("speech"==a.a.style?1.6:0.8,"speech"==a.a.style?1.6:0.8,"speech"==a.a.style?1.6:0.8,"speech"==a.a.style?1.6:0.8)}
-f.show=function(){var a=this.a.b,a=(a&&0==a.a||"title"==this.a.style||"highlightText"==this.a.style||"pause"==this.a.type?!1:!0)&&!this.Fa,b=!this.na,c="widget"==this.a.type;if(a){var d=ct(this);if(d){var e=null;"highlight"==this.a.type||"label"==this.a.style?e=new Ss:"popup"==this.a.style?e=new Vs:"anchored"==this.a.style?e=new Qs:"speech"==this.a.style?e=new Ws:"image"==this.a.type&&("video"==this.a.style?e=new Ts(4/3,16/9,!0):"channel"==this.a.style&&(e=new Ts));e&&(e.Yd(this.a,d,et(this)),this.Fa=
-e,d=e.N())&&(In(d),V(d,"annotation-type-"+this.a.type.toLowerCase()),this.j(d))}}if(b){d=["annotation","hid"];"highlightText"!=this.a.style||d.push("annotation-no-mouse");d.push("annotation-type-"+this.a.type.toLowerCase());this.na=Uc("div",d);this.a.o&&("label"==this.a.style?(this.b=Uc("div",["label-text"]),this.b.style.backgroundColor=this.a.b.j,dd(this.b,this.a.o),this.na.appendChild(this.b)):dd(this.na,this.a.o));Pe(this.na,"annotation_id",this.a.id);this.j(this.na);$s(this,this.na);if(xr(this.a)&&
-"image"!=this.a.type&&wr(this.a)){if(d=Dq(this.a))this.na.title=tq(d);this.Sc=Uc("span","annotation-link-icon");this.na.appendChild(this.Sc)}bt(this);xr(this.a)||(this.na.style.cursor="default")}c&&("subscribe"==this.a.style?E("yt-uix-subscription-button",this.na)||(this.na.innerHTML=this.a.k):this.a.k&&(this.na.innerHTML=this.a.k));if(a||b){t:{a=this.a.a.a;if(a.length&&(a=ir(a[0]))){a=a.o;break t}a=0}this.na&&(this.na.style.zIndex=a);this.Fa&&this.Fa.N()&&(this.Fa.N().style.zIndex=a)}Hn(this.na);
-Fd(this.na,dt(this)?1:0);Jr(this);this.Fa&&Hn(this.Fa.N())};f.hide=function(){In(this.na);this.Fa&&In(this.Fa.N())};function dt(a){return"label"!=a.a.style||a.Fa.Qc}function ct(a){var b=a.g.tf;return b?"player_relative"==a.a.G?(a=a.g.Oc)?new Db(-b.left,-b.top,a.width,a.height):null:new Db(0,0,b.width,b.height):null};function gt(a){Im.call(this,a);this.b={};this.i={};this.j=new qs(this.F,this.a.K());var b=Q(a),c=E("html5-annotations-button",b);this.g=null;a.K().Ma?(F(c),this.g=new ws(this.a.app.R.B),this.g.listen("change",this.uq,this)):J(c,"click",v(this.Aq,this));this.D("onHideControls",this.zq,this);this.D("onShowControls",this.Cq,this);this.D("onStateChange",this.Bq,this);this.D("e",this.Eq,this);this.D("d",this.Dq,this);this.D("a",this.xq,this);this.D("b",this.wq,this);this.D("c",this.yq,this);a=E("video-annotations",
-b);a=E("countdowntimer",a);this.k=Uc("DIV",["video-annotations","html5-stop-propagation"]);Lm(this,this.k);Lm(this,a);this.A=new ps(a,v(this.nj,this))}y(gt,Im);f=gt.prototype;f.qa="iv-module";f.tl=!1;f.ep=!0;f.ba=!1;f.yd=0;function ht(a){return E("video-annotations",Q(a))&&it(a)?new gt(a):null}function it(a){return"leanback"==a.K().Z?!1:qm(a.getVideoData(),"iv3_module")}f.$a=function(){return it(this.a)};
-f.create=function(){gt.C.create.call(this);this.g&&this.u("module_menu_item_add",this.g);1==(this.a.K().ga||this.a.getVideoData().da)?this.load():jt(this,"tooltip-default")};f.destroy=function(){this.unload();this.g&&this.u("module_menu_item_remove",this.g);gt.C.destroy.call(this)};f.Aq=function(){this.ba||this.yd?this.unload():this.load()};f.uq=function(){var a=this.ba||this.yd,b=0==this.g.getSelected();a&&!b?this.unload():!a&&b&&this.load()};f.Bq=function(a){this.ep=P(a.state,8);0>Ho(a,4)&&this.A.stop()};
-f.load=function(){gt.C.load.call(this);jt(this,"tooltip-alt");var a={format:"XML",method:"GET",pd:v(this.Jo,this,null)},b=this.a.getVideoData();b.Jk&&(this.yd++,Qj(b.Jk,a));b.Ik&&(this.yd++,Qj(b.Ik,a));b.Hk&&(this.a.K().lc||this.a.K().Lc)&&(a={format:"XML",method:"GET",pd:v(this.Jo,this,v(this.fv,this,b.Ca))},this.yd++,Qj(b.Hk,a));this.g&&this.g.Za(0)};
-f.unload=function(){this.g&&this.g.Za(1);this.j.log_({"iv-event":1});this.nj();Jm(this);Hb(this.b,function(a){a.destroy()});Hb(this.i,function(a){a.destroy()});this.yd=0;this.ba=!1;this.b={};this.i={};jt(this,"tooltip-default");gt.C.unload.call(this)};function jt(a,b){var c=E("html5-annotations-button",Q(a.a));if(c){var d=G(c,b)||"";Pe(c,"tooltip",d);c.setAttribute("aria-label",d)}}
-function kt(a,b){for(var c={},d=0;d<b.attributes.length;d++){var e=b.attributes[d];c[e.name]=e.nodeValue}for(d=0;d<b.childNodes.length;d++)if(e=b.childNodes[d],e.tagName){var g;if(c[e.tagName])g=c[e.tagName];else if("html_blob"==e.tagName||"data"==e.tagName){c[e.tagName]=e.childNodes[0].nodeValue.trim();continue}else g=[],c[e.tagName]=g;e&&"TEXT"==e.tagName?1==e.childNodes.length&&3==e.childNodes[0].nodeType?g.push(e.childNodes[0].nodeValue):g.push(""):e&&g.push(kt(a,e))}return c}
-f.Jo=function(a,b){if(this.yd&&!this.ba){this.yd--;var c=b.responseXML?b.responseXML.getElementsByTagName("annotations"):null;if(Mj(b)&&c){c=c[0];a&&a(c);lt(this,c);V(Q(this.a),this.qa+"-loaded");0==this.yd&&(this.ba=!0);var c=[],d;for(d in this.b){var e=this.b[d].ib;if(e.a)if(e=e.a,e.a.length)if(e=e.a[0].b||e.a[0].a,!e||2>e.length)e=null;else var g=e.length-1,e=0>=e[0].b&&0>=e[g].b?null:{start:e[0].b,end:e[g].b};else e=null;else e=null;if(g=e)e=1E3*g.start,g=1E3*g.end,0==e&&(e++,g++),e==g&&g++,g<
-e||(e=new $h(e,g,{id:d}),c.push(e))}for(d in this.i)e=this.i[d].ib,e=new $h(e.data.start_ms,e.data.end_ms,{id:d}),c.push(e);this.uf.apply(this,c)}}};function mt(a,b){var c=nt(a,b);if(!c)return null;zr(b,function(a){a=v(this.ax,this,b.id,a);this.D("ivTrigger:"+b.id,a)},a);return new Gr(a.F,b,c)}
-function ot(a,b){var c=Uc("div",["annotation","annotation-type-custom","hid"]);a.k.appendChild(c);var d=null,e=new No(new Ko(a),a.a.K(),a.a.getVideoData(),a.j,a.a);switch(b.style){case "video":d=new Fq(b,c,e)}d&&zq(d,a.F);return d}
-function lt(a,b){for(var c=b.getElementsByTagName("annotation"),d=0;d<c.length;d++){var e=kt(a,c[d]),g=null;try{g=vr(e)}catch(h){}g&&("custom"==g.type?(e=ot(a,g))&&(a.i[g.id]=e):(e=mt(a,g))&&(a.b[g.id]=e))}Hb(a.b,function(a){var b=a.ib;b.a&&b.a.b&&(b=this.b[b.a.b])&&(a.b.Tk=b.ib)},a)}f.yc=function(a){gt.C.yc.call(this,a);a=a.getId();var b=this.b[a],c=this.i[a];c&&!c.Gb?c.show():b&&!b.Gb&&(b=b.ib,"pause"==b.type?pt(this,b):(qt(this,a),a=this.j,b&&b.i&&a.log_(Bq(a,b,2))))};
-f.Vc=function(a){gt.C.Vc.call(this,a);rt(this,a.getId())};function pt(a,b){if(a.ep){var c=Pa(b.g,function(a){return"pause"==a.type&&!!a.duration&&!!a.duration.value},void 0);c&&(a.tl=!0,a.u("command_pause"),a.A.start(1E3*c.duration.value))}}function rt(a,b,c){var d=a.i[b];if(d&&!d.Gb)d.hide();else if(b=a.b[b])Ir(b),c&&c.b?(a=v(a.lo,a,b),b.a=new Oo(a,2E3),b.a.start()):a.lo(b)}f.lo=function(a){if(a){a.hide();var b=a.ib.id;this.u(Fr("shown",b),!1,b);st(this,a.ib,"hidden")}};
-function qt(a,b,c){if(b=a.b[b])Ir(b),c&&c.i?(a=v(a.mo,a,b),b.a=new Oo(a,2E3),b.a.start()):a.mo(b)}f.mo=function(a){if(a){a.show();var b=a.ib.id;this.u(Fr("shown",b),!0,b);st(this,a.ib,"shown")}};f.ax=function(a,b,c){c?qt(this,a,b):rt(this,a,b)};f.xq=function(a){if(a&&a.id){var b=this.j;a&&a.i&&Dq(a)&&b.log_(Bq(b,a,8))}};f.wq=function(a){if(a&&a.id){var b=Dq(a),c=v(function(){b&&st(this,a,"click")},this);uq(tq(b))&&"new"!=b.target||(c(),c=null);Eq(this.j,a,c)}};
-function st(a,b,c){yr(b,function(a){if(a.trigger==c)switch(a.type){case "log":a.url&&sa(a.url.value);break;case "openUrl":var e=this.a.getVideoData(),g=vq(a.url,e);if(-1!=g){this.u("command_seek",g);this.nj();break}if(e=wq(a.url,b,e))Vm(this),window.open(e,xq(a.url))}},a)}f.zq=function(){this.u(Fr("playerControlShow",void 0),!1,void 0)};f.Cq=function(){this.u(Fr("playerControlShow",void 0),!0,void 0)};f.Eq=function(a){a=a.id;this.u(Fr("rollOver",a),!0,a)};
-f.Dq=function(a){a=a.id;this.u(Fr("rollOver",a),!1,a)};f.yq=function(a){if(a||a.id)if(this.b[a.id].Gb=!0,rt(this,a.id),a){var b=this.j;a&&a.i&&b.log_(Bq(b,a,4));st(this,a,"close")}};f.nj=function(){this.A.stop();this.tl&&(this.tl=!1,this.u("command_play"))};function nt(a,b){if(tt(b)){var c=b.F||Ma(b.g,function(a){return"click"==a||"rollOut"==a||"rollOut"==a},void 0);return new Zs(b,v(a.k.appendChild,a.k),a.a.K(),a.F,c)}return null}
-function tt(a){if("highlight"==a.type||"image"==a.type||"widget"==a.type)return!0;if("text"==a.type)for(var b in sr)if(a.style==sr[b])return!0;return!1}function ut(a,b,c,d,e){var g=a.ownerDocument.createElement("action");g.setAttribute("type","log");g.setAttribute("trigger",d);a=a.ownerDocument.createElement("url");d={};d.value="a_id="+c;d.label="cta_annotation_"+e;b=Kj(b,d);a.setAttribute("value",b);g.appendChild(a);return g}
-f.fv=function(a,b){if(a)for(var c=b.getElementsByTagName("annotation"),d=0;d<c.length;d++){var e=c[d],g=kt(this,e);if(fq(g,"logable",!0)){var g=$p(g,"id","REQUIRED"),h=e.getElementsByTagName("action"),h=h.length?h[0]:null;e.insertBefore(ut(e,a,g,"shown","shown"),h);e.insertBefore(ut(e,a,g,"click","clicked"),h);e.insertBefore(ut(e,a,g,"close","closed"),h)}}};var vt;function wt(a,b){fa(b)&&(b=b.join(" "));if(""===b||void 0==b){var c;vt||(vt={atomic:!1,autocomplete:"none",dropeffect:"none",haspopup:!1,live:"off",multiline:!1,multiselectable:!1,orientation:"vertical",readonly:!1,relevant:"additions text",required:!1,sort:"none",busy:!1,disabled:!1,hidden:!1,invalid:"false"});c=vt;"pressed"in c?a.setAttribute("aria-pressed",c.pressed):a.removeAttribute("aria-pressed")}else a.setAttribute("aria-pressed",b)};function xt(a,b,c,d,e){un.call(this,a,b,c,c);this.O=b;this.Q=this.P=c;this.B=d||null;this.G=e||null;this.I=e||null;this.b=!1}y(xt,un);function zt(a){wn(a,a.b&&a.B?a.B:a.O);a.Hb(a.b&&a.G?a.G:a.P);a.a=a.b&&a.I?a.I:a.Q;X(a.element,"ytp-button-pressed",a.b)}function At(a){a.b=!0;wt(a.element,!0);zt(a)}function Bt(a){a.b=!1;wt(a.element,!1);zt(a)}xt.prototype.H=function(){this.I=this.G=this.B=null;yf(this.V);this.V=null;xt.C.H.call(this)};function Ct(a){Y.call(this,["div","ytp-action-buttons"]);this.g=new xt(a,"ytp-button-info",a.getMsg("YTP_BUTTON_INFO"));L(this,this.g);this.g.W(this.element);this.i=new xt(a,"ytp-button-share",a.getMsg("YTP_BUTTON_SHARE"));L(this,this.i);this.i.W(this.element);this.a=new xt(a,"ytp-button-dislike",a.getMsg("YTP_BUTTON_DISLIKE"));L(this,this.a);this.listen(this.a,"click",this.k);this.a.W(this.element);this.b=new xt(a,"ytp-button-like",a.getMsg("YTP_BUTTON_LIKE"));L(this,this.b);this.listen(this.b,"click",
-this.F);this.b.W(this.element);this.b.hide();this.a.hide()}y(Ct,Y);Ct.prototype.F=function(){At(this.b);Bt(this.a)};Ct.prototype.k=function(){At(this.a);Bt(this.b)};function Dt(a){var b=le("/signin?context=popup","next",document.location.protocol+"//"+document.domain+"/post_login"),b=le(b,"feature","sub_button");if(b=window.open(b,"loginPopup","width=375,height=440,resizable=yes,scrollbars=yes",!0)){var c=jp("LOGGED_IN",function(b){np();a(b)});bf("LOGGED_IN_PUBSUB_KEY",c);b.moveTo((screen.width-375)/2,(screen.height-440)/2)}}pa("yt.pubsub.publish",op);function Et(){this.a={}}y(Et,xp);ca(Et);f=Et.prototype;f.Wi="tooltip";f.Vi=0;f.register=function(){yp(this,"mouseover",this.Lp);yp(this,"mouseout",this.Hl);yp(this,"click",this.Hl);yp(this,"touchstart",this.Kx);yp(this,"touchend",this.Rp);yp(this,"touchcancel",this.Rp)};f.$p=function(){return!(this.g&&0==sc.indexOf("6"))};
-f.Lp=function(a){if(!(this.Vi&&1E3>x()-this.Vi)){var b=parseInt(G(a,"tooltip-hide-timer"),10);b&&(this.removeData(a,"tooltip-hide-timer"),I(b));var b=v(function(){Ft(this,a);this.removeData(a,"tooltip-show-timer")},this),c=parseInt(G(a,"tooltip-show-delay"),10)||0,b=H(b,c);Pe(a,"tooltip-show-timer",b.toString());a.title&&(zp(a,Gt(a)),a.title="")}};
-f.Hl=function(a){var b=parseInt(G(a,"tooltip-show-timer"),10);b&&(I(b),this.removeData(a,"tooltip-show-timer"));b=v(function(){Ht(this,a);this.removeData(a,"tooltip-hide-timer")},this);b=H(b,50);Pe(a,"tooltip-hide-timer",b.toString());if(b=G(a,"tooltip-text"))a.title=b};f.Kx=function(a,b){this.Vi=0;var c=tp(b,Z(this),null[0].target);this.Lp(c)};f.Rp=function(a,b){this.Vi=x();var c=tp(b,Z(this),null[0].target);this.Hl(c)};function It(a,b){zp(a,b);var c=G(a,"content-id");if(c=Mc(c))c.innerHTML=b}
-function Gt(a){return G(a,"tooltip-text")||a.title}
-function Ft(a,b){if(b){var c=Gt(b);if(c){var d=Mc(Jt(a,b));if(!d){d=document.createElement("div");d.id=Jt(a,b);d.className=Z(a,"tip");var e=document.createElement("div");e.className=Z(a,"tip-body");var g=document.createElement("div");g.className=Z(a,"tip-arrow");var h=document.createElement("div");h.className=Z(a,"tip-content");var k=Kt(a,b),m=Jt(a,b,"content");h.id=m;Pe(b,"content-id",m);e.appendChild(h);k&&d.appendChild(k);d.appendChild(e);d.appendChild(g);(Gf()||document.body).appendChild(d);It(b,
-c);(c=parseInt(G(b,"tooltip-max-width"),10))&&e.offsetWidth>c&&(e.style.width=c+"px",Dc(h,Z(a,"normal-wrap")));h=Gc(b,Z(a,"reverse"));Lt(a,b,d,e,k,h)||Lt(a,b,d,e,k,!h);var p=Z(a,"tip-visible");H(function(){Dc(d,p)},0)}}}}
-function Lt(a,b,c,d,e,g){Hc(c,Z(a,"tip-reverse"),g);var h=0;g&&(h=1);a=Cd(b);g=new A((a.width-10)/2,g?a.height:0);var k=ud(b);qp(new A(k.x+g.x,k.y+g.y),c,h);h=Rc(window);k=xd(c);c=Cd(d);var m=Math.floor(c.width/2);e&&(e.style.left="3px",e.style.height=c.height+"px",e.style.width=c.width+"px");e=!!(h.height<k.y+a.height);a=!!(k.y<a.height);g=!!(k.x<m);h=!!(h.width<k.x+m);k=(c.width+3)/-2- -5;b=G(b,"force-tooltip-direction");if("left"==b||g)k=-5;else if("right"==b||h)k=20-c.width-3;d.style.left=Math.floor(k)+
-"px";return!(e||a)}function Ht(a,b){if(b){var c=Mc(Jt(a,b));c&&(Mt(c),F(c),a.removeData(b,"content-id"))}}function Jt(a,b,c){a=Z(a);var d=b.__yt_uid_key;d||(d=Se(),b.__yt_uid_key=d);b=a+d;c&&(b+="-"+c);return b}function Kt(a,b){var c=null;$b&&Gc(b,Z(a,"masked"))&&((c=Mc("yt-uix-tooltip-shared-mask"))?(c.parentNode.removeChild(c),Hn(c)):(c=document.createElement("iframe"),c.src='javascript:""',c.id="yt-uix-tooltip-shared-mask",c.className=Z(a,"tip-mask")));return c}
-function Mt(a){var b=Mc("yt-uix-tooltip-shared-mask"),c=b&&kd(b,function(b){return b==a},!1,2);b&&c&&(b.parentNode.removeChild(b),In(b),document.body.appendChild(b))};function Nt(){this.a={};this.i=[]}y(Nt,xp);ca(Nt);Nt.prototype.Wi="subscription-button";
-Nt.prototype.register=function(){yp(this,"click",this.mp);this.i.push(jp("subscription-subscribe-loading",this.lp,this),jp("subscription-subscribe-loaded",this.kp,this),jp("subscription-unsubscirbe-loading",this.lp,this),jp("subscription-unsubscribe-loaded",this.kp,this),jp("subscription-subscribe-success",this.Hw,this),jp("subscription-unsubscribe-success",this.Iw,this),jp("subscription-enable-ypc",this.Gw,this),jp("subscription-disable-ypc",this.Fw,this))};
-var Ot={Kp:"hover-enabled",Ex:"yt-uix-button-subscribe",Fx:"yt-uix-button-subscribed",Sz:"ypc-enabled",Tx:"yt-uix-button-subscription-container",Ux:"yt-subscription-button-disabled-mask-container"},Pt={fA:"channel-external-id",Gx:"subscriber-count-show-when-subscribed",Hx:"subscriber-count-tooltip",Ix:"subscriber-count-title",FB:"href",Wp:"is-subscribed",mC:"parent-url",DC:"sessionlink",Jx:"style-type",Xp:"subscription-id",NC:"target",Lx:"ypc-enabled",Pp:"ypc-item-type",Op:"ypc-item-id",Qp:"ypc-offers-url"};
-f=Nt.prototype;f.mp=function(a){var b=G(a,"href"),c=!!ff("subscription_ajax");if(b)a=G(a,"target")||"_self",window.open(b,a);else if(c){var b=G(a,"channel-external-id"),c=G(a,"sessionlink"),d;if(G(a,"ypc-enabled")){d=G(a,Pt.Pp);var e=G(a,Pt.Op),g=G(a,Pt.Qp);d={itemType:d,itemId:e,offersUrl:g,subscriptionElement:a}}else d=null;e=G(a,"parent-url");G(a,"is-subscribed")?(g=G(a,"subscription-id"),op("subscription-unsubscribe",b,g,d,a,c,e)):op("subscription-subscribe",b,d,a,c,e)}else Qt(this,a)};
-f.lp=function(a){this.Tf(a,this.Up,!0)};f.kp=function(a){this.Tf(a,this.Up,!1)};f.Hw=function(a,b){this.Tf(a,this.Vp,!0,b)};f.Iw=function(a){this.Tf(a,this.Vp,!1)};f.Gw=function(a){this.Tf(a,this.Ox)};f.Fw=function(a){this.Tf(a,this.Nx)};f.Vp=function(a,b,c){b?(Pe(a,Pt.Wp,"true"),c&&Pe(a,Pt.Xp,c)):(this.removeData(a,Pt.Wp),this.removeData(a,Pt.Xp));Rt(a)};f.Up=function(a,b){var c=jd(a,Ot.Tx);Hc(c,Ot.Ux,b);a.setAttribute("aria-busy",b?"true":"false");a.disabled=b};
-function Rt(a){var b=G(a,Pt.Jx),c=!!G(a,"is-subscribed"),b="-"+b,d=Ot.Fx+b;Hc(a,Ot.Ex+b,!c);Hc(a,d,c);G(a,Pt.Hx)&&!G(a,Pt.Gx)&&(b=Z(Et.getInstance()),Hc(a,b,!c),a.title=c?"":G(a,Pt.Ix));c?H(function(){Dc(a,Ot.Kp)},1E3):Ec(a,Ot.Kp)}f.Ox=function(a){var b=!!G(a,Pt.Pp),c=!!G(a,Pt.Op),d=!!G(a,Pt.Qp);!G(a,"ypc-enabled")&&b&&c&&d&&(Dc(a,"ypc-enabled"),Pe(a,Pt.Lx,"true"))};f.Nx=function(a){G(a,"ypc-enabled")&&(Ec(a,"ypc-enabled"),this.removeData(a,"ypc-enabled"))};
-function St(a,b){var c=Nc(Z(a));return Ka(c,function(a){return b==G(a,"channel-external-id")},a)}f.ey=function(a,b,c){var d=db(arguments,2);z(a,function(a){b.apply(this,$a(a,d))},this)};f.Tf=function(a,b,c){var d=St(this,a),d=$a([d],db(arguments,1));this.ey.apply(this,d)};function Qt(a,b){var c=v(function(a){a.subscription_ajax&&ef("subscription_ajax",a.subscription_ajax);this.mp(b)},a);Dt(c)};function Tt(a){this.b=a||1;yn.call(this,30*this.b,30*this.b);this.F=this.width/2;this.i=this.height/2;this.B=0;this.S.translate(this.F,this.i)}y(Tt,yn);Tt.prototype.show=function(){Tt.C.show.call(this);var a=this.G;this.k=new Date;this.g(a,125)};
-Tt.prototype.G=function(){this.S.clearRect(-this.F,-this.i,this.width,this.height);for(var a=this.B++%8,b=0;8>b;b++){var c=2*Math.PI/8*(a+b),d=11*this.b*Math.cos(c),c=11*this.b*Math.sin(c),e=(b+1)/9;this.S.beginPath();this.S.arc(d,c,4*this.b,0,2*Math.PI,!1);this.S.fillStyle="rgba(189, 189, 189, "+e+")";this.S.fill()}};Tt.prototype.hide=function(){I(this.a);Tt.C.hide.call(this)};function Ut(){Y.call(this,["div","ytp-sentiment-display",["div","ytp-sentiment-bar",["div","ytp-sentiment-bar-likes"],["div","ytp-sentiment-bar-dislikes"]],["div","ytp-sentiment-text","{{sentiment}}"]]);this.b=this.template.a["ytp-sentiment-bar-likes"];this.a=this.template.a["ytp-sentiment-bar-dislikes"]}y(Ut,Y);Ut.prototype.H=function(){this.a=this.b=null;Ut.C.H.call(this)};function Vt(a){a=["button","ytp-button-share-more",["div","ytp-button-share-more-icon yt-uix-button-icon-new-window"],["span","ytp-button-share-more-content",a.getMsg("YTP_BUTTON_MORE_SHARE")]];Y.call(this,a)}y(Vt,Y);function Wt(a,b,c,d){un.call(this,a,"share-service-icon-"+d+"-sharebar",b,c);V(this.element,"share-service-icon-sharebar")}y(Wt,un);function Xt(){Y.call(this,["div","ytp-share-url-container",["input","ytp-share-url"]]);this.a=this.template.a["ytp-share-url"]}y(Xt,Y);Xt.prototype.H=function(){this.a=null;Xt.C.H.call(this)};function Yt(a,b,c){R.call(this);this.a=a;this.g=b;this.i=c;this.gb=new Ko(this);this.j=this.b=this.k=this.ia=null;this.A=this.o=!1}y(Yt,R);f=Yt.prototype;f.Nj=function(){var a=E("html5-title",this.a);this.k=E("html5-title-text",a);this.gb.listen(this.k,"click",this.qn);this.b=new Ct(this.i);this.b.W(a,1);this.gb.listen(this.b.g,"click",this.bk);this.g.hf&&this.b.g.hide();this.gb.listen(this.b.i,"click",this.Vh)};f.reset=function(){};
-f.update=function(a){this.ia=a;this.reset();dd(this.k,a.title||"");Hn(this.a)};f.qn=function(){this.Ci(this.ia.Lc||Zt(this.g,this.ia))};f.bk=function(){if(!this.o){this.o=!0;hn(this.ia?this.ia.M:void 0,!1,this.$s,ba,this,this.g.Ea,this.g.Ua);if(!this.j){var a=E("html5-info-panel-loading-icon",this.a);this.j=new Tt;V(this.j.element,"html5-info-panel-loader");this.j.W(a);L(this,this.j)}this.j.show()}Bt(this.b.i);W(this.a,"show-share");a=this.b.g;a.b?Bt(a):At(a);return Gm(this.a,"show-more-info")};
-f.Vh=function(a){Bt(this.b.g);W(this.a,"show-more-info");if("detailpage"!=this.g.Z){if(!this.A){this.A=!0;var b={action_get_share_info:1,feature:"player_embedded",video_id:this.ia?this.ia.M:void 0};this.g.Ea&&(b.authuser=this.g.Ea);this.g.Ua&&(b.pageid=this.g.Ua);Qj("/share_ajax",{S:this,method:"GET",onError:this.Bt,Pa:this.Ct,rf:b})}a&&a.stopPropagation();a=this.b.i;a.b?Bt(a):At(a);Gm(this.a,"show-share")}};
-f.$s=function(a,b){if(!this.ka()){var c=E("html5-info-panel",this.a),d=b.user_info;this.ia&&(this.ia.pa=d.external_id);var e=E("html5-author-img",c).getElementsByTagName("img")[0];e.src=d.image_url;this.gb.listen(e,"click",this.Nn);e=E("html5-author-name",c);dd(e,d.username);this.gb.listen(e,"click",this.Nn);e=b.video_info;e.subscription_ajax_token&&ef("subscription_ajax",e.subscription_ajax_token);var g=E("html5-subscribe-button-container",c);g.innerHTML=d.subscription_button_html?d.subscription_button_html:
-"";d=Nt.getInstance();(d=E(Z(d),g))&&$t(this.i,d);E("html5-view-count",c).innerHTML=e.view_count_string;var h=parseInt(e.likes_count_unformatted,10),g=parseInt(e.dislikes_count_unformatted,10),d=new Ut,k=0,m=0;0<h+g&&(k=100*h/(h+g),m=100*g/(h+g));d.b.style.width=k+"%";d.a.style.width=m+"%";h=nf("YTP_SENTIMENT_LIKE",h);g=nf("YTP_SENTIMENT_DISLIKE",g);bn(d.template,"sentiment",h+", "+g);d.W(E("html5-video-info",c),2);d=E("html5-description-text",c);dd(d,e.description);this.j.hide();c=E("html5-info-panel-content",
-c);Hn(c)}};
-f.Ct=function(a,b){if(!this.ka()){var c=E("share-bar"),d=new Xt;Pc(d.a,{value:b.url_short});d.W(c);Dm(this.a,"show-share")&&(d.a.focus(),d.a.select());for(var d=b.links,e=0;e<Math.min(3,d.length);e++){var g=new Wt(this.i,d[e].name,d[e].sname,d[e].img);g.W(c);this.gb.listen(g,"click",oa(Rp,d[e].url,{}))}d=new Vt(this.i);this.gb.listen(d,"click",v(this.Ci,this,b.more));d.W(c);d=new un(this.i,"yt-uix-button-icon-share-bar-close",this.i.getMsg("YTP_BUTTON_CLOSE"),this.i.getMsg("YTP_BUTTON_CLOSE"));d.W(c);
-this.gb.listen(d,"click",this.Vh)}};f.Bt=function(){};f.Nn=function(){var a=this.g,b=this.ia,c="",c=b.pa?a.lb+"channel/UC"+b.pa:a.lb+"user/"+b.author;this.Ci(c)};f.Ci=function(a){Qp(a)};f.H=function(){this.gb.removeAll();this.ia=this.k=this.g=this.a=null;Yt.C.H.call(this)};function au(){Y.call(this,["div","ytp-playlist-tray-index-length",["span","ytp-playlist-tray-index","{{index}}"],["span",""," / "],["span","ytp-playlist-tray-length","{{length}}"]])}y(au,Y);au.prototype.Jg=function(a){bn(this.template,"index",a+1)};function bu(a){xt.call(this,a,"ytp-button-expand",a.getMsg("YTP_BUTTON_EXPAND"),"ytp-button-collapse",a.getMsg("YTP_BUTTON_COLLAPSE"));this.Aa([["div","ytp-button-playlist-icon"],["div","ytp-button-playlist-text",a.getMsg("YTP_BUTTON_PLAYLIST")]])}y(bu,xt);function cu(a){Y.call(this,["div","ytp-playlist-tray-controller"]);this.b=new bu(a);this.b.W(this.template.N());L(this,this.b);this.a=new au;this.a.W(this.template.N());L(this,this.a)}y(cu,Y);function du(a,b,c,d){a=["div","ytp-playlist-tray-action-info",["div","ytp-playlist-tray-playlist-title",b],["div","ytp-playlist-tray-author-name",a.getMsg("YTP_AUTHOR_ATTRIBUTION",{author:c})],["div","ytp-playlist-tray-description-text",d]];Y.call(this,a)}y(du,Y);function eu(a){var b=["div","ytp-playlist-tray-action-share",["div","ytp-playlist-tray-action-share-heading",a.getMsg("YTP_SHARE_PLAYLIST")],["div","share-bar-services"]];Y.call(this,b);this.i=a;this.g=new Ko(this);this.b=this.a=null}y(eu,Y);eu.prototype.H=function(){this.g.removeAll();this.g=null;eu.C.H.call(this)};function fu(a,b){Y.call(this,["div","ytp-playlist-tray-item",["span","ytp-playlist-tray-item-index","{{index}}"],["span","ytp-playlist-tray-item-now-playing","\u25b6"],["img","ytp-playlist-tray-item-thumbnail",{src:"{{image}}"}],["span","ytp-playlist-tray-item-title","{{title}}"],["span","ytp-playlist-tray-item-author","{{author}}"]]);this.a=b;this.template.update({index:b+1,title:a.title,author:a.author,image:Qn(a.M)})}y(fu,Y);
-fu.prototype.Jg=function(a){X(this.element,"ytp-playlist-tray-item-current",this.a==a)};function gu(){Y.call(this,["div","ytp-playlist-tray-tray"]);this.a=null;this.i=new Ko(this);this.b=[]}y(gu,Y);function hu(a,b){b!=a.a&&(a.a&&a.a.$("shuffle",a.g,a),a.a=b,a.a.D("shuffle",a.g,a),a.g())}gu.prototype.g=function(){this.i.removeAll();this.b=[];$c(this.element);for(var a=0;a<=this.a.Mb-1;++a){var b=new fu(wh(this.a,a),a);b.Jg(this.a.ua);this.b.push(b);this.i.listen(b,"click",oa(this.k,a));b.W(this.element)}};
-gu.prototype.k=function(a){a={index:a};var b=document.createEvent("CustomEvent");b.initCustomEvent("playvideoat",!0,!0,a||null);this.dispatchEvent(b)};gu.prototype.H=function(){this.i.removeAll();gu.C.H.call(this)};function iu(a){Im.call(this,a);var b=Q(a);this.j=new Ko(this);this.k=a.app.R.B;this.i=new Xm(["div",["ytp-playlist-tray-container","html5-stop-propagation"],["div",["ytp-playlist-tray-info","show-more-info"]]]);L(this,this.i);this.a.app.R.g.appendChild(this.i.N());this.g=new gu;this.j.listen(this.g,"playvideoat",v(function(b){a.hm(b.detail.index)},a));L(this,this.g);this.g.W(this.i.N(),0);this.G=E("html5-playlist-button",b);J(this.G,"click",v(this.zm,this));this.B=this.A=null;this.I=!1;this.b=new cu(this.k);
-this.b.W(E("html5-title",void 0),0);this.j.listen(this.b.b,"click",this.zm);this.D("fullscreentoggled",this.oq,this);this.D("videodatachange",this.pq,this);this.D("onResize",this.im,this);this.D("clearvideooverlays",this.unload,this)}y(iu,Im);f=iu.prototype;f.qa="playlist";f.create=function(){var a=this.a.vb();hu(this.g,a);for(var b=this.g,c=0;c<b.b.length;c++)b.b[c].Jg(b.a.ua);a.D("shuffle",this.lu,this);iu.C.create.call(this)};
-f.lu=function(){this.b.a.Jg(this.a.Tj());var a=zm(this.a.vb());bn(this.b.a.template,"length",a)};f.destroy=function(){this.a.vb()||(hu(this.g,null),iu.C.destroy.call(this))};f.load=function(){this.ba=!0;iu.C.load.call(this);At(this.b.b)};f.unload=function(){this.ba=!1;iu.C.unload.call(this);Bt(this.b.b)};
-f.zm=function(){if(this.ba)this.unload();else if(this.u("command_clear_video_overlays"),this.load(),this.im(),!this.A){var a=E("ytp-playlist-tray-info"),b=new Ct(this.k);b.W(a,0);this.j.listen(b.g,"click",this.Zt);this.j.listen(b.i,"click",this.au);b=this.a.vb();this.A=new du(this.k,b.title,b.author,b.description);this.A.W(a)}};f.Zt=function(){var a=E("ytp-playlist-tray-info");Dc(a,"show-more-info");Ec(a,"show-share")};
-f.au=function(){var a=E("ytp-playlist-tray-info");Ec(a,"show-more-info");Dc(a,"show-share");this.I||(this.B=new eu(this.k),this.B.W(a),this.I=!0,Qj("/share_ajax",{S:this,method:"GET",onError:this.Wu,Pa:this.Xu,rf:{action_get_share_info:1,feature:"player_embedded",video_id:this.a.getVideoData().M,list:this.a.vb().g}}))};f.hide=function(){var a=E("ytp-playlist-tray-info");Ec(a,"show-more-info");Ec(a,"show-share")};
-f.Xu=function(a,b){var c=this.B;c.g.removeAll();var d=b.links,e=c.template.a["share-bar-services"];$c(e);for(var g=0;g<Math.min(3,d.length);g++){var h=new Wt(c.i,d[g].name,d[g].sname,d[g].img);h.W(e);c.g.listen(h,"click",oa(Rp,d[g].url))}c.a&&F(c.a.element);c.a=new Vt(c.i);c.g.listen(c.a,"click",oa(Qp,b.more));c.a.W(c.element);c.b&&F(c.b.element);c.b=new Xt;Pc(c.b.a,{value:b.url_short});c.b.W(c.element)};f.Wu=function(){};f.oq=function(a){var b=this.a.K().Z;this.ba&&!a&&"detailpage"==b&&this.unload()};
-f.pq=function(){this.b.a.Jg(this.a.Tj());var a=zm(this.a.vb());bn(this.b.a.template,"length",a)};f.im=function(){var a=Cd(this.i.N());X(this.i.N(),"show-tray-panel",560<a.width)};f.$a=function(a){return!!a.vb()};function ju(a){return a.vb()?new iu(a):null}f.H=function(){Df(this.G);this.G=null;iu.C.H.call(this)};var ku=RegExp("^(ar|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Arab|Hebr|Thaa|Nkoo|Tfng))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)","i");function lu(a,b){Fm(a,["html5-async-progress","html5-async-success","html5-async-error"]);b&&V(a,b);Ht(Et.getInstance(),a)};function mu(a,b,c,d){if(this.g=!!c)this.Wk=Math.max(800,this.Wk);this.element=a;this.G=b;this.k=d;nu?a.ontouchstart=v(this.Tv,this):a.onmousedown=v(this.Sv,this);a.onclick=v(this.Gn,this)}var nu="ontouchstart"in document,ou=[],pu=!1;function qu(){nu&&!pu&&(pu=!0,document.addEventListener("click",function(a){for(var b=new A(a.clientX,a.clientY),c=0,d;d=ou[c];c++)if(25>xb(d,b)){a.stopPropagation();a.preventDefault();ou.splice(c,1);break}},!0))}
-function ru(a){ou.push(a);window.setTimeout(function(){var b=ou.indexOf(a);-1!=b&&ou.splice(b,1)},2500)}f=mu.prototype;f.Wk=1E3;
-f.Tv=function(a){if(!(1<a.touches.length||a._stop)){this.a=a._stop=!0;this.g||(this.element.ontouchend=v(this.Gn,this),document.body.addEventListener("touchend",su(this),!1));document.body.addEventListener("touchmove",tu(this),!1);document.body.addEventListener("touchcancel",su(this),!1);uu(this,a);this.F=window.setTimeout(v(this.gi,this,!0),100);var b=a.touches[0];this.b=new A(b.clientX,b.clientY);this.g||this.k&&!this.k(a)||ru(this.b)}};
-f.Sv=function(a){a.stopPropagation();this.a=!0;uu(this,a);this.gi(!0)};f.Gn=function(a){"touchend"==a.type&&!this.a||a._stop||(a._stop=!0,this.gi(!0),window.setTimeout(v(function(){this.yi();this.G(a)},this),0))};f.Lw=function(a){1<a.touches.length?this.yi():(a=a.touches[0],a=new A(a.clientX,a.clientY),this.b&&12<xb(this.b,a)&&this.yi())};function tu(a){a.i||(a.i=v(a.Lw,a));return a.i}
-f.yi=function(){window.clearTimeout(this.F);window.clearTimeout(this.A);this.gi(!1);this.a=!1;document.body.removeEventListener("touchmove",tu(this),!1);document.body.removeEventListener("touchend",su(this),!1);document.body.removeEventListener("touchcancel",su(this),!1)};function su(a){a.j||(a.j=v(a.yi,a));return a.j}f.gi=function(a){this.B&&Hc(this.element,this.B,a)};function uu(a,b){a.o&&(a.A=window.setTimeout(v(function(){this.a=!1;this.o(b)},a),a.Wk))};function vu(a){un.call(this,a);xn(this,15);wu(this)}y(vu,un);function wu(a){wn(a,"ytp-button-fullscreen-enter");var b=a.g.getMsg("YTP_BUTTON_FULLSCREEN_ENTER");a.Hb(b);a.a=b};function xu(){Y.call(this,["div",["ytp-menu","html5-stop-propagation"],"{{content}}"]);this.a=[];this.stopPropagation("click")}y(xu,Y);xu.prototype.add=function(a){for(var b=this.a.length,c=0;c<this.a.length;c++){if(this.a[c]==a)return;if(c<b&&this.a[c].priority<a.priority){b=c;break}}cb(this.a,b,0,a);yu(this)};xu.prototype.remove=function(a){Xa(this.a,a);yu(this)};
-function yu(a){var b;if(1==a.a.length)b=new Y(["div","ytp-menu-content",["div","ytp-menu-row",["div","ytp-menu-cell",a.a[0].label]],["div","ytp-menu-row",["div","ytp-menu-cell","{{content}}"]]]),b.Aa(a.a[0].element);else{b=new Y(["div","ytp-menu-content"]);for(var c=0;c<a.a.length;c++){var d=new Y(["div","ytp-menu-row",["div",["ytp-menu-cell","ytp-menu-title"],a.a[c].label],["div","ytp-menu-cell","{{content}}"]]);d.Aa(a.a[c].element);d.W(b.N())}}a.Aa(b)}xu.prototype.H=function(){this.a=null;xu.C.H.call(this)};function zu(a){un.call(this,a);xn(this,3);Au(this)}y(zu,un);function Au(a){wn(a,"ytp-button-play");var b=a.g.getMsg("YTP_BUTTON_PLAY");a.Hb(b);a.a=b};function Bu(a){Y.call(this,["div","ytp-playlist-controls","{{content}}"]);this.b=new un(a,"ytp-button-prev",a.getMsg("YTP_BUTTON_PREV"),a.getMsg("YTP_BUTTON_PREV"));L(this,this.b);this.a=new un(a,"ytp-button-next",a.getMsg("YTP_BUTTON_NEXT"),a.getMsg("YTP_BUTTON_NEXT"));L(this,this.a);this.Aa([this.b,this.a])}y(Bu,Y);function Cu(a,b,c,d){var e=Math.min(c/(b.Rn/b.mi),d/(b.Qn/b.rows)),g=b.Rn*e,e=b.Qn*e,g=Math.floor(g/b.mi)*b.mi,e=Math.floor(e/b.rows)*b.rows,h=g/b.mi,k=e/b.rows,m=Math.floor((c-h)/2);c=Math.ceil((c-h)/2);var p=Math.floor((d-k)/2);d=-1*b.iu*h;var r=-1*b.row*k;a=a.style;a.width=h+"px";a.height=k+"px";h=p+"px";a.marginTop=h;a.marginBottom=h;a.marginLeft=m+"px";a.marginRight=c+"px";a.backgroundImage="url("+b.url+")";a.backgroundPosition=d+"px "+r+"px";a.a=g+"px "+e+"px"};function Du(){this.b=!1;this.a=new Np(this.dv,250,this);L(this,this.a)}y(Du,K);f=Du.prototype;f.to=!1;f.ud=null;f.cc=null;f.Ph=null;f.Sj=null;f.Uj=null;f.wg=null;f.$d=0;f.wk=0;f.Xk=0;f.Fo=10;f.Nb=0;f.Ai=0;f.Zk=0;f.Uc=null;f.Le=null;f.Oe=0;f.disable=function(){this.to=!0};f.Xa=function(a){this.Oe=a};f.qo=function(a,b){this.cc.style.display="none";for(var c,d,e=a;e<=b;e++)if(d=this.cc.children[e])c=yl(this.Le,e,this.Nb),Cu(d,c,this.Nb,this.Ai);this.cc.style.display=""};
-function Eu(a,b){if(b!=a.Zk){var c=yl(a.Le,b,2*a.Nb),d=Math.round(2*a.Nb),e=Math.round(2*a.Ai);Cu(a.Sj,c,d,e);a.Zk=b}}f.dv=function(){for(var a=this.wk,b=Math.max(Math.floor(a/this.Nb),0),a=Math.min(Math.ceil((a+this.$d)/this.Nb),this.Uc.a[0].b-1);b<=a;b++){for(var c=this.Le,d=b,e=al(c.a,2*this.Nb),g=void 0,h=void 0;0<=e;e--)if(g=c.a.a[e],h=Math.floor(d/(g.a*g.g)),!g.i[h]){var g=c,k=e,m=k+"-"+h;g.i[m]||(g.i[m]=!0,vl(g.g,k,{nn:k,on:h}))}zl(c)}};
-function Fu(a,b){a.Fo=Math.min(10,Math.ceil(a.$d/72));a.Nb=Math.floor(a.$d/a.Fo);a.Ai=0.555*a.Nb;a.Xk=a.Nb*a.Uc.a[0].b;Bd(a.cc,a.Xk);var c=Math.round(2*a.Nb),d=0.555*c+12;Ad(a.Ph,c,d);pd(a.Ph,(a.$d-c)/2);a.ud.style.height=qd(d+20,!0);b&&(a.qo(0,a.Uc.a[0].b-1),Eu(a,a.Zk),a.b=!0)}f.H=function(){this.wg=this.Uj=this.Sj=this.Ph=this.cc=this.ud=this.Le=this.Uc=null;Du.C.H.call(this)};function Gu(a,b,c,d){this.width=b;this.a=c;this.i=d;this.b=b-c-d;this.g=wb(a-c,0,this.b);this.position=this.g+c;this.td=this.g/this.b};function Hu(){Y.call(this,["div",["ytp-progress-magnifier","html5-draggable"],["div","ytp-progress-magnifier-play-progress"],["div","ytp-progress-magnifier-load-progress"],["div","ytp-progress-magnifier-scrubber-button"]]);this.i=this.template.a["ytp-progress-magnifier-load-progress"];this.F=0;this.k=this.template.a["ytp-progress-magnifier-play-progress"];this.B=0;this.b=[];this.g=this.template.a["ytp-progress-magnifier-scrubber-button"]}y(Hu,Y);
-function Iu(a,b){var c=a.a,d=c.width-4,e=d-2*a.Oe;if(ga(b))var d=Ju(a).position,g=a.N().offsetWidth/2,d=wb(b,d-g,d+g);else d=2+c.td*d;return new Gu(d,c.width,2+c.td*e,2+(1-c.td)*e)}function Ju(a){var b=a.a;a=a.N().offsetWidth/2+2;return new Gu(b.position,b.width,a,a)}Hu.prototype.disable=function(){this.a=null};
-function Ku(a,b){if(a.a){var c=a.N(),d=Ju(a),e=Iu(a),g=c.offsetWidth/2,h=d.position-g,d=d.position+g;c.style.left=h+"px";var k=a.F*e.b+e.a,m=a.B*e.b+e.a,p=a.g.offsetWidth,r=m-h-p/2;r>-p&&r<2*g+p?(a.g.style.left=r+"px",cn(a.g)):dn(a.g);m-=h;0<=m?(Bd(a.k,Math.min(m,2*g)),cn(a.k)):dn(a.k);k-=h;0<=k?(Bd(a.i,Math.min(k,2*g)),cn(a.i)):dn(a.i);if(b){g=(h-e.a)/2/60;e=(d-e.a)/2/60;h=0;for(d=Math.ceil(g);d<=e;d++)h<a.b.length?k=a.b[h]:(k=document.createElement("div"),a.b[h]=k,c.appendChild(k)),k.className=
-0==d%60?"ytp-progress-magnifier-60m":0==d%30?"ytp-progress-magnifier-30m":0==d%15?"ytp-progress-magnifier-15m":"ytp-progress-magnifier-1m",k.style.left=120*(d-g)+"px",h++;for(;h<a.b.length;)F(a.b.pop())}}}Hu.prototype.Xa=function(a){this.Oe=a;Ku(this,!0)};Hu.prototype.H=function(){this.g=this.b=this.k=this.i=null;Hu.C.H.call(this)};function Lu(){}y(Lu,K);f=Lu.prototype;f.bi=!1;f.Oe=0;f.Fb=null;f.Dh=null;f.Wj=null;f.lj=null;f.Gg=null;f.bh=null;f.disable=function(){this.bi=!0};f.show=function(){this.bi||Hn(this.Fb)};f.hide=function(){In(this.Fb)};f.Xa=function(a){this.Oe=a};f.reset=function(){W(this.Fb,"with-thumbnail");this.bh=this.Gg=null};f.Nu=function(a,b){(a<=this.a||this.a<=b)&&Mu(this)};function Mu(a){var b=yl(a.bh,a.a,108);Cu(a.Wj,b,108,60)}f.H=function(){this.lj=this.Wj=this.Dh=this.Fb=this.bh=this.Gg=null;Lu.C.H.call(this)};function Nu(a){R.call(this);this.kb=a;this.va=null;this.J={};this.aa=Infinity;this.Y=this.V=this.L=null;this.ja=0;this.o=this.g=this.G=null;this.k=new Ko(this);this.Va="";this.Ra=null;this.ha=0;this.Ka=null;this.xa=0;this.a=this.b=this.jb=this.i=this.Q=this.da=null;this.za=new Ko(this);this.pa=null;this.Ca=new Ko(this);this.A=this.I=!1;this.O=this.P=this.ga=null;this.j=this.Sa=this.la=this.B=0;this.Ma=""}y(Nu,R);
-function Ou(a,b){a.g=b;a.i=E("html5-progress-bar",a.g);a.k.listen(a.i,"click",a.Lh);Lo(a.k,a.i,"down",a.vv);a.Va=Lo(a.k,a.i,"over",a.bn);a.Q=E("html5-progress-list",a.i);a.Ka=E("html5-play-progress",a.Q);a.Ra=E("html5-load-progress",a.Q);a.da=E("html5-highlight",a.Q);a.va=E("html5-ad-progress-list",a.i);a.pa=E("html5-scrubber-button",a.i);a.V=E("html5-clip-exclusion",a.i);a.Y=a.V.cloneNode(!1);a.V.parentNode.appendChild(a.Y);a.G=E("html5-clip-start",a.i);Lo(a.k,a.G,"over",a.To);Lo(a.k,a.G,"out",a.So);
-a.k.listen(a.G,"click",a.dl);a.L=E("html5-clip-end",a.i);Lo(a.k,a.L,"over",a.To);Lo(a.k,a.L,"out",a.So);a.k.listen(a.L,"click",a.dl);a.jb=E("html5-progress-screenreader",a.i)}f=Nu.prototype;
-f.bn=function(a){if(!this.I){this.k.ac(this.Va);this.A=!1;this.P=this.ga=a=new A(sf(a),tf(a));if(this.a&&5400<=this.B){I(this.la);this.a.show();Hn(this.da);a=this.a;var b=Pu(this);a.a=b;Ku(a,!0);a=oa(V,this.g,"html5-progress-magnifier-hover");this.la=H(a,0)}this.b&&this.b.show();Lo(this.za,this.g,"move",this.jn);Lo(this.za,this.g,"out",this.Dt)}};function Qu(a){a.A=!1;I(a.la);W(a.g,"html5-progress-magnifier-hover");var b=hp(a.a.N());a.la=H(v(function(){this.a.hide();In(this.da)},a),b)}
-f.Dt=function(a){this.I||a.relatedTarget&&!(this.b&&cd(this.b.Fb,a.relatedTarget)||!cd(this.g,a.relatedTarget))||Ru(this)};
-f.jn=function(a){var b=new A(sf(a),tf(a));if(this.a&&this.a.a)if(this.I)this.A?this.O=b:this.P=b;else{var c=Ed(this.a.N());if(c.contains(b))this.O=b,this.A=!0;else{var d=Ed(this.Q),e=this.ga.y-tf(a);if(sf(a)>=c.left&&tf(a)>=c.top&&sf(a)<c.left+c.width||d.contains(b)){c=6*e-6;if(sf(a)>=this.ga.x-c&&sf(a)<=this.ga.x+c)return;this.A=!1;this.ga=this.P=b}else{Ru(this);return}}}else this.P=b;Su(this)};
-function Su(a){if(a.a&&a.a.a){var b=Ed(a.a.N());if(a.I&&a.A){var c=b.left,b=c+b.width;a.j=c>a.O.x?a.O.x-c:b<a.O.x?a.O.x-b:0}c=a.a;b=Pu(a);c.a=b;Ku(c,!0);var d=a.a,c=Iu(d),b=Ju(d),d=d.N().offsetWidth,e=b.position-d/2,c=new Gu(c.position,d,c.a-e,c.i-(b.width-e-d)),b=Math.max(c.width/c.b,0.015);a.da.style.left=Math.round(1E3*((c.width/2-c.a)/c.b-b/2))/10+"%";a.da.style.width=Math.round(1E3*b)/10+"%"}a.b&&(c=a.b,a=Tu(a),c.bi||(b=c.Fb.offsetWidth/2,d=new Gu(a.position,a.width,b,b),c.Fb.style.left=d.position-
-b+"px",b=c.Dh.offsetWidth/2,d=new Gu(a.position,a.width,b,b),c.Dh.style.left=d.position-c.Fb.offsetLeft-b+"px",dd(c.lj,Dn(a.td*c.Oe)),c.Gg&&(a=$k(c.Gg,a.td),a!=c.a&&(c.a=a,Mu(c)))))}f.Nw=function(){var a;if(0>this.j)a=0.15*this.j-0.1,this.j-=a,0<this.j&&(this.j=0);else if(0<this.j)a=0.15*this.j+0.1,this.j-=a,0>this.j&&(this.j=0);else return;var b=ud(this.g).x;this.P.x=wb(this.P.x+a,b,b+Pu(this).width);Su(this);a=Tu(this);Uu(this,a.td,this.ha);this.u("seekto",a.td*this.B,!1)};
-function Ru(a){a.za.removeAll();a.b&&a.b.hide();a.a&&a.a.a&&(a.a.disable(),Qu(a));a.Va=Lo(a.k,a.i,"over",a.bn)}f.vv=function(a){a.stopPropagation();a.preventDefault();this.b&&this.b.hide();this.a&&this.a.a&&Qu(this);Vu(this);this.Lh(a)};f.Zs=function(a){a.stopPropagation();a.preventDefault();this.A=!0;Vu(this);this.Lh(a)};function Vu(a){a.I=!0;a.u("beginseeking");Lo(a.Ca,document,"move",a.Lh);Lo(a.Ca,document,"up",a.Ow);a.A&&(a.Sa=hf(v(a.Nw,a),20))}
-f.Ow=function(a){a.stopPropagation();this.I=!1;this.Ca.removeAll();jf(this.Sa);Ru(this);this.u("endseeking")};f.Lh=function(a){a.stopPropagation();a.preventDefault();this.jn(a);a=this.A?Tu(this):Pu(this);var b=a.td*this.B;Uu(this,a.td,this.ha);(b<this.ja||b>this.aa)&&this.dl();this.u("seekto",b,!this.I)};function Tu(a){return a.a&&a.a.a?a.A?Iu(a.a,a.O.x-ud(a.g).x):Iu(a.a):Pu(a)}function Pu(a){return new Gu(a.P.x-ud(a.g).x,a.Q.clientWidth,a.pa.clientWidth/2,a.pa.clientWidth/2)}
-function Wu(a,b,c){Uu(a,q(b)&&!a.I?b:a.xa,q(c)?c:a.ha)}function Uu(a,b,c){a.xa=b;var d=Math.round(1E3*b)/10,e;if(!a.Ma&&(e=a.Ka,a.Ma="transform",void 0===e.style.transform)){var g=(gc?"Webkit":fc?"Moz":C?"ms":ec?"O":null)+"Transform";void 0!==e.style[g]&&(a.Ma=g)}e=a.Ma;a.Ka.style[e]="scalex("+b+")";a.pa.style.left=d+"%";a.ha=Math.max(a.xa,c);a.Ra.style[e]="scalex("+a.ha+")";a.a&&(a=a.a,a.B=b,a.F=c,Ku(a,!1))}f.Xa=function(a){this.B=a;Xu(this);this.a&&this.a.Xa(a)};
-function Xu(a){var b=0<a.ja,c=0<a.B&&a.aa<a.B;X(a.G,"html5-clip-enabled",b);X(a.V,"html5-clip-enabled",b);X(a.L,"html5-clip-enabled",c);X(a.Y,"html5-clip-enabled",c);b&&(a.G.style.left=100*a.ja/a.B+"%",a.V.style.width=a.G.style.left);c&&(b=Math.min(100,100*a.aa/a.B),a.L.style.left=b+"%",a.Y.style.left=b+"%",a.Y.style.width=100-b+"%")}f.To=function(){V(this.g,"html5-clip-marker-hover")};f.So=function(){W(this.g,"html5-clip-marker-hover")};
-f.dl=function(a){a&&a.stopPropagation();this.ja=0;Xu(this);this.aa=Infinity;Xu(this)};function Yu(a,b){b=wb(Math.round(100*b),0,100);if(!a.J[b]){var c=document.createElement("div");100<=b?(c.style.left="auto",c.style.right="0%"):c.style.left=b+"%";Em(c,["html5-ad-progress","html5-progress-section"]);a.va.appendChild(c);a.J[b]=c}}function Zu(a,b){b=wb(Math.round(100*b),0,100);a.J[b]&&(F(a.J[b]),a.J[b]=null)}
-f.H=function(){I(this.la);jf(this.Sa);this.k.removeAll();this.za.removeAll();this.Ca.removeAll();this.va=null;this.J={};this.pa=this.jb=this.Q=this.i=this.Ka=this.Ra=this.g=this.G=this.Y=this.V=this.L=null;Nu.C.H.call(this)};function $u(a,b,c){Y.call(this,["div","ytp-drop-down","{{content}}"]);this.F=a;this.g=!1;this.k=0;this.a=new Y(["div","ytp-drop-down-menu","{{content}}"]);L(this,this.a);this.b=new un(this.F,"ytp-drop-down-label");L(this,this.b);this.listen(this.b,"click",this.B);this.i=new Y(["div","ytp-drop-down-label-content","{{content}}"]);L(this,this.i);this.b.Aa([this.i,["div","ytp-drop-down-arrow"]]);this.Aa([this.a,this.b]);this.stopPropagation("click");q(b)&&this.Hb(b);q(c)&&(this.a.Aa(c),av(this));av(this)}
-y($u,Y);$u.prototype.Hb=function(a){this.i.Aa(a);av(this)};$u.prototype.o=function(){this.g=!1;av(this)};$u.prototype.B=function(){this.g=!this.g;av(this)};function bv(a,b){b>a.k&&(a.k=b,a.element.style.minWidth=a.k+"px")}function av(a){a.g?(a.a.show(),a.listen(window,"blur",a.o,a,"menu"),a.listen(document,"click",a.o,a,"menu")):(a.a.hide(),fn(a,"menu"));var b=Cd(a.b.N());a.a.N().style.bottom=b.height-1+"px";bv(a,b.width)}$u.prototype.H=function(){this.F=null;$u.C.H.call(this)};function cv(a){un.call(this,a,"ytp-drop-down-menu-button");this.i=new Y(["div","ytp-drop-down-menu-button-check"]);L(this,this.i)}y(cv,un);cv.prototype.Aa=function(a){cv.C.Aa.call(this,[this.i,a])};cv.prototype.Za=function(a){X(this.element,"ytp-drop-down-menu-button-selected",a)};function dv(a){Y.call(this,["span"]);this.element.innerHTML=a}y(dv,Y);function ev(a){ss.call(this);this.g=a;this.j={};this.a=[];this.k=new Y(["div","ytp-menu-drop-down-content"]);L(this,this.k);this.b="auto";this.i=!0;this.label=this.g.getMsg("YTP_QUALITY_TITLE");this.element=new $u(a,void 0,this.k);L(this,this.element);bv(this.element,100);fv(this,this.b,this.b);this.priority=-1}y(ev,ss);function gv(a,b){if(!jb(a.a,b)){for(var c=0;c<a.a.length;c++)hv(a,a.a[c]).ve();a.a=[];z(b,function(a){this.a.push(a);var b=hv(this,a);b.Za(a==this.b);b.W(this.k.N())},a)}}
-function hv(a,b){var c=a.j[b];if(c)return c;c=new cv(a.g);L(a,c);a.j[b]=c;c.Aa(new dv(iv(a,b)));c.listen(c.N(),"click",v(a.o,a,b));return c}ev.prototype.Re=function(){return this.b};function fv(a,b,c){hv(a,a.b).Za(!1);hv(a,b).Za(!0);a.b=b;a.i="auto"==c;a.i&&c!=b?a.element.Hb(jv(a,b)):a.element.Hb(new dv(iv(a,c)))}function iv(a,b){return a.g.getMsg("YTP_QUALITY_"+b.toUpperCase())}function jv(a,b){var c=a.g.getMsg("YTP_QUALITY_AUTO_WITH_QUALITY",{video_quality:iv(a,b)});return new dv(c)}
-ev.prototype.o=function(a){this.element.o();this.i&&"auto"==a||(fv(this,a,a),Ef(this.element,"change"))};ev.prototype.H=function(){this.j={};this.a=[];this.g=null;ev.C.H.call(this)};function kv(a){xt.call(this,a,"ytp-settings-button",a.getMsg("YTP_TOOLTIP_SETTINGS"),"ytp-settings-button-active");xn(this,10);this.i=new Y(["div","ytp-settings-hd-quality-badge"]);L(this,this.i);this.Aa(this.i);this.i.hide()}y(kv,xt);function lv(a){ss.call(this);this.label=a.getMsg("YTP_PLAYER_SIZE_TITLE");this.element=new ts(a,["ytp-size-control-small","ytp-size-control-large"],!0);L(this,this.element);this.priority=0}y(lv,ss);lv.prototype.getSelected=function(){return this.element.getSelected()};lv.prototype.Za=function(a){this.element.Za(a)};function mv(a){ss.call(this);this.b=a;this.i={};this.a=[];this.g=1;this.j=new Y(["div","ytp-menu-drop-down-content"]);L(this,this.j);this.label=this.b.getMsg("YTP_PLAYER_SPEED_TITLE");this.element=new $u(a,void 0,this.j);L(this,this.element);bv(this.element,100);this.priority=1}y(mv,ss);function nv(a,b){if(!jb(a.a,b)){for(var c=0;c<a.a.length;c++)ov(a,a.a[c]).ve();a.a=[];z(b,function(a){this.a.push(a);var b=ov(this,a);b.Za(a==this.g);b.W(this.j.N())},a)}}
-function ov(a,b){var c=a.i[b];if(c)return c;c=new cv(a.b);L(a,c);a.i[b]=c;c.Aa(pv(a,b));c.listen(c.N(),"click",v(a.k,a,b));return c}function qv(a,b){ov(a,a.g).Za(!1);ov(a,b).Za(!0);a.g=b;a.element.Hb(pv(a,b))}function pv(a,b){return 1==b?a.b.getMsg("YTP_PLAYER_SPEED_NORMAL"):b.toString()}mv.prototype.k=function(a){this.element.o();qv(this,a);Ef(this.element,"change")};mv.prototype.H=function(){this.i={};this.a=[];this.b=null;mv.C.H.call(this)};function rv(){Y.call(this,["div",["ytp-time-display","html5-control"],["span","ytp-time-current","{{current}}"],["span","ytp-time-separator"," / "],["span","ytp-time-duration","{{duration}}"],["span","ytp-time-live-badge","Live"]]);this.a=this.template.a["ytp-time-live-badge"]}y(rv,Y);rv.prototype.Xa=function(a){bn(this.template,"duration",Dn(a))};rv.prototype.H=function(){this.a=null;rv.C.H.call(this)};function sv(a){R.call(this);this.j=a;this.a=new Ko(this);this.O=new Ko(this);this.B=null;this.A={};this.G={};this.J=this.I=this.i=this.g=this.b=null;this.L=new Ko(this)}y(sv,R);f=sv.prototype;f.mf=null;f.wc=null;f.Ee=null;f.oj=null;f.Sd=null;f.sc=null;f.kf=null;f.Wb=null;f.jg=null;f.Pd=null;f.se=null;f.Ah=null;f.nd=null;f.lf=null;f.te=null;f.tn=!1;f.ig=null;f.ub=null;
-function tv(a,b){a.mf=b;var c=E("html5-player-chrome",b);a.wc=new zu(a.j);a.wc.W(c,0);L(a,a.wc);new mu(a.wc.N(),v(a.Nt,a),!1,function(){return!0});a.Ee=new Bu(a.j);a.Ee.W(c,1);L(a,a.Ee);a.a.listen(a.Ee.a,"click",oa(a.u,"nextvideo"));a.a.listen(a.Ee.b,"click",oa(a.u,"previousvideo"));var d=E("html5-progress-bar-container",b);a.oj=new Nu(a.j);Ou(a.oj,d);a.k=new rv;a.k.W(c,4);L(a,a.k);a.a.listen(a.k.a,"click",oa(a.u,"seekto",Infinity));a.Sd=E("html5-volume-control",b);a.a.listen(a.Sd,"keydown",a.Ot);
-a.sc=E("html5-volume-button",a.Sd);a.a.listen(a.sc,"click",a.wn);a.kf=E("html5-volume-panel",a.Sd);a.Wb=E("html5-volume-slider",a.Sd);Lo(a.a,a.Wb,"down",a.Kt);a.jg=E("html5-volume-slider-foreground",a.Sd);a.Ah=E("html5-threed-popup-menu",b);a.se=E("html5-small-player-button",b);a.a.listen(a.se,"click",a.vn);a.Pd=E("html5-large-player-button",b);a.a.listen(a.Pd,"click",a.vn);a.o=new vu(a.j);a.o.W(c,7);L(a,a.o);a.a.listen(a.o,"click",a.Jt);a.nd=E("html5-quality-button",b);a.te=E("html5-quality-popup-menu",
-a.nd);Mo(a.a,a.te,a.Ht);a.lf=E("html5-speed-popup-menu",a.nd);Mo(a.a,a.lf,a.It);a.ub=E("html5-watch-later-button",b);a.a.listen(a.ub,"click",a.Lt);a.ub&&$t(a.j,a.ub,a.j.getMsg("YTP_TOOLTIP_WATCH_LATER"),!0);a.ig=E("html5-watch-on-youtube-button",b);a.a.listen(a.ig,"click",a.Mt)}f.disable=function(a){uv(this,a,!0)};f.enable=function(a){uv(this,a,!1)};
-function uv(a,b,c){for(var d=0;d<b.length;d++)switch(b[d]){case "audio":X(a.mf,"disabled-control-audio",c);break;case "play_pause":var e=a.wc;c?e.disable():e.enable();break;case "seek":X(a.mf,"disabled-control-seek",c)}}function vv(a,b){if(a.b)gv(a.b,b),b.length?wv(a,a.b):xv(a,a.b);else{var c=Nc("yt-uix-button-menu-item",a.te);z(c,function(a){a.style.display="none";for(var c=0,g=b.length;c<g;c++)G(a,"value")==b[c]&&(a.style.display="list-item")},a);c=!!b.length;Fn(a.te,c);Fn(a.nd,c)}}
-f.Ot=function(a){var b=a.keyCode;if(32==b||13==b)this.wn(),a.preventDefault()};f.Xa=function(a){this.k.Xa(a)};function yv(a,b,c){a.b?(fv(a.b,b,c),c=a.B,0==b.indexOf("hd")||"highres"==b?c.i.show():c.i.hide()):a.te&&(a=a.te,zv(a,"active",b),zv(a,"selected",c||b))}function zv(a,b,c){var d=E("yt-uix-button-menu-item."+b,a);d&&W(d,b);a=a.querySelector(".yt-uix-button-menu-item"+('[data-value="'+c+'"]'));V(a,b)}f.wn=function(){this.u("mutetoggled")};
-function Av(a,b){if(b){if(a.tn){var c=a.wc;wn(c,"ytp-button-stop");var d=c.g.getMsg("YTP_BUTTON_STOP")}else c=a.wc,wn(c,"ytp-button-pause"),d=c.g.getMsg("YTP_BUTTON_PAUSE");c.Hb(d);c.a=d}else Au(a.wc)}f.Nt=function(){this.u("playpausetoggled")};f.Kt=function(a){this.u("beginvolume");V(this.sc,"changing");var b=this.Wb.clientWidth;a=100*(wd(a,this.Wb).x/b);Bv(this,a);Lo(this.O,document,"move",this.Zw);Lo(this.O,document,"up",this.$w)};
-f.Zw=function(a){var b=this.Wb.clientWidth,b=100*(wd(a,this.Wb).x/b);Bv(this,b);a.preventDefault()};function Bv(a,b){var c={volume:wb(b,0,100),muted:!1};a.u("volumechanged",c)}f.$w=function(){W(this.sc,"changing");this.O.removeAll();this.u("endvolume")};f.vn=function(a){this.u("sizechangerequested",a.currentTarget==this.Pd)};f.Ht=function(a){a=G(a.currentTarget,"value");this.u("qualitychanged",a)};f.Jt=function(){this.u("fullscreentoggled")};
-function Cv(a,b){if(a.i)qv(a.i,parseFloat(b));else if(a.lf){var c=a.lf;zv(c,"active",b);zv(c,"selected",b)}}function wv(a,b){var c=a.G.__default__;c&&c.add(b)}function xv(a,b){var c=a.G.__default__;c&&c.remove(b)}function Dv(a,b,c,d){a.A[b]||(a.A[b]=c,d=d||a.B.N(),d.parentNode&&d.parentNode.insertBefore(c.N(),d.nextSibling),c.listen(c,"click",oa(a.Mw,b),a,"menuButtonClick"),c=new xu,L(a,c),c.hide(),c.W(a.mf),a.G[b]=c)}
-f.It=function(a){a=G(a.currentTarget,"value");this.u("speedchanged",parseFloat(a));Cv(this,a)};f.Lt=function(){Dm(this.ub,"html5-async-progress")||(lu(this.ub,"html5-async-progress"),this.u("watchlater"))};f.Mt=function(){this.u("watchonyoutube")};f.yg=function(){this.L.removeAll();this.I&&(this.I.hide(),this.I=null);this.J&&(Bt(this.J),this.J=null)};
-f.Mw=function(a,b){b.stopPropagation();var c=this.A[a];if(c)if(c.b)this.yg();else{var d=this.G[a];this.yg();this.I=d;this.I.show();c&&(this.J=c,At(this.J));this.L.listen(window,"blur",this.yg);this.L.listen(document,"click",this.yg)}};f.er=function(){this.u("qualitychanged",this.b.Re())};f.gr=function(){this.u("sizechangerequested",1==this.g.getSelected())};f.hr=function(){this.u("speedchanged",this.i.g)};
-f.dr=function(a){var b=a.target,c="unknown",c=b==this.wc.N()?"playpause":b==this.sc||b==this.kf||b==this.Wb||b==this.Sd||b==this.jg?"volume":b==this.k?"time":b==this.nd?"settings":b==this.B?"settings-redesign":b==this.ub?"watchlater":b==this.ig?"youtube":b==this.o.N()?"fullscreen":b==this.se||b==this.Pd?"size":a.target;this.u("controlclick",c)};
-f.H=function(){this.a.removeAll();this.O.removeAll();this.L.removeAll();this.yg();this.ub=this.ig=this.nd=this.Ah=this.te=this.lf=this.se=this.Pd=this.jg=this.Wb=this.kf=this.sc=this.Sd=this.mf=null;for(var a in this.A){var b=this.A[a];b.ve();fn(b,"menuButtonClick")}this.A={};this.G={};this.B=this.i=this.g=this.b=null;sv.C.H.call(this)};var Ev=["left","right","center"],Fv={id:0,priority:0,anchorPoint:7,ci:50,ny:80,de:95,zd:15,mk:100,isVisible:!0,textAlign:Ev[2],Ke:0,backgroundColor:"#080808",ai:"#fff",fy:1,Al:1},Gv={id:99,priority:1,anchorPoint:0,ci:5,de:7,zd:2,mk:32,textAlign:Ev[0]},Hv=["CA","MX","US"];function Iv(a){a=a||Fv;w(this,a)}f=Iv.prototype;f.anchorPoint=7;f.ci=50;f.de=95;f.ny=80;f.Ke=0;f.textAlign="center";f.backgroundColor="#080808";f.ai="#fff";f.fy=1;f.Al=1;f.zd=15;f.mk=32;f.isVisible=!0;f.fontFamily='"Arial Unicode Ms", Arial';f.ix="100%";function Jv(a,b){this.id=a;this.ta=new Iv(b);var c="caption-window";0==this.id&&(c="standard-caption-window");this.oa=Uc("div",{id:"caption-window-"+this.id,"class":c});this.Bb=Uc("span",{"class":"captions-text",style:"visibility: hidden"});this.Bb.innerHTML="C";this.ma=Uc("span",{"class":"captions-text",tabindex:"4","aria-live":"assertive"});this.Ri=Uc("div",{"class":"caption-window-transform"});this.Ri.appendChild(this.ma);this.oa.appendChild(this.Ri)}f=Jv.prototype;f.id=0;f.ta=null;f.$g="";
-f.Gc=null;f.oa=null;f.Ri=null;f.ma=null;f.Bb=null;f.type=1;f.getType=function(){return this.type};f.Mi=function(){var a;this.Bb.style.fontFamily=this.ma.style.fontFamily;this.oa.appendChild(this.Bb);a=this.Bb.offsetHeight;this.oa.removeChild(this.Bb);return a};f.Pf=function(){this.ma&&(0!=this.id&&(Bd(this.oa,"100%"),Bd(this.oa,this.ma.offsetWidth)),Kv(this),Fn(this.oa,this.ta.isVisible))};
-function Kv(a){pd(a.oa,a.ta.ci+"%",a.ta.de+"%");for(var b=0;8>=b;b++)W(a.oa,"anchor-point-"+b);V(a.oa,"anchor-point-"+a.ta.anchorPoint)}f.Lo=function(a){var b=[];z(a,function(a){a.Qi?b[b.length-1]+=a.ce:b.push(a.ce)});this.Te(b.join("\n"));this.Gc=a};f.Te=function(a){this.$g=a=Lv(a);this.ma.innerHTML=this.$g;this.Bl();this.Pf()};
-f.Bl=function(){this.oa.style.textAlign=this.ta.textAlign;this.ma.style.backgroundColor=this.ta.backgroundColor;this.ma.style.color=this.ta.ai;this.ma.style.opacity=this.ta.Al;this.ma.style.fontFamily=this.ta.fontFamily;this.ma.style.fontSize=this.ta.ix;1==this.ta.Ke?this.ma.setAttribute("dir","rtl"):this.ma.removeAttribute("dir")};f.toString=function(){var a="Caption window ("+this.id+"): "+this.$g,b;for(b in this.ta)a+=b+" "+this.ta[b]+" | ";return a};
-function Lv(a){a=a.split("\n");for(var b=0,c=a.length;b<c;b++)a[b]=a[b]?"&nbsp;"+a[b]+"&nbsp;":"";return a.join("<br>")}f.Ti=function(){this.Gc=[];this.Te("")};function Mv(a,b){Jv.call(this,a,b);this.ma.style.display="block";this.ma.style.padding="0";this.Qb=[];var c=this.ma;W(c,"captions-text");V(c,"caption-painton-text-rows")}y(Mv,Jv);f=Mv.prototype;f.type=0;f.Vn="";f.Zg=!1;f.yb=null;f.Qb=null;f.Mi=function(){return this.Qb[0]?this.Qb[0].offsetHeight:0};function Nv(a){return a.Qb.reduce(function(a,c){return Math.max(a,c.offsetWidth)},0)}
-f.Pf=function(){0!=this.id&&(Bd(this.oa,"100%"),Bd(this.oa,this.Zg?Nv(this):this.yb.width));var a=Math.round(this.ta.zd*this.Mi());this.oa.style.maxHeight=a+"px";Kv(this);Fn(this.oa,this.ta.isVisible)};
-f.Te=function(a){this.Ti();a=Lv(a);this.Zg||(this.$g=a);a=a.split("<br>");for(var b=0,c=a.length;b<c;b++)if(a[b]){var d=Uc("div",{"class":"caption-row-holder"}),e=Uc("span",{"class":"caption-row captions-text"});d.appendChild(e);e.innerHTML=a[b];this.Zg||(this.ma.style.height=this.yb.height+"px",this.ma.style.width=this.yb.width+"px",d.style.position="absolute",d.style.top=this.yb.Un[b]+"px",d.style.left=this.yb.Tn[b]+"px");this.ma.appendChild(d);this.Qb.push(e)}this.Bl();this.Pf()};
-f.Ti=function(){for(var a=0,b=this.Qb.length;a<b;a++){var c=jd(this.Qb[a],"caption-row-holder");F(c)}this.Qb=[]};f.Bl=function(){this.oa.style.textAlign=this.ta.textAlign;for(var a=0,b=this.Qb.length;a<b;a++)this.Qb[a].style.backgroundColor=this.ta.backgroundColor;this.ma.style.color=this.ta.ai;this.ma.style.opacity=this.ta.Al;this.ma.style.fontFamily=this.ta.fontFamily;1==this.ta.Ke?this.ma.setAttribute("dir","rtl"):this.ma.removeAttribute("dir")};function Ov(a,b){Jv.call(this,a,b);this.Gc=[];this.je=[];this.Ab=[];this.Qf=new Fi(433);this.Qf.stop();J(this.Qf,"tick",v(this.nx,this))}y(Ov,Jv);f=Ov.prototype;f.type=2;f.kx=32;f.Ab=null;f.ke=0;f.je=null;f.Qf=null;f.Pf=function(){Bd(this.oa,"100%");var a=this.oa.offsetWidth,a=Math.min(Pv(this),a);Bd(this.oa,a+"px");Bd(this.Ri,"100%");this.ma.style.whiteSpace="nowrap";Kv(this);Fn(this.oa,this.ta.isVisible)};
-f.Lo=function(a){var b=a.length;if(0>=b)this.Ti();else{for(var c=0;c<b&&0<=this.Gc.indexOf(a[c]);)c++;this.Gc=this.Gc.concat(a.slice(c));Qv(this)}};f.Ti=function(){this.Gc=[];this.Ab=[];this.ke=0;this.Ab=[];this.je=[];Rv(this)};
-function Qv(a){if(!Sv(a))if(a.ke>=a.Gc.length)Rv(a);else{var b=a.Ab.length-1;0>b&&(a.je.push(0),a.ke=0,a.Ab.push(""),b=0);for(var c=a.Gc.length,d=a.ke;d<c;d++){var e=a.Gc[d];if("\n"==e.ce){a.ke++;a.je[b]++;break}if(e.Qi||0==a.Ab[b].length)a.Ab[b]+=e.ce,a.ke++,a.je[b]++;else break}Rv(a);d<c&&!Sv(a)&&(b=a.Mi(),V(a.ma,"caption-rollup"),a.oa.style.overflow="hidden",a.ma.style.top=-b+"px",a.Qf.start())}}function Sv(a){return a.Qf.Tc||Dm(a.ma,"caption-rollup")}
-f.nx=function(){this.oa.style.overflow="visible";this.ma.style.top=0;this.Qf.stop();W(this.ma,"caption-rollup");this.Ab.push("");this.je.push(0);Qv(this)};function Rv(a){if(!Sv(a)){for(;a.Ab.length<a.ta.zd;)a.Ab.unshift(""),a.je.unshift(0);for(;a.Ab.length>a.ta.zd;){a.Ab.shift();var b=a.je.shift();0<b&&(a.ke-=b,a.Gc.splice(0,b))}a.Te(a.Ab.join("\n"))}}
-function Pv(a){a.Bb.style.fontFamily=a.ma.style.fontFamily;a.Bb.style.fontSize=a.ma.style.fontSize;a.ma.appendChild(a.Bb);a.Bb.innerHTML="\u2014";var b=a.Bb.offsetWidth;a.Bb.innerHTML="&nbsp;";b=2*a.Bb.offsetWidth+b*a.kx;a.ma.removeChild(a.Bb);return b};function Tv(a){this.a=a.lk;this.i=a.priority;this.Dc=a.Dc||this.Dc}Tv.prototype.a=0;Tv.prototype.i=0;Tv.prototype.Dc=0;Tv.prototype.toString=function(){return this.a+", "+this.Dc};function Uv(a){Tv.call(this,a);this.ce=a.text||this.ce;this.Wh=a.windowId||this.Wh;this.Qi=a.params.append||this.Qi;this.Fp=a.params.row||this.Fp;this.Ep=a.params.mx||this.Ep}y(Uv,Tv);f=Uv.prototype;f.ce="";f.Qi=!1;f.Fp=0;f.Ep=0;f.Wh=0;f.toString=function(){return this.a+", "+this.Dc+": "+this.ce};
-function Vv(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={lk:c,Dc:d,text:b,windowId:e,priority:5,params:{}};a.getAttribute("r")&&(b.params.row=parseInt(a.getAttribute("r"),10));a.getAttribute("c")&&(b.params.mx=parseInt(a.getAttribute("c"),10));
-a.getAttribute("append")&&(b.priority=6,b.params.append=!0);return new Uv(b)}function Wv(a){Tv.call(this,a);this.id=a.windowId||this.id;this.params=a.params}y(Wv,Tv);Wv.prototype.id=0;Wv.prototype.params=null;Wv.prototype.g="";Wv.prototype.b=!1;function Xv(){return new Wv({lk:-2147483648,Dc:4294967295,params:Fv})};function Yv(a){if("undefined"!=typeof DOMParser)return(new DOMParser).parseFromString(a,"application/xml");if("undefined"!=typeof ActiveXObject){var b=new ActiveXObject("MSXML2.DOMDocument");if(b){b.resolveExternals=!1;b.validateOnParse=!1;try{b.setProperty("ProhibitDTD",!0),b.setProperty("MaxXMLSize",2048),b.setProperty("MaxElementDepth",256)}catch(c){}}b.loadXML(a);return b}throw Error("Your browser does not support loading xml documents");};function Zv(a){this.b=[];this.g=[];this.a={};if(a&&(a=Yv(a))&&a.firstChild)switch(this.i=a,this.i.firstChild.tagName){case "timedtext":a=this.i.firstChild.childNodes;for(var b=0,c=a.length;b<c;b++)switch(a[b].tagName){case "window":var d=a[b],e=parseInt(d.getAttribute("id"),10),g=void 0;t:{var h=this.a[e];if(d.getAttribute("t")||d.getAttribute("start")){g=parseInt(d.getAttribute("t"),10);d.getAttribute("start")&&(g=1E3*parseFloat(d.getAttribute("start")));h&&(h.a+h.Dc>=g?h.Dc=g:h=null);switch(d.getAttribute("op")){case "kill":g=
-null;break t;case "define":h=null}h?h.j=!0:h=Xv();var k={};w(k,h?h.params:Fv);d.getAttribute("id")&&(k.id=d.getAttribute("id"));d.getAttribute("op")&&(k.py=d.getAttribute("op"));d.getAttribute("rc")&&(k.zd=parseInt(d.getAttribute("rc"),10));d.getAttribute("cc")&&(k.mk=parseInt(d.getAttribute("cc"),10));d.getAttribute("ap")&&(h=parseInt(d.getAttribute("ap"),10),k.anchorPoint=0>h||8<h?7:h);d.getAttribute("ah")&&(k.ci=parseInt(d.getAttribute("ah"),10));d.getAttribute("av")&&(k.de=parseInt(d.getAttribute("av"),
-10));d.getAttribute("id")&&(k.id=parseInt(d.getAttribute("id"),10)||0);d.getAttribute("vs")&&(k.isVisible=Boolean(d.getAttribute("vs")));d.getAttribute("ju")&&(k.textAlign=Ev[parseInt(d.getAttribute("ju"),10)]);d.getAttribute("pd")&&(k.Ke=1,0==parseInt(d.getAttribute("pd"),10)&&(k.Ke=0));d.getAttribute("bc")&&(k.backgroundColor=parseInt(d.getAttribute("bc"),16));d.getAttribute("bo")&&(k.opacity=parseInt(d.getAttribute("bo"),10)/100);d.getAttribute("fc")&&(k.ai=parseInt(d.getAttribute("fc"),16));d.getAttribute("sd")&&
-(k.ek=parseInt(d.getAttribute("sd"),10));h=parseInt(d.getAttribute("d"),10)||1E3*parseFloat(d.getAttribute("dur"))||2147483647;d={lk:g,Dc:h,params:k,windowId:parseInt(d.getAttribute("id"),10)};g=new Wv(d)}else g=null}this.a[e]=g;this.g.push(g);break;case "text":e=Vv(a[b]),this.b.push(e),d=e.Wh,this.a[d]&&(d=this.a[d],e=e.ce,""!=d.g&&(d.b=!0),d.g+=e)}break;default:for(this.g.push(Xv()),a=this.i.firstChild.childNodes,b=0,c=a.length;b<c;b++)e=Vv(a[b]),this.b.push(e)}}Zv.prototype.b=null;
-Zv.prototype.g=null;Zv.prototype.a=null;function $v(a){this.a=a.languageCode;this.b=a.languageName||null;this.g=a.languageOriginal||null;this.id=a.id||null;this.i=a.is_default||!1};function aw(a){a=a||{};this.Ak=a.format;this.b=a.languageCode||"";this.Wg=a.languageName;this.Lb=a.kind||"";this.gc=a.name;this.Ba=a.id;this.vk=a.is_servable;this.hi=a.is_default;this.ii=a.is_translateable;a.translationLanguage&&(this.a=new $v(a.translationLanguage))}
-function bw(a){var b={format:a.Ak,languageCode:a.b,languageName:a.Wg,displayName:cw(a),kind:a.Lb,name:a.gc,id:a.Ba,is_servable:a.vk,is_default:a.hi,is_translateable:a.ii};a.a&&(b.translationLanguage={languageCode:a.a.a,languageName:a.a.b,languageOriginal:a.a.g,id:a.a.id,is_default:a.a.i});return b}f=aw.prototype;f.Wg=null;f.Lb=null;f.gc=null;f.Ba=null;f.vk=!1;f.hi=!1;f.ii=!1;f.Ak=1;
-function cw(a){var b=[a.Wg];if("asr"==a.Lb){var c=mf("HTML5_SUBS_ASR");b.push(" (",c,")")}a.gc&&b.push(" - ",a.gc);a.a&&b.push(" >> ",a.a.b);return b.join("")}f.toString=function(){var a=[this.b,": ",this.gc," (",this.Lb,")"];this.a&&a.push(" >> ",this.a.a);return a.join("")};f.equals=function(a){if(!a)return!1;var b=this.a,c=a.a;if(b&&c){if(b.a!=c.a)return!1}else if(b||c)return!1;return this.b==a.b&&this.gc==a.gc&&this.Lb==a.Lb};function dw(){this.g=[];this.a=[]}dw.prototype.g=null;dw.prototype.a=null;dw.prototype.b=-1;function ew(a,b){return b?a.a.concat(a.g):a.a}function fw(a,b){switch(b.Lb){case "asr":return gw(b,a.g);default:if(b.hi||0>a.b)a.b=a.a.length;return gw(b,a.a)}}function gw(a,b){return Pa(b,v(a.equals,a))?!1:(b.push(a),!0)};function hw(a,b,c,d){this.Jd=a;c?this.Jd=Kj(this.Jd,{hl:c}):(a=Gj(this.Jd).hl||"",a=a.split("_").join("-"),this.Jd=Kj(this.Jd,{hl:a}));this.Di=b;this.Bp=!!d;this.Hd=new dw;this.qi=[];this.Cp={}}f=hw.prototype;f.Jd="";f.Di=null;f.Bp=!1;f.Hd=null;f.qi=null;f.Cp=null;function iw(a,b){return Pa(ew(a.Hd,!0),function(a){return a.toString()==b})}function jw(a,b){var c=a.Jd,d={v:a.Di,type:"track",lang:b.b,name:b.gc,kind:b.Lb,fmt:b.Ak};b.a&&(d.tlang=b.a.a);return c=Kj(c,d)}
-function kw(a,b,c){var d=jw(a,b);a=v(function(a){a=new Zv(a.responseText);c(a,b)},a);Nj(d,a)}function lw(a){var b=a.Hd.b;a=ew(a.Hd,!0);return 0>b?null:a[b]}
-function mw(a,b){var c=a.Jd,d={type:"list",tlangs:1,v:a.Di,fmts:Number(!0)};a.Bp&&(d.asrs=1);c=Kj(c,d);d=v(function(a){if((a=a.responseXML)&&a.firstChild){for(var c=this.Hd,d=a.getElementsByTagName("track"),k=d.length,m=0;m<k;m++){var p=parseInt(d[m].getAttribute("formats"),10)||1,r=d[m].getAttribute("lang_code"),s=d[m].getAttribute("lang_translated"),D=d[m].getAttribute("name"),O=d[m].getAttribute("kind")||"",ta=d[m].getAttribute("id"),$="true"==d[m].getAttribute("lang_default"),xE="true"==d[m].getAttribute("cantran");
-fw(c,new aw({format:p,languageCode:r,languageName:s,name:D,kind:O,id:ta,is_servable:!0,is_default:$,is_translateable:xE}))}a=a.getElementsByTagName("target");c=a.length;for(d=0;d<c;d++)k=a[d].getAttribute("lang_code"),m=a[d].getAttribute("lang_translated"),p=a[d].getAttribute("lang_original"),r=a[d].getAttribute("id"),s="true"==a[d].getAttribute("lang_default"),k={languageCode:k,languageName:m,languageOriginal:p,id:r,is_default:s},this.Cp[k.languageCode]=k.languageName,this.qi.push(new $v(k))}b()},
-a);Nj(c,d)};function nw(a){Im.call(this,a);var b=Q(a);this.Dd=a.K();this.On=a.app.R;this.he=[];this.Ia={};this.be={};this.Me=[];this.i=E("captions-translation-select",b);this.wl=E("captions-translation-dialog",b);this.ul=E("captions-settings-dialog",b);this.Xc=E("html5-captions-button",b);J(this.Xc,"click",v(this.Xv,this));J(E("captions-translation-confirm",b),"click",v(this.ew,this));J(E("captions-translation-cancel",b),"click",v(this.Pn,this));Af(E("captions-settings-background-opacity",b),v(this.Vv,this),
-"INPUT");Af(E("captions-settings-text-opacity",b),v(this.dw,this),"INPUT");Af(E("captions-settings-window-opacity",b),v(this.fw,this),"INPUT");Af(E("captions-settings-char-edge-style",b),v(this.Yv,this),"SELECT");J(E("captions-settings-font-family",b),"change",v(this.bw,this));J(E("captions-settings-font-inc",b),"click",v(this.hp,this));J(E("captions-settings-font-dec",b),"click",v(this.gp,this));J(E("captions-settings-confirm",b),"click",v(this.Uv,this));J(E("captions-settings-cancel",b),"click",
-v(this.cw,this));a=E("captions-settings-dialog",b);Cf(a,v(this.Zv,this),"html5-color-picker-button");this.Xc&&(this.ed=E("html5-captions-tracks",this.Xc),this.yf=Mp(Ap.getInstance(),this.Xc),a=E("html5-captions-track-template",this.yf),this.fp=new Xs(a,["track_id","track_display_name"]),Cf(this.yf,v(this.Wv,this),"yt-uix-button-menu-item"));this.Lf=new Fi;this.Lf.stop();J(this.Lf,"tick",v(this.Yk,this));this.D("onResize",v(this.Fn,this));this.D("onBackgroundChange",v(this.hw,this));this.D("onTextOpacityChange",
-v(this.iw,this));this.D("onWindowOpacityChange",v(this.jw,this));this.D("onFontSizeIncrease",v(this.hp,this));this.D("onFontSizeDecrease",v(this.gp,this));this.D("onShowControls",v(this.aw,this));this.D("onHideControls",v(this.$v,this));"detailpage"==this.Dd.Z&&(b=E("captions-account-settings-link",b))&&Hn(b);this.ji=new Jv(99,Gv);this.Xg=new Fi(2E3);this.Xg.stop();J(this.Xg,"tick",v(this.gw,this))}y(nw,Im);f=nw.prototype;f.qa="captions";f.ad="cc";f.nl="subtitlesModuleData";f.ti=!1;f.Kk=!1;f.Zc=null;
-f.Dd=null;f.On=null;f.Xc=null;f.yf=null;f.fp=null;f.wl=null;f.ul=null;f.ed=null;f.Me=null;f.he=null;f.Ia=null;f.be=null;f.Lf=null;f.ji=null;f.Xg=null;f.Ob=null;f.oi=!1;f.Mo=1;var ow={background:"#080808",backgroundOpacity:1,charEdgeStyle:"uniform",color:"#fff",fontFamily:'"Arial Unicode Ms", Arial',fontFamilyOption:"propSans",fontSizeIncrement:0,textOpacity:1,windowColor:"#080808",windowOpacity:0};f=nw.prototype;f.fc=null;f.Hn=!1;
-f.create=function(){nw.C.create.call(this);this.Zc=this.a.getVideoData();var a=this.a.K().Q;-1==Hv.indexOf(a)&&V(Q(this.a),"cc-international");this.b=Ob(ow);w(this.b,Pm(this,"display-settings"));1==this.Dd.a.cc_load_policy||1==this.Zc.Bm||"alwayson"==mm(this.Zc,"yt:cc")?a=!0:(a=Pm(this,"module-enabled"),a=null!=a?!!a:"on"==mm(this.Zc,"yt:cc")||this.Dd.a.cc_prefer_on);a&&this.load()};f.destroy=function(){this.unload();nw.C.destroy.call(this)};
-f.load=function(){if(this.ti)this.ba&&(nw.C.load.call(this),this.oi="alwayson"==mm(this.Zc,"yt:cc"),this.yf&&X(this.yf,"captions-always-on",this.oi),Qm(this,"module-enabled",!0),this.ti=!1,pw(this),this.Fn());else{this.ti=!0;this.ba=!1;var a=this.Zc.b.cc_lang_pref||this.Dd.a.cc_lang_pref||mm(this.Zc,"yt:cc_default_lang")||this.Dd.i,a=a&&a.split("_").join("-");this.Ob=new hw(this.Zc.di,this.Zc.M,a,this.Zc.ok);a=v(this.$n,this);mw(this.Ob,a)}};
-f.unload=function(){this.Ac&&(qw(this,!1),this.vo("control_subtitles_set_track"));rw(this);Nm(this);Qm(this,"module-enabled",!1);this.ti=!1;this.ba&&(this.ba=!1,nw.C.unload.call(this))};f.log_=function(){};function sw(a,b){a.i&&($c(a.i),z(b,function(a){var b=Xc("option");b.setAttribute("value",a.a);b.appendChild(Yc(a.b+" -- "+a.g));this.i.appendChild(b)},a))}
-f.$n=function(){this.ed&&$c(this.ed);sw(this,this.Ob.qi);var a=ew(this.Ob.Hd,!0);if(0<a.length){this.log_("Caption track list loaded, found "+a.length+" tracks.");z(a,function(a){if(a.vk){var b=a.toString();a=cw(a);tw(this,b,a)}},this);var b=this.Ob.Hd.b;(a=a[b]&&a[b].toString())&&uw(this,a);this.Xc&&Lp(Ap.getInstance(),this.Xc);(a=lw(this.Ob))?(this.Kk=!0,vw(this,a)):(this.ba||(this.ba=!0,this.load()),this.u("publish_external_event","onCaptionsTrackListChanged"))}else this.log_("No captions found."),
-this.unload(),In(this.yf),In(this.Xc)};f.av=function(a,b){var c=a.g.concat(a.b);this.log_("Caption track loaded with "+c.length+" events.");rw(this);this.Me=ab(c);this.fc=b;this.Hn=ku.test(b.b);this.ba||(this.ba=!0,this.load());this.Kk&&(this.Kk=!1,this.u("publish_external_event","onCaptionsTrackListChanged"));c=La(c,function(a,b){return new $h(a.a,a.a+a.Dc,{id:"caption"+b})});this.uf.apply(this,c);this.Sn(b)};
-f.Sn=function(a){var b={trackName:a.gc,trackKind:a.Lb};a.a?(b.trackLangCode=a.a.a,b.fromLangCode=a.b):b.trackLangCode=a.b;this.log(b);var b=this.ji,c=cw(a);c&&(c=c.replace(/<[^>]*>?/g,""),b.Te(c));Lm(this,this.ji.oa);this.Xg.start();this.u("publish_external_event","captionschanged",bw(a))};f.yc=function(a){0==a.getId().indexOf("caption")&&(a=parseInt(a.getId().split("caption")[1],10),!isNaN(a)&&this.Me[a]&&(this.he.push(this.Me[a]),this.Lf.start()))};
-f.Vc=function(a){0==a.getId().indexOf("caption")&&(a=parseInt(a.getId().split("caption")[1],10),!isNaN(a)&&this.Me[a]&&(a=this.he.indexOf(this.Me[a]),0<=a&&this.he.splice(a,1),this.Lf.start()))};
-function ww(a,b){if(b instanceof Wv){var c=a.Ia[b.id];w(b.params,a.b);c&&c.getType()!=(b.params.ek?2:b.b?0:1)&&(F(c.oa),delete a.Ia[b.id]);if(!a.Ia[b.id]){var c=a.Ia,d=b.id,e;t:{e=b.id;var g=b.params;switch(b.params.ek?2:b.b?0:1){case 0:e=new Mv(e,g);break t;case 2:e=new Ov(e,g);break t;default:e=new Jv(e,g)}}c[d]=e;c=a.Ia[b.id].oa;X(c,"captions-asr","asr"==a.fc.Lb);null!=b.params.Ke&&(b.params.Ke=a.Hn?1:0);0==a.Ia[b.id].id?(V(c,a.qa),xw(a.a.app.R,c)):Lm(a,c)}w(a.Ia[b.id].ta,b.params);if(0==(b.params.ek?
-2:b.b?0:1)){c=a.Ia[b.id];c.Vn=b.g;c.yb={};c.Zg=!0;c.Te(c.Vn);c.yb.zd=c.Qb.length;c.yb.width=c.oa.offsetWidth;c.yb.height=c.oa.offsetHeight;c.yb.Tn=[];c.yb.Un=[];for(d=0;d<c.yb.zd;d++)c.yb.Un.push(c.Qb[d].offsetTop),c.yb.Tn.push(c.Qb[d].offsetLeft);c.Zg=!1;c.Te(c.$g)}}else c=b.Wh,a.be[c]||(a.be[c]=[]),a.be[c].push(b)}f.Fn=function(){if(this.ba){Nm(this);this.Mo=yw(this.Dd).height/360;pw(this);for(var a in this.Ia)this.Ia[a].Pf()}};
-function zw(a){var b=[],c;for(c in a.Ia){var d=a.Ia[c];d instanceof Mv&&b.push(a.Ia[c])}if(0!=b.length){b.sort(function(a,b){return b.ta.de-a.ta.de});c=yw(a.Dd).height;var e=a.Ia[b[0].id].ta.de,g;for(g in b){d=a.Ia[b[g].id];d.ta.de=e;var h=Math.round(d.ta.zd*d.Mi()),e=e-Math.round(100*(h/c));d.Pf()}}}f.gw=function(){this.Xg.stop();F(this.ji.oa)};
-f.Yk=function(){this.Lf.stop();var a=this.he.length,b;for(b in this.be)delete this.be[b];this.he.sort(function(a,b){return a.a==b.a?a.i-b.i:a.a-b.a});for(var c=0;c<a;c++)ww(this,this.he[c]);for(b in this.Ia)this.be[b]?this.Ia[b].Lo(this.be[b]):(F(this.Ia[b].oa),delete this.Ia[b]);zw(this);this.log_("Refreshing caption display...")};function Aw(a,b){var c=E(a).querySelectorAll("."+b+" input[type=radio]"),d=Sa(c,function(a){return a.checked}),d=(-1==d?1:d+1)%c.length;c[d].click()}
-f.hw=function(){Aw("captions-settings-background-opacity","captions-settings-background-opacity-radio")};f.iw=function(){Aw("captions-settings-text-opacity","captions-settings-text-opacity-radio")};f.jw=function(){Aw("captions-settings-window-opacity","captions-settings-window-opacity-radio")};f.Vv=function(a){a=parseFloat(a.target.getAttribute("value"));isNaN(a)||(this.b.backgroundOpacity=a,pw(this))};f.dw=function(a){a=parseFloat(a.target.getAttribute("value"));isNaN(a)||(this.b.textOpacity=a,pw(this))};
-f.fw=function(a){a=parseFloat(a.target.getAttribute("value"));isNaN(a)||(this.b.windowOpacity=a,pw(this))};f.Yv=function(a){a.target&&(this.b.charEdgeStyle=a.target.value,pw(this))};f.bw=function(a){a.target&&(this.b.fontFamilyOption=a.target.value,pw(this))};f.aw=function(){var a=this.Ia[0];a&&a.oa&&(a=a.oa,W(a,"controls-hidden"),V(a,"controls-visible"))};f.$v=function(){var a=this.Ia[0];a&&a.oa&&(a=a.oa,Dm(a,"controls-visible")&&(W(a,"controls-visible"),V(a,"controls-hidden")))};
-f.gp=function(){Bw(this,-1)};f.hp=function(){Bw(this,1)};function Bw(a,b){a.b.fontSizeIncrement+=b;pw(a)}function Cw(a,b){var c=E(b);c&&(c.querySelector('input[value="'+a.toFixed(1)+'"]').checked=!0)}function Dw(a,b,c){var d=E(b);d&&(b=d.querySelector("span.yt-uix-form-input-select-value"),d=d.querySelector("select"),d.value=a.b[c],dd(b,d.options[d.selectedIndex].text))}function rw(a){Jm(a);a.he=[];a.Me=[];a.fc=null;a.Yk()}
-function vw(a,b){if(b)if(a.Ac)a.fc=b,qw(a,!0),a.vo("control_subtitles_set_track",bw(b));else if(a.Dd.Yf){var c=a.Ob,d=a.On.b,e=v(a.Sn,a),g=c.Jd,c={v:c.Di,type:"track",lang:b.b,name:b.gc,kind:b.Lb,fmt:"vtt"};b.a&&(c.tlang=b.a.a);var h=document.createElement("track");h.src=Kj(g,c);h.mode="showing";h.setAttribute("kind","captions");h.setAttribute("default","");d.appendChild(h);e(b)}else kw(a.Ob,b,v(a.av,a))}f.Xv=function(){this.ba?H(v(this.zp,this),1):this.load()};
-f.Wv=function(a){a=a.currentTarget;var b=G(a,"action");if(b)switch(b){case "translate":this.oi||(Nm(this),Mm(this),Hn(this.wl));break;case "settings":Nm(this);Mm(this);Ew(this);Hn(this.ul);break;case "captions-off":this.unload()}else(a=G(a,"trackid"))?(uw(this,a),b=iw(this.Ob,a),vw(this,b),this.log_("Caption change failed for "+a)):this.log_("onCaptionTrackClicked_ empty, ignoring")};
-function uw(a,b){if(a.ed){var c=E("yt-uix-button-menu-item.active",a.ed);c&&W(c,"active");if(c=a.ed.querySelector(".yt-uix-button-menu-item"+('[data-trackid="'+b+'"]')))V(c,"active"),a.zp()}}f.zp=function(){var a=E("yt-uix-button-menu-item.active",this.ed);if(a){var b=this.ed,c=C&&!uc(8)?0:b.offsetTop,d=a.offsetTop+a.offsetHeight-c-(b.clientHeight+b.scrollTop)+1;b.scrollTop+=Math.max(d,0);d=b.scrollTop-(a.offsetTop-c)+1;b.scrollTop-=Math.max(d,0)}};f.Pn=function(){In(this.wl)};
-f.ew=function(){if(!this.oi){this.Pn();var a;t:{var b=this.Ob.qi;for(a=0;a<b.length;a++){var c=b[a];if(c.a==this.i.value){a=c;break t}}a=null}a&&(c=this.fc,b=new aw,b.b=c.b,b.Wg=c.Wg,b.gc=c.gc,b.Lb=c.Lb,b.hi=!1,b.ii=c.ii,b.a=a,fw(this.Ob.Hd,b)&&(a=b.toString(),tw(this,a,cw(b)),uw(this,a),this.Xc&&Lp(Ap.getInstance(),this.Xc)),vw(this,b))}};f.Uv=function(){In(this.ul)};f.cw=function(){delete this.b;this.b=Ob(ow);Qm(this,"display-settings",this.b);pw(this)};
-function pw(a){Fw(a);var b=ap(a.b.background),c=a.b.backgroundOpacity;Qm(a,"display-settings",a.b);a.k=kn(".captions-text, .caption-row","background-color: rgba("+b[0]+","+b[1]+","+b[2]+","+c+") !important;",{Ib:a.k,reset:!0});Cw(c,"captions-settings-background-opacity");b=ap(a.b.color);c=a.b.textOpacity;Qm(a,"display-settings",a.b);a.G=kn(".captions-text","color: rgba("+b[0]+","+b[1]+","+b[2]+","+c+") !important;",{Ib:a.G,reset:!0});Cw(c,"captions-settings-text-opacity");b=ap(a.b.windowColor);c=
-a.b.windowOpacity;Qm(a,"display-settings",a.b);a.J=kn(".caption-window-transform","background-color: rgba("+b[0]+","+b[1]+","+b[2]+","+c+") !important;",{Ib:a.J,reset:!0});Cw(c,"captions-settings-window-opacity");Qm(a,"display-settings",a.b);var b=a.b.charEdgeStyle,d=a.b.textOpacity;if("none"==b)ln(a.j);else{var c="",e="rgba(34, 34, 34, "+d+")",d="rgba(204, 204, 204, "+d+")";switch(b){case "dropShadow":c="text-shadow: 2px 2px 3px "+e+", 2px 2px 4px "+e+", 2px 2px 5px "+e+";";break;case "raised":c=
-"text-shadow: 1px 1px "+e+", 2px 2px "+e+", 3px 3px "+e+";";break;case "depressed":c="text-shadow: 1px 1px "+d+", 0 1px "+d+", -1px -1px "+e+", 0 -1px "+e+";";break;case "uniform":c="text-shadow: 0 0 4px "+e+", 0 0 4px "+e+", 0 0 4px "+e+", 0 0 4px "+e+";"}a.j=kn(".captions-text",c,{Ib:a.j,reset:!0})}Dw(a,"captions-settings-char-edge-style","charEdgeStyle");c=b="";switch(a.b.fontFamilyOption){case "monoSerif":b='"Courier New", Courier, "Nimbus Mono L", monospace';break;case "propSerif":b='"Times New Roman", Times, Georgia, Cambria, serif';
-break;case "monoSans":b='"Deja Vu Sans Mono", "Lucida Console", Monaco, Consolas, monospace';break;case "propSans":b='"Arial Unicode Ms", Arial, Helvetica, Verdana, sans-serif';break;case "casual":b='"Comic Sans MS", Impact, fantasy';break;case "cursive":b='"Monotype Corsiva", "URW Chancery L", "Apple Chancery", cursive';break;case "smallCaps":b='"Arial Unicode Ms", Arial, Helvetica, Verdana, sans-serif',c="font-variant: small-caps;"}a.A=kn(".captions-text",c+"font-family: "+b+" !important;",{Ib:a.A,
-reset:!0});a.b.fontFamily=b;Qm(a,"display-settings",a.b);Dw(a,"captions-settings-font-family","fontFamilyOption");Qm(a,"display-settings",a.b);b="font-size: "+Math.round(((a.b.fontSizeIncrement||0)+16)*a.Mo)+"px;";a.B=kn(".caption-window-transform",b,{Ib:a.B,reset:!0});a.Yk()}f.Zv=function(a){var b=v(function(b){var d=G(a.currentTarget,b.toLowerCase());d&&(this.b[b]=d)},this);b("color");b("background");b("windowColor");pw(this);Qm(this,"display-settings",this.b)};
-function Ew(a){var b={Ib:a.g},c=a.b.color,d=a.b.background,e=a.b.windowColor;c&&(a.g=kn('.html5-popup-dialog button[data-color="'+c+'"]',"border: 3px solid #992121;",b));d&&(a.g=kn('.html5-popup-dialog button[data-background="'+d+'"]',"border: 3px solid #992121;",b));e&&(a.g=kn('.html5-popup-dialog button[data-windowcolor="'+e+'"]',"border: 3px solid #992121;",b))}
-function Fw(a){var b=[],c=v(function(a){var c=this.b[a];c&&b.push(a+": "+c+" !important")},a);c("color");c("background");c={Ib:a.g,reset:!0};a.g=kn(".captions-text",b,c);var d=ap(a.b.windowColor),c={Ib:a.I,reset:!0};a.I=kn(".caption-window-transform","background-color: rgba("+d[0]+","+d[1]+","+d[2]+", 1)",c);Ew(a)}function tw(a,b,c){a.ed&&(b=Ys(a.fp,{track_id:b,track_display_name:c}),a.ed.appendChild(b))}function Gw(a){return nw.prototype.$a(a)?new nw(a):null}
-f.aq=function(a,b){switch(a){case "fontSize":return isNaN(b)||(this.b.fontSizeIncrement=b,pw(this)),this.b.fontSizeIncrement;case "reload":b&&mw(this.Ob,v(this.$n,this));break;case "track":if(b){if(!ia(b))break;var c=new aw(b);c.equals(this.fc)||(vw(this,c),uw(this,c.toString()))}else return this.fc?bw(this.fc):{};return"";case "tracklist":return this.ba?La(ew(this.Ob.Hd,b&&b.includeAsr),function(a){return bw(a)}):[]}};f.Vo=function(){return["reload","fontSize","track","tracklist"]};f.$a=function(a){return!!a.getVideoData().di};
-f.Qh=function(a){a?(a=this.fc,rw(this),this.fc=a):(qw(this,this.ba),this.fc&&vw(this,this.fc))};function qw(a,b){X(Q(a.a),a.qa+"-loaded",b)};function Hw(){var a=ac(),b;if(b=ll()){t:{if(navigator.plugins&&0<navigator.plugins.length)for(b=0;b<navigator.plugins.length;b++)if(0<=navigator.plugins[b].name.indexOf("NVIDIA 3D Vision")){b=!0;break t}b=!1}if(b)t:{var c=navigator.userAgent.match(/Firefox[\/\s](\d+\.\d+)/);if(c&&1<c.length&&4<=c[1]){c=document.createElement("embed");c.setAttribute("id","NvImageDetectionFFID");c.setAttribute("style","visibility: hidden");c.setAttribute("width",25);c.setAttribute("height",25);c.setAttribute("type",
-"image/jps");Zc(document.documentElement,c);c=Mc("NvImageDetectionFFID");try{if(null!=c){b=27527<=c.NvGetDriverVersion();break t}}catch(d){}}b=!1}}return b||!(!a||-1==a.indexOf("Sony"))};function Iw(a){Im.call(this,a);var b=a.getVideoData();b.P&&Jw(this);Kw(this,"html5-threed-conversion-on",v(this.sv,this));Kw(this,"html5-threed-conversion-off",v(this.rv,this));var c=Q(this.a);a=E("html5-threed-popup-menu-change-mode-link",c);c=E("html5-threed-dialog-change-mode-button",c);b="/select_3d_mode?video_id="+b.M;a.setAttribute("href",b);c.setAttribute("href",b)}y(Iw,Im);f=Iw.prototype;f.nl="threeDModuleData";f.$e=null;function Kw(a,b,c){a=E(b,Q(a.a));J(a,"click",c)}f.qa="threed";f.ad="threed";
-f.create=function(){Lw(this.a.app,void 0);Iw.C.create.call(this)};f.destroy=function(){Lw(this.a.app,!0);this.unload();Iw.C.destroy.call(this)};function Mw(a){return Iw.prototype.$a(a)?new Iw(a):null}f.$a=function(a){a=a.getVideoData();return!!a.P||!!a.rj};f.sv=function(){Nw(this,!0)};f.rv=function(){Nw(this,!1)};function Nw(a,b){var c=a.a.getVideoData();if(c.rj&&c.zf!=b){var c=a.a.app,d=N(c),e=d.a;e.zf=!e.zf;e.j=[];e.u("dataupdated");gh(d,"m");Lw(c);b?Jw(a):Nm(a)}}
-function Jw(a){Pm(a,"warning-shown")||Hw()||(a.$e=E("threed-html5-warning-dialog",Q(a.a)),Hn(a.$e),H(v(function(){Ow(this)},a),0),J(a.$e,"mouseover",v(function(){W(this.$e,"hide-dialog")},a)),J(a.$e,"mouseout",v(function(){Ow(this)},a)),Kw(a,"threed-html5-warning-close",v(a.Bv,a)))}function Ow(a){V(a.$e,"hide-dialog");H(v(function(){Dm(this.$e,"hide-dialog")&&Nm(this)},a),9E3)}f.Bv=function(){Qm(this,"warning-shown",!0);Nm(this)};function Pw(a){Im.call(this,a);this.b=new Xm(["div","ytp-ypc-clickwrap-overlay",["h2","header",mf("YPC_CLICKWRAP_HEADER")],["div","description",mf("YPC_CLICKWRAP_DESCRIPTION")],["button","confirm-button",mf("YPC_CLICKWRAP_BUTTON")]]);dn(this.b.N());this.a.app.R.g.appendChild(this.b.N());L(this,this.b);this.g=this.b.a["confirm-button"]}y(Pw,Im);f=Pw.prototype;f.qa="ypc_clickwrap";f.ad="ypc-clickwrap";f.$a=function(){return qm(this.a.getVideoData(),"ypc_clickwrap_module")};
-function Qw(a){return qm(a.getVideoData(),"ypc_clickwrap_module")?new Pw(a):null}f.create=function(){Pw.C.create.call(this);this.load()};f.destroy=function(){this.ba&&this.unload()};f.load=function(){Pw.C.load.call(this);E("html5-video-container",Q(this.a));cn(this.b.N());J(this.g,"click",v(this.nu,this));this.ba=!0};f.unload=function(){dn(this.b.N());Df(this.g);this.ba=!1;Pw.C.unload.call(this)};f.nu=function(){Km(this);this.destroy()};function Rw(a){a=a.b;this.j=a.ypc_offer_button_text;this.description=a.ypc_offer_description;this.heading=a.ypc_offer_headline;this.k=a.ypc_full_video_message;this.b=a.ypc_offer_id;this.a=a.ypc_buy_url;this.g=a.ypc_item_thumbnail;this.title=a.ypc_item_title;this.i=a.ypc_item_url;this.M=a.ypc_vid};function Sw(){Y.call(this,["div",["ytp-drawer","html5-stop-propagation"],["div","ytp-drawer-content","{{content}}"],["a","ytp-drawer-close-button"],["a","ytp-drawer-open-button"]]);this.b=this.template.a["ytp-drawer-close-button"];J(this.b,"click",v(this.hide,this));this.a=this.template.a["ytp-drawer-open-button"];J(this.a,"click",v(this.show,this));this.Aa(null);this.hide()}y(Sw,Y);Sw.prototype.hide=function(){V(this.element,"ytp-drawer-closed")};
-Sw.prototype.Aa=function(a){a?(Sw.C.Aa.call(this,a),cn(this.element)):dn(this.element)};Sw.prototype.show=function(){H(oa(W,this.element,"ytp-drawer-closed"),0)};Sw.prototype.H=function(){Df(this.b);Df(this.a);this.a=this.b=null;Sw.C.H.call(this)};function Tw(a,b){R.call(this);this.a=new Sw;L(this,this.a);this.b=document.createElement("div");Em(this.b,["html5-stop-propagation","html5-ypc-endscreen"]);this.i=document.createElement("div");V(this.i,"html5-ypc-overlay");this.g=new Xm(["div","html5-ypc-module",["div","html5-ypc-action-heading","{{heading}}"],["div","html5-ypc-thumbnail","{{thumbnail_element}}"],["div","html5-ypc-title","{{title}}"],["div","html5-ypc-description","{{description}}"],["button","html5-ypc-purchase","{{button_label}}"]]);
-L(this,this.g);this.j=this.g.a["html5-ypc-purchase"];J(this.j,"click",v(this.k,this));dd(this.i,b.k);var c=b.title;b.i&&(c=["a",{href:b.i,target:"blank_"},b.title]);var d="";b.g&&(d=["img",{src:b.g}]);this.g.update({heading:b.heading,title:c,thumbnail_element:d,description:b.description,button_label:b.j});this.a.W(a);this.a.Aa(this.g.N());a.appendChild(this.b)}y(Tw,R);Tw.prototype.H=function(){Tw.C.H.call(this);this.j&&Df(this.j);F(this.b);F(this.i);this.i=this.b=this.a=null};Tw.prototype.k=function(){this.u("ypcContentRequest")};function Uw(a){Im.call(this,a);this.g=this.b=null;this.i=NaN}y(Uw,Im);f=Uw.prototype;f.qa="ypc";f.ad="ypc";function Vw(a){var b=a.getVideoData();return a.K().ld&&qm(b,"ypc_module")}f.$a=function(){return Vw(this.a)};function Ww(a){return Vw(a)?new Uw(a):null}f.create=function(){Uw.C.create.call(this);var a=this.a.getVideoData();this.b=new Rw(a);a.ja?this.load():this.a.wo({video_id:this.b.M,ypc_preview:1})};f.destroy=function(){this.ba&&this.unload();this.b=null};
-f.load=function(){Uw.C.load.call(this);var a=E("html5-video-container",Q(this.a));this.g=new Tw(a,this.b);this.g.D("ypcContentRequest",this.xt,this);xw(this.a.app.R,this.g.i);eo(this.a.K())&&(a=new $h(2147483647,2147483647,{priority:2}),this.uf(a));this.g.a.show();I(this.i);this.i=H(v(function(){this.g.a.hide()},this),1E4);this.ba=!0};f.unload=function(){Jm(this);Ug(this.g);this.g=null;this.ba=!1;Uw.C.unload.call(this)};
-f.yc=function(a){Uw.C.yc.call(this,a);a=this.g;a.b.appendChild(a.g.N());a.a.Aa(null);cn(a.b)};f.Vc=function(a){Uw.C.Vc.call(this,a);a=this.g;dn(a.b);a.a.Aa(a.g.N())};f.xt=function(){if(this.b.a)"embedded"==this.a.K().Z?Qp(this.b.a):window.location=S(this.b.a,{})+"";else if(this.b.b){var a=n("yt.www.watch.player.handleEndPreview");a&&a(this.b.b)}};var Xw={yz:"ERROR_ALREADY_PINNED_ON_A_DEVICE",Dz:"ERROR_AUTHENTICATION_EXPIRED",Ez:"ERROR_AUTHENTICATION_MALFORMED",Fz:"ERROR_AUTHENTICATION_MISSING",Pz:"ERROR_BAD_REQUEST",Vz:"ERROR_CANNOT_ACTIVATE_RENTAL",cA:"ERROR_CGI_PARAMS_MALFORMED",dA:"ERROR_CGI_PARAMS_MISSING",PA:"DEVICE_FALLBACK",SA:"ERROR_LICENSE",VA:"FLASH_FALLBACK",tB:"ERROR_GEO_FAILURE",GB:"HTML5_DEFAULT_FALLBACK",HB:"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",MB:"ERROR_INVALID_DRM_MESSAGE",QB:"LEARN_MORE",hC:"ERROR_NOT_SIGNED_IN",sC:"ERROR_PURCHASE_NOT_FOUND",
-tC:"ERROR_PURCHASE_REFUNDED",wC:"ERROR_RENTAL_EXPIRED",Wz:"ERROR_CAST_SESSION_DEVICE_MISMATCHED",Xz:"ERROR_CAST_SESSION_VIDEO_MISMATCHED",Zz:"ERROR_CAST_TOKEN_FAILED",Yz:"ERROR_CAST_TOKEN_EXPIRED",$z:"ERROR_CAST_TOKEN_MALFORMED",CC:"ERROR_SERVER_ERROR",GC:"ERROR_STOPPED_BY_ANOTHER_PLAYBACK",IC:"ERROR_STREAMING_DEVICES_QUOTA_PER_24H_EXCEEDED",JC:"ERROR_STREAMING_NOT_ALLOWED",KC:"ERROR_STREAMING_UNAVAILABLE",xC:"ERROR_RETRYABLE_ERROR",RC:"ERROR_TOO_MANY_STREAMS_PER_USER",QC:"ERROR_TOO_MANY_STREAMS_PER_ENTITLEMENT",
-TC:"ERROR_UNSUPPORTED_DEVICE",UC:"ERROR_UNUSUAL_ACTIVITY",aD:"ERROR_VIDEO_FORBIDDEN",cD:"ERROR_VIDEO_NOT_FOUND"},Yw={300:"ERROR_STREAMING_DEVICES_QUOTA_PER_24H_EXCEEDED",301:"ERROR_ALREADY_PINNED_ON_A_DEVICE",303:"ERROR_STOPPED_BY_ANOTHER_PLAYBACK",304:"ERROR_TOO_MANY_STREAMS_PER_USER",305:"ERROR_TOO_MANY_STREAMS_PER_ENTITLEMENT",400:"ERROR_VIDEO_NOT_FOUND",401:"ERROR_GEO_FAILURE",402:"ERROR_STREAMING_NOT_ALLOWED",403:"ERROR_UNSUPPORTED_DEVICE",405:"ERROR_VIDEO_FORBIDDEN",500:"ERROR_PURCHASE_NOT_FOUND",
-501:"ERROR_RENTAL_EXPIRED",502:"ERROR_PURCHASE_REFUNDED",5E3:"ERROR_BAD_REQUEST",5001:"ERROR_CGI_PARAMS_MISSING",5002:"ERROR_CGI_PARAMS_MALFORMED",5100:"ERROR_AUTHENTICATION_MISSING",5101:"ERROR_AUTHENTICATION_MALFORMED",5102:"ERROR_AUTHENTICATION_EXPIRED",5200:"ERROR_CAST_TOKEN_MALFORMED",5201:"ERROR_CAST_TOKEN_EXPIRED",5202:"ERROR_CAST_TOKEN_FAILED",5203:"ERROR_CAST_SESSION_VIDEO_MISMATCHED",5204:"ERROR_CAST_SESSION_DEVICE_MISMATCHED",6E3:"ERROR_INVALID_DRM_MESSAGE",7E3:"ERROR_SERVER_ERROR",8E3:"ERROR_RETRYABLE_ERROR"};function Zw(a){Im.call(this,a);this.qa="ypc_license_checker";this.ad="ypc_license";this.j=!1;this.i=0;this.g=!1;this.b=null;this.B=pl();this.A=a.K().lb+"ypc_license_server"}y(Zw,Im);
-var $w={LICENSE_DENIED_CANNOT_ACTIVATE_RENTAL:"ERROR_CANNOT_ACTIVATE_RENTAL",LICENSE_DENIED_NOT_SIGNED_IN:"ERROR_NOT_SIGNED_IN",LICENSE_DENIED_NO_ACTIVE_PURCHASE_AGREEMENT:"ERROR_RENTAL_EXPIRED",LICENSE_DENIED_CONCURRENT_PLAYBACK:"ERROR_STOPPED_BY_ANOTHER_PLAYBACK",LICENSE_DENIED_UNUSUAL_ACTIVITY:"ERROR_UNUSUAL_ACTIVITY",LICENSE_DENIED_STREAMING_UNAVAILABLE:"ERROR_STREAMING_UNAVAILABLE",LICENSE_DENIED_PLAYBACK_CAP:"ERROR_LICENSE"};
-function ax(a){return qm(a.getVideoData(),"ypc_license_checker_module")}f=Zw.prototype;f.$a=function(){return ax(this.a)};f.create=function(){Zw.C.create.call(this);var a=new $h(1E3,2147483646,{priority:0});this.uf(a);this.D("onStateChange",this.Yw,this)};function bx(a){return ax(a)?new Zw(a):null}f.yc=function(){this.j=!0;cx(this,6E4)};f.Yw=function(a){P(a.state,2)?(this.i=0,this.b=null,this.g=!1):(P(a.state,1)||P(a.state,8))&&cx(this,6E4)};
-function cx(a,b){if(!a.b&&a.j){var c=b;void 0==c&&(c=a.g?6E4:1E3);var d=a.a.getVideoData();d.a&&d.a.g||(a.b={video_id:d.M,player_id:a.B,request_id:pl(),purchase_id:d.jd,version:"4",player_time_seconds:a.a.getCurrentTime().toString(),gid:d.Ic,session_token:d.Jc},a.k=d.Da,0==c?a.pn():H(v(a.pn,a),c))}}f.pn=function(){if(this.b){var a=S(this.A,{cpn:this.k});Qj(a,{format:"RAW",method:"POST",Gf:this.b,timeout:3E4,Pa:v(this.Jv,this),onError:v(this.Iv,this),Sk:v(this.Kv,this)})}};
-f.Jv=function(a){if(this.b){a=a.responseText;var b=a in $w?1:64<=a.length&&a.match(/[0-9a-fA-f]+/)?0:-1;-1==b?dx(this,"decode"):(this.i=0,this.b=null,1==b?(this.g=!1,a=a in $w?mf($w[a]):mf("ERROR_LICENSE"),ex(this.a.app.b,150,a,void 0)):(this.g=!0,cx(this)))}};f.Iv=function(a){dx(this,"net-"+a.status)};f.Kv=function(){dx(this,"timeout")};function dx(a,b){if(a.b)if(a.log({errorType:b}),a.b=null,5<++a.i){var c=mf("ERROR_LICENSE");ex(a.a.app.b,150,c,void 0)}else cx(a)};function fx(){this.a=[];this.i={};this.o={};this.F={};this.b=this.j=null;this.g=[];this.k=null}y(fx,K);fx.prototype.B=function(a){if(this.b){var b;var c=ja(a);b=this.i[c];if(!b)if(this.b){if(b=a(this.b)){a=this.i[c]=b;for(var d in this.j)a.D(d,this.j[d]);a.D("command_log_timing",this.A,this);L(this,b)}}else b=null;b&&b.$a(this.b)&&!Ta(this.a,b)&&(b.create(),this.a.push(b),Ta(this.g,b.qa)&&(b.Ac=this.k,b.Qh(!!b.Ac)))}};function gx(a){z(a.a,function(a){a.destroy()});a.a=[]}
-function hx(a,b,c){ix(a);a.k=b;a.g=ab(c);z(a.a,function(a){0<=Ja(c,a.qa)&&(a.Ac=b,a.Qh(!!a.Ac))})}function ix(a){z(a.g,function(a){if(a=jh(this,a))a.Ac=null,a.Qh(!1)},a);a.k=null;a.g=[]}function zh(a,b,c,d){return b&&c?(a=jh(a,b))?a.aq(c,d):null:null}function Ah(a,b){if(!b)return La(a.a,function(a){return a.qa});var c=jh(a,b);return c?c.Vo():[]}function jh(a,b){return Pa(a.a,function(a){return a.qa==b})}fx.prototype.G=function(a,b){z(this.a,function(c){c.u(a,b)})};
-function jx(a){var b=[];z(a.a,function(a){(a=a.Hi())&&b.push(a)});return b}fx.prototype.A=function(a,b){w(this.F,a||null);w(this.o,b||null)};function kx(a){this.a={};for(var b=0;b<a.length;b++){var c=a[b];this.a[c.a]=c}}function lx(a){a=Jb(a.a);gb(a,function(a,c){return a.a-c.a});return a};function mx(a,b,c){this.b=a;this.a=b;this.i=!!c.Cf;this.g=c.fa};function nx(){this.fe={};this.a=this.bb().a;this.Wc=null}f=nx.prototype;f.bb=function(){var a=this.constructor,b;if(!(b=a.Ip)){var c;b=a.Bx;var d=[];for(c in b)b.hasOwnProperty(c)&&(0==c||d.push(new mx(a,c,b[c])));c=new kx(d);b=a.Ip=c}return b};f.has=function(a){a.b.bb();this.bb();return null!=this.fe[a.a]};f.get=function(a,b){a.b.bb();this.bb();var c;c=this.a[a.a];var d=ox(this,c);c.i?(t(d),c=d[b||0]):(t(d),c=d);return c};
-f.set=function(a,b){a.b.bb();this.bb();var c=a.a;this.fe[c]=b;this.Wc&&(this.Wc[c]=b)};f.add=function(a,b){a.b.bb();this.bb();var c=a.a;this.fe[c]||(this.fe[c]=[]);this.fe[c].push(b);this.Wc&&delete this.Wc[c]};f.clear=function(a){a.b.bb();this.bb();a=a.a;delete this.fe[a];this.Wc&&delete this.Wc[a]};
-f.equals=function(a){if(!a||this.constructor!=a.constructor)return!1;for(var b=lx(this.bb()),c=0;c<b.length;c++){var d=b[c];if(this.has(d)!=a.has(d))return!1;if(this.has(d)){var e=11==d.g||10==d.g,g=ox(this,d),h=ox(a,d);if(d.i){if(g.length!=h.length)return!1;for(d=0;d<g.length;d++)if(e?!g[d].equals(h[d]):g[d]!=h[d])return!1}else if(e?!g.equals(h):g!=h)return!1}}return!0};
-function px(a,b){for(var c=lx(a.bb()),d=0;d<c.length;d++){var e=c[d];if(b.has(e)){a.Wc&&delete a.Wc[e.a];var g=11==e.g||10==e.g;if(e.i){var h,k=b;h=e;h.b.bb();k.bb();h=ox(k,k.a[h.a]);null==h||t(h);h=h||[];for(k=0;k<h.length;k++)a.add(e,g?h[k].clone():h[k])}else h=ox(b,e),g?(g=ox(a,e))?px(g,h):a.set(e,h.clone()):a.set(e,h)}}}f.clone=function(){var a=new this.constructor;a!=this&&(a.fe={},a.Wc&&(a.Wc={}),px(a,this));return a};function ox(a,b){var c=a.fe[b.a];return null==c?null:c}
-function qx(a,b){a.Bx=b;a.bb=function(){return a.Ip||(new a).bb()}};var rx={Jy:0,tA:1,EA:2,Iy:3,Ry:4,rA:5,CA:6,zA:7,AA:8,BA:9,xA:10,yA:11,Ty:12,Sy:13,Hy:14,Ay:15,sA:20,GA:21,zy:22,uA:23,FA:24,DA:25,Oy:30,HA:31,Ny:32,Py:33,wA:40,vA:41,Uy:42,Vy:43,By:50,Fy:51,Ky:52,Ly:53,My:54,wy:55,xy:56,Qy:57,Gy:58,Ey:60,Cy:61,yy:70,vy:80,Wy:90};function sx(){nx.apply(this)}y(sx,nx);function tx(){nx.apply(this)}y(tx,nx);function ux(){nx.apply(this)}y(ux,nx);function vx(){nx.apply(this)}y(vx,nx);function wx(){nx.apply(this)}y(wx,nx);function xx(){nx.apply(this)}y(xx,nx);
-qx(sx,{0:{name:"YtAdType",mh:"video.YtAdType"},1:{name:"ad_namespace",required:!0,fa:14,defaultValue:0,type:{wz:0,QA:1,xz:2,aA:3,sB:4,OA:5,NA:6,Rz:7,LA:8,Tz:9,KA:10,MA:11,Cz:12,wD:13}},2:{name:"ad_format",required:!0,fa:14,defaultValue:0,type:{tz:0,NB:1,LB:2,eC:3,VC:4,OB:5,IB:6,KB:7,xD:8,RA:9}},3:{name:"ad_invideo",fa:14,defaultValue:0,type:{vz:0,iA:1,jA:2,kA:3,lA:4,hA:5,Uz:6}},4:{name:"invideo_autoplay",fa:14,defaultValue:0,type:{Nz:0,rC:1}},5:{name:"ad_instream",fa:14,defaultValue:0,type:{uz:0,
-SC:1}},6:{name:"ad_instream_long",fa:8,type:Boolean}});qx(tx,{0:{name:"AdId",mh:"video.AdId"},1:{name:"ad_network",fa:14,defaultValue:1,type:{lC:1,uy:2}},2:{name:"ad_network_name",fa:9,type:String},3:{name:"ad_id",required:!0,fa:9,type:String}});
-qx(ux,{0:{name:"YtAdEvent",mh:"video.YtAdEvent"},1:{name:"ad_event_type",required:!0,fa:14,defaultValue:0,type:{ez:0,lz:1,fz:2,oz:3,gz:4,hz:5,bz:6,$y:7,IA:8,Xy:9,mz:10,nz:11,Yy:12,JA:13,pz:14,cz:15,Zy:16,dz:17,az:18,qz:100,rz:101,jz:130,iz:131,kz:132}},2:{name:"wall_time",required:!0,fa:2,type:Number},3:{name:"media_time",required:!0,fa:2,type:Number},4:{name:"logentry_time_usec",required:!0,fa:3,type:String},5:{name:"ad_error_type",fa:14,defaultValue:0,type:rx}});
-qx(vx,{0:{name:"YtAdSlot",mh:"video.YtAdSlot"},1:{name:"slot_time",required:!0,fa:2,type:Number},2:{name:"ad_type",required:!0,fa:11,type:sx},3:{name:"ad_events",Cf:!0,fa:11,type:ux},4:{name:"ad_video_duration",fa:2,type:Number},5:{name:"ad_id",fa:9,type:String},6:{name:"slot_index",fa:5,type:Number}});
-qx(wx,{0:{name:"YtVideoMetadata",mh:"video.YtVideoMetadata"},1:{name:"content_owner_ids",Cf:!0,fa:9,type:String},2:{name:"video_duration_seconds",fa:2,type:Number},3:{name:"all_content_owner_ids",fa:9,type:String}});
-qx(xx,{0:{name:"YtWatchAdInfo",mh:"video.YtWatchAdInfo"},1:{name:"video_id",required:!0,fa:9,type:String},2:{name:"allowed_ads",Cf:!0,fa:11,type:sx},3:{name:"ad_slots",Cf:!0,fa:11,type:vx},4:{name:"ps",fa:9,type:String},5:{name:"el",fa:9,type:String},6:{name:"country",fa:9,type:String},7:{name:"feature",fa:9,type:String},8:{name:"blocked",fa:8,type:Boolean},9:{name:"plid",fa:9,type:String},10:{name:"video_metadata",fa:11,type:wx},11:{name:"experiment_id",Cf:!0,fa:3,type:String},12:{name:"ad_flags",
-fa:4,type:String},13:{name:"all_experiment_ids",fa:9,type:String},14:{name:"no_ads_returned",fa:8,type:Boolean},15:{name:"ad_errors",Cf:!0,fa:14,defaultValue:0,type:rx},16:{name:"ad_slot_with_event",fa:11,type:vx}});function yx(a,b){Hh.call(this,a,b)}y(yx,Hh);f=yx.prototype;f.rg=function(){Wg(this.app,!0,this.a);this.app.Qd(!1,this.a)};f.Qj=function(){this.app.Od(!1,this.a)};f.Gp=function(a,b,c){Wg(this.app,!0,this.a);var d=this.app,e=this.a;d.pf(d.getCurrentTime()+a,b,c,e)};f.Oh=function(a,b){Wg(this.app,!0,this.a);this.app.pf(a,b,void 0,this.a)};f.uj=function(){ch(this.app,this.a)};function zx(a){this.app=a;Im.call(this,a.I)}y(zx,Im);var Ax={iC:"0",jC:"1",TA:"2",Yx:"3",Oz:"4",BC:"5"};var Bx={vC:"red",WHITE:"white"};var Cx={$x:"0",FC:"1",oA:"2"};var Dx={"ad-trueview-indisplay-pv":6,"ad-trueview-insearch":7},Ex={"ad-trueview-indisplay-pv":2,"ad-trueview-insearch":2},Fx={adunit:{Vb:!1,zc:!1},detailpage:{oc:!0}};Fx.embedded={sh:Ff(),yh:"4",zc:!0};Fx.profilepage={kl:!0};
-var Gx="blogger books docs google-live play picasaweb".split(" "),Hx={blazer:{bj:"youtube_mobile",Tb:!1,gy:!1,Eg:!1,Fg:!1,nc:!0,Ub:!1,tb:!1,Db:!0},blogger:{ze:!1,Uf:!1,Nc:!1,Vb:!1,xc:!1,oc:!1,zc:!1,qc:"bl"},books:{ze:!1,Uf:!1,Nc:!1,Vb:!1,xc:!1,oc:!0,zc:!1,qc:"gb"},docs:{ze:!1,Uf:!1,Nc:!1,Vb:!1,xc:!1,oc:!1,zc:!1,qc:"gd"},"google-live":{ze:!1,Uf:!1,Nc:!1,Vb:!1,xc:!1,oc:!1,zc:!1,qc:"gl"},play:{Vb:!1,xc:!1,oc:!1,zc:!1,qc:"gp"},"native":{Eg:!1,Fg:!1,Ub:!0},olympics:{Eg:!1,Fg:!1,Hh:!0,Db:!0},picasaweb:{ze:!1,
-Uf:!1,Nc:!1,Vb:!1,xc:!1,oc:!1,zc:!1,qc:"pw"},touch:{Eg:!1,Fg:!1,Db:!0}};
-function Ix(a){this.o=[];this.a={};Jx(this,a.fexp);this.Y=U(this.Y,a.origin);this.Z=a.el||this.Z;var b=Fx[this.Z];b&&w(this,b);b=a.ps||this.La;0<navigator.msMaxTouchPoints&&(b="touch");this.La=b;(b=Hx[this.La])&&w(this,b);this.hf=Kx(this)&&Ta(Gx,this.La);this.gg=!(!kl().defaultPlaybackRate||ec||Ti||Si||Ui);if(a.use_media_volume)b=!1;else{var b=kl(),c=b.muted;b.muted=!c;b=b.muted!=c}this.am=b;this.fm=Ui;if(Ti||Si)this.bm=this.Ic||"blazer"!=this.La;this.lm="0"!=a.add_player_event_listeners;b=T(this.sh,
-a.fs);this.sh="detailpage"==this.Z||"olympics"==this.La?b:b&&Ff();this.Ea=U(this.Ea,a.authuser);this.yh=ql(this.yh,a.autohide,Ax);this.Tb=T(this.Tb,a.autoplay);this.Hj=T(this.Hj,a.autoplayoverride);this.color=ql(this.color,a.color,Bx);this.k=U(this.k,a.content_v);this.Ij=ql(this.Ij,a.controls,Cx);this.F=U(this.F,a.cbrand);this.A=U(this.A,a.cbr);this.B=U(this.B,a.cbrver);this.Wf=U(this.Wf,a.c);this.ef=U(this.ef,a.cver);this.G=U(this.G,a.cmodel);this.I=U(this.I,a.cnetwork);this.J=U(this.J,a.cos);this.L=
-U(this.L,a.cosver);this.O=U(this.O,a.cplatform);this.Fh=T(this.Fh,a.edu_mode);this.b=U(this.b,a.eurl);this.P=U(this.P,a.framer);this.ga=ql(this.ga,a.iv_load_policy,cl);this.i=U(this.i,a.hl);this.Cm=T(this.Cm,a.bwlogging);this.nc=T(this.nc,a.is_html5_mobile_device);this.Nd=T(this.Nd,a.player_wide);this.Dm=T(this.Dm,a.is_playground);this.loop=T(this.loop,a.loop);this.jf=T(this.jf,a.modestbranding);"red"!=this.color&&(this.jf=!1);this.oh=T(this.oh,a.noadapt);this.Xf=T(this.Xf,a.on3g);this.Ua=U(this.Ua,
-a.pageid);this.Ch=ql(this.Ch,a.vq,dk);this.ej=U(this.ej,a.playerapiid);this.th=T(this.th,a.playsinline);this.fj=T(this.fj,a.playonclick);this.Q=U(this.Q,a.cr);this.ha=U(this.ha,a.q);this.Nc=T(this.Nc,a.logwatch);this.wj=T(this.wj,a.canplaylive);this.xj=T(this.xj,a.canplaypaid);this.Vb=T(this.Vb,a.showinfo);this.xc=T(this.xc,a.rel);this.oc=T(this.oc,a.enablesizebutton);this.hj=T(this.hj,a.ss);this.V=U(this.V,a.theme);this.Ub=T(this.Ub,a.use_native_controls);this.tb=!Si&&T(this.tb,a.svt);Kx(this)&&
-(this.mg=T(this.mg,a.altf),this.tg=T(this.tg,a.retryneterr),this.Hh=T(this.Hh,a.nologo));this.tg=this.tg||this.oe;this.Ub&&(this.jf=!0,this.ga=3);this.Jj=T(this.Jj,a.ssl);if(this.Db=T(this.Db,a.use_tablet_controls))this.V="dark";b=this.xh;if(c=a.video_container_override){var d=c.split("x");2==d.length&&(c=parseInt(d[0],10),d=parseInt(d[1],10),b=isNaN(c)||isNaN(d)||0>=c*d?b:new B(c,d))}this.xh=b;this.Ra=U(this.Ra,a.attrib);this.aa=U(this.aa,a.sk);this.protocol=this.Jj?"https":"http";this.qe="0"!=this.Ij;
-this.dj=T(this.qe,a.store_user_volume);this.Md=T(this.Md,a.use_media_volume);(b=a.BASE_YT_URL)&&ok(b,kk)&&(this.lb=b);Lx(this,a);Mx(this,a);"detailpage"==this.Z&&delete this.b;this.Yi=Nx(this)+"s";this.zc=this.jf&&!this.Ub?!this.Vb:this.Vb||this.qe?!1:this.zc;b=this.Tb||"detailpage"==this.Z;c=!0;this.nc&&(c=!1);dj("nintendo wiiu")&&(c=!1);this.Hj&&(c=!0);this.Ul=b&&c;this.a=a}y(Ix,K);f=Ix.prototype;f.lm=!0;f.sh=!0;f.Ea="";f.yh="2";f.Tb=!1;f.Hj=!1;f.lb="/";f.gy=!0;f.color="red";f.Ij="1";f.Wf="web";
-f.ef="html5";f.Fh=!1;f.Eg=!0;f.Fg=!0;f.gg=!1;f.am=!1;f.Z="detailpage";f.Cm=!1;f.fk=!1;f.hf=!1;f.nc=!1;f.pb=!1;f.Nd=!1;f.ze=!0;f.Dm=!1;f.Uf=!0;f.qg=!1;f.loop=!1;f.jf=!1;f.oh=!1;f.Ch=null;f.ej="";f.Xf=!1;f.Ua="";f.La=null;f.th=!1;f.mg=!1;f.fm=!1;f.tg=!1;f.Ul=!1;f.Nc=!1;f.wj=!0;f.xj=!0;f.qe=!0;f.dj=!0;f.Md=!1;f.Vb=!0;f.xc=!0;f.kl=!1;f.oc=!1;f.zc=!1;f.hj=!1;f.Hh=!1;f.bm=!1;f.Ub=!1;f.tb=!0;f.Jj=!1;f.Db=!1;f.Oc=null;f.xh=null;f.Ko=null;f.tf=null;f.Ya=null;f.Bj=null;f.qc="yt";f.fj=!1;
-function Lx(a,b){a.Nc=T(a.Nc,b.logwatch);a.la=void 0==b.user_age?a.la:Number(b.user_age);a.rp=U(a.rp,b.user_display_image);a.Dl=U(a.Dl,b.user_display_name);a.pa=U(a.pa,b.user_gender)}
-function Mx(a,b){var c;t:{if(b&&((c=b.adformat)||(c=(c=b.attrib)&&c in Dx&&c in Ex?Ex[c]+"_"+Dx[c]:void 0),c)){var d=c.match(/^(\d*)_((\d*)_?(\d*))$/);if(d&&5==d.length&&(d=d[3],d=6==d||7==d||8==d||9==d||10==d||11==d,Kx(a)||d))break t}c=void 0}c&&(a.g=c,a.a.adformat=b.adformat);c=b.agcid;a.Va=c;a.a.agcid=c;c=b.feature;a.j=c;a.a.feature=c;if(c=b.referrer)a.referrer=c,a.a.referrer=c;"1"==b.enablecsi&&(a.fk=!1)}
-function Ox(a){var b={};b.c=a.Wf;a.ef&&(b.cver=a.ef);a.O&&(b.cplatform=a.O);a.F&&(b.cbrand=a.F);a.G&&(b.cmodel=a.G);a.I&&(b.cnetwork=a.I);a.A&&(b.cbr=a.A);a.B&&(b.cbrver=a.B);a.J&&(b.cos=a.J);a.L&&(b.cosver=a.L);return b}
-function Jx(a,b){if(b){a.o=b.split(",");var c={};z(a.o,function(a){c[a]=!0});a.Ic=!!c["918108"];a.ld=!!c["912711"];a.Yf=!!c["925900"];a.eg=!!c["913559"];a.cj=!c["904831"];a.Ka=!!c["913424"];a.xa=!!c["932206"];a.jd=!!c["932217"];a.Kc=!!c["932246"];a.Jc=!!c["932245"];a.gd=!!c["932240"];a.ag=!!c["932236"];a.kd=!!c["932237"];a.kb=!!c["932242"];a.mc=!!c["932243"];a.jb=!!c["932247"];a.bg=!!c["932248"];a.za=!!c["932239"];a.Ca=!!c["932250"];a.Zf=!!c["932252"];a.$f=!!c["932253"];a.lc=!!c["924604"];a.Lc=!!c["924610"];
-a.oe=!!c["918117"];a.Ma=!!c["907231"]&&"leanback"!=a.Z;a.ja=!!c["938600"];a.Hc=!!c["936903"];a.hd=!!c["927845"]}}
-function Px(a,b){switch(b.md){case 38:var c=b.M.indexOf(":"),d=b.M.slice(0,c),c=b.M.slice(c+1);return S("//play.google.com/books/volumes/"+d+"/content/media",{aid:c,sig:b.ld});case 30:return d="//docs.google.com/",a.lb!=Ix.prototype.lb&&(d=a.lb),S(d+"get_video_info",{docid:b.M,authuser:b.Ea,authkey:b.An,eurl:a.b});case 33:return S("//google-liveplayer.appspot.com/get_video_info",{key:b.M});default:return d={html5:"1",video_id:b.M,cpn:b.Da,eurl:a.b,ps:a.La,el:a.Z,hl:a.i,list:b.Ta,agcid:a.Va,sts:15973},
-b.Q?d.vvt=b.Q:b.G&&(d.access_token=b.G),a.g&&(d.adformat=a.g),b.da&&(d.iv_load_policy=b.da),b.df&&(d.autoplay="1"),b.Ck&&(d.mdx="1"),b.Dk&&(d.utpsa="1"),b.Sa&&(d.is_fling="1"),c=Qx(a),c.width&&(d.width=c.width),c.height&&(d.height=c.height),b.ja&&(d.ypc_preview="1"),b.Ld&&(d.splay="1"),a.k&&(d.content_v=a.k),b.Bn&&(d.livemonitor=1),a.Ea&&(d.authuser=a.Ea),a.Ua&&(d.pageid=a.Ua),w(d,Ox(a)),S(a.lb+"get_video_info",d)}}
-function Nx(a){return a.Fh?"//s.youtubeeducation.com/":a.Uf?"//s.youtube.com/":"//video.google.com/"}function Rx(a){return a.referrer?a.referrer.slice(0,128):""}
-function Zt(a,b,c,d){b={v:b.M,list:b.Ta};a.Z&&(b.feature="player_"+a.Z);c&&w(b,c);a=S(a.protocol+"://"+("www.youtube-nocookie.com"==window.location.host||a.Fh?"www.youtube.com":window.location.host)+"/watch",b);if(d){c="";c="!"=="#".charAt(1)?"#".substr(0,2):"#";b="#";"#"==b.charAt(0)&&(b="!"==b.charAt(1)?b.substr(2):b.substr(1));b=Fj(b);for(var e in d)b[e]=d[e];d=c+Hj(b);a=a+d}return a}
-function Sx(a){var b={contact_type:"playbackissue",html5:1,plid:a.fb,ei:a.k,v:a.M};a.a&&(b.fmt=a.a.Oa);return S("//www.google.com/support/youtube/bin/request.py",b)}function Qx(a){return(a=a.Bj)?new B(a.clientWidth,a.clientHeight):new B(Number.NaN,Number.NaN)}function yw(a){return a.Ya?new B(a.Ya.clientWidth,a.Ya.clientHeight):new B(Number.NaN,Number.NaN)}
-function Tx(a){var b={};if(!a.Ya)return b;a.Ya.webkitDecodedFrameCount&&(b.hmewdfc=a.Ya.webkitDecodedFrameCount,b.hmewdrop=a.Ya.webkitDroppedFrameCount,b.hmewvdbc=a.Ya.webkitVideoDecodedByteCount,b.hmewadbc=a.Ya.webkitAudioDecodedByteCount);a.Ya.mozParsedFrames&&(b.hmempf=a.Ya.mozParsedFrames,b.hmemdf=a.Ya.mozDecodedFrames,b.hmempresented=a.Ya.mozPresentedFrames,b.hmempainted=a.Ya.mozPaintedFrames,b.hmempaintdelay=a.Ya.mozPaintDelay);return b}
-function Ux(a){var b=n("yt.www.watch.activity.getTimeSinceActive",window);if("detailpage"==a.Z&&b)return b();var c;a.Sa&&(c=x()-a.Sa);return c}function eo(a){return"leanback"==a.Z||a.hf||!a.xc&&!a.kl?!1:!0}function Eh(a){return"detailpage"!=a.Z?!1:!0}function Kx(a){a=nk()&&(ok(a.Y,kk)||ok(a.Y,lk));var b=ok(document.location.toString(),kk)&&!nk();return a||b}f.H=function(){this.Bj=this.Ya=null;Ix.C.H.call(this)};function Vx(){this.b=0;this.a=this.j=this.g=this.i=NaN}function Wx(a,b){for(var c=0;c<a.length;c++)if(a.start(c)<=b&&a.end(c)>=b)return a.end(c)-b;return 0};function Xx(a){this.b=a;this.pendingRequests_=[];this.a=[];this.i=this.g=null;this.j=0}function Yx(a,b){a.pendingRequests_.push(b);a.g=b.g[b.g.length-1];a.j+=b.U.length}function Zx(a){for(;a.pendingRequests_.length&&5==a.pendingRequests_[0].state;){var b=a.pendingRequests_.shift();z(b.o,a.F,a)}}
-Xx.prototype.F=function(a){if(4==a.info.type){for(var b=Pk(a.info.a,a.info),c=[],d=a.a,e=0;e<b.length;e++){var g=jk(b[e].U.start+b[e].ob-a.info.U.start+a.U.start,b[e].Ha);c.push(new vk(b[e],a.buffer,g,d));d=!1}bb(this.a,c)}else 3==a.info.type&&this.a.push(a)};
-function $x(a,b){if(a.k)return a.a[0].U;var c=a.b.info.i;if(a.a[0].info.i>=b)return null;var d;for(d=1;d<a.a.length;d++){var e=a.a[d].buffer!=a.a[d-1].buffer;if(a.a[d].info.i>b||e)break}d--;var e=a.a[d].U.end,g=a.a[d].info.k-b;if(c&&1<g){c=Math.floor(a.a[d].info.Ha*((b-a.a[d].info.i)/a.a[d].info.o));if(0==c)return null;e=a.a[d].U.start+c-1}return new hk(a.a[0].a?0:a.a[0].U.start,e)}
-function ay(a){a.pendingRequests_.length?a.g=Ha(a.pendingRequests_[a.pendingRequests_.length-1].g):a.a.length?a.g=Ha(a.a).info:a.g=a.i}function by(a){return a.b.Yb()?a.b.index.g?a.b.index.b[a.b.index.T]:-1:NaN}function cy(a,b){a.b.Yb();a.g=a.b.Ej(b,0).a[0];a.i&&a.i.b&&(a.i=null);return a.g.startTime}
-function dy(a){ey(a);if(a.b.info.a&&a.i&&!a.i.g){var b=Qa(a.a,function(a){return a.info.g});a.a=db(a.a,0,b+1);a.k=!0}else a.a=[];if(a.a.length)for(a.j=a.a[0].buffer.byteLength,b=1;b<a.a.length;b++)a.a[b].buffer!=a.a[b-1].buffer&&(a.j+=a.a[b].buffer.byteLength);else a.j=0}function fy(a){var b=!1,c;for(c=0;c<a.pendingRequests_.length;c++)if(7==a.pendingRequests_[c].state){b=!0;break}if(b){for(;c<a.pendingRequests_.length;)a.o(a.pendingRequests_.pop());ay(a)}}
-function gy(a){var b=a.i;a.a.length&&(b=Ha(a.a).info);b=a.g||b;return b.qf(b.U.length-(b.Ha+b.ob))}function hy(a){return Ma(a.a,function(a){return a.info.g})}function iy(a){return Oa(a.pendingRequests_,function(a){return!(!a.b||1!=a.b.priority)&&!(4<=a.state)})}Xx.prototype.o=function(a){rk(a.g[0])||a.dispose();this.j-=a.U.length};function ey(a){z(a.pendingRequests_,a.o,a);a.pendingRequests_=[];a.g=null};function jy(a,b){this.state=1;this.g=b.a;this.k=a;this.o=null;this.U=tk(b.a);this.F=b.b;this.G=NaN;this.A=this.j=0;this.i=NaN;this.b=this.B=null;this.I=""}f=jy.prototype;
-f.start=function(){var a=1==this.state,b=6==this.state;1==this.state||3==this.state||b&&ky(this);ly(this,2);if(b){if(this.j<this.k.o){this.j++;a=0.5+Math.random();H(v(this.gk,this),1E4*a);return}b=this.F;if(!(this.G<=b.g)){b.b++;b.g=zk-1;var c;c=Je(b.a).Ne;var d=pk(b.a);b.a=Kj(d,{cmo:"pf="+b.b,shost:c})}this.j=0}a?this.gk():H(v(this.gk,this),0)};
-f.gk=function(){if(!this.ka()){this.G=zk++;var a={};this.U&&(a.range=this.U.toString());a.keepalive="yes";4==this.g[this.g.length-1].type&&(a.fr="yes");a=S(this.F.a,a);this.j&&(a=me(qe(a,"playerretry"),"playerretry",this.j.toString()));this.I=a;var b={format:"RAW",method:"GET",responseType:"arraybuffer",withCredentials:!0,pd:v(this.mq,this)};this.a=Qj(a,b);this.A=0;this.b&&(a=this.b,a.a=x(),a.j=a.a,a.b=0,a.o=0,a.i=!1,a.k={km:Uh(a.g),lq:Vh(a.g),kq:Wh(a.g)},my(a),this.a.addEventListener("progress",
-v(this.nq,this),!1),0<this.k.a&&!rk(this.g[0])&&(this.i=H(v(this.ym,this),this.k.a)))}};f.nq=function(a){if(!this.ka()){var b=this.b,c=a.timeStamp,d=a.loaded;c<b.a&&(c=x());if(!(20>c-b.j)){if(32768<d){ny(b,c);var e=(c-b.j)/1E3,g=d-b.b;if(0<g)if(0.2<e||1024>g)b.o+=e;else{var h=b.g,e=Math.max(e,0.05);h.a.b(e,g/e)}}b.j=c;b.b=d}this.b.b>this.b.A&&4>this.state&&ly(this,4);4==a.target.readyState&&oy(this.b,a.timeStamp)}};
-f.mq=function(a){if(!this.ka()&&a==this.a){this.i&&(I(this.i),this.i=NaN);var b=null==a.response||400<=a.status;if(!b){a=a.response;var c;t:{if(2048>a.byteLength&&(c=String.fromCharCode.apply(String,new Uint8Array(a)),ok(c,kk)))break t;c=""}if(c)a=this.F,c=qe(c,"keepalive"),c=qe(c,"playerretry"),c=qe(c,"range"),c=qe(c,"shost"),a.a=c,ly(this,3);else if(a.byteLength!=this.U.length)b=!0;else{c=this.g;if(1==c.length&&!c[0].U){var d;d=c[0];var e=jk(0,a.byteLength);d=new qk(d.type,d.a,e,d.j,d.startTime,
-d.duration,d.ob,e.length,d.b);c[0]=d}d=[];for(var e=0,g=!1,h=!1,k=0;k<c.length;k++){var m=c[k],p=a,r=jk(e,m.Ha),s=!1;if(1==m.type)a.slice?p=a.slice(e,e+m.Ha):(g=new Uint8Array(a,e,e+m.Ha),p=(new Uint8Array(g)).buffer),r=jk(0,m.Ha),g=!0;else if(3==m.type||4==m.type)s=g&&!h,h=!0;d.push(new vk(m,p,r,s));e+=m.Ha}this.o=d;ly(this,5)}}b&&(ky(this),ly(this,6))}};function ky(a){return a.j<a.k.o?!0:!(a.G>a.F.g&&1<=a.F.b)}function ly(a,b){a.state=b;3<=a.state&&a.B&&a.B(a)}
-f.ym=function(){this.i=NaN;if(!this.ka()&&this.b){var a=!1;if(this.b.i){var b=this.b.F;my(this.b);this.b.F-b>=0.8*(this.k.a/1E3)?(this.A++,a=5<=this.A):this.A=0}else a=5<x()/1E3-(this.b.a/1E3+this.b.k.km);a?(ly(this,7),py(this),oy(this.b,Date.now())):this.i=H(v(this.ym,this),this.k.a)}};f.ka=function(){return-1==this.state};f.dispose=function(){ly(this,-1);this.B=this.o=null;py(this);I(this.i);this.i=NaN};function py(a){if(a.a){var b=a.a;a.a=null;b.abort()}};function qy(a,b,c,d){this.priority=b;this.g=a;this.A=d;this.b=this.j=this.a=NaN;this.o=0;this.B=c;this.F=NaN;this.i=!1}function oy(a,b){b<a.a&&(b=x());ny(a,b);var c=a.g,d=a.b,e=a.o,d=Math.max(d,32768);c.j.b(1,e/d);c=a.g;d=b-a.a;e=a.b;isNaN(e)||(c.g+=e);isNaN(d)||(c.i+=d/1E3)}function my(a){var b=a.B-a.b,b=b*a.k.lq+b/a.k.kq,c=x()/1E3,b=a.i?b+c:b+Math.max(c,a.a/1E3+a.k.km);a.F=b}function ny(a,b){a.i||(a.g.b.b(1,(b-a.a)/1E3),a.i=!0)};function ry(a,b,c,d){R.call(this);this.j=a;this.a=b;this.i=new Xx(c);this.b=new Xx(d);this.k=this.G=this.I=NaN;this.o=this.L=this.B=!1;this.A=NaN;this.O=!1}y(ry,R);var sy=2/24;f=ry.prototype;f.gt=function(a){this.g=a;a.Zb.appendBuffer&&(a.Zb.addEventListener("updateend",v(this.Of,this),!1),a.rd.addEventListener("updateend",v(this.Of,this),!1));ty(this);uy("msa")};
-function vy(a){a.g&&a.g.Zb&&a.g.Zb.removeEventListener&&(a.g.Zb.removeEventListener("updateend",v(a.Of,a)),a.g.rd.removeEventListener("updateend",v(a.Of,a)));a.g=null}function wy(a){if(0<a.a.i){var b=(a.i.b.info.b+a.b.b.info.b+12500)*a.a.i;if(0<a.a.g){if(b>a.a.g)return;b=a.a.g}b={cwndbw:(8*b/1024).toFixed(0)};Ak(a.i.b.j,b);Ak(a.b.b.j,b)}}function xy(a,b,c){c-=a.a.L;c-=c*b*Vh(a.j);c=Math.max(a.a.J,Math.min(a.a.P,c));a=Math.max(a.a.O,Math.ceil(a.a.J*b));return Math.min(a,Math.ceil(c*b))}
-function yy(a,b){var c=Math.min(2.5,Uh(a.j));return Math.ceil(b*c+32768)}function zy(a){var b=Wh(a.j);a=Uh(a.j)+1048576*Vh(a.j);return b*Math.min(1,1048576/(b*a))}
-function Ay(a,b){if(!b.g){if(!b.b.Yb())return;cy(b,a.k)}if(!(b.j>a.a.A)){var c=b.g;4==c.type&&c.a.Yb()&&(b.g=Ha(Pk(c.a,c)),c=b.g);if(!(c.b||!c.a.Aj(c)||c.a.info.i&&(4==c.type||a.b.g&&!a.b.g.b&&a.b.g.k<c.i))){var d=a.a.B;a.o&&0<a.a.k&&(d=Math.max(d,a.a.k/c.a.info.b));d=a.k+d;if(!(3==c.type&&c.k>d||2<=iy(b)+1)){var d=c.k-a.k,e=c.a.info.b,g=c.a.Yb()?xy(a,e,d):a.a.I,h=yy(a,c.a.info.b),k=!1,e=!1;if(c&&3==c.type&&b.b.Yb()&&c.a!=b.b){var d=xy(a,b.b.info.b,d+(c.startTime+c.duration-c.k)),m=yy(a,b.b.info.b),
-e=c.a.info.b<b.b.info.b;if(!e||d>=m)k=!0,g=d,h=m}d=h;0<g&&(d=Math.max(a.a.I,g,Math.min(2*g,h)));if(k){c=b.g?b.g.startTime+b.g.duration+sy:0;if(a.a.b&&e)t:{e=Uh(a.j)+d*Vh(a.j)+d/Wh(a.j)+a.k+a.a.L,e=Math.min(e,c),e=Ek(b.b.index,e),e+1<b.b.index.hb()&&(c=b.b.index.b[e+1]),e=c;if(b.pendingRequests_.length){if(b.pendingRequests_[0].g[0].startTime<=e)break t;ey(b)}for(g=b.a.length-1;0<=g;g--)h=b.a[g],h.info.startTime>e&&(b.a.pop(),b.a.length&&b.a[g-1].buffer==h.buffer||(b.j-=h.buffer.byteLength));ay(b)}b.g&&
-!b.g.g&&(e=new jy(a.a,gy(b)),By(a,e,!0),Yx(b,e));b.g&&(c=b.g?b.g.startTime+b.g.duration+sy:0);d=new jy(a.a,b.b.Ej(c,d))}else d=new jy(a.a,c.qf(d));By(a,d,!1);Yx(b,d)}}}}function By(a,b,c){c=c?2:1;a.a.V&&(c=0);var d=Math.min(2.5,Uh(a.j)),e=Wh(a.j);b.b=new qy(a.j,c,b.U.length,0.95*b.U.length-d*e);a=v(a.Du,a);b.B=a;b.start()}
-f.Du=function(a){if(!this.ka()){var b=6==a.state&&ky(a);3==a.state||b?(b&&this.u("softerror",209),a.start()):5==a.state?(!this.J&&a.g[0].a.info.a&&(this.J=a.I),Cy(this),z(a.o,function(a){rk(a.info)&&a.info.a.Co(a)}),Na(a.o,function(a){return xk(a)})&&!a.g[0].a.Do()?ty(this):Dy(this,126)):7==a.state||4==a.state?(7==a.state&&this.u("softerror",210),ty(this)):Dy(this,121)}};
-function Cy(a){if(!a.O&&a.J&&window.performance&&window.performance.getEntriesByName){var b=window.performance.getEntriesByName(a.J);b.length&&(b=b[0],uy("vrst",b.fetchStart),uy("vdns",b.domainLookupEnd),uy("vreq",b.requestStart),uy("fvb",b.responseStart),uy("vrc",b.responseEnd),a.O=!0)}}function ty(a){isNaN(a.I)&&(a.I=H(v(a.Of,a),0))}function Ey(a){isNaN(a.G)&&(a.G=H(v(function(){this.Of();this.G=NaN},a),1E3))}
-f.Of=function(){this.I=NaN;if(!this.L&&this.g){var a=Math.floor(Math.max(by(this.i),by(this.b)));isNaN(a)||(this.g.Xa(a),this.L=!0)}if(!this.ka())if("prerender"==window.document.webkitVisibilityState)Ey(this);else{this.g&&this.g.Gb()&&vy(this);Zx(this.b);Zx(this.i);fy(this.b);fy(this.i);a=!1;if(this.g){var a=Fy(this,this.b,this.g.rd),b=Gy(this.g.rd,this.k);if(!isNaN(b)||this.b.i&&this.b.i.b)this.b.i&&this.b.i.b&&(b=NaN),a|=Fy(this,this.i,this.g.Zb,b);if(this.b.i&&this.b.i.b&&this.i.i&&this.i.i.b&&
-!this.g.Zb.updating&&!this.g.rd.updating&&this.g.isOpen()){a=this.g;a.isOpen()&&a.g.endOfStream();return}}this.dm();Ay(this,this.b);Ay(this,this.i);a&&(this.g.Zb.appendBuffer||ty(this))}};f.dm=function(){if(!this.ka()&&!isNaN(this.a.F)){var a=zy(this);!isNaN(this.A)&&Math.abs(this.A-a)/a<this.a.F||(Math.round(a/1024),Math.round(this.A/1024),this.u("bandwidthchange",a),fg("yt-player-bandwidth",{byterate:a},2592E3),this.A=a)}};
-function Fy(a,b,c,d){if(c.updating)return!0;var e=b.a.length?b.a[0]:null;if(!e)return!1;!b.i||b.i.g||sk(b.i,e.info)||(b.i=null,a.g.isOpen()&&c.abort(),c.g=null);var g;e.info.a.Yb();e.a?g=!1:(g=e.info.a.b,c.g==g?g=!1:(Hy(a,c,g),c.g=g,g=!0));if(g&&c.updating)return!0;g=a.a.G;var h=b.b.info.i?10485760:a.a.k;a.o&&0<h&&(g=Math.max(g,h/b.b.info.b));g=a.k+g;0<=d&&(g=Math.min(g,d));d=$x(b,g);if(!d)return!1;g=new Uint8Array(e.buffer,d.start,d.length);if(!Hy(a,c,g))return!1;for(var k;b.a.length&&(b.a[0].U.end>
-d.end?(k=b.a[0],h=d.end-b.a[0].U.start+1,h=Math.min(h,k.info.Ha),g=new qk(k.info.type,k.info.a,k.info.U,k.info.j,k.info.startTime,k.info.duration,k.info.ob,h,!1),a=jk(k.U.start,h),g=new vk(g,k.buffer,a,k.a),h=new qk(k.info.type,k.info.a,k.info.U,k.info.j,k.info.startTime,k.info.duration,k.info.ob+h,k.info.Ha-h,k.info.b),a=new hk(a.end+1,k.U.end),a=[g,new vk(h,k.buffer,a,!1)],k=a[0],b.a[0]=a[1]):k=b.a.shift(),a=b,a.i=k.info,a.k&&a.i.g&&(a.k=!1),k.U.end!=d.end););b.a.length&&k.buffer==b.a[0].buffer||
-(b.j-=k.buffer.byteLength);e.a&&(c.g=e.info.a.b);return!c.appendBuffer||c.updating}function Hy(a,b,c){if(b.appendBuffer)try{b.appendBuffer(c)}catch(d){return!1}else b.append(c);return!a.g.Gb()}function Gy(a,b){for(var c=0;c<a.buffered.length;c++)if(a.buffered.start(c)<=b&&a.buffered.end(c)>=b)return a.buffered.end(c);return NaN}function Iy(a,b){if(!a.ka()){var c=Jy(a,a.b,b,a.g&&a.g.rd),d=Jy(a,a.i,c,a.g&&a.g.Zb);a.k=Math.max(b,c,d);a.B=!0;ty(a)}}
-function Jy(a,b,c,d){if(b.b.Yb())if(d){if(a.o&&a.a.b)return dy(b),cy(b,c);var e=Gy(d,c),g=NaN,h=b.i;h&&(g=Gy(d,h.a.index.b[h.j]));if(e==g)return c;dy(b);b.b.info.a&&b.i&&!b.i.g&&!hy(b)&&(d=new jy(a.a,gy(b)),By(a,d,!0),Yx(b,d));if(isNaN(e))return cy(b,c);cy(b,e+sy)}else cy(b,c);else b.b.i?0!=c&&ey(b):Ky(a,b,!1);return c}
-function Ky(a,b,c){var d=c?65536:0;c&&!isNaN(a.a.j)&&(d=Math.floor(Math.max(d,a.a.j*b.b.info.b)));d=b.b.mn(d);z(d,function(a){var c=new jy(this.a,a);By(this,c,!0);!rk(a.a[a.a.length-1])&&Yx(b,c)},a);b.b.i=!0;if(b.b.info.a&&c)for(c=0;c<a.a.Q&&!b.g.b;c++)d=new jy(a.a,b.g.qf(49152)),By(a,d,!0),Yx(b,d)}f.H=function(){vy(this);ey(this.i);ey(this.b);this.b=this.i=null;ry.C.H.call(this)};
-function Dy(a,b){a.u("fatalerror",b);if(a.g&&a.g.isOpen()){var c=a.g;c.isOpen()&&c.g.endOfStream("network")}a.dispose()}function uy(a,b){var c;b&&(c=window.performance.timing.navigationStart+b);Sp(a,c)};function Ly(){this.G=30;this.B=40;this.k=62914560;this.A=20971520;this.j=2;this.Q=0;this.J=this.L=2;this.I=131072;this.P=15;this.O=2097152;this.F=0.1;this.o=2;this.b=!0;this.a=1800;this.g=this.i=NaN};function My(a,b,c){this.a=a;this.headers=b;this.message=c};function Ny(a,b,c,d,e,g,h){this.a=[];this.g=a;this.k=b.g;this.j=b;this.i=c;this.G=d;this.I=e;this.b=[];this.J=h||null;this.B=this.L=!1;this.A=null;this.o=!0;this.F={};this.listen(this.g,["keymessage","webkitkeymessage"],this.pj);this.listen(this.g,["keyadded","webkitkeyadded"],this.gq);this.listen(this.g,["keyerror","webkitkeyerror"],this.hq);g&&this.b.push(g)}y(Ny,Hl);function Jh(a,b){if(ok(b,kk)){for(var c in a.F)b=me(qe(b,c),c,a.F[c]);a.k=b}else Oy(a,"u")}f=Ny.prototype;
-f.start=function(){this.ka()||(this.L=!0,this.b.length&&this.pj(this.b.shift()))};f.dispose=function(){Ny.C.dispose.call(this);this.I=this.g=null};f.pj=function(a){this.ka()||a.sessionId!=this.i||(this.B&&a.defaultURL&&Jh(this,a.defaultURL),this.L?(this.A=a,Py(this,a)):this.b.push(a))};f.gq=function(a){this.ka()||a.sessionId!=this.i||(this.B=!0,this.b.length&&this.pj(this.b.shift()))};
-function Py(a,b){var c={format:"RAW",method:"POST",Bw:b.message,responseType:"arraybuffer",withCredentials:!0,Pa:a.Cw,onError:a.En,S:a};a.J&&(c.headers={Authorization:"Bearer "+a.J});var d=a.k;a.o||(d=me(qe(d,"exclude_customdata"),"exclude_customdata","1"));Qj(d,c)}
-f.Cw=function(a){if(!this.ka())if(0!=a.status&&a.response){t:{a=new Uint8Array(a.response);var b=0,c=String.fromCharCode.apply(String,a.subarray(0,16384)).split("\r\n"),d=c[0];Ya(c,0);c.pop();var b=b+(d.length+2),e=d.match(/^GLS\/1.\d ([0-9]{1,3}) (\w+)$/);if(null!=e){d=e[1];isFinite(d)&&(d=String(d));for(var d=u(d)?/^\s*-?0x/i.test(d)?parseInt(d,16):parseInt(d,10):NaN,g={},h=0;h<c.length;h++){e=c[h];b+=e.length+2;if(0==e.length){a=new My(d,g,a.subarray(b));break t}e=e.match(/([^:]+):\s+([^]+)/);
-if(null==e)break;g[e[1]]=e[2]}}a=null}0!=a.a?(b=Yw[a.a.toString()],Oy(this,"f"+a.a,b?b:"ERROR_LICENSE")):(a=a.message,this.g.addKey?this.g.addKey(this.j.a,a,this.G,this.i):this.g.webkitAddKey(this.j.a,a,this.G,this.i))}else this.En(a)};f.hq=function(a){this.ka()||a.sessionId!=this.i||("playready"==this.j.b&&a.errorCode==a.MEDIA_KEYERR_UNKNOWN&&2==a.systemCode&&this.o?(this.o=!1,Py(this,this.A)):Oy(this,"s"+a.errorCode.code+"."+a.systemCode))};f.En=function(a){Oy(this,"r"+a.status)};
-function Oy(a,b,c){a.ka()||a.I(b,c);a.dispose()};function Qy(a,b,c,d){this.a=[];this.b=a;this.g=b;this.B=c;this.o=d;this.A=null;this.j={};this.F={};this.i=null;this.k=[];this.listen(this.b,["needkey","webkitneedkey"],this.G);this.listen(this.b,["keymessage","webkitkeymessage"],this.J);this.listen(this.b,["keyerror","webkitkeyerror"],this.I)}y(Qy,Hl);Qy.prototype.dispose=function(){Qy.C.dispose.call(this);this.b=null;Hb(this.j,function(a){a.dispose()})};
-Qy.prototype.G=function(a){a=a.initData;if(!this.i&&Nb(this.j)||"widevine"!=this.g.b){var b=String.fromCharCode.apply(String,a);if(!this.F[b]){this.F[b]=!0;b="clearkey"==this.g.b;if(112==a[4]&&115==a[5]&&115==a[6]&&104==a[7]&&b){t:{for(var c=new DataView(a.buffer),b=0;b<c.byteLength;){var d=c.getUint32(b,!1);if(1886614376!=c.getUint32(b+4,!1))break;if(1477738184==c.getUint32(b+12,!1)&&69420633==c.getUint32(b+16,!1)&&2464609580==c.getUint32(b+20,!1)&&1558758348==c.getUint32(b+24,!1)){c=c.getUint32(b+
-28,!1);if(16!=c)break;a=a.subarray(b+32,b+32+c);break t}b+=d}a=null}if(!a)return}this.i?this.k.push(a):Ry(this,a)}}};function Ry(a,b){if(!a.ka()){try{a.b.generateKeyRequest?a.b.generateKeyRequest(a.g.a,b):a.b.webkitGenerateKeyRequest(a.g.a,b)}catch(c){var d="g";c instanceof DOMException&&(d+=c.code);a.o(d,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",!0);return}a.i=b}}
-Qy.prototype.J=function(a){if(!this.ka()&&this.b&&!this.j[a.sessionId]){var b=new Ny(this.b,this.g,a.sessionId,this.i,this.o,a,this.A);this.j[a.sessionId]=b;this.i=null;this.B(b);this.k.length&&Ry(this,this.k.shift())}};Qy.prototype.I=function(a){!this.ka()&&this.b&&(this.j[a.sessionId]||this.o("s"+a.errorCode.code+"."+a.systemCode))};function Sy(a,b,c,d){this.ia=a;this.a=b;this.g=c;this.b=d};function Ty(a){this.a=a}function Uy(a,b){var c=b.ff;return c&&c&&"unknown"!=c?c:(c=a.a.Ch)&&c&&"unknown"!=c?c:"auto"}function Vy(a,b,c){var d,e=Uy(a,b);e&&"auto"!=e&&(d=Wy(b,e));d||(d=Xy(a,b,c));return d}
-function Xy(a,b,c){var d=b.j,e;if(a.a.Oc){var g=a.a.Oc.clone();Si&&!a.a.th&&(g=(window.screen&&window.screen.width?new B(window.screen.width,window.screen.height):null)||g);g.scale(Si||Zb?window.devicePixelRatio||1:1);e=a.a.xh||g}else e=a.a.xh;t:{g=a=0;null!==e&&(a=e.width,g=e.height);e=16/9;a>Math.round(e*g)&&(a=Math.round(e*g));a*=g;e=null;for(g=0;g<d.length;g++){e=d[g];var h=e.getInfo(),h=h.a.width*h.a.height*("medium"==e.Re()?0.26:0.85)>a,k=!0;e.a&&c&&(k=e.b.info.b+e.g.info.b<c);if(!h&&k){c=e;
-break t}}c=e}c||(c=b.j[0]);return c}function Wy(a,b){var c=null,d=fk.indexOf(b);if(0<=d)for(;d<fk.length&&!(c=km(a,fk[d]));d++);return c};function Yy(){this.b=this.a=NaN}function Zy(a,b,c){if(a.a==b)return 500<c-a.b;a.a=b;a.b=c;return!1};var $y=[102,107,108];var eh=[0.25,0.5,1,1.5,2];function az(a,b){this.state=a;this.a=b}function Ho(a,b){return P(a.state,b)&&!P(a.a,b)?1:!P(a.state,b)&&P(a.a,b)?-1:0};function bz(a,b){R.call(this);this.la=new Yy;this.A=new xj(v(this.getCurrentTime,this),v(this.fq,this),v(this.hg,this));L(this,this.A);this.O=NaN;this.P=this.I=null;this.o=a;this.ja=new Ty(a);this.da=NaN;this.ga=!1;this.g=this.j=null;this.Q=[];this.V=!1;this.ha=NaN;this.i=new tj;this.B=b;this.J=this.Y=null;this.G=NaN;this.L=new Ko(this);this.b=this.a=null;this.aa=NaN;this.k=null}y(bz,R);f=bz.prototype;
-f.H=function(){I(this.aa);I(this.xa);jf(this.ha);cz(this);sn(this);Ug(this.j,this.J,this.L,this.a);this.a=this.L=this.i=this.j=this.P=this.la=null};
-function dz(a,b){a.V=!1;a.O=NaN;a.b&&nj(a.b);ez(a);cz(a);Ug(a.j,a.a);a.j=null;a.A.reset();if(2==a.B||ok(a.o.Y,lk))b.Y=!1,b.rn=!0;a.a=b;a.a.D("dataupdated",a.Rt,a);a.a.D("dataloaded",a.Qt,a);a.a.D("onStatusFail",a.Pt,a);if(b.nf&&b.nf>b.ya){var c=b.nf;a.P&&(a.Rh(a.va),a.va=null);a.P=new $h(1E3*c,2147483646);a.P.Eb.D("onEnter",a.lg,a);a.xk(a.P)}fz(a,"newdata")}function cz(a){jf(a.da);a.k&&(Tg(a.k),a.k=null)}f.getVideoData=function(){return this.a};f.K=function(){return this.o};
-function gz(a){return!(!a.a||!a.a.j.length)}function hz(a){if(a.a&&(a.a.M||a.a.gf))return!0;ex(a,2);return!1}function iz(a){if(!a.V){var b=new tj;jz(a,uj(b,b.b|8));a.k&&(b=a.k,b.A=x(),b=b.i,b.i.vps=["0.000:N"],b.G=x(),b.F=hf(v(b.ng,b),1E4),b.j.start());a.V=!0;!hz(a)||a.a&&a.a.Fe||(gz(a)||hm(a.a,a.o.mg),gz(a)?kz(a):a.a.Fe||(lz(a)?kz(a):(b=Px(a.o,a.a),pm(a.a,b))))}}
-function mz(a){if(!a.Q.length){if(!a.A.ug){var b=a.A;b.g=Cj(b);b.ug=!0;b.Xb()}a.Q.length||0<Ji(a.A.b,-2147483648).length||a.u("playbackready",a)}}f.or=function(){var a=this.k,b=this.a.Rj;a.V!=b&&(nz(a,{metric:"heartbeat",tpmt:this.a.Ae}),a.V=b)};function kz(a){a.Q=ab(a.a.I);a.a.eb&&(oz(a,a.a.ra),pz(a,!0));gh(a,"i");a.u("playbackdataloaded")}f.lg=function(a){qz(this);jz(this,!1==a?new tj:new tj(wj()))};
-function Ch(a,b,c){b={event:"streamingerror",ec:b,v:a.a.M};c&&(b.em=c);w(b,Ox(a.o));a.k&&rz(a.k,b,void 0)}function ex(a,b,c,d){if(Lb(Xw,c))var e=c;else var g=c;jz(a,uj(a.i,128,{errorCode:b,errorDetail:d,message:g,messageKey:e}))}function sz(a,b){a.Q=a.Q.filter(function(a){return b!=a});mz(a)}f.hg=function(){return P(this.i,8)&&!P(this.i,64)&&!P(this.i,2)};function lz(a){return!(!a.a||!a.a.M&&!a.a.gf||a.a.M)}f.fq=function(){return this.i};function tz(a,b){a.b&&sn(a);a.b=b;uz(a)}
-function sn(a){a.g=null;a.b&&(ez(a),a.L.removeAll(),nj(a.b),a.b=null)}function vz(a){if(a.b){var b=lm(a.a);if(a.a.o&&a.a.o.a){var b=a.a.o,c=b.g,d=b.b;a.g||(a.j||wz(a,b),a.g=new Il(a.b,a.a.ra,c.info.Jb,d.info.Jb),b=a.g,b.b||(b.b=b.g.ht?b.g.a.webkitMediaSourceURL:window.URL.createObjectURL(b.g)),a.za=new Kl(b.b,!1,!0),b=v(a.j.gt,a.j),a.g.j=b);b=a.za}a.b.Bd!=b?xz(a,b):(P(a.i,64)&&jz(a,uj(a.i,a.i.b|8)),lj(a.b),a.a.Cb&&!a.a.eb&&yz(a,Infinity))}}
-function gh(a,b,c){if(!a.ka()&&gz(a)&&!P(a.i,128)){var d="m"==b,e="m"==a.a.kd;if(d||!e){d&&"auto"==c&&(b="a",d=!1);c&&(a.a.ff=c);var g=NaN;!a.Y||a.o.xa&&"play"!=a.o.La||a.o.oh||(g=a.j?zy(a.j):Wh(a.Y),"i"==b&&(g=a.o.Jc?0.4*g:0.6*g));var h;if(a.o.Hc&&"i"==b){h=a.ja;var k=a.a,m=Wy(k,"medium");m||(m=Xy(h,k,g));h=m}else h=Vy(a.ja,a.a,g);k=h;h=k.getInfo();g=k.a?k.b.info:h;if(a.a.a!=h||a.a.la!=g||d!=e)a.a.o=k,a.a.a=h,a.a.la=g,a.a.kd=b,c&&(a.a.ff=c),k.a?a.j?(c=a.j,e=k.g,k=d,c.ka()||(c.o=k,c.b.b!=e&&(c.b.b=
-e,wy(c),k&&dy(c.b),e.i||Ky(c,c.b,!1),ty(c)))):wz(a,k):a.hg()&&vz(a),c=b,a.k&&(e=Vy(a.ja,a.a),b=a.k.i,c=new Sy(a.a,h,c,e.xe.Oa),zz(b,"vfs",[c.a.Oa,c.b,b.A,c.g]),b.A=c.a.Oa,c=yw(b.a),0<c.width&&0<c.height&&zz(b,"view",[Math.round(c.width),Math.round(c.height)]),zz(b,"vps",[b.b]),b.ng()),a.u("internalvideoformatchange",a.a,d)}}}
-function wz(a,b){var c=a.o,d=new Ly;if(c.xa||c.oh)d.F=NaN;c.jd&&(d.o=0);c.gd&&(d.j=3);c.Il&&(d.J=1,d.I=49152);c.kd&&(d.P=30);c.ag&&(d.a=700);c.kb&&(d.i=3);c.mc&&(d.i=1.5,d.g=1048576);c.Zf&&(d.Q=2);c.$f&&(d.L=3);"play"==c.La&&(d=Ob(d),d.G=10,d.B=20,d.k=NaN,d.A=10485760,d.O=1048576,d.b=!1,c.bg&&(d.b=!0));Vi&&dj("crkey")&&(c=Ob(d),c.j=3.5,c.G=20,c.B=40,c.A=20971520,c.b=!0,c.a=700,c.o=2,d=c);a.j=new ry(a.Y,d,b.b,b.g);a.j.D("bandwidthchange",a.bq,a);a.j.D("fatalerror",a.cq,a);a.j.D("softerror",a.dq,a);
-c=a.j;d=(d=a.a.ya)||0;wy(c);0==d&&(c.i.b.i||Ky(c,c.i,!0),c.b.b.i||Ky(c,c.b,!0));Iy(c,d);uy("gv");H(v(c.dm,c),0)}f.bq=function(){gh(this,"a")};f.cq=function(a){ex(this,a)};f.dq=function(a){Ch(this,a);if(this.k)this.k.onError(a)};function qz(a){P(a.i,64)&&jz(a,uj(a.i,a.i.b&-9));a.b&&a.b.pause()}
-function yz(a,b,c,d){if(a.b){if(a.b){b=b||0;var e=1>a.b.seekable.length?NaN:a.b.seekable.end(a.b.seekable.length-1);a.j&&!isNaN(Math.floor(Math.min(by(a.j.i),by(a.j.b))))&&(e=Math.floor(Math.min(by(a.j.i),by(a.j.b))));b>e&&(b=e,pz(a,!0));0>b&&(b=0)}else b=0;a.a.ya=b;a.G=b;c?a.Sh():(Az(a),d&&(a.J||(a.J=new Oo(a.Sh,d,a)),a.J.start()),Bz(a,!0));a.P&&b>a.a.nf&&(a.Rh(a.va),a.va=null);a.u("seekto",a,b)}else a.a.ya=b||0}
-function Az(a){P(a.i,32)||(jz(a,uj(a.i,a.i.b|32)),P(a.i,8)&&qz(a),a.u("beginseeking",a))}f.Sh=function(){if(!isNaN(this.G)&&this.b){var a=this.od();!this.a.Cb&&this.G>=Math.floor(a)?(this.G=a,this.u("endseeking",this),qz(this),this.lg()):(this.j&&Iy(this.j,this.G),jj(this.b,this.G))}this.J&&(this.J.dispose(),this.J=null);P(this.i,32)&&(jz(this,uj(this.i,this.i.b&-33)),this.u("endseeking",this))};
-f.getCurrentTime=function(){if(!isNaN(this.G))return this.G;var a=0;this.b?a=this.b.getCurrentTime():this.a&&(a=this.a.pe);return a};f.od=function(){var a=0;this.b&&(a=this.b.Rd);0==a&&this.a&&(a=this.a.ra);return a};f.qq=function(){var a=new Vx;if(this.Y){var b=this.Y;a.g=b.g;a.j=b.i;a.a=Wh(b)}this.j?(b=this.j,b.g&&(a.b=Wx(b.g.rd.buffered,b.k),a.i=Wx(b.g.Zb.buffered,b.k)),a.a=zy(b),Wh(b.j),Uh(b.j),Vh(b.j)):this.b&&(a.b=Wx(this.b.buffered,this.getCurrentTime()));return a};
-function Cz(a,b){var c=isNaN(b)?a.getCurrentTime():b,d=a.od();return Infinity==d?1:d?c/d:0}f.sq=function(){var a;if(this.a){a=this.a;var b={};a.a&&(b.fmt=a.a.Oa,a.la&&(b.afmt=a.la.Oa));a.P&&(b.threed=a.Hc);b.plid=a.fb;b.ei=a.k;b.list=a.Ta;b.cpn=a.Da;a.M&&(b.v=a.M);a.Dj&&(b.infringe=1);a.Ld&&(b.splay=1);a.Cb&&(b.live=a.eb?"dvr":"live");a.df&&(b.autoplay=1);a.ga&&(b.sdetail=a.ga);a.md&&(b.partnerid=a.md);a=b}else a={};return a};
-function Dz(a,b){var c={};if(b){if(a.k){var d=Ez(a.k);d&&w(c,d.Mh())}a.b&&w(c,{vct:a.b.currentTime.toFixed(3),vd:a.b.duration.toFixed(3),vpl:qj(a.b.played),vbu:qj(a.b.buffered),vpa:a.b.paused,vsk:a.b.seeking,vpr:a.b.playbackRate,vrs:a.b.readyState,vns:a.b.networkState,vec:a.b.error?a.b.error.errorCode:null});if(a.j){var d=a.j,e={lct:d.k.toFixed(3),lsk:d.B,lmf:d.o,lbw:Wh(d.j).toFixed(3),lhd:Uh(d.j).toFixed(3),ltd:Vh(d.j).toFixed(3),laa:d.i.i?uk(d.i.i):"",lva:d.b.i?uk(d.b.i):"",lar:d.i.g?uk(d.i.g):
-"",lvr:d.b.g?uk(d.b.g):""};d.g&&!d.g.Gb()&&(e.lab=qj(d.g.Zb.buffered),e.lvb=qj(d.g.rd.buffered));w(c,e)}P(a.i,384)&&(c.debug_error=a.i.a)}c.debug_videoId=a.a.M;return c}f.xk=function(a){this.A.cx(a)};f.Rh=function(a){this.A.fx(a)};f.Qt=function(a){this.u("commoninfoloaded",a);fz(this,"dataloaded");hm(this.a,this.o.mg);this.V&&kz(this)};f.Rt=function(){fz(this)};f.Pt=function(a){ex(this,parseInt(a.errorcode,10),unescape(a.reason),a.errordetail)};
-function fz(a,b){a.u("internalvideodatachange",b||"dataupdated",a,a.a)}function uz(a){z("loadstart loadeddata loadedmetadata play playing pause ended suspend progress seeking seeked timeupdate durationchange error waiting abort".split(" "),function(a){this.L.listen(this.b,a,this.Lv)},a)}
-f.Lv=function(a){var b=a.target;if(b==this.b&&b.currentSrc){switch(a.type){case "durationchange":this.a.eb||(b.Xa(b.duration||0),b=b.Rd,(!this.g||isFinite(b)&&0<b)&&oz(this,b));break;case "ended":jz(this,uj(this.i,4));break;case "loadedmetadata":this.a.ya&&(this.b.currentTime=this.a.ya),this.o.bm&&this.a.ya&&(this.O=this.a.ya,this.b.pause());case "loadeddata":this.aa&&I(this.aa);break;case "loadstart":jf(this.ha);this.ha=hf(v(this.cn,this),100);var b=this.L,c=this.b,d=v(this.cn,b.Ig),c=xf(c,d);b.ae.push(c);
-break;case "progress":this.O&&this.b.seekable.length&&this.b.seekable.end(0)>this.O&&(this.b.currentTime=this.O,this.O=NaN,this.pa=this.L.listen(this.b,"canplay",this.ft));case "suspend":Bz(this);this.u("onLoadProgress",this,this.b?ih(this.b):0);break;case "seeking":Fz(this);break;case "timeupdate":Fz(this),Bz(this),this.u("onVideoProgress",this,b.getCurrentTime())}this.u("videoelementevent",a);t:if(b=this.i,d=this.la,P(b,128))a=b;else{var c=b.b,e=b.a,g=a.target;switch(a.type){case "ended":if(0>=
-g.networkState)break;c=wj();e=null;break;case "pause":P(b,32)||P(b,2)||(c=4,P(b,1)&&P(b,8)&&(c|=1),e=null);break;case "playing":c=8;e=null;break;case "abort":if(64==c)break;case "error":c|=256;a=g.error;d=107;if(a&&a.code)switch(a.code){case a.MEDIA_ERR_ABORTED:d=200;break;case a.MEDIA_ERR_NETWORK:d=201;break;case a.MEDIA_ERR_DECODE:d=202;break;case a.MEDIA_ERR_SRC_NOT_SUPPORTED:d=203}e={errorCode:d};Ta(sj,e.errorCode)&&(c|=128);break;case "canplay":c&=-2;break;case "progress":P(b,8)&&(g=a.target.getCurrentTime(),
-d&&Zy(d,g,a.timeStamp)&&(c|=1));break;case "seeked":c&=-18;break;case "seeking":c|=16;g.inUnbufferedArea()&&(c|=1);c&=-3;break;case "waiting":P(b,2)||(c|=1);break;case "timeupdate":P(b,16)||(c&=-2);c&=-65;break;default:a=b;break t}a=uj(b,c,e)}jz(this,a)}};
-f.cn=function(){if(this.b&&0<this.b.getCurrentTime()&&0<this.b.Rd&&!this.a.Im){jf(this.ha);this.a.Im=!0;if(this.k){var a=this.k;if(!a.g){var b=Ez(a,"playback");a.a.Xl&&(a.L=[10+a.a.Vf,10,10,40+a.a.nh-a.a.Vf,40],jf(a.I),a.I=NaN,a.I=hf(v(a.ha,a),100),b.cg=Gz(a,!0));b.dg=!0;b.A=a.j();b.send();if(a.b.Nc&&!a.g){var b=a.b,c=a.a,b={noflv:"1",html5:"1",video_id:c.M,cpn:c.Da,plid:c.fb,ei:c.k,referrer:Rx(b),eurl:b.b,framer:b.P,feature:b.j,fmt:c.a?c.a.Oa:0,ptk:c.A,skl:c.Yl,access_token:c.G,ucid:c.lc};w(b,Hz(a));
-b=S(a.b.lb+"user_watch",b);sa(b)}a.a.A&&sa(S(a.b.lb+"ptracking",{html5:"1",video_id:a.a.M,cpn:a.a.Da,plid:a.a.fb,ei:a.a.k,ptk:a.a.A,oid:a.a.Va,ptchn:a.a.Ra,pltype:a.a.jb,content_v:a.b.k}));if(a.a.Wl&&a.b.ze&&!a.g){var b=a.b,c=a.a,d={noflv:1,video_id:c.M,cpn:c.Da,el:b.Z,ps:b.La,referrer:Rx(b),eurl:b.b,framer:b.P,fmt:c.a?c.a.Oa:0,ptk:c.A,subscribed:c.g,t:c.hd};b.Tb&&(d.autoplay="1");c.Ld&&(d.splay="1");0<c.ya&&(d.start=1E3*c.ya);c.gj&&(d.tmi="1");b=S(a.Q,d);sa(b)}a.a.fg&&nz(a,{metric:"playback"});a.g=
-!0}}jf(this.da);this.a.fg&&(this.k.g||this.a.Vl)&&(this.da=hf(v(this.or,this),3E4));this.u("playbackstarted")}};f.ft=function(){this.pa&&(this.L.ac(this.pa),this.pa=void 0,lj(this.b))};
-function Bz(a,b){if(a.b){var c=a.getCurrentTime();if(a.j){var d=a.j;if(!d.B||d.k<=c&&c<d.k+10)d.k=c,d.B=!1;Ey(d)}a.a.eb&&c>a.od()&&(d=a.od(),0==d&&(d=c),oz(a,1.2*d));var d=Cz(a),e=0;a.b.buffered&&0<a.b.buffered.length&&(a.a.eb?a.ga||(e=(1>a.b.seekable.length?NaN:a.b.seekable.end(a.b.seekable.length-1))/a.od()):e=a.b?ih(a.b):0);5<c&&(a.a.ya=c);a.xa&&I(a.xa);a.b.paused||a.b.ended||(a.xa=a.b.played&&0==a.b.played.length?H(v(a.Xm,a),100):H(v(a.Xm,a),1E3));a.a.pe=c;if(!b&&a.hg()){var g=a.a.Rj,h=a.a.pe;
-0<g&&h>g&&(a.a.Ae+=h-g);a.a.ra&&a.a.J&&a.a.Ae>=a.a.J&&(g=a.k,g.g&&g.a.J&&(h=Ez(g,"delayplay"),h.$i=!0,h.A=g.j(),h.send()),a.a.J=NaN)}if(a.a.Zl&&(g=a.a.Yj,h=a.a.pe,1==g&&0<h||2==g&&20<=h||3==g&&30<=h)){g=a.k;if(g.g){var h=g.b,k=g.a,g={ns:"yt",html5:"1",docid:k.M,plid:k.fb,ei:k.k,cpn:k.Da,fmt:k.a?k.a.Oa:0,el:h.Z,ps:h.La,subscribed:k.g,yttk:"1",st:g.j(),et:g.j(),ctp:k.Yj,vid:h.aa},g=S("//s2.youtube.com/s",g);sa(g)}a.a.Yj++}a.u("progresssync",a,c,d,e,b);a.a.Rj=c}}
-f.Xm=function(){this.b&&(this.b.Yo(),P(this.i,8)&&Zy(this.la,this.getCurrentTime(),Date.now())&&jz(this,uj(this.i,this.i.b|1)),Bz(this))};
-function jz(a,b){if(b.b!=a.i.b||b.a!=a.i.a){var c=new az(b,a.i);a.i=b;a.o.tg&&P(b,8)&&0<Ho(c,256)&&201==b.a.errorCode&&setTimeout(v(function(){this.b&&(this.a.o&&!this.a.o.a&&this.b.load(),vz(this))},a),500);0>Ho(c,8)&&pz(a,!1);0<Ho(c,32)&&pz(a,!1);a.a&&a.a.Cb&&a.a.eb&&P(c.state,2)&&(oz(a,a.getCurrentTime()),Bz(a,!0));P(b,256)&&Iz(a,b);a.k&&Jz(a.k,c);Aj(a.A,c);a.u("statechange",c)}}
-function Iz(a,b){var c=b.a;jf(a.da);if(a.a&&a.a.fg&&Ta($y,c.errorCode)){var d=a.k,c=c.errorCode;d.Y||(d.Y=new Rn("error-__ec__"));c={metric:Vn(d.Y,{ec:c})};nz(d,c)}}function Fz(a){P(a.i,2)||P(a.i,32)||(a.G=NaN)}function pz(a,b){a.a&&a.a.eb&&a.ga!=b&&(a.ga=b,a.u("liveviewshift",b))}function xz(a,b){a.o.za&&pj(a.b,b.a||ok(b.b,kk));hj(a.b,b);a.g&&!b.a&&(a.g=null);a.a.a&&a.a.a.g&&Kz(a);I(a.aa);a.aa=H(v(a.mu,a),15E3);a.o.fm?H(v(function(){lj(this.b)},a),0):lj(a.b)}
-function Kz(a){var b=a.a.a&&a.a.a.g||null;b&&!a.I&&a.b&&((b=Dl(a.b,a.a.a.Jb,b))?(a.I=new Qy(a.b,b,v(a.hu,a),v(a.gu,a)),a.I.A=a.a.G,L(a,a.I)):ex(a,203,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK"))}function ez(a){a.I&&(a.I.dispose(),a.I=null)}f.hu=function(a){var b=Ox(this.o);b.cpn=this.a.Da;this.a.Q&&(b.vvt=this.a.Q);Rb(a.F,b);Jh(a,a.k);this.u("newlicensesession",a)};f.gu=function(a,b,c){ex(this,c?5:206,q(b)?b:"ERROR_LICENSE",a)};f.mu=function(){Ch(this,102);if(this.k)this.k.onError(102);this.u("loadsofttimeout")};
-function oz(a,b){a.b&&a.b.Xa(b);a.a.ra!=b&&(a.a.ra=b,fz(a))};function Lz(){}ca(Lz);f=Lz.prototype;f.jc=null;f.Ji=null;f.load=function(a){if(this.jc)return po(this.jc);this.jc=new io;this.Ji=a?a:"3";oo(ro("3.1"==this.Ji?"//s0.2mdn.net/instream/html5/ima3.js":"//s0.2mdn.net/instream/html5/ima.js",{timeout:1E4}),this.Cx,this.Jp,this);return this.jc};f.getVersion=function(){return this.Ji};f.Cx=function(){"3.1"==this.Ji&&this.jc?this.jc.b():(google.ima.SdkLoader.setCallbacks(v(this.jc.b,this.jc),v(this.Mv,this)),google.ima.SdkLoader.load("3",void 0))};
-f.Mv=function(a){this.Jp(Error("Google Ads SDK Failed to load: "+a))};f.Jp=function(a){this.jc.a(a)};function Mz(a){return a?-1!=a.toString().search(/(?:true|1)/i):!1}function Nz(a,b){if(a){var c="getErrorCode"in a?a.getErrorCode():null;c?b.error_code=c:(c="getMessage"in a&&ha(a.getMessage)&&"3.1"==Lz.getInstance().getVersion()?a.getMessage():a.message,50<c.length&&(c=c.substring(0,47)+"..."),b.error_message=c)}}
-function Oz(a,b){if(a&&"3.1"==Lz.getInstance().getVersion()){var c=a.getAdId();if(c){var d=a.getWrapperAdIds()||[];b.ad_id=$a(d,c).join(",");if(c=a.getAdSystem())d=a.getWrapperAdSystems()||[],b.ad_sys=$a(d,c).join(",");a.isSkippable()&&(b.skip=1)}}}function Pz(a,b){if(a[b])return Mz(a[b]);var c=b.toLowerCase(),d;for(d in a)if(d&&d.toLowerCase()==c)return Mz(a[d]);return!1}
-function Qz(a){var b="";a&2&&a&1?b="video":a&2?b="skippablevideo":a&1&&(b="standardvideo");a&4&&(b&&(b+="_"),b+="text_image_flash");return b};function Rz(){var a=n("yt.www.watch.ads.handleSetAfvCompanionVars");a&&a()}function Sz(a){var b=n("yt.www.watch.ads.handleMoveGutCompanion");b&&b(1==a?!0:!1)}function Tz(a){var b=n("yt.www.watch.ads.handleShowAfvCompanionAdDiv");b&&b(0<(a&3))}function Uz(){var a=n("yt.www.watch.ads.handleHideCompanion");a&&a()};function Vz(a,b){return Ta(a.o,b)};function Wz(a,b){this.a=a;this.g=b}Wz.prototype.j=null;Wz.prototype.b=NaN;function Xz(a,b,c){a.a.u("AD_LOGGING_EVENT",b,c)}function Yz(a){Zz(a);var b=$z(a);if(a.i){var c=aA(a.g),d=a.i.y-c.top,d=Math.round(a.i.x-c.left)+"x"+Math.round(d);b.ck_xy=d;b.ck_wh=c.width+"x"+c.height}Xz(a,15,b)}function bA(a){Zz(a);var b=$z(a);if(isNaN(a.b))Zz(a);else{var c=x()-a.b;b.ad_stl=c}Xz(a,4,b)}function cA(a){Zz(a);var b=$z(a),c=a.a.Xo();c?b.ad_fmt=c:Zz(a);Xz(a,5,b)}
-function $z(a){var b={},c=a.a.ia,d=a.a.wf(),e=a.a.Go();Oz(a.a.Ng(),b);d&&0<d&&(b.ad_len=d);c&&c.M?b.ad_v=c.M:e&&(c=Ij(e),b.ad_dom=c,a.g.ea.k||Vz(a.g.K(),"921806")||Vz(a.g.K(),"921805"))&&(b.ad_v_url=e);b.at=a.a.getType();return b}function Zz(a){a.j||(a.j="InstreamAdDisplay ("+a.a.getType()+")")};function dA(a,b,c,d){R.call(this);this.a=b;this.a.D("onVolumeChange",this.ct,this);this.a.D("control_toggle_play_pause",this.Ym,this);this.a.D("control_play",this.Jh,this);this.a.D("control_pause",this.Xj,this);this.b=c;this.j=d;this.i=new Wz(this,this.a);this.o=a+"_2";this.g=new Ko(this)}y(dA,R);f=dA.prototype;f.ab=null;f.ia=null;f.Kf=!1;f.Rg=null;f.Qg=null;f.Vg=null;
-f.show=function(){this.i.b=x();var a="";if("3.1"==eA())a=this.j;else{var b=null;try{b=this.b.getSelectedCreative(),a=b.getMediaUrl("video/x-flv")||b.getMediaUrl("video/mp4")||b.getMediaUrl("video/webm")}catch(c){fA(this,c);return}}if(a){b=Gj(a);b=b.v||b.video_id;if(!b){var d=ge(a).match(/^\/watch\/([^\/]*)$/i);d&&(b=d[1])}b||(a=a.match(/yt_vid\/([a-zA-Z0-9_-]{11})/),null!=a&&1<a.length&&(b=a[1]));a=b?new nh({video_id:b,dash:"0"}):null}else a=null;this.ia=a;var e;this.ia?(this.ia.Ld=!0,e={video_id:this.ia.M},
-this.ia.D("onStatusFail",this.yn,this),this.ia.D("dataloaded",this.xn,this),a=this.a.K(),a=new Ix(a.a),a.Z="adunit",a.Tb=!0,a=Px(a,this.ia),pm(this.ia,a)):gA(this);hA(this.a,-1,e);this.$m()};function iA(a){a.ia&&(a.ia.$("onStatusFail",a.yn,a),a.ia.$("dataloaded",a.xn,a))}
-f.xn=function(){iA(this);var a=this.a.K();hm(this.ia,a.mg);(a=Vy(new Ty(this.a.K()),this.ia))?(a=a.i)?(a=new re(ij(a)),a.a.set("autoplay","1"),a=a.toString(),"3.1"==eA()?this.b.setMediaUrl(a):this.b.getSelectedCreative().setMediaUrl(a),gA(this)):fA(this,Error("Failed to determine ad media resource.")):fA(this,Error("Failed to determine ad media format."))};
-function gA(a){Sz(1);Tz(1);a.a.K();var b=a.a.b,c=rn(b);b.X.K().tb||bd(c)||nn(b).appendChild(c);a.ab=c;a.Vg=Q(a.a.a);a.a.ea.L?F(E("video-ad-status-bar")):(b=Q(a.a.a),a.Rg=E("video-ad-time-left",b),b=E("html5-ad-progress-list",b),c=Xc("div"),Em(c,["html5-ad-progress","html5-progress-section"]),b.appendChild(c),a.Qg=c,a.g.listen(a.ab,"timeupdate",a.bu));Em(a.Vg,["ad-showing","ad-interrupting"]);a.g.listen(qn(a.a.b),"mouseup",a.fu);a.g.listen(a.ab,"waiting",a.$m);a.a.D("onResize",a.zk,a);try{a.g.listen(a.b,
-google.ima.AdErrorEvent.Type.AD_ERROR,a.du);a.g.listen(a.b,google.ima.AdEvent.Type.CLICK,a.cu);a.g.listen(a.b,google.ima.AdEvent.Type.COMPLETE,a.eu);a.g.listen(a.b,google.ima.AdEvent.Type.PAUSED,a.Kn);a.g.listen(a.b,google.ima.AdEvent.Type.STARTED,a.Ln);a.zk();var d=a.a,e=d.b,g=jA(d);e.X.K().tb&&(Ad(e.a,g),pd(e.a,0,0));a.b.start()}catch(h){fA(a,h)}}
-f.Ln=function(){this.Kf=!0;this.k||(this.k=!0,bA(this.i),kA(this.a,1));if(0==this.wf()){var a=this.ab;a.Xa(a.duration||0)}this.a.mb(!0);hA(this.a,1);this.u("adPlay",this)};f.Kn=function(){this.Kf=!1;this.a.mb(!1);hA(this.a,2)};f.eu=function(){cA(this.i);this.Kf=!1;hA(this.a,0);kA(this.a,2);this.u("adEnd",this)};f.du=function(a){fA(this,a.getError())};function fA(a,b){a.Kf=!1;hA(a.a,0);a.u("adError",b)}f.yn=function(){iA(this);fA(this,Error("Request to get video data failed."))};
-f.cu=function(){Yz(this.i);"3.1"==eA()||this.a.ea.Q||H(v(this.Jh,this),0);this.u("select")};f.fu=function(a){a=new A(sf(a),tf(a));this.i.i=a};f.bu=function(){var a=Dn(this.b.getRemainingTime());this.Rg.innerHTML=a;0==this.wf()&&(a=this.ab,a.Xa(a.duration||0));a=this.wf()?this.ab.getCurrentTime()/this.wf():0;a=Math.round(1E3*a)/10;this.Qg.style.width=a+"%"};f.$m=function(){!this.Kf&&this.k||hA(this.a,3)};
-f.H=function(){this.a.$("control_toggle_play_pause",this.Ym,this);this.a.$("control_play",this.Jh,this);this.a.$("control_pause",this.Xj,this);this.a.$("onResize",this.zk,this);this.g.removeAll();iA(this);this.b.destroy();this.ab&&(on(this.a.b),this.ab=null);this.Rg&&(this.Rg.innerHTML="",this.Rg=null);this.Qg&&(F(this.Qg),this.Qg=null);this.Vg&&(Fm(this.Vg,["ad-showing","ad-interrupting"]),this.Vg=null);dA.C.H.call(this)};f.getType=function(){return this.o};f.Ng=function(){return this.b.getCurrentAd()};
-f.wf=function(){return this.ab?this.ab.Rd:null};f.Xo=function(){return this.ab?this.ab.getType():null};f.Go=function(){return this.ab&&this.ab.currentSrc?this.ab.currentSrc:null};f.ct=function(a){a=a.muted?0:a.volume;isNaN(a)||(a=wb(a/100,0,1),this.b.setVolume(a))};f.Ym=function(){this.Kf?this.Xj():this.Jh()};f.Jh=function(){this.ab&&(this.b.resume(),this.Ln())};f.Xj=function(){this.ab&&(this.b.pause(),this.Kn())};f.zk=function(){var a=jA(this.a);this.b.resize(a.width,a.height,google.ima.ViewMode.NORMAL)};function lA(a,b,c){R.call(this);this.a=b;this.a.D("control_toggle_play_pause",this.Wm,this);this.a.D("control_play",this.Ih,this);this.a.D("control_pause",this.Vj,this);this.b=c;this.j=new Wz(this,this.a);this.o=a+"_2";this.i=new Ko(this);this.g=mA(b);this.g.D("statechange",this.Um,this);this.g.D("internalvideodatachange",this.Vm,this);this.ia=null}y(lA,R);f=lA.prototype;f.bl=!1;f.Bg=null;f.Ag=null;f.Cg=null;
-f.show=function(){var a=this.a;nA(a.app,mA(a));this.j.b=x();Sz(1);Tz(1);this.Cg=Q(this.a.a);if(this.a.ea.L)F(E("video-ad-status-bar"));else{a=Q(this.a.a);this.Bg=E("video-ad-time-left",a);var a=E("html5-ad-progress-list",a),b=Xc("div");Em(b,["html5-ad-progress","html5-progress-section"]);a.appendChild(b);this.Ag=b;this.g.D("progresssync",this.an,this)}Em(this.Cg,["ad-showing","ad-interrupting"]);this.i.listen(qn(this.a.b),"mouseup",this.wt);this.a.D("onResize",this.$j,this);try{this.i.listen(this.b,
-google.ima.AdErrorEvent.Type.AD_ERROR,this.ut),this.i.listen(this.b,google.ima.AdEvent.Type.CLICK,this.tt),this.i.listen(this.b,google.ima.AdEvent.Type.COMPLETE,this.vt),this.i.listen(this.b,google.ima.AdEvent.Type.PAUSED,this.gn),this.i.listen(this.b,google.ima.AdEvent.Type.STARTED,this.hn),this.$j(),this.b.start()}catch(c){oA(this,c)}};f.Vm=function(a,b,c){"newdata"==a&&this.ia!=c&&hA(this.a,-1,{video_id:c.M});this.ia=c};f.Um=function(a){a=a.state;P(a,128)&&oA(this,Error(a.a.message||"Video player error."))};
-f.hn=function(){this.bl=!0;this.k||(this.k=!0,bA(this.j),kA(this.a,1));hA(this.a,1);this.u("adPlay",this)};f.gn=function(){this.bl=!1;hA(this.a,2)};f.vt=function(){cA(this.j);hA(this.a,0);kA(this.a,2);this.u("adEnd",this)};f.ut=function(a){oA(this,a.getError())};function oA(a,b){a.g.lg();hA(a.a,0);a.u("adError",b)}f.tt=function(){Yz(this.j);"3.1"==eA()||this.a.ea.Q||H(v(this.Ih,this),0);this.u("select")};f.wt=function(a){this.j.i=new A(a.pageX,a.pageY)};
-f.an=function(a,b,c){this.Bg.innerHTML=Dn(a.od()-b);a=Math.round(1E3*c)/10;this.Ag.style.width=a+"%"};
-f.H=function(){this.a.$("control_toggle_play_pause",this.Wm,this);this.a.$("control_play",this.Ih,this);this.a.$("control_pause",this.Vj,this);this.a.$("onResize",this.$j,this);this.i.removeAll();this.g.D("statechange",this.Um,this);this.g.$("internalvideodatachange",this.Vm,this);this.g.$("progresssync",this.an,this);var a=this.a;a.g&&pA(a.app,a.g);this.b.destroy();this.Bg&&(this.Bg.innerHTML="",this.Bg=null);this.Ag&&(F(this.Ag),this.Ag=null);this.Cg&&(Fm(this.Cg,["ad-showing","ad-interrupting"]),
-this.Cg=null);lA.C.H.call(this)};f.getType=function(){return this.o};f.Ng=function(){return this.b.getCurrentAd()};f.wf=function(){return this.g.od()};f.Xo=function(){return this.ia&&this.ia.a?this.ia.a.Jb:null};f.Go=function(){if(!this.ia)return null;var a=lm(this.ia);return a?ij(a):null};f.Wm=function(){this.bl?this.Vj():this.Ih()};f.Ih=function(){this.b.resume();this.hn()};f.Vj=function(){this.b.pause();this.gn()};f.$j=function(){var a=jA(this.a);this.b.resize(a.width,a.height,google.ima.ViewMode.NORMAL)};function qA(a,b){this.b=a;this.a=b;this.b.getType()}function rA(a,b,c){a.b.u("AD_LOGGING_EVENT",b,c)}function sA(a){var b={};Oz(a.b.Ng(),b);a.j&&a.g&&(b.ot=a.g-a.j);var c;c=a.a.a.app.K().pb||a.a.ea.k?2:a.a.K().Nd?1:0;b.ad_ps=c;b.at=a.b.getType();return b};function tA(a,b,c){R.call(this);this.b=b;this.a=c;this.i=new qA(this,b);this.k=a+"_1";this.g=new Ko(this)}y(tA,R);f=tA.prototype;f.Xd=null;f.fn=!1;
-f.show=function(){V(Q(this.b.a),"ad-showing");this.Xd=nn(this.b.b);V(this.Xd,"ad-overlay");this.g.listen(this.Xd,"mouseup",this.nt);try{Gd(this.Xd);this.g.listen(this.a,google.ima.AdEvent.Type.USER_CLOSE,this.jt);this.g.listen(this.a,google.ima.AdEvent.Type.CLICK,this.lt);this.g.listen(this.a,google.ima.AdErrorEvent.Type.AD_ERROR,this.kt);uA(this,google.ima.ViewMode.NORMAL);this.zg();this.a.start();var a=this.i;a.j=x();var b=sA(a);rA(a,3,b);this.fn=!0;this.b.D("onResize",this.zg,this);this.b.D("onStateChange",
-this.Zm,this);this.u("adEnd",this)}catch(c){this.u("adError",c)}};f.Ng=function(){return this.a.getCurrentAd()};f.getType=function(){return this.k};f.H=function(){this.g.removeAll();this.b.$("onResize",this.zg,this);this.b.$("onStateChange",this.Zm,this);W(Q(this.b.a),"ad-showing");this.a&&(this.a.destroy(),this.a=null);this.Xd&&W(this.Xd,"ad-overlay");this.Xd=null;tA.C.H.call(this)};f.jt=function(){var a=this.i;a.g=x();var b=sA(a);rA(a,6,b)};
-f.lt=function(){Vm(this.b);var a=this.i;a.g=x();var b=sA(a);if(a.i){var c=aA(a.a),d=a.i.y-c.top,d=Math.round(a.i.x-c.left)+"x"+Math.round(d);b.ck_xy=d;b.ck_wh=c.width+"x"+c.height}rA(a,100,b)};f.nt=function(a){this.i.i=a.target==a.currentTarget?null:new A(a.pageX,a.pageY)};f.kt=function(a){a=a.getError();this.u("adError",a)};f.Zm=function(a){P(a.state,16)&&uA(this,google.ima.ViewMode.NORMAL)};function uA(a,b){a.j!=b&&(a.j=b,a.fn&&a.zg())}
-f.zg=function(){var a=Gd(this.Xd);this.a.resize(a.width,a.height,this.j)};function vA(a,b){R.call(this);this.ca=a;this.a=b}y(vA,R);vA.prototype.show=function(){var a=n("afcAdCall");a&&a();a={};a.ad_id=this.a;a.at=this.getType();this.u("AD_LOGGING_EVENT",3,a);this.u("adEnd",this)};function wA(a,b){tA.call(this,1,a,b)}y(wA,tA);wA.prototype.zg=function(){};wA.prototype.getType=function(){return"1_3"};function xA(a,b,c,d){R.call(this);this.Ba=b;this.b=a;this.start=c;this.g=d;this.a=null}y(xA,R);f=xA.prototype;f.hk=!0;f.qd=!1;f.isVisible=!0;f.Qe="unloaded";f.Ok=!1;function yA(a){return 0==a.start?zA(a)&&AA(a)?-2147483648:0:-1==a.start||-2==a.start?2147483647:1E3*a.start}function zA(a){return"loaded"==a.Qe||"error"==a.Qe}function AA(a){if(!zA(a))throw Error("Preroll status is undefined before ad load.");return 0==a.start&&a.qd}
-function BA(a){a.Qe="loading";var b=a.g.shift();b?(0==a.start&&CA(a.b,"nl"),b=b.create(a.start,a.Ba,a.b),L(a,b),oo(b.load(),a.Hv,a.Gv,a)):(DA(a.b,2,EA(a,{})),a.Qe="error",FA(a))}f.getId=function(){return this.Ba};function GA(a){a.a.$("adEnd",a.yo,a);a.a.$("adError",a.Bo,a);a.a.$("AD_LOGGING_EVENT",a.zo,a);a.a.$("select",a.Ao,a)}f.Gv=function(a){a instanceof jo||BA(this)};
-f.Hv=function(a){this.start=a.startTime;this.a=a.Tt;L(this,this.a);0==this.Ba&&(a=this.a.getType(),this.b.i.at=a);this.a instanceof dA||this.a instanceof lA?this.qd=!0:this.a instanceof vA?this.isVisible=!1:this.a instanceof wA&&(this.isVisible=!1);this.Qe="loaded";FA(this)};function FA(a){a.u("adBreakComplete",a)}
-f.show=function(){this.Ok?this.a instanceof tA&&uA(this.a,google.ima.ViewMode.NORMAL):(this.Ok=!0,this.a instanceof dA&&CA(this.b,"bs"),this.a.D("adEnd",this.yo,this),this.a.D("adError",this.Bo,this),this.a.D("AD_LOGGING_EVENT",this.zo,this),this.a.D("select",this.Ao,this),this.a.show())};f.yo=function(){if(this.qd){GA(this);var a=this.b;a.ea.gd&&!a.qj&&(sa(a.K().lb+"mac_204?action_fcts=1"),a.qj=!0)}FA(this)};f.Bo=function(a){if(a){var b={};Nz(a,b);EA(this,b);HA(this.b,32,b)}GA(this);FA(this)};
-f.zo=function(a,b){EA(this,b);DA(this.b,a,b)};f.Ao=function(){this.hk=!1};function EA(a,b){b.sst=a.start;b.sidx=0};function IA(a){this.iq=a}function JA(a){try{var b=Yv(a).getElementsByTagName("AdBreak"),c=La(b,function(a){a=a.getAttribute("time");return Fa(a)});return new IA(c)}catch(d){return new IA([0])}};function KA(a,b,c,d){this.i=a;this.j=b;this.b=c;this.k=d}KA.prototype.g="";KA.prototype.a="";function LA(a){var b={};b.l_ns=a.j;b.l_state=a.k;b.sst=a.i;b.sidx=0;a.g&&(b.at=a.g);a.a&&(b.ad_id=a.a);return b};function MA(a,b,c,d,e){this.j=a;this.g=b;this.B=c;this.ca=d;this.b=e;this.a=new KA(b,this.j,d,e);this.F=new Ko(this);this.i=new Ko(this)}y(MA,K);f=MA.prototype;f.ho=null;f.xd=null;
-f.load=function(){if(this.xd)return this.xd;this.xd=new io;var a=this.ca.ea.k?this.ca.K().Oc||NA:Cd(Q(this.ca.a)),b;this.ca.ea.a?b=!1:(b=0<(this.b&3)?190:200,b=200>a.width||a.height<b);if(b){b=this.a;var c=LA(b);c.ck_wh=a.width+"x"+a.height;HA(b.b,14,c);this.Se(Error("The player size is too small."))}else oo(this.ca.pg,this.Mu,this.Fd,this);return this.xd};
-f.Nk=function(){var a=new google.ima.AdsRenderingSettings;a.baseYouTubeUrl=this.ca.K().lb;a.contentId=this.ca.getVideoData().M;a.useStyledNonLinearAds=!0;a.disableVideoAdUi=!this.ca.ea.L;a.useVideoAdUi=this.ca.ea.L;a.youTubeAdNamespace=this.j;return a};function OA(a,b){a.ho=b;var c=b.getType();a.a.g=c}function PA(a){a=a.g;return 0==a||-1==a?a:1E3*a}
-f.Mu=function(a){var b=this.a;DA(b.b,9,LA(b));b=new google.ima.AdsRequest;b.adTagUrl=this.k();var c=this.ca.K().Oc||NA;b.linearAdSlotWidth=c.width;b.linearAdSlotHeight=c.height;b.nonLinearAdSlotWidth=c.width;b.nonLinearAdSlotHeight=100;"3.1"==eA()&&(b.isYouTube=!0);var c=this.b,d=n("yt.www.watch.ads.setGutSlotSizes");d&&d(0<(c&3),0<(c&12));this.F.listen(a,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,this.Gu);this.F.listen(a,google.ima.AdErrorEvent.Type.AD_ERROR,this.Fu);this.ni(a,b)};
-f.Gu=function(a){if(a.getUserRequestContext()===this){try{var b;if("3.1"==eA()){var c=this.Nk();b=a.getAdsManager({},c)}else b=a.getAdsManager({})}catch(d){this.Fd(d);return}this.i.listen(b,google.ima.AdEvent.Type.LOADED,v(this.Ew,this,b));this.i.listen(b,google.ima.AdErrorEvent.Type.AD_ERROR,v(this.Dw,this,b));z([google.ima.AdEvent.Type.ALL_ADS_COMPLETED,google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED,google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED],function(a){this.i.listen(b,a,ba)},this);a=jA(this.ca);
-try{b.init(a.width,a.height,google.ima.ViewMode.NORMAL)}catch(e){b.destroy(),this.Fd(e)}}};f.Ew=function(a,b){this.i.removeAll();var c=b.getAd(),d=c.isLinear(),e=this.a,g=LA(e);g.ad_man=d?"instream":"overlay";DA(e.b,12,g);e="";"3.1"==eA()&&(e=b.getAdData().mediaUrl);switch(d?this.Ug(a,c,e):this.Pe(a,c)){case 0:QA(this);break;case 1:a.destroy();this.Se(Error("Unable to create a display state."));break;case 2:c=this.a;HA(c.b,21,LA(c));a.destroy();this.Se(Error("Fallback to next ad."));break;default:a.destroy()}};
-f.Dw=function(a,b){this.i.removeAll();a.destroy();this.Fd(b.getError())};f.Fu=function(a){var b=a.getError();b.getType()==google.ima.AdError.Type.AD_LOAD&&a.getUserRequestContext()===this&&this.Fd(b)};f.Ug=function(a,b,c){b=b.getAdId();this.a.a=b;a=this.ca.ea.P?new lA(this.j,this.ca,a):new dA(this.j,this.ca,a,c);OA(this,a);return 0};f.Pe=function(a,b){var c=b.getAdId();this.a.a=c;OA(this,new tA(this.j,this.ca,a));return 0};
-f.Fd=function(a){if(a instanceof jo)this.xd.cancel();else{var b=this.a,c=LA(b);a&&Nz(a,c);HA(b.b,32,c);this.Se(a)}};function QA(a){a.xd.b({Tt:a.ho,startTime:a.g})}f.Se=function(a){this.xd.a(a)};f.H=function(){this.F.removeAll();this.i.removeAll();this.xd&&this.xd.cancel();MA.C.H.call(this)};f.ni=function(a,b){try{a.requestAds(b,this)}catch(c){this.Fd(c)}};function RA(a,b){this.a=a;this.b=b};function SA(a){vA.call(this,a,"")}y(SA,vA);SA.prototype.getType=function(){return"2_3"};SA.prototype.Ng=function(){return null};function TA(a,b,c,d){MA.call(this,2,a,b,c,d);this.o=new RA(this.ca.ea,this.ca.K());Rz()}y(TA,MA);TA.prototype.Nk=function(){var a=TA.C.Nk.call(this);a.a=0==this.B;a.b=!0;return a};
-TA.prototype.k=function(){var a=this.o,b=this.b,c=PA(this),d={};d.eid=a.a.ha;d.videoad_start_delay=c;d.scs=a.a.oe;d.client=a.a.eg;d.description_url=a.a.pa;d.loeid=a.a.Zf;d.cust_gender=a.a.Ic;d.host=a.a.host;d.hl=a.b.i;d.max_ad_duration=a.a.$f;d.url="embedded"==a.b.Z&&a.b.b?a.b.b:a.a.pa;a.a.Kc&&(d.adtest="on");isNaN(a.a.ga)||(d.cust_age=a.a.ga);isNaN(a.a.za)||(d.hostTierId=a.a.za);a.a.jb&&(d.yt_pt=a.a.jb);a.a.mc&&(d.video_cpm=a.a.mc);a.a.G&&(d.as_dbp=a.a.G);d.ytdevice=a.a.ag;d.ad_type=Qz(b);0<(b&3)?
-a.a.Ca&&(d.channel=a.a.Ca.join("+")):b&4&&a.a.Va&&(d.channel=a.a.Va.join("+"));a.a.Mc&&(d.lsv=1);a.a.bg&&(d.tfcd=1);var a=d,b={},e;for(e in a)ea.call(void 0,a[e])&&(b[e]=a[e]);return"//googleads.g.doubleclick.net/pagead/ads?"+Ej(b,"&")};TA.prototype.Pe=function(a,b){if(this.ca.ea.a)return 1;0==this.g&&(this.g=10,this.a.i=10,DA(this.ca,1));Tz(this.b);return TA.C.Pe.call(this,a,b)};
-TA.prototype.Se=function(a){var b=this.ca.ea;b.a?TA.C.Se.call(this,a):b.Ma||this.b&4?(OA(this,new SA(this.ca)),QA(this)):TA.C.Se.call(this,a)};function UA(a,b){if(a){this.Hp=a;this.wp=b;var c,d=this.Hp,e=d.indexOf(";sz=");c=Dj(d.substring(e),";");d=d.substring(0,e).split("pfadx");if(c=2!=d.length?null:{yx:d[0],zx:d[1],Ax:c})this.vp=c.yx,this.xp=c.zx,this.yp=c.Ax}}f=UA.prototype;f.Hp="";f.vp="";f.wp=!1;f.Fl="";f.xp="";f.yp=null;
-function VA(a,b){var c=[];b&1&&c.push("480x360");b&2&&c.push("480x361");b&12&&c.push("480x70");var d=[],e,g;b&12&&(d.push("300x250"),e="watch-channel-brand-div",g=1);0<(b&3)&&(d.push("300x60"),e="watch-longform-ad",g=1);c={Ap:e,lh:c,Dp:g,px:!0,El:d};d=Pb(a.yp);c.ox&&(d.pos=c.ox);c.Dp&&(d.tile=c.Dp.toString());c.Ap&&(d.kmyd=c.Ap);c.px&&(t(d["!c"])?d["!c"].push("html5"):d["!c"]=d["!c"]?[d["!c"],"html5"]:"html5");c.El&&0<c.El.length&&a.wp&&(d.ciu_szs=c.El.join(","));d.dcmt="text/xml";cj()&&(d.kmob="ps3");
-a.Fl||(a.Fl=Math.floor(999999999*Math.random()).toString());d.ord=a.Fl;c.lh&&c.lh.length&&"sz"in d&&delete d.sz;d=Ej(d,";");c.lh&&c.lh.length&&(d="sz="+c.lh.join(",")+";"+d);return[a.vp,"pfadx",a.xp,";",d,"?"].join("")};function WA(a,b,c,d){MA.call(this,1,a,b,c,d)}y(WA,MA);WA.prototype.k=function(){return VA(new UA(this.ca.ea.Jc,this.ca.ea.xa),this.b)};WA.prototype.Pe=function(a,b){var c=b.getAdId();this.a.a=c;c=b.getTraffickingParameters();return Pz(c,"rm")?(1!=this.b&&Uz(),XA(a),2):Pz(c,"blockAllAds")?(XA(a),OA(this,new wA(this.ca,a)),0):Pz(c,"hideMaster")?(OA(this,new wA(this.ca,a)),0):this.ca.ea.a?1:"3.1"==eA()?(OA(this,new tA(this.j,this.ca,a)),0):1};
-function XA(a){a.sendImpressionUrls&&a.sendImpressionUrls()};function YA(a,b,c,d,e){MA.call(this,1,a,b,c,d|e);this.A=d;this.o=e;Rz()}y(YA,WA);var ZA={GDFP:1,DART:1,DART_DFP:1,DART_DFA:1,ADSENSE:2,"ADSENSE/ADX":2};YA.prototype.k=function(){return VA(new UA(this.ca.ea.I,this.ca.ea.xa),this.A)};YA.prototype.ni=function(a,b){if(this.o){b.youTubeAdType=Qz(this.o);var c=this.ca.ea.ha;c&&(b.youTubeExperimentIds=c);b.youTubeVideoAdStartDelay=PA(this)}YA.C.ni.call(this,a,b)};YA.prototype.Ug=function(a,b,c){var d=$A(a);return 1!=d&&2!=d?1:YA.C.Ug.call(this,a,b,c)};
-YA.prototype.Pe=function(a,b){switch($A(a)){case 1:return YA.C.Pe.call(this,a,b);case 2:var c;1!=this.A&&Uz();this.ca.ea.a?c=1:(0==this.g&&(this.g=10,this.a.i=10,DA(this.ca,1)),Tz(this.b),c=b.getAdId(),this.a.a=c,OA(this,new tA(2,this.ca,a)),c=0);return c;default:return 1}};function $A(a){var b=a.getCurrentAd().getWrapperAdSystems();a=Ua(b)?a.getCurrentAd().getAdSystem():b[0];return(a=ZA[a.toUpperCase()])?a:0};function aB(a,b,c){var d=c.ea;this.o=d.hd;var e=0,d=d.kd.toUpperCase();"INVIDEO"==d?e=4:"INSTREAM"==d?e=1:"MPU"==d&&(e=8);MA.call(this,2,a,b,c,e)}y(aB,MA);function bB(a){var b=new io;Qj(a,{format:"RAW",method:"GET",timeout:5E3,Sk:function(){b.a(Error(a+" timed out"))},onError:function(c){b.a(Error("Problem loading "+a+" with status code "+c.status))},Pa:function(a){b.b(a)}});return b}aB.prototype.k=function(){return""};
-aB.prototype.ni=function(a,b){var c=this.b;c&1||c&4?this.o?("goo.gl"==Ij(this.o)?(c=bB("https://www.googleapis.com/urlshortener/v1/url?key=AIzaSyBbSB-E7SYd1iggX6r2b5C7ljvO6fVqaj0&shortUrl="+this.o),oo(c,function(a){a=nb(a.responseText);if(!a||!a.longUrl)throw Error("Invalid expanded forced ad URL");a=Kj(a.longUrl,{video_format:"43"});return bB(a)},null,this)):c=bB(this.o),oo(c,function(c){b.adsResponse=c.responseText;a.requestAds(b,this)},null,this),oo(c,null,this.Fd,this)):this.Fd(Error("Invalid empty URL")):
-this.Fd(Error("Invalid request type: "+c))};function cB(a,b,c){this.a=a;this.g=b;this.b=Si||Ti?"html5_ios":Ui?"html5_android":cj()?"html5_ps3":"leanback"==c?"html5_tv_leanback":"html5"};function dB(a,b,c,d){MA.call(this,4,a,b,c,d);this.o=new cB(this.ca.ea,this.ca.getVideoData().ra,this.ca.K().Z)}y(dB,MA);
-dB.prototype.k=function(){var a;a=this.o;if(a.a.aa&&a.a.kb){var b="10613:10613_youtube_"+a.b,c="youtube_watch_"+a.b,d="10613:10613_youtube_"+a.b.split("_")[0],e={nw:"10613"};e.asnw=a.a.aa;e.ssnw=a.a.aa;e.caid=a.a.kb;e.prof=b;e.vdur=a.g;e.csid=c;e.resp="vast2";e.crtp="vast2s";e.flag="+emcr";b={};isNaN(a.a.la)||(b._fw_d_001=a.a.la);a.a.lc&&(b._fw_d_002=a.a.lc);a.a.Ra&&(b["_fwu:10613:lang"]=a.a.Ra);a.a.G&&(b._fw_dbp=a.a.G);b._fw_yt_type=a.a.B?"short":"long";var c={ptgt:"a",slid:"preroll"},g="";a.a.g&&
-!a.a.b?g=";linear-skippable":!a.a.g&&a.a.b&&(g=";video");c.slau="preroll"+g;c.w="480";c.h="360";c.tpos="0";c.tpcl="preroll";c.envp=d;c.cd="1440,900";a="//2975c.v.fwmrm.net/ad/g/1?"+Ej(e,"&")+";"+Ej(b,"&")+";"+Ej(c,"&")}else a="";return a};dB.prototype.Ug=function(a,b){return 0!=this.g?1:dB.C.Ug.call(this,a,b,null)};dB.prototype.Pe=function(){return 1};function eB(a,b,c){this.g=a;this.a=b;this.b=c||0}eB.prototype.create=function(a,b,c){switch(this.g){case 1:return new TA(a,b,c,this.a);case 2:return new WA(a,b,c,this.a);case 3:return new YA(a,b,c,this.a,this.b);case 5:return new dB(a,b,c,this.a);case 4:return new aB(a,b,c);default:return null}};function fB(a){this.a=a};function gB(a,b){this.O=a;this.Q=this.O.nc;this.k="leanback"==this.O.Z;this.a=this.Q||this.k;var c="3.1"==Lz.getInstance().getVersion();this.L=!this.a&&c;this.P=a.tb&&c&&!this.a;this.apply(b)}var hB={$B:"m",UA:"f"};
-gB.prototype.apply=function(a){var b=Vz(this.O,"908301"),c="3.1"==Lz.getInstance().getVersion(),d=Mz(a.instream),e=(!this.a||b)&&c&&Mz(a.trueview),g=Mz(a.aftv)&&(!this.a||b);this.ja=a.ad_slots;this.da=a.ad_breaks;this.Lc=a.ad_flags||0;this.ga=parseInt(a.cust_age,10);this.ha=a.cafe_experiment_id;var h=parseInt(a.cust_gender,10);isNaN(h)||(this.Ic=h);this.Jc=a.ad_tag;this.Kc=!!a.adtest;this.la=parseInt(a.ad_age,10);this.Hc=a.cid;this.pa=a.ad_eurl;this.I=a.dynamic_allocation_ad_tag;this.va=a.excluded_ads;
-this.kd=a.force_ad_type;this.hd=a.force_ad_url;this.lc=Mb(hB,function(b){return b==a.ad_gender});this.G=a.dbp;this.xa=!!a.mpu;this.host=a.ad_host;this.za=parseInt(a.ad_host_tier,10);this.ld=1==a.ad_logging_flag;this.F=Mz(a.afv)&&!this.a;this.i=g&&e;this.j=g&&d&&!Mz(a.no_afv_instream);this.A=Mz(a.dclk);this.Mc=1==a.livestream;this.Sa=Mz(a.forced_ad)&&b&&c;this.J=1==parseInt(a.tpas_ad_type_id,10);this.Yf=!!a.fqsf;this.b=d;this.V=Mz(a.invideo)&&!this.a;this.Y=Mz(a.mpu)&&!this.a;this.gd=Mz(a.shortform);
-this.B=Mz(a.sffb);this.oe="1"==a.as_launched_in_country;this.rb=!this.a&&!this.J;this.g=e;b=a.ad_channel_code_instream;this.Ca=u(b)?b.split(","):[];this.Ra=a.ad_language_iso639_2;this.Zf=a.loeid;b=parseInt(a.afv_instream_max,10);isNaN(b)&&(b=15E3);this.$f=b;this.o=parseInt(a.midroll_freqcap,10);isNaN(this.o)&&(this.o=-1);b=a.ad_channel_code_overlay;this.Va=u(b)?b.split(","):[];this.jb=a.yt_pt;this.eg=a.ad_video_pub_id;this.bg=Mz(a.tag_for_child_directed);this.mc=parseInt(a.afv_video_min_cpm,10);this.Ma=
-g&&this.B&&!this.F;this.jd=this.F||this.Ma;this.ag=parseInt(a.ad_device,10);this.kb=a.tpas_video_id;this.aa=a.tpas_partner_id;this.Ka=iB(this)};function iB(a){if(/^[\s\xa0]*$/.test(null==a.I?"":String(a.I))||!Vz(a.O,"932604")||!a.P)return!1;var b=(a.b||a.g)&&a.A;a.B&&a.A&&(b=b||a.V||a.Y);if(!b)return!1;b=a.i||a.j;if(!(b||a.B&&a.F))return!1;a=a.I.length+330+102;var c=window.document.referrer;a+=encodeURIComponent(String("ref"+(c?"="+c:""))).length;b||(a+=41);return 2048>=a}gB.prototype.rb=!0;function jB(a,b,c){this.a=a;this.k=b;this.g=c;this.j=this.b=-1;this.g&&0<this.a.ea.o&&this.a.D("endseeking",this.i,this)}y(jB,K);function kB(a,b){lB(a);0<b&&(a.j=H(v(a.i,a),1E3*b))}function lB(a){-1!=a.j&&(I(a.j),a.j=-1)}
-jB.prototype.i=function(){var a=this.a.ea.o;if(this.g&&!(0>=a)){var b=this.a.a.getCurrentTime(),c=[],d=null,e=Number.MAX_VALUE;Hb(this.k.i,function(a){if(a.qd&&a.isVisible&&!(0>=mB(this,a))){var g;g=a.getId();g=this.k.j[g];if(mB(this,a)>b){var m=!nB(this,a);m!=g.Pc&&(g.Pc=m,c.push(g));m||(g=mB(this,a)-b,g<e&&(e=g,d=a))}else g.Pc||(g.Pc=!0,c.push(g))}},this);0<c.length&&oB(this.a,c);if(d){var g=0;0<this.b&&(g=x()/1E3-this.b);kB(this,a-g-e+2)}else lB(this)}};
-function nB(a,b){if(!a.g||!b.qd||!(0<b.start)&&-1!=b.start)return!1;var c=a.a.ea.o;if(0>=c||0>=a.b)return!1;var d=x()/1E3,e=mB(a,b)-a.a.a.getCurrentTime();0<e&&(d+=e);return d-a.b<=c}function mB(a,b){return-1==b.start?a.a.a.getVideoData().ra:b.start}jB.prototype.H=function(){lB(this)};function pB(a,b){this.b=b;this.g=[];this.i={};this.j={};this.a=a;var c=!a.ea.Mc&&Ma(this.b,function(a){return 0<a.start||-1==a.start});this.k=new jB(this.a,this,c)}y(pB,K);f=pB.prototype;f.Cd=null;function qB(a){a.g.length||(gb(a.b,function(a,c){return a.getId()-c.getId()}),a.g=Ka(a.b,function(a){return"unloaded"==a.Qe}),0==a.g.length?Km(a.a):(null===Pa(a.g,function(a){return 0==a.start})&&Km(a.a),rB(a)))}function rB(a){if(a.g.length){var b=a.g.shift();b.D("adBreakComplete",a.fl,a);BA(b)}}
-f.fl=function(a){a.$("adBreakComplete",this.fl,this);H(v(this.lx,this,a),0)};f.lx=function(a){var b=Ja(this.b,a),c=this.b[b+1],b=this.b[b-1],d=2147483646;-2==a.start||-1==a.start?d=2147483647:c&&2147483647!=c.start&&(d=yA(c)-1);0==a.Ba&&(CA(this.a,"bl"),AA(a)||CA(this.a,"fb"));if(c="loaded"!=a.Qe){if(b&&zA(b)){var e=yA(b);e>d&&(d=e);sB(this,b);tB(this,b,d)}}else this.i[a.getId()]=a,tB(this,a,d);Km(this.a);c&&this.sg(a);a=this.i;var b=0,g;for(g in a)b++;b==this.b.length&&this.k.i();rB(this)};
-function tB(a,b,c){var d=yA(b);if(!isNaN(d)){var e={};e.priority=-2!=b.start?2:3;e.id=String(b.getId());e.visible=b.isVisible;c=new $h(d,c,e);a.j[b.getId()]=c;a.a.uf(c)}}function sB(a,b){a.j[b.getId()]&&(a.a.lv(a.j[b.getId()]),delete a.j[b.getId()])}f.sg=function(a){a.$("adBreakComplete",this.fl,this);this.Cd&&a==this.Cd&&(this.Cd=null);sB(this,a);Xa(this.b,a);delete this.i[a.getId()];Tg(a)};
-f.Eu=function(a){if(a.qd){if(-1!=a.start&&a.hk){var b=this.a;uB(b);Um(b)}else AA(a)&&!a.hk?(b=this.a,uB(b),Um(b)):(uB(this.a),this.a.mb(!1));this.sg(a);a=this.k;a.g&&0<a.a.ea.o&&(a.b=x()/1E3,a.i())}else a.isVisible||this.sg(a)};f.H=function(){Tg(this.k);z(this.b,this.sg,this);pB.C.H.call(this)};function vB(){return[]};function wB(a,b){this.g=a;b&&(this.b=b)}function xB(a){var b={};b.allowed=a.g;a.b&&(b.ex_ads=a.b);a.a&&(b.at=a.a);return b};function yB(a,b){this.g=a;this.X=b;this.o=x();this.a=a.ea;this.b={};var c=[];this.a.J&&this.a.b&&c.push("4_2");this.a.A&&(this.a.b&&c.push("1_2"),this.a.g&&c.push("1_2_1"),this.a.V&&c.push("1_1"),this.a.Y&&c.push("1_3"));this.a.i&&c.push("2_2_1");this.a.j&&c.push("2_2");this.a.F&&c.push("2_1");this.a.jd&&c.push("2_3");this.i=c.join(",");this.k=new wB(this.i,this.a.va);this.b.allowed=this.i;(c=this.a.va)&&(this.b.ex_ads=c)}var zB=[9,10,11,12],AB=[21,30],BB=[1009];yB.prototype.j=0;
-function CB(a,b){if(!a.a.ld)return!1;var c=a.g.K();if(Vz(c,"906335"))return!0;c=b.ad_event;return Ta(zB,c)||7==c&&(c=b.ad_error,Ta(AB,c)||32==c&&Ta(BB,b.error_code))?!1:!0};function DB(a){zx.call(this,a);this.j={};this.i={at:"0"};this.b=new mn(this.a);this.g=null;a=this.getVideoData().b.html5_sdk_version;this.k=Lz.getInstance().load(a)}y(DB,zx);var NA=new B(0,0);f=DB.prototype;f.qa="ad";f.ad="ad";f.ue=null;f.Td=null;f.ea=null;f.qj=!1;f.Mj=!1;f.pg=null;f.ki=null;f.$a=function(){return!!this.app.I.getVideoData().ca};
-f.create=function(){DB.C.create.call(this);this.ba=!0;CA(this,"i");this.ea=new gB(this.K(),this.a.getVideoData().b||{});this.ue=new yB(this,this.a);Sz();this.qj=!1;var a=po(this.k);this.pg=oo(a,this.jq,null,this);t:{var a=new fB(this),b=[];try{var c=a.a.ea,d;if(c.rb){var e;if(c.da)e=JA(c.da);else{var g;if(c.ja){var h=La(c.ja.split(","),Fa);g=new IA(h)}else g=new IA([0]);e=g}d=e}else d=new IA([0]);for(var k=d.iq,c=0;c<k.length;c++){var m=a.a;d=c;var p=k[c],r;if(a.a.ea.B){e=[];var s=a.a.ea;if(s.Sa)e.push(new eB(4,
-0));else{s.J&&(s.b||s.g)&&e.push(new eB(5,1));g=0;s.A&&(s.b&&(g|=1),s.g&&(g|=2),s.V&&(g|=4),s.Y&&(g|=8));h=0;if(s.j||s.i)s.j&&(h|=1),s.i&&(h|=2);var D=0;s.F&&(D=4);h||(h=D,D=0);s.Ka&&g&&(h||D)?e.push(new eB(3,g,h)):(g&&e.push(new eB(2,g)),h&&e.push(new eB(1,h)));D&&e.push(new eB(1,D))}}else{e=[];var O=a.a.ea;if(O.Sa)e.push(new eB(4,0));else{O.J&&O.b&&e.push(new eB(5,1));g=0;O.A&&(O.b&&(g|=1),O.g&&(g|=2));h=0;if(O.j||O.i)O.j&&(h|=1),O.i&&(h|=2);O.Ka&&g&&h?e.push(new eB(3,g,h)):(g&&e.push(new eB(2,
-g)),h&&e.push(new eB(1,h)))}}r=e;var ta=new xA(m,d,p,r);b.push(ta)}}catch($){}finally{break t}}k=b;CA(this,"bd");this.Td=new pB(this,k);qB(this.Td);k={};k.allowed=this.ue.i;Om(this,{},k)};f.destroy=function(){this.Mj&&uB(this);this.ba=!1;this.g&&pA(this.app,this.g);Ug(this.Td,this.g);this.g=this.Td=null;this.pg&&(this.pg.cancel(),this.pg=null);this.ue=null;on(this.b);DB.C.destroy.call(this)};f.getVideoData=function(){return this.app.getVideoData(1)};f.K=function(){return this.app.K()};
-function DA(a,b,c){a=a.ue;c=c||{};var d=(x()-a.o)/1E3;c.art=d;d=a.g.K();d.j&&(c.feature=d.da);c.ad_flags=a.a.Lc;var e=a.a.Hc;e&&(c.cid=e);c.mt=a.X.getCurrentTime();(d=Ux(d))&&(c.lact=d);(d=a.X.Gh())&&(c.len=d);a.a.Yf&&(c.fqsf=1);(d=Lz.getInstance().getVersion())&&(c.sdkv=d);c.ad_event=b;if(3==b||4==b)a.k.a=c.at;b=c;if(CB(a,b)){var g;t:{c=a.b;d=Ob(b);for(g in c){if(g in d){g=null;break t}d[g]=c[g]}g=d}null===g?a.g.log(a.b):b=g;a.g.log(b);a.b={}}}function HA(a,b,c){c=c||{};c.ad_error=b;DA(a,7,c)}
-f.Hi=function(){return this.ue?this.ue.k:DB.C.Hi.call(this)};function eA(){return Lz.getInstance().getVersion()}function mA(a){if(!a.g){var b=new Ix(a.K().a);b.Z="adunit";b.Tb=!0;a.g=new bz(b,2)}return a.g}function jA(a){var b=a.ea.k?a.K().Oc||NA:Gd(Q(a.a));a.ea.a||(b.height-=27);return b}function aA(a){return a.ea.k?(a=a.K().Oc||NA,new Db(0,0,a.width,a.height)):Ed(Q(a.a))}function uB(a){on(a.b);a.Mj=!1;Tm(a);Sm(a,["seek"]);a.K().Md&&Sm(a,["audio"])}
-function kA(a,b){switch(b){case 1:a.u("publish_external_event","onAdStart");break;case 2:a.u("publish_external_event","onAdEnd")}}function hA(a,b,c){a.u("publish_external_event","onAdStateChange",b,a.b.X.K().tb?a.b.X.app.R.b:rn(a.b),c)}
-f.yc=function(a){DB.C.yc.call(this,a);var b=parseInt(a.getId(),10);this.Td&&!isNaN(b)&&(a=this.Td,q(b)&&(b=a.i[b]))&&(a.Cd==b&&!b.qd&&b.isVisible?b.show():(a.Cd&&a.sg(a.Cd),nB(a.k,b)?(a.Cd=null,b=a.j[b.getId()],b.Pc||(b.Pc=!0,oB(a.a,[b]))):(a.Cd=b,b.D("adBreakComplete",a.Eu,a),b.qd&&(a=a.a,a.Mj=!0,a.u("command_redirect_controls",a,["play_pause"],void 0),Rm(a,["seek"]),a.K().Md&&Rm(a,["audio"]),Vm(a)),b.show())))};
-f.Vc=function(a){DB.C.Vc.call(this,a);var b=parseInt(a.getId(),10),c=1E3*this.a.getCurrentTime();this.Td&&!isNaN(b)&&c>a.start&&(2147483647==a.end||2147483646==a.end)&&(a=this.Td,(b=a.i[b])&&a.Cd==b&&!b.qd&&b.isVisible&&b.Ok&&b.a instanceof tA&&uA(b.a,google.ima.ViewMode.FULLSCREEN))};
-f.jq=function(){CA(this,"sdk");if(this.ki)return this.ki;var a;if(this.ea.P){a=new yx(this.app,2);var b=google.ima.AdDisplayContainer,c=nn(this.b),d=qn(this.b);a.j||(a.j=Ob(a.i),a.j.addEventListener=v(a.Xt,a),a.j.removeEventListener=v(a.Yt,a));a=new b(c,void 0,d,a.j)}else{a=this.b.X.K().tb?this.b.X.app.R.b:rn(this.b);if(!a)return a=Error("AdModule.getVideoElement returned an invalid element."),b=new io,b.a(a),b;a=new google.ima.AdDisplayContainer(nn(this.b),a,qn(this.b))}return this.ki=new google.ima.AdsLoader(a)};
-function CA(a,b){var c=b;"nl"==b&&(c=a.ue,c.j++,c=c.j.toString());a.j[c]=x();"bs"!=c&&"fb"!=c||Om(a,a.j,a.i)}function oB(a,b){a.u("command_update_cuerange_markers",b,a.a.a)}f.ie=function(a){this.u(a)};function EB(a){return FB(a||arguments.callee.caller,[])}
-function FB(a,b){var c=[];if(Ta(b,a))c.push("[...circular reference...]");else if(a&&50>b.length){c.push(GB(a)+"(");for(var d=a.arguments,e=0;e<d.length;e++){0<e&&c.push(", ");var g;g=d[e];switch(typeof g){case "object":g=g?"object":"null";break;case "string":break;case "number":g=String(g);break;case "boolean":g=g?"true":"false";break;case "function":g=(g=GB(g))?g:"[fn]";break;default:g=typeof g}40<g.length&&(g=g.substr(0,40)+"...");c.push(g)}b.push(a);c.push(")\n");try{c.push(FB(a.caller,b))}catch(h){c.push("[exception trying to get caller]\n")}}else a?
-c.push("[...long stack...]"):c.push("[end]");return c.join("")}function GB(a){if(HB[a])return HB[a];a=String(a);if(!HB[a]){var b=/function ([^\(]+)/.exec(a);HB[a]=b?b[1]:"[Anonymous]"}return HB[a]}var HB={};function IB(a,b,c,d,e){this.reset(a,b,c,d,e)}IB.prototype.b=null;IB.prototype.a=null;var JB=0;IB.prototype.reset=function(a,b,c,d,e){"number"==typeof e||JB++;this.i=d||x();this.j=a;this.k=b;this.g=c;delete this.b;delete this.a};IB.prototype.getMessage=function(){return this.k};function KB(a){this.b=a}KB.prototype.a=null;function LB(a,b){this.name=a;this.value=b}LB.prototype.toString=function(){return this.name};var MB=new LB("SHOUT",1200),NB=new LB("SEVERE",1E3),OB=new LB("WARNING",900),PB=new LB("INFO",800);f=KB.prototype;f.Cv=function(){};f.Ev=function(){return!1};f.getChildren=function(){this.a||(this.a={});return this.a};f.log=function(){};
-f.Dv=function(a,b,c){var d=new IB(a,String(b),this.b);if(c){d.b=c;var e;var g=arguments.callee.caller;try{var h;var k=n("window.location.href");if(u(c))h={message:c,name:"Unknown error",lineNumber:"Not available",fileName:k,stack:"Not available"};else{var m,p,r=!1;try{m=c.lineNumber||c.line||"Not available"}catch(s){m="Not available",r=!0}try{p=c.fileName||c.filename||c.sourceURL||l.$googDebugFname||k}catch(D){p="Not available",r=!0}h=!r&&c.lineNumber&&c.fileName&&c.stack&&c.message&&c.name?c:{message:c.message||
-"Not available",name:c.name||"UnknownError",lineNumber:m,fileName:p,stack:c.stack||"Not available"}}e="Message: "+ya(h.message)+'\nUrl: <a href="view-source:'+h.fileName+'" target="_new">'+h.fileName+"</a>\nLine: "+h.lineNumber+"\n\nBrowser stack:\n"+ya(h.stack+"-> ")+"[end]\n\nJS stack traversal:\n"+ya(EB(g)+"-> ")}catch(O){e="Exception trying to expose exception! You win, we lose. "+O}d.a=e}return d};f.info=function(){};var QB={},RB=null;function SB(){RB||(RB=new KB(""),QB[""]=RB)}
-function TB(a){SB();var b;if(!(b=QB[a])){b=new KB(a);var c=a.lastIndexOf("."),d=a.substr(c+1);TB(a.substr(0,c)).getChildren()[d]=b;QB[a]=b}return b};function UB(){this.a=x()}var VB=new UB;UB.prototype.set=function(a){this.a=a};UB.prototype.reset=function(){this.set(x())};UB.prototype.get=function(){return this.a};function WB(a){this.g=a||"";this.i=VB}WB.prototype.b=!0;WB.prototype.a=!1;function XB(a){return 10>a?"0"+a:String(a)}function YB(a,b){var c=(a.i-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}function ZB(a){WB.call(this,a)}y(ZB,WB);
-function $B(a,b){var c=[];c.push(a.g," ");if(a.b){var d=new Date(b.i);c.push("[",XB(d.getFullYear()-2E3)+XB(d.getMonth()+1)+XB(d.getDate())+" "+XB(d.getHours())+":"+XB(d.getMinutes())+":"+XB(d.getSeconds())+"."+XB(Math.floor(d.getMilliseconds()/10)),"] ")}c.push("[",YB(b,a.i.get()),"s] ");c.push("[",b.g,"] ");c.push(b.getMessage());a.a&&b.b&&c.push("\n",b.a);c.push("\n");return c.join("")};function aC(a,b){this.b=new rb(a);this.a=b?ob:nb}aC.prototype.stringify=function(a){return qb(this.b,a)};aC.prototype.parse=function(a){return this.a(a)};function bC(){};function cC(){}cC.prototype.a=null;var dC;function eC(){}y(eC,cC);function fC(a){return(a=gC(a))?new ActiveXObject(a):new XMLHttpRequest}function hC(a){var b={};gC(a)&&(b[0]=!0,b[1]=!0);return b}
-function gC(a){if(!a.b&&"undefined"==typeof XMLHttpRequest&&"undefined"!=typeof ActiveXObject){for(var b=["MSXML2.XMLHTTP.6.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"],c=0;c<b.length;c++){var d=b[c];try{return new ActiveXObject(d),a.b=d}catch(e){}}throw Error("Could not create ActiveXObject. ActiveX might be disabled, or MSXML might not be installed");}return a.b}dC=new eC;function iC(a,b,c,d,e){this.b=a;this.a=b;this.j=c;this.g=d;this.i=e||1;this.uc=45E3;this.o=new Tr(this);this.k=new Fi;Gi(this.k,250)}f=iC.prototype;f.Be=null;f.Cc=!1;f.Jf=null;f.$k=null;f.xg=null;f.Ff=null;f.Wd=null;f.Kb=null;f.Zd=null;f.Qa=null;f.Og=0;f.Ec=null;f.vf=null;f.Ie=null;f.vg=-1;f.ln=!0;f.Je=!1;f.ck=0;f.Xh=null;
-function jC(a,b){switch(a){case 0:return"Non-200 return code ("+b+")";case 1:return"XMLHTTP failure (no data)";case 2:return"HttpConnection timeout";default:return"Unknown error"}}var kC={},lC={};f=iC.prototype;f.setTimeout=function(a){this.uc=a};function mC(a,b,c){a.Ff=1;a.Wd=Ie(b.clone());a.Zd=c;a.F=!0;nC(a,null)}function oC(a,b,c,d,e){a.Ff=1;a.Wd=Ie(b.clone());a.Zd=null;a.F=c;e&&(a.ln=!1);nC(a,d)}
-function nC(a,b){a.xg=x();pC(a);a.Kb=a.Wd.clone();Ge(a.Kb,"t",a.i);a.Og=0;a.Qa=a.b.rk(a.b.fi()?b:null);0<a.ck&&(a.Xh=new Np(v(a.sn,a,a.Qa),a.ck));a.o.listen(a.Qa,"readystatechange",a.Et);var c=a.Be?Ob(a.Be):{};a.Zd?(a.vf="POST",c["Content-Type"]="application/x-www-form-urlencoded",a.Qa.send(a.Kb,a.vf,a.Zd,c)):(a.vf="GET",a.ln&&!gc&&(c.Connection="close"),a.Qa.send(a.Kb,a.vf,null,c));a.b.Bc(1);var d=a.Zd;if(d)for(var c="",d=d.split("&"),e=0;e<d.length;e++){var g=d[e].split("=");if(1<g.length)var h=
-g[0],g=g[1],k=h.split("_"),c=2<=k.length&&"type"==k[1]?c+(h+"="+g+"&"):c+(h+"=redacted&")}else c=null;a.a.info("XMLHTTP REQ ("+a.g+") [attempt "+a.i+"]: "+a.vf+"\n"+a.Kb+"\n"+c)}f.Et=function(a){a=a.target;var b=this.Xh;b&&3==qC(a)?(this.a.debug("Throttling readystatechange."),Op(b)):this.sn(a)};
-f.sn=function(a){try{if(a==this.Qa)t:{var b=qC(this.Qa),c=this.Qa.i,d=rC(this.Qa);if(C&&!vc(10)||gc&&!uc("420+")){if(4>b)break t}else if(3>b||3==b&&!ec&&!sC(this.Qa))break t;this.Je||4!=b||7==c||(8==c||0>=d?this.b.Bc(3):this.b.Bc(2));tC(this);var e=rC(this.Qa);this.vg=e;var g=sC(this.Qa);g||this.a.debug("No response text for uri "+this.Kb+" status "+e);this.Cc=200==e;this.a.info("XMLHTTP RESP ("+this.g+") [ attempt "+this.i+"]: "+this.vf+"\n"+this.Kb+"\n"+b+" "+e);this.Cc?(4==b&&uC(this),this.F?(vC(this,
-b,g),ec&&this.Cc&&3==b&&(this.o.listen(this.k,"tick",this.dt),this.k.start())):(wC(this.a,this.g,g,null),xC(this,g)),this.Cc&&!this.Je&&(4==b?this.b.Uh(this):(this.Cc=!1,pC(this)))):(this.Ie=400==e&&0<g.indexOf("Unknown SID")?3:0,yC(),uC(this),zC(this))}}catch(h){this.a.debug("Failed call to OnXmlHttpReadyStateChanged_"),this.Qa&&sC(this.Qa)&&sC(this.Qa)}finally{}};
-function vC(a,b,c){for(var d=!0;!a.Je&&a.Og<c.length;){var e=AC(a,c);if(e==lC){4==b&&(a.Ie=4,yC(),d=!1);wC(a.a,a.g,null,"[Incomplete Response]");break}else if(e==kC){a.Ie=4;yC();wC(a.a,a.g,c,"[Invalid Chunk]");d=!1;break}else wC(a.a,a.g,e,null),xC(a,e)}4==b&&0==c.length&&(a.Ie=1,yC(),d=!1);a.Cc=a.Cc&&d;d||(wC(a.a,a.g,c,"[Invalid Chunked Response]"),uC(a),zC(a))}f.dt=function(){var a=qC(this.Qa),b=sC(this.Qa);this.Og<b.length&&(tC(this),vC(this,a,b),this.Cc&&4!=a&&pC(this))};
-function AC(a,b){var c=a.Og,d=b.indexOf("\n",c);if(-1==d)return lC;c=Number(b.substring(c,d));if(isNaN(c))return kC;d+=1;if(d+c>b.length)return lC;var e=b.substr(d,c);a.Og=d+c;return e}
-function BC(a,b){a.xg=x();pC(a);var c=b?window.location.hostname:"";a.Kb=a.Wd.clone();Fe(a.Kb,"DOMAIN",c);Fe(a.Kb,"t",a.i);try{a.Ec=new ActiveXObject("htmlfile")}catch(d){uC(a);a.Ie=7;yC();zC(a);return}var e="<html><body>";b&&(e+='<script>document.domain="'+c+'"\x3c/script>');e+="</body></html>";a.Ec.open();a.Ec.write(e);a.Ec.close();a.Ec.parentWindow.m=v(a.St,a);a.Ec.parentWindow.d=v(a.Dn,a,!0);a.Ec.parentWindow.rpcClose=v(a.Dn,a,!1);c=a.Ec.createElement("div");a.Ec.parentWindow.document.body.appendChild(c);
-c.innerHTML='<iframe src="'+a.Kb+'"></iframe>';a.a.info("TRIDENT REQ ("+a.g+") [ attempt "+a.i+"]: GET\n"+a.Kb);a.b.Bc(1)}f.St=function(a){CC(v(this.ly,this,a),0)};f.ly=function(a){if(!this.Je){var b=this.a;b.info("TRIDENT TEXT ("+this.g+"): "+DC(b,a));tC(this);xC(this,a);pC(this)}};f.Dn=function(a){CC(v(this.ky,this,a),0)};f.ky=function(a){this.Je||(this.a.info("TRIDENT TEXT ("+this.g+"): "+a?"success":"failure"),uC(this),this.Cc=a,this.b.Uh(this),this.b.Bc(4))};f.cancel=function(){this.Je=!0;uC(this)};
-function pC(a){a.$k=x()+a.uc;EC(a,a.uc)}function EC(a,b){if(null!=a.Jf)throw Error("WatchDog timer not null");a.Jf=CC(v(a.Px,a),b)}function tC(a){a.Jf&&(l.clearTimeout(a.Jf),a.Jf=null)}f.Px=function(){this.Jf=null;var a=x();0<=a-this.$k?(this.a.info("TIMEOUT: "+this.Kb),2!=this.Ff&&this.b.Bc(3),uC(this),this.Ie=2,yC(),zC(this)):EC(this,this.$k-a)};function zC(a){a.b.Gb()||a.Je||a.b.Uh(a)}
-function uC(a){tC(a);Tg(a.Xh);a.Xh=null;a.k.stop();a.o.removeAll();if(a.Qa){var b=a.Qa;a.Qa=null;b.abort();b.dispose()}a.Ec&&(a.Ec=null)}function xC(a,b){try{a.b.$o(a,b),a.b.Bc(4)}catch(c){}};function FC(){}function wC(a,b,c,d){a.info("XMLHTTP TEXT ("+b+"): "+DC(a,c)+(d?" "+d:""))}FC.prototype.debug=function(a){this.info(a)};FC.prototype.info=function(){};
-function DC(a,b){if(!b||"y2f%"==b)return b;try{var c=ob(b);if(c)for(var d=0;d<c.length;d++)if(t(c[d])){var e=c[d];if(!(2>e.length)){var g=e[1];if(t(g)&&!(1>g.length)){var h=g[0];if("noop"!=h&&"stop"!=h)for(var k=1;k<g.length;k++)g[k]=""}}}return pb(c)}catch(m){return a.debug("Exception parsing expected JS array - probably was not JS"),b}};function GC(a,b,c,d,e){(new FC).debug("TestLoadImageWithRetries: "+e);if(0==d)c(!1);else{var g=e||0;d--;HC(a,b,function(e){e?c(!0):l.setTimeout(function(){GC(a,b,c,d,g)},g)})}}
-function HC(a,b,c){var d=new FC;d.debug("TestLoadImage: loading "+a);var e=new Image;e.onload=function(){try{d.debug("TestLoadImage: loaded"),IC(e),c(!0)}catch(a){}};e.onerror=function(){try{d.debug("TestLoadImage: error"),IC(e),c(!1)}catch(a){}};e.onabort=function(){try{d.debug("TestLoadImage: abort"),IC(e),c(!1)}catch(a){}};e.ontimeout=function(){try{d.debug("TestLoadImage: timeout"),IC(e),c(!1)}catch(a){}};l.setTimeout(function(){if(e.ontimeout)e.ontimeout()},b);e.src=a}
-function IC(a){a.onload=null;a.onerror=null;a.onabort=null;a.ontimeout=null};function JC(a,b){this.a=a;this.b=b;this.g=new aC(null,!0)}f=JC.prototype;f.yk=null;f.Pb=null;f.wi=!1;f.Wn=null;f.vi=null;f.Pk=null;f.Vk=null;f.Rb=null;f.Ve=-1;f.Yg=null;f.ah=null;f.connect=function(a){this.Vk=a;a=KC(this.a,this.Vk);yC();this.Wn=x();var b=this.a.A;null!=b?(this.Yg=b[0],(this.ah=b[1])?(this.Rb=1,LC(this)):(this.Rb=2,MC(this))):(Ge(a,"MODE","init"),this.Pb=new iC(this,this.b,void 0,void 0,void 0),this.Pb.Be=this.yk,oC(this.Pb,a,!1,null,!0),this.Rb=0)};
-function LC(a){var b=NC(a.a,a.ah,"/mail/images/cleardot.gif");Ie(b);GC(b.toString(),5E3,v(a.yv,a),3,2E3);a.Bc(1)}f.yv=function(a){if(a)this.Rb=2,MC(this);else{yC();var b=this.a;b.a.debug("Test Connection Blocked");b.wd=b.ge.Ve;OC(b,9)}a&&this.Bc(2)};
-function MC(a){a.b.debug("TestConnection: starting stage 2");var b=a.a.B;if(null!=b)a.b.debug("TestConnection: skipping stage 2, precomputed result is "+b?"Buffered":"Unbuffered"),yC(),b?(yC(),PC(a.a,a,!1)):(yC(),PC(a.a,a,!0));else if(a.Pb=new iC(a,a.b,void 0,void 0,void 0),a.Pb.Be=a.yk,b=QC(a.a,a.Yg,a.Vk),yC(),!C||vc(10))Ge(b,"TYPE","xmlhttp"),oC(a.Pb,b,!1,a.Yg,!1);else{Ge(b,"TYPE","html");var c=a.Pb;a=Boolean(a.Yg);c.Ff=3;c.Wd=Ie(b.clone());BC(c,a)}}f.rk=function(a){return this.a.rk(a)};
-f.abort=function(){this.Pb&&(this.Pb.cancel(),this.Pb=null);this.Ve=-1};f.Gb=function(){return!1};
-f.$o=function(a,b){this.Ve=a.vg;if(0==this.Rb)if(this.b.debug("TestConnection: Got data for stage 1"),b){try{var c=this.g.parse(b)}catch(d){RC(this.a,this);return}this.Yg=c[0];this.ah=c[1]}else this.b.debug("TestConnection: Null responseText"),RC(this.a,this);else if(2==this.Rb)if(this.wi)yC(),this.Pk=x();else if("11111"==b){if(yC(),this.wi=!0,this.vi=x(),c=this.vi-this.Wn,!C||vc(10)||500>c)this.Ve=200,this.Pb.cancel(),this.b.debug("Test connection succeeded; using streaming connection"),yC(),PC(this.a,
-this,!0)}else yC(),this.vi=this.Pk=x(),this.wi=!1};
-f.Uh=function(){this.Ve=this.Pb.vg;if(!this.Pb.Cc)this.b.debug("TestConnection: request failed, in state "+this.Rb),0==this.Rb?yC():2==this.Rb&&yC(),RC(this.a,this);else if(0==this.Rb)this.b.debug("TestConnection: request complete for initial check"),this.ah?(this.Rb=1,LC(this)):(this.Rb=2,MC(this));else if(2==this.Rb){this.b.debug("TestConnection: request complete for stage 2");var a=!1;(a=!C||vc(10)?this.wi:200>this.Pk-this.vi?!1:!0)?(this.b.debug("Test connection succeeded; using streaming connection"),yC(),
-PC(this.a,this,!0)):(this.b.debug("Test connection failed; not using streaming"),yC(),PC(this.a,this,!1))}};f.fi=function(){return this.a.fi()};f.Bc=function(a){this.a.Bc(a)};function SC(a){Ci.call(this);this.headers=new Wd;this.j=a||null;this.b=!1;this.I=this.a=null;this.O=this.A="";this.i=0;this.k="";this.g=this.L=this.F=this.J=!1;this.o=0;this.B=null;this.P="";this.G=this.Q=!1}y(SC,Ci);var TC=/^https?$/i,UC=["POST","PUT"];f=SC.prototype;
-f.send=function(a,b,c,d){if(this.a)throw Error("[goog.net.XhrIo] Object is active with another request="+this.A+"; newUri="+a);b=b?b.toUpperCase():"GET";this.A=a;this.k="";this.i=0;this.O=b;this.J=!1;this.b=!0;this.a=this.j?fC(this.j):fC(dC);this.I=this.j?this.j.a||(this.j.a=hC(this.j)):dC.a||(dC.a=hC(dC));this.a.onreadystatechange=v(this.Mm,this);try{bC(VC(this,"Opening Xhr")),this.L=!0,this.a.open(b,a,!0),this.L=!1}catch(e){bC(VC(this,"Error opening Xhr: "+e.message));WC(this,e);return}a=c||"";
-var g=this.headers.clone();d&&ae(d,function(a,b){g.set(b,a)});d=Pa(g.tc(),XC);c=l.FormData&&a instanceof l.FormData;!Ta(UC,b)||d||c||g.set("Content-Type","application/x-www-form-urlencoded;charset=utf-8");ae(g,function(a,b){this.a.setRequestHeader(b,a)},this);this.P&&(this.a.responseType=this.P);"withCredentials"in this.a&&(this.a.withCredentials=this.Q);try{YC(this),0<this.o&&(this.G=C&&uc(9)&&ga(this.a.timeout)&&q(this.a.ontimeout),bC(VC(this,"Will abort after "+this.o+"ms if incomplete, xhr2 "+
-this.G)),this.G?(this.a.timeout=this.o,this.a.ontimeout=v(this.uc,this)):this.B=Hi(this.uc,this.o,this)),bC(VC(this,"Sending request")),this.F=!0,this.a.send(a),this.F=!1}catch(h){bC(VC(this,"Send error: "+h.message)),WC(this,h)}};function XC(a){return"content-type"==a.toLowerCase()}f.uc=function(){"undefined"!=typeof aa&&this.a&&(this.k="Timed out after "+this.o+"ms, aborting",this.i=8,VC(this,this.k),Di(this,"timeout"),this.abort(8))};
-function WC(a,b){a.b=!1;a.a&&(a.g=!0,a.a.abort(),a.g=!1);a.k=b;a.i=5;ZC(a);$C(a)}function ZC(a){a.J||(a.J=!0,Di(a,"complete"),Di(a,"error"))}f.abort=function(a){this.a&&this.b&&(VC(this,"Aborting"),this.b=!1,this.g=!0,this.a.abort(),this.g=!1,this.i=a||7,Di(this,"complete"),Di(this,"abort"),$C(this))};f.H=function(){this.a&&(this.b&&(this.b=!1,this.g=!0,this.a.abort(),this.g=!1),$C(this,!0));SC.C.H.call(this)};f.Mm=function(){this.ka()||(this.L||this.F||this.g?aD(this):this.kw())};f.kw=function(){aD(this)};
-function aD(a){if(a.b&&"undefined"!=typeof aa)if(a.I[1]&&4==qC(a)&&2==rC(a))VC(a,"Local request error detected and ignored");else if(a.F&&4==qC(a))Hi(a.Mm,0,a);else if(Di(a,"readystatechange"),4==qC(a)){VC(a,"Request complete");a.b=!1;try{var b=rC(a),c,d;t:switch(b){case 200:case 201:case 202:case 204:case 206:case 304:case 1223:d=!0;break t;default:d=!1}if(!(c=d)){var e;if(e=0===b){var g=de(String(a.A))[1]||null;if(!g&&self.location)var h=self.location.protocol,g=h.substr(0,h.length-1);e=!TC.test(g?
-g.toLowerCase():"")}c=e}if(c)Di(a,"complete"),Di(a,"success");else{a.i=6;var k;try{k=2<qC(a)?a.a.statusText:""}catch(m){k=""}a.k=k+" ["+rC(a)+"]";ZC(a)}}finally{$C(a)}}}function $C(a,b){if(a.a){YC(a);var c=a.a,d=a.I[0]?ba:null;a.a=null;a.I=null;b||Di(a,"ready");try{c.onreadystatechange=d}catch(e){}}}function YC(a){a.a&&a.G&&(a.a.ontimeout=null);ga(a.B)&&(l.clearTimeout(a.B),a.B=null)}function qC(a){return a.a?a.a.readyState:0}function rC(a){try{return 2<qC(a)?a.a.status:-1}catch(b){return-1}}
-function sC(a){try{return a.a?a.a.responseText:""}catch(b){return""}}function VC(a,b){return b+" ["+a.O+" "+a.A+" "+rC(a)+"]"};function bD(a,b,c){this.F=a||null;this.b=1;this.g=[];this.i=[];this.a=new FC;this.k=new aC(null,!0);this.A=b||null;this.B=null!=c?c:null}function cD(a,b){this.a=a;this.map=b;this.S=null}f=bD.prototype;f.eh=null;f.xb=null;f.Na=null;f.uk=null;f.Yh=null;f.Mn=null;f.li=null;f.Lg=0;f.yu=0;f.qb=null;f.ee=null;f.Gd=null;f.Ue=null;f.ge=null;f.$h=null;f.sf=-1;f.eo=-1;f.wd=-1;f.Mg=0;f.Ef=0;f.Ge=8;var dD=new Ci;function eD(a){ei.call(this,"statevent",a)}y(eD,ei);
-function fD(a,b){ei.call(this,"timingevent",a);this.size=b}y(fD,ei);function gD(a){ei.call(this,"serverreachability",a)}y(gD,ei);f=bD.prototype;f.connect=function(a,b,c,d,e){this.a.debug("connect()");yC();this.uk=b;this.eh=c||{};d&&q(e)&&(this.eh.OSID=d,this.eh.OAID=e);this.a.debug("connectTest_()");this.ge=new JC(this,this.a);this.ge.yk=null;this.ge.g=this.k;this.ge.connect(a)};
-f.disconnect=function(){this.a.debug("disconnect()");hD(this);if(3==this.b){var a=this.Lg++,b=this.Yh.clone();Fe(b,"SID",this.j);Fe(b,"RID",a);Fe(b,"TYPE","terminate");iD(this,b);a=new iC(this,this.a,this.j,a,void 0);a.Ff=2;a.Wd=Ie(b.clone());(new Image).src=a.Wd;a.xg=x();pC(a)}jD(this)};function hD(a){a.ge&&(a.ge.abort(),a.ge=null);a.Na&&(a.Na.cancel(),a.Na=null);a.Gd&&(l.clearTimeout(a.Gd),a.Gd=null);kD(a);a.xb&&(a.xb.cancel(),a.xb=null);a.ee&&(l.clearTimeout(a.ee),a.ee=null)}
-f.Gb=function(){return 0==this.b};function lD(a){var b=0;a.Na&&b++;a.xb&&b++;return b}function mD(a){a.xb||a.ee||(a.ee=CC(v(a.jo,a),0),a.Mg=0)}
-f.jo=function(a){this.ee=null;this.a.debug("startForwardChannel_");if(1==this.b){if(!a){this.a.debug("open_()");this.Lg=Math.floor(1E5*Math.random());a=this.Lg++;var b=new iC(this,this.a,"",a,void 0);b.Be=null;var c=nD(this),d=this.Yh.clone();Fe(d,"RID",a);this.F&&Fe(d,"CVER",this.F);iD(this,d);mC(b,d,c);this.xb=b;this.b=2}}else 3==this.b&&(a?oD(this,a):0==this.g.length?this.a.debug("startForwardChannel_ returned: nothing to send"):this.xb||(oD(this),this.a.debug("startForwardChannel_ finished, sent request")))};
-function oD(a,b){var c,d;b?6<a.Ge?(a.g=a.i.concat(a.g),a.i.length=0,c=a.Lg-1,d=nD(a)):(c=b.g,d=b.Zd):(c=a.Lg++,d=nD(a));var e=a.Yh.clone();Fe(e,"SID",a.j);Fe(e,"RID",c);Fe(e,"AID",a.sf);iD(a,e);c=new iC(a,a.a,a.j,c,a.Mg+1);c.Be=null;c.setTimeout(Math.round(1E4)+Math.round(1E4*Math.random()));a.xb=c;mC(c,e,d)}function iD(a,b){if(a.qb){var c=a.qb.Mp(a);c&&ae(c,function(a,c){Fe(b,c,a)})}}
-function nD(a){var b=Math.min(a.g.length,1E3),c=["count="+b],d;6<a.Ge&&0<b?(d=a.g[0].a,c.push("ofs="+d)):d=0;for(var e=0;e<b;e++){var g=a.g[e].a,h=a.g[e].map,g=6>=a.Ge?e:g-d;try{ae(h,function(a,b){c.push("req"+g+"_"+b+"="+encodeURIComponent(a))})}catch(k){c.push("req"+g+"_type="+encodeURIComponent("_badmap"))}}a.i=a.i.concat(a.g.splice(0,b));return c.join("&")}function pD(a){a.Na||a.Gd||(a.o=1,a.Gd=CC(v(a.Oo,a),0),a.Ef=0)}
-function qD(a){if(a.Na||a.Gd||3<=a.Ef)return!1;a.a.debug("Going to retry GET");a.o++;a.Gd=CC(v(a.Oo,a),rD(a,a.Ef));a.Ef++;return!0}
-f.Oo=function(){this.Gd=null;this.a.debug("Creating new HttpRequest");this.Na=new iC(this,this.a,this.j,"rpc",this.o);this.Na.Be=null;this.Na.ck=0;var a=this.Mn.clone();Fe(a,"RID","rpc");Fe(a,"SID",this.j);Fe(a,"CI",this.$h?"0":"1");Fe(a,"AID",this.sf);iD(this,a);if(!C||vc(10))Fe(a,"TYPE","xmlhttp"),oC(this.Na,a,!0,this.li,!1);else{Fe(a,"TYPE","html");var b=this.Na,c=Boolean(this.li);b.Ff=3;b.Wd=Ie(a.clone());BC(b,c)}this.a.debug("New Request created")};
-function PC(a,b,c){a.a.debug("Test Connection Finished");a.$h=c;a.wd=b.Ve;a.a.debug("connectChannel_()");a.wv(1,0);a.Yh=KC(a,a.uk);mD(a)}function RC(a,b){a.a.debug("Test Connection Failed");a.wd=b.Ve;OC(a,2)}
-f.$o=function(a,b){if(0!=this.b&&(this.Na==a||this.xb==a))if(this.wd=a.vg,this.xb==a&&3==this.b)if(7<this.Ge){var c;try{c=this.k.parse(b)}catch(d){c=null}if(t(c)&&3==c.length){var e=c;if(0==e[0])t:if(this.a.debug("Server claims our backchannel is missing."),this.Gd)this.a.debug("But we are currently starting the request.");else{if(this.Na)if(this.Na.xg+3E3<this.xb.xg)kD(this),this.Na.cancel(),this.Na=null;else break t;qD(this);yC()}else this.eo=e[1],c=this.eo-this.sf,0<c&&(e=e[2],this.a.debug(e+" bytes (in "+
-c+" arrays) are outstanding on the BackChannel"),37500>e&&this.$h&&0==this.Ef&&!this.Ue&&(this.Ue=CC(v(this.wu,this),6E3)))}else this.a.debug("Bad POST response data returned"),OC(this,11)}else"y2f%"!=b&&(this.a.debug("Bad data returned - missing/invald magic cookie"),OC(this,11));else if(this.Na==a&&kD(this),!/^[\s\xa0]*$/.test(b))for(c=this.k.parse(b),t(c),e=0;e<c.length;e++){var g=c[e];this.sf=g[0];g=g[1];2==this.b?"c"==g[0]?(this.j=g[1],this.li=g[2],g=g[3],null!=g?this.Ge=g:this.Ge=6,this.b=3,
-this.qb&&this.qb.co(this),this.Mn=QC(this,this.li,this.uk),pD(this)):"stop"==g[0]&&OC(this,7):3==this.b&&("stop"==g[0]?OC(this,7):"noop"!=g[0]&&this.qb&&this.qb.bo(this,g),this.Ef=0)}};f.wu=function(){null!=this.Ue&&(this.Ue=null,this.Na.cancel(),this.Na=null,qD(this),yC())};function kD(a){null!=a.Ue&&(l.clearTimeout(a.Ue),a.Ue=null)}
-f.Uh=function(a){this.a.debug("Request complete");var b;if(this.Na==a)kD(this),this.Na=null,b=2;else if(this.xb==a)this.xb=null,b=1;else return;this.wd=a.vg;if(0!=this.b)if(a.Cc)1==b?(x(),Di(dD,new fD(dD,a.Zd?a.Zd.length:0)),mD(this),this.i.length=0):pD(this);else{var c=a.Ie;if(3==c||7==c||0==c&&0<this.wd)this.a.debug("Not retrying due to error type");else{this.a.debug("Maybe retrying, last error: "+jC(c,this.wd));var d;if(d=1==b)this.xb||this.ee?d=!1:1==this.b||2<=this.Mg?d=!1:(this.a.debug("Going to retry POST"),
-this.ee=CC(v(this.jo,this,a),rD(this,this.Mg)),this.Mg++,d=!0);if(d||2==b&&qD(this))return;this.a.debug("Exceeded max number of retries")}this.a.debug("Error: HTTP request failed");switch(c){case 1:OC(this,5);break;case 4:OC(this,10);break;case 3:OC(this,6);break;case 7:OC(this,12);break;default:OC(this,2)}}};function rD(a,b){var c=5E3+Math.floor(1E4*Math.random());a.qb||(a.a.debug("Inactive channel"),c*=2);return c*b}
-f.wv=function(a){if(!Ta(arguments,this.b))throw Error("Unexpected channel state: "+this.b);};function OC(a,b){a.a.info("Error code "+b);if(2==b||9==b){var c=null;a.qb&&(c=null);var d=v(a.zv,a);c||(c=new re("//www.google.com/images/cleardot.gif"),Ie(c));HC(c.toString(),1E4,d)}else yC();sD(a,b)}f.zv=function(a){a?(this.a.info("Successfully pinged google.com"),yC()):(this.a.info("Failed to ping google.com"),yC(),sD(this,8))};
-function sD(a,b){a.a.debug("HttpChannel: error - "+b);a.b=0;a.qb&&a.qb.Ho(a,b);jD(a);hD(a)}function jD(a){a.b=0;a.wd=-1;if(a.qb)if(0==a.i.length&&0==a.g.length)a.qb.Ek(a);else{a.a.debug("Number of undelivered maps, pending: "+a.i.length+", outgoing: "+a.g.length);var b=ab(a.i),c=ab(a.g);a.i.length=0;a.g.length=0;a.qb.Ek(a,b,c)}}function KC(a,b){var c=NC(a,null,b);a.a.debug("GetForwardChannelUri: "+c);return c}function QC(a,b,c){b=NC(a,a.fi()?b:null,c);a.a.debug("GetBackChannelUri: "+b);return b}
-function NC(a,b,c){var d=Je(c);if(""!=d.Ne)b&&te(d,b+"."+d.Ne),ue(d,d.ih);else var e=window.location,d=Ke(e.protocol,b?b+"."+e.hostname:e.hostname,e.port,c);a.eh&&ae(a.eh,function(a,b){Fe(d,b,a)});Fe(d,"VER",a.Ge);iD(a,d);return d}f.rk=function(a){if(a)throw Error("Can't create secondary domain capable XhrIo object.");a=new SC;a.Q=!1;return a};function CC(a,b){if(!ha(a))throw Error("Fn must not be null and must be a function");return l.setTimeout(function(){a()},b)}f.Bc=function(){Di(dD,new gD(dD))};
-function yC(){Di(dD,new eD(dD))}f.fi=function(){return!(!C||vc(10))};function tD(){}f=tD.prototype;f.co=function(){};f.bo=function(){};f.Ho=function(){};f.Ek=function(){};f.Mp=function(){return{}};function uD(a){a&&(this.id=a.id||a.name,this.name=a.name,this.app=a.app,this.type=a.type||"REMOTE_CONTROL",this.dp=a.user||"")}f=uD.prototype;f.id="";f.name="";f.app="";f.type="REMOTE_CONTROL";f.dp="";f.equals=function(a){return a?this.id==a.id:!1};function vD(a,b){this.action=a;this.params=b||null};function wD(){v(this.i,this);this.a=new ZB;this.a.b=!1;this.b=this.a.a=!1;this.g="";this.j={}}function xD(){var a=yD;!0!=a.b&&(SB(),a.b=!0)}wD.prototype.i=function(a){if(!this.j[a.g]){var b=$B(this.a,a),c=zD;if(c)switch(a.j){case MB:AD(c,"info",b);break;case NB:AD(c,"error",b);break;case OB:AD(c,"warn",b);break;default:AD(c,"debug",b)}else window.opera?window.opera.postError(b):this.g+=b}};var yD=null,zD=window.console;function AD(a,b,c){if(a[b])a[b](c);else a.log(c)};var BD=null,CD=null,DD=Array(50),ED=-1,FD=!1;function GD(a){var b=(ED+1)%50;ED=b;DD[b]=a;FD||(FD=49==b)}function HD(a){var b=DD;if(b[0]){var c=ED,d=FD?c:-1;do{var d=(d+1)%50,e=b[d];z(a,function(a){a(e)})}while(d!=c);DD=Array(50);ED=-1;FD=!1}}
-function ID(){var a=JD,b=n("yt.mdx.remote.debug.logger_"),c=n("yt.mdx.remote.debug.handlers_");b&&c||(yD||(yD=new wD),-1!=window.location.href.indexOf("Debug=true")&&xD(),xD(),yD.a.a=!0,(b=n("yt.mdx.remote.debug.logger_"))||(b=TB("yt.mdx.remote")),BD=b,KB.prototype.log=KB.prototype.log,KB.prototype.getLogRecord=KB.prototype.Dv,KB.prototype.addHandler=KB.prototype.Cv,KB.prototype.removeHandler=KB.prototype.Ev,pa("yt.mdx.remote.debug.logger_",BD),CD=n("yt.mdx.remote.debug.handlers_")||[],pa("yt.mdx.remote.debug.handlers_",
-CD),n("yt.mdx.remote.debug.logger_"),c=n("yt.mdx.remote.debug.handlers_"));c&&(c.push(a),HD(c))}function KD(a,b){var c=n("yt.mdx.remote.debug.logger_"),d=n("yt.mdx.remote.debug.handlers_");if(c){if(c.log(PB,a+": "+b,void 0),d&&!Ua(d)){HD(d);var e=c.getLogRecord(PB,a+": "+b,void 0);z(d,function(a){a(e)})}}else d&&!Ua(d)||GD(new IB(PB,String(b),"yt.mdx.remote"))};function LD(){if(!("cast"in window))return!1;var a=window.cast||{};return"ActivityStatus"in a&&"Api"in a&&"LaunchRequest"in a&&"Receiver"in a}function MD(a){KD("CAST",a)}function JD(a){var b=ND();b&&b.logMessage&&(a=$B(OD,a),b.logMessage(a))}
-function PD(){if(!QD&&(Ua(RD)&&bb(RD,Og()),LD())){var a=ND();a?(a.removeReceiverListener("YouTube",SD),a.addReceiverListener("YouTube",SD),MD("API initialized in the other binary")):(a=new cast.Api,pa("yt.mdx.remote.castapi.api_",a),a.addReceiverListener("YouTube",SD),a.setReloadTabRequestHandler&&a.setReloadTabRequestHandler(function(){window.location.reload()}),OD=new ZB,OD.b=!1,OD.a=!1,ID(),MD("API initialized"));QD=!0}}
-function TD(a){var b=Qa(RD,function(b){return b.id==a.id});0<=b&&(RD[b]=ng(a))}function SD(a){MD("Updating receivers: "+pb(a));UD(a);op("yt-remote-cast-device-list-update",VD());z(VD(),function(a){WD(a.id)});z(a,function(a){a.isTabProjected&&(a=XD(a.id),MD("Detected device: "+a.id+" is tab projected. Firing DEVICE_TAB_PROJECTED event."),op("yt-remote-cast-device-tab-projected",a))})}
-function YD(a,b){MD("Updating "+a+" activity status: "+pb(b));var c=XD(a);c?(b.activityId&&(c.activityId=b.activityId),c.status="running"==b.status?"RUNNING":"stopped"==b.status?"STOPPED":"error"==b.status?"ERROR":"UNKNOWN","RUNNING"!=c.status&&(c.activityId=""),TD(c),op("yt-remote-cast-device-status-update",c)):MD("Device not found")}function VD(){PD();return tg(RD)}
-function UD(a){a=La(a,function(a){var c={id:a.id,name:a.name};if(a=XD(a.id))c.activityId=a.activityId,c.status=a.status;return c});Va(RD);bb(RD,a)}function XD(a){var b=VD();return Pa(b,function(b){return b.id==a})||null}function WD(a){var b=XD(a),c=ND();c&&b&&b.activityId&&c.getActivityStatus(b.activityId,function(b){"error"==b.status&&(b.status="stopped");YD(a,b)})}
-function ZD(a){PD();var b=XD(a),c=ND();c&&b&&b.activityId?(MD("Stopping cast activity"),c.stopActivity(b.activityId,oa(YD,a))):MD("Dropping cast activity stop")}function ND(){return n("yt.mdx.remote.castapi.api_")}var OD=null,QD=!1,RD=n("yt.mdx.remote.castapi.devices_")||[];pa("yt.mdx.remote.castapi.devices_",RD);function $D(a,b){Fi.call(this);if(ha(a))b&&(a=v(a,b));else if(a&&ha(a.handleEvent))a=v(a.handleEvent,a);else throw Error("Invalid listener argument");this.o=a;si(this,"tick",v(this.k,this));this.stop();Gi(this,5E3+2E4*Math.random())}y($D,Fi);$D.prototype.j=0;$D.prototype.k=function(){if(500<this.a){var a=this.a;24E4>2*a&&(a*=2);Gi(this,a)}this.o()};$D.prototype.start=function(){$D.C.start.call(this);this.j=x()+this.a};$D.prototype.stop=function(){this.j=0;$D.C.stop.call(this)};function aE(a,b){this.k=a;this.j=b;this.g=new Xh;this.b=new $D(this.Gt,this);this.a=null}y(aE,tD);f=aE.prototype;f.Th="";f.Pg=0;f.xi=0;f.He=function(){};f.D=function(a,b,c){return this.g.D(a,b,c)};f.$=function(a,b,c){return this.g.$(a,b,c)};f.Rc=function(a){return this.g.Rc(a)};f.u=function(a,b){return this.g.u.apply(this.g,arguments)};
-f.connect=function(a,b,c){if(!this.a||2!=this.a.b){this.Th="";this.b.stop();this.i=a||null;this.Pg=b||0;a=this.k+"/test";b=this.k+"/bind";var d=new bD("1",c?c.firstTestResults:null,c?c.secondTestResults:null),e=this.a;e&&(e.qb=null);d.qb=this;this.a=d;e?(3!=e.b&&0==lD(e)||this.He("Unexpected state on old channel when reconnecting: "+e.b),this.a.connect(a,b,this.j,e.j,e.sf)):c?this.a.connect(a,b,this.j,c.sessionId,c.arrayId):this.a.connect(a,b,this.j)}};
-f.disconnect=function(a){this.xi=a||0;this.b.stop();this.a&&0!=this.a.b&&this.a.disconnect();this.xi=0};f.sendMessage=function(a,b){if(!this.a||0==this.a.b||2!=this.a.b&&3!=this.a.b&&!this.b.Tc)this.He("Ignoring message: "+a);else{var c={_sc:a};b&&Rb(c,b);var d=this.a;if(0==d.b)throw Error("Invalid operation: sending map when state is closed");1E3==d.g.length&&pb(c);d.g.push(new cD(d.yu++,c));2!=d.b&&3!=d.b||mD(d)}};
-f.co=function(){var a=this.b;a.stop();Gi(a,5E3+2E4*Math.random());this.i=null;this.Pg=0;this.u("handlerOpened")};f.Ho=function(a,b){var c=2==b&&401==this.a.wd;4==b||c||(6==b&&(c=this.b,c.stop(),Gi(c,500)),this.b.start());this.u("handlerError",b)};f.Ek=function(){this.b.Tc||this.u("handlerClosed")};f.Mp=function(){var a={v:2};this.Th&&(a.gsessionid=this.Th);0!=this.Pg&&(a.ui=""+this.Pg);0!=this.xi&&(a.ui=""+this.xi);this.i&&Rb(a,this.i);return a};
-f.bo=function(a,b){"S"==b[0]?this.Th=b[1]:this.g.u("handlerMessage",new vD(b[0],b[1]))};function bE(a,b){(a.j.loungeIdToken=b)||a.b.stop()}function cE(a){return a.b.Tc?a.b.j-x():NaN}f.Gt=function(){this.b.stop();0!=lD(this.a)?this.b.start():this.connect(this.i,this.Pg)};function dE(a,b){aE.call(this,a,b)}y(dE,aE);dE.prototype.He=function(){};function eE(){this.wb=[];this.index=-1;fE(this)}function fE(a){a.volume=-1;a.muted=!1;a.b=null;a.a=-1;a.g=null;a.i=0;a.j=x()}function gE(a){return a.wb[a.index]}function hE(a,b){a.i=b;a.j=x()}function iE(a){switch(a.a){case 1:return(x()-a.j)/1E3+a.i;case -1E3:return 0}return a.i}function jE(a,b){var c=a.index;a.index=Ja(a.wb,b);c!=a.index&&fE(a)}function kE(a,b,c){c=c||gE(a);if(jb(a.wb,b)&&c==gE(a))return!1;a.wb=ab(b);jE(a,c);return!0}
-eE.prototype.add=function(a,b){return a&&!Ta(this.wb,a)?(!b||-1<this.index&&this.index>=this.wb.length-1?this.wb.push(a):this.wb.splice(this.index+1,0,a),!0):!1};eE.prototype.remove=function(a){var b=gE(this);return Xa(this.wb,a)?(this.index=Ja(this.wb,b),!0):!1};function lE(){R.call(this);this.Fc=xg(Lg());this.log_("Initializing local screens: "+Nf(this.Fc));this.g=[];this.nk=null;this.b=[];this.a=[];this.pi(VD());this.log_("Initializing DIAL devices: "+og(this.a));var a=xg(Mg());mE(this,a);this.log_("Initializing online screens: "+Nf(this.b));nE(this)}y(lE,R);var oE=[2E3,2E3,1E3,1E3,1E3,2E3,2E3,5E3,5E3,1E4];f=lE.prototype;f.gh=NaN;f.log_=function(a){KD("RM",a)};
-function pE(a){var b=navigator.userAgent;if(0<=b.search("MSIE")&&(b=b.match(/MSIE ([\d.]+)/)[1],0>Ea(b,"10.0")))return a;b=de(document.location.href);return be("https",null,b[3],null,a)}function nE(a){jp("yt-remote-cast-device-list-update",a.pi,a);jp("yt-remote-cast-device-status-update",a.bx,a);jp("yt-remote-cast-device-tab-projected",function(a){this.u("connectToReceiver",a.id)},a);a.pp();hf(v(a.pp,a),1E4)}
-f.u=function(a,b){if(this.ka())return!1;this.log_("Firing "+a);return this.F.u.apply(this.F,arguments)};f.pp=function(){var a=VD();Ua(a)||this.pi(a);a=qE(this);Ua(a)||(ig("yt-remote-lounge-token-expiration")?rE(this,a):sE(this))};f.Uk=function(){var a=qE(this),b=Ka(a,function(a){return!!Ag(this.b,a)},this);mE(this,b);this.pi(VD());this.u("managedScreenChange",a)};function tE(a,b){return Ka(b,function(a){return a.zb?(a=vg(this.a,a.zb),!!a&&"RUNNING"==a.status):!0},a)}
-f.pi=function(a){var b=!1;z(a,function(a){var c=Bg(this.Fc,a.id);c&&c.name!=a.name&&(this.log_("Renaming screen id "+c.id+" from "+c.name+" to "+a.name),c.name=a.name,b=!0)},this);b&&(this.log_("Renaming due to DIAL."),uE(this));Ng(sg(a));var c=!jb(this.a,a,ug);c&&this.log_("Updating DIAL devices: "+og(this.a)+" to "+og(a));this.a=a;mE(this,this.b);c&&this.u("onlineReceiverChange")};
-f.bx=function(a){var b=vg(this.a,a.id);b&&(this.log_("Updating DIAL device: "+b.id+"("+b.name+") from status: "+b.status+" to status: "+a.status+" and from activityId: "+b.activityId+" to activityId: "+a.activityId),b.activityId=a.activityId,b.status=a.status,Ng(sg(this.a)));mE(this,this.b)};function mE(a,b,c){b=tE(a,b);var d=!jb(a.b,b,zg);!d&&!c||Ua(b)||(c=wg(b),fg("yt-remote-online-screens",c,60));d&&(a.log_("Updating online screens: "+Nf(a.b)+" -> "+Nf(b)),a.b=b,a.u("onlineReceiverChange"))}
-function rE(a,b){var c=[],d={};z(b,function(a){a.kc&&(d[a.kc]=a,c.push(a.kc))});var e={method:"POST",Gf:{lounge_token:c.join(",")},S:a,Pa:function(a,b){var c=[];z(b.screens||[],function(a){"online"==a.status&&c.push(d[a.loungeToken])});var e=this.nk?vE(this,this.nk):null;e&&!Ag(c,e)&&c.push(e);mE(this,c,!0)}};Qj(pE("/api/lounge/pairing/get_screen_availability"),e)}
-function sE(a){var b=qE(a),c=La(b,function(a){return a.nb});Ua(c)||(a.log_("Updating lounge tokens for: "+pb(c)),Qj(pE("/api/lounge/pairing/get_lounge_token_batch"),{Gf:{screen_ids:c.join(",")},method:"POST",S:a,Pa:function(a,c){wE(this,c.screens||[]);this.Fc=Ka(this.Fc,function(a){return!!a.kc});uE(this);rE(this,b)}}))}function wE(a,b){z($a(a.Fc,a.g),function(a){var d=Pa(b,function(b){return a.nb==b.screenId});d&&(a.kc=d.loungeToken)})}
-function uE(a){var b=xg(Lg());jb(a.Fc,b,zg)||(a.log_("Saving local screens: "+Nf(b)+" to "+Nf(a.Fc)),Kg(wg(a.Fc)),a.Uk())}function yE(a,b,c){var d=Qa(b,function(a){return yg(c,a)}),e=0>d?!0:!1;0>d?b.push(c):b[d]=c;Ag(a.b,c)||a.b.push(c);return e}
-f.Po=function(a,b,c){var d=!1;b>=oE.length&&(this.log_("Pairing DIAL device "+a+" with "+c+" timed out."),d=!0);var e=vg(this.a,a);if(!e)this.log_("Pairing DIAL device "+a+" with "+c+" failed: no device for "+a),d=!0;else if("ERROR"==e.status||"STOPPED"==e.status)this.log_("Pairing DIAL device "+a+" with "+c+" failed: launch error on "+a),d=!0;d?(zE(this),this.u("screenPair",null)):Qj(pE("/api/lounge/pairing/get_screen"),{method:"POST",Gf:{pairing_code:c},S:this,Pa:function(a,b){zE(this);var d=new Lf(b.screen);
-d.name=e.name;d.zb=e.id;var m=yE(this,this.Fc,d);this.log_("Paired with "+(m?"a new":"an old")+" local screen:"+Mf(d));uE(this);this.u("screenPair",d);this.log_("Pairing "+c+" succeeded.");this.u("screenPair",d)},onError:function(){this.log_("Polling pairing code: "+c);I(this.gh);this.gh=H(v(this.Po,this,a,b+1,c),oE[b])}})};
-function AE(a,b,c,d,e){zE(a);if(vg(a.a,b)){if(!c){var g=c=pg();PD();var h=XD(b),k=ND();if(k&&h){var m=new cast.Receiver(h.id,h.name),m=new cast.LaunchRequest("YouTube",m);m.parameters="pairingCode="+g;m.description=new cast.LaunchDescription;m.description.text=document.title;d&&(m.parameters+="&v="+d,e&&(m.parameters+="&t="+Math.round(e)),m.description.url="http://i.ytimg.com/vi/"+d+"/default.jpg");"UNKNOWN"!=h.status&&(h.status="UNKNOWN",TD(h),op("yt-remote-cast-device-status-update",h));MD("Sending a cast launch request with params: "+
-m.parameters);k.launch(m,oa(YD,b))}else MD("No cast API or no cast device. Dropping cast launch.")}a.gh=H(v(a.Po,a,b,0,c),oE[0])}else a.log_("No DIAL device with id: "+b)}function zE(a){I(a.gh);a.gh=NaN}function vE(a,b){var c=Bg(qE(a),b);a.log_("Found screen: "+Mf(c)+" with key: "+b);return c}function BE(a,b){var c=Bg(a.b,b);a.log_("Found online screen: "+Mf(c)+" with key: "+b);return c}
-function CE(a,b){var c=vg(a.a,b);if(!c){var d=Bg(a.Fc,b);d&&(c=vg(a.a,d.zb))}a.log_("Found DIAL: "+(c?c.toString():"null")+" with key: "+b);return c}function qE(a){return $a(a.g,Ka(a.Fc,function(a){return!Ag(this.g,a)},a))};function DE(a,b){R.call(this);if(gg){var c=gg;eg(c,c.If.Id(!0))}Cg();TB("goog.net.BrowserChannel");this.i=new lE;c=Eg();this.g=new dE("/api/lounge/bc",{device:"REMOTE_CONTROL",id:c,name:a,app:b});this.a=null;this.A=[];this.g.D("handlerOpened",this.Ru,this);this.g.D("handlerClosed",this.Ou,this);this.g.D("handlerError",this.Pu,this);this.g.D("handlerMessage",this.Qu,this);this.i.D("managedScreenChange",this.Uk,this);this.log_("Initializing with device id = "+c+", name = "+a+", app = "+b)}y(DE,R);
-f=DE.prototype;f.Sg=NaN;f.Qk=NaN;f.Oi=NaN;f.Pi=NaN;f.log_=function(a){KD("RC",a)};function EE(a){var b=Fg();return b?vE(a.i,b):null}function FE(a,b,c){a.$("connectionOpened",b,c);a.$("connectionClosed",b,c);a.$("connectionError",b,c)}function GE(a,b){"connectionError"==b&&jg("yt-remote-session-screen-id");a.log_("Firing "+b);a.u(b,"connectionOpened"==b);a.o=null}
-function HE(a,b){"playerChange"==b?(I(a.Oi),a.Oi=H(v(function(){this.u("playerChange");this.Oi=NaN},a),2E3)):"playlistChange"==b&&(I(a.Pi),a.Pi=H(v(function(){this.u("playlistChange");this.Pi=NaN},a),2E3))}function IE(a,b){"playerChange"==b&&isNaN(a.Oi)&&a.u("playerChange");"playlistChange"==b&&isNaN(a.Pi)&&a.u("playlistChange")}function JE(a,b){b?(a.log_("Changing current screen id from: "+a.j+" to "+b.nb),a.j=b.nb,bE(a.g,b.kc)):(a.log_("Removing current screen id: "+a.j),a.j="",bE(a.g,""))}
-function KE(a){return a.j?vE(a.i,a.j):null}f.connect=function(a){this.log_("Connecting to the receiver: "+pb(a));var b=BE(this.i,a.key);b?LE(this,b):(a=CE(this.i,a.key))?ME(this,a):H(v(function(){GE(this,"connectionError")},this),0)};function NE(a){a=a||0;5>=a&&(a=0);return a}
-function LE(a,b){a.log_("Connecting to screen: "+Mf(b));var c=EE(a);c&&!yg(b,c)?a.disconnect():OE(a);a.a=null;JE(a,b);c={};if(a.b){c.videoIds=PE(a.b).join(",");c.videoId=a.b.a.getVideoData().M;c.videoSources=QE(a.b).join(",");var d=a.o?a.o.currentTime:a.b.a.getCurrentTime();c.currentTime=NE(d)}Nb(c)?a.log_("Connecting with empty params"):a.log_("Connecting with setPlaylist and params: "+pb(c));a.b?Pg(a.b.a.getVideoData().M,RE(a.b)):Pg("","");a.g.connect(Nb(c)?{}:{method:"setPlaylist",params:pb(c)},
-1,Jg());a.a=new eE;Nb(c)||(a.a.wb=c.videoIds.split(","),jE(a.a,c.videoId));SE(a)}function ME(a,b){a.log_("Connecting to DIAL device: "+(b?b.toString():"null"));TE(a);UE(a);var c=a.o?a.o.pairingCode:"";c?AE(a.i,b.id,c):a.b?AE(a.i,b.id,"",a.b.a.getVideoData().M,a.b.a.getCurrentTime()):AE(a.i,b.id,"");a.k=b.id;a.i.D("screenPair",a.Cn,a)}f.Cn=function(a){this.log_("Paired with a DIAL screen: "+Mf(a));TE(this);a?LE(this,a):(this.k="",GE(this,"connectionError"))};
-f.disconnect=function(){this.log_("Disconnecting with user intent.");UE(this);Qg();this.g.disconnect(1)};function UE(a){zE(a.i);var b=Pa(a.A,function(a){return"REMOTE_CONTROL"==a.type});b?(a.log_("Did not stop DIAL device, because another remote is connected: "+pb(b?{id:b.id,name:b.name,app:b.app,type:b.type,user:b.dp}:null)),a.k=""):(b=KE(a),a.k?(a.log_("Stopping DIAL device: "+a.k),ZD(a.k),a.k=""):b&&b.zb&&(a.log_("Stopping DIAL device: "+b.zb),ZD(b.zb)))}
-function OE(a){a.log_("Disconnecting from screen.");a.g.disconnect(2)}function VE(a,b){var c=KE(a),d=Pa(b,function(a){return c&&(a.key==c.nb||a.key==c.zb)||this.k&&(a=CE(this.i,a.key))&&a.id==this.k?!0:!1},a);a.log_("Found current receiver: "+pb(d)+" in "+pb(b));return d}function WE(a){return XE(a)?a.a:null}function YE(a,b,c){c?a.log_("Sending: action="+b+", params="+pb(c)):a.log_("Sending: action="+b);ZE(a)?a.log_("Action = "+b+" was ignored due to reconnecting."):a.g.sendMessage(b,c)}
-function $E(a,b,c,d){d=NE(d);a.a.add(b,!0)&&YE(a,"insertVideo",{videoId:b,videoSource:c});hE(a.a,d);jE(a.a,b);HE(a,"playlistChange");YE(a,"setVideo",{currentTime:d,videoId:b})}function aF(a,b,c,d,e){e=NE(e);YE(a,"setPlaylist",{videoIds:c.join(","),videoId:b,videoSources:La(c,function(){return d}),currentTime:e});hE(a.a,e);kE(a.a,c,b);HE(a,"playlistChange")}
-function bF(a){var b=ig("yt-remote-session-video-id"),c=ig("yt-remote-session-list-id"),d=a.b.a.getVideoData().M,e=RE(a.b);Pg(d,e);a.log_("Watch context changed: videoId from "+b+" to "+d+" listId from "+c+" to "+e);var g=!1,h=!1;d&&d!=b&&(g=!0);e&&e!=c&&(h=!0);g?(b=QE(a.b),c=a.b.a.vb(),b=b[c?c.ua:0],c=a.b.a.getCurrentTime(),h?aF(a,d,PE(a.b),b,c):$E(a,d,b,c)):h&&(d=PE(a.b),h=QE(a.b),YE(a,"updatePlaylist",{videoIds:d.join(","),videoSources:h.join(",")}),kE(a.a,d),HE(a,"playlistChange"))}
-function cF(a){YE(a,"play");hE(a.a,iE(a.a));-1E3!=a.a.a&&(a.a.a=1);HE(a,"playerChange")}f.ao=function(){YE(this,"getNowPlaying")};function XE(a){var b=a.g.a;return!!b&&3==b.b&&!!a.j&&isNaN(a.Sg)}function SE(a){dF(a);a.Sg=H(v(function(){dF(this);JE(this,null);this.k="";this.a=null;this.log_("Connecting timeout");GE(this,"connectionError");Qg();this.g.disconnect(1)},a),1E4)}function dF(a){I(a.Sg);a.Sg=NaN}function eF(a){I(a.Qk);a.Qk=NaN}function TE(a){a.i.$("screenPair",a.Cn,a)}
-f.Ru=function(){this.log_("Channel opened");var a=this.j;fg("yt-remote-session-browser-channel",{firstTestResults:[""],secondTestResults:!this.g.a.$h,sessionId:this.g.a.j,arrayId:this.g.a.sf});fg("yt-remote-session-screen-id",a);var a=Dg(),b=Eg();Ta(a,b)||a.push(b);Hg(a);Cg();this.b&&(this.b.a.getVideoData().Ta&&!RE(this.b)?this.log_("Wait for playlist data to be loaded."):bF(this))};function fF(a){Qg(!0);eF(a);a.i.nk=null;JE(a,null);a.k=""}
-f.Ou=function(){this.log_("Channel closed");var a=!!this.j&&isNaN(this.Sg);fF(this);a&&GE(this,"connectionClosed")};f.Pu=function(a){ZE(this)?this.log_("Channel error: "+a+" with reconnection in "+cE(this.g)+" ms"):this.log_("Channel error: "+a+" without reconnection");ZE(this)||fF(this);dF(this);GE(this,"connectionError")};
-function gF(a,b){switch(b.action){case "loungeStatus":var c=nb(b.params.devices);a.A=La(c,function(a){return new uD(a)});break;case "loungeScreenDisconnected":Za(a.A,function(a){return"LOUNGE_SCREEN"==a.type});break;case "remoteConnected":var d=new uD(nb(b.params.device));Pa(a.A,function(a){return a.equals(d)})||Wa(a.A,d);break;case "remoteDisconnected":d=new uD(nb(b.params.device)),Za(a.A,function(a){return a.equals(d)})}}
-function hF(a,b){var c=!1;if("loungeStatus"==b.action)c=!!Pa(a.A,function(a){return"LOUNGE_SCREEN"==a.type});else if("loungeScreenConnected"==b.action)c=!0;else if("loungeScreenDisconnected"==b.action)c=!1;else return;c!=XE(a)&&(c?(dF(a),GE(a,"connectionOpened"),a.ao()):a.disconnect())}function ZE(a){return!isNaN(cE(a.g))}
-f.Qu=function(a){a.params?this.log_("Received: action="+a.action+", params="+pb(a.params)):this.log_("Received: action="+a.action);gF(this,a);hF(this,a);if(XE(this)){var b=!1,c=!1,d,e,g,h,k,m,p;a.params&&(d=a.params.videoId||a.params.video_id,e=a.params.videoIds||a.params.video_ids,g=a.params.state,h=a.params.currentTime||a.params.current_time,k=a.params.volume,m=a.params.muted,q(a.params.currentError)&&(p=nb(a.params.currentError)));if("onSubtitlesTrackChanged"==a.action)d==gE(this.a)&&(delete a.params.videoId,
-Nb(a.params)?this.a.b=null:this.a.b=a.params,IE(this,"playerChange"));else if(gE(this.a)||'"onStateChange"'!=a.action)"playlistModified"!=a.action&&"nowPlayingPlaylist"!=a.action||e?(d||"nowPlaying"!=a.action&&"nowPlayingPlaylist"!=a.action?d?d!=gE(this.a)&&(b=!0):d=gE(this.a):(jE(this.a,""),b=!0),e&&(e=e.split(","),kE(this.a,e,d)&&(b=!0))):(kE(this.a,[]),b=!0),this.a.add(d)&&YE(this,"getPlaylist"),d&&jE(this.a,d),b&&IE(this,"playlistChange"),q(g)&&(b=parseInt(g,10),b=isNaN(b)?-1:b,-1==b&&-1E3==this.a.a&&
-(b=-1E3),0==b&&"0"==h&&(b=-1),c=c||b!=this.a.a,this.a.a=b,d=null,-1E3==b&&(d=this.a.g||"unknown",p&&(d=p.reason||d)),c=c||this.a.g!=d,this.a.g=d,1==this.a.a?(eF(this),this.Qk=H(v(this.ao,this),2E4)):eF(this)),"onError"!=a.action||-1!=this.a.a&&-1E3!=this.a.a||(a=nb(a.params.errors)||[],1==a.length&&"PLAYER_ERROR"==a[0].error&&a[0].videoId==gE(this.a)&&(this.a.a=-1E3,this.a.g=a[0].reason||"unknown",c=!0)),h&&(b=parseInt(h,10),hE(this.a,isNaN(b)?0:b),c=!0),q(k)&&(b=parseInt(k,10),isNaN(b)||(c=c||this.a.volume!=
-b,this.a.volume=b),q(m)&&(m="true"==m,c=c||this.a.muted!=m,this.a.muted=m)),c&&IE(this,"playerChange")}};f.Uk=function(){this.j&&!KE(this)?(this.log_("Dropping current screen with id: "+this.j),this.disconnect(),this.a=null):EE(this)||Qg()};function iF(){DE.call(this,"Desktop","youtube-desktop");J(window,"unload",v(this.B,this));J(window,"beforeunload",v(this.B,this))}y(iF,DE);ca(iF);iF.prototype.B=function(){OE(this)};function jF(a,b){this.a=a;this.a.D("onVolumeChange",this.Nh,this);this.a.D("onPlaylistUpdate",this.Pm,this);this.i=NaN;this.b=b;this.b.D("playerChange",this.Qm,this);this.b.D("playlistChange",this.Rm,this);this.k=0;this.g={};this.j=new Np(this.Ys,1E3,this);L(this,this.j);this.o=0}y(jF,K);f=jF.prototype;
-f.H=function(){kF(this);this.a.$("onVolumeChange",this.Nh,this);this.a.$("onPlaylistUpdate",this.Pm,this);this.a=null;this.b.$("playerChange",this.Qm,this);this.b.$("playlistChange",this.Rm,this);this.b=null};f.Pw=function(a,b){WE(this.b)&&(lF(this)?this.Qv.apply(this,arguments):this.Rv.apply(this,arguments))};
-f.Rv=function(a,b){var c=Array.prototype.slice.call(arguments,1);switch(a){case "control_toggle_play_pause":case "control_play":case "control_pause":mF(this,this.a.a.getCurrentTime());break;case "control_seek":mF(this,c[0])}};
-f.Qv=function(a,b){var c=WE(this.b),d=Array.prototype.slice.call(arguments,1);switch(a){case "control_toggle_play_pause":1==c.a?nF(this):(cF(this.b),this.a.mb(!0));break;case "control_play":cF(this.b);this.a.mb(!0);break;case "control_pause":nF(this);break;case "control_seek":this.o=d[0];Op(this.j);break;case "control_subtitles_set_track":oF(this,d[0])}};function nF(a){var b=a.b;YE(b,"pause");hE(b.a,iE(b.a));-1E3!=b.a.a&&(b.a.a=2);HE(b,"playerChange");pF(a,iE(WE(a.b)));kF(a);a.a.mb(!1)}
-f.Ys=function(){var a=this.o,b=WE(this.b);kF(this);pF(this,a);-1==b.a?mF(this,a):(b=this.b,a=Math.floor(a),YE(b,"seekTo",{newTime:a}),hE(b.a,a),-1E3!=b.a.a&&(b.a.a=3),HE(b,"playerChange"))};
-function oF(a,b){if(lF(a)){var c=a.b,d=a.a.a.getVideoData().M;b?(c.a.b={trackName:b.name,languageCode:b.languageCode,sourceLanguageCode:b.translationLanguage?b.translationLanguage.languageCode:"",languageName:b.languageName,format:b.format,kind:b.kind},d={videoId:d},Rb(d,c.a.b),YE(c,"setSubtitlesTrack",d)):YE(c,"setSubtitlesTrack");HE(c,"playerChange");a.g=WE(a.b).b}}function mF(a,b){$E(a.b,a.a.a.getVideoData().M,"VI",b);var c=a.a;qF(c);rF(c.g)}
-f.Nh=function(a){if(lF(this)){var b=Math.round(a.volume),c=this.b;a=!!a.muted;var d={volume:b,muted:a};-1!=c.a.volume&&(d.delta=b-c.a.volume);c.a.muted=a;c.a.volume=b;YE(c,"setVolume",d);HE(c,"playerChange")}};f.Pm=function(){bF(this.b)};
-f.Qm=function(){if(lF(this)){var a=WE(this.b);kF(this);switch(a.a){case 1:sF(this);this.a.mb(!0);break;case 3:var b=this.a;qF(b);rF(b.g);break;case 0:this.a.mb(!1);this.j.stop();b=this.a.a;(b=N(b.app,b.a||1))&&b.lg(!0);pF(this,this.a.a.getVideoData().ra);break;case 2:this.a.mb(!1);pF(this,iE(a));break;case -1:this.a.mb(!1);break;case -1E3:var b=this.a,c=mf("REMOTE_PLAYER_ERROR");qF(b);tF(b.g,c)}0==this.k&&(b=this.a.a,(b=N(b.app,b.a||1))&&b.lg(!1));this.k=a.a;uF(this);b=Math.round(this.a.a.Em());-1!=
-a.volume&&b!=a.volume&&(this.a.$("onVolumeChange",this.Nh,this),this.a.a.Gm(a.volume),a.muted?this.a.a.Fm():this.a.a.Hm(),this.a.D("onVolumeChange",this.Nh,this))}else this.a.mb(!1)};
-function uF(a){var b=WE(a.b).b;if(!(b||a.g?b&&a.g&&b.trackName==a.g.trackName&&b.languageCode==a.g.languageCode&&b.languageName==a.g.languageName&&b.format==a.g.format&&b.kind==a.g.kind:1))if(a.g=b){var c=a.a.a.tj("captions","tracklist",{qy:1}),c=Pa(c,function(a){return a.languageCode==b.languageCode&&a.name==b.trackName});a.a.a.Sm("captions","track",c)}else a.a.a.Tm("captions")}f.Rm=function(){lF(this)||(pF(this,0),kF(this),this.a.mb(!1))};
-function lF(a){var b=WE(a.b);return!!b&&gE(b)==a.a.a.getVideoData().M}function sF(a){kF(a);ZE(a.b)||(pF(a,iE(WE(a.b))),a.i=H(v(function(){sF(this)},a),500))}function kF(a){I(a.i);a.i=NaN}function pF(a,b){var c=a.a.a.getVideoData().ra;a.a.u("command_progress",b,b/c,void 0)};function vF(){Y.call(this,["div",["html5-bezel","html5-center-overlay"],["div","{{icon}}"]]);this.a=NaN;this.hide()}y(vF,Y);vF.prototype.hide=function(){vF.C.hide.call(this);wF(this)};vF.prototype.setIcon=function(a){bn(this.template,"icon",a)};vF.prototype.show=function(a){wF(this);a&&this.setIcon(a);vF.C.show.call(this)};function wF(a){I(a.a);W(a.element,"html5-bezel-fade")};function xF(a){Y.call(this,["div","ytp-thumbnail"]);this.a=a}y(xF,Y);
-xF.prototype.show=function(a){if(a||this.element.childNodes.length){if(a){$c(this.element);var b=this.element,c=this.a;if(void 0!=Jn("backgroundSize"))d=document.createElement("div"),d.style.backgroundImage="url("+Nn(b,a,c)+")";else{var d=document.createElement("img");d.src=Nn(b,a,c);a=d;b.clientWidth/b.clientHeight<Mn?(a.style.height="100%",a.style.width="auto"):(a.style.height="auto",a.style.width="100%")}V(d,"video-thumbnail");this.element.appendChild(d)}xF.C.show.call(this)}};function yF(a,b,c,d){R.call(this);this.P=d;this.b=this.a=null;this.I=c;this.O=new Rn(mf("REMOTE_PLAYER_RECONNECT_TIME"),["formatted_time"]);this.B=new Rn(mf("REMOTE_CONNECTED_STATUS"),["receiver_name"]);this.G=new Rn(mf("REMOTE_CONNECTING_STATUS"),["receiver_name"]);this.L=new Rn(mf("REMOTE_ERROR_STATUS"),["receiver_name"]);this.j=this.G;this.g=this.A=this.k=this.i=null;this.J="";this.o=null;this.k=E("ytp-remote-display-container",b);this.i=E("html5-remote-display-status-bar",b);zF(this);b=E("html5-remote-display-error",
-b);c=Xc("div");b.appendChild(c);V(c,"html5-remote-display-error-icon");this.A=Xc("div");b.appendChild(this.A);this.g=new un(this.P,"ytp-button-remote-reconnect");this.g.Aa(mf("REMOTE_PLAYER_RECONNECT_BUTTON"));this.g.W(b);this.J=J(this.g,"click",v(this.u,this,"reconnectclicked"));this.o=new xF(a.a.K().nc);this.o.W(this.k);this.o.show(a.a.getVideoData());L(this,this.o);this.a=new vF;this.a.W(this.k);this.a.hide();L(this,this.a);this.b=new Tt;V(this.b.element,"html5-center-overlay");V(this.b.element,
-"html5-center-transform");this.b.W(this.k);this.b.show();L(this,this.b)}y(yF,R);yF.prototype.H=function(){yf(this.J);this.i.innerHTML="";yF.C.H.call(this);this.o=this.i=this.a=null};function AF(a){a.j=a.G;zF(a);BF(a,!1);a.a.hide();a.b.show()}function rF(a){a.j=a.B;zF(a);BF(a,!1);a.a.hide();a.b.show()}function tF(a,b){a.j=a.L;zF(a);a.a.hide();a.b.hide();a.g.hide();a.A.innerHTML=b;BF(a,!0)}function BF(a,b){X(a.k,"ytp-remote-error",b)}
-function CF(a,b){tF(a,Vn(a.O,{formatted_time:Dn(b/1E3)}));a.g.show()}function zF(a){a.i&&(a.i.innerHTML=Vn(a.j,{receiver_name:'<span class="mdx-receiver">'+a.I+"</span>"},void 0,!0))};function DF(a){R.call(this);this.k=this.g="";this.j=null;this.i=a;this.a=this.b=null;EF(this,a)}y(DF,R);DF.prototype.H=function(){yf(this.g);yf(this.k)};function FF(a,b){var c="";z(b,function(a){c+=Vn(this.j,{receiver_key:a.key,receiver_name:a.name})},a);a.a.innerHTML=c;Lp(Ap.getInstance(),a.i)}function GF(a,b){var c=E("active",a.a);if(c){if(G(c,"value")==b)return;Fm(c,["active","selected"])}(c=a.a.querySelector('[data-value="'+b+'"]'))&&Em(c,["active","selected"])}
-function EF(a,b){a.b=Mp(Ap.getInstance(),b);var c=E("html5-remote-receiver-template",a.b);a.j=Un(c,["receiver_key","receiver_name"]);a.a=E("html5-remote-receivers",a.b);a.a.innerHTML="";a.g=Cf(a.b,v(a.o,a),"yt-uix-button-menu-item");a.k=J(b,"click",v(function(){this.u("menushown")},a))}DF.prototype.o=function(a){(a=a.currentTarget)&&"remote-select-receiver"==G(a,"action")&&(a=G(a,"value"),GF(this,a),this.u("selectreceiver",a))};function HF(a){zx.call(this,a);var b=Q(this.a);this.G=a.R.B;this.k={key:pg(),name:mf("REMOTE_LOCAL_SCREEN")};this.g=this.j=null;this.b=IF(this);this.B=NaN;a=this.b;a.o=ig("yt-remote-delayed-connect-key");if(a.o)a.log_("Connecting with the delayed connect data: "+pb(a.o)),a.connect({key:a.o.key}),jg("yt-remote-delayed-connect-key");else{var c=EE(a);c?c.nb==a.j?a.log_("Skipping connecting because current connection exists."):(a.log_("Resuming MDx session: "+Mf(c)),JE(a,c),a.g.connect({},0,Jg()),a.a=
-new eE,SE(a)):(Qg(),a.log_("Skipping connecting because no session screen found."))}this.A=new DF(E("html5-remote-button",b));this.A.D("selectreceiver",this.sj,this);L(this,this.A);this.i=this.k;this.og()}y(HF,zx);var JF=["play_pause","seek"],KF=["captions"];f=HF.prototype;f.qa="remote";f.ad="remote";f.$a=function(){return this.app.I.K().qg};
-f.create=function(){HF.C.create.call(this);var a=this.b=IF(this),b=this.un;FE(a,b,this);a.D("connectionOpened",b,this);a.D("connectionClosed",b,this);a.D("connectionError",b,this);this.b.i.D("onlineReceiverChange",this.og,this);this.b.i.D("connectToReceiver",this.sj,this);this.og();this.i!=this.k&&3<this.a.app.o&&this.load()};function LF(a){a.b&&(FE(a.b,a.un,a),a.b.i.$("onlineReceiverChange",a.og,a),a.b.i.$("connectToReceiver",a.sj,a),a.b.b=null,a.b=null)}
-f.destroy=function(){var a=this.A;Fp(Ap.getInstance(),a.i);LF(this);HF.C.destroy.call(this)};
-f.load=function(){if(!this.ba){HF.C.load.call(this);this.og();var a=E("html5-remote-module",Q(this.a));this.g=new yF(this,a,this.i.name,this.G);this.g.D("reconnectclicked",this.nm,this);this.j=new jF(this,this.b);oF(this.j,this.a.tj("captions","track"));this.a.uj();this.u("command_redirect_controls",this,JF,KF);var b=this.b.o?this.b.o.currentTime:0;0!=b&&H(v(function(){pF(this.j,b)},this),0);WE(this.b)&&!Ua(WE(this.b).wb)&&this.a.rg();this.ba=!0}};
-f.unload=function(){this.ba&&(this.ba=!1,MF(this,this.k),this.mb(!1),Tm(this),this.g.$("reconnectclicked",this.nm,this),qF(this),Ug(this.j,this.g),this.g=this.j=null,HF.C.unload.call(this))};f.H=function(){LF(this);qF(this);Ug(this.j,this.g);this.g=this.j=null;HF.C.H.call(this)};function RE(a){return a.a.vb()?a.a.getVideoData().Ta:""}function PE(a){var b=a.a.vb();if(b){a=[];for(var c=0;c<b.Mb;c++)a[c]=wh(b,c).M;return a}return[a.a.getVideoData().M]}
-function QE(a){var b=RE(a);if(b){b=b.substr(0,2);a=zm(a.a.vb());for(var c=[],d=0;d<a;d++)c[d]=b;b=c}else b=["VI"];return b}function IF(a){var b=iF.getInstance();b.b=a;return b}f.un=function(){qF(this);this.ba&&ZE(this.b)?NF(this):WE(this.b)?this.load():this.unload()};f.nm=function(){var a=this.b;ZE(a)&&(a=a.g.b,a.Tc&&(a.stop(),a.start(),a.k()));AF(this.g)};f.ie=function(a,b){this.j.Pw.apply(this.j,arguments)};
-f.sj=function(a){if(this.i.key!=a)if(this.k.key==a){var b=WE(this.b);a=!!b&&1==b.a&&gE(b)==this.a.getVideoData().M;b=b?iE(b):0;this.i=this.k;this.b.disconnect();this.unload();a&&(this.a.Oh(b),this.a.rg())}else if(a=qg(Rg(),a))MF(this,a),this.b.connect(a),this.load()};function MF(a,b){(a.i||b?a.i&&b&&a.i.key==b.key:1)||(a.i=b,GF(a.A,b.key))}f.og=function(){var a=Rg();this.b&&(this.i=VE(this.b,a)||this.k);a.unshift(this.k);FF(this.A,a);GF(this.A,this.i.key);this.g&&(a=this.g,a.I=this.i.name,zF(a))};
-function NF(a){qF(a);ZE(a.b)?(CF(a.g,cE(a.b.g)),a.B=H(v(function(){NF(this)},a),1E3)):AF(a.g)}function qF(a){I(a.B);a.B=NaN}f.mb=function(a){qF(this);var b=this.g;b.j=b.B;zF(b);BF(b,!1);b.b.hide();b.a.show();b.a.setIcon(a?"html5-bezel-pause":"html5-bezel-play");HF.C.mb.call(this,a)};function OF(){Y.call(this,["div","html5-video-info-panel",["span","html5-video-info-panel-close",{role:"button",title:"close"},"[x]"],["div","html5-video-info-panel-content",["table","html5-video-info-table",["tr","",["th","","Video ID:"],["td","","{{video_id}}"]],["tr","",["th","","Dimensions:"],["td","","{{dimensions}}"]],["tr","",["th","","Resolution:"],["td","","{{resolution}}"]],["tr","",["th","","Volume:"],["td","","{{volume}}"]],["tr","",["th","","Stream Type:"],["td","","{{stream_type}}"]],
-["tr","",["th","","Mime Type:"],["td","","{{mime}}"]],["tr","",["th","","DASH:"],["td","","{{dash}}"]],["tr","",["th","","DRM:"],["td","","{{drm}}"]]],["table",["html5-video-info-table","html5-video-element-info-table"],["tr","",["th","","Decoded Frames"],["th","","Dropped Frames"],["th","","Parsed Frames"],["th","","Presented Frames"]],["tr","",["td","","{{decoded_frames}}"],["td","","{{dropped_frames}}"],["td","","{{parsed_frames}}"],["td","","{{presented_frames}}"]],["tr","",["th","","Video Bytes Decoded"],
-["th","","Audio Bytes Decoded"],["th","","Painted Frames"],["th","","Paint Delay"]],["tr","",["td","","{{video_bytes_decoded}}"],["td","","{{audio_bytes_decoded}}"],["td","","{{painted_frames}}"],["td","","{{paint_delay}}"]]]]]);this.a=this.template.a["html5-video-info-panel-close"]}y(OF,Y);OF.prototype.update=function(a){a.dimensions=a.video_element_width+" x "+a.video_element_height;a.resolution=a.video_width+" x "+a.video_height;a.volume+="%";a.drm=a.drm_flavor+" / "+a.drm_key_system;this.template.update(a)};
-OF.prototype.H=function(){this.a=null;OF.C.H.call(this)};function PF(a){R.call(this);this.app=a;this.g=this.a=this.la=null;this.G=new Db(0,0,0,0);this.b=null;this.da=new Db(0,0,0,0);this.aa=this.V=null;this.Sa=this.Va=0;this.va=this.Q=null;a=a.K();this.Ra=nk()||"blazer"==a.La;this.Ca=0;this.j=null;this.ik()}y(PF,R);var QF=null;f=PF.prototype;f.ik=function(){this.app.D("initializingmode",this.gx,this);this.app.D("videodatachange",this.yl,this)};f.gx=function(){this.da=new Db(0,0,0,0);this.G=new Db(0,0,0,0)};
-f.Gj=function(){var a=Mc(this.la);(a=Dm(a,"html5-video-player")?a:E("html5-video-player",a))||(a=QF||E("html5-video-player"));if(!a)return!1;RF(this,a);this.u("templateready");return!0};function RF(a,b){QF=b.cloneNode(!0);a.a=b;a.a.setAttribute("id",a.app.J.attrs.id);var c=Mc(a.la);c!=a.a&&c.appendChild(a.a);(c=Mc("html5-player-messages"))&&z(c.children,function(a){try{var b=JSON.parse(a.innerHTML);lf(a.id,b)}catch(c){lf(a.id,a.innerHTML)}})}f.addClass=function(a){Em(this.a,arguments)};
-f.removeClass=function(a){Fm(this.a,arguments)};
-f.ij=function(){var a=this.app.K(),b=this.a;this.addClass("el-"+a.Z);this.addClass("ps-"+a.La);X(b,"html5-native-controls",a.Ub);X(b,"html5-mobile",a.nc);a.qe||this.addClass("html5-chromeless");a.tb||this.addClass("tag-pool-enabled");b.style.display="";this.g=E("html5-video-container",b);this.V=E("html5-video-content",b);this.aa=E("html5-video-controls",b);this.j=new OF;this.j.W(b);J(this.j.a,"click",v(this.jk,this));L(this,this.j);this.Ra?this.Q=J(window,"resize",v(this.zi,this)):this.Q=hf(v(this.zi,
-this),250)};f.zi=function(){Ab(SF(this),Gb(this.G))||this.we()};
-f.we=function(){if(this.b){var a=SF(this);if(!a.isEmpty()){var b,c=TF(this),d=SF(this);b=1;var e=UF(this),g,h=!1;e?(g=VF(this,d,c,e,!1),b=g.width/g.height/Bb(c),g=new Db(g.left+g.width/2*(1-1/b),g.top,g.width/b,g.height)):g=new Db(0,0,d.width,d.height);Fb(this.da,g)||(this.da=g,Ad(this.b,Gb(g)),pd(this.b,new A(g.left,g.top)),h=!0);c=VF(this,d,c,e,!0);Fb(this.G,c)||(this.G=c,Ad(this.V,c.width,c.height),pd(this.V,c.left,c.top),h=!0);Kn(this.b,"transform",1==b?"none":"scaleX("+b+")");b=h;if(h=!Ab(a,
-Gb(this.G)))this.G.width=a.width,this.G.height=a.height,this.jl(a);(b||h)&&this.u("resize")}}};f.jl=function(){};f.Kj=function(){};f.yl=function(a,b){this.b.setAttribute("data-youtube-id",b.M);bj&&(b.title?this.b.setAttribute("title",b.title):this.b.removeAttribute("title"));b.pl&&(this.b.poster=b.pl);var c=mm(b,"yt:bgcolor");this.g.style.backgroundColor=c?c:"";this.Va=sl(mm(b,"yt:stretch"));this.Sa=sl(mm(b,"yt:crop"))};f.yj=function(){};f.jp=function(){};f.uo=function(){};
-function SF(a){return a.g?new B(a.g.clientWidth,a.g.clientHeight):new B(0,0)}function TF(a){return a.b?new B(a.b.videoWidth,a.b.videoHeight):new B(0,0)}function VF(a,b,c,d,e){c.isEmpty()?e=b:d?(c=new B(a.Va||Bb(c),1),a=new B(a.Sa||Bb(c),1),Cb(a,c),d=Bb(a)>Bb(b)?b.width/a.width:b.height/a.height,e=e?a.scale(d):c.scale(d)):e=Cb(c.clone(),b);return new Db((b.width-e.width)/2,(b.height-e.height)/2,e.width,e.height)}function UF(a){return!a.app.K().Ub&&!TF(a).isEmpty()}
-function xw(a,b){var c=a.aa;c.insertBefore(b,c.childNodes[0]||null)}f.zj=function(){};function Bh(a){a.j&&(a.j.show(),a.np(),jf(a.Ca),a.Ca=hf(v(a.np,a),500))}
-f.np=function(){var a=N(this.app),b=this.app.getVideoData(),c=this.app.kj(),d=this.b,c={video_id:b.M,video_width:d.videoWidth,video_height:d.videoHeight,video_element_width:d.clientWidth,video_element_height:d.clientHeight,dash:"no",mime:"",drm_flavor:"",drm_key_system:"",volume:Math.round(this.app.wa.volume),stream_type:this.app.K().protocol,decoded_frames:c.hmewdfc||c.hmemdf||"-",dropped_frames:c.hmewdrop||"-",parsed_frames:c.hmempf||"-",presented_frames:c.hmempresented||"-",video_bytes_decoded:c.hmewvdbc||
-"-",audio_bytes_decoded:c.hmewadbc||"-",painted_frames:c.hmempainted||"-",paint_delay:c.hmempaintdelay||"-"};b.a&&(c.dash=b.a.i&&b.a.a?"no":"yes",c.mime=b.a.Jb);if(a=a.I?a.I.g:null)c.drm_flavor=a.b,c.drm_key_system=a.a;this.j.update(c)};f.jk=function(a){a&&a.stopPropagation();this.j&&(jf(this.Ca),this.j.hide())};f.H=function(){this.Q&&(this.Ra?yf(this.Q):jf(this.Q));this.va&&yf(this.va);this.jk();this.j&&Df(this.j.a);F(this.a);this.aa=this.V=this.b=this.g=this.a=this.la=null;PF.C.H.call(this)};function WF(){this.a=[];this.b=[]}ca(WF);var tn=n("yt.player.utils.VideoTagPool.instance_")||WF.getInstance();pa("yt.player.utils.VideoTagPool.instance_",tn);f=WF.prototype;f.hy=function(a){if(!(this.a.length>=a)){a-=this.a.length;for(var b=0;b<a;b++){var c=XF(this);this.a.push(c)}}};
-function XF(a){var b=document.createElement("video");w(b,gj);J(b,"loadeddata",v(b.Nv,b));J(b,"volumechange",v(b.Ov,b));J(b,"timeupdate",v(b.Yo,b));Si&&6<=Xi&&J(b,"webkitbeginfullscreen",v(b.play,b));hj(b);if(a.b.length){var c=a.b[0],d=c.muted;b.volume=100*c.volume/100;b.muted=d}a.b.push(b);J(b,"volumechange",v(a.Pv,a));return b}f.Pv=function(a){a=a.target;var b=a.volume,c=a.muted;z(this.a,function(a){a.volume=b;a.muted=c})};f.oy=function(){return this.a.length?this.a.pop():XF(this)};
-f.my=function(a){a&&Ta(this.b,a)&&(nj(a),Df(a),Xa(this.b,a))};f.jy=function(a){return this.a.length>=(a||1)};WF.prototype.fillPool=WF.prototype.hy;WF.prototype.getTag=WF.prototype.oy;WF.prototype.releaseTag=WF.prototype.my;WF.prototype.hasTags=WF.prototype.jy;function YF(a,b){var c,d;d||(d=0);c||(c=td(document.body));var e=new A(sf(b),tf(b));qp(e,a,d,null,c,5)};function ZF(){this.a=new Ko(this)}y(ZF,K);f=ZF.prototype;f.Oj=null;f.Ce=null;f.Pj=null;f.Ki=null;f.De=null;f.$r=function(){this.hide()};f.as=function(a){a.stopPropagation()};f.hide=function(){In(this.De);op("panelhidden")};f.bs=function(a){27==a.keyCode&&this.hide()};f.Nm=function(){this.Ce.select()};f.show=function(){Hn(this.De)};f.H=function(){this.a.removeAll();this.Ce=this.Oj=this.Pj=this.De=null;ZF.C.H.call(this)};function $F(a){this.X=a;this.X.D("internalvideodatachange",this.In,this);this.g=new Ko(this);this.a=new Ko(this);this.b=new ZF;L(this,this.b)}y($F,K);f=$F.prototype;f.$b=null;function aG(a,b,c){for(var d=Nc(En[b],a.$b),e=0;e<d.length;e++)Lo(a.g,d[e],"down",function(a){c.call(this,a);this.hide(a);a=b.replace("CONTEXT_MENU_","").toLowerCase();bG(this.X,"contextmenu."+a)})}f.In=function(a,b){var c=E("html5-context-menu-copy-embed-html",this.$b);Fn(c,b.no)};f.Om=function(a){a=qh(this.X,a);cG(this,a,"URL")};
-f.ds=function(){var a=df("EMBED_HTML_TEMPLATE"),b=df("EMBED_HTML_URL"),c=Qx(this.X.K()),d=this.X.getVideoData().M,b=b.replace(/__videoid__/g,d),a=a.replace(/__url__/g,ya(b)),a=a.replace(/__width__/g,c.width),a=a.replace(/__height__/g,c.height);cG(this,a,"Text")};function cG(a,b,c){window.clipboardData&&window.clipboardData.setData(c,b)||(a=a.b,Gn(a.De)&&a.hide(),a.Ki&&W(a.De,a.Ki),a.Ki="html5-modal-panel-clipboard-substitute",V(a.De,a.Ki),a.show(),a.Ce.value=b,a.Ce.focus(),H(v(a.Nm,a),100))}
-f.es=function(a){dG(this.X,a.target.getAttribute("href"))};
-f.gs=function(){var a=this.X.getVideoData(),b=this.X.K(),c=Qx(b),d=yw(b),e=lm(a),e=e?ij(e):"",c={cr:b.Q,csipt:a.Kc,ec:108,feature:b.j,h:d.height,hl:b.i,playerh:c.height,playerw:c.width,ptk:a.A,referrer:b.referrer,screenh:window.screen.height,screenw:window.screen.width,sdetail:a.ga,shost:Ij(e),sourceid:a.gd,vid:b.aa,vq:b.Ch,w:d.width};w(c,this.X.kj());(d=N(this.X))&&w(c,Dz(d,!0));c.videoId&&(c.v=c.videoId,delete c.videoId);b.nc&&(c.mobile="1");this.X.of("streamingerror",c);window.open(Sx(a))};
-f.cs=function(){cG(this,rh(this.X,!0),"Text")};f.hs=function(){Bh(this.X.R)};f.ou=function(a){a.preventDefault();Gn(this.$b)?a.stopPropagation():(YF(this.$b,a),Hn(this.$b),this.a.listen(this.$b,"contextmenu",function(a){a.preventDefault()}),a=v(function(){this.a.listen(window,"blur",this.hide);Lo(this.a,document,"down",this.hide)},this),H(a,0),this.a.listen(document,"keydown",this.Av))};f.Av=function(a){27==a.keyCode&&this.hide(a)};f.hide=function(a){In(this.$b);this.a.removeAll();a&&a.stopPropagation()};
-f.H=function(){this.g.removeAll();this.a.removeAll();this.X.$("internalvideodatachange",this.In,this);this.X=null;F(this.$b);this.$b=null;$F.C.H.call(this)};function eG(a,b){yn.call(this,a,b);this.F=null;this.B=this.G=this.i=this.b=0;V(this.element,"ytp-tv-static");fG(this,a,b)}y(eG,yn);function gG(a){for(var b=Math.floor(0.6*a),c=b;c<a;++c){for(var d=!1,e=2;e<Math.sqrt(c);e++){if(!(c%e)){d=!1;break}d=!0}if(d)return c}return b}
-function fG(a,b,c){if(b&&c){a.width=a.element.width=b;a.height=a.element.height=c;var d=document.createElement("canvas");d.width=b;d.height=c;for(var e=d.getContext("2d"),g=e.getImageData(0,0,b,c),h=b*c,k=0;k<h;k++){var m=4*k;g.data[m]=g.data[m+1]=g.data[m+2]=Math.floor(35*Math.random());g.data[m+3]=255}e.putImageData(g,0,0);a.F=d;a.G=gG(b);a.B=gG(c/10);a.S.scale(1.5,1.5)}}eG.prototype.show=function(){eG.C.show.call(this);var a=this.I;this.k=new Date;this.g(a,75)};
-eG.prototype.I=function(){var a=1-1/1.5;this.b=(this.b+this.G)%(this.width*a);this.i=(this.i+this.B)%(this.height*a);this.S.drawImage(this.F,-1*this.b,-1*this.i)};eG.prototype.hide=function(){I(this.a);eG.C.hide.call(this)};function hG(){Y.call(this,["div",["ytp-error","html5-stop-propagation"],["div","ytp-error-content",["div","ytp-error-content-wrap","{{content}}"]]]);this.A="table";this.b=[];if(void 0==jl){var a=document.createElement("canvas");jl=!(!a.getContext||!a.getContext("2d"))}jl&&(this.a=new eG(1,1),this.a.W(this.element,0),L(this,this.a))}y(hG,Y);hG.prototype.show=function(){hG.C.show.call(this);iG(this);this.a&&this.a.show()};hG.prototype.hide=function(){hG.C.hide.call(this);this.a&&this.a.hide()};
-function iG(a){a.a&&fG(a.a,a.element.clientWidth,a.element.clientHeight)}hG.prototype.H=function(){yf(this.b);this.b=[];hG.C.H.call(this)};function jG(){this.b=this.a=null}jG.prototype.getMsg=function(a,b,c){return mf(a,b,c)};function $t(a,b,c,d){a.a&&kG(a.a,b,c,d)};function lG(a,b){var c;var d="followon_"+a;if(b.baseUrl&&b.uid){var e=b.rmktEnabled;c=b.focEnabled&&!b.isAd;if(e||c){d={label:c?d:"default"};if(e){e={utuid:b.uid,type:a};b.vid&&(e.utvid=b.vid);b.eventLabel&&(e.el=b.eventLabel);b.playerStyle&&(e.ps=b.playerStyle);b.feature&&(e.feature=b.feature);b.ppe&&(e.ppe=b.ppe);var g,h=[];for(g in e)h.push(encodeURIComponent(g)+"="+encodeURIComponent(e[g]));g=h.join(";");d.data=g}c&&"view"==a&&b.vid&&b.uid&&(b.oeid||b.ieid)&&(b.oeid&&(d.oeid=b.oeid),b.ieid&&(d.ieid=
-b.ieid),d.evid=b.vid);c&&(d.foc_id=b.uid);c=S(b.baseUrl,d)}else c=null}else c=null;c&&sa(c)}function mG(a){var b=df("CONVERSION_CONFIG_DICT");if(b){if(u(void 0)){var c=24==(void 0).length&&"UC"==(void 0).slice(0,2)?(void 0).substr(2):22==(void 0).length?void 0:null;if(b.uid!=c)return}lG(a,b)}};function nG(a,b,c){c=c||{};Wj("watch_actions_ajax",c.Ea,c.Ua,v(oG,l,a,b,c),c.onError)}
-function oG(a,b,c){var d={};0===b?d.action_like_video=1:1===b?d.action_dislike_video=1:d.action_indifferent_video=1;d.video_id=a;d.plid=c.fb;c.Ta&&(d.list=c.Ta);c.Ea&&(d.authuser=c.Ea);c.Ua&&(d.pageid=c.Ua);a={screen:Hj({h:screen.height,w:screen.width,d:screen.colorDepth}),session_token:ff("watch_actions_ajax")};c.hx&&(a.station_id=c.hx);Qj("/watch_actions_ajax",{format:"XML",method:"POST",rf:d,Gf:a,Pa:c.Pa,onError:c.onError,pd:c.pd});0===b?mG("like"):1===b&&mG("dislike")};function pG(a,b,c,d,e){if(Dm(c,"html5-async-progress"))return null;X(c,"sentiment-like",b);X(c,"sentiment-dislike",!b);if(!a)return null;lu(c,"html5-async-progress");c={fb:a.fb,Pa:function(a){return function(){lu(a,"html5-async-success")}}(c),onError:function(a){return function(){lu(a)}}(c)};d&&(c.authUser=d);e&&(c.pageId=e);nG(a.M,b?0:1,c);df("CONVERSION_CONFIG_DICT")||lG(b?"like":"dislike",a.i);return b?0:1};function qG(a,b,c){Yt.call(this,a,c.K(),b);this.X=c}y(qG,Yt);f=qG.prototype;f.Nj=function(){qG.C.Nj.call(this);this.gb.listen(this.b.b,"click",this.Tu);this.gb.listen(this.b.a,"click",this.Su);this.X.D("presentingplayerstatechange",this.ro,this)};f.update=function(a){qG.C.update.call(this,a);"watch_actions_ajax"in $e&&!this.X.g?(a=this.b,a.b.show(),a.a.show()):(a=this.b,a.b.hide(),a.a.hide())};f.Vh=function(a){var b=Gc(this.a,"show-share");this.u("share-click");b||qG.C.Vh.call(this,a)};
-f.qn=function(a){this.u("title-click",a)};f.bk=function(){var a=Gc(this.a,"show-more-info");this.u("info-click");if(a)this.B&&this.X.Qd();else{qG.C.bk.call(this);var b=Dh(this.X);this.B=P(b,8)&&!P(b,2);this.X.Od()}return!a};f.Tu=function(){rG(this,!0)};f.Su=function(){rG(this,!1)};f.ro=function(a){P(a.state,8)&&W(this.a,"show-more-info")};function rG(a,b){var c=pG(a.ia,b,a.a,a.g.Ea,a.g.Ua);null!=c&&(0==c?a.b.F():a.b.k(),a.X.u("RATE_SENTIMENT",c))}f.Ci=function(a){dG(this.X,a)};
-f.H=function(){this.X.$("presentingplayerstatechange",this.ro,this);this.X=null;qG.C.H.call(this)};function sG(a,b,c,d,e,g,h,k){this.j=[];z(mb(b),function(b){this.j.push(J(a,b,v(this.nr,this)))},this);z(mb(d),function(b){this.j.push(J(a,b,v(this.mr,this)))},this);this.k=g||null;this.B=c;this.A=h||0;this.g=0;this.i=!1;this.F=e;this.o=k||0;this.a=0;this.b=!1}f=sG.prototype;f.nr=function(a){I(this.a);this.a=0;this.g=H(v(this.iv,this,a),this.A)};f.mr=function(a){I(this.g);this.g=0;this.a=H(v(this.hv,this,a),this.o)};f.iv=function(a){this.b||this.i||(this.i=!0,this.B.call(this.k||l,a))};
-f.hv=function(a){!this.b&&this.i&&(this.i=!1,this.F.call(this.k||l,a))};f.dispose=function(){this.b=!0;I(this.g);I(this.a);yf(this.j)};f.ka=function(){return this.b};var tG=null,uG=null;function vG(){Y.call(this,["div","ytp-tooltip",["div","ytp-tooltip-body",["div","ytp-tooltip-content","{{content}}"]],["div","ytp-tooltip-arrow"]]);this.a=this.template.a["ytp-tooltip-body"];this.b=this.template.a["ytp-tooltip-content"]}y(vG,Y);vG.prototype.hide=function(){vG.C.hide.call(this);pd(this.a,0)};function wG(a,b){X(a.b,"ytp-tooltip-content-text",!b.tagName);bn(a.template,"content",b)}vG.prototype.H=function(){$c(this.b);this.b=this.a=null;vG.C.H.call(this)};function xG(a,b){this.a={};this.il=a;this.Ro=b}y(xG,K);
-function vn(a,b,c){var d,e=new sG(b,"mouseover",function(){if(this.il){var a=new vG;a.W(this.il);d=a}else d=null;if(d&&(a=c&&c(b),!c||a)){a?wG(d,a):(a=G(b,"tooltip")||"",wG(d,Yc(a)));var e=!!G(b,"tooltip-below"),a=d,k=Cd(b),k=new A(k.width/2,e?k.height:0),m=ud(b),k=new A(m.x+k.x,m.y+k.y),e=!!e;X(a.element,"ytp-tooltip-below",e);if(m=sd(a.element))var p=ud(m),r=Jd(m),k=yb(k,new A(p.x+r.left,p.y+r.top));qp(k,a.element,e?1:0);a.show();var r=Cd(a.a),e=-1*(r.width/2),s=Rc(window),D=Sc(document),k=D.x,
-s=s.width+D.x,D=k,O=s;m&&(m=Cd(m),D=p.x,O=m.width+p.x);m=ud(a.a);p=m.x+e;m=m.x+r.width+e;p<Math.max(k,D)?e-=p-Math.max(k,D):m>Math.min(s,O)&&(e-=m-Math.min(s,O));pd(a.a,e)}},["mouseout","mousedown"],function(){d&&(d.hide(),Tg(d),d=null)},a,10,50);a.a[ja(b)]=e}
-function kG(a,b,c,d){vn(a,b,function(){var a=this.Ro,b;if(a&&a.Dl){b=a.Dl;var h=a.rp;tG||(tG=new Rn(mf("YTP_TOOLTIP_IDENTITY")),uG=new Rn(mf("YTP_TOOLTIP_IDENTITY_WATCH_LATER")));a=Xc("div");V(a,"ytp-identity-tooltip");var k=Xc("img");k.src=h;var h=Xc("span"),m=null;d?(V(h,"ytp-idt-watch-later"),m=[Yc(Vn(uG,{user_name:""})),Xc("br"),Yc(b)]):m=Yc(Vn(tG,{user_name:b}));Zc(h,m);Zc(a,k,h);b=a}else b=c;return b})}
-xG.prototype.H=function(){this.Ro=this.il=null;for(var a in this.a)Tg(this.a[a]);this.a={};xG.C.H.call(this)};function yG(a,b){this.k=a;this.i=[];this.o=b;this.j=[]}y(yG,K);function zG(a,b,c){a.i.push(a.k.D(b,c,a))}function AG(a,b,c){a.j.push(a.o.D(b,c,a))}function BG(a){for(var b=0;b<a.i.length;b++)a.k.Rc(a.i[b]);for(b=0;b<a.j.length;b++)a.o.Rc(a.j[b])}yG.prototype.H=function(){BG(this);yG.C.H.call(this)};function CG(a,b){yG.call(this,a,b);this.g=!1;this.b=a;this.a=b;var c=a.K();c.color&&V(this.a.i,c.color);if(c.Eg){var d=this.a,e=E("html5-progress-tooltip",d.g);d.b=new Lu;var g=d.b;g.Fb=e;g.Dh=E("html5-progress-tooltip-arrow",g.Fb);g.Wj=E("html5-progress-tooltip-thumbnail",g.Fb);g.lj=E("html5-progress-tooltip-timestamp",g.Fb);L(d,d.b);d=this.a;d.a=new Hu;d.a.W(d.g);Lo(d.k,d.a.N(),"down",d.Zs);d.a.hide();L(d,d.a)}c.Fg&&(c=this.a,d=E("html5-storyboard",c.g),c.o=new Du,e=c.o,g=c.kb.b.a?new B(c.kb.b.a.clientWidth,
-c.kb.b.a.clientHeight):new B(0,0),e.ud=d,e.$d=g.width,e.cc=E("html5-storyboard-filmstrip",e.ud),e.Ph=E("html5-storyboard-lens",e.ud),e.Sj=E("html5-storyboard-lens-thumbnail",e.ud),e.Uj=E("html5-storyboard-lens-timestamp",e.ud),e.wg=E("html5-storyboard-thumbnail",e.cc),F(e.wg),L(c,c.o));DG(this)}y(CG,yG);
-function DG(a){BG(a);a.g=!0;zG(a,"cuerangesadded",a.qw);zG(a,"cuerangesremoved",a.rw);zG(a,"cuerangemarkersupdated",a.ow);zG(a,"presentingplayerstatechange",a.yw);zG(a,"progresssync",a.zw);zG(a,"resize",a.uw);zG(a,"seekto",a.ww);zG(a,"videodatachange",a.Aw);zG(a,"videoplayerchange",a.ip);zG(a,"videoready",a.xw);AG(a,"beginseeking",a.mw);AG(a,"endseeking",a.tw);AG(a,"seekto",a.lw)}f=CG.prototype;f.qw=function(a){var b=N(this.b).getVideoData();!b||0>=b.ra||EG(this,a,b)};
-function EG(a,b,c){var d=c.ra;z(b,function(a){a.Pc&&Yu(this.a,a.start/(1E3*d))},a)}f.rw=function(a){var b=N(this.b).getVideoData();if(b&&!(0>=b.ra)){var c=b.ra;z(a,function(a){a.Pc&&Zu(this.a,a.start/(1E3*c))},this)}};f.ow=function(a){var b=N(this.b).getVideoData();!b||0>=b.ra||z(a,function(a){var d=a.start/(1E3*b.ra);a.Pc?Yu(this.a,d):Zu(this.a,d)},this)};f.uw=function(a){if(this.a.o){var b=this.a.o;!b.Uc||b.$d==a.width&&b.b||(b.$d=a.width,Fu(b,!0))}};
-f.ww=function(a){Wu(this.a,a);if(this.a.o){var b=this.a.o;if(b.Uc){b.wk=b.Xk*a-b.$d/2;pd(b.cc,-1*b.wk);var c=$k(b.Uc,a);Eu(b,c);dd(b.Uj,Dn(b.Oe*a));Op(b.a)}}};f.yw=function(a){if(0>Ho(a,16)){a=this.a;var b=this.b.getCurrentTime();a.jb.innerHTML=Math.floor(100*a.xa)+"% at "+Math.floor(b)+" of "+Math.floor(a.B)+" seconds"}};f.ip=function(a){1!=a.B?this.g&&(BG(this),this.g=!1,zG(this,"videoplayerchange",this.ip)):this.g||DG(this)};
-f.Aw=function(a,b,c){"newdata"==a&&(Wu(this.a,(b.ya||0)/b.ra,0),a=this.a,$c(a.va),a.J={},(c=N(this.b,c))&&EG(this,c.A.i||[],b),this.a.b&&this.a.b.reset());this.a.Xa(b.ra);this.a.b&&this.a.b.Xa(b.ra);this.a.o&&this.a.o.Xa(b.ra);c=this.a;c.ja=b.Cj;Xu(c);c=this.a;c.aa=b.Am;Xu(c)};
-f.xw=function(a){if(this.a.b){var b=this.a.b;if(!b.bi)if(nm(a)){V(b.Fb,"with-thumbnail");b.Gg=nm(a);b.bh=om(a);var c=v(b.Nu,b);b.bh.D("l",c)}else b.reset()}if(this.a.o&&(b=this.a.o,b.wg&&$c(b.cc),W(b.ud,"enabled"),b.Uc=nm(a),b.Le=om(a),b.Uc&&!b.to)){V(b.ud,"enabled");a=v(b.qo,b);b.Le.D("l",a);Fu(b);a=b.cc.cloneNode(!0);for(var c=b.Uc.a[0].b,d,e,g=0;g<c;g++)e=b.wg.cloneNode(!1),d=yl(b.Le,g,b.Nb),Cu(e,d,b.Nb,b.Ai),a.appendChild(e);c=b.cc;(d=c.parentNode)&&d.replaceChild(a,c);b.cc=a}};
-f.zw=function(a,b,c){Wu(this.a,b,c)};f.mw=function(){Az(this.b.b)};f.tw=function(){this.b.b.Sh()};f.lw=function(a,b){Xg(this.b,a,b)};function FG(a,b){yG.call(this,a,b);zG(this,"applicationplayerstatechange",this.Fq);zG(this,"controlsdisabled",this.Hq);zG(this,"controlsenabled",this.Iq);zG(this,"liveviewshift",this.Lq);zG(this,"fullscreentoggled",this.Kq);zG(this,"presentingplayerstatechange",this.jr);zG(this,"progresssync",this.kr);zG(this,"threedenabled",this.Yq);zG(this,"videodatachange",this.lr);zG(this,"onPlaybackQualityChange",this.Uq);zG(this,"onVolumeChange",this.Zq);zG(this,"menu_button_add",this.Mq);zG(this,"menu_button_remove",
-this.Nq);zG(this,"menu_item_add",this.Oq);zG(this,"menu_item_remove",this.Pq);AG(this,"fullscreentoggled",this.Jq);AG(this,"mutetoggled",this.Qq);AG(this,"nextvideo",this.Rq);AG(this,"playpausetoggled",this.Sq);AG(this,"previousvideo",this.Tq);AG(this,"qualitychanged",this.Vq);AG(this,"sizechangerequested",this.Wq);AG(this,"speedchanged",this.Xq);AG(this,"volumechanged",this.ar);AG(this,"watchlater",this.ir);AG(this,"watchonyoutube",this.br);AG(this,"controlclick",this.Gq);this.a=a;this.b=b;this.g=
-new CG(a,b.oj);L(this,this.g);var c=a.K();if(c.Ma){var d=this.b;d.B=new kv(d.j);L(d,d.B);Dv(d,"__default__",d.B,d.nd);F(d.se);F(d.Pd);F(d.nd);bd(d.ub).appendChild(d.ub);d.b=new ev(d.j);L(d,d.b);d.b.listen("change",d.er,d);d.g=new lv(d.j);L(d,d.g);d.g.listen("change",d.gr,d);d.i=new mv(d.j);L(d,d.i);d.i.listen("change",d.hr,d)}if(c.oc){var d=this.b,e=this.a.K().Nd;d.g?(d.g.Za(e?1:0),wv(d,d.g)):(Hn(d.se),Hn(d.Pd))}c.sh&&this.b.o.show();c.gg&&(d=this.b,e=this.a.a.gg?eh:[1],d.i?(nv(d.i,e),wv(d,d.i)):
-Hn(d.lf));if(c.Ka)for(c=this.b,d=[c.wc,c.sc,c.kf,c.k,c.nd,c.ub,c.ig,c.o,c.se,c.Pd,c.B],e=0;e<d.length;e++)c.a.listen(d[e],"click",c.dr)}y(FG,yG);f=FG.prototype;f.Hq=function(a){this.b.disable(a)};f.Iq=function(a){this.b.enable(a)};f.Lq=function(a){X(this.b.k.element,"ytp-time-live-dvr",!a)};f.Kq=function(a){var b=this.b,c=this.a.K().Nd;if(a){var d=b.o;wn(d,"ytp-button-fullscreen-exit");var e=d.g.getMsg("YTP_BUTTON_FULLSCREEN_EXIT");d.Hb(e);d.a=e}else wu(b.o);b.g&&b.g.Za(a?-1:c?1:0)};
-f.jr=function(a){P(a.state,2)||(0<Ho(a,8)?Av(this.b,!0):0>Ho(a,8)?Av(this.b,!1):0>Ho(a,2)&&Av(this.b,P(a.state,8)));0>Ho(a,16)&&GG(this,this.a.getCurrentTime())};f.Fq=function(a){if(P(a.state,2)){a=this.b.wc;wn(a,"ytp-button-replay");var b=a.g.getMsg("YTP_BUTTON_REPLAY");a.Hb(b);a.a=b}};f.Yq=function(){var a=this.b,b=this.a.getVideoData().zf,c=E("html5-threed-conversion-on",a.Ah),a=E("html5-threed-conversion-off",a.Ah);Fn(c,!b);Fn(a,b)};
-f.lr=function(a,b){if(1==N(this.a).B){"newdata"==a&&(GG(this,b.ya||0),lu(this.b.ub),Cv(this.b,"1.0"));this.b.Xa(b.ra);vv(this.b,jm(b));var c=this.b,d=b.Cb,e=b.eb;c.tn=d&&!e;c=c.k;X(c.element,"ytp-time-liveonly",d&&!e);X(c.element,"ytp-time-live",d&&e);this.a.g&&"detailpage"!=this.a.K().Z?this.b.Ee.show():this.b.Ee.hide()}};f.Uq=function(a){1==N(this.a).B&&yv(this.b,a,HG(this.a))};
-f.Zq=function(a){var b=this.b,c=a.volume;a=a.muted;Pe(b.sc,"value",a||0==c?"off":20>c?"min":40>c?"quiet":60>c?"normal":80>c?"loud":"max");Pe(b.sc,"volume",c);var d=b.Wb.clientWidth-6,e=b.Wb.style.backgroundPosition.split(" "),e=1<e.length?e[1]:"0px";if(a)b.Wb.style.backgroundPosition="-"+d+"px "+e,b.jg.style.left="0px";else{var g;0>=c?g=0:100<=c?g=d:(g=(d-0)*c/100,g=0>=g?0:g>=d?d:0+Math.round(g));b.jg.style.left=g+"px";b.Wb.style.backgroundPosition="-"+(d-g)+"px "+e}c=Math.round(c);d=c+"% "+mf("HTML5_VOLUME_SETTING")+
-(a?" "+mf("HTML5_VOLUME_MUTED"):"");b.kf.setAttribute("aria-valuenow",c);b.kf.setAttribute("aria-valuetext",d);c=b.sc;d=G(c,a?"tooltip-alt":"tooltip-default")||"";Pe(c,"tooltip",d);c.setAttribute("aria-label",d);b.sc.setAttribute("aria-label",(a?mf("HTML5_VOLUME_UNMUTE"):mf("HTML5_VOLUME_MUTE"))+" "+mf("HTML5_CONTROL_TOGGLE"))};f.Oq=function(a){wv(this.b,a)};f.Pq=function(a){xv(this.b,a)};f.Mq=function(a,b){Dv(this.b,a,b)};
-f.Nq=function(a){var b=this.b,c=b.A[a];c&&(c.ve(),fn(c,"menuButtonClick"),b.A[a]=null,b.G[a].dispose(),b.G[a]=null)};f.kr=function(a){GG(this,a)};f.Jq=function(){IG(this.a,!this.a.K().pb)};f.Qq=function(){this.a.wa.muted?Zg(this.a):Yg(this.a)};f.Rq=function(){th(this.a)};f.Sq=function(){JG(this.a)};f.Tq=function(){uh(this.a)};f.Vq=function(a){"auto"==a&&yv(this.b,fh(this.a),a);"auto"==HG(this.a)&&yv(this.b,a,a);var b=N(this.a,1);b&&gh(b,"m",a)};
-f.Wq=function(a){var b=this.a;IG(b,!1);a!=b.a.Nd&&(b.a.Nd=a,b.u("SIZE_CLICKED",a),b.R.zi())};f.Xq=function(a){dh(this.a,a)};f.ar=function(a){KG(this.a,a)};f.br=function(){dG(this.a,qh(this.a,!0))};f.Gq=function(a){bG(this.a,a)};f.ir=function(){Wj("addto_ajax",this.a.K().Ea,this.a.K().Ua,v(this.uv,this),v(this.No,this))};
-f.uv=function(){var a={ov:"WL",wb:this.a.getVideoData(1).M,Ea:this.a.K().Ea,Ua:this.a.K().Ua,Pa:this.pv,onError:this.No,S:this},b={video_ids:a.wb,full_list_id:a.ry||"",new_playlist_name:a.qv||"",session_token:ff("addto_ajax")},c=df("PLAYBACK_ID");c&&(b.plid=c);c={};a.privacy&&(c.privacy=a.privacy);a.nv&&(c.feature=a.nv);a.Ea&&(c.authuser=a.Ea);a.Ua&&(c.pageid=a.Ua);var d="";switch(a.ov){case "PL":d=a.qv?"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;Qj("/addto_ajax",{mv:!0,format:"XML",method:"POST",rf:c,Gf:b,S:a.S,onError:a.onError,Pa:a.Pa})};f.pv=function(){lu(this.b.ub,"html5-async-success");this.a.u("WATCH_LATER")};f.No=function(a,b){var c=this.b.ub,d=b&&b.error_message;lu(c,"html5-async-error");if(d){var e=Et.getInstance(),g=Gt(c);It(c,d);Ft(e,c);zp(c,g)}};function GG(a,b){1==N(a.a).B&&bn(a.b.k.template,"current",Dn(b))};var LG={0:"autohide-off",1:"autohide-on",2:"autohide-fade",3:"autohide-auto",4:"autohide-embeds",5:"autohide-seekbar"};function MG(a){PF.call(this,a);this.P=this.o=this.O=this.Ka=this.A=this.ga=this.ha=this.Y=this.J=this.I=this.k=this.i=null;this.xa=!1;this.pa=this.B=null;this.Ma=!0;this.za=this.L=!1;a=this.app.K().Db?4E3:3E3;this.ja=new Oo(this.Zj,a,this);L(this,this.ja);this.ja.start()}y(MG,PF);f=MG.prototype;
-f.ik=function(){MG.C.ik.call(this);this.app.D("appstatechange",this.Rw,this);this.app.D("applicationplayerstatechange",this.Sw,this);this.app.D("clearvideooverlays",this.Ww,this);this.app.D("initializingmode",this.Uw,this);this.app.D("presentingplayerstatechange",this.Tw,this);this.app.D("onDetailedError",this.Vw,this)};
-f.Gj=function(){var a=this.app.J.assets;if(a.css&&!ml()){var b={rel:"stylesheet",type:"text/css",href:a.css},c=document.getElementById("www-player-css");b.id="www-player-css";var d=c||document.createElement("link");Pc(d,b);c||document.getElementsByTagName("head")[0].appendChild(d);this.Qo(200)}else this.xa=!0;MG.C.Gj.call(this)||Qj(a.html,{format:"RAW",method:"GET",Pa:v(this.Xw,this)});return!0};
-f.Xw=function(a){if(a.responseText){var b=Xc("div");b.innerHTML=a.responseText;RF(this,E("html5-video-player",b));this.u("templateready")}else this.u("templateerror")};f.Qo=function(a){0>=a||ml()?(this.xa=!0,this.a&&cn(this.a)):H(v(this.Qo,this,a-1),50)};
-f.ij=function(){MG.C.ij.call(this);this.xa||dn(this.a);NG(this);var a=this.app.K();a.V&&this.addClass(a.V+"-theme");a.hf&&this.addClass("house-brand");!a.jf&&a.qe||this.addClass("modest-branding");a.hj&&this.addClass("html5-hide-share");a.am||this.addClass("html5-hide-volume");a.Db&&(this.addClass("html5-tablet"),V(document.body,"html5-tablet-body"));a.Vb||this.addClass("hide-info-bar");a.Db||a.Ub||this.addClass(LG[a.yh]);var b=Bb(new B(this.a.clientWidth,this.a.clientHeight)).toFixed(1);"1.3"!=b&&
-"1.8"!=b||this.addClass("autohide-aspect");a.oc&&this.we();this.I=E("html5-watermark",this.a);OG(this.app)&&Hn(this.I);a.qe&&!a.Ub&&(this.A=new sv(this.B),tv(this.A,this.aa),L(this,this.A),this.Ka=new FG(this.app,this.A),L(this,this.Ka));var b=E("html5-context-menu",this.a),c=E("html5-modal-panel",this.a),d=this.O=new $F(this.app);d.$b=b;F(d.$b);document.body.appendChild(d.$b);var e=d.b;e.De=c;e.Pj=E("html5-modal-panel-close-button",c);e.Oj=E("html5-modal-panel-clipboard-substitute-content",c);e.Ce=
-Ve("input",e.Oj);hc&&e.Ce.removeAttribute("readonly");e.a.listen(document,"keydown",e.bs);e.a.listen(c,"contextmenu",e.as);Lo(e.a,e.Pj,"down",e.$r);Lo(e.a,e.Ce,"down",e.Nm);var c={Tr:d.cs,Ur:d.ds,Vr:v(d.Om,d,!1),Wr:v(d.Om,d,!0),Yr:d.gs,Zr:d.hs,Xr:d.es},g;for(g in c)aG(d,g,c[g]);L(this,this.O);a.hf&&V(b,"house-brand");this.k=new Tt(2);V(this.k.element,"html5-video-loader");V(this.k.element,"html5-center-overlay");V(this.k.element,"ytp-scalable-icon-grow");this.k.W(this.g);L(this,this.k);g=E("html5-info-bar",
-this.a);this.o=new qG(g,this.B,this.app);this.o.Nj();L(this,this.o);this.J=new xF(a.nc);this.J.W(this.g);L(this,this.J);this.Y=new vF;this.Y.W(this.g);L(this,this.Y);PG(this)};f.jl=function(a){MG.C.jl.call(this,a);QG(this,a);this.i&&iG(this.i)};f.Kj=function(){MG.C.Kj.call(this);QG(this,SF(this))};f.yl=function(a,b){MG.C.yl.call(this,a,b);"newdata"==a&&this.o.reset();this.o&&this.o.update(b);if(OG(this.app)){var c=b.Ma;c&&(this.I.src=c);Hn(this.I)}};
-f.Rw=function(a){2==a?RG(this):(this.J.hide(),this.removeClass("cued-mode"));3==a?this.k.show():P(Dh(this.app),1)||this.k.hide()};
-f.Tw=function(a){var b;b=a.state;if(P(b,2))b=["ended-mode"];else{var c=[];P(b,8)?c.push("playing-mode"):P(b,4)&&c.push("paused-mode");P(b,1)&&!P(b,32)&&c.push("buffering-mode");P(b,32)&&c.push("seeking-mode");P(b,64)&&c.push("unstarted-mode");b=c}this.pa&&Fm(this.a,this.pa);Em(this.a,b);this.pa=b;P(a.state,1)?this.k.show():0>Ho(a,1)&&this.k.hide();this.Ma=P(a.state,8)&&!P(a.state,4);0>Ho(a,64)&&SG(this.app)};f.Sw=function(a){P(a.state,2)?RG(this):0>Ho(a,2)&&(this.J.hide(),this.removeClass("cued-mode"))};
-function PG(a){var b=a.app.K();if(b.lm){if(b.Db){var c=v(function(a){return TG(a)||Dm(a.target,"html5-draggable")},a);a.P=new mu(a.a,v(function(a){Dm(this.a,"cued-mode")?tn.hasTags(void 0)&&this.Xn(a):TG(a)&&(this.L?this.Lk():this.Zj(),this.A&&(a=Ap.getInstance(),a.Bf&&Fp(a,a.Bf)))},a),!1,c);J(a.a,"gesturechange",v(a.ru,a));J(a.a,"gestureend",v(a.su,a))}else J(a.a,"click",v(a.Xn,a)),J(a.a,"dblclick",v(a.qu,a)),J(a.a,"click",v(a.Lk,a)),J(a.a,"mousemove",v(a.Lk,a)),J(a.a,"mouseout",v(a.Zj,a));var d=
-v(function(){var a=this.b;a&&(hj(a),tn.fillPool(4),b.Db&&qu(),(a=wf(this.a,"click",d,!0))&&yf(a))},a);J(a.a,"click",d,!0);J(a.a,"keypress",v(a.uu,a));J(a.a,"keydown",v(a.pu,a));c=v(a.O.ou,a.O);bj&&a.P?a.P.o=c:J(a.a,"contextmenu",c);J(a.I,"click",v(a.Yn,a));a.o.D("title-click",v(a.Yn,a));a.o.D("share-click",v(a.vu,a));a.o.D("info-click",v(a.tu,a))}}f.Xn=function(a){var b=this.app.K();TG(a)&&(this.a.focus(),!Dm(this.a,"cued-mode")&&b.Ub||JG(this.app,!0));bG(this.app,"screenclick")};
-f.qu=function(a){6!=this.app.o&&(TG(a)&&(a=this.app,IG(a,!a.a.pb)),bG(this.app,"screendoubleclick"))};f.ru=function(a){var b=a.scale,c=this.app.K().pb;b*(c?-1:1)>(c?-0.7:1.3)&&(b=this.app,IG(b,!b.a.pb));a.preventDefault()};f.su=function(a){a=a.scale;var b=this.app.K().pb;a*(b?-1:1)>(b?-0.9:1.1)&&(a=this.app,IG(a,!a.a.pb))};function TG(a){return!jd(a.target,"html5-stop-propagation")}
-f.uu=function(a){var b=a.keyCode;if(179==b||178==b)179==b&&(this.u("playpausetoggled",!0),a.preventDefault()),178==b&&(ah(this.app),a.preventDefault());98==b&&this.app.af("onBackgroundChange");111==b&&this.app.af("onTextOpacityChange");119==b&&this.app.af("onWindowOpacityChange");61!=b&&43!=b||this.app.af("onFontSizeIncrease");45!=b&&95!=b||this.app.af("onFontSizeDecrease");32==b&&TG(a)&&(JG(this.app,!0),a.preventDefault());48<=b&&57>=b&&(Xg(this.app,(b-48)/10*Lh(this.app)),a.preventDefault())};
-f.pu=function(a){var b=a.keyCode;if(38==b||40==b||37==b||39==b){var c=5;a.ctrlKey&&(c*=2);if(38==b)c=this.app,KG(c,{volume:c.wa.volume+5,muted:!1});else if(40==b)c=this.app,KG(c,{volume:c.wa.volume-5,muted:!1});else if(37==b){var d=this.app,c=-1*c;Xg(d,d.getCurrentTime()+c,!1,250,void 0)}else 39==b&&(d=this.app,Xg(d,d.getCurrentTime()+c,!1,250,void 0));a.preventDefault()}36==b&&(Xg(this.app,0),a.preventDefault());35==b&&(Xg(this.app,Infinity),a.preventDefault());27==b&&(IG(this.app,!1),a.preventDefault())};
-f.Yn=function(a){a.preventDefault();a=this.app;var b;b=a.getVideoData();b=b.Lc||Zt(a.a,b);dG(a,b)};f.vu=function(){this.app.Eh();IG(this.app,!1);var a=this.app,b=a.getVideoData();a.u("SHARE_CLICKED",{videoId:b.M,listId:b.Ta,feature:"player_"+a.a.Z})};f.tu=function(){this.app.Eh()};f.Ww=function(){var a=this.o;W(a.a,"show-share");W(a.a,"show-more-info")};f.Lk=function(){this.za=!0;this.ja.start();this.L&&(this.L=!1,this.removeClass("hide-controls"),this.app.Wa("onShowControls"))};
-f.Zj=function(){this.za=!0;this.ja.stop();if(!this.L){var a;if(a=this.A){a=this.A;var b=Ap.getInstance();a=!!b.Bf&&Ue(b.Bf,a.mf)||null!=a.I}b=(b=jh(this.app.k,"playlist"))&&b.ba;this.Ma&&this.za&&!a&&!b&&(this.L=!0,this.addClass("hide-controls"),this.app.Wa("onHideControls"))}};function RG(a){a.J.show(a.app.getVideoData());a.addClass("cued-mode")}f.yj=function(){var a=Nc("html5-popup-dialog",this.a);z(a,function(a){In(a)},this)};
-f.Vw=function(a){this.i||(this.i=new hG,this.i.W(this.a),L(this,this.i));var b=this.app.K(),c=a.message;a=a.messageKey;if(!b.hf&&"HTML5_DEFAULT_FALLBACK"==a){c+=mf("LEARN_MORE");a=this.i;for(var d=v(this.app.of,this.app,"",{errorHelpClick:1}),e=a.element.getElementsByTagName("a"),g=0;g<e.length;g++)a.b.push(J(e[g],"click",d));this.app.of("",{errorHelpShown:1})}a=this.i;b="embedded"==b.Z;yf(a.b);a.b=[];bn(a.template,"content",new dv(c));if(b)for(b=a.element.getElementsByTagName("a"),c=0;c<b.length;c++)b[c].setAttribute("target",
-"_blank");this.i.show()};f.Uw=function(){this.i&&this.i.hide()};f.jp=function(a){var b=this.Y;b.show(a);H(oa(V,b.element,"html5-bezel-fade"),0);b.a=H(v(b.hide,b),300)};f.uo=function(a){E("html5-viewport-sheet").disabled=!a};f.we=function(){var a=this.app.K();Pe(document.body,"player-size",a.pb?"fullscreen":a.Nd?"large":"small");MG.C.we.call(this)};
-function UG(a,b){var c="scale("+a+") !important;";b&&(c="translate(-50%, -50%) "+c);return["transform: "+c,"-webkit-transform: "+c,"-moz-transform: "+c,"-o-transform: "+c,"-ms-transform: "+c]}function QG(a,b){if(!b.isEmpty()){var c=b.width,d=b.height,e=0,g=0;c/d>480/360?(e=d,g=360):(e=c,g=480);c=wb(e/g,0.5,1);d={Ib:a.ha,reset:!0};a.ha=kn(".ytp-scalable-icon-shrink",UG(c,!1),d);c=wb(0.33*(e/g),0.5,1);d={Ib:a.ga,reset:!0};a.ga=kn(".ytp-scalable-icon-grow",UG(c,!0),d)}}
-f.zj=function(a){this.A&&Av(this.A,a)};function NG(a){a.B=new jG;a.B.b=a;var b=new xG(a.a,a.app.K());L(a,b);a.B.a=b;a=Nc("ytp-tooltip-anchor",a.a);z(a,function(a){vn(b,a)})}f.H=function(){this.k.hide();ln(this.ha);ln(this.ga);Df(this.a);Df(this.I);Tg(this.P);MG.C.H.call(this);this.I=this.J=this.ga=this.ha=this.P=this.Y=null};function oh(a,b,c,d){"string"==typeof a&&(a={mediaContentUrl:a});var e=a,g=/\/([ve]|embed)\/([^#?]+)/.exec(a.mediaContentUrl);e.video_id=g&&g[2]?g[2]:null;return lh(a,b,c,d)}function lh(a,b,c,d){b={endSeconds:void 0,list:b,mediaContentUrl:void 0,startSeconds:c,suggestedQuality:d,videoId:a};if(ia(a)){for(var e in b)b[e]=b[e]||a[e];b.videoId=a.video_id||a.videoId}return b};function VG(a,b,c){this.g=a;this.a=b;this.I=c||null;this.i={};this.F=NaN;this.j=new Oo(this.tq,3E4,this);L(this,this.j);this.k=new Oo(this.mj,1E3,this);L(this,this.k);this.G=0;this.b="N";this.o=NaN;this.A=""}y(VG,K);var WG={5:"N","-1":"N",3:"B",0:"EN",2:"PA",1:"PL"};function zz(a,b,c){var d=a.i[b];d||(d=[],a.i[b]=d);d.push(((x()-a.G)/1E3).toFixed(3)+":"+c.join(":"))}f=VG.prototype;
-f.mj=function(){if(this.I){var a=this.I();if(!isNaN(this.B)&&!isNaN(a.g)){var b=a.g-this.B;0<b&&zz(this,"bwm",[b,(a.j-this.L).toFixed(3)])}this.B=a.g;this.L=a.j;isNaN(a.a)||zz(this,"bwe",[a.a.toFixed(3)]);isNaN(a.b)||(b=a.b,a.i<b&&(b=a.i),this.J!=b&&(zz(this,"bh",[b.toFixed(3)]),this.J=b),this.a.Ca&&3>b&&("PL"==this.b||"B"==this.b)&&this.k.start())}};
-f.ng=function(){if(!this.ka()&&!Nb(this.i)){0!=this.k.Ba||this.mj();var a=Tx(this.a).hmewdrop;0<=a&&a!=this.o&&zz(this,"df",[a-(this.o||0)]);this.o=a;a={event:"streamingstats"};this.g.a&&(a.fmt=this.g.a.Oa);a.cpn=this.g.Da;a.ei=this.g.k;a.el=this.a.Z;a.docid=this.g.M;a.ns=this.a.qc;this.a.g&&(a.adformat=this.a.g);this.g.Cb&&(a.live=this.g.eb?"dvr":"live");Rb(a,Ox(this.a));a.html5="1";var a=S(Nx(this.a)+"stream_204",a),b;for(b in this.i)a+="&"+b+"="+this.i[b].join(",");sa(a);this.i={};this.j.start()}};
-f.onError=function(a){zz(this,"error",[a,this.g.pe.toFixed(3)])};f.tq=function(){"PL"==this.b&&(zz(this,"vps",[this.b]),this.ng())};f.H=function(){VG.C.H.call(this);jf(this.F)};function XG(a,b,c,d){c=c||"";this.i=[];this.j=[];this.B=[];this.F="watchtime"==c;this.jd=Nx(b)+"api/stats/"+c;d&&(this.Rl=d.fs,this.O=d.nbe,this.P=d.bc,this.Q=d.bd,this.lc=d.bt,d.rtn&&(this.cg=d.rtn),this.F?(this.ha=d.state,0<d.rti&&(this.qh=d.rti)):(this.da=d.mos,this.la=d.volume,d.at&&(this.I=d.at),d.allowed&&(this.L=d.allowed),d.ex_ads&&(this.aa=d.ex_ads)));this.G=b.g;this.rh=b.Tb;this.V=b.k;this.Ca=b.F;this.Ma=b.A;this.Ka=b.B;this.Sa=b.Wf;this.Mc=b.ef;this.Ra=b.G;this.Va=b.I;this.jb=b.J;this.kb=
-b.L;this.mc=b.O;this.b=b.b;this.Ic=b.Z;this.B=b.o;this.ja=b.ja;this.Kc=b.i;this.Tl=b.qc;this.kd=b.La;this.referrer=b.referrer;this.hd=b.Q;this.o=b.j;this.ld=b.ha;this.pa=b.la;this.va=b.pa;this.gd=Ux(b);!a.a||a.V.isEmpty();this.rh=a.df||this.rh;this.xa=a.Da;this.A=a.pe;this.Y=a.J;this.za=a.Ka;this.a=a.a;this.Sl=a.Ld;this.Jc=a.Vf;a.Cb&&(this.ga=a.eb?"dvr":"live");this.Hc=a.nh;this.md=a.md;this.fb=a.fb;this.Lc=a.k;this.Ta=a.Ta;this.o=a.aa||this.o;this.rb=a.ha;this.g=a.g;this.M=a.M}f=XG.prototype;
-f.rh=!1;f.$i=!1;f.Rl=!1;f.dg=!1;f.Sl=!1;f.Tl="yt";f.qh=null;f.cg=null;f.Np=!1;f.send=function(){if(!this.Np){var a=this.Mh(),a=S(this.jd,a);sa(a);this.Np=!0}};
-f.Mh=function(){var a={ns:this.Tl,el:this.Ic,hl:this.Kc,cr:this.hd,cpn:this.xa,docid:this.M,ver:2,referrer:this.referrer,cmt:this.re(this.A),plid:this.fb,ei:this.Lc,fmt:this.a?this.a.Oa:0,fs:this.Rl?"1":"0",rt:this.re(this.J),c:this.Sa,cver:this.Mc,euri:this.b,subscribed:this.g,lact:this.gd,cplatform:this.mc,cbrand:this.Ca,cmodel:this.Ra,cnetwork:this.Va,cbr:this.Ma,cbrver:this.Ka,cos:this.jb,cosver:this.kb,q:this.ld};this.rh&&(a.autoplay="1");this.Sl&&(a.splay="1");this.aj&&(a.ssrt="1");this.Y&&
-(a.delay=this.Y);this.G&&(a.adformat=this.G);this.V&&(a.content_v=this.V);void 0!=this.pa&&this.va&&(a.uga=this.va+this.pa);void 0!=this.k&&(a.len=this.re(this.k));!this.F&&0<this.B.length&&(a.fexp=this.B.toString());void 0!=this.da&&(a.mos=this.da);void 0!=this.la&&(a.volume=this.la);void 0!=this.ha&&(a.state=this.ha);null===this.cg||(a.rtn=this.re(this.cg));this.o&&(a.feature=this.o);this.Ta&&(a.list=this.Ta);this.rb&&(a.ytr=this.rb);this.F?(a.idpj=this.Jc,a.ldpj=this.Hc,null===this.qh||(a.rti=
-this.re(this.qh))):(void 0!=this.I&&(a.at=this.I),void 0!=this.L&&(a.allowed=this.L),void 0!=this.aa&&(a.ex_ads=this.aa));void 0!=this.ga&&(a.live=this.ga);this.ja||(a.ps=this.kd,a.sw=this.za,this.P&&(a.bc=this.P),this.Q&&(a.bd=this.Q,a.bt=this.lc),0<this.O&&(a.nbe=this.O));!this.dg&&0<this.i.length&&(a.st=La(this.i,this.re).join(","),a.et=La(this.j,this.re).join(","));return a};f.re=function(a){return(1*a.toFixed(3)).toString()};function YG(a,b,c,d){this.i=[];this.j=[];this.o=[];this.cj=b.Yi;c&&(this.O=c.nbe,this.P=c.bc,this.Q=c.bd,this.Ic=c.bt,this.Ml=c.fs,this.Nl=c.mos,this.aj=c.ssrt,this.source=c.sourceid,this.xa=c.sd,this.Kl=c.hmewadbc,this.va=c.hmewdfc,this.Ll=c.hmewdrop,this.Il=c.hmewvdbc,this.hd=c.hmemdf,this.ld=c.hmempaintdelay,this.jd=c.hmempainted,this.ga=c.hmempf,this.gd=c.hmempresented,this.Zf=c.volume);this.bj=b.bj;this.ph=b.Tb;this.V=b.k;this.Ka=b.F;this.Sa=b.A;this.Mc=b.B;this.Ra=b.Wf;this.Va=b.ef;this.jb=
-b.G;this.kb=b.I;this.mc=b.J;this.lc=b.L;this.Lc=b.O;this.b=b.b;this.Kc=b.Z;this.o=b.o;this.Hc=b.P;this.kd=b.i;this.Pl=b.qc;this.Xf=b.Xf?"1":void 0;this.G=Qx(b);this.oe=b.La;this.referrer=Rx(b);this.ag=b.Q;this.F=b.j;this.I=new B(window.screen.width,window.screen.height);this.Yf=b.ha;this.ha=b.la;this.la=b.pa;this.Yi=Ux(b);this.L=yw(b);this.pa=b.Ra;this.Jl=b.aa;!a.a||a.V.isEmpty();this.ph=a.df||this.ph;this.za=a.Da;this.Ca=a.Kc;this.Y=a.J;this.Ma=a.Ka;this.a=a.a;this.Ol=a.Ld;this.aa=a.Vf;a.Cb&&(this.ja=
-a.eb?"dvr":"live");this.da=a.nh;this.md=a.md;this.fb=a.fb;this.Jc=a.k;this.Ta=a.Ta;this.$f=a.ga;this.F=a.aa||this.F;this.bg=a.ha;this.Ql=a.Zi;this.g=a.g;this.eg=a.Hc;this.M=a.M;this.rb=a.V;this.B=d||[]}f=YG.prototype;f.ph=!1;f.$i=!1;f.Ml=!1;f.dg=!1;f.Nl=!1;f.Ol=!1;f.aj=!1;f.Pl="yt";f.Ql=!1;f.Sp=!1;f.send=function(){if(!this.Sp){var a=this.Mh(),a=S(this.cj,a);sa(a);this.Sp=!0}};
-f.Mh=function(){var a={html5:"1",ns:this.Pl,ps:this.oe,el:this.Kc,hl:this.kd,cr:this.ag,c:this.Ra,cpn:this.za,docid:this.M,sd:this.xa,sourceid:this.source,referrer:this.referrer,q:this.Yf,plid:this.fb,ei:this.Jc,fmt:this.a?this.a.Oa:0,fs:this.Ml?"1":"0",screenw:this.I.width,screenh:this.I.height,w:this.L.width,h:this.L.height,vw:this.rb.width,vh:this.rb.height,playerw:this.G.width,playerh:this.G.height,vid:this.Jl,rt:this.wh(this.J),mos:this.Nl,volume:this.Zf,app:this.bj,csipt:this.Ca,on3g:this.Xf,
-partnerid:this.md,sdetail:this.$f,subscribed:this.g,sw:this.Ma,list:this.Ta,eurl:this.b,framer:this.Hc,feature:this.F,ytr:this.bg,threed:this.eg,lact:this.Yi,cver:this.Va,cplatform:this.Lc,cbrand:this.Ka,cmodel:this.jb,cnetwork:this.kb,cbr:this.Sa,cbrver:this.Mc,cos:this.mc,cosver:this.lc};this.dg&&(a.playback="1");this.ph&&(a.autoplay="1");this.Ol&&(a.splay="1");this.aj&&(a.ssrt="1");this.Y&&(a.delay=this.Y);this.Ql&&!this.dg&&(a.vtmp="1");this.$i&&(a.tv="1");this.V&&(a.content_v=this.V);void 0!=
-this.ha&&this.la&&(a.uga=this.la+this.ha);void 0!=this.k&&(a.len=this.wh(this.k));0<this.o.length&&(a.fexp=this.o.toString());0<this.aa&&(a.idpj=this.aa);0<this.da&&(a.ldpj=this.da);void 0!=this.pa&&(a.attrib=this.pa);void 0!=this.ja&&(a.live=this.ja);this.P&&(a.bc=this.P);this.Q&&(a.bd=this.Q,a.bt=this.Ic);0<this.O&&(a.nbe=this.O);void 0!=this.va&&(a.hmewdfc=this.va,a.hmewdrop=this.Ll,a.hmewvdbc=this.Il,a.hmewadbc=this.Kl);void 0!=this.ga&&(a.hmempf=this.ga,a.hmemdf=this.hd,a.hmempresented=this.gd,
-a.hmempainted=this.jd,a.hmempaintdelay=this.ld);0<this.i.length&&(a.st=this.i.map(this.wh).join(","),a.et=this.j.map(this.wh).join(","));for(var b=0;b<this.B.length;b++)Hb(xB(this.B[b]),function(b,d){d in a||(a[d]=b)});return a};f.wh=function(a){return(1*a.toFixed(3)).toString()};function ZG(){this.cb=[];this.L=[10,10,10,40];this.i=null;this.B="paused";this.ga=!1;this.k=NaN;this.P=this.J=0;this.aa=this.O=null;this.ja=vB;this.j=null;this.Q="";this.V=this.F=0;this.G=NaN;this.o=this.A=0}y(ZG,K);function $G(a){var b=a.aa();a.O&&w(b,a.O());return b}function Gz(a,b,c){var d=(x()-a.A)/1E3;c=isNaN(c)?d:c;c=Math.ceil(c);var e=a.L[a.J];a.J+1<a.L.length&&a.J++;c=c+e;d=1E3*(c-d);a.k=H(v(a.la,a,c,b),d);return c}
-ZG.prototype.la=function(a,b){if(!this.ka()){this.k=NaN;var c=aH(this),d=bH(this,c);b&&(d.qh=a);var e=400<this.P;c.length&&!e&&(d.cg=Gz(this,!0,a));d.send();this.P++}};ZG.prototype.ha=function(){var a=this.j()||0,b=(x()-this.A)/1E3,c=a-this.F;0!=c&&(0.5<Math.abs(isNaN(this.G)?c:c-(b-this.G))?(cH(this),this.o=a,this.G=NaN):(this.G=b,this.g&&isNaN(this.k)&&Gz(this,!1)));this.F=a};function cH(a){0.5<a.F-a.o&&(a.cb.push([a.o,a.F]),a.o=a.F)}function aH(a){cH(a);var b=a.cb;a.cb=[];return b}
-function Ez(a,b){var c=$G(a),d=a.ja();a.b.cj?(w(c,{state:a.B}),z(d,function(a){w(c,xB(a))}),d=new XG(a.a,a.b,b,c)):d=new YG(a.a,a.b,c,d);d.J=(x()-a.A)/1E3;d.k=a.da();return d}function bH(a,b){b.length||(b=[[a.o,a.o]]);for(var c=Ez(a,"watchtime"),d=0;d<b.length;d++)c.i.push(b[d][0]),c.j.push(b[d][1]);return c}
-function Hz(a){var b=a.b;a=a.a;var c=a.aa||b.j,c={ns:b.qc,html5:"1",el:b.Z,ps:b.La,fexp:b.o.join(",")||void 0,feature:c||void 0,ytr:a.ha||void 0,list:a.Ta,d:b.va,f:b.da};b.Tb&&(c.autoplay="1");a.g&&(c.subscribed=a.g);return c}ZG.prototype.onError=function(a){this.i.onError(a)};
-function Jz(a,b){if(!a.ka()){P(b.state,2)?(a.B="paused",bH(a,aH(a)).send()):P(b.state,8)?(a.B="playing",a.g&&isNaN(a.k)&&Gz(a,!1)):a.B="paused";var c=a.i,d=b.state,e;e=b.state;if(P(e,128))e="ER";else if(P(e,16)||P(e,32))e="S";else{var g=WG[vj(e)];"B"==g&&P(e,4)&&(g="PB");e=g}e!=c.b&&"N"!=e&&(!c.a.Ca||"B"!=e&&"PB"!=e||c.mj(),zz(c,"vps",[e]),c.b=e);if(0<Ho(b,256)||P(d,128))c.onError(d.a.errorCode);(P(d,2)||P(d,128))&&c.ng()}}
-function rz(a,b,c){b.rt=(x()-a.A)/1E3;w(b,$G(a));w(b,Hz(a));a=Kj("streamingerror"==b.event?"//s.youtube.com/stream_204":a.b.lb+"player_204",b);sa(a,c)}function nz(a,b){var c=a.b,d=a.a,e={ns:c.qc,el:c.Z,eurl:c.b,fmt:d.a?d.a.Oa:0,html5:1,list:d.Ta,plid:d.fb,ei:d.k,ps:c.La,noflv:1,st:a.j(),video_id:d.M};c.Tb&&(b.autoplay="1");d.gj&&(b.tmi="1");w(e,b);w(e,Ox(c));sa(S("//www.youtube.com/live_204",e))}ZG.prototype.H=function(){ZG.C.H.call(this);I(this.k);this.k=NaN;jf(this.I);this.I=NaN};function dH(a,b,c){R.call(this);this.o=1;this.Y={};this.D("openingpage",v(this.Fr,this));this.D("initializingmode",v(this.Cr,this));this.D("internalenvironmentdatachange",v(this.Br,this));this.D("internalvolumechange",v(this.Km,this));this.J=null;b instanceof Hf||(b=new Hf(b));this.J=b;b=this.J.args;Tg(this.a);this.a=new Ix(b||{});this.u("internalenvironmentdatachange","newdata");this.ja=Kx(this.a)?new Hh(this,1):new Vg(this,1);L(this,this.ja);this.V=new Mh(this);L(this,this.V);this.I=new Mh(this,
-1);L(this,this.I);this.P={};this.ga=Sb(["internalvideodatachange",this.ur,"liveviewshift",this.Dr,"commoninfoloaded",this.Ar,"playbackready",this.wr,"playbackstarted",this.xr,"statechange",this.yr,"videoelementevent",this.Sr]);this.la=new Th(this.a);this.k=new fx;L(this,this.k);this.b=null;b=new bz(this.a,1);if(this.b!=b){if(this.b){var d=this.b,e=this.ga,g;for(g in e)d.$(g,e[g],this)}b.Y=this.la;g=this.ga;for(var h in g)b.D(h,g[h],this);this.b=b}this.ha=Sb(["beginseeking",this.zr,"endseeking",this.Pr,
-"internalvideodatachange",this.Lm,"internalvideoformatchange",this.Nr,"progresssync",this.Jr,"seekto",this.Kr,"onLoadProgress",this.Er,"onVideoProgress",this.Or,"newlicensesession",this.Qr,"playbackdataloaded",this.Hr,"playbackready",this.Gr,"statechange",this.Ir]);this.j=null;nA(this,this.b);this.aa=-1;this.G=this.A=null;this.B={};this.O=null;this.L={};this.Q=null;this.da=0;c?this.R=c(this):this.R=new MG(this);L(this,this.R);this.R.D("templateerror",this.Lr,this);this.R.D("templateready",this.Mr,
-this);this.R.D("resize",this.Rr,this);Sp("fs");c=this.R;c.la=a;c.Gj()||c.u("templateerror");bG(this,"init")}y(dH,R);f=dH.prototype;f.Ud=null;f.list=null;f.Xe=!0;f.wa=null;f.Af=null;f.Dg=1;f.R=null;f.vj=null;f.xf=null;f.Mk=!1;f.ri=null;f.Zn=0;var eH={};
-function fH(a){var b=tn.getTag();a.i=b;a.Ud=a.i;a.j&&tz(a.j,b);oj(a.i,a.Dg);if(a.a.Md)a.xf&&yf(a.xf),a.xf=J(a.i,"volumechange",v(a.qt,a),!1);else{var b=a.i,c=a.wa.muted;b.volume=a.wa.volume/100;b.muted=c}b=a.R;b.b=a.i;b.da=new Db(0,0,0,0);b.b.parentNode||b.g.appendChild(b.b);V(b.b,"video-stream");V(b.b,"html5-main-video");c=b.app.K();c.Ub&&c.qe&&b.b.setAttribute("controls",!0);c.th&&b.b.setAttribute("webkit-playsinline",!0);b.b.setAttribute("x-webkit-airplay","allow");c.fj&&(b.va=J(b.b,"click",v(b.b.play,
-b.b)));a.a.Ya=a.i}function gH(a){if(a.i){a.xf&&(yf(a.xf),a.xf=null);a.j&&sn(a.j);var b=a.R;b.b&&(F(b.b),b.b=null);a.a.Ya=null;tn.releaseTag(a.i);a.i=null}}function pn(a,b){a.a.tb?(a.O&&(pd(a.i,a.O.left,a.O.top),Ad(a.i,Gb(a.O)),a.O=null),nj(a.i),sn(a.j),tz(a.j,a.i),oj(a.i,a.Dg)):tn.releaseTag(b)}function nA(a,b){if(a.j!=b){a.j&&(gx(a.k),pA(a,a.j));a.P[b.B]=b;a.j=b;a.i&&tz(b,a.i);var c=a.ha,d;for(d in c)b.D(d,c[d],a);a.u("videoplayerchange",b);gz(b)&&hH(a)}}
-function pA(a,b){sn(b);var c=a.ha,d;for(d in c)b.$(d,c[d],a);b!=a.b&&(c=b.B,a.P[c]==b&&delete a.P[c]);b==a.j&&(a.j=null,b!=a.b&&nA(a,a.b))}function N(a,b){return b?a.P[b]||null:a.j}function hH(a){var b=a.j.getVideoData();a.Lm("newdata",a.j,b);var c=a.k;z([Jo,Gw,go,bx,ju,Mw,Qw,Ww,ht],c.B,c);a.u("videoready",b);6!=a.o&&mz(a.j)}f=dH.prototype;f.wr=function(){iH(this,5)};f.Gr=function(a){a=a.i;P(a,8)&&!P(a,2)&&this.Qd()};
-function Fh(a){!a.G&&a.I.K().qg&&(a.G=new HF(a),a.G&&jH(a,a.G));var b=a.G;b&&!b.vc&&b.$a(a.I)&&b.create()}
-function jH(a,b){L(a,b);b.D("loaded",a.pm,a);b.D("unloaded",a.rm,a);b.D("command_pause",kH(a.Od,a));b.D("command_play",kH(a.Qd,a));b.D("command_seek",kH(a.pf,a));b.D("command_disable_controls",a.kg,a);b.D("command_enable_controls",a.Bh,a);b.D("command_redirect_controls",a.vm,a);b.D("command_stop_redirect_controls",a.zh,a);b.D("command_redirected_show_is_playing",a.R.zj,a.R);b.D("command_progress",a.jj,a);b.D("command_add_cuerange",a.om,a);b.D("command_remove_cuerange",a.tm,a);b.D("command_remove_cuerange_all",
-a.um,a);b.D("command_update_cuerange_markers",a.xm,a);b.D("command_preroll_ready",a.wm,a);b.D("command_hide_all_dialogs",a.R.yj,a.R);b.D("command_clear_video_overlays",a.Eh,a);b.D("command_log",a.of,a);b.D("publish_external_event",a.sm,a);b.D("command_log_timing",a.k.A,a.k)}function Gh(a){a&&a.vc&&a.destroy()}f.Wa=function(a,b){this.u.apply(this,arguments);this.af.apply(this,arguments)};f.Ni=function(a,b){var c=ab(arguments);Kx(this.a)&&c.push(this.j.B);this.u.apply(this,c)};f.K=function(){return this.a};
-f.getVideoData=function(a){return(a=N(this,a))?a.getVideoData():null};f.log_=function(){};f.Cr=function(){jf(0);this.a.Md||this.Km(this.wa)};f.kj=function(){var a=Tx(this.a);a.fs=this.a.pb;a.volume=Math.round(this.wa.volume);a.mos=this.wa.muted?1:0;this.a.eg&&this.g&&this.g.g&&"WL"==this.g.g.type&&(a.ssrt=1);return a};f.rq=function(){var a=jx(this.k);if(this.A){var b=this.A.Hi();b&&a.push(b)}return a};f.Lr=function(){ex(this.b,5,void 0,void 0)};
-f.Mr=function(){this.a.Bj=this.R.a;var a=this.k,b={};b.loaded=v(this.pm,this);b.unloaded=v(this.rm,this);b.command_pause=kH(this.Od,this);b.command_play=kH(this.Qd,this);b.command_seek=kH(this.pf,this);b.command_disable_controls=v(this.kg,this);b.command_enable_controls=v(this.Bh,this);b.command_redirect_controls=v(this.vm,this);b.command_stop_redirect_controls=v(this.zh,this);b.command_redirected_show_is_playing=v(this.R.zj,this.R);b.command_progress=v(this.jj,this);b.command_add_cuerange=v(this.om,
-this);b.command_remove_cuerange=v(this.tm,this);b.command_remove_cuerange_all=v(this.um,this);b.command_preroll_ready=v(this.wm,this);b.command_update_cuerange_markers=v(this.xm,this);b.command_hide_all_dialogs=v(this.R.yj,this.R);b.command_clear_video_overlays=v(this.Eh,this);b.command_log=v(this.of,this);b.publish_external_event=v(this.sm,this);b.module_menu_button_add=v(this.pr,this);b.module_menu_button_remove=v(this.qr,this);b.module_menu_item_add=v(this.rr,this);b.module_menu_item_remove=v(this.sr,
-this);a.j=b;b=this.V;a.b!=b&&(gx(a),a.i={},a.b=b);this.R.ij();a=this.ja;a.b=this.R.a;for(var c in a.i)a.b[c]=a.i[c];for(c in a.g)a.b[c]=a.g[c];c=v(this.tr,this);a=document;b=Ye("fullscreenchange",a);"msfullscreenchange"==b&&(b="MSFullscreenChange");this.vj=b?J(a,b,c):null;c=this.J.args;this.a.dj?this.wa=Sh():this.wa||(this.wa={volume:100,muted:!1,nonNormalized:100});fH(this);a=new nh(c);dz(this.b,a);b=this.getVideoData();if("detailpage"==this.a.Z){var d;d=b.M;var e=Rh("yt-player-restore-playhead");
-d=e?e[d]:void 0;d&&(b.ya=d)}jg("yt-player-restore-playhead");this.a.Oc=SF(this.R);"detailpage"!=this.a.Z&&c&&(c.playlist||c.list||c.api)&&(lH(this,c),a.M||a.gf||(c=this.g,a=v(this.Jm,this),c.ye=a,c.Vd&&H(c.ye,0)));if(c=this.J.args.jsapicallback)ha(c)||(c=n(c)),c&&kH(v(c,l,this.a.ej),l);this.a.qg=Eh(this.a)&&(!Ua(Mg())||!Ua(Og()));ll()?this.a.Ul?mH(this):"leanback"!=this.a.Z&&nH(this):ex(this.b,5,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",void 0);this.R.Kj()};
-function nH(a){a.u("initializingmode");iH(a,2)}function mH(a){a.u("initializingmode");nA(a,a.b);iH(a,3);a.a.tb||(gH(a),fH(a),tz(a.b,a.i));iz(a.b);oH(a,3)}function kH(a,b){return function(){var c=Array.prototype.slice.call(arguments);H(function(){a.apply(b||this,c)},0)}}f.of=function(a,b,c){var d=N(this);b.event=a;d.k&&rz(d.k,b,c)};
-function dh(a,b){if(!isNaN(b)&&a.i){var c=1,c=a.a.gg?eh:[1],c=1>b?Pa(c,function(a){return a>=b}):Ra(c,function(a){return a<=b});a.Dg!=c&&(a.Dg=c,a.b==a.j&&oj(a.i,c),a.u("onPlaybackRateChange",c))}}function fh(a,b){var c=a.getVideoData(b);return c&&c.a?c.a.a.i:"unknown"}function HG(a){return(a=N(a,void 0))?Uy(a.ja,a.a):"unknown"}f.getCurrentTime=function(a){return(a=N(this,a))?a.getCurrentTime():0};function Lh(a,b){var c=N(a,b);return c?c.od():0}
-function hh(a,b){var c=a.getVideoData(b);if(!c)return[];c=La(c.j,function(a){return a.Re()});eb(c);return c}function rh(a,b){var c=Dz(a.b,b);c.debug_playbackQuality=fh(a);c.debug_date=(new Date).toString();return pb(c)}
-function Lw(a,b){var c=a.getVideoData(),d=!!c.P||!!c.zf||!b;a.u("threedenabled",d);d&&a.i.setAttribute("mozStereoMode","1");Hw()&&(a.i.setAttribute("mozStereoMode",d?"1":"0"),c=bl[d?c.oe:0],d=document.createElement("NvStereoExtDataElement"),d.setAttribute("stereoMode",c),Zc(document.documentElement,d),Ef(d,"3DModeEvent"))}function Dh(a){return(a=N(a,1))&&a.i}
-f.Sr=function(a){var b=a.target;switch(a.type){case "loadedmetadata":Up("fvb")||Sp("fvb");this.a.hd?this.da=H(v(this.R.we,this.R),16):this.R.we();break;case "loadstart":Up("gv")||Sp("gv");break;case "progress":case "timeupdate":Up("l2s")||(a=kj(b),a<b.buffered.length&&2<b.buffered.end(a)&&Sp("l2s"))}};f.Qr=function(a){if(this.Mk){var b=this.Zn.toString();this.Zn++;this.ri[b]=a;a={request:ab(a.b[0]?a.b[0].message:null),sessionId:b,system:a.j.a,url:a.k};this.u("onNewLicenseSession",a)}else a.start()};
-f.Er=function(a,b){this.Ni("onLoadProgress",b)};f.Or=function(a,b){this.Ni("onVideoProgress",b)};
-f.Jr=function(a,b,c,d,e){if(!e&&a.hg()&&!lz(a)){e=a.getVideoData();if(this.a.ze&&e.ra&&!e.en&&e.Ae>=e.gm){var g;g=a.K();var h=wb(e.pe/e.ra,0,1),h={html5:"1",video_id:e.M,eurl:g.b,framer:g.P,feature:g.j,ps:g.La,el:g.Z,list:e.Ta,w:h,l:e.ra,plid:e.fb,ei:e.k,access_token:e.G,tpmt:e.Ae,cpn:e.Da};g.g&&(h.adformat=g.g);g.referrer&&(h.referrer=Rx(g));g.Tb&&(h.autoplay="1");g.Ea&&(h.authuser=g.Ea);g.Ua&&(h.pageid=g.Ua);e.Ld&&(h.splay="1");e.g&&(h.subscribed=e.g);w(h,Ox(g));g=S(g.lb+"set_awesome",h);sa(g);
-e.en=!0}e.ra&&e.Ae>=e.$l&&pH(this)}this.jj(b,c,d,a)};f.jj=function(a,b,c,d){this.u("progresssync",a,b,c||0,(d||N(this)).B)};
-f.yr=function(a){var b;(b=!P(a.state,2))||(this.g&&("embedded"==this.a.Z||this.a.pb)&&fo(this)?(th(this),b=!0):b=!1,b=!b);if(b){P(a.state,2)&&(this.Od(),P(a.a,32)&&this.b.Sh(),this.a.nc&&IG(this,!1));0<Ho(a,256)&&(b=a.state.a,Ch(this.b,b.errorCode,b.errorDetail));if(P(a.state,128)){b=a.state;jf(0);ch(this);b=b.a;206==b.errorCode&&Ch(this.b,b.errorCode,b.errorDetail);b.message||(b.messageKey||(b.messageKey="HTML5_DEFAULT_FALLBACK"),b.message=mf(b.messageKey));5==b.errorCode&&Ch(this.b,208,b.errorDetail);
-var c=5;206==b.errorCode&&(c=150);Ta(rj,b.errorCode)&&(c=b.errorCode);this.u("onError",c);this.u("onDetailedError",b)}this.u("applicationplayerstatechange",a);P(a.state,2)&&(a=this.getVideoData(),a.Cb&&!a.eb&&this.kg(["play_pause"]))}};f.Ir=function(a){!P(a.state,32)&&0>Ho(a,16)&&(!P(a.state,8)||this.i.ended&&!P(a.state,2)||this.Qd());this.u("presentingplayerstatechange",a);this.af("onStateChange",a);oH(this,vj(a.state))};
-f.ur=function(a,b,c){if("newdata"==a){Gh(this.A);Gh(this.G);a=[];for(var d in this.B)bh(this,d)&&a.push(d);this.B={};0<a.length&&this.u("controlsenabled",a);this.zh();this.Y={}}this.getVideoData().Dj?(this.Af=Ob(this.wa),this.kg(["audio"]),d=this.i,d.Bk=!0,d.muted=!0):(bh(this,"audio")&&this.Bh(["audio"]),this.i.Bk=!1,this.Af&&(KG(this,this.Af),this.Af=null));d=this.getVideoData();d.Cb&&!this.a.wj?ex(this.b,205,"DEVICE_FALLBACK",void 0):d.Cb&&!d.eb?this.kg(["seek"]):this.Bh(["seek"]);this.getVideoData().ak&&
-!this.a.xj&&ex(this.b,207,"DEVICE_FALLBACK",void 0);if(c.O||c.i.focEnabled||c.i.rmktEnabled)c=1E3*this.getVideoData().ra,qH(this,"part2viewed",0,c),qH(this,"videoplaytime25",0.25*c,c),qH(this,"videoplaytime50",0.5*c,c),qH(this,"videoplaytime75",0.75*c,c),qH(this,"videoplaytime100",c,2147483647),qH(this,"conversionview",c,2147483647)};
-f.Lm=function(a,b,c){if("newdata"==a&&(gx(this.k),dh(this,1),!b.k&&!lz(b))){var d=new ZG,e=v(this.kj,this);d.O=e;e=v(this.rq,this);d.ja=e;cz(b);b.a&&!lz(b)&&(b.k=d,e=v(b.od,b),d.da=e,e=v(b.getCurrentTime,b),d.j=e,e=v(b.qq,b),d.pa=e,e=v(b.sq,b),d.aa=e,e=b.o,d.a=b.a,d.b=e,d.Q=d.b.lb+"get_video",d.g=!1,d.i=new VG(d.a,d.b,d.pa),L(d,d.i),d.ga=!0,b.a.fg&&nz(b.k,{metric:"connected"}))}this.wa.volume=(this.wa.nonNormalized||this.wa.volume)*this.getVideoData().uh;c.gm=Math.min(0.8*c.ra,180);this.Wa("videodatachange",
-a,c,b.B)};f.Nr=function(a,b){var c=this.j.getVideoData();a==c&&this.u("onPlaybackQualityChange",a.a.a.i,b)};f.Br=function(){"detailpage"==this.a.Z&&Ih(this)};function Ih(a){var b=rH();if(b&&0<=b.index){var c=[];z(b.videoIds,function(a){if(a=b.videoData?b.videoData[a]:void 0)a.video_id=a.id,c.push(a)});lH(a,{videoList:c,loop:b.autoPlay,index:b.index})}}function lH(a,b){Tg(a.g);a.g=new sm(b)}
-function qH(a,b,c,d){b in a.Y||(c=new $h(c,d,{id:b,priority:1}),c.Eb.D("onEnter",a.Zo,a),c.Eb.D("onExit",a.Zo,a),a.b.xk(c),a.Y[b]=c)}f.Zo=function(a){var b=a.getId(),c=this.b.getVideoData();"part2viewed"==b?(c.O&&sa(c.O),c.kb&&sa(c.kb)):"conversionview"==b&&pH(this);c.Ca&&(b=a.getId(),c=Kj(c.Ca,{label:b}),sa(c));this.b.Rh(a)};
-function pH(a){var b=a.b.getVideoData();b.fo||(b.i.eventLabel=a.a.Z,b.i.playerStyle=a.a.La,b.O&&(b.i.feature="pyv"),b.i.vid=b.M,b.i.isAd=!("adunit"!=a.a.Z&&!b.O),lG("view",b.i),b.fo=!0)}function iH(a,b){b!=a.o&&(2==b&&oH(a,5),a.o=b,a.u("appstatechange",b))}function oH(a,b){a.aa!=b&&(a.aa=b,a.Ni("onStateChange",b))}function bG(a,b){if(a.a.Ka){var c={controlClicked:b};a.a.pb&&(c.fs=1);a.of("",c)}}f.pf=function(a,b,c,d){(d=N(this,d))&&yz(d,a,!1!=b,c)};
-f.Kr=function(a,b){var c=a.getVideoData();if(1==this.o||2==this.o)c.ya=b;2==this.o?mH(this):(c=Cz(a,b),this.Wa("seekto",c))};f.zr=function(){this.Wa("beginseeking")};f.Pr=function(){this.Wa("endseeking")};function KG(a,b){a.wa=b;a.u("internalvolumechange",a.wa)}function Yg(a){a.wa.muted=!0;a.u("internalvolumechange",a.wa)}function Zg(a){a.wa.muted=!1;a.u("internalvolumechange",a.wa)}function ph(a,b){var c;if(c=(new re(b)).a){var d=a.a;d.va=c.get("d",d.va);d.da=c.get("f",d.da)}}
-function kh(a,b,c){b=new nh(b);return sH(a,b,void 0,c)}function sH(a,b,c,d){var e=N(a,d);if(!e)return!1;I(a.da);void 0!=c&&(b.ff=c);ch(a,d);dz(e,b);if(!hz(e))return!1;Mx(e.K(),b.b);e==a.b?(iH(a,1),mH(a)):iz(e);return!0}function vh(a,b){var c=sH(a,b);Wg(a,c,void 0)}function Wg(a,b,c){c=N(a,c);b&&c==a.b&&(c.getVideoData().Ld=!0)}function mh(a,b,c){var d=N(a,c);d&&(ch(a,c),dz(d,b),hz(d)&&(Mx(d.K(),b.b),d==a.b&&(iH(a,1),nH(a))))}
-function Xn(a,b,c,d,e){if(!b&&!d)throw Error("Playback source is invalid");b=lh(b||null,d||null);a.a.pb||"detailpage"!=a.a.Z?d?(a.Xe=!1,sh(a,b,void 0,void 0,void 0)):kh(a,b,1):(d={},c&&(d.feature=c),b=new nh(b),d=Zt(a.a,b,d),c&&a.u("onNavigate",{url:d,feature:c}),e?dG(a,d):(window.ytspf||{}).enabled?spf.navigate(d):window.location=S(d,{})+"")}function sh(a,b,c,d,e){b=ia(b)&&!t(b)?b:{api:b,index:c,startSeconds:d,suggestedQuality:e};lH(a,b);b=a.g;a=v(a.Jm,a);b.ye=a;b.Vd&&H(b.ye,0)}
-f.Jm=function(){var a=wh(this.g);this.getVideoData().df||!this.Xe?vh(this,a):mh(this,a)};function fo(a){var b=rH();return!(!a.g||!(a.g.loop||a.g.ua+1<a.g.Mb)||b&&!b.autoPlay)}function th(a){a.g&&(a.g.Vd?(a.g.loop||a.g.ua+1<a.g.Mb)&&vh(a,xm(a.g)):(xm(a.g),a.Xe=!1))}function uh(a){a.g&&(a.g.Vd?(a.g.loop||0<=a.g.ua-1)&&vh(a,ym(a.g)):(ym(a.g),a.Xe=!1))}function rH(){var a=n("yt.www.watch.lists.getState");return a?a():null}
-function qh(a,b){var c=null;b&&(c={t:Math.floor(a.getCurrentTime(1))});return Zt(a.a,a.getVideoData(1),null,c)}f.om=function(a,b){var c=N(this,b);c&&(z(a,c.xk,c),this.u("cuerangesadded",a))};f.tm=function(a,b){var c=N(this,b);c&&(z(a,c.Rh,c),this.u("cuerangesremoved",a))};f.um=function(a,b){var c=N(this,b);if(c){for(var c=c.A,d=c.i.length-1;0<=d;d--)c.i[d].namespace==a&&yj(c,d);c.Xb()}};f.xm=function(a){this.u("cuerangemarkersupdated",a)};f.wm=function(a,b){var c=N(this,b);c&&sz(c,a)};f.xr=function(){tH(this)};
-function tH(a){if(!a.a.fk){var b=a.b.getVideoData();if(b.M){var c=b.M;Wp().docid=c}b.k&&(c=b.k,Wp().ei=c);b.Da&&(c=b.Da,Wp().cpn=c);0<b.ya&&(c=b.ya.toString(),Wp().start=c);b=b.a.Oa.toString();Wp().fmt=b;b=Math.round((a.b.b?ih(a.b.b):0)*Lh(a)).toString();Wp().tds=b;Sp("aft");if("detailpage"==a.a.Z){var b=a.k.F,d;for(d in b)Sp(d,b[d]);d=a.k.o;for(var e in d)b=e,c=d[e],Wp()[b]=c;b=Tp().tick;e=Tp().span;c=Wp();if(d=n("yt.timing.reportbuilder_")){if(d=d.apply(null,[b,e,c,void 0]))Vp(d),Xp()}else{d={v:2,
-s:"youtube",action:df("TIMING_ACTION")};var g=df("TIMING_INFO")||{},h;for(h in g)c[h]=g[h];h=c.srt;delete c.srt;if(!h&&0!==h)try{var k=(window.performance||window.mozPerformance||window.msPerformance||window.webkitPerformance).timing;h=k.responseStart-k.navigationStart}catch(m){c.pt&&(h=c.pt)}if(h||0===h)c.srt=h;b.aft||(b.aft=b.vr&&b.cl&&b.cl>b.vr?b.cl:b.vr?b.vr:b.ol);b.aft&&b.plev&&(b.aft=Math.min(b.aft,b.plev));b.vr&&b.gv&&(e.vl=Math.round(b.vr-b.gv));for(var p in c)"_"!=p.charAt(0)&&(d[p]=c[p]);
-k={};p=[];h=b._start;for(var r in b)"_"!=r.charAt(0)&&(c=Math.max(Math.round(b[r]-h),0),k[r]=c,p.push(r+"."+c));d.rt=p.join(",");r={};p=[];for(var s in e)"_"!=s.charAt(0)&&(r[s]=e[s],p.push(s+"."+e[s]));d.it=p.join(",");Vp(d);(s=n("ytdebug.logTiming"))&&s(d,k,r);Xp()}}a.a.fk=!0}}f.pm=function(a){"remote"==a?(iH(this,6),Gh(this.A)):this.Ni("onApiChange")};f.rm=function(a){"remote"==a&&nH(this)};
-f.qt=function(){if(!bh(this,"audio")){var a=100*this.i.volume,a={volume:a,nonNormalized:a/this.getVideoData().uh,muted:this.i.muted};this.wa=Ob(a);this.Wa("onVolumeChange",a)}};
-f.Km=function(a){a.volume=wb(a.volume,0,100);a.nonNormalized=a.volume/this.getVideoData().uh;if(this.a.dj&&!this.a.Md){var b={};b.volume=isNaN(a.volume)?Sh().volume:wb(a.volume,0,100);b.nonNormalized=a.nonNormalized;b.muted=void 0==a.muted?Sh().muted:a.muted;fg("yt-player-volume",b,2592E3)}if(bh(this,"audio"))this.Af&&(this.Af=Ob(a),this.Wa("onVolumeChange",a));else{var b=this.i,c=a.muted;b.volume=a.volume/100;b.muted=c;this.a.Md||this.Wa("onVolumeChange",a)}};f.tr=function(){uH(this,!!Gf())};
-function uH(a,b){a.R.uo(b);if("detailpage"==a.a.Z&&!b){var c=a.b.getVideoData(),d=n("checkCurrentVideo");if(d&&df("VIDEO_ID")!=c.M){var e=a.getCurrentTime(),g={};g[c.M]=e;fg("yt-player-restore-playhead",g,172800);d(c.M);a.u("openingpage")}}a.a.pb=b;a.R.we();a.Wa("fullscreentoggled",b)}f.Rr=function(){SG(this)};f.Eh=function(){this.Wa("clearvideooverlays")};f.pr=function(a,b){this.Wa("menu_button_add",a,b)};f.qr=function(a){this.Wa("menu_button_remove",a)};
-f.rr=function(a){this.Wa("menu_item_add",a)};f.sr=function(a){this.Wa("menu_item_remove",a)};f.Dr=function(a){this.Wa("liveviewshift",a)};f.sm=function(a,b){if("onAdStateChange"==a){var c=arguments[1],d=arguments[2],e=arguments[3]||{};1==c&&tH(this);"leanback"==this.a.Z&&Kx(this.a)&&(0==c?this.Ud=this.i:this.Ud=d,this.u("onAdStateChange",c,e.video_id))}else this.u.apply(this,arguments)};
-f.af=function(a,b){this.k.G.apply(this.k,arguments);this.A&&this.A.u.apply(this.A,arguments);this.G&&this.G.u.apply(this.G,arguments)};f.Qd=function(a,b){var c=N(this,b);c&&(2==this.o?mH(this):c.V?(a&&vH(this,c),P(c.i,2)?this.pf(0):vz(c)):iz(c))};f.Od=function(a,b){var c=N(this,b);c&&(a&&vH(this,c),qz(c))};
-function ch(a,b){var c=N(a,b);if(c&&1!=a.o&&2!=a.o){qz(c);if(c.k){var d=c.k;bH(d,aH(d)).send();d=d.i;"PL"==d.b&&(zz(d,"vps",["PA"]),d.b="PA");d.ng()}c.V=!1;c.b&&(ez(c),c.g&&(Ug(c.j,c.g),c.j=null,c.g=null),c.a&&(c.a.ya=c.getCurrentTime()),c.G=NaN,mj(c.b),c.o.za&&pj(c.b,!1),P(c.i,128)||jz(c,uj(c.i)))}}function $g(a,b){if(!bh(a,"play_pause")){var c=a.L.play_pause?a.Q:null;c?c.ie("control_play"):a.Qd(!1,b)}}
-function ah(a,b){if(!bh(a,"play_pause")){var c=a.L.play_pause?a.Q:null;c?c.ie("control_pause"):a.Od(!1,b)}}function JG(a,b){if(!bh(a,"play_pause")&&(!a.a.Db||2!=a.o||tn.hasTags(void 0))){var c=a.L.play_pause?a.Q:null;c?c.ie("control_toggle_play_pause"):(c=N(a,void 0))&&(c.hg()?a.Od(b,void 0):a.Qd(b,void 0))}}function Xg(a,b,c,d,e){if(!bh(a,"seek")){var g=a.L.seek?a.Q:null;g?g.ie("control_seek",b):a.pf(b,c,d,e)}}
-function IG(a,b){if(a.a.pb!=b)if(Ff())if(b){var c=a.R.a,d=Xe(["requestFullscreen","requestFullScreen"],c);d&&d.apply(c)}else(c=Xe(["exitFullscreen","cancelFullscreen","cancelFullScreen"],document))&&c.call(document);else a.u("onFullScreenToggleRequest"),uH(a,b)}function dG(a,b){IG(a,!1);a.u("openingpage");Qp(b)}f.Ar=function(a){Lx(this.a,a)};
-f.Hr=function(){if(this.j==this.b){var a;if(a=Eh(this.a))if(ig("yt-remote-delayed-connect-key"))a=!0;else{a=Fg();var b=xg(Mg());a=!!Bg(b,a)}if(a||!this.getVideoData(1).jm||this.a.nc)if((b=gz(this.b))||(b=((b=this.getVideoData())&&b.I.length&&!gz(N(this))?0<=Ja(b.I,"fresca"):!1)||a),b){if(this.b.Q.length||0<Ji(this.b.A.b,-2147483648).length)iH(this,4),Gh(this.A);a&&iH(this,6);!this.A&&this.I.getVideoData().ca&&(this.A=new DB(this))&&jH(this,this.A);(a=this.A)&&!a.vc&&a.$a(this.I)&&a.create();Fh(this);
-hH(this)}else a=!1,this.getVideoData().ja||this.V&&(a=Vw(this.V)),a?(a=this.getVideoData(),kh(this,{video_id:a.b.ypc_vid||a.M,ypc_preview:1},1)):(this.log_("No available formats"),ex(this.b,5,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",void 0));else a="DEVICE_FALLBACK",hc||dj("iemobile")||dj("xbox")&&dj("trident")||dj("nintendo wiiu")||(a="FLASH_FALLBACK"),ex(this.b,5,a,void 0)}else hH(this)};f.Fr=function(){this.Od()};
-function vH(a,b){var c=b.getVideoData(),d="html5-bezel-pause";P(b.i,8)?c.Cb&&!c.eb&&(d="html5-bezel-stop"):d="html5-bezel-play";a.R.jp(d)}function SG(a){a.a.Oc=SF(a.R);if(a.i){var b=!1,c=a.getVideoData();if(0!=a.i.readyState){var d=new B(a.i.videoWidth,a.i.videoHeight);Ab(c.V,d)||(c.V=d,b=!0)}c=VF(a.R,SF(a.R),TF(a.R),UF(a.R),void 0);Fb(a.a.Ko,c)||(a.a.Ko=c,b=!0);c=VF(a.R,SF(a.R),TF(a.R),UF(a.R),!0);Fb(a.a.tf,c)||(a.a.tf=c,b=!0);b&&(gh(N(a),"r"),a.u("resize",Qx(a.a)),a.Wa("onResize"))}}
-function bh(a,b){return!(!a.B[b]||!a.B[b].length)}f.kg=function(a,b){b=b||"defaultcontext";var c=[];z(a,function(a){this.B[a]?0>this.B[a].indexOf(b)&&this.B[a].push(b):(this.B[a]=[b],c.push(a))},this);0<c.length&&this.u("controlsdisabled",c)};f.Bh=function(a,b){b=b||"defaultcontext";var c=[];z(a,function(a){if(bh(this,a)){var e=this.B[a].indexOf(b);0<=e&&this.B[a].splice(e,1);0==this.B[a].length&&c.push(a)}},this);0<c.length&&this.u("controlsenabled",c)};
-f.vm=function(a,b,c){this.zh();this.Q=a;b&&z(b,function(a){this.L[a]=!0},this);c&&hx(this.k,a,c)};f.zh=function(){this.Q=null;this.L={};ix(this.k)};function OG(a){var b=a.getVideoData();return b&&b.Ma&&!Zl.test(b.Ma)?!a.a.Hh:a.a.zc}f.H=function(){gH(this);this.vj&&yf(this.vj);jf(0);Ug(Jb(this.P));this.P={};this.j=this.b=null;Ug(this.a,this.g);this.J=this.I=this.ja=this.V=this.Ud=null;I(this.da);dH.C.H.call(this)};pa("yt.player.Application",dH);function wH(a,b,c,d,e,g){var h={};b&&(h.v=b);c&&(h.list=c);d&&(h.url=d);a={name:a,locale:e,feature:g};for(var k in h)a[k]=h[k];h=S("/sharing_services",a);sa(h)};wp(Ap);wp(Et);n("yt.tracking.share")||pa("yt.tracking.share",wH);n("yt.net.ping")||pa("yt.net.ping.send",sa);n("yt.window.popup")||(pa("yt.window.popup",Rp),pa("yt.window.open",Qp));pa("yt.player.Application.create",function(a,b){eH[a]&&(eH[a].dispose(),eH[a]=null);var c=new dH(a,b);Sg(c,function(){eH[a]=null});eH[a]=c});})();
diff --git a/test/testdata/html5player-vfldJ8xgI.js b/test/testdata/html5player-vfldJ8xgI.js
deleted file mode 100644 (file)
index bd6c222..0000000
+++ /dev/null
@@ -1,890 +0,0 @@
-(function(){var f,aa=aa||{},l=this;function n(a,b){for(var c=a.split("."),d=b||l,e;e=c.shift();)if(null!=d[e])d=d[e];else return null;return d}function ba(){}function ca(a){a.getInstance=function(){return a.lq?a.lq:a.lq=new a}}
-function da(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}function q(a){return void 0!==a}function ea(a){return null!=a}function t(a){return"array"==da(a)}function fa(a){var b=da(a);return"array"==b||"object"==b&&"number"==typeof a.length}function u(a){return"string"==typeof a}function ga(a){return"number"==typeof a}function ha(a){return"function"==da(a)}function ia(a){var b=typeof a;return"object"==b&&null!=a||"function"==b}function ja(a){return a[ka]||(a[ka]=++la)}
-var ka="closure_uid_"+(1E9*Math.random()>>>0),la=0;function ma(a,b,c){return a.call.apply(a.bind,arguments)}function na(a,b,c){if(!a)throw 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)}}
-function v(a,b,c){v=Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?ma:na;return v.apply(null,arguments)}function oa(a,b){var c=Array.prototype.slice.call(arguments,1);return function(){var b=c.slice();b.push.apply(b,arguments);return a.apply(this,b)}}function w(a,b){for(var c in b)a[c]=b[c]}var x=Date.now||function(){return+new Date};
-function pa(a,b){var c=a.split("."),d=l;c[0]in d||!d.execScript||d.execScript("var "+c[0]);for(var e;c.length&&(e=c.shift());)c.length||void 0===b?d=d[e]?d[e]:d[e]={}:d[e]=b}function y(a,b){function c(){}c.prototype=b.prototype;a.C=b.prototype;a.prototype=new c;a.prototype.constructor=a}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 v.apply(null,c)}return v(this,a)};function qa(a){Error.captureStackTrace?Error.captureStackTrace(this,qa):this.stack=Error().stack||"";a&&(this.message=String(a))}y(qa,Error);qa.prototype.name="CustomError";var ra;function ta(a,b){for(var c=a.split("%s"),d="",e=Array.prototype.slice.call(arguments,1);e.length&&1<c.length;)d+=c.shift()+e.shift();return d+c.join("%s")}function ua(a){return decodeURIComponent(a.replace(/\+/g," "))}function va(a){if(!wa.test(a))return a;-1!=a.indexOf("&")&&(a=a.replace(xa,"&amp;"));-1!=a.indexOf("<")&&(a=a.replace(ya,"&lt;"));-1!=a.indexOf(">")&&(a=a.replace(za,"&gt;"));-1!=a.indexOf('"')&&(a=a.replace(Aa,"&quot;"));return a}var xa=/&/g,ya=/</g,za=/>/g,Aa=/\"/g,wa=/[&<>\"]/;
-function Ba(a,b){for(var c=0,d=String(a).replace(/^[\s\xa0]+|[\s\xa0]+$/g,"").split("."),e=String(b).replace(/^[\s\xa0]+|[\s\xa0]+$/g,"").split("."),g=Math.max(d.length,e.length),h=0;0==c&&h<g;h++){var k=d[h]||"",m=e[h]||"",p=RegExp("(\\d*)(\\D*)","g"),s=RegExp("(\\d*)(\\D*)","g");do{var r=p.exec(k)||["","",""],D=s.exec(m)||["","",""];if(0==r[0].length&&0==D[0].length)break;c=((0==r[1].length?0:parseInt(r[1],10))<(0==D[1].length?0:parseInt(D[1],10))?-1:(0==r[1].length?0:parseInt(r[1],10))>(0==D[1].length?
-0:parseInt(D[1],10))?1:0)||((0==r[2].length)<(0==D[2].length)?-1:(0==r[2].length)>(0==D[2].length)?1:0)||(r[2]<D[2]?-1:r[2]>D[2]?1:0)}while(0==c)}return c}function Ca(a){var b=Number(a);return 0==b&&/^[\s\xa0]*$/.test(a)?NaN:b}function Da(a){return String(a).replace(/\-([a-z])/g,function(a,c){return c.toUpperCase()})}
-function Ea(a){var b=u(void 0)?"undefined".replace(/([-()\[\]{}+?*.$\^|,:#<!\\])/g,"\\$1").replace(/\x08/g,"\\x08"):"\\s";return a.replace(RegExp("(^"+(b?"|["+b+"]+":"")+")([a-z])","g"),function(a,b,e){return b+e.toUpperCase()})};function Fa(){};function Ga(a){return a[a.length-1]}
-var Ha=Array.prototype,Ia=Ha.indexOf?function(a,b,c){return Ha.indexOf.call(a,b,c)}:function(a,b,c){c=null==c?0:0>c?Math.max(0,a.length+c):c;if(u(a))return u(b)&&1==b.length?a.indexOf(b,c):-1;for(;c<a.length;c++)if(c in a&&a[c]===b)return c;return-1},z=Ha.forEach?function(a,b,c){Ha.forEach.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)g in e&&b.call(c,e[g],g,a)},Ja=Ha.filter?function(a,b,c){return Ha.filter.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=[],g=
-0,h=u(a)?a.split(""):a,k=0;k<d;k++)if(k in h){var m=h[k];b.call(c,m,k,a)&&(e[g++]=m)}return e},Ka=Ha.map?function(a,b,c){return Ha.map.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=Array(d),g=u(a)?a.split(""):a,h=0;h<d;h++)h in g&&(e[h]=b.call(c,g[h],h,a));return e},La=Ha.some?function(a,b,c){return Ha.some.call(a,b,c)}:function(a,b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)if(g in e&&b.call(c,e[g],g,a))return!0;return!1},Ma=Ha.every?function(a,b,c){return Ha.every.call(a,b,c)}:function(a,
-b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)if(g in e&&!b.call(c,e[g],g,a))return!1;return!0};function Na(a,b){var c=0;z(a,function(a,e,g){b.call(void 0,a,e,g)&&++c},void 0);return c}function Oa(a,b,c){b=Pa(a,b,c);return 0>b?null:u(a)?a.charAt(b):a[b]}function Pa(a,b,c){for(var d=a.length,e=u(a)?a.split(""):a,g=0;g<d;g++)if(g in e&&b.call(c,e[g],g,a))return g;return-1}function Qa(a,b){var c=Ra(a,b,void 0);return 0>c?null:u(a)?a.charAt(c):a[c]}
-function Ra(a,b,c){for(var d=u(a)?a.split(""):a,e=a.length-1;0<=e;e--)if(e in d&&b.call(c,d[e],e,a))return e;return-1}function Sa(a,b){return 0<=Ia(a,b)}function Ta(a){return 0==a.length}function Ua(a){if(!t(a))for(var b=a.length-1;0<=b;b--)delete a[b];a.length=0}function Va(a,b){Sa(a,b)||a.push(b)}function Wa(a,b){var c=Ia(a,b),d;(d=0<=c)&&Xa(a,c);return d}function Xa(a,b){Ha.splice.call(a,b,1)}function Ya(a,b){var c=Pa(a,b,void 0);0<=c&&Xa(a,c)}
-function Za(a){return Ha.concat.apply(Ha,arguments)}function $a(a){var b=a.length;if(0<b){for(var c=Array(b),d=0;d<b;d++)c[d]=a[d];return c}return[]}function ab(a,b){for(var c=1;c<arguments.length;c++){var d=arguments[c],e;if(t(d)||(e=fa(d))&&Object.prototype.hasOwnProperty.call(d,"callee"))a.push.apply(a,d);else if(e)for(var g=a.length,h=d.length,k=0;k<h;k++)a[g+k]=d[k];else a.push(d)}}function bb(a,b,c,d){Ha.splice.apply(a,cb(arguments,1))}
-function cb(a,b,c){return 2>=arguments.length?Ha.slice.call(a,b):Ha.slice.call(a,b,c)}function db(a){for(var b={},c=0,d=0;d<a.length;){var e=a[d++],g=ia(e)?"o"+ja(e):(typeof e).charAt(0)+e;Object.prototype.hasOwnProperty.call(b,g)||(b[g]=!0,a[c++]=e)}a.length=c}function eb(a,b,c){for(var d=0,e=a.length,g;d<e;){var h=d+e>>1,k;k=b(c,a[h]);0<k?d=h+1:(e=h,g=!k)}return g?d:~d}function fb(a,b){Ha.sort.call(a,b||gb)}function hb(a,b){var c=gb;fb(a,function(a,e){return c(a[b],e[b])})}
-function ib(a,b,c){if(!fa(a)||!fa(b)||a.length!=b.length)return!1;var d=a.length;c=c||jb;for(var e=0;e<d;e++)if(!c(a[e],b[e]))return!1;return!0}function gb(a,b){return a>b?1:a<b?-1:0}function jb(a,b){return a===b}function kb(a,b,c){c=eb(a,c||gb,b);0>c&&bb(a,-(c+1),0,b)}function lb(a){for(var b=[],c=0;c<arguments.length;c++){var d=arguments[c];t(d)?b.push.apply(b,lb.apply(null,d)):b.push(d)}return b};function mb(a){a=String(a);if(/^\s*$/.test(a)?0:/^[\],:{}\s\u2028\u2029]*$/.test(a.replace(/\\["\\\/bfnrtu]/g,"@").replace(/"[^"\\\n\r\u2028\u2029\x00-\x08\x0a-\x1f]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:[\s\u2028\u2029]*\[)+/g,"")))try{return eval("("+a+")")}catch(b){}throw Error("Invalid JSON string: "+a);}function nb(a){return eval("("+a+")")}function ob(a){return pb(new qb(void 0),a)}function qb(a){this.a=a}
-function pb(a,b){var c=[];rb(a,b,c);return c.join("")}
-function rb(a,b,c){switch(typeof b){case "string":sb(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(null==b){c.push("null");break}if(t(b)){var d=b.length;c.push("[");for(var e="",g=0;g<d;g++)c.push(e),e=b[g],rb(a,a.a?a.a.call(b,String(g),e):e,c),e=",";c.push("]");break}c.push("{");d="";for(g in b)Object.prototype.hasOwnProperty.call(b,g)&&(e=b[g],"function"!=typeof e&&(c.push(d),sb(g,c),c.push(":"),
-rb(a,a.a?a.a.call(b,g,e):e,c),d=","));c.push("}");break;case "function":break;default:throw Error("Unknown type: "+typeof b);}}var tb={'"':'\\"',"\\":"\\\\","/":"\\/","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\x0B":"\\u000b"},ub=/\uffff/.test("\uffff")?/[\\\"\x00-\x1f\x7f-\uffff]/g:/[\\\"\x00-\x1f\x7f-\xff]/g;
-function sb(a,b){b.push('"',a.replace(ub,function(a){if(a in tb)return tb[a];var b=a.charCodeAt(0),e="\\u";16>b?e+="000":256>b?e+="00":4096>b&&(e+="0");return tb[a]=e+b.toString(16)}),'"')};function vb(a,b,c){return Math.min(Math.max(a,b),c)};function A(a,b){this.x=q(a)?a:0;this.y=q(b)?b:0}f=A.prototype;f.clone=function(){return new A(this.x,this.y)};function wb(a,b){var c=a.x-b.x,d=a.y-b.y;return Math.sqrt(c*c+d*d)}function xb(a,b){return new A(a.x-b.x,a.y-b.y)}f.ceil=function(){this.x=Math.ceil(this.x);this.y=Math.ceil(this.y);return this};f.floor=function(){this.x=Math.floor(this.x);this.y=Math.floor(this.y);return this};f.round=function(){this.x=Math.round(this.x);this.y=Math.round(this.y);return this};
-f.scale=function(a,b){var c=ga(b)?b:a;this.x*=a;this.y*=c;return this};function yb(a,b,c,d){this.top=a;this.right=b;this.bottom=c;this.left=d}f=yb.prototype;f.clone=function(){return new yb(this.top,this.right,this.bottom,this.left)};f.contains=function(a){return this&&a?a instanceof yb?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:!1};
-f.ceil=function(){this.top=Math.ceil(this.top);this.right=Math.ceil(this.right);this.bottom=Math.ceil(this.bottom);this.left=Math.ceil(this.left);return this};f.floor=function(){this.top=Math.floor(this.top);this.right=Math.floor(this.right);this.bottom=Math.floor(this.bottom);this.left=Math.floor(this.left);return this};f.round=function(){this.top=Math.round(this.top);this.right=Math.round(this.right);this.bottom=Math.round(this.bottom);this.left=Math.round(this.left);return this};
-f.scale=function(a,b){var c=ga(b)?b:a;this.left*=a;this.right*=a;this.top*=c;this.bottom*=c;return this};function B(a,b){this.width=a;this.height=b}function zb(a,b){return a==b?!0:a&&b?a.width==b.width&&a.height==b.height:!1}f=B.prototype;f.clone=function(){return new B(this.width,this.height)};function Ab(a){return a.width/a.height}f.isEmpty=function(){return!(this.width*this.height)};f.ceil=function(){this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};f.floor=function(){this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};
-f.round=function(){this.width=Math.round(this.width);this.height=Math.round(this.height);return this};f.scale=function(a,b){var c=ga(b)?b:a;this.width*=a;this.height*=c;return this};function Bb(a,b){return a.scale(Ab(a)>Ab(b)?b.width/a.width:b.height/a.height)};function Cb(a,b,c,d){this.left=a;this.top=b;this.width=c;this.height=d}f=Cb.prototype;f.clone=function(){return new Cb(this.left,this.top,this.width,this.height)};function Db(a){return new Cb(a.left,a.top,a.right-a.left,a.bottom-a.top)}f.contains=function(a){return a instanceof Cb?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};
-f.ceil=function(){this.left=Math.ceil(this.left);this.top=Math.ceil(this.top);this.width=Math.ceil(this.width);this.height=Math.ceil(this.height);return this};f.floor=function(){this.left=Math.floor(this.left);this.top=Math.floor(this.top);this.width=Math.floor(this.width);this.height=Math.floor(this.height);return this};f.round=function(){this.left=Math.round(this.left);this.top=Math.round(this.top);this.width=Math.round(this.width);this.height=Math.round(this.height);return this};
-f.scale=function(a,b){var c=ga(b)?b:a;this.left*=a;this.width*=a;this.top*=c;this.height*=c;return this};function Eb(a,b,c){for(var d in a)b.call(c,a[d],d,a)}function Fb(a,b){for(var c in a)if(!b.call(void 0,a[c],c,a))return!1;return!0}function Gb(a){var b=[],c=0,d;for(d in a)b[c++]=a[d];return b}function Hb(a){var b=[],c=0,d;for(d in a)b[c++]=d;return b}function Ib(a,b){for(var c in a)if(a[c]==b)return!0;return!1}function Jb(a,b){for(var c in a)if(b.call(void 0,a[c],c,a))return c}function Kb(a){for(var b in a)return!1;return!0}function Lb(a){var b={},c;for(c in a)b[c]=a[c];return b}
-function Mb(a){var b=da(a);if("object"==b||"array"==b){if(a.clone)return a.clone();var b="array"==b?[]:{},c;for(c in a)b[c]=Mb(a[c]);return b}return a}var Nb="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");function Ob(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 g=0;g<Nb.length;g++)c=Nb[g],Object.prototype.hasOwnProperty.call(d,c)&&(a[c]=d[c])}}
-function Pb(a){var b=arguments.length;if(1==b&&t(arguments[0]))return Pb.apply(null,arguments[0]);if(b%2)throw Error("Uneven number of arguments");for(var c={},d=0;d<b;d+=2)c[arguments[d]]=arguments[d+1];return c};function Qb(a){return function(){throw a;}};var Rb,Sb,Tb,Ub,Vb,Wb,Xb;function Yb(){return l.navigator?l.navigator.userAgent:null}function Zb(){return l.navigator}Vb=Ub=Tb=Sb=Rb=!1;var $b;if($b=Yb()){var ac=Zb();Rb=0==$b.lastIndexOf("Opera",0);Sb=!Rb&&(-1!=$b.indexOf("MSIE")||-1!=$b.indexOf("Trident"));Ub=(Tb=!Rb&&-1!=$b.indexOf("WebKit"))&&-1!=$b.indexOf("Mobile");Vb=!Rb&&!Tb&&!Sb&&"Gecko"==ac.product}var bc=Rb,C=Sb,cc=Vb,dc=Tb,ec=Ub,fc=Zb(),gc=fc&&fc.platform||"";Wb=-1!=gc.indexOf("Mac");Xb=-1!=gc.indexOf("Win");
-var hc=!!Zb()&&-1!=(Zb().appVersion||"").indexOf("X11");function ic(){var a=l.document;return a?a.documentMode:void 0}var jc;t:{var kc="",lc;if(bc&&l.opera)var mc=l.opera.version,kc="function"==typeof mc?mc():mc;else if(cc?lc=/rv\:([^\);]+)(\)|;)/:C?lc=/\b(?:MSIE|rv)[: ]([^\);]+)(\)|;)/:dc&&(lc=/WebKit\/(\S+)/),lc)var nc=lc.exec(Yb()),kc=nc?nc[1]:"";if(C){var oc=ic();if(oc>parseFloat(kc)){jc=String(oc);break t}}jc=kc}var pc=jc,qc={};function rc(a){return qc[a]||(qc[a]=0<=Ba(pc,a))}
-function sc(a){return C&&tc>=a}var uc=l.document,tc=uc&&C?ic()||("CSS1Compat"==uc.compatMode?parseInt(pc,10):5):void 0;var vc=!C||sc(9),wc=!cc&&!C||C&&sc(9)||cc&&rc("1.9.1"),xc=C&&!rc("9"),yc=C||bc||dc;function zc(a){a=a.className;return u(a)&&a.match(/\S+/g)||[]}function Ac(a,b){for(var c=zc(a),d=cb(arguments,1),e=c.length+d.length,g=c,h=0;h<d.length;h++)Sa(g,d[h])||g.push(d[h]);g=c.join(" ");a.className=g;return c.length==e}function Bc(a,b){var c=zc(a),d=cb(arguments,1),c=Cc(c,d).join(" ");a.className=c}function Cc(a,b){return Ja(a,function(a){return!Sa(b,a)})}function Dc(a,b){return Sa(zc(a),b)}function Ec(a,b,c){c?Ac(a,b):Bc(a,b)}function Fc(a,b){var c=!Dc(a,b);Ec(a,b,c)};function Gc(a){return a?new Hc(Ic(a)):ra||(ra=new Hc)}function Jc(a){return u(a)?document.getElementById(a):a}function Kc(a,b){var c=b||document;return c.querySelectorAll&&c.querySelector?c.querySelectorAll("."+a):c.getElementsByClassName?c.getElementsByClassName(a):Lc("*",a,b)}function E(a,b){var c=b||document,d=null;return(d=c.querySelectorAll&&c.querySelector?c.querySelector("."+a):Kc(a,b)[0])||null}
-function Lc(a,b,c){var d=document;c=c||d;a=a&&"*"!=a?a.toUpperCase():"";if(c.querySelectorAll&&c.querySelector&&(a||b))return c.querySelectorAll(a+(b?"."+b:""));if(b&&c.getElementsByClassName){c=c.getElementsByClassName(b);if(a){for(var d={},e=0,g=0,h;h=c[g];g++)a==h.nodeName&&(d[e++]=h);d.length=e;return d}return c}c=c.getElementsByTagName(a||"*");if(b){d={};for(g=e=0;h=c[g];g++)a=h.className,"function"==typeof a.split&&Sa(a.split(/\s+/),b)&&(d[e++]=h);d.length=e;return d}return c}
-function Mc(a,b){Eb(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)||0==d.lastIndexOf("data-",0)?a.setAttribute(d,b):a[d]=b})}var Nc={cellpadding:"cellPadding",cellspacing:"cellSpacing",colspan:"colSpan",frameborder:"frameBorder",height:"height",maxlength:"maxLength",role:"role",rowspan:"rowSpan",type:"type",usemap:"useMap",valign:"vAlign",width:"width"};
-function Oc(a){a=a.document;a="CSS1Compat"==a.compatMode?a.documentElement:a.body;return new B(a.clientWidth,a.clientHeight)}function Pc(a){var b=Qc(a);a=a.parentWindow||a.defaultView;return C&&rc("10")&&a.pageYOffset!=b.scrollTop?new A(b.scrollLeft,b.scrollTop):new A(a.pageXOffset||b.scrollLeft,a.pageYOffset||b.scrollTop)}function Qc(a){return dc||"CSS1Compat"!=a.compatMode?a.body||a.documentElement:a.documentElement}
-function Rc(a,b,c){var d=arguments,e=document,g=d[0],h=d[1];if(!vc&&h&&(h.name||h.type)){g=["<",g];h.name&&g.push(' name="',va(h.name),'"');if(h.type){g.push(' type="',va(h.type),'"');var k={};Ob(k,h);delete k.type;h=k}g.push(">");g=g.join("")}g=e.createElement(g);h&&(u(h)?g.className=h:t(h)?Ac.apply(null,[g].concat(h)):Mc(g,h));2<d.length&&Sc(e,g,d,2);return g}
-function Sc(a,b,c,d){function e(c){c&&b.appendChild(u(c)?a.createTextNode(c):c)}for(;d<c.length;d++){var g=c[d];!fa(g)||ia(g)&&0<g.nodeType?e(g):z(Tc(g)?$a(g):g,e)}}function Uc(a){return document.createElement(a)}function Vc(a){return document.createTextNode(String(a))}function Wc(a,b){Sc(Ic(a),a,arguments,1)}function Xc(a){for(var b;b=a.firstChild;)a.removeChild(b)}function F(a){a&&a.parentNode&&a.parentNode.removeChild(a)}
-function Yc(a){if(void 0!=a.firstElementChild)a=a.firstElementChild;else for(a=a.firstChild;a&&1!=a.nodeType;)a=a.nextSibling;return a}function Zc(a){if(yc&&!(C&&rc("9")&&!rc("10")&&l.SVGElement&&a instanceof l.SVGElement))return a.parentElement;a=a.parentNode;return ia(a)&&1==a.nodeType?a:null}
-function $c(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}function Ic(a){return 9==a.nodeType?a:a.ownerDocument||a.document}
-function ad(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 Xc(a),a.appendChild(Ic(a).createTextNode(String(b)))}function bd(a,b){var c=[];return cd(a,b,c,!0)?c[0]:void 0}function cd(a,b,c,d){if(null!=a)for(a=a.firstChild;a;){if(b(a)&&(c.push(a),d)||cd(a,b,c,d))return!0;a=a.nextSibling}return!1}var dd={SCRIPT:1,STYLE:1,HEAD:1,IFRAME:1,OBJECT:1},ed={IMG:" ",BR:"\n"};
-function fd(a,b,c){if(!(a.nodeName in dd))if(3==a.nodeType)c?b.push(String(a.nodeValue).replace(/(\r\n|\r|\n)/g,"")):b.push(a.nodeValue);else if(a.nodeName in ed)b.push(ed[a.nodeName]);else for(a=a.firstChild;a;)fd(a,b,c),a=a.nextSibling}function Tc(a){if(a&&"number"==typeof a.length){if(ia(a))return"function"==typeof a.item||"string"==typeof a.item;if(ha(a))return"function"==typeof a.item}return!1}function gd(a,b){return b?hd(a,function(a){return!b||Dc(a,b)},!0):null}
-function hd(a,b,c,d){c||(a=a.parentNode);c=null==d;for(var e=0;a&&(c||e<=d);){if(b(a))return a;a=a.parentNode;e++}return null}function Hc(a){this.a=a||l.document||document}f=Hc.prototype;f.N=function(a){return u(a)?this.a.getElementById(a):a};f.createElement=function(a){return this.a.createElement(a)};function id(a){return"CSS1Compat"==a.a.compatMode}function jd(a){return Pc(a.a)}f.appendChild=function(a,b){a.appendChild(b)};f.append=Wc;
-f.getChildren=function(a){return wc&&void 0!=a.children?a.children:Ja(a.childNodes,function(a){return 1==a.nodeType})};f.contains=$c;function kd(a,b,c){u(b)?ld(a,c,b):Eb(b,oa(ld,a))}function ld(a,b,c){var d;t:if(d=Da(c),void 0===a.style[d]&&(c=(dc?"Webkit":cc?"Moz":C?"ms":bc?"O":null)+Ea(c),void 0!==a.style[c])){d=c;break t}d&&(a.style[d]=b)}function md(a,b){var c=Ic(a);return c.defaultView&&c.defaultView.getComputedStyle&&(c=c.defaultView.getComputedStyle(a,null))?c[b]||c.getPropertyValue(b)||"":""}function nd(a,b){return md(a,b)||(a.currentStyle?a.currentStyle[b]:null)||a.style&&a.style[b]}
-function od(a,b,c){var d,e=cc&&(Wb||hc)&&rc("1.9");b instanceof A?(d=b.x,b=b.y):(d=b,b=c);a.style.left=pd(d,e);a.style.top=pd(b,e)}function qd(a){var b;try{b=a.getBoundingClientRect()}catch(c){return{left:0,top:0,right:0,bottom:0}}C&&a.ownerDocument.body&&(a=a.ownerDocument,b.left-=a.documentElement.clientLeft+a.body.clientLeft,b.top-=a.documentElement.clientTop+a.body.clientTop);return b}
-function rd(a){if(C&&!sc(8))return a.offsetParent;var b=Ic(a),c=nd(a,"position"),d="fixed"==c||"absolute"==c;for(a=a.parentNode;a&&a!=b;a=a.parentNode)if(c=nd(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 null}
-function sd(a){for(var b=new yb(0,Infinity,Infinity,0),c=Gc(a),d=c.a.body,e=c.a.documentElement,g=Qc(c.a);a=rd(a);)if(!(C&&0==a.clientWidth||dc&&0==a.clientHeight&&a==d||a==d||a==e||"visible"==nd(a,"overflow"))){var h=td(a),k;k=a;if(cc&&!rc("1.9")){var m=parseFloat(md(k,"borderLeftWidth"));if(ud(k))var p=k.offsetWidth-k.clientWidth-m-parseFloat(md(k,"borderRightWidth")),m=m+p;k=new A(m,parseFloat(md(k,"borderTopWidth")))}else k=new A(k.clientLeft,k.clientTop);h.x+=k.x;h.y+=k.y;b.top=Math.max(b.top,
-h.y);b.right=Math.min(b.right,h.x+a.clientWidth);b.bottom=Math.min(b.bottom,h.y+a.clientHeight);b.left=Math.max(b.left,h.x)}d=g.scrollLeft;g=g.scrollTop;b.left=Math.max(b.left,d);b.top=Math.max(b.top,g);c=Oc(c.a.parentWindow||c.a.defaultView||window);b.right=Math.min(b.right,d+c.width);b.bottom=Math.min(b.bottom,g+c.height);return 0<=b.top&&0<=b.left&&b.bottom>b.top&&b.right>b.left?b:null}
-function td(a){var b,c=Ic(a),d=nd(a,"position"),e=cc&&c.getBoxObjectFor&&!a.getBoundingClientRect&&"absolute"==d&&(b=c.getBoxObjectFor(a))&&(0>b.screenX||0>b.screenY),g=new A(0,0),h;b=c?Ic(c):document;h=!C||sc(9)||id(Gc(b))?b.documentElement:b.body;if(a==h)return g;if(a.getBoundingClientRect)b=qd(a),a=jd(Gc(c)),g.x=b.left+a.x,g.y=b.top+a.y;else if(c.getBoxObjectFor&&!e)b=c.getBoxObjectFor(a),a=c.getBoxObjectFor(h),g.x=b.screenX-a.screenX,g.y=b.screenY-a.screenY;else{b=a;do{g.x+=b.offsetLeft;g.y+=
-b.offsetTop;b!=a&&(g.x+=b.clientLeft||0,g.y+=b.clientTop||0);if(dc&&"fixed"==nd(b,"position")){g.x+=c.body.scrollLeft;g.y+=c.body.scrollTop;break}b=b.offsetParent}while(b&&b!=a);if(bc||dc&&"absolute"==d)g.y-=c.body.offsetTop;for(b=a;(b=rd(b))&&b!=c.body&&b!=h;)g.x-=b.scrollLeft,bc&&"TR"==b.tagName||(g.y-=b.scrollTop)}return g}function vd(a,b){var c=wd(a),d=wd(b);return new A(c.x-d.x,c.y-d.y)}
-function xd(a){var b;if(a.getBoundingClientRect)b=qd(a),b=new A(b.left,b.top);else{b=jd(Gc(a));var c=td(a);b=new A(c.x-b.x,c.y-b.y)}if(cc&&!rc(12)){var d;C?d="-ms-transform":dc?d="-webkit-transform":bc?d="-o-transform":cc&&(d="-moz-transform");var e;d&&(e=nd(a,d));e||(e=nd(a,"transform"));a=e?(a=e.match(yd))?new A(parseFloat(a[1]),parseFloat(a[2])):new A(0,0):new A(0,0);a=new A(b.x+a.x,b.y+a.y)}else a=b;return a}
-function wd(a){if(1==a.nodeType)return xd(a);var b=ha(a.Ux),c=a;a.targetTouches?c=a.targetTouches[0]:b&&a.re.targetTouches&&(c=a.re.targetTouches[0]);return new A(c.clientX,c.clientY)}function zd(a,b,c){if(b instanceof B)c=b.height,b=b.width;else if(void 0==c)throw Error("missing height argument");Ad(a,b);a.style.height=pd(c,!0)}function pd(a,b){"number"==typeof a&&(a=(b?Math.round(a):a)+"px");return a}function Ad(a,b){a.style.width=pd(b,!0)}
-function Bd(a){var b=Cd;if("none"!=nd(a,"display"))return b(a);var c=a.style,d=c.display,e=c.visibility,g=c.position;c.visibility="hidden";c.position="absolute";c.display="inline";a=b(a);c.display=d;c.position=g;c.visibility=e;return a}function Cd(a){var b=a.offsetWidth,c=a.offsetHeight,d=dc&&!b&&!c;return q(b)&&!d||!a.getBoundingClientRect?new B(b,c):(a=qd(a),new B(a.right-a.left,a.bottom-a.top))}function Dd(a){var b=td(a);a=Bd(a);return new Cb(b.x,b.y,a.width,a.height)}
-function Ed(a,b){var c=a.style;"opacity"in c?c.opacity=b:"MozOpacity"in c?c.MozOpacity=b:"filter"in c&&(c.filter=""===b?"":"alpha(opacity="+100*b+")")}function ud(a){return"rtl"==nd(a,"direction")}
-function Fd(a){var b=Ic(a),c=C&&a.currentStyle;if(c&&id(Gc(b))&&"auto"!=c.width&&"auto"!=c.height&&!c.boxSizing)return b=Gd(a,c.width,"width","pixelWidth"),a=Gd(a,c.height,"height","pixelHeight"),new B(b,a);c=new B(a.offsetWidth,a.offsetHeight);b=Hd(a);a=Id(a);return new B(c.width-a.left-b.left-b.right-a.right,c.height-a.top-b.top-b.bottom-a.bottom)}
-function Gd(a,b,c,d){if(/^\d+px?$/.test(b))return parseInt(b,10);var e=a.style[c],g=a.runtimeStyle[c];a.runtimeStyle[c]=a.currentStyle[c];a.style[c]=b;b=a.style[d];a.style[c]=e;a.runtimeStyle[c]=g;return b}function Jd(a,b){var c=a.currentStyle?a.currentStyle[b]:null;return c?Gd(a,c,"left","pixelLeft"):0}
-function Hd(a){if(C){var b=Jd(a,"paddingLeft"),c=Jd(a,"paddingRight"),d=Jd(a,"paddingTop");a=Jd(a,"paddingBottom");return new yb(d,c,a,b)}b=md(a,"paddingLeft");c=md(a,"paddingRight");d=md(a,"paddingTop");a=md(a,"paddingBottom");return new yb(parseFloat(d),parseFloat(c),parseFloat(a),parseFloat(b))}var Kd={thin:2,medium:4,thick:6};
-function Ld(a,b){if("none"==(a.currentStyle?a.currentStyle[b+"Style"]:null))return 0;var c=a.currentStyle?a.currentStyle[b+"Width"]:null;return c in Kd?Kd[c]:Gd(a,c,"left","pixelLeft")}
-function Id(a){if(C&&!sc(9)){var b=Ld(a,"borderLeft"),c=Ld(a,"borderRight"),d=Ld(a,"borderTop");a=Ld(a,"borderBottom");return new yb(d,c,a,b)}b=md(a,"borderLeftWidth");c=md(a,"borderRightWidth");d=md(a,"borderTopWidth");a=md(a,"borderBottomWidth");return new yb(parseFloat(d),parseFloat(c),parseFloat(a),parseFloat(b))}var Md=/[^\d]+$/,Nd={cm:1,"in":1,mm:1,pc:1,pt:1},Od={em:1,ex:1};
-function Pd(a){var b=nd(a,"fontSize"),c;c=(c=b.match(Md))&&c[0]||null;if(b&&"px"==c)return parseInt(b,10);if(C){if(c in Nd)return Gd(a,b,"left","pixelLeft");if(a.parentNode&&1==a.parentNode.nodeType&&c in Od)return a=a.parentNode,c=nd(a,"fontSize"),Gd(a,b==c?"1em":b,"left","pixelLeft")}c=Rc("span",{style:"visibility:hidden;position:absolute;line-height:0;padding:0;margin:0;border:0;height:1em;"});a.appendChild(c);b=c.offsetHeight;F(c);return b}var yd=/matrix\([0-9\.\-]+, [0-9\.\-]+, [0-9\.\-]+, [0-9\.\-]+, ([0-9\.\-]+)p?x?, ([0-9\.\-]+)p?x?\)/;var Qd="StopIteration"in l?l.StopIteration:Error("StopIteration");function Rd(){}Rd.prototype.next=function(){throw Qd;};Rd.prototype.Nd=function(){return this};function Sd(a){if(a instanceof Rd)return a;if("function"==typeof a.Nd)return a.Nd(!1);if(fa(a)){var b=0,c=new Rd;c.next=function(){for(;;){if(b>=a.length)throw Qd;if(b in a)return a[b++];b++}};return c}throw Error("Not implemented");}
-function Td(a,b,c){if(fa(a))try{z(a,b,c)}catch(d){if(d!==Qd)throw d;}else{a=Sd(a);try{for(;;)b.call(c,a.next(),void 0,a)}catch(e){if(e!==Qd)throw e;}}}function Ud(a){if(fa(a))return $a(a);a=Sd(a);var b=[];Td(a,function(a){b.push(a)});return b};function Vd(a,b){this.b={};this.a=[];this.g=this.R=0;var c=arguments.length;if(1<c){if(c%2)throw Error("Uneven number of arguments");for(var d=0;d<c;d+=2)this.set(arguments[d],arguments[d+1])}else if(a){a instanceof Vd?(c=a.uc(),d=a.jc()):(c=Hb(a),d=Gb(a));for(var e=0;e<c.length;e++)this.set(c[e],d[e])}}f=Vd.prototype;f.hb=function(){return this.R};f.jc=function(){Wd(this);for(var a=[],b=0;b<this.a.length;b++)a.push(this.b[this.a[b]]);return a};f.uc=function(){Wd(this);return this.a.concat()};
-f.equals=function(a,b){if(this===a)return!0;if(this.R!=a.hb())return!1;var c=b||Xd;Wd(this);for(var d,e=0;d=this.a[e];e++)if(!c(this.get(d),a.get(d)))return!1;return!0};function Xd(a,b){return a===b}f.isEmpty=function(){return 0==this.R};f.clear=function(){this.b={};this.g=this.R=this.a.length=0};f.remove=function(a){return Yd(this.b,a)?(delete this.b[a],this.R--,this.g++,this.a.length>2*this.R&&Wd(this),!0):!1};
-function Wd(a){if(a.R!=a.a.length){for(var b=0,c=0;b<a.a.length;){var d=a.a[b];Yd(a.b,d)&&(a.a[c++]=d);b++}a.a.length=c}if(a.R!=a.a.length){for(var e={},c=b=0;b<a.a.length;)d=a.a[b],Yd(e,d)||(a.a[c++]=d,e[d]=1),b++;a.a.length=c}}f.get=function(a,b){return Yd(this.b,a)?this.b[a]:b};f.set=function(a,b){Yd(this.b,a)||(this.R++,this.a.push(a),this.g++);this.b[a]=b};f.clone=function(){return new Vd(this)};
-f.Nd=function(a){Wd(this);var b=0,c=this.a,d=this.b,e=this.g,g=this,h=new Rd;h.next=function(){for(;;){if(e!=g.g)throw Error("The map has changed since the iterator was created");if(b>=c.length)throw Qd;var h=c[b++];return a?h:d[h]}};return h};function Yd(a,b){return Object.prototype.hasOwnProperty.call(a,b)};function Zd(a){if("function"==typeof a.jc)return a.jc();if(u(a))return a.split("");if(fa(a)){for(var b=[],c=a.length,d=0;d<c;d++)b.push(a[d]);return b}return Gb(a)}function $d(a,b,c){if("function"==typeof a.forEach)a.forEach(b,c);else if(fa(a)||u(a))z(a,b,c);else{var d;if("function"==typeof a.uc)d=a.uc();else if("function"!=typeof a.jc)if(fa(a)||u(a)){d=[];for(var e=a.length,g=0;g<e;g++)d.push(g)}else d=Hb(a);else d=void 0;for(var e=Zd(a),g=e.length,h=0;h<g;h++)b.call(c,e[h],d&&d[h],a)}};function ae(a,b,c,d,e){var g="";a&&(g+=a+":");c&&(g+="//",b&&(g+=b+"@"),g+=c,d&&(g+=":"+d));e&&(g+=e);return g}var be=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([^/#?]*?)(?::([0-9]+))?(?=[/#?]|$))?([^?#]+)?(?:\\?([^#]*))?(?:#(.*))?$");function ce(a){if(de){de=!1;var b=l.location;if(b){var c=b.href;if(c&&(c=ee(c))&&c!=b.hostname)throw de=!0,Error();}}return a.match(be)}var de=dc;function ee(a){return(a=ce(a)[3]||null)&&decodeURIComponent(a)}
-function fe(a){return(a=ce(a)[5]||null)&&decodeURIComponent(a)}function ge(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]=void 0)}return a.join("")}function he(a,b,c){if(t(b))for(var d=0;d<b.length;d++)he(a,String(b[d]),c);else null!=b&&c.push("&",a,""===b?"":"=",encodeURIComponent(String(b)))}function ie(a,b,c){Math.max(b.length-(c||0),0);for(c=c||0;c<b.length;c+=2)he(b[c],b[c+1],a);return a}
-function je(a,b){for(var c in b)he(c,b[c],a);return a}function ke(a,b){return ge(2==arguments.length?ie([a],arguments[1],0):ie([a],arguments,1))}function le(a,b,c){a=[a,"&",b];null!=c&&a.push("=",encodeURIComponent(String(c)));return ge(a)}function me(a,b,c,d){for(var e=c.length;0<=(b=a.indexOf(c,b))&&b<d;){var g=a.charCodeAt(b-1);if(38==g||63==g)if(g=a.charCodeAt(b+e),!g||61==g||38==g||35==g)return b;b+=e+1}return-1}var ne=/#|$/,oe=/[?&]($|#)/;
-function pe(a,b){for(var c=a.search(ne),d=0,e,g=[];0<=(e=me(a,d,b,c));)g.push(a.substring(d,e)),d=Math.min(a.indexOf("&",e)+1||c,c);g.push(a.substr(d));return g.join("").replace(oe,"$1")};function qe(a,b){var c;if(a instanceof qe)this.ef=q(b)?b:a.ef,re(this,a.Uf),this.Si=a.Si,se(this,a.Se),te(this,a.rh),this.sh=a.sh,ue(this,a.a.clone()),ve(this,a.Cl);else if(a&&(c=ce(String(a)))){this.ef=!!b;re(this,c[1]||"",!0);var d=c[2]||"";this.Si=d?decodeURIComponent(d):"";se(this,c[3]||"",!0);te(this,c[4]);this.sh=(d=c[5]||"")?decodeURIComponent(d):"";ue(this,c[6]||"",!0);ve(this,c[7]||"",!0)}else this.ef=!!b,this.a=new we(null,0,this.ef)}f=qe.prototype;f.Uf="";f.Si="";f.Se="";f.rh=null;
-f.sh="";f.Cl="";f.ef=!1;f.toString=function(){var a=[],b=this.Uf;b&&a.push(xe(b,ye),":");if(b=this.Se){a.push("//");var c=this.Si;c&&a.push(xe(c,ye),"@");a.push(encodeURIComponent(String(b)));b=this.rh;null!=b&&a.push(":",String(b))}if(b=this.sh)this.Se&&"/"!=b.charAt(0)&&a.push("/"),a.push(xe(b,"/"==b.charAt(0)?ze:Ae));(b=this.a.toString())&&a.push("?",b);(b=this.Cl)&&a.push("#",xe(b,Be));return a.join("")};f.clone=function(){return new qe(this)};
-function re(a,b,c){a.Uf=c?b?decodeURIComponent(b):"":b;a.Uf&&(a.Uf=a.Uf.replace(/:$/,""))}function se(a,b,c){a.Se=c?b?decodeURIComponent(b):"":b}function te(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.rh=b}else a.rh=null}function ue(a,b,c){b instanceof we?(a.a=b,Ce(a.a,a.ef)):(c||(b=xe(b,De)),a.a=new we(b,0,a.ef))}function Ee(a,b,c){a.a.set(b,c)}function Fe(a,b,c){t(c)||(c=[String(c)]);Ge(a.a,b,c)}function ve(a,b,c){a.Cl=c?b?decodeURIComponent(b):"":b;return a}
-function He(a){Ee(a,"zx",Math.floor(2147483648*Math.random()).toString(36)+Math.abs(Math.floor(2147483648*Math.random())^x()).toString(36));return a}function Ie(a){return a instanceof qe?a.clone():new qe(a,void 0)}function Je(a,b,c,d){var e=new qe(null,void 0);a&&re(e,a);b&&se(e,b);c&&te(e,c);d&&(e.sh=d);return e}function xe(a,b){return u(a)?encodeURI(a).replace(b,Ke):null}function Ke(a){a=a.charCodeAt(0);return"%"+(a>>4&15).toString(16)+(a&15).toString(16)}
-var ye=/[#\/\?@]/g,Ae=/[\#\?:]/g,ze=/[\#\?]/g,De=/[\#\?@]/g,Be=/#/g;function we(a,b,c){this.a=a||null;this.b=!!c}function Le(a){if(!a.Ja&&(a.Ja=new Vd,a.R=0,a.a))for(var b=a.a.split("&"),c=0;c<b.length;c++){var d=b[c].indexOf("="),e=null,g=null;0<=d?(e=b[c].substring(0,d),g=b[c].substring(d+1)):e=b[c];e=ua(e);e=Me(a,e);a.add(e,g?ua(g):"")}}f=we.prototype;f.Ja=null;f.R=null;f.hb=function(){Le(this);return this.R};
-f.add=function(a,b){Le(this);this.a=null;a=Me(this,a);var c=this.Ja.get(a);c||this.Ja.set(a,c=[]);c.push(b);this.R++;return this};f.remove=function(a){Le(this);a=Me(this,a);return Yd(this.Ja.b,a)?(this.a=null,this.R-=this.Ja.get(a).length,this.Ja.remove(a)):!1};f.clear=function(){this.Ja=this.a=null;this.R=0};f.isEmpty=function(){Le(this);return 0==this.R};function Ne(a,b){Le(a);b=Me(a,b);return Yd(a.Ja.b,b)}
-f.uc=function(){Le(this);for(var a=this.Ja.jc(),b=this.Ja.uc(),c=[],d=0;d<b.length;d++)for(var e=a[d],g=0;g<e.length;g++)c.push(b[d]);return c};f.jc=function(a){Le(this);var b=[];if(u(a))Ne(this,a)&&(b=Za(b,this.Ja.get(Me(this,a))));else{a=this.Ja.jc();for(var c=0;c<a.length;c++)b=Za(b,a[c])}return b};f.set=function(a,b){Le(this);this.a=null;a=Me(this,a);Ne(this,a)&&(this.R-=this.Ja.get(a).length);this.Ja.set(a,[b]);this.R++;return this};
-f.get=function(a,b){var c=a?this.jc(a):[];return 0<c.length?String(c[0]):b};function Ge(a,b,c){a.remove(b);0<c.length&&(a.a=null,a.Ja.set(Me(a,b),$a(c)),a.R+=c.length)}f.toString=function(){if(this.a)return this.a;if(!this.Ja)return"";for(var a=[],b=this.Ja.uc(),c=0;c<b.length;c++)for(var d=b[c],e=encodeURIComponent(String(d)),d=this.jc(d),g=0;g<d.length;g++){var h=e;""!==d[g]&&(h+="="+encodeURIComponent(String(d[g])));a.push(h)}return this.a=a.join("&")};
-f.clone=function(){var a=new we;a.a=this.a;this.Ja&&(a.Ja=this.Ja.clone(),a.R=this.R);return a};function Me(a,b){var c=String(b);a.b&&(c=c.toLowerCase());return c}function Ce(a,b){b&&!a.b&&(Le(a),a.a=null,$d(a.Ja,function(a,b){var e=b.toLowerCase();b!=e&&(this.remove(b),Ge(this,e,a))},a));a.b=b};function Oe(a,b,c){a.dataset?a.dataset[Pe(b)]=c:a.setAttribute("data-"+b,c)}function G(a,b){return a.dataset?a.dataset[Pe(b)]:a.getAttribute("data-"+b)}var Qe={};function Pe(a){return Qe[a]||(Qe[a]=String(a).replace(/\-([a-z])/g,function(a,c){return c.toUpperCase()}))};var Re=n("yt.dom.getNextId_");if(!Re){Re=function(){return++Se};pa("yt.dom.getNextId_",Re);var Se=0}function Te(a,b){a=Jc(a);b=Jc(b);return!!hd(a,function(a){return a===b},!0,void 0)}function Ue(a,b){var c=Lc(a,null,b);return c.length?c[0]:null}function Ve(a,b){if(a in b)return b[a];var c=a.charAt(0).toUpperCase()+a.substr(1);if("moz"+c in b)return b["moz"+c];if("ms"+c in b)return b["ms"+c];if("o"+c in b)return b["o"+c];if("webkit"+c in b)return b["webkit"+c]}
-function We(a,b){var c;La(a,function(a){c=Ve(a,b);return!!c});return c}function Xe(a,b){return"on"+a in b?a:"onmoz"+a in b?"moz"+a:"onms"+a in b?"ms"+a:"ono"+a in b?"o"+a:"onwebkit"+a in b?"webkit"+a:null};var Ye=window.yt&&window.yt.config_||{};pa("yt.config_",Ye);var Ze=window.yt&&window.yt.tokens_||{};pa("yt.tokens_",Ze);var $e=window.yt&&window.yt.msgs_||{};pa("yt.msgs_",$e);function af(a){bf(Ye,arguments)}function cf(a,b){return a in Ye?Ye[a]:b}function df(a){bf(Ze,arguments)}function ef(a){return a in Ze?Ze[a]:void 0}function H(a,b){ha(a)&&(a=ff(a));return window.setTimeout(a,b)}function gf(a,b){ha(a)&&(a=ff(a));return window.setInterval(a,b)}function I(a){window.clearTimeout(a)}
-function hf(a){window.clearInterval(a)}function ff(a){return a&&window.yterr?function(){try{return a.apply(this,arguments)}catch(b){throw jf(b),b;}}:a}function jf(a){if(window&&window.yterr){var b=n("yt.www.errors.log");b?b(a):(b=cf("ERRORS")||[],b.push(a),af("ERRORS",b))}}function kf(a){bf($e,arguments)}function lf(a,b,c){var d=b||{};if(a=a in $e?$e[a]:c)for(var e in d)a=a.replace(RegExp("\\$"+e,"gi"),function(){return d[e]});return a}function mf(a,b){return nf(a in $e?$e[a]:{},b)}
-function nf(a,b){var c=cf("I18N_PLURAL_RULES")||function(a){return 1==a?"one":"other"};return(c=a["case"+b]||a[c(b)])?c.replace("#",b.toString()):b+""}function bf(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]}};function of(a){if(a=a||window.event){for(var b in a)b in pf||(this[b]=a[b]);this.scale=a.scale;this.rotation=a.rotation;this.ld=a;(b=a.target||a.srcElement)&&3==b.nodeType&&(b=b.parentNode);this.target=b;if(b=a.relatedTarget)try{b=b.nodeName&&b}catch(c){b=null}else"mouseover"==this.type?b=a.fromElement:"mouseout"==this.type&&(b=a.toElement);this.relatedTarget=b;this.clientX=void 0!=a.clientX?a.clientX:a.pageX;this.clientY=void 0!=a.clientY?a.clientY:a.pageY;if(document.body&&document.documentElement){b=
-document.body.scrollLeft+document.documentElement.scrollLeft;var d=document.body.scrollTop+document.documentElement.scrollTop;this.pageX=void 0!=a.pageX?a.pageX:a.clientX+b;this.pageY=void 0!=a.pageY?a.pageY:a.clientY+d}this.keyCode=a.keyCode?a.keyCode:a.which;this.charCode=a.charCode||("keypress"==this.type?this.keyCode:0);this.altKey=a.altKey;this.ctrlKey=a.ctrlKey;this.shiftKey=a.shiftKey;"MozMousePixelScroll"==this.type?(this.wheelDeltaX=a.axis==a.HORIZONTAL_AXIS?a.detail:0,this.wheelDeltaY=a.axis==
-a.HORIZONTAL_AXIS?0:a.detail):window.opera?(this.wheelDeltaX=0,this.wheelDeltaY=a.detail):0==a.wheelDelta%120?"WebkitTransform"in document.documentElement.style?window.chrome&&0==navigator.platform.indexOf("Mac")?(this.wheelDeltaX=a.wheelDeltaX/-30,this.wheelDeltaY=a.wheelDeltaY/-30):(this.wheelDeltaX=a.wheelDeltaX/-1.2,this.wheelDeltaY=a.wheelDeltaY/-1.2):(this.wheelDeltaX=0,this.wheelDeltaY=a.wheelDelta/-1.6):(this.wheelDeltaX=a.wheelDeltaX/-3,this.wheelDeltaY=a.wheelDeltaY/-3)}}f=of.prototype;
-f.ld=null;f.type="";f.target=null;f.relatedTarget=null;f.currentTarget=null;f.data=null;f.source=null;f.state=null;f.keyCode=0;f.charCode=0;f.altKey=!1;f.ctrlKey=!1;f.shiftKey=!1;f.clientX=0;f.clientY=0;f.pageX=0;f.pageY=0;f.wheelDeltaX=0;f.wheelDeltaY=0;f.rotation=0;f.scale=1;f.preventDefault=function(){this.ld.returnValue=!1;this.ld.preventDefault&&this.ld.preventDefault()};f.stopPropagation=function(){this.ld.cancelBubble=!0;this.ld.stopPropagation&&this.ld.stopPropagation()};
-f.stopImmediatePropagation=function(){this.ld.cancelBubble=!0;this.ld.stopImmediatePropagation&&this.ld.stopImmediatePropagation()};var pf={stopImmediatePropagation:1,stopPropagation:1,preventMouseEvent:1,preventManipulation:1,preventDefault:1,layerX:1,layerY:1,scale:1,rotation:1};var qf=n("yt.events.listeners_")||{};pa("yt.events.listeners_",qf);var rf=n("yt.events.counter_")||{count:0};pa("yt.events.counter_",rf);function sf(a,b,c,d){return Jb(qf,function(e){return e[0]==a&&e[1]==b&&e[2]==c&&e[4]==!!d})}
-function J(a,b,c,d){if(!a||!a.addEventListener&&!a.attachEvent)return"";d=!!d;var e=sf(a,b,c,d);if(e)return e;var e=++rf.count+"",g=!("mouseenter"!=b&&"mouseleave"!=b||!a.addEventListener||"onmouseenter"in document),h;h=g?function(d){d=new of(d);if(!hd(d.relatedTarget,function(b){return b==a},!0))return d.currentTarget=a,d.type=b,c.call(a,d)}:function(b){b=new of(b);b.currentTarget=a;return c.call(a,b)};h=ff(h);qf[e]=[a,b,c,h,d];a.addEventListener?"mouseenter"==b&&g?a.addEventListener("mouseover",
-h,d):"mouseleave"==b&&g?a.addEventListener("mouseout",h,d):"mousewheel"==b&&"MozBoxSizing"in document.documentElement.style?a.addEventListener("MozMousePixelScroll",h,d):a.addEventListener(b,h,d):a.attachEvent("on"+b,h);return e}function tf(a,b){var c;return c=J(a,"timeupdate",function(){uf(c);b.apply(a,arguments)},void 0)}
-function vf(a,b,c){b=b.toLowerCase();var d=c,e="mouse"+b;if(Ve("pointerEnabled",window.navigator))e="MSPointer"+b.charAt(0).toUpperCase()+b.substr(1);else if(Xe("touchstart",document)){d=b;switch(b){case "down":d="start";break;case "up":d="end";break;case "over":d="enter";break;case "out":d="leave"}e="touch"+d;d=function(a){z(null,function(b){var d=new of(a);w(d,b);c(d)})}}return J(a,e,d)}function wf(a,b,c){xf(a,"change",b,function(a){return a.nodeName.toLowerCase()===c.toLowerCase()&&!0})}
-function yf(a,b,c){return xf(a,"click",b,function(a){return Dc(a,c)})}function xf(a,b,c,d){var e=a||document;return J(e,b,function(a){var b=hd(a.target,function(a){return a===e||d(a)},!0);b&&b!==e&&!b.disabled&&(a.currentTarget=b,c.call(b,a))})}function uf(a){a&&("string"==typeof a&&(a=[a]),z(a,function(a){if(a in qf){var c=qf[a],d=c[0],e=c[1],g=c[3],c=c[4];d.removeEventListener?d.removeEventListener(e,g,c):d.detachEvent&&d.detachEvent("on"+e,g);delete qf[a]}}))}
-function zf(a){for(var b in qf)qf[b][0]==a&&uf(b)}function Af(a,b){if(document.createEvent){var c=document.createEvent("HTMLEvents");c.initEvent(b,!0,!0);a.dispatchEvent(c)}else c=document.createEventObject(),a.fireEvent("on"+b,c)};function Bf(){return!!We(["fullscreenEnabled","fullScreenEnabled"],document)}function Cf(){return We(["fullscreenElement","fullScreenElement"],document)};function Df(a){a=a||{};this.url=a.url||"";this.urlV8=a.url_v8||"";this.urlV9As2=a.url_v9as2||"";this.args=a.args||Lb(Ef);this.assets=a.assets||{};this.attrs=a.attrs||Lb(Ff);this.params=a.params||Lb(Gf);this.minVersion=a.min_version||"8.0.0";this.fallback=a.fallback||null;this.fallbackMessage=a.fallbackMessage||null;this.html5=!!a.html5;this.disable=a.disable||{};this.loaded=!!a.loaded}var Ef={enablejsapi:1},Ff={},Gf={allowscriptaccess:"always",allowfullscreen:"true",bgcolor:"#000000"};
-Df.prototype.clone=function(){var a=new Df,b;for(b in this){var c=this[b];"object"==da(c)?a[b]=Lb(c):a[b]=c}return a};function Hf(a){a&&(this.name=va(a.name),this.mb=a.screenId,this.lc=a.loungeToken,this.Cb=a.dialId||"")}f=Hf.prototype;f.name="";f.mb="";f.lc="";f.Cb="";f.kq=function(){return{key:this.mb,name:this.name}};f.toString=function(){var a=this.lc?this.lc.slice(-6):"null";return"{name:"+this.name+",screenId:"+this.mb+",loungeToken:..."+a+",dialId:"+this.Cb+"}"};function If(a){return a?a.toString():"null"}function Jf(a){a=a||[];return"["+Ka(a,function(a){return If(a)}).join(",")+"]"};function Kf(a){this.a=a}var Lf=/\s*;\s*/;f=Kf.prototype;f.set=function(a,b,c,d,e,g){if(/[;=\s]/.test(a))throw Error('Invalid cookie name "'+a+'"');if(/[;\r\n]/.test(b))throw Error('Invalid cookie value "'+b+'"');q(c)||(c=-1);e=e?";domain="+e:"";d=d?";path="+d:"";g=g?";secure":"";c=0>c?"":0==c?";expires="+(new Date(1970,1,1)).toUTCString():";expires="+(new Date(x()+1E3*c)).toUTCString();this.a.cookie=a+"="+b+e+d+c+g};
-f.get=function(a,b){for(var c=a+"=",d=(this.a.cookie||"").split(Lf),e=0,g;g=d[e];e++){if(0==g.lastIndexOf(c,0))return g.substr(c.length);if(g==a)return""}return b};f.remove=function(a,b,c){var d=q(this.get(a));this.set(a,"",0,b,c);return d};f.uc=function(){return Mf(this).keys};f.jc=function(){return Mf(this).Mv};f.isEmpty=function(){return!this.a.cookie};f.hb=function(){return this.a.cookie?(this.a.cookie||"").split(Lf).length:0};f.clear=function(){for(var a=Mf(this).keys,b=a.length-1;0<=b;b--)this.remove(a[b])};
-function Mf(a){a=(a.a.cookie||"").split(Lf);for(var b=[],c=[],d,e,g=0;e=a[g];g++)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,Mv:c}}var Nf=new Kf(document);Nf.b=3950;function Of(){};function Pf(){}y(Pf,Of);Pf.prototype.hb=function(){var a=0;Td(this.Nd(!0),function(){a++});return a};Pf.prototype.clear=function(){var a=Ud(this.Nd(!0)),b=this;z(a,function(a){b.remove(a)})};function Qf(a){this.a=a}y(Qf,Pf);f=Qf.prototype;f.isAvailable=function(){if(!this.a)return!1;try{return this.a.setItem("__sak","1"),this.a.removeItem("__sak"),!0}catch(a){return!1}};f.set=function(a,b){try{this.a.setItem(a,b)}catch(c){if(0==this.a.length)throw"Storage mechanism: Storage disabled";throw"Storage mechanism: Quota exceeded";}};f.get=function(a){a=this.a.getItem(a);if(!u(a)&&null!==a)throw"Storage mechanism: Invalid value was encountered";return a};f.remove=function(a){this.a.removeItem(a)};
-f.hb=function(){return this.a.length};f.Nd=function(a){var b=0,c=this.a,d=new Rd;d.next=function(){if(b>=c.length)throw Qd;var d;d=c.key(b++);if(a)return d;d=c.getItem(d);if(!u(d))throw"Storage mechanism: Invalid value was encountered";return d};return d};f.clear=function(){this.a.clear()};f.key=function(a){return this.a.key(a)};function Rf(){var a=null;try{a=window.localStorage||null}catch(b){}this.a=a}y(Rf,Qf);function Sf(){var a=null;try{a=window.sessionStorage||null}catch(b){}this.a=a}y(Sf,Qf);function Tf(a){this.Of=a;this.fq=new qb}f=Tf.prototype;f.Of=null;f.fq=null;f.set=function(a,b){q(b)?this.Of.set(a,pb(this.fq,b)):this.Of.remove(a)};f.get=function(a){var b;try{b=this.Of.get(a)}catch(c){return}if(null!==b)try{return mb(b)}catch(d){throw"Storage: Invalid value was encountered";}};f.remove=function(a){this.Of.remove(a)};function Uf(a){Tf.call(this,a)}y(Uf,Tf);function Vf(a){this.data=a}function Wf(a){return!q(a)||a instanceof Vf?a:new Vf(a)}Uf.prototype.set=function(a,b){Uf.C.set.call(this,a,Wf(b))};Uf.prototype.a=function(a){a=Uf.C.get.call(this,a);if(!q(a)||a instanceof Object)return a;throw"Storage: Invalid value was encountered";};Uf.prototype.get=function(a){if(a=this.a(a)){if(a=a.data,!q(a))throw"Storage: Invalid value was encountered";}else a=void 0;return a};function Xf(a){Tf.call(this,a)}y(Xf,Uf);function Yf(a){var b=a.creation;a=a.expiration;return!!a&&a<x()||!!b&&b>x()}Xf.prototype.set=function(a,b,c){if(b=Wf(b)){if(c){if(c<x()){Xf.prototype.remove.call(this,a);return}b.expiration=c}b.creation=x()}Xf.C.set.call(this,a,b)};Xf.prototype.a=function(a,b){var c=Xf.C.a.call(this,a);if(c)if(!b&&Yf(c))Xf.prototype.remove.call(this,a);else return c};function Zf(a){Tf.call(this,a)}y(Zf,Xf);function $f(a,b){var c=[];Td(b,function(a){var b;try{b=Zf.prototype.a.call(this,a,!0)}catch(g){if("Storage: Invalid value was encountered"==g)return;throw g;}q(b)?Yf(b)&&c.push(a):c.push(a)},a);return c}function ag(a,b){var c=$f(a,b);z(c,function(a){Zf.prototype.remove.call(this,a)},a)};function bg(a,b,c){var d=c&&0<c?c:0;c=d?x()+1E3*d:0;if((d=d?cg:dg)&&window.JSON){u(b)||(b=JSON.stringify(b,void 0));try{d.set(a,b,c)}catch(e){d.remove(a)}}}function eg(a){if(!dg&&!cg||!window.JSON)return null;var b;try{b=dg.get(a),b=u(b)?b:cg.get(a)}catch(c){return null}if(!u(b))return null;try{b=JSON.parse(b,void 0)}catch(d){}return b}function fg(a){dg&&dg.remove(a);cg&&cg.remove(a)}var cg,gg=new Rf;cg=gg.isAvailable()?new Zf(gg):null;var dg,hg=new Sf;dg=hg.isAvailable()?new Zf(hg):null;function ig(a){a&&(this.id=a.id||"",this.name=va(a.name||""),this.activityId=a.activityId||"",this.status=a.status||"UNKNOWN")}f=ig.prototype;f.id="";f.name="";f.activityId="";f.status="UNKNOWN";f.kq=function(){return{key:this.id,name:this.name}};function jg(a){return{id:a.id,name:a.name,activityId:a.activityId,status:a.status}}f.toString=function(){return"{id:"+this.id+",name:"+this.name+",activityId:"+this.activityId+",status:"+this.status+"}"};
-function kg(a){a=a||[];return"["+Ka(a,function(a){return a?a.toString():"null"}).join(",")+"]"};function lg(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(a){var b=16*Math.random()|0;return("x"==a?b:b&3|8).toString(16)})}function mg(a,b){return Oa(a,function(a){return a.key==b})}function ng(a){return Ka(a,function(a){return a.kq()})}function og(a){return Ka(a,function(a){return jg(a)})}function pg(a){return Ka(a,function(a){return new ig(a)})}function qg(a,b){return a||b?a&&b?a.id==b.id&&a.name==b.name:!1:!0}
-function rg(a,b){return Oa(a,function(a){return a.id==b})}function sg(a){return Ka(a,function(a){return{name:a.name,screenId:a.mb,loungeToken:a.lc,dialId:a.Cb}})}function tg(a){return Ka(a,function(a){return new Hf(a)})}function ug(a,b){return a||b?a&&b?a.mb==b.mb:!1:!0}function vg(a,b){return a||b?a&&b?a.mb==b.mb&&a.lc==b.lc&&a.name==b.name&&a.Cb==b.Cb:!1:!0}function wg(a,b){return Oa(a,function(a){return ug(a,b)})}function xg(a,b){return Oa(a,function(a){return b==a.mb||b==a.Cb})};function yg(){var a=zg(),b=Ag();Sa(a,b);Bg()&&kb(a,b);a=Cg(a);Ta(a)?Nf.remove("remote_sid","/","youtube.com"):(a=a.join(","),Nf.set("remote_sid",a,void 0,"/","youtube.com"))}function zg(){var a=eg("yt-remote-connected-devices")||[];fb(a);return a}function Cg(a){if(Ta(a))return[];var b=a[0].indexOf("#"),c=-1==b?a[0]:a[0].substring(0,b);return Ka(a,function(a,b){return 0==b?a:a.substring(c.length)})}function Dg(a){bg("yt-remote-connected-devices",a,86400)}
-function Ag(){if(Eg)return Eg;var a=eg("yt-remote-device-id");a||(a=lg(),bg("yt-remote-device-id",a,31536E3));for(var b=zg(),c=1,d=a;Sa(b,d);)c++,d=a+"#"+c;return Eg=d}function Fg(){return eg("yt-remote-session-browser-channel")}function Bg(){return eg("yt-remote-session-screen-id")}
-function Gg(a){5<a.length&&(a=a.slice(a.length-5));var b=Ka(Hg(),function(a){return a.loungeToken}),c=Ka(a,function(a){return a.loungeToken});Ma(c,function(a){return!Sa(b,a)})&&bg("yt-remote-lounge-token-expiration",!0,86400);bg("yt-remote-local-screens",a,31536E3)}function Hg(){return eg("yt-remote-local-screens")||[]}function Ig(){return eg("yt-remote-online-screens")||[]}function Jg(a){bg("yt-remote-online-dial-devices",a,30)}function Kg(){return eg("yt-remote-online-dial-devices")||[]}
-function Lg(a,b){a?bg("yt-remote-session-video-id",a):fg("yt-remote-session-video-id");b?bg("yt-remote-session-list-id",b):fg("yt-remote-session-list-id")}function Mg(a){a||(fg("yt-remote-session-screen-id"),fg("yt-remote-session-video-id"),fg("yt-remote-session-list-id"));yg();a=zg();Wa(a,Ag());Dg(a)}var Eg="";function Ng(){var a=tg(Ig()),b=pg(Kg()),b=Ja(b,function(b){return!xg(a,b.id)});return ng(Za(a,b))};var Og={},Pg=0;function Qg(a,b){if(a){var c=new Image,d=""+Pg++;Og[d]=c;c.onload=c.onerror=function(){b&&Og[d]&&b();delete Og[d]};c.src=a;c=eval("null")}};function K(){}K.prototype.Pc=!1;K.prototype.ha=function(){return this.Pc};K.prototype.dispose=function(){this.Pc||(this.Pc=!0,this.F())};function L(a,b){Rg(a,oa(Sg,b))}function Rg(a,b){a.tb||(a.tb=[]);a.tb.push(v(b,void 0))}K.prototype.F=function(){if(this.tb)for(;this.tb.length;)this.tb.shift()()};function Sg(a){a&&"function"==typeof a.dispose&&a.dispose()}function Tg(a){for(var b=0,c=arguments.length;b<c;++b){var d=arguments[b];fa(d)?Tg.apply(null,d):Sg(d)}};function Ug(a,b){this.app=a;this.b=null;this.i={};this.g={};this.o={};this.k={};this.j=null;this.a=b;N(this,"cueVideoById",this.Br);N(this,"loadVideoById",this.Xj);N(this,"cueVideoByUrl",this.Cr);N(this,"loadVideoByUrl",this.Yr);N(this,"playVideo",this.rg);N(this,"pauseVideo",this.fn);N(this,"stopVideo",this.Dj);N(this,"clearVideo",this.zr);N(this,"getVideoBytesLoaded",this.Nr);N(this,"getVideoBytesTotal",this.Or);N(this,"getVideoLoadedFraction",this.Qr);N(this,"getVideoStartBytes",this.Rr);N(this,
-"cuePlaylist",this.Ar);N(this,"loadPlaylist",this.Xr);N(this,"nextVideo",this.$r);N(this,"previousVideo",this.as);N(this,"playVideoAt",this.um);N(this,"setShuffle",this.gs);N(this,"setLoop",this.cs);N(this,"getPlaylist",this.vb);N(this,"getPlaylistIndex",this.ak);N(this,"getPlaylistId",this.Lr);N(this,"loadModule",this.Wr);N(this,"unloadModule",this.en);N(this,"setOption",this.dn);N(this,"getOption",this.Cj);N(this,"getOptions",this.Hr);N(this,"mute",this.Pm);N(this,"unMute",this.Rm);N(this,"isMuted",
-this.Ur);N(this,"setVolume",this.Qm);N(this,"getVolume",this.Om);N(this,"seekTo",this.Wh);N(this,"getPlayerState",this.Kr);N(this,"getPlaybackRate",this.Jr);N(this,"setPlaybackRate",this.es);N(this,"getAvailablePlaybackRates",this.Er);N(this,"getPlaybackQuality",this.Ir);N(this,"setPlaybackQuality",this.ds);N(this,"getAvailableQualityLevels",this.Fr);N(this,"getCurrentTime",this.getCurrentTime);N(this,"getDuration",this.wg);N(this,"addEventListener",this.addEventListener);N(this,"removeEventListener",
-this.removeEventListener);N(this,"getVideoUrl",this.Sr);N(this,"getDebugText",this.Gr);N(this,"getVideoEmbedCode",this.Pr);N(this,"getVideoData",this.getVideoData);N(this,"addCueRange",this.yr);N(this,"removeCueRange",this.bs);N(this,"setSize",this.hs);N(this,"getApiInterface",this.Dr);N(this,"destroy",this.destroy);N(this,"showVideoInfo",this.is);N(this,"hideVideoInfo",this.Tr);this.g.logFallback=v(this.Zr,this);this.g.isNotServable=v(this.Vr,this);this.g.getUpdatedConfigurationData=v(this.Mr,this);
-this.g.updateRemoteReceivers=v(this.js,this)}y(Ug,K);function N(a,b,c){a.i[b]=v(c,a)}f=Ug.prototype;f.Dr=function(){return Hb(this.i)};f.N=function(){return this.b};f.addEventListener=function(a,b){var c=b;u(b)&&(c=function(){n(b).apply(window,arguments)},this.o[b]=c);this.app.D(a,c)};f.fu=function(a,b){var c=u(b)?a+b:a+ja(b);if(!this.k[c]){u(b)&&(b=function(){n(b).apply(window,arguments)});var d=v(function(a){b({target:this.j,data:a})},this);this.k[c]=d;this.addEventListener(a,d)}};
-f.removeEventListener=function(a,b){var c=b;if(u(b)&&b in this.o){var c=this.o[b],d=this.o;b in d&&delete d[b]}this.app.$(a,c)};f.gu=function(a,b){var c=u(b)?a+b:a+ja(b);this.k[c]&&this.removeEventListener(a,this.k[c])};f.Kr=function(){return this.app.aa};f.Wh=function(a,b){Vg(this.app,!0,this.a);Wg(this.app,a,b,void 0,this.a)};f.getCurrentTime=function(){var a=this.app.Xd;return a&&O(this.app).b!=a?a.getCurrentTime():this.app.getCurrentTime(this.a)};
-f.wg=function(){var a=this.app.Xd;return a?a.Vd:0};f.Om=function(){return this.app.wa.volume};f.Qm=function(a){var b=this.app;b.wa.volume=a;b.u("internalvolumechange",b.wa)};f.Ur=function(){return this.app.wa.muted};f.Pm=function(){Xg(this.app)};f.Rm=function(){Yg(this.app)};f.rg=function(){Vg(this.app,!0,this.a);Zg(this.app,this.a)};f.fn=function(){$g(this.app,this.a)};f.Dj=function(){var a=this.app;ah(a,"play_pause")||bh(a,this.a)};f.zr=function(){};f.Jr=function(){return this.app.Ig};
-f.es=function(a){ch(this.app,a)};f.Er=function(){return this.app.a.lg?dh:[1]};f.Ir=function(){return eh(this.app,this.a)};f.ds=function(a){var b=O(this.app,this.a);b&&fh(b,"m",a)};f.Fr=function(){return gh(this.app,this.a)};f.Nr=function(){var a=hh(this.app.Xd);return Math.floor(1E3*a)};f.Or=function(){return 1E3};f.Qr=function(){return hh(this.app.Xd)};f.Rr=function(){return 0};f.hs=function(){this.app.S.Ji()};f.Wr=function(a){(a=ih(this.app.k,a))&&a.load()};
-f.en=function(a){(a=ih(this.app.k,a))&&a.unload()};f.Xj=function(a,b,c){var d=this.app,e=this.a;a=jh(d,kh(a,d.list,b,c),e);Vg(d,a,e)};f.Br=function(a,b,c){var d=this.app,e=this.a;lh(d,new mh(kh(a,d.list,b,c)),e)};f.Yr=function(a,b,c){var d=this.app,e=this.a;a=nh(a,d.list,b,c);b=jh(d,a,e);Vg(d,b,e);oh(d,a.mediaContentUrl)};f.Cr=function(a,b,c){var d=this.app,e=this.a;a=nh(a,d.list,b,c);lh(d,new mh(a),e);oh(d,a.mediaContentUrl)};f.Sr=function(){return ph(this.app)};f.Gr=function(){return qh(this.app)};
-f.Pr=function(){return""};f.yr=function(){return!1};f.bs=function(){};f.Xr=function(a,b,c,d){var e=this.app;e.bf=!1;rh(e,a,b,c,d)};f.Ar=function(a,b,c,d){var e=this.app;e.bf=!0;rh(e,a,b,c,d)};f.$r=function(){sh(this.app)};f.as=function(){th(this.app)};f.um=function(a){var b=this.app;b.g&&(b.g.Zd?uh(b,vh(b.g,a)):b.bf=!1,wh(b.g,a))};f.gs=function(a){var b=this.app;b.g&&xh(b.g,a)};f.cs=function(a){var b=this.app;b.g&&(b.g.loop=a)};
-f.vb=function(){var a=this.app.g;if(!a)return null;for(var b=[],c=0;c<a.Mb;c++)b[c]=vh(a,c).L;return b};f.ak=function(){var a=this.app.g?this.app.g.ua:null;return null==a?-1:a};f.Lr=function(){return this.app.g&&this.app.g.g?this.app.g.g.toString():null};f.dn=function(a,b,c){return yh(this.app.k,a,b,c)};f.Cj=function(a,b,c){return yh(this.app.k,a,b,c)};f.Hr=function(a){return zh(this.app.k,a)};f.getVideoData=function(){var a=this.app.getVideoData(this.a)||{};return{video_id:a.L,author:a.author,title:a.title}};
-f.is=function(){Ah(this.app.S)};f.Tr=function(){this.app.S.uk()};f.Zr=function(){Bh(this.app.b,204)};f.Vr=function(){var a=Ch(this.app);return!(!a||!P(a,128)||5!=a.a.errorCode)};f.Mr=function(){var a=this.app,b=a.K.clone();if(a=a.b.getVideoData()){var c=b.args,d=Lb(a.b);d.start=a.xa;w(c,d)}return b};f.js=function(a){var b=this.app;Dh(b.a)&&6!=b.o&&(b.a.sg=!Ta(a),b.a.sg?1!=b.o&&3!=b.o&&Eh(b):Fh(b.G))};f.destroy=function(){this.app.dispose()};
-f.F=function(){if(this.b){for(var a in this.i)this.b[a]=null;for(a in this.g)this.b[a]=null}this.o=this.k=this.b=null;Ug.C.F.call(this)};function Gh(a,b){Ug.call(this,a,b);N(this,"cueVideoByPlayerVars",this.yx);N(this,"loadVideoByPlayerVars",this.Io);N(this,"preloadVideoByPlayerVars",this.Bx);N(this,"seekBy",this.Sp);N(this,"enableLicenseIntercept",this.zx);N(this,"updatePlaylist",this.Fx);N(this,"resumeLicenseSession",this.Cx);N(this,"updateLastActiveTime",this.Ex);N(this,"updateVideoData",this.Gx);N(this,"getStoryboardFormat",this.Ax)}y(Gh,Ug);f=Gh.prototype;f.yx=function(a){var b=this.a;lh(this.app,new mh(a),b)};
-f.Io=function(a){jh(this.app,a,this.a)};f.Bx=function(){};f.Sp=function(a,b,c){Vg(this.app,!0,this.a);var d=this.app,e=this.a;Wg(d,d.getCurrentTime()+a,b,c,e)};f.zx=function(){var a=this.app;a.Xk||(a.Xk=!0,a.Di={})};f.Fx=function(){var a=this.app;Hh(a);a.fb("onPlaylistUpdate")};f.Cx=function(a,b){var c=this.app,d=c.Di[a];d&&(Ih(d,b),d.start(),delete c.Di[a])};f.Ex=function(){this.app.a.Ta=x()};f.Gx=function(a){var b=O(this.app,this.a||1);b&&(b=b.a,Jh(b,a),b.u("dataupdated"))};f.Ax=function(){return this.app.getVideoData().b.storyboard_spec};
-f.getVideoData=function(){var a=Gh.C.getVideoData.call(this),b=this.app.getVideoData(this.a)||{};a.cpn=b.Da;return a};f.getCurrentTime=function(a){return a?this.app.getCurrentTime(a):Gh.C.getCurrentTime.call(this)};f.wg=function(a){return a?Kh(this.app,a):Gh.C.wg.call(this)};function Lh(a,b){Gh.call(this,a,b)}y(Lh,Gh);f=Lh.prototype;f.Xj=function(a,b,c){jh(this.app,kh(a,this.app.list,b,c),this.a)};f.rg=function(){Zg(this.app,this.a)};f.Wh=function(a,b){Wg(this.app,a,b,void 0,this.a)};function Q(a){return a.app.S.a}f.J=function(){return this.app.J()};f.vb=function(){return this.app.g};f.getVideoData=function(){return this.app.getVideoData(this.a)};function Mh(a){this.j=Math.exp(Math.log(0.5)/a);this.a=this.g=0}Mh.prototype.b=function(a,b){var c=Math.pow(this.j,a);this.a=b*(1-c)+c*this.a;this.g+=a};Mh.prototype.i=function(){return this.a/(1-Math.pow(this.j,this.g))};function Nh(a,b){this.o=0;this.j=a;this.H=b||0.5;this.k="index";this.a=0;this.g=[]}Nh.prototype.b=function(a,b){Oh(this,"index");this.g.push({index:this.o++,jh:a,value:b});this.a+=a;for(Oh(this,"index");this.a>this.j;){var c=this.a-this.j,d=this.g[0];d.jh<=c?(this.a-=d.jh,this.g.shift()):(this.a-=c,d.jh-=c)}};function Ph(a,b){Oh(a,"value");var c=b*a.a,d=0,e=NaN;a.g.some(function(a){d+=a.jh;e=a.value;if(d>=c)return!0});return e}Nh.prototype.i=function(){return Ph(this,this.H)};
-function Oh(a,b){a.k!=b&&(a.k=b,hb(a.g,b))};function Qh(a){var b=eg(a);if(!b){var c=new Rf;c.isAvailable()&&(b=(new Tf(c)).get(a))}return b}function Rh(){var a={volume:100,muted:!1,nonNormalized:100},b=Qh("yt-player-volume")||{};a.volume=isNaN(b.volume)?100:vb(b.volume,0,100);a.nonNormalized=isNaN(b.nonNormalized)?a.volume:b.nonNormalized;a.muted=void 0==b.muted?!1:b.muted;return a};function Sh(a){this.i=this.j=0;a.Nc?this.b=new Mh(16):this.b=new Nh(16,0.6);a.ve||"play"==a.Ca?this.g=new Mh(4):this.g=new Nh(16,0.6);a.Xl?this.a=new Nh(8,0.6):a.Vl?this.a=new Nh(16,0.6):a.Wl?this.a=new Nh(24,0.6):"play"==a.Ca?this.a=new Mh(15):this.a=new Nh(15,0.6);var b=Qh("yt-player-bandwidth");a=a.oc?0.1:0.5;b&&!isNaN(b.byterate)?this.a.b(a,b.byterate):this.a.b(a,13E4)}function Th(a){a=a.b.i();return a=isNaN(a)?0.5:a}function Uh(a){return a.g.i()||0}function Vh(a){a=a.a.i();return 0<a?a:1};function Wh(){this.a=[];this.Tb={}}y(Wh,K);f=Wh.prototype;f.ip=1;f.Pi=0;f.D=function(a,b,c){var d=this.Tb[a];d||(d=this.Tb[a]=[]);var e=this.ip;this.a[e]=a;this.a[e+1]=b;this.a[e+2]=c;this.ip=e+3;d.push(e);return e};f.$=function(a,b,c){if(a=this.Tb[a]){var d=this.a;if(a=Oa(a,function(a){return d[a+1]==b&&d[a+2]==c}))return this.Wc(a)}return!1};
-f.Wc=function(a){if(0!=this.Pi)return this.b||(this.b=[]),this.b.push(a),!1;var b=this.a[a];if(b){var c=this.Tb[b];c&&Wa(c,a);delete this.a[a];delete this.a[a+1];delete this.a[a+2]}return!!b};f.u=function(a,b){var c=this.Tb[a];if(c){this.Pi++;for(var d=cb(arguments,1),e=0,g=c.length;e<g;e++){var h=c[e];this.a[h+1].apply(this.a[h+2],d)}this.Pi--;if(this.b&&0==this.Pi)for(;c=this.b.pop();)this.Wc(c);return 0!=e}return!1};
-f.clear=function(a){if(a){var b=this.Tb[a];b&&(z(b,this.Wc,this),delete this.Tb[a])}else this.a.length=0,this.Tb={}};f.hb=function(a){if(a){var b=this.Tb[a];return b?b.length:0}a=0;for(b in this.Tb)a+=this.hb(b);return a};f.F=function(){Wh.C.F.call(this);delete this.a;delete this.Tb;delete this.b};function Xh(a,b){this.start=a;this.end=b;this.a=ja(this)}function Yh(a,b){return a.start!=b.start?a.start-b.start:a.end!=b.end?a.end-b.end:a.a!=b.a?a.a-b.a:0}Xh.prototype.contains=function(a,b){return a>=this.start&&(a<this.end||a==this.end&&this.start==this.end)&&(null==b||a<b&&b<=this.end)};Xh.prototype.toString=function(){return"Interval["+this.start+", "+this.end+"]"};function Zh(a,b,c){Xh.call(this,a,b);a=c||{};this.Ba=a.id||"";void 0!=a.priority&&(this.th=a.priority);this.namespace=a.namespace||"";this.Uc=a.visible||!1;this.zb=new Wh}y(Zh,Xh);f=Zh.prototype;f.Ba="";f.th=7;f.active=!0;f.Uc=!1;f.zb=null;f.namespace="";f.getId=function(){return this.Ba};function $h(a,b){return a.start==b.start?a.th==b.th?0:a.th<b.th?-1:1:a.start<b.start?-1:1};function ai(a,b){this.type=a;this.currentTarget=this.target=b}f=ai.prototype;f.dispose=function(){};f.se=!1;f.defaultPrevented=!1;f.gp=!0;f.stopPropagation=function(){this.se=!0};f.preventDefault=function(){this.defaultPrevented=!0;this.gp=!1};function bi(a){bi[" "](a);return a}bi[" "]=ba;var ci=!C||sc(9),di=C&&!rc("9");!dc||rc("528");cc&&rc("1.9b")||C&&rc("8")||bc&&rc("9.5")||dc&&rc("528");cc&&!rc("8")||C&&rc("9");function ei(a,b){a&&this.init(a,b)}y(ei,ai);f=ei.prototype;f.target=null;f.relatedTarget=null;f.clientX=0;f.clientY=0;f.keyCode=0;f.charCode=0;f.ctrlKey=!1;f.altKey=!1;f.shiftKey=!1;f.re=null;
-f.init=function(a,b){var c=this.type=a.type;ai.call(this,c);this.target=a.target||a.srcElement;this.currentTarget=b;var d=a.relatedTarget;if(d){if(cc){var e;t:{try{bi(d.nodeName);e=!0;break t}catch(g){}e=!1}e||(d=null)}}else"mouseover"==c?d=a.fromElement:"mouseout"==c&&(d=a.toElement);this.relatedTarget=d;this.clientX=void 0!==a.clientX?a.clientX:a.pageX;this.clientY=void 0!==a.clientY?a.clientY:a.pageY;this.keyCode=a.keyCode||0;this.charCode=a.charCode||("keypress"==c?a.keyCode:0);this.ctrlKey=a.ctrlKey;
-this.altKey=a.altKey;this.shiftKey=a.shiftKey;this.state=a.state;this.re=a;a.defaultPrevented&&this.preventDefault();delete this.se};f.stopPropagation=function(){ei.C.stopPropagation.call(this);this.re.stopPropagation?this.re.stopPropagation():this.re.cancelBubble=!0};f.preventDefault=function(){ei.C.preventDefault.call(this);var a=this.re;if(a.preventDefault)a.preventDefault();else if(a.returnValue=!1,di)try{if(a.ctrlKey||112<=a.keyCode&&123>=a.keyCode)a.keyCode=-1}catch(b){}};f.Ux=function(){return this.re};var fi="closure_listenable_"+(1E6*Math.random()|0);function gi(a){try{return!(!a||!a[fi])}catch(b){return!1}}var hi=0;function ii(a,b,c,d,e){this.df=a;this.proxy=null;this.src=b;this.type=c;this.capture=!!d;this.gb=e;this.key=++hi;this.removed=this.Oi=!1}function ji(a){a.removed=!0;a.df=null;a.proxy=null;a.src=null;a.gb=null};function ki(a){this.src=a;this.a={};this.b=0}ki.prototype.add=function(a,b,c,d,e){var g=this.a[a];g||(g=this.a[a]=[],this.b++);var h=li(g,b,d,e);-1<h?(a=g[h],c||(a.Oi=!1)):(a=new ii(b,this.src,a,!!d,e),a.Oi=c,g.push(a));return a};ki.prototype.remove=function(a,b,c,d){if(!(a in this.a))return!1;var e=this.a[a];b=li(e,b,c,d);return-1<b?(ji(e[b]),Xa(e,b),0==e.length&&(delete this.a[a],this.b--),!0):!1};
-function mi(a,b){var c=b.type;if(!(c in a.a))return!1;var d=Wa(a.a[c],b);d&&(ji(b),0==a.a[c].length&&(delete a.a[c],a.b--));return d}ki.prototype.removeAll=function(a){var b=0,c;for(c in this.a)if(!a||c==a){for(var d=this.a[c],e=0;e<d.length;e++)++b,ji(d[e]);delete this.a[c];this.b--}return b};function ni(a,b,c,d,e){a=a.a[b];b=-1;a&&(b=li(a,c,d,e));return-1<b?a[b]:null}function li(a,b,c,d){for(var e=0;e<a.length;++e){var g=a[e];if(!g.removed&&g.df==b&&g.capture==!!c&&g.gb==d)return e}return-1};var oi="closure_lm_"+(1E6*Math.random()|0),pi={},qi=0;function ri(a,b,c,d,e){if(t(b)){for(var g=0;g<b.length;g++)ri(a,b[g],c,d,e);return null}c=si(c);if(gi(a))a=a.listen(b,c,d,e);else{if(!b)throw Error("Invalid event type");var g=!!d,h=ti(a);h||(a[oi]=h=new ki(a));c=h.add(b,c,!1,d,e);c.proxy||(d=ui(),c.proxy=d,d.src=a,d.df=c,a.addEventListener?a.addEventListener(b,d,g):a.attachEvent(b in pi?pi[b]:pi[b]="on"+b,d),qi++);a=c}return a}
-function ui(){var a=vi,b=ci?function(c){return a.call(b.src,b.df,c)}:function(c){c=a.call(b.src,b.df,c);if(!c)return c};return b}function wi(a,b,c,d,e){if(t(b))for(var g=0;g<b.length;g++)wi(a,b[g],c,d,e);else c=si(c),gi(a)?a.dc(b,c,d,e):a&&(a=ti(a))&&(b=ni(a,b,c,!!d,e))&&xi(b)}
-function xi(a){if(ga(a)||!a||a.removed)return!1;var b=a.src;if(gi(b))return mi(b.gd,a);var c=a.type,d=a.proxy;b.removeEventListener?b.removeEventListener(c,d,a.capture):b.detachEvent&&b.detachEvent(c in pi?pi[c]:pi[c]="on"+c,d);qi--;(c=ti(b))?(mi(c,a),0==c.b&&(c.src=null,b[oi]=null)):ji(a);return!0}function yi(a,b,c,d){var e=1;if(a=ti(a))if(b=a.a[b])for(b=$a(b),a=0;a<b.length;a++){var g=b[a];g&&g.capture==c&&!g.removed&&(e&=!1!==zi(g,d))}return Boolean(e)}
-function zi(a,b){var c=a.df,d=a.gb||a.src;a.Oi&&xi(a);return c.call(d,b)}
-function vi(a,b){if(a.removed)return!0;if(!ci){var c=b||n("window.event"),d=new ei(c,this),e=!0;if(!(0>c.keyCode||void 0!=c.returnValue)){t:{var g=!1;if(0==c.keyCode)try{c.keyCode=-1;break t}catch(h){g=!0}if(g||void 0==c.returnValue)c.returnValue=!0}c=[];for(g=d.currentTarget;g;g=g.parentNode)c.push(g);for(var g=a.type,k=c.length-1;!d.se&&0<=k;k--)d.currentTarget=c[k],e&=yi(c[k],g,!0,d);for(k=0;!d.se&&k<c.length;k++)d.currentTarget=c[k],e&=yi(c[k],g,!1,d)}return e}return zi(a,new ei(b,this))}
-function ti(a){a=a[oi];return a instanceof ki?a:null}var Ai="__closure_events_fn_"+(1E9*Math.random()>>>0);function si(a){return ha(a)?a:a[Ai]||(a[Ai]=function(b){return a.handleEvent(b)})};function Bi(){this.gd=new ki(this);this.U=this}y(Bi,K);Bi.prototype[fi]=!0;f=Bi.prototype;f.Kl=null;f.addEventListener=function(a,b,c,d){ri(this,a,b,c,d)};f.removeEventListener=function(a,b,c,d){wi(this,a,b,c,d)};
-function Ci(a,b){var c,d=a.Kl;if(d){c=[];for(var e=1;d;d=d.Kl)c.push(d),++e}var d=a.U,e=b,g=e.type||e;if(u(e))e=new ai(e,d);else if(e instanceof ai)e.target=e.target||d;else{var h=e,e=new ai(g,d);Ob(e,h)}var h=!0,k;if(c)for(var m=c.length-1;!e.se&&0<=m;m--)k=e.currentTarget=c[m],h=Di(k,g,!0,e)&&h;e.se||(k=e.currentTarget=d,h=Di(k,g,!0,e)&&h,e.se||(h=Di(k,g,!1,e)&&h));if(c)for(m=0;!e.se&&m<c.length;m++)k=e.currentTarget=c[m],h=Di(k,g,!1,e)&&h}
-f.F=function(){Bi.C.F.call(this);this.gd&&this.gd.removeAll(void 0);this.Kl=null};f.listen=function(a,b,c,d){return this.gd.add(a,b,!1,c,d)};f.dc=function(a,b,c,d){return this.gd.remove(a,b,c,d)};function Di(a,b,c,d){b=a.gd.a[b];if(!b)return!0;b=$a(b);for(var e=!0,g=0;g<b.length;++g){var h=b[g];if(h&&!h.removed&&h.capture==c){var k=h.df,m=h.gb||h.src;h.Oi&&mi(a.gd,h);e=!1!==k.call(m,d)&&e}}return e&&!1!=d.gp};function Ei(a,b){Bi.call(this);this.a=a||1;this.b=b||l;this.g=v(this.cu,this);this.i=x()}y(Ei,Bi);f=Ei.prototype;f.Xc=!1;f.ic=null;function Fi(a,b){a.a=b;a.ic&&a.Xc?(a.stop(),a.start()):a.ic&&a.stop()}f.cu=function(){if(this.Xc){var a=x()-this.i;0<a&&a<0.8*this.a?this.ic=this.b.setTimeout(this.g,this.a-a):(this.ic&&(this.b.clearTimeout(this.ic),this.ic=null),Ci(this,"tick"),this.Xc&&(this.ic=this.b.setTimeout(this.g,this.a),this.i=x()))}};
-f.start=function(){this.Xc=!0;this.ic||(this.ic=this.b.setTimeout(this.g,this.a),this.i=x())};f.stop=function(){this.Xc=!1;this.ic&&(this.b.clearTimeout(this.ic),this.ic=null)};f.F=function(){Ei.C.F.call(this);this.stop();delete this.b};function Gi(a,b,c){if(ha(a))c&&(a=v(a,c));else if(a&&"function"==typeof a.handleEvent)a=v(a.handleEvent,a);else throw Error("Invalid listener argument");return 2147483647<b?-1:l.setTimeout(a,b||0)};function Hi(){this.a=[]}function Ii(a,b){for(var c=[],d=0;d<a.a.length;++d){var e=a.a[d];e.contains(b)&&c.push(e);if(e.start>b)break}return c}function Ji(a,b,c){for(var d=[],e=0;e<a.a.length;++e){var g=a.a[e];if(null!=c&&g.start>c)break;g.start>b&&d.push(g)}return d}function Ki(a,b){for(var c=[],d=0;d<a.a.length;++d){var e=a.a[d];e.contains(b)&&c.push(e.end);if(e.start>b){c.push(e.start);break}}c.sort(gb);return c[0]};var Li,Mi,Ni,Oi,Pi;Pi=Oi=Ni=Mi=Li=!1;var Qi=Yb();Qi&&(-1!=Qi.indexOf("Firefox")||-1!=Qi.indexOf("Camino")||(-1!=Qi.indexOf("iPhone")||-1!=Qi.indexOf("iPod")?Li=!0:-1!=Qi.indexOf("iPad")?Mi=!0:-1!=Qi.indexOf("Chrome")?Oi=!0:-1!=Qi.indexOf("Android")?Ni=!0:-1!=Qi.indexOf("Safari")&&(Pi=!0)));var Ri=Li,Si=Mi,Ti=Ni,Ui=Oi,Vi=Pi;var Wi,Xi;var Yi=Yb(),Zi=Yi.match(/\((iPad|iPhone|iPod)( Simulator)?;/);if(!Zi||2>Zi.length)Wi=void 0;else{var $i=Yi.match(/\((iPad|iPhone|iPod)( Simulator)?; (U; )?CPU (iPhone )?OS (\d_\d)[_ ]/);Wi=$i&&6==$i.length?Number($i[5].replace("_",".")):0}(Xi=0<=Wi)&&0<=Yb().search("Safari")&&Yb().search("Version");var aj=Ri||Si;function bj(){return cj("(ps3; leanback shell)")}function cj(a){var b=Yb();return b?0<=b.toLowerCase().indexOf(a.toLowerCase()):!1};function dj(){}var ej=Xi&&4>Wi?0.1:0,fj=new dj;f=dj.prototype;f.Bd=null;f.Ok=!1;f.Vd=0;f.Sl=0;function gj(a,b){var c="";b&&(a.Bd=b,c=hj(b));a.src&&""==c||(c&&a.src!=c&&(a.src=c),b&&b.a||a.load())}function ij(a,b){0<a.readyState&&(a.currentTime=Math.max(ej,b))}f.getType=function(){return this.type};f.Va=function(a){this.Vd=a};f.getCurrentTime=function(){return this.Sl||this.currentTime};f.kp=function(){this.Sl=this.currentTime};
-function hh(a){var b=a.Vd;if(Infinity==b)return 1;if(b&&a.buffered&&0<a.buffered.length){var c=jj(a);return a.buffered.end(c)/b}return 0}function kj(a){a.ended&&ij(a,0);!a.hasAttribute("src")&&a.Bd&&(a.src=hj(a.Bd),a.Bd.a||a.load());a.play()}function lj(a){a.currentSrc&&(aj&&ij(a,0),Xc(a),a.removeAttribute("src"),a.load(),a.Bd&&a.Bd.a&&(a.Bd=null))}function mj(a){lj(a);a.Vd=0;a.Sl=0;a.Bd=null}function nj(a,b){a.defaultPlaybackRate=b;a.playbackRate=b}
-function jj(a){var b=a.buffered;a=a.getCurrentTime();for(var c=0;c<b.length&&!(b.start(c)>a);c++)if(a<=b.end(c))return c;return 0}f.inUnbufferedArea=function(){var a=this.buffered;if(!a||!a.length)return!0;var b=jj(this);if(0<b)return!1;var c=this.getCurrentTime();return a.start(b)>c||a.end(b)<c};function oj(a,b){b?a.setAttribute("crossorigin","true"):a.removeAttribute("crossorigin")}f.Xv=function(){this.hasAttribute("controls")&&this.setAttribute("controls","true")};
-f.Yv=function(){this.Ok&&!this.muted&&(this.muted=!0)};function pj(a){var b="";if(a)for(var c=0;c<a.length;c++)b+=a.start(c).toFixed(3)+"-"+a.end(c).toFixed(3)+",";return b};var qj=[2,5,100,101,150],rj=[202,203];function sj(a,b){a=a||64;a&128&&!b||a&2&&a&16||(this.b=a,this.a=b||null)}sj.prototype.b=64;sj.prototype.a=null;function tj(a,b,c){return b==a.b&&c==a.a||b&128&&!c||b&2&&b&16?a:new sj(b,c)}function uj(a,b){return tj(a,a.b|b)}function P(a,b){return!!(a.b&b)}function vj(a){return P(a,128)?-1:P(a,2)?0:P(a,1)&&!P(a,32)?3:P(a,64)?-1:P(a,8)?1:P(a,4)?2:-1}function wj(){var a;return a=14};function R(){this.H=new Wh;L(this,this.H)}y(R,K);R.prototype.D=function(a,b,c){return this.ha()?0:this.H.D(a,b,c)};R.prototype.$=function(a,b,c){return this.ha()?!1:this.H.$(a,b,c)};R.prototype.Wc=function(a){return this.ha()?!1:this.H.Wc(a)};R.prototype.u=function(a,b){return this.ha()?!1:this.H.u.apply(this.H,arguments)};function xj(a,b,c){R.call(this);this.A=a;this.o=b;this.B=c;this.j=new Ei(250);this.j.addEventListener("tick",this.Xb,!1,this);L(this,this.j);this.i=[];this.a=[];this.b=new Hi}y(xj,R);f=xj.prototype;f.Sh=!1;f.vg=!1;f.Gk=!1;f.Fk=!1;f.Ng=null;f.nx=function(a){this.Xb();z(arguments,function(a){this.i.push(a);var c=this.b.a;!c.length||0<Yh(a,c[c.length-1])?c.push(a):kb(c,a,Yh);this.u("onAdd",a)},this);this.Xb()};f.ox=function(a){z(arguments,function(a){a=this.i.indexOf(a);0<=a&&yj(this,a)},this);this.Xb()};
-function yj(a,b){var c=a.i.splice(b,1)[0],d=a.b.a,e=eb(d,Yh||gb,c);0<=e&&Xa(d,e);b=a.a.indexOf(c);0<=b&&a.a.splice(b,1);a.u("onRemove",c)}f.reset=function(){this.vg=this.Sh=!1;zj(this);for(var a=this.i.length-1;0<=a;a--)yj(this,a);this.Xb();this.k=null};
-function Aj(a,b){if(a.vg&&!a.Sh)if(zj(a),P(b.state,2)){a.k=null;for(var c=[],d=0;d<a.a.length;d++){var e=a.a[d];e.active&&2147483647>e.end&&(c.push(e),a.a.splice(d--,1))}d=Ii(a.b,2147483646);d=d.concat(Ji(a.b,2147483646));e=[];if(c.length)for(var g=0;g<c.length;g++)e.push(["onExit",c[g]]);c=e.concat(Bj(a,d));for(d=0;d<c.length;d++)g=c[d],e=g[1],e.zb.u.apply(e.zb,g)}else P(b.state,16)?(a.g=Cj(a),a.j.stop(),a.j.start(),a.Xb()):(a.j.stop(),P(b.a,16)?(a.g=Cj(a),null!=Ki(a.b,Math.max(a.g-2E3,0))&&(a.Ng=
-Gi(v(a.Xb,a)))):a.Xb())}function Bj(a,b){var c=[];if(!b.length)return c;b.sort($h);for(var d=0;d<b.length;d++){var e=b[d];e.active&&-1==a.a.indexOf(e)&&(a.a.push(e),c.push(["onEnter",e]))}return c}
-f.Xb=function(){this.Fk=!0;if(!this.Gk)for(var a=3;this.Fk&&a;){this.Fk=!1;this.Gk=!0;if(this.vg&&!this.Sh){zj(this);for(var b=Cj(this),c=[],d=0;d<this.a.length;d++){var e=this.a[d];e.active&&!e.contains(b)&&(c.push(["onExit",e]),this.a.splice(d--,1))}d=Ii(this.b,b);e=this.o();!P(e,48)&&b>this.g&&(d=d.concat(Ji(this.b,this.g,b)));c=c.concat(Bj(this,d));this.g=b;!this.Sh&&this.k&&(c.unshift(["onLockBlockExit",this.k]),this.k=null,P(e,2)&&(this.g=2147483647));this.B()&&(b=Ki(this.b,this.g),null!=b&&
-(this.Ng=Gi(v(this.Xb,this),b-this.g)));for(d=0;d<c.length;d++)b=c[d],e=b[1],"onLockBlockExit"==b[0]||"onLockBlockEnter"==b[0]?this.u.apply(this,b):e.zb.u.apply(e.zb,b)}this.Gk=!1;a--}};function zj(a){null!=a.Ng&&(l.clearTimeout(a.Ng),a.Ng=null)}function Cj(a){return P(a.o(),2)?2147483647:1E3*a.A()}f.F=function(){this.j.removeEventListener("tick",this.Xb,!1,this);zj(this);this.k=this.b=this.a=this.i=null;xj.C.F.call(this)};function Dj(a,b){for(var c=a.split(b),d={},e=0,g=c.length;e<g;e++){var h=c[e].split("=");if(1==h.length&&h[0]||2==h.length){var k=ua(h[0]||""),h=ua(h[1]||"");k in d?t(d[k])?ab(d[k],h):d[k]=[d[k],h]:d[k]=h}}return d}function Ej(a,b){var c=[];Eb(a,function(a,b){var g=encodeURIComponent(String(b)),h;h=t(a)?a:[a];z(h,function(a){""==a?c.push(g):c.push(g+"="+encodeURIComponent(String(a)))})});return c.join(b)}function Fj(a){"?"==a.charAt(0)&&(a=a.substr(1));return Dj(a,"&")}
-function Gj(a){return-1!=a.indexOf("?")?(a=(a||"").split("#")[0],a=a.split("?",2),Fj(1<a.length?a[1]:a[0])):{}}function Hj(a){a=je([],a);a[0]="";return a.join("")}function S(a,b){return ge(je([a],b))}var Ij=ee;function Jj(){var a=ce(document.location.href);return ae(a[1],a[2],a[3],a[4])}function Kj(a,b){var c=a.split("#",2);a=c[0];var c=1<c.length?"#"+c[1]:"",d=a.split("?",2);a=d[0];var d=Fj(d[1]||""),e;for(e in b)d[e]=b[e];return S(a,d)+c};var Lj=null;"undefined"!=typeof XMLHttpRequest?Lj=function(){return new XMLHttpRequest}:"undefined"!=typeof ActiveXObject&&(Lj=function(){return new ActiveXObject("Microsoft.XMLHTTP")});function Mj(a){switch(a&&"status"in a?a.status:-1){case 0:case 200:case 201:case 202:case 203:case 204:case 205:case 206:case 304:return!0;default:return!1}};function Nj(a,b,c,d,e,g,h){var k=Lj&&Lj();if("open"in k){k.onreadystatechange=function(){4==(k&&"readyState"in k?k.readyState:0)&&b&&ff(b)(k)};c=(c||"GET").toUpperCase();d=d||"";k.open(c,a,!0);g&&(k.responseType=g);h&&(k.withCredentials=!0);g="POST"==c;if(e=Oj(a,e))for(var m in e)k.setRequestHeader(m,e[m]),"content-type"==m.toLowerCase()&&(g=!1);g&&k.setRequestHeader("Content-Type","application/x-www-form-urlencoded");k.send(d);return k}}
-function Oj(a,b){b=b||{};var c;if(c=cf("PAGE_CL"))if(c=cf("PAGE_BUILD_TIMESTAMP")){var d;d||(d=window.location.href);c=ce(a)[1]||null;var e=Ij(a);c&&e?(c=d,d=ce(a),c=ce(c),d=d[3]==c[3]&&d[1]==c[1]&&d[4]==c[4]):d=e?Ij(d)==e&&(Number(ce(d)[4]||null)||null)==(Number(ce(a)[4]||null)||null):!0;c=d||Pj(a)}c&&(b["X-YouTube-Page-CL"]=cf("PAGE_CL"),b["X-YouTube-Page-Timestamp"]=cf("PAGE_BUILD_TIMESTAMP"));return b}
-function Pj(a){var b=["X-YouTube-Page-CL","X-YouTube-Page-Timestamp"],c=cf("CORS_HEADER_WHITELIST")||{};a=Ij(a);if(!a)return!0;var d=c[a];return d?Ma(b,function(a){return Sa(d,a)}):!1}
-function Qj(a,b){var c=b.format||"JSON";b.rv&&(a=document.location.protocol+"//"+document.location.hostname+(document.location.port?":"+document.location.port:"")+a);var d=b.yf;d&&(a=Kj(a,d));var e=b.Lw||"";(d=b.Mf)&&u(e)&&(e=Fj(e),Ob(e,d),e=Hj(e));var g=!1,h,k=Nj(a,function(a){if(!g){g=!0;h&&I(h);var d=Mj(a),e=null;if(d||400<=a.status&&500>a.status)e=Rj(c,a);if(d)t:{switch(c){case "XML":d=0==parseInt(e&&e.return_code,10);break t;case "RAW":d=!0;break t}d=!!e}var e=e||{},k=b.Z||l;d?b.Qa&&b.Qa.call(k,
-a,e):b.onError&&b.onError.call(k,a,e);b.rd&&b.rd.call(k,a,e)}},b.method,e,b.headers,b.responseType,b.withCredentials);b.bl&&0<b.timeout&&(h=H(function(){g||(g=!0,k.abort(),I(h),b.bl.call(b.Z||l,k))},b.timeout));return k}function Rj(a,b){var c=null;switch(a){case "JSON":var d=b.responseText,e=b.getResponseHeader("Content-Type")||"";d&&0<=e.indexOf("json")&&(c=nb(d));break;case "XML":if(d=(d=b.responseXML)?Sj(d):null)c={},z(d.getElementsByTagName("*"),function(a){c[a.tagName]=Tj(a)})}return c}
-function Sj(a){return a?(a=("responseXML"in a?a.responseXML:a).getElementsByTagName("root"))&&0<a.length?a[0]:null:null}function Tj(a){var b="";z(a.childNodes,function(a){b+=a.nodeValue});return b}var Uj={html5_ajax:"action_get_html5_token",watch_actions_ajax:"action_get_watch_actions_token",addto_ajax:"action_get_wl_token"},Vj={html5_ajax:"html5_ajax_token",watch_actions_ajax:"watch_actions_ajax_token",addto_ajax:"addto_ajax_token"};
-function Wj(a,b,c,d,e){if(ef(a))d&&window.setTimeout(d,0);else{var g=Jj()+"/token_ajax",h={};b&&(h.By=b);c&&(h.Cy=c);h[Uj[a]]=1;Qj(g,{format:"RAW",method:"GET",yf:h,rd:function(b){var c=Fj(b.responseText),g=c[Vj[a]];g?(df(a,g),d&&d()):e&&e(b,c)}})}};function Xj(a){a=a.split("");a=Yj(a,11);a=a.reverse();a=Yj(a,29);a=a.slice(1);a=a.reverse();a=a.slice(3);return a.join("")}function Yj(a,b){var c=a[0];a[0]=a[b%a.length];a[b]=c;return a};function Zj(){this.lang=""};function ak(a,b,c,d,e,g){this.Pa=a;this.j=0<=b.indexOf("/mp4")?1:0<=b.indexOf("/webm")?2:0<=b.indexOf("/x-flv")?3:0;this.lb=b;this.a=g||0;this.i=c||null;this.b=d||null;this.g=e||null}function bk(a){return 2==a.j}function ck(a){return 0<=a.indexOf("opus")||0<=a.indexOf("vorbis")||0<=a.indexOf("mp4a")}function dk(a){return 0<=a.indexOf("vp9")||0<=a.indexOf("vp8")||0<=a.indexOf("avc1")};var ek={gy:"auto",WC:"tiny",ZB:"light",SMALL:"small",iC:"medium",LARGE:"large",EB:"hd720",DB:"hd1080",LB:"highres",aD:"unknown"};function fk(a,b,c){this.width=a;this.height=b;t:if(a||b){for(var d=1;d<gk.length;d++){var e=gk[d],g=hk[e];if(a>=g[0]||b>=g[1]){a=e;break t}}a="tiny"}else a="auto";this.i=a;this.a=c||0}var gk="auto highres hd1080 hd720 large medium small tiny".split(" "),hk={auto:[0,0],tiny:[256,144],light:[320,240],small:[320,240],medium:[640,360],large:[854,480],hd720:[1280,720],hd1080:[1920,1080],highres:[2048,1536]};function ik(a,b){this.start=a;this.end=b;this.length=b-a+1}function jk(a){a=a.split("-");return 2==a.length&&(a=new ik(parseInt(a[0],10),parseInt(a[1],10)),!isNaN(a.start)&&!isNaN(a.end)&&!isNaN(a.length)&&0<a.length)?a:null}function kk(a,b){return new ik(a,a+b-1)}ik.prototype.toString=function(){return this.start+"-"+(null==this.end?"":this.end)};var lk="corp.google.com youtube.com youtube-nocookie.com prod.google.com sandbox.google.com docs.google.com drive.google.com mail.google.com play.google.com googlevideo.com".split(" "),mk=["2mdn.net"],nk="www.google.com/aclk www.google.com/pagead/conversion googleadservices.com/aclk googleadservices.com/pagead/conversion googleads.g.doubleclick.net/aclk googleads.g.doubleclick.net/pagead/conversion".split(" ");function ok(){return-1!=document.location.toString().indexOf("/embed/")}
-function pk(a,b){return RegExp("^https?://([a-z0-9-]{1,63}\\.)*("+b.join("|").replace(/\./g,".")+")(:[0-9]+)?([/?#]|$)","i").test(a)}function qk(a){a=new qe(a);re(a,document.location.protocol);se(a,document.location.hostname);document.location.port&&te(a,document.location.port);return a.toString()};function rk(a,b,c,d,e,g,h,k,m){this.a=b;this.T=c;this.type=a;this.j=0<=d?d:-1;this.startTime=e||0;this.duration=g||0;this.nb=h||0;this.Ha=0<=k?k:NaN;this.b=!!m;this.T?(this.T=this.T,this.Ha=0<=this.Ha?this.Ha:this.T.length,this.g=this.nb+this.Ha==this.T.length,this.i=this.startTime+this.duration*this.nb/this.T.length,this.o=this.duration*this.Ha/this.T.length,this.k=this.i+this.o):this.g=!0}function sk(a){return 1==a.type||2==a.type}
-function tk(a,b){return a.a==b.a&&a.T.start+a.nb+a.Ha==b.T.start+b.nb}function uk(a){Fa(1==a.length||Ma(a,function(a){return!!a.T}));for(var b=1;b<a.length;b++);b=a[a.length-1];return new ik(a[0].T.start+a[0].nb,b.T.start+b.nb+b.Ha-1)}rk.prototype.yg=function(a){return this.a.yg(this,a)};function vk(a){return"i="+a.a.info.Pa+",r="+(a.T.start+a.nb)+"-"+(a.T.start+a.nb+a.Ha-1)+",t="+a.i.toFixed(1)+"-"+(a.i+a.o).toFixed(1)};function wk(a,b,c,d){this.info=a;this.buffer=b;this.T=c;this.a=d}function xk(a){return new DataView(a.buffer,a.T.start,a.T.length)}function yk(a){if(a.info.Ha!=a.T.length)return!1;if(1==a.info.a.info.j){if(8>a.info.Ha||4==a.info.type)return!0;var b=xk(a),c=b.getUint32(0,!1),b=b.getUint32(4,!1);if(2==a.info.type)return c==a.info.Ha&&1936286840==b;if(3==a.info.type&&0==a.info.nb)return 1836019558==b}return!0};function zk(a){this.a=a;this.b=0;this.g=-1}var Ak=0;function Bk(a,b){a.a=Kj(a.a,b)};function Ck(a,b){this.index=null;this.info=b;this.b=null;this.i=!1;this.j=new zk(a)}f=Ck.prototype;f.Po=function(){return!1};f.Yb=function(){return!1};f.Oj=function(){return!1};f.po=function(){return[]};f.yg=function(){return null};f.Vj=function(){return null};f.Oo=function(){};function Dk(a){this.b=a[0].a.j;this.a=a};function Ek(){this.R=0;this.a=new Float64Array(128);this.b=new Float32Array(128);this.g=!1}Ek.prototype.hb=function(){return this.R};function Fk(a,b){var c=eb(a.b.subarray(0,a.R),gb,b);return 0<=c?c:Math.max(0,-c-2)}function Gk(a){if(a.a.length<a.R+1){var b=2*a.a.length,b=b+2,c=a.a;a.a=new Float64Array(b+1);var d=a.b;a.b=new Float32Array(b+1);for(b=0;b<a.R+1;b++)a.a[b]=c[b],a.b[b]=d[b]}}function Hk(a,b){this.b=a;this.a=0;this.g=b||0}
-function Ik(a){for(var b=Jk(a,!1);236==b;)Kk(a),b=Jk(a,!1);return b}function Lk(a){var b=Jk(a,!0),c=a.b.byteOffset+a.a,d=Math.min(b,a.b.buffer.byteLength-c),c=new DataView(a.b.buffer,c,d),c=new Hk(c,a.g+a.a);a.a+=b;return c}function Mk(a){for(var b=Jk(a,!0),c=Nk(a),d=1;d<b;d++)c=(c<<8)+Nk(a);return c}function Kk(a){var b=Jk(a,!0);a.a+=b}function Jk(a,b){var c=Nk(a);if(1==c){for(var d=c=0;7>d;d++)c=256*c+Nk(a);return c}for(var e=128,d=0;6>d&&e>c;d++)c=256*c+Nk(a),e*=128;return b?c-e:c}
-function Nk(a){return a.b.getUint8(a.a++)};function Ok(a,b,c,d){Ck.call(this,a,b);this.o=c;this.k=d;this.g=null;this.index=new Ek;b=parseInt;c=a.search(ne);d=me(a,0,"clen",c);if(0>d)a=null;else{var e=a.indexOf("&",d);if(0>e||e>c)e=c;d+=5;a=ua(a.substr(d,e-d))}this.a=b(a,10)}y(Ok,Ck);f=Ok.prototype;f.Yb=function(){return!(!this.b||!this.index.hb())};
-f.po=function(a){var b=new rk(1,this,this.o),c=new rk(2,this,this.k),d=[],e=[b];tk(b,c)?e.push(c):d.push(new Dk([c]));isNaN(this.a)?a=0:a>this.a&&(a=this.a);b=e[e.length-1];c=b.T.end-e[0].T.start+1;a>c&&(a=kk(b.T.end+1,a-c),e.push(new rk(4,this,a)));d.push(new Dk(e));return d};
-f.Oo=function(a){if(1==a.info.type){if(this.b)return;this.b=new Uint8Array(a.buffer,a.T.start,a.T.length)}else if(2==a.info.type){if(this.g||this.index.hb())return;if(1==this.info.j){var b=this.index,c=xk(a),d=a.info.T.start;a=0;var e=c.getUint32(0,!1),g=c.getUint8(a+8);a+=12;var h=c.getUint32(a+4,!1);a+=8;var k;0==g?(g=c.getUint32(a,!1),k=c.getUint32(a+4,!1),a+=8):(g=(c.getUint32(a,!1)<<32)+c.getUint32(a+4,!1),k=(c.getUint32(a+8,!1)<<32)+c.getUint32(a+12,!1),a+=16);b.a[0]=k+(e+d);b.b[0]=g;b.g=!0;
-d=c.getUint16(a+2,!1);a+=4;for(e=0;e<d;e++){var m=c.getUint32(a,!1);k=c.getUint32(a+4,!1);a+=12;g=b;k=k/h;g.R++;Gk(g);g.a[g.R]=g.a[g.R-1]+m;g.b[g.R]=g.b[g.R-1]+k}}else this.g=xk(a)}if(bk(this.info)&&this.b&&this.g){c=new DataView(this.b.buffer,this.b.byteOffset,this.b.byteLength);b=this.index;e=this.g;a=new Hk(c);if(440786851==Ik(a)&&(Kk(a),408125543==Ik(a))){h=a;d=h.a;c=Jk(h,!0);h.a=d;a=Lk(a);h=a.g+a.a;for(m=Ik(a);357149030!=m;)Kk(a),m=Ik(a);a=Lk(a);g=1E6;k=1E9;for(d=0;!(a.a>=a.b.byteLength);)if(m=
-Ik(a),2807729==m)g=Mk(a);else if(2807730==m)k=Mk(a);else if(17545==m){var d=a,m=Jk(d,!0),p=0;4==m?p=d.b.getFloat32(d.a):8==m&&(p=d.b.getFloat64(d.a));d.a+=m;d=p}else Kk(a);g/=k;d*=g;a=new Hk(e);if(475249515==Ik(a)){for(a=Lk(a);!(a.a>=a.b.byteLength);)if(m=Ik(a),187==m){e=Lk(a);m=g;k=h;if(179!=Ik(e))m=null;else if(m*=Mk(e),183!=Ik(e))m=null;else{e=Lk(e);for(p=k;!(e.a>=e.b.byteLength);)241==Ik(e)?p=Mk(e)+k:Kk(e);m=[p,m]}e=b;k=m[0];m=m[1];Gk(e);e.a[e.R]=k;e.b[e.R]=m;e.R++}else Kk(a);a=d;c=c+h;Gk(b);
-b.g=!0;b.b[b.R]=a;b.a[b.R]=c}}this.g=null}};function Pk(a,b,c,d){for(var e=[];b<a.index.hb();b++){var g=kk(a.index.a[b],b+1<a.index.R||a.index.g?a.index.a[b+1]-a.index.a[b]:-1),h=a.index.b[b],k;k=a.index;var m=b;k=m+1<k.R||k.g?k.b[m+1]-k.b[m]:-1;var m=Math.max(0,c-g.start),p=Math.min(g.end+1,c+d)-(g.start+m),s=b==a.index.hb()-1&&m+p==g.length;e.push(new rk(3,a,g,b,h,k,m,p,s));if(g.start+m+p>=c+d)break}return new Dk(e)}
-function Qk(a,b){for(var c=0;c+1<a.index.hb()&&b.T.start>=a.index.a[c+1];)c++;return Pk(a,c,b.T.start,b.T.length).a}f.Oj=function(a){return this.Yb()?!0:isNaN(this.a)?!1:a.T.end+1<this.a};f.yg=function(a,b){this.Oj(a);if(!this.Yb()){var c=kk(a.T.end+1,b);c.end+1>this.a&&(c=new ik(c.start,this.a-1));c=[new rk(4,a.a,c)];return new Dk(c)}4==a.type&&(c=Qk(this,a),a=c[c.length-1]);var c=0,d=a.T.start+a.nb+a.Ha;3==a.type&&(c=a.j,d==a.T.end+1&&(c+=1));return Pk(this,c,d,b)};
-f.Vj=function(a,b){var c=Fk(this.index,a);return Pk(this,c,this.index.a[c],b)};f.Po=function(){return this.Yb()&&!isNaN(this.a)&&(this.index.g?this.index.a[this.index.R]:-1)!=this.a};function Rk(){this.duration=0;this.a={}}var Sk=/PT(([0-9]*)H)?(([0-9]*)M)?(([0-9.]*)S)?/;function Tk(a){var b=new Rk;z(a,function(a){var d=a.type,e=a.itag,g=null;dk(d)&&(g=a.size.split("x"),g=new fk(parseInt(g[0],10),parseInt(g[1],10)));var h=null;ck(d)&&(h=new Zj);d=new ak(e,d,h,g,null,parseInt(a.bitrate,10)/8);g=jk(a.init);h=jk(a.index);(a=Uk(a.url,d,a.s))&&(b.a[e]=new Ok(a,d,g,h))});return b}
-function Vk(a,b){for(var c=a;c;c=c.parentNode)if(c.attributes){var d=c.attributes[b];if(d)return d.value}return""}function Wk(a,b){for(var c=a;c;c=c.parentNode){var d=c.getElementsByTagName(b);if(0<d.length)return d[0]}return null}function Uk(a,b,c){if(!pk(a,lk))return"";b={alr:"yes",mime:b.lb.split(";")[0]};c&&(b.signature=Xj(c));return Kj(a,b)};function Xk(a,b,c,d,e,g,h,k,m){this.i={};this.o=a;this.H=b;this.b=c;this.a=d;this.g=e;this.A=g;this.j=h;this.k=k;this.B=m}function Yk(a,b){var c=a.A,c=c.replace("$N",a.j),c=c.replace("$L",a.B.toString()),c=c.replace("$M",b.toString());a.k&&(c=S(c,{sigh:a.k}));return c}function Zk(a,b){var c=Math.floor(b/(a.a*a.g)),d=a.a*a.g,e=b%d,g=e%a.a,e=Math.floor(e/a.a),h=a.g,k=a.b-d*c;k<d&&(h=Math.ceil(k/a.a));return{url:Yk(a,c),qu:g,yi:a.a,row:e,rows:h,bo:a.o*a.a,ao:a.H*h}};function $k(a){var b=[];a=a.split("|");for(var c=a[0],d,e,g,h,k,m,p,s,r=1;r<a.length;r++)d=a[r].split("#"),e=r-1,g=parseInt(d[0],10),h=parseInt(d[1],10),k=parseInt(d[2],10),m=parseInt(d[3],10),p=parseInt(d[4],10),s=d[6],d=d[7],b.push(new Xk(g,h,k,m,p,c,s,d,e));this.a=b;this.b={};1<this.a.length&&-1!=this.a[0].j.indexOf("default")&&this.a.splice(0,1)}function al(a,b){var c=a.a[0].b-1;return vb(Math.round(c*b),0,c)}
-function bl(a,b){var c=a.b[b];if(c)return c;for(var c=a.a.length,d=0;d<c;d++)if(a.a[d].o>=b)return a.b[b]=d;a.b[b]=c-1;return c-1};var cl={0:"MONO",1:"LEFT_RIGHT",2:"RIGHT_LEFT",3:"TOP_BOTTOM",4:"BOTTOM_TOP"};var dl={cC:1,dC:2,eC:3};var el;var fl=Yb(),fl=fl.toLowerCase();if(-1!=fl.indexOf("android")){var gl=fl.match(/android\D*(\d\.\d)[^\;|\)]*[\;\)]/);if(gl)el=Number(gl[1]);else{var hl={cupcake:1.5,donut:1.6,eclair:2,froyo:2.2,gingerbread:2.3,honeycomb:3,"ice cream sandwich":4,jellybean:4.1},il=fl.match("("+Hb(hl).join("|")+")");el=il?hl[il[0]]:0}}else el=void 0;var jl,kl;function ll(){var a=n("yt.player.utils.videoElement_");a||(a=document.createElement("video"),pa("yt.player.utils.videoElement_",a));return a}function ml(){if(2.2==el)return!0;var a=ll();try{return!(!a||!a.canPlayType||!a.canPlayType('video/mp4; codecs="avc1.42001E, mp4a.40.2"')&&!a.canPlayType('video/webm; codecs="vp8.0, vorbis"'))}catch(b){return!1}}
-function nl(){var a=Rc("div",{"class":"html5-player-css-loaded"});document.body.appendChild(a);var b="none"==md(a,"display");F(a);return b};function ol(){var a;if(void 0==jl&&(jl=!1,window.crypto&&window.crypto.qy))try{a=new Uint8Array(1),window.crypto.qy(a),jl=!0}catch(b){}if(jl){a=Array(16);var c=new Uint8Array(16);window.crypto.getRandomValues(c);for(var d=0;d<a.length;d++)a[d]=c[d]}else for(a=Array(16),c=0;16>c;c++){for(var d=x(),e=0;e<d%23;e++)a[c]=Math.random();a[c]=Math.floor(256*Math.random())}return a}
-function pl(){for(var a=ol(),b=[],c=0;c<a.length;c++)b.push("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-_".charAt(a[c]&63));return b.join("")}function ql(){return Ka(ol(),function(a){return(a&15).toString(16)}).join("")};function rl(a,b,c){b={cpn:b};c&&(b.ibw="1369843");return{url:S(a,b),type:"application/x-mpegURL",quality:"auto",itag:"93"}};function T(a,b){return void 0==b?a:"1"==b?!0:!1}function sl(a,b,c){for(var d in c)if(c[d]==b)return c[d];return a}function U(a,b){return void 0==b?a:b}function tl(a,b){var c=U(a,b);c&&(c=qk(c));return c}function ul(a){if(!a)return 0;a=a.split(":");var b=parseFloat(a[0]),c=1;2==a.length&&(c=parseFloat(a[1]));return isNaN(b)||isNaN(c)||0==c?0:b/c};function vl(a,b){this.a=a;this.b=b}vl.prototype.clone=function(){return new vl(this.a,this.b)};function wl(a){this.a=[];if(a)t:{var b,c;if(a instanceof wl){if(b=a.uc(),c=a.jc(),0>=a.hb()){a=this.a;for(var d=0;d<b.length;d++)a.push(new vl(b[d],c[d]));break t}}else b=Hb(a),c=Gb(a);for(d=0;d<b.length;d++)xl(this,b[d],c[d])}}function xl(a,b,c){var d=a.a;d.push(new vl(b,c));b=d.length-1;a=a.a;for(c=a[b];0<b;)if(d=b-1>>1,a[d].a>c.a)a[b]=a[d],b=d;else break;a[b]=c}f=wl.prototype;
-f.remove=function(){var a=this.a,b=a.length,c=a[0];if(!(0>=b)){if(1==b)Ua(a);else{a[0]=a.pop();for(var a=0,b=this.a,d=b.length,e=b[a];a<d>>1;){var g=2*a+1,h=2*a+2,g=h<d&&b[h].a<b[g].a?h:g;if(b[g].a>e.a)break;b[a]=b[g];a=g}b[a]=e}return c.b}};f.jc=function(){for(var a=this.a,b=[],c=a.length,d=0;d<c;d++)b.push(a[d].b);return b};f.uc=function(){for(var a=this.a,b=[],c=a.length,d=0;d<c;d++)b.push(a[d].a);return b};f.clone=function(){return new wl(this)};f.hb=function(){return this.a.length};
-f.isEmpty=function(){return Ta(this.a)};f.clear=function(){Ua(this.a)};function yl(){wl.call(this)}y(yl,wl);function zl(a){R.call(this);this.a=a;this.g=new yl;this.i={}}y(zl,R);zl.prototype.b=!1;function Al(a,b,c){var d;for(c=bl(a.a,c);0<=c;){d=a.a.a[c];if(d=d.i[Math.floor(b/(d.a*d.g))]?Zk(d,b):null)return d;c--}return Zk(a.a.a[0],b)}function Bl(a){if(!a.b)if(a.g.isEmpty())a.b=!1;else{a.b=!0;var b=a.g.remove(),c=new Image;c.src=Yk(a.a.a[b.xn],b.yn);c.onload=v(a.j,a,b.xn,b.yn)}}
-zl.prototype.j=function(a,b){this.b=!1;var c=this.a.a[a];c.i[b]=!0;Bl(this);var d,e=c.a*c.g;d=b*e;c=Math.min(d+e-1,c.b-1);d=[d,c];this.u("l",d[0],d[1])};function Cl(a,b,c){this.b=a;this.a=b;this.g=c}var Dl={playready:["com.youtube.playready"],widevine:["com.widevine.alpha"],clearkey:["org.w3.clearkey","webkit-org.w3.clearkey"]},El=["widevine","playready"];function Fl(a,b,c){if(!a.addKey&&!a.webkitAddKey)return null;for(var d=0;d<El.length;d++){var e=El[d];if(c[e])for(var g=Dl[e],h=0;h<g.length;h++){var k=g[h];if(a.canPlayType(b,k))return new Cl(e,k,c[e])}}return null};function Gl(a,b){this.a=a;this.b=b;this.i=0;Object.defineProperty(this,"timestampOffset",{get:this.Nu,set:this.Ou});Object.defineProperty(this,"buffered",{get:this.Mu})}f=Gl.prototype;f.append=function(a){this.a.webkitSourceAppend(this.b,a)};f.abort=function(){this.a.webkitSourceAbort(this.b)};f.Mu=function(){return this.a.webkitSourceState==this.a.SOURCE_CLOSED?new Hl:this.a.webkitSourceBuffered(this.b)};f.Nu=function(){return this.i};
-f.Ou=function(a){this.i=a;this.a.webkitSourceTimestampOffset(this.b,a)};function Hl(){this.length=0};function Il(a){this.activeSourceBuffers=this.sourceBuffers=[];this.a=a;this.b=NaN;this.g=0;Object.defineProperty(this,"duration",{get:this.Hu,set:this.Ku});Object.defineProperty(this,"readyState",{get:this.Iu});this.a.addEventListener("webkitsourceclose",v(this.Ju,this),!0)}function Jl(a){return window.MediaSource?new window.MediaSource:window.WebKitMediaSource?new window.WebKitMediaSource:HTMLMediaElement.prototype.webkitSourceAddId?new Il(a):null}f=Il.prototype;
-f.addEventListener=function(a,b,c){this.a.addEventListener(a,b,c)};f.mn=function(){return this.a.webkitMediaSourceURL};f.addSourceBuffer=function(a){var b=(this.g++).toString();this.a.webkitSourceAddId(b,a);a=new Gl(this.a,b);this.sourceBuffers.push(a);return a};
-f.removeSourceBuffer=function(a){for(var b in this.sourceBuffers)if(a===this.sourceBuffers[b]){this.a.webkitSourceRemoveId(a.b);for(a=b+1;a<this.sourceBuffers.length;a++)this.sourceBuffers[a-1]=this.sourceBuffers[a];this.sourceBuffers.pop();break}};f.Iu=function(){switch(this.a.webkitSourceState){case this.a.SOURCE_CLOSED:return"closed";case this.a.SOURCE_OPEN:return"open";case this.a.SOURCE_ENDED:return"ended"}return""};
-f.endOfStream=function(a){var b=this.a.EOS_NO_ERROR;"network"==a?b=this.a.EOS_NETWORK_ERR:"decode"==a&&(b=this.a.EOS_DECODE_ERR);this.a.webkitSourceEndOfStream(b)};f.Ju=function(){Ua(this.sourceBuffers)};f.Hu=function(){return this.b};f.Ku=function(a){this.b=a;this.a.webkitSourceSetDuration&&this.a.webkitSourceSetDuration(a)};function Kl(){this.a=[]}Kl.prototype.listen=function(a,b,c){if(t(b))for(var d=0;d<b.length;d++)this.listen(a,b[d],c);else c=v(c,this),a.addEventListener(b,c,!1),this.a.push(a,b,c)};Kl.prototype.removeAll=function(){if(this.a)for(;this.a.length;){var a=this.a.shift(),b=this.a.shift(),c=this.a.shift();a.removeEventListener&&a.removeEventListener(b,c)}};Kl.prototype.ha=function(){return null===this.a};Kl.prototype.dispose=function(){this.removeAll();this.a=null};function Ll(a,b,c,d){this.a=[];this.ud=this.Zb=null;this.i=b;this.g=Jl(a);this.b="";this.j=null;this.listen(this.g,["sourceopen","webkitsourceopen"],oa(this.Pt,d,c));this.listen(this.g,["sourceclose","webkitsourceclose"],this.Ot)}y(Ll,Kl);var Ml={};f=Ll.prototype;f.Va=function(a){this.isOpen()?this.g.duration=a:this.i=a};f.isOpen=function(){return"open"==this.g.readyState};f.Ib=function(){return"closed"==this.g.readyState};
-f.Pt=function(a,b){isNaN(this.i)||(this.g.duration=this.i,this.i=NaN,this.Zb=this.g.addSourceBuffer(a),this.ud=this.g.addSourceBuffer(b),this.j&&(this.j(this),this.j=null))};f.Ot=function(){this.dispose()};f.dispose=function(){Nl(this.b);this.b="";Ll.C.dispose.call(this)};function Nl(a){if(a)try{window.URL.revokeObjectURL(a)}catch(b){}}
-function Ol(a){if(window.MediaSource&&window.MediaSource.isTypeSupported)return window.MediaSource.isTypeSupported(a);'audio/mp4; codecs="mp4a.40.2"'==a&&(a='video/mp4; codecs="avc1.4d404f"');return!!ll().canPlayType(a)}
-function Pl(a,b){var c={};if(window.MediaSource&&window.MediaSource.isTypeSupported)Ka(a,function(a){c[a]=window.MediaSource.isTypeSupported(a)}),H(oa(b,c),0);else{for(var d=!1,e=0;e<a.length;e++){var g=Ml[a[e]];if(void 0!=g)c[a[e]]=g;else{d=!0;break}}if(d){var d=ll(),e=Jl(d),g=e.mn?e.a.webkitMediaSourceURL:window.URL.createObjectURL(e),h=oa(Ql,a,b,d,e,g);e.addEventListener("sourceopen",h,!1);e.addEventListener("webkitsourceopen",h,!1);d.src=g}else H(oa(b,c),0)}}
-function Ql(a,b,c,d,e){for(var g={},h=0;h<a.length;h++){var k=Ml[a[h]];if(void 0==k){try{var m=d.addSourceBuffer(a[h]);d.removeSourceBuffer(m);k=!0}catch(p){p.code==DOMException.NOT_SUPPORTED_ERR&&(k=!1)}Ml[a[h]]=k}g[a[h]]=k}c.src="";Nl(e);b(g)};function Rl(a,b,c,d){this.a=c;this.b=a;this.j=d||"";this.i=b;this.g={}}function hj(a){if(a.a)a=a.b;else if(a.i){var b;b=(new qe(a.b)).a.get("id");b="http://www.youtube.com/api/manifest/t2b/source/youtube/id/"+encodeURIComponent(b);b+="/itag/"+a.j;b+="/mfmt/amf";a=ve(new qe(S(a.b,a.g)),b).toString()}else a=S(a.b,a.g);return a};function Sl(a,b){var c=b.Pa in Tl&&bj();this.i=(this.a=!!(a instanceof Array))?null:new Rl(a,c,this.a,b.Pa);this.b=this.a?a[0]:null;this.g=this.a?a[1]:null;this.ye=b}Sl.prototype.getInfo=function(){return this.ye};Sl.prototype.We=function(){return this.ye.b.i};var Ul={'video/mp4; codecs="avc1.42001E, mp4a.40.2"':"maybe"},Vl={"application/x-mpegURL":"maybe"},Wl={"application/x-mpegURL":"maybe"};
-function Xl(a,b,c){if(!ml())return[];var d=Yl(a,b);a=!d.length&&b?Yl(a,!1):d;var e={};b=ll();c=c||(Ti||Ui&&cj("crkey")?!0:!1);for(d=0;d<a.length;d++){var g=a[d];if((b.canPlayType(g.getInfo().lb)||Zl(g))&&!(g.ye.Pa in $l||bj()&&"5"==g.ye.Pa)){var h=g.We();if(!e[h]||bk(g.getInfo())&&!c||!bk(g.getInfo())&&c)e[h]=g}}var k=[];z(gk,function(a){(g=e[a])&&k.push(g)});return k}function Zl(a){var b;a=a.getInfo().lb;Si?b=Wl[a]:2.2==el?b=Ul[a]:cj("android")&&cj("chrome")&&(b=Vl[a]);return b||""}
-var Tl={5:!0,34:!0,35:!0},$l={52:!0,53:!0,54:!0,55:!0,60:!0,79:!0,87:!0},am={zB:160,vB:133,xB:134,pB:135,lB:136,hB:137,qB:138,fB:140,wB:142,yB:143,sB:144,uB:222,tB:223,mB:145,oB:224,nB:225,iB:146,kB:226,jB:227,rB:147,gB:149,eB:261,AB:161,rD:171,qD:172,yD:194,vD:195,xD:220,wD:221,uD:196,tD:197,sD:198,CD:242,DD:243,BD:244,AD:247,zD:248};function bm(a){var b=[];z(a,function(a){a.url&&b.push(cm(a.url,a.type,"auto","0"))});return b}
-function cm(a,b,c,d,e){var g=new Zj;(c=hk[c])||(c=hk.small);e=new fk(c[0],c[1],e?-1:0);b=unescape(b.replace(/&quot;/g,'"'));return new Sl(a,new ak(d,b,g,e))}function Yl(a,b){for(var c=[],d=0;d<a.length;d++){var e=a[d],g;if(g=cc)if(g=0!=e.ye.b.a)g=1==e.getInfo().j;g||0!=e.ye.b.a==b&&c.push(e)}return c}
-function dm(a,b,c){for(var d=[],e=0;e<a.length;e++){var g=a[e];if(g.sig||g.s){var h=g.sig||Xj(g.s);g.url=Kj(g.url,{signature:h})}g.url&&d.push(cm(g.url,g.type,g.quality,g.itag,g.stereo3d))}return Xl(d,!!b,!!c)}function em(a,b){var c=bm(a);return Xl(c,!1,!!b)}function fm(a,b,c,d,e,g){if(a){var h=[];if(g){g={};for(var k in a.a)h=a.a[k].info.lb,g[h]=Ol(h);gm(a,b,c,d,e,g)}else{for(k in a.a)h.push(a.a[k].info.lb);Pl(h,v(gm,null,a,b,c,d,e))}}else c([])}
-function gm(a,b,c,d,e,g){var h=null,k={},m={},p;for(p in am){var s=am[p],r=a.a[s];if(r&&g[r.info.lb]&&!(0<=r.info.lb.indexOf("vp9")&&cj("cros armv7"))){if(r.info.g){h||(h=ll());if(!Fl(h,r.info.lb,r.info.g))continue;if(!e&&r.info.b&&(1280<=r.info.b.width||720<=r.info.b.height))continue;if(261==s)continue}if(s=0<r.info.lb.indexOf("/webm")?r.info.g?3:1:0<r.info.lb.indexOf("/mp4")?r.info.g?4:2:null){Bk(r.j,b);var D=r.info.i?k:m;D[s]=D[s]||[];D[s].push(r)}}}a=[3,4,1,2];d&&(a=[4,3,2,1]);d=null;for(p=0;p<
-a.length;p++)if(k[a[p]]&&m[a[p]]){d=a[p];break}a=[];if(null!=d)for(hb(k[d],"itag"),k=k[d].pop(),p=0;p<m[d].length;p++)a.push(new Sl([k,m[d][p]],m[d][p].info));fb(a,function(a,b){var c=a.getInfo(),d=b.getInfo();return d.b.height-c.b.height||d.a-c.a});c(a)};function mh(a){R.call(this);this.k=[];this.ga=new B(0,0);this.O=[];this.I=[];this.b={};this.ya={};this.i={};hm(this,a)}y(mh,R);var im=/\/img\/watermark\/youtube_(hd_)?watermark(-vfl\S{6})?.png$/,jm="author cc_asr cc_load_policy iv_new_window iv_load_policy keywords subscribed rvs title ttsurl ypc_buy_url ypc_full_video_length ypc_item_thumbnail ypc_item_title ypc_item_url ypc_offer_button_text ypc_offer_description ypc_offer_headline ypc_offer_id ypc_price_string ypc_preview ypc_video_rental_bar_text".split(" ");
-f=mh.prototype;f.ca=!1;f.Ao=!0;f.cb=!1;f.Sk="";f.Rk="";f.Qk="";f.Fj=!1;f.Ch=1;f.Cn=!1;f.rm=0;f.we=0;f.uo=!1;f.zk=!1;f.Lm=3;f.ni="";f.Da="";f.Tk=!1;f.kg=!1;f.jm=!1;f.rf=0;f.Ze=!1;f.Tm=!1;f.cg=0;f.kf=!1;f.km=!0;f.rj=!1;f.Gn=!1;f.Fb=!1;f.Bk=!1;f.Qd=!1;f.In=!1;f.Ck=!1;f.bk=0;f.ta=0;f.xh=0;f.jk=!1;f.Bl="";f.im=!1;f.ij=!1;f.tm=0;f.lm=!1;f.Sm=!1;f.xa=0;f.gj=null;f.mf=null;f.Ej=!1;f.If=!1;f.nf=null;f.gk=1;f.Ce=0;f.El=null;f.nm=!1;f.Jj=0;f.Im=NaN;
-function Jh(a,b){var c=b||{};c.iv_read_url&&(a.Sk=qk(c.iv_read_url));c.iv_invideo_url&&(a.Rk=qk(c.iv_invideo_url));c.iv_cta_url&&(a.Qk=qk(c.iv_cta_url));a.author=U(a.author,c.author);a.zk=T(a.zk,c.cc_asr);a.ni=tl(a.ni,c.ttsurl);a.Da=U(a.Da,c.cpn);a.g=U(a.g,c.subscribed);a.title=U(a.title,c.title);a.ia=U(a.ia,c.ypc_preview);a.jk=T(a.jk,c.paygated);c.keywords&&(a.ya=km(c.keywords));c.rvs&&(a.Qc=lm(c.rvs));c.poster&&(a.Bl=c.poster);z(jm,function(a){a in c&&(this.b[a]=c[a])},a)}
-function hm(a,b){var c=b||{};a.cb="1"!=c.hlsdvr||Vi||Si&&5>Wi?!1:!0;a.Fj="1"==c.infringe||"1"==c.muted;a.Fn=c.authkey;a.Ea=c.authuser;a.Da||(a.Da=c.cpn||pl());a.Nc=c.csi_page_type;a.Na=c.sw;a.Ta=T(a.Ta,c.dto);a.nd=c.t;a.Tk=T(a.Tk,c.cenchd);a.kg="1"==c.enable_cardio;a.jm="1"==c.enable_cardio_before_playback;a.rf=void 0==(c.end||c.endSeconds)?a.rf:Number(c.end||c.endSeconds);a.km="1"!=c.no_get_video_log;a.rj="1"==c.tmi;a.Gn="1"==c.livemonitor;a.Fb="1"==c.live_playback;a.Bk=T(a.Bk,c.mdx);a.Ck=T(a.Ck,
-c.utpsa);a.Co=c.iurlmaxres;a.G=U(a.G,c.oauth_token);a.U=U(a.U,c.vvt);a.md=c.osig;a.ib=c.ptchn;a.oc=c.oid;a.A=c.ptk;a.mc=c.pltype;a.eb=c.plid;a.j=c.eventid;a.Oa=U(a.Oa,c.list);a.nc=c.pyv_beacon_url;a.ue=c.purchase_id;a.ja=c.sdetail;a.te=c.sourceid;a.aa=U(a.aa,c.feature);a.bb=1==(void 0==c.is_fling?a.bb?1:0:Number(c.is_fling));a.ma=U(a.ma,c.ytr);a.Do=c.iurlsd;a.nm="1"==c.skip_kansas_logging;a.mf=sl(a.mf,c.vq||c.suggestedQuality,ek);a.ve=c.approx_threed_layout||0;a.Ej="1"==c.threed_converted;a.Li=c.iurl;
-a.ij="1"==c.sendtmp;a.lm=!!a.Na||a.ij;a.xa=void 0==(c.start||c.startSeconds)?a.xa:Number(c.start||c.startSeconds);a.L=c.docid||c.video_id||c.videoId;mm(a,c.watermark);a.Mc=U(a.Mc,c.ypc_gid);a.Jc=U(a.Jc,c.ypc_license_session_token);if(c.ad3_module||c.ad_module)"1"==c.allow_html5_ads?(a.ca=!0,"1"==c.ad_preroll&&a.I.push("ad")):"1"==c.supported_without_ads||c.cta&&c.fexp&&(-1!=c.fexp.indexOf("924604")||-1!=c.fexp.indexOf("924610"))||(a.Tm=!0);c.adaptive_fmts&&(a.Sa=nm(a,c.adaptive_fmts));c.allow_embed&&
-(a.Ao="1"==c.allow_embed);c.autoplay&&(a.kf="1"==c.autoplay);c.iv_load_policy&&(a.fa=om(c.iv_load_policy,a.fa));c.cc_load_policy&&(a.Lm=om(c.cc_load_policy,2));c.dash&&void 0===a.X&&(a.X="1"==c.dash);if(c.dashmpd){a.M=S(c.dashmpd,{cpn:a.Da});var d=/\/s\/([0-9A-F.]+)/,e=d.exec(a.M);e&&(e=Xj(e[1]),a.M=a.M.replace(d,"/signature/"+e))}c.delay&&(a.K=Ca(c.delay));c.idpj&&(a.cg=Ca(c.idpj));c.url_encoded_fmt_stream_map&&(a.O=nm(a,c.url_encoded_fmt_stream_map));c.hlsvp&&(d=rl(c.hlsvp,a.Da,c.fexp&&-1!=c.fexp.indexOf("934005")&&
-!c.on3g),a.O.push(d));c.length_seconds&&(a.ta=Ca(c.length_seconds));c.ldpj&&(a.xh=Ca(c.ldpj));c.loudness&&(a.za=c.loudness,a.Ch=-15<a.za&&0>a.za?Math.pow(10,(-18-a.za)/20):1);c.partnerid&&(a.pd=Ca(c.partnerid));c.pyv_billable_url&&pk(c.pyv_billable_url,nk)&&(a.P=c.pyv_billable_url);c.pyv_conv_url&&pk(c.pyv_conv_url,nk)&&(a.Ka=c.pyv_conv_url);c.url_encoded_third_party_media&&(a.nf=lm(c.url_encoded_third_party_media));c.threed_module&&!c.threed_converted&&(a.Q=c.threed_module,a.Lc=6);if("1"==c.track_embed||
-c.tk)a.im=!0;c.watch_ajax_token&&df("watch_actions_ajax",c.watch_ajax_token);c.fresca_preroll&&a.I.push("fresca");c.ypc_clickwrap_module&&a.I.push("ypc_clickwrap");void 0!=c.start&&(a.Jj=c.start);void 0!=c.end&&(a.Im=c.end);a.Kc=U(a.Kc,c.ucid);z(["baseUrl","uid","oeid","ieid","ppe"],function(a){this.i[a]=c[a]},a);a.i.focEnabled="1"==c.focEnabled;a.i.rmktEnabled="1"==c.rmktEnabled;a.rm=pm(c.rmktPingThreshold,c.length_seconds);a.b=c;Jh(a,c);a.X&&qm(a)}
-function qm(a){if(cj("android")&&cj("chrome")&&!rc(29)?0:window.MediaSource||window.WebKitMediaSource||HTMLMediaElement.prototype.webkitSourceAddId)if(a.Sa)a.B=Tk(a.Sa);else if(a.M){var b={format:"RAW",method:"GET",Z:a,Qa:a.ax,onError:a.wl};a.Ze=!0;a=qk(a.M);Qj(a,b)}}
-f.ax=function(a){if(!this.ha()){if(200<=a.status&&400>a.status){var b=new Rk;t:{a=a.responseText;a=(new DOMParser).parseFromString(a,"text/xml").getElementsByTagName("MPD")[0];var c;if(c=Vk(a,"mediaPresentationDuration")){var d=Sk.exec(c);c=d?3600*parseFloat(d[2]||0)+60*parseFloat(d[4]||0)+parseFloat(d[6]||0):parseFloat(c)}else c=0;b.duration=c;a=a.getElementsByTagName("Representation");for(c=0;c<a.length;c++){var d=a[c],e=Vk(d,"id"),g=Vk(d,"mimeType"),h=Vk(d,"codecs"),g=h?g+'; codecs="'+h+'"':g,
-h=parseInt(Vk(d,"bandwidth"),10)/8,k=null;dk(g)&&(k=new fk(parseInt(Vk(d,"width"),10),parseInt(Vk(d,"height"),10)));var m=null;ck(g)&&(m=new Zj);var p=null,s=Wk(d,"ContentProtection");if(s)if((p=s.attributes.schemeIdUri)&&"http://youtube.com/drm/2012/10/10"==p.textContent)for(p={},s=s.firstChild;null!=s;s=s.nextSibling)"yt:SystemURL"==s.nodeName&&(p[s.attributes.type.textContent]=s.textContent.trim());else p=null;e=new ak(e,g,m,k,p,h);g=Uk(Wk(d,"BaseURL").textContent,e);h=Wk(d,"SegmentBase");d=jk(h.attributes.indexRange.value);
-h=jk(h.getElementsByTagName("Initialization")[0].attributes.range.value);d=new Ok(g,e,h,d);if(!d){a=!1;break t}b.a[d.info.Pa]=d}a=!0}if(this.B=a?b:null)this.ta=this.B.duration||this.ta}this.wl()}};f.wl=function(){this.ha()||(this.Ze=!1,this.u("dataloaded",this.b))};function rm(a,b,c,d){fm(a.B,sm(a),v(function(a){this.ha()||(a.length?(this.k=a,this.u("dataupdated"),b()):(this.X=!1,tm(this,b,c)))},a),c,a.Tk,d)}
-function tm(a,b,c){a.k=a.nf&&a.In?em(a.nf,c):dm(a.O,!!a.Q||a.If,c);H(v(function(){this.ha()||(this.u("dataupdated"),b&&b())},a),0)}function um(a){a=Ka(a.k,function(a){return a.We()});db(a);return a.concat(["auto"])}function vm(a,b){var c=null;a.k.some(function(a){if(a.We()==b)return c=a,!0});return c}function wm(a){var b=a.o&&a.o.i;if(!b)return null;w(b.g,sm(a));return b}function sm(a){var b={};a.A&&(b.ptk=a.A,b.oid=a.oc,b.ptchn=a.ib,b.pltype=a.mc);return b}
-function xm(a,b){return u(a.ya[b])?a.ya[b]:null}function ym(a){!a.El&&a.b.storyboard_spec&&(a.El=new $k(a.b.storyboard_spec));return a.El}function zm(a){var b=ym(a);!a.gj&&b&&(a.gj=new zl(b),L(a,a.gj));return a.gj}function Am(a,b){var c={format:"RAW",method:"GET",Z:a,Qa:a.rx};a.Ze=!0;Qj(b,c)}f.rx=function(a){this.ha()||(this.Ze=!1,a=Fj(a.responseText),"fail"==a.status?this.u("onStatusFail",a):(hm(this,a),this.Ze||this.wl()))};function om(a,b){var c=parseInt(a,10);return Ib(dl,c)?c:b}
-function lm(a){a=a.split(",");return a=a.map(function(a){return Fj(a)})}function nm(a,b){var c=lm(b);z(c,function(a){a.url&&(a.url=S(a.url,{cpn:this.Da}))},a);return c}function km(a){var b={};z(a.split(","),function(a){var d=a.split("=");2==d.length?b[d[0]]=d[1]:b[a]=!0});return b}function mm(a,b){if(b){var c=b.split(",");2<=c.length&&(a.Ma=c[1],a.Oc=c[0])}}function Bm(a,b){return!!a.b[b]}function pm(a,b){var c=Ca(b),d=Ca(a);return isNaN(d)||isNaN(c)?0:Math.min(d,c)};function Cm(a,b){this.type=a||"";this.id=b||""}Cm.prototype.toString=function(){return this.type+this.id};function Dm(a){R.call(this);this.a=[];this.b=[];this.ua=Math.max(0,a.index||0);this.loop=!!a.loop;this.xa=a.startSeconds||0;this.Mn="1"==a.mob;this.title=a.playlist_title||"";a.video_id&&(this.a[this.ua]=new mh(a));a.api&&("string"==typeof a.api&&16==a.api.length?a.list="PL"+a.api:a.playlist=a.api);if(a.list)switch(a.listType){case "user_uploads":Em(this,a.list);break;case "user_favorites":Fm(this,a.list);break;case "search":Gm(this,a.list);break;default:a.playlist_length&&(this.Mb=a.playlist_length),
-this.g=new Cm(a.list.substr(0,2),a.list.substr(2)),this.Yg||Hm(this,"/list_ajax?style=json&action_get_list=1",{list:this.g})}else if(a.playlist){var b=a.playlist.toString().split(",");0<this.ua&&(this.a=[]);z(b,function(a){a&&this.a.push(new mh({video_id:a}))},this);this.Mb=this.a.length;this.Zd=!0}else a.videoList&&(0<this.ua&&(this.a=[]),z(a.videoList,function(a){this.a.push(new mh(a))},this),this.Mb=this.a.length,this.Zd=!0);xh(this,!!a.shuffle);a.suggestedQuality&&(this.i=a.suggestedQuality)}
-y(Dm,R);f=Dm.prototype;f.loop=!1;f.xa=0;f.Jo=!1;f.ua=0;f.title="";f.Mb=0;f.Mn=!1;f.Zd=!1;f.Yg=!1;f.Ae=null;function Im(a){if(++a.ua>=a.Mb)if(a.loop)a.ua=0;else return null;wh(a,a.ua);return vh(a,a.ua)}function Jm(a){if(0>--a.ua)if(a.loop)a.ua=a.Mb-1;else return null;wh(a,a.ua);return vh(a,a.ua)}function vh(a,b){var c=void 0!=b?b:a.ua;if(c=a.a&&c in a.a?a.a[a.b[c]]:null)c.xa=a.xa||c.Jj||0;return c}
-function xh(a,b){a.Jo=b;var c=a.b&&null!=a.b[a.ua]?a.b[a.ua]:a.ua;a.b=[];for(var d=0;d<a.a.length;d++)a.b.push(d);a.ua=c;if(a.Jo){c=a.b[a.ua];for(d=1;d<a.b.length;d++){var e=Math.floor(Math.random()*(d+1)),g=a.b[d];a.b[d]=a.b[e];a.b[e]=g}for(d=0;d<a.b.length;d++)a.b[d]==c&&(a.ua=d)}a.u("shuffle")}function wh(a,b){a.ua=vb(b,0,a.Mb-1);a.xa=0}function Km(a){return a.Mb}function Em(a,b){a.Yg||(a.g=new Cm("UU","PLAYER_"+b),Hm(a,"/list_ajax?style=json&action_get_user_uploads_by_user=1",{username:b}))}
-function Fm(a,b){a.Yg||(a.g=new Cm("FL","PLAYER_"+b),Hm(a,"/list_ajax?style=json&action_get_favorited_by_user=1",{username:b}))}function Gm(a,b){if(!a.Yg){a.g=new Cm("SR",b);var c={search_query:b};a.Mn&&(c.mob="1");Hm(a,"/search_ajax?style=json&embeddable=1",c)}}function Hm(a,b,c){Qj(S(b,c),{format:"JSON",Qa:function(a,b){Lm(this,b)},Z:a})}
-function Lm(a,b){if(b.video&&b.video.length){a.title=b.title;a.description=b.description;a.views=b.views;a.author=b.author;var c=vh(a);a.ua=0;a.a=[];z(b.video,function(a){a&&(a.video_id=a.encrypted_id,c&&a.video_id==c.L&&(this.ua=this.a.length),this.a.push(new mh(a)))},a);a.Mb=a.a.length;xh(a,!1);a.Yg=!1;a.Zd=!0;a.Ae&&a.Ae()}}f.F=function(){this.Ae=null;Tg(this.a);Dm.C.F.call(this)};var Mm=!!l.DOMTokenList,Nm=Mm?function(a){return a.classList}:function(a){a=a.className;return u(a)&&a.match(/\S+/g)||[]},Om=Mm?function(a,b){return a.classList.contains(b)}:function(a,b){return Sa(Nm(a),b)},V=Mm?function(a,b){a.classList.add(b)}:function(a,b){Om(a,b)||(a.className+=0<a.className.length?" "+b:b)},Pm=Mm?function(a,b){z(b,function(b){V(a,b)})}:function(a,b){var c={};z(Nm(a),function(a){c[a]=!0});z(b,function(a){c[a]=!0});a.className="";for(var d in c)a.className+=0<a.className.length?
-" "+d:d},W=Mm?function(a,b){a.classList.remove(b)}:function(a,b){Om(a,b)&&(a.className=Ja(Nm(a),function(a){return a!=b}).join(" "))},Qm=Mm?function(a,b){z(b,function(b){W(a,b)})}:function(a,b){a.className=Ja(Nm(a),function(a){return!Sa(b,a)}).join(" ")};function X(a,b,c){c?V(a,b):W(a,b)}function Rm(a,b){var c=!Om(a,b);X(a,b,c);return c};function Sm(a,b){this.Zf=a;this.jf=b+"::"}y(Sm,Pf);f=Sm.prototype;f.Zf=null;f.jf="";f.set=function(a,b){this.Zf.set(this.jf+a,b)};f.get=function(a){return this.Zf.get(this.jf+a)};f.remove=function(a){this.Zf.remove(this.jf+a)};f.Nd=function(a){var b=this.Zf.Nd(!0),c=this,d=new Rd;d.next=function(){for(var d=b.next();d.substr(0,c.jf.length)!=c.jf;)d=b.next();return a?d.substr(c.jf.length):c.Zf.get(d)};return d};function Tm(a){R.call(this);this.a=a;if(this.zl){a="yt-html5-player-modules::"+this.zl;var b=new Rf;if(a=b.isAvailable()?a?new Sm(b,a):b:null)this.o=new Tf(a)}}y(Tm,R);f=Tm.prototype;f.qa="";f.hd="";f.je=!1;f.ba=!1;f.Bc=null;f.zf=function(a){var b=$a(arguments),c=v(this.xc,this),d=v(this.$c,this);z(b,function(a){a.namespace=this.qa;a.zb.D("onEnter",c);a.zb.D("onExit",d)},this);this.u("command_add_cuerange",b,this.a.a)};f.qv=function(a){var b=$a(arguments);this.u("command_remove_cuerange",b,this.a.a)};
-function Um(a){a.u("command_remove_cuerange_all",a.qa,a.a.a)}function Vm(a){a.u("command_preroll_ready",a.qa,a.a.a)}function Wm(a,b){V(b,a.qa);a.a.app.S.U.appendChild(b)}function Xm(a){a.u("command_show_dialog_area")}function Ym(a){a.u("command_hide_all_dialogs")}f.create=function(){var a=this.qa+"-created";this.Xa(this.a);Om(Q(this.a),a);V(Q(this.a),a);this.je=!0};f.destroy=function(){this.unload();W(Q(this.a),this.qa+"-created");this.je=!1};
-f.load=function(){V(Q(this.a),this.qa+"-loaded");this.u("loaded",this.qa)};f.unload=function(){W(Q(this.a),this.qa+"-loaded");this.u("unloaded",this.qa)};f.xc=function(){};f.$c=function(){};f.oe=function(){};f.log=function(a){this.u("command_log",this.hd,a)};function Zm(a,b,c){var d={},e;for(e in b)d[a.qa+"_"+e]=b[e];b={};for(var g in c)b[a.qa+"_"+g]=c[g];a.u("command_log_timing",d,b)}f.Ri=function(){return null};
-function $m(a,b){if(!a.o)return null;var c;try{c=a.o.get(b)}catch(d){a.o&&a.o.remove(b)}return c}function an(a,b,c){if(a.o)try{a.o.set(b,c)}catch(d){}}function bn(a,b){a.u("command_disable_controls",b,a.qa)}function cn(a,b){a.u("command_enable_controls",b,a.qa)}function dn(a){a.u("command_stop_redirect_controls")}function en(a){a.u("command_play",!1,a.a.a)}function fn(a){a.u("command_pause",!1,a.a.a)}f.kb=function(a){this.u("command_redirected_show_is_playing",a)};f.nq=function(){};f.hp=function(){return[]};
-f.Xa=function(){return!1};f.Ho=function(a,b){this.Bc&&this.Bc.oe&&this.Bc.oe.apply(this.Bc,arguments)};f.Zh=function(){};function gn(a,b){this.a=a;this.zb=b;this.Kf=E("html5-endscreen",Q(this.a));V(this.Kf,this.Dl);this.Tf=E("html5-endscreen-content",Q(this.a))}f=gn.prototype;f.Dl="base-endscreen";f.Kf=null;f.Tf=null;f.zb=null;f.je=!1;f.create=function(){this.je=!0};f.destroy=function(){this.je=!1};f.load=function(){};function hn(a){this.a={};this.g={};this.i={};this.b=jn(this,a)}y(hn,K);function jn(a,b,c){var d=0,e=Uc(b[d++]);if(u(b[d])||t(b[d])||null===b[d]){var g=b[d++];t(g)&&(g=g.join(" "));if(g=kn(a,e,"className",g))ln(a,e,"className",g),mn(a,g,e)}for(;d<b.length;d++){var h=b[d];if(t(h))jn(a,h,e);else if(ia(h)){var g=a,k=e,m=void 0;for(m in h)h[m]&&ln(g,k,m,kn(g,k,m,h[m]))}else u(h)&&ln(a,e,"child",kn(a,e,"child",h))}c&&c.appendChild(e);return e}f=hn.prototype;f.N=function(){return this.b};
-function mn(a,b,c){var d=b.split(" ");if(1<d.length)for(b=0;b<d.length;b++)mn(a,d[b],c);else a.a[b]=c}f.V=function(a,b){q(b)?a.insertBefore(this.b,a.childNodes[b]||null):a.appendChild(this.b)};f.Jk=function(){F(this.b)};function kn(a,b,c,d){return u(d)&&"{{"==d.substr(0,2)?(a.g[d]=[b,c],null):d}f.update=function(a){for(var b in a)nn(this,b,a[b])};function nn(a,b,c){if(c!=a.i[b]){var d=a.g["{{"+b+"}}"];d&&(a.i[b]=c,ln(a,d[0],d[1],c))}}
-function ln(a,b,c,d){if("child"==c){Xc(b);if(!t(d)||t(d)&&u(d[0]))d=[d];c=[];for(var e=0;e<d.length;e++){var g=d[e];null===g||(!g.nodeType||1!=g.nodeType&&3!=g.nodeType?t(g)&&u(g[0])?c.push(jn(a,g)):g.N?c.push(g.N()):c.push(Vc(g.toString())):c.push(g))}for(a=0;a<c.length;a++)b.appendChild(c[a])}else"className"==c?b.className=d:null===d?b.removeAttribute(c):b.setAttribute(c,d.toString())}f.F=function(){this.a={};this.g={};this.i={};this.Jk();this.b=null;hn.C.F.call(this)};function on(a){a&&(a.style.display="block")}function pn(a){a&&(a.style.display="none")}function qn(a,b){var c=Ve("requestAnimationFrame",window);return H(function(){c?c.call(window,a):a()},b||0)};function Z(a){this.template=new hn(a);L(this,this.template);this.element=this.template.N();this.H="block";this.K=[];this.A={}}y(Z,K);f=Z.prototype;f.N=function(){return this.element};f.V=function(a,b){this.template.V(a,b)};f.Jk=function(){this.template.Jk()};f.Aa=function(a){nn(this.template,"content",a)};f.show=function(){var a=this.element;a&&(a.style.display=this.H);this.element.removeAttribute("aria-hidden")};f.hide=function(){pn(this.element);this.element.setAttribute("aria-hidden","true")};
-f.listen=function(a,b,c,d,e){a=J(a,b,v(c,d||this));this.K.push(a);u(e)&&this.A[e].push(a);return a};f.dc=function(a){uf(a)};f.stopPropagation=function(a){this.listen(this,a,function(a){a.stopPropagation()})};f.addEventListener=function(a,b,c){this.element.addEventListener?this.element.addEventListener(a,b,c):this.element.attachEvent&&this.element.attachEvent("on"+a,b)};
-f.removeEventListener=function(a,b,c){this.element.removeEventListener?this.element.removeEventListener(a,b,c):this.element.detachEvent&&this.element.detachEvent("on"+a,b)};f.dispatchEvent=function(a){return this.element.dispatchEvent(a)};f.fireEvent=function(a,b){return this.element.fireEvent(a,b)};f.F=function(){this.dc(this.K);this.element=null;Z.C.F.call(this)};function rn(){Z.call(this,["div","",["div","ytp-channel-banner-container",["img","ytp-channel-banner",{src:"{{banner}}"}],["div","ytp-subscribe-curtain"]],["div","ytp-subscribe-card",["img","ytp-author-image",{src:"{{image}}"}],["div","ytp-subscribe-card-right",["div","ytp-author-name","{{author}}"],["div","html5-subscribe-button-container"]]]])}y(rn,Z);function sn(a,b,c,d,e,g,h){a&&(a={video_id:a,html5:1,page_subscribe:b?1:0},g&&(a.authuser=g),h&&(a.pageid=h),Qj("/get_video_metadata",{method:"GET",onError:d,Qa:c,yf:a,Z:e}))};function tn(a,b){gn.call(this,a,b);this.b=new rn;this.b.V(this.Kf);sn(this.a.getVideoData().L,!0,this.g,ba,this,this.a.J().Ea,this.a.J().Ua)}y(tn,gn);tn.prototype.Dl="subscribecard-endscreen";
-tn.prototype.g=function(a,b){var c=b.user_info,d=this.a.getVideoData();d&&(d.va=c.external_id);nn(this.b.template,"banner",c.channel_banner_url);nn(this.b.template,"image",c.channel_logo_url||c.image_url);nn(this.b.template,"author",c.channel_title||c.username);d=b.video_info;d.subscription_ajax_token&&df("subscription_ajax",d.subscription_ajax_token);c=c.subscription_button_html;this.b.template.a["html5-subscribe-button-container"].innerHTML=c?c:""};function un(a,b,c){c=c||{};var d=c.Kb;d||(d=document.createElement("style"),document.getElementsByTagName("head")[0].appendChild(d),d=d.sheet||d.styleSheet);c.reset&&vn(d);b=b instanceof Array?b.join(";"):b;d.insertRule?d.insertRule(a+"{"+b+"}",d.cssRules.length):d.addRule(a,b,-1);return d}function vn(a){for(var b=(a.cssRules||a.rules).length;0<b;b--){var c=a;c.deleteRule?c.deleteRule(0):c.removeRule(0)}};function wn(a){this.W=a}y(wn,K);wn.prototype.b=null;wn.prototype.g=null;wn.prototype.a=null;function xn(a){a.b||(a.b=E("ad-container",Q(a.W)),a.W.J().ub&&V(a.b,"ad-container-single-media-element"));return a.b}function yn(a){a.a&&(a.W.J().ub?(W(a.a,"ad-video"),zn(a.W.app,a.a),a.a=null):(F(a.a),mj(a.a)))}
-function An(a){if(!a.g){if(a.W.J().Gb){var b=Uc("button");V(b,"video-click-tracking");Wc(b,lf("VISIT_ADVERTISERS_SITE"));var c=Uc("div");V(c,"video-click-tracking-container");c.appendChild(b);xn(a).appendChild(c)}else b=Uc("div"),Pm(b,["video-click-tracking","ad-video"]),xn(a).appendChild(b);a.g=b}return a.g}wn.prototype.F=function(){wn.C.F.call(this);this.a&&(zn(this.W.app,this.a),this.a=null);yn(this);Xc(xn(this));Xc(An(this));this.g=this.b=null;delete this.W};
-function Bn(a){if(!a.a){var b;b=a.W.app;if(b.a.ub){var c=new A(b.i.offsetLeft,b.i.offsetTop),d=Bd(b.i);b.M=new Cb(c.x,c.y,d.width,d.height);Cn(b.j);nj(b.i,1);mj(b.i);b=b.i}else b=Dn.getTag();a.a=b;Pm(a.a,["video-stream","ad-video"])}return a.a};function En(a,b,c,d){Z.call(this,["div",{className:"ytp-button",role:"button","aria-label":"{{label}}","aria-disabled":"{{disabled}}",tabindex:"{{tabindex}}"},"{{content}}"]);this.H="inline-block";this.g=a;this.M=this.a=this.o=null;this.j=!1;this.listen(this.element,"click",this.$u);this.listen(this.element,"keypress",this.av);a=this.g;var e=v(this.Zu,this);a.a&&Fn(a.a,this.element,e);b&&Gn(this,b);c&&this.Jb(c);d&&(this.a=d)}y(En,Z);
-function Gn(a,b){b&&""!=b&&(a.o&&W(a.element,a.o),a.o=b,V(a.element,b))}f=En.prototype;f.Jb=function(a){nn(this.template,"label",a)};function Hn(a,b){a.M=b;nn(a.template,"tabindex",b)}f.Zu=function(){return this.j?null:this.a?Vc(this.a):null};f.enable=function(){this.j=!1;this.template.update({disabled:null,tabindex:this.M});W(this.element,"ytp-disabled")};f.disable=function(){this.j=!0;this.template.update({disabled:"true",tabindex:null});V(this.element,"ytp-disabled")};
-f.$u=function(a){this.j&&(a.stopImmediatePropagation(),a.preventDefault())};f.av=function(a){if(13==a.keyCode||32==a.keyCode)a.stopPropagation(),a.preventDefault(),Af(this.element,"click")};f.F=function(){var a=this.g;if(a.a){var a=a.a,b=ja(this.element);Sg(a.a[b]);a.a[b]=null}this.g=null;En.C.F.call(this)};function In(a,b){Z.call(this,["canvas"]);this.element.width=a;this.element.height=b;this.width=a;this.height=b;this.Z=this.element.getContext("2d");this.a=0;this.j=null}y(In,Z);In.prototype.g=function(a,b){I(this.a);this.a=qn(v(this.g,this,a,b),b);a.call(this,new Date-this.j)};In.prototype.F=function(){I(this.a);this.Z=null;In.C.F.call(this)};function Jn(){In.call(this,84,84);this.b=this.width/2;this.o=this.height/2;this.i=Kn}y(Jn,In);var Kn=3*Math.PI/2,Ln=2*Math.PI;function Mn(a,b){var c=b*Ln+Kn;a.Z.beginPath();a.Z.arc(a.b,a.o,40,a.i,c,!1);a.Z.lineWidth=4;a.Z.strokeStyle="#b8b8b8";a.Z.stroke();a.i=c}
-Jn.prototype.show=function(){Jn.C.show.call(this);this.Z.globalAlpha=0.8;this.Z.beginPath();this.Z.arc(this.b,this.o,42,0,Ln);this.Z.fillStyle="#333";this.Z.fill();var a=35*(Math.sqrt(3)/2);this.Z.save();this.Z.fillStyle="#fff";this.Z.globalAlpha=0.9;this.Z.translate(a,this.b);this.Z.beginPath();this.Z.lineTo(0,a/2);this.Z.lineTo(28,0);this.Z.lineTo(0,-a/2);this.Z.closePath();this.Z.fill();this.Z.restore();Mn(this,0)};function Nn(a){var b=Math.floor(a/86400),c=Math.floor(a%86400/3600),d=Math.floor(a%3600/60);a=Math.floor(a%60);var e="";0<b&&(e+=b+":",10>c&&(e+="0"));0<c&&(e+=c+":",10>d&&(e+="0"));e+=d+":";10>a&&(e+="0");return e+a};var On={PC:"html5-stop-propagation",pA:"html5-chromeless",$B:"html5-live-dvr-disabled",aC:"html5-live-dvr-engaged",bC:"html5-live-playback",jC:"html5-mobile",lC:"modest-branding",nC:"html5-native-controls",UC:"html5-tablet",TC:"html5-tablet-body",gC:"html5-main-video",eD:"html5-video-container",fD:"html5-video-content",gD:"html5-video-controls",hD:"ytp-fallback",iD:"ytp-fallback-content",kD:"html5-video-loader",pD:"html5-watermark",Zz:"html5-branded-watermark",oD:"html5-viewport-sheet",vA:"html5-context-menu",
-ks:"html5-context-menu-copy-debug-info",ls:"html5-context-menu-copy-embed-html",ms:"html5-context-menu-copy-video-url",os:"html5-context-menu-copy-video-url-at-current-time",rs:"html5-context-menu-link",ts:"html5-context-menu-report-playback-issue",us:"html5-context-menu-show-video-info",wA:"html5-show-video-info-template",kC:"html5-modal-panel",RB:"html5-info-bar",Tz:"autohide-off",Uz:"autohide-on",Sz:"autohide-fade",Qz:"autohide-auto",Rz:"autohide-embeds",Vz:"autohide-seekbar",Pz:"autohide-aspect",
-FB:"hide-controls",GB:"hide-info-bar",HB:"html5-hide-share",IB:"html5-hide-volume",nD:"video-thumbnail",yC:"html5-popup-dialog",Jz:"html5-async-progress",Kz:"html5-async-success",Iz:"html5-async-error",kA:"html5-center-overlay",IC:"ytp-scalable-icon-shrink",HC:"ytp-scalable-icon-grow",MB:"house-brand"};function Pn(a,b){(a=Jc(a))&&a.style&&(a.style.display=b?"":"none",Ec(a,"hid",!b))}function Qn(a){return(a=Jc(a))?!("none"==a.style.display||Dc(a,"hid")):!1}function Rn(a){z(arguments,function(a){Pn(a,!0)})}function Sn(a){z(arguments,function(a){Pn(a,!1)})}function Tn(a){var b=document.body;if(void 0!=b.style[a])return a;a=a.charAt(0).toUpperCase()+a.substr(1);for(var c=["Moz","Webkit","ms","O"],d=0;d<c.length;d++)if(void 0!=b.style[c[d]+a])return c[d]+a}
-function Un(a,b,c){(a=Jc(a))&&a.style&&(b=Tn(b))&&(a.style[b]=c)};var Vn=window.location.protocol+"//i.ytimg.com/",Wn=4/3;function Xn(a,b,c){var d;switch(b.pd){case 30:d=Yn;break;default:d=Zn}return d(a,b,c)}function Zn(a,b,c){if(!c){c=a.clientHeight;a=a.clientWidth;if((900<a||600<c)&&b.Co)return b.Co;if((430<a||320<c)&&b.Do)return b.Do}return b.Li?b.Li:b.L?$n(b.L):""}function Yn(a,b){return b.Li?b.Li:b.L?S("//docs.google.com/vt",{id:b.L,authuser:b.Ea,authkey:b.Fn}):"//docs.google.com/images/doclist/cleardot.gif"}
-function $n(a,b){return(Vn+"vi/"+escape(a)+"/"+escape(b||"hqdefault.jpg")).replace("i.","i"+(a.charCodeAt(0)%cf("THUMBNAIL_NUM_SHARDS",1)+1)+".")};function ao(a,b,c){this.b=a;(a=b||null)||(a=bo(this.b));a="("+a.join("|")+")";a=ta("__%s__",a);this.g=RegExp(a,"g");this.a=c||{}}var co=/__([a-z]+(?:_[a-z]+)*)__/g;function eo(a,b){var c=Jc(a).innerHTML,c=c.replace(/^\s*(\x3c!--\s*)?/,""),c=c.replace(/(\s*--\x3e)?\s*$/,"");return new ao(c,b,void 0)}function bo(a){var b=[],c={};a.replace(co,function(a,e){e in c||(c[e]=!0,b.push(e))});return b}
-function fo(a,b,c,d){var e=v(function(a,e){c&&(e=c(e));return d?b[e]||this.a[e]||"":va(b[e]||this.a[e]||"")},a);return a.b.replace(a.g,e)};function go(a,b){this.W=a;this.H=b;var c=E("videowall-still-content-template",Q(this.W));this.B=eo(c);c=Uc("a");c.tabIndex=0;V(c,"videowall-still");J(c,"click",v(this.ov,this));J(c,"keypress",v(this.pv,this));this.a=c;this.o=this.W.app.S.B}f=go.prototype;
-f.update=function(a,b){this.g=a.feature_type||"endscreen";this.j=a.id||a.video_id;this.i=a.list;var c=!1,d=!1;a.endscreen_autoplay||("episodic"==this.g?d=!0:this.i&&(c=!0));var e=Lb(a);c||d?(e.index=parseInt(e.index,10)+1,e.title||(e.title=a.playlist_title,e.author=a.playlist_author),e.playlist_length||(e.playlist_length=0)):e.duration=Nn(a.length_seconds);var g=$n(c&&a.thumbnail_ids?a.thumbnail_ids.split(",")[0]:this.j,b?"hqdefault.jpg":"mqdefault.jpg");this.a.style.backgroundImage="url("+g+")";
-this.a.innerHTML=fo(this.B,e,void 0,!0);X(this.a,"videowall-still-featured",!!a.featured);X(this.a,"videowall-still-list",c);X(this.a,"videowall-still-episodic",d)};f.N=function(){return this.a};f.select=function(a){this.i?ho(this.W.app,this.j,a||this.g,this.i):ho(this.W.app,this.j,a||this.g)};f.Cu=function(){var a=new Date-this.A;1E4>a?(Mn(this.b,a/1E4),a=1E4-a,E("videowall-still-listlabel-autoplay-message",this.a).innerHTML=mf("AUTOPLAY_MESSAGE",Math.ceil(a/1E3))):(hf(this.k),this.select("autoplay"))};
-f.Du=function(a){var b=gd(a.target,"videowall-still-listlabel-autoplay"),c=E("autoplay-play-canvas",this.a);V(b,"videowall-still-listlabel-autoplay-hide");V(c,"autoplay-play-canvas-hide");X(this.a,"videowall-still-autoplay",!1);a.stopPropagation();this.H.log({cancelButtonClick:"1"});hf(this.k)};f.ov=function(){this.select()};f.pv=function(a){switch(a.keyCode){case 13:case 32:this.select(),a.preventDefault()}};function io(a,b,c){gn.call(this,a,b);this.ll=[];this.zb.D("onResize",this.Tv,this);this.zb.D("videodatachange",this.Uv,this);this.b=c}y(io,gn);f=io.prototype;f.Dl="videowall-endscreen";f.ph=null;f.rb=null;f.ll=null;f.dp=!1;f.qh=0;f.create=function(){io.C.create.call(this);this.rb=this.a.getVideoData().Qc;jo(this)};f.destroy=function(){this.Tf.innerHTML="";delete this.rb;io.C.destroy.call(this)};
-f.load=function(){if(this.rb&&this.rb.length&&this.rb[0].endscreen_autoplay){var a=ko(this,0);a.b=new Jn;V(a.b.element,"autoplay-play-canvas");a.b.V(a.a);a.b.show();X(a.a,"videowall-still-autoplay",!0);var b=E("videowall-still-listlabel-autoplay",a.a),c=new En(a.o);c.V(b);Gn(c,"videowall-still-listlabel-autoplay-cancel");c.Aa(a.o.getMsg("YTP_BUTTON_CANCEL"));c.show();J(c,"click",v(a.Du,a));a.H.log({cancelButtonShow:"1"});a.A=new Date;a.k=gf(v(a.Cu,a),50)}};
-function jo(a){if(a.rb&&a.rb.length){X(a.Kf,"endscreen-enable-layout",!0);a.Tf.innerHTML="";var b=Bd(a.Kf);Om(Q(a.a),"ad-showing")&&(b.height-=200);b.height-=30;var c=Math.floor(b.width/158),d=Math.floor(b.height/(158/1.45));if(1>d||1>c)a.qh=0;else{var e=a.rb.length,g=!1,h="episodic"==a.rb[0].feature_type,k=a.rb[0].endscreen_autoplay;(a.rb[0].featured||h||k)&&2<d&&2<c&&(g=!0,e+=3);X(a.Tf,"feature-video",g);for(var k=h=0,m=Ab(b),p=!0;0<=e&&(h<c||k<d);){var s=e>=k,r=e>=h;if(p&&r||!s&&r)e-=h,k++;else if(s)e-=
-k,h++;else break;p=1.45*(h/k)>m}a.dp=p;c=new B(h,k);a.dp?(d=1/c.width,b=b.width*d,d=b/1.45):(d=1/c.height,d*=b.height,b=1.45*d);b=new B(Math.floor(b),Math.floor(d));a.qh=c.width*c.height;g&&(a.qh-=3);a.ph&&vn(a.ph);g=lo(b);d={Kb:a.ph};a.ph=un(".videowall-still",g,d);g=lo(b.clone().scale(2));d.Kb=a.ph;un(".feature-video .videowall-still:first-child",g,d);zd(a.Tf,b.width*c.width,b.height*c.height)}g=0;for(b=a.qh;g<b;g++)c=ko(a,g),a.Tf.appendChild(c.N());X(a.Kf,"endscreen-enable-layout",!1)}}
-function ko(a,b){var c=a.ll[b];c||(c=new go(a.a,a.b),a.ll[b]=c);c.update(a.rb[b],0==b&&a.rb[0].featured);return c}function lo(a){return["width:"+a.width+"px","height:"+a.height+"px"]}f.Tv=function(){jo(this)};f.Uv=function(){var a=this.a.getVideoData().Qc;this.rb!=a&&(this.rb=a,jo(this))};function mo(a){Tm.call(this,a);a.J().yl?this.Sf=new tn(this.a,this.H):a.J().wc?this.Sf=new io(this.a,this.H,this):this.Sf=new gn(this.a,this.H)}y(mo,Tm);f=mo.prototype;f.qa="endscreen";f.hd="end";f.Sf=null;function no(a){var b=a.J(),c=a.getVideoData();a=1==O(a.app).B;return oo(b)&&!Bm(c,"ypc_module")&&a}f.Xa=function(a){return no(a)};
-f.create=function(){mo.C.create.call(this);var a=Math.max(1E3*(this.a.getVideoData().ta-10),0),a=new Zh(a,2147483647,{id:"preload"}),b=new Zh(2147483647,2147483647,{id:"load",priority:6});this.zf(a,b)};f.destroy=function(){Um(this);this.Sf.destroy();mo.C.destroy.call(this)};f.load=function(){mo.C.load.call(this);this.Sf.load();this.ba=!0};f.unload=function(){mo.C.unload.call(this);this.ba=!1};f.xc=function(a){mo.C.xc.call(this,a);"preload"==a.getId()?this.Sf.create():po(this.a.app)||this.load()};
-f.$c=function(a){"load"==a.getId()&&this.unload();mo.C.$c.call(this,a)};function qo(a){return no(a)?new mo(a):null};var ro={created:1,ready:2,testing:4,"testing-starting":3,live:6,"live-starting":5,complete:8,"complete-starting":7};/*
- Portions of this code are from MochiKit, received by
- The Closure Authors under the MIT license. All other code is Copyright
- 2005-2009 The Closure Authors. All Rights Reserved.
-*/
-function so(a,b){this.o=[];this.M=a;this.K=b||null;this.k=this.g=!1;this.j=void 0;this.G=this.kv=this.A=!1;this.H=0;this.i=null;this.B=0}so.prototype.cancel=function(a){if(this.g)this.j instanceof so&&this.j.cancel();else{if(this.i){var b=this.i;delete this.i;a?b.cancel(a):(b.B--,0>=b.B&&b.cancel())}this.M?this.M.call(this.K,this):this.G=!0;this.g||this.a(new to)}};so.prototype.I=function(a,b){this.A=!1;uo(this,a,b)};function uo(a,b,c){a.g=!0;a.j=c;a.k=!b;vo(a)}
-function wo(a){if(a.g){if(!a.G)throw new xo;a.G=!1}}so.prototype.b=function(a){wo(this);uo(this,!0,a)};so.prototype.a=function(a){wo(this);uo(this,!1,a)};function yo(a,b,c,d){a.o.push([b,c,d]);a.g&&vo(a);return a}function zo(a){var b=new so;yo(a,b.b,b.a,b);return b}function Ao(a){return La(a.o,function(a){return ha(a[1])})}
-function vo(a){a.H&&a.g&&Ao(a)&&(l.clearTimeout(a.H),delete a.H);a.i&&(a.i.B--,delete a.i);for(var b=a.j,c=!1,d=!1;a.o.length&&!a.A;){var e=a.o.shift(),g=e[0],h=e[1],e=e[2];if(g=a.k?h:g)try{var k=g.call(e||a.K,b);q(k)&&(a.k=a.k&&(k==b||k instanceof Error),a.j=b=k);b instanceof so&&(d=!0,a.A=!0)}catch(m){b=m,a.k=!0,Ao(a)||(c=!0)}}a.j=b;d&&(yo(b,v(a.I,a,!0),v(a.I,a,!1)),b.kv=!0);c&&(a.H=l.setTimeout(Qb(b),0))}function xo(){qa.call(this)}y(xo,qa);xo.prototype.message="Deferred has already fired";
-xo.prototype.name="AlreadyCalledError";function to(){qa.call(this)}y(to,qa);to.prototype.message="Deferred was canceled";to.prototype.name="CanceledError";function Bo(a,b){var c=b||{},d=c.document||document,e=Uc("SCRIPT"),g={Uo:e,vc:void 0},h=new so(Co,g),k=null,m=null!=c.timeout?c.timeout:5E3;0<m&&(k=window.setTimeout(function(){Do(e,!0);h.a(new Eo(1,"Timeout reached for loading script "+a))},m),g.vc=k);e.onload=e.onreadystatechange=function(){e.readyState&&"loaded"!=e.readyState&&"complete"!=e.readyState||(Do(e,c.iv||!1,k),h.b(null))};e.onerror=function(){Do(e,!0,k);h.a(new Eo(0,"Error while loading script "+a))};Mc(e,{type:"text/javascript",charset:"UTF-8",
-src:a});Fo(d).appendChild(e);return h}function Fo(a){var b=a.getElementsByTagName("HEAD");return!b||Ta(b)?a.documentElement:b[0]}function Co(){if(this&&this.Uo){var a=this.Uo;a&&"SCRIPT"==a.tagName&&Do(a,!0,this.vc)}}function Do(a,b,c){null!=c&&l.clearTimeout(c);a.onload=ba;a.onerror=ba;a.onreadystatechange=ba;b&&window.setTimeout(function(){F(a)},0)}function Eo(a,b){var c="Jsloader error (code #"+a+")";b&&(c+=": "+b);qa.call(this,c);this.code=a}y(Eo,qa);function Go(a,b){this.b=new qe(a);this.a=b?b:"callback";this.vc=5E3}var Ho=0;Go.prototype.send=function(a,b,c,d){a=a||null;d=d||"_"+(Ho++).toString(36)+x().toString(36);l._callbacks_||(l._callbacks_={});var e=this.b.clone();if(a)for(var g in a)a.hasOwnProperty&&!a.hasOwnProperty(g)||Fe(e,g,a[g]);b&&(l._callbacks_[d]=Io(d,b),Fe(e,this.a,"_callbacks_."+d));b=Bo(e.toString(),{timeout:this.vc,iv:!0});yo(b,null,Jo(d,a,c),void 0);return{Ba:d,kc:b}};
-Go.prototype.cancel=function(a){a&&(a.kc&&a.kc.cancel(),a.Ba&&Ko(a.Ba,!1))};function Jo(a,b,c){return function(){Ko(a,!1);c&&c(b)}}function Io(a,b){return function(c){Ko(a,!0);b.apply(void 0,arguments)}}function Ko(a,b){l._callbacks_[a]&&(b?delete l._callbacks_[a]:l._callbacks_[a]=ba)};function Lo(a){R.call(this);this.g=fo(new ao("http://gdata.youtube.com/feeds/api/users/live/broadcasts/__video_id__/states?v=2&alt=json-in-script"),{video_id:a});this.a=new Ei(15E3+Math.floor(3E4*Math.random()));this.a.addEventListener("tick",v(this.b,this));this.b();this.a.start()}y(Lo,R);Lo.prototype.F=function(){this.a.dispose();Lo.C.F.call(this)};Lo.prototype.b=function(){(new Go(this.g)).send(null,v(this.j,this),v(this.i,this))};
-Lo.prototype.j=function(a){this.u("payload",a);Fi(this.a,15E3+Math.floor(3E4*Math.random()))};Lo.prototype.i=function(){this.u("error");var a=this.a.a;192E4>a&&Fi(this.a,2*a)};function Mo(){this.g=new hn(["div","html5-fresca-module",["div","html5-fresca-band-slate",["hgroup","html5-fresca-message",["h2","html5-fresca-heading","{{heading}}"],["h3","html5-fresca-subheading","{{subheading}}"],["h4","html5-fresca-long-test","{{long_text}}"]],["span","html5-fresca-countdown","{{countdown}}"]]]);L(this,this.g);this.b=this.g.a["html5-fresca-module"];V(this.b,"html5-stop-propagation");this.i=0;this.a=null}y(Mo,K);Mo.prototype.N=function(){return this.b};
-Mo.prototype.update=function(a){if(!this.k||this.a.state!=a.state||this.a.startTime!=a.startTime||this.a.b!=a.b||this.a.a.join()!=a.a.join()){this.a=a;this.b.style.backgroundImage=this.a.b||"none";a=this.a.a;if(!a.length){t:switch(this.a.state){case 6:a="";break t;case 8:case 7:a=lf("FRESCA_COMPLETE_MESSAGE");break t;default:a=lf("FRESCA_STAND_BY_MESSAGE")}a=[a]}this.g.update({heading:a[0]||"",subheading:a[1]||"",long_text:a[2]||""});this.j()}};
-function No(a){var b=Math.floor((new Date).valueOf()/1E3);return b>a?lf("FRESCA_STARTING_SOON_MESSAGE"):Nn(a-b)}Mo.prototype.j=function(){var a;a=this.a;a.startTime?(a=a.state,a=6==a||8==a||7==a?!1:!0):a=!1;X(this.b,"html5-fresca-show-countdown",a);a&&(this.g.update({countdown:No(this.a.startTime)}),I(this.i),this.i=H(v(this.j,this),1E3))};Mo.prototype.F=function(){I(this.i);this.b=null;Mo.C.F.call(this)};function Oo(a){this.a=[];a&&Po(this,a)}Oo.prototype.state=-1;function Po(a,b){var c=b.feed;if(c){var d=c.yt$lifeCycleState;d&&(a.state=ro[d.$t]||-1);(d=c.yt$when)&&d.start&&(d=new Date(d.start),a.startTime=Math.floor(d.valueOf()/1E3));if(c=c.yt$slate)c.imgUrl&&(a.b="url("+c.imgUrl+")"),(c=c.content)&&c.length&&(c=c.splice(0,3),a.a=Ka(c,function(a){return a.$t}))}};function Qo(a){Tm.call(this,a)}y(Qo,Tm);f=Qo.prototype;f.qa="fresca";f.hd="fresca";f.hi=!1;f.Pg=!1;f.Xa=function(){return Bm(this.a.getVideoData(),"fresca_module")};f.create=function(a){Qo.C.create.call(this);this.hi=this.Pg=!1;cn(this,["play_pause","seek"]);this.i=new Mo;this.a.app.S.g.appendChild(this.i.N());this.g=a||new Lo(this.a.getVideoData().L);this.g.D("payload",this.Su,this);this.g.D("error",this.Ru,this);this.D("onStateChange",this.xo,this)};
-f.destroy=function(){this.ba&&this.unload();this.$("onStateChange",this.xo,this);Tg(this.g,this.i);Qo.C.destroy.call(this)};f.load=function(){Qo.C.load.call(this);this.ba=!0};f.unload=function(){this.ba=!1;Qo.C.unload.call(this)};f.xo=function(a){this.b&&(this.hi=P(a.state,2),(Ro(a,16)||this.hi)&&So(this,this.b))};f.Ru=function(){this.Pg||(this.b=new Oo,So(this,this.b))};f.Su=function(a){this.b=new Oo(a);6!=this.b.state||this.a.getVideoData().O.length?So(this,this.b):this.a.Xj(this.a.getVideoData().L)};
-function So(a,b){var c=6>b.state;!c&&a.a.app.b.ga&&(b.b||b.a.length)&&(c=!0);a.hi&&!a.a.J().wc&&(c=!0);if(!a.Pg)switch(b.state){case 6:a.Pg=!0;cn(a,["play_pause","seek"]);Vm(a);break;case 8:case 7:c=a.Pg=!0}c&&a.i.update(b);c&&!a.ba?a.load():!c&&a.ba&&a.unload()}function To(a){return Bm(a.getVideoData(),"fresca_module")?new Qo(a):null};function Uo(a){this.Og=a||window;this.ee=[]}f=Uo.prototype;f.Og=null;f.ee=null;f.listen=function(a,b,c,d){c=v(c,d||this.Og);a=J(a,b,c);this.ee.push(a);return a};function Vo(a,b,c,d){d=v(d,a.Og);b=vf(b,c,d);a.ee.push(b);return b}function Wo(a,b,c){c=v(c,a.Og);b=yf(b,c,"yt-uix-button-menu-item");a.ee.push(b)}f.dc=function(a){uf(a);Wa(this.ee,a)};f.removeAll=function(){uf(this.ee);this.ee=[]};function Xo(a,b,c){this.a=a;this.i=b||0;this.b=c;this.g=v(this.du,this)}y(Xo,K);f=Xo.prototype;f.Ba=0;f.F=function(){Xo.C.F.call(this);this.stop();delete this.a;delete this.b};f.start=function(a){this.stop();this.Ba=Gi(this.g,q(a)?a:this.i)};f.stop=function(){0!=this.Ba&&l.clearTimeout(this.Ba);this.Ba=0};f.du=function(){this.Ba=0;this.a&&this.a.call(this.b)};var Yo={},Zo=null;function $o(a){a=ja(a);delete Yo[a];Kb(Yo)&&Zo&&Zo.stop()}function ap(){Zo||(Zo=new Xo(function(){bp()},20));var a=Zo;0!=a.Ba||a.start()}function bp(){var a=x();Eb(Yo,function(b){cp(b,a)});Kb(Yo)||ap()};function dp(){Bi.call(this);this.a=0;this.k=this.startTime=null}y(dp,Bi);f=dp.prototype;f.yk=function(){this.Kd("begin")};f.Qi=function(){this.Kd("end")};f.rd=function(){this.Kd("finish")};f.onStop=function(){this.Kd("stop")};f.Kd=function(a){Ci(this,a)};function ep(a,b,c,d){dp.call(this);if(!t(a)||!t(b))throw Error("Start and end parameters must be arrays");if(a.length!=b.length)throw Error("Start and end points must be the same length");this.g=a;this.o=b;this.duration=c;this.j=d;this.b=[]}y(ep,dp);f=ep.prototype;f.ed=0;
-function fp(a){if(0==a.a)a.ed=0,a.b=a.g;else if(1==a.a)return;$o(a);var b=x();a.startTime=b;-1==a.a&&(a.startTime-=a.duration*a.ed);a.k=a.startTime+a.duration;a.ed||a.yk();a.Kd("play");-1==a.a&&a.Kd("resume");a.a=1;var c=ja(a);c in Yo||(Yo[c]=a);ap();cp(a,b)}f.stop=function(a){$o(this);this.a=0;a&&(this.ed=1);gp(this,this.ed);this.onStop();this.Qi()};f.F=function(){0==this.a||this.stop(!1);this.Kd("destroy");ep.C.F.call(this)};f.destroy=function(){this.dispose()};
-function cp(a,b){a.ed=(b-a.startTime)/(a.k-a.startTime);1<=a.ed&&(a.ed=1);gp(a,a.ed);1==a.ed?(a.a=0,$o(a),a.rd(),a.Qi()):1==a.a&&a.ql()}function gp(a,b){ha(a.j)&&(b=a.j(b));a.b=Array(a.g.length);for(var c=0;c<a.g.length;c++)a.b[c]=(a.o[c]-a.g[c])*b+a.g[c]}f.ql=function(){this.Kd("animate")};f.Kd=function(a){Ci(this,new hp(a,this))};function hp(a,b){ai.call(this,a);this.x=b.b[0];this.y=b.b[1];this.duration=b.duration;this.state=b.a}y(hp,ai);var ip=/#(.)(.)(.)/;function jp(a){if(!kp.test(a))throw Error("'"+a+"' is not a valid hex color");4==a.length&&(a=a.replace(ip,"#$1$1$2$2$3$3"));a=a.toLowerCase();return[parseInt(a.substr(1,2),16),parseInt(a.substr(3,2),16),parseInt(a.substr(5,2),16)]}var kp=/^#(?:[0-9a-f]{3}){1,2}$/i;function lp(a,b,c,d,e){ep.call(this,b,c,d,e);this.element=a}y(lp,ep);lp.prototype.i=ba;lp.prototype.ql=function(){this.i();lp.C.ql.call(this)};lp.prototype.Qi=function(){this.i();lp.C.Qi.call(this)};lp.prototype.yk=function(){this.i();lp.C.yk.call(this)};function mp(a,b,c,d,e){if(2!=b.length||2!=c.length)throw Error("Start and end points must be 2D");lp.apply(this,arguments)}y(mp,lp);
-mp.prototype.i=function(){this.element.style.left=Math.round(this.b[0])+"px";this.element.style.top=Math.round(this.b[1])+"px"};function np(a){return a*a*a}function op(a){return 1-Math.pow(1-a,3)};function pp(a,b,c,d,e){this.qb=a;this.element=b;this.i=c;this.g=d;this.Me=e;this.Ib=this.a=!1;this.jl=!0}function qp(a,b){b.D("onHideControls",function(){this.jl=!1;this.kh()},a);b.D("onShowControls",function(){this.jl=!0;this.kh()},a);b.D("onResize",a.kh,a)}
-function rp(a,b){var c=Rc("div","annotation-x-button-container"),d=Rc("div","annotation-x-button");c.appendChild(d);a.i.listen(c,"click",v(function(a){var c=this.Me,d=this.qb;d&&d.i&&c.log_(sp(c,d,4));b(a);a.stopPropagation();this.Ib=!0},a));return c}f=pp.prototype;f.N=function(){return this.element};f.show=function(){};f.hide=function(){};f.destroy=function(){F(this.element)};f.kh=function(){};function tp(a,b,c,d,e){pp.call(this,a,b,c,d,e);this.b=Rc("div","invideo-video-text-container");this.j=!1}y(tp,pp);function up(a){var b=new mp(a.element,[a.element.offsetLeft,a.element.offsetTop],[a.element.offsetLeft,a.element.offsetTop-a.element.offsetHeight],300,op);ri(b,"begin",v(function(){this.a=!0},a));fp(b)}
-function vp(a){var b=new mp(a.element,[a.element.offsetLeft,a.element.offsetTop],[a.element.offsetLeft,a.element.offsetTop+a.element.offsetHeight+4],300,np);ri(b,"end",v(function(){this.a=!1;Sn(this.element)},a));fp(b)}
-function wp(a){zd(a.element,444,56);var b=a.qb.data,c={src:b.image_url,"class":"invideo-video-img"},d=Rc("div","invideo-video-img-container"),c=Rc("img",c);zd(c,100,56);d.appendChild(c);a.element.appendChild(d);zd(a.b,244,56);d=Rc("span","iv-subtitle-text");ad(d,b.text_line_1);a.b.appendChild(d);d=Rc("span","iv-title-text");ad(d,b.text_line_2);a.b.appendChild(d);a.element.appendChild(a.b);b=rp(a,v(function(){vp(this)},a));a.element.appendChild(b);a.i.listen(a.element,"click",v(function(){var a=xp(this.qb);
-yp(this.Me,this.qb);window.open(a.value)},a))}tp.prototype.show=function(){if(!this.a){this.j||(wp(this),this.j=!0);this.kh();Rn(this.element);var a=this.Me,b=this.qb;b&&b.i&&a.log_(sp(a,b,2));up(this)}};tp.prototype.hide=function(){this.a&&vp(this)};tp.prototype.kh=function(){var a=this.g.Dg,b=this.g.Tc;if(a&&b){var c=Bd(this.element),d=b.height-a.top,b=c.width<b.width&&c.height<b.height,e=this.g.ob?35:5,e=this.jl?e:0;od(this.element,-a.left,this.a&&b?d-c.height-e:d)}};function zp(a,b){return null!=b&&!!b.match(a)}function Ap(a,b){for(var c in a)if(a[c]==b)return!0;return!1}function Bp(a,b,c,d){var e=new Cp;e.type=c;e.defaultValue=d;e.b=oa(zp,/.+/);return Dp(a[b],e)}function Ep(a,b,c){var d=new Cp;d.type="OPTIONAL";d.a=function(a){if(isNaN(parseInt(a,0)))return null;a=parseInt(a,0).toString(16);return"#"+"000000".substring(0,6-a.length)+a};d.b=function(a){return!!a};d.defaultValue=c;return Dp(a[b],d)}
-function Fp(a,b,c,d){var e=new Cp;e.type=c;e.defaultValue=d;return Dp(a[b],e)}function Gp(a,b,c,d,e){var g=new Cp;g.type=d;g.defaultValue=e;g.b=oa(Ap,c);return Dp(a[b],g)}function Hp(a,b,c){var d=new Cp;d.type="OPTIONAL";d.defaultValue=c;d.b=function(a){return!0==a||!1==a};d.a=function(a){return"true"==a||"false"==a?"true"==a:a};return Dp(a[b],d)}function Ip(a,b,c){var d=new Cp;d.type="OPTIONAL";d.defaultValue=c;d.a=function(a){return parseFloat(a)};return Dp(a[b],d)}
-function Jp(a){var b=new Cp;b.type="OPTIONAL";b.defaultValue=0;b.a=function(a){return parseInt(a,10)};return Dp(a.d,b)}function Kp(a,b,c,d,e,g,h){var k=new Cp;k.type="OPTIONAL";k.a=function(a){a=10==c?parseFloat(a):parseInt(a,c);return g&&null!=a&&!isNaN(a)?vb(a,d,e):a};k.defaultValue=h;k.b=function(a){return null!=a&&!isNaN(a)&&a>=d&&a<=e};return Dp(a[b],k)}
-function Lp(a,b){var c=new Cp;c.type="OPTIONAL";c.defaultValue=0;c.a=function(a){if("never"==a)return-1;a=a.split(":");if(3<a.length)return null;var b=0,c=1;z(a,function(a){a=parseFloat(a);0>a&&(c=-c);b=60*b+Math.abs(a)});return c*b};return Dp(a[b],c)}function Mp(a,b){return null==b?null:a(b)}function Np(a,b,c,d,e){if(null==a||null==a[b])return null;var g=new Cp;g.type=d;g.defaultValue=e;g.b=function(a){return!!a};g.a=oa(Mp,c);return Dp(a[b],g)}
-function Dp(a,b){var c;if("OPTIONAL"==b.type||"REQUIRED"==b.type){if(c=null==a?null:b.a(t(a)&&a.length?a[0]:a),!b.b(c)){if("REQUIRED"==b.type)throw"Required field missing.";c=null==b.defaultValue?null:b.defaultValue}}else c="REPEATED"==b.type?null!=a?Op(t(a)?a:[a],b):null!=b.defaultValue?t(b.defaultValue)?b.defaultValue:[b.defaultValue]:[]:"IDLIST"==b.type?Pp(a,b):null;return c}
-function Pp(a,b){function c(a){return Ja(a.split(/ +/),function(a){return""!=a})}return null!=a?Op(c(a),b):null!=b.defaultValue?t(b.defaultValue)?b.defaultValue:[b.defaultValue]:[]}function Op(a,b){for(var c=[],d=0;d<a.length;++d){var e=b.a(a[d]);b.b(e)&&c.push(e)}return c.length?c:null!=b.defaultValue?t(b.defaultValue)?b.defaultValue:[b.defaultValue]:[]}function Cp(){this.a=Qp;this.b=Rp}Cp.prototype.type="OPTIONAL";Cp.prototype.defaultValue=null;function Qp(a){return null==a?null:a.toString()}
-function Rp(a){return null!=a};function Sp(a){this.value=a}function Tp(a){a=Lp(a,"value");return new Sp(a)};function Up(){}function Vp(a){var b=Fp(a,"external_user_id","OPTIONAL");a=Fp(a,"subscription_token","OPTIONAL");return b&&a?new Up:null};function Wp(a,b,c,d){this.value=a;this.target=b;this.a=c;this.b=d}var Xp={yA:"current",oC:"new"};function Yp(a){var b=Fp(a,"value","OPTIONAL");if(null==b||null==Gj(b))return null;var c=Gp(a,"target",Xp,"OPTIONAL","current");if(null==c)return null;Hp(a,"trusted",!1);var d=Fp(a,"link_class","OPTIONAL","");a=Hp(a,"show_link_icon",!0);return new Wp(b,c,d,a)}function Zp(a){return a.value?a.value:null};function $p(a,b,c,d){this.type=a;this.trigger=b;this.url=c;this.duration=d}var aq={hy:"close",fC:"log",sC:"openUrl",PAUSE:"pause",ly:"subscribe"},bq={CLICK:"click",hy:"close",iy:"hidden",GC:"rollOut",jy:"rollOver",ky:"shown"};function cq(a){var b=Gp(a,"type",aq,"OPTIONAL"),c=Gp(a,"trigger",bq,"OPTIONAL"),d=Np(a,"url",Yp,"OPTIONAL");Np(a,"subscribeData",Vp,"OPTIONAL");a=Np(a,"duration",Tp,"OPTIONAL");return b?new $p(b,c,d,a):null};function dq(a,b,c,d,e,g,h,k,m,p,s,r,D,M){this.k=a;this.j=b;this.o=c;this.H=d;this.a=e;this.G=g;this.i=h;this.textAlign=k;this.I=m;this.A=p;this.padding=s;this.b=r;this.g=D;this.B=M}
-function eq(a){var b=Ep(a,"fgColor","#1A1A1A"),c=Ep(a,"bgColor","#FFF"),d=Ep(a,"borderColor","#000"),e=Kp(a,"borderWidth",10,0,5,!1,0),g=Kp(a,"bgAlpha",10,0,1,!1,0.8);Kp(a,"borderAlpha",10,0,1,!1,0.2);Kp(a,"gloss",16,0,255,!1,0);var h=Ep(a,"highlightFontColor","#F2F2F2"),k=Kp(a,"highlightWidth",10,0,5,!1,3),m=Fp(a,"textAlign","OPTIONAL",""),p=Kp(a,"textSize",10,3.3,30.1,!0,3.6107),s=Fp(a,"fontWeight","OPTIONAL",""),r;r=(r=a?a.padding&&a.padding.length?a.padding[0]:a.padding:null)?new yb(parseFloat(r.top),
-parseFloat(r.right),parseFloat(r.bottom),parseFloat(r.left)):null;r=!r||null==r.top||isNaN(r.top)||null==r.right||isNaN(r.right)||null==r.bottom||isNaN(r.bottom)||null==r.left||isNaN(r.left)?null:r;var D=Fp(a,"effects","IDLIST"),M=Kp(a,"cornerRadius",10,0,10,!0,0);a=Np(a,"gradient",fq,"OPTIONAL");return new dq(b,c,d,e,g,h,k,m,p,s,r,D,M,a)}function gq(a,b,c,d,e,g,h,k){this.j=a;this.o=b;this.k=c;this.H=d;this.a=e;this.b=g;this.g=h;this.i=k}
-function fq(a){var b=Kp(a,"x1",10,0,100,!0,0),c=Kp(a,"y1",10,0,100,!0,0),d=Kp(a,"x2",10,0,100,!0,100),e=Kp(a,"y2",10,0,100,!0,100),g=Ep(a,"color1","#FFF"),h=Ep(a,"color2","#000"),k=Kp(a,"opacity1",10,0,100,!0,100);a=Kp(a,"opacity2",10,0,100,!0,0);return new gq(b,c,d,e,g,h,k,a)};function hq(a,b){this.a=a;this.L=b}function iq(a){var b=Fp(a,"standard_url","OPTIONAL","");Fp(a,"rollover_url","OPTIONAL","");Fp(a,"click_url","OPTIONAL","");a=Fp(a,"video_id","OPTIONAL","");return new hq(b,a)};function jq(a,b,c){var d=a.H,e=a.A,g=a.a?a.a:"xy",h=kq(c,a.j,g);a=lq(c,a.g,g);var g=640*b.width*h/100,k=360*b.height*a/100;return new Cb(0==d?640*b.left*h/100:0<d?d:c.width+d-g,0==e?360*b.top*a/100:0<e?e:c.height+e-k,g,k)}function kq(a,b,c){var d=(c="xx"==c||"xy"==c)?640:360;return(d+((c?a.width:a.height)-d)*b)/d}function lq(a,b,c){var d=(c="xy"==c||"yy"==c)?360:640;return(d+((c?a.height:a.width)-d)*b)/d};function mq(a,b,c,d,e,g,h,k,m,p,s){this.x=a;this.y=b;this.k=c;this.i=d;this.b=e;this.o=g;this.H=h;this.A=k;this.j=m;this.g=p;this.a=s}function nq(a,b){var c=Ip(a,"x",0),d=Ip(a,"y",0),e=Ip(a,"w",0),g=Ip(a,"h",0),h=Lp(a,"t"),k=Jp(a),m=Ip(a,"px",0),p=Ip(a,"py",0),s=Ip(a,"scaleSlope",1),r=Ip(a,"scaleSlopeX",s),s=Ip(a,"scaleSlopeY",s),D=Fp(a,"scaleDimension","OPTIONAL","xy");return b(c,d,e,g,h,k,m,p,r,s,D)}
-function oq(a,b,c){c=c?oq(c,b):null;a=jq(a,new Cb(a.x,a.y,a.k,a.i),b);c?(a.top+=c.top,a.left+=c.left):(a.top+=b.top,a.left+=b.left);c=a.clone();b&&!b.contains(a)&&(a.width<b.width?c.left=vb(a.left,b.left,b.left+b.width-a.width):(c.left=b.left,c.width=b.width),a.height<b.height?c.top=vb(a.top,b.top,b.top+b.height-a.height):(c.top=b.top,c.height=b.height));return c}function pq(a){return nq(a,function(a,c,d,e,g,h,k,m,p,s,r){return new mq(a,c,d,e,g,h,k,m,p,s,r)})};function qq(a,b,c,d,e,g,h,k,m,p,s,r,D){mq.call(this,a,b,c,d,e,k,m,p,s,r,D);this.B=g;this.G=h}y(qq,mq);function rq(a){var b=Ip(a,"sx",0),c=Ip(a,"sy",0);return nq(a,function(a,e,g,h,k,m,p,s,r,D,M){return new qq(a,e,g,h,k,b,c,m,p,s,r,D,M)})};function sq(a,b,c){this.type=a;this.b=b;this.a=c}var tq={fy:"anchored",CC:"rect"};function uq(a){var b=Gp(a,"type",tq,"OPTIONAL","rect"),c=Np(a,"rectRegion",pq,"REPEATED");a=Np(a,"anchoredRegion",rq,"REPEATED");return new sq(b,c,a)}function vq(a){return a.b&&a.b.length?a.b[0]:a.a&&a.a.length?a.a[0]:null};function wq(a,b){this.b=a;this.a=b}function xq(a){Bp(a,"timeRelative","OPTIONAL");var b=Bp(a,"spaceRelative","OPTIONAL");return(a=Np(a,"movingRegion",uq,"REPEATED"))?new wq(b,a):null};function yq(a,b){this.state=a;this.a=b}var zq={vC:"playerControlShow",jy:"rollOver",ky:"shown"};function Aq(a){var b=Gp(a,"state",zq,"OPTIONAL");a=Bp(a,"ref","OPTIONAL","");return b?new yq(b,a):null};function Bq(a,b,c,d){this.a=a||[];this.g=b||[];this.i=c;this.b=d}function Cq(a){var b=Np(a,"condition",Aq,"REPEATED"),c=Np(a,"notCondition",Aq,"REPEATED"),d=Hp(a,"show_delay",!1);a=Hp(a,"hide_delay",!1);return b||c?new Bq(b,c,d,a):null}function Dq(a,b,c){z(a.a,oa(b,!1),c);z(a.g,oa(b,!0),c)};function Eq(a,b,c,d,e,g,h,k,m,p,s,r,D,M,sa,Y){this.id=a;this.author=b;this.type=c;this.style=d;this.o=e;this.a=g;this.g=h||[];this.B=k||[];this.b=m;this.G=p;this.j=s;this.H=r;this.i=D;this.k=M;this.data=sa;this.A=Y}var Fq={fy:"anchored",nA:"channel",KB:"highlightText",XB:"label",xC:"popup",MC:"speech",ly:"subscribe",XC:"title",VIDEO:"video"},Gq={zA:"custom",JB:"highlight",IMAGE:"image",PAUSE:"pause",TEXT:"text",FD:"widget"},Hq={mD:"video_relative",wC:"player_relative"};
-function Iq(a){var b=Bp(a,"id","REQUIRED"),c=Bp(a,"author","OPTIONAL"),d=Gp(a,"type",Gq,"REQUIRED"),e=Gp(a,"style",Fq,"OPTIONAL"),g=Fp(a,"TEXT","OPTIONAL"),h=Np(a,"data",function(a){return 0!=a.length?mb(a):{}},"OPTIONAL",{}),k=Np(a,"segment",xq,"OPTIONAL"),m=Np(a,"action",cq,"REPEATED"),p=Np(a,"trigger",Cq,"REPEATED"),s=Np(a,"appearance",eq,"OPTIONAL");s||(s=eq({}));var r=Gp(a,"coordinate_system",Hq,"OPTIONAL","video_relative"),D=Np(a,"image_source",iq,"OPTIONAL"),M=Hp(a,"closeable",!0),sa=Hp(a,
-"logable",!0),Y=Fp(a,"html_blob","OPTIONAL","");a=Fp(a,"log_data","OPTIONAL","");return b&&d?new Eq(b,c,d,e,g,k,m,p,s,r,D,M,sa,Y,h,a):null}function xp(a){return(a=Oa(a.g,function(a){return null!=a.url},void 0))?a.url:null}function Jq(a){return La(a.g,function(a){return null!=a.url&&a.url.b},void 0)}function Kq(a){return La(a.g,function(a){return"click"==a.trigger},void 0)}function Lq(a,b,c){z(a.g,b,c)}function Mq(a,b,c){z(a.B,b,c)}function Nq(a,b){Ka(a.B,b,void 0)}
-function Oq(a){return(a=a.a?a.a.a.length?a.a.a[0]:null:null)?vq(a):null}function Pq(a,b){var c=Oq(a);return c&&b?kq(b,c.j,c.a?c.a:"xy"):1}function Qq(a,b){var c=Oq(a);return c&&b?lq(b,c.g,c.a?c.a:"xy"):1};function Rq(a,b,c){this.a={};this.b=!1;this.j="ivTrigger:"+a;this.g=c;Dq(b,function(a,b){var c=Sq(b.state,b.a);this.g.D(c,v(this.i,this,c,a));this.a[c]=!1},this)}Rq.prototype.i=function(a,b,c,d){this.a[a]=b?!c:c;a=Fb(this.a,function(a){return a});this.b!=a&&(this.b=a,this.g.u(this.j,a,d))};function Sq(a,b){var c="ivTriggerCondition:"+a;return b?c+":"+b:c};function Tq(a,b,c){this.i=a;this.qb=b;this.b=c;this.a=null;this.Ib=this.isVisible=!1;Uq(b,a)}function Uq(a,b){Nq(a,function(c){return new Rq(a.id,c,b)})}Tq.prototype.hide=function(){this.isVisible=!1;this.i.$("onResize",this.g,this);this.b.hide()};Tq.prototype.show=function(){this.isVisible=!0;this.b.show();this.i.D("onResize",this.g,this)};Tq.prototype.destroy=function(){this.i.$("onResize",this.g,this);var a=this.b;a.i.removeAll();a.na&&F(a.na);a.Fa&&a.Fa.N()&&F(a.Fa.N());Vq(this)};
-function Vq(a){a.a&&(a.a.stop(),a.a=null)}Tq.prototype.g=function(){Wq(this.b)};function Xq(){};function Yq(a,b,c,d,e,g,h,k){this.j=a;this.o=b;this.k=c;this.H=d;this.a=e;this.b=g;this.g=q(h)?h:null;this.i=q(k)?k:null}y(Yq,Xq);function Zq(){this.ab=[];this.R=[];this.Pd=[]}Zq.prototype.Yf=null;Zq.prototype.kd=null;Zq.prototype.bj=!0;var $q=[2,2,6,6,0];f=Zq.prototype;f.clear=function(){this.ab.length=0;this.R.length=0;this.Pd.length=0;delete this.Yf;delete this.kd;delete this.bj;return this};function ar(a,b,c){0==Ga(a.ab)?a.Pd.length-=2:(a.ab.push(0),a.R.push(1));a.Pd.push(b,c);a.kd=a.Yf=[b,c]}
-f.Ga=function(a){var b=Ga(this.ab);if(null==b)throw Error("Path cannot start with lineTo");1!=b&&(this.ab.push(1),this.R.push(0));for(b=0;b<arguments.length;b+=2){var c=arguments[b],d=arguments[b+1];this.Pd.push(c,d)}this.R[this.R.length-1]+=b/2;this.kd=[c,d]};f.close=function(){var a=Ga(this.ab);if(null==a)throw Error("Path cannot start with close");4!=a&&(this.ab.push(4),this.R.push(1),this.kd=this.Yf);return this};
-function br(a,b,c,d,e){var g=a.kd[0]-b*Math.cos(d*Math.PI/180),h=a.kd[1]-c*Math.sin(d*Math.PI/180),g=g+b*Math.cos((d+e)*Math.PI/180),h=h+c*Math.sin((d+e)*Math.PI/180);a.ab.push(3);a.R.push(1);a.Pd.push(b,c,d,e,g,h);a.bj=!1;a.kd=[g,h]}function cr(a,b){for(var c=a.Pd,d=0,e=0,g=a.ab.length;e<g;e++){var h=a.ab[e],k=$q[h]*a.R[e];b(h,c.slice(d,d+k));d+=k}}
-f.clone=function(){var a=new this.constructor;a.ab=this.ab.concat();a.R=this.R.concat();a.Pd=this.Pd.concat();a.Yf=this.Yf&&this.Yf.concat();a.kd=this.kd&&this.kd.concat();a.bj=this.bj;return a};f.isEmpty=function(){return 0==this.ab.length};function dr(a,b){this.A=a;this.B=null==b?1:b}y(dr,Xq);function er(a,b){this.a=a;this.b=b};function fr(a){this.b=a;this.a={}}y(fr,K);var gr=[];f=fr.prototype;f.listen=function(a,b,c,d,e){t(b)||(gr[0]=b,b=gr);for(var g=0;g<b.length;g++){var h=ri(a,b[g],c||this,d||!1,e||this.b||this);if(!h)break;this.a[h.key]=h}return this};f.dc=function(a,b,c,d,e){if(t(b))for(var g=0;g<b.length;g++)this.dc(a,b[g],c,d,e);else e=e||this.b||this,c=si(c||this),d=!!d,b=gi(a)?ni(a.gd,b,c,d,e):a?(a=ti(a))?ni(a,b,c,d,e):null:null,b&&(xi(b),delete this.a[b.key]);return this};
-f.removeAll=function(){Eb(this.a,xi);this.a={}};f.F=function(){fr.C.F.call(this);this.removeAll()};f.handleEvent=function(){throw Error("EventHandler.handleEvent not implemented");};function hr(){}ca(hr);hr.prototype.a=0;hr.getInstance();function ir(a){Bi.call(this);this.o=a||Gc()}y(ir,Bi);f=ir.prototype;f.Dv=hr.getInstance();f.Ba=null;f.cf=!1;f.Nf=null;f.Il=null;f.getId=function(){return this.Ba||(this.Ba=":"+(this.Dv.a++).toString(36))};f.N=function(){return this.Nf};f.Fp=function(){this.Nf=this.o.createElement("div")};f.Vi=function(){jr(this,function(a){a.cf&&a.Vi()});this.j&&this.j.removeAll();this.cf=!1};
-f.F=function(){this.cf&&this.Vi();this.j&&(this.j.dispose(),delete this.j);jr(this,function(a){a.dispose()});this.Nf&&F(this.Nf);this.Nf=this.Il=null;ir.C.F.call(this)};function jr(a,b){a.Il&&z(a.Il,b,void 0)};function kr(a,b,c,d,e){ir.call(this,e);this.width=a;this.height=b;this.g=c||null;this.k=d||null}y(kr,ir);kr.prototype.b=null;kr.prototype.mh=function(){return this.cf?Bd(this.N()):ga(this.width)&&ga(this.height)?new B(this.width,this.height):null};function lr(a){var b=a.mh();return b?b.width/(a.g?new B(a.g,a.k):a.mh()).width:0};function mr(a,b){Bi.call(this);this.nh=a;this.Nj=b;this[fi]=!1}y(mr,Bi);f=mr.prototype;f.Nj=null;f.nh=null;f.N=function(){return this.nh};f.addEventListener=function(a,b,c,d){ri(this.nh,a,b,c,d)};f.removeEventListener=function(a,b,c,d){wi(this.nh,a,b,c,d)};f.F=function(){mr.C.F.call(this);var a=this.nh;if(a)if(gi(a))a.gd&&a.gd.removeAll(void 0);else if(a=ti(a)){var b=0,c;for(c in a.a)for(var d=$a(a.a[c]),e=0;e<d.length;++e)xi(d[e])&&++b}};function nr(a,b,c,d){mr.call(this,a,b);a=this.Nj;b=this.N();c?(b.setAttribute("stroke",c.b),c=c.a,u(c)&&-1!=c.indexOf("px")?b.setAttribute("stroke-width",parseFloat(c)/lr(a)):b.setAttribute("stroke-width",c)):b.setAttribute("stroke","none");c=this.Nj;a=this.N();if(d instanceof dr)a.setAttribute("fill",d.A),a.setAttribute("fill-opacity",d.B);else if(d instanceof Yq){b="lg-"+d.j+"-"+d.o+"-"+d.k+"-"+d.H+"-"+d.a+"-"+d.b;var e=b in c.a?c.a[b]:null;if(!e){var e=or(c,"linearGradient",{x1:d.j,y1:d.o,x2:d.k,
-y2:d.H,gradientUnits:"userSpaceOnUse"}),g="stop-color:"+d.a;ga(d.g)&&(g+=";stop-opacity:"+d.g);g=or(c,"stop",{offset:"0%",style:g});e.appendChild(g);g="stop-color:"+d.b;ga(d.i)&&(g+=";stop-opacity:"+d.i);d=or(c,"stop",{offset:"100%",style:g});e.appendChild(d);e=pr(c,b,e)}a.setAttribute("fill","url(#"+e+")")}else a.setAttribute("fill","none")}y(nr,mr);function qr(a,b){mr.call(this,a,b)}y(qr,mr);function rr(a,b){mr.call(this,a,b)}y(rr,mr);function sr(a,b,c,d){nr.call(this,a,b,c,d)}y(sr,nr);function tr(a,b){mr.call(this,a,b)}y(tr,qr);tr.prototype.clear=function(){Xc(this.N())};function ur(a,b,c,d){nr.call(this,a,b,c,d)}y(ur,sr);function vr(a,b){mr.call(this,a,b)}y(vr,rr);function wr(a,b,c,d,e){kr.call(this,a,b,c,d,e);this.a={};this.H=dc&&!rc(526);this.A=new fr(this)}var xr;y(wr,kr);var yr=0;function or(a,b,c){a=a.o.a.createElementNS("http://www.w3.org/2000/svg",b);if(c)for(var d in c)a.setAttribute(d,c[d]);return a}f=wr.prototype;
-f.Fp=function(){var a=or(this,"svg",{width:this.width,height:this.height,overflow:"hidden"}),b=or(this,"g");this.i=or(this,"defs");this.b=new tr(b,this);a.appendChild(this.i);a.appendChild(b);this.Nf=a;this.g&&(this.N().setAttribute("preserveAspectRatio","none"),this.H?this.Ro():this.N().setAttribute("viewBox","0 0 "+(this.g?this.g+" "+this.k:"")))};
-f.Ro=function(){if(this.cf){var a=this.mh();0==a.width?this.N().style.visibility="hidden":(this.N().style.visibility="",this.b.N().setAttribute("transform","scale("+a.width/this.g+" "+a.height/this.k+") translate(0 0)"))}};
-f.mh=function(){if(!cc)return this.cf?Bd(this.N()):wr.C.mh.call(this);var a=this.width,b=this.height,c=u(a)&&-1!=a.indexOf("%"),d=u(b)&&-1!=b.indexOf("%");if(!this.cf&&(c||d))return null;var e,g;c&&(e=this.N().parentNode,g=Bd(e),a=parseFloat(a)*g.width/100);d&&(e=e||this.N().parentNode,g=g||Bd(e),b=parseFloat(b)*g.height/100);return new B(a,b)};f.clear=function(){this.b.clear();Xc(this.i);this.a={}};function zr(a,b,c,d){b=or(a,"path",{d:Ar(b)});c=new ur(b,a,c,d);a.b.N().appendChild(c.N())}
-function Ar(a){var b=[];cr(a,function(a,d){switch(a){case 0:b.push("M");Array.prototype.push.apply(b,d);break;case 1:b.push("L");Array.prototype.push.apply(b,d);break;case 2:b.push("C");Array.prototype.push.apply(b,d);break;case 3:var e=d[3];b.push("A",d[0],d[1],0,180<Math.abs(e)?1:0,0<e?1:0,d[4],d[5]);break;case 4:b.push("Z")}});return b.join(" ")}function pr(a,b,c){if(b in a.a)return a.a[b];var d="_svgdef_"+yr++;c.setAttribute("id",d);a.a[b]=d;a.i.appendChild(c);return d}
-f.Vi=function(){wr.C.Vi.call(this);this.H&&this.A.dc(Br(),"tick",this.Ro)};f.F=function(){delete this.a;delete this.i;delete this.b;wr.C.F.call(this)};function Br(){xr||(xr=new Ei(400),xr.start());return xr};function Cr(a,b,c){this.a=a;this.b=0;this.i=b;c&&(this.tn=c)}f=Cr.prototype;f.tn=70;f.mk=!1;f.start=function(a){this.k=x();this.b=a;this.j=this.k+this.b;this.mk=!0;Rn(this.a);hf(this.g);this.g=gf(v(this.Vt,this),this.tn)};f.stop=function(){this.mk=!1;Sn(this.a);this.g&&hf(this.g)};
-f.Vt=function(){if(this.mk){var a=x(),b;b=0==this.b||a>=this.j?0:1-(a-this.k)/this.b;var c=E("countdowntimer-diminishing-pieslice",this.a),d=Ue("svg",this.a);!d&&this.a.querySelectorAll&&(d=this.a.querySelectorAll("svg"),d=d.length?d[0]:null);var d=parseInt(d.getAttribute("width"),10),e=new Zq,g=d/2-5;ar(e,d/2,d/2);e.Ga(d/2,5);br(e,g,g,-90,360*-b);e.Ga(d/2,d/2);e.close();c.setAttribute("d",Ar(e));a>=this.j&&(this.stop(),this.i&&this.i())}};var Dr=n("yt.prefs.UserPrefs.prefs_")||{};pa("yt.prefs.UserPrefs.prefs_",Dr);function Er(a){var b=null;"transition"in a.style?b="transition-duration":"webkitTransition"in a.style?b="-webkit-transition-duration":"MozTransition"in a.style?b="-moz-transition-duration":"OTransition"in a.style?b="-o-transition-duration":"msTransition"in a.style&&(b="-ms-transition-duration");a=b?(document.defaultView?document.defaultView.getComputedStyle(a,null):document.parentWindow.getComputedStyle(a,null)).getPropertyValue(b):"0";return 1E3*parseFloat(a)};var Fr=n("yt.pubsub.instance_")||new Wh;Wh.prototype.subscribe=Wh.prototype.D;Wh.prototype.unsubscribeByKey=Wh.prototype.Wc;Wh.prototype.publish=Wh.prototype.u;Wh.prototype.clear=Wh.prototype.clear;pa("yt.pubsub.instance_",Fr);function Gr(a,b,c){var d=Hr();return d?d.subscribe(a,function(){var d=arguments;try{Ir&&Jr[a]?b.apply(c||l,d):H(function(){b.apply(c||l,d)},0)}catch(g){jf(g)}},c):0}
-function Kr(){var a=cf("LOGGED_IN_PUBSUB_KEY"),b=Hr();b&&("number"==typeof a?a=[a]:"string"==typeof a&&(a=[parseInt(a,10)]),z(a,function(a){b.unsubscribeByKey(a)}))}function Lr(a,b){var c=Hr();return c?c.publish.apply(c,arguments):!1}function Hr(){return n("yt.pubsub.instance_")}var Ir=!!cf("SYNCHRONOUS_PUBSUB"),Jr={};function Mr(a,b,c,d,e,g){var h,k;if(h=c.offsetParent){var m="HTML"==h.tagName||"BODY"==h.tagName;m&&"static"==nd(h,"position")||(k=td(h),m||(m=(m=ud(h))&&cc?-h.scrollLeft:!m||C&&rc("8")||"visible"==nd(h,"overflowX")?h.scrollLeft:h.scrollWidth-h.clientWidth-h.scrollLeft,k=xb(k,new A(m,h.scrollTop))))}h=k||new A;k=Dd(a);if(m=sd(a)){var p=Db(m),m=Math.max(k.left,p.left),s=Math.min(k.left+k.width,p.left+p.width);if(m<=s){var r=Math.max(k.top,p.top),p=Math.min(k.top+k.height,p.top+p.height);r<=p&&(k.left=
-m,k.top=r,k.width=s-m,k.height=p-r)}}m=Gc(a);r=Gc(c);if(m.a!=r.a){var s=m.a.body,r=r.a.parentWindow||r.a.defaultView,p=new A(0,0),D=Ic(s)?Ic(s).parentWindow||Ic(s).defaultView:window,M=s;do{var sa=D==r?td(M):xd(M);p.x+=sa.x;p.y+=sa.y}while(D&&D!=r&&(M=D.frameElement)&&(D=D.parent));s=xb(p,td(s));C&&!id(m)&&(s=xb(s,jd(m)));k.left+=s.x;k.top+=s.y}a=(b&4&&ud(a)?b^2:b)&-5;b=new A(a&2?k.left+k.width:k.left,a&1?k.top+k.height:k.top);b=xb(b,h);e&&(b.x+=(a&2?-1:1)*e.x,b.y+=(a&1?-1:1)*e.y);if(e=sd(c))e.top-=
-h.y,e.right-=h.x,e.bottom-=h.y,e.left-=h.x;Nr(b,c,d,g,e,65,void 0)}
-function Nr(a,b,c,d,e,g,h){a=a.clone();var k=(c&4&&ud(b)?c^2:c)&-5;c=Bd(b);h=h?h.clone():c.clone();if(d||0!=k)k&2?a.x-=h.width+(d?d.right:0):d&&(a.x+=d.left),k&1?a.y-=h.height+(d?d.bottom:0):d&&(a.y+=d.top);if(g&&(e?(d=a,k=0,65==(g&65)&&(d.x<e.left||d.x>=e.right)&&(g&=-2),132==(g&132)&&(d.y<e.top||d.y>=e.bottom)&&(g&=-5),d.x<e.left&&g&1&&(d.x=e.left,k|=1),d.x<e.left&&d.x+h.width>e.right&&g&16&&(h.width=Math.max(h.width-(d.x+h.width-e.right),0),k|=4),d.x+h.width>e.right&&g&1&&(d.x=Math.max(e.right-
-h.width,e.left),k|=1),g&2&&(k=k|(d.x<e.left?16:0)|(d.x+h.width>e.right?32:0)),d.y<e.top&&g&4&&(d.y=e.top,k|=2),d.y<=e.top&&d.y+h.height<e.bottom&&g&32&&(h.height=Math.max(h.height-(e.top-d.y),0),d.y=e.top,k|=8),d.y>=e.top&&d.y+h.height>e.bottom&&g&32&&(h.height=Math.max(h.height-(d.y+h.height-e.bottom),0),k|=8),d.y+h.height>e.bottom&&g&4&&(d.y=Math.max(e.bottom-h.height,e.top),k|=2),g&8&&(k=k|(d.y<e.top?64:0)|(d.y+h.height>e.bottom?128:0)),e=k):e=256,e&496))return;od(b,a);zb(c,h)||(e=id(Gc(Ic(b))),
-!C||e&&rc("8")?(b=b.style,cc?b.MozBoxSizing="border-box":dc?b.WebkitBoxSizing="border-box":b.boxSizing="border-box",b.width=Math.max(h.width,0)+"px",b.height=Math.max(h.height,0)+"px"):(a=b.style,e?(e=Hd(b),b=Id(b),a.pixelWidth=h.width-b.left-e.left-e.right-b.right,a.pixelHeight=h.height-b.top-e.top-e.bottom-b.bottom):(a.pixelWidth=h.width,a.pixelHeight=h.height)))};var Or={},Pr="ontouchstart"in document;function Qr(a,b,c){var d;switch(a){case "mouseover":case "mouseout":d=3;break;case "mouseenter":case "mouseleave":d=9}return hd(c,function(a){return Dc(a,b)},!0,d)}
-function Rr(a){var b="mouseover"==a.type&&"mouseenter"in Or||"mouseout"==a.type&&"mouseleave"in Or,c=a.type in Or||b;if("HTML"!=a.target.tagName&&c){if(b){var b="mouseover"==a.type?"mouseenter":"mouseleave",c=Or[b],d;for(d in c.Tb){var e=Qr(b,d,a.target);e&&!hd(a.relatedTarget,function(a){return a==e},!0)&&c.u(d,e,b,a)}}if(b=Or[a.type])for(d in b.Tb)(e=Qr(a.type,d,a.target))&&b.u(d,e,a.type,a)}}J(document,"blur",Rr,!0);J(document,"change",Rr,!0);J(document,"click",Rr);J(document,"focus",Rr,!0);
-J(document,"mouseover",Rr);J(document,"mouseout",Rr);J(document,"mousedown",Rr);J(document,"keydown",Rr);J(document,"keyup",Rr);J(document,"keypress",Rr);J(document,"cut",Rr);J(document,"paste",Rr);Pr&&(J(document,"touchstart",Rr),J(document,"touchend",Rr),J(document,"touchcancel",Rr));var Sr=window.yt&&window.yt.uix&&window.yt.uix.widgets_||{};pa("yt.uix.widgets_",Sr);function Tr(a){a=a.getInstance();var b=$(a);b in Sr||!a.mq()||(a.register(),Sr[b]=a)};function Ur(){this.a={}}Ur.prototype.g=!!eval("/*@cc_on!@*/false");Ur.prototype.mq=function(){return!0};function Vr(a,b,c){var d=$(a,void 0),e=v(c,a);b in Or||(Or[b]=new Wh);Or[b].D(d,e);a.a[c]=e}Ur.prototype.b=function(a,b,c){var d=G(a,b);if(d&&(d=n(d))){var e=cb(arguments,2);bb(e,0,0,a);d.apply(null,e)}};function Wr(a,b){Oe(a,"tooltip-text",b)}Ur.prototype.removeData=function(a,b){a.dataset?delete a.dataset[Pe(b)]:a.removeAttribute("data-"+b)};
-function $(a,b){return"yt-uix"+(a.fj?"-"+a.fj:"")+(b?"-"+b:"")};function Xr(){this.a={}}y(Xr,Ur);ca(Xr);f=Xr.prototype;f.fj="button";f.Df=null;f.register=function(){Vr(this,"click",this.$x);Vr(this,"keydown",this.Yx);Vr(this,"keypress",this.Zx)};f.$x=function(a){a&&!a.disabled&&(Yr(this,a),this.click(a))};
-f.Yx=function(a,b,c){if(!(c.altKey||c.ctrlKey||c.shiftKey)&&(b=Zr(this,a))){var d=function(a){var b="";a.tagName&&(b=a.tagName.toLowerCase());return"ul"==b||"table"==b};if(d=d(b)?b:bd(b,d)){var d=d.tagName.toLowerCase(),e;"ul"==d?e=this.ey:"table"==d&&(e=this.cy);e&&$r(this,a,b,c,v(e,this))}}};
-function $r(a,b,c,d,e){var g=Qn(c),h=9==d.keyCode;h||32==d.keyCode||13==d.keyCode?(d=as(a,c))?(b=Yc(d),"a"==b.tagName.toLowerCase()?window.location=b.href:Af(b,"click")):h&&bs(a,b):g?27==d.keyCode?(as(a,c),bs(a,b)):e(b,c,d):(a=Dc(b,$(a,"reverse"))?38:40,d.keyCode==a&&(Af(b,"click"),d.preventDefault()))}f.Zx=function(a,b,c){c.altKey||c.ctrlKey||c.shiftKey||(a=Zr(this,a),Qn(a)&&c.preventDefault())};function as(a,b){var c=$(a,"menu-item-highlight"),d=E(c,b);d&&Bc(d,c);return d}
-function cs(a,b,c){Ac(c,$(a,"menu-item-highlight"));b.setAttribute("aria-activedescendant",c.getAttribute("id"))}f.cy=function(a,b,c){var d=as(this,b);b=Ue("table",b);var e=Ue("tr",b),e=Lc("td",null,e).length;b=Lc("td",null,b);d=ds(d,b,e,c);-1!=d&&(cs(this,a,b[d]),c.preventDefault())};f.ey=function(a,b,c){if(40==c.keyCode||38==c.keyCode){var d=as(this,b);b=Lc("li",null,b);d=ds(d,b,1,c);cs(this,a,b[d]);c.preventDefault()}};
-function ds(a,b,c,d){var e=b.length;a=Ia(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}function es(a,b){var c=b.iframeMask;c||(c=document.createElement("iframe"),c.src='javascript:""',c.className=$(a,"menu-mask"),b.iframeMask=c);return c}
-function fs(a,b,c,d){var e=gd(b,$(a,"group")),g=!!G(b,"button-menu-ignore-group"),e=e&&!g?e:b,g=5,h=4,k=Dd(b);if(Dc(b,$(a,"reverse"))){g=4;h=5;k=k.top+"px";try{c.style.maxHeight=k}catch(m){}}Dc(b,"flip")&&(Dc(b,$(a,"reverse"))?(g=6,h=7):(g=7,h=6));var p;G(b,"button-has-sibling-menu")?p=rd(e):G(b,"button-menu-root-container")&&(p=gs(b));C&&!rc("8")&&(p=null);var s;p&&(s=Dd(p),s=new yb(-s.top,s.left,s.top,-s.left));p=new A(0,1);Dc(b,$(a,"center-menu"))&&(p.x-=Math.round((Bd(c).width-Bd(b).width)/2));
-d&&(p.y+=Pc(document).y);if(a=es(a,b))b=Bd(c),a.style.width=b.width+"px",a.style.height=b.height+"px",Mr(e,g,a,h,p,s),d&&Un(a,"position","fixed");Mr(e,g,c,h,p,s)}function gs(a){if(G(a,"button-menu-root-container")){var b=G(a,"button-menu-root-container");return gd(a,b)}return document.body}
-f.pp=function(a){if(a){var b=Zr(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);var c;c=G(a,"button-has-sibling-menu")?a.parentNode:gs(a);c.appendChild(b);b.style.minWidth=a.offsetWidth-2+"px";var d=es(this,a);d&&c.appendChild(d);c=!!G(a,"button-menu-fixed");fs(this,a,b,c);Rn(b);this.b(a,"button-menu-action",!0);Ac(a,$(this,"active"));b=v(this.np,this,a,!1);c=v(this.np,this,
-a,!0);c=J(document,"click",c);b=J(document,"contextmenu",b);Oe(a,"button-listener",c);Oe(a,"button-context-menu-listener",b);this.Df=a}}};
-function bs(a,b){if(b){var c=Zr(a,b);if(c){a.Df=null;b.setAttribute("aria-pressed","false");b.setAttribute("aria-expanded","false");b.removeAttribute("aria-activedescendant");Sn(c);a.b(b,"button-menu-action",!1);var d=es(a,b);H(function(){d&&d.parentNode&&d.parentNode.removeChild(d);c.originalParentNode&&(c.parentNode.removeChild(c),c.originalParentNode.appendChild(c),c.originalParentNode=null,c.activeButtonNode=null)},1)}var e=gd(b,$(a,"group"));Bc(b,$(a,"active"));e&&Bc(e,$(a,"group-active"));if(e=
-G(b,"button-listener"))uf(e),a.removeData(b,"button-listener");if(e=G(b,"button-context-menu-listener"))uf(e),a.removeData(b,"button-context-menu-listener")}}function hs(a,b){var c=Zr(a,b);c&&fs(a,b,c)}function is(a,b){return Zr(a,b)}
-f.np=function(a,b,c){c=c||window.event;c=c.target||c.srcElement;3==c.nodeType&&(c=c.parentNode);var d=gd(c,$(this));if(d){var d=Zr(this,d),e=Zr(this,a);if(d==e)return}if(!gd(c,$(this,"menu"))||Dc(c,$(this,"menu-item"))||Dc(c,$(this,"menu-close")))if(bs(this,a),(d=gd(c,$(this,"menu")))&&b&&G(a,"button-menu-indicate-selected")){if(a=E($(this,"content"),a))xc&&"innerText"in c?b=c.innerText.replace(/(\r\n|\r|\n)/g,"\n"):(b=[],fd(c,b,!0),b=b.join("")),b=b.replace(/ \xAD /g," ").replace(/\xAD/g,""),b=b.replace(/\u200B/g,
-""),xc||(b=b.replace(/ +/g," "))," "!=b&&(b=b.replace(/^\s*/,"")),ad(a,b);a=$(this,"menu-item-selected");(b=E(a,d))&&Bc(b,a);Ac(c.parentNode,a)}};function Zr(a,b){if(!b.widgetMenu){var c=G(b,"button-menu-id"),c=c&&Jc(c),d=$(a,"menu");c?(Ac(c,d),Ac(c,$(a,"menu-external"))):c=E(d,b);b.widgetMenu=c}return b.widgetMenu}
-function Yr(a,b){if(G(b,"button-toggle")){var c=gd(b,$(a,"group"));if(c&&G(c,"button-toggle-group")){var d=G(c,"button-toggle-group"),c=Kc($(a),c),e=$(a,"toggled"),g=Dc(b,e);z(c,function(a){a!=b||"optional"==d&&g?Bc(a,e):Ac(b,e)})}else Fc(b,$(a,"toggled"))}}f.click=function(a){if(Zr(this,a)){var b=Zr(this,a),c=gd(b.activeButtonNode||b.parentNode,$(this));c&&c!=a?(bs(this,c),H(v(this.pp,this,a),1)):Qn(b)?bs(this,a):this.pp(a);a.focus()}this.b(a,"button-action")};function js(a,b,c){this.i=a;this.g=b;this.b=c;this.a=v(this.eu,this)}y(js,K);f=js.prototype;f.dj=!1;f.Hf=null;function ks(a){a.Hf?a.dj=!0:ls(a)}f.stop=function(){this.Hf&&(l.clearTimeout(this.Hf),this.Hf=null,this.dj=!1)};f.F=function(){js.C.F.call(this);this.stop()};f.eu=function(){this.Hf=null;this.dj&&(this.dj=!1,ls(this))};function ls(a){a.Hf=Gi(a.a,a.g);a.i.call(a.b)};function ms(a,b,c){b||(b={});var d=c||window;c="undefined"!=typeof a.href?a.href:String(a);a=b.target||a.target;var e=[],g;for(g in b)switch(g){case "width":case "height":case "top":case "left":e.push(g+"="+b[g]);break;case "target":case "noreferrer":break;default:e.push(g+"="+(b[g]?1:0))}g=e.join(",");if(b.noreferrer){if(b=d.open("",a,g))C&&-1!=c.indexOf(";")&&(c="'"+c.replace(/'/g,"%27")+"'"),b.opener=null,c=va(c),b.document.write('<META HTTP-EQUIV="refresh" content="0; url='+c+'">'),b.document.close()}else b=
-d.open(c,a,g);return b}function ns(a,b){var c;c=b||{};c.target=c.target||a.target||"YouTube";c.width=c.width||600;c.height=c.height||600;(c=ms(a,c))?(c.opener||(c.opener=window),c.focus()):c=null;return!c};function os(a,b){ps().tick[a]=b||x()}function qs(a){var b=ps().tick;return a in b}function rs(a){var b="https:"==window.location.protocol?"https://gg.google.com/csi":"http://csi.gstatic.com/csi",c="",d;for(d in a)c+="&"+d+"="+a[d];Qg(b+"?"+c.substring(1))}function ss(){return ps().info}function ps(){return n("ytcsi.data_")||ts()}function ts(){var a={tick:{},span:{},info:{}};pa("ytcsi.data_",a);return a};function us(a){if(!a)return!1;a=a.replace(/https?:\/\//g,"");var b=a.split("/",1);if(!b||1>b.length||!b[0])return!1;b=b[0].toLowerCase().split(".").reverse();return 2>b.length?!1:("com"==b[0]&&"youtube"==b[1]||"be"==b[0]&&"youtu"==b[1])&&-1==a.indexOf("/redirect?")}
-function vs(a,b){if("new"==a.target)return-1;var c=Zp(a);if(!c)return-1;var c=c.replace(/https?:\/\//g,""),d;(d=!us(c))||(d=fe(c)||"",d=d.split("/"),d="/"+(1<d.length?d[1]:""),d="/watch"!=d);if(d)return-1;d=Gj(c);if(!d||d.v!=b.L||d.list||d.p)return-1;c=c.split("#",2);if(!c||2>c.length)return-1;(c=Fj(c[1]))&&c.t?(d=c.t,c=0,-1!=d.indexOf("h")&&(d=d.split("h"),c=3600*d[0],d=d[1]),-1!=d.indexOf("m")&&(d=d.split("m"),c=60*d[0]+c,d=d[1]),-1!=d.indexOf("s")?(d=d.split("s"),c=1*d[0]+c):c=1*d+c):c=-1;return c}
-;function ws(a,b){this.b=a;this.a=b}function yp(a,b,c){b&&b.i&&xp(b)&&a.log_(sp(a,b,3),c)}function sp(a,b,c){var d={};d["iv-event"]=c;d["a-id"]=b.id;d["a-type"]=xs(b);if(c=xp(b))d.link=escape(Zp(c)),c.a&&(d["l-class"]=c.a);d.ps=a.a.Ca;if(b.A){var e=new we(b.A);z(e.uc(),function(a){d[a]=e.get(a)})}return d}
-function xs(a){switch(a.type){case "text":switch(a.style){case "popup":return 1;case "speech":return 2;case "anchored":return 8;case "label":return 9;case "title":return 4;default:return 0}case "highlight":return 3;case "image":switch(a.style){case "video":return 11;case "channel":return 10;default:return 0}default:return 0}}ws.prototype.log_=function(a,b){this.b.u("command_log","iv",a,b)};function ys(){this.element=this.label=null;this.priority=0}y(ys,K);ys.prototype.listen=function(a,b,c){return this.element.listen(this.element,a,b,c||this)};ys.prototype.dc=function(a){this.element.dc(a)};function zs(a,b,c){Z.call(this,["div","ytp-segmented-control"]);this.g=a;this.b=-1;this.a=[];q(b)&&As(this,b,c)}y(zs,Z);function As(a,b,c){Tg(a.a);a.a=[];for(var d=0;d<b.length;d++){var e=new En(a.g);a.a[d]=e;c?e.Aa(["div",b[d]]):e.Aa(b[d]);0!=d&&V(e.N(),"ytp-segmented-control-other");Bs(e,d==a.b);J(e,"click",v(a.Eu,a));e.V(a.element)}}f=zs.prototype;
-f.V=function(a,b){zs.C.V.call(this,a,b);for(var c=0,d=0;d<this.a.length;d++)c=Math.max(c,Bd(this.a[d].N()).width);if(c)for(d=0;d<this.a.length;d++)Ad(this.a[d].N(),c)};f.Ya=function(a){this.b=a;for(var b=0;b<this.a.length;b++)Bs(this.a[b],b==a)};f.getSelected=function(){return this.b};function Bs(a,b){if(b){var c=a.N();W(c,"ytp-segmented-control-deselected");V(c,"ytp-segmented-control-selected")}else c=a.N(),W(c,"ytp-segmented-control-selected"),V(c,"ytp-segmented-control-deselected")}
-f.Eu=function(a){for(var b=0;b<this.a.length;b++)if(this.a[b]==a.currentTarget){b==this.b&&2==this.a.length?this.Ya(0==b?1:0):this.Ya(b);Af(this.element,"change");break}};f.F=function(){As(this,[]);this.g=null;zs.C.F.call(this)};function Cs(a){ys.call(this);this.label=a.getMsg("YTP_ANNOTATIONS_TITLE");this.element=new zs(a,[a.getMsg("YTP_ON"),a.getMsg("YTP_OFF")]);L(this,this.element);this.priority=2}y(Cs,ys);Cs.prototype.getSelected=function(){return this.element.getSelected()};Cs.prototype.Ya=function(a){this.element.Ya(a)};function Ds(a,b){this.start=a<b?a:b;this.end=a<b?b:a}Ds.prototype.clone=function(){return new Ds(this.start,this.end)};function Es(){}f=Es.prototype;f.Vc=!1;f.hf=null;f.Nl=null;function Fs(a,b,c){a.hf?(zd(a.hf.N(),b,c),a.hf.clear()):(b=new wr(b,c,void 0,void 0,void 0),a.hf=b,a.hf.Fp(),a.Nl=Rc("div"),a.Nl.appendChild(a.hf.N()));return a.hf}f.N=function(){return this.Nl};f.de=function(){};function Gs(a,b,c){var d=document.createElementNS("http://www.w3.org/2000/svg",a);b&&Eb(b,function(a,b){d.setAttribute(b,a)});for(var e=2;e<arguments.length;e++)d.appendChild(arguments[e]);return d}function Hs(a,b){var c;c=":"+(hr.getInstance().a++).toString(36);b.setAttribute("result",c);a.appendChild(b);return c};function Is(a,b){var c=Hs(a,Gs("feGaussianBlur",{"in":b,stdDeviation:"1.8"})),c=Hs(a,Gs("feDiffuseLighting",{"in":c,surfaceScale:"4",diffuseConstant:"1"},Gs("feDistantLight",{azimuth:"270",elevation:"15","lighting-color":"white"}))),c=Hs(a,Gs("feComposite",{"in":c,in2:b,operator:"in"}));return Hs(a,Gs("feComposite",{in2:c,"in":b,operator:"arithmetic",k2:1,k3:0.5,k4:0}))}
-function Js(a,b){var c=Hs(a,Gs("feOffset",{"in":b,dx:"-7",dy:"-7"})),c=Hs(a,Gs("feGaussianBlur",{"in":c,stdDeviation:"3"})),c=Hs(a,Gs("feColorMatrix",{"in":c,type:"matrix",values:"0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.5 0"})),d=Hs(a,Gs("feColorMatrix",{"in":b,type:"matrix",values:"0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 100 0"})),d=Hs(a,Gs("feGaussianBlur",{"in":d,stdDeviation:"1"})),c=Hs(a,Gs("feComposite",{operator:"out","in":c,in2:d}));return Hs(a,Gs("feComposite",{operator:"over","in":b,in2:c}))}
-function Ks(a,b){return b}function Ls(a){var b=Gs("filter",{filterUnits:"userSpaceOnUse"}),c="SourceGraphic";z(a,function(a){t:{switch(a){case "bevel":a=Is;break t;case "dropshadow":a=Js;break t}a=Ks}c=a(b,c)});return b}function Ms(a){a=Ja(a,function(a){return a in Ns});fb(a,function(a,c){return Ns[a]-Ns[c]});return a}function Os(a,b){if(!b)return null;var c="effects:"+(b?b.join("|"):""),d=c in a.a?a.a[c]:null;if(d)return d;d=Ls(b);return 0<d.childNodes.length?pr(a,c,d):null}
-function Ps(a){return Oa(a,function(a){return"dropshadow"==a})?new yb(0,7,7,0):new yb(0,0,0,0)}var Ns={bevel:1,dropshadow:2};function Qs(a,b,c,d,e){b=Rs(b,c,d?d.a/2+1:0);zr(a,b,d,e)}function Rs(a,b,c){var d=new Zq;ar(d,a.left+b+c,a.top+c);d.Ga(a.left+a.width-b-c,a.top+c);br(d,b,b,-90,90);d.Ga(a.left+a.width-c,a.top+a.height-b-c);br(d,b,b,0,90);d.Ga(a.left+b+c,a.top+a.height-c);br(d,b,b,90,90);d.Ga(a.left+c,a.top+b+c);br(d,b,b,180,90);d.close();return d}function Ss(a,b,c){b&&c&&a.setAttribute(b,"url(#"+c+")")}
-function Ts(a,b,c,d){var e=a.B;e?a=new Yq(e.j*b/100,e.o*c/100,e.k*b/100,e.H*c/100,e.a,e.b,e.g,e.i):(b=d?Math.max(a.a,0.9):a.a,a=new dr(a.j,b));return a}function Us(a,b){var c=new yb(a.top,a.left+a.width,a.top+a.height,a.left),d=Ps(b);ia(d)?(c.top-=d.top,c.right+=d.right,c.bottom+=d.bottom,c.left-=d.left):(c.top-=d,c.right+=void 0,c.bottom+=void 0,c.left-=NaN);return Db(c)}function Vs(a,b,c){c.length&&(b=Oa(b.childNodes,function(a){return"g"==a.tagName}))&&(a=Os(a,Ms(c)),Ss(b,"filter",a))};function Ws(){}y(Ws,Es);Ws.prototype.a=0;
-Ws.prototype.de=function(a,b,c){var d=a.b,e=d.H,g=this.Vc&&Kq(a),e=(e+=g?1:0)?new er(e,g?d.k:d.o):null;if(g=Oq(a)){var h=oq(g,b,c);if(!(0>=h.width||0>=h.height)){var k;if(k=(a=(a=a.a?a.a.a.length?a.a.a[0]:null:null)&&a.a?a.a:null)&&a.length?a[0]:null){var m;c=c?oq(c,b):null;a=jq(k,new Cb(k.B,k.G,k.k,k.i),b);c?(a.top+=c.top,a.left+=c.left):(a.top+=b.top,a.left+=b.left);m=new A(a.left,a.top);c=h.clone();a=new Cb(m.x,m.y,1,1);var g=Math.max(c.left+c.width,a.left+a.width),p=Math.max(c.top+c.height,a.top+
-a.height);c.left=Math.min(c.left,a.left);c.top=Math.min(c.top,a.top);c.width=g-c.left;c.height=p-c.top;c=Us(c,d.b);a=Fs(this,c.width,c.height);var g=Ts(d,c.width,c.height,this.Vc),h=new Cb(h.left-c.left,h.top-c.top,h.width,h.height),s=new A(m.x-c.left,m.y-c.top);this.a=17*lq(b,k.g,k.a?k.a:"xy");b=d.g;k=e?e.a/2:0;m=Xs(h,s);var p=this.b(h,b,s,m),r=s.x,s=s.y,D=h.width,M=h.height,sa=h.left,h=h.top,Y=new Zq;ar(Y,sa+b+k,h+k);"t"==m&&(Y.Ga(p.start,h+k),Y.Ga(r,s),Y.Ga(p.end,h+k));Y.Ga(sa+D-b-k,h+k);br(Y,
-b,b,-90,90);"r"==m&&(Y.Ga(sa+D-k,p.start),Y.Ga(r,s),Y.Ga(sa+D-k,p.end));Y.Ga(sa+D-k,h+M-b-k);br(Y,b,b,0,90);"b"==m&&(Y.Ga(p.end,h+M-k),Y.Ga(r,s),Y.Ga(p.start,h+M-k));Y.Ga(sa+b+k,h+M-k);br(Y,b,b,90,90);"l"==m&&(Y.Ga(sa+k,p.end),Y.Ga(r,s),Y.Ga(sa+k,p.start));Y.Ga(sa+k,h+b+k);br(Y,b,b,180,90);Y.close();zr(a,Y,e,g);if(e=this.N())V(e,"annotation-shape"),V(e,"annotation-speech-shape"),od(e,c.left,c.top),zd(e,c.width,c.height),Vs(a,e,d.b)}}}};
-function Xs(a,b){var c=a.top-b.y,d=b.x-a.left-a.width,e=b.y-a.top-a.height,g=a.left-b.x,h=Math.max(c,d,e,g);if(0>h)return"i";switch(h){case c:return"t";case d:return"r";case e:return"b";case g:return"l"}return"i"}Ws.prototype.b=function(a,b,c,d){function e(a,c,d){h=Math.min(Math.max(d-2*b,0),g);k=vb(a-h/2,c+b,c+d-h-b)}var g=this.a,h=0,k=0;"t"==d||"b"==d?e(c.x,a.left,a.width):"l"!=d&&"r"!=d||e(c.y,a.top,a.height);return new Ds(k,k+h)};function Ys(){}y(Ys,Es);Ys.prototype.de=function(a,b,c){var d=Oq(a);d&&(b=oq(d,b,c),0>=b.width||0>=b.height||(a=a.b,c=Us(b,a.b),d=Fs(this,c.width,c.height),Qs(d,new Cb(0,0,b.width,b.height),a.g,new er(!a.i&&this.Vc?1:a.i,a.j),new dr("#000",0)),b=this.N(),V(b,"annotation-shape"),Ed(b,this.Vc?Math.max(a.a,0.9):a.a),od(b,c.left,c.top),zd(b,c.width,c.height)))};function Zs(a,b,c){this.a=a||0;this.g=b||0;this.b=c||!1}y(Zs,Es);function $s(a,b){var c=a.width,d=a.height,e=0,g=0;0<b&&(a.width/a.height>b?(d=a.width/b,g=(a.height-d)/2):(c=a.height*b,e=(a.width-c)/2));return new Cb(e,g,c,d)}
-Zs.prototype.de=function(a,b,c){var d=oq(Oq(a),b,c);if(!(0>=d.width||0>=d.height)){var e=$s(d,this.g);e.left+=d.left;e.top+=d.top;b=a.b;c=Us(e,b.b);var g=Fs(this,c.width,c.height),h=new dr("#000",0),e=$s(e,this.a);a=a.j?a.j.a?a.j.a:a.j.L?$n(a.j.L,"hqdefault.jpg"):"":"";e=or(g,"image",{x:e.left,y:e.top,width:e.width,height:e.height,"image-rendering":"optimizeQuality",preserveAspectRatio:"none"});e.setAttributeNS("http://www.w3.org/1999/xlink","href",a);a=new vr(e,g);g.b.N().appendChild(a.N());if(e=
-this.N()){var k=this.Vc?Math.max(b.a,0.9):b.a;Ed(e,k);if(this.b&&0<b.i){var k=new er(b.i,b.j),d=new Cb(0,0,d.width,d.height),m;m=Rs(d,b.g,k.a/2+1);var p="mask"in g.a?g.a.mask:null;if(p)m=p;else{var p=document.createElementNS("http://www.w3.org/2000/svg","mask"),s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",Ar(m));s.setAttribute("fill","#FFF");p.appendChild(s);m=pr(g,"mask",p)}Ss(a.N(),"mask",m);Qs(g,d,b.g,k,h)}V(e,"annotation-shape");V(e,"annotation-image-shape");
-od(e,c.left,c.top);zd(e,c.width,c.height);Vs(g,e,b.b)}}};function at(){}y(at,Es);at.prototype.de=function(a,b,c){var d=Oq(a);if(d){var e=oq(d,b,c);if(!(0>=e.width||0>=e.height)){b=a.b;c=Us(e,b.b);var d=Fs(this,c.width,c.height),g=b.H;a=this.Vc&&Kq(a);a=(g+=a?1:0)?new er(g,a?b.k:b.o):null;g=new Cb(0,0,e.width,e.height);e=Ts(b,e.width,e.height,this.Vc);Qs(d,g,b.g,a,e);if(a=this.N())V(a,"annotation-shape"),V(a,"annotation-popup-shape"),od(a,c.left,c.top),zd(a,c.width,c.height),Vs(d,a,b.b)}}};function bt(){}y(bt,Ws);bt.prototype.b=function(a,b,c,d){function e(a,c,d){h=Math.min(Math.max(d-2*b,0),g);k=a<=c+d/2?Math.max(c+d/4-h/2,c+b):Math.min(c+3*d/4-h/2,c+d-h-b)}var g=this.a,h=0,k=0;"t"==d||"b"==d?e(c.x,a.left,a.width):"l"!=d&&"r"!=d||e(c.y,a.top,a.height);return new Ds(k,k+h)};function ct(a,b){this.b=Jc(a);this.a=eo(this.b,b)}
-function dt(a,b){var c=fo(a.a,b,void 0),c=c.replace(/^[\s\xa0]+/,""),d;d=String(c.substr(0,3)).toLowerCase();(d=0==("<tr"<d?-1:"<tr"==d?0:1))&&(c="<table><tbody>"+c+"</tbody></table>");var e=c,g=document,c=g.createElement("div");C?(c.innerHTML="<br>"+e,c.removeChild(c.firstChild)):c.innerHTML=e;if(1==c.childNodes.length)c=c.removeChild(c.firstChild);else{for(e=g.createDocumentFragment();c.firstChild;)e.appendChild(c.firstChild);c=e}d&&(c=Yc(Yc(c)));return c};function et(a,b,c,d,e){this.a=a;this.j=b;this.g=c;this.o=d;this.k=e;this.i=new Uo(this)}f=et.prototype;f.na=null;f.Yc=null;f.fc=null;f.Fa=null;f.al=null;function ft(a,b){var c=v(function(a,c,g){c=g?gt(this,c,v(g,this)):gt(this,c);this.i.listen(b,a,c)},a);c("mouseover","e",a.Uw);c("mouseout","d",a.Tw);c("click","b");c("mousedown","a");c("touchend","b")}
-function ht(a){if(a.a.H){var b;if(La(a.a.g,function(a){return"close"==a.type},void 0))b=a.na;else{b=dt(new ct("annotation-close-button-template",[]),{});if(!(b instanceof Element))return;a.fc=b;Oe(a.fc,"annotation_id",a.a.id);a.na.appendChild(a.fc);b=a.fc}var c=function(a){a.stopPropagation()};a.i.listen(b,"click",gt(a,"c",c));a.i.listen(b,"touchend",gt(a,"c",c))}}
-function gt(a,b,c){return v(function(a){if(this.k)c&&c(a);else if(a.target instanceof Element){Sn(a.target);var e=document.elementFromPoint(a.clientX,a.clientY);Rn(a.target);Om(e,"annotation")&&Af(e,a.type)}this.o.u(b,this.a)},a)}f.Uw=function(){this.fc&&Rn(this.fc);this.Yc&&Ed(this.Yc,1);var a=it(this);this.Fa&&(this.Fa.Vc=!0,Ed(this.na,jt(this)?1:0),a&&this.Fa.de(this.a,a,kt(this)))};
-f.Tw=function(){this.fc&&Sn(this.fc);this.Yc&&Ed(this.Yc,0);var a=it(this);this.Fa&&(this.Fa.Vc=!1,Ed(this.na,jt(this)?1:0),a&&this.Fa.de(this.a,a,kt(this)))};function kt(a){return a.al?Oq(a.al):null}
-function Wq(a){if(a.na||a.Fa){var b=Oq(a.a);if(b){var c=it(a),d=kt(a);if(a.na&&c){b=oq(b,c,d);zd(a.na,b.width,b.height);od(a.na,b.left,b.top);var e=a.g.Dg;e&&(e=new yb(360*lt(a).top*Qq(a.a,e)/100,640*lt(a).right*Pq(a.a,e)/100,360*lt(a).bottom*Qq(a.a,e)/100,640*lt(a).left*Pq(a.a,e)/100),a.Yc&&(e.right+=1.5*c.height/100),a.na.style.padding=e.top+"px "+e.right+"px "+e.bottom+"px "+e.left+"px");"label"==a.a.style&&a.b&&(a.b.style.padding=a.na.style.padding);if(a.Yc){e=4.2*c.height/100;e=new B(e,e);zd(a.Yc,
-e);if("highlight"==a.a.type||"label"==a.a.style)var g=1.5*c.height/100,e=new A(b.width-e.width-g,b.height-e.height-g);else e=new A(b.width-e.width-3*c.height/100,(b.height-e.height)/2);od(a.Yc,e)}if(a.fc){zd(a.fc,new B(18,18));var e=a.fc,g=Bd(a.fc),h=9<=c.left+c.width-(b.left+b.width),k=9<=b.top-c.top;od(e,h&&k?new A(b.width-9,-9):h?new A(b.width-9,b.height>27+g.height?9:b.height-9):k?new A(b.width>27+g.width?b.width-9-g.width:-9,-9):b.width/c.width>b.height/c.height?new A(b.width>27+g.width?b.width-
-9-g.width:-9,b.height-9):new A(-9,b.height>27+g.height?9:b.height-9))}}a.Fa&&c&&a.Fa.de(a.a,c,d);if(a.na){c=a.na;d=a.a.b;c.style.color="highlightText"==a.a.style?d.G:d.k;c.style.fontSize=360*d.I*Qq(a.a,a.g.Dg)/100+"px";c.style.textAlign=d.textAlign?d.textAlign:"title"==a.a.style||"highlightText"==a.a.style?"center":"left";d.A&&(c.style.fontWeight=d.A);a=a.na;c=a.style.overflow;(d=E("annotation-link-icon",a))&&Sn(d);a.style.overflow="scroll";for(b=100;0<b&&!(a.scrollHeight<=a.offsetHeight&&a.scrollWidth<=
-a.offsetWidth);b--){e=Pd(a);if(5>e)break;e--;a.style.fontSize=e+"px"}a.style.overflow=c;d&&Rn(d)}}}}function lt(a){var b=a.a.b;return b.padding?b.padding:new yb("speech"==a.a.style?1.6:0.8,"speech"==a.a.style?1.6:0.8,"speech"==a.a.style?1.6:0.8,"speech"==a.a.style?1.6:0.8)}
-f.show=function(){var a=this.a.b,a=(a&&0==a.a||"title"==this.a.style||"highlightText"==this.a.style||"pause"==this.a.type?!1:!0)&&!this.Fa,b=!this.na,c="widget"==this.a.type;if(a){var d=it(this);if(d){var e=null;"highlight"==this.a.type||"label"==this.a.style?e=new Ys:"popup"==this.a.style?e=new at:"anchored"==this.a.style?e=new Ws:"speech"==this.a.style?e=new bt:"image"==this.a.type&&("video"==this.a.style?e=new Zs(4/3,16/9,!0):"channel"==this.a.style&&(e=new Zs));e&&(e.de(this.a,d,kt(this)),this.Fa=
-e,d=e.N())&&(Sn(d),V(d,"annotation-type-"+this.a.type.toLowerCase()),this.j(d))}}if(b){d=["annotation","hid"];"highlightText"!=this.a.style||d.push("annotation-no-mouse");d.push("annotation-type-"+this.a.type.toLowerCase());this.na=Rc("div",d);this.a.o&&("label"==this.a.style?(this.b=Rc("div",["label-text"]),this.b.style.backgroundColor=this.a.b.j,ad(this.b,this.a.o),this.na.appendChild(this.b)):ad(this.na,this.a.o));Oe(this.na,"annotation_id",this.a.id);this.j(this.na);ft(this,this.na);if(Kq(this.a)&&
-"image"!=this.a.type&&Jq(this.a)){if(d=xp(this.a))this.na.title=Zp(d);this.Yc=Rc("span","annotation-link-icon");this.na.appendChild(this.Yc)}ht(this);Kq(this.a)||(this.na.style.cursor="default")}c&&("subscribe"==this.a.style?E("yt-uix-subscription-button",this.na)||(this.na.innerHTML=this.a.k):this.a.k&&(this.na.innerHTML=this.a.k));if(a||b){t:{a=this.a.a.a;if(a.length&&(a=vq(a[0]))){a=a.o;break t}a=0}this.na&&(this.na.style.zIndex=a);this.Fa&&this.Fa.N()&&(this.Fa.N().style.zIndex=a)}Rn(this.na);
-Ed(this.na,jt(this)?1:0);Wq(this);this.Fa&&Rn(this.Fa.N())};f.hide=function(){Sn(this.na);this.Fa&&Sn(this.Fa.N())};function jt(a){return"label"!=a.a.style||a.Fa.Vc}function it(a){var b=a.g.Dg;return b?"player_relative"==a.a.G?(a=a.g.Tc)?new Cb(-b.left,-b.top,a.width,a.height):null:new Cb(0,0,b.width,b.height):null};function mt(a){Tm.call(this,a);this.b={};this.i={};this.j=new ws(this.H,this.a.J());var b=Q(a),c=E("html5-annotations-button",b);this.g=null;a.J().Ma?(F(c),this.g=new Cs(this.a.app.S.B),this.g.listen("change",this.Hq,this)):J(c,"click",v(this.Mq,this));this.D("onHideControls",this.Lq,this);this.D("onShowControls",this.Oq,this);this.D("onStateChange",this.Nq,this);this.D("e",this.Qq,this);this.D("d",this.Pq,this);this.D("a",this.Jq,this);this.D("b",this.Iq,this);this.D("c",this.Kq,this);a=E("video-annotations",
-b);a=E("countdowntimer",a);this.k=Rc("DIV",["video-annotations","html5-stop-propagation"]);Wm(this,this.k);Wm(this,a);this.A=new Cr(a,v(this.xj,this))}y(mt,Tm);f=mt.prototype;f.qa="iv-module";f.Fl=!1;f.qp=!0;f.ba=!1;f.Dd=0;function nt(a){return E("video-annotations",Q(a))&&ot(a)?new mt(a):null}function ot(a){return"leanback"==a.J().Y?!1:Bm(a.getVideoData(),"iv3_module")}f.Xa=function(){return ot(this.a)};
-f.create=function(){mt.C.create.call(this);this.g&&this.u("module_menu_add",this.g);1==(this.a.J().fa||this.a.getVideoData().fa)?this.load():pt(this,"tooltip-default")};f.destroy=function(){this.unload();this.g&&this.u("module_menu_remove",this.g);mt.C.destroy.call(this)};f.Mq=function(){this.ba||this.Dd?this.unload():this.load()};f.Hq=function(){var a=this.ba||this.Dd,b=0==this.g.getSelected();a&&!b?this.unload():!a&&b&&this.load()};f.Nq=function(a){this.qp=P(a.state,8);0>Ro(a,4)&&this.A.stop()};
-f.load=function(){mt.C.load.call(this);pt(this,"tooltip-alt");var a={format:"XML",method:"GET",rd:v(this.Vo,this,null)},b=this.a.getVideoData();b.Sk&&(this.Dd++,Qj(b.Sk,a));b.Rk&&(this.Dd++,Qj(b.Rk,a));b.Qk&&(this.a.J().Qc||this.a.J().Kc)&&(a={format:"XML",method:"GET",rd:v(this.Vo,this,v(this.jv,this,b.Ka))},this.Dd++,Qj(b.Qk,a));this.g&&this.g.Ya(0)};
-f.unload=function(){this.g&&this.g.Ya(1);this.j.log_({"iv-event":1});this.xj();Um(this);Eb(this.b,function(a){a.destroy()});Eb(this.i,function(a){a.destroy()});this.Dd=0;this.ba=!1;this.b={};this.i={};pt(this,"tooltip-default");mt.C.unload.call(this)};function pt(a,b){var c=E("html5-annotations-button",Q(a.a));if(c){var d=G(c,b)||"";Oe(c,"tooltip",d);c.setAttribute("aria-label",d)}}
-function qt(a,b){for(var c={},d=0;d<b.attributes.length;d++){var e=b.attributes[d];c[e.name]=e.nodeValue}for(d=0;d<b.childNodes.length;d++)if(e=b.childNodes[d],e.tagName){var g;if(c[e.tagName])g=c[e.tagName];else if("html_blob"==e.tagName||"data"==e.tagName){c[e.tagName]=e.childNodes[0].nodeValue.trim();continue}else g=[],c[e.tagName]=g;e&&"TEXT"==e.tagName?1==e.childNodes.length&&3==e.childNodes[0].nodeType?g.push(e.childNodes[0].nodeValue):g.push(""):e&&g.push(qt(a,e))}return c}
-f.Vo=function(a,b){if(this.Dd&&!this.ba){this.Dd--;var c=b.responseXML?b.responseXML.getElementsByTagName("annotations"):null;if(Mj(b)&&c){c=c[0];a&&a(c);rt(this,c);V(Q(this.a),this.qa+"-loaded");0==this.Dd&&(this.ba=!0);var c=[],d;for(d in this.b){var e=this.b[d].qb;if(e.a)if(e=e.a,e.a.length)if(e=e.a[0].b||e.a[0].a,!e||2>e.length)e=null;else var g=e.length-1,e=0>=e[0].b&&0>=e[g].b?null:{start:e[0].b,end:e[g].b};else e=null;else e=null;if(g=e)e=1E3*g.start,g=1E3*g.end,0==e&&(e++,g++),e==g&&g++,g<
-e||(e=new Zh(e,g,{id:d}),c.push(e))}for(d in this.i)e=this.i[d].qb,e=new Zh(e.data.start_ms,e.data.end_ms,{id:d}),c.push(e);this.zf.apply(this,c)}}};function st(a,b){var c=tt(a,b);if(!c)return null;Mq(b,function(a){a=v(this.lx,this,b.id,a);this.D("ivTrigger:"+b.id,a)},a);return new Tq(a.H,b,c)}function ut(a,b){var c=Rc("div",["annotation","annotation-type-custom","hid"]);a.k.appendChild(c);var d=null;switch(b.style){case "video":d=new tp(b,c,new Uo(a),a.a.J(),a.j)}d&&qp(d,a.H);return d}
-function rt(a,b){for(var c=b.getElementsByTagName("annotation"),d=0;d<c.length;d++){var e=qt(a,c[d]),g=null;try{g=Iq(e)}catch(h){}g&&("custom"==g.type?(e=ut(a,g))&&(a.i[g.id]=e):(e=st(a,g))&&(a.b[g.id]=e))}Eb(a.b,function(a){var b=a.qb;b.a&&b.a.b&&(b=this.b[b.a.b])&&(a.b.al=b.qb)},a)}f.xc=function(a){mt.C.xc.call(this,a);a=a.getId();var b=this.b[a],c=this.i[a];c&&!c.Ib?c.show():b&&!b.Ib&&(b=b.qb,"pause"==b.type?vt(this,b):(wt(this,a),a=this.j,b&&b.i&&a.log_(sp(a,b,2))))};
-f.$c=function(a){mt.C.$c.call(this,a);xt(this,a.getId())};function vt(a,b){if(a.qp){var c=Oa(b.g,function(a){return"pause"==a.type&&!!a.duration&&!!a.duration.value},void 0);c&&(a.Fl=!0,a.u("command_pause"),a.A.start(1E3*c.duration.value))}}function xt(a,b,c,d){var e=a.i[b];if(e&&!e.Ib)e.hide();else if(b=a.b[b])Vq(b),d=d&&a.b[d]&&a.b[d].isVisible,c&&c.b&&d?(a=v(a.yo,a,b),b.a=new Xo(a,2E3),b.a.start()):a.yo(b)}f.yo=function(a){if(a){a.hide();var b=a.qb.id;this.u(Sq("shown",b),!1,b);zt(this,a.qb,"hidden")}};
-function wt(a,b,c,d){if(b=a.b[b])Vq(b),d=d&&a.b[d]&&a.b[d].isVisible,c&&c.i&&d?(a=v(a.zo,a,b),b.a=new Xo(a,2E3),b.a.start()):a.zo(b)}f.zo=function(a){if(a){a.show();var b=a.qb.id;this.u(Sq("shown",b),!0,b);zt(this,a.qb,"shown")}};f.lx=function(a,b,c,d){c?wt(this,a,b,d):xt(this,a,b,d)};f.Jq=function(a){if(a&&a.id){var b=this.j;a&&a.i&&xp(a)&&b.log_(sp(b,a,8))}};
-f.Iq=function(a){if(a&&a.id){var b=xp(a),c=v(function(){b&&zt(this,a,"click")},this);us(Zp(b))&&"new"!=b.target||(c(),c=null);yp(this.j,a,c)}};
-function zt(a,b,c){Lq(b,function(a){if(a.trigger==c)switch(a.type){case "log":a.url&&Qg(a.url.value);break;case "openUrl":var e=this.a.getVideoData(),g=vs(a.url,e);if(-1!=g){this.u("command_seek",g);this.xj();break}if(e=(g=Zp(a.url))?us(g)?Kj(g,{src_vid:e.L,feature:"iv",annotation_id:b.id}):g:null)fn(this),window.open(e,a.url.target?"new"==a.url.target?"_blank":"_top":us(Zp(a.url))?"_top":"_blank")}},a)}f.Lq=function(){this.u(Sq("playerControlShow",void 0),!1,void 0)};
-f.Oq=function(){this.u(Sq("playerControlShow",void 0),!0,void 0)};f.Qq=function(a){a=a.id;this.u(Sq("rollOver",a),!0,a)};f.Pq=function(a){a=a.id;this.u(Sq("rollOver",a),!1,a)};f.Kq=function(a){if(a||a.id)if(this.b[a.id].Ib=!0,xt(this,a.id),a){var b=this.j;a&&a.i&&b.log_(sp(b,a,4));zt(this,a,"close")}};f.xj=function(){this.A.stop();this.Fl&&(this.Fl=!1,this.u("command_play"))};
-function tt(a,b){if(At(b)){var c=b.H||La(b.g,function(a){return"click"==a||"rollOut"==a||"rollOut"==a},void 0);return new et(b,v(a.k.appendChild,a.k),a.a.J(),a.H,c)}return null}function At(a){if("highlight"==a.type||"image"==a.type||"widget"==a.type)return!0;if("text"==a.type)for(var b in Fq)if(a.style==Fq[b])return!0;return!1}
-function Bt(a,b,c,d,e){var g=a.ownerDocument.createElement("action");g.setAttribute("type","log");g.setAttribute("trigger",d);a=a.ownerDocument.createElement("url");d={};d.value="a_id="+c;d.label="cta_annotation_"+e;b=Kj(b,d);a.setAttribute("value",b);g.appendChild(a);return g}
-f.jv=function(a,b){if(a)for(var c=b.getElementsByTagName("annotation"),d=0;d<c.length;d++){var e=c[d],g=qt(this,e);if(Hp(g,"logable",!0)){var g=Bp(g,"id","REQUIRED"),h=e.getElementsByTagName("action"),h=h.length?h[0]:null;e.insertBefore(Bt(e,a,g,"shown","shown"),h);e.insertBefore(Bt(e,a,g,"click","clicked"),h);e.insertBefore(Bt(e,a,g,"close","closed"),h)}}};var Ct;function Dt(a,b){fa(b)&&(b=b.join(" "));if(""===b||void 0==b){var c;Ct||(Ct={atomic:!1,autocomplete:"none",dropeffect:"none",haspopup:!1,live:"off",multiline:!1,multiselectable:!1,orientation:"vertical",readonly:!1,relevant:"additions text",required:!1,sort:"none",busy:!1,disabled:!1,hidden:!1,invalid:"false"});c=Ct;"pressed"in c?a.setAttribute("aria-pressed",c.pressed):a.removeAttribute("aria-pressed")}else a.setAttribute("aria-pressed",b)};function Et(a,b,c,d,e){En.call(this,a,b,c,c);this.O=b;this.Q=this.P=c;this.B=d||null;this.G=e||null;this.I=e||null;this.b=!1}y(Et,En);function Ft(a){Gn(a,a.b&&a.B?a.B:a.O);a.Jb(a.b&&a.G?a.G:a.P);a.a=a.b&&a.I?a.I:a.Q;X(a.element,"ytp-button-pressed",a.b)}function Gt(a){a.b=!0;Dt(a.element,!0);Ft(a)}function Ht(a){a.b=!1;Dt(a.element,!1);Ft(a)}Et.prototype.F=function(){this.I=this.G=this.B=null;uf(this.U);this.U=null;Et.C.F.call(this)};function It(a){Z.call(this,["div","ytp-action-buttons"]);this.g=new Et(a,"ytp-button-info",a.getMsg("YTP_BUTTON_INFO"));L(this,this.g);this.g.V(this.element);this.i=new Et(a,"ytp-button-share",a.getMsg("YTP_BUTTON_SHARE"));L(this,this.i);this.i.V(this.element);this.a=new Et(a,"ytp-button-dislike",a.getMsg("YTP_BUTTON_DISLIKE"));L(this,this.a);this.listen(this.a,"click",this.j);this.a.V(this.element);this.b=new Et(a,"ytp-button-like",a.getMsg("YTP_BUTTON_LIKE"));L(this,this.b);this.listen(this.b,"click",
-this.o);this.b.V(this.element);this.b.hide();this.a.hide()}y(It,Z);It.prototype.o=function(){Gt(this.b);Ht(this.a)};It.prototype.j=function(){Gt(this.a);Ht(this.b)};function Jt(a){var b=ke("/signin?context=popup","next",document.location.protocol+"//"+document.domain+"/post_login"),b=ke(b,"feature","sub_button");if(b=window.open(b,"loginPopup","width=375,height=440,resizable=yes,scrollbars=yes",!0)){var c=Gr("LOGGED_IN",function(b){Kr();a(b)});af("LOGGED_IN_PUBSUB_KEY",c);b.moveTo((screen.width-375)/2,(screen.height-440)/2)}}pa("yt.pubsub.publish",Lr);function Kt(){this.a={}}y(Kt,Ur);ca(Kt);f=Kt.prototype;f.fj="tooltip";f.ej=0;f.register=function(){Vr(this,"mouseover",this.Xp);Vr(this,"mouseout",this.Tl);Vr(this,"click",this.Tl);Vr(this,"touchstart",this.Sx);Vr(this,"touchend",this.cq);Vr(this,"touchcancel",this.cq)};f.mq=function(){return!(this.g&&0==pc.indexOf("6"))};
-f.Xp=function(a){if(!(this.ej&&1E3>x()-this.ej)){var b=parseInt(G(a,"tooltip-hide-timer"),10);b&&(this.removeData(a,"tooltip-hide-timer"),I(b));var b=v(function(){Lt(this,a);this.removeData(a,"tooltip-show-timer")},this),c=parseInt(G(a,"tooltip-show-delay"),10)||0,b=H(b,c);Oe(a,"tooltip-show-timer",b.toString());a.title&&(Wr(a,Mt(a)),a.title="")}};
-f.Tl=function(a){var b=parseInt(G(a,"tooltip-show-timer"),10);b&&(I(b),this.removeData(a,"tooltip-show-timer"));b=v(function(){Nt(this,a);this.removeData(a,"tooltip-hide-timer")},this);b=H(b,50);Oe(a,"tooltip-hide-timer",b.toString());if(b=G(a,"tooltip-text"))a.title=b};f.Sx=function(a,b){this.ej=0;var c=Qr(b,$(this),null[0].target);this.Xp(c)};f.cq=function(a,b){this.ej=x();var c=Qr(b,$(this),null[0].target);this.Tl(c)};function Ot(a,b){Wr(a,b);var c=G(a,"content-id");if(c=Jc(c))c.innerHTML=b}
-function Mt(a){return G(a,"tooltip-text")||a.title}
-function Lt(a,b){if(b){var c=Mt(b);if(c){var d=Jc(Pt(a,b));if(!d){d=document.createElement("div");d.id=Pt(a,b);d.className=$(a,"tip");var e=document.createElement("div");e.className=$(a,"tip-body");var g=document.createElement("div");g.className=$(a,"tip-arrow");var h=document.createElement("div");h.className=$(a,"tip-content");var k=Qt(a,b),m=Pt(a,b,"content");h.id=m;Oe(b,"content-id",m);e.appendChild(h);k&&d.appendChild(k);d.appendChild(e);d.appendChild(g);(Cf()||document.body).appendChild(d);Ot(b,
-c);(c=parseInt(G(b,"tooltip-max-width"),10))&&e.offsetWidth>c&&(e.style.width=c+"px",Ac(h,$(a,"normal-wrap")));h=Dc(b,$(a,"reverse"));Rt(a,b,d,e,k,h)||Rt(a,b,d,e,k,!h);var p=$(a,"tip-visible");H(function(){Ac(d,p)},0)}}}}
-function Rt(a,b,c,d,e,g){Ec(c,$(a,"tip-reverse"),g);var h=0;g&&(h=1);a=Bd(b);g=new A((a.width-10)/2,g?a.height:0);var k=td(b);Nr(new A(k.x+g.x,k.y+g.y),c,h);h=Oc(window);k=wd(c);c=Bd(d);var m=Math.floor(c.width/2);e&&(e.style.left="3px",e.style.height=c.height+"px",e.style.width=c.width+"px");e=!!(h.height<k.y+a.height);a=!!(k.y<a.height);g=!!(k.x<m);h=!!(h.width<k.x+m);k=(c.width+3)/-2- -5;b=G(b,"force-tooltip-direction");if("left"==b||g)k=-5;else if("right"==b||h)k=20-c.width-3;d.style.left=Math.floor(k)+
-"px";return!(e||a)}function Nt(a,b){if(b){var c=Jc(Pt(a,b));c&&(St(c),F(c),a.removeData(b,"content-id"))}}function Pt(a,b,c){a=$(a);var d=b.__yt_uid_key;d||(d=Re(),b.__yt_uid_key=d);b=a+d;c&&(b+="-"+c);return b}function Qt(a,b){var c=null;Xb&&Dc(b,$(a,"masked"))&&((c=Jc("yt-uix-tooltip-shared-mask"))?(c.parentNode.removeChild(c),Rn(c)):(c=document.createElement("iframe"),c.src='javascript:""',c.id="yt-uix-tooltip-shared-mask",c.className=$(a,"tip-mask")));return c}
-function St(a){var b=Jc("yt-uix-tooltip-shared-mask"),c=b&&hd(b,function(b){return b==a},!1,2);b&&c&&(b.parentNode.removeChild(b),Sn(b),document.body.appendChild(b))};function Tt(){this.a={};this.i=[]}y(Tt,Ur);ca(Tt);Tt.prototype.fj="subscription-button";
-Tt.prototype.register=function(){Vr(this,"click",this.Cp);this.i.push(Gr("subscription-subscribe-loading",this.Bp,this),Gr("subscription-subscribe-loaded",this.Ap,this),Gr("subscription-unsubscirbe-loading",this.Bp,this),Gr("subscription-unsubscribe-loaded",this.Ap,this),Gr("subscription-subscribe-success",this.Rw,this),Gr("subscription-unsubscribe-success",this.Sw,this),Gr("subscription-enable-ypc",this.Qw,this),Gr("subscription-disable-ypc",this.Pw,this))};
-var Ut={Wp:"hover-enabled",Mx:"yt-uix-button-subscribe",Nx:"yt-uix-button-subscribed",aA:"ypc-enabled",ay:"yt-uix-button-subscription-container",by:"yt-subscription-button-disabled-mask-container"},Vt={oA:"channel-external-id",Ox:"subscriber-count-show-when-subscribed",Px:"subscriber-count-tooltip",Qx:"subscriber-count-title",NB:"href",iq:"is-subscribed",uC:"parent-url",LC:"sessionlink",Rx:"style-type",jq:"subscription-id",VC:"target",Tx:"ypc-enabled",aq:"ypc-item-type",$p:"ypc-item-id",bq:"ypc-offers-url"};
-f=Tt.prototype;f.Cp=function(a){var b=G(a,"href"),c=!!ef("subscription_ajax");if(b)a=G(a,"target")||"_self",window.open(b,a);else if(c){var b=G(a,"channel-external-id"),c=G(a,"sessionlink"),d;if(G(a,"ypc-enabled")){d=G(a,Vt.aq);var e=G(a,Vt.$p),g=G(a,Vt.bq);d={itemType:d,itemId:e,offersUrl:g,subscriptionElement:a}}else d=null;e=G(a,"parent-url");G(a,"is-subscribed")?(g=G(a,"subscription-id"),Lr("subscription-unsubscribe",b,g,d,a,c,e)):Lr("subscription-subscribe",b,d,a,c,e)}else Wt(this,a)};
-f.Bp=function(a){this.$f(a,this.gq,!0)};f.Ap=function(a){this.$f(a,this.gq,!1)};f.Rw=function(a,b){this.$f(a,this.hq,!0,b)};f.Sw=function(a){this.$f(a,this.hq,!1)};f.Qw=function(a){this.$f(a,this.Wx)};f.Pw=function(a){this.$f(a,this.Vx)};f.hq=function(a,b,c){b?(Oe(a,Vt.iq,"true"),c&&Oe(a,Vt.jq,c)):(this.removeData(a,Vt.iq),this.removeData(a,Vt.jq));Xt(a)};f.gq=function(a,b){var c=gd(a,Ut.ay);Ec(c,Ut.by,b);a.setAttribute("aria-busy",b?"true":"false");a.disabled=b};
-function Xt(a){var b=G(a,Vt.Rx),c=!!G(a,"is-subscribed"),b="-"+b,d=Ut.Nx+b;Ec(a,Ut.Mx+b,!c);Ec(a,d,c);G(a,Vt.Px)&&!G(a,Vt.Ox)&&(b=$(Kt.getInstance()),Ec(a,b,!c),a.title=c?"":G(a,Vt.Qx));c?H(function(){Ac(a,Ut.Wp)},1E3):Bc(a,Ut.Wp)}f.Wx=function(a){var b=!!G(a,Vt.aq),c=!!G(a,Vt.$p),d=!!G(a,Vt.bq);!G(a,"ypc-enabled")&&b&&c&&d&&(Ac(a,"ypc-enabled"),Oe(a,Vt.Tx,"true"))};f.Vx=function(a){G(a,"ypc-enabled")&&(Bc(a,"ypc-enabled"),this.removeData(a,"ypc-enabled"))};
-function Yt(a,b){var c=Kc($(a));return Ja(c,function(a){return b==G(a,"channel-external-id")},a)}f.my=function(a,b,c){var d=cb(arguments,2);z(a,function(a){b.apply(this,Za(a,d))},this)};f.$f=function(a,b,c){var d=Yt(this,a),d=Za([d],cb(arguments,1));this.my.apply(this,d)};function Wt(a,b){var c=v(function(a){a.subscription_ajax&&df("subscription_ajax",a.subscription_ajax);this.Cp(b)},a);Jt(c)};function Zt(a){this.b=a||1;In.call(this,30*this.b,30*this.b);this.o=this.width/2;this.i=this.height/2;this.B=0;this.Z.translate(this.o,this.i)}y(Zt,In);Zt.prototype.show=function(){Zt.C.show.call(this);var a=this.G;this.j=new Date;this.g(a,125)};
-Zt.prototype.G=function(){this.Z.clearRect(-this.o,-this.i,this.width,this.height);for(var a=this.B++%8,b=0;8>b;b++){var c=2*Math.PI/8*(a+b),d=11*this.b*Math.cos(c),c=11*this.b*Math.sin(c),e=(b+1)/9;this.Z.beginPath();this.Z.arc(d,c,4*this.b,0,2*Math.PI,!1);this.Z.fillStyle="rgba(189, 189, 189, "+e+")";this.Z.fill()}};Zt.prototype.hide=function(){I(this.a);Zt.C.hide.call(this)};function $t(){Z.call(this,["div","ytp-sentiment-display",["div","ytp-sentiment-bar",["div","ytp-sentiment-bar-likes"],["div","ytp-sentiment-bar-dislikes"]],["div","ytp-sentiment-text","{{sentiment}}"]]);this.b=this.template.a["ytp-sentiment-bar-likes"];this.a=this.template.a["ytp-sentiment-bar-dislikes"]}y($t,Z);$t.prototype.F=function(){this.a=this.b=null;$t.C.F.call(this)};function au(a){a=["button","ytp-button-share-more",["div","ytp-button-share-more-icon yt-uix-button-icon-new-window"],["span","ytp-button-share-more-content",a.getMsg("YTP_BUTTON_MORE_SHARE")]];Z.call(this,a)}y(au,Z);function bu(a,b,c,d){En.call(this,a,"share-service-icon-"+d+"-sharebar",b,c);V(this.element,"share-service-icon-sharebar")}y(bu,En);function cu(){Z.call(this,["div","ytp-share-url-container",["input","ytp-share-url"]]);this.a=this.template.a["ytp-share-url"]}y(cu,Z);cu.prototype.F=function(){this.a=null;cu.C.F.call(this)};function du(a,b,c){R.call(this);this.a=a;this.g=b;this.i=c;this.gb=new Uo(this);this.j=this.b=this.k=this.ka=null;this.A=this.o=!1}y(du,R);f=du.prototype;f.Wj=function(){var a=E("html5-title",this.a);this.k=E("html5-title-text",a);this.gb.listen(this.k,"click",this.En);this.b=new It(this.i);this.b.V(a,1);this.gb.listen(this.b.g,"click",this.kk);this.g.of&&this.b.g.hide();this.gb.listen(this.b.i,"click",this.di)};f.reset=function(){};
-f.update=function(a){this.ka=a;this.reset();ad(this.k,a.title||"");Rn(this.a)};f.En=function(){this.Mi(this.ka.Oc||eu(this.g,this.ka))};f.kk=function(){if(!this.o){this.o=!0;sn(this.ka?this.ka.L:void 0,!1,this.Fs,ba,this,this.g.Ea,this.g.Ua);if(!this.j){var a=E("html5-info-panel-loading-icon",this.a);this.j=new Zt;V(this.j.element,"html5-info-panel-loader");this.j.V(a);L(this,this.j)}this.j.show()}Ht(this.b.i);W(this.a,"show-share");a=this.b.g;a.b?Ht(a):Gt(a);return Rm(this.a,"show-more-info")};
-f.di=function(a){Ht(this.b.g);W(this.a,"show-more-info");if("detailpage"!=this.g.Y){if(!this.A){this.A=!0;var b={action_get_share_info:1,feature:"player_embedded",video_id:this.ka?this.ka.L:void 0};this.g.Ea&&(b.authuser=this.g.Ea);this.g.Ua&&(b.pageid=this.g.Ua);Qj("/share_ajax",{Z:this,method:"GET",onError:this.Rt,Qa:this.St,yf:b})}a&&a.stopPropagation();a=this.b.i;a.b?Ht(a):Gt(a);Rm(this.a,"show-share")}};
-f.Fs=function(a,b){if(!this.ha()){var c=E("html5-info-panel",this.a),d=b.user_info;this.ka&&(this.ka.va=d.external_id);var e=E("html5-author-img",c).getElementsByTagName("img")[0];e.src=d.image_url;this.gb.listen(e,"click",this.Wn);e=E("html5-author-name",c);ad(e,d.username);this.gb.listen(e,"click",this.Wn);e=b.video_info;e.subscription_ajax_token&&df("subscription_ajax",e.subscription_ajax_token);var g=E("html5-subscribe-button-container",c);g.innerHTML=d.subscription_button_html?d.subscription_button_html:
-"";d=Tt.getInstance();(d=E($(d),g))&&fu(this.i,d);E("html5-view-count",c).innerHTML=e.view_count_string;var h=parseInt(e.likes_count_unformatted,10),g=parseInt(e.dislikes_count_unformatted,10),d=new $t,k=0,m=0;0<h+g&&(k=100*h/(h+g),m=100*g/(h+g));d.b.style.width=k+"%";d.a.style.width=m+"%";h=mf("YTP_SENTIMENT_LIKE",h);g=mf("YTP_SENTIMENT_DISLIKE",g);nn(d.template,"sentiment",h+", "+g);d.V(E("html5-video-info",c),2);d=E("html5-description-text",c);ad(d,e.description);this.j.hide();c=E("html5-info-panel-content",
-c);Rn(c)}};
-f.St=function(a,b){if(!this.ha()){var c=E("share-bar"),d=new cu;Mc(d.a,{value:b.url_short});d.V(c);Om(this.a,"show-share")&&(d.a.focus(),d.a.select());for(var d=b.links,e=0;e<Math.min(3,d.length);e++){var g=new bu(this.i,d[e].name,d[e].sname,d[e].img);g.V(c);this.gb.listen(g,"click",oa(ns,d[e].url,{}))}d=new au(this.i);this.gb.listen(d,"click",v(this.Mi,this,b.more));d.V(c);d=new En(this.i,"yt-uix-button-icon-share-bar-close",this.i.getMsg("YTP_BUTTON_CLOSE"),this.i.getMsg("YTP_BUTTON_CLOSE"));d.V(c);
-this.gb.listen(d,"click",this.di)}};f.Rt=function(){};f.Wn=function(){var a=this.g,b=this.ka,c="",c=b.va?a.jb+"channel/UC"+b.va:a.jb+"user/"+b.author;this.Mi(c)};f.Mi=function(a){ms(a)};f.F=function(){this.gb.removeAll();this.ka=this.k=this.g=this.a=null;du.C.F.call(this)};function gu(){Z.call(this,["div","ytp-playlist-tray-index-length",["span","ytp-playlist-tray-index","{{index}}"],["span",""," / "],["span","ytp-playlist-tray-length","{{length}}"]])}y(gu,Z);gu.prototype.Mg=function(a){nn(this.template,"index",a+1)};function hu(a){Et.call(this,a,"ytp-button-expand",a.getMsg("YTP_BUTTON_EXPAND"),"ytp-button-collapse",a.getMsg("YTP_BUTTON_COLLAPSE"));this.Aa([["div","ytp-button-playlist-icon"],["div","ytp-button-playlist-text",a.getMsg("YTP_BUTTON_PLAYLIST")]])}y(hu,Et);function iu(a){Z.call(this,["div","ytp-playlist-tray-controller"]);this.b=new hu(a);this.b.V(this.template.N());L(this,this.b);this.a=new gu;this.a.V(this.template.N());L(this,this.a)}y(iu,Z);function ju(a,b,c,d){a=["div","ytp-playlist-tray-action-info",["div","ytp-playlist-tray-playlist-title",b],["div","ytp-playlist-tray-author-name",a.getMsg("YTP_AUTHOR_ATTRIBUTION",{author:c})],["div","ytp-playlist-tray-description-text",d]];Z.call(this,a)}y(ju,Z);function ku(a){var b=["div","ytp-playlist-tray-action-share",["div","ytp-playlist-tray-action-share-heading",a.getMsg("YTP_SHARE_PLAYLIST")],["div","share-bar-services"]];Z.call(this,b);this.i=a;this.g=new Uo(this);this.b=this.a=null}y(ku,Z);ku.prototype.F=function(){this.g.removeAll();this.g=null;ku.C.F.call(this)};function lu(a,b){Z.call(this,["div","ytp-playlist-tray-item",["span","ytp-playlist-tray-item-index","{{index}}"],["span","ytp-playlist-tray-item-now-playing","\u25b6"],["img","ytp-playlist-tray-item-thumbnail",{src:"{{image}}"}],["span","ytp-playlist-tray-item-title","{{title}}"],["span","ytp-playlist-tray-item-author","{{author}}"]]);this.a=b;this.template.update({index:b+1,title:a.title,author:a.author,image:$n(a.L)})}y(lu,Z);
-lu.prototype.Mg=function(a){X(this.element,"ytp-playlist-tray-item-current",this.a==a)};function mu(){Z.call(this,["div","ytp-playlist-tray-tray"]);this.a=null;this.i=new Uo(this);this.b=[]}y(mu,Z);function nu(a,b){b!=a.a&&(a.a&&a.a.$("shuffle",a.g,a),a.a=b,a.a.D("shuffle",a.g,a),a.g())}mu.prototype.g=function(){this.i.removeAll();this.b=[];Xc(this.element);for(var a=0;a<=this.a.Mb-1;++a){var b=new lu(vh(this.a,a),a);b.Mg(this.a.ua);this.b.push(b);this.i.listen(b,"click",oa(this.j,a));b.V(this.element)}};
-mu.prototype.j=function(a){a={index:a};var b=document.createEvent("CustomEvent");b.initCustomEvent("playvideoat",!0,!0,a||null);this.dispatchEvent(b)};mu.prototype.F=function(){this.i.removeAll();mu.C.F.call(this)};function ou(a){Tm.call(this,a);var b=Q(a);this.j=new Uo(this);this.k=a.app.S.B;this.i=new hn(["div",["ytp-playlist-tray-container","html5-stop-propagation"],["div",["ytp-playlist-tray-info","show-more-info"]]]);L(this,this.i);this.a.app.S.g.appendChild(this.i.N());this.g=new mu;this.j.listen(this.g,"playvideoat",v(function(b){a.um(b.detail.index)},a));L(this,this.g);this.g.V(this.i.N(),0);this.G=E("html5-playlist-button",b);J(this.G,"click",v(this.Km,this));this.B=this.A=null;this.I=!1;this.b=new iu(this.k);
-this.b.V(E("html5-title",void 0),0);this.j.listen(this.b.b,"click",this.Km);this.D("fullscreentoggled",this.Bq,this);this.D("videodatachange",this.Cq,this);this.D("onResize",this.vm,this);this.D("clearvideooverlays",this.unload,this)}y(ou,Tm);f=ou.prototype;f.qa="playlist";f.create=function(){var a=this.a.vb();nu(this.g,a);for(var b=this.g,c=0;c<b.b.length;c++)b.b[c].Mg(b.a.ua);a.D("shuffle",this.su,this);ou.C.create.call(this)};
-f.su=function(){this.b.a.Mg(this.a.ak());var a=Km(this.a.vb());nn(this.b.a.template,"length",a)};f.destroy=function(){this.a.vb()||(nu(this.g,null),ou.C.destroy.call(this))};f.load=function(){this.ba=!0;ou.C.load.call(this);Gt(this.b.b)};f.unload=function(){this.ba=!1;ou.C.unload.call(this);Ht(this.b.b)};
-f.Km=function(){if(this.ba)this.unload();else if(this.u("command_clear_video_overlays"),this.load(),this.vm(),!this.A){var a=E("ytp-playlist-tray-info"),b=new It(this.k);b.V(a,0);this.j.listen(b.g,"click",this.hu);this.j.listen(b.i,"click",this.iu);b=this.a.vb();this.A=new ju(this.k,b.title,b.author,b.description);this.A.V(a)}};f.hu=function(){var a=E("ytp-playlist-tray-info");Ac(a,"show-more-info");Bc(a,"show-share")};
-f.iu=function(){var a=E("ytp-playlist-tray-info");Bc(a,"show-more-info");Ac(a,"show-share");this.I||(this.B=new ku(this.k),this.B.V(a),this.I=!0,Qj("/share_ajax",{Z:this,method:"GET",onError:this.ev,Qa:this.fv,yf:{action_get_share_info:1,feature:"player_embedded",video_id:this.a.getVideoData().L,list:this.a.vb().g}}))};f.hide=function(){var a=E("ytp-playlist-tray-info");Bc(a,"show-more-info");Bc(a,"show-share")};
-f.fv=function(a,b){var c=this.B;c.g.removeAll();var d=b.links,e=c.template.a["share-bar-services"];Xc(e);for(var g=0;g<Math.min(3,d.length);g++){var h=new bu(c.i,d[g].name,d[g].sname,d[g].img);h.V(e);c.g.listen(h,"click",oa(ns,d[g].url))}c.a&&F(c.a.element);c.a=new au(c.i);c.g.listen(c.a,"click",oa(ms,b.more));c.a.V(c.element);c.b&&F(c.b.element);c.b=new cu;Mc(c.b.a,{value:b.url_short});c.b.V(c.element)};f.ev=function(){};f.Bq=function(a){var b=this.a.J().Y;this.ba&&!a&&"detailpage"==b&&this.unload()};
-f.Cq=function(){this.b.a.Mg(this.a.ak());var a=Km(this.a.vb());nn(this.b.a.template,"length",a)};f.vm=function(){var a=Bd(this.i.N());X(this.i.N(),"show-tray-panel",560<a.width)};f.Xa=function(a){return!!a.vb()};function pu(a){return a.vb()?new ou(a):null}f.F=function(){zf(this.G);this.G=null;ou.C.F.call(this)};var qu=RegExp("^(ar|dv|he|iw|fa|nqo|ps|sd|ug|ur|yi|.*[-_](Arab|Hebr|Thaa|Nkoo|Tfng))(?!.*[-_](Latn|Cyrl)($|-|_))($|-|_)","i");function ru(a,b){Qm(a,["html5-async-progress","html5-async-success","html5-async-error"]);b&&V(a,b);Nt(Kt.getInstance(),a)};function su(a,b,c,d){if(this.g=!!c)this.il=Math.max(800,this.il);this.element=a;this.G=b;this.k=d;tu?a.ontouchstart=v(this.cw,this):a.onmousedown=v(this.bw,this);a.onclick=v(this.Rn,this)}var tu="ontouchstart"in document,uu=[],vu=!1;function wu(){tu&&!vu&&(vu=!0,document.addEventListener("click",function(a){for(var b=new A(a.clientX,a.clientY),c=0,d;d=uu[c];c++)if(25>wb(d,b)){a.stopPropagation();a.preventDefault();uu.splice(c,1);break}},!0))}
-function xu(a){uu.push(a);window.setTimeout(function(){var b=uu.indexOf(a);-1!=b&&uu.splice(b,1)},2500)}f=su.prototype;f.il=1E3;
-f.cw=function(a){if(!(1<a.touches.length||a._stop)){this.a=a._stop=!0;this.g||(this.element.ontouchend=v(this.Rn,this),document.body.addEventListener("touchend",yu(this),!1));document.body.addEventListener("touchmove",zu(this),!1);document.body.addEventListener("touchcancel",yu(this),!1);Au(this,a);this.H=window.setTimeout(v(this.ri,this,!0),100);var b=a.touches[0];this.b=new A(b.clientX,b.clientY);this.g||this.k&&!this.k(a)||xu(this.b)}};
-f.bw=function(a){a.stopPropagation();this.a=!0;Au(this,a);this.ri(!0)};f.Rn=function(a){"touchend"==a.type&&!this.a||a._stop||(a._stop=!0,this.ri(!0),window.setTimeout(v(function(){this.Ii();this.G(a)},this),0))};f.Vw=function(a){1<a.touches.length?this.Ii():(a=a.touches[0],a=new A(a.clientX,a.clientY),this.b&&12<wb(this.b,a)&&this.Ii())};function zu(a){a.i||(a.i=v(a.Vw,a));return a.i}
-f.Ii=function(){window.clearTimeout(this.H);window.clearTimeout(this.A);this.ri(!1);this.a=!1;document.body.removeEventListener("touchmove",zu(this),!1);document.body.removeEventListener("touchend",yu(this),!1);document.body.removeEventListener("touchcancel",yu(this),!1)};function yu(a){a.j||(a.j=v(a.Ii,a));return a.j}f.ri=function(a){this.B&&Ec(this.element,this.B,a)};function Au(a,b){a.o&&(a.A=window.setTimeout(v(function(){this.a=!1;this.o(b)},a),a.il))};function Bu(a){En.call(this,a);Hn(this,15);Cu(this)}y(Bu,En);function Cu(a){Gn(a,"ytp-button-fullscreen-enter");var b=a.g.getMsg("YTP_BUTTON_FULLSCREEN_ENTER");a.Jb(b);a.a=b};function Du(){Z.call(this,["div",["ytp-menu","html5-stop-propagation"],"{{content}}"]);this.a=[];this.stopPropagation("click")}y(Du,Z);Du.prototype.add=function(a){for(var b=this.a.length,c=0;c<this.a.length;c++){if(this.a[c]==a)return;if(c<b&&this.a[c].priority<a.priority){b=c;break}}bb(this.a,b,0,a);Eu(this)};Du.prototype.remove=function(a){Wa(this.a,a);Eu(this)};
-function Eu(a){var b;if(1==a.a.length)b=new Z(["div","ytp-menu-content",["div","ytp-menu-row",["div","ytp-menu-cell",a.a[0].label]],["div","ytp-menu-row",["div","ytp-menu-cell","{{content}}"]]]),b.Aa(a.a[0].element);else{b=new Z(["div","ytp-menu-content"]);for(var c=0;c<a.a.length;c++){var d=new Z(["div","ytp-menu-row",["div",["ytp-menu-cell","ytp-menu-title"],a.a[c].label],["div","ytp-menu-cell","{{content}}"]]);d.Aa(a.a[c].element);d.V(b.N())}}a.Aa(b)}Du.prototype.F=function(){this.a=null;Du.C.F.call(this)};function Fu(a){En.call(this,a);Hn(this,3);Gu(this)}y(Fu,En);function Gu(a){Gn(a,"ytp-button-play");var b=a.g.getMsg("YTP_BUTTON_PLAY");a.Jb(b);a.a=b};function Hu(a){Z.call(this,["div","ytp-playlist-controls","{{content}}"]);this.b=new En(a,"ytp-button-prev",a.getMsg("YTP_BUTTON_PREV"),a.getMsg("YTP_BUTTON_PREV"));L(this,this.b);this.a=new En(a,"ytp-button-next",a.getMsg("YTP_BUTTON_NEXT"),a.getMsg("YTP_BUTTON_NEXT"));L(this,this.a);this.Aa([this.b,this.a])}y(Hu,Z);function Iu(a,b,c,d){var e=Math.min(c/(b.bo/b.yi),d/(b.ao/b.rows)),g=b.bo*e,e=b.ao*e,g=Math.floor(g/b.yi)*b.yi,e=Math.floor(e/b.rows)*b.rows,h=g/b.yi,k=e/b.rows,m=Math.floor((c-h)/2);c=Math.ceil((c-h)/2);d=Math.floor((d-k)/2);kd(a,{width:h+"px",height:k+"px","margin-top":d+"px","margin-bottom":d+"px","margin-left":m+"px","margin-right":c+"px","background-image":"url("+b.url+")","background-position":-1*b.qu*h+"px "+-1*b.row*k+"px","background-size":g+"px "+e+"px"})};function Ju(){this.a=new js(this.Lv,250,this);L(this,this.a)}y(Ju,K);f=Ju.prototype;f.Fo=!1;f.yd=null;f.ac=null;f.Yh=null;f.dk=null;f.ek=null;f.Ag=null;f.Je=0;f.Ik=0;f.gl=0;f.Qo=10;f.Ob=0;f.Ki=0;f.nl=0;f.Zc=null;f.Qe=null;f.Te=0;f.disable=function(){this.Fo=!0};f.Va=function(a){this.Te=a};f.Bo=function(a,b){this.ac.style.display="none";for(var c,d,e=a;e<=b;e++)if(d=this.ac.children[e])c=Al(this.Qe,e,this.Ob),Iu(d,c,this.Ob,this.Ki);this.ac.style.display=""};
-function Ku(a,b){if(b!=a.nl){var c=Al(a.Qe,b,2*a.Ob),d=Math.round(2*a.Ob),e=Math.round(2*a.Ki);Iu(a.dk,c,d,e);a.nl=b}}f.Lv=function(){for(var a=this.Ik,b=Math.max(Math.floor(a/this.Ob),0),a=Math.min(Math.ceil((a+this.Je)/this.Ob),this.Zc.a[0].b-1);b<=a;b++){for(var c=this.Qe,d=b,e=bl(c.a,2*this.Ob),g=void 0,h=void 0;0<=e;e--)if(g=c.a.a[e],h=Math.floor(d/(g.a*g.g)),!g.i[h]){var g=c,k=e,m=k+"-"+h;g.i[m]||(g.i[m]=!0,xl(g.g,k,{xn:k,yn:h}))}Bl(c)}};
-function Lu(a,b){a.Qo=Math.min(10,Math.ceil(a.Je/72));a.Ob=Math.floor(a.Je/a.Qo);a.Ki=0.555*a.Ob;a.gl=a.Ob*a.Zc.a[0].b;Ad(a.ac,a.gl);var c=Math.round(2*a.Ob),d=0.555*c+12;zd(a.Yh,c,d);od(a.Yh,(a.Je-c)/2);a.yd.style.height=pd(d+20,!0);b&&(a.Bo(0,a.Zc.a[0].b-1),Ku(a,a.nl))}f.F=function(){this.Ag=this.ek=this.dk=this.Yh=this.ac=this.yd=this.Qe=this.Zc=null;Ju.C.F.call(this)};function Mu(a,b,c,d){this.width=b;this.a=c;this.i=d;this.b=b-c-d;this.g=vb(a-c,0,this.b);this.position=this.g+c;this.xd=this.g/this.b};function Nu(){Z.call(this,["div",["ytp-progress-magnifier","html5-draggable"],["div","ytp-progress-magnifier-play-progress"],["div","ytp-progress-magnifier-load-progress"],["div","ytp-progress-magnifier-scrubber-button"]]);this.i=this.template.a["ytp-progress-magnifier-load-progress"];this.o=0;this.j=this.template.a["ytp-progress-magnifier-play-progress"];this.B=0;this.b=[];this.g=this.template.a["ytp-progress-magnifier-scrubber-button"]}y(Nu,Z);
-function Ou(a,b){var c=a.a,d=c.width-4,e=d-2*a.Te;if(ga(b))var d=Pu(a).position,g=a.N().offsetWidth/2,d=vb(b,d-g,d+g);else d=2+c.xd*d;return new Mu(d,c.width,2+c.xd*e,2+(1-c.xd)*e)}function Pu(a){var b=a.a;a=a.N().offsetWidth/2+2;return new Mu(b.position,b.width,a,a)}Nu.prototype.disable=function(){this.a=null};
-function Qu(a,b){if(a.a){var c=a.N(),d=Pu(a),e=Ou(a),g=c.offsetWidth/2,h=d.position-g,d=d.position+g;c.style.left=h+"px";var k=a.o*e.b+e.a,m=a.B*e.b+e.a,p=a.g.offsetWidth,s=m-h-p/2;s>-p&&s<2*g+p?(a.g.style.left=s+"px",on(a.g)):pn(a.g);m-=h;0<=m?(Ad(a.j,Math.min(m,2*g)),on(a.j)):pn(a.j);k-=h;0<=k?(Ad(a.i,Math.min(k,2*g)),on(a.i)):pn(a.i);if(b){g=(h-e.a)/2/60;e=(d-e.a)/2/60;h=0;for(d=Math.ceil(g);d<=e;d++)h<a.b.length?k=a.b[h]:(k=document.createElement("div"),a.b[h]=k,c.appendChild(k)),k.className=
-0==d%60?"ytp-progress-magnifier-60m":0==d%30?"ytp-progress-magnifier-30m":0==d%15?"ytp-progress-magnifier-15m":"ytp-progress-magnifier-1m",k.style.left=120*(d-g)+"px",h++;for(;h<a.b.length;)F(a.b.pop())}}}Nu.prototype.Va=function(a){this.Te=a;Qu(this,!0)};Nu.prototype.F=function(){this.g=this.b=this.j=this.i=null;Nu.C.F.call(this)};function Ru(){}y(Ru,K);f=Ru.prototype;f.ki=!1;f.Te=0;f.Hb=null;f.Lh=null;f.fk=null;f.wj=null;f.Jg=null;f.ih=null;f.disable=function(){this.ki=!0};f.show=function(){this.ki||Rn(this.Hb)};f.hide=function(){Sn(this.Hb)};f.Va=function(a){this.Te=a};f.reset=function(){W(this.Hb,"with-thumbnail");this.ih=this.Jg=null};f.Uu=function(a,b){(a<=this.a||this.a<=b)&&Su(this)};function Su(a){var b=Al(a.ih,a.a,108);Iu(a.fk,b,108,60)}f.F=function(){this.wj=this.fk=this.Lh=this.Hb=this.ih=this.Jg=null;Ru.C.F.call(this)};function Tu(a){R.call(this);this.bb=a;this.va=null;this.K={};this.aa=Infinity;this.X=this.U=this.M=null;this.ia=0;this.o=this.g=this.G=null;this.k=new Uo(this);this.Sa="";this.Na=null;this.ja=0;this.ib=null;this.ya=0;this.a=this.b=this.Ta=this.i=this.Q=this.ga=null;this.za=new Uo(this);this.pa=null;this.Ka=new Uo(this);this.A=this.I=!1;this.O=this.P=this.fa=null;this.j=this.Ma=this.ma=this.B=0}y(Tu,R);
-function Uu(a,b){a.g=b;a.i=E("html5-progress-bar",a.g);a.k.listen(a.i,"click",a.Th);Vo(a.k,a.i,"down",a.Bv);a.Sa=Vo(a.k,a.i,"over",a.qn);a.Q=E("html5-progress-list",a.i);a.ib=E("html5-play-progress",a.Q);a.Na=E("html5-load-progress",a.Q);a.ga=E("html5-highlight",a.Q);a.va=E("html5-ad-progress-list",a.i);a.pa=E("html5-scrubber-button",a.i);a.U=E("html5-clip-exclusion",a.i);a.X=a.U.cloneNode(!1);a.U.parentNode.appendChild(a.X);a.G=E("html5-clip-start",a.i);Vo(a.k,a.G,"over",a.fp);Vo(a.k,a.G,"out",a.ep);
-a.k.listen(a.G,"click",a.tl);a.M=E("html5-clip-end",a.i);Vo(a.k,a.M,"over",a.fp);Vo(a.k,a.M,"out",a.ep);a.k.listen(a.M,"click",a.tl);a.Ta=E("html5-progress-screenreader",a.i)}f=Tu.prototype;
-f.qn=function(a){if(!this.I){this.k.dc(this.Sa);this.A=!1;this.P=this.fa=a=new A(a.pageX,a.pageY);if(this.a&&5400<=this.B){I(this.ma);this.a.show();Rn(this.ga);a=this.a;var b=Vu(this);a.a=b;Qu(a,!0);a=oa(V,this.g,"html5-progress-magnifier-hover");this.ma=H(a,0)}this.b&&this.b.show();Vo(this.za,this.g,"move",this.wn);Vo(this.za,this.g,"out",this.Ut)}};function Wu(a){a.A=!1;I(a.ma);W(a.g,"html5-progress-magnifier-hover");var b=Er(a.a.N());a.ma=H(v(function(){this.a.hide();Sn(this.ga)},a),b)}
-f.Ut=function(a){this.I||a.relatedTarget&&!(this.b&&$c(this.b.Hb,a.relatedTarget)||!$c(this.g,a.relatedTarget))||Xu(this)};
-f.wn=function(a){var b=new A(a.pageX,a.pageY);if(this.a&&this.a.a)if(this.I)this.A?this.O=b:this.P=b;else{var c=Dd(this.a.N());if(c.contains(b))this.O=b,this.A=!0;else{var d=Dd(this.Q),e=this.fa.y-a.pageY;if(a.pageX>=c.left&&a.pageY>=c.top&&a.pageX<c.left+c.width||d.contains(b)){c=6*e-6;if(a.pageX>=this.fa.x-c&&a.pageX<=this.fa.x+c)return;this.A=!1;this.fa=this.P=b}else{Xu(this);return}}}else this.P=b;Yu(this)};
-function Yu(a){if(a.a&&a.a.a){var b=Dd(a.a.N());if(a.I&&a.A){var c=b.left,b=c+b.width;a.j=c>a.O.x?a.O.x-c:b<a.O.x?a.O.x-b:0}c=a.a;b=Vu(a);c.a=b;Qu(c,!0);var d=a.a,c=Ou(d),b=Pu(d),d=d.N().offsetWidth,e=b.position-d/2,c=new Mu(c.position,d,c.a-e,c.i-(b.width-e-d)),b=Math.max(c.width/c.b,0.015);a.ga.style.left=Math.round(1E3*((c.width/2-c.a)/c.b-b/2))/10+"%";a.ga.style.width=Math.round(1E3*b)/10+"%"}a.b&&(c=a.b,a=Zu(a),c.ki||(b=c.Hb.offsetWidth/2,d=new Mu(a.position,a.width,b,b),c.Hb.style.left=d.position-
-b+"px",b=c.Lh.offsetWidth/2,d=new Mu(a.position,a.width,b,b),c.Lh.style.left=d.position-c.Hb.offsetLeft-b+"px",ad(c.wj,Nn(a.xd*c.Te)),c.Jg&&(a=al(c.Jg,a.xd),a!=c.a&&(c.a=a,Su(c)))))}f.Ww=function(){var a;if(0>this.j)a=0.15*this.j-0.1,this.j-=a,0<this.j&&(this.j=0);else if(0<this.j)a=0.15*this.j+0.1,this.j-=a,0>this.j&&(this.j=0);else return;var b=td(this.g).x;this.P.x=vb(this.P.x+a,b,b+Vu(this).width);Yu(this);a=Zu(this);$u(this,a.xd,this.ja);this.u("seekto",a.xd*this.B,!1)};
-function Xu(a){a.za.removeAll();a.b&&a.b.hide();a.a&&a.a.a&&(a.a.disable(),Wu(a));a.Sa=Vo(a.k,a.i,"over",a.qn)}f.Bv=function(a){a.stopPropagation();a.preventDefault();this.b&&this.b.hide();this.a&&this.a.a&&Wu(this);av(this);this.Th(a)};f.Gs=function(a){a.stopPropagation();a.preventDefault();this.A=!0;av(this);this.Th(a)};function av(a){a.I=!0;a.u("beginseeking");Vo(a.Ka,document,"move",a.Th);Vo(a.Ka,document,"up",a.Xw);a.A&&(a.Ma=gf(v(a.Ww,a),20))}
-f.Xw=function(a){a.stopPropagation();this.I=!1;this.Ka.removeAll();hf(this.Ma);Xu(this);this.u("endseeking")};f.Th=function(a){a.stopPropagation();a.preventDefault();this.wn(a);a=this.A?Zu(this):Vu(this);var b=a.xd*this.B;$u(this,a.xd,this.ja);(b<this.ia||b>this.aa)&&this.tl();this.u("seekto",b,!this.I)};function Zu(a){return a.a&&a.a.a?a.A?Ou(a.a,a.O.x-td(a.g).x):Ou(a.a):Vu(a)}function Vu(a){return new Mu(a.P.x-td(a.g).x,a.Q.clientWidth,a.pa.clientWidth/2,a.pa.clientWidth/2)}
-function bv(a,b,c){$u(a,q(b)&&!a.I?b:a.ya,q(c)?c:a.ja)}function $u(a,b,c){a.ya=b;var d=Math.round(1E3*b)/10;kd(a.ib,"transform","scalex("+b+")");a.pa.style.left=d+"%";a.ja=Math.max(a.ya,c);kd(a.Na,"transform","scalex("+a.ja+")");a.a&&(a=a.a,a.B=b,a.o=c,Qu(a,!1))}f.Va=function(a){this.B=a;cv(this);this.a&&this.a.Va(a)};
-function cv(a){var b=0<a.ia,c=0<a.B&&a.aa<a.B;X(a.G,"html5-clip-enabled",b);X(a.U,"html5-clip-enabled",b);X(a.M,"html5-clip-enabled",c);X(a.X,"html5-clip-enabled",c);b&&(a.G.style.left=100*a.ia/a.B+"%",a.U.style.width=a.G.style.left);c&&(b=Math.min(100,100*a.aa/a.B),a.M.style.left=b+"%",a.X.style.left=b+"%",a.X.style.width=100-b+"%")}f.fp=function(){V(this.g,"html5-clip-marker-hover")};f.ep=function(){W(this.g,"html5-clip-marker-hover")};
-f.tl=function(a){a&&a.stopPropagation();this.ia=0;cv(this);this.aa=Infinity;cv(this)};function dv(a,b){b=vb(Math.round(100*b),0,100);if(!a.K[b]){var c=document.createElement("div");c.style.left=b+"%";Pm(c,["html5-ad-progress","html5-progress-section"]);a.va.appendChild(c);a.K[b]=c}}function ev(a,b){b=vb(Math.round(100*b),0,100);a.K[b]&&(F(a.K[b]),a.K[b]=null)}
-f.F=function(){I(this.ma);hf(this.Ma);this.k.removeAll();this.za.removeAll();this.Ka.removeAll();this.va=null;this.K={};this.pa=this.Ta=this.Q=this.i=this.ib=this.Na=this.g=this.G=this.X=this.U=this.M=null;Tu.C.F.call(this)};function fv(a,b,c){Z.call(this,["div","ytp-drop-down","{{content}}"]);this.o=a;this.g=!1;this.j=0;this.a=new Z(["div","ytp-drop-down-menu","{{content}}"]);L(this,this.a);this.b=new En(this.o,"ytp-drop-down-label");L(this,this.b);this.listen(this.b,"click",this.B);this.i=new Z(["div","ytp-drop-down-label-content","{{content}}"]);L(this,this.i);this.b.Aa([this.i,["div","ytp-drop-down-arrow"]]);this.Aa([this.a,this.b]);this.stopPropagation("click");q(b)&&this.Jb(b);q(c)&&(this.a.Aa(c),gv(this));gv(this)}
-y(fv,Z);fv.prototype.Jb=function(a){this.i.Aa(a);gv(this)};fv.prototype.k=function(){this.g=!1;gv(this)};fv.prototype.B=function(){this.g=!this.g;gv(this)};function hv(a,b){b>a.j&&(a.j=b,a.element.style.minWidth=a.j+"px")}function gv(a){a.g?(a.a.show(),a.listen(window,"blur",a.k,a,"menu"),a.listen(document,"click",a.k,a,"menu")):(a.a.hide(),a.dc(a.A.menu),a.A.menu=[]);var b=Bd(a.b.N());a.a.N().style.bottom=b.height-1+"px";hv(a,b.width)}fv.prototype.F=function(){this.o=null;fv.C.F.call(this)};function iv(a){En.call(this,a,"ytp-drop-down-menu-button");this.i=new Z(["div","ytp-drop-down-menu-button-check"]);L(this,this.i)}y(iv,En);iv.prototype.Aa=function(a){iv.C.Aa.call(this,[this.i,a])};iv.prototype.Ya=function(a){X(this.element,"ytp-drop-down-menu-button-selected",a)};function jv(a){Z.call(this,["span"]);this.element.innerHTML=a}y(jv,Z);function kv(a){ys.call(this);this.g=a;this.b={};this.j=new Z(["div","ytp-menu-drop-down-content"]);L(this,this.j);this.a="auto";this.i=!0;this.label=this.g.getMsg("YTP_QUALITY_TITLE");this.element=new fv(a,void 0,this.j);L(this,this.element);hv(this.element,100);lv(this,this.a,this.a);this.priority=-1}y(kv,ys);function mv(a,b){nv(a);z(b,function(a){var b=new iv(this.g);b.Aa(new jv(ov(this,a)));b.V(this.j.N());this.b[a]=b;J(b,"click",v(this.k,this,a))},a);a.b[a.a]&&a.b[a.a].Ya(!0)}
-kv.prototype.We=function(){return this.a};function lv(a,b,c){a.a&&a.b[a.a]&&a.b[a.a].Ya(!1);a.a=b;a.b[a.a]&&a.b[a.a].Ya(!0);a.i="auto"==c;a.i&&c!=b?a.element.Jb(pv(a,b)):a.element.Jb(new jv(ov(a,c)))}function ov(a,b){return a.g.getMsg("YTP_QUALITY_"+b.toUpperCase())}function pv(a,b){var c=a.g.getMsg("YTP_QUALITY_AUTO_WITH_QUALITY",{video_quality:ov(a,b)});return new jv(c)}function nv(a){Eb(a.b,function(a){Sg(a)});a.b={}}
-kv.prototype.k=function(a){this.element.k();this.i&&"auto"==a||(lv(this,a,a),Af(this.element,"change"))};kv.prototype.F=function(){nv(this);this.g=null;kv.C.F.call(this)};function qv(a){Et.call(this,a,"ytp-settings-button",a.getMsg("YTP_TOOLTIP_SETTINGS"),"ytp-settings-button-active");Hn(this,10);this.i=new Z(["div","ytp-settings-hd-quality-badge"]);L(this,this.i);this.Aa(this.i);this.i.hide()}y(qv,Et);function rv(a){ys.call(this);this.label=a.getMsg("YTP_PLAYER_SIZE_TITLE");this.element=new zs(a,["ytp-size-control-small","ytp-size-control-large"],!0);L(this,this.element);this.priority=0}y(rv,ys);rv.prototype.getSelected=function(){return this.element.getSelected()};rv.prototype.Ya=function(a){this.element.Ya(a)};function sv(a){ys.call(this);this.g=a;this.a={};this.b=1;this.i=new Z(["div","ytp-menu-drop-down-content"]);L(this,this.i);this.label=this.g.getMsg("YTP_PLAYER_SPEED_TITLE");this.element=new fv(a,void 0,this.i);L(this,this.element);hv(this.element,100);this.priority=1}y(sv,ys);function tv(a,b){uv(a);z(b,function(a){var b=new iv(this.g);b.Aa(vv(this,a));b.V(this.i.N());this.a[a]=b;J(b,"click",v(this.j,this,a))},a);a.a[a.b]&&a.a[a.b].Ya(!0)}
-function wv(a,b){a.b&&a.a[a.b]&&a.a[a.b].Ya(!1);a.b=b;a.a[a.b]&&a.a[a.b].Ya(!0);a.element.Jb(vv(a,b))}function vv(a,b){return 1==b?a.g.getMsg("YTP_PLAYER_SPEED_NORMAL"):b.toString()}function uv(a){Eb(a.a,function(a){Sg(a)});a.a={}}sv.prototype.j=function(a){this.element.k();wv(this,a);Af(this.element,"change")};sv.prototype.F=function(){uv(this);this.g=null;sv.C.F.call(this)};function xv(){Z.call(this,["div",["ytp-time-display","html5-control"],["span","ytp-time-current","{{current}}"],["span","ytp-time-separator"," / "],["span","ytp-time-duration","{{duration}}"],["span","ytp-time-live-badge","Live"]]);this.a=this.template.a["ytp-time-live-badge"]}y(xv,Z);xv.prototype.Va=function(a){nn(this.template,"duration",Nn(a))};xv.prototype.F=function(){this.a=null;xv.C.F.call(this)};function yv(a){R.call(this);this.b=a;this.a=new Uo(this);this.A=new Uo(this);this.k=this.j=null;this.o=new Uo(this)}y(yv,R);f=yv.prototype;f.qf=null;f.Ec=null;f.Ne=null;f.ok=null;f.ae=null;f.yc=null;f.vf=null;f.cc=null;f.Cg=null;f.Yd=null;f.Ee=null;f.Xh=null;f.wd=null;f.Sc=null;f.wb=null;f.wf=null;f.Ie=null;f.Pl=!1;f.zc=null;f.Fd=null;f.Gd=null;f.Xn=!1;f.xg=null;f.xb=null;
-function zv(a,b){a.qf=b;var c=E("html5-player-chrome",b);a.Ec=new Fu(a.b);a.Ec.V(c,0);L(a,a.Ec);new su(a.Ec.N(),v(a.Mt,a),!1,function(){return!0});a.Ne=new Hu(a.b);a.Ne.V(c,1);L(a,a.Ne);a.a.listen(a.Ne.a,"click",oa(a.u,"nextvideo"));a.a.listen(a.Ne.b,"click",oa(a.u,"previousvideo"));var d=E("html5-progress-bar-container",b);a.ok=new Tu(a.b);Uu(a.ok,d);a.g=new xv;a.g.V(c,4);L(a,a.g);a.a.listen(a.g.a,"click",oa(a.u,"seekto",Infinity));a.ae=E("html5-volume-control",b);a.a.listen(a.ae,"keydown",a.Nt);
-a.yc=E("html5-volume-button",a.ae);a.a.listen(a.yc,"click",a.Bn);a.vf=E("html5-volume-panel",a.ae);a.cc=E("html5-volume-slider",a.ae);Vo(a.a,a.cc,"down",a.Jt);a.Cg=E("html5-volume-slider-foreground",a.ae);a.Xh=E("html5-threed-popup-menu",b);a.Ee=E("html5-small-player-button",b);a.a.listen(a.Ee,"click",a.An);a.Yd=E("html5-large-player-button",b);a.a.listen(a.Yd,"click",a.An);a.i=new Bu(a.b);a.i.V(c,7);L(a,a.i);a.a.listen(a.i,"click",a.It);a.wd=E("html5-quality-button",b);a.Ie=E("html5-quality-popup-menu",
-a.wd);Wo(a.a,a.Ie,a.Gt);a.wf=E("html5-speed-popup-menu",a.wd);Wo(a.a,a.wf,a.Ht);a.xb=E("html5-watch-later-button",b);a.a.listen(a.xb,"click",a.Kt);a.xb&&fu(a.b,a.xb,a.b.getMsg("YTP_TOOLTIP_WATCH_LATER"),!0);a.xg=E("html5-watch-on-youtube-button",b);a.a.listen(a.xg,"click",a.Lt)}f.disable=function(a){Av(this,a,!0)};f.enable=function(a){Av(this,a,!1)};
-function Av(a,b,c){for(var d=0;d<b.length;d++)switch(b[d]){case "audio":X(a.qf,"disabled-control-audio",c);break;case "play_pause":var e=a.Ec;c?e.disable():e.enable();break;case "seek":X(a.qf,"disabled-control-seek",c)}}
-function Bv(a,b){if(a.zc)mv(a.zc,b),b.length?a.wb.add(a.zc):a.wb.remove(a.zc);else{var c=Kc("yt-uix-button-menu-item",a.Ie);z(c,function(a){a.style.display="none";for(var c=0,g=b.length;c<g;c++)G(a,"value")==b[c]&&(a.style.display="list-item")},a);a.Pl=!!b.length;Pn(a.Ie,a.Pl);Pn(a.wd,a.Pl)}}f.Nt=function(a){var b=a.keyCode;if(32==b||13==b)this.Bn(),a.preventDefault()};f.Va=function(a){this.g.Va(a)};
-function Cv(a,b,c){a.zc?(lv(a.zc,b,c),c=a.Sc,0==b.indexOf("hd")||"highres"==b?c.i.show():c.i.hide()):a.Ie&&(a=a.Ie,Dv(a,"active",b),Dv(a,"selected",c||b))}function Dv(a,b,c){var d=E("yt-uix-button-menu-item."+b,a);d&&W(d,b);a=a.querySelector(".yt-uix-button-menu-item"+('[data-value="'+c+'"]'));V(a,b)}f.Bn=function(){this.u("mutetoggled")};
-function Ev(a,b){if(b){if(a.Xn){var c=a.Ec;Gn(c,"ytp-button-stop");var d=c.g.getMsg("YTP_BUTTON_STOP")}else c=a.Ec,Gn(c,"ytp-button-pause"),d=c.g.getMsg("YTP_BUTTON_PAUSE");c.Jb(d);c.a=d}else Gu(a.Ec)}f.Mt=function(){this.u("playpausetoggled")};f.Jt=function(a){this.u("beginvolume");V(this.yc,"changing");var b=this.cc.clientWidth;a=100*(vd(a,this.cc).x/b);Fv(this,a);Vo(this.A,document,"move",this.Zw);Vo(this.A,document,"up",this.$w)};
-f.Zw=function(a){var b=this.cc.clientWidth,b=100*(vd(a,this.cc).x/b);Fv(this,b);a.preventDefault()};function Fv(a,b){var c={volume:vb(b,0,100),muted:!1};a.u("volumechanged",c)}f.$w=function(){W(this.yc,"changing");this.A.removeAll();this.u("endvolume")};f.An=function(a){this.u("sizechangerequested",a.currentTarget==this.Yd)};f.Gt=function(a){a=G(a.currentTarget,"value");this.u("qualitychanged",a)};f.It=function(){this.u("fullscreentoggled")};
-function Gv(a,b){if(a.Gd)wv(a.Gd,parseFloat(b));else if(a.wf){var c=a.wf;Dv(c,"active",b);Dv(c,"selected",b)}}f.Ht=function(a){a=G(a.currentTarget,"value");this.u("speedchanged",parseFloat(a));Gv(this,a)};f.Kt=function(){Om(this.xb,"html5-async-progress")||(ru(this.xb,"html5-async-progress"),this.u("watchlater"))};f.Lt=function(){this.u("watchonyoutube")};f.Ug=function(){this.o.removeAll();this.j&&(this.j.hide(),this.j=null);this.k&&(Ht(this.k),this.k=null)};
-f.zt=function(a){a.stopPropagation();if(this.Sc.b)this.Ug();else{a=this.wb;var b=this.Sc;this.Ug();this.j=a;this.j.show();b&&(this.k=b,Gt(this.k));this.o.listen(window,"blur",this.Ug);this.o.listen(document,"click",this.Ug)}};f.xt=function(){this.u("qualitychanged",this.zc.We())};f.At=function(){this.u("sizechangerequested",1==this.Fd.getSelected())};f.Bt=function(){this.u("speedchanged",this.Gd.b)};
-f.wt=function(a){var b=a.target,c="unknown",c=b==this.Ec.N()?"playpause":b==this.yc||b==this.vf||b==this.cc||b==this.ae||b==this.Cg?"volume":b==this.g?"time":b==this.wd?"settings":b==this.Sc?"settings-redesign":b==this.xb?"watchlater":b==this.xg?"youtube":b==this.i.N()?"fullscreen":b==this.Ee||b==this.Yd?"size":a.target;this.u("controlclick",c)};
-f.F=function(){this.a.removeAll();this.A.removeAll();this.o.removeAll();this.Ug();this.wb=this.Sc=this.zc=this.xb=this.xg=this.Ie=this.wf=this.wd=this.Xh=this.Ee=this.Yd=this.Cg=this.cc=this.vf=this.yc=this.ae=this.qf=null;yv.C.F.call(this)};var Hv=["left","right","center"],Iv={id:0,priority:0,li:7,mi:50,vy:80,he:95,Ed:15,xk:100,isVisible:!0,textAlign:Hv[2],Oe:0,backgroundColor:"#080808",ii:"#fff",ny:1,Ll:1},Jv={id:99,priority:1,li:0,mi:5,he:7,Ed:2,xk:32,textAlign:Hv[0]},Kv=["CA","MX","US"];function Lv(a){a=a||Iv;w(this,a)}f=Lv.prototype;f.li=7;f.mi=50;f.he=95;f.vy=80;f.Oe=0;f.textAlign="center";f.backgroundColor="#080808";f.ii="#fff";f.ny=1;f.Ll=1;f.Ed=15;f.xk=32;f.isVisible=!0;f.fontFamily='"Arial Unicode Ms", Arial';f.qx="100%";function Mv(a,b){this.id=a;this.ra=new Lv(b);var c="caption-window";0==this.id&&(c="standard-caption-window");this.oa=Rc("div",{id:"caption-window-"+this.id,"class":c});this.Eb=Rc("span",{"class":"captions-text",style:"visibility: hidden"});this.Eb.innerHTML="C";this.la=Rc("span",{"class":"captions-text",tabindex:"4","aria-live":"assertive"});this.aj=Rc("div",{"class":"caption-window-transform"});this.aj.appendChild(this.la);this.oa.appendChild(this.aj)}f=Mv.prototype;f.id=0;f.ra=null;f.gh="";
-f.Ic=null;f.oa=null;f.aj=null;f.la=null;f.Eb=null;f.type=1;f.getType=function(){return this.type};f.Wi=function(){var a;this.Eb.style.fontFamily=this.la.style.fontFamily;this.oa.appendChild(this.Eb);a=this.Eb.offsetHeight;this.oa.removeChild(this.Eb);return a};f.Wf=function(){this.la&&(0!=this.id&&(Ad(this.oa,"100%"),Ad(this.oa,this.la.offsetWidth)),Nv(this),Pn(this.oa,this.ra.isVisible))};
-function Nv(a){od(a.oa,a.ra.mi+"%",a.ra.he+"%");for(var b=0;8>=b;b++)W(a.oa,"anchor-point-"+b);V(a.oa,"anchor-point-"+a.ra.li)}f.Wo=function(a){var b=[];z(a,function(a){a.$i?b[b.length-1]+=a.ge:b.push(a.ge)});this.Xe(b.join("\n"));this.Ic=a};f.Xe=function(a){this.gh=a=Ov(a);this.la.innerHTML=this.gh;this.Ml();this.Wf()};
-f.Ml=function(){this.oa.style.textAlign=this.ra.textAlign;this.la.style.backgroundColor=this.ra.backgroundColor;this.la.style.color=this.ra.ii;this.la.style.opacity=this.ra.Ll;this.la.style.fontFamily=this.ra.fontFamily;this.la.style.fontSize=this.ra.qx;1==this.ra.Oe?this.la.setAttribute("dir","rtl"):this.la.removeAttribute("dir")};f.toString=function(){var a="Caption window ("+this.id+"): "+this.gh,b;for(b in this.ra)a+=b+" "+this.ra[b]+" | ";return a};
-function Ov(a){a=a.split("\n");for(var b=0,c=a.length;b<c;b++)a[b]=a[b]?"&nbsp;"+a[b]+"&nbsp;":"";return a.join("<br>")}f.cj=function(){this.Ic=[];this.Xe("")};function Pv(a,b){Mv.call(this,a,b);this.la.style.display="block";this.la.style.padding="0";this.Rb=[];var c=this.la;W(c,"captions-text");V(c,"caption-painton-text-rows")}y(Pv,Mv);f=Pv.prototype;f.type=0;f.ho="";f.fh=!1;f.Bb=null;f.Rb=null;f.Wi=function(){return this.Rb[0]?this.Rb[0].offsetHeight:0};function Qv(a){return a.Rb.reduce(function(a,c){return Math.max(a,c.offsetWidth)},0)}
-f.Wf=function(){0!=this.id&&(Ad(this.oa,"100%"),Ad(this.oa,this.fh?Qv(this):this.Bb.width));var a=Math.round(this.ra.Ed*this.Wi());kd(this.oa,"max-height",a+"px");Nv(this);Pn(this.oa,this.ra.isVisible)};
-f.Xe=function(a){this.cj();a=Ov(a);this.fh||(this.gh=a);a=a.split("<br>");for(var b=0,c=a.length;b<c;b++)if(a[b]){var d=Rc("div",{"class":"caption-row-holder"}),e=Rc("span",{"class":"caption-row captions-text"});d.appendChild(e);e.innerHTML=a[b];this.fh||(this.la.style.height=this.Bb.height+"px",this.la.style.width=this.Bb.width+"px",d.style.position="absolute",d.style.top=this.Bb.fo[b]+"px",d.style.left=this.Bb.eo[b]+"px");this.la.appendChild(d);this.Rb.push(e)}this.Ml();this.Wf()};
-f.cj=function(){for(var a=0,b=this.Rb.length;a<b;a++){var c=gd(this.Rb[a],"caption-row-holder");F(c)}this.Rb=[]};f.Ml=function(){this.oa.style.textAlign=this.ra.textAlign;for(var a=0,b=this.Rb.length;a<b;a++)this.Rb[a].style.backgroundColor=this.ra.backgroundColor;this.la.style.color=this.ra.ii;this.la.style.opacity=this.ra.Ll;this.la.style.fontFamily=this.ra.fontFamily;1==this.ra.Oe?this.la.setAttribute("dir","rtl"):this.la.removeAttribute("dir")};function Rv(a,b){Mv.call(this,a,b);this.Ic=[];this.pe=[];this.Db=[];this.Xf=new Ei(433);this.Xf.stop();J(this.Xf,"tick",v(this.vx,this))}y(Rv,Mv);f=Rv.prototype;f.type=2;f.sx=32;f.Db=null;f.qe=0;f.pe=null;f.Xf=null;f.Wf=function(){Ad(this.oa,"100%");var a=this.oa.offsetWidth,a=Math.min(Sv(this),a);Ad(this.oa,a+"px");Ad(this.aj,"100%");this.la.style.whiteSpace="nowrap";Nv(this);Pn(this.oa,this.ra.isVisible)};
-f.Wo=function(a){var b=a.length;if(0>=b)this.cj();else{for(var c=0;c<b&&0<=this.Ic.indexOf(a[c]);)c++;this.Ic=this.Ic.concat(a.slice(c));Tv(this)}};f.cj=function(){this.Ic=[];this.Db=[];this.qe=0;this.Db=[];this.pe=[];Uv(this)};
-function Tv(a){if(!Vv(a))if(a.qe>=a.Ic.length)Uv(a);else{var b=a.Db.length-1;0>b&&(a.pe.push(0),a.qe=0,a.Db.push(""),b=0);for(var c=a.Ic.length,d=a.qe;d<c;d++){var e=a.Ic[d];if("\n"==e.ge){a.qe++;a.pe[b]++;break}if(e.$i||0==a.Db[b].length)a.Db[b]+=e.ge,a.qe++,a.pe[b]++;else break}Uv(a);d<c&&!Vv(a)&&(b=a.Wi(),V(a.la,"caption-rollup"),a.oa.style.overflow="hidden",a.la.style.top=-b+"px",a.Xf.start())}}function Vv(a){return a.Xf.Xc||Om(a.la,"caption-rollup")}
-f.vx=function(){this.oa.style.overflow="visible";this.la.style.top=0;this.Xf.stop();W(this.la,"caption-rollup");this.Db.push("");this.pe.push(0);Tv(this)};function Uv(a){if(!Vv(a)){for(;a.Db.length<a.ra.Ed;)a.Db.unshift(""),a.pe.unshift(0);for(;a.Db.length>a.ra.Ed;){a.Db.shift();var b=a.pe.shift();0<b&&(a.qe-=b,a.Ic.splice(0,b))}a.Xe(a.Db.join("\n"))}}
-function Sv(a){a.Eb.style.fontFamily=a.la.style.fontFamily;a.Eb.style.fontSize=a.la.style.fontSize;a.la.appendChild(a.Eb);a.Eb.innerHTML="\u2014";var b=a.Eb.offsetWidth;a.Eb.innerHTML="&nbsp;";b=2*a.Eb.offsetWidth+b*a.sx;a.la.removeChild(a.Eb);return b};function Wv(a){this.a=a.wk;this.i=a.priority;this.Fc=a.Fc||this.Fc}Wv.prototype.a=0;Wv.prototype.i=0;Wv.prototype.Fc=0;Wv.prototype.toString=function(){return this.a+", "+this.Fc};function Xv(a){Wv.call(this,a);this.ge=a.text||this.ge;this.bi=a.windowId||this.bi;this.$i=a.params.append||this.$i;this.Rp=a.params.row||this.Rp;this.Qp=a.params.ux||this.Qp}y(Xv,Wv);f=Xv.prototype;f.ge="";f.$i=!1;f.Rp=0;f.Qp=0;f.bi=0;f.toString=function(){return this.a+", "+this.Fc+": "+this.ge};
-function Yv(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={wk:c,Fc:d,text:b,windowId:e,priority:5,params:{}};a.getAttribute("r")&&(b.params.row=parseInt(a.getAttribute("r"),10));a.getAttribute("c")&&(b.params.ux=parseInt(a.getAttribute("c"),10));
-a.getAttribute("append")&&(b.priority=6,b.params.append=!0);return new Xv(b)}function Zv(a){Wv.call(this,a);this.id=a.windowId||this.id;this.params=a.params}y(Zv,Wv);Zv.prototype.id=0;Zv.prototype.params=null;Zv.prototype.g="";Zv.prototype.b=!1;function $v(){return new Zv({wk:-2147483648,Fc:4294967295,params:Iv})};function aw(a){if("undefined"!=typeof DOMParser)return(new DOMParser).parseFromString(a,"application/xml");if("undefined"!=typeof ActiveXObject){var b=new ActiveXObject("MSXML2.DOMDocument");if(b){b.resolveExternals=!1;b.validateOnParse=!1;try{b.setProperty("ProhibitDTD",!0),b.setProperty("MaxXMLSize",2048),b.setProperty("MaxElementDepth",256)}catch(c){}}b.loadXML(a);return b}throw Error("Your browser does not support loading xml documents");};function bw(a){this.b=[];this.g=[];this.a={};if(a&&(a=aw(a))&&a.firstChild)switch(this.i=a,this.i.firstChild.tagName){case "timedtext":a=this.i.firstChild.childNodes;for(var b=0,c=a.length;b<c;b++)switch(a[b].tagName){case "window":var d=a[b],e=parseInt(d.getAttribute("id"),10),g=void 0;t:{var h=this.a[e];if(d.getAttribute("t")||d.getAttribute("start")){g=parseInt(d.getAttribute("t"),10);d.getAttribute("start")&&(g=1E3*parseFloat(d.getAttribute("start")));h&&(h.a+h.Fc>=g?h.Fc=g:h=null);switch(d.getAttribute("op")){case "kill":g=
-null;break t;case "define":h=null}h?h.j=!0:h=$v();var k={};w(k,h?h.params:Iv);d.getAttribute("id")&&(k.id=d.getAttribute("id"));d.getAttribute("op")&&(k.xy=d.getAttribute("op"));d.getAttribute("rc")&&(k.Ed=parseInt(d.getAttribute("rc"),10));d.getAttribute("cc")&&(k.xk=parseInt(d.getAttribute("cc"),10));d.getAttribute("ap")&&(h=parseInt(d.getAttribute("ap"),10),k.li=0>h||8<h?7:h);d.getAttribute("ah")&&(k.mi=parseInt(d.getAttribute("ah"),10));d.getAttribute("av")&&(k.he=parseInt(d.getAttribute("av"),
-10));d.getAttribute("id")&&(k.id=parseInt(d.getAttribute("id"),10)||0);d.getAttribute("vs")&&(k.isVisible=Boolean(d.getAttribute("vs")));d.getAttribute("ju")&&(k.textAlign=Hv[parseInt(d.getAttribute("ju"),10)]);d.getAttribute("pd")&&(k.Oe=1,0==parseInt(d.getAttribute("pd"),10)&&(k.Oe=0));d.getAttribute("bc")&&(k.backgroundColor=parseInt(d.getAttribute("bc"),16));d.getAttribute("bo")&&(k.opacity=parseInt(d.getAttribute("bo"),10)/100);d.getAttribute("fc")&&(k.ii=parseInt(d.getAttribute("fc"),16));d.getAttribute("sd")&&
-(k.nk=parseInt(d.getAttribute("sd"),10));h=parseInt(d.getAttribute("d"),10)||1E3*parseFloat(d.getAttribute("dur"))||2147483647;d={wk:g,Fc:h,params:k,windowId:parseInt(d.getAttribute("id"),10)};g=new Zv(d)}else g=null}this.a[e]=g;this.g.push(g);break;case "text":e=Yv(a[b]),this.b.push(e),d=e.bi,this.a[d]&&(d=this.a[d],e=e.ge,""!=d.g&&(d.b=!0),d.g+=e)}break;default:for(this.g.push($v()),a=this.i.firstChild.childNodes,b=0,c=a.length;b<c;b++)e=Yv(a[b]),this.b.push(e)}}bw.prototype.b=null;
-bw.prototype.g=null;bw.prototype.a=null;function cw(a){this.a=a.languageCode;this.b=a.languageName||null;this.g=a.languageOriginal||null;this.id=a.id||null;this.i=a.is_default||!1};function dw(a){a=a||{};this.Nk=a.format;this.b=a.languageCode||"";this.bh=a.languageName;this.Nb=a.kind||"";this.hc=a.name;this.Ba=a.id;this.Ek=a.is_servable;this.pi=a.is_default;this.qi=a.is_translateable;a.translationLanguage&&(this.a=new cw(a.translationLanguage))}
-function ew(a){var b={format:a.Nk,languageCode:a.b,languageName:a.bh,displayName:fw(a),kind:a.Nb,name:a.hc,id:a.Ba,is_servable:a.Ek,is_default:a.pi,is_translateable:a.qi};a.a&&(b.translationLanguage={languageCode:a.a.a,languageName:a.a.b,languageOriginal:a.a.g,id:a.a.id,is_default:a.a.i});return b}f=dw.prototype;f.bh=null;f.Nb=null;f.hc=null;f.Ba=null;f.Ek=!1;f.pi=!1;f.qi=!1;f.Nk=1;
-function fw(a){var b=[a.bh];if("asr"==a.Nb){var c=lf("HTML5_SUBS_ASR");b.push(" (",c,")")}a.hc&&b.push(" - ",a.hc);a.a&&b.push(" >> ",a.a.b);return b.join("")}f.toString=function(){var a=[this.b,": ",this.hc," (",this.Nb,")"];this.a&&a.push(" >> ",this.a.a);return a.join("")};f.equals=function(a){if(!a)return!1;var b=this.a,c=a.a;if(b&&c){if(b.a!=c.a)return!1}else if(b||c)return!1;return this.b==a.b&&this.hc==a.hc&&this.Nb==a.Nb};function gw(){this.g=[];this.a=[]}gw.prototype.g=null;gw.prototype.a=null;gw.prototype.b=-1;function hw(a,b){return b?a.a.concat(a.g):a.a}function iw(a,b){switch(b.Nb){case "asr":return jw(b,a.g);default:if(b.pi||0>a.b)a.b=a.a.length;return jw(b,a.a)}}function jw(a,b){return Oa(b,v(a.equals,a))?!1:(b.push(a),!0)};function kw(a,b,c,d){this.Od=a;c?this.Od=Kj(this.Od,{hl:c}):(a=Gj(this.Od).hl||"",a=a.split("_").join("-"),this.Od=Kj(this.Od,{hl:a}));this.Ni=b;this.Np=!!d;this.Md=new gw;this.Ci=[];this.Op={}}f=kw.prototype;f.Od="";f.Ni=null;f.Np=!1;f.Md=null;f.Ci=null;f.Op=null;function lw(a,b){return Oa(hw(a.Md,!0),function(a){return a.toString()==b})}function mw(a,b){var c=a.Od,d={v:a.Ni,type:"track",lang:b.b,name:b.hc,kind:b.Nb,fmt:b.Nk};b.a&&(d.tlang=b.a.a);return c=Kj(c,d)}
-function nw(a,b,c){var d=mw(a,b);a=v(function(a){a=new bw(a.responseText);c(a,b)},a);Nj(d,a)}function ow(a){var b=a.Md.b;a=hw(a.Md,!0);return 0>b?null:a[b]}
-function pw(a,b){var c=a.Od,d={type:"list",tlangs:1,v:a.Ni,fmts:Number(!0)};a.Np&&(d.asrs=1);c=Kj(c,d);d=v(function(a){if((a=a.responseXML)&&a.firstChild){for(var c=this.Md,d=a.getElementsByTagName("track"),k=d.length,m=0;m<k;m++){var p=parseInt(d[m].getAttribute("formats"),10)||1,s=d[m].getAttribute("lang_code"),r=d[m].getAttribute("lang_translated"),D=d[m].getAttribute("name"),M=d[m].getAttribute("kind")||"",sa=d[m].getAttribute("id"),Y="true"==d[m].getAttribute("lang_default"),SC="true"==d[m].getAttribute("cantran");
-iw(c,new dw({format:p,languageCode:s,languageName:r,name:D,kind:M,id:sa,is_servable:!0,is_default:Y,is_translateable:SC}))}a=a.getElementsByTagName("target");c=a.length;for(d=0;d<c;d++)k=a[d].getAttribute("lang_code"),m=a[d].getAttribute("lang_translated"),p=a[d].getAttribute("lang_original"),s=a[d].getAttribute("id"),r="true"==a[d].getAttribute("lang_default"),k={languageCode:k,languageName:m,languageOriginal:p,id:s,is_default:r},this.Op[k.languageCode]=k.languageName,this.Ci.push(new cw(k))}b()},
-a);Nj(c,d)};function qw(a){Tm.call(this,a);var b=Q(a);this.Id=a.J();this.Zn=a.app.S;this.ne=[];this.Ia={};this.fe={};this.Re=[];this.i=E("captions-translation-select",b);this.Hl=E("captions-translation-dialog",b);this.Gl=E("captions-settings-dialog",b);this.dd=E("html5-captions-button",b);J(this.dd,"click",v(this.gw,this));J(E("captions-translation-confirm",b),"click",v(this.qw,this));J(E("captions-translation-cancel",b),"click",v(this.$n,this));wf(E("captions-settings-background-opacity",b),v(this.ew,this),
-"INPUT");wf(E("captions-settings-text-opacity",b),v(this.ow,this),"INPUT");wf(E("captions-settings-window-opacity",b),v(this.rw,this),"INPUT");wf(E("captions-settings-char-edge-style",b),v(this.hw,this),"SELECT");J(E("captions-settings-font-family",b),"change",v(this.lw,this));J(E("captions-settings-font-inc",b),"click",v(this.xp,this));J(E("captions-settings-font-dec",b),"click",v(this.wp,this));J(E("captions-settings-confirm",b),"click",v(this.dw,this));J(E("captions-settings-cancel",b),"click",
-v(this.mw,this));a=E("captions-settings-dialog",b);yf(a,v(this.iw,this),"html5-color-picker-button");this.dd&&(this.jd=E("html5-captions-tracks",this.dd),this.Ef=is(Xr.getInstance(),this.dd),a=E("html5-captions-track-template",this.Ef),this.vp=new ct(a,["track_id","track_display_name"]),yf(this.Ef,v(this.fw,this),"yt-uix-button-menu-item"));this.Rf=new Ei;this.Rf.stop();J(this.Rf,"tick",v(this.kl,this));this.D("onResize",v(this.Pn,this));this.D("onBackgroundChange",v(this.uw,this));this.D("onTextOpacityChange",
-v(this.ww,this));this.D("onWindowOpacityChange",v(this.xw,this));this.D("onFontSizeIncrease",v(this.xp,this));this.D("onFontSizeDecrease",v(this.wp,this));this.D("onShowControls",v(this.kw,this));this.D("onHideControls",v(this.jw,this));"detailpage"==this.Id.Y&&(b=E("captions-account-settings-link",b))&&Rn(b);this.wi=new Mv(99,Jv);this.dh=new Ei(2E3);this.dh.stop();J(this.dh,"tick",v(this.tw,this))}y(qw,Tm);f=qw.prototype;f.qa="captions";f.hd="cc";f.zl="subtitlesModuleData";f.Ei=!1;f.Uk=!1;f.fd=null;
-f.Id=null;f.Zn=null;f.dd=null;f.Ef=null;f.vp=null;f.Hl=null;f.Gl=null;f.jd=null;f.Re=null;f.ne=null;f.Ia=null;f.fe=null;f.Rf=null;f.wi=null;f.dh=null;f.Pb=null;f.Ai=!1;f.Xo=1;var rw={background:"#080808",backgroundOpacity:1,charEdgeStyle:"uniform",color:"#fff",fontFamily:'"Arial Unicode Ms", Arial',fontFamilyOption:"propSans",fontSizeIncrement:0,textOpacity:1,windowColor:"#080808",windowOpacity:0};f=qw.prototype;f.gc=null;f.Sn=!1;
-f.create=function(){qw.C.create.call(this);this.fd=this.a.getVideoData();var a=this.a.J().U;-1==Kv.indexOf(a)&&V(Q(this.a),"cc-international");this.b=Lb(rw);w(this.b,$m(this,"display-settings"));1==this.Id.a.cc_load_policy||1==this.fd.Lm||"alwayson"==xm(this.fd,"yt:cc")?a=!0:(a=$m(this,"module-enabled"),a=null!=a?!!a:"on"==xm(this.fd,"yt:cc")||this.Id.a.cc_prefer_on);a&&this.load()};f.destroy=function(){this.unload();qw.C.destroy.call(this)};
-f.load=function(){if(this.Ei)this.ba&&(qw.C.load.call(this),this.Ai="alwayson"==xm(this.fd,"yt:cc"),this.Ef&&X(this.Ef,"captions-always-on",this.Ai),an(this,"module-enabled",!0),this.Ei=!1,sw(this),this.Pn());else{this.Ei=!0;this.ba=!1;var a=this.fd.b.cc_lang_pref||this.Id.a.cc_lang_pref||xm(this.fd,"yt:cc_default_lang")||this.Id.i,a=a&&a.split("_").join("-");this.Pb=new kw(this.fd.ni,this.fd.L,a,this.fd.zk);a=v(this.mo,this);pw(this.Pb,a)}};
-f.unload=function(){this.Bc&&(tw(this,!1),this.Ho("control_subtitles_set_track"));uw(this);Ym(this);an(this,"module-enabled",!1);this.Ei=!1;this.ba&&(this.ba=!1,qw.C.unload.call(this))};f.log_=function(){};function vw(a,b){a.i&&(Xc(a.i),z(b,function(a){var b=Uc("option");b.setAttribute("value",a.a);b.appendChild(Vc(a.b+" -- "+a.g));this.i.appendChild(b)},a))}
-f.mo=function(){this.jd&&Xc(this.jd);vw(this,this.Pb.Ci);var a=hw(this.Pb.Md,!0);if(0<a.length){this.log_("Caption track list loaded, found "+a.length+" tracks.");z(a,function(a){if(a.Ek){var b=a.toString();a=fw(a);ww(this,b,a)}},this);var b=this.Pb.Md.b;(a=a[b]&&a[b].toString())&&xw(this,a);this.dd&&hs(Xr.getInstance(),this.dd);(a=ow(this.Pb))?(this.Uk=!0,yw(this,a)):(this.ba||(this.ba=!0,this.load()),this.u("publish_external_event","onCaptionsTrackListChanged"))}else this.log_("No captions found."),
-this.unload(),Sn(this.Ef),Sn(this.dd)};f.hv=function(a,b){var c=a.g.concat(a.b);this.log_("Caption track loaded with "+c.length+" events.");uw(this);this.Re=$a(c);this.gc=b;this.Sn=qu.test(b.b);this.ba||(this.ba=!0,this.load());this.Uk&&(this.Uk=!1,this.u("publish_external_event","onCaptionsTrackListChanged"));c=Ka(c,function(a,b){return new Zh(a.a,a.a+a.Fc,{id:"caption"+b})});this.zf.apply(this,c);this.co(b)};
-f.co=function(a){var b={trackName:a.hc,trackKind:a.Nb};a.a?(b.trackLangCode=a.a.a,b.fromLangCode=a.b):b.trackLangCode=a.b;this.log(b);var b=this.wi,c=fw(a);c&&(c=c.replace(/<[^>]*>?/g,""),b.Xe(c));Wm(this,this.wi.oa);this.dh.start();this.u("publish_external_event","captionschanged",ew(a))};f.xc=function(a){0==a.getId().indexOf("caption")&&(a=parseInt(a.getId().split("caption")[1],10),!isNaN(a)&&this.Re[a]&&(this.ne.push(this.Re[a]),this.Rf.start()))};
-f.$c=function(a){0==a.getId().indexOf("caption")&&(a=parseInt(a.getId().split("caption")[1],10),!isNaN(a)&&this.Re[a]&&(a=this.ne.indexOf(this.Re[a]),0<=a&&this.ne.splice(a,1),this.Rf.start()))};
-function zw(a,b){if(b instanceof Zv){var c=a.Ia[b.id];w(b.params,a.b);c&&c.getType()!=(b.params.nk?2:b.b?0:1)&&(F(c.oa),delete a.Ia[b.id]);if(!a.Ia[b.id]){var c=a.Ia,d=b.id,e;t:{e=b.id;var g=b.params;switch(b.params.nk?2:b.b?0:1){case 0:e=new Pv(e,g);break t;case 2:e=new Rv(e,g);break t;default:e=new Mv(e,g)}}c[d]=e;c=a.Ia[b.id].oa;X(c,"captions-asr","asr"==a.gc.Nb);null!=b.params.Oe&&(b.params.Oe=a.Sn?1:0);0==a.Ia[b.id].id?(V(c,a.qa),Aw(a.a.app.S,c)):Wm(a,c)}w(a.Ia[b.id].ra,b.params);if(0==(b.params.nk?
-2:b.b?0:1)){c=a.Ia[b.id];c.ho=b.g;c.Bb={};c.fh=!0;c.Xe(c.ho);c.Bb.Ed=c.Rb.length;c.Bb.width=c.oa.offsetWidth;c.Bb.height=c.oa.offsetHeight;c.Bb.eo=[];c.Bb.fo=[];for(d=0;d<c.Bb.Ed;d++)c.Bb.fo.push(c.Rb[d].offsetTop),c.Bb.eo.push(c.Rb[d].offsetLeft);c.fh=!1;c.Xe(c.gh)}}else c=b.bi,a.fe[c]||(a.fe[c]=[]),a.fe[c].push(b)}f.Pn=function(){if(this.ba){Ym(this);this.Xo=Bw(this.Id).height/360;sw(this);for(var a in this.Ia)this.Ia[a].Wf()}};
-function Cw(a){var b=[],c;for(c in a.Ia){var d=a.Ia[c];d instanceof Pv&&b.push(a.Ia[c])}if(0!=b.length){b.sort(function(a,b){return b.ra.he-a.ra.he});c=Bw(a.Id).height;var e=a.Ia[b[0].id].ra.he,g;for(g in b){d=a.Ia[b[g].id];d.ra.he=e;var h=Math.round(d.ra.Ed*d.Wi()),e=e-Math.round(100*(h/c));d.Wf()}}}f.tw=function(){this.dh.stop();F(this.wi.oa)};
-f.kl=function(){this.Rf.stop();var a=this.ne.length,b;for(b in this.fe)delete this.fe[b];this.ne.sort(function(a,b){return a.a==b.a?a.i-b.i:a.a-b.a});for(var c=0;c<a;c++)zw(this,this.ne[c]);for(b in this.Ia)this.fe[b]?this.Ia[b].Wo(this.fe[b]):(F(this.Ia[b].oa),delete this.Ia[b]);Cw(this);this.log_("Refreshing caption display...")};function Dw(a,b){var c=E(a).querySelectorAll("."+b+" input[type=radio]"),d=Ra(c,function(a){return a.checked}),d=(-1==d?1:d+1)%c.length;c[d].click()}
-f.uw=function(){Dw("captions-settings-background-opacity","captions-settings-background-opacity-radio")};f.ww=function(){Dw("captions-settings-text-opacity","captions-settings-text-opacity-radio")};f.xw=function(){Dw("captions-settings-window-opacity","captions-settings-window-opacity-radio")};f.ew=function(a){a=parseFloat(a.target.getAttribute("value"));isNaN(a)||(this.b.backgroundOpacity=a,sw(this))};f.ow=function(a){a=parseFloat(a.target.getAttribute("value"));isNaN(a)||(this.b.textOpacity=a,sw(this))};
-f.rw=function(a){a=parseFloat(a.target.getAttribute("value"));isNaN(a)||(this.b.windowOpacity=a,sw(this))};f.hw=function(a){a.target&&(this.b.charEdgeStyle=a.target.value,sw(this))};f.lw=function(a){a.target&&(this.b.fontFamilyOption=a.target.value,sw(this))};f.kw=function(){var a=this.Ia[0];a&&a.oa&&(a=a.oa,W(a,"controls-hidden"),V(a,"controls-visible"))};f.jw=function(){var a=this.Ia[0];a&&a.oa&&(a=a.oa,Om(a,"controls-visible")&&(W(a,"controls-visible"),V(a,"controls-hidden")))};
-f.wp=function(){Ew(this,-1)};f.xp=function(){Ew(this,1)};function Ew(a,b){a.b.fontSizeIncrement+=b;sw(a)}function Fw(a,b){var c=E(b);c&&(c.querySelector('input[value="'+a.toFixed(1)+'"]').checked=!0)}function Gw(a,b,c){var d=E(b);d&&(b=d.querySelector("span.yt-uix-form-input-select-value"),d=d.querySelector("select"),d.value=a.b[c],ad(b,d.options[d.selectedIndex].text))}function uw(a){Um(a);a.ne=[];a.Re=[];a.gc=null;a.kl()}
-function yw(a,b){if(b)if(a.Bc)a.gc=b,tw(a,!0),a.Ho("control_subtitles_set_track",ew(b));else if(a.Id.jg){var c=a.Pb,d=a.Zn.b,e=v(a.co,a),g=c.Od,c={v:c.Ni,type:"track",lang:b.b,name:b.hc,kind:b.Nb,fmt:"vtt"};b.a&&(c.tlang=b.a.a);var h=document.createElement("track");h.src=Kj(g,c);h.mode="showing";h.setAttribute("kind","captions");h.setAttribute("default","");d.appendChild(h);e(b)}else nw(a.Pb,b,v(a.hv,a))}f.gw=function(){this.ba?H(v(this.Lp,this),1):this.load()};
-f.fw=function(a){a=a.currentTarget;var b=G(a,"action");if(b)switch(b){case "translate":this.Ai||(Ym(this),Xm(this),Rn(this.Hl));break;case "settings":Ym(this);Xm(this);Hw(this);Rn(this.Gl);break;case "captions-off":this.unload()}else(a=G(a,"trackid"))?(xw(this,a),b=lw(this.Pb,a),yw(this,b),this.log_("Caption change failed for "+a)):this.log_("onCaptionTrackClicked_ empty, ignoring")};
-function xw(a,b){if(a.jd){var c=E("yt-uix-button-menu-item.active",a.jd);c&&W(c,"active");if(c=a.jd.querySelector(".yt-uix-button-menu-item"+('[data-trackid="'+b+'"]')))V(c,"active"),a.Lp()}}f.Lp=function(){var a=E("yt-uix-button-menu-item.active",this.jd);if(a){var b=this.jd,c=C&&!rc(8)?0:b.offsetTop,d=a.offsetTop+a.offsetHeight-c-(b.clientHeight+b.scrollTop)+1;b.scrollTop+=Math.max(d,0);d=b.scrollTop-(a.offsetTop-c)+1;b.scrollTop-=Math.max(d,0)}};f.$n=function(){Sn(this.Hl)};
-f.qw=function(){if(!this.Ai){this.$n();var a;t:{var b=this.Pb.Ci;for(a=0;a<b.length;a++){var c=b[a];if(c.a==this.i.value){a=c;break t}}a=null}a&&(c=this.gc,b=new dw,b.b=c.b,b.bh=c.bh,b.hc=c.hc,b.Nb=c.Nb,b.pi=!1,b.qi=c.qi,b.a=a,iw(this.Pb.Md,b)&&(a=b.toString(),ww(this,a,fw(b)),xw(this,a),this.dd&&hs(Xr.getInstance(),this.dd)),yw(this,b))}};f.dw=function(){Sn(this.Gl)};f.mw=function(){delete this.b;this.b=Lb(rw);an(this,"display-settings",this.b);sw(this)};
-function sw(a){Iw(a);var b=jp(a.b.background),c=a.b.backgroundOpacity;an(a,"display-settings",a.b);a.k=un(".captions-text, .caption-row","background-color: rgba("+b[0]+","+b[1]+","+b[2]+","+c+") !important;",{Kb:a.k,reset:!0});Fw(c,"captions-settings-background-opacity");b=jp(a.b.color);c=a.b.textOpacity;an(a,"display-settings",a.b);a.G=un(".captions-text","color: rgba("+b[0]+","+b[1]+","+b[2]+","+c+") !important;",{Kb:a.G,reset:!0});Fw(c,"captions-settings-text-opacity");b=jp(a.b.windowColor);c=
-a.b.windowOpacity;an(a,"display-settings",a.b);a.K=un(".caption-window-transform","background-color: rgba("+b[0]+","+b[1]+","+b[2]+","+c+") !important;",{Kb:a.K,reset:!0});Fw(c,"captions-settings-window-opacity");an(a,"display-settings",a.b);var b=a.b.charEdgeStyle,d=a.b.textOpacity;if("none"==b)vn(a.j);else{var c="",e="rgba(34, 34, 34, "+d+")",d="rgba(204, 204, 204, "+d+")";switch(b){case "dropShadow":c="text-shadow: 2px 2px 3px "+e+", 2px 2px 4px "+e+", 2px 2px 5px "+e+";";break;case "raised":c=
-"text-shadow: 1px 1px "+e+", 2px 2px "+e+", 3px 3px "+e+";";break;case "depressed":c="text-shadow: 1px 1px "+d+", 0 1px "+d+", -1px -1px "+e+", 0 -1px "+e+";";break;case "uniform":c="text-shadow: 0 0 4px "+e+", 0 0 4px "+e+", 0 0 4px "+e+", 0 0 4px "+e+";"}a.j=un(".captions-text",c,{Kb:a.j,reset:!0})}Gw(a,"captions-settings-char-edge-style","charEdgeStyle");c=b="";switch(a.b.fontFamilyOption){case "monoSerif":b='"Courier New", Courier, "Nimbus Mono L", monospace';break;case "propSerif":b='"Times New Roman", Times, Georgia, Cambria, serif';
-break;case "monoSans":b='"Deja Vu Sans Mono", "Lucida Console", Monaco, Consolas, monospace';break;case "propSans":b='"Arial Unicode Ms", Arial, Helvetica, Verdana, sans-serif';break;case "casual":b='"Comic Sans MS", Impact, fantasy';break;case "cursive":b='"Monotype Corsiva", "URW Chancery L", "Apple Chancery", cursive';break;case "smallCaps":b='"Arial Unicode Ms", Arial, Helvetica, Verdana, sans-serif',c="font-variant: small-caps;"}a.A=un(".captions-text",c+"font-family: "+b+" !important;",{Kb:a.A,
-reset:!0});a.b.fontFamily=b;an(a,"display-settings",a.b);Gw(a,"captions-settings-font-family","fontFamilyOption");an(a,"display-settings",a.b);b="font-size: "+Math.round(((a.b.fontSizeIncrement||0)+16)*a.Xo)+"px;";a.B=un(".caption-window-transform",b,{Kb:a.B,reset:!0});a.kl()}f.iw=function(a){var b=v(function(b){var d=G(a.currentTarget,b.toLowerCase());d&&(this.b[b]=d)},this);b("color");b("background");b("windowColor");sw(this);an(this,"display-settings",this.b)};
-function Hw(a){var b={Kb:a.g},c=a.b.color,d=a.b.background,e=a.b.windowColor;c&&(a.g=un('.html5-popup-dialog button[data-color="'+c+'"]',"border: 3px solid #992121;",b));d&&(a.g=un('.html5-popup-dialog button[data-background="'+d+'"]',"border: 3px solid #992121;",b));e&&(a.g=un('.html5-popup-dialog button[data-windowcolor="'+e+'"]',"border: 3px solid #992121;",b))}
-function Iw(a){var b=[],c=v(function(a){var c=this.b[a];c&&b.push(a+": "+c+" !important")},a);c("color");c("background");c={Kb:a.g,reset:!0};a.g=un(".captions-text",b,c);var d=jp(a.b.windowColor),c={Kb:a.I,reset:!0};a.I=un(".caption-window-transform","background-color: rgba("+d[0]+","+d[1]+","+d[2]+", 1)",c);Hw(a)}function ww(a,b,c){a.jd&&(b=dt(a.vp,{track_id:b,track_display_name:c}),a.jd.appendChild(b))}function Jw(a){return qw.prototype.Xa(a)?new qw(a):null}
-f.nq=function(a,b){switch(a){case "fontSize":return isNaN(b)||(this.b.fontSizeIncrement=b,sw(this)),this.b.fontSizeIncrement;case "reload":b&&pw(this.Pb,v(this.mo,this));break;case "track":if(b){if(!ia(b))break;var c=new dw(b);c.equals(this.gc)||(yw(this,c),xw(this,c.toString()))}else return this.gc?ew(this.gc):{};return"";case "tracklist":return this.ba?Ka(hw(this.Pb.Md,b&&b.includeAsr),function(a){return ew(a)}):[]}};f.hp=function(){return["reload","fontSize","track","tracklist"]};f.Xa=function(a){return!!a.getVideoData().ni};
-f.Zh=function(a){a?(a=this.gc,uw(this),this.gc=a):(tw(this,this.ba),this.gc&&yw(this,this.gc))};function tw(a,b){X(Q(a.a),a.qa+"-loaded",b)};function Kw(){var a=Yb(),b;if(b=ml()){t:{if(navigator.plugins&&0<navigator.plugins.length)for(b=0;b<navigator.plugins.length;b++)if(0<=navigator.plugins[b].name.indexOf("NVIDIA 3D Vision")){b=!0;break t}b=!1}if(b)t:{var c=navigator.userAgent.match(/Firefox[\/\s](\d+\.\d+)/);if(c&&1<c.length&&4<=c[1]){c=document.createElement("embed");c.setAttribute("id","NvImageDetectionFFID");c.setAttribute("style","visibility: hidden");c.setAttribute("width",25);c.setAttribute("height",25);c.setAttribute("type",
-"image/jps");Wc(document.documentElement,c);c=Jc("NvImageDetectionFFID");try{if(null!=c){b=27527<=c.NvGetDriverVersion();break t}}catch(d){}}b=!1}}return b||!(!a||-1==a.indexOf("Sony"))};function Lw(a){Tm.call(this,a);var b=a.getVideoData();b.Q&&Mw(this);Nw(this,"html5-threed-conversion-on",v(this.zv,this));Nw(this,"html5-threed-conversion-off",v(this.yv,this));var c=Q(this.a);a=E("html5-threed-popup-menu-change-mode-link",c);c=E("html5-threed-dialog-change-mode-button",c);b="/select_3d_mode?video_id="+b.L;a.setAttribute("href",b);c.setAttribute("href",b)}y(Lw,Tm);f=Lw.prototype;f.zl="threeDModuleData";f.ff=null;function Nw(a,b,c){a=E(b,Q(a.a));J(a,"click",c)}f.qa="threed";f.hd="threed";
-f.create=function(){Ow(this.a.app,void 0);Lw.C.create.call(this)};f.destroy=function(){Ow(this.a.app,!0);this.unload();Lw.C.destroy.call(this)};function Pw(a){return Lw.prototype.Xa(a)?new Lw(a):null}f.Xa=function(a){a=a.getVideoData();return!!a.Q||!!a.Ej};f.zv=function(){Qw(this,!0)};f.yv=function(){Qw(this,!1)};function Qw(a,b){var c=a.a.getVideoData();if(c.Ej&&c.If!=b){var c=a.a.app,d=O(c),e=d.a;e.If=!e.If;e.k=[];e.u("dataupdated");fh(d,"m");Ow(c);b?Mw(a):Ym(a)}}
-function Mw(a){$m(a,"warning-shown")||Kw()||(a.ff=E("threed-html5-warning-dialog",Q(a.a)),Rn(a.ff),H(v(function(){Rw(this)},a),0),J(a.ff,"mouseover",v(function(){W(this.ff,"hide-dialog")},a)),J(a.ff,"mouseout",v(function(){Rw(this)},a)),Nw(a,"threed-html5-warning-close",v(a.Hv,a)))}function Rw(a){V(a.ff,"hide-dialog");H(v(function(){Om(this.ff,"hide-dialog")&&Ym(this)},a),9E3)}f.Hv=function(){an(this,"warning-shown",!0);Ym(this)};function Sw(a){Tm.call(this,a);this.b=new hn(["div","ytp-ypc-clickwrap-overlay",["h2","header",lf("YPC_CLICKWRAP_HEADER")],["div","description",lf("YPC_CLICKWRAP_DESCRIPTION")],["button","confirm-button",lf("YPC_CLICKWRAP_BUTTON")]]);pn(this.b.N());this.a.app.S.g.appendChild(this.b.N());L(this,this.b);this.g=this.b.a["confirm-button"]}y(Sw,Tm);f=Sw.prototype;f.qa="ypc_clickwrap";f.hd="ypc-clickwrap";f.Xa=function(){return Bm(this.a.getVideoData(),"ypc_clickwrap_module")};
-function Tw(a){return Bm(a.getVideoData(),"ypc_clickwrap_module")?new Sw(a):null}f.create=function(){Sw.C.create.call(this);this.load()};f.destroy=function(){this.ba&&this.unload()};f.load=function(){Sw.C.load.call(this);E("html5-video-container",Q(this.a));on(this.b.N());J(this.g,"click",v(this.tu,this));this.ba=!0};f.unload=function(){pn(this.b.N());zf(this.g);this.ba=!1;Sw.C.unload.call(this)};f.tu=function(){Vm(this);this.destroy()};function Uw(a){a=a.b;this.j=a.ypc_offer_button_text;this.description=a.ypc_offer_description;this.heading=a.ypc_offer_headline;this.k=a.ypc_full_video_message;this.b=a.ypc_offer_id;this.a=a.ypc_buy_url;this.g=a.ypc_item_thumbnail;this.title=a.ypc_item_title;this.i=a.ypc_item_url;this.L=a.ypc_vid};function Vw(){Z.call(this,["div",["ytp-drawer","html5-stop-propagation"],["div","ytp-drawer-content","{{content}}"],["a","ytp-drawer-close-button"],["a","ytp-drawer-open-button"]]);this.b=this.template.a["ytp-drawer-close-button"];J(this.b,"click",v(this.hide,this));this.a=this.template.a["ytp-drawer-open-button"];J(this.a,"click",v(this.show,this));this.Aa(null);this.hide()}y(Vw,Z);Vw.prototype.hide=function(){V(this.element,"ytp-drawer-closed")};
-Vw.prototype.Aa=function(a){a?(Vw.C.Aa.call(this,a),on(this.element)):pn(this.element)};Vw.prototype.show=function(){H(oa(W,this.element,"ytp-drawer-closed"),0)};Vw.prototype.F=function(){zf(this.b);zf(this.a);this.a=this.b=null;Vw.C.F.call(this)};function Ww(a,b){R.call(this);this.a=new Vw;L(this,this.a);this.b=document.createElement("div");Pm(this.b,["html5-stop-propagation","html5-ypc-endscreen"]);this.i=document.createElement("div");V(this.i,"html5-ypc-overlay");this.g=new hn(["div","html5-ypc-module",["div","html5-ypc-action-heading","{{heading}}"],["div","html5-ypc-thumbnail","{{thumbnail_element}}"],["div","html5-ypc-title","{{title}}"],["div","html5-ypc-description","{{description}}"],["button","html5-ypc-purchase","{{button_label}}"]]);
-L(this,this.g);this.j=this.g.a["html5-ypc-purchase"];J(this.j,"click",v(this.k,this));ad(this.i,b.k);var c=b.title;b.i&&(c=["a",{href:b.i,target:"blank_"},b.title]);var d="";b.g&&(d=["img",{src:b.g}]);this.g.update({heading:b.heading,title:c,thumbnail_element:d,description:b.description,button_label:b.j});this.a.V(a);this.a.Aa(this.g.N());a.appendChild(this.b)}y(Ww,R);Ww.prototype.F=function(){Ww.C.F.call(this);this.j&&zf(this.j);F(this.b);F(this.i);this.i=this.b=this.a=null};Ww.prototype.k=function(){this.u("ypcContentRequest")};function Xw(a){Tm.call(this,a);this.g=this.b=null;this.i=NaN}y(Xw,Tm);f=Xw.prototype;f.qa="ypc";f.hd="ypc";function Yw(a){var b=a.getVideoData();return a.J().nd&&Bm(b,"ypc_module")}f.Xa=function(){return Yw(this.a)};function Zw(a){return Yw(a)?new Xw(a):null}f.create=function(){Xw.C.create.call(this);var a=this.a.getVideoData();this.b=new Uw(a);a.ia?this.load():this.a.Io({video_id:this.b.L,ypc_preview:1})};f.destroy=function(){this.ba&&this.unload();this.b=null};
-f.load=function(){Xw.C.load.call(this);var a=E("html5-video-container",Q(this.a));this.g=new Ww(a,this.b);this.g.D("ypcContentRequest",this.Qt,this);Aw(this.a.app.S,this.g.i);oo(this.a.J())&&(a=new Zh(2147483647,2147483647,{priority:2}),this.zf(a));this.g.a.show();I(this.i);this.i=H(v(function(){this.g.a.hide()},this),1E4);this.ba=!0};f.unload=function(){Um(this);Tg(this.g);this.g=null;this.ba=!1;Xw.C.unload.call(this)};
-f.xc=function(a){Xw.C.xc.call(this,a);a=this.g;a.b.appendChild(a.g.N());a.a.Aa(null);on(a.b)};f.$c=function(a){Xw.C.$c.call(this,a);a=this.g;pn(a.b);a.a.Aa(a.g.N())};f.Qt=function(){if(this.b.a)"embedded"==this.a.J().Y?ms(this.b.a):window.location=S(this.b.a,{})+"";else if(this.b.b){var a=n("yt.www.watch.player.handleEndPreview");a&&a(this.b.b)}};var $w={Hz:"ERROR_ALREADY_PINNED_ON_A_DEVICE",Mz:"ERROR_AUTHENTICATION_EXPIRED",Nz:"ERROR_AUTHENTICATION_MALFORMED",Oz:"ERROR_AUTHENTICATION_MISSING",Yz:"ERROR_BAD_REQUEST",dA:"ERROR_CANNOT_ACTIVATE_RENTAL",lA:"ERROR_CGI_PARAMS_MALFORMED",mA:"ERROR_CGI_PARAMS_MISSING",YA:"DEVICE_FALLBACK",aB:"ERROR_LICENSE",dB:"FLASH_FALLBACK",CB:"ERROR_GEO_FAILURE",OB:"HTML5_DEFAULT_FALLBACK",PB:"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",UB:"ERROR_INVALID_DRM_MESSAGE",YB:"LEARN_MORE",pC:"ERROR_NOT_SIGNED_IN",AC:"ERROR_PURCHASE_NOT_FOUND",
-BC:"ERROR_PURCHASE_REFUNDED",EC:"ERROR_RENTAL_EXPIRED",eA:"ERROR_CAST_SESSION_DEVICE_MISMATCHED",fA:"ERROR_CAST_SESSION_VIDEO_MISMATCHED",hA:"ERROR_CAST_TOKEN_FAILED",gA:"ERROR_CAST_TOKEN_EXPIRED",iA:"ERROR_CAST_TOKEN_MALFORMED",KC:"ERROR_SERVER_ERROR",OC:"ERROR_STOPPED_BY_ANOTHER_PLAYBACK",QC:"ERROR_STREAMING_DEVICES_QUOTA_PER_24H_EXCEEDED",RC:"ERROR_STREAMING_NOT_ALLOWED",SC:"ERROR_STREAMING_UNAVAILABLE",FC:"ERROR_RETRYABLE_ERROR",ZC:"ERROR_TOO_MANY_STREAMS_PER_USER",YC:"ERROR_TOO_MANY_STREAMS_PER_ENTITLEMENT",
-bD:"ERROR_UNSUPPORTED_DEVICE",cD:"ERROR_UNUSUAL_ACTIVITY",jD:"ERROR_VIDEO_FORBIDDEN",lD:"ERROR_VIDEO_NOT_FOUND"},ax={300:"ERROR_STREAMING_DEVICES_QUOTA_PER_24H_EXCEEDED",301:"ERROR_ALREADY_PINNED_ON_A_DEVICE",303:"ERROR_STOPPED_BY_ANOTHER_PLAYBACK",304:"ERROR_TOO_MANY_STREAMS_PER_USER",305:"ERROR_TOO_MANY_STREAMS_PER_ENTITLEMENT",400:"ERROR_VIDEO_NOT_FOUND",401:"ERROR_GEO_FAILURE",402:"ERROR_STREAMING_NOT_ALLOWED",403:"ERROR_UNSUPPORTED_DEVICE",405:"ERROR_VIDEO_FORBIDDEN",500:"ERROR_PURCHASE_NOT_FOUND",
-501:"ERROR_RENTAL_EXPIRED",502:"ERROR_PURCHASE_REFUNDED",5E3:"ERROR_BAD_REQUEST",5001:"ERROR_CGI_PARAMS_MISSING",5002:"ERROR_CGI_PARAMS_MALFORMED",5100:"ERROR_AUTHENTICATION_MISSING",5101:"ERROR_AUTHENTICATION_MALFORMED",5102:"ERROR_AUTHENTICATION_EXPIRED",5200:"ERROR_CAST_TOKEN_MALFORMED",5201:"ERROR_CAST_TOKEN_EXPIRED",5202:"ERROR_CAST_TOKEN_FAILED",5203:"ERROR_CAST_SESSION_VIDEO_MISMATCHED",5204:"ERROR_CAST_SESSION_DEVICE_MISMATCHED",6E3:"ERROR_INVALID_DRM_MESSAGE",7E3:"ERROR_SERVER_ERROR",8E3:"ERROR_RETRYABLE_ERROR"};function bx(a){Tm.call(this,a);this.qa="ypc_license_checker";this.hd="ypc_license";this.j=!1;this.i=0;this.g=!1;this.b=null;this.B=ql();this.A=a.J().jb+"ypc_license_server"}y(bx,Tm);
-var cx={LICENSE_DENIED_CANNOT_ACTIVATE_RENTAL:"ERROR_CANNOT_ACTIVATE_RENTAL",LICENSE_DENIED_NOT_SIGNED_IN:"ERROR_NOT_SIGNED_IN",LICENSE_DENIED_NO_ACTIVE_PURCHASE_AGREEMENT:"ERROR_RENTAL_EXPIRED",LICENSE_DENIED_CONCURRENT_PLAYBACK:"ERROR_STOPPED_BY_ANOTHER_PLAYBACK",LICENSE_DENIED_UNUSUAL_ACTIVITY:"ERROR_UNUSUAL_ACTIVITY",LICENSE_DENIED_STREAMING_UNAVAILABLE:"ERROR_STREAMING_UNAVAILABLE",LICENSE_DENIED_PLAYBACK_CAP:"ERROR_LICENSE"};
-function dx(a){return Bm(a.getVideoData(),"ypc_license_checker_module")}f=bx.prototype;f.Xa=function(){return dx(this.a)};f.create=function(){bx.C.create.call(this);var a=new Zh(1E3,2147483646,{priority:0});this.zf(a);this.D("onStateChange",this.jx,this)};function ex(a){return dx(a)?new bx(a):null}f.xc=function(){this.j=!0;fx(this,6E4)};f.jx=function(a){P(a.state,2)?(this.i=0,this.b=null,this.g=!1):(P(a.state,1)||P(a.state,8))&&fx(this,6E4)};
-function fx(a,b){if(!a.b&&a.j){var c=b;void 0==c&&(c=a.g?6E4:1E3);var d=a.a.getVideoData();d.a&&d.a.g||(a.b={video_id:d.L,player_id:a.B,request_id:ql(),purchase_id:d.ue,version:"4",player_time_seconds:a.a.getCurrentTime().toString(),gid:d.Mc,session_token:d.Jc},a.k=d.Da,0==c?a.Dn():H(v(a.Dn,a),c))}}f.Dn=function(){if(this.b){var a=S(this.A,{cpn:this.k});Qj(a,{format:"RAW",method:"POST",Mf:this.b,timeout:3E4,Qa:v(this.Rv,this),onError:v(this.Qv,this),bl:v(this.Sv,this)})}};
-f.Rv=function(a){if(this.b){a=a.responseText;var b=a in cx?1:64<=a.length&&a.match(/[0-9a-fA-f]+/)?0:-1;-1==b?gx(this,"decode"):(this.i=0,this.b=null,1==b?(this.g=!1,a=a in cx?lf(cx[a]):lf("ERROR_LICENSE"),hx(this.a.app.b,150,a,void 0)):(this.g=!0,fx(this)))}};f.Qv=function(a){gx(this,"net-"+a.status)};f.Sv=function(){gx(this,"timeout")};function gx(a,b){if(a.b)if(a.log({errorType:b}),a.b=null,5<++a.i){var c=lf("ERROR_LICENSE");hx(a.a.app.b,150,c,void 0)}else fx(a)};function ix(){this.a=[];this.i={};this.o={};this.H={};this.b=this.j=null;this.g=[];this.k=null}y(ix,K);ix.prototype.B=function(a){if(this.b){var b;var c=ja(a);b=this.i[c];if(!b)if(this.b){if(b=a(this.b)){a=this.i[c]=b;for(var d in this.j)a.D(d,this.j[d]);a.D("command_log_timing",this.A,this);L(this,b)}}else b=null;b&&b.Xa(this.b)&&!Sa(this.a,b)&&(b.create(),this.a.push(b),Sa(this.g,b.qa)&&(b.Bc=this.k,b.Zh(!!b.Bc)))}};function jx(a){z(a.a,function(a){a.destroy()});a.a=[]}
-function kx(a,b,c){lx(a);a.k=b;a.g=$a(c);z(a.a,function(a){0<=Ia(c,a.qa)&&(a.Bc=b,a.Zh(!!a.Bc))})}function lx(a){z(a.g,function(a){if(a=ih(this,a))a.Bc=null,a.Zh(!1)},a);a.k=null;a.g=[]}function yh(a,b,c,d){return b&&c?(a=ih(a,b))?a.nq(c,d):null:null}function zh(a,b){if(!b)return Ka(a.a,function(a){return a.qa});var c=ih(a,b);return c?c.hp():[]}function ih(a,b){return Oa(a.a,function(a){return a.qa==b})}ix.prototype.G=function(a,b){z(this.a,function(c){c.u(a,b)})};
-function mx(a){var b=[];z(a.a,function(a){(a=a.Ri())&&b.push(a)});return b}ix.prototype.A=function(a,b){w(this.H,a||null);w(this.o,b||null)};function nx(a){this.a={};for(var b=0;b<a.length;b++){var c=a[b];this.a[c.a]=c}}function ox(a){a=Gb(a.a);fb(a,function(a,c){return a.a-c.a});return a};function px(a,b,c){this.b=a;this.a=b;this.i=!!c.Gf;this.g=c.ea};function qx(){this.ke={};this.a=this.$a().a;this.ad=null}f=qx.prototype;f.$a=function(){var a=this.constructor,b;if(!(b=a.Up)){var c;b=a.Kx;var d=[];for(c in b)b.hasOwnProperty(c)&&(0==c||d.push(new px(a,c,b[c])));c=new nx(d);b=a.Up=c}return b};f.has=function(a){a.b.$a();this.$a();return null!=this.ke[a.a]};f.get=function(a,b){a.b.$a();this.$a();var c;c=this.a[a.a];var d=rx(this,c);c.i?(t(d),c=d[b||0]):(t(d),c=d);return c};
-f.set=function(a,b){a.b.$a();this.$a();var c=a.a;this.ke[c]=b;this.ad&&(this.ad[c]=b)};f.add=function(a,b){a.b.$a();this.$a();var c=a.a;this.ke[c]||(this.ke[c]=[]);this.ke[c].push(b);this.ad&&delete this.ad[c]};f.clear=function(a){a.b.$a();this.$a();a=a.a;delete this.ke[a];this.ad&&delete this.ad[a]};
-f.equals=function(a){if(!a||this.constructor!=a.constructor)return!1;for(var b=ox(this.$a()),c=0;c<b.length;c++){var d=b[c];if(this.has(d)!=a.has(d))return!1;if(this.has(d)){var e=11==d.g||10==d.g,g=rx(this,d),h=rx(a,d);if(d.i){if(g.length!=h.length)return!1;for(d=0;d<g.length;d++)if(e?!g[d].equals(h[d]):g[d]!=h[d])return!1}else if(e?!g.equals(h):g!=h)return!1}}return!0};
-function sx(a,b){for(var c=ox(a.$a()),d=0;d<c.length;d++){var e=c[d];if(b.has(e)){a.ad&&delete a.ad[e.a];var g=11==e.g||10==e.g;if(e.i){var h,k=b;h=e;h.b.$a();k.$a();h=rx(k,k.a[h.a]);null==h||t(h);h=h||[];for(k=0;k<h.length;k++)a.add(e,g?h[k].clone():h[k])}else h=rx(b,e),g?(g=rx(a,e))?sx(g,h):a.set(e,h.clone()):a.set(e,h)}}}f.clone=function(){var a=new this.constructor;a!=this&&(a.ke={},a.ad&&(a.ad={}),sx(a,this));return a};function rx(a,b){var c=a.ke[b.a];return null==c?null:c}
-function tx(a,b){a.Kx=b;a.$a=function(){return a.Up||(new a).$a()}};var ux={Sy:0,CA:1,NA:2,Ry:3,$y:4,AA:5,LA:6,IA:7,JA:8,KA:9,GA:10,HA:11,bz:12,az:13,Qy:14,Ky:15,BA:20,PA:21,Jy:22,DA:23,OA:24,MA:25,Xy:30,QA:31,Wy:32,Yy:33,FA:40,EA:41,cz:42,dz:43,Ly:50,Oy:51,Ty:52,Uy:53,Vy:54,Gy:55,Hy:56,Zy:57,Py:58,Ny:60,My:61,Iy:70,Fy:80,ez:90};function vx(){qx.apply(this)}y(vx,qx);function wx(){qx.apply(this)}y(wx,qx);function xx(){qx.apply(this)}y(xx,qx);function yx(){qx.apply(this)}y(yx,qx);function zx(){qx.apply(this)}y(zx,qx);function Ax(){qx.apply(this)}y(Ax,qx);
-tx(vx,{0:{name:"YtAdType",wh:"video.YtAdType"},1:{name:"ad_namespace",required:!0,ea:14,defaultValue:0,type:{Fz:0,ZA:1,Gz:2,jA:3,BB:4,XA:5,WA:6,$z:7,UA:8,bA:9,TA:10,VA:11,Lz:12,GD:13}},2:{name:"ad_format",required:!0,ea:14,defaultValue:0,type:{Cz:0,VB:1,TB:2,mC:3,dD:4,WB:5,QB:6,SB:7,HD:8,$A:9}},3:{name:"ad_invideo",ea:14,defaultValue:0,type:{Ez:0,rA:1,sA:2,tA:3,uA:4,qA:5,cA:6}},4:{name:"invideo_autoplay",ea:14,defaultValue:0,type:{Wz:0,zC:1}},5:{name:"ad_instream",ea:14,defaultValue:0,type:{Dz:0,
-$C:1}},6:{name:"ad_instream_long",ea:8,type:Boolean}});tx(wx,{0:{name:"AdId",wh:"video.AdId"},1:{name:"ad_network",ea:14,defaultValue:1,type:{tC:1,Ey:2}},2:{name:"ad_network_name",ea:9,type:String},3:{name:"ad_id",required:!0,ea:9,type:String}});
-tx(xx,{0:{name:"YtAdEvent",wh:"video.YtAdEvent"},1:{name:"ad_event_type",required:!0,ea:14,defaultValue:0,type:{nz:0,vz:1,oz:2,yz:3,pz:4,qz:5,kz:6,iz:7,RA:8,fz:9,wz:10,xz:11,gz:12,SA:13,zz:14,lz:15,hz:16,mz:17,jz:18,Az:100,Bz:101,tz:130,rz:131,uz:132}},2:{name:"wall_time",required:!0,ea:2,type:Number},3:{name:"media_time",required:!0,ea:2,type:Number},4:{name:"logentry_time_usec",required:!0,ea:3,type:String},5:{name:"ad_error_type",ea:14,defaultValue:0,type:ux}});
-tx(yx,{0:{name:"YtAdSlot",wh:"video.YtAdSlot"},1:{name:"slot_time",required:!0,ea:2,type:Number},2:{name:"ad_type",required:!0,ea:11,type:vx},3:{name:"ad_events",Gf:!0,ea:11,type:xx},4:{name:"ad_video_duration",ea:2,type:Number},5:{name:"ad_id",ea:9,type:String},6:{name:"slot_index",ea:5,type:Number}});
-tx(zx,{0:{name:"YtVideoMetadata",wh:"video.YtVideoMetadata"},1:{name:"content_owner_ids",Gf:!0,ea:9,type:String},2:{name:"video_duration_seconds",ea:2,type:Number},3:{name:"all_content_owner_ids",ea:9,type:String}});
-tx(Ax,{0:{name:"YtWatchAdInfo",wh:"video.YtWatchAdInfo"},1:{name:"video_id",required:!0,ea:9,type:String},2:{name:"allowed_ads",Gf:!0,ea:11,type:vx},3:{name:"ad_slots",Gf:!0,ea:11,type:yx},4:{name:"ps",ea:9,type:String},5:{name:"el",ea:9,type:String},6:{name:"country",ea:9,type:String},7:{name:"feature",ea:9,type:String},8:{name:"blocked",ea:8,type:Boolean},9:{name:"plid",ea:9,type:String},10:{name:"video_metadata",ea:11,type:zx},11:{name:"experiment_id",Gf:!0,ea:3,type:String},12:{name:"ad_flags",
-ea:4,type:String},13:{name:"all_experiment_ids",ea:9,type:String},14:{name:"no_ads_returned",ea:8,type:Boolean},15:{name:"ad_errors",Gf:!0,ea:14,defaultValue:0,type:ux},16:{name:"ad_slot_with_event",ea:11,type:yx}});function Bx(a,b){Gh.call(this,a,b)}y(Bx,Gh);f=Bx.prototype;f.rg=function(){Vg(this.app,!0,this.a);this.app.Ud(!1,this.a)};f.fn=function(){this.app.Td(!1,this.a)};f.Sp=function(a,b,c){Vg(this.app,!0,this.a);var d=this.app,e=this.a;d.sf(d.getCurrentTime()+a,b,c,e)};f.Wh=function(a,b){Vg(this.app,!0,this.a);this.app.sf(a,b,void 0,this.a)};f.Dj=function(){bh(this.app,this.a)};function Cx(a){this.app=a;Tm.call(this,a.I)}y(Cx,Tm);var Dx={qC:"0",rC:"1",bB:"2",gy:"3",Xz:"4",JC:"5"};var Ex={DC:"red",ED:"white"};var Fx={iy:"0",NC:"1",xA:"2"};var Gx={"ad-trueview-indisplay-pv":6,"ad-trueview-insearch":7},Hx={"ad-trueview-indisplay-pv":2,"ad-trueview-insearch":2},Ix={adunit:{Wb:!1,Ac:!1},detailpage:{tc:!0}};Ix.embedded={Fh:Bf(),Gh:"4",Ac:!0};Ix.profilepage={yl:!0};
-var Jx="blogger books docs google-live play picasaweb".split(" "),Kx={blazer:{mj:"youtube_mobile",Ub:!1,oy:!1,Kg:!1,Lg:!1,qc:!0,Vb:!1,ub:!1,Gb:!0},blogger:{Be:!1,ag:!1,Rc:!1,Wb:!1,wc:!1,tc:!1,Ac:!1,sc:"bl"},books:{Be:!1,ag:!1,Rc:!1,Wb:!1,wc:!1,tc:!0,Ac:!1,sc:"gb"},docs:{Be:!1,ag:!1,Rc:!1,Wb:!1,wc:!1,tc:!1,Ac:!1,sc:"gd"},"google-live":{Be:!1,ag:!1,Rc:!1,Wb:!1,wc:!1,tc:!1,Ac:!1,sc:"gl"},play:{Wb:!1,wc:!1,tc:!1,Ac:!1,sc:"gp"},"native":{Kg:!1,Lg:!1,Vb:!0},olympics:{Kg:!1,Lg:!1,Rh:!0,Gb:!0},picasaweb:{Be:!1,
-ag:!1,Rc:!1,Wb:!1,wc:!1,tc:!1,Ac:!1,sc:"pw"},touch:{Kg:!1,Lg:!1,Gb:!0}};
-function Lx(a){this.o=[];this.a={};Mx(this,a.fexp);this.Q=U(this.Q,a.origin);this.Y=a.el||this.Y;var b=Ix[this.Y];b&&w(this,b);b=a.ps||this.Ca;0<navigator.msMaxTouchPoints&&(b="touch");this.Ca=b;(b=Kx[this.Ca])&&w(this,b);this.of=Nx(this)&&Sa(Jx,this.Ca);this.lg=!(!ll().defaultPlaybackRate||bc||Si||Ri||Ti);if(a.use_media_volume)b=!1;else{var b=ll(),c=b.muted;b.muted=!c;b=b.muted!=c}this.pm=b;this.sm=Ti;if(Si||Ri)this.qm=this.Oc||"blazer"!=this.Ca;this.ym="0"!=a.add_player_event_listeners;b=T(this.Fh,
-a.fs);this.Fh="detailpage"==this.Y||"olympics"==this.Ca?b:b&&Bf();this.Ea=U(this.Ea,a.authuser);this.Gh=sl(this.Gh,a.autohide,Dx);this.Ub=T(this.Ub,a.autoplay);this.Rj=T(this.Rj,a.autoplayoverride);this.color=sl(this.color,a.color,Ex);this.k=U(this.k,a.content_v);this.Sj=sl(this.Sj,a.controls,Fx);this.H=U(this.H,a.cbrand);this.A=U(this.A,a.cbr);this.B=U(this.B,a.cbrver);this.eg=U(this.eg,a.c);this.lf=U(this.lf,a.cver);this.G=U(this.G,a.cmodel);this.I=U(this.I,a.cnetwork);this.K=U(this.K,a.cos);this.M=
-U(this.M,a.cosver);this.O=U(this.O,a.cplatform);this.Oh=T(this.Oh,a.edu_mode);this.b=U(this.b,a.eurl);this.P=U(this.P,a.framer);this.fa=sl(this.fa,a.iv_load_policy,dl);this.i=U(this.i,a.hl);this.Mm=T(this.Mm,a.bwlogging);this.qc=T(this.qc,a.is_html5_mobile_device);this.Rd=T(this.Rd,a.player_wide);this.Nm=T(this.Nm,a.is_playground);this.loop=T(this.loop,a.loop);this.pf=T(this.pf,a.modestbranding);"red"!=this.color&&(this.pf=!1);this.yh=T(this.yh,a.noadapt);this.fg=T(this.fg,a.on3g);this.Ua=U(this.Ua,
-a.pageid);this.Kh=sl(this.Kh,a.vq,ek);this.pj=U(this.pj,a.playerapiid);this.Dh=T(this.Dh,a.playsinline);this.qj=T(this.qj,a.playonclick);this.U=U(this.U,a.cr);this.ja=U(this.ja,a.q);this.Rc=T(this.Rc,a.logwatch);this.Hj=T(this.Hj,a.canplaylive);this.Ij=T(this.Ij,a.canplaypaid);this.Wb=T(this.Wb,a.showinfo);this.wc=T(this.wc,a.rel);this.tc=T(this.tc,a.enablesizebutton);this.tj=T(this.tj,a.ss);this.X=U(this.X,a.theme);this.Vb=T(this.Vb,a.use_native_controls);this.ub=!Ri&&T(this.ub,a.svt);Nx(this)&&
-(this.Nh=T(this.Nh,a.altf),this.qg=T(this.qg,a.retryneterr),this.Rh=T(this.Rh,a.nologo));this.qg=this.qg||this.te;this.Vb&&(this.pf=!0,this.fa=3);this.Tj=T(this.Tj,a.ssl);if(this.Gb=T(this.Gb,a.use_tablet_controls))this.X="dark";b=this.Jh;if(c=a.video_container_override){var d=c.split("x");2==d.length&&(c=parseInt(d[0],10),d=parseInt(d[1],10),b=isNaN(c)||isNaN(d)||0>=c*d?b:new B(c,d))}this.Jh=b;this.bb=U(this.bb,a.attrib);this.aa=U(this.aa,a.sk);this.protocol=this.Tj?"https":"http";this.xe="0"!=this.Sj;
-this.oj=T(this.xe,a.store_user_volume);this.Sd=T(this.Sd,a.use_media_volume);(b=a.BASE_YT_URL)&&pk(b,lk)&&(this.jb=b);Ox(this,a);Px(this,a);"detailpage"==this.Y&&delete this.b;this.hj=Qx(this)+"s";this.Ac=this.pf&&!this.Vb?!this.Wb:this.Wb||this.xe?!1:this.Ac;b=this.Ub||"detailpage"==this.Y;c=!0;this.qc&&(c=!1);cj("nintendo wiiu")&&(c=!1);this.Rj&&(c=!0);this.hm=b&&c;this.a=a}y(Lx,K);f=Lx.prototype;f.ym=!0;f.Fh=!0;f.Ea="";f.Gh="2";f.Ub=!1;f.Rj=!1;f.jb="/";f.oy=!0;f.color="red";f.Sj="1";f.eg="web";
-f.lf="html5";f.Oh=!1;f.Kg=!0;f.Lg=!0;f.lg=!1;f.pm=!1;f.Y="detailpage";f.Mm=!1;f.pk=!1;f.of=!1;f.qc=!1;f.ob=!1;f.Rd=!1;f.Be=!0;f.Nm=!1;f.ag=!0;f.sg=!1;f.loop=!1;f.pf=!1;f.yh=!1;f.Kh=null;f.pj="";f.fg=!1;f.Ua="";f.Ca=null;f.Dh=!1;f.Nh=!1;f.sm=!1;f.qg=!1;f.hm=!1;f.Rc=!1;f.Hj=!0;f.Ij=!0;f.xe=!0;f.oj=!0;f.Sd=!1;f.Wb=!0;f.wc=!0;f.yl=!1;f.tc=!1;f.Ac=!1;f.tj=!1;f.Rh=!1;f.qm=!1;f.Vb=!1;f.ub=!0;f.Tj=!1;f.Gb=!1;f.Tc=null;f.Jh=null;f.nv=null;f.Dg=null;f.Wa=null;f.Mj=null;f.sc="yt";f.qj=!1;
-function Ox(a,b){a.Rc=T(a.Rc,b.logwatch);a.ma=void 0==b.user_age?a.ma:Number(b.user_age);a.Gp=U(a.Gp,b.user_display_image);a.Ol=U(a.Ol,b.user_display_name);a.pa=U(a.pa,b.user_gender)}
-function Px(a,b){var c;t:{if(b&&((c=b.adformat)||(c=(c=b.attrib)&&c in Gx&&c in Hx?Hx[c]+"_"+Gx[c]:void 0),c)){var d=c.match(/^(\d*)_((\d*)_?(\d*))$/);if(d&&5==d.length&&(d=d[3],d=6==d||7==d||8==d||9==d||10==d||11==d,pk(a.Q,mk)||d))break t}c=void 0}c&&(a.g=c,a.a.adformat=b.adformat);c=b.agcid;a.ib=c;a.a.agcid=c;c=b.feature;a.j=c;a.a.feature=c;if(c=b.referrer)a.referrer=c,a.a.referrer=c;"1"==b.enablecsi&&(a.pk=!1)}
-function Rx(a){var b={};b.c=a.eg;a.lf&&(b.cver=a.lf);a.O&&(b.cplatform=a.O);a.H&&(b.cbrand=a.H);a.G&&(b.cmodel=a.G);a.I&&(b.cnetwork=a.I);a.A&&(b.cbr=a.A);a.B&&(b.cbrver=a.B);a.K&&(b.cos=a.K);a.M&&(b.cosver=a.M);return b}
-function Mx(a,b){if(b){a.o=b.split(",");var c={};z(a.o,function(a){c[a]=!0});a.Oc=!!c["918108"];a.nd=!!c["912711"];a.jg=!!c["925900"];a.lj=!!c["913559"];a.nj=!c["904831"];a.Sa=!!c["913424"];a.ya=!!c["932206"];a.md=!!c["932217"];a.ve=!!c["932225"];a.Nc=!!c["932246"];a.Jc=!!c["932245"];a.ue=!!c["932240"];a.dg=!!c["932236"];a.Lc=!!c["932237"];a.mc=!!c["932242"];a.nc=!!c["932243"];a.oc=!!c["932247"];a.bg=!!c["932248"];a.za=!!c["932239"];a.Na=!!c["932249"];a.Ka=!!c["932250"];a.od=!!c["932251"];a.Mc=!!c["932252"];
-a.Qc=!!c["924604"];a.Kc=!!c["924610"];a.te=!!c["918117"];a.Ma=!!c["907231"]&&"leanback"!=a.Y;a.ia=!!c["938600"]}}
-function Sx(a,b){switch(b.pd){case 38:var c=b.L.indexOf(":"),d=b.L.slice(0,c),c=b.L.slice(c+1);return S("//play.google.com/books/volumes/"+d+"/content/media",{aid:c,sig:b.md});case 30:return d="//docs.google.com/",a.jb!=Lx.prototype.jb&&(d=a.jb),S(d+"get_video_info",{docid:b.L,authuser:b.Ea,authkey:b.Fn,eurl:a.b});case 33:return S("//google-liveplayer.appspot.com/get_video_info",{key:b.L});default:return d={html5:"1",video_id:b.L,cpn:b.Da,eurl:a.b,ps:a.Ca,el:a.Y,hl:a.i,list:b.Oa,agcid:a.ib,sts:15964},
-b.U?d.vvt=b.U:b.G&&(d.access_token=b.G),a.g&&(d.adformat=a.g),b.fa&&(d.iv_load_policy=b.fa),b.kf&&(d.autoplay="1"),b.Bk&&(d.mdx="1"),b.Ck&&(d.utpsa="1"),b.bb&&(d.is_fling="1"),c=Tx(a),c.width&&(d.width=c.width),c.height&&(d.height=c.height),b.ia&&(d.ypc_preview="1"),b.Qd&&(d.splay="1"),a.k&&(d.content_v=a.k),b.Gn&&(d.livemonitor=1),a.Ea&&(d.authuser=a.Ea),a.Ua&&(d.pageid=a.Ua),w(d,Rx(a)),S(a.jb+"get_video_info",d)}}
-function Qx(a){return a.Oh?"//s.youtubeeducation.com/":a.ag?"//s.youtube.com/":"//video.google.com/"}function Ux(a){return a.referrer?a.referrer.slice(0,128):""}
-function eu(a,b,c,d){b={v:b.L,list:b.Oa};a.Y&&(b.feature="player_"+a.Y);c&&w(b,c);a=S(a.protocol+"://"+("www.youtube-nocookie.com"==window.location.host||a.Oh?"www.youtube.com":window.location.host)+"/watch",b);if(d){c="";c="!"=="#".charAt(1)?"#".substr(0,2):"#";b="#";"#"==b.charAt(0)&&(b="!"==b.charAt(1)?b.substr(2):b.substr(1));b=Fj(b);for(var e in d)b[e]=d[e];d=c+Hj(b);a=a+d}return a}
-function Vx(a){var b={contact_type:"playbackissue",html5:1,plid:a.eb,ei:a.j,v:a.L};a.a&&(b.fmt=a.a.Pa);return S("//www.google.com/support/youtube/bin/request.py",b)}function Tx(a){return(a=a.Mj)?new B(a.clientWidth,a.clientHeight):new B(Number.NaN,Number.NaN)}function Bw(a){return a.Wa?new B(a.Wa.clientWidth,a.Wa.clientHeight):new B(Number.NaN,Number.NaN)}
-function Wx(a){var b={};if(!a.Wa)return b;a.Wa.webkitDecodedFrameCount&&(b.hmewdfc=a.Wa.webkitDecodedFrameCount,b.hmewdrop=a.Wa.webkitDroppedFrameCount,b.hmewvdbc=a.Wa.webkitVideoDecodedByteCount,b.hmewadbc=a.Wa.webkitAudioDecodedByteCount);a.Wa.mozParsedFrames&&(b.hmempf=a.Wa.mozParsedFrames,b.hmemdf=a.Wa.mozDecodedFrames,b.hmempresented=a.Wa.mozPresentedFrames,b.hmempainted=a.Wa.mozPaintedFrames,b.hmempaintdelay=a.Wa.mozPaintDelay);return b}
-function Xx(a){var b=n("yt.www.watch.activity.getTimeSinceActive",window);if("detailpage"==a.Y&&b)return b();var c;a.Ta&&(c=x()-a.Ta);return c}function oo(a){return"leanback"==a.Y||a.of||!a.wc&&!a.yl?!1:!0}function Dh(a){return"detailpage"!=a.Y?!1:!0}function Nx(a){a=ok()&&(pk(a.Q,lk)||pk(a.Q,mk));var b=pk(document.location.toString(),lk)&&!ok();return a||b}f.F=function(){this.Mj=this.Wa=null;Lx.C.F.call(this)};function Yx(){this.b=0;this.a=this.j=this.g=this.i=NaN}function Zx(a,b){for(var c=0;c<a.length;c++)if(a.start(c)<=b&&a.end(c)>=b)return a.end(c)-b;return 0};function $x(a){this.b=a;this.pendingRequests_=[];this.a=[];this.g=this.i=null;this.j=0}function ay(a,b){a.pendingRequests_.push(b);a.i=b.g[b.g.length-1];a.j+=b.T.length}function by(a){for(;a.pendingRequests_.length&&5==a.pendingRequests_[0].state;){var b=a.pendingRequests_.shift();z(b.o,a.H,a)}}
-$x.prototype.H=function(a){if(4==a.info.type){for(var b=Qk(a.info.a,a.info),c=[],d=a.a,e=0;e<b.length;e++){var g=kk(b[e].T.start+b[e].nb-a.info.T.start+a.T.start,b[e].Ha);c.push(new wk(b[e],a.buffer,g,d));d=!1}ab(this.a,c)}else 3==a.info.type&&this.a.push(a)};
-function cy(a,b,c){if(a.k)return a.a[0].T;var d=a.b.info.i;d&&0<b.H&&(c=Math.min(c,a.a[0].info.i+b.H));if(a.a[0].info.i>=c)return null;for(b=1;b<a.a.length;b++){var e=a.a[b].buffer!=a.a[b-1].buffer;if(a.a[b].info.i>c||e)break}b--;var e=a.a[b].T.end,g=a.a[b].info.k-c;if(d&&1<g){c=Math.floor(a.a[b].info.Ha*((c-a.a[b].info.i)/a.a[b].info.o));if(0==c)return null;e=a.a[b].T.start+c-1}return new ik(a.a[0].a?0:a.a[0].T.start,e)}
-function dy(a){a.pendingRequests_.length?a.i=Ga(a.pendingRequests_[a.pendingRequests_.length-1].g):a.a.length?a.i=Ga(a.a).info:a.i=a.g}function ey(a){return a.b.Yb()?a.b.index.g?a.b.index.b[a.b.index.R]:-1:NaN}function fy(a,b){a.b.Yb();a.i=a.b.Vj(b,0).a[0];a.g&&a.g.b&&(a.g=null);return a.i.startTime}
-function gy(a){hy(a);if(a.b.info.b&&a.g&&!a.g.g){var b=Pa(a.a,function(a){return a.info.g});a.a=cb(a.a,0,b+1);a.k=!0}else a.a=[];if(a.a.length)for(a.j=a.a[0].buffer.byteLength,b=1;b<a.a.length;b++)a.a[b].buffer!=a.a[b-1].buffer&&(a.j+=a.a[b].buffer.byteLength);else a.j=0}function iy(a){var b=!1,c;for(c=0;c<a.pendingRequests_.length;c++)if(7==a.pendingRequests_[c].state){b=!0;break}if(b){for(;c<a.pendingRequests_.length;)a.o(a.pendingRequests_.pop());dy(a)}}
-function jy(a){var b=a.g;a.a.length&&(b=Ga(a.a).info);b=a.i||b;return b.yg(b.T.length-(b.Ha+b.nb))}function ky(a){return La(a.a,function(a){return a.info.g})}function ly(a){return Na(a.pendingRequests_,function(a){return!(!a.b||1!=a.b.priority)&&!(4<=a.state)})}$x.prototype.o=function(a){sk(a.g[0])||a.dispose();this.j-=a.T.length};function hy(a){z(a.pendingRequests_,a.o,a);a.pendingRequests_=[];a.i=null};function my(a,b){this.state=1;this.g=b.a;this.k=a;this.o=null;this.T=uk(b.a);this.H=b.b;this.G=NaN;this.A=this.j=0;this.i=NaN;this.b=this.B=null;this.I=""}f=my.prototype;
-f.start=function(){var a=1==this.state,b=6==this.state;1==this.state||3==this.state||b&&ny(this);oy(this,2);if(b){if(this.j<this.k.o){this.j++;a=0.5+Math.random();H(v(this.qk,this),1E4*a);return}b=this.H;if(!(this.G<=b.g)){b.b++;b.g=Ak-1;var c;c=Ie(b.a).Se;var d=qk(b.a);b.a=Kj(d,{cmo:"pf="+b.b,shost:c})}this.j=0}a?this.qk():H(v(this.qk,this),0)};
-f.qk=function(){if(!this.ha()){this.G=Ak++;var a={};this.T&&(a.range=this.T.toString());a.keepalive="yes";4==this.g[this.g.length-1].type&&(a.fr="yes");a=S(this.H.a,a);this.j&&(a=le(pe(a,"playerretry"),"playerretry",this.j.toString()));this.I=a;var b={format:"RAW",method:"GET",responseType:"arraybuffer",withCredentials:!0,rd:v(this.zq,this)};this.a=Qj(a,b);this.A=0;this.b&&(a=this.b,a.a=x(),a.j=a.a,a.b=0,a.o=0,a.i=!1,a.k={wm:Th(a.g),yq:Uh(a.g),xq:Vh(a.g)},py(a),this.a.addEventListener("progress",
-v(this.Aq,this),!1),0<this.k.a&&!sk(this.g[0])&&(this.i=H(v(this.Jm,this),this.k.a)))}};f.Aq=function(a){if(!this.ha()){var b=this.b,c=a.timeStamp,d=a.loaded;c<b.a&&(c=x());if(!(20>c-b.j)){if(32768<d){qy(b,c);var e=(c-b.j)/1E3,g=d-b.b;if(0<g)if(0.2<e||1024>g)b.o+=e;else{var h=b.g,e=Math.max(e,0.05);h.a.b(e,g/e)}}b.j=c;b.b=d}this.b.b>this.b.A&&4>this.state&&oy(this,4);4==a.target.readyState&&ry(this.b,a.timeStamp)}};
-f.zq=function(a){if(!this.ha()&&a==this.a){this.i&&(I(this.i),this.i=NaN);var b=null==a.response||400<=a.status;if(!b){a=a.response;var c;t:{if(2048>a.byteLength&&(c=String.fromCharCode.apply(String,new Uint8Array(a)),pk(c,lk)))break t;c=""}if(c)a=this.H,c=pe(c,"keepalive"),c=pe(c,"playerretry"),c=pe(c,"range"),c=pe(c,"shost"),a.a=c,oy(this,3);else if(a.byteLength!=this.T.length)b=!0;else{c=this.g;if(1==c.length&&!c[0].T){var d;d=c[0];var e=kk(0,a.byteLength);d=new rk(d.type,d.a,e,d.j,d.startTime,
-d.duration,d.nb,e.length,d.b);c[0]=d}d=[];for(var e=0,g=!1,h=!1,k=0;k<c.length;k++){var m=c[k],p=a,s=kk(e,m.Ha),r=!1;if(1==m.type)a.slice?p=a.slice(e,e+m.Ha):(g=new Uint8Array(a,e,e+m.Ha),p=(new Uint8Array(g)).buffer),s=kk(0,m.Ha),g=!0;else if(3==m.type||4==m.type)r=g&&!h,h=!0;d.push(new wk(m,p,s,r));e+=m.Ha}this.o=d;oy(this,5)}}b&&(ny(this),oy(this,6))}};function ny(a){return a.j<a.k.o?!0:!(a.G>a.H.g&&1<=a.H.b)}function oy(a,b){a.state=b;3<=a.state&&a.B&&a.B(a)}
-f.Jm=function(){this.i=NaN;if(!this.ha()&&this.b){var a=!1;if(this.b.i){var b=this.b.H;py(this.b);this.b.H-b>=0.8*(this.k.a/1E3)?(this.A++,a=5<=this.A):this.A=0}else a=5<x()/1E3-(this.b.a/1E3+this.b.k.wm);a?(oy(this,7),sy(this),ry(this.b,Date.now())):this.i=H(v(this.Jm,this),this.k.a)}};f.ha=function(){return-1==this.state};f.dispose=function(){oy(this,-1);this.B=this.o=null;sy(this);I(this.i);this.i=NaN};function sy(a){if(a.a){var b=a.a;a.a=null;b.abort()}};function ty(a,b,c,d){this.priority=b;this.g=a;this.A=d;this.b=this.j=this.a=NaN;this.o=0;this.B=c;this.H=NaN;this.i=!1}function ry(a,b){b<a.a&&(b=x());qy(a,b);var c=a.g,d=a.b,e=a.o,d=Math.max(d,32768);c.g.b(1,e/d);c=a.g;d=b-a.a;e=a.b;isNaN(e)||(c.i+=e);isNaN(d)||(c.j+=d/1E3)}function py(a){var b=a.B-a.b,b=b*a.k.yq+b/a.k.xq,c=x()/1E3,b=a.i?b+c:b+Math.max(c,a.a/1E3+a.k.wm);a.H=b}function qy(a,b){a.i||(a.g.b.b(1,(b-a.a)/1E3),a.i=!0)};function uy(a,b,c,d){R.call(this);this.j=a;this.b=b;this.i=new $x(c);this.a=new $x(d);this.k=this.G=this.I=NaN;this.o=this.M=this.B=!1;this.A=NaN;this.O=!1}y(uy,R);var vy=2/24;f=uy.prototype;f.Es=function(a){this.g=a;a.Zb.appendBuffer&&(a.Zb.addEventListener("updateend",v(this.Vf,this),!1),a.ud.addEventListener("updateend",v(this.Vf,this),!1));wy(this)};
-function xy(a){a.g&&a.g.Zb&&a.g.Zb.removeEventListener&&(a.g.Zb.removeEventListener("updateend",v(a.Vf,a)),a.g.ud.removeEventListener("updateend",v(a.Vf,a)));a.g=null}function yy(a){if(0<a.b.j){var b=(a.i.b.info.a+a.a.b.info.a+12500)*a.b.j;if(0<a.b.i){if(b>a.b.i)return;b=a.b.i}b={cwndbw:(8*b/1024).toFixed(0)};Bk(a.i.b.j,b);Bk(a.a.b.j,b)}}function zy(a,b,c){c-=2;c-=c*b*Uh(a.j);c=Math.max(a.b.M,Math.min(a.b.P,c));a=Math.max(a.b.O,Math.ceil(a.b.M*b));return Math.min(a,Math.ceil(c*b))}
-function Ay(a,b){var c=Math.min(2.5,Th(a.j));return Math.ceil(b*c+32768)}function By(a){var b=Vh(a.j);a=Th(a.j)+1048576*Uh(a.j);return b*Math.min(1,1048576/(b*a))}
-function Cy(a,b){if(!b.i){if(!b.b.Yb())return;fy(b,a.k)}if(!(b.j>a.b.B)){var c=b.i;4==c.type&&c.a.Yb()&&(b.i=Ga(Qk(c.a,c)),c=b.i);if(!(c.b||!c.a.Oj(c)||c.a.info.i&&(4==c.type||a.a.i&&!a.a.i.b&&a.a.i.k<c.i))){var d=a.b.G;a.o&&0<a.b.b&&(d=Math.max(d,a.b.b/c.a.info.a));d=a.k+d;if(!(3==c.type&&c.k>d||2<=ly(b)+1)){var d=c.k-a.k,e=c.a.info.a,g=c.a.Yb()?zy(a,e,d):a.b.K,h=Ay(a,c.a.info.a),k=!1,e=!1;if(c&&3==c.type&&b.b.Yb()&&c.a!=b.b){var d=zy(a,b.b.info.a,d+(c.startTime+c.duration-c.k)),m=Ay(a,b.b.info.a),
-e=c.a.info.a<b.b.info.a;if(!e||d>=m)k=!0,g=d,h=m}d=h;0<g&&(d=Math.max(a.b.K,g,Math.min(2*g,h)));if(k){c=b.i?b.i.startTime+b.i.duration+vy:0;if(a.b.g&&e)t:{e=Th(a.j)+d*Uh(a.j)+d/Vh(a.j)+a.k+2,e=Math.min(e,c),e=Fk(b.b.index,e),e+1<b.b.index.hb()&&(c=b.b.index.b[e+1]),e=c;if(b.pendingRequests_.length){if(b.pendingRequests_[0].g[0].startTime<=e)break t;hy(b)}for(g=b.a.length-1;0<=g;g--)h=b.a[g],h.info.startTime>e&&(b.a.pop(),b.a.length&&b.a[g-1].buffer==h.buffer||(b.j-=h.buffer.byteLength));dy(b)}b.i&&
-!b.i.g&&(e=new my(a.b,jy(b)),Dy(a,e,!0),ay(b,e));b.i&&(c=b.i?b.i.startTime+b.i.duration+vy:0);d=new my(a.b,b.b.Vj(c,d))}else d=new my(a.b,c.yg(d));Dy(a,d,!1);ay(b,d)}}}}function Dy(a,b,c){c=c?2:1;a.b.Q&&(c=0);var d=Math.min(2.5,Th(a.j)),e=Vh(a.j);b.b=new ty(a.j,c,b.T.length,0.95*b.T.length-d*e);a=v(a.Pv,a);b.B=a;b.start()}
-f.Pv=function(a){if(!this.ha()){var b=6==a.state&&ny(a);3==a.state||b?(b&&this.u("softerror",209),a.start()):5==a.state?(this.K||(this.K=a.I),Ey(this),z(a.o,function(a){sk(a.info)&&a.info.a.Oo(a)}),Ma(a.o,function(a){return yk(a)})&&!a.g[0].a.Po()?wy(this):Fy(this,126)):7==a.state||4==a.state?(7==a.state&&this.u("softerror",210),wy(this)):Fy(this,121)}};
-function Ey(a){if(!a.O&&a.K&&window.performance&&window.performance.getEntriesByName){var b=window.performance.getEntriesByName(a.K);b.length&&(b=b[0],Gy("vrst",b.fetchStart),Gy("vdns",b.domainLookupEnd),Gy("vreq",b.requestStart),Gy("fvb",b.responseStart),a.O=!0)}}function wy(a){isNaN(a.I)&&(a.I=H(v(a.Vf,a),0))}function Hy(a){isNaN(a.G)&&(a.G=H(v(function(){this.Vf();this.G=NaN},a),1E3))}
-f.Vf=function(){this.I=NaN;if(!this.M&&this.g){var a=Math.floor(Math.max(ey(this.i),ey(this.a)));isNaN(a)||(this.g.Va(a),this.M=!0)}if(!this.ha())if("prerender"==window.document.webkitVisibilityState)Hy(this);else{this.g&&this.g.Ib()&&xy(this);by(this.a);by(this.i);iy(this.a);iy(this.i);a=!1;if(this.g){var a=Iy(this,this.a,this.g.ud),b=Jy(this.g.ud,this.k);if(!isNaN(b)||this.a.g&&this.a.g.b)this.a.g&&this.a.g.b&&(b=NaN),a|=Iy(this,this.i,this.g.Zb,b);if(this.a.g&&this.a.g.b&&this.i.g&&this.i.g.b&&
-!this.g.Zb.updating&&!this.g.ud.updating&&this.g.isOpen()){a=this.g;a.isOpen()&&a.g.endOfStream();return}}this.om();Cy(this,this.a);Cy(this,this.i);a&&(this.g.Zb.appendBuffer||wy(this))}};f.om=function(){if(!this.ha()&&!isNaN(this.b.A)){var a=By(this);!isNaN(this.A)&&Math.abs(this.A-a)/a<this.b.A||(Math.round(a/1024),Math.round(this.A/1024),this.u("bandwidthchange",a),bg("yt-player-bandwidth",{byterate:a},2592E3),this.A=a)}};
-function Iy(a,b,c,d){if(c.updating)return!0;var e=b.a.length?b.a[0]:null;if(!e)return!1;!b.g||b.g.g||tk(b.g,e.info)||(b.g=null,a.g.isOpen()&&c.abort(),c.g=null);var g;e.info.a.Yb();e.a?g=!1:(g=e.info.a.b,c.g==g?g=!1:(Ky(a,c,g),c.g=g,g=!0));if(g&&c.updating)return!0;g=a.b.I;a.o&&0<a.b.b&&(g=Math.max(g,a.b.b/b.b.info.a));g=a.k+g;0<=d&&(g=Math.min(g,d));d=cy(b,a.b,g);if(!d)return!1;g=new Uint8Array(e.buffer,d.start,d.length);if(!Ky(a,c,g))return!1;for(var h;b.a.length;){if(b.a[0].T.end>d.end){h=b.a[0];
-var k=d.end-b.a[0].T.start+1,k=Math.min(k,h.info.Ha);g=new rk(h.info.type,h.info.a,h.info.T,h.info.j,h.info.startTime,h.info.duration,h.info.nb,k,!1);a=kk(h.T.start,k);g=new wk(g,h.buffer,a,h.a);k=new rk(h.info.type,h.info.a,h.info.T,h.info.j,h.info.startTime,h.info.duration,h.info.nb+k,h.info.Ha-k,h.info.b);a=new ik(a.end+1,h.T.end);a=[g,new wk(k,h.buffer,a,!1)];h=a[0];b.a[0]=a[1]}else h=b.a.shift();a=b;a.g=h.info;a.k&&a.g.g&&(a.k=!1);if(h.T.end==d.end)break}b.a.length&&h.buffer==b.a[0].buffer||
-(b.j-=h.buffer.byteLength);e.a&&(c.g=e.info.a.b);return!c.appendBuffer||c.updating}function Ky(a,b,c){if(b.appendBuffer)try{b.appendBuffer(c)}catch(d){return!1}else b.append(c);return!a.g.Ib()}function Jy(a,b){for(var c=0;c<a.buffered.length;c++)if(a.buffered.start(c)<=b&&a.buffered.end(c)>=b)return a.buffered.end(c);return NaN}function Ly(a,b){if(!a.ha()){var c=My(a,a.a,b,a.g&&a.g.ud),d=My(a,a.i,c,a.g&&a.g.Zb);a.k=Math.max(b,c,d);a.B=!0;wy(a)}}
-function My(a,b,c,d){if(b.b.Yb())if(d){if(a.o&&a.b.g)return gy(b),fy(b,c);var e=Jy(d,c),g=NaN,h=b.g;h&&(g=Jy(d,h.a.index.b[h.j]));if(e==g)return c;gy(b);b.b.info.b&&b.g&&!b.g.g&&!ky(b)&&(d=new my(a.b,jy(b)),Dy(a,d,!0),ay(b,d));if(isNaN(e))return fy(b,c);fy(b,e+vy)}else fy(b,c);else b.b.i?0!=c&&hy(b):Ny(a,b,!1);return c}
-function Ny(a,b,c){var d=c?65536:0;c&&!isNaN(a.b.k)&&(d=Math.floor(Math.max(d,a.b.k*b.b.info.a)));c=b.b.po(d);z(c,function(a){var c=new my(this.b,a);Dy(this,c,!0);!sk(a.a[a.a.length-1])&&ay(b,c)},a);b.b.i=!0}f.F=function(){xy(this);hy(this.i);hy(this.a);this.a=this.i=null;uy.C.F.call(this)};function Fy(a,b){a.u("fatalerror",b);if(a.g&&a.g.isOpen()){var c=a.g;c.isOpen()&&c.g.endOfStream("network")}a.dispose()}function Gy(a,b){var c;b&&(c=window.performance.timing.navigationStart+b);os(a,c)};function Oy(){this.H=2;this.I=30;this.G=40;this.b=NaN;this.B=20971520;this.M=this.k=2;this.K=131072;this.P=15;this.O=2097152;this.A=0.1;this.o=2;this.g=!0;this.a=1800;this.i=this.j=NaN};function Py(a,b,c){this.a=a;this.headers=b;this.message=c};function Qy(a,b,c,d,e,g,h){this.a=[];this.g=a;this.k=b.g;this.j=b;this.i=c;this.G=d;this.I=e;this.b=[];this.K=h||null;this.B=this.M=!1;this.A=null;this.o=!0;this.H={};this.listen(this.g,["keymessage","webkitkeymessage"],this.zj);this.listen(this.g,["keyadded","webkitkeyadded"],this.sq);this.listen(this.g,["keyerror","webkitkeyerror"],this.tq);g&&this.b.push(g)}y(Qy,Kl);function Ih(a,b){if(pk(b,lk)){for(var c in a.H)b=le(pe(b,c),c,a.H[c]);a.k=b}else Ry(a,"u")}f=Qy.prototype;
-f.start=function(){this.ha()||(this.M=!0,this.b.length&&this.zj(this.b.shift()))};f.dispose=function(){Qy.C.dispose.call(this);this.I=this.g=null};f.zj=function(a){this.ha()||a.sessionId!=this.i||(this.B&&a.defaultURL&&Ih(this,a.defaultURL),this.M?(this.A=a,Sy(this,a)):this.b.push(a))};f.sq=function(a){this.ha()||a.sessionId!=this.i||(this.B=!0,this.b.length&&this.zj(this.b.shift()))};
-function Sy(a,b){var c={format:"RAW",method:"POST",Lw:b.message,responseType:"arraybuffer",withCredentials:!0,Qa:a.Mw,onError:a.Qn,Z:a};a.K&&(c.headers={Authorization:"Bearer "+a.K});var d=a.k;a.o||(d=le(pe(d,"exclude_customdata"),"exclude_customdata","1"));Qj(d,c)}
-f.Mw=function(a){if(!this.ha())if(0!=a.status&&a.response){t:{a=new Uint8Array(a.response);var b=0,c=String.fromCharCode.apply(String,a.subarray(0,16384)).split("\r\n"),d=c[0];Xa(c,0);c.pop();var b=b+(d.length+2),e=d.match(/^GLS\/1.\d ([0-9]{1,3}) (\w+)$/);if(null!=e){d=e[1];isFinite(d)&&(d=String(d));for(var d=u(d)?/^\s*-?0x/i.test(d)?parseInt(d,16):parseInt(d,10):NaN,g={},h=0;h<c.length;h++){e=c[h];b+=e.length+2;if(0==e.length){a=new Py(d,g,a.subarray(b));break t}e=e.match(/([^:]+):\s+([^]+)/);
-if(null==e)break;g[e[1]]=e[2]}}a=null}0!=a.a?(b=ax[a.a.toString()],Ry(this,"f"+a.a,b?b:"ERROR_LICENSE")):(a=a.message,this.g.addKey?this.g.addKey(this.j.a,a,this.G,this.i):this.g.webkitAddKey(this.j.a,a,this.G,this.i))}else this.Qn(a)};f.tq=function(a){this.ha()||a.sessionId!=this.i||("playready"==this.j.b&&a.errorCode==a.MEDIA_KEYERR_UNKNOWN&&2==a.systemCode&&this.o?(this.o=!1,Sy(this,this.A)):Ry(this,"s"+a.errorCode.code+"."+a.systemCode))};f.Qn=function(a){Ry(this,"r"+a.status)};
-function Ry(a,b,c){a.ha()||a.I(b,c);a.dispose()};function Ty(a,b,c,d){this.a=[];this.b=a;this.g=b;this.B=c;this.o=d;this.A=null;this.j={};this.H={};this.i=null;this.k=[];this.listen(this.b,["needkey","webkitneedkey"],this.G);this.listen(this.b,["keymessage","webkitkeymessage"],this.K);this.listen(this.b,["keyerror","webkitkeyerror"],this.I)}y(Ty,Kl);Ty.prototype.dispose=function(){Ty.C.dispose.call(this);this.b=null;Eb(this.j,function(a){a.dispose()})};
-Ty.prototype.G=function(a){a=a.initData;if(!this.i&&Kb(this.j)||"widevine"!=this.g.b){var b=String.fromCharCode.apply(String,a);if(!this.H[b]){this.H[b]=!0;b="clearkey"==this.g.b;if(112==a[4]&&115==a[5]&&115==a[6]&&104==a[7]&&b){t:{for(var c=new DataView(a.buffer),b=0;b<c.byteLength;){var d=c.getUint32(b,!1);if(1886614376!=c.getUint32(b+4,!1))break;if(1477738184==c.getUint32(b+12,!1)&&69420633==c.getUint32(b+16,!1)&&2464609580==c.getUint32(b+20,!1)&&1558758348==c.getUint32(b+24,!1)){c=c.getUint32(b+
-28,!1);if(16!=c)break;a=a.subarray(b+32,b+32+c);break t}b+=d}a=null}if(!a)return}this.i?this.k.push(a):Uy(this,a)}}};function Uy(a,b){if(!a.ha()){try{a.b.generateKeyRequest?a.b.generateKeyRequest(a.g.a,b):a.b.webkitGenerateKeyRequest(a.g.a,b)}catch(c){var d="g";c instanceof DOMException&&(d+=c.code);a.o(d,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",!0);return}a.i=b}}
-Ty.prototype.K=function(a){if(!this.ha()&&this.b&&!this.j[a.sessionId]){var b=new Qy(this.b,this.g,a.sessionId,this.i,this.o,a,this.A);this.j[a.sessionId]=b;this.i=null;this.B(b);this.k.length&&Uy(this,this.k.shift())}};Ty.prototype.I=function(a){!this.ha()&&this.b&&(this.j[a.sessionId]||this.o("s"+a.errorCode.code+"."+a.systemCode))};function Vy(a,b,c,d){this.ka=a;this.a=b;this.g=c;this.b=d};function Wy(a){this.a=a}function Xy(a,b){var c=b.mf;return c&&c&&"unknown"!=c?c:(c=a.a.Kh)&&c&&"unknown"!=c?c:"auto"}
-function Yy(a,b,c){var d,e=Xy(a,b);if(e&&"auto"!=e&&(d=null,e=gk.indexOf(e),0<=e))for(;e<gk.length&&!(d=vm(b,gk[e]));e++);if(!d){d=b.k;var g;a.a.Tc?(e=a.a.Tc.clone(),Ri&&!a.a.Dh&&(e=(window.screen&&window.screen.width?new B(window.screen.width,window.screen.height):null)||e),e.scale(Ri||Wb?window.devicePixelRatio||1:1),g=a.a.Jh||e):g=a.a.Jh;t:{e=a=0;null!==g&&(a=g.width,e=g.height);g=16/9;a>Math.round(g*e)&&(a=Math.round(g*e));a*=e;g=null;for(e=0;e<d.length;e++){g=d[e];var h=g.getInfo(),h=h.b.width*
-h.b.height*("medium"==g.We()?0.26:0.85)>a,k=!0;g.a&&c&&(k=g.b.info.a+g.g.info.a<c);if(!h&&k){c=g;break t}}c=g}c||(c=b.k[0]);d=c}return d};function Zy(){this.b=this.a=NaN}function $y(a,b,c){if(a.a==b)return 500<c-a.b;a.a=b;a.b=c;return!1};var az=[102,107,108];var dh=[0.25,0.5,1,1.5,2];function bz(a,b){this.state=a;this.a=b}function Ro(a,b){return P(a.state,b)&&!P(a.a,b)?1:!P(a.state,b)&&P(a.a,b)?-1:0};function cz(a,b){R.call(this);this.ja=new Zy;this.A=new xj(v(this.getCurrentTime,this),v(this.rq,this),v(this.ig,this));L(this,this.A);this.O=NaN;this.P=this.I=null;this.o=a;this.va=new Wy(a);this.ia=NaN;this.ga=!1;this.g=this.k=null;this.Q=[];this.U=!1;this.fa=NaN;this.i=new sj;this.B=b;this.K=this.X=null;this.G=NaN;this.M=new Uo(this);this.b=this.a=null;this.aa=NaN;this.j=null}y(cz,R);f=cz.prototype;
-f.F=function(){I(this.aa);I(this.ya);hf(this.fa);dz(this);Cn(this);Tg(this.k,this.K,this.M,this.a);this.a=this.M=this.i=this.k=this.P=this.ja=null};
-function ez(a,b){a.U=!1;a.O=NaN;a.b&&mj(a.b);fz(a);dz(a);Tg(a.k,a.a);a.k=null;a.A.reset();if(2==a.B||pk(a.o.Q,mk))b.X=!1,b.In=!0;a.a=b;a.a.D("dataupdated",a.bu,a);a.a.D("dataloaded",a.au,a);a.a.D("onStatusFail",a.Zt,a);if(b.rf&&b.rf>b.xa){var c=b.rf;a.P&&(a.$h(a.pa),a.pa=null);a.P=new Zh(1E3*c,2147483646);a.P.zb.D("onEnter",a.ng,a);a.Kk(a.P)}gz(a,"newdata")}function dz(a){hf(a.ia);a.j&&(Sg(a.j),a.j=null)}f.getVideoData=function(){return this.a};f.J=function(){return this.o};
-function hz(a){return!(!a.a||!a.a.k.length)}function iz(a){if(a.a&&(a.a.L||a.a.nf))return!0;hx(a,2);return!1}function jz(a){a.U||(kz(a,uj(new sj,8)),a.j&&lz(a.j),a.U=!0,!iz(a)||a.a&&a.a.Ze||mz(a,v(function(){if(hz(this))nz(this);else if(!this.a.Ze)if(oz(this))nz(this);else{var a=Sx(this.o,this.a);Am(this.a,a)}},a)))}function pz(a){if(!a.Q.length){if(!a.A.vg){var b=a.A;b.g=Cj(b);b.vg=!0;b.Xb()}a.Q.length||0<Ii(a.A.b,-2147483648).length||a.u("playbackready",a)}}
-f.Tq=function(){var a=this.j,b=this.a.bk;a.U!=b&&(qz(a,{metric:"heartbeat",tpmt:this.a.Ce}),a.U=b)};function nz(a){a.Q=$a(a.a.I);a.a.cb&&(rz(a,a.a.ta),sz(a,!0));fh(a,"i");a.u("playbackdataloaded")}f.ng=function(a){tz(this);kz(this,!1==a?new sj:new sj(wj()))};function Bh(a,b,c){b={event:"streamingerror",ec:b,v:a.a.L};c&&(b.em=c);w(b,Rx(a.o));a.j&&uz(a.j,b,void 0)}function hx(a,b,c,d){if(Ib($w,c))var e=c;else var g=c;kz(a,tj(a.i,128,{errorCode:b,errorDetail:d,message:g,messageKey:e}))}
-function vz(a,b){a.Q=a.Q.filter(function(a){return b!=a});pz(a)}f.ig=function(){return P(this.i,8)&&!P(this.i,64)&&!P(this.i,2)};function oz(a){return!(!a.a||!a.a.L&&!a.a.nf||a.a.L)}f.rq=function(){return this.i};function wz(a,b){a.b&&Cn(a);a.b=b;xz(a)}function Cn(a){a.g=null;a.b&&(fz(a),a.M.removeAll(),mj(a.b),a.b=null)}
-function yz(a){if(a.b){var b=wm(a.a);if(a.a.o&&a.a.o.a){var c=a.a.o,b=c.g,c=c.b;a.g||(a.g=new Ll(a.b,a.a.ta,b.info.lb,c.info.lb),b=a.g,b.b||(b.b=b.g.mn?b.g.a.webkitMediaSourceURL:window.URL.createObjectURL(b.g)),a.za=new Rl(b.b,!1,!0),b=v(a.k.Es,a.k),a.g.j=b);b=a.za}a.b.Bd!=b?zz(a,b):(P(a.i,64)&&kz(a,uj(a.i,8)),kj(a.b),a.a.Fb&&!a.a.cb&&Az(a,Infinity))}}
-function fh(a,b,c){if(!a.ha()&&hz(a)&&!P(a.i,128)){var d="m"==b,e="m"==a.a.od;if(d||!e){d&&"auto"==c&&(b="a",d=!1);c&&(a.a.mf=c);var g=NaN;!a.X||a.o.ya||a.o.yh||(g=a.k?By(a.k):Vh(a.X),"i"==b&&(g=a.o.Jc?0.4*g:0.6*g));var h=Yy(a.va,a.a,g),g=h.getInfo(),k=h.a?h.b.info:g;if(a.a.a!=g||a.a.pa!=k||d!=e){a.a.o=h;a.a.a=g;a.a.pa=k;a.a.od=b;c&&(a.a.mf=c);if(h.a)if(a.k){var m=a.k,h=h.g;c=d;m.ha()||(m.o=c,m.a.b!=h&&(m.a.b=h,yy(m),c&&gy(m.a),h.i||Ny(m,m.a,!1),wy(m)))}else{c=a.o;e=new Oy;if(c.ya||c.yh)e.A=NaN;c.md&&
-(e.o=0);c.ue&&(e.k=3);c.Ul&&(e.M=1,e.K=49152);c.Lc&&(e.P=30);c.dg&&(e.a=700);c.mc&&(e.j=3);c.nc&&(e.j=1.5,e.i=1048576);c.od&&(e.b=62914560);c.Mc&&(e.H=NaN);"play"==c.Ca&&(e=Lb(e),e.I=10,e.G=20,e.b=NaN,e.B=10485760,e.O=1048576,e.g=!1,c.bg&&(e.g=!0));Ui&&cj("crkey")&&(c=Lb(e),c.k=3.5,c.I=20,c.G=40,c.B=20971520,c.g=!0,c.a=700,c.o=2,e=c);c=e;a.a.Ta&&(c.a=NaN);a.k=new uy(a.X,c,h.b,h.g);a.k.D("bandwidthchange",a.oq,a);a.k.D("fatalerror",a.pq,a);a.k.D("softerror",a.qq,a);h=a.k;c=(c=a.a.xa)||0;yy(h);0==c&&
-(h.a.b.i||Ny(h,h.a,!0),h.i.b.i||Ny(h,h.i,!0));Ly(h,c);Gy("gv");H(v(h.om,h),0);t:{for(m in Ml)if(!!Ol(m)!=Ml[m]){m=!1;break t}m=!0}m||Bh(a,211)}else a.ig()&&yz(a);m=b;a.j&&(h=Yy(a.va,a.a),b=a.j.i,g=new Vy(a.a,g,m,h.ye.Pa),Bz(b,"vfs",[g.a.Pa,g.b,b.A,g.g]),b.A=g.a.Pa,g=Bw(b.a),0<g.width&&0<g.height&&Bz(b,"view",[Math.round(g.width),Math.round(g.height)]),Bz(b,"vps",[b.g]),b.mg());a.u("internalvideoformatchange",a.a,d)}}}}f.oq=function(){fh(this,"a")};f.pq=function(a){hx(this,a)};
-f.qq=function(a){Bh(this,a);if(this.j)this.j.onError(a)};function tz(a){P(a.i,64)&&kz(a,tj(a.i,a.i.b&-9));a.b&&a.b.pause()}
-function Az(a,b,c,d){if(a.b){if(a.b){b=b||0;var e=1>a.b.seekable.length?NaN:a.b.seekable.end(a.b.seekable.length-1);a.k&&!isNaN(Math.floor(Math.min(ey(a.k.i),ey(a.k.a))))&&(e=Math.floor(Math.min(ey(a.k.i),ey(a.k.a))));b>e&&(b=e,sz(a,!0));0>b&&(b=0)}else b=0;a.a.xa=b;a.G=b;c?a.ti():(Cz(a),d&&(a.K||(a.K=new Xo(a.ti,d,a)),a.K.start()),Dz(a,!0));a.P&&b>a.a.rf&&(a.$h(a.pa),a.pa=null);a.u("seekto",a,b)}else a.a.xa=b||0}function Cz(a){P(a.i,32)||(kz(a,uj(a.i,32)),P(a.i,8)&&tz(a),a.u("beginseeking",a))}
-f.ti=function(){if(!isNaN(this.G)&&this.b){var a=this.qd();!this.a.Fb&&this.G>=Math.floor(a)?(this.G=a,this.u("endseeking",this),tz(this),this.ng()):(this.k&&Ly(this.k,this.G),ij(this.b,this.G))}this.K&&(this.K.dispose(),this.K=null);P(this.i,32)&&(kz(this,tj(this.i,this.i.b&-33)),this.u("endseeking",this))};f.getCurrentTime=function(){if(!isNaN(this.G))return this.G;var a=0;this.b?a=this.b.getCurrentTime():this.a&&(a=this.a.we);return a};
-f.qd=function(){var a=0;this.b&&(a=this.b.Vd);0==a&&this.a&&(a=this.a.ta);return a};f.Dq=function(){var a=new Yx;if(this.X){var b=this.X;a.g=b.i;a.j=b.j;a.a=Vh(b)}this.k?(b=this.k,b.g&&(a.b=Zx(b.g.ud.buffered,b.k),a.i=Zx(b.g.Zb.buffered,b.k)),a.a=By(b),Vh(b.j),Th(b.j),Uh(b.j)):this.b&&(a.b=Zx(this.b.buffered,this.getCurrentTime()));return a};function Ez(a,b){var c=isNaN(b)?a.getCurrentTime():b,d=a.qd();return Infinity==d?1:d?c/d:0}
-f.Fq=function(){var a;if(this.a){a=this.a;var b={};a.a&&(b.fmt=a.a.Pa,a.pa&&(b.afmt=a.pa.Pa));a.Q&&(b.threed=a.Lc);b.plid=a.eb;b.ei=a.j;b.list=a.Oa;b.cpn=a.Da;a.L&&(b.v=a.L);a.Fj&&(b.infringe=1);a.Qd&&(b.splay=1);a.Fb&&(b.live=a.cb?"dvr":"live");a.kf&&(b.autoplay=1);a.ja&&(b.sdetail=a.ja);a.pd&&(b.partnerid=a.pd);a=b}else a={};return a};
-function Fz(a,b){var c={};if(b){if(a.j){var d=Gz(a.j);d&&w(c,d.Uh())}a.b&&w(c,{vct:a.b.currentTime.toFixed(3),vd:a.b.duration.toFixed(3),vpl:pj(a.b.played),vbu:pj(a.b.buffered),vpa:a.b.paused,vsk:a.b.seeking,vpr:a.b.playbackRate,vrs:a.b.readyState,vns:a.b.networkState,vec:a.b.error?a.b.error.errorCode:null});if(a.k){var d=a.k,e={lct:d.k.toFixed(3),lsk:d.B,lmf:d.o,lbw:Vh(d.j).toFixed(3),lhd:Th(d.j).toFixed(3),ltd:Uh(d.j).toFixed(3),laa:d.i.g?vk(d.i.g):"",lva:d.a.g?vk(d.a.g):"",lar:d.i.i?vk(d.i.i):
-"",lvr:d.a.i?vk(d.a.i):""};d.g&&!d.g.Ib()&&(e.lab=pj(d.g.Zb.buffered),e.lvb=pj(d.g.ud.buffered));w(c,e)}P(a.i,384)&&(c.debug_error=a.i.a)}c.debug_videoId=a.a.L;return c}f.Kk=function(a){this.A.nx(a)};f.$h=function(a){this.A.ox(a)};f.au=function(a){this.u("commoninfoloaded",a);gz(this,"dataloaded");mz(this,v(function(){this.U&&nz(this)},this))};f.bu=function(){gz(this)};f.Zt=function(a){hx(this,parseInt(a.errorcode,10),unescape(a.reason),a.errordetail)};
-function gz(a,b){a.u("internalvideodatachange",b||"dataupdated",a,a.a)}function mz(a,b){if(hz(a))a.o.Na?b():H(b,0);else{var c=a.a,d=a.o.Nh;c.B?rm(c,b,!!d,!("play"==a.o.Ca&&!a.o.Na)):tm(c,b,!!d)}}function xz(a){z("loadstart loadeddata loadedmetadata play playing pause ended suspend progress seeking seeked timeupdate durationchange error waiting abort".split(" "),function(a){this.M.listen(this.b,a,this.Vv)},a)}
-f.Vv=function(a){var b=a.target;if(b.currentSrc){switch(a.type){case "durationchange":this.a.cb||(b.Va(b.duration||0),b=b.Vd,(!this.g||isFinite(b)&&0<b)&&rz(this,b));break;case "ended":kz(this,tj(this.i,4));break;case "loadedmetadata":this.a.xa&&(this.b.currentTime=this.a.xa),this.o.qm&&this.a.xa&&(this.O=this.a.xa,this.b.pause());case "loadeddata":this.aa&&I(this.aa);break;case "loadstart":hf(this.fa);this.fa=gf(v(this.rn,this),100);var b=this.M,c=this.b,d=v(this.rn,b.Og),c=tf(c,d);b.ee.push(c);
-break;case "progress":this.O&&this.b.seekable.length&&this.b.seekable.end(0)>this.O&&(this.b.currentTime=this.O,this.O=NaN,this.ma=this.M.listen(this.b,"canplay",this.Is));case "suspend":Dz(this);this.u("onLoadProgress",this,this.b?hh(this.b):0);break;case "seeking":Hz(this);break;case "timeupdate":Hz(this),Dz(this),this.u("onVideoProgress",this,b.getCurrentTime())}this.u("videoelementevent",a);t:if(b=this.i,d=this.ja,P(b,128))a=b;else{var c=b.b,e=b.a,g=a.target;switch(a.type){case "ended":if(0>=
-g.networkState)break;c=wj();e=null;break;case "pause":P(b,32)||P(b,2)||(c=4,P(b,1)&&P(b,8)&&(c|=1),e=null);break;case "playing":c=8;e=null;break;case "abort":if(64==c)break;case "error":c|=256;a=g.error;d=107;if(a&&a.code)switch(a.code){case a.MEDIA_ERR_ABORTED:d=200;break;case a.MEDIA_ERR_NETWORK:d=201;break;case a.MEDIA_ERR_DECODE:d=202;break;case a.MEDIA_ERR_SRC_NOT_SUPPORTED:d=203}e={errorCode:d};Sa(rj,e.errorCode)&&(c|=128);break;case "canplay":c&=-2;break;case "progress":P(b,8)&&(g=a.target.getCurrentTime(),
-d&&$y(d,g,a.timeStamp)&&(c|=1));break;case "seeked":c&=-18;break;case "seeking":c|=16;g.inUnbufferedArea()&&(c|=1);c&=-3;break;case "waiting":P(b,2)||(c|=1);break;case "timeupdate":P(b,16)||(c&=-2);c&=-65;break;default:a=b;break t}a=tj(b,c,e)}kz(this,a)}};
-f.rn=function(){if(this.b&&0<this.b.getCurrentTime()&&0<this.b.Vd&&!this.a.Sm){hf(this.fa);this.a.Sm=!0;if(this.j){var a=this.j;if(!a.g){var b=Gz(a,"playback");a.a.lm&&(a.M=[10+a.a.cg,10,10,40+a.a.xh-a.a.cg,40],hf(a.I),a.I=NaN,a.I=gf(v(a.ja,a),100),b.gg=Iz(a,!0));b.hg=!0;b.A=a.j();b.send();if(a.b.Rc&&!a.g){var b=a.b,c=a.a,b={noflv:"1",html5:"1",video_id:c.L,cpn:c.Da,plid:c.eb,ei:c.j,referrer:Ux(b),eurl:b.b,framer:b.P,feature:b.j,fmt:c.a?c.a.Pa:0,ptk:c.A,skl:c.nm,access_token:c.G,ucid:c.Kc};w(b,Jz(a));
-b=S(a.b.jb+"user_watch",b);Qg(b)}a.a.A&&Qg(S(a.b.jb+"ptracking",{html5:"1",video_id:a.a.L,cpn:a.a.Da,plid:a.a.eb,ei:a.a.j,ptk:a.a.A,oid:a.a.oc,ptchn:a.a.ib,pltype:a.a.mc,content_v:a.b.k}));if(a.a.km&&a.b.Be&&!a.g){var b=a.b,c=a.a,d={noflv:1,video_id:c.L,cpn:c.Da,el:b.Y,ps:b.Ca,referrer:Ux(b),eurl:b.b,framer:b.P,fmt:c.a?c.a.Pa:0,ptk:c.A,subscribed:c.g,t:c.nd};b.Ub&&(d.autoplay="1");c.Qd&&(d.splay="1");0<c.xa&&(d.start=1E3*c.xa);c.rj&&(d.tmi="1");b=S(a.Q,d);Qg(b)}a.a.kg&&qz(a,{metric:"playback"});a.g=
-!0}}hf(this.ia);this.a.kg&&(this.j.g||this.a.jm)&&(this.ia=gf(v(this.Tq,this),3E4));this.u("playbackstarted")}};f.Is=function(){this.ma&&(this.M.dc(this.ma),this.ma=void 0,kj(this.b))};
-function Dz(a,b){if(a.b){var c=a.getCurrentTime();if(a.k){var d=a.k;if(!d.B||d.k<=c&&c<d.k+10)d.k=c,d.B=!1;Hy(d)}a.a.cb&&c>a.qd()&&(d=a.qd(),0==d&&(d=c),rz(a,1.2*d));var d=Ez(a),e=0;a.b.buffered&&0<a.b.buffered.length&&(a.a.cb?a.ga||(e=(1>a.b.seekable.length?NaN:a.b.seekable.end(a.b.seekable.length-1))/a.qd()):e=a.b?hh(a.b):0);5<c&&(a.a.xa=c);a.ya&&I(a.ya);a.b.paused||a.b.ended||(a.ya=a.b.played&&0==a.b.played.length?H(v(a.ln,a),100):H(v(a.ln,a),1E3));a.a.we=c;if(!b&&a.ig()){var g=a.a.bk,h=a.a.we;
-0<g&&h>g&&(a.a.Ce+=h-g);a.a.ta&&a.a.K&&a.a.Ce>=a.a.K&&(g=a.j,g.g&&g.a.K&&(h=Gz(g,"delayplay"),h.jj=!0,h.A=g.j(),h.send()),a.a.K=NaN)}if(a.a.im&&(g=a.a.gk,h=a.a.we,1==g&&0<h||2==g&&20<=h||3==g&&30<=h)){g=a.j;if(g.g){var h=g.b,k=g.a,g={ns:"yt",html5:"1",docid:k.L,plid:k.eb,ei:k.j,cpn:k.Da,fmt:k.a?k.a.Pa:0,el:h.Y,ps:h.Ca,subscribed:k.g,yttk:"1",st:g.j(),et:g.j(),ctp:k.gk,vid:h.aa},g=S("//s2.youtube.com/s",g);Qg(g)}a.a.gk++}a.u("progresssync",a,c,d,e,b);a.a.bk=c}}
-f.ln=function(){this.b&&(this.b.kp(),P(this.i,8)&&$y(this.ja,this.getCurrentTime(),Date.now())&&kz(this,uj(this.i,1)),Dz(this))};
-function kz(a,b){if(b.b!=a.i.b||b.a!=a.i.a){var c=new bz(b,a.i);a.i=b;a.o.qg&&P(b,8)&&0<Ro(c,256)&&201==b.a.errorCode&&setTimeout(v(function(){this.b&&(this.a.o&&!this.a.o.a&&this.b.load(),yz(this))},a),500);0>Ro(c,8)&&sz(a,!1);0<Ro(c,32)&&sz(a,!1);a.a&&a.a.Fb&&a.a.cb&&P(c.state,2)&&(rz(a,a.getCurrentTime()),Dz(a,!0));P(b,256)&&Kz(a,b);a.j&&Lz(a.j,c);Aj(a.A,c);a.u("statechange",c)}}
-function Kz(a,b){var c=b.a;hf(a.ia);if(a.a&&a.a.kg&&Sa(az,c.errorCode)){var d=a.j,c=c.errorCode;d.X||(d.X=new ao("error-__ec__"));c={metric:fo(d.X,{ec:c})};qz(d,c)}}function Hz(a){P(a.i,2)||P(a.i,32)||(a.G=NaN)}function sz(a,b){a.a&&a.a.cb&&a.ga!=b&&(a.ga=b,a.u("liveviewshift",b))}function zz(a,b){a.o.za&&oj(a.b,b.a||pk(b.b,lk));gj(a.b,b);a.g&&!b.a&&(a.g=null);a.a.a&&a.a.a.g&&Mz(a);I(a.aa);a.aa=H(v(a.ru,a),15E3);a.o.sm?H(v(function(){kj(this.b)},a),0):kj(a.b)}
-function Mz(a){var b=a.a.a&&a.a.a.g||null;b&&!a.I&&a.b&&((b=Fl(a.b,a.a.a.lb,b))?(a.I=new Ty(a.b,b,v(a.pu,a),v(a.ou,a)),a.I.A=a.a.G,L(a,a.I)):hx(a,203,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK"))}function fz(a){a.I&&(a.I.dispose(),a.I=null)}f.pu=function(a){var b=Rx(this.o);b.cpn=this.a.Da;this.a.U&&(b.vvt=this.a.U);Ob(a.H,b);Ih(a,a.k);this.u("newlicensesession",a)};f.ou=function(a,b,c){hx(this,c?5:206,q(b)?b:"ERROR_LICENSE",a)};f.ru=function(){Bh(this,102);if(this.j)this.j.onError(102);this.u("loadsofttimeout")};
-function rz(a,b){a.b&&a.b.Va(b);a.a.ta!=b&&(a.a.ta=b,gz(a))};function Nz(){}ca(Nz);f=Nz.prototype;f.kc=null;f.Ti=null;f.load=function(a){if(this.kc)return zo(this.kc);this.kc=new so;this.Ti=a?a:"3";yo(Bo("3.1"==this.Ti?"//s0.2mdn.net/instream/html5/ima3.js":"//s0.2mdn.net/instream/html5/ima.js",{timeout:1E4}),this.Lx,this.Vp,this);return this.kc};f.getVersion=function(){return this.Ti};f.Lx=function(){"3.1"==this.Ti&&this.kc?this.kc.b():(google.ima.SdkLoader.setCallbacks(v(this.kc.b,this.kc),v(this.Wv,this)),google.ima.SdkLoader.load("3",void 0))};
-f.Wv=function(a){this.Vp(Error("Google Ads SDK Failed to load: "+a))};f.Vp=function(a){this.kc.a(a)};function Oz(a){return a?-1!=a.toString().search(/(?:true|1)/i):!1}function Pz(a,b){if(a){var c="getErrorCode"in a?a.getErrorCode():null;c?b.error_code=c:(c=a.message,50<c.length&&(c=c.substring(0,47)+"..."),b.error_message=c)}}function Qz(a,b){if(a&&"3.1"==Nz.getInstance().getVersion()){var c=a.getAdId();if(c){var d=a.getWrapperAdIds()||[];b.ad_id=Za(d,c).join(",");if(c=a.getAdSystem())d=a.getWrapperAdSystems()||[],b.ad_sys=Za(d,c).join(",");a.isSkippable()&&(b.skip=1)}}}
-function Rz(a,b){if(a[b])return Oz(a[b]);var c=b.toLowerCase(),d;for(d in a)if(d&&d.toLowerCase()==c)return Oz(a[d]);return!1}function Sz(a){var b="";a&2&&a&1?b="video":a&2?b="skippablevideo":a&1&&(b="standardvideo");a&4&&(b&&(b+="_"),b+="text_image_flash");return b};function Tz(){var a=n("yt.www.watch.ads.handleSetAfvCompanionVars");a&&a()}function Uz(a){var b=n("yt.www.watch.ads.handleMoveGutCompanion");b&&b(1==a?!0:!1)}function Vz(a){var b=n("yt.www.watch.ads.handleShowAfvCompanionAdDiv");b&&b(0<(a&3))}function Wz(){var a=n("yt.www.watch.ads.handleHideCompanion");a&&a()};function Xz(a,b){return Sa(a.o,b)};function Yz(a,b){this.a=a;this.g=b}Yz.prototype.j=null;Yz.prototype.b=NaN;function Zz(a,b,c){a.a.u("AD_LOGGING_EVENT",b,c)}function $z(a){aA(a);var b=bA(a);if(a.i){var c=cA(a.g),d=a.i.y-c.top,d=Math.round(a.i.x-c.left)+"x"+Math.round(d);b.ck_xy=d;b.ck_wh=c.width+"x"+c.height}Zz(a,15,b)}function dA(a){aA(a);var b=bA(a);if(isNaN(a.b))aA(a);else{var c=x()-a.b;b.ad_stl=c}Zz(a,4,b)}function eA(a){aA(a);var b=bA(a),c=a.a.jp();c?b.ad_fmt=c:aA(a);Zz(a,5,b)}
-function bA(a){var b={},c=a.a.ka,d=a.a.Bf(),e=a.a.So();Qz(a.a.Sg(),b);d&&0<d&&(b.ad_len=d);c&&c.L?b.ad_v=c.L:e&&(c=Ij(e),b.ad_dom=c,a.g.da.k||Xz(a.g.J(),"921806")||Xz(a.g.J(),"921805"))&&(b.ad_v_url=e);b.at=a.a.getType();return b}function aA(a){a.j||(a.j="InstreamAdDisplay ("+a.a.getType()+")")};function fA(a,b,c,d){R.call(this);this.a=b;this.a.D("onVolumeChange",this.Hs,this);this.a.D("control_toggle_play_pause",this.gn,this);this.a.D("control_play",this.Qh,this);this.a.D("control_pause",this.ck,this);this.b=c;this.j=d;this.i=new Yz(this,this.a);this.o=a+"_2";this.g=new Uo(this)}y(fA,R);f=fA.prototype;f.Za=null;f.ka=null;f.Qf=!1;f.Xg=null;f.Wg=null;f.$g=null;
-f.show=function(){this.i.b=x();var a="";if("3.1"==gA())a=this.j;else{var b=null;try{b=this.b.getSelectedCreative(),a=b.getMediaUrl("video/x-flv")||b.getMediaUrl("video/mp4")||b.getMediaUrl("video/webm")}catch(c){hA(this,c);return}}if(a){b=Gj(a);b=b.v||b.video_id;if(!b){var d=fe(a).match(/^\/watch\/([^\/]*)$/i);d&&(b=d[1])}b||(a=a.match(/yt_vid\/([a-zA-Z0-9_-]{11})/),null!=a&&1<a.length&&(b=a[1]));a=b?new mh({video_id:b,dash:"0"}):null}else a=null;this.ka=a;var e;this.ka?(this.ka.Qd=!0,e={video_id:this.ka.L},
-this.ka.D("onStatusFail",this.Ln,this),this.ka.D("dataloaded",this.Kn,this),a=this.a.J(),a=new Lx(a.a),a.Y="adunit",a.Ub=!0,a=Sx(a,this.ka),Am(this.ka,a)):iA(this);jA(this.a,-1,e);this.on()};function kA(a){a.ka&&(a.ka.$("onStatusFail",a.Ln,a),a.ka.$("dataloaded",a.Kn,a))}f.Kn=function(){kA(this);var a=this.a.J(),b=this.ka,c=v(this.xv,this),a=a.Nh;b.B?rm(b,c,!!a,!1):tm(b,c,!!a)};
-f.xv=function(){var a=Yy(new Wy(this.a.J()),this.ka);a?(a=a.i)?(a=new qe(hj(a)),a.a.set("autoplay","1"),a=a.toString(),"3.1"==gA()?this.b.setMediaUrl(a):this.b.getSelectedCreative().setMediaUrl(a),iA(this)):hA(this,Error("Failed to determine ad media resource.")):hA(this,Error("Failed to determine ad media format."))};
-function iA(a){Uz(1);Vz(1);a.a.J();var b=a.a.b,c=Bn(b);b.W.J().ub||Zc(c)||xn(b).appendChild(c);a.Za=c;a.$g=Q(a.a.a);a.a.da.M?F(E("video-ad-status-bar")):(b=Q(a.a.a),a.Xg=E("video-ad-time-left",b),b=E("html5-ad-progress-list",b),c=Uc("div"),Pm(c,["html5-ad-progress","html5-progress-section"]),b.appendChild(c),a.Wg=c,a.g.listen(a.Za,"timeupdate",a.ju));Pm(a.$g,["ad-showing","ad-interrupting"]);a.g.listen(An(a.a.b),"mouseup",a.nu);a.g.listen(a.Za,"waiting",a.on);a.a.D("onResize",a.Lk,a);try{a.g.listen(a.b,
-google.ima.AdErrorEvent.Type.AD_ERROR,a.lu);a.g.listen(a.b,google.ima.AdEvent.Type.CLICK,a.ku);a.g.listen(a.b,google.ima.AdEvent.Type.COMPLETE,a.mu);a.g.listen(a.b,google.ima.AdEvent.Type.PAUSED,a.Un);a.g.listen(a.b,google.ima.AdEvent.Type.STARTED,a.Vn);a.Lk();var d=a.a,e=d.b,g=lA(d);e.W.J().ub&&(zd(e.a,g),od(e.a,0,0));a.b.start()}catch(h){hA(a,h)}}
-f.Vn=function(){this.Qf=!0;this.k||(this.k=!0,dA(this.i),mA(this.a,1));if(0==this.Bf()){var a=this.Za;a.Va(a.duration||0)}this.a.kb(!0);jA(this.a,1);this.u("adPlay",this)};f.Un=function(){this.Qf=!1;this.a.kb(!1);jA(this.a,2)};f.mu=function(){eA(this.i);this.Qf=!1;jA(this.a,0);mA(this.a,2);this.u("adEnd",this)};f.lu=function(a){hA(this,a.getError())};function hA(a,b){a.Qf=!1;jA(a.a,0);a.u("adError",b)}f.Ln=function(){kA(this);hA(this,Error("Request to get video data failed."))};
-f.ku=function(){$z(this.i);"3.1"==gA()||this.a.da.Q||H(v(this.Qh,this),0);this.u("select")};f.nu=function(a){this.i.i=new A(a.pageX,a.pageY)};f.ju=function(){var a=Nn(this.b.getRemainingTime());this.Xg.innerHTML=a;0==this.Bf()&&(a=this.Za,a.Va(a.duration||0));a=this.Bf()?this.Za.getCurrentTime()/this.Bf():0;a=Math.round(1E3*a)/10;this.Wg.style.width=a+"%"};f.on=function(){!this.Qf&&this.k||jA(this.a,3)};
-f.F=function(){this.a.$("control_toggle_play_pause",this.gn,this);this.a.$("control_play",this.Qh,this);this.a.$("control_pause",this.ck,this);this.a.$("onResize",this.Lk,this);this.g.removeAll();kA(this);this.b.destroy();this.Za&&(yn(this.a.b),this.Za=null);this.Xg&&(this.Xg.innerHTML="",this.Xg=null);this.Wg&&(F(this.Wg),this.Wg=null);this.$g&&(Qm(this.$g,["ad-showing","ad-interrupting"]),this.$g=null);fA.C.F.call(this)};f.getType=function(){return this.o};f.Sg=function(){return this.b.getCurrentAd()};
-f.Bf=function(){return this.Za?this.Za.Vd:null};f.jp=function(){return this.Za?this.Za.getType():null};f.So=function(){return this.Za&&this.Za.currentSrc?this.Za.currentSrc:null};f.Hs=function(a){a=a.muted?0:a.volume;isNaN(a)||(a=vb(a/100,0,1),this.b.setVolume(a))};f.gn=function(){this.Qf?this.ck():this.Qh()};f.Qh=function(){this.Za&&(this.b.resume(),this.Vn())};f.ck=function(){this.Za&&(this.b.pause(),this.Un())};f.Lk=function(){var a=lA(this.a);this.b.resize(a.width,a.height,google.ima.ViewMode.NORMAL)};function nA(a,b,c){R.call(this);this.a=b;this.a.D("control_toggle_play_pause",this.$m,this);this.a.D("control_play",this.Ph,this);this.a.D("control_pause",this.$j,this);this.b=c;this.j=new Yz(this,this.a);this.o=a+"_2";this.i=new Uo(this);this.g=oA(b);this.g.D("statechange",this.Ym,this);this.g.D("internalvideodatachange",this.Zm,this);this.ka=null}y(nA,R);f=nA.prototype;f.rl=!1;f.Gg=null;f.Fg=null;f.Hg=null;
-f.show=function(){var a=this.a;pA(a.app,oA(a));this.j.b=x();Uz(1);Vz(1);this.Hg=Q(this.a.a);if(this.a.da.M)F(E("video-ad-status-bar"));else{a=Q(this.a.a);this.Gg=E("video-ad-time-left",a);var a=E("html5-ad-progress-list",a),b=Uc("div");Pm(b,["html5-ad-progress","html5-progress-section"]);a.appendChild(b);this.Fg=b;this.g.D("progresssync",this.pn,this)}Pm(this.Hg,["ad-showing","ad-interrupting"]);this.i.listen(An(this.a.b),"mouseup",this.Rs);this.a.D("onResize",this.ik,this);try{this.i.listen(this.b,
-google.ima.AdErrorEvent.Type.AD_ERROR,this.Ps),this.i.listen(this.b,google.ima.AdEvent.Type.CLICK,this.Os),this.i.listen(this.b,google.ima.AdEvent.Type.COMPLETE,this.Qs),this.i.listen(this.b,google.ima.AdEvent.Type.PAUSED,this.un),this.i.listen(this.b,google.ima.AdEvent.Type.STARTED,this.vn),this.ik(),this.b.start()}catch(c){qA(this,c)}};f.Zm=function(a,b,c){"newdata"==a&&this.ka!=c&&jA(this.a,-1,{video_id:c.L});this.ka=c};f.Ym=function(a){a=a.state;P(a,128)&&qA(this,Error(a.a.message||"Video player error."))};
-f.vn=function(){this.rl=!0;this.k||(this.k=!0,dA(this.j),mA(this.a,1));jA(this.a,1);this.u("adPlay",this)};f.un=function(){this.rl=!1;jA(this.a,2)};f.Qs=function(){eA(this.j);jA(this.a,0);mA(this.a,2);this.u("adEnd",this)};f.Ps=function(a){qA(this,a.getError())};function qA(a,b){a.g.ng();jA(a.a,0);a.u("adError",b)}f.Os=function(){$z(this.j);"3.1"==gA()||this.a.da.Q||H(v(this.Ph,this),0);this.u("select")};f.Rs=function(a){this.j.i=new A(a.pageX,a.pageY)};
-f.pn=function(a,b,c){this.Gg.innerHTML=Nn(a.qd()-b);a=Math.round(1E3*c)/10;this.Fg.style.width=a+"%"};
-f.F=function(){this.a.$("control_toggle_play_pause",this.$m,this);this.a.$("control_play",this.Ph,this);this.a.$("control_pause",this.$j,this);this.a.$("onResize",this.ik,this);this.i.removeAll();this.g.D("statechange",this.Ym,this);this.g.$("internalvideodatachange",this.Zm,this);this.g.$("progresssync",this.pn,this);var a=this.a;a.g&&rA(a.app,a.g);this.b.destroy();this.Gg&&(this.Gg.innerHTML="",this.Gg=null);this.Fg&&(F(this.Fg),this.Fg=null);this.Hg&&(Qm(this.Hg,["ad-showing","ad-interrupting"]),
-this.Hg=null);nA.C.F.call(this)};f.getType=function(){return this.o};f.Sg=function(){return this.b.getCurrentAd()};f.Bf=function(){return this.g.qd()};f.jp=function(){return this.ka&&this.ka.a?this.ka.a.lb:null};f.So=function(){if(!this.ka)return null;var a=wm(this.ka);return a?hj(a):null};f.$m=function(){this.rl?this.$j():this.Ph()};f.Ph=function(){this.b.resume();this.vn()};f.$j=function(){this.b.pause();this.un()};f.ik=function(){var a=lA(this.a);this.b.resize(a.width,a.height,google.ima.ViewMode.NORMAL)};function sA(a,b){this.b=a;this.a=b;this.b.getType()}function tA(a,b,c){a.b.u("AD_LOGGING_EVENT",b,c)}function uA(a){var b={};Qz(a.b.Sg(),b);a.j&&a.g&&(b.ot=a.g-a.j);var c;c=a.a.a.app.J().ob||a.a.da.k?2:a.a.J().Rd?1:0;b.ad_ps=c;b.at=a.b.getType();return b};function vA(a,b,c){R.call(this);this.b=b;this.a=c;this.i=new sA(this,b);this.k=a+"_1";this.g=new Uo(this)}y(vA,R);f=vA.prototype;f.be=null;f.sn=!1;
-f.show=function(){V(Q(this.b.a),"ad-showing");this.be=xn(this.b.b);V(this.be,"ad-overlay");this.g.listen(this.be,"mouseup",this.Ns);try{Fd(this.be);this.g.listen(this.a,google.ima.AdEvent.Type.USER_CLOSE,this.Js);this.g.listen(this.a,google.ima.AdEvent.Type.CLICK,this.Ms);this.g.listen(this.a,google.ima.AdErrorEvent.Type.AD_ERROR,this.Ls);wA(this,google.ima.ViewMode.NORMAL);this.Eg();this.a.start();var a=this.i;a.j=x();var b=uA(a);tA(a,3,b);this.sn=!0;this.b.D("onResize",this.Eg,this);this.b.D("onStateChange",
-this.nn,this);this.u("adEnd",this)}catch(c){this.u("adError",c)}};f.Sg=function(){return this.a.getCurrentAd()};f.getType=function(){return this.k};f.F=function(){this.g.removeAll();this.b.$("onResize",this.Eg,this);this.b.$("onStateChange",this.nn,this);W(Q(this.b.a),"ad-showing");this.a&&(this.a.destroy(),this.a=null);this.be&&W(this.be,"ad-overlay");this.be=null;vA.C.F.call(this)};f.Js=function(){var a=this.i;a.g=x();var b=uA(a);tA(a,6,b)};
-f.Ms=function(){fn(this.b);var a=this.i;a.g=x();var b=uA(a);if(a.i){var c=cA(a.a),d=a.i.y-c.top,d=Math.round(a.i.x-c.left)+"x"+Math.round(d);b.ck_xy=d;b.ck_wh=c.width+"x"+c.height}tA(a,100,b)};f.Ns=function(a){this.i.i=a.target==a.currentTarget?null:new A(a.pageX,a.pageY)};f.Ls=function(a){a=a.getError();this.u("adError",a)};f.nn=function(a){P(a.state,16)&&wA(this,google.ima.ViewMode.NORMAL)};function wA(a,b){a.j!=b&&(a.j=b,a.sn&&a.Eg())}
-f.Eg=function(){var a=Fd(this.be);this.a.resize(a.width,a.height,this.j)};function xA(a,b){R.call(this);this.ca=a;this.a=b}y(xA,R);xA.prototype.show=function(){var a=n("afcAdCall");a&&a();a={};a.ad_id=this.a;a.at=this.getType();this.u("AD_LOGGING_EVENT",3,a);this.u("adEnd",this)};function yA(a,b){vA.call(this,1,a,b)}y(yA,vA);yA.prototype.Eg=function(){};yA.prototype.getType=function(){return"1_3"};function zA(a,b,c,d){R.call(this);this.Ba=b;this.b=a;this.start=c;this.g=d;this.a=null}y(zA,R);f=zA.prototype;f.rk=!0;f.td=!1;f.isVisible=!0;f.Ve="unloaded";f.Yk=!1;function AA(a){return 0==a.start?BA(a)&&CA(a)?-2147483648:0:-1==a.start||-2==a.start?2147483647:1E3*a.start}function BA(a){return"loaded"==a.Ve||"error"==a.Ve}function CA(a){if(!BA(a))throw Error("Preroll status is undefined before ad load.");return 0==a.start&&a.td}
-function DA(a){a.Ve="loading";var b=a.g.shift();b?(0==a.start&&EA(a.b,"nl"),b=b.create(a.start,a.Ba,a.b),L(a,b),yo(b.load(),a.Ov,a.Nv,a)):(FA(a.b,2,GA(a,{})),a.Ve="error",HA(a))}f.getId=function(){return this.Ba};function IA(a){a.a.$("adEnd",a.Ko,a);a.a.$("adError",a.No,a);a.a.$("AD_LOGGING_EVENT",a.Lo,a);a.a.$("select",a.Mo,a)}f.Nv=function(a){a instanceof to||DA(this)};
-f.Ov=function(a){this.start=a.startTime;this.a=a.Yt;L(this,this.a);0==this.Ba&&(a=this.a.getType(),this.b.i.at=a);this.a instanceof fA||this.a instanceof nA?this.td=!0:this.a instanceof xA?this.isVisible=!1:this.a instanceof yA&&(this.isVisible=!1);this.Ve="loaded";HA(this)};function HA(a){a.u("adBreakComplete",a)}
-f.show=function(){this.Yk?this.a instanceof vA&&wA(this.a,google.ima.ViewMode.NORMAL):(this.Yk=!0,this.a instanceof fA&&EA(this.b,"bs"),this.a.D("adEnd",this.Ko,this),this.a.D("adError",this.No,this),this.a.D("AD_LOGGING_EVENT",this.Lo,this),this.a.D("select",this.Mo,this),this.a.show())};f.Ko=function(){if(this.td){IA(this);var a=this.b;a.da.md&&!a.Bj&&(Qg(a.J().jb+"mac_204?action_fcts=1"),a.Bj=!0)}HA(this)};f.No=function(a){if(a){var b={};Pz(a,b);GA(this,b);JA(this.b,32,b)}IA(this);HA(this)};
-f.Lo=function(a,b){GA(this,b);FA(this.b,a,b)};f.Mo=function(){this.rk=!1};function GA(a,b){b.sst=a.start;b.sidx=0};function KA(a){this.uq=a}function LA(a){try{var b=aw(a).getElementsByTagName("AdBreak"),c=Ka(b,function(a){a=a.getAttribute("time");return Ca(a)});return new KA(c)}catch(d){return new KA([0])}};function MA(a,b,c,d){this.i=a;this.j=b;this.b=c;this.k=d}MA.prototype.g="";MA.prototype.a="";function NA(a){var b={};b.l_ns=a.j;b.l_state=a.k;b.sst=a.i;b.sidx=0;a.g&&(b.at=a.g);a.a&&(b.ad_id=a.a);return b};function OA(a,b,c,d,e){this.j=a;this.g=b;this.B=c;this.ca=d;this.b=e;this.a=new MA(b,this.j,d,e);this.H=new Uo(this);this.i=new Uo(this)}y(OA,K);f=OA.prototype;f.vo=null;f.Cd=null;
-f.load=function(){if(this.Cd)return this.Cd;this.Cd=new so;var a=this.ca.da.k?this.ca.J().Tc||PA:Bd(Q(this.ca.a)),b;this.ca.da.a?b=!1:(b=0<(this.b&3)?190:200,b=200>a.width||a.height<b);if(b){b=this.a;var c=NA(b);c.ck_wh=a.width+"x"+a.height;JA(b.b,14,c);this.Ye(Error("The player size is too small."))}else yo(this.ca.tg,this.Tu,this.Jd,this);return this.Cd};
-f.Wk=function(){var a=new google.ima.AdsRenderingSettings;a.baseYouTubeUrl=this.ca.J().jb;a.contentId=this.ca.getVideoData().L;a.useStyledNonLinearAds=!0;a.disableVideoAdUi=!this.ca.da.M;a.useVideoAdUi=this.ca.da.M;a.youTubeAdNamespace=this.j;return a};function QA(a,b){a.vo=b;var c=b.getType();a.a.g=c}function RA(a){a=a.g;return 0==a||-1==a?a:1E3*a}
-f.Tu=function(a){var b=this.a;FA(b.b,9,NA(b));b=new google.ima.AdsRequest;b.adTagUrl=this.k();var c=this.ca.J().Tc||PA;b.linearAdSlotWidth=c.width;b.linearAdSlotHeight=c.height;b.nonLinearAdSlotWidth=c.width;b.nonLinearAdSlotHeight=100;"3.1"==gA()&&(b.isYouTube=!0);var c=this.b,d=n("yt.www.watch.ads.setGutSlotSizes");d&&d(0<(c&3),0<(c&12));this.H.listen(a,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,this.Qu);this.H.listen(a,google.ima.AdErrorEvent.Type.AD_ERROR,this.Pu);this.zi(a,b)};
-f.Qu=function(a){if(a.getUserRequestContext()===this){try{var b;if("3.1"==gA()){var c=this.Wk();b=a.getAdsManager({},c)}else b=a.getAdsManager({})}catch(d){this.Jd(d);return}this.i.listen(b,google.ima.AdEvent.Type.LOADED,v(this.Ow,this,b));this.i.listen(b,google.ima.AdErrorEvent.Type.AD_ERROR,v(this.Nw,this,b));z([google.ima.AdEvent.Type.ALL_ADS_COMPLETED,google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED,google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED],function(a){this.i.listen(b,a,ba)},this);a=lA(this.ca);
-try{b.init(a.width,a.height,google.ima.ViewMode.NORMAL)}catch(e){b.destroy(),this.Jd(e)}}};f.Ow=function(a,b){this.i.removeAll();var c=b.getAd(),d=c.isLinear(),e=this.a,g=NA(e);g.ad_man=d?"instream":"overlay";FA(e.b,12,g);e="";"3.1"==gA()&&(e=b.getAdData().mediaUrl);switch(d?this.ah(a,c,e):this.Ue(a,c)){case 0:SA(this);break;case 1:a.destroy();this.Ye(Error("Unable to create a display state."));break;case 2:c=this.a;JA(c.b,21,NA(c));a.destroy();this.Ye(Error("Fallback to next ad."));break;default:a.destroy()}};
-f.Nw=function(a,b){this.i.removeAll();a.destroy();this.Jd(b.getError())};f.Pu=function(a){var b=a.getError();b.getType()==google.ima.AdError.Type.AD_LOAD&&a.getUserRequestContext()===this&&this.Jd(b)};f.ah=function(a,b,c){b=b.getAdId();this.a.a=b;a=this.ca.da.P?new nA(this.j,this.ca,a):new fA(this.j,this.ca,a,c);QA(this,a);return 0};f.Ue=function(a,b){var c=b.getAdId();this.a.a=c;QA(this,new vA(this.j,this.ca,a));return 0};
-f.Jd=function(a){if(a instanceof to)this.Cd.cancel();else{var b=this.a,c=NA(b);a&&Pz(a,c);JA(b.b,32,c);this.Ye(a)}};function SA(a){a.Cd.b({Yt:a.vo,startTime:a.g})}f.Ye=function(a){this.Cd.a(a)};f.F=function(){this.H.removeAll();this.i.removeAll();this.Cd&&this.Cd.cancel();OA.C.F.call(this)};f.zi=function(a,b){try{a.requestAds(b,this)}catch(c){this.Jd(c)}};function TA(a,b){this.a=a;this.b=b};function UA(a){xA.call(this,a,"")}y(UA,xA);UA.prototype.getType=function(){return"2_3"};UA.prototype.Sg=function(){return null};function VA(a,b,c,d){OA.call(this,2,a,b,c,d);this.o=new TA(this.ca.da,this.ca.J());Tz()}y(VA,OA);VA.prototype.Wk=function(){var a=VA.C.Wk.call(this);a.a=0==this.B;a.b=!0;return a};
-VA.prototype.k=function(){var a=this.o,b=this.b,c=RA(this),d={};d.eid=a.a.ja;d.videoad_start_delay=c;d.scs=a.a.ue;d.client=a.a.jg;d.description_url=a.a.pa;d.loeid=a.a.te;d.cust_gender=a.a.Kc;d.host=a.a.host;d.hl=a.b.i;d.max_ad_duration=a.a.ve;d.url="embedded"==a.b.Y&&a.b.b?a.b.b:a.a.pa;a.a.Mc&&(d.adtest="on");isNaN(a.a.fa)||(d.cust_age=a.a.fa);isNaN(a.a.za)||(d.hostTierId=a.a.za);a.a.ib&&(d.yt_pt=a.a.ib);a.a.mc&&(d.video_cpm=a.a.mc);a.a.G&&(d.as_dbp=a.a.G);d.ytdevice=a.a.dg;d.ad_type=Sz(b);0<(b&3)?
-a.a.Ka&&(d.channel=a.a.Ka.join("+")):b&4&&a.a.bb&&(d.channel=a.a.bb.join("+"));a.a.Sa&&(d.lsv=1);var a=d,b={},e;for(e in a)ea.call(void 0,a[e])&&(b[e]=a[e]);return"//googleads.g.doubleclick.net/pagead/ads?"+Ej(b,"&")};VA.prototype.Ue=function(a,b){if(this.ca.da.a)return 1;0==this.g&&(this.g=10,this.a.i=10,FA(this.ca,1));Vz(this.b);return VA.C.Ue.call(this,a,b)};
-VA.prototype.Ye=function(a){var b=this.ca.da;b.a?VA.C.Ye.call(this,a):b.Ma||this.b&4?(QA(this,new UA(this.ca)),SA(this)):VA.C.Ye.call(this,a)};function WA(a,b){if(a){this.Tp=a;this.Ip=b;var c,d=this.Tp,e=d.indexOf(";sz=");c=Dj(d.substring(e),";");d=d.substring(0,e).split("pfadx");if(c=2!=d.length?null:{Hx:d[0],Ix:d[1],Jx:c})this.Hp=c.Hx,this.Jp=c.Ix,this.Kp=c.Jx}}f=WA.prototype;f.Tp="";f.Hp="";f.Ip=!1;f.Rl="";f.Jp="";f.Kp=null;
-function XA(a,b){var c=[];b&1&&c.push("480x360");b&2&&c.push("480x361");b&12&&c.push("480x70");var d=[],e,g;b&12&&(d.push("300x250"),e="watch-channel-brand-div",g=1);0<(b&3)&&(d.push("300x60"),e="watch-longform-ad",g=1);c={Mp:e,uh:c,Pp:g,xx:!0,Ql:d};d=Mb(a.Kp);c.wx&&(d.pos=c.wx);c.Pp&&(d.tile=c.Pp.toString());c.Mp&&(d.kmyd=c.Mp);c.xx&&(t(d["!c"])?d["!c"].push("html5"):d["!c"]=d["!c"]?[d["!c"],"html5"]:"html5");c.Ql&&0<c.Ql.length&&a.Ip&&(d.ciu_szs=c.Ql.join(","));d.dcmt="text/xml";bj()&&(d.kmob="ps3");
-a.Rl||(a.Rl=Math.floor(999999999*Math.random()).toString());d.ord=a.Rl;c.uh&&c.uh.length&&"sz"in d&&delete d.sz;d=Ej(d,";");c.uh&&c.uh.length&&(d="sz="+c.uh.join(",")+";"+d);return[a.Hp,"pfadx",a.Jp,";",d,"?"].join("")};function YA(a,b,c,d){OA.call(this,1,a,b,c,d)}y(YA,OA);YA.prototype.k=function(){return XA(new WA(this.ca.da.Oc,this.ca.da.ya),this.b)};YA.prototype.Ue=function(a,b){var c=b.getAdId();this.a.a=c;c=b.getTraffickingParameters();return Rz(c,"rm")?(1!=this.b&&Wz(),ZA(a),2):Rz(c,"blockAllAds")?(ZA(a),QA(this,new yA(this.ca,a)),0):Rz(c,"hideMaster")?(QA(this,new yA(this.ca,a)),0):this.ca.da.a?1:"3.1"==gA()?(QA(this,new vA(this.j,this.ca,a)),0):1};
-function ZA(a){a.sendImpressionUrls&&a.sendImpressionUrls()};function $A(a,b,c,d,e){OA.call(this,1,a,b,c,d|e);this.A=d;this.o=e;Tz()}y($A,YA);var aB={GDFP:1,DART:1,DART_DFP:1,DART_DFA:1,ADSENSE:2,"ADSENSE/ADX":2};$A.prototype.k=function(){return XA(new WA(this.ca.da.I,this.ca.da.ya),this.A)};$A.prototype.zi=function(a,b){if(this.o){b.youTubeAdType=Sz(this.o);var c=this.ca.da.ja;c&&(b.youTubeExperimentIds=c);b.youTubeVideoAdStartDelay=RA(this)}$A.C.zi.call(this,a,b)};$A.prototype.ah=function(a,b,c){var d=bB(a);return 1!=d&&2!=d?1:$A.C.ah.call(this,a,b,c)};
-$A.prototype.Ue=function(a,b){switch(bB(a)){case 1:return $A.C.Ue.call(this,a,b);case 2:var c;1!=this.A&&Wz();this.ca.da.a?c=1:(0==this.g&&(this.g=10,this.a.i=10,FA(this.ca,1)),Vz(this.b),c=b.getAdId(),this.a.a=c,QA(this,new vA(2,this.ca,a)),c=0);return c;default:return 1}};function bB(a){var b=a.getCurrentAd().getWrapperAdSystems();a=Ta(b)?a.getCurrentAd().getAdSystem():b[0];return(a=aB[a.toUpperCase()])?a:0};function cB(a,b,c){var d=c.da;this.o=d.Lc;var e=0,d=d.Nc.toUpperCase();"INVIDEO"==d?e=4:"INSTREAM"==d?e=1:"MPU"==d&&(e=8);OA.call(this,2,a,b,c,e)}y(cB,OA);function dB(a){var b=new so;Qj(a,{format:"RAW",method:"GET",timeout:5E3,bl:function(){b.a(Error(a+" timed out"))},onError:function(c){b.a(Error("Problem loading "+a+" with status code "+c.status))},Qa:function(a){b.b(a)}});return b}cB.prototype.k=function(){return""};
-cB.prototype.zi=function(a,b){var c=this.b;c&1||c&4?this.o?("goo.gl"==Ij(this.o)?(c=dB("https://www.googleapis.com/urlshortener/v1/url?key=AIzaSyBbSB-E7SYd1iggX6r2b5C7ljvO6fVqaj0&shortUrl="+this.o),yo(c,function(a){a=mb(a.responseText);if(!a||!a.longUrl)throw Error("Invalid expanded forced ad URL");a=Kj(a.longUrl,{video_format:"43"});return dB(a)},null,this)):c=dB(this.o),yo(c,function(c){b.adsResponse=c.responseText;a.requestAds(b,this)},null,this),yo(c,null,this.Jd,this)):this.Jd(Error("Invalid empty URL")):
-this.Jd(Error("Invalid request type: "+c))};function eB(a,b,c){this.a=a;this.g=b;this.b=Ri||Si?"html5_ios":Ti?"html5_android":bj()?"html5_ps3":"leanback"==c?"html5_tv_leanback":"html5"};function fB(a,b,c,d){OA.call(this,4,a,b,c,d);this.o=new eB(this.ca.da,this.ca.getVideoData().ta,this.ca.J().Y)}y(fB,OA);
-fB.prototype.k=function(){var a;a=this.o;if(a.a.aa&&a.a.oc){var b="10613:10613_youtube_"+a.b,c="youtube_watch_"+a.b,d="10613:10613_youtube_"+a.b.split("_")[0],e={nw:"10613"};e.asnw=a.a.aa;e.ssnw=a.a.aa;e.caid=a.a.oc;e.prof=b;e.vdur=a.g;e.csid=c;e.resp="vast2";e.crtp="vast2s";e.flag="+emcr";b={};isNaN(a.a.ma)||(b._fw_d_001=a.a.ma);a.a.nc&&(b._fw_d_002=a.a.nc);a.a.Ta&&(b["_fwu:10613:lang"]=a.a.Ta);a.a.G&&(b._fw_dbp=a.a.G);b._fw_yt_type=a.a.B?"short":"long";var c={ptgt:"a",slid:"preroll"},g="";a.a.g&&
-!a.a.b?g=";linear-skippable":!a.a.g&&a.a.b&&(g=";video");c.slau="preroll"+g;c.w="480";c.h="360";c.tpos="0";c.tpcl="preroll";c.envp=d;c.cd="1440,900";a="//2975c.v.fwmrm.net/ad/g/1?"+Ej(e,"&")+";"+Ej(b,"&")+";"+Ej(c,"&")}else a="";return a};fB.prototype.ah=function(a,b){return 0!=this.g?1:fB.C.ah.call(this,a,b,null)};fB.prototype.Ue=function(){return 1};function gB(a,b,c){this.g=a;this.a=b;this.b=c||0}gB.prototype.create=function(a,b,c){switch(this.g){case 1:return new VA(a,b,c,this.a);case 2:return new YA(a,b,c,this.a);case 3:return new $A(a,b,c,this.a,this.b);case 5:return new fB(a,b,c,this.a);case 4:return new cB(a,b,c);default:return null}};function hB(a){this.a=a};function iB(a,b){this.O=a;this.Q=this.O.qc;this.k="leanback"==this.O.Y;this.a=this.Q||this.k;var c="3.1"==Nz.getInstance().getVersion();this.M=!this.a&&c;this.P=a.ub&&c&&!this.a;this.apply(b)}var jB={hC:"m",cB:"f"};
-iB.prototype.apply=function(a){var b=Xz(this.O,"908301"),c="3.1"==Nz.getInstance().getVersion(),d=Oz(a.instream),e=(!this.a||b)&&c&&Oz(a.trueview),g=Oz(a.aftv)&&(!this.a||b);this.ia=a.ad_slots;this.ga=a.ad_breaks;this.Qc=a.ad_flags||0;this.fa=parseInt(a.cust_age,10);this.ja=a.cafe_experiment_id;var h=parseInt(a.cust_gender,10);isNaN(h)||(this.Kc=h);this.Oc=a.ad_tag;this.Mc=!!a.adtest;this.ma=parseInt(a.ad_age,10);this.Jc=a.cid;this.pa=a.ad_eurl;this.I=a.dynamic_allocation_ad_tag;this.va=a.excluded_ads;
-this.Nc=a.force_ad_type;this.Lc=a.force_ad_url;this.nc=Jb(jB,function(b){return b==a.ad_gender});this.G=a.dbp;this.ya=!!a.mpu;this.host=a.ad_host;this.za=parseInt(a.ad_host_tier,10);this.od=1==a.ad_logging_flag;this.H=Oz(a.afv)&&!this.a;this.i=g&&e;this.j=g&&d&&!Oz(a.no_afv_instream);this.A=Oz(a.dclk);this.Sa=1==a.livestream;this.Na=Oz(a.forced_ad)&&b&&c;this.K=1==parseInt(a.tpas_ad_type_id,10);this.bg=!!a.fqsf;this.b=d;this.U=Oz(a.invideo)&&!this.a;this.X=Oz(a.mpu)&&!this.a;this.md=Oz(a.shortform);
-this.B=Oz(a.sffb);this.ue="1"==a.as_launched_in_country;this.tb=!this.a&&!this.K;this.g=e;b=a.ad_channel_code_instream;this.Ka=u(b)?b.split(","):[];this.Ta=a.ad_language_iso639_2;this.te=a.loeid;b=parseInt(a.afv_instream_max,10);isNaN(b)&&(b=15E3);this.ve=b;this.o=parseInt(a.midroll_freqcap,10);isNaN(this.o)&&(this.o=-1);b=a.ad_channel_code_overlay;this.bb=u(b)?b.split(","):[];this.ib=a.yt_pt;this.jg=a.ad_video_pub_id;this.mc=parseInt(a.afv_video_min_cpm,10);this.Ma=g&&this.B&&!this.H;this.nd=this.H||
-this.Ma;this.dg=parseInt(a.ad_device,10);this.oc=a.tpas_video_id;this.aa=a.tpas_partner_id;this.Pc=kB(this)};function kB(a){if(/^[\s\xa0]*$/.test(null==a.I?"":String(a.I))||!Xz(a.O,"932604")||!a.P)return!1;var b=(a.b||a.g)&&a.A;a.B&&a.A&&(b=b||a.U||a.X);if(!b)return!1;b=a.i||a.j;if(!(b||a.B&&a.H))return!1;a=a.I.length+330+102;var c=window.document.referrer;a+=encodeURIComponent(String("ref"+(c?"="+c:""))).length;b||(a+=41);return 2048>=a}iB.prototype.tb=!0;function lB(a,b,c){this.a=a;this.k=b;this.g=c;this.j=this.b=-1;this.g&&0<this.a.da.o&&this.a.D("endseeking",this.i,this)}y(lB,K);function mB(a,b){nB(a);0<b&&(a.j=H(v(a.i,a),1E3*b))}function nB(a){-1!=a.j&&(I(a.j),a.j=-1)}
-lB.prototype.i=function(){var a=this.a.da.o;if(this.g&&!(0>=a)){var b=this.a.a.getCurrentTime(),c=[],d=null,e=Number.MAX_VALUE;Eb(this.k.i,function(a){if(a.td&&a.isVisible&&!(0>=oB(this,a))){var g;g=a.getId();g=this.k.j[g];if(oB(this,a)>b){var m=!pB(this,a);m!=g.Uc&&(g.Uc=m,c.push(g));m||(g=oB(this,a)-b,g<e&&(e=g,d=a))}else g.Uc||(g.Uc=!0,c.push(g))}},this);0<c.length&&qB(this.a,c);if(d){var g=0;0<this.b&&(g=x()/1E3-this.b);mB(this,a-g-e+2)}else nB(this)}};
-function pB(a,b){if(!a.g||!b.td||!(0<b.start)&&-1!=b.start)return!1;var c=a.a.da.o;if(0>=c||0>=a.b)return!1;var d=x()/1E3,e=oB(a,b)-a.a.a.getCurrentTime();0<e&&(d+=e);return d-a.b<=c}function oB(a,b){return-1==b.start?a.a.a.wg():b.start}lB.prototype.F=function(){nB(this)};function rB(a,b){this.b=b;this.g=[];this.i={};this.j={};this.a=a;var c=!a.da.Sa&&La(this.b,function(a){return 0<a.start||-1==a.start});this.k=new lB(this.a,this,c)}y(rB,K);f=rB.prototype;f.Hd=null;function sB(a){a.g.length||(fb(a.b,function(a,c){return a.getId()-c.getId()}),a.g=Ja(a.b,function(a){return"unloaded"==a.Ve}),0==a.g.length?Vm(a.a):(null===Oa(a.g,function(a){return 0==a.start})&&Vm(a.a),tB(a)))}function tB(a){if(a.g.length){var b=a.g.shift();b.D("adBreakComplete",a.ul,a);DA(b)}}
-f.ul=function(a){a.$("adBreakComplete",this.ul,this);H(v(this.tx,this,a),0)};f.tx=function(a){var b=Ia(this.b,a),c=this.b[b+1],b=this.b[b-1],d=2147483646;-2==a.start||-1==a.start?d=2147483647:c&&2147483647!=c.start&&(d=AA(c)-1);0==a.Ba&&(EA(this.a,"bl"),CA(a)||EA(this.a,"fb"));if(c="loaded"!=a.Ve){if(b&&BA(b)){var e=AA(b);e>d&&(d=e);uB(this,b);vB(this,b,d)}}else this.i[a.getId()]=a,vB(this,a,d);Vm(this.a);c&&this.ug(a);a=this.i;var b=0,g;for(g in a)b++;b==this.b.length&&this.k.i();tB(this)};
-function vB(a,b,c){var d=AA(b);if(!isNaN(d)){var e={};e.priority=-2!=b.start?2:3;e.id=String(b.getId());e.visible=b.isVisible;c=new Zh(d,c,e);a.j[b.getId()]=c;a.a.zf(c)}}function uB(a,b){a.j[b.getId()]&&(a.a.qv(a.j[b.getId()]),delete a.j[b.getId()])}f.ug=function(a){a.$("adBreakComplete",this.ul,this);this.Hd&&a==this.Hd&&(this.Hd=null);uB(this,a);Wa(this.b,a);delete this.i[a.getId()];Sg(a)};
-f.Lu=function(a){if(a.td){if(-1!=a.start&&a.rk){var b=this.a;wB(b);en(b)}else CA(a)&&!a.rk?(b=this.a,wB(b),en(b)):(wB(this.a),this.a.kb(!1));this.ug(a);a=this.k;a.g&&0<a.a.da.o&&(a.b=x()/1E3,a.i())}else a.isVisible||this.ug(a)};f.F=function(){Sg(this.k);z(this.b,this.ug,this);rB.C.F.call(this)};function xB(){return[]};function yB(a,b){this.g=a;b&&(this.b=b)}function zB(a){var b={};b.allowed=a.g;a.b&&(b.ex_ads=a.b);a.a&&(b.at=a.a);return b};function AB(a,b){this.g=a;this.W=b;this.o=x();this.a=a.da;this.b={};var c=[];this.a.K&&this.a.b&&c.push("4_2");this.a.A&&(this.a.b&&c.push("1_2"),this.a.g&&c.push("1_2_1"),this.a.U&&c.push("1_1"),this.a.X&&c.push("1_3"));this.a.i&&c.push("2_2_1");this.a.j&&c.push("2_2");this.a.H&&c.push("2_1");this.a.nd&&c.push("2_3");this.i=c.join(",");this.k=new yB(this.i,this.a.va);this.b.allowed=this.i;(c=this.a.va)&&(this.b.ex_ads=c)}var BB=[9,10,11,12],CB=[21,30],DB=[1009];AB.prototype.j=0;
-function EB(a,b){if(!a.a.od)return!1;var c=a.g.J();if(Xz(c,"906335"))return!0;c=b.ad_event;return Sa(BB,c)||7==c&&(c=b.ad_error,Sa(CB,c)||32==c&&Sa(DB,b.error_code))?!1:!0};function FB(a){Cx.call(this,a);this.j={};this.i={at:"0"};this.b=new wn(this.a);this.g=null;a=this.getVideoData().b.html5_sdk_version;this.k=Nz.getInstance().load(a)}y(FB,Cx);var PA=new B(0,0);f=FB.prototype;f.qa="ad";f.hd="ad";f.ze=null;f.Wd=null;f.da=null;f.Bj=!1;f.Uj=!1;f.tg=null;f.vi=null;f.Xa=function(){return!!this.app.I.getVideoData().ca};
-f.create=function(){FB.C.create.call(this);this.ba=!0;EA(this,"i");this.da=new iB(this.J(),this.a.getVideoData().b||{});this.ze=new AB(this,this.a);Uz();this.Bj=!1;var a=zo(this.k);this.tg=yo(a,this.wq,null,this);t:{var a=new hB(this),b=[];try{var c=a.a.da,d;if(c.tb){var e;if(c.ga)e=LA(c.ga);else{var g;if(c.ia){var h=Ka(c.ia.split(","),Ca);g=new KA(h)}else g=new KA([0]);e=g}d=e}else d=new KA([0]);for(var k=d.uq,c=0;c<k.length;c++){var m=a.a;d=c;var p=k[c],s;if(a.a.da.B){e=[];var r=a.a.da;if(r.Na)e.push(new gB(4,
-0));else{r.K&&(r.b||r.g)&&e.push(new gB(5,1));g=0;r.A&&(r.b&&(g|=1),r.g&&(g|=2),r.U&&(g|=4),r.X&&(g|=8));h=0;if(r.j||r.i)r.j&&(h|=1),r.i&&(h|=2);var D=0;r.H&&(D=4);h||(h=D,D=0);r.Pc&&g&&(h||D)?e.push(new gB(3,g,h)):(g&&e.push(new gB(2,g)),h&&e.push(new gB(1,h)));D&&e.push(new gB(1,D))}}else{e=[];var M=a.a.da;if(M.Na)e.push(new gB(4,0));else{M.K&&M.b&&e.push(new gB(5,1));g=0;M.A&&(M.b&&(g|=1),M.g&&(g|=2));h=0;if(M.j||M.i)M.j&&(h|=1),M.i&&(h|=2);M.Pc&&g&&h?e.push(new gB(3,g,h)):(g&&e.push(new gB(2,
-g)),h&&e.push(new gB(1,h)))}}s=e;var sa=new zA(m,d,p,s);b.push(sa)}}catch(Y){}finally{break t}}k=b;EA(this,"bd");this.Wd=new rB(this,k);sB(this.Wd);k={};k.allowed=this.ze.i;Zm(this,{},k)};f.destroy=function(){this.Uj&&wB(this);this.ba=!1;this.g&&rA(this.app,this.g);Tg(this.Wd,this.g);this.g=this.Wd=null;this.tg&&(this.tg.cancel(),this.tg=null);this.ze=null;yn(this.b);FB.C.destroy.call(this)};f.getVideoData=function(){return this.app.getVideoData(1)};f.J=function(){return this.app.J()};
-function FA(a,b,c){a=a.ze;c=c||{};var d=(x()-a.o)/1E3;c.art=d;d=a.g.J();d.j&&(c.feature=d.ga);c.ad_flags=a.a.Qc;var e=a.a.Jc;e&&(c.cid=e);c.mt=a.W.getCurrentTime();(d=Xx(d))&&(c.lact=d);(d=a.W.wg())&&(c.len=d);a.a.bg&&(c.fqsf=1);(d=Nz.getInstance().getVersion())&&(c.sdkv=d);c.ad_event=b;if(3==b||4==b)a.k.a=c.at;b=c;if(EB(a,b)){var g;t:{c=a.b;d=Lb(b);for(g in c){if(g in d){g=null;break t}d[g]=c[g]}g=d}null===g?a.g.log(a.b):b=g;a.g.log(b);a.b={}}}function JA(a,b,c){c=c||{};c.ad_error=b;FA(a,7,c)}
-f.Ri=function(){return this.ze?this.ze.k:FB.C.Ri.call(this)};function gA(){return Nz.getInstance().getVersion()}function oA(a){if(!a.g){var b=new Lx(a.J().a);b.Y="adunit";b.Ub=!0;a.g=new cz(b,2)}return a.g}function lA(a){var b=a.da.k?a.J().Tc||PA:Fd(Q(a.a));a.da.a||(b.height-=27);return b}function cA(a){return a.da.k?(a=a.J().Tc||PA,new Cb(0,0,a.width,a.height)):Dd(Q(a.a))}function wB(a){yn(a.b);a.Uj=!1;dn(a);cn(a,["seek"]);a.J().Sd&&cn(a,["audio"])}
-function mA(a,b){switch(b){case 1:a.u("publish_external_event","onAdStart");break;case 2:a.u("publish_external_event","onAdEnd")}}function jA(a,b,c){a.u("publish_external_event","onAdStateChange",b,a.b.W.J().ub?a.b.W.app.S.b:Bn(a.b),c)}
-f.xc=function(a){FB.C.xc.call(this,a);var b=parseInt(a.getId(),10);this.Wd&&!isNaN(b)&&(a=this.Wd,q(b)&&(b=a.i[b]))&&(a.Hd==b&&!b.td&&b.isVisible?b.show():(a.Hd&&a.ug(a.Hd),pB(a.k,b)?(a.Hd=null,b=a.j[b.getId()],b.Uc||(b.Uc=!0,qB(a.a,[b]))):(a.Hd=b,b.D("adBreakComplete",a.Lu,a),b.td&&(a=a.a,a.Uj=!0,a.u("command_redirect_controls",a,["play_pause"],void 0),bn(a,["seek"]),a.J().Sd&&bn(a,["audio"]),fn(a)),b.show())))};
-f.$c=function(a){FB.C.$c.call(this,a);var b=parseInt(a.getId(),10),c=1E3*this.a.getCurrentTime();this.Wd&&!isNaN(b)&&c>a.start&&(2147483647==a.end||2147483646==a.end)&&(a=this.Wd,(b=a.i[b])&&a.Hd==b&&!b.td&&b.isVisible&&b.Yk&&b.a instanceof vA&&wA(b.a,google.ima.ViewMode.FULLSCREEN))};
-f.wq=function(){EA(this,"sdk");if(this.vi)return this.vi;var a;if(this.da.P){a=new Bx(this.app,2);var b=google.ima.AdDisplayContainer,c=xn(this.b),d=An(this.b);a.j||(a.j=Lb(a.i),a.j.addEventListener=v(a.fu,a),a.j.removeEventListener=v(a.gu,a));a=new b(c,void 0,d,a.j)}else{a=this.b.W.J().ub?this.b.W.app.S.b:Bn(this.b);if(!a)return a=Error("AdModule.getVideoElement returned an invalid element."),b=new so,b.a(a),b;a=new google.ima.AdDisplayContainer(xn(this.b),a,An(this.b))}return this.vi=new google.ima.AdsLoader(a)};
-function EA(a,b){var c=b;"nl"==b&&(c=a.ze,c.j++,c=c.j.toString());a.j[c]=x();"bs"!=c&&"fb"!=c||Zm(a,a.j,a.i)}function qB(a,b){a.u("command_update_cuerange_markers",b,a.a.a)}f.oe=function(a){this.u(a)};function GB(a){return HB(a||arguments.callee.caller,[])}
-function HB(a,b){var c=[];if(Sa(b,a))c.push("[...circular reference...]");else if(a&&50>b.length){c.push(IB(a)+"(");for(var d=a.arguments,e=0;e<d.length;e++){0<e&&c.push(", ");var g;g=d[e];switch(typeof g){case "object":g=g?"object":"null";break;case "string":break;case "number":g=String(g);break;case "boolean":g=g?"true":"false";break;case "function":g=(g=IB(g))?g:"[fn]";break;default:g=typeof g}40<g.length&&(g=g.substr(0,40)+"...");c.push(g)}b.push(a);c.push(")\n");try{c.push(HB(a.caller,b))}catch(h){c.push("[exception trying to get caller]\n")}}else a?
-c.push("[...long stack...]"):c.push("[end]");return c.join("")}function IB(a){if(JB[a])return JB[a];a=String(a);if(!JB[a]){var b=/function ([^\(]+)/.exec(a);JB[a]=b?b[1]:"[Anonymous]"}return JB[a]}var JB={};function KB(a,b,c,d,e){this.reset(a,b,c,d,e)}KB.prototype.b=null;KB.prototype.a=null;var LB=0;KB.prototype.reset=function(a,b,c,d,e){"number"==typeof e||LB++;this.i=d||x();this.j=a;this.k=b;this.g=c;delete this.b;delete this.a};KB.prototype.getMessage=function(){return this.k};function MB(a){this.b=a}MB.prototype.a=null;function NB(a,b){this.name=a;this.value=b}NB.prototype.toString=function(){return this.name};var OB=new NB("SHOUT",1200),PB=new NB("SEVERE",1E3),QB=new NB("WARNING",900),RB=new NB("INFO",800);f=MB.prototype;f.Iv=function(){};f.Kv=function(){return!1};f.getChildren=function(){this.a||(this.a={});return this.a};f.log=function(){};
-f.Jv=function(a,b,c){var d=new KB(a,String(b),this.b);if(c){d.b=c;var e;var g=arguments.callee.caller;try{var h;var k=n("window.location.href");if(u(c))h={message:c,name:"Unknown error",lineNumber:"Not available",fileName:k,stack:"Not available"};else{var m,p,s=!1;try{m=c.lineNumber||c.zy||"Not available"}catch(r){m="Not available",s=!0}try{p=c.fileName||c.filename||c.sourceURL||l.$googDebugFname||k}catch(D){p="Not available",s=!0}h=!s&&c.lineNumber&&c.fileName&&c.stack&&c.message&&c.name?c:{message:c.message||
-"Not available",name:c.name||"UnknownError",lineNumber:m,fileName:p,stack:c.stack||"Not available"}}e="Message: "+va(h.message)+'\nUrl: <a href="view-source:'+h.fileName+'" target="_new">'+h.fileName+"</a>\nLine: "+h.lineNumber+"\n\nBrowser stack:\n"+va(h.stack+"-> ")+"[end]\n\nJS stack traversal:\n"+va(GB(g)+"-> ")}catch(M){e="Exception trying to expose exception! You win, we lose. "+M}d.a=e}return d};f.info=function(){};var SB={},TB=null;function UB(){TB||(TB=new MB(""),SB[""]=TB)}
-function VB(a){UB();var b;if(!(b=SB[a])){b=new MB(a);var c=a.lastIndexOf("."),d=a.substr(c+1);VB(a.substr(0,c)).getChildren()[d]=b;SB[a]=b}return b};function WB(){this.a=x()}var XB=new WB;WB.prototype.set=function(a){this.a=a};WB.prototype.reset=function(){this.set(x())};WB.prototype.get=function(){return this.a};function YB(a){this.g=a||"";this.i=XB}YB.prototype.b=!0;YB.prototype.a=!1;function ZB(a){return 10>a?"0"+a:String(a)}function $B(a,b){var c=(a.i-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}function aC(a){YB.call(this,a)}y(aC,YB);
-function bC(a,b){var c=[];c.push(a.g," ");if(a.b){var d=new Date(b.i);c.push("[",ZB(d.getFullYear()-2E3)+ZB(d.getMonth()+1)+ZB(d.getDate())+" "+ZB(d.getHours())+":"+ZB(d.getMinutes())+":"+ZB(d.getSeconds())+"."+ZB(Math.floor(d.getMilliseconds()/10)),"] ")}c.push("[",$B(b,a.i.get()),"s] ");c.push("[",b.g,"] ");c.push(b.getMessage());a.a&&b.b&&c.push("\n",b.a);c.push("\n");return c.join("")};function cC(a,b){this.b=new qb(a);this.a=b?nb:mb}cC.prototype.stringify=function(a){return pb(this.b,a)};cC.prototype.parse=function(a){return this.a(a)};function dC(){};function eC(){}eC.prototype.a=null;var fC;function gC(){}y(gC,eC);function hC(a){return(a=iC(a))?new ActiveXObject(a):new XMLHttpRequest}function jC(a){var b={};iC(a)&&(b[0]=!0,b[1]=!0);return b}
-function iC(a){if(!a.b&&"undefined"==typeof XMLHttpRequest&&"undefined"!=typeof ActiveXObject){for(var b=["MSXML2.XMLHTTP.6.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"],c=0;c<b.length;c++){var d=b[c];try{return new ActiveXObject(d),a.b=d}catch(e){}}throw Error("Could not create ActiveXObject. ActiveX might be disabled, or MSXML might not be installed");}return a.b}fC=new gC;function kC(a,b,c,d,e){this.b=a;this.a=b;this.j=c;this.g=d;this.i=e||1;this.vc=45E3;this.o=new fr(this);this.k=new Ei;Fi(this.k,250)}f=kC.prototype;f.Fe=null;f.Dc=!1;f.Pf=null;f.pl=null;f.Bg=null;f.Lf=null;f.$d=null;f.Lb=null;f.ce=null;f.Ra=null;f.Tg=0;f.Gc=null;f.Af=null;f.Le=null;f.zg=-1;f.zn=!0;f.Pe=!1;f.lk=0;f.fi=null;
-function lC(a,b){switch(a){case 0:return"Non-200 return code ("+b+")";case 1:return"XMLHTTP failure (no data)";case 2:return"HttpConnection timeout";default:return"Unknown error"}}var mC={},nC={};f=kC.prototype;f.setTimeout=function(a){this.vc=a};function oC(a,b,c){a.Lf=1;a.$d=He(b.clone());a.ce=c;a.H=!0;pC(a,null)}function qC(a,b,c,d,e){a.Lf=1;a.$d=He(b.clone());a.ce=null;a.H=c;e&&(a.zn=!1);pC(a,d)}
-function pC(a,b){a.Bg=x();rC(a);a.Lb=a.$d.clone();Fe(a.Lb,"t",a.i);a.Tg=0;a.Ra=a.b.Dk(a.b.oi()?b:null);0<a.lk&&(a.fi=new js(v(a.Hn,a,a.Ra),a.lk));a.o.listen(a.Ra,"readystatechange",a.Tt);var c=a.Fe?Lb(a.Fe):{};a.ce?(a.Af="POST",c["Content-Type"]="application/x-www-form-urlencoded",a.Ra.send(a.Lb,a.Af,a.ce,c)):(a.Af="GET",a.zn&&!dc&&(c.Connection="close"),a.Ra.send(a.Lb,a.Af,null,c));a.b.Cc(1);var d=a.ce;if(d)for(var c="",d=d.split("&"),e=0;e<d.length;e++){var g=d[e].split("=");if(1<g.length)var h=
-g[0],g=g[1],k=h.split("_"),c=2<=k.length&&"type"==k[1]?c+(h+"="+g+"&"):c+(h+"=redacted&")}else c=null;a.a.info("XMLHTTP REQ ("+a.g+") [attempt "+a.i+"]: "+a.Af+"\n"+a.Lb+"\n"+c)}f.Tt=function(a){a=a.target;var b=this.fi;b&&3==sC(a)?(this.a.debug("Throttling readystatechange."),ks(b)):this.Hn(a)};
-f.Hn=function(a){try{if(a==this.Ra)t:{var b=sC(this.Ra),c=this.Ra.i,d=tC(this.Ra);if(C&&!sc(10)||dc&&!rc("420+")){if(4>b)break t}else if(3>b||3==b&&!bc&&!uC(this.Ra))break t;this.Pe||4!=b||7==c||(8==c||0>=d?this.b.Cc(3):this.b.Cc(2));vC(this);var e=tC(this.Ra);this.zg=e;var g=uC(this.Ra);g||this.a.debug("No response text for uri "+this.Lb+" status "+e);this.Dc=200==e;this.a.info("XMLHTTP RESP ("+this.g+") [ attempt "+this.i+"]: "+this.Af+"\n"+this.Lb+"\n"+b+" "+e);this.Dc?(4==b&&wC(this),this.H?(xC(this,
-b,g),bc&&this.Dc&&3==b&&(this.o.listen(this.k,"tick",this.Ks),this.k.start())):(yC(this.a,this.g,g,null),zC(this,g)),this.Dc&&!this.Pe&&(4==b?this.b.ci(this):(this.Dc=!1,rC(this)))):(this.Le=400==e&&0<g.indexOf("Unknown SID")?3:0,AC(),wC(this),BC(this))}}catch(h){this.a.debug("Failed call to OnXmlHttpReadyStateChanged_"),this.Ra&&uC(this.Ra)&&uC(this.Ra)}finally{}};
-function xC(a,b,c){for(var d=!0;!a.Pe&&a.Tg<c.length;){var e=CC(a,c);if(e==nC){4==b&&(a.Le=4,AC(),d=!1);yC(a.a,a.g,null,"[Incomplete Response]");break}else if(e==mC){a.Le=4;AC();yC(a.a,a.g,c,"[Invalid Chunk]");d=!1;break}else yC(a.a,a.g,e,null),zC(a,e)}4==b&&0==c.length&&(a.Le=1,AC(),d=!1);a.Dc=a.Dc&&d;d||(yC(a.a,a.g,c,"[Invalid Chunked Response]"),wC(a),BC(a))}f.Ks=function(){var a=sC(this.Ra),b=uC(this.Ra);this.Tg<b.length&&(vC(this),xC(this,a,b),this.Dc&&4!=a&&rC(this))};
-function CC(a,b){var c=a.Tg,d=b.indexOf("\n",c);if(-1==d)return nC;c=Number(b.substring(c,d));if(isNaN(c))return mC;d+=1;if(d+c>b.length)return nC;var e=b.substr(d,c);a.Tg=d+c;return e}
-function DC(a,b){a.Bg=x();rC(a);var c=b?window.location.hostname:"";a.Lb=a.$d.clone();Ee(a.Lb,"DOMAIN",c);Ee(a.Lb,"t",a.i);try{a.Gc=new ActiveXObject("htmlfile")}catch(d){wC(a);a.Le=7;AC();BC(a);return}var e="<html><body>";b&&(e+='<script>document.domain="'+c+'"\x3c/script>');e+="</body></html>";a.Gc.open();a.Gc.write(e);a.Gc.close();a.Gc.parentWindow.m=v(a.Xt,a);a.Gc.parentWindow.d=v(a.Nn,a,!0);a.Gc.parentWindow.rpcClose=v(a.Nn,a,!1);c=a.Gc.createElement("div");a.Gc.parentWindow.document.body.appendChild(c);
-c.innerHTML='<iframe src="'+a.Lb+'"></iframe>';a.a.info("TRIDENT REQ ("+a.g+") [ attempt "+a.i+"]: GET\n"+a.Lb);a.b.Cc(1)}f.Xt=function(a){EC(v(this.ty,this,a),0)};f.ty=function(a){if(!this.Pe){var b=this.a;b.info("TRIDENT TEXT ("+this.g+"): "+FC(b,a));vC(this);zC(this,a);rC(this)}};f.Nn=function(a){EC(v(this.sy,this,a),0)};f.sy=function(a){this.Pe||(this.a.info("TRIDENT TEXT ("+this.g+"): "+a?"success":"failure"),wC(this),this.Dc=a,this.b.ci(this),this.b.Cc(4))};f.cancel=function(){this.Pe=!0;wC(this)};
-function rC(a){a.pl=x()+a.vc;GC(a,a.vc)}function GC(a,b){if(null!=a.Pf)throw Error("WatchDog timer not null");a.Pf=EC(v(a.Xx,a),b)}function vC(a){a.Pf&&(l.clearTimeout(a.Pf),a.Pf=null)}f.Xx=function(){this.Pf=null;var a=x();0<=a-this.pl?(this.a.info("TIMEOUT: "+this.Lb),2!=this.Lf&&this.b.Cc(3),wC(this),this.Le=2,AC(),BC(this)):GC(this,this.pl-a)};function BC(a){a.b.Ib()||a.Pe||a.b.ci(a)}
-function wC(a){vC(a);Sg(a.fi);a.fi=null;a.k.stop();a.o.removeAll();if(a.Ra){var b=a.Ra;a.Ra=null;b.abort();b.dispose()}a.Gc&&(a.Gc=null)}function zC(a,b){try{a.b.mp(a,b),a.b.Cc(4)}catch(c){}};function HC(){}function yC(a,b,c,d){a.info("XMLHTTP TEXT ("+b+"): "+FC(a,c)+(d?" "+d:""))}HC.prototype.debug=function(a){this.info(a)};HC.prototype.info=function(){};
-function FC(a,b){if(!b||"y2f%"==b)return b;try{var c=nb(b);if(c)for(var d=0;d<c.length;d++)if(t(c[d])){var e=c[d];if(!(2>e.length)){var g=e[1];if(t(g)&&!(1>g.length)){var h=g[0];if("noop"!=h&&"stop"!=h)for(var k=1;k<g.length;k++)g[k]=""}}}return ob(c)}catch(m){return a.debug("Exception parsing expected JS array - probably was not JS"),b}};function IC(a,b,c,d,e){(new HC).debug("TestLoadImageWithRetries: "+e);if(0==d)c(!1);else{var g=e||0;d--;JC(a,b,function(e){e?c(!0):l.setTimeout(function(){IC(a,b,c,d,g)},g)})}}
-function JC(a,b,c){var d=new HC;d.debug("TestLoadImage: loading "+a);var e=new Image;e.onload=function(){try{d.debug("TestLoadImage: loaded"),KC(e),c(!0)}catch(a){}};e.onerror=function(){try{d.debug("TestLoadImage: error"),KC(e),c(!1)}catch(a){}};e.onabort=function(){try{d.debug("TestLoadImage: abort"),KC(e),c(!1)}catch(a){}};e.ontimeout=function(){try{d.debug("TestLoadImage: timeout"),KC(e),c(!1)}catch(a){}};l.setTimeout(function(){if(e.ontimeout)e.ontimeout()},b);e.src=a}
-function KC(a){a.onload=null;a.onerror=null;a.onabort=null;a.ontimeout=null};function LC(a,b){this.a=a;this.b=b;this.g=new cC(null,!0)}f=LC.prototype;f.Mk=null;f.Qb=null;f.Gi=!1;f.jo=null;f.Fi=null;f.Zk=null;f.fl=null;f.Sb=null;f.$e=-1;f.eh=null;f.hh=null;f.connect=function(a){this.fl=a;a=MC(this.a,this.fl);AC();this.jo=x();var b=this.a.A;null!=b?(this.eh=b[0],(this.hh=b[1])?(this.Sb=1,NC(this)):(this.Sb=2,OC(this))):(Fe(a,"MODE","init"),this.Qb=new kC(this,this.b,void 0,void 0,void 0),this.Qb.Fe=this.Mk,qC(this.Qb,a,!1,null,!0),this.Sb=0)};
-function NC(a){var b=PC(a.a,a.hh,"/mail/images/cleardot.gif");He(b);IC(b.toString(),5E3,v(a.Ev,a),3,2E3);a.Cc(1)}f.Ev=function(a){if(a)this.Sb=2,OC(this);else{AC();var b=this.a;b.a.debug("Test Connection Blocked");b.zd=b.le.$e;QC(b,9)}a&&this.Cc(2)};
-function OC(a){a.b.debug("TestConnection: starting stage 2");var b=a.a.B;if(null!=b)a.b.debug("TestConnection: skipping stage 2, precomputed result is "+b?"Buffered":"Unbuffered"),AC(),b?(AC(),RC(a.a,a,!1)):(AC(),RC(a.a,a,!0));else if(a.Qb=new kC(a,a.b,void 0,void 0,void 0),a.Qb.Fe=a.Mk,b=TC(a.a,a.eh,a.fl),AC(),!C||sc(10))Fe(b,"TYPE","xmlhttp"),qC(a.Qb,b,!1,a.eh,!1);else{Fe(b,"TYPE","html");var c=a.Qb;a=Boolean(a.eh);c.Lf=3;c.$d=He(b.clone());DC(c,a)}}f.Dk=function(a){return this.a.Dk(a)};
-f.abort=function(){this.Qb&&(this.Qb.cancel(),this.Qb=null);this.$e=-1};f.Ib=function(){return!1};
-f.mp=function(a,b){this.$e=a.zg;if(0==this.Sb)if(this.b.debug("TestConnection: Got data for stage 1"),b){try{var c=this.g.parse(b)}catch(d){UC(this.a,this);return}this.eh=c[0];this.hh=c[1]}else this.b.debug("TestConnection: Null responseText"),UC(this.a,this);else if(2==this.Sb)if(this.Gi)AC(),this.Zk=x();else if("11111"==b){if(AC(),this.Gi=!0,this.Fi=x(),c=this.Fi-this.jo,!C||sc(10)||500>c)this.$e=200,this.Qb.cancel(),this.b.debug("Test connection succeeded; using streaming connection"),AC(),RC(this.a,
-this,!0)}else AC(),this.Fi=this.Zk=x(),this.Gi=!1};
-f.ci=function(){this.$e=this.Qb.zg;if(!this.Qb.Dc)this.b.debug("TestConnection: request failed, in state "+this.Sb),0==this.Sb?AC():2==this.Sb&&AC(),UC(this.a,this);else if(0==this.Sb)this.b.debug("TestConnection: request complete for initial check"),this.hh?(this.Sb=1,NC(this)):(this.Sb=2,OC(this));else if(2==this.Sb){this.b.debug("TestConnection: request complete for stage 2");var a=!1;(a=!C||sc(10)?this.Gi:200>this.Zk-this.Fi?!1:!0)?(this.b.debug("Test connection succeeded; using streaming connection"),AC(),
-RC(this.a,this,!0)):(this.b.debug("Test connection failed; not using streaming"),AC(),RC(this.a,this,!1))}};f.oi=function(){return this.a.oi()};f.Cc=function(a){this.a.Cc(a)};function VC(a){Bi.call(this);this.headers=new Vd;this.j=a||null;this.b=!1;this.I=this.a=null;this.O=this.A="";this.i=0;this.k="";this.g=this.M=this.H=this.K=!1;this.o=0;this.B=null;this.P="";this.G=this.Q=!1}y(VC,Bi);var WC=/^https?$/i,XC=["POST","PUT"];f=VC.prototype;
-f.send=function(a,b,c,d){if(this.a)throw Error("[goog.net.XhrIo] Object is active with another request="+this.A+"; newUri="+a);b=b?b.toUpperCase():"GET";this.A=a;this.k="";this.i=0;this.O=b;this.K=!1;this.b=!0;this.a=this.j?hC(this.j):hC(fC);this.I=this.j?this.j.a||(this.j.a=jC(this.j)):fC.a||(fC.a=jC(fC));this.a.onreadystatechange=v(this.Xm,this);try{dC(YC(this,"Opening Xhr")),this.M=!0,this.a.open(b,a,!0),this.M=!1}catch(e){dC(YC(this,"Error opening Xhr: "+e.message));ZC(this,e);return}a=c||"";
-var g=this.headers.clone();d&&$d(d,function(a,b){g.set(b,a)});d=Oa(g.uc(),$C);c=l.FormData&&a instanceof l.FormData;!Sa(XC,b)||d||c||g.set("Content-Type","application/x-www-form-urlencoded;charset=utf-8");$d(g,function(a,b){this.a.setRequestHeader(b,a)},this);this.P&&(this.a.responseType=this.P);"withCredentials"in this.a&&(this.a.withCredentials=this.Q);try{aD(this),0<this.o&&(this.G=C&&rc(9)&&ga(this.a.timeout)&&q(this.a.ontimeout),dC(YC(this,"Will abort after "+this.o+"ms if incomplete, xhr2 "+
-this.G)),this.G?(this.a.timeout=this.o,this.a.ontimeout=v(this.vc,this)):this.B=Gi(this.vc,this.o,this)),dC(YC(this,"Sending request")),this.H=!0,this.a.send(a),this.H=!1}catch(h){dC(YC(this,"Send error: "+h.message)),ZC(this,h)}};function $C(a){return"content-type"==a.toLowerCase()}f.vc=function(){"undefined"!=typeof aa&&this.a&&(this.k="Timed out after "+this.o+"ms, aborting",this.i=8,YC(this,this.k),Ci(this,"timeout"),this.abort(8))};
-function ZC(a,b){a.b=!1;a.a&&(a.g=!0,a.a.abort(),a.g=!1);a.k=b;a.i=5;bD(a);cD(a)}function bD(a){a.K||(a.K=!0,Ci(a,"complete"),Ci(a,"error"))}f.abort=function(a){this.a&&this.b&&(YC(this,"Aborting"),this.b=!1,this.g=!0,this.a.abort(),this.g=!1,this.i=a||7,Ci(this,"complete"),Ci(this,"abort"),cD(this))};f.F=function(){this.a&&(this.b&&(this.b=!1,this.g=!0,this.a.abort(),this.g=!1),cD(this,!0));VC.C.F.call(this)};f.Xm=function(){this.ha()||(this.M||this.H||this.g?dD(this):this.yw())};f.yw=function(){dD(this)};
-function dD(a){if(a.b&&"undefined"!=typeof aa)if(a.I[1]&&4==sC(a)&&2==tC(a))YC(a,"Local request error detected and ignored");else if(a.H&&4==sC(a))Gi(a.Xm,0,a);else if(Ci(a,"readystatechange"),4==sC(a)){YC(a,"Request complete");a.b=!1;try{var b=tC(a),c,d;t:switch(b){case 200:case 201:case 202:case 204:case 206:case 304:case 1223:d=!0;break t;default:d=!1}if(!(c=d)){var e;if(e=0===b){var g=ce(String(a.A))[1]||null;if(!g&&self.location)var h=self.location.protocol,g=h.substr(0,h.length-1);e=!WC.test(g?
-g.toLowerCase():"")}c=e}if(c)Ci(a,"complete"),Ci(a,"success");else{a.i=6;var k;try{k=2<sC(a)?a.a.statusText:""}catch(m){k=""}a.k=k+" ["+tC(a)+"]";bD(a)}}finally{cD(a)}}}function cD(a,b){if(a.a){aD(a);var c=a.a,d=a.I[0]?ba:null;a.a=null;a.I=null;b||Ci(a,"ready");try{c.onreadystatechange=d}catch(e){}}}function aD(a){a.a&&a.G&&(a.a.ontimeout=null);ga(a.B)&&(l.clearTimeout(a.B),a.B=null)}function sC(a){return a.a?a.a.readyState:0}function tC(a){try{return 2<sC(a)?a.a.status:-1}catch(b){return-1}}
-function uC(a){try{return a.a?a.a.responseText:""}catch(b){return""}}function YC(a,b){return b+" ["+a.O+" "+a.A+" "+tC(a)+"]"};function eD(a,b,c){this.H=a||null;this.b=1;this.g=[];this.i=[];this.a=new HC;this.k=new cC(null,!0);this.A=b||null;this.B=null!=c?c:null}function fD(a,b){this.a=a;this.map=b;this.Z=null}f=eD.prototype;f.lh=null;f.Ab=null;f.La=null;f.Hk=null;f.gi=null;f.Yn=null;f.xi=null;f.Qg=0;f.Gu=0;f.pb=null;f.ie=null;f.Ld=null;f.af=null;f.le=null;f.ji=null;f.xf=-1;f.to=-1;f.zd=-1;f.Rg=0;f.Jf=0;f.Ke=8;var gD=new Bi;function hD(a){ai.call(this,"statevent",a)}y(hD,ai);
-function iD(a,b){ai.call(this,"timingevent",a);this.size=b}y(iD,ai);function jD(a){ai.call(this,"serverreachability",a)}y(jD,ai);f=eD.prototype;f.connect=function(a,b,c,d,e){this.a.debug("connect()");AC();this.Hk=b;this.lh=c||{};d&&q(e)&&(this.lh.OSID=d,this.lh.OAID=e);this.a.debug("connectTest_()");this.le=new LC(this,this.a);this.le.Mk=null;this.le.g=this.k;this.le.connect(a)};
-f.disconnect=function(){this.a.debug("disconnect()");kD(this);if(3==this.b){var a=this.Qg++,b=this.gi.clone();Ee(b,"SID",this.j);Ee(b,"RID",a);Ee(b,"TYPE","terminate");lD(this,b);a=new kC(this,this.a,this.j,a,void 0);a.Lf=2;a.$d=He(b.clone());(new Image).src=a.$d;a.Bg=x();rC(a)}mD(this)};function kD(a){a.le&&(a.le.abort(),a.le=null);a.La&&(a.La.cancel(),a.La=null);a.Ld&&(l.clearTimeout(a.Ld),a.Ld=null);nD(a);a.Ab&&(a.Ab.cancel(),a.Ab=null);a.ie&&(l.clearTimeout(a.ie),a.ie=null)}
-f.Ib=function(){return 0==this.b};function oD(a){var b=0;a.La&&b++;a.Ab&&b++;return b}function pD(a){a.Ab||a.ie||(a.ie=EC(v(a.wo,a),0),a.Rg=0)}
-f.wo=function(a){this.ie=null;this.a.debug("startForwardChannel_");if(1==this.b){if(!a){this.a.debug("open_()");this.Qg=Math.floor(1E5*Math.random());a=this.Qg++;var b=new kC(this,this.a,"",a,void 0);b.Fe=null;var c=qD(this),d=this.gi.clone();Ee(d,"RID",a);this.H&&Ee(d,"CVER",this.H);lD(this,d);oC(b,d,c);this.Ab=b;this.b=2}}else 3==this.b&&(a?rD(this,a):0==this.g.length?this.a.debug("startForwardChannel_ returned: nothing to send"):this.Ab||(rD(this),this.a.debug("startForwardChannel_ finished, sent request")))};
-function rD(a,b){var c,d;b?6<a.Ke?(a.g=a.i.concat(a.g),a.i.length=0,c=a.Qg-1,d=qD(a)):(c=b.g,d=b.ce):(c=a.Qg++,d=qD(a));var e=a.gi.clone();Ee(e,"SID",a.j);Ee(e,"RID",c);Ee(e,"AID",a.xf);lD(a,e);c=new kC(a,a.a,a.j,c,a.Rg+1);c.Fe=null;c.setTimeout(Math.round(1E4)+Math.round(1E4*Math.random()));a.Ab=c;oC(c,e,d)}function lD(a,b){if(a.pb){var c=a.pb.Yp(a);c&&$d(c,function(a,c){Ee(b,c,a)})}}
-function qD(a){var b=Math.min(a.g.length,1E3),c=["count="+b],d;6<a.Ke&&0<b?(d=a.g[0].a,c.push("ofs="+d)):d=0;for(var e=0;e<b;e++){var g=a.g[e].a,h=a.g[e].map,g=6>=a.Ke?e:g-d;try{$d(h,function(a,b){c.push("req"+g+"_"+b+"="+encodeURIComponent(a))})}catch(k){c.push("req"+g+"_type="+encodeURIComponent("_badmap"))}}a.i=a.i.concat(a.g.splice(0,b));return c.join("&")}function sD(a){a.La||a.Ld||(a.o=1,a.Ld=EC(v(a.Zo,a),0),a.Jf=0)}
-function tD(a){if(a.La||a.Ld||3<=a.Jf)return!1;a.a.debug("Going to retry GET");a.o++;a.Ld=EC(v(a.Zo,a),uD(a,a.Jf));a.Jf++;return!0}
-f.Zo=function(){this.Ld=null;this.a.debug("Creating new HttpRequest");this.La=new kC(this,this.a,this.j,"rpc",this.o);this.La.Fe=null;this.La.lk=0;var a=this.Yn.clone();Ee(a,"RID","rpc");Ee(a,"SID",this.j);Ee(a,"CI",this.ji?"0":"1");Ee(a,"AID",this.xf);lD(this,a);if(!C||sc(10))Ee(a,"TYPE","xmlhttp"),qC(this.La,a,!0,this.xi,!1);else{Ee(a,"TYPE","html");var b=this.La,c=Boolean(this.xi);b.Lf=3;b.$d=He(a.clone());DC(b,c)}this.a.debug("New Request created")};
-function RC(a,b,c){a.a.debug("Test Connection Finished");a.ji=c;a.zd=b.$e;a.a.debug("connectChannel_()");a.Cv(1,0);a.gi=MC(a,a.Hk);pD(a)}function UC(a,b){a.a.debug("Test Connection Failed");a.zd=b.$e;QC(a,2)}
-f.mp=function(a,b){if(0!=this.b&&(this.La==a||this.Ab==a))if(this.zd=a.zg,this.Ab==a&&3==this.b)if(7<this.Ke){var c;try{c=this.k.parse(b)}catch(d){c=null}if(t(c)&&3==c.length){var e=c;if(0==e[0])t:if(this.a.debug("Server claims our backchannel is missing."),this.Ld)this.a.debug("But we are currently starting the request.");else{if(this.La)if(this.La.Bg+3E3<this.Ab.Bg)nD(this),this.La.cancel(),this.La=null;else break t;tD(this);AC()}else this.to=e[1],c=this.to-this.xf,0<c&&(e=e[2],this.a.debug(e+" bytes (in "+
-c+" arrays) are outstanding on the BackChannel"),37500>e&&this.ji&&0==this.Jf&&!this.af&&(this.af=EC(v(this.Fu,this),6E3)))}else this.a.debug("Bad POST response data returned"),QC(this,11)}else"y2f%"!=b&&(this.a.debug("Bad data returned - missing/invald magic cookie"),QC(this,11));else if(this.La==a&&nD(this),!/^[\s\xa0]*$/.test(b))for(c=this.k.parse(b),t(c),e=0;e<c.length;e++){var g=c[e];this.xf=g[0];g=g[1];2==this.b?"c"==g[0]?(this.j=g[1],this.xi=g[2],g=g[3],null!=g?this.Ke=g:this.Ke=6,this.b=3,
-this.pb&&this.pb.ro(this),this.Yn=TC(this,this.xi,this.Hk),sD(this)):"stop"==g[0]&&QC(this,7):3==this.b&&("stop"==g[0]?QC(this,7):"noop"!=g[0]&&this.pb&&this.pb.qo(this,g),this.Jf=0)}};f.Fu=function(){null!=this.af&&(this.af=null,this.La.cancel(),this.La=null,tD(this),AC())};function nD(a){null!=a.af&&(l.clearTimeout(a.af),a.af=null)}
-f.ci=function(a){this.a.debug("Request complete");var b;if(this.La==a)nD(this),this.La=null,b=2;else if(this.Ab==a)this.Ab=null,b=1;else return;this.zd=a.zg;if(0!=this.b)if(a.Dc)1==b?(x(),Ci(gD,new iD(gD,a.ce?a.ce.length:0)),pD(this),this.i.length=0):sD(this);else{var c=a.Le;if(3==c||7==c||0==c&&0<this.zd)this.a.debug("Not retrying due to error type");else{this.a.debug("Maybe retrying, last error: "+lC(c,this.zd));var d;if(d=1==b)this.Ab||this.ie?d=!1:1==this.b||2<=this.Rg?d=!1:(this.a.debug("Going to retry POST"),
-this.ie=EC(v(this.wo,this,a),uD(this,this.Rg)),this.Rg++,d=!0);if(d||2==b&&tD(this))return;this.a.debug("Exceeded max number of retries")}this.a.debug("Error: HTTP request failed");switch(c){case 1:QC(this,5);break;case 4:QC(this,10);break;case 3:QC(this,6);break;case 7:QC(this,12);break;default:QC(this,2)}}};function uD(a,b){var c=5E3+Math.floor(1E4*Math.random());a.pb||(a.a.debug("Inactive channel"),c*=2);return c*b}
-f.Cv=function(a){if(!Sa(arguments,this.b))throw Error("Unexpected channel state: "+this.b);};function QC(a,b){a.a.info("Error code "+b);if(2==b||9==b){var c=null;a.pb&&(c=null);var d=v(a.Fv,a);c||(c=new qe("//www.google.com/images/cleardot.gif"),He(c));JC(c.toString(),1E4,d)}else AC();vD(a,b)}f.Fv=function(a){a?(this.a.info("Successfully pinged google.com"),AC()):(this.a.info("Failed to ping google.com"),AC(),vD(this,8))};
-function vD(a,b){a.a.debug("HttpChannel: error - "+b);a.b=0;a.pb&&a.pb.To(a,b);mD(a);kD(a)}function mD(a){a.b=0;a.zd=-1;if(a.pb)if(0==a.i.length&&0==a.g.length)a.pb.Pk(a);else{a.a.debug("Number of undelivered maps, pending: "+a.i.length+", outgoing: "+a.g.length);var b=$a(a.i),c=$a(a.g);a.i.length=0;a.g.length=0;a.pb.Pk(a,b,c)}}function MC(a,b){var c=PC(a,null,b);a.a.debug("GetForwardChannelUri: "+c);return c}function TC(a,b,c){b=PC(a,a.oi()?b:null,c);a.a.debug("GetBackChannelUri: "+b);return b}
-function PC(a,b,c){var d=Ie(c);if(""!=d.Se)b&&se(d,b+"."+d.Se),te(d,d.rh);else var e=window.location,d=Je(e.protocol,b?b+"."+e.hostname:e.hostname,e.port,c);a.lh&&$d(a.lh,function(a,b){Ee(d,b,a)});Ee(d,"VER",a.Ke);lD(a,d);return d}f.Dk=function(a){if(a)throw Error("Can't create secondary domain capable XhrIo object.");a=new VC;a.Q=!1;return a};function EC(a,b){if(!ha(a))throw Error("Fn must not be null and must be a function");return l.setTimeout(function(){a()},b)}f.Cc=function(){Ci(gD,new jD(gD))};
-function AC(){Ci(gD,new hD(gD))}f.oi=function(){return!(!C||sc(10))};function wD(){}f=wD.prototype;f.ro=function(){};f.qo=function(){};f.To=function(){};f.Pk=function(){};f.Yp=function(){return{}};function xD(a){a&&(this.id=a.id||a.name,this.name=a.name,this.app=a.app,this.type=a.type||"REMOTE_CONTROL",this.rp=a.user||"")}f=xD.prototype;f.id="";f.name="";f.app="";f.type="REMOTE_CONTROL";f.rp="";f.equals=function(a){return a?this.id==a.id:!1};function yD(a,b){this.action=a;this.params=b||null};function zD(){v(this.i,this);this.a=new aC;this.a.b=!1;this.b=this.a.a=!1;this.g="";this.j={}}function AD(){var a=BD;!0!=a.b&&(UB(),a.b=!0)}zD.prototype.i=function(a){if(!this.j[a.g]){var b=bC(this.a,a),c=CD;if(c)switch(a.j){case OB:DD(c,"info",b);break;case PB:DD(c,"error",b);break;case QB:DD(c,"warn",b);break;default:DD(c,"debug",b)}else window.opera?window.opera.postError(b):this.g+=b}};var BD=null,CD=window.console;function DD(a,b,c){if(a[b])a[b](c);else a.log(c)};var ED=null,FD=null,GD=Array(50),HD=-1,ID=!1;function JD(a){var b=(HD+1)%50;HD=b;GD[b]=a;ID||(ID=49==b)}function KD(a){var b=GD;if(b[0]){var c=HD,d=ID?c:-1;do{var d=(d+1)%50,e=b[d];z(a,function(a){a(e)})}while(d!=c);GD=Array(50);HD=-1;ID=!1}}
-function LD(){var a=MD,b=n("yt.mdx.remote.debug.logger_"),c=n("yt.mdx.remote.debug.handlers_");b&&c||(BD||(BD=new zD),-1!=window.location.href.indexOf("Debug=true")&&AD(),AD(),BD.a.a=!0,(b=n("yt.mdx.remote.debug.logger_"))||(b=VB("yt.mdx.remote")),ED=b,MB.prototype.log=MB.prototype.log,MB.prototype.getLogRecord=MB.prototype.Jv,MB.prototype.addHandler=MB.prototype.Iv,MB.prototype.removeHandler=MB.prototype.Kv,pa("yt.mdx.remote.debug.logger_",ED),FD=n("yt.mdx.remote.debug.handlers_")||[],pa("yt.mdx.remote.debug.handlers_",
-FD),n("yt.mdx.remote.debug.logger_"),c=n("yt.mdx.remote.debug.handlers_"));c&&(c.push(a),KD(c))}function ND(a,b){var c=n("yt.mdx.remote.debug.logger_"),d=n("yt.mdx.remote.debug.handlers_");if(c){if(c.log(RB,a+": "+b,void 0),d&&!Ta(d)){KD(d);var e=c.getLogRecord(RB,a+": "+b,void 0);z(d,function(a){a(e)})}}else d&&!Ta(d)||JD(new KB(RB,String(b),"yt.mdx.remote"))};function OD(){if(!("cast"in window))return!1;var a=window.cast||{};return"ActivityStatus"in a&&"Api"in a&&"LaunchRequest"in a&&"Receiver"in a}function PD(a){ND("CAST",a)}function MD(a){var b=QD();b&&b.logMessage&&(a=bC(RD,a),b.logMessage(a))}
-function SD(){if(!TD&&(Ta(UD)&&ab(UD,Kg()),OD())){var a=QD();a?(a.removeReceiverListener("YouTube",VD),a.addReceiverListener("YouTube",VD),PD("API initialized in the other binary")):(a=new cast.Api,pa("yt.mdx.remote.castapi.api_",a),a.addReceiverListener("YouTube",VD),a.setReloadTabRequestHandler&&a.setReloadTabRequestHandler(function(){window.location.reload()}),RD=new aC,RD.b=!1,RD.a=!1,LD(),PD("API initialized"));TD=!0}}
-function WD(a){var b=Pa(UD,function(b){return b.id==a.id});0<=b&&(UD[b]=jg(a))}function VD(a){PD("Updating receivers: "+ob(a));XD(a);Lr("yt-remote-cast-device-list-update",YD());z(YD(),function(a){ZD(a.id)});z(a,function(a){a.isTabProjected&&(a=$D(a.id),PD("Detected device: "+a.id+" is tab projected. Firing DEVICE_TAB_PROJECTED event."),Lr("yt-remote-cast-device-tab-projected",a))})}
-function aE(a,b){PD("Updating "+a+" activity status: "+ob(b));var c=$D(a);c?(b.activityId&&(c.activityId=b.activityId),c.status="running"==b.status?"RUNNING":"stopped"==b.status?"STOPPED":"error"==b.status?"ERROR":"UNKNOWN","RUNNING"!=c.status&&(c.activityId=""),WD(c),Lr("yt-remote-cast-device-status-update",c)):PD("Device not found")}function YD(){SD();return pg(UD)}
-function XD(a){a=Ka(a,function(a){var c={id:a.id,name:a.name};if(a=$D(a.id))c.activityId=a.activityId,c.status=a.status;return c});Ua(UD);ab(UD,a)}function $D(a){var b=YD();return Oa(b,function(b){return b.id==a})||null}function ZD(a){var b=$D(a),c=QD();c&&b&&b.activityId&&c.getActivityStatus(b.activityId,function(b){"error"==b.status&&(b.status="stopped");aE(a,b)})}
-function bE(a){SD();var b=$D(a),c=QD();c&&b&&b.activityId?(PD("Stopping cast activity"),c.stopActivity(b.activityId,oa(aE,a))):PD("Dropping cast activity stop")}function QD(){return n("yt.mdx.remote.castapi.api_")}var RD=null,TD=!1,UD=n("yt.mdx.remote.castapi.devices_")||[];pa("yt.mdx.remote.castapi.devices_",UD);function cE(a,b){Ei.call(this);if(ha(a))b&&(a=v(a,b));else if(a&&ha(a.handleEvent))a=v(a.handleEvent,a);else throw Error("Invalid listener argument");this.o=a;ri(this,"tick",v(this.k,this));this.stop();Fi(this,5E3+2E4*Math.random())}y(cE,Ei);cE.prototype.j=0;cE.prototype.k=function(){if(500<this.a){var a=this.a;24E4>2*a&&(a*=2);Fi(this,a)}this.o()};cE.prototype.start=function(){cE.C.start.call(this);this.j=x()+this.a};cE.prototype.stop=function(){this.j=0;cE.C.stop.call(this)};function dE(a,b){this.k=a;this.j=b;this.g=new Wh;this.b=new cE(this.Wt,this);this.a=null}y(dE,wD);f=dE.prototype;f.ai="";f.Vg=0;f.Hi=0;f.Me=function(){};f.D=function(a,b,c){return this.g.D(a,b,c)};f.$=function(a,b,c){return this.g.$(a,b,c)};f.Wc=function(a){return this.g.Wc(a)};f.u=function(a,b){return this.g.u.apply(this.g,arguments)};
-f.connect=function(a,b,c){if(!this.a||2!=this.a.b){this.ai="";this.b.stop();this.i=a||null;this.Vg=b||0;a=this.k+"/test";b=this.k+"/bind";var d=new eD("1",c?c.firstTestResults:null,c?c.secondTestResults:null),e=this.a;e&&(e.pb=null);d.pb=this;this.a=d;e?(3!=e.b&&0==oD(e)||this.Me("Unexpected state on old channel when reconnecting: "+e.b),this.a.connect(a,b,this.j,e.j,e.xf)):c?this.a.connect(a,b,this.j,c.sessionId,c.arrayId):this.a.connect(a,b,this.j)}};
-f.disconnect=function(a){this.Hi=a||0;this.b.stop();this.a&&0!=this.a.b&&this.a.disconnect();this.Hi=0};f.sendMessage=function(a,b){if(!this.a||0==this.a.b||2!=this.a.b&&3!=this.a.b&&!this.b.Xc)this.Me("Ignoring message: "+a);else{var c={_sc:a};b&&Ob(c,b);var d=this.a;if(0==d.b)throw Error("Invalid operation: sending map when state is closed");1E3==d.g.length&&ob(c);d.g.push(new fD(d.Gu++,c));2!=d.b&&3!=d.b||pD(d)}};
-f.ro=function(){var a=this.b;a.stop();Fi(a,5E3+2E4*Math.random());this.i=null;this.Vg=0;this.u("handlerOpened")};f.To=function(a,b){var c=2==b&&401==this.a.zd;4==b||c||(6==b&&(c=this.b,c.stop(),Fi(c,500)),this.b.start());this.u("handlerError",b)};f.Pk=function(){this.b.Xc||this.u("handlerClosed")};f.Yp=function(){var a={v:2};this.ai&&(a.gsessionid=this.ai);0!=this.Vg&&(a.ui=""+this.Vg);0!=this.Hi&&(a.ui=""+this.Hi);this.i&&Ob(a,this.i);return a};
-f.qo=function(a,b){"S"==b[0]?this.ai=b[1]:this.g.u("handlerMessage",new yD(b[0],b[1]))};function eE(a,b){(a.j.loungeIdToken=b)||a.b.stop()}function fE(a){return a.b.Xc?a.b.j-x():NaN}f.Wt=function(){this.b.stop();0!=oD(this.a)?this.b.start():this.connect(this.i,this.Vg)};function gE(a,b){dE.call(this,a,b)}y(gE,dE);gE.prototype.Me=function(){};function hE(){this.yb=[];this.index=-1;iE(this)}function iE(a){a.volume=-1;a.muted=!1;a.b=null;a.a=-1;a.g=null;a.i=0;a.j=x()}function jE(a){return a.yb[a.index]}function kE(a,b){a.i=b;a.j=x()}function lE(a){switch(a.a){case 1:return(x()-a.j)/1E3+a.i;case -1E3:return 0}return a.i}function mE(a,b){var c=a.index;a.index=Ia(a.yb,b);c!=a.index&&iE(a)}function nE(a,b,c){c=c||jE(a);if(ib(a.yb,b)&&c==jE(a))return!1;a.yb=$a(b);mE(a,c);return!0}
-hE.prototype.add=function(a,b){return a&&!Sa(this.yb,a)?(!b||-1<this.index&&this.index>=this.yb.length-1?this.yb.push(a):this.yb.splice(this.index+1,0,a),!0):!1};hE.prototype.remove=function(a){var b=jE(this);return Wa(this.yb,a)?(this.index=Ia(this.yb,b),!0):!1};function oE(){R.call(this);this.Hc=tg(Hg());this.log_("Initializing local screens: "+Jf(this.Hc));this.g=[];this.Ak=null;this.b=[];this.a=[];this.Bi(YD());this.log_("Initializing DIAL devices: "+kg(this.a));var a=tg(Ig());pE(this,a);this.log_("Initializing online screens: "+Jf(this.b));qE(this)}y(oE,R);var rE=[2E3,2E3,1E3,1E3,1E3,2E3,2E3,5E3,5E3,1E4];f=oE.prototype;f.oh=NaN;f.log_=function(a){ND("RM",a)};
-function sE(a){var b=navigator.userAgent;if(0<=b.search("MSIE")&&(b=b.match(/MSIE ([\d.]+)/)[1],0>Ba(b,"10.0")))return a;b=ce(document.location.href);return ae("https",null,b[3],null,a)}function qE(a){Gr("yt-remote-cast-device-list-update",a.Bi,a);Gr("yt-remote-cast-device-status-update",a.mx,a);Gr("yt-remote-cast-device-tab-projected",function(a){this.u("connectToReceiver",a.id)},a);a.Ep();gf(v(a.Ep,a),1E4)}
-f.u=function(a,b){if(this.ha())return!1;this.log_("Firing "+a);return this.H.u.apply(this.H,arguments)};f.Ep=function(){var a=YD();Ta(a)||this.Bi(a);a=tE(this);Ta(a)||(eg("yt-remote-lounge-token-expiration")?uE(this,a):vE(this))};f.dl=function(){var a=tE(this),b=Ja(a,function(a){return!!wg(this.b,a)},this);pE(this,b);this.Bi(YD());this.u("managedScreenChange",a)};function wE(a,b){return Ja(b,function(a){return a.Cb?(a=rg(this.a,a.Cb),!!a&&"RUNNING"==a.status):!0},a)}
-f.Bi=function(a){var b=!1;z(a,function(a){var c=xg(this.Hc,a.id);c&&c.name!=a.name&&(this.log_("Renaming screen id "+c.id+" from "+c.name+" to "+a.name),c.name=a.name,b=!0)},this);b&&(this.log_("Renaming due to DIAL."),xE(this));Jg(og(a));var c=!ib(this.a,a,qg);c&&this.log_("Updating DIAL devices: "+kg(this.a)+" to "+kg(a));this.a=a;pE(this,this.b);c&&this.u("onlineReceiverChange")};
-f.mx=function(a){var b=rg(this.a,a.id);b&&(this.log_("Updating DIAL device: "+b.id+"("+b.name+") from status: "+b.status+" to status: "+a.status+" and from activityId: "+b.activityId+" to activityId: "+a.activityId),b.activityId=a.activityId,b.status=a.status,Jg(og(this.a)));pE(this,this.b)};function pE(a,b,c){b=wE(a,b);var d=!ib(a.b,b,vg);!d&&!c||Ta(b)||(c=sg(b),bg("yt-remote-online-screens",c,60));d&&(a.log_("Updating online screens: "+Jf(a.b)+" -> "+Jf(b)),a.b=b,a.u("onlineReceiverChange"))}
-function uE(a,b){var c=[],d={};z(b,function(a){a.lc&&(d[a.lc]=a,c.push(a.lc))});var e={method:"POST",Mf:{lounge_token:c.join(",")},Z:a,Qa:function(a,b){var c=[];z(b.screens||[],function(a){"online"==a.status&&c.push(d[a.loungeToken])});var e=this.Ak?yE(this,this.Ak):null;e&&!wg(c,e)&&c.push(e);pE(this,c,!0)}};Qj(sE("/api/lounge/pairing/get_screen_availability"),e)}
-function vE(a){var b=tE(a),c=Ka(b,function(a){return a.mb});Ta(c)||(a.log_("Updating lounge tokens for: "+ob(c)),Qj(sE("/api/lounge/pairing/get_lounge_token_batch"),{Mf:{screen_ids:c.join(",")},method:"POST",Z:a,Qa:function(a,c){zE(this,c.screens||[]);this.Hc=Ja(this.Hc,function(a){return!!a.lc});xE(this);uE(this,b)}}))}function zE(a,b){z(Za(a.Hc,a.g),function(a){var d=Oa(b,function(b){return a.mb==b.screenId});d&&(a.lc=d.loungeToken)})}
-function xE(a){var b=tg(Hg());ib(a.Hc,b,vg)||(a.log_("Saving local screens: "+Jf(b)+" to "+Jf(a.Hc)),Gg(sg(a.Hc)),a.dl())}function AE(a,b,c){var d=Pa(b,function(a){return ug(c,a)}),e=0>d?!0:!1;0>d?b.push(c):b[d]=c;wg(a.b,c)||a.b.push(c);return e}
-f.$o=function(a,b,c){var d=!1;b>=rE.length&&(this.log_("Pairing DIAL device "+a+" with "+c+" timed out."),d=!0);var e=rg(this.a,a);if(!e)this.log_("Pairing DIAL device "+a+" with "+c+" failed: no device for "+a),d=!0;else if("ERROR"==e.status||"STOPPED"==e.status)this.log_("Pairing DIAL device "+a+" with "+c+" failed: launch error on "+a),d=!0;d?(BE(this),this.u("screenPair",null)):Qj(sE("/api/lounge/pairing/get_screen"),{method:"POST",Mf:{pairing_code:c},Z:this,Qa:function(a,b){BE(this);var d=new Hf(b.screen);
-d.name=e.name;d.Cb=e.id;var m=AE(this,this.Hc,d);this.log_("Paired with "+(m?"a new":"an old")+" local screen:"+If(d));xE(this);this.u("screenPair",d);this.log_("Pairing "+c+" succeeded.");this.u("screenPair",d)},onError:function(){this.log_("Polling pairing code: "+c);I(this.oh);this.oh=H(v(this.$o,this,a,b+1,c),rE[b])}})};
-function CE(a,b,c,d,e){BE(a);if(rg(a.a,b)){if(!c){var g=c=lg();SD();var h=$D(b),k=QD();if(k&&h){var m=new cast.Receiver(h.id,h.name),m=new cast.LaunchRequest("YouTube",m);m.parameters="pairingCode="+g;m.description=new cast.LaunchDescription;m.description.text=document.title;d&&(m.parameters+="&v="+d,e&&(m.parameters+="&t="+Math.round(e)),m.description.url="http://i.ytimg.com/vi/"+d+"/default.jpg");"UNKNOWN"!=h.status&&(h.status="UNKNOWN",WD(h),Lr("yt-remote-cast-device-status-update",h));PD("Sending a cast launch request with params: "+
-m.parameters);k.launch(m,oa(aE,b))}else PD("No cast API or no cast device. Dropping cast launch.")}a.oh=H(v(a.$o,a,b,0,c),rE[0])}else a.log_("No DIAL device with id: "+b)}function BE(a){I(a.oh);a.oh=NaN}function yE(a,b){var c=xg(tE(a),b);a.log_("Found screen: "+If(c)+" with key: "+b);return c}function DE(a,b){var c=xg(a.b,b);a.log_("Found online screen: "+If(c)+" with key: "+b);return c}
-function EE(a,b){var c=rg(a.a,b);if(!c){var d=xg(a.Hc,b);d&&(c=rg(a.a,d.Cb))}a.log_("Found DIAL: "+(c?c.toString():"null")+" with key: "+b);return c}function tE(a){return Za(a.g,Ja(a.Hc,function(a){return!wg(this.g,a)},a))};function FE(a,b){R.call(this);if(cg){var c=cg;ag(c,c.Of.Nd(!0))}yg();VB("goog.net.BrowserChannel");this.i=new oE;c=Ag();this.g=new gE("/api/lounge/bc",{device:"REMOTE_CONTROL",id:c,name:a,app:b});this.a=null;this.A=[];this.g.D("handlerOpened",this.Yu,this);this.g.D("handlerClosed",this.Vu,this);this.g.D("handlerError",this.Wu,this);this.g.D("handlerMessage",this.Xu,this);this.i.D("managedScreenChange",this.dl,this);this.log_("Initializing with device id = "+c+", name = "+a+", app = "+b)}y(FE,R);
-f=FE.prototype;f.Zg=NaN;f.$k=NaN;f.Yi=NaN;f.Zi=NaN;f.log_=function(a){ND("RC",a)};function GE(a){var b=Bg();return b?yE(a.i,b):null}function HE(a,b,c){a.$("connectionOpened",b,c);a.$("connectionClosed",b,c);a.$("connectionError",b,c)}function IE(a,b){"connectionError"==b&&fg("yt-remote-session-screen-id");a.log_("Firing "+b);a.u(b,"connectionOpened"==b);a.o=null}
-function JE(a,b){"playerChange"==b?(I(a.Yi),a.Yi=H(v(function(){this.u("playerChange");this.Yi=NaN},a),2E3)):"playlistChange"==b&&(I(a.Zi),a.Zi=H(v(function(){this.u("playlistChange");this.Zi=NaN},a),2E3))}function KE(a,b){"playerChange"==b&&isNaN(a.Yi)&&a.u("playerChange");"playlistChange"==b&&isNaN(a.Zi)&&a.u("playlistChange")}function LE(a,b){b?(a.log_("Changing current screen id from: "+a.j+" to "+b.mb),a.j=b.mb,eE(a.g,b.lc)):(a.log_("Removing current screen id: "+a.j),a.j="",eE(a.g,""))}
-function ME(a){return a.j?yE(a.i,a.j):null}f.connect=function(a){this.log_("Connecting to the receiver: "+ob(a));var b=DE(this.i,a.key);b?NE(this,b):(a=EE(this.i,a.key))?OE(this,a):H(v(function(){IE(this,"connectionError")},this),0)};function PE(a){a=a||0;5>=a&&(a=0);return a}
-function NE(a,b){a.log_("Connecting to screen: "+If(b));var c=GE(a);c&&!ug(b,c)?a.disconnect():QE(a);a.a=null;LE(a,b);c={};if(a.b){c.videoIds=RE(a.b).join(",");c.videoId=a.b.a.getVideoData().L;c.videoSources=SE(a.b).join(",");var d=a.o?a.o.currentTime:a.b.a.getCurrentTime();c.currentTime=PE(d)}Kb(c)?a.log_("Connecting with empty params"):a.log_("Connecting with setPlaylist and params: "+ob(c));a.b?Lg(a.b.a.getVideoData().L,TE(a.b)):Lg("","");a.g.connect(Kb(c)?{}:{method:"setPlaylist",params:ob(c)},
-1,Fg());a.a=new hE;Kb(c)||(a.a.yb=c.videoIds.split(","),mE(a.a,c.videoId));UE(a)}function OE(a,b){a.log_("Connecting to DIAL device: "+(b?b.toString():"null"));VE(a);WE(a);var c=a.o?a.o.pairingCode:"";c?CE(a.i,b.id,c):a.b?CE(a.i,b.id,"",a.b.a.getVideoData().L,a.b.a.getCurrentTime()):CE(a.i,b.id,"");a.k=b.id;a.i.D("screenPair",a.On,a)}f.On=function(a){this.log_("Paired with a DIAL screen: "+If(a));VE(this);a?NE(this,a):(this.k="",IE(this,"connectionError"))};
-f.disconnect=function(){this.log_("Disconnecting with user intent.");WE(this);Mg();this.g.disconnect(1)};function WE(a){BE(a.i);var b=Oa(a.A,function(a){return"REMOTE_CONTROL"==a.type});b?(a.log_("Did not stop DIAL device, because another remote is connected: "+ob(b?{id:b.id,name:b.name,app:b.app,type:b.type,user:b.rp}:null)),a.k=""):(b=ME(a),a.k?(a.log_("Stopping DIAL device: "+a.k),bE(a.k),a.k=""):b&&b.Cb&&(a.log_("Stopping DIAL device: "+b.Cb),bE(b.Cb)))}
-function QE(a){a.log_("Disconnecting from screen.");a.g.disconnect(2)}function XE(a,b){var c=ME(a),d=Oa(b,function(a){return c&&(a.key==c.mb||a.key==c.Cb)||this.k&&(a=EE(this.i,a.key))&&a.id==this.k?!0:!1},a);a.log_("Found current receiver: "+ob(d)+" in "+ob(b));return d}function YE(a){return ZE(a)?a.a:null}function $E(a,b,c){c?a.log_("Sending: action="+b+", params="+ob(c)):a.log_("Sending: action="+b);aF(a)?a.log_("Action = "+b+" was ignored due to reconnecting."):a.g.sendMessage(b,c)}
-function bF(a,b,c,d){d=PE(d);a.a.add(b,!0)&&$E(a,"insertVideo",{videoId:b,videoSource:c});kE(a.a,d);mE(a.a,b);JE(a,"playlistChange");$E(a,"setVideo",{currentTime:d,videoId:b})}function cF(a,b,c,d,e){e=PE(e);$E(a,"setPlaylist",{videoIds:c.join(","),videoId:b,videoSources:Ka(c,function(){return d}),currentTime:e});kE(a.a,e);nE(a.a,c,b);JE(a,"playlistChange")}
-function dF(a){var b=eg("yt-remote-session-video-id"),c=eg("yt-remote-session-list-id"),d=a.b.a.getVideoData().L,e=TE(a.b);Lg(d,e);a.log_("Watch context changed: videoId from "+b+" to "+d+" listId from "+c+" to "+e);var g=!1,h=!1;d&&d!=b&&(g=!0);e&&e!=c&&(h=!0);g?(b=SE(a.b),c=a.b.a.vb(),b=b[c?c.ua:0],c=a.b.a.getCurrentTime(),h?cF(a,d,RE(a.b),b,c):bF(a,d,b,c)):h&&(d=RE(a.b),h=SE(a.b),$E(a,"updatePlaylist",{videoIds:d.join(","),videoSources:h.join(",")}),nE(a.a,d),JE(a,"playlistChange"))}
-function eF(a){$E(a,"play");kE(a.a,lE(a.a));-1E3!=a.a.a&&(a.a.a=1);JE(a,"playerChange")}f.oo=function(){$E(this,"getNowPlaying")};function ZE(a){var b=a.g.a;return!!b&&3==b.b&&!!a.j&&isNaN(a.Zg)}function UE(a){fF(a);a.Zg=H(v(function(){fF(this);LE(this,null);this.k="";this.a=null;this.log_("Connecting timeout");IE(this,"connectionError");Mg();this.g.disconnect(1)},a),1E4)}function fF(a){I(a.Zg);a.Zg=NaN}function gF(a){I(a.$k);a.$k=NaN}function VE(a){a.i.$("screenPair",a.On,a)}
-f.Yu=function(){this.log_("Channel opened");var a=this.j;bg("yt-remote-session-browser-channel",{firstTestResults:[""],secondTestResults:!this.g.a.ji,sessionId:this.g.a.j,arrayId:this.g.a.xf});bg("yt-remote-session-screen-id",a);var a=zg(),b=Ag();Sa(a,b)||a.push(b);Dg(a);yg();this.b&&(this.b.a.getVideoData().Oa&&!TE(this.b)?this.log_("Wait for playlist data to be loaded."):dF(this))};function hF(a){Mg(!0);gF(a);a.i.Ak=null;LE(a,null);a.k=""}
-f.Vu=function(){this.log_("Channel closed");var a=!!this.j&&isNaN(this.Zg);hF(this);a&&IE(this,"connectionClosed")};f.Wu=function(a){aF(this)?this.log_("Channel error: "+a+" with reconnection in "+fE(this.g)+" ms"):this.log_("Channel error: "+a+" without reconnection");aF(this)||hF(this);fF(this);IE(this,"connectionError")};
-function iF(a,b){switch(b.action){case "loungeStatus":var c=mb(b.params.devices);a.A=Ka(c,function(a){return new xD(a)});break;case "loungeScreenDisconnected":Ya(a.A,function(a){return"LOUNGE_SCREEN"==a.type});break;case "remoteConnected":var d=new xD(mb(b.params.device));Oa(a.A,function(a){return a.equals(d)})||Va(a.A,d);break;case "remoteDisconnected":d=new xD(mb(b.params.device)),Ya(a.A,function(a){return a.equals(d)})}}
-function jF(a,b){var c=!1;if("loungeStatus"==b.action)c=!!Oa(a.A,function(a){return"LOUNGE_SCREEN"==a.type});else if("loungeScreenConnected"==b.action)c=!0;else if("loungeScreenDisconnected"==b.action)c=!1;else return;c!=ZE(a)&&(c?(fF(a),IE(a,"connectionOpened"),a.oo()):a.disconnect())}function aF(a){return!isNaN(fE(a.g))}
-f.Xu=function(a){a.params?this.log_("Received: action="+a.action+", params="+ob(a.params)):this.log_("Received: action="+a.action);iF(this,a);jF(this,a);if(ZE(this)){var b=!1,c=!1,d,e,g,h,k,m,p;a.params&&(d=a.params.videoId||a.params.video_id,e=a.params.videoIds||a.params.video_ids,g=a.params.state,h=a.params.currentTime||a.params.current_time,k=a.params.volume,m=a.params.muted,q(a.params.currentError)&&(p=mb(a.params.currentError)));if("onSubtitlesTrackChanged"==a.action)d==jE(this.a)&&(delete a.params.videoId,
-Kb(a.params)?this.a.b=null:this.a.b=a.params,KE(this,"playerChange"));else if(jE(this.a)||'"onStateChange"'!=a.action)"playlistModified"!=a.action&&"nowPlayingPlaylist"!=a.action||e?(d||"nowPlaying"!=a.action&&"nowPlayingPlaylist"!=a.action?d?d!=jE(this.a)&&(b=!0):d=jE(this.a):(mE(this.a,""),b=!0),e&&(e=e.split(","),nE(this.a,e,d)&&(b=!0))):(nE(this.a,[]),b=!0),this.a.add(d)&&$E(this,"getPlaylist"),d&&mE(this.a,d),b&&KE(this,"playlistChange"),q(g)&&(b=parseInt(g,10),b=isNaN(b)?-1:b,-1==b&&-1E3==this.a.a&&
-(b=-1E3),0==b&&"0"==h&&(b=-1),c=c||b!=this.a.a,this.a.a=b,d=null,-1E3==b&&(d=this.a.g||"unknown",p&&(d=p.reason||d)),c=c||this.a.g!=d,this.a.g=d,1==this.a.a?(gF(this),this.$k=H(v(this.oo,this),2E4)):gF(this)),"onError"!=a.action||-1!=this.a.a&&-1E3!=this.a.a||(a=mb(a.params.errors)||[],1==a.length&&"PLAYER_ERROR"==a[0].error&&a[0].videoId==jE(this.a)&&(this.a.a=-1E3,this.a.g=a[0].reason||"unknown",c=!0)),h&&(b=parseInt(h,10),kE(this.a,isNaN(b)?0:b),c=!0),q(k)&&(b=parseInt(k,10),isNaN(b)||(c=c||this.a.volume!=
-b,this.a.volume=b),q(m)&&(m="true"==m,c=c||this.a.muted!=m,this.a.muted=m)),c&&KE(this,"playerChange")}};f.dl=function(){this.j&&!ME(this)?(this.log_("Dropping current screen with id: "+this.j),this.disconnect(),this.a=null):GE(this)||Mg()};function kF(){FE.call(this,"Desktop","youtube-desktop");J(window,"unload",v(this.B,this));J(window,"beforeunload",v(this.B,this))}y(kF,FE);ca(kF);kF.prototype.B=function(){QE(this)};function lF(a,b){this.a=a;this.a.D("onVolumeChange",this.Vh,this);this.a.D("onPlaylistUpdate",this.an,this);this.i=NaN;this.b=b;this.b.D("playerChange",this.bn,this);this.b.D("playlistChange",this.cn,this);this.k=0;this.g={};this.j=new js(this.Ds,1E3,this);L(this,this.j);this.o=0}y(lF,K);f=lF.prototype;
-f.F=function(){mF(this);this.a.$("onVolumeChange",this.Vh,this);this.a.$("onPlaylistUpdate",this.an,this);this.a=null;this.b.$("playerChange",this.bn,this);this.b.$("playlistChange",this.cn,this);this.b=null};f.Yw=function(a,b){YE(this.b)&&(nF(this)?this.$v.apply(this,arguments):this.aw.apply(this,arguments))};
-f.aw=function(a,b){var c=Array.prototype.slice.call(arguments,1);switch(a){case "control_toggle_play_pause":case "control_play":case "control_pause":oF(this,this.a.a.getCurrentTime());break;case "control_seek":oF(this,c[0])}};
-f.$v=function(a,b){var c=YE(this.b),d=Array.prototype.slice.call(arguments,1);switch(a){case "control_toggle_play_pause":1==c.a?pF(this):(eF(this.b),this.a.kb(!0));break;case "control_play":eF(this.b);this.a.kb(!0);break;case "control_pause":pF(this);break;case "control_seek":this.o=d[0];ks(this.j);break;case "control_subtitles_set_track":qF(this,d[0])}};function pF(a){var b=a.b;$E(b,"pause");kE(b.a,lE(b.a));-1E3!=b.a.a&&(b.a.a=2);JE(b,"playerChange");rF(a,lE(YE(a.b)));mF(a);a.a.kb(!1)}
-f.Ds=function(){var a=this.o,b=YE(this.b);mF(this);rF(this,a);-1==b.a?oF(this,a):(b=this.b,a=Math.floor(a),$E(b,"seekTo",{newTime:a}),kE(b.a,a),-1E3!=b.a.a&&(b.a.a=3),JE(b,"playerChange"))};
-function qF(a,b){if(nF(a)){var c=a.b,d=a.a.a.getVideoData().L;b?(c.a.b={trackName:b.name,languageCode:b.languageCode,sourceLanguageCode:b.translationLanguage?b.translationLanguage.languageCode:"",languageName:b.languageName,format:b.format,kind:b.kind},d={videoId:d},Ob(d,c.a.b),$E(c,"setSubtitlesTrack",d)):$E(c,"setSubtitlesTrack");JE(c,"playerChange");a.g=YE(a.b).b}}function oF(a,b){bF(a.b,a.a.a.getVideoData().L,"VI",b);var c=a.a;sF(c);tF(c.g)}
-f.Vh=function(a){if(nF(this)){var b=Math.round(a.volume),c=this.b;a=!!a.muted;var d={volume:b,muted:a};-1!=c.a.volume&&(d.delta=b-c.a.volume);c.a.muted=a;c.a.volume=b;$E(c,"setVolume",d);JE(c,"playerChange")}};f.an=function(){dF(this.b)};
-f.bn=function(){if(nF(this)){var a=YE(this.b);mF(this);switch(a.a){case 1:uF(this);this.a.kb(!0);break;case 3:var b=this.a;sF(b);tF(b.g);break;case 0:this.a.kb(!1);this.j.stop();b=this.a.a;(b=O(b.app,b.a||1))&&b.ng(!0);rF(this,this.a.a.getVideoData().ta);break;case 2:this.a.kb(!1);rF(this,lE(a));break;case -1:this.a.kb(!1);break;case -1E3:var b=this.a,c=lf("REMOTE_PLAYER_ERROR");sF(b);vF(b.g,c)}0==this.k&&(b=this.a.a,(b=O(b.app,b.a||1))&&b.ng(!1));this.k=a.a;wF(this);b=Math.round(this.a.a.Om());-1!=
-a.volume&&b!=a.volume&&(this.a.$("onVolumeChange",this.Vh,this),this.a.a.Qm(a.volume),a.muted?this.a.a.Pm():this.a.a.Rm(),this.a.D("onVolumeChange",this.Vh,this))}else this.a.kb(!1)};
-function wF(a){var b=YE(a.b).b;if(!(b||a.g?b&&a.g&&b.trackName==a.g.trackName&&b.languageCode==a.g.languageCode&&b.languageName==a.g.languageName&&b.format==a.g.format&&b.kind==a.g.kind:1))if(a.g=b){var c=a.a.a.Cj("captions","tracklist",{yy:1}),c=Oa(c,function(a){return a.languageCode==b.languageCode&&a.name==b.trackName});a.a.a.dn("captions","track",c)}else a.a.a.en("captions")}f.cn=function(){nF(this)||(rF(this,0),mF(this),this.a.kb(!1))};
-function nF(a){var b=YE(a.b);return!!b&&jE(b)==a.a.a.getVideoData().L}function uF(a){mF(a);aF(a.b)||(rF(a,lE(YE(a.b))),a.i=H(v(function(){uF(this)},a),500))}function mF(a){I(a.i);a.i=NaN}function rF(a,b){var c=a.a.a.getVideoData().ta;a.a.u("command_progress",b,b/c,void 0)};function xF(){Z.call(this,["div",["html5-bezel","html5-center-overlay"],["div","{{icon}}"]]);this.a=NaN;this.hide()}y(xF,Z);xF.prototype.hide=function(){xF.C.hide.call(this);yF(this)};xF.prototype.setIcon=function(a){nn(this.template,"icon",a)};xF.prototype.show=function(a){yF(this);a&&this.setIcon(a);xF.C.show.call(this)};function yF(a){I(a.a);W(a.element,"html5-bezel-fade")};function zF(a){Z.call(this,["div","ytp-thumbnail"]);this.a=a}y(zF,Z);
-zF.prototype.show=function(a){if(a||this.element.childNodes.length){if(a){Xc(this.element);var b=this.element,c=this.a;if(void 0!=Tn("backgroundSize"))d=document.createElement("div"),d.style.backgroundImage="url("+Xn(b,a,c)+")";else{var d=document.createElement("img");d.src=Xn(b,a,c);a=d;b.clientWidth/b.clientHeight<Wn?(a.style.height="100%",a.style.width="auto"):(a.style.height="auto",a.style.width="100%")}V(d,"video-thumbnail");this.element.appendChild(d)}zF.C.show.call(this)}};function AF(a,b,c,d){R.call(this);this.P=d;this.b=this.a=null;this.I=c;this.O=new ao(lf("REMOTE_PLAYER_RECONNECT_TIME"),["formatted_time"]);this.B=new ao(lf("REMOTE_CONNECTED_STATUS"),["receiver_name"]);this.G=new ao(lf("REMOTE_CONNECTING_STATUS"),["receiver_name"]);this.M=new ao(lf("REMOTE_ERROR_STATUS"),["receiver_name"]);this.j=this.G;this.g=this.A=this.k=this.i=null;this.K="";this.o=null;this.k=E("ytp-remote-display-container",b);this.i=E("html5-remote-display-status-bar",b);BF(this);b=E("html5-remote-display-error",
-b);c=Uc("div");b.appendChild(c);V(c,"html5-remote-display-error-icon");this.A=Uc("div");b.appendChild(this.A);this.g=new En(this.P,"ytp-button-remote-reconnect");this.g.Aa(lf("REMOTE_PLAYER_RECONNECT_BUTTON"));this.g.V(b);this.K=J(this.g,"click",v(this.u,this,"reconnectclicked"));this.o=new zF(a.a.J().qc);this.o.V(this.k);this.o.show(a.a.getVideoData());L(this,this.o);this.a=new xF;this.a.V(this.k);this.a.hide();L(this,this.a);this.b=new Zt;V(this.b.element,"html5-center-overlay");V(this.b.element,
-"html5-center-transform");this.b.V(this.k);this.b.show();L(this,this.b)}y(AF,R);AF.prototype.F=function(){uf(this.K);this.i.innerHTML="";AF.C.F.call(this);this.o=this.i=this.a=null};function CF(a){a.j=a.G;BF(a);DF(a,!1);a.a.hide();a.b.show()}function tF(a){a.j=a.B;BF(a);DF(a,!1);a.a.hide();a.b.show()}function vF(a,b){a.j=a.M;BF(a);a.a.hide();a.b.hide();a.g.hide();a.A.innerHTML=b;DF(a,!0)}function DF(a,b){X(a.k,"ytp-remote-error",b)}
-function EF(a,b){vF(a,fo(a.O,{formatted_time:Nn(b/1E3)}));a.g.show()}function BF(a){a.i&&(a.i.innerHTML=fo(a.j,{receiver_name:'<span class="mdx-receiver">'+a.I+"</span>"},void 0,!0))};function FF(a){R.call(this);this.k=this.g="";this.j=null;this.i=a;this.a=this.b=null;GF(this,a)}y(FF,R);FF.prototype.F=function(){uf(this.g);uf(this.k)};function HF(a,b){var c="";z(b,function(a){c+=fo(this.j,{receiver_key:a.key,receiver_name:a.name})},a);a.a.innerHTML=c;hs(Xr.getInstance(),a.i)}function IF(a,b){var c=E("active",a.a);if(c){if(G(c,"value")==b)return;Qm(c,["active","selected"])}(c=a.a.querySelector('[data-value="'+b+'"]'))&&Pm(c,["active","selected"])}
-function GF(a,b){a.b=is(Xr.getInstance(),b);var c=E("html5-remote-receiver-template",a.b);a.j=eo(c,["receiver_key","receiver_name"]);a.a=E("html5-remote-receivers",a.b);a.a.innerHTML="";a.g=yf(a.b,v(a.o,a),"yt-uix-button-menu-item");a.k=J(b,"click",v(function(){this.u("menushown")},a))}FF.prototype.o=function(a){(a=a.currentTarget)&&"remote-select-receiver"==G(a,"action")&&(a=G(a,"value"),IF(this,a),this.u("selectreceiver",a))};function JF(a){Cx.call(this,a);var b=Q(this.a);this.G=a.S.B;this.k={key:lg(),name:lf("REMOTE_LOCAL_SCREEN")};this.g=this.j=null;this.b=KF(this);this.B=NaN;a=this.b;a.o=eg("yt-remote-delayed-connect-key");if(a.o)a.log_("Connecting with the delayed connect data: "+ob(a.o)),a.connect({key:a.o.key}),fg("yt-remote-delayed-connect-key");else{var c=GE(a);c?c.mb==a.j?a.log_("Skipping connecting because current connection exists."):(a.log_("Resuming MDx session: "+If(c)),LE(a,c),a.g.connect({},0,Fg()),a.a=
-new hE,UE(a)):(Mg(),a.log_("Skipping connecting because no session screen found."))}this.A=new FF(E("html5-remote-button",b));this.A.D("selectreceiver",this.Aj,this);L(this,this.A);this.i=this.k;this.pg()}y(JF,Cx);var LF=["play_pause","seek"],MF=["captions"];f=JF.prototype;f.qa="remote";f.hd="remote";f.Xa=function(){return this.app.I.J().sg};
-f.create=function(){JF.C.create.call(this);var a=this.b=KF(this),b=this.Jn;HE(a,b,this);a.D("connectionOpened",b,this);a.D("connectionClosed",b,this);a.D("connectionError",b,this);this.b.i.D("onlineReceiverChange",this.pg,this);this.b.i.D("connectToReceiver",this.Aj,this);this.pg();this.i!=this.k&&3<this.a.app.o&&this.load()};function NF(a){a.b&&(HE(a.b,a.Jn,a),a.b.i.$("onlineReceiverChange",a.pg,a),a.b.i.$("connectToReceiver",a.Aj,a),a.b.b=null,a.b=null)}
-f.destroy=function(){var a=this.A;bs(Xr.getInstance(),a.i);NF(this);JF.C.destroy.call(this)};
-f.load=function(){if(!this.ba){JF.C.load.call(this);this.pg();var a=E("html5-remote-module",Q(this.a));this.g=new AF(this,a,this.i.name,this.G);this.g.D("reconnectclicked",this.xm,this);this.j=new lF(this,this.b);qF(this.j,this.a.Cj("captions","track"));this.a.Dj();this.u("command_redirect_controls",this,LF,MF);var b=this.b.o?this.b.o.currentTime:0;0!=b&&H(v(function(){rF(this.j,b)},this),0);YE(this.b)&&!Ta(YE(this.b).yb)&&this.a.rg();this.ba=!0}};
-f.unload=function(){this.ba&&(this.ba=!1,OF(this,this.k),this.kb(!1),dn(this),this.g.$("reconnectclicked",this.xm,this),sF(this),Tg(this.j,this.g),this.g=this.j=null,JF.C.unload.call(this))};f.F=function(){NF(this);sF(this);Tg(this.j,this.g);this.g=this.j=null;JF.C.F.call(this)};function TE(a){return a.a.vb()?a.a.getVideoData().Oa:""}function RE(a){var b=a.a.vb();if(b){a=[];for(var c=0;c<b.Mb;c++)a[c]=vh(b,c).L;return a}return[a.a.getVideoData().L]}
-function SE(a){var b=TE(a);if(b){b=b.substr(0,2);a=Km(a.a.vb());for(var c=[],d=0;d<a;d++)c[d]=b;b=c}else b=["VI"];return b}function KF(a){var b=kF.getInstance();b.b=a;return b}f.Jn=function(){sF(this);this.ba&&aF(this.b)?PF(this):YE(this.b)?this.load():this.unload()};f.xm=function(){var a=this.b;aF(a)&&(a=a.g.b,a.Xc&&(a.stop(),a.start(),a.k()));CF(this.g)};f.oe=function(a,b){this.j.Yw.apply(this.j,arguments)};
-f.Aj=function(a){if(this.i.key!=a)if(this.k.key==a){var b=YE(this.b);a=!!b&&1==b.a&&jE(b)==this.a.getVideoData().L;b=b?lE(b):0;this.i=this.k;this.b.disconnect();this.unload();a&&(this.a.Wh(b),this.a.rg())}else if(a=mg(Ng(),a))OF(this,a),this.b.connect(a),this.load()};function OF(a,b){(a.i||b?a.i&&b&&a.i.key==b.key:1)||(a.i=b,IF(a.A,b.key))}f.pg=function(){var a=Ng();this.b&&(this.i=XE(this.b,a)||this.k);a.unshift(this.k);HF(this.A,a);IF(this.A,this.i.key);this.g&&(a=this.g,a.I=this.i.name,BF(a))};
-function PF(a){sF(a);aF(a.b)?(EF(a.g,fE(a.b.g)),a.B=H(v(function(){PF(this)},a),1E3)):CF(a.g)}function sF(a){I(a.B);a.B=NaN}f.kb=function(a){sF(this);var b=this.g;b.j=b.B;BF(b);DF(b,!1);b.b.hide();b.a.show();b.a.setIcon(a?"html5-bezel-pause":"html5-bezel-play");JF.C.kb.call(this,a)};function QF(){Z.call(this,["div","html5-video-info-panel",["span","html5-video-info-panel-close",{role:"button",title:"close"},"[x]"],["div","html5-video-info-panel-content",["table","html5-video-info-table",["tr","",["th","","Video ID:"],["td","","{{video_id}}"]],["tr","",["th","","Dimensions:"],["td","","{{dimensions}}"]],["tr","",["th","","Resolution:"],["td","","{{resolution}}"]],["tr","",["th","","Volume:"],["td","","{{volume}}"]],["tr","",["th","","Stream Type:"],["td","","{{stream_type}}"]],
-["tr","",["th","","Mime Type:"],["td","","{{mime}}"]],["tr","",["th","","DASH:"],["td","","{{dash}}"]],["tr","",["th","","DRM:"],["td","","{{drm}}"]]],["table",["html5-video-info-table","html5-video-element-info-table"],["tr","",["th","","Decoded Frames"],["th","","Dropped Frames"],["th","","Parsed Frames"],["th","","Presented Frames"]],["tr","",["td","","{{decoded_frames}}"],["td","","{{dropped_frames}}"],["td","","{{parsed_frames}}"],["td","","{{presented_frames}}"]],["tr","",["th","","Video Bytes Decoded"],
-["th","","Audio Bytes Decoded"],["th","","Painted Frames"],["th","","Paint Delay"]],["tr","",["td","","{{video_bytes_decoded}}"],["td","","{{audio_bytes_decoded}}"],["td","","{{painted_frames}}"],["td","","{{paint_delay}}"]]]]]);this.a=this.template.a["html5-video-info-panel-close"]}y(QF,Z);QF.prototype.update=function(a){a.dimensions=a.video_element_width+" x "+a.video_element_height;a.resolution=a.video_width+" x "+a.video_height;a.volume+="%";a.drm=a.drm_flavor+" / "+a.drm_key_system;this.template.update(a)};
-QF.prototype.F=function(){this.a=null;QF.C.F.call(this)};function RF(a){R.call(this);this.app=a;this.aa=this.U=this.b=this.P=this.g=this.a=this.ja=null;this.Na=this.Ta=0;this.pa=this.Q=null;a=a.J();this.Sa=ok()||"blazer"==a.Ca;this.za=0;this.j=null;this.vk()}y(RF,R);var SF=null;f=RF.prototype;f.vk=function(){this.app.D("videodatachange",this.Jl,this)};f.Qj=function(){var a=Jc(this.ja);(a=Om(a,"html5-video-player")?a:E("html5-video-player",a))||(a=SF||E("html5-video-player"));if(!a)return!1;TF(this,a);this.u("templateready");return!0};
-function TF(a,b){SF=b.cloneNode(!0);a.a=b;a.a.setAttribute("id",a.app.K.attrs.id);var c=Jc(a.ja);c!=a.a&&c.appendChild(a.a);(c=Jc("html5-player-messages"))&&z(c.children,function(a){try{var b=JSON.parse(a.innerHTML);kf(a.id,b)}catch(c){kf(a.id,a.innerHTML)}})}f.addClass=function(a){Pm(this.a,arguments)};f.removeClass=function(a){Qm(this.a,arguments)};
-f.sj=function(){var a=this.app.J(),b=this.a;this.addClass("el-"+a.Y);this.addClass("ps-"+a.Ca);X(b,"html5-native-controls",a.Vb);X(b,"html5-mobile",a.qc);a.xe||this.addClass("html5-chromeless");a.ub||this.addClass("tag-pool-enabled");b.style.display="";this.g=E("html5-video-container",b);this.U=E("html5-video-content",b);this.aa=E("html5-video-controls",b);this.j=new QF;this.j.V(b);J(this.j.a,"click",v(this.uk,this));L(this,this.j);this.Sa?this.Q=J(window,"resize",v(this.Ji,this)):this.Q=gf(v(this.Ji,
-this),250)};f.Ji=function(){this.P&&zb(UF(this),this.P)||this.uf()};f.uf=function(){if(this.b){var a=UF(this);if(!a.isEmpty()){var b=VF(this),c=UF(this),d=1,e=WF(this);if(e){var g=XF(this,c,b,e,!1),d=g.width/g.height/Ab(b);zd(this.b,g.width/d,g.height);od(this.b,g.left+g.width/2*(1-1/d),g.top)}else zd(this.b,c),od(this.b,0,0);b=XF(this,c,b,e,!0);zd(this.U,b.width,b.height);od(this.U,b.left,b.top);Un(this.b,"transform",1==d?"none":"scaleX("+d+")");this.P&&zb(a,this.P)||(this.P=a,this.Al(a));this.u("resize")}}};
-f.Al=function(){};f.Pj=function(){};f.Jl=function(a,b){this.b.setAttribute("data-youtube-id",b.L);aj&&(b.title?this.b.setAttribute("title",b.title):this.b.removeAttribute("title"));b.Bl&&(this.b.poster=b.Bl);var c=xm(b,"yt:bgcolor");this.g.style.backgroundColor=c?c:"";this.Ta=ul(xm(b,"yt:stretch"));this.Na=ul(xm(b,"yt:crop"))};f.Kj=function(){};f.zp=function(){};f.Go=function(){};function UF(a){return a.g?new B(a.g.clientWidth,a.g.clientHeight):new B(0,0)}
-function VF(a){return a.b?new B(a.b.videoWidth,a.b.videoHeight):new B(0,0)}function XF(a,b,c,d,e){c.isEmpty()?e=b:d?(c=new B(a.Ta||Ab(c),1),a=new B(a.Na||Ab(c),1),Bb(a,c),d=Ab(a)>Ab(b)?b.width/a.width:b.height/a.height,e=e?a.scale(d):c.scale(d)):e=Bb(c.clone(),b);return new Cb((b.width-e.width)/2,(b.height-e.height)/2,e.width,e.height)}function WF(a){return!a.app.J().Vb&&!VF(a).isEmpty()}function Aw(a,b){var c=a.aa;c.insertBefore(b,c.childNodes[0]||null)}f.Lj=function(){};
-function Ah(a){a.j&&(a.j.show(),a.Dp(),hf(a.za),a.za=gf(v(a.Dp,a),500))}
-f.Dp=function(){var a=O(this.app),b=this.app.getVideoData(),c=this.app.uj(),d=this.b,c={video_id:b.L,video_width:d.videoWidth,video_height:d.videoHeight,video_element_width:d.clientWidth,video_element_height:d.clientHeight,dash:"no",mime:"",drm_flavor:"",drm_key_system:"",volume:Math.round(this.app.wa.volume),stream_type:this.app.J().protocol,decoded_frames:c.hmewdfc||c.hmemdf||"-",dropped_frames:c.hmewdrop||"-",parsed_frames:c.hmempf||"-",presented_frames:c.hmempresented||"-",video_bytes_decoded:c.hmewvdbc||
-"-",audio_bytes_decoded:c.hmewadbc||"-",painted_frames:c.hmempainted||"-",paint_delay:c.hmempaintdelay||"-"};b.a&&(c.dash=b.a.i&&b.a.b?"no":"yes",c.mime=b.a.lb);if(a=a.I?a.I.g:null)c.drm_flavor=a.b,c.drm_key_system=a.a;this.j.update(c)};f.uk=function(a){a&&a.stopPropagation();this.j&&(hf(this.za),this.j.hide())};f.F=function(){this.Q&&(this.Sa?uf(this.Q):hf(this.Q));this.pa&&uf(this.pa);this.uk();this.j&&zf(this.j.a);F(this.a);this.aa=this.U=this.b=this.g=this.a=this.ja=null;RF.C.F.call(this)};function YF(){this.a=[];this.b=[]}ca(YF);var Dn=n("yt.player.utils.VideoTagPool.instance_")||YF.getInstance();pa("yt.player.utils.VideoTagPool.instance_",Dn);f=YF.prototype;f.py=function(a){if(!(this.a.length>=a)){a-=this.a.length;for(var b=0;b<a;b++){var c=ZF(this);this.a.push(c)}}};
-function ZF(a){var b=document.createElement("video");w(b,fj);J(b,"loadeddata",v(b.Xv,b));J(b,"volumechange",v(b.Yv,b));J(b,"timeupdate",v(b.kp,b));Ri&&6<=Wi&&J(b,"webkitbeginfullscreen",v(b.play,b));gj(b);if(a.b.length){var c=a.b[0],d=c.muted;b.volume=100*c.volume/100;b.muted=d}a.b.push(b);J(b,"volumechange",v(a.Zv,a));return b}f.Zv=function(a){a=a.target;var b=a.volume,c=a.muted;z(this.a,function(a){a.volume=b;a.muted=c})};f.wy=function(){return this.a.length?this.a.pop():ZF(this)};
-f.uy=function(a){a&&Sa(this.b,a)&&(mj(a),zf(a),Wa(this.b,a))};f.ry=function(a){return this.a.length>=(a||1)};YF.prototype.fillPool=YF.prototype.py;YF.prototype.getTag=YF.prototype.wy;YF.prototype.releaseTag=YF.prototype.uy;YF.prototype.hasTags=YF.prototype.ry;function $F(a,b){var c,d;d||(d=0);c||(c=sd(document.body));Nr(new A(b.pageX,b.pageY),a,d,null,c,5)};function aG(){this.a=new Uo(this)}y(aG,K);f=aG.prototype;f.Yj=null;f.Ge=null;f.Zj=null;f.Ui=null;f.He=null;f.vs=function(){this.hide()};f.ws=function(a){a.stopPropagation()};f.hide=function(){Sn(this.He);Lr("panelhidden")};f.xs=function(a){27==a.keyCode&&this.hide()};f.hn=function(){this.Ge.select()};f.show=function(){Rn(this.He)};f.F=function(){this.a.removeAll();this.Ge=this.Yj=this.Zj=this.He=null;aG.C.F.call(this)};function bG(a){this.W=a;this.W.D("internalvideodatachange",this.Tn,this);this.g=new Uo(this);this.a=new Uo(this);this.b=new aG;L(this,this.b)}y(bG,K);f=bG.prototype;f.$b=null;function cG(a,b,c){for(var d=Kc(On[b],a.$b),e=0;e<d.length;e++)Vo(a.g,d[e],"down",function(a){c.call(this,a);this.hide(a);a=b.replace("CONTEXT_MENU_","").toLowerCase();dG(this.W,"contextmenu."+a)})}f.Tn=function(a,b){var c=E("html5-context-menu-copy-embed-html",this.$b);Pn(c,b.Ao)};f.jn=function(a){a=ph(this.W,a);eG(this,a,"URL")};
-f.zs=function(){var a=cf("EMBED_HTML_TEMPLATE"),b=cf("EMBED_HTML_URL"),c=Tx(this.W.J()),d=this.W.getVideoData().L,b=b.replace(/__videoid__/g,d),a=a.replace(/__url__/g,va(b)),a=a.replace(/__width__/g,c.width),a=a.replace(/__height__/g,c.height);eG(this,a,"Text")};function eG(a,b,c){window.clipboardData&&window.clipboardData.setData(c,b)||(a=a.b,Qn(a.He)&&a.hide(),a.Ui&&W(a.He,a.Ui),a.Ui="html5-modal-panel-clipboard-substitute",V(a.He,a.Ui),a.show(),a.Ge.value=b,a.Ge.focus(),H(v(a.hn,a),100))}
-f.As=function(a){fG(this.W,a.target.getAttribute("href"))};
-f.Bs=function(){var a=this.W.getVideoData(),b=this.W.J(),c=Tx(b),d=Bw(b),e=wm(a),e=e?hj(e):"",c={cr:b.U,csipt:a.Nc,ec:108,feature:b.j,h:d.height,hl:b.i,playerh:c.height,playerw:c.width,ptk:a.A,referrer:b.referrer,screenh:window.screen.height,screenw:window.screen.width,sdetail:a.ja,shost:Ij(e),sourceid:a.te,vid:b.aa,vq:b.Kh,w:d.width};w(c,this.W.uj());(d=O(this.W))&&w(c,Fz(d,!0));c.videoId&&(c.v=c.videoId,delete c.videoId);b.qc&&(c.mobile="1");this.W.tf("streamingerror",c);window.open(Vx(a))};
-f.ys=function(){eG(this,qh(this.W,!0),"Text")};f.Cs=function(){Ah(this.W.S)};f.uu=function(a){a.preventDefault();Qn(this.$b)?a.stopPropagation():($F(this.$b,a),Rn(this.$b),this.a.listen(this.$b,"contextmenu",function(a){a.preventDefault()}),a=v(function(){this.a.listen(window,"blur",this.hide);Vo(this.a,document,"down",this.hide)},this),H(a,0),this.a.listen(document,"keydown",this.Gv))};f.Gv=function(a){27==a.keyCode&&this.hide(a)};f.hide=function(a){Sn(this.$b);this.a.removeAll();a&&a.stopPropagation()};
-f.F=function(){this.g.removeAll();this.a.removeAll();this.W.$("internalvideodatachange",this.Tn,this);this.W=null;F(this.$b);this.$b=null;bG.C.F.call(this)};function gG(a,b){In.call(this,a,b);this.o=null;this.B=this.G=this.i=this.b=0;V(this.element,"ytp-tv-static");hG(this,a,b)}y(gG,In);function iG(a){for(var b=Math.floor(0.6*a),c=b;c<a;++c){for(var d=!1,e=2;e<Math.sqrt(c);e++){if(!(c%e)){d=!1;break}d=!0}if(d)return c}return b}
-function hG(a,b,c){if(b&&c){a.width=a.element.width=b;a.height=a.element.height=c;var d=document.createElement("canvas");d.width=b;d.height=c;for(var e=d.getContext("2d"),g=e.getImageData(0,0,b,c),h=b*c,k=0;k<h;k++){var m=4*k;g.data[m]=g.data[m+1]=g.data[m+2]=Math.floor(35*Math.random());g.data[m+3]=255}e.putImageData(g,0,0);a.o=d;a.G=iG(b);a.B=iG(c/10);a.Z.scale(1.5,1.5)}}gG.prototype.show=function(){gG.C.show.call(this);var a=this.I;this.j=new Date;this.g(a,75)};
-gG.prototype.I=function(){var a=1-1/1.5;this.b=(this.b+this.G)%(this.width*a);this.i=(this.i+this.B)%(this.height*a);this.Z.drawImage(this.o,-1*this.b,-1*this.i)};gG.prototype.hide=function(){I(this.a);gG.C.hide.call(this)};function jG(){Z.call(this,["div",["ytp-error","html5-stop-propagation"],["div","ytp-error-content",["div","ytp-error-content-wrap","{{content}}"]]]);this.H="table";this.b=[];if(void 0==kl){var a=document.createElement("canvas");kl=!(!a.getContext||!a.getContext("2d"))}kl&&(this.a=new gG(1,1),this.a.V(this.element,0),L(this,this.a))}y(jG,Z);jG.prototype.show=function(){jG.C.show.call(this);kG(this);this.a&&this.a.show()};jG.prototype.hide=function(){jG.C.hide.call(this);this.a&&this.a.hide()};
-function kG(a){a.a&&hG(a.a,a.element.clientWidth,a.element.clientHeight)}jG.prototype.F=function(){uf(this.b);this.b=[];jG.C.F.call(this)};function lG(){this.b=this.a=null}lG.prototype.getMsg=function(a,b,c){return lf(a,b,c)};function fu(a,b,c,d){a.a&&mG(a.a,b,c,d)};function nG(a,b){var c;var d="followon_"+a;if(b.baseUrl&&b.uid){var e=b.rmktEnabled;c=b.focEnabled&&!b.isAd;if(e||c){d={label:c?d:"default"};if(e){e={utuid:b.uid,type:a};b.vid&&(e.utvid=b.vid);b.eventLabel&&(e.el=b.eventLabel);b.playerStyle&&(e.ps=b.playerStyle);b.feature&&(e.feature=b.feature);b.ppe&&(e.ppe=b.ppe);var g,h=[];for(g in e)h.push(encodeURIComponent(g)+"="+encodeURIComponent(e[g]));g=h.join(";");d.data=g}c&&"view"==a&&b.vid&&b.uid&&(b.oeid||b.ieid)&&(b.oeid&&(d.oeid=b.oeid),b.ieid&&(d.ieid=
-b.ieid),d.evid=b.vid);c&&(d.foc_id=b.uid);c=S(b.baseUrl,d)}else c=null}else c=null;c&&Qg(c)}function oG(a){var b=cf("CONVERSION_CONFIG_DICT");if(b){if(u(void 0)){var c=24==(void 0).length&&"UC"==(void 0).slice(0,2)?(void 0).substr(2):22==(void 0).length?void 0:null;if(b.uid!=c)return}nG(a,b)}};function pG(a,b,c){c=c||{};Wj("watch_actions_ajax",c.Ea,c.Ua,v(qG,l,a,b,c),c.onError)}
-function qG(a,b,c){var d={};0===b?d.action_like_video=1:1===b?d.action_dislike_video=1:d.action_indifferent_video=1;d.video_id=a;d.plid=c.eb;c.Oa&&(d.list=c.Oa);c.Ea&&(d.authuser=c.Ea);c.Ua&&(d.pageid=c.Ua);a={screen:Hj({h:screen.height,w:screen.width,d:screen.colorDepth}),session_token:ef("watch_actions_ajax")};c.px&&(a.station_id=c.px);Qj("/watch_actions_ajax",{format:"XML",method:"POST",yf:d,Mf:a,Qa:c.Qa,onError:c.onError,rd:c.rd});0===b?oG("like"):1===b&&oG("dislike")};function rG(a,b,c,d,e){if(Om(c,"html5-async-progress"))return null;X(c,"sentiment-like",b);X(c,"sentiment-dislike",!b);if(!a)return null;ru(c,"html5-async-progress");c={eb:a.eb,Qa:function(a){return function(){ru(a,"html5-async-success")}}(c),onError:function(a){return function(){ru(a)}}(c)};d&&(c.authUser=d);e&&(c.pageId=e);pG(a.L,b?0:1,c);cf("CONVERSION_CONFIG_DICT")||nG(b?"like":"dislike",a.i);return b?0:1};function sG(a,b,c){du.call(this,a,c.J(),b);this.W=c}y(sG,du);f=sG.prototype;f.Wj=function(){sG.C.Wj.call(this);this.gb.listen(this.b.b,"click",this.dv);this.gb.listen(this.b.a,"click",this.cv);this.W.D("presentingplayerstatechange",this.Eo,this)};f.update=function(a){sG.C.update.call(this,a);"watch_actions_ajax"in Ze&&!this.W.g?(a=this.b,a.b.show(),a.a.show()):(a=this.b,a.b.hide(),a.a.hide())};f.di=function(a){var b=Dc(this.a,"show-share");this.u("share-click");b||sG.C.di.call(this,a)};
-f.En=function(a){this.u("title-click",a)};f.kk=function(){var a=Dc(this.a,"show-more-info");this.u("info-click");if(a)this.B&&this.W.Ud();else{sG.C.kk.call(this);var b=Ch(this.W);this.B=P(b,8)&&!P(b,2);this.W.Td()}return!a};f.dv=function(){tG(this,!0)};f.cv=function(){tG(this,!1)};f.Eo=function(a){P(a.state,8)&&W(this.a,"show-more-info")};function tG(a,b){var c=rG(a.ka,b,a.a,a.g.Ea,a.g.Ua);null!=c&&(0==c?a.b.o():a.b.j(),a.W.u("RATE_SENTIMENT",c))}f.Mi=function(a){fG(this.W,a)};
-f.F=function(){this.W.$("presentingplayerstatechange",this.Eo,this);this.W=null;sG.C.F.call(this)};function uG(a,b,c,d,e,g,h,k){this.j=[];z(lb(b),function(b){this.j.push(J(a,b,v(this.Sq,this)))},this);z(lb(d),function(b){this.j.push(J(a,b,v(this.Rq,this)))},this);this.k=g||null;this.B=c;this.A=h||0;this.g=0;this.i=!1;this.H=e;this.o=k||0;this.a=0;this.b=!1}f=uG.prototype;f.Sq=function(a){I(this.a);this.a=0;this.g=H(v(this.mv,this,a),this.A)};f.Rq=function(a){I(this.g);this.g=0;this.a=H(v(this.lv,this,a),this.o)};f.mv=function(a){this.b||this.i||(this.i=!0,this.B.call(this.k||l,a))};
-f.lv=function(a){!this.b&&this.i&&(this.i=!1,this.H.call(this.k||l,a))};f.dispose=function(){this.b=!0;I(this.g);I(this.a);uf(this.j)};f.ha=function(){return this.b};var vG=null,wG=null;function xG(){Z.call(this,["div","ytp-tooltip",["div","ytp-tooltip-body",["div","ytp-tooltip-content","{{content}}"]],["div","ytp-tooltip-arrow"]]);this.a=this.template.a["ytp-tooltip-body"];this.b=this.template.a["ytp-tooltip-content"]}y(xG,Z);xG.prototype.hide=function(){xG.C.hide.call(this);od(this.a,0)};function yG(a,b){X(a.b,"ytp-tooltip-content-text",!b.tagName);nn(a.template,"content",b)}xG.prototype.F=function(){Xc(this.b);this.b=this.a=null;xG.C.F.call(this)};function zG(a,b){this.a={};this.xl=a;this.ap=b}y(zG,K);
-function Fn(a,b,c){var d,e=new uG(b,"mouseover",function(){if(this.xl){var a=new xG;a.V(this.xl);d=a}else d=null;if(d&&(a=c&&c(b),!c||a)){a?yG(d,a):(a=G(b,"tooltip")||"",yG(d,Vc(a)));var e=!!G(b,"tooltip-below"),a=d,k=Bd(b),k=new A(k.width/2,e?k.height:0),m=td(b),k=new A(m.x+k.x,m.y+k.y),e=!!e;X(a.element,"ytp-tooltip-below",e);if(m=rd(a.element))var p=td(m),s=Id(m),k=xb(k,new A(p.x+s.left,p.y+s.top));Nr(k,a.element,e?1:0);a.show();var s=Bd(a.a),e=-1*(s.width/2),r=Oc(window),D=Pc(document),k=D.x,
-r=r.width+D.x,D=k,M=r;m&&(m=Bd(m),D=p.x,M=m.width+p.x);m=td(a.a);p=m.x+e;m=m.x+s.width+e;p<Math.max(k,D)?e-=p-Math.max(k,D):m>Math.min(r,M)&&(e-=m-Math.min(r,M));od(a.a,e)}},["mouseout","mousedown"],function(){d&&(d.hide(),Sg(d),d=null)},a,10,50);a.a[ja(b)]=e}
-function mG(a,b,c,d){Fn(a,b,function(){var a=this.ap,b;if(a&&a.Ol){b=a.Ol;var h=a.Gp;vG||(vG=new ao(lf("YTP_TOOLTIP_IDENTITY")),wG=new ao(lf("YTP_TOOLTIP_IDENTITY_WATCH_LATER")));a=Uc("div");V(a,"ytp-identity-tooltip");var k=Uc("img");k.src=h;var h=Uc("span"),m=null;d?(V(h,"ytp-idt-watch-later"),m=[Vc(fo(wG,{user_name:""})),Uc("br"),Vc(b)]):m=Vc(fo(vG,{user_name:b}));Wc(h,m);Wc(a,k,h);b=a}else b=c;return b})}
-zG.prototype.F=function(){this.ap=this.xl=null;for(var a in this.a)Sg(this.a[a]);this.a={};zG.C.F.call(this)};function AG(a,b){this.k=a;this.i=[];this.o=b;this.j=[]}y(AG,K);function BG(a,b,c){a.i.push(a.k.D(b,c,a))}function CG(a,b,c){a.j.push(a.o.D(b,c,a))}function DG(a){for(var b=0;b<a.i.length;b++)a.k.Wc(a.i[b]);for(b=0;b<a.j.length;b++)a.o.Wc(a.j[b])}AG.prototype.F=function(){DG(this)};function EG(a,b){AG.call(this,a,b);this.g=!1;this.b=a;this.a=b;var c=a.J();c.color&&V(this.a.i,c.color);if(c.Kg){var d=this.a,e=E("html5-progress-tooltip",d.g);d.b=new Ru;var g=d.b;g.Hb=e;g.Lh=E("html5-progress-tooltip-arrow",g.Hb);g.fk=E("html5-progress-tooltip-thumbnail",g.Hb);g.wj=E("html5-progress-tooltip-timestamp",g.Hb);L(d,d.b);d=this.a;d.a=new Nu;d.a.V(d.g);Vo(d.k,d.a.N(),"down",d.Gs);d.a.hide();L(d,d.a)}c.Lg&&(c=this.a,d=E("html5-storyboard",c.g),c.o=new Ju,e=c.o,g=c.bb.b.a?new B(c.bb.b.a.clientWidth,
-c.bb.b.a.clientHeight):new B(0,0),e.yd=d,e.Je=g.width,e.ac=E("html5-storyboard-filmstrip",e.yd),e.Yh=E("html5-storyboard-lens",e.yd),e.dk=E("html5-storyboard-lens-thumbnail",e.yd),e.ek=E("html5-storyboard-lens-timestamp",e.yd),e.Ag=E("html5-storyboard-thumbnail",e.ac),F(e.Ag),L(c,c.o));FG(this)}y(EG,AG);
-function FG(a){DG(a);a.g=!0;BG(a,"cuerangesadded",a.Cw);BG(a,"cuerangesremoved",a.Dw);BG(a,"cuerangemarkersupdated",a.Bw);BG(a,"presentingplayerstatechange",a.Iw);BG(a,"progresssync",a.Jw);BG(a,"resize",a.Fw);BG(a,"seekto",a.Gw);BG(a,"videodatachange",a.Kw);BG(a,"videoplayerchange",a.yp);BG(a,"videoready",a.Hw);CG(a,"beginseeking",a.Aw);CG(a,"endseeking",a.Ew);CG(a,"seekto",a.zw)}f=EG.prototype;f.Cw=function(a){var b=O(this.b).getVideoData();!b||0>=b.ta||GG(this,a,b)};
-function GG(a,b,c){var d=c.ta;z(b,function(a){a.Uc&&dv(this.a,a.start/(1E3*d))},a)}f.Dw=function(a){var b=O(this.b).getVideoData();if(b&&!(0>=b.ta)){var c=b.ta;z(a,function(a){a.Uc&&ev(this.a,a.start/(1E3*c))},this)}};f.Bw=function(a){var b=O(this.b).getVideoData();!b||0>=b.ta||z(a,function(a){var d=a.start/(1E3*b.ta);a.Uc?dv(this.a,d):ev(this.a,d)},this)};f.Fw=function(a){if(this.a.o){var b=this.a.o;b.Zc&&(b.Je=a.width,Lu(b,!0))}};
-f.Gw=function(a){bv(this.a,a);if(this.a.o){var b=this.a.o;if(b.Zc){b.Ik=b.gl*a-b.Je/2;od(b.ac,-1*b.Ik);var c=al(b.Zc,a);Ku(b,c);ad(b.ek,Nn(b.Te*a));ks(b.a)}}};f.Iw=function(a){if(0>Ro(a,16)){a=this.a;var b=this.b.getCurrentTime();a.Ta.innerHTML=Math.floor(100*a.ya)+"% at "+Math.floor(b)+" of "+Math.floor(a.B)+" seconds"}};f.yp=function(a){1!=a.B?this.g&&(DG(this),this.g=!1,BG(this,"videoplayerchange",this.yp)):this.g||FG(this)};
-f.Kw=function(a,b,c){"newdata"==a&&(bv(this.a,(b.xa||0)/b.ta,0),a=this.a,Xc(a.va),a.K={},(c=O(this.b,c))&&GG(this,c.A.i||[],b),this.a.b&&this.a.b.reset());this.a.Va(b.ta);this.a.b&&this.a.b.Va(b.ta);this.a.o&&this.a.o.Va(b.ta);c=this.a;c.ia=b.Jj;cv(c);c=this.a;c.aa=b.Im;cv(c)};
-f.Hw=function(a){if(this.a.b){var b=this.a.b;if(!b.ki)if(ym(a)){V(b.Hb,"with-thumbnail");b.Jg=ym(a);b.ih=zm(a);var c=v(b.Uu,b);b.ih.D("l",c)}else b.reset()}if(this.a.o&&(b=this.a.o,b.Ag&&Xc(b.ac),W(b.yd,"enabled"),b.Zc=ym(a),b.Qe=zm(a),b.Zc&&!b.Fo)){V(b.yd,"enabled");a=v(b.Bo,b);b.Qe.D("l",a);Lu(b);a=b.ac.cloneNode(!0);for(var c=b.Zc.a[0].b,d,e,g=0;g<c;g++)e=b.Ag.cloneNode(!1),d=Al(b.Qe,g,b.Ob),Iu(e,d,b.Ob,b.Ki),a.appendChild(e);c=b.ac;(d=c.parentNode)&&d.replaceChild(a,c);b.ac=a}};
-f.Jw=function(a,b,c){bv(this.a,b,c)};f.Aw=function(){Cz(this.b.b)};f.Ew=function(){this.b.b.ti()};f.zw=function(a,b){Wg(this.b,a,b)};function HG(a,b){AG.call(this,a,b);BG(this,"applicationplayerstatechange",this.Ts);BG(this,"controlsdisabled",this.Vs);BG(this,"controlsenabled",this.Ws);BG(this,"liveviewshift",this.Zs);BG(this,"fullscreentoggled",this.Ys);BG(this,"presentingplayerstatechange",this.Dt);BG(this,"progresssync",this.Et);BG(this,"threedenabled",this.qt);BG(this,"videodatachange",this.Ft);BG(this,"onPlaybackQualityChange",this.jt);BG(this,"onVolumeChange",this.tt);BG(this,"menu_add",this.$s);BG(this,"menu_remove",this.ct);
-CG(this,"fullscreentoggled",this.Xs);CG(this,"mutetoggled",this.dt);CG(this,"nextvideo",this.ft);CG(this,"playpausetoggled",this.gt);CG(this,"previousvideo",this.ht);CG(this,"qualitychanged",this.kt);CG(this,"sizechangerequested",this.lt);CG(this,"speedchanged",this.nt);CG(this,"volumechanged",this.ut);CG(this,"watchlater",this.Ct);CG(this,"watchonyoutube",this.vt);CG(this,"controlclick",this.Us);this.a=a;this.b=b;this.g=new EG(a,b.ok);L(this,this.g);var c=a.J();if(c.Ma){var d=this.b;d.Sc=new qv(d.b);
-L(d,d.Sc);var e=d.wd;e.parentNode&&e.parentNode.insertBefore(d.Sc.N(),e.nextSibling);F(d.Ee);F(d.Yd);F(d.wd);Zc(d.xb).appendChild(d.xb);d.wb=new Du;L(d,d.wb);d.wb.hide();d.wb.V(d.qf);d.a.listen(d.Sc,"click",d.zt);d.zc=new kv(d.b);L(d,d.zc);d.zc.listen("change",d.xt,d);d.Fd=new rv(d.b);L(d,d.Fd);d.Fd.listen("change",d.At,d);d.Gd=new sv(d.b);L(d,d.Gd);d.Gd.listen("change",d.Bt,d)}c.tc&&(d=this.b,e=this.a.J().Rd,d.Fd?(d.Fd.Ya(e?1:0),d.wb.add(d.Fd)):(Rn(d.Ee),Rn(d.Yd)));c.Fh&&this.b.i.show();c.lg&&(d=
-this.b,e=this.a.a.lg?dh:[1],d.Gd?(tv(d.Gd,e),d.wb.add(d.Gd)):Rn(d.wf));if(c.Sa)for(c=this.b,d=[c.Ec,c.yc,c.vf,c.g,c.wd,c.xb,c.xg,c.i,c.Ee,c.Yd,c.Sc],e=0;e<d.length;e++)c.a.listen(d[e],"click",c.wt)}y(HG,AG);f=HG.prototype;f.Vs=function(a){this.b.disable(a)};f.Ws=function(a){this.b.enable(a)};f.Zs=function(a){X(this.b.g.element,"ytp-time-live-dvr",!a)};
-f.Ys=function(a){var b=this.b,c=this.a.J().Rd;if(a){var d=b.i;Gn(d,"ytp-button-fullscreen-exit");var e=d.g.getMsg("YTP_BUTTON_FULLSCREEN_EXIT");d.Jb(e);d.a=e}else Cu(b.i);b.Fd&&b.Fd.Ya(a?-1:c?1:0)};f.Dt=function(a){P(a.state,2)||(0<Ro(a,8)?Ev(this.b,!0):0>Ro(a,8)?Ev(this.b,!1):0>Ro(a,2)&&Ev(this.b,P(a.state,8)));0>Ro(a,16)&&IG(this,this.a.getCurrentTime())};f.Ts=function(a){if(P(a.state,2)){a=this.b.Ec;Gn(a,"ytp-button-replay");var b=a.g.getMsg("YTP_BUTTON_REPLAY");a.Jb(b);a.a=b}};
-f.qt=function(){var a=this.b,b=this.a.getVideoData().If,c=E("html5-threed-conversion-on",a.Xh),a=E("html5-threed-conversion-off",a.Xh);Pn(c,!b);Pn(a,b)};f.Ft=function(a,b){if(1==O(this.a).B){"newdata"==a&&(IG(this,b.xa||0),ru(this.b.xb),Gv(this.b,"1.0"));this.b.Va(b.ta);Bv(this.b,um(b));var c=this.b,d=b.Fb,e=b.cb;c.Xn=d&&!e;c=c.g;X(c.element,"ytp-time-liveonly",d&&!e);X(c.element,"ytp-time-live",d&&e);this.a.g&&"detailpage"!=this.a.J().Y?this.b.Ne.show():this.b.Ne.hide()}};
-f.jt=function(a){1==O(this.a).B&&Cv(this.b,a,JG(this.a))};
-f.tt=function(a){var b=this.b,c=a.volume;a=a.muted;Oe(b.yc,"value",a||0==c?"off":20>c?"min":40>c?"quiet":60>c?"normal":80>c?"loud":"max");Oe(b.yc,"volume",c);var d=b.cc.clientWidth-6,e=b.cc.style.backgroundPosition.split(" "),e=1<e.length?e[1]:"0px";if(a)b.cc.style.backgroundPosition="-"+d+"px "+e,b.Cg.style.left="0px";else{var g;0>=c?g=0:100<=c?g=d:(g=(d-0)*c/100,g=0>=g?0:g>=d?d:0+Math.round(g));b.Cg.style.left=g+"px";b.cc.style.backgroundPosition="-"+(d-g)+"px "+e}c=Math.round(c);d=c+"% "+lf("HTML5_VOLUME_SETTING")+
-(a?" "+lf("HTML5_VOLUME_MUTED"):"");b.vf.setAttribute("aria-valuenow",c);b.vf.setAttribute("aria-valuetext",d);c=b.yc;d=G(c,a?"tooltip-alt":"tooltip-default")||"";Oe(c,"tooltip",d);c.setAttribute("aria-label",d);b.yc.setAttribute("aria-label",(a?lf("HTML5_VOLUME_UNMUTE"):lf("HTML5_VOLUME_MUTE"))+" "+lf("HTML5_CONTROL_TOGGLE"))};f.$s=function(a){var b=this.b;b.wb&&b.wb.add(a)};f.ct=function(a){var b=this.b;b.wb&&b.wb.remove(a)};f.Et=function(a){IG(this,a)};f.Xs=function(){KG(this.a,!this.a.J().ob)};
-f.dt=function(){this.a.wa.muted?Yg(this.a):Xg(this.a)};f.ft=function(){sh(this.a)};f.gt=function(){LG(this.a)};f.ht=function(){th(this.a)};f.kt=function(a){"auto"==a&&Cv(this.b,eh(this.a),a);"auto"==JG(this.a)&&Cv(this.b,a,a);var b=O(this.a,1);b&&fh(b,"m",a)};f.lt=function(a){var b=this.a;KG(b,!1);a!=b.a.Rd&&(b.a.Rd=a,b.u("SIZE_CLICKED",a),b.S.Ji())};f.nt=function(a){ch(this.a,a)};f.ut=function(a){MG(this.a,a)};f.vt=function(){fG(this.a,ph(this.a,!0))};f.Us=function(a){dG(this.a,a)};
-f.Ct=function(){Wj("addto_ajax",this.a.J().Ea,this.a.J().Ua,v(this.Av,this),v(this.Yo,this))};
-f.Av=function(){var a={uv:"WL",yb:this.a.getVideoData(1).L,Ea:this.a.J().Ea,Ua:this.a.J().Ua,Qa:this.vv,onError:this.Yo,Z:this},b={video_ids:a.yb,playlist_id:a.Oa||"",full_list_id:a.Ay||"",new_playlist_name:a.wv||"",session_token:ef("addto_ajax")},c=cf("PLAYBACK_ID");c&&(b.plid=c);c={};a.privacy&&(c.privacy=a.privacy);a.sv&&(c.feature=a.sv);a.Ea&&(c.authuser=a.Ea);a.Ua&&(c.pageid=a.Ua);var d="";switch(a.uv){case "PL":d=a.wv?"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;Qj("/addto_ajax",{rv:!0,format:"XML",method:"POST",yf:c,Mf:b,Z:a.Z,onError:a.onError,Qa:a.Qa})};f.vv=function(){ru(this.b.xb,"html5-async-success");this.a.u("WATCH_LATER")};f.Yo=function(a,b){var c=this.b.xb,d=b&&b.error_message;ru(c,"html5-async-error");if(d){var e=Kt.getInstance(),g=Mt(c);Ot(c,d);Lt(e,c);Wr(c,g)}};function IG(a,b){1==O(a.a).B&&nn(a.b.g.template,"current",Nn(b))};var NG={0:"autohide-off",1:"autohide-on",2:"autohide-fade",3:"autohide-auto",4:"autohide-embeds",5:"autohide-seekbar"};function OG(a){RF.call(this,a);this.O=this.o=this.M=this.Ma=this.A=this.ga=this.fa=this.X=this.I=this.G=this.k=this.i=null;this.va=!1;this.ma=this.B=null;this.Ka=!0;this.ya=this.K=!1;a=this.app.J().Gb?4E3:3E3;this.ia=new Xo(this.hk,a,this);L(this,this.ia);this.ia.start()}y(OG,RF);f=OG.prototype;
-f.vk=function(){OG.C.vk.call(this);this.app.D("appstatechange",this.bx,this);this.app.D("applicationplayerstatechange",this.cx,this);this.app.D("clearvideooverlays",this.ix,this);this.app.D("initializingmode",this.gx,this);this.app.D("presentingplayerstatechange",this.fx,this);this.app.D("onDetailedError",this.hx,this)};
-f.Qj=function(){var a=this.app.K.assets;if(a.css&&!nl()){var b={rel:"stylesheet",type:"text/css",href:a.css},c=document.getElementById("www-player-css");b.id="www-player-css";var d=c||document.createElement("link");Mc(d,b);c||document.getElementsByTagName("head")[0].appendChild(d);this.bp(200)}else this.va=!0;OG.C.Qj.call(this)||Qj(a.html,{format:"RAW",method:"GET",Qa:v(this.kx,this)});return!0};
-f.kx=function(a){if(a.responseText){var b=Uc("div");b.innerHTML=a.responseText;TF(this,E("html5-video-player",b));this.u("templateready")}else this.u("templateerror")};f.bp=function(a){0>=a||nl()?(this.va=!0,this.a&&on(this.a)):H(v(this.bp,this,a-1),50)};
-f.sj=function(){OG.C.sj.call(this);this.va||pn(this.a);PG(this);var a=this.app.J();a.X&&this.addClass(a.X+"-theme");a.of&&this.addClass("house-brand");!a.pf&&a.xe||this.addClass("modest-branding");a.tj&&this.addClass("html5-hide-share");a.pm||this.addClass("html5-hide-volume");a.Gb&&(this.addClass("html5-tablet"),V(document.body,"html5-tablet-body"));a.Wb||this.addClass("hide-info-bar");a.Gb||a.Vb||this.addClass(NG[a.Gh]);var b=Ab(new B(this.a.clientWidth,this.a.clientHeight)).toFixed(1);"1.3"!=b&&
-"1.8"!=b||this.addClass("autohide-aspect");a.tc&&this.uf();this.G=E("html5-watermark",this.a);QG(this.app)&&Rn(this.G);a.xe&&!a.Vb&&(this.A=new yv(this.B),zv(this.A,this.aa),L(this,this.A),this.Ma=new HG(this.app,this.A),L(this,this.Ma));var b=E("html5-context-menu",this.a),c=E("html5-modal-panel",this.a),d=this.M=new bG(this.app);d.$b=b;F(d.$b);document.body.appendChild(d.$b);var e=d.b;e.He=c;e.Zj=E("html5-modal-panel-close-button",c);e.Yj=E("html5-modal-panel-clipboard-substitute-content",c);e.Ge=
-Ue("input",e.Yj);ec&&e.Ge.removeAttribute("readonly");e.a.listen(document,"keydown",e.xs);e.a.listen(c,"contextmenu",e.ws);Vo(e.a,e.Zj,"down",e.vs);Vo(e.a,e.Ge,"down",e.hn);var c={ks:d.ys,ls:d.zs,ms:v(d.jn,d,!1),os:v(d.jn,d,!0),ts:d.Bs,us:d.Cs,rs:d.As},g;for(g in c)cG(d,g,c[g]);L(this,this.M);a.of&&V(b,"house-brand");this.k=new Zt(2);V(this.k.element,"html5-video-loader");V(this.k.element,"html5-center-overlay");V(this.k.element,"ytp-scalable-icon-grow");this.k.V(this.g);L(this,this.k);g=E("html5-info-bar",
-this.a);this.o=new sG(g,this.B,this.app);this.o.Wj();L(this,this.o);this.I=new zF(a.qc);this.I.V(this.g);L(this,this.I);this.X=new xF;this.X.V(this.g);L(this,this.X);RG(this)};f.Al=function(a){OG.C.Al.call(this,a);SG(this,a);this.i&&kG(this.i)};f.Pj=function(){OG.C.Pj.call(this);SG(this,UF(this))};f.Jl=function(a,b){OG.C.Jl.call(this,a,b);"newdata"==a&&this.o.reset();this.o&&this.o.update(b);if(QG(this.app)){var c=b.Ma;c&&(this.G.src=c);Rn(this.G)}};
-f.bx=function(a){2==a?TG(this):(this.I.hide(),this.removeClass("cued-mode"));3==a?this.k.show():P(Ch(this.app),1)||this.k.hide()};
-f.fx=function(a){var b;b=a.state;if(P(b,2))b=["ended-mode"];else{var c=[];P(b,8)?c.push("playing-mode"):P(b,4)&&c.push("paused-mode");P(b,1)&&!P(b,32)&&c.push("buffering-mode");P(b,32)&&c.push("seeking-mode");P(b,64)&&c.push("unstarted-mode");b=c}this.ma&&Qm(this.a,this.ma);Pm(this.a,b);this.ma=b;P(a.state,1)?this.k.show():0>Ro(a,1)&&this.k.hide();this.Ka=P(a.state,8)&&!P(a.state,4);0>Ro(a,64)&&UG(this.app)};f.cx=function(a){P(a.state,2)?TG(this):0>Ro(a,2)&&(this.I.hide(),this.removeClass("cued-mode"))};
-function RG(a){var b=a.app.J();if(b.ym){if(b.Gb){var c=v(function(a){return VG(a)||Om(a.target,"html5-draggable")},a);a.O=new su(a.a,v(function(a){Om(this.a,"cued-mode")?Dn.hasTags(void 0)&&this.ko(a):VG(a)&&(this.K?this.Vk():this.hk(),this.A&&(a=Xr.getInstance(),a.Df&&bs(a,a.Df)))},a),!1,c);J(a.a,"gesturechange",v(a.xu,a));J(a.a,"gestureend",v(a.yu,a))}else J(a.a,"click",v(a.ko,a)),J(a.a,"dblclick",v(a.wu,a)),J(a.a,"click",v(a.Vk,a)),J(a.a,"mousemove",v(a.Vk,a)),J(a.a,"mouseout",v(a.hk,a));var d=
-v(function(){var a=this.b;a&&(gj(a),Dn.fillPool(4),b.Gb&&wu(),(a=sf(this.a,"click",d,!0))&&uf(a))},a);J(a.a,"click",d,!0);J(a.a,"keypress",v(a.Au,a));J(a.a,"keydown",v(a.vu,a));c=v(a.M.uu,a.M);aj&&a.O?a.O.o=c:J(a.a,"contextmenu",c);J(a.G,"click",v(a.lo,a));a.o.D("title-click",v(a.lo,a));a.o.D("share-click",v(a.Bu,a));a.o.D("info-click",v(a.zu,a))}}f.ko=function(a){var b=this.app.J();VG(a)&&(this.a.focus(),!Om(this.a,"cued-mode")&&b.Vb||LG(this.app,!0));dG(this.app,"screenclick")};
-f.wu=function(a){6!=this.app.o&&(VG(a)&&(a=this.app,KG(a,!a.a.ob)),dG(this.app,"screendoubleclick"))};f.xu=function(a){var b=a.scale,c=this.app.J().ob;b*(c?-1:1)>(c?-0.7:1.3)&&(b=this.app,KG(b,!b.a.ob));a.preventDefault()};f.yu=function(a){a=a.scale;var b=this.app.J().ob;a*(b?-1:1)>(b?-0.9:1.1)&&(a=this.app,KG(a,!a.a.ob))};function VG(a){return!gd(a.target,"html5-stop-propagation")}
-f.Au=function(a){var b=a.keyCode;if(179==b||178==b)179==b&&(this.u("playpausetoggled",!0),a.preventDefault()),178==b&&($g(this.app),a.preventDefault());98==b&&this.app.gf("onBackgroundChange");111==b&&this.app.gf("onTextOpacityChange");119==b&&this.app.gf("onWindowOpacityChange");61!=b&&43!=b||this.app.gf("onFontSizeIncrease");45!=b&&95!=b||this.app.gf("onFontSizeDecrease");32==b&&VG(a)&&(LG(this.app,!0),a.preventDefault());48<=b&&57>=b&&(Wg(this.app,(b-48)/10*Kh(this.app)),a.preventDefault())};
-f.vu=function(a){var b=a.keyCode;if(38==b||40==b||37==b||39==b){var c=5;a.ctrlKey&&(c*=2);if(38==b)c=this.app,MG(c,{volume:c.wa.volume+5,muted:!1});else if(40==b)c=this.app,MG(c,{volume:c.wa.volume-5,muted:!1});else if(37==b){var d=this.app,c=-1*c;Wg(d,d.getCurrentTime()+c,!1,250,void 0)}else 39==b&&(d=this.app,Wg(d,d.getCurrentTime()+c,!1,250,void 0));a.preventDefault()}36==b&&(Wg(this.app,0),a.preventDefault());35==b&&(Wg(this.app,Infinity),a.preventDefault());27==b&&(KG(this.app,!1),a.preventDefault())};
-f.lo=function(a){a.preventDefault();a=this.app;var b;b=a.getVideoData();b=b.Oc||eu(a.a,b);fG(a,b)};f.Bu=function(){this.app.Mh();KG(this.app,!1);var a=this.app,b=a.getVideoData();a.u("SHARE_CLICKED",{videoId:b.L,listId:b.Oa,feature:"player_"+a.a.Y})};f.zu=function(){this.app.Mh()};f.ix=function(){var a=this.o;W(a.a,"show-share");W(a.a,"show-more-info")};f.Vk=function(){this.ya=!0;this.ia.start();this.K&&(this.K=!1,this.removeClass("hide-controls"),this.app.fb("onShowControls"))};
-f.hk=function(){this.ya=!0;this.ia.stop();if(!this.K){var a;if(a=this.A){a=this.A;var b=Xr.getInstance();a=!!b.Df&&Te(b.Df,a.qf)||null!=a.j}b=(b=ih(this.app.k,"playlist"))&&b.ba;this.Ka&&this.ya&&!a&&!b&&(this.K=!0,this.addClass("hide-controls"),this.app.fb("onHideControls"))}};function TG(a){a.I.show(a.app.getVideoData());a.addClass("cued-mode")}f.Kj=function(){var a=Kc("html5-popup-dialog",this.a);z(a,function(a){Sn(a)},this)};
-f.hx=function(a){this.i||(this.i=new jG,this.i.V(this.a),L(this,this.i));var b=this.app.J(),c=a.message;a=a.messageKey;if(!b.of&&"HTML5_DEFAULT_FALLBACK"==a){c+=lf("LEARN_MORE");a=this.i;for(var d=v(this.app.tf,this.app,"",{errorHelpClick:1}),e=a.element.getElementsByTagName("a"),g=0;g<e.length;g++)a.b.push(J(e[g],"click",d));this.app.tf("",{errorHelpShown:1})}a=this.i;b="embedded"==b.Y;uf(a.b);a.b=[];nn(a.template,"content",new jv(c));if(b)for(b=a.element.getElementsByTagName("a"),c=0;c<b.length;c++)b[c].setAttribute("target",
-"_blank");this.i.show()};f.gx=function(){this.i&&this.i.hide()};f.zp=function(a){var b=this.X;b.show(a);H(oa(V,b.element,"html5-bezel-fade"),0);b.a=H(v(b.hide,b),300)};f.Go=function(a){E("html5-viewport-sheet").disabled=!a};f.uf=function(){var a=this.app.J();Oe(document.body,"player-size",a.ob?"fullscreen":a.Rd?"large":"small");OG.C.uf.call(this)};
-function WG(a,b){var c="scale("+a+") !important;";b&&(c="translate(-50%, -50%) "+c);return["transform: "+c,"-webkit-transform: "+c,"-moz-transform: "+c,"-o-transform: "+c,"-ms-transform: "+c]}function SG(a,b){if(!b.isEmpty()){var c=b.width,d=b.height,e=0,g=0;c/d>480/360?(e=d,g=360):(e=c,g=480);c=vb(e/g,0.5,1);d={Kb:a.fa,reset:!0};a.fa=un(".ytp-scalable-icon-shrink",WG(c,!1),d);c=vb(0.33*(e/g),0.5,1);d={Kb:a.ga,reset:!0};a.ga=un(".ytp-scalable-icon-grow",WG(c,!0),d)}}
-f.Lj=function(a){this.A&&Ev(this.A,a)};function PG(a){a.B=new lG;a.B.b=a;var b=new zG(a.a,a.app.J());L(a,b);a.B.a=b;a=Kc("ytp-tooltip-anchor",a.a);z(a,function(a){Fn(b,a)})}f.F=function(){this.k.hide();vn(this.fa);vn(this.ga);zf(this.a);zf(this.G);Sg(this.O);OG.C.F.call(this);this.G=this.I=this.ga=this.fa=this.O=this.X=null};function nh(a,b,c,d){"string"==typeof a&&(a={mediaContentUrl:a});var e=a,g=/\/([ve]|embed)\/([^#?]+)/.exec(a.mediaContentUrl);e.video_id=g&&g[2]?g[2]:null;return kh(a,b,c,d)}function kh(a,b,c,d){b={endSeconds:void 0,list:b,mediaContentUrl:void 0,startSeconds:c,suggestedQuality:d,video_id:a};if(ia(a)){for(var e in b)b[e]=b[e]||a[e];b.video_id=a.video_id||a.videoId}return b};function XG(a,b,c){this.b=a;this.a=b;this.I=c||null;this.i={};this.H=NaN;this.j=new Xo(this.Gq,3E4,this);L(this,this.j);this.k=new Xo(this.yj,1E3,this);L(this,this.k);this.G=0;this.g="N";this.o=NaN;this.A=""}y(XG,K);var YG={5:"N","-1":"N",3:"B",0:"EN",2:"PA",1:"PL"};function Bz(a,b,c){var d=a.i[b];d||(d=[],a.i[b]=d);d.push(((x()-a.G)/1E3).toFixed(3)+":"+c.join(":"))}f=XG.prototype;
-f.yj=function(){if(this.I){var a=this.I();if(!isNaN(this.B)&&!isNaN(a.g)){var b=a.g-this.B;0<b&&Bz(this,"bwm",[b,(a.j-this.M).toFixed(3)])}this.B=a.g;this.M=a.j;isNaN(a.a)||Bz(this,"bwe",[a.a.toFixed(3)]);isNaN(a.b)||(b=a.b,a.i<b&&(b=a.i),this.K!=b&&(Bz(this,"bh",[b.toFixed(3)]),this.K=b),this.a.Ka&&3>b&&("PL"==this.g||"B"==this.g)&&this.k.start())}};
-f.mg=function(){if(!this.ha()&&!Kb(this.i)){0!=this.k.Ba||this.yj();var a=Wx(this.a).hmewdrop;0<=a&&a!=this.o&&Bz(this,"df",[a-(this.o||0)]);this.o=a;a={event:"streamingstats"};this.b.a&&(a.fmt=this.b.a.Pa);a.cpn=this.b.Da;a.ei=this.b.j;a.el=this.a.Y;a.docid=this.b.L;a.ns=this.a.sc;this.a.g&&(a.adformat=this.a.g);this.b.Fb&&(a.live=this.b.cb?"dvr":"live");Ob(a,Rx(this.a));a.html5="1";var a=S(Qx(this.a)+"stream_204",a),b;for(b in this.i)a+="&"+b+"="+this.i[b].join(",");Qg(a);this.i={};this.j.start()}};
-f.onError=function(a){Bz(this,"error",[a,this.b.we.toFixed(3)])};f.Gq=function(){"PL"==this.g&&(Bz(this,"vps",[this.g]),this.mg())};f.F=function(){XG.C.F.call(this);hf(this.H)};function ZG(a,b,c,d){c=c||"";this.i=[];this.j=[];this.B=[];this.H="watchtime"==c;this.nd=Qx(b)+"api/stats/"+c;d&&(this.dm=d.fs,this.O=d.nbe,this.P=d.bc,this.Q=d.bd,this.nc=d.bt,d.rtn&&(this.gg=d.rtn),this.H?(this.ja=d.state,0<d.rti&&(this.Ah=d.rti)):(this.ga=d.mos,this.ma=d.volume,d.at&&(this.I=d.at),d.allowed&&(this.M=d.allowed),d.ex_ads&&(this.aa=d.ex_ads)));this.G=b.g;this.Bh=b.Ub;this.U=b.k;this.Ka=b.H;this.Ma=b.A;this.Pc=b.B;this.Na=b.eg;this.Sa=b.lf;this.Ta=b.G;this.bb=b.I;this.ib=b.K;this.oc=
-b.M;this.mc=b.O;this.b=b.b;this.Kc=b.Y;this.B=b.o;this.ia=b.ia;this.Mc=b.i;this.gm=b.sc;this.Nc=b.Ca;this.referrer=b.referrer;this.Lc=b.U;this.o=b.j;this.od=b.ja;this.pa=b.ma;this.va=b.pa;this.md=Xx(b);!a.a||a.ga.isEmpty();this.Bh=a.kf||this.Bh;this.ya=a.Da;this.A=a.we;this.X=a.K;this.za=a.Na;this.a=a.a;this.fm=a.Qd;this.Oc=a.cg;a.Fb&&(this.fa=a.cb?"dvr":"live");this.Jc=a.xh;this.pd=a.pd;this.eb=a.eb;this.Qc=a.j;this.Oa=a.Oa;this.o=a.aa||this.o;this.tb=a.ma;this.g=a.g;this.L=a.L}f=ZG.prototype;
-f.Bh=!1;f.jj=!1;f.dm=!1;f.hg=!1;f.fm=!1;f.gm="yt";f.Ah=null;f.gg=null;f.Zp=!1;f.send=function(){if(!this.Zp){var a=this.Uh(),a=S(this.nd,a);Qg(a);this.Zp=!0}};
-f.Uh=function(){var a={ns:this.gm,el:this.Kc,hl:this.Mc,cr:this.Lc,cpn:this.ya,docid:this.L,ver:2,referrer:this.referrer,cmt:this.De(this.A),plid:this.eb,ei:this.Qc,fmt:this.a?this.a.Pa:0,fs:this.dm?"1":"0",rt:this.De(this.K),c:this.Na,cver:this.Sa,subscribed:this.g,lact:this.md,cplatform:this.mc,cbrand:this.Ka,cmodel:this.Ta,cnetwork:this.bb,cbr:this.Ma,cbrver:this.Pc,cos:this.ib,cosver:this.oc,q:this.od};this.Bh&&(a.autoplay="1");this.fm&&(a.splay="1");this.kj&&(a.ssrt="1");this.X&&(a.delay=this.X);
-this.G&&(a.adformat=this.G);this.U&&(a.content_v=this.U);void 0!=this.pa&&this.va&&(a.uga=this.va+this.pa);void 0!=this.k&&(a.len=this.De(this.k));!this.H&&0<this.B.length&&(a.fexp=this.B.toString());void 0!=this.ga&&(a.mos=this.ga);void 0!=this.ma&&(a.volume=this.ma);void 0!=this.ja&&(a.state=this.ja);null===this.gg||(a.rtn=this.De(this.gg));this.o&&(a.feature=this.o);this.Oa&&(a.list=this.Oa);this.tb&&(a.ytr=this.tb);this.H?(a.idpj=this.Oc,a.ldpj=this.Jc,null===this.Ah||(a.rti=this.De(this.Ah))):
-(void 0!=this.I&&(a.at=this.I),void 0!=this.M&&(a.allowed=this.M),void 0!=this.aa&&(a.ex_ads=this.aa));void 0!=this.fa&&(a.live=this.fa);this.ia||(a.ps=this.Nc,a.sw=this.za,this.P&&(a.bc=this.P),this.Q&&(a.bd=this.Q,a.bt=this.nc),0<this.O&&(a.nbe=this.O));!this.hg&&0<this.i.length&&(a.st=Ka(this.i,this.De).join(","),a.et=Ka(this.j,this.De).join(","));return a};f.De=function(a){return(1*a.toFixed(3)).toString()};function $G(a,b,c,d){this.i=[];this.j=[];this.o=[];this.nj=b.hj;c&&(this.O=c.nbe,this.P=c.bc,this.Q=c.bd,this.Kc=c.bt,this.Yl=c.fs,this.Zl=c.mos,this.kj=c.ssrt,this.source=c.sourceid,this.ya=c.sd,this.Wl=c.hmewadbc,this.va=c.hmewdfc,this.Xl=c.hmewdrop,this.Ul=c.hmewvdbc,this.Lc=c.hmemdf,this.od=c.hmempaintdelay,this.nd=c.hmempainted,this.fa=c.hmempf,this.md=c.hmempresented,this.te=c.volume);this.mj=b.mj;this.zh=b.Ub;this.U=b.k;this.Pc=b.H;this.Na=b.A;this.Sa=b.B;this.Ta=b.eg;this.bb=b.lf;this.ib=
-b.G;this.oc=b.I;this.mc=b.K;this.nc=b.M;this.Qc=b.O;this.b=b.b;this.Mc=b.Y;this.o=b.o;this.Jc=b.P;this.Nc=b.i;this.am=b.sc;this.fg=b.fg?"1":void 0;this.G=Tx(b);this.ue=b.Ca;this.referrer=Ux(b);this.dg=b.U;this.H=b.j;this.I=new B(window.screen.width,window.screen.height);this.jg=b.ja;this.ja=b.ma;this.ma=b.pa;this.hj=Xx(b);this.M=Bw(b);this.pa=b.bb;this.Vl=b.aa;!a.a||a.ga.isEmpty();this.zh=a.kf||this.zh;this.za=a.Da;this.Ka=a.Nc;this.X=a.K;this.Ma=a.Na;this.a=a.a;this.$l=a.Qd;this.aa=a.cg;a.Fb&&(this.ia=
-a.cb?"dvr":"live");this.ga=a.xh;this.pd=a.pd;this.eb=a.eb;this.Oc=a.j;this.Oa=a.Oa;this.ve=a.ja;this.H=a.aa||this.H;this.bg=a.ma;this.bm=a.ij;this.g=a.g;this.lj=a.Lc;this.L=a.L;this.tb=a.ga;this.B=d||[]}f=$G.prototype;f.zh=!1;f.jj=!1;f.Yl=!1;f.hg=!1;f.Zl=!1;f.$l=!1;f.kj=!1;f.am="yt";f.bm=!1;f.dq=!1;f.send=function(){if(!this.dq){var a=this.Uh(),a=S(this.nj,a);Qg(a);this.dq=!0}};
-f.Uh=function(){var a={html5:"1",ns:this.am,ps:this.ue,el:this.Mc,hl:this.Nc,cr:this.dg,c:this.Ta,cpn:this.za,docid:this.L,sd:this.ya,sourceid:this.source,referrer:this.referrer,q:this.jg,plid:this.eb,ei:this.Oc,fmt:this.a?this.a.Pa:0,fs:this.Yl?"1":"0",screenw:this.I.width,screenh:this.I.height,w:this.M.width,h:this.M.height,vw:this.tb.width,vh:this.tb.height,playerw:this.G.width,playerh:this.G.height,vid:this.Vl,rt:this.Eh(this.K),mos:this.Zl,volume:this.te,app:this.mj,csipt:this.Ka,on3g:this.fg,
-partnerid:this.pd,sdetail:this.ve,subscribed:this.g,sw:this.Ma,list:this.Oa,eurl:this.b,framer:this.Jc,feature:this.H,ytr:this.bg,threed:this.lj,lact:this.hj,cver:this.bb,cplatform:this.Qc,cbrand:this.Pc,cmodel:this.ib,cnetwork:this.oc,cbr:this.Na,cbrver:this.Sa,cos:this.mc,cosver:this.nc};this.hg&&(a.playback="1");this.zh&&(a.autoplay="1");this.$l&&(a.splay="1");this.kj&&(a.ssrt="1");this.X&&(a.delay=this.X);this.bm&&!this.hg&&(a.vtmp="1");this.jj&&(a.tv="1");this.U&&(a.content_v=this.U);void 0!=
-this.ja&&this.ma&&(a.uga=this.ma+this.ja);void 0!=this.k&&(a.len=this.Eh(this.k));0<this.o.length&&(a.fexp=this.o.toString());0<this.aa&&(a.idpj=this.aa);0<this.ga&&(a.ldpj=this.ga);void 0!=this.pa&&(a.attrib=this.pa);void 0!=this.ia&&(a.live=this.ia);this.P&&(a.bc=this.P);this.Q&&(a.bd=this.Q,a.bt=this.Kc);0<this.O&&(a.nbe=this.O);void 0!=this.va&&(a.hmewdfc=this.va,a.hmewdrop=this.Xl,a.hmewvdbc=this.Ul,a.hmewadbc=this.Wl);void 0!=this.fa&&(a.hmempf=this.fa,a.hmemdf=this.Lc,a.hmempresented=this.md,
-a.hmempainted=this.nd,a.hmempaintdelay=this.od);0<this.i.length&&(a.st=this.i.map(this.Eh).join(","),a.et=this.j.map(this.Eh).join(","));for(var b=0;b<this.B.length;b++)Eb(zB(this.B[b]),function(b,d){d in a||(a[d]=b)});return a};f.Eh=function(a){return(1*a.toFixed(3)).toString()};function aH(){this.ab=[];this.M=[10,10,10,40];this.i=null;this.B="paused";this.fa=!1;this.k=NaN;this.P=this.K=0;this.aa=this.O=null;this.ia=xB;this.j=null;this.Q="";this.U=this.H=0;this.G=NaN;this.o=this.A=0}y(aH,K);function bH(a){var b=a.aa();a.O&&w(b,a.O());return b}function Iz(a,b,c){var d=(x()-a.A)/1E3;c=isNaN(c)?d:c;c=Math.ceil(c);var e=a.M[a.K];a.K+1<a.M.length&&a.K++;c=c+e;d=1E3*(c-d);a.k=H(v(a.ma,a,c,b),d);return c}
-aH.prototype.ma=function(a,b){if(!this.ha()){this.k=NaN;var c=cH(this),d=dH(this,c);b&&(d.Ah=a);var e=400<this.P;c.length&&!e&&(d.gg=Iz(this,!0,a));d.send();this.P++}};aH.prototype.ja=function(){var a=this.j(),b=(x()-this.A)/1E3,c=a-this.H;0!=c&&(0.5<(isNaN(this.G)?c:Math.abs(c-(b-this.G)))?(eH(this),this.o=a,this.G=NaN):(this.G=b,this.g&&isNaN(this.k)&&Iz(this,!1)));this.H=a};function eH(a){0.5<a.H-a.o&&(a.ab.push([a.o,a.H]),a.o=a.H)}function cH(a){eH(a);var b=a.ab;a.ab=[];return b}
-function Gz(a,b){var c=bH(a),d=a.ia();a.b.nj?(w(c,{state:a.B}),z(d,function(a){w(c,zB(a))}),d=new ZG(a.a,a.b,b,c)):d=new $G(a.a,a.b,c,d);d.K=(x()-a.A)/1E3;d.k=a.ga();return d}function dH(a,b){b.length||(b=[[a.o,a.o]]);for(var c=Gz(a,"watchtime"),d=0;d<b.length;d++)c.i.push(b[d][0]),c.j.push(b[d][1]);return c}
-function Jz(a){var b=a.b;a=a.a;var c=a.aa||b.j,c={ns:b.sc,html5:"1",el:b.Y,ps:b.Ca,fexp:b.o.join(",")||void 0,feature:c||void 0,ytr:a.ma||void 0,list:a.Oa,d:b.va,f:b.ga};b.Ub&&(c.autoplay="1");a.g&&(c.subscribed=a.g);return c}function lz(a){a.A=x();a=a.i;a.i.vps=["0.000:N"];a.G=x();a.H=gf(v(a.mg,a),1E4);a.j.start()}aH.prototype.onError=function(a){this.i.onError(a)};
-function Lz(a,b){if(!a.ha()){P(b.state,2)?(a.B="paused",dH(a,cH(a)).send()):P(b.state,8)?(a.B="playing",a.g&&isNaN(a.k)&&Iz(a,!1)):a.B="paused";var c=a.i,d=b.state,e;e=b.state;if(P(e,128))e="ER";else if(P(e,16)||P(e,32))e="S";else{var g=YG[vj(e)];"B"==g&&P(e,4)&&(g="PB");e=g}e!=c.g&&"N"!=e&&(!c.a.Ka||"B"!=e&&"PB"!=e||c.yj(),Bz(c,"vps",[e]),c.g=e);if(0<Ro(b,256)||P(d,128))c.onError(d.a.errorCode);(P(d,2)||P(d,128))&&c.mg()}}
-function uz(a,b,c){b.rt=(x()-a.A)/1E3;w(b,bH(a));a=S("streamingerror"==b.event?"//s.youtube.com/stream_204":a.b.jb+"player_204",Jz(a));a=S(a,b);Qg(a,c)}function qz(a,b){var c=a.b,d=a.a,e={ns:c.sc,el:c.Y,eurl:c.b,fmt:d.a?d.a.Pa:0,html5:1,list:d.Oa,plid:d.eb,ei:d.j,ps:c.Ca,noflv:1,st:a.j(),video_id:d.L};c.Ub&&(b.autoplay="1");d.rj&&(b.tmi="1");w(e,b);w(e,Rx(c));Qg(S("//www.youtube.com/live_204",e))}aH.prototype.F=function(){aH.C.F.call(this);I(this.k);this.k=NaN;hf(this.I);this.I=NaN};function fH(a,b,c){R.call(this);this.o=1;this.X={};this.D("openingpage",v(this.jr,this));this.D("initializingmode",v(this.gr,this));this.D("internalenvironmentdatachange",v(this.er,this));this.D("internalvolumechange",v(this.Vm,this));this.K=null;b instanceof Df||(b=new Df(b));this.K=b;b=this.K.args;Sg(this.a);this.a=new Lx(b||{});this.u("internalenvironmentdatachange","newdata");this.ia=Nx(this.a)?new Gh(this,1):new Ug(this,1);L(this,this.ia);this.U=new Lh(this);L(this,this.U);this.I=new Lh(this,
-1);L(this,this.I);this.P={};this.ga=Pb(["internalvideodatachange",this.Xq,"liveviewshift",this.hr,"commoninfoloaded",this.dr,"playbackready",this.Yq,"playbackstarted",this.Zq,"statechange",this.ar,"videoelementevent",this.xr]);this.ja=new Sh(this.a);this.k=new ix;L(this,this.k);this.b=null;b=new cz(this.a,1);if(this.b!=b){if(this.b){var d=this.b,e=this.ga,g;for(g in e)d.$(g,e[g],this)}b.X=this.ja;g=this.ga;for(var h in g)b.D(h,g[h],this);this.b=b}this.fa=Pb(["beginseeking",this.br,"endseeking",this.tr,
-"internalvideodatachange",this.Wm,"internalvideoformatchange",this.rr,"progresssync",this.nr,"seekto",this.or,"onLoadProgress",this.ir,"onVideoProgress",this.sr,"newlicensesession",this.ur,"playbackdataloaded",this.lr,"playbackready",this.kr,"statechange",this.mr]);this.j=null;pA(this,this.b);this.aa=-1;this.G=this.A=null;this.B={};this.M=null;this.O={};this.Q=null;c?this.S=c(this):this.S=new OG(this);L(this,this.S);this.S.D("templateerror",this.pr,this);this.S.D("templateready",this.qr,this);this.S.D("resize",
-this.wr,this);os("fs");c=this.S;c.ja=a;c.Qj()||c.u("templateerror")}y(fH,R);f=fH.prototype;f.Xd=null;f.list=null;f.bf=!0;f.wa=null;f.Ff=null;f.Ig=1;f.S=null;f.Gj=null;f.Cf=null;f.Xk=!1;f.Di=null;f.no=0;var gH={};
-function hH(a){var b=Dn.getTag();a.i=b;a.Xd=a.i;a.j&&wz(a.j,b);nj(a.i,a.Ig);if(a.a.Sd)a.Cf&&uf(a.Cf),a.Cf=J(a.i,"volumechange",v(a.Ss,a),!1);else{var b=a.i,c=a.wa.muted;b.volume=a.wa.volume/100;b.muted=c}b=a.S;b.b=a.i;b.b.parentNode||b.g.appendChild(b.b);V(b.b,"video-stream");V(b.b,"html5-main-video");c=b.app.J();c.Vb&&c.xe&&b.b.setAttribute("controls",!0);c.Dh&&b.b.setAttribute("webkit-playsinline",!0);b.b.setAttribute("x-webkit-airplay","allow");c.qj&&(b.pa=J(b.b,"click",v(b.b.play,b.b)));a.a.Wa=
-a.i}function iH(a){if(a.i){a.Cf&&(uf(a.Cf),a.Cf=null);a.j&&Cn(a.j);var b=a.S;b.b&&(F(b.b),b.b=null);a.a.Wa=null;Dn.releaseTag(a.i);a.i=null}}function zn(a,b){a.a.ub?(a.M&&(od(a.i,a.M.left,a.M.top),zd(a.i,new B(a.M.width,a.M.height)),a.M=null),mj(a.i),Cn(a.j),wz(a.j,a.i),nj(a.i,a.Ig)):Dn.releaseTag(b)}function pA(a,b){if(a.j!=b){a.j&&(jx(a.k),rA(a,a.j));a.P[b.B]=b;a.j=b;a.i&&wz(b,a.i);var c=a.fa,d;for(d in c)b.D(d,c[d],a);a.u("videoplayerchange",b);hz(b)&&jH(a)}}
-function rA(a,b){Cn(b);var c=a.fa,d;for(d in c)b.$(d,c[d],a);b!=a.b&&(c=b.B,a.P[c]==b&&delete a.P[c]);b==a.j&&(a.j=null,b!=a.b&&pA(a,a.b))}function O(a,b){return b?a.P[b]||null:a.j}function jH(a){var b=a.j.getVideoData();a.Wm("newdata",a.j,b);var c=a.k;z([To,Jw,qo,ex,pu,Pw,Tw,Zw,nt],c.B,c);a.u("videoready",b);6!=a.o&&pz(a.j)}f=fH.prototype;f.Yq=function(){kH(this,5)};f.kr=function(a){a=a.i;P(a,8)&&!P(a,2)&&this.Ud()};
-function Eh(a){!a.G&&a.I.J().sg&&(a.G=new JF(a),a.G&&lH(a,a.G));var b=a.G;b&&!b.je&&b.Xa(a.I)&&b.create()}
-function lH(a,b){L(a,b);b.D("loaded",a.Am,a);b.D("unloaded",a.Bm,a);b.D("command_pause",mH(a.Td,a));b.D("command_play",mH(a.Ud,a));b.D("command_seek",mH(a.sf,a));b.D("command_disable_controls",a.og,a);b.D("command_enable_controls",a.Ih,a);b.D("command_redirect_controls",a.Fm,a);b.D("command_stop_redirect_controls",a.Hh,a);b.D("command_redirected_show_is_playing",a.S.Lj,a.S);b.D("command_progress",a.vj,a);b.D("command_add_cuerange",a.zm,a);b.D("command_remove_cuerange",a.Dm,a);b.D("command_remove_cuerange_all",
-a.Em,a);b.D("command_update_cuerange_markers",a.Hm,a);b.D("command_preroll_ready",a.Gm,a);b.D("command_hide_all_dialogs",a.S.Kj,a.S);b.D("command_clear_video_overlays",a.Mh,a);b.D("command_log",a.tf,a);b.D("publish_external_event",a.Cm,a);b.D("command_log_timing",a.k.A,a.k)}function Fh(a){a&&a.je&&a.destroy()}f.fb=function(a,b){this.u.apply(this,arguments);this.gf.apply(this,arguments)};f.Xi=function(a,b){var c=$a(arguments);Nx(this.a)&&c.push(this.j.B);this.u.apply(this,c)};f.J=function(){return this.a};
-f.getVideoData=function(a){return(a=O(this,a))?a.getVideoData():null};f.log_=function(){};f.gr=function(){hf(0);this.a.Sd||this.Vm(this.wa)};f.uj=function(){var a=Wx(this.a);a.fs=this.a.ob;a.volume=Math.round(this.wa.volume);a.mos=this.wa.muted?1:0;this.a.lj&&this.g&&this.g.g&&"WL"==this.g.g.type&&(a.ssrt=1);return a};f.Eq=function(){var a=mx(this.k);if(this.A){var b=this.A.Ri();b&&a.push(b)}return a};f.pr=function(){hx(this.b,5,void 0,void 0)};
-f.qr=function(){this.a.Mj=this.S.a;var a=this.k,b={};b.loaded=v(this.Am,this);b.unloaded=v(this.Bm,this);b.command_pause=mH(this.Td,this);b.command_play=mH(this.Ud,this);b.command_seek=mH(this.sf,this);b.command_disable_controls=v(this.og,this);b.command_enable_controls=v(this.Ih,this);b.command_redirect_controls=v(this.Fm,this);b.command_stop_redirect_controls=v(this.Hh,this);b.command_redirected_show_is_playing=v(this.S.Lj,this.S);b.command_progress=v(this.vj,this);b.command_add_cuerange=v(this.zm,
-this);b.command_remove_cuerange=v(this.Dm,this);b.command_remove_cuerange_all=v(this.Em,this);b.command_preroll_ready=v(this.Gm,this);b.command_update_cuerange_markers=v(this.Hm,this);b.command_hide_all_dialogs=v(this.S.Kj,this.S);b.command_clear_video_overlays=v(this.Mh,this);b.command_log=v(this.tf,this);b.publish_external_event=v(this.Cm,this);b.module_menu_add=v(this.Uq,this);b.module_menu_remove=v(this.Vq,this);a.j=b;b=this.U;a.b!=b&&(jx(a),a.i={},a.b=b);this.S.sj();a=this.ia;a.b=this.S.a;for(var c in a.i)a.b[c]=
-a.i[c];for(c in a.g)a.b[c]=a.g[c];c=v(this.Wq,this);a=document;b=Xe("fullscreenchange",a);"msfullscreenchange"==b&&(b="MSFullscreenChange");this.Gj=b?J(a,b,c):null;c=this.K.args;this.a.oj?this.wa=Rh():this.wa||(this.wa={volume:100,muted:!1,nonNormalized:100});hH(this);a=new mh(c);ez(this.b,a);b=this.getVideoData();if("detailpage"==this.a.Y){var d;d=b.L;var e=Qh("yt-player-restore-playhead");d=e?e[d]:void 0;d&&(b.xa=d)}fg("yt-player-restore-playhead");this.a.Tc=UF(this.S);"detailpage"!=this.a.Y&&c&&
-(c.playlist||c.list||c.api)&&(nH(this,c),a.L||a.nf||(c=this.g,a=v(this.Um,this),c.Ae=a,c.Zd&&H(c.Ae,0)));if(c=this.K.args.jsapicallback)ha(c)||(c=n(c)),c&&mH(v(c,l,this.a.pj),l);this.a.sg=Dh(this.a)&&(!Ta(Ig())||!Ta(Kg()));ml()?this.a.hm?oH(this):"leanback"!=this.a.Y&&pH(this):hx(this.b,5,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",void 0);this.S.Pj()};function pH(a){a.u("initializingmode");kH(a,2)}
-function oH(a){a.u("initializingmode");pA(a,a.b);kH(a,3);a.a.ub||(iH(a),hH(a),wz(a.b,a.i));jz(a.b);qH(a,3)}function mH(a,b){return function(){var c=Array.prototype.slice.call(arguments);H(function(){a.apply(b||this,c)},0)}}f.tf=function(a,b,c){var d=O(this);b.event=a;d.j&&uz(d.j,b,c)};function ch(a,b){if(!isNaN(b)&&a.i){var c=1,c=a.a.lg?dh:[1],c=1>b?Oa(c,function(a){return a>=b}):Qa(c,function(a){return a<=b});a.Ig!=c&&(a.Ig=c,a.b==a.j&&nj(a.i,c),a.u("onPlaybackRateChange",c))}}
-function eh(a,b){var c=a.getVideoData(b);return c&&c.a?c.a.b.i:"unknown"}function JG(a){return(a=O(a,void 0))?Xy(a.va,a.a):"unknown"}f.getCurrentTime=function(a){return(a=O(this,a))?a.getCurrentTime():0};function Kh(a,b){var c=O(a,b);return c?c.qd():0}function gh(a,b){var c=a.getVideoData(b);if(!c)return[];c=Ka(c.k,function(a){return a.We()});db(c);return c}function qh(a,b){var c=Fz(a.b,b);c.debug_playbackQuality=eh(a);c.debug_date=(new Date).toString();return ob(c)}
-function Ow(a,b){var c=a.getVideoData(),d=!!c.Q||!!c.If||!b;a.u("threedenabled",d);d&&a.i.setAttribute("mozStereoMode","1");Kw()&&(a.i.setAttribute("mozStereoMode",d?"1":"0"),c=cl[d?c.ve:0],d=document.createElement("NvStereoExtDataElement"),d.setAttribute("stereoMode",c),Wc(document.documentElement,d),Af(d,"3DModeEvent"))}function Ch(a){return(a=O(a,1))&&a.i}
-f.xr=function(a){var b=a.target;switch(a.type){case "loadedmetadata":qs("fvb")||os("fvb");this.S.uf();break;case "loadstart":qs("gv")||os("gv");break;case "progress":case "timeupdate":qs("l2s")||(a=jj(b),a<b.buffered.length&&2<b.buffered.end(a)&&os("l2s"))}};f.ur=function(a){if(this.Xk){var b=this.no.toString();this.no++;this.Di[b]=a;a={request:$a(a.b[0]?a.b[0].message:null),sessionId:b,system:a.j.a,url:a.k};this.u("onNewLicenseSession",a)}else a.start()};
-f.ir=function(a,b){this.Xi("onLoadProgress",b)};f.sr=function(a,b){this.Xi("onVideoProgress",b)};
-f.nr=function(a,b,c,d,e){if(!e&&a.ig()&&!oz(a)){e=a.getVideoData();if(this.a.Be&&e.ta&&!e.Cn&&e.Ce>=e.tm){var g;g=a.J();var h=vb(e.we/e.ta,0,1),h={html5:"1",video_id:e.L,eurl:g.b,framer:g.P,feature:g.j,ps:g.Ca,el:g.Y,list:e.Oa,w:h,l:e.ta,plid:e.eb,ei:e.j,access_token:e.G,tpmt:e.Ce,cpn:e.Da};g.g&&(h.adformat=g.g);g.referrer&&(h.referrer=Ux(g));g.Ub&&(h.autoplay="1");g.Ea&&(h.authuser=g.Ea);g.Ua&&(h.pageid=g.Ua);e.Qd&&(h.splay="1");e.g&&(h.subscribed=e.g);w(h,Rx(g));g=S(g.jb+"set_awesome",h);Qg(g);
-e.Cn=!0}e.ta&&e.Ce>=e.rm&&rH(this)}this.vj(b,c,d,a)};f.vj=function(a,b,c,d){this.u("progresssync",a,b,c||0,(d||O(this)).B)};
-f.ar=function(a){if(!P(a.state,2)||!sH(this)){P(a.state,2)&&(this.Td(),P(a.a,32)&&this.b.ti(),this.a.qc&&KG(this,!1));if(0<Ro(a,256)){var b=a.state.a;Bh(this.b,b.errorCode,b.errorDetail)}if(P(a.state,128)&&(b=a.state,hf(0),bh(this),b=b.a,206==b.errorCode&&Bh(this.b,b.errorCode,b.errorDetail),!sH(this))){b.message||(b.messageKey||(b.messageKey="HTML5_DEFAULT_FALLBACK"),b.message=lf(b.messageKey));5==b.errorCode&&Bh(this.b,208,b.errorDetail);var c=5;206==b.errorCode&&(c=150);Sa(qj,b.errorCode)&&(c=
-b.errorCode);this.u("onError",c);this.u("onDetailedError",b)}this.u("applicationplayerstatechange",a);P(a.state,2)&&(a=this.getVideoData(),a.Fb&&!a.cb&&this.og(["play_pause"]))}};f.mr=function(a){!P(a.state,32)&&0>Ro(a,16)&&(!P(a.state,8)||this.i.ended&&!P(a.state,2)||this.Ud());this.u("presentingplayerstatechange",a);this.gf("onStateChange",a);qH(this,vj(a.state))};
-f.Xq=function(a,b,c){if("newdata"==a){Fh(this.A);Fh(this.G);a=[];for(var d in this.B)ah(this,d)&&a.push(d);this.B={};0<a.length&&this.u("controlsenabled",a);this.Hh();this.X={}}this.getVideoData().Fj?(this.Ff=Lb(this.wa),this.og(["audio"]),d=this.i,d.Ok=!0,d.muted=!0):(ah(this,"audio")&&this.Ih(["audio"]),this.i.Ok=!1,this.Ff&&(MG(this,this.Ff),this.Ff=null));d=this.getVideoData();d.Fb&&!this.a.Hj?hx(this.b,205,"DEVICE_FALLBACK",void 0):d.Fb&&!d.cb?this.og(["seek"]):this.Ih(["seek"]);this.getVideoData().jk&&
-!this.a.Ij&&hx(this.b,207,"DEVICE_FALLBACK",void 0);if(c.P||c.i.focEnabled||c.i.rmktEnabled)c=1E3*this.getVideoData().ta,tH(this,"part2viewed",0,c),tH(this,"videoplaytime25",0.25*c,c),tH(this,"videoplaytime50",0.5*c,c),tH(this,"videoplaytime75",0.75*c,c),tH(this,"videoplaytime100",c,2147483647),tH(this,"conversionview",c,2147483647)};
-f.Wm=function(a,b,c){if("newdata"==a&&(jx(this.k),ch(this,1),!b.j&&!oz(b))){var d=new aH,e=v(this.uj,this);d.O=e;e=v(this.Eq,this);d.ia=e;dz(b);b.a&&!oz(b)&&(b.j=d,e=v(b.qd,b),d.ga=e,e=v(b.getCurrentTime,b),d.j=e,e=v(b.Dq,b),d.pa=e,e=v(b.Fq,b),d.aa=e,e=b.o,d.a=b.a,d.b=e,d.Q=d.b.jb+"get_video",d.g=!1,d.i=new XG(d.a,d.b,d.pa),L(d,d.i),d.fa=!0,b.a.kg&&qz(b.j,{metric:"connected"}))}this.wa.volume=(this.wa.nonNormalized||this.wa.volume)*this.getVideoData().Ch;c.tm=Math.min(0.8*c.ta,180);this.fb("videodatachange",
-a,c,b.B)};f.rr=function(a,b){var c=this.j.getVideoData();a==c&&this.u("onPlaybackQualityChange",a.a.b.i,b)};f.er=function(){"detailpage"==this.a.Y&&Hh(this)};function Hh(a){var b=uH();if(b&&0<=b.index){var c=[];z(b.videoIds,function(a){if(a=b.videoData?b.videoData[a]:void 0)a.video_id=a.id,c.push(a)});nH(a,{videoList:c,loop:b.autoPlay,index:b.index})}}function nH(a,b){Sg(a.g);a.g=new Dm(b)}
-function tH(a,b,c,d){b in a.X||(c=new Zh(c,d,{id:b,priority:1}),c.zb.D("onEnter",a.lp,a),c.zb.D("onExit",a.lp,a),a.b.Kk(c),a.X[b]=c)}f.lp=function(a){var b=a.getId(),c=this.b.getVideoData();"part2viewed"==b?(c.P&&Qg(c.P),c.nc&&Qg(c.nc)):"conversionview"==b&&rH(this);c.Ka&&(b=a.getId(),c=Kj(c.Ka,{label:b}),Qg(c));this.b.$h(a)};
-function rH(a){var b=a.b.getVideoData();b.uo||(b.i.eventLabel=a.a.Y,b.i.playerStyle=a.a.Ca,b.P&&(b.i.feature="pyv"),b.i.vid=b.L,b.i.isAd=!("adunit"!=a.a.Y&&!b.P),nG("view",b.i),b.uo=!0)}function kH(a,b){b!=a.o&&(2==b&&qH(a,5),a.o=b,a.u("appstatechange",b))}function qH(a,b){a.aa!=b&&(a.aa=b,a.Xi("onStateChange",b))}function dG(a,b){if(a.a.Sa){var c={controlClicked:b};a.a.ob&&(c.fs=1);a.tf("",c)}}f.sf=function(a,b,c,d){(d=O(this,d))&&Az(d,a,!1!=b,c)};
-f.or=function(a,b){var c=a.getVideoData();if(1==this.o||2==this.o)c.xa=b;2==this.o?oH(this):(c=Ez(a,b),this.fb("seekto",c))};f.br=function(){this.fb("beginseeking")};f.tr=function(){this.fb("endseeking")};function MG(a,b){a.wa=b;a.u("internalvolumechange",a.wa)}function Xg(a){a.wa.muted=!0;a.u("internalvolumechange",a.wa)}function Yg(a){a.wa.muted=!1;a.u("internalvolumechange",a.wa)}function oh(a,b){var c;if(c=(new qe(b)).a){var d=a.a;d.va=c.get("d",d.va);d.ga=c.get("f",d.ga)}}
-function jh(a,b,c){b=new mh(b);return vH(a,b,void 0,c)}function vH(a,b,c,d){var e=O(a,d);if(!e)return!1;void 0!=c&&(b.mf=c);bh(a,d);ez(e,b);if(!iz(e))return!1;Px(e.J(),b.b);e==a.b?(kH(a,1),oH(a)):jz(e);return!0}function uh(a,b){var c=vH(a,b);Vg(a,c,void 0)}function Vg(a,b,c){c=O(a,c);b&&c==a.b&&(c.getVideoData().Qd=!0)}function lh(a,b,c){var d=O(a,c);d&&(bh(a,c),ez(d,b),iz(d)&&(Px(d.J(),b.b),d==a.b&&(kH(a,1),pH(a))))}
-function ho(a,b,c,d){if(!b&&!d)throw Error("Playback source is invalid");b=kh(b||null,d||null);a.a.ob||"detailpage"!=a.a.Y?d?(a.bf=!1,rh(a,b,void 0,void 0,void 0)):jh(a,b,1):(d={},c&&(d.feature=c),b=new mh(b),d=eu(a.a,b,d),c&&a.u("onNavigate",{url:d,feature:c}),window.location.href=d)}function rh(a,b,c,d,e){"string"==typeof b||b instanceof Array?nH(a,{api:b,index:c,startSeconds:d,suggestedQuality:e}):nH(a,b);b=a.g;a=v(a.Um,a);b.Ae=a;b.Zd&&H(b.Ae,0)}
-f.Um=function(){var a=vh(this.g);this.getVideoData().kf||!this.bf?uh(this,a):lh(this,a)};function po(a){var b=uH();return!(!a.g||!(a.g.loop||a.g.ua+1<a.g.Mb)||b&&!b.autoPlay)}function sH(a){return a.g&&("embedded"==a.a.Y||a.a.ob)&&po(a)?(sh(a),!0):!1}function sh(a){a.g&&(a.g.Zd?(a.g.loop||a.g.ua+1<a.g.Mb)&&uh(a,Im(a.g)):(Im(a.g),a.bf=!1))}function th(a){a.g&&(a.g.Zd?(a.g.loop||0<=a.g.ua-1)&&uh(a,Jm(a.g)):(Jm(a.g),a.bf=!1))}function uH(){var a=n("yt.www.watch.lists.getState");return a?a():null}
-function ph(a,b){var c=null;b&&(c={t:Math.floor(a.getCurrentTime(1))});return eu(a.a,a.getVideoData(1),null,c)}f.zm=function(a,b){var c=O(this,b);c&&(z(a,c.Kk,c),this.u("cuerangesadded",a))};f.Dm=function(a,b){var c=O(this,b);c&&(z(a,c.$h,c),this.u("cuerangesremoved",a))};f.Em=function(a,b){var c=O(this,b);if(c){for(var c=c.A,d=c.i.length-1;0<=d;d--)c.i[d].namespace==a&&yj(c,d);c.Xb()}};f.Hm=function(a){this.u("cuerangemarkersupdated",a)};f.Gm=function(a,b){var c=O(this,b);c&&vz(c,a)};f.Zq=function(){wH(this)};
-function wH(a){if(!a.a.pk){var b=a.b.getVideoData();if(b.L){var c=b.L;ss().docid=c}b.j&&(c=b.j,ss().ei=c);b.Da&&(c=b.Da,ss().cpn=c);0<b.xa&&(c=b.xa.toString(),ss().start=c);b=b.a.Pa.toString();ss().fmt=b;b=Math.round((a.b.b?hh(a.b.b):0)*Kh(a)).toString();ss().tds=b;os("aft");if("detailpage"==a.a.Y){var b=a.k.H,d;for(d in b)os(d,b[d]);d=a.k.o;for(var e in d)b=e,c=d[e],ss()[b]=c;b=ps().tick;e=ps().span;c=ss();if(d=n("yt.timing.reportbuilder_")){if(d=d.apply(null,[b,e,c,void 0]))rs(d),ts()}else{d={v:2,
-s:"youtube",action:cf("TIMING_ACTION")};var g=cf("TIMING_INFO")||{},h;for(h in g)c[h]=g[h];h=c.srt;delete c.srt;if(!h&&0!==h)try{var k=(window.performance||window.mozPerformance||window.msPerformance||window.webkitPerformance).timing;h=k.responseStart-k.navigationStart}catch(m){c.pt&&(h=c.pt)}if(h||0===h)c.srt=h;b.aft||(b.aft=b.vr&&b.cl&&b.cl>b.vr?b.cl:b.vr?b.vr:b.ol);b.aft&&b.plev&&(b.aft=Math.min(b.aft,b.plev));b.vr&&b.gv&&(e.vl=Math.round(b.vr-b.gv));for(var p in c)"_"!=p.charAt(0)&&(d[p]=c[p]);
-k={};p=[];h=b._start;for(var s in b)"_"!=s.charAt(0)&&(c=Math.max(Math.round(b[s]-h),0),k[s]=c,p.push(s+"."+c));d.rt=p.join(",");s={};p=[];for(var r in e)"_"!=r.charAt(0)&&(s[r]=e[r],p.push(r+"."+e[r]));d.it=p.join(",");rs(d);(r=n("ytdebug.logTiming"))&&r(d,k,s);ts()}}a.a.pk=!0}}f.Am=function(a){"remote"==a?(kH(this,6),Fh(this.A)):this.Xi("onApiChange")};f.Bm=function(a){"remote"==a&&pH(this)};
-f.Ss=function(){if(!ah(this,"audio")){var a=100*this.i.volume,a={volume:a,nonNormalized:a/this.getVideoData().Ch,muted:this.i.muted};this.wa=Lb(a);this.fb("onVolumeChange",a)}};
-f.Vm=function(a){a.volume=vb(a.volume,0,100);a.nonNormalized=a.volume/this.getVideoData().Ch;if(this.a.oj&&!this.a.Sd){var b={};b.volume=isNaN(a.volume)?Rh().volume:vb(a.volume,0,100);b.nonNormalized=a.nonNormalized;b.muted=void 0==a.muted?Rh().muted:a.muted;bg("yt-player-volume",b,2592E3)}if(ah(this,"audio"))this.Ff&&(this.Ff=Lb(a),this.fb("onVolumeChange",a));else{var b=this.i,c=a.muted;b.volume=a.volume/100;b.muted=c;this.a.Sd||this.fb("onVolumeChange",a)}};f.Wq=function(){xH(this,!!Cf())};
-function xH(a,b){a.S.Go(b);if("detailpage"==a.a.Y&&!b){var c=a.b.getVideoData(),d=n("checkCurrentVideo");if(d&&cf("VIDEO_ID")!=c.L){var e=a.getCurrentTime(),g={};g[c.L]=e;bg("yt-player-restore-playhead",g,172800);d(c.L);a.u("openingpage")}}a.a.ob=b;a.S.uf();a.fb("fullscreentoggled",b)}f.wr=function(){UG(this)};f.Mh=function(){this.fb("clearvideooverlays")};f.Uq=function(a){this.fb("menu_add",a)};f.Vq=function(a){this.fb("menu_remove",a)};f.hr=function(a){this.fb("liveviewshift",a)};
-f.Cm=function(a,b){if("onAdStateChange"==a){var c=arguments[1],d=arguments[2],e=arguments[3]||{};1==c&&wH(this);"leanback"==this.a.Y&&Nx(this.a)&&(0==c?this.Xd=this.i:this.Xd=d,this.u("onAdStateChange",c,e.video_id))}else this.u.apply(this,arguments)};f.gf=function(a,b){this.k.G.apply(this.k,arguments);this.A&&this.A.u.apply(this.A,arguments);this.G&&this.G.u.apply(this.G,arguments)};f.Ud=function(a,b){var c=O(this,b);c&&(2==this.o?oH(this):c.U?(a&&yH(this,c),P(c.i,2)?this.sf(0):yz(c)):jz(c))};
-f.Td=function(a,b){var c=O(this,b);c&&(a&&yH(this,c),tz(c))};function bh(a,b){var c=O(a,b);if(c&&1!=a.o&&2!=a.o){tz(c);if(c.j){var d=c.j;dH(d,cH(d)).send();d.i.mg()}c.U=!1;c.b&&(fz(c),c.g&&(Tg(c.k,c.g),c.k=null,c.g=null),c.a&&(c.a.xa=c.getCurrentTime()),c.G=NaN,lj(c.b),c.o.za&&oj(c.b,!1),P(c.i,128)||kz(c,tj(c.i)))}}function Zg(a,b){if(!ah(a,"play_pause")){var c=a.O.play_pause?a.Q:null;c?c.oe("control_play"):a.Ud(!1,b)}}
-function $g(a,b){if(!ah(a,"play_pause")){var c=a.O.play_pause?a.Q:null;c?c.oe("control_pause"):a.Td(!1,b)}}function LG(a,b){if(!ah(a,"play_pause")&&(!a.a.Gb||2!=a.o||Dn.hasTags(void 0))){var c=a.O.play_pause?a.Q:null;c?c.oe("control_toggle_play_pause"):(c=O(a,void 0))&&(c.ig()?a.Td(b,void 0):a.Ud(b,void 0))}}function Wg(a,b,c,d,e){if(!ah(a,"seek")){var g=a.O.seek?a.Q:null;g?g.oe("control_seek",b):a.sf(b,c,d,e)}}
-function KG(a,b){if(a.a.ob!=b)if(Bf())if(b){var c=a.S.a,d=We(["requestFullscreen","requestFullScreen"],c);d&&d.apply(c)}else(c=We(["exitFullscreen","cancelFullscreen","cancelFullScreen"],document))&&c.call(document);else a.u("onFullScreenToggleRequest"),xH(a,b)}function fG(a,b){KG(a,!1);a.u("openingpage");ms(b)}f.dr=function(a){Ox(this.a,a)};
-f.lr=function(){if(this.j==this.b){var a;if(a=Dh(this.a))if(eg("yt-remote-delayed-connect-key"))a=!0;else{a=Bg();var b=tg(Ig());a=!!xg(b,a)}if(a||!this.getVideoData(1).Tm||this.a.qc)if((b=hz(this.b))||(b=((b=this.getVideoData())&&b.I.length&&!b.O.length?0<=Ia(b.I,"fresca"):!1)||a),b){if(this.b.Q.length||0<Ii(this.b.A.b,-2147483648).length)kH(this,4),Fh(this.A);a&&kH(this,6);!this.A&&this.I.getVideoData().ca&&(this.A=new FB(this))&&lH(this,this.A);(a=this.A)&&!a.je&&a.Xa(this.I)&&a.create();Eh(this);
-jH(this)}else a=!1,this.getVideoData().ia||this.U&&(a=Yw(this.U)),a?(a=this.getVideoData(),jh(this,{video_id:a.b.ypc_vid||a.L,ypc_preview:1},1)):(this.log_("No available formats"),hx(this.b,5,"HTML5_NO_AVAILABLE_FORMATS_FALLBACK",void 0));else a="DEVICE_FALLBACK",ec||cj("iemobile")||cj("xbox")&&cj("trident")||cj("nintendo wiiu")||(a="FLASH_FALLBACK"),hx(this.b,5,a,void 0)}else jH(this)};f.jr=function(){this.Td()};
-function yH(a,b){var c=b.getVideoData(),d="html5-bezel-pause";P(b.i,8)?c.Fb&&!c.cb&&(d="html5-bezel-stop"):d="html5-bezel-play";a.S.zp(d)}function UG(a){a.a.Tc=UF(a.S);if(a.i){var b=a.getVideoData();0!=a.i.readyState&&(b.ga=new B(a.i.videoWidth,a.i.videoHeight));a.a.nv=XF(a.S,UF(a.S),VF(a.S),WF(a.S),void 0);a.a.Dg=XF(a.S,UF(a.S),VF(a.S),WF(a.S),!0);fh(O(a),"r");a.u("resize",Tx(a.a));a.fb("onResize")}}function ah(a,b){return!(!a.B[b]||!a.B[b].length)}
-f.og=function(a,b){b=b||"defaultcontext";var c=[];z(a,function(a){this.B[a]?0>this.B[a].indexOf(b)&&this.B[a].push(b):(this.B[a]=[b],c.push(a))},this);0<c.length&&this.u("controlsdisabled",c)};f.Ih=function(a,b){b=b||"defaultcontext";var c=[];z(a,function(a){if(ah(this,a)){var e=this.B[a].indexOf(b);0<=e&&this.B[a].splice(e,1);0==this.B[a].length&&c.push(a)}},this);0<c.length&&this.u("controlsenabled",c)};
-f.Fm=function(a,b,c){this.Hh();this.Q=a;b&&z(b,function(a){this.O[a]=!0},this);c&&kx(this.k,a,c)};f.Hh=function(){this.Q=null;this.O={};lx(this.k)};function QG(a){var b=a.getVideoData();return b&&b.Ma&&!im.test(b.Ma)?!a.a.Rh:a.a.Ac}f.F=function(){iH(this);this.Gj&&uf(this.Gj);hf(0);Tg(Gb(this.P));this.P={};this.j=this.b=null;Tg(this.a,this.g);this.K=this.I=this.ia=this.U=this.Xd=null;fH.C.F.call(this)};pa("yt.player.Application",fH);function zH(a,b,c,d){a={name:a,locale:c,feature:d};for(var e in b)a[e]=b[e];b=S("/sharing_services",a);Qg(b)}function AH(a,b,c,d,e,g){var h={};b&&(h.v=b);c&&(h.list=c);d&&(h.url=d);zH(a,h,e,g)}function BH(a,b,c,d){zH(a,{v:b},c,d)}function CH(a,b,c,d,e){zH(a,{list:b,v:c},d,e)};Tr(Xr);Tr(Kt);n("yt.tracking.shareVideo")||(pa("yt.tracking.share",AH),pa("yt.tracking.shareVideo",BH),pa("yt.tracking.shareList",CH));n("yt.window.popup")||(pa("yt.window.popup",ns),pa("yt.window.open",ms));pa("yt.player.Application.create",function(a,b){gH[a]&&(gH[a].dispose(),gH[a]=null);var c=new fH(a,b);Rg(c,function(){gH[a]=null});gH[a]=c});})();
diff --git a/test/testdata/watch_as3-vflg5GhxU.swf b/test/testdata/watch_as3-vflg5GhxU.swf
deleted file mode 100644 (file)
index 62300be..0000000
Binary files a/test/testdata/watch_as3-vflg5GhxU.swf and /dev/null differ
index a11f2b0f31f8055c0d8f71dfd5ccc3d01055c1bb..dc47dc0dba5b5a5945259c2dffeac63ca46b9ef0 100755 (executable)
Binary files a/youtube-dl and b/youtube-dl differ
index 9f2b1099740ba145e312bca5f1373c993bc5c5fa..5dcfe85db89f99b5c8458cdb9b1b12f98930b6b0 100644 (file)
@@ -25,6 +25,8 @@ redistribute it or use it however you like.
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ sudo\ if\ needed)
 \-i,\ \-\-ignore\-errors\ \ \ \ \ \ \ \ continue\ on\ download\ errors,\ for\ example\ to\ to
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ skip\ unavailable\ videos\ in\ a\ playlist
+\-\-abort\-on\-error\ \ \ \ \ \ \ \ \ \ \ Abort\ downloading\ of\ further\ videos\ (in\ the
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ playlist\ or\ the\ command\ line)\ if\ an\ error\ occurs
 \-\-dump\-user\-agent\ \ \ \ \ \ \ \ \ \ display\ the\ current\ browser\ identification
 \-\-user\-agent\ UA\ \ \ \ \ \ \ \ \ \ \ \ specify\ a\ custom\ user\ agent
 \-\-referer\ REF\ \ \ \ \ \ \ \ \ \ \ \ \ \ specify\ a\ custom\ referer,\ use\ if\ the\ video\ access
@@ -34,7 +36,7 @@ redistribute it or use it however you like.
 \-\-extractor\-descriptions\ \ \ Output\ descriptions\ of\ all\ supported\ extractors
 \-\-proxy\ URL\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Use\ the\ specified\ HTTP/HTTPS\ proxy
 \-\-no\-check\-certificate\ \ \ \ \ Suppress\ HTTPS\ certificate\ validation.
-\-\-cache\-dir\ None\ \ \ \ \ \ \ \ \ \ \ Location\ in\ the\ filesystem\ where\ youtube\-dl\ can
+\-\-cache\-dir\ DIR\ \ \ \ \ \ \ \ \ \ \ \ Location\ in\ the\ filesystem\ where\ youtube\-dl\ can
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ store\ downloaded\ information\ permanently.\ By
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ default\ $XDG_CACHE_HOME/youtube\-dl\ or\ ~/.cache
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ /youtube\-dl\ .
@@ -60,15 +62,19 @@ redistribute it or use it however you like.
 \-\-datebefore\ DATE\ \ \ \ \ \ \ \ \ \ download\ only\ videos\ uploaded\ before\ this\ date
 \-\-dateafter\ DATE\ \ \ \ \ \ \ \ \ \ \ download\ only\ videos\ uploaded\ after\ this\ date
 \-\-no\-playlist\ \ \ \ \ \ \ \ \ \ \ \ \ \ download\ only\ the\ currently\ playing\ video
+\-\-age\-limit\ YEARS\ \ \ \ \ \ \ \ \ \ download\ only\ videos\ suitable\ for\ the\ given\ age
+\-\-download\-archive\ FILE\ \ \ \ Download\ only\ videos\ not\ present\ in\ the\ archive
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ file.\ Record\ all\ downloaded\ videos\ in\ it.
 \f[]
 .fi
 .SS Download Options:
 .IP
 .nf
 \f[C]
-\-r,\ \-\-rate\-limit\ LIMIT\ \ \ \ \ maximum\ download\ rate\ (e.g.\ 50k\ or\ 44.6m)
+\-r,\ \-\-rate\-limit\ LIMIT\ \ \ \ \ maximum\ download\ rate\ in\ bytes\ per\ second\ (e.g.
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ 50K\ or\ 4.2M)
 \-R,\ \-\-retries\ RETRIES\ \ \ \ \ \ number\ of\ retries\ (default\ is\ 10)
-\-\-buffer\-size\ SIZE\ \ \ \ \ \ \ \ \ size\ of\ download\ buffer\ (e.g.\ 1024\ or\ 16k)
+\-\-buffer\-size\ SIZE\ \ \ \ \ \ \ \ \ size\ of\ download\ buffer\ (e.g.\ 1024\ or\ 16K)
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (default\ is\ 1024)
 \-\-no\-resize\-buffer\ \ \ \ \ \ \ \ \ do\ not\ automatically\ adjust\ the\ buffer\ size.\ By
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ default,\ the\ buffer\ size\ is\ automatically\ resized
@@ -88,15 +94,17 @@ redistribute it or use it however you like.
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ %(uploader_id)s\ for\ the\ uploader\ nickname\ if
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ different,\ %(autonumber)s\ to\ get\ an\ automatically
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ incremented\ number,\ %(ext)s\ for\ the\ filename
-\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ extension,\ %(upload_date)s\ for\ the\ upload\ date
-\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (YYYYMMDD),\ %(extractor)s\ for\ the\ provider
-\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (youtube,\ metacafe,\ etc),\ %(id)s\ for\ the\ video\ id
-\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ ,\ %(playlist)s\ for\ the\ playlist\ the\ video\ is\ in,
-\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ %(playlist_index)s\ for\ the\ position\ in\ the
-\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ playlist\ and\ %%\ for\ a\ literal\ percent.\ Use\ \-\ to
-\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ output\ to\ stdout.\ Can\ also\ be\ used\ to\ download\ to
-\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ a\ different\ directory,\ for\ example\ with\ \-o\ \[aq]/my/d
-\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ ownloads/%(uploader)s/%(title)s\-%(id)s.%(ext)s\[aq]\ .
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ extension,\ %(format)s\ for\ the\ format\ description
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (like\ "22\ \-\ 1280x720"\ or\ "HD")%(upload_date)s\ for
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ the\ upload\ date\ (YYYYMMDD),\ %(extractor)s\ for\ the
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ provider\ (youtube,\ metacafe,\ etc),\ %(id)s\ for\ the
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ video\ id\ ,\ %(playlist)s\ for\ the\ playlist\ the
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ video\ is\ in,\ %(playlist_index)s\ for\ the\ position
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ in\ the\ playlist\ and\ %%\ for\ a\ literal\ percent.\ Use
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \-\ to\ output\ to\ stdout.\ Can\ also\ be\ used\ to
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ download\ to\ a\ different\ directory,\ for\ example
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ with\ \-o\ \[aq]/my/downloads/%(uploader)s/%(title)s\-%(i
+\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ d)s.%(ext)s\[aq]\ .
 \-\-autonumber\-size\ NUMBER\ \ \ Specifies\ the\ number\ of\ digits\ in\ %(autonumber)s
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ when\ it\ is\ present\ in\ output\ filename\ template\ or
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \-\-autonumber\ option\ is\ given
@@ -113,6 +121,7 @@ redistribute it or use it however you like.
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ file\ modification\ time
 \-\-write\-description\ \ \ \ \ \ \ \ write\ video\ description\ to\ a\ .description\ file
 \-\-write\-info\-json\ \ \ \ \ \ \ \ \ \ write\ video\ metadata\ to\ a\ .info.json\ file
+\-\-write\-annotations\ \ \ \ \ \ \ \ write\ video\ annotations\ to\ a\ .annotation\ file
 \-\-write\-thumbnail\ \ \ \ \ \ \ \ \ \ write\ thumbnail\ image\ to\ disk
 \f[]
 .fi
@@ -199,6 +208,7 @@ redistribute it or use it however you like.
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ processed\ files\ are\ overwritten\ by\ default
 \-\-embed\-subs\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ embed\ subtitles\ in\ the\ video\ (only\ for\ mp4
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ videos)
+\-\-add\-metadata\ \ \ \ \ \ \ \ \ \ \ \ \ add\ metadata\ to\ the\ files
 \f[]
 .fi
 .SH CONFIGURATION
index abbe6af49db5a31cc8302b5b8e531a03c6afc190..5132eacd9ca6a47a80ca73643f5d48f66a279b43 100644 (file)
@@ -1,9 +1,9 @@
-__youtube-dl()
+__youtube_dl()
 {
     local cur prev opts
     COMPREPLY=()
     cur="${COMP_WORDS[COMP_CWORD]}"
-    opts="--help --version --update --ignore-errors --dump-user-agent --user-agent --referer --list-extractors --extractor-descriptions --proxy --no-check-certificate --cache-dir --no-cache-dir --playlist-start --playlist-end --match-title --reject-title --max-downloads --min-filesize --max-filesize --date --datebefore --dateafter --no-playlist --rate-limit --retries --buffer-size --no-resize-buffer --test --title --id --literal --auto-number --output --autonumber-size --restrict-filenames --batch-file --no-overwrites --continue --no-continue --cookies --no-part --no-mtime --write-description --write-info-json --write-thumbnail --quiet --simulate --skip-download --get-url --get-title --get-id --get-thumbnail --get-description --get-filename --get-format --newline --no-progress --console-title --verbose --dump-intermediate-pages --youtube-print-sig-code --format --all-formats --prefer-free-formats --max-quality --list-formats --write-sub --write-auto-sub --all-subs --list-subs --sub-format --sub-lang --username --password --netrc --video-password --extract-audio --audio-format --audio-quality --recode-video --keep-video --no-post-overwrites --embed-subs"
+    opts="--help --version --update --ignore-errors --abort-on-error --dump-user-agent --user-agent --referer --list-extractors --extractor-descriptions --proxy --no-check-certificate --cache-dir --no-cache-dir --playlist-start --playlist-end --match-title --reject-title --max-downloads --min-filesize --max-filesize --date --datebefore --dateafter --no-playlist --age-limit --download-archive --rate-limit --retries --buffer-size --no-resize-buffer --test --title --id --literal --auto-number --output --autonumber-size --restrict-filenames --batch-file --no-overwrites --continue --no-continue --cookies --no-part --no-mtime --write-description --write-info-json --write-annotations --write-thumbnail --quiet --simulate --skip-download --get-url --get-title --get-id --get-thumbnail --get-description --get-filename --get-format --newline --no-progress --console-title --verbose --dump-intermediate-pages --youtube-print-sig-code --format --all-formats --prefer-free-formats --max-quality --list-formats --write-sub --write-auto-sub --all-subs --list-subs --sub-format --sub-lang --username --password --netrc --video-password --extract-audio --audio-format --audio-quality --recode-video --keep-video --no-post-overwrites --embed-subs --add-metadata"
     keywords=":ytfavorites :ytrecommended :ytsubscriptions :ytwatchlater"
 
     if [[ ${cur} =~ : ]]; then
@@ -15,4 +15,4 @@ __youtube-dl()
     fi
 }
 
-complete -F __youtube-dl youtube-dl
+complete -F __youtube_dl youtube-dl
index d6673fd3ab88d543086417f903cf2ff7d4019944..8ecabab1a517467c118dad0857c47291bcb2f929 100644 (file)
@@ -270,6 +270,7 @@ class FileDownloader(object):
     def _download_with_rtmpdump(self, filename, url, player_url, page_url, play_path, tc_url):
         self.report_destination(filename)
         tmpfilename = self.temp_name(filename)
+        test = self.params.get('test', False)
 
         # Check for rtmpdump first
         try:
@@ -291,6 +292,8 @@ class FileDownloader(object):
             basic_args += ['--playpath', play_path]
         if tc_url is not None:
             basic_args += ['--tcUrl', url]
+        if test:
+            basic_args += ['--stop', '1']
         args = basic_args + [[], ['--resume', '--skip', '1']][self.params.get('continuedl', False)]
         if self.params.get('verbose', False):
             try:
@@ -300,7 +303,7 @@ class FileDownloader(object):
                 shell_quote = repr
             self.to_screen(u'[debug] rtmpdump command line: ' + shell_quote(args))
         retval = subprocess.call(args)
-        while retval == 2 or retval == 1:
+        while (retval == 2 or retval == 1) and not test:
             prevsize = os.path.getsize(encodeFilename(tmpfilename))
             self.to_screen(u'\r[rtmpdump] %s bytes' % prevsize, skip_eol=True)
             time.sleep(5.0) # This seems to be needed
@@ -313,7 +316,7 @@ class FileDownloader(object):
                 self.to_screen(u'\r[rtmpdump] Could not download the whole video. This can happen for some advertisements.')
                 retval = 0
                 break
-        if retval == 0:
+        if retval == 0 or (test and retval == 2):
             fsize = os.path.getsize(encodeFilename(tmpfilename))
             self.to_screen(u'\r[rtmpdump] %s bytes' % fsize)
             self.try_rename(tmpfilename, filename)
index 3ee1d3c5865e203f564d87c8beb55a3de3a46934..13b56ede5fdb3d66064a8072cdda87787eee1bae 100644 (file)
@@ -3,7 +3,14 @@ import subprocess
 import sys
 import time
 
-from .utils import *
+
+from .utils import (
+    compat_subprocess_get_DEVNULL,
+    encodeFilename,
+    PostProcessingError,
+    shell_quote,
+    subtitles_filename,
+)
 
 
 class PostProcessor(object):
@@ -82,6 +89,8 @@ class FFmpegPostProcessor(PostProcessor):
                + opts +
                [encodeFilename(self._ffmpeg_filename_argument(out_path))])
 
+        if self._downloader.params.get('verbose', False):
+            self._downloader.to_screen(u'[debug] ffmpeg command line: %s' % shell_quote(cmd))
         p = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
         stdout,stderr = p.communicate()
         if p.returncode != 0:
@@ -177,7 +186,8 @@ class FFmpegExtractAudioPP(FFmpegPostProcessor):
             extension = self._preferredcodec
             more_opts = []
             if self._preferredquality is not None:
-                if int(self._preferredquality) < 10:
+                # The opus codec doesn't support the -aq option
+                if int(self._preferredquality) < 10 and extension != 'opus':
                     more_opts += [self._exes['avconv'] and '-q:a' or '-aq', self._preferredquality]
                 else:
                     more_opts += [self._exes['avconv'] and '-b:a' or '-ab', self._preferredquality + 'k']
@@ -467,3 +477,35 @@ class FFmpegEmbedSubtitlePP(FFmpegPostProcessor):
         os.rename(encodeFilename(temp_filename), encodeFilename(filename))
 
         return True, information
+
+
+class FFmpegMetadataPP(FFmpegPostProcessor):
+    def run(self, info):
+        metadata = {}
+        if info.get('title') is not None:
+            metadata['title'] = info['title']
+        if info.get('upload_date') is not None:
+            metadata['date'] = info['upload_date']
+        if info.get('uploader') is not None:
+            metadata['artist'] = info['uploader']
+        elif info.get('uploader_id') is not None:
+            metadata['artist'] = info['uploader_id']
+
+        if not metadata:
+            self._downloader.to_screen(u'[ffmpeg] There isn\'t any metadata to add')
+            return True, info
+
+        filename = info['filepath']
+        ext = os.path.splitext(filename)[1][1:]
+        temp_filename = filename + u'.temp'
+
+        options = ['-c', 'copy']
+        for (name, value) in metadata.items():
+            options.extend(['-metadata', '%s="%s"' % (name, value)])
+        options.extend(['-f', ext])
+
+        self._downloader.to_screen(u'[ffmpeg] Adding metadata to \'%s\'' % filename)
+        self.run_ffmpeg(filename, temp_filename, options)
+        os.remove(encodeFilename(filename))
+        os.rename(encodeFilename(temp_filename), encodeFilename(filename))
+        return True, info
index 2503fd09b976b86da60c9a82fd31495266106c97..e2332f9b84ef2c41d6cf986553d4f999bac946a6 100644 (file)
@@ -3,6 +3,7 @@
 
 from __future__ import absolute_import
 
+import errno
 import io
 import os
 import re
@@ -70,6 +71,7 @@ class YoutubeDL(object):
     logtostderr:       Log messages to stderr instead of stdout.
     writedescription:  Write the video description to a .description file
     writeinfojson:     Write the video description to a .info.json file
+    writeannotations:  Write the video annotations to a .annotations.xml file
     writethumbnail:    Write the thumbnail image to a file
     writesubtitles:    Write the video subtitles to a file
     writeautomaticsub: Write the automatic subtitles to a file
@@ -84,7 +86,12 @@ class YoutubeDL(object):
     cachedir:          Location of the cache files in the filesystem.
                        None to disable filesystem cache.
     noplaylist:        Download single video instead of a playlist if in doubt.
-    
+    age_limit:         An integer representing the user's age in years.
+                       Unsuitable videos for the given age are skipped.
+    downloadarchive:   File name of a file where all downloads are recorded.
+                       Videos already present in the file are not downloaded
+                       again.
+
     The following parameters are not used by YoutubeDL itself, they are used by
     the FileDownloader:
     nopart, updatetime, buffersize, ratelimit, min_filesize, max_filesize, test,
@@ -113,7 +120,7 @@ class YoutubeDL(object):
                 and not params['restrictfilenames']):
             # On Python 3, the Unicode filesystem API will throw errors (#1474)
             self.report_warning(
-                u'Assuming --restrict-filenames isnce file system encoding '
+                u'Assuming --restrict-filenames since file system encoding '
                 u'cannot encode all charactes. '
                 u'Set the LC_ALL environment variable to fix this.')
             params['restrictfilenames'] = True
@@ -209,10 +216,10 @@ class YoutubeDL(object):
         If stderr is a tty file the 'WARNING:' will be colored
         '''
         if sys.stderr.isatty() and os.name != 'nt':
-            _msg_header=u'\033[0;33mWARNING:\033[0m'
+            _msg_header = u'\033[0;33mWARNING:\033[0m'
         else:
-            _msg_header=u'WARNING:'
-        warning_message=u'%s %s' % (_msg_header,message)
+            _msg_header = u'WARNING:'
+        warning_message = u'%s %s' % (_msg_header, message)
         self.to_stderr(warning_message)
 
     def report_error(self, message, tb=None):
@@ -227,19 +234,6 @@ class YoutubeDL(object):
         error_message = u'%s %s' % (_msg_header, message)
         self.trouble(error_message, tb)
 
-    def slow_down(self, start_time, byte_counter):
-        """Sleep if the download speed is over the rate limit."""
-        rate_limit = self.params.get('ratelimit', None)
-        if rate_limit is None or byte_counter == 0:
-            return
-        now = time.time()
-        elapsed = now - start_time
-        if elapsed <= 0.0:
-            return
-        speed = float(byte_counter) / elapsed
-        if speed > rate_limit:
-            time.sleep((byte_counter - rate_limit * (now - start_time)) / rate_limit)
-
     def report_writedescription(self, descfn):
         """ Report that the description file is being written """
         self.to_screen(u'[info] Writing video description to: ' + descfn)
@@ -252,6 +246,10 @@ class YoutubeDL(object):
         """ Report that the metadata file has been written """
         self.to_screen(u'[info] Video description metadata as JSON to: ' + infofn)
 
+    def report_writeannotations(self, annofn):
+        """ Report that the annotations file has been written. """
+        self.to_screen(u'[info] Writing video annotations to: ' + annofn)
+
     def report_file_already_downloaded(self, file_name):
         """Report file has already been fully downloaded."""
         try:
@@ -277,13 +275,15 @@ class YoutubeDL(object):
             if template_dict['playlist_index'] is not None:
                 template_dict['playlist_index'] = u'%05d' % template_dict['playlist_index']
 
-            sanitize = lambda k,v: sanitize_filename(
+            sanitize = lambda k, v: sanitize_filename(
                 u'NA' if v is None else compat_str(v),
                 restricted=self.params.get('restrictfilenames'),
-                is_id=(k==u'id'))
-            template_dict = dict((k, sanitize(k, v)) for k,v in template_dict.items())
+                is_id=(k == u'id'))
+            template_dict = dict((k, sanitize(k, v))
+                                 for k, v in template_dict.items())
 
-            filename = self.params['outtmpl'] % template_dict
+            tmpl = os.path.expanduser(self.params['outtmpl'])
+            filename = tmpl % template_dict
             return filename
         except KeyError as err:
             self.report_error(u'Erroneous output template')
@@ -309,15 +309,22 @@ class YoutubeDL(object):
             dateRange = self.params.get('daterange', DateRange())
             if date not in dateRange:
                 return u'[download] %s upload date is not in range %s' % (date_from_str(date).isoformat(), dateRange)
+        age_limit = self.params.get('age_limit')
+        if age_limit is not None:
+            if age_limit < info_dict.get('age_limit', 0):
+                return u'Skipping "' + title + '" because it is age restricted'
+        if self.in_download_archive(info_dict):
+            return (u'%(title)s has already been recorded in archive'
+                    % info_dict)
         return None
-        
+
     def extract_info(self, url, download=True, ie_key=None, extra_info={}):
         '''
         Returns a list with a dictionary for each video we find.
         If 'download', also downloads the videos.
         extra_info is a dict containing the extra values to add to each result
          '''
-        
+
         if ie_key:
             ies = [self.get_info_extractor(ie_key)]
         else:
@@ -359,7 +366,7 @@ class YoutubeDL(object):
                     raise
         else:
             self.report_error(u'no suitable InfoExtractor: %s' % url)
-        
+
     def process_ie_result(self, ie_result, download=True, extra_info={}):
         """
         Take the result of the ie(may be modified) and resolve all unresolved
@@ -372,13 +379,7 @@ class YoutubeDL(object):
         result_type = ie_result.get('_type', 'video') # If not given we suppose it's a video, support the default old system
         if result_type == 'video':
             ie_result.update(extra_info)
-            if 'playlist' not in ie_result:
-                # It isn't part of a playlist
-                ie_result['playlist'] = None
-                ie_result['playlist_index'] = None
-            if download:
-                self.process_info(ie_result)
-            return ie_result
+            return self.process_video_result(ie_result)
         elif result_type == 'url':
             # We have to add extra_info to the results because it may be
             # contained in a playlist
@@ -389,7 +390,7 @@ class YoutubeDL(object):
         elif result_type == 'playlist':
             # We process each entry in the playlist
             playlist = ie_result.get('title', None) or ie_result.get('id', None)
-            self.to_screen(u'[download] Downloading playlist: %s'  % playlist)
+            self.to_screen(u'[download] Downloading playlist: %s' % playlist)
 
             playlist_results = []
 
@@ -407,12 +408,12 @@ class YoutubeDL(object):
             self.to_screen(u"[%s] playlist '%s': Collected %d video ids (downloading %d of them)" %
                 (ie_result['extractor'], playlist, n_all_entries, n_entries))
 
-            for i,entry in enumerate(entries,1):
-                self.to_screen(u'[download] Downloading video #%s of %s' %(i, n_entries))
+            for i, entry in enumerate(entries, 1):
+                self.to_screen(u'[download] Downloading video #%s of %s' % (i, n_entries))
                 extra = {
-                         'playlist': playlist, 
-                         'playlist_index': i + playliststart,
-                         }
+                    'playlist': playlist,
+                    'playlist_index': i + playliststart,
+                }
                 if not 'extractor' in entry:
                     # We set the extractor, if it's an url it will be set then to
                     # the new extractor, but if it's already a video we must make
@@ -436,6 +437,103 @@ class YoutubeDL(object):
         else:
             raise Exception('Invalid result type: %s' % result_type)
 
+    def select_format(self, format_spec, available_formats):
+        if format_spec == 'best' or format_spec is None:
+            return available_formats[-1]
+        elif format_spec == 'worst':
+            return available_formats[0]
+        else:
+            extensions = [u'mp4', u'flv', u'webm', u'3gp']
+            if format_spec in extensions:
+                filter_f = lambda f: f['ext'] == format_spec
+            else:
+                filter_f = lambda f: f['format_id'] == format_spec
+            matches = list(filter(filter_f, available_formats))
+            if matches:
+                return matches[-1]
+        return None
+
+    def process_video_result(self, info_dict, download=True):
+        assert info_dict.get('_type', 'video') == 'video'
+
+        if 'playlist' not in info_dict:
+            # It isn't part of a playlist
+            info_dict['playlist'] = None
+            info_dict['playlist_index'] = None
+
+        # This extractors handle format selection themselves
+        if info_dict['extractor'] in [u'youtube', u'Youku', u'YouPorn', u'mixcloud']:
+            if download:
+                self.process_info(info_dict)
+            return info_dict
+
+        # We now pick which formats have to be downloaded
+        if info_dict.get('formats') is None:
+            # There's only one format available
+            formats = [info_dict]
+        else:
+            formats = info_dict['formats']
+
+        # We check that all the formats have the format and format_id fields
+        for (i, format) in enumerate(formats):
+            if format.get('format_id') is None:
+                format['format_id'] = compat_str(i)
+            if format.get('format') is None:
+                format['format'] = u'{id} - {res}{note}'.format(
+                    id=format['format_id'],
+                    res=self.format_resolution(format),
+                    note=u' ({})'.format(format['format_note']) if format.get('format_note') is not None else '',
+                )
+
+        if self.params.get('listformats', None):
+            self.list_formats(info_dict)
+            return
+
+        format_limit = self.params.get('format_limit', None)
+        if format_limit:
+            formats = list(takewhile_inclusive(
+                lambda f: f['format_id'] != format_limit, formats
+            ))
+        if self.params.get('prefer_free_formats'):
+            def _free_formats_key(f):
+                try:
+                    ext_ord = [u'flv', u'mp4', u'webm'].index(f['ext'])
+                except ValueError:
+                    ext_ord = -1
+                # We only compare the extension if they have the same height and width
+                return (f.get('height'), f.get('width'), ext_ord)
+            formats = sorted(formats, key=_free_formats_key)
+
+        req_format = self.params.get('format', 'best')
+        if req_format is None:
+            req_format = 'best'
+        formats_to_download = []
+        # The -1 is for supporting YoutubeIE
+        if req_format in ('-1', 'all'):
+            formats_to_download = formats
+        else:
+            # We can accept formats requestd in the format: 34/5/best, we pick
+            # the first that is available, starting from left
+            req_formats = req_format.split('/')
+            for rf in req_formats:
+                selected_format = self.select_format(rf, formats)
+                if selected_format is not None:
+                    formats_to_download = [selected_format]
+                    break
+        if not formats_to_download:
+            raise ExtractorError(u'requested format not available')
+
+        if download:
+            if len(formats_to_download) > 1:
+                self.to_screen(u'[info] %s: downloading video in %s formats' % (info_dict['id'], len(formats_to_download)))
+            for format in formats_to_download:
+                new_info = dict(info_dict)
+                new_info.update(format)
+                self.process_info(new_info)
+        # We update the info dict with the best quality format (backwards compatibility)
+        info_dict.update(formats_to_download[-1])
+        return info_dict
+
     def process_info(self, info_dict):
         """Process a single resolved IE result."""
 
@@ -509,10 +607,22 @@ class YoutubeDL(object):
                 self.report_error(u'Cannot write description file ' + descfn)
                 return
 
+        if self.params.get('writeannotations', False):
+            try:
+                annofn = filename + u'.annotations.xml'
+                self.report_writeannotations(annofn)
+                with io.open(encodeFilename(annofn), 'w', encoding='utf-8') as annofile:
+                    annofile.write(info_dict['annotations'])
+            except (KeyError, TypeError):
+                self.report_warning(u'There are no annotations to write.')
+            except (OSError, IOError):
+                self.report_error(u'Cannot write annotations file: ' + annofn)
+                return
+
         subtitles_are_requested = any([self.params.get('writesubtitles', False),
                                        self.params.get('writeautomaticsub')])
 
-        if  subtitles_are_requested and 'subtitles' in info_dict and info_dict['subtitles']:
+        if subtitles_are_requested and 'subtitles' in info_dict and info_dict['subtitles']:
             # subtitles download errors are already managed as troubles in relevant IE
             # that way it will silently go on when used with unsupporting IE
             subtitles = info_dict['subtitles']
@@ -534,7 +644,7 @@ class YoutubeDL(object):
             infofn = filename + u'.info.json'
             self.report_writeinfojson(infofn)
             try:
-                json_info_dict = dict((k, v) for k,v in info_dict.items() if not k in ['urlhandle'])
+                json_info_dict = dict((k, v) for k, v in info_dict.items() if not k in ['urlhandle'])
                 write_json_file(json_info_dict, encodeFilename(infofn))
             except (OSError, IOError):
                 self.report_error(u'Cannot write metadata to JSON file ' + infofn)
@@ -578,6 +688,8 @@ class YoutubeDL(object):
                     self.report_error(u'postprocessing: %s' % str(err))
                     return
 
+        self.record_download_archive(info_dict)
+
     def download(self, url_list):
         """Download a given list of URLs."""
         if len(url_list) > 1 and self.fixed_template():
@@ -602,7 +714,7 @@ class YoutubeDL(object):
         keep_video = None
         for pp in self._pps:
             try:
-                keep_video_wish,new_info = pp.run(info)
+                keep_video_wish, new_info = pp.run(info)
                 if keep_video_wish is not None:
                     if keep_video_wish:
                         keep_video = keep_video_wish
@@ -617,3 +729,55 @@ class YoutubeDL(object):
                 os.remove(encodeFilename(filename))
             except (IOError, OSError):
                 self.report_warning(u'Unable to remove downloaded video file')
+
+    def in_download_archive(self, info_dict):
+        fn = self.params.get('download_archive')
+        if fn is None:
+            return False
+        vid_id = info_dict['extractor'] + u' ' + info_dict['id']
+        try:
+            with locked_file(fn, 'r', encoding='utf-8') as archive_file:
+                for line in archive_file:
+                    if line.strip() == vid_id:
+                        return True
+        except IOError as ioe:
+            if ioe.errno != errno.ENOENT:
+                raise
+        return False
+
+    def record_download_archive(self, info_dict):
+        fn = self.params.get('download_archive')
+        if fn is None:
+            return
+        vid_id = info_dict['extractor'] + u' ' + info_dict['id']
+        with locked_file(fn, 'a', encoding='utf-8') as archive_file:
+            archive_file.write(vid_id + u'\n')
+
+    @staticmethod
+    def format_resolution(format):
+        if format.get('height') is not None:
+            if format.get('width') is not None:
+                res = u'%sx%s' % (format['width'], format['height'])
+            else:
+                res = u'%sp' % format['height']
+        else:
+            res = '???'
+        return res
+
+    def list_formats(self, info_dict):
+        formats_s = []
+        for format in info_dict.get('formats', [info_dict]):
+            formats_s.append(u'%-15s: %-5s     %-15s[%s]' % (
+                format['format_id'],
+                format['ext'],
+                format.get('format_note') or '-',
+                self.format_resolution(format),
+                )
+            )
+        if len(formats_s) != 1:
+            formats_s[0] += ' (worst)'
+            formats_s[-1] += ' (best)'
+        formats_s = "\n".join(formats_s)
+        self.to_screen(u'[info] Available formats for %s:\n'
+            u'format code    extension   note           resolution\n%s' % (
+                info_dict['id'], formats_s))
index 03df835f23ebe58bd1048d336ba68019e4a2e33d..fce1adf0cffbf527841dfada34b931d93f67fd5a 100644 (file)
@@ -31,11 +31,13 @@ __authors__  = (
     'Huarong Huo',
     'Ismael Mejía',
     'Steffan \'Ruirize\' James',
+    'Andras Elso',
 )
 
 __license__ = 'Public Domain'
 
 import codecs
+import collections
 import getpass
 import optparse
 import os
@@ -45,17 +47,43 @@ import shlex
 import socket
 import subprocess
 import sys
-import warnings
+import traceback
 import platform
 
 
-from .utils import *
+from .utils import (
+    compat_cookiejar,
+    compat_print,
+    compat_str,
+    compat_urllib_request,
+    DateRange,
+    decodeOption,
+    determine_ext,
+    DownloadError,
+    get_cachedir,
+    make_HTTPS_handler,
+    MaxDownloadsReached,
+    platform_name,
+    preferredencoding,
+    SameFileError,
+    std_headers,
+    write_string,
+    YoutubeDLHandler,
+)
 from .update import update_self
 from .version import __version__
-from .FileDownloader import *
+from .FileDownloader import (
+    FileDownloader,
+)
 from .extractor import gen_extractors
 from .YoutubeDL import YoutubeDL
-from .PostProcessor import *
+from .PostProcessor import (
+    FFmpegMetadataPP,
+    FFmpegVideoConvertor,
+    FFmpegExtractAudioPP,
+    FFmpegEmbedSubtitlePP,
+)
+
 
 def parseOpts(overrideArguments=None):
     def _readOptions(filename_bytes):
@@ -151,6 +179,9 @@ def parseOpts(overrideArguments=None):
             action='store_true', dest='update_self', help='update this program to latest version. Make sure that you have sufficient permissions (run with sudo if needed)')
     general.add_option('-i', '--ignore-errors',
             action='store_true', dest='ignoreerrors', help='continue on download errors, for example to to skip unavailable videos in a playlist', default=False)
+    general.add_option('--abort-on-error',
+            action='store_false', dest='ignoreerrors',
+            help='Abort downloading of further videos (in the playlist or the command line) if an error occurs')
     general.add_option('--dump-user-agent',
             action='store_true', dest='dump_user_agent',
             help='display the current browser identification', default=False)
@@ -168,7 +199,7 @@ def parseOpts(overrideArguments=None):
     general.add_option('--proxy', dest='proxy', default=None, help='Use the specified HTTP/HTTPS proxy', metavar='URL')
     general.add_option('--no-check-certificate', action='store_true', dest='no_check_certificate', default=False, help='Suppress HTTPS certificate validation.')
     general.add_option(
-        '--cache-dir', dest='cachedir', default=get_cachedir(),
+        '--cache-dir', dest='cachedir', default=get_cachedir(), metavar='DIR',
         help='Location in the filesystem where youtube-dl can store downloaded information permanently. By default $XDG_CACHE_HOME/youtube-dl or ~/.cache/youtube-dl .')
     general.add_option(
         '--no-cache-dir', action='store_const', const=None, dest='cachedir',
@@ -188,6 +219,12 @@ def parseOpts(overrideArguments=None):
     selection.add_option('--datebefore', metavar='DATE', dest='datebefore', help='download only videos uploaded before this date', default=None)
     selection.add_option('--dateafter', metavar='DATE', dest='dateafter', help='download only videos uploaded after this date', default=None)
     selection.add_option('--no-playlist', action='store_true', dest='noplaylist', help='download only the currently playing video', default=False)
+    selection.add_option('--age-limit', metavar='YEARS', dest='age_limit',
+                         help='download only videos suitable for the given age',
+                         default=None, type=int)
+    selection.add_option('--download-archive', metavar='FILE',
+                         dest='download_archive',
+                         help='Download only videos not present in the archive file. Record all downloaded videos in it.')
 
 
     authentication.add_option('-u', '--username',
@@ -201,7 +238,7 @@ def parseOpts(overrideArguments=None):
 
 
     video_format.add_option('-f', '--format',
-            action='store', dest='format', metavar='FORMAT',
+            action='store', dest='format', metavar='FORMAT', default='best',
             help='video format code, specifiy the order of preference using slashes: "-f 22/17/18". "-f mp4" and "-f flv" are also supported')
     video_format.add_option('--all-formats',
             action='store_const', dest='format', help='download all available video formats', const='all')
@@ -233,11 +270,11 @@ def parseOpts(overrideArguments=None):
             help='languages of the subtitles to download (optional) separated by commas, use IETF language tags like \'en,pt\'')
 
     downloader.add_option('-r', '--rate-limit',
-            dest='ratelimit', metavar='LIMIT', help='maximum download rate (e.g. 50k or 44.6m)')
+            dest='ratelimit', metavar='LIMIT', help='maximum download rate in bytes per second (e.g. 50K or 4.2M)')
     downloader.add_option('-R', '--retries',
             dest='retries', metavar='RETRIES', help='number of retries (default is %default)', default=10)
     downloader.add_option('--buffer-size',
-            dest='buffersize', metavar='SIZE', help='size of download buffer (e.g. 1024 or 16k) (default is %default)', default="1024")
+            dest='buffersize', metavar='SIZE', help='size of download buffer (e.g. 1024 or 16K) (default is %default)', default="1024")
     downloader.add_option('--no-resize-buffer',
             action='store_true', dest='noresizebuffer',
             help='do not automatically adjust the buffer size. By default, the buffer size is automatically resized from an initial value of SIZE.', default=False)
@@ -298,7 +335,9 @@ def parseOpts(overrideArguments=None):
             help=('output filename template. Use %(title)s to get the title, '
                   '%(uploader)s for the uploader name, %(uploader_id)s for the uploader nickname if different, '
                   '%(autonumber)s to get an automatically incremented number, '
-                  '%(ext)s for the filename extension, %(upload_date)s for the upload date (YYYYMMDD), '
+                  '%(ext)s for the filename extension, '
+                  '%(format)s for the format description (like "22 - 1280x720" or "HD")'
+                  '%(upload_date)s for the upload date (YYYYMMDD), '
                   '%(extractor)s for the provider (youtube, metacafe, etc), '
                   '%(id)s for the video id , %(playlist)s for the playlist the video is in, '
                   '%(playlist_index)s for the position in the playlist and %% for a literal percent. '
@@ -332,6 +371,9 @@ def parseOpts(overrideArguments=None):
     filesystem.add_option('--write-info-json',
             action='store_true', dest='writeinfojson',
             help='write video metadata to a .info.json file', default=False)
+    filesystem.add_option('--write-annotations',
+            action='store_true', dest='writeannotations',
+            help='write video annotations to a .annotation file', default=False)
     filesystem.add_option('--write-thumbnail',
             action='store_true', dest='writethumbnail',
             help='write thumbnail image to disk', default=False)
@@ -351,6 +393,8 @@ def parseOpts(overrideArguments=None):
             help='do not overwrite post-processed files; the post-processed files are overwritten by default')
     postproc.add_option('--embed-subs', action='store_true', dest='embedsubtitles', default=False,
             help='embed subtitles in the video (only for mp4 videos)')
+    postproc.add_option('--add-metadata', action='store_true', dest='addmetadata', default=False,
+            help='add metadata to the files')
 
 
     parser.add_option_group(general)
@@ -441,27 +485,7 @@ def _real_main(argv=None):
     all_urls = batchurls + args
     all_urls = [url.strip() for url in all_urls]
 
-    # General configuration
-    cookie_processor = compat_urllib_request.HTTPCookieProcessor(jar)
-    if opts.proxy is not None:
-        if opts.proxy == '':
-            proxies = {}
-        else:
-            proxies = {'http': opts.proxy, 'https': opts.proxy}
-    else:
-        proxies = compat_urllib_request.getproxies()
-        # Set HTTPS proxy to HTTP one if given (https://github.com/rg3/youtube-dl/issues/805)
-        if 'http' in proxies and 'https' not in proxies:
-            proxies['https'] = proxies['http']
-    proxy_handler = compat_urllib_request.ProxyHandler(proxies)
-    https_handler = make_HTTPS_handler(opts)
-    opener = compat_urllib_request.build_opener(https_handler, proxy_handler, cookie_processor, YoutubeDLHandler())
-    # Delete the default user-agent header, which would otherwise apply in
-    # cases where our custom HTTP handler doesn't come into play
-    # (See https://github.com/rg3/youtube-dl/issues/1309 for details)
-    opener.addheaders =[]
-    compat_urllib_request.install_opener(opener)
-    socket.setdefaulttimeout(300) # 5 minutes should be enough (famous last words)
+    opener = _setup_opener(jar=jar, opts=opts)
 
     extractors = gen_extractors()
 
@@ -478,6 +502,8 @@ def _real_main(argv=None):
             if not ie._WORKING:
                 continue
             desc = getattr(ie, 'IE_DESC', ie.IE_NAME)
+            if desc is False:
+                continue
             if hasattr(ie, 'SEARCH_KEY'):
                 _SEARCHES = (u'cute kittens', u'slithering pythons', u'falling cat', u'angry poodle', u'purple fish', u'running tortoise')
                 _COUNTS = (u'', u'5', u'10', u'all')
@@ -610,6 +636,7 @@ def _real_main(argv=None):
         'nopart': opts.nopart,
         'updatetime': opts.updatetime,
         'writedescription': opts.writedescription,
+        'writeannotations': opts.writeannotations,
         'writeinfojson': opts.writeinfojson,
         'writethumbnail': opts.writethumbnail,
         'writesubtitles': opts.writesubtitles,
@@ -631,6 +658,8 @@ def _real_main(argv=None):
         'daterange': date,
         'cachedir': opts.cachedir,
         'youtube_print_sig_code': opts.youtube_print_sig_code,
+        'age_limit': opts.age_limit,
+        'download_archive': opts.download_archive,
         })
 
     if opts.verbose:
@@ -650,11 +679,19 @@ def _real_main(argv=None):
             except:
                 pass
         write_string(u'[debug] Python version %s - %s' %(platform.python_version(), platform_name()) + u'\n')
-        write_string(u'[debug] Proxy map: ' + str(proxy_handler.proxies) + u'\n')
+
+        proxy_map = {}
+        for handler in opener.handlers:
+            if hasattr(handler, 'proxies'):
+                proxy_map.update(handler.proxies)
+        write_string(u'[debug] Proxy map: ' + compat_str(proxy_map) + u'\n')
 
     ydl.add_default_info_extractors()
 
     # PostProcessors
+    # Add the metadata pp first, the other pps will copy it
+    if opts.addmetadata:
+        ydl.add_post_processor(FFmpegMetadataPP())
     if opts.extractaudio:
         ydl.add_post_processor(FFmpegExtractAudioPP(preferredcodec=opts.audioformat, preferredquality=opts.audioquality, nopostoverwrites=opts.nopostoverwrites))
     if opts.recodevideo:
@@ -683,11 +720,42 @@ def _real_main(argv=None):
     if opts.cookiefile is not None:
         try:
             jar.save()
-        except (IOError, OSError) as err:
+        except (IOError, OSError):
             sys.exit(u'ERROR: unable to save cookie jar')
 
     sys.exit(retcode)
 
+
+def _setup_opener(jar=None, opts=None, timeout=300):
+    if opts is None:
+        FakeOptions = collections.namedtuple(
+            'FakeOptions', ['proxy', 'no_check_certificate'])
+        opts = FakeOptions(proxy=None, no_check_certificate=False)
+
+    cookie_processor = compat_urllib_request.HTTPCookieProcessor(jar)
+    if opts.proxy is not None:
+        if opts.proxy == '':
+            proxies = {}
+        else:
+            proxies = {'http': opts.proxy, 'https': opts.proxy}
+    else:
+        proxies = compat_urllib_request.getproxies()
+        # Set HTTPS proxy to HTTP one if given (https://github.com/rg3/youtube-dl/issues/805)
+        if 'http' in proxies and 'https' not in proxies:
+            proxies['https'] = proxies['http']
+    proxy_handler = compat_urllib_request.ProxyHandler(proxies)
+    https_handler = make_HTTPS_handler(opts)
+    opener = compat_urllib_request.build_opener(
+        https_handler, proxy_handler, cookie_processor, YoutubeDLHandler())
+    # Delete the default user-agent header, which would otherwise apply in
+    # cases where our custom HTTP handler doesn't come into play
+    # (See https://github.com/rg3/youtube-dl/issues/1309 for details)
+    opener.addheaders = []
+    compat_urllib_request.install_opener(opener)
+    socket.setdefaulttimeout(timeout)
+    return opener
+
+
 def main(argv=None):
     try:
         _real_main(argv)
index d1b7e5f991fa63664233670100a7ef54861c58c9..db69af361929fd7ff726d1a1df980730cad3630c 100644 (file)
@@ -2,7 +2,12 @@ from .appletrailers import AppleTrailersIE
 from .addanime import AddAnimeIE
 from .archiveorg import ArchiveOrgIE
 from .ard import ARDIE
-from .arte import ArteTvIE
+from .arte import (
+    ArteTvIE,
+    ArteTVPlus7IE,
+    ArteTVCreativeIE,
+    ArteTVFutureIE,
+)
 from .auengine import AUEngineIE
 from .bandcamp import BandcampIE
 from .bliptv import BlipTVIE, BlipTVUserIE
@@ -12,6 +17,7 @@ from .brightcove import BrightcoveIE
 from .c56 import C56IE
 from .canalplus import CanalplusIE
 from .canalc2 import Canalc2IE
+from .cinemassacre import CinemassacreIE
 from .cnn import CNNIE
 from .collegehumor import CollegeHumorIE
 from .comedycentral import ComedyCentralIE
@@ -34,6 +40,7 @@ from .eighttracks import EightTracksIE
 from .escapist import EscapistIE
 from .exfm import ExfmIE
 from .facebook import FacebookIE
+from .faz import FazIE
 from .fktv import (
     FKTVIE,
     FKTVPosteckeIE,
@@ -60,6 +67,7 @@ from .ign import IGNIE, OneUPIE
 from .ina import InaIE
 from .infoq import InfoQIE
 from .instagram import InstagramIE
+from .internetvideoarchive import InternetVideoArchiveIE
 from .jeuxvideo import JeuxVideoIE
 from .jukebox import JukeboxIE
 from .justintv import JustinTVIE
@@ -80,6 +88,8 @@ from .naver import NaverIE
 from .nba import NBAIE
 from .nbc import NBCNewsIE
 from .newgrounds import NewgroundsIE
+from .nhl import NHLIE, NHLVideocenterIE
+from .nowvideo import NowVideoIE
 from .ooyala import OoyalaIE
 from .orf import ORFIE
 from .pbs import PBSIE
@@ -89,8 +99,10 @@ from .rbmaradio import RBMARadioIE
 from .redtube import RedTubeIE
 from .ringtv import RingTVIE
 from .ro220 import Ro220IE
+from .rottentomatoes import RottenTomatoesIE
 from .roxwel import RoxwelIE
 from .rtlnow import RTLnowIE
+from .rutube import RutubeIE
 from .sina import SinaIE
 from .slashdot import SlashdotIE
 from .slideshare import SlideshareIE
@@ -101,7 +113,9 @@ from .spiegel import SpiegelIE
 from .stanfordoc import StanfordOpenClassroomIE
 from .statigram import StatigramIE
 from .steam import SteamIE
+from .sztvhu import SztvHuIE
 from .teamcoco import TeamcocoIE
+from .techtalks import TechTalksIE
 from .ted import TEDIE
 from .tf1 import TF1IE
 from .thisav import ThisAVIE
@@ -117,10 +131,14 @@ from .veehd import VeeHDIE
 from .veoh import VeohIE
 from .vevo import VevoIE
 from .vice import ViceIE
+from .viddler import ViddlerIE
+from .videodetective import VideoDetectiveIE
 from .videofyme import VideofyMeIE
+from .videopremium import VideoPremiumIE
 from .vimeo import VimeoIE, VimeoChannelIE
 from .vine import VineIE
 from .wat import WatIE
+from .websurg import WeBSurgIE
 from .weibo import WeiboIE
 from .wimp import WimpIE
 from .worldstarhiphop import WorldStarHipHopIE
@@ -140,6 +158,7 @@ from .youtube import (
     YoutubeShowIE,
     YoutubeSubscriptionsIE,
     YoutubeRecommendedIE,
+    YoutubeTruncatedURLIE,
     YoutubeWatchLaterIE,
     YoutubeFavouritesIE,
 )
index 69b3b0ad7820600ef5107ad3d79230c0e4edcaac..d39b489518f7bc699854d9ddeb7cd4fa357a6c2b 100644 (file)
@@ -1,3 +1,4 @@
+# encoding: utf-8
 import re
 import json
 import xml.etree.ElementTree
@@ -7,15 +8,15 @@ from ..utils import (
     ExtractorError,
     find_xpath_attr,
     unified_strdate,
+    determine_ext,
+    get_element_by_id,
 )
 
+# There are different sources of video in arte.tv, the extraction process 
+# is different for each one. The videos usually expire in 7 days, so we can't
+# add tests.
+
 class ArteTvIE(InfoExtractor):
-    """
-    There are two sources of video in arte.tv: videos.arte.tv and
-    www.arte.tv/guide, the extraction process is different for each one.
-    The videos expire in 7 days, so we can't add tests.
-    """
-    _EMISSION_URL = r'(?:http://)?www\.arte.tv/guide/(?P<lang>fr|de)/(?:(?:sendungen|emissions)/)?(?P<id>.*?)/(?P<name>.*?)(\?.*)?'
     _VIDEOS_URL = r'(?:http://)?videos.arte.tv/(?P<lang>fr|de)/.*-(?P<id>.*?).html'
     _LIVEWEB_URL = r'(?:http://)?liveweb.arte.tv/(?P<lang>fr|de)/(?P<subpage>.+?)/(?P<name>.+)'
     _LIVE_URL = r'index-[0-9]+\.html$'
@@ -24,7 +25,7 @@ class ArteTvIE(InfoExtractor):
 
     @classmethod
     def suitable(cls, url):
-        return any(re.match(regex, url) for regex in (cls._EMISSION_URL, cls._VIDEOS_URL, cls._LIVEWEB_URL))
+        return any(re.match(regex, url) for regex in (cls._VIDEOS_URL, cls._LIVEWEB_URL))
 
     # TODO implement Live Stream
     # from ..utils import compat_urllib_parse
@@ -55,14 +56,6 @@ class ArteTvIE(InfoExtractor):
     #     video_url = u'%s/%s' % (info.get('url'), info.get('path'))
 
     def _real_extract(self, url):
-        mobj = re.match(self._EMISSION_URL, url)
-        if mobj is not None:
-            lang = mobj.group('lang')
-            # This is not a real id, it can be for example AJT for the news
-            # http://www.arte.tv/guide/fr/emissions/AJT/arte-journal
-            video_id = mobj.group('id')
-            return self._extract_emission(url, video_id, lang)
-
         mobj = re.match(self._VIDEOS_URL, url)
         if mobj is not None:
             id = mobj.group('id')
@@ -80,49 +73,6 @@ class ArteTvIE(InfoExtractor):
             # self.extractLiveStream(url)
             # return
 
-    def _extract_emission(self, url, video_id, lang):
-        """Extract from www.arte.tv/guide"""
-        webpage = self._download_webpage(url, video_id)
-        json_url = self._html_search_regex(r'arte_vp_url="(.*?)"', webpage, 'json url')
-
-        json_info = self._download_webpage(json_url, video_id, 'Downloading info json')
-        self.report_extraction(video_id)
-        info = json.loads(json_info)
-        player_info = info['videoJsonPlayer']
-
-        info_dict = {'id': player_info['VID'],
-                     'title': player_info['VTI'],
-                     'description': player_info.get('VDE'),
-                     'upload_date': unified_strdate(player_info['VDA'].split(' ')[0]),
-                     'thumbnail': player_info['programImage'],
-                     'ext': 'flv',
-                     }
-
-        formats = player_info['VSR'].values()
-        def _match_lang(f):
-            # Return true if that format is in the language of the url
-            if lang == 'fr':
-                l = 'F'
-            elif lang == 'de':
-                l = 'A'
-            regexes = [r'VO?%s' % l, r'VO?.-ST%s' % l]
-            return any(re.match(r, f['versionCode']) for r in regexes)
-        # Some formats may not be in the same language as the url
-        formats = filter(_match_lang, formats)
-        # We order the formats by quality
-        formats = sorted(formats, key=lambda f: int(f['height']))
-        # Prefer videos without subtitles in the same language
-        formats = sorted(formats, key=lambda f: re.match(r'VO(F|A)-STM\1', f['versionCode']) is None)
-        # Pick the best quality
-        format_info = formats[-1]
-        if format_info['mediaType'] == u'rtmp':
-            info_dict['url'] = format_info['streamer']
-            info_dict['play_path'] = 'mp4:' + format_info['url']
-        else:
-            info_dict['url'] = format_info['url']
-
-        return info_dict
-
     def _extract_video(self, url, video_id, lang):
         """Extract from videos.arte.tv"""
         ref_xml_url = url.replace('/videos/', '/do_delegate/videos/')
@@ -172,3 +122,123 @@ class ArteTvIE(InfoExtractor):
                 'ext': 'flv',
                 'thumbnail': self._og_search_thumbnail(webpage),
                 }
+
+
+class ArteTVPlus7IE(InfoExtractor):
+    IE_NAME = u'arte.tv:+7'
+    _VALID_URL = r'https?://www\.arte.tv/guide/(?P<lang>fr|de)/(?:(?:sendungen|emissions)/)?(?P<id>.*?)/(?P<name>.*?)(\?.*)?'
+
+    @classmethod
+    def _extract_url_info(cls, url):
+        mobj = re.match(cls._VALID_URL, url)
+        lang = mobj.group('lang')
+        # This is not a real id, it can be for example AJT for the news
+        # http://www.arte.tv/guide/fr/emissions/AJT/arte-journal
+        video_id = mobj.group('id')
+        return video_id, lang
+
+    def _real_extract(self, url):
+        video_id, lang = self._extract_url_info(url)
+        webpage = self._download_webpage(url, video_id)
+        return self._extract_from_webpage(webpage, video_id, lang)
+
+    def _extract_from_webpage(self, webpage, video_id, lang):
+        json_url = self._html_search_regex(r'arte_vp_url="(.*?)"', webpage, 'json url')
+
+        json_info = self._download_webpage(json_url, video_id, 'Downloading info json')
+        self.report_extraction(video_id)
+        info = json.loads(json_info)
+        player_info = info['videoJsonPlayer']
+
+        info_dict = {
+            'id': player_info['VID'],
+            'title': player_info['VTI'],
+            'description': player_info.get('VDE'),
+            'upload_date': unified_strdate(player_info.get('VDA', '').split(' ')[0]),
+            'thumbnail': player_info.get('programImage') or player_info.get('VTU', {}).get('IUR'),
+        }
+
+        formats = player_info['VSR'].values()
+        def _match_lang(f):
+            if f.get('versionCode') is None:
+                return True
+            # Return true if that format is in the language of the url
+            if lang == 'fr':
+                l = 'F'
+            elif lang == 'de':
+                l = 'A'
+            regexes = [r'VO?%s' % l, r'VO?.-ST%s' % l]
+            return any(re.match(r, f['versionCode']) for r in regexes)
+        # Some formats may not be in the same language as the url
+        formats = filter(_match_lang, formats)
+        # Some formats use the m3u8 protocol
+        formats = filter(lambda f: f.get('videoFormat') != 'M3U8', formats)
+        # We order the formats by quality
+        formats = list(formats) # in python3 filter returns an iterator
+        if re.match(r'[A-Z]Q', formats[0]['quality']) is not None:
+            sort_key = lambda f: ['HQ', 'MQ', 'EQ', 'SQ'].index(f['quality'])
+        else:
+            sort_key = lambda f: int(f.get('height',-1))
+        formats = sorted(formats, key=sort_key)
+        # Prefer videos without subtitles in the same language
+        formats = sorted(formats, key=lambda f: re.match(r'VO(F|A)-STM\1', f.get('versionCode', '')) is None)
+        # Pick the best quality
+        def _format(format_info):
+            quality = format_info['quality']
+            m_quality = re.match(r'\w*? - (\d*)p', quality)
+            if m_quality is not None:
+                quality = m_quality.group(1)
+            if format_info.get('versionCode') is not None:
+                format_id = u'%s-%s' % (quality, format_info['versionCode'])
+            else:
+                format_id = quality
+            info = {
+                'format_id': format_id,
+                'format_note': format_info.get('versionLibelle'),
+                'width': format_info.get('width'),
+                'height': format_info.get('height'),
+            }
+            if format_info['mediaType'] == u'rtmp':
+                info['url'] = format_info['streamer']
+                info['play_path'] = 'mp4:' + format_info['url']
+                info['ext'] = 'flv'
+            else:
+                info['url'] = format_info['url']
+                info['ext'] = determine_ext(info['url'])
+            return info
+        info_dict['formats'] = [_format(f) for f in formats]
+
+        return info_dict
+
+
+# It also uses the arte_vp_url url from the webpage to extract the information
+class ArteTVCreativeIE(ArteTVPlus7IE):
+    IE_NAME = u'arte.tv:creative'
+    _VALID_URL = r'https?://creative\.arte\.tv/(?P<lang>fr|de)/magazine?/(?P<id>.+)'
+
+    _TEST = {
+        u'url': u'http://creative.arte.tv/de/magazin/agentur-amateur-corporate-design',
+        u'file': u'050489-002.mp4',
+        u'info_dict': {
+            u'title': u'Agentur Amateur / Agence Amateur #2 : Corporate Design',
+        },
+    }
+
+
+class ArteTVFutureIE(ArteTVPlus7IE):
+    IE_NAME = u'arte.tv:future'
+    _VALID_URL = r'https?://future\.arte\.tv/(?P<lang>fr|de)/(thema|sujet)/.*?#article-anchor-(?P<id>\d+)'
+
+    _TEST = {
+        u'url': u'http://future.arte.tv/fr/sujet/info-sciences#article-anchor-7081',
+        u'file': u'050940-003.mp4',
+        u'info_dict': {
+            u'title': u'Les champignons au secours de la planète',
+        },
+    }
+
+    def _real_extract(self, url):
+        anchor_id, lang = self._extract_url_info(url)
+        webpage = self._download_webpage(url, anchor_id)
+        row = get_element_by_id(anchor_id, webpage)
+        return self._extract_from_webpage(row, anchor_id, lang)
index 08b28c994272e3461bba5d99856928ff6adb6cf3..493504f75082f7b7605121acbfd88dbb621e84fb 100644 (file)
@@ -115,7 +115,7 @@ class BlipTVIE(InfoExtractor):
                 ext = umobj.group(1)
 
                 info = {
-                    'id': data['item_id'],
+                    'id': compat_str(data['item_id']),
                     'url': video_url,
                     'uploader': data['display_name'],
                     'upload_date': upload_date,
index 558b3d0093975eff273d38a7a2bad9f1d4e36355..1392f382a24c273604f0c67db7afafefbcec85b8 100644 (file)
@@ -49,6 +49,13 @@ class BrightcoveIE(InfoExtractor):
         Build a Brightcove url from a xml string containing
         <object class="BrightcoveExperience">{params}</object>
         """
+
+        # Fix up some stupid HTML, see https://github.com/rg3/youtube-dl/issues/1553
+        object_str = re.sub(r'(<param name="[^"]+" value="[^"]+")>',
+                            lambda m: m.group(1) + '/>', object_str)
+        # Fix up some stupid XML, see https://github.com/rg3/youtube-dl/issues/1608
+        object_str = object_str.replace(u'<--', u'<!--')
+
         object_doc = xml.etree.ElementTree.fromstring(object_str)
         assert u'BrightcoveExperience' in object_doc.attrib['class']
         params = {'flashID': object_doc.attrib['id'],
@@ -91,7 +98,10 @@ class BrightcoveIE(InfoExtractor):
         playlist_info = self._download_webpage(self._PLAYLIST_URL_TEMPLATE % player_key,
                                                player_key, u'Downloading playlist information')
 
-        playlist_info = json.loads(playlist_info)['videoList']
+        json_data = json.loads(playlist_info)
+        if 'videoList' not in json_data:
+            raise ExtractorError(u'Empty playlist')
+        playlist_info = json_data['videoList']
         videos = [self._extract_video_info(video_info) for video_info in playlist_info['mediaCollectionDTO']['videoDTOs']]
 
         return self.playlist_result(videos, playlist_id=playlist_info['id'],
diff --git a/youtube_dl/extractor/cinemassacre.py b/youtube_dl/extractor/cinemassacre.py
new file mode 100644 (file)
index 0000000..6925b96
--- /dev/null
@@ -0,0 +1,91 @@
+# encoding: utf-8
+import re
+
+from .common import InfoExtractor
+from ..utils import (
+    ExtractorError,
+)
+
+
+class CinemassacreIE(InfoExtractor):
+    _VALID_URL = r'(?:http://)?(?:www\.)?(?P<url>cinemassacre\.com/(?P<date_Y>[0-9]{4})/(?P<date_m>[0-9]{2})/(?P<date_d>[0-9]{2})/.+?)(?:[/?].*)?'
+    _TESTS = [{
+        u'url': u'http://cinemassacre.com/2012/11/10/avgn-the-movie-trailer/',
+        u'file': u'19911.flv',
+        u'info_dict': {
+            u'upload_date': u'20121110',
+            u'title': u'“Angry Video Game Nerd: The Movie” – Trailer',
+            u'description': u'md5:fb87405fcb42a331742a0dce2708560b',
+        },
+        u'params': {
+            # rtmp download
+            u'skip_download': True,
+        },
+    },
+    {
+        u'url': u'http://cinemassacre.com/2013/10/02/the-mummys-hand-1940',
+        u'file': u'521be8ef82b16.flv',
+        u'info_dict': {
+            u'upload_date': u'20131002',
+            u'title': u'The Mummy’s Hand (1940)',
+        },
+        u'params': {
+            # rtmp download
+            u'skip_download': True,
+        },
+    }]
+
+    def _real_extract(self, url):
+        mobj = re.match(self._VALID_URL, url)
+
+        webpage_url = u'http://' + mobj.group('url')
+        webpage = self._download_webpage(webpage_url, None) # Don't know video id yet
+        video_date = mobj.group('date_Y') + mobj.group('date_m') + mobj.group('date_d')
+        mobj = re.search(r'src="(?P<embed_url>http://player\.screenwavemedia\.com/play/(?:embed|player)\.php\?id=(?:Cinemassacre-)?(?P<video_id>.+?))"', webpage)
+        if not mobj:
+            raise ExtractorError(u'Can\'t extract embed url and video id')
+        playerdata_url = mobj.group(u'embed_url')
+        video_id = mobj.group(u'video_id')
+
+        video_title = self._html_search_regex(r'<title>(?P<title>.+?)\|',
+            webpage, u'title')
+        video_description = self._html_search_regex(r'<div class="entry-content">(?P<description>.+?)</div>',
+            webpage, u'description', flags=re.DOTALL, fatal=False)
+        if len(video_description) == 0:
+            video_description = None
+
+        playerdata = self._download_webpage(playerdata_url, video_id)
+        base_url = self._html_search_regex(r'\'streamer\': \'(?P<base_url>rtmp://.*?)/(?:vod|Cinemassacre)\'',
+            playerdata, u'base_url')
+        base_url += '/Cinemassacre/'
+        # Important: The file names in playerdata are not used by the player and even wrong for some videos
+        sd_file = 'Cinemassacre-%s_high.mp4' % video_id
+        hd_file = 'Cinemassacre-%s.mp4' % video_id
+        video_thumbnail = 'http://image.screenwavemedia.com/Cinemassacre/Cinemassacre-%s_thumb_640x360.jpg' % video_id
+
+        formats = [
+            {
+                'url': base_url + sd_file,
+                'ext': 'flv',
+                'format': 'sd',
+                'format_id': 'sd',
+            },
+            {
+                'url': base_url + hd_file,
+                'ext': 'flv',
+                'format': 'hd',
+                'format_id': 'hd',
+            },
+        ]
+
+        info = {
+            'id': video_id,
+            'title': video_title,
+            'formats': formats,
+            'description': video_description,
+            'upload_date': video_date,
+            'thumbnail': video_thumbnail,
+        }
+        # TODO: Remove when #980 has been merged
+        info.update(formats[-1])
+        return info
index bf8d711eea44c8d60855f458407391d66ef2664d..69b2beecebac319ef92e8043ab75ad71fad46a25 100644 (file)
@@ -51,12 +51,12 @@ class ComedyCentralIE(InfoExtractor):
         '400': 'mp4',
     }
     _video_dimensions = {
-        '3500': '1280x720',
-        '2200': '960x540',
-        '1700': '768x432',
-        '1200': '640x360',
-        '750': '512x288',
-        '400': '384x216',
+        '3500': (1280, 720),
+        '2200': (960, 540),
+        '1700': (768, 432),
+        '1200': (640, 360),
+        '750': (512, 288),
+        '400': (384, 216),
     }
 
     @classmethod
@@ -64,11 +64,13 @@ class ComedyCentralIE(InfoExtractor):
         """Receives a URL and returns True if suitable for this IE."""
         return re.match(cls._VALID_URL, url, re.VERBOSE) is not None
 
-    def _print_formats(self, formats):
-        print('Available formats:')
-        for x in formats:
-            print('%s\t:\t%s\t[%s]' %(x, self._video_extensions.get(x, 'mp4'), self._video_dimensions.get(x, '???')))
-
+    @staticmethod
+    def _transform_rtmp_url(rtmp_video_url):
+        m = re.match(r'^rtmpe?://.*?/(?P<finalid>gsp.comedystor/.*)$', rtmp_video_url)
+        if not m:
+            raise ExtractorError(u'Cannot transform RTMP url')
+        base = 'http://mtvnmobile.vo.llnwd.net/kip0/_pxn=1+_pxI0=Ripod-h264+_pxL0=undefined+_pxM0=+_pxK=18639+_pxE=mp4/44620/mtvnorigin/'
+        return base + m.group('finalid')
 
     def _real_extract(self, url):
         mobj = re.match(self._VALID_URL, url, re.VERBOSE)
@@ -155,40 +157,31 @@ class ComedyCentralIE(InfoExtractor):
                 self._downloader.report_error(u'unable to download ' + mediaId + ': No videos found')
                 continue
 
-            if self._downloader.params.get('listformats', None):
-                self._print_formats([i[0] for i in turls])
-                return
-
-            # For now, just pick the highest bitrate
-            format,rtmp_video_url = turls[-1]
-
-            # Get the format arg from the arg stream
-            req_format = self._downloader.params.get('format', None)
-
-            # Select format if we can find one
-            for f,v in turls:
-                if f == req_format:
-                    format, rtmp_video_url = f, v
-                    break
-
-            m = re.match(r'^rtmpe?://.*?/(?P<finalid>gsp.comedystor/.*)$', rtmp_video_url)
-            if not m:
-                raise ExtractorError(u'Cannot transform RTMP url')
-            base = 'http://mtvnmobile.vo.llnwd.net/kip0/_pxn=1+_pxI0=Ripod-h264+_pxL0=undefined+_pxM0=+_pxK=18639+_pxE=mp4/44620/mtvnorigin/'
-            video_url = base + m.group('finalid')
+            formats = []
+            for format, rtmp_video_url in turls:
+                w, h = self._video_dimensions.get(format, (None, None))
+                formats.append({
+                    'url': self._transform_rtmp_url(rtmp_video_url),
+                    'ext': self._video_extensions.get(format, 'mp4'),
+                    'format_id': format,
+                    'height': h,
+                    'width': w,
+                })
 
             effTitle = showId + u'-' + epTitle + u' part ' + compat_str(partNum+1)
             info = {
                 'id': shortMediaId,
-                'url': video_url,
+                'formats': formats,
                 'uploader': showId,
                 'upload_date': officialDate,
                 'title': effTitle,
-                'ext': 'mp4',
-                'format': format,
                 'thumbnail': None,
                 'description': compat_str(officialTitle),
             }
+
+            # TODO: Remove when #980 has been merged
+            info.update(info['formats'][-1])
+
             results.append(info)
 
         return results
index 77726ee2432fc2bcd6df6ce89dcc560419524051..7d7ce5d98a7ef21ccb1fe6897ebad9dd996cc649 100644 (file)
@@ -35,6 +35,8 @@ class InfoExtractor(object):
     title:          Video title, unescaped.
     ext:            Video filename extension.
 
+    Instead of url and ext, formats can also specified.
+
     The following fields are optional:
 
     format:         The video format, defaults to ext (used for --get-format)
@@ -52,8 +54,23 @@ class InfoExtractor(object):
     view_count:     How many users have watched the video on the platform.
     urlhandle:      [internal] The urlHandle to be used to download the file,
                     like returned by urllib.request.urlopen
-
-    The fields should all be Unicode strings.
+    age_limit:      Age restriction for the video, as an integer (years)
+    formats:        A list of dictionaries for each format available, it must
+                    be ordered from worst to best quality. Potential fields:
+                    * url       Mandatory. The URL of the video file
+                    * ext       Will be calculated from url if missing
+                    * format    A human-readable description of the format
+                                ("mp4 container with h264/opus").
+                                Calculated from the format_id, width, height 
+                                and format_note fields if missing.
+                    * format_id A short description of the format
+                                ("mp4_h264_opus" or "19")
+                    * format_note Additional info about the format
+                                ("3D" or "DASH video")
+                    * width     Width of the video, if known
+                    * height    Height of the video, if known
+
+    Unless mentioned otherwise, the fields should be Unicode strings.
 
     Subclasses of this one should re-define the _real_initialize() and
     _real_extract() methods and define a _VALID_URL regexp.
@@ -305,6 +322,15 @@ class InfoExtractor(object):
                                         self._og_regex('video')],
                                        html, name, **kargs)
 
+    def _rta_search(self, html):
+        # See http://www.rtalabel.org/index.php?content=howtofaq#single
+        if re.search(r'(?ix)<meta\s+name="rating"\s+'
+                     r'     content="RTA-5042-1996-1400-1577-RTA"',
+                     html):
+            return 18
+        return 0
+
+
 class SearchInfoExtractor(InfoExtractor):
     """
     Base class for paged search queries extractors.
@@ -342,7 +368,7 @@ class SearchInfoExtractor(InfoExtractor):
 
     def _get_n_results(self, query, n):
         """Get a specified number of results for a query"""
-        raise NotImplementedError("This method must be implemented by sublclasses")
+        raise NotImplementedError("This method must be implemented by subclasses")
 
     @property
     def SEARCH_KEY(self):
index 259806f385d621b909f465f0dc78271fb352c4fe..7d83539469d3d7ff120f916cc837a60bacfe8390 100644 (file)
@@ -10,6 +10,7 @@ from ..utils import (
     compat_str,
     get_element_by_attribute,
     get_element_by_id,
+    orderedSet,
 
     ExtractorError,
 )
@@ -158,12 +159,12 @@ class DailymotionPlaylistIE(DailymotionBaseInfoExtractor):
                                              id, u'Downloading page %s' % pagenum)
 
             playlist_el = get_element_by_attribute(u'class', u'video_list', webpage)
-            video_ids.extend(re.findall(r'data-id="(.+?)" data-ext-id', playlist_el))
+            video_ids.extend(re.findall(r'data-id="(.+?)"', playlist_el))
 
             if re.search(self._MORE_PAGES_INDICATOR, webpage, re.DOTALL) is None:
                 break
         return [self.url_result('http://www.dailymotion.com/video/%s' % video_id, 'Dailymotion')
-                   for video_id in video_ids]
+                   for video_id in orderedSet(video_ids)]
 
     def _real_extract(self, url):
         mobj = re.match(self._VALID_URL, url)
diff --git a/youtube_dl/extractor/faz.py b/youtube_dl/extractor/faz.py
new file mode 100644 (file)
index 0000000..deaa4ed
--- /dev/null
@@ -0,0 +1,60 @@
+# encoding: utf-8
+import re
+import xml.etree.ElementTree
+
+from .common import InfoExtractor
+from ..utils import (
+    determine_ext,
+    clean_html,
+    get_element_by_attribute,
+)
+
+
+class FazIE(InfoExtractor):
+    IE_NAME = u'faz.net'
+    _VALID_URL = r'https?://www\.faz\.net/multimedia/videos/.*?-(?P<id>\d+).html'
+
+    _TEST = {
+        u'url': u'http://www.faz.net/multimedia/videos/stockholm-chemie-nobelpreis-fuer-drei-amerikanische-forscher-12610585.html',
+        u'file': u'12610585.mp4',
+        u'info_dict': {
+            u'title': u'Stockholm: Chemie-Nobelpreis für drei amerikanische Forscher',
+            u'description': u'md5:1453fbf9a0d041d985a47306192ea253',
+        },
+    }
+
+    def _real_extract(self, url):
+        mobj = re.match(self._VALID_URL, url)
+        video_id = mobj.group('id')
+        self.to_screen(video_id)
+        webpage = self._download_webpage(url, video_id)
+        config_xml_url = self._search_regex(r'writeFLV\(\'(.+?)\',', webpage,
+            u'config xml url')
+        config_xml = self._download_webpage(config_xml_url, video_id,
+            u'Downloading config xml')
+        config = xml.etree.ElementTree.fromstring(config_xml.encode('utf-8'))
+
+        encodings = config.find('ENCODINGS')
+        formats = []
+        for code in ['LOW', 'HIGH', 'HQ']:
+            encoding = encodings.find(code)
+            if encoding is None:
+                continue
+            encoding_url = encoding.find('FILENAME').text
+            formats.append({
+                'url': encoding_url,
+                'ext': determine_ext(encoding_url),
+                'format_id': code.lower(),
+            })
+
+        descr_html = get_element_by_attribute('class', 'Content Copy', webpage)
+        info = {
+            'id': video_id,
+            'title': self._og_search_title(webpage),
+            'formats': formats,
+            'description': clean_html(descr_html),
+            'thumbnail': config.find('STILL/STILL_BIG').text,
+        }
+        # TODO: Remove when #980 has been merged
+        info.update(formats[-1])
+        return info
index 80d96baf739522b97f933878faa8a4083a0e8959..e1d2f0526a42169fbbba96789a413d3d20fec6a6 100644 (file)
@@ -9,7 +9,7 @@ from ..utils import (
 
 class FlickrIE(InfoExtractor):
     """Information Extractor for Flickr videos"""
-    _VALID_URL = r'(?:https?://)?(?:www\.)?flickr\.com/photos/(?P<uploader_id>[\w\-_@]+)/(?P<id>\d+).*'
+    _VALID_URL = r'(?:https?://)?(?:www\.|secure\.)?flickr\.com/photos/(?P<uploader_id>[\w\-_@]+)/(?P<id>\d+).*'
     _TEST = {
         u'url': u'http://www.flickr.com/photos/forestwander-nature-pictures/5645318632/in/photostream/',
         u'file': u'5645318632.mp4',
index 461dac8efba90ea09f4f1e585d93754c81bd0136..086cafca027e3b99967f50f3220d1632f1cc8033 100644 (file)
@@ -103,7 +103,7 @@ class France2IE(FranceTVBaseInfoExtractor):
 
 
 class GenerationQuoiIE(InfoExtractor):
-    IE_NAME = u'http://generation-quoi.france2.fr'
+    IE_NAME = u'france2.fr:generation-quoi'
     _VALID_URL = r'https?://generation-quoi\.france2\.fr/portrait/(?P<name>.*)(\?|$)'
 
     _TEST = {
index cd3bbe65f5dd9891f5cf4a68fb1adcd8a45c4196..098768361ede01d8acc01dc773a31b5b8fc67241 100644 (file)
@@ -1,55 +1,59 @@
 import re
-import xml.etree.ElementTree
+import json
 
 from .common import InfoExtractor
 from ..utils import (
-    unified_strdate,
     compat_urllib_parse,
+    compat_urlparse,
+    unescapeHTML,
+    get_meta_content,
 )
 
+
 class GameSpotIE(InfoExtractor):
     _VALID_URL = r'(?:http://)?(?:www\.)?gamespot\.com/.*-(?P<page_id>\d+)/?'
     _TEST = {
         u"url": u"http://www.gamespot.com/arma-iii/videos/arma-iii-community-guide-sitrep-i-6410818/",
-        u"file": u"6410818.mp4",
+        u"file": u"gs-2300-6410818.mp4",
         u"md5": u"b2a30deaa8654fcccd43713a6b6a4825",
         u"info_dict": {
             u"title": u"Arma 3 - Community Guide: SITREP I",
-            u"upload_date": u"20130627", 
+            u'description': u'Check out this video where some of the basics of Arma 3 is explained.',
         }
     }
 
-
     def _real_extract(self, url):
         mobj = re.match(self._VALID_URL, url)
-        page_id = mobj.group('page_id')
+        page_id = video_id = mobj.group('page_id')
         webpage = self._download_webpage(url, page_id)
-        video_id = self._html_search_regex([r'"og:video" content=".*?\?id=(\d+)"',
-                                            r'http://www\.gamespot\.com/videoembed/(\d+)'],
-                                           webpage, 'video id')
-        data = compat_urllib_parse.urlencode({'id': video_id, 'newplayer': '1'})
-        info_url = 'http://www.gamespot.com/pages/video_player/xml.php?' + data
-        info_xml = self._download_webpage(info_url, video_id)
-        doc = xml.etree.ElementTree.fromstring(info_xml)
-        clip_el = doc.find('./playList/clip')
+        data_video_json = self._search_regex(r'data-video=\'(.*?)\'', webpage, u'data video')
+        data_video = json.loads(unescapeHTML(data_video_json))
 
-        http_urls = [{'url': node.find('filePath').text,
-                      'rate': int(node.find('rate').text)}
-            for node in clip_el.find('./httpURI')]
-        best_quality = sorted(http_urls, key=lambda f: f['rate'])[-1]
-        video_url = best_quality['url']
-        title = clip_el.find('./title').text
-        ext = video_url.rpartition('.')[2]
-        thumbnail_url = clip_el.find('./screenGrabURI').text
-        view_count = int(clip_el.find('./views').text)
-        upload_date = unified_strdate(clip_el.find('./postDate').text)
+        # Transform the manifest url to a link to the mp4 files
+        # they are used in mobile devices.
+        f4m_url = data_video['videoStreams']['f4m_stream']
+        f4m_path = compat_urlparse.urlparse(f4m_url).path
+        QUALITIES_RE = r'((,\d+)+,?)'
+        qualities = self._search_regex(QUALITIES_RE, f4m_path, u'qualities').strip(',').split(',')
+        http_path = f4m_path[1:].split('/', 1)[1]
+        http_template = re.sub(QUALITIES_RE, r'%s', http_path)
+        http_template = http_template.replace('.csmil/manifest.f4m', '')
+        http_template = compat_urlparse.urljoin('http://video.gamespotcdn.com/', http_template)
+        formats = []
+        for q in qualities:
+            formats.append({
+                'url': http_template % q,
+                'ext': 'mp4',
+                'format_id': q,
+            })
 
-        return [{
-            'id'          : video_id,
-            'url'         : video_url,
-            'ext'         : ext,
-            'title'       : title,
-            'thumbnail'   : thumbnail_url,
-            'upload_date' : upload_date,
-            'view_count'  : view_count,
-        }]
+        info = {
+            'id': data_video['guid'],
+            'title': compat_urllib_parse.unquote(data_video['title']),
+            'formats': formats,
+            'description': get_meta_content('description', webpage),
+            'thumbnail': self._og_search_thumbnail(webpage),
+        }
+        # TODO: Remove when #980 has been merged
+        info.update(formats[-1])
+        return info
index 764070635160d96487baa53b4370b28e8a957316..69e0a7bd271dd0965f5c1f6f9c3a7cdce7a3da0b 100644 (file)
@@ -11,6 +11,8 @@ from ..utils import (
     compat_urlparse,
 
     ExtractorError,
+    smuggle_url,
+    unescapeHTML,
 )
 from .brightcove import BrightcoveIE
 
@@ -29,6 +31,17 @@ class GenericIE(InfoExtractor):
                 u"title": u"R\u00e9gis plante sa Jeep"
             }
         },
+        # embedded vimeo video
+        {
+            u'url': u'http://skillsmatter.com/podcast/home/move-semanticsperfect-forwarding-and-rvalue-references',
+            u'file': u'22444065.mp4',
+            u'md5': u'2903896e23df39722c33f015af0666e2',
+            u'info_dict': {
+                u'title': u'ACCU 2011: Move Semantics,Perfect Forwarding, and Rvalue references- Scott Meyers- 13/04/2011',
+                u"uploader_id": u"skillsmatter",
+                u"uploader": u"Skills Matter",
+            }
+        }
     ]
 
     def report_download_webpage(self, video_id):
@@ -117,16 +130,31 @@ class GenericIE(InfoExtractor):
         except ValueError:
             # since this is the last-resort InfoExtractor, if
             # this error is thrown, it'll be thrown here
-            raise ExtractorError(u'Invalid URL: %s' % url)
+            raise ExtractorError(u'Failed to download URL: %s' % url)
 
         self.report_extraction(video_id)
         # Look for BrightCove:
-        m_brightcove = re.search(r'<object.+?class=([\'"]).*?BrightcoveExperience.*?\1.+?</object>', webpage, re.DOTALL)
+        m_brightcove = re.search(r'<object[^>]+?class=([\'"])[^>]*?BrightcoveExperience.*?\1.+?</object>', webpage, re.DOTALL)
         if m_brightcove is not None:
             self.to_screen(u'Brightcove video detected.')
             bc_url = BrightcoveIE._build_brighcove_url(m_brightcove.group())
             return self.url_result(bc_url, 'Brightcove')
 
+        # Look for embedded Vimeo player
+        mobj = re.search(
+            r'<iframe[^>]+?src="(https?://player.vimeo.com/video/.+?)"', webpage)
+        if mobj:
+            player_url = unescapeHTML(mobj.group(1))
+            surl = smuggle_url(player_url, {'Referer': url})
+            return self.url_result(surl, 'Vimeo')
+
+        # Look for embedded YouTube player
+        mobj = re.search(
+            r'<iframe[^>]+?src="(https?://(?:www\.)?youtube.com/embed/.+?)"', webpage)
+        if mobj:
+            surl = unescapeHTML(mobj.group(1))
+            return self.url_result(surl, 'Youtube')
+
         # Start with something easy: JW Player in SWFObject
         mobj = re.search(r'flashvars: [\'"](?:.*&)?file=(http[^\'"&]*)', webpage)
         if mobj is None:
@@ -149,12 +177,12 @@ class GenericIE(InfoExtractor):
             # HTML5 video
             mobj = re.search(r'<video[^<]*(?:>.*?<source.*?)? src="([^"]+)"', webpage, flags=re.DOTALL)
         if mobj is None:
-            raise ExtractorError(u'Invalid URL: %s' % url)
+            raise ExtractorError(u'Unsupported URL: %s' % url)
 
         # It's possible that one of the regexes
         # matched, but returned an empty group:
         if mobj.group(1) is None:
-            raise ExtractorError(u'Invalid URL: %s' % url)
+            raise ExtractorError(u'Did not find a valid video URL at %s' % url)
 
         video_url = mobj.group(1)
         video_url = compat_urlparse.urljoin(url, video_url)
index 8895ad2897f8abd30471ba3f7ef07963c44e7b57..2570746b2047a1d1ae0a60b48970b1414f168e40 100644 (file)
@@ -41,8 +41,9 @@ class GooglePlusIE(InfoExtractor):
 
         # Extract update date
         upload_date = self._html_search_regex(
-            ['title="Timestamp">(.*?)</a>', r'<a.+?class="g-M.+?>(.+?)</a>'],
-            webpage, u'upload date', fatal=False)
+            r'''(?x)<a.+?class="o-U-s\s[^"]+"\s+style="display:\s*none"\s*>
+                    ([0-9]{4}-[0-9]{2}-[0-9]{2})</a>''',
+            webpage, u'upload date', fatal=False, flags=re.VERBOSE)
         if upload_date:
             # Convert timestring to a format suitable for filename
             upload_date = datetime.datetime.strptime(upload_date, "%Y-%m-%d")
diff --git a/youtube_dl/extractor/internetvideoarchive.py b/youtube_dl/extractor/internetvideoarchive.py
new file mode 100644 (file)
index 0000000..be8e05f
--- /dev/null
@@ -0,0 +1,84 @@
+import re
+import xml.etree.ElementTree
+
+from .common import InfoExtractor
+from ..utils import (
+    compat_urlparse,
+    compat_urllib_parse,
+    xpath_with_ns,
+    determine_ext,
+)
+
+
+class InternetVideoArchiveIE(InfoExtractor):
+    _VALID_URL = r'https?://video\.internetvideoarchive\.net/flash/players/.*?\?.*?publishedid.*?'
+
+    _TEST = {
+        u'url': u'http://video.internetvideoarchive.net/flash/players/flashconfiguration.aspx?customerid=69249&publishedid=452693&playerid=247',
+        u'file': u'452693.mp4',
+        u'info_dict': {
+            u'title': u'SKYFALL',
+            u'description': u'In SKYFALL, Bond\'s loyalty to M is tested as her past comes back to haunt her. As MI6 comes under attack, 007 must track down and destroy the threat, no matter how personal the cost.',
+            u'duration': 153,
+        },
+    }
+
+    @staticmethod
+    def _build_url(query):
+        return 'http://video.internetvideoarchive.net/flash/players/flashconfiguration.aspx?' + query
+
+    @staticmethod
+    def _clean_query(query):
+        NEEDED_ARGS = ['publishedid', 'customerid']
+        query_dic = compat_urlparse.parse_qs(query)
+        cleaned_dic = dict((k,v[0]) for (k,v) in query_dic.items() if k in NEEDED_ARGS)
+        # Other player ids return m3u8 urls
+        cleaned_dic['playerid'] = '247'
+        cleaned_dic['videokbrate'] = '100000'
+        return compat_urllib_parse.urlencode(cleaned_dic)
+
+    def _real_extract(self, url):
+        query = compat_urlparse.urlparse(url).query
+        query_dic = compat_urlparse.parse_qs(query)
+        video_id = query_dic['publishedid'][0]
+        url = self._build_url(query)
+
+        flashconfiguration_xml = self._download_webpage(url, video_id,
+            u'Downloading flash configuration')
+        flashconfiguration = xml.etree.ElementTree.fromstring(flashconfiguration_xml.encode('utf-8'))
+        file_url = flashconfiguration.find('file').text
+        file_url = file_url.replace('/playlist.aspx', '/mrssplaylist.aspx')
+        # Replace some of the parameters in the query to get the best quality
+        # and http links (no m3u8 manifests)
+        file_url = re.sub(r'(?<=\?)(.+)$',
+            lambda m: self._clean_query(m.group()),
+            file_url)
+        info_xml = self._download_webpage(file_url, video_id,
+            u'Downloading video info')
+        info = xml.etree.ElementTree.fromstring(info_xml.encode('utf-8'))
+        item = info.find('channel/item')
+
+        def _bp(p):
+            return xpath_with_ns(p,
+                {'media': 'http://search.yahoo.com/mrss/',
+                'jwplayer': 'http://developer.longtailvideo.com/trac/wiki/FlashFormats'})
+        formats = []
+        for content in item.findall(_bp('media:group/media:content')):
+            attr = content.attrib
+            f_url = attr['url']
+            formats.append({
+                'url': f_url,
+                'ext': determine_ext(f_url),
+                'width': int(attr['width']),
+                'bitrate': int(attr['bitrate']),
+            })
+        formats = sorted(formats, key=lambda f: f['bitrate'])
+
+        return {
+            'id': video_id,
+            'title': item.find('title').text,
+            'formats': formats,
+            'thumbnail': item.find(_bp('media:thumbnail')).attrib['url'],
+            'description': item.find('description').text,
+            'duration': int(attr['duration']),
+        }
index 4327bc13dab9c913eca8c4c263b6405e0dcc9076..6bb54b932298395b8f07554b12ad6091cca140d3 100644 (file)
@@ -6,13 +6,14 @@ import xml.etree.ElementTree
 
 from .common import InfoExtractor
 
+
 class JeuxVideoIE(InfoExtractor):
     _VALID_URL = r'http://.*?\.jeuxvideo\.com/.*/(.*?)-\d+\.htm'
 
     _TEST = {
         u'url': u'http://www.jeuxvideo.com/reportages-videos-jeux/0004/00046170/tearaway-playstation-vita-gc-2013-tearaway-nous-presente-ses-papiers-d-identite-00115182.htm',
         u'file': u'5182.mp4',
-        u'md5': u'e0fdb0cd3ce98713ef9c1e1e025779d0',
+        u'md5': u'046e491afb32a8aaac1f44dd4ddd54ee',
         u'info_dict': {
             u'title': u'GC 2013 : Tearaway nous présente ses papiers d\'identité',
             u'description': u'Lorsque les développeurs de LittleBigPlanet proposent un nouveau titre, on ne peut que s\'attendre à un résultat original et fort attrayant.\n',
@@ -23,25 +24,29 @@ class JeuxVideoIE(InfoExtractor):
         mobj = re.match(self._VALID_URL, url)
         title = re.match(self._VALID_URL, url).group(1)
         webpage = self._download_webpage(url, title)
-        m_download = re.search(r'<param name="flashvars" value="config=(.*?)" />', webpage)
-
-        xml_link = m_download.group(1)
+        xml_link = self._html_search_regex(
+            r'<param name="flashvars" value="config=(.*?)" />',
+            webpage, u'config URL')
         
-        id = re.search(r'http://www.jeuxvideo.com/config/\w+/0011/(.*?)/\d+_player\.xml', xml_link).group(1)
+        video_id = self._search_regex(
+            r'http://www\.jeuxvideo\.com/config/\w+/\d+/(.*?)/\d+_player\.xml',
+            xml_link, u'video ID')
 
-        xml_config = self._download_webpage(xml_link, title,
-                                                  'Downloading XML config')
+        xml_config = self._download_webpage(
+            xml_link, title, u'Downloading XML config')
         config = xml.etree.ElementTree.fromstring(xml_config.encode('utf-8'))
-        info = re.search(r'<format\.json>(.*?)</format\.json>',
-                         xml_config, re.MULTILINE|re.DOTALL).group(1)
-        info = json.loads(info)['versions'][0]
+        info_json = self._search_regex(
+            r'(?sm)<format\.json>(.*?)</format\.json>',
+            xml_config, u'JSON information')
+        info = json.loads(info_json)['versions'][0]
         
         video_url = 'http://video720.jeuxvideo.com/' + info['file']
 
-        return {'id': id,
-                'title' : config.find('titre_video').text,
-                'ext' : 'mp4',
-                'url' : video_url,
-                'description': self._og_search_description(webpage),
-                'thumbnail': config.find('image').text,
-                }
+        return {
+            'id': video_id,
+            'title': config.find('titre_video').text,
+            'ext': 'mp4',
+            'url': video_url,
+            'description': self._og_search_description(webpage),
+            'thumbnail': config.find('image').text,
+        }
index 8f956571d54dc4a42a4f3726642929e4b2497f13..e520e2bb491f2c55f3867ab214b2b949eca6e684 100644 (file)
@@ -54,23 +54,26 @@ class MTVIE(InfoExtractor):
     def _get_thumbnail_url(self, uri, itemdoc):
         return 'http://mtv.mtvnimages.com/uri/' + uri
 
-    def _extract_video_url(self, metadataXml):
+    def _extract_video_formats(self, metadataXml):
         if '/error_country_block.swf' in metadataXml:
             raise ExtractorError(u'This video is not available from your country.', expected=True)
         mdoc = xml.etree.ElementTree.fromstring(metadataXml.encode('utf-8'))
         renditions = mdoc.findall('.//rendition')
 
-        # For now, always pick the highest quality.
-        rendition = renditions[-1]
-
-        try:
-            _,_,ext = rendition.attrib['type'].partition('/')
-            format = ext + '-' + rendition.attrib['width'] + 'x' + rendition.attrib['height'] + '_' + rendition.attrib['bitrate']
-            rtmp_video_url = rendition.find('./src').text
-        except KeyError:
-            raise ExtractorError('Invalid rendition field.')
-        video_url = self._transform_rtmp_url(rtmp_video_url)
-        return {'ext': ext, 'url': video_url, 'format': format}
+        formats = []
+        for rendition in mdoc.findall('.//rendition'):
+            try:
+                _, _, ext = rendition.attrib['type'].partition('/')
+                rtmp_video_url = rendition.find('./src').text
+                formats.append({'ext': ext,
+                                'url': self._transform_rtmp_url(rtmp_video_url),
+                                'format_id': rendition.get('bitrate'),
+                                'width': int(rendition.get('width')),
+                                'height': int(rendition.get('height')),
+                                })
+            except (KeyError, TypeError):
+                raise ExtractorError('Invalid rendition field.')
+        return formats
 
     def _get_video_info(self, itemdoc):
         uri = itemdoc.find('guid').text
@@ -81,19 +84,25 @@ class MTVIE(InfoExtractor):
             mediagen_url += '&acceptMethods=fms'
         mediagen_page = self._download_webpage(mediagen_url, video_id,
                                                u'Downloading video urls')
-        video_info = self._extract_video_url(mediagen_page)
 
         description_node = itemdoc.find('description')
         if description_node is not None:
-            description = description_node.text
+            description = description_node.text.strip()
         else:
             description = None
-        video_info.update({'title': itemdoc.find('title').text,
-                           'id': video_id,
-                           'thumbnail': self._get_thumbnail_url(uri, itemdoc),
-                           'description': description,
-                           })
-        return video_info
+
+        info = {
+            'title': itemdoc.find('title').text,
+            'formats': self._extract_video_formats(mediagen_page),
+            'id': video_id,
+            'thumbnail': self._get_thumbnail_url(uri, itemdoc),
+            'description': description,
+        }
+
+        # TODO: Remove when #980 has been merged
+        info.update(info['formats'][-1])
+
+        return info
 
     def _get_videos_info(self, uri):
         video_id = self._id_from_uri(uri)
diff --git a/youtube_dl/extractor/nhl.py b/youtube_dl/extractor/nhl.py
new file mode 100644 (file)
index 0000000..224f56a
--- /dev/null
@@ -0,0 +1,120 @@
+import re
+import json
+import xml.etree.ElementTree
+
+from .common import InfoExtractor
+from ..utils import (
+    compat_urlparse,
+    compat_urllib_parse,
+    determine_ext,
+    unified_strdate,
+)
+
+
+class NHLBaseInfoExtractor(InfoExtractor):
+    @staticmethod
+    def _fix_json(json_string):
+        return json_string.replace('\\\'', '\'')
+
+    def _extract_video(self, info):
+        video_id = info['id']
+        self.report_extraction(video_id)
+
+        initial_video_url = info['publishPoint']
+        data = compat_urllib_parse.urlencode({
+            'type': 'fvod',
+            'path': initial_video_url.replace('.mp4', '_sd.mp4'),
+        })
+        path_url = 'http://video.nhl.com/videocenter/servlets/encryptvideopath?' + data
+        path_response = self._download_webpage(path_url, video_id,
+            u'Downloading final video url')
+        path_doc = xml.etree.ElementTree.fromstring(path_response)
+        video_url = path_doc.find('path').text
+
+        join = compat_urlparse.urljoin
+        return {
+            'id': video_id,
+            'title': info['name'],
+            'url': video_url,
+            'ext': determine_ext(video_url),
+            'description': info['description'],
+            'duration': int(info['duration']),
+            'thumbnail': join(join(video_url, '/u/'), info['bigImage']),
+            'upload_date': unified_strdate(info['releaseDate'].split('.')[0]),
+        }
+
+
+class NHLIE(NHLBaseInfoExtractor):
+    IE_NAME = u'nhl.com'
+    _VALID_URL = r'https?://video(?P<team>\.[^.]*)?\.nhl\.com/videocenter/console\?.*?(?<=[?&])id=(?P<id>\d+)'
+
+    _TEST = {
+        u'url': u'http://video.canucks.nhl.com/videocenter/console?catid=6?id=453614',
+        u'file': u'453614.mp4',
+        u'info_dict': {
+            u'title': u'Quick clip: Weise 4-3 goal vs Flames',
+            u'description': u'Dale Weise scores his first of the season to put the Canucks up 4-3.',
+            u'duration': 18,
+            u'upload_date': u'20131006',
+        },
+    }
+
+    def _real_extract(self, url):
+        mobj = re.match(self._VALID_URL, url)
+        video_id = mobj.group('id')
+        json_url = 'http://video.nhl.com/videocenter/servlets/playlist?ids=%s&format=json' % video_id
+        info_json = self._download_webpage(json_url, video_id,
+            u'Downloading info json')
+        info_json = self._fix_json(info_json)
+        info = json.loads(info_json)[0]
+        return self._extract_video(info)
+
+
+class NHLVideocenterIE(NHLBaseInfoExtractor):
+    IE_NAME = u'nhl.com:videocenter'
+    IE_DESC = u'Download the first 12 videos from a videocenter category'
+    _VALID_URL = r'https?://video\.(?P<team>[^.]*)\.nhl\.com/videocenter/(console\?.*?catid=(?P<catid>[^&]+))?'
+
+    @classmethod
+    def suitable(cls, url):
+        if NHLIE.suitable(url):
+            return False
+        return super(NHLVideocenterIE, cls).suitable(url)
+
+    def _real_extract(self, url):
+        mobj = re.match(self._VALID_URL, url)
+        team = mobj.group('team')
+        webpage = self._download_webpage(url, team)
+        cat_id = self._search_regex(
+            [r'var defaultCatId = "(.+?)";',
+             r'{statusIndex:0,index:0,.*?id:(.*?),'],
+            webpage, u'category id')
+        playlist_title = self._html_search_regex(
+            r'tab0"[^>]*?>(.*?)</td>',
+            webpage, u'playlist title', flags=re.DOTALL).lower().capitalize()
+
+        data = compat_urllib_parse.urlencode({
+            'cid': cat_id,
+            # This is the default value
+            'count': 12,
+            'ptrs': 3,
+            'format': 'json',
+        })
+        path = '/videocenter/servlets/browse?' + data
+        request_url = compat_urlparse.urljoin(url, path)
+        response = self._download_webpage(request_url, playlist_title)
+        response = self._fix_json(response)
+        if not response.strip():
+            self._downloader.report_warning(u'Got an empty reponse, trying '
+                                            u'adding the "newvideos" parameter')
+            response = self._download_webpage(request_url + '&newvideos=true',
+                playlist_title)
+            response = self._fix_json(response)
+        videos = json.loads(response)
+
+        return {
+            '_type': 'playlist',
+            'title': playlist_title,
+            'id': cat_id,
+            'entries': [self._extract_video(i) for i in videos],
+        }
diff --git a/youtube_dl/extractor/nowvideo.py b/youtube_dl/extractor/nowvideo.py
new file mode 100644 (file)
index 0000000..ab52ad4
--- /dev/null
@@ -0,0 +1,43 @@
+import re
+
+from .common import InfoExtractor
+from ..utils import compat_urlparse
+
+
+class NowVideoIE(InfoExtractor):
+    _VALID_URL = r'(?:https?://)?(?:www\.)?nowvideo\.ch/video/(?P<id>\w+)'
+    _TEST = {
+        u'url': u'http://www.nowvideo.ch/video/0mw0yow7b6dxa',
+        u'file': u'0mw0yow7b6dxa.flv',
+        u'md5': u'f8fbbc8add72bd95b7850c6a02fc8817',
+        u'info_dict': {
+            u"title": u"youtubedl test video _BaW_jenozKc.mp4"
+        }
+    }
+
+    def _real_extract(self, url):
+        mobj = re.match(self._VALID_URL, url)
+
+        video_id = mobj.group('id')
+        webpage_url = 'http://www.nowvideo.ch/video/' + video_id
+        webpage = self._download_webpage(webpage_url, video_id)
+
+        self.report_extraction(video_id)
+
+        video_title = self._html_search_regex(r'<h4>(.*)</h4>',
+            webpage, u'video title')
+
+        video_key = self._search_regex(r'var fkzd="(.*)";',
+            webpage, u'video key')
+
+        api_call = "http://www.nowvideo.ch/api/player.api.php?file={0}&numOfErrors=0&cid=1&key={1}".format(video_id, video_key)
+        api_response = self._download_webpage(api_call, video_id,
+            u'Downloading API page')
+        video_url = compat_urlparse.parse_qs(api_response)[u'url'][0]
+
+        return [{
+            'id':        video_id,
+            'url':       video_url,
+            'ext':       'flv',
+            'title':     video_title,
+        }]
index add76a11e5f2c0c17af76b71db6e8bd07adc6cd6..5d770ec285c3d1e3dcad04cfe49ca7780a9dd2b4 100644 (file)
@@ -38,6 +38,7 @@ class PornotubeIE(InfoExtractor):
         VIDEO_UPLOADED_RE = r'<div class="video_added_by">Added (?P<date>[0-9\/]+) by'
         upload_date = self._html_search_regex(VIDEO_UPLOADED_RE, webpage, u'upload date', fatal=False)
         if upload_date: upload_date = unified_strdate(upload_date)
+        age_limit = self._rta_search(webpage)
 
         info = {'id': video_id,
                 'url': video_url,
@@ -45,6 +46,7 @@ class PornotubeIE(InfoExtractor):
                 'upload_date': upload_date,
                 'title': video_title,
                 'ext': 'flv',
-                'format': 'flv'}
+                'format': 'flv',
+                'age_limit': age_limit}
 
         return [info]
index 1d2cf1f56df7ae932e67d4cd8253f6441818d80e..994778e16758bc292a01e99e5292caee30a6d5c2 100644 (file)
@@ -10,28 +10,35 @@ class RedTubeIE(InfoExtractor):
         u'file': u'66418.mp4',
         u'md5': u'7b8c22b5e7098a3e1c09709df1126d2d',
         u'info_dict': {
-            u"title": u"Sucked on a toilet"
+            u"title": u"Sucked on a toilet",
+            u"age_limit": 18,
         }
     }
 
-    def _real_extract(self,url):
+    def _real_extract(self, url):
         mobj = re.match(self._VALID_URL, url)
 
         video_id = mobj.group('id')
-        video_extension = 'mp4'        
+        video_extension = 'mp4'
         webpage = self._download_webpage(url, video_id)
 
         self.report_extraction(video_id)
 
-        video_url = self._html_search_regex(r'<source src="(.+?)" type="video/mp4">',
-            webpage, u'video URL')
+        video_url = self._html_search_regex(
+            r'<source src="(.+?)" type="video/mp4">', webpage, u'video URL')
 
-        video_title = self._html_search_regex('<h1 class="videoTitle slidePanelMovable">(.+?)</h1>',
+        video_title = self._html_search_regex(
+            r'<h1 class="videoTitle slidePanelMovable">(.+?)</h1>',
             webpage, u'title')
 
-        return [{
-            'id':       video_id,
-            'url':      video_url,
-            'ext':      video_extension,
-            'title':    video_title,
-        }]
+        # No self-labeling, but they describe themselves as
+        # "Home of Videos Porno"
+        age_limit = 18
+
+        return {
+            'id':        video_id,
+            'url':       video_url,
+            'ext':       video_extension,
+            'title':     video_title,
+            'age_limit': age_limit,
+        }
diff --git a/youtube_dl/extractor/rottentomatoes.py b/youtube_dl/extractor/rottentomatoes.py
new file mode 100644 (file)
index 0000000..c79c394
--- /dev/null
@@ -0,0 +1,16 @@
+from .videodetective import VideoDetectiveIE
+
+
+# It just uses the same method as videodetective.com,
+# the internetvideoarchive.com is extracted from the og:video property
+class RottenTomatoesIE(VideoDetectiveIE):
+    _VALID_URL = r'https?://www\.rottentomatoes\.com/m/[^/]+/trailers/(?P<id>\d+)'
+
+    _TEST = {
+        u'url': u'http://www.rottentomatoes.com/m/toy_story_3/trailers/11028566/',
+        u'file': '613340.mp4',
+        u'info_dict': {
+            u'title': u'TOY STORY 3',
+            u'description': u'From the creators of the beloved TOY STORY films, comes a story that will reunite the gang in a whole new way.',
+        },
+    }
index 32541077ff829662c42d2380095a2ab4bdc7e08d..d1b08c9bc050b3639ca252f2e84a373a8e4fa5f9 100644 (file)
@@ -8,8 +8,8 @@ from ..utils import (
 )
 
 class RTLnowIE(InfoExtractor):
-    """Information Extractor for RTL NOW, RTL2 NOW, RTL NITRO, SUPER RTL NOW and VOX NOW"""
-    _VALID_URL = r'(?:http://)?(?P<url>(?P<base_url>rtl-now\.rtl\.de/|rtl2now\.rtl2\.de/|(?:www\.)?voxnow\.de/|(?:www\.)?rtlnitronow\.de/|(?:www\.)?superrtlnow\.de/)[a-zA-Z0-9-]+/[a-zA-Z0-9-]+\.php\?(?:container_id|film_id)=(?P<video_id>[0-9]+)&player=1(?:&season=[0-9]+)?(?:&.*)?)'
+    """Information Extractor for RTL NOW, RTL2 NOW, RTL NITRO, SUPER RTL NOW, VOX NOW and n-tv NOW"""
+    _VALID_URL = r'(?:http://)?(?P<url>(?P<base_url>rtl-now\.rtl\.de/|rtl2now\.rtl2\.de/|(?:www\.)?voxnow\.de/|(?:www\.)?rtlnitronow\.de/|(?:www\.)?superrtlnow\.de/|(?:www\.)?n-tvnow\.de/)[a-zA-Z0-9-]+/[a-zA-Z0-9-]+\.php\?(?:container_id|film_id)=(?P<video_id>[0-9]+)&player=1(?:&season=[0-9]+)?(?:&.*)?)'
     _TESTS = [{
         u'url': u'http://rtl-now.rtl.de/ahornallee/folge-1.php?film_id=90419&player=1&season=1',
         u'file': u'90419.flv',
@@ -74,8 +74,22 @@ class RTLnowIE(InfoExtractor):
         u'params': {
             u'skip_download': True,
         },
+    },
+    {
+        u'url': u'http://www.n-tvnow.de/top-gear/episode-1-2013-01-01-00-00-00.php?film_id=124903&player=1&season=10',
+        u'file': u'124903.flv',
+        u'info_dict': {
+            u'upload_date': u'20130101', 
+            u'title': u'Top Gear vom 01.01.2013',
+            u'description': u'Episode 1',
+        },
+        u'params': {
+            u'skip_download': True,
+        },
+        u'skip': u'Only works from Germany',
     }]
 
+
     def _real_extract(self,url):
         mobj = re.match(self._VALID_URL, url)
 
@@ -98,14 +112,17 @@ class RTLnowIE(InfoExtractor):
             webpage, u'playerdata_url')
 
         playerdata = self._download_webpage(playerdata_url, video_id)
-        mobj = re.search(r'<title><!\[CDATA\[(?P<description>.+?)\s+- (?:Sendung )?vom (?P<upload_date_d>[0-9]{2})\.(?P<upload_date_m>[0-9]{2})\.(?:(?P<upload_date_Y>[0-9]{4})|(?P<upload_date_y>[0-9]{2})) [0-9]{2}:[0-9]{2} Uhr\]\]></title>', playerdata)
+        mobj = re.search(r'<title><!\[CDATA\[(?P<description>.+?)(?:\s+- (?:Sendung )?vom (?P<upload_date_d>[0-9]{2})\.(?P<upload_date_m>[0-9]{2})\.(?:(?P<upload_date_Y>[0-9]{4})|(?P<upload_date_y>[0-9]{2})) [0-9]{2}:[0-9]{2} Uhr)?\]\]></title>', playerdata)
         if mobj:
             video_description = mobj.group(u'description')
             if mobj.group('upload_date_Y'):
                 video_upload_date = mobj.group('upload_date_Y')
-            else:
+            elif mobj.group('upload_date_y'):
                 video_upload_date = u'20' + mobj.group('upload_date_y')
-            video_upload_date += mobj.group('upload_date_m')+mobj.group('upload_date_d')
+            else:
+                video_upload_date = None
+            if video_upload_date:
+                video_upload_date += mobj.group('upload_date_m')+mobj.group('upload_date_d')
         else:
             video_description = None
             video_upload_date = None
diff --git a/youtube_dl/extractor/rutube.py b/youtube_dl/extractor/rutube.py
new file mode 100644 (file)
index 0000000..a18034f
--- /dev/null
@@ -0,0 +1,58 @@
+# encoding: utf-8
+import re
+import json
+
+from .common import InfoExtractor
+from ..utils import (
+    compat_urlparse,
+    compat_str,
+    ExtractorError,
+)
+
+
+class RutubeIE(InfoExtractor):
+    _VALID_URL = r'https?://rutube.ru/video/(?P<long_id>\w+)'
+
+    _TEST = {
+        u'url': u'http://rutube.ru/video/3eac3b4561676c17df9132a9a1e62e3e/',
+        u'file': u'3eac3b4561676c17df9132a9a1e62e3e.mp4',
+        u'info_dict': {
+            u'title': u'Раненный кенгуру забежал в аптеку',
+            u'uploader': u'NTDRussian',
+            u'uploader_id': u'29790',
+        },
+        u'params': {
+            # It requires ffmpeg (m3u8 download)
+            u'skip_download': True,
+        },
+    }
+
+    def _get_api_response(self, short_id, subpath):
+        api_url = 'http://rutube.ru/api/play/%s/%s/?format=json' % (subpath, short_id)
+        response_json = self._download_webpage(api_url, short_id,
+            u'Downloading %s json' % subpath)
+        return json.loads(response_json)
+
+    def _real_extract(self, url):
+        mobj = re.match(self._VALID_URL, url)
+        long_id = mobj.group('long_id')
+        webpage = self._download_webpage(url, long_id)
+        og_video = self._og_search_video_url(webpage)
+        short_id = compat_urlparse.urlparse(og_video).path[1:]
+        options = self._get_api_response(short_id, 'options')
+        trackinfo = self._get_api_response(short_id, 'trackinfo')
+        # Some videos don't have the author field
+        author = trackinfo.get('author') or {}
+        m3u8_url = trackinfo['video_balancer'].get('m3u8')
+        if m3u8_url is None:
+            raise ExtractorError(u'Couldn\'t find m3u8 manifest url')
+
+        return {
+            'id': trackinfo['id'],
+            'title': trackinfo['title'],
+            'url': m3u8_url,
+            'ext': 'mp4',
+            'thumbnail': options['thumbnail_url'],
+            'uploader': author.get('name'),
+            'uploader_id': compat_str(author['id']) if author else None,
+        }
diff --git a/youtube_dl/extractor/sztvhu.py b/youtube_dl/extractor/sztvhu.py
new file mode 100644 (file)
index 0000000..81fa35c
--- /dev/null
@@ -0,0 +1,44 @@
+# -*- coding: utf-8 -*-
+
+import re
+
+from .common import InfoExtractor
+from ..utils import determine_ext
+
+
+class SztvHuIE(InfoExtractor):
+    _VALID_URL = r'(?:http://)?(?:(?:www\.)?sztv\.hu|www\.tvszombathely\.hu)/(?:[^/]+)/.+-(?P<id>[0-9]+)'
+    _TEST = {
+        u'url': u'http://sztv.hu/hirek/cserkeszek-nepszerusitettek-a-kornyezettudatos-eletmodot-a-savaria-teren-20130909',
+        u'file': u'20130909.mp4',
+        u'md5': u'a6df607b11fb07d0e9f2ad94613375cb',
+        u'info_dict': {
+            u"title": u"Cserkészek népszerűsítették a környezettudatos életmódot a Savaria téren",
+            u"description": u'A zöld nap játékos ismeretterjesztő programjait a Magyar Cserkész Szövetség szervezte, akik az ország nyolc városában adják át tudásukat az érdeklődőknek. A PET...',
+        }
+    }
+
+    def _real_extract(self, url):
+        mobj = re.match(self._VALID_URL, url)
+        video_id = mobj.group('id')
+        webpage = self._download_webpage(url, video_id)
+        video_file = self._search_regex(
+            r'file: "...:(.*?)",', webpage, 'video file')
+        title = self._html_search_regex(
+            r'<meta name="title" content="([^"]*?) - [^-]*? - [^-]*?"',
+            webpage, 'video title')
+        description = self._html_search_regex(
+            r'<meta name="description" content="([^"]*)"/>',
+            webpage, 'video description', fatal=False)
+        thumbnail = self._og_search_thumbnail(webpage)
+
+        video_url = 'http://media.sztv.hu/vod/' + video_file
+
+        return {
+            'id': video_id,
+            'url': video_url,
+            'title': title,
+            'ext': determine_ext(video_url),
+            'description': description,
+            'thumbnail': thumbnail,
+        }
diff --git a/youtube_dl/extractor/techtalks.py b/youtube_dl/extractor/techtalks.py
new file mode 100644 (file)
index 0000000..a55f236
--- /dev/null
@@ -0,0 +1,65 @@
+import re
+
+from .common import InfoExtractor
+from ..utils import (
+    get_element_by_attribute,
+    clean_html,
+)
+
+
+class TechTalksIE(InfoExtractor):
+    _VALID_URL = r'https?://techtalks\.tv/talks/[^/]*/(?P<id>\d+)/'
+
+    _TEST = {
+        u'url': u'http://techtalks.tv/talks/learning-topic-models-going-beyond-svd/57758/',
+        u'playlist': [
+            {
+                u'file': u'57758.flv',
+                u'info_dict': {
+                    u'title': u'Learning Topic Models --- Going beyond SVD',
+                },
+            },
+            {
+                u'file': u'57758-slides.flv',
+                u'info_dict': {
+                    u'title': u'Learning Topic Models --- Going beyond SVD',
+                },
+            },
+        ],
+        u'params': {
+            # rtmp download
+            u'skip_download': True,
+        },
+    }
+
+    def _real_extract(self, url):
+        mobj = re.match(self._VALID_URL, url)
+        talk_id = mobj.group('id')
+        webpage = self._download_webpage(url, talk_id)
+        rtmp_url = self._search_regex(r'netConnectionUrl: \'(.*?)\'', webpage,
+            u'rtmp url')
+        play_path = self._search_regex(r'href=\'(.*?)\' [^>]*id="flowplayer_presenter"',
+            webpage, u'presenter play path')
+        title = clean_html(get_element_by_attribute('class', 'title', webpage))
+        video_info = {
+                'id': talk_id,
+                'title': title,
+                'url': rtmp_url,
+                'play_path': play_path,
+                'ext': 'flv',
+            }
+        m_slides = re.search(r'<a class="slides" href=\'(.*?)\'', webpage)
+        if m_slides is None:
+            return video_info
+        else:
+            return [
+                video_info,
+                # The slides video
+                {
+                    'id': talk_id + '-slides',
+                    'title': title,
+                    'url': rtmp_url,
+                    'play_path': m_slides.group(1),
+                    'ext': 'flv',
+                },
+            ]
index 4c11f7a03c37136c0c80677e55b66598c647edeb..dfa1176a3e4e4eef333dcb829773c189bf9916ba 100644 (file)
@@ -77,12 +77,20 @@ class TEDIE(InfoExtractor):
         
         thumbnail = self._search_regex(r'</span>[\s.]*</div>[\s.]*<img src="(.*?)"',
                                        webpage, 'thumbnail')
+        formats = [{
+            'ext': 'mp4',
+            'url': stream['file'],
+            'format': stream['id']
+            } for stream in info['htmlStreams']]
         info = {
-                'id': info['id'],
-                'url': info['htmlStreams'][-1]['file'],
-                'ext': 'mp4',
-                'title': title,
-                'thumbnail': thumbnail,
-                'description': desc,
-                }
+            'id': info['id'],
+            'title': title,
+            'thumbnail': thumbnail,
+            'description': desc,
+            'formats': formats,
+        }
+
+        # TODO: Remove when #980 has been merged
+        info.update(info['formats'][-1])
+
         return info
index 1405b73f76ad5166d45d9a9eb9687c49fa8a0bde..7a3891b89b736fb05f4c09d441d7eb56e68d8dcd 100644 (file)
@@ -7,15 +7,25 @@ from .common import InfoExtractor
 
 
 class TudouIE(InfoExtractor):
-    _VALID_URL = r'(?:http://)?(?:www\.)?tudou\.com/(?:listplay|programs)/(?:view|(.+?))/(?:([^/]+)|([^/]+))(?:\.html)?'
-    _TEST = {
+    _VALID_URL = r'(?:http://)?(?:www\.)?tudou\.com/(?:listplay|programs|albumplay)/(?:view|(.+?))/(?:([^/]+)|([^/]+))(?:\.html)?'
+    _TESTS = [{
         u'url': u'http://www.tudou.com/listplay/zzdE77v6Mmo/2xN2duXMxmw.html',
         u'file': u'159448201.f4v',
         u'md5': u'140a49ed444bd22f93330985d8475fcb',
         u'info_dict': {
             u"title": u"卡马乔国足开大脚长传冲吊集锦"
         }
-    }
+    },
+    {
+        u'url': u'http://www.tudou.com/albumplay/TenTw_JgiPM/PzsAs5usU9A.html',
+        u'file': u'todo.mp4',
+        u'md5': u'todo.mp4',
+        u'info_dict': {
+            u'title': u'todo.mp4',
+        },
+        u'add_ie': [u'Youku'],
+        u'skip': u'Only works from China'
+    }]
 
     def _url_for_id(self, id, quality = None):
         info_url = "http://v2.tudou.com/f?id="+str(id)
@@ -29,14 +39,19 @@ class TudouIE(InfoExtractor):
         mobj = re.match(self._VALID_URL, url)
         video_id = mobj.group(2)
         webpage = self._download_webpage(url, video_id)
-        title = re.search(",kw:\"(.+)\"",webpage)
-        if title is None:
-            title = re.search(",kw: \'(.+)\'",webpage)
-        title = title.group(1)
-        thumbnail_url = re.search(",pic: \'(.+?)\'",webpage)
-        if thumbnail_url is None:
-            thumbnail_url = re.search(",pic:\"(.+?)\"",webpage)
-        thumbnail_url = thumbnail_url.group(1)
+
+        m = re.search(r'vcode:\s*[\'"](.+?)[\'"]', webpage)
+        if m and m.group(1):
+            return {
+                '_type': 'url',
+                'url': u'youku:' + m.group(1),
+                'ie_key': 'Youku'
+            }
+
+        title = self._search_regex(
+            r",kw:\s*['\"](.+?)[\"']", webpage, u'title')
+        thumbnail_url = self._search_regex(
+            r",pic:\s*[\"'](.+?)[\"']", webpage, u'thumbnail URL', fatal=False)
 
         segs_json = self._search_regex(r'segs: \'(.*)\'', webpage, 'segments')
         segments = json.loads(segs_json)
index 70408c4f0edc2ba5b00a9e793cf1e1c2e0ba30ed..1c1cc418d29a8897e2a2825492ed7becab75af6b 100644 (file)
@@ -1,11 +1,15 @@
 import re
 import json
+import xml.etree.ElementTree
+import datetime
 
 from .common import InfoExtractor
 from ..utils import (
+    determine_ext,
     ExtractorError,
 )
 
+
 class VevoIE(InfoExtractor):
     """
     Accepts urls from vevo.com or in the format 'vevo:{id}'
@@ -15,11 +19,11 @@ class VevoIE(InfoExtractor):
     _TEST = {
         u'url': u'http://www.vevo.com/watch/hurts/somebody-to-die-for/GB1101300280',
         u'file': u'GB1101300280.mp4',
-        u'md5': u'06bea460acb744eab74a9d7dcb4bfd61',
         u'info_dict': {
             u"upload_date": u"20130624",
             u"uploader": u"Hurts",
-            u"title": u"Somebody to Die For"
+            u"title": u"Somebody to Die For",
+            u'duration': 230,
         }
     }
 
@@ -27,27 +31,47 @@ class VevoIE(InfoExtractor):
         mobj = re.match(self._VALID_URL, url)
         video_id = mobj.group('id')
 
-        json_url = 'http://www.vevo.com/data/video/%s' % video_id
-        base_url = 'http://smil.lvl3.vevo.com'
-        videos_url = '%s/Video/V2/VFILE/%s/%sr.smil' % (base_url, video_id, video_id.lower())
+        json_url = 'http://videoplayer.vevo.com/VideoService/AuthenticateVideo?isrc=%s' % video_id
         info_json = self._download_webpage(json_url, video_id, u'Downloading json info')
-        links_webpage = self._download_webpage(videos_url, video_id, u'Downloading videos urls')
 
         self.report_extraction(video_id)
-        video_info = json.loads(info_json)
-        m_urls = list(re.finditer(r'<video src="(?P<ext>.*?):/?(?P<url>.*?)"', links_webpage))
-        if m_urls is None or len(m_urls) == 0:
-            raise ExtractorError(u'Unable to extract video url')
-        # They are sorted from worst to best quality
-        m_url = m_urls[-1]
-        video_url = base_url + '/' + m_url.group('url')
-        ext = m_url.group('ext')
-
-        return {'url': video_url,
-                'ext': ext,
-                'id': video_id,
-                'title': video_info['title'],
-                'thumbnail': video_info['img'],
-                'upload_date': video_info['launchDate'].replace('/',''),
-                'uploader': video_info['Artists'][0]['title'],
-                }
+        video_info = json.loads(info_json)['video']
+        last_version = {'version': -1}
+        for version in video_info['videoVersions']:
+            # These are the HTTP downloads, other types are for different manifests
+            if version['sourceType'] == 2:
+                if version['version'] > last_version['version']:
+                    last_version = version
+        if last_version['version'] == -1:
+            raise ExtractorError(u'Unable to extract last version of the video')
+
+        renditions = xml.etree.ElementTree.fromstring(last_version['data'])
+        formats = []
+        # Already sorted from worst to best quality
+        for rend in renditions.findall('rendition'):
+            attr = rend.attrib
+            f_url = attr['url']
+            formats.append({
+                'url': f_url,
+                'ext': determine_ext(f_url),
+                'height': int(attr['frameheight']),
+                'width': int(attr['frameWidth']),
+            })
+
+        date_epoch = int(self._search_regex(
+            r'/Date\((\d+)\)/', video_info['launchDate'], u'launch date'))/1000
+        upload_date = datetime.datetime.fromtimestamp(date_epoch)
+        info = {
+            'id': video_id,
+            'title': video_info['title'],
+            'formats': formats,
+            'thumbnail': video_info['imageUrl'],
+            'upload_date': upload_date.strftime('%Y%m%d'),
+            'uploader': video_info['mainArtists'][0]['artistName'],
+            'duration': video_info['duration'],
+        }
+
+        # TODO: Remove when #980 has been merged
+        info.update(formats[-1])
+
+        return info
diff --git a/youtube_dl/extractor/viddler.py b/youtube_dl/extractor/viddler.py
new file mode 100644 (file)
index 0000000..12c84a9
--- /dev/null
@@ -0,0 +1,64 @@
+import json
+import re
+
+from .common import InfoExtractor
+from ..utils import (
+    determine_ext,
+)
+
+
+class ViddlerIE(InfoExtractor):
+    _VALID_URL = r'(?P<domain>https?://(?:www\.)?viddler.com)/(?:v|embed|player)/(?P<id>[0-9]+)'
+    _TEST = {
+        u"url": u"http://www.viddler.com/v/43903784",
+        u'file': u'43903784.mp4',
+        u'md5': u'fbbaedf7813e514eb7ca30410f439ac9',
+        u'info_dict': {
+            u"title": u"Video Made Easy",
+            u"uploader": u"viddler",
+            u"duration": 100.89,
+        }
+    }
+
+    def _real_extract(self, url):
+        mobj = re.match(self._VALID_URL, url)
+        video_id = mobj.group('id')
+
+        embed_url = mobj.group('domain') + u'/embed/' + video_id
+        webpage = self._download_webpage(embed_url, video_id)
+
+        video_sources_code = self._search_regex(
+            r"(?ms)sources\s*:\s*(\{.*?\})", webpage, u'video URLs')
+        video_sources = json.loads(video_sources_code.replace("'", '"'))
+
+        formats = [{
+            'url': video_url,
+            'format': format_id,
+        } for video_url, format_id in video_sources.items()]
+
+        title = self._html_search_regex(
+            r"title\s*:\s*'([^']*)'", webpage, u'title')
+        uploader = self._html_search_regex(
+            r"authorName\s*:\s*'([^']*)'", webpage, u'uploader', fatal=False)
+        duration_s = self._html_search_regex(
+            r"duration\s*:\s*([0-9.]*)", webpage, u'duration', fatal=False)
+        duration = float(duration_s) if duration_s else None
+        thumbnail = self._html_search_regex(
+            r"thumbnail\s*:\s*'([^']*)'",
+            webpage, u'thumbnail', fatal=False)
+
+        info = {
+            '_type': 'video',
+            'id': video_id,
+            'title': title,
+            'thumbnail': thumbnail,
+            'uploader': uploader,
+            'duration': duration,
+            'formats': formats,
+        }
+
+        # TODO: Remove when #980 has been merged
+        info['formats'][-1]['ext'] = determine_ext(info['formats'][-1]['url'])
+        info.update(info['formats'][-1])
+
+        return info
diff --git a/youtube_dl/extractor/videodetective.py b/youtube_dl/extractor/videodetective.py
new file mode 100644 (file)
index 0000000..265dd5b
--- /dev/null
@@ -0,0 +1,30 @@
+import re
+
+from .common import InfoExtractor
+from .internetvideoarchive import InternetVideoArchiveIE
+from ..utils import (
+    compat_urlparse,
+)
+
+
+class VideoDetectiveIE(InfoExtractor):
+    _VALID_URL = r'https?://www\.videodetective\.com/[^/]+/[^/]+/(?P<id>\d+)'
+
+    _TEST = {
+        u'url': u'http://www.videodetective.com/movies/kick-ass-2/194487',
+        u'file': u'194487.mp4',
+        u'info_dict': {
+            u'title': u'KICK-ASS 2',
+            u'description': u'md5:65ba37ad619165afac7d432eaded6013',
+            u'duration': 135,
+        },
+    }
+
+    def _real_extract(self, url):
+        mobj = re.match(self._VALID_URL, url)
+        video_id = mobj.group('id')
+        webpage = self._download_webpage(url, video_id)
+        og_video = self._og_search_video_url(webpage)
+        query = compat_urlparse.urlparse(og_video).query
+        return self.url_result(InternetVideoArchiveIE._build_url(query),
+            ie=InternetVideoArchiveIE.ie_key())
diff --git a/youtube_dl/extractor/videopremium.py b/youtube_dl/extractor/videopremium.py
new file mode 100644 (file)
index 0000000..65f39b9
--- /dev/null
@@ -0,0 +1,40 @@
+import re
+import random
+
+from .common import InfoExtractor
+
+
+class VideoPremiumIE(InfoExtractor):
+    _VALID_URL = r'(?:https?://)?(?:www\.)?videopremium\.tv/(?P<id>\w+)(?:/.*)?'
+    _TEST = {
+        u'url': u'http://videopremium.tv/4w7oadjsf156',
+        u'file': u'4w7oadjsf156.f4v',
+        u'info_dict': {
+            u"title": u"youtube-dl_test_video____a_________-BaW_jenozKc.mp4.mp4"
+        },
+        u'params': {
+            u'skip_download': True,
+        },
+    }
+
+    def _real_extract(self, url):
+        mobj = re.match(self._VALID_URL, url)
+
+        video_id = mobj.group('id')
+        webpage_url = 'http://videopremium.tv/' + video_id
+        webpage = self._download_webpage(webpage_url, video_id)
+
+        self.report_extraction(video_id)
+
+        video_title = self._html_search_regex(r'<h2(?:.*?)>\s*(.+?)\s*<',
+            webpage, u'video title')
+
+        return [{
+            'id':          video_id,
+            'url':         "rtmp://e%d.md.iplay.md/play" % random.randint(1, 16),
+            'play_path':   "mp4:%s.f4v" % video_id,
+            'page_url':    "http://videopremium.tv/" + video_id,
+            'player_url':  "http://videopremium.tv/uplayer/uppod.swf",
+            'ext':         'f4v',
+            'title':       video_title,
+        }]
index 4a7d82b7adfb90e337ff17d9f90d731612650ec6..1125513c7b0cd443becb2847acb9db9032303dfb 100644 (file)
@@ -11,13 +11,14 @@ from ..utils import (
     get_element_by_attribute,
     ExtractorError,
     std_headers,
+    unsmuggle_url,
 )
 
 class VimeoIE(InfoExtractor):
     """Information extractor for vimeo.com."""
 
     # _VALID_URL matches Vimeo URLs
-    _VALID_URL = r'(?P<proto>https?://)?(?:(?:www|player)\.)?vimeo(?P<pro>pro)?\.com/(?:(?:(?:groups|album)/[^/]+)|(?:.*?)/)?(?P<direct_link>play_redirect_hls\?clip_id=)?(?:videos?/)?(?P<id>[0-9]+)(?:[?].*)?$'
+    _VALID_URL = r'(?P<proto>https?://)?(?:(?:www|player)\.)?vimeo(?P<pro>pro)?\.com/(?:(?:(?:groups|album)/[^/]+)|(?:.*?)/)?(?P<direct_link>play_redirect_hls\?clip_id=)?(?:videos?/)?(?P<id>[0-9]+)/?(?:[?].*)?$'
     _NETRC_MACHINE = 'vimeo'
     IE_NAME = u'vimeo'
     _TESTS = [
@@ -53,7 +54,7 @@ class VimeoIE(InfoExtractor):
                 u'title': u'Kathy Sierra: Building the minimum Badass User, Business of Software',
                 u'uploader': u'The BLN & Business of Software',
             },
-        },
+        }
     ]
 
     def _login(self):
@@ -98,6 +99,12 @@ class VimeoIE(InfoExtractor):
         self._login()
 
     def _real_extract(self, url, new_video=True):
+        url, data = unsmuggle_url(url)
+        headers = std_headers
+        if data is not None:
+            headers = headers.copy()
+            headers.update(data)
+
         # Extract ID from URL
         mobj = re.match(self._VALID_URL, url)
         if mobj is None:
@@ -112,7 +119,7 @@ class VimeoIE(InfoExtractor):
             url = 'https://vimeo.com/' + video_id
 
         # Retrieve video webpage to extract further information
-        request = compat_urllib_request.Request(url, None, std_headers)
+        request = compat_urllib_request.Request(url, None, headers)
         webpage = self._download_webpage(request, video_id)
 
         # Now we begin extracting as much information as we can from what we
@@ -172,46 +179,45 @@ class VimeoIE(InfoExtractor):
 
         # Vimeo specific: extract video codec and quality information
         # First consider quality, then codecs, then take everything
-        # TODO bind to format param
-        codecs = [('h264', 'mp4'), ('vp8', 'flv'), ('vp6', 'flv')]
+        codecs = [('vp6', 'flv'), ('vp8', 'flv'), ('h264', 'mp4')]
         files = { 'hd': [], 'sd': [], 'other': []}
         config_files = config["video"].get("files") or config["request"].get("files")
         for codec_name, codec_extension in codecs:
-            if codec_name in config_files:
-                if 'hd' in config_files[codec_name]:
-                    files['hd'].append((codec_name, codec_extension, 'hd'))
-                elif 'sd' in config_files[codec_name]:
-                    files['sd'].append((codec_name, codec_extension, 'sd'))
+            for quality in config_files.get(codec_name, []):
+                format_id = '-'.join((codec_name, quality)).lower()
+                key = quality if quality in files else 'other'
+                video_url = None
+                if isinstance(config_files[codec_name], dict):
+                    file_info = config_files[codec_name][quality]
+                    video_url = file_info.get('url')
                 else:
-                    files['other'].append((codec_name, codec_extension, config_files[codec_name][0]))
-
-        for quality in ('hd', 'sd', 'other'):
-            if len(files[quality]) > 0:
-                video_quality = files[quality][0][2]
-                video_codec = files[quality][0][0]
-                video_extension = files[quality][0][1]
-                self.to_screen(u'%s: Downloading %s file at %s quality' % (video_id, video_codec.upper(), video_quality))
-                break
-        else:
+                    file_info = {}
+                if video_url is None:
+                    video_url = "http://player.vimeo.com/play_redirect?clip_id=%s&sig=%s&time=%s&quality=%s&codecs=%s&type=moogaloop_local&embed_location=" \
+                        %(video_id, sig, timestamp, quality, codec_name.upper())
+
+                files[key].append({
+                    'ext': codec_extension,
+                    'url': video_url,
+                    'format_id': format_id,
+                    'width': file_info.get('width'),
+                    'height': file_info.get('height'),
+                })
+        formats = []
+        for key in ('other', 'sd', 'hd'):
+            formats += files[key]
+        if len(formats) == 0:
             raise ExtractorError(u'No known codec found')
 
-        video_url = None
-        if isinstance(config_files[video_codec], dict):
-            video_url = config_files[video_codec][video_quality].get("url")
-        if video_url is None:
-            video_url = "http://player.vimeo.com/play_redirect?clip_id=%s&sig=%s&time=%s&quality=%s&codecs=%s&type=moogaloop_local&embed_location=" \
-                        %(video_id, sig, timestamp, video_quality, video_codec.upper())
-
         return [{
             'id':       video_id,
-            'url':      video_url,
             'uploader': video_uploader,
             'uploader_id': video_uploader_id,
             'upload_date':  video_upload_date,
             'title':    video_title,
-            'ext':      video_extension,
             'thumbnail':    video_thumbnail,
             'description':  video_description,
+            'formats': formats,
         }]
 
 
diff --git a/youtube_dl/extractor/websurg.py b/youtube_dl/extractor/websurg.py
new file mode 100644 (file)
index 0000000..43953bf
--- /dev/null
@@ -0,0 +1,59 @@
+# coding: utf-8
+
+import re
+
+from ..utils import (
+    compat_urllib_request,
+    compat_urllib_parse
+)
+
+from .common import InfoExtractor
+
+class WeBSurgIE(InfoExtractor):
+    IE_NAME = u'websurg.com'
+    _VALID_URL = r'http://.*?\.websurg\.com/MEDIA/\?noheader=1&doi=(.*)'
+
+    _TEST = {
+        u'url': u'http://www.websurg.com/MEDIA/?noheader=1&doi=vd01en4012',
+        u'file': u'vd01en4012.mp4',
+        u'params': {
+            u'skip_download': True,
+        },
+        u'skip': u'Requires login information',
+    }
+    
+    _LOGIN_URL = 'http://www.websurg.com/inc/login/login_div.ajax.php?login=1'
+
+    def _real_initialize(self):
+
+        login_form = {
+            'username': self._downloader.params['username'],
+            'password': self._downloader.params['password'],
+            'Submit': 1
+        }
+        
+        request = compat_urllib_request.Request(
+            self._LOGIN_URL, compat_urllib_parse.urlencode(login_form))
+        request.add_header(
+            'Content-Type', 'application/x-www-form-urlencoded;charset=utf-8')
+        compat_urllib_request.urlopen(request).info()
+        webpage = self._download_webpage(self._LOGIN_URL, '', 'Logging in')
+        
+        if webpage != 'OK':
+            self._downloader.report_error(
+                u'Unable to log in: bad username/password')
+        
+    def _real_extract(self, url):
+        video_id = re.match(self._VALID_URL, url).group(1)
+        
+        webpage = self._download_webpage(url, video_id)
+        
+        url_info = re.search(r'streamer="(.*?)" src="(.*?)"', webpage)
+        
+        return {'id': video_id,
+                'title': self._og_search_title(webpage),
+                'description': self._og_search_description(webpage),
+                'ext' : 'mp4',
+                'url' : url_info.group(1) + '/' + url_info.group(2),
+                'thumbnail': self._og_search_thumbnail(webpage)
+                }
index 361619694980d3260ff81aeed2d0d07294739a0e..81c4be3269150aafc72f6ff0980923119c299373 100644 (file)
@@ -19,7 +19,8 @@ class XHamsterIE(InfoExtractor):
         u'info_dict': {
             u"upload_date": u"20121014", 
             u"uploader_id": u"Ruseful2011", 
-            u"title": u"FemaleAgent Shy beauty takes the bait"
+            u"title": u"FemaleAgent Shy beauty takes the bait",
+            u"age_limit": 18,
         }
     },
     {
@@ -27,9 +28,10 @@ class XHamsterIE(InfoExtractor):
         u'file': u'2221348.flv',
         u'md5': u'e767b9475de189320f691f49c679c4c7',
         u'info_dict': {
-            u"upload_date": u"20130914", 
-            u"uploader_id": u"jojo747400", 
-            u"title": u"Britney Spears  Sexy Booty"
+            u"upload_date": u"20130914",
+            u"uploader_id": u"jojo747400",
+            u"title": u"Britney Spears  Sexy Booty",
+            u"age_limit": 18,
         }
     }]
 
@@ -72,6 +74,8 @@ class XHamsterIE(InfoExtractor):
         video_thumbnail = self._search_regex(r'\'image\':\'(?P<thumbnail>[^\']+)\'',
             webpage, u'thumbnail', fatal=False)
 
+        age_limit = self._rta_search(webpage)
+
         return [{
             'id':       video_id,
             'url':      video_url,
@@ -80,5 +84,6 @@ class XHamsterIE(InfoExtractor):
             'description': video_description,
             'upload_date': video_upload_date,
             'uploader_id': video_uploader_id,
-            'thumbnail': video_thumbnail
+            'thumbnail': video_thumbnail,
+            'age_limit': age_limit,
         }]
index 40d8489000bb7a25f277c84d6d407b72ce778c8d..8a0eb1afdacc4cbe1cbb441b939cff3d7697cf4e 100644 (file)
@@ -18,7 +18,8 @@ class XNXXIE(InfoExtractor):
         u'file': u'1135332.flv',
         u'md5': u'0831677e2b4761795f68d417e0b7b445',
         u'info_dict': {
-            u"title": u"lida \u00bb Naked Funny Actress  (5)"
+            u"title": u"lida \u00bb Naked Funny Actress  (5)",
+            u"age_limit": 18,
         }
     }
 
@@ -50,4 +51,5 @@ class XNXXIE(InfoExtractor):
             'ext': 'flv',
             'thumbnail': video_thumbnail,
             'description': None,
+            'age_limit': 18,
         }]
index c3b9736d70a7af6fb90cd617312d25fd2d7cc740..90138d7e523a405c20bae8352c6233b5868860f5 100644 (file)
@@ -13,7 +13,8 @@ class XVideosIE(InfoExtractor):
         u'file': u'939581.flv',
         u'md5': u'1d0c835822f0a71a7bf011855db929d0',
         u'info_dict': {
-            u"title": u"Funny Porns By >>>>S<<<<<< -1"
+            u"title": u"Funny Porns By >>>>S<<<<<< -1",
+            u"age_limit": 18,
         }
     }
 
@@ -46,6 +47,7 @@ class XVideosIE(InfoExtractor):
             'ext': 'flv',
             'thumbnail': video_thumbnail,
             'description': None,
+            'age_limit': 18,
         }
 
         return [info]
index 39126e6316dda1fa5a13059e482fb8b0c059cf50..464b498f584c3e42b613a79589b52a4d32fec413 100644 (file)
@@ -17,17 +17,21 @@ class YahooIE(InfoExtractor):
     _TESTS = [
         {
             u'url': u'http://screen.yahoo.com/julian-smith-travis-legg-watch-214727115.html',
-            u'file': u'214727115.mp4',
+            u'file': u'214727115.flv',
             u'info_dict': {
                 u'title': u'Julian Smith & Travis Legg Watch Julian Smith',
                 u'description': u'Julian and Travis watch Julian Smith',
             },
+            u'params': {
+                # Requires rtmpdump
+                u'skip_download': True,
+            },
         },
         {
             u'url': u'http://screen.yahoo.com/wired/codefellas-s1-ep12-cougar-lies-103000935.html',
             u'file': u'103000935.flv',
             u'info_dict': {
-                u'title': u'The Cougar Lies with Spanish Moss',
+                u'title': u'Codefellas - The Cougar Lies with Spanish Moss',
                 u'description': u'Agent Topple\'s mustache does its dirty work, and Nicole brokers a deal for peace. But why is the NSA collecting millions of Instagram brunch photos? And if your waffles have nothing to hide, what are they so worried about?',
             },
             u'params': {
@@ -46,6 +50,21 @@ class YahooIE(InfoExtractor):
             webpage, u'items', flags=re.MULTILINE)
         items = json.loads(items_json)
         info = items['mediaItems']['query']['results']['mediaObj'][0]
+        # The 'meta' field is not always in the video webpage, we request it
+        # from another page
+        long_id = info['id']
+        query = ('SELECT * FROM yahoo.media.video.streams WHERE id="%s"'
+                 ' AND plrs="86Gj0vCaSzV_Iuf6hNylf2"' % long_id)
+        data = compat_urllib_parse.urlencode({
+            'q': query,
+            'env': 'prod',
+            'format': 'json',
+        })
+        query_result_json = self._download_webpage(
+            'http://video.query.yahoo.com/v1/public/yql?' + data,
+            video_id, u'Downloading video info')
+        query_result = json.loads(query_result_json)
+        info = query_result['query']['results']['mediaObj'][0]
         meta = info['meta']
 
         formats = []
index 00fa2ccb5469329685a00ada37194219c31cb79f..9d88c17f52a25091ea045d2ea0dd6f819da93473 100644 (file)
@@ -13,7 +13,7 @@ from ..utils import (
 
 
 class YoukuIE(InfoExtractor):
-    _VALID_URL =  r'(?:http://)?(v|player)\.youku\.com/(v_show/id_|player\.php/sid/)(?P<ID>[A-Za-z0-9]+)(\.html|/v.swf)'
+    _VALID_URL =  r'(?:(?:http://)?(?:v|player)\.youku\.com/(?:v_show/id_|player\.php/sid/)|youku:)(?P<ID>[A-Za-z0-9]+)(?:\.html|/v\.swf|)'
     _TEST =   {
         u"url": u"http://v.youku.com/v_show/id_XNDgyMDQ2NTQw.html",
         u"file": u"XNDgyMDQ2NTQw_part00.flv",
index c85fd4b5af0ccdd3f259bd403ddd4311f2de5fdb..e3b56cece6bd9d8bebfe3cfffe7a1aefe2614131 100644 (file)
@@ -26,7 +26,8 @@ class YouPornIE(InfoExtractor):
             u"upload_date": u"20101221", 
             u"description": u"Love & Sex Answers: http://bit.ly/DanAndJenn -- Is It Unhealthy To Masturbate Daily?", 
             u"uploader": u"Ask Dan And Jennifer", 
-            u"title": u"Sex Ed: Is It Safe To Masturbate Daily?"
+            u"title": u"Sex Ed: Is It Safe To Masturbate Daily?",
+            u"age_limit": 18,
         }
     }
 
@@ -51,6 +52,7 @@ class YouPornIE(InfoExtractor):
         req = compat_urllib_request.Request(url)
         req.add_header('Cookie', 'age_verified=1')
         webpage = self._download_webpage(req, video_id)
+        age_limit = self._rta_search(webpage)
 
         # Get JSON parameters
         json_params = self._search_regex(r'var currentVideo = new Video\((.*)\);', webpage, u'JSON parameters')
@@ -115,7 +117,8 @@ class YouPornIE(InfoExtractor):
                 'ext': extension,
                 'format': format,
                 'thumbnail': thumbnail,
-                'description': video_description
+                'description': video_description,
+                'age_limit': age_limit,
             })
 
         if self._downloader.params.get('listformats', None):
index 9ca29a043f677a9d020c9aa3bde1b008ebadf6d2..a88cba2b4d74d2f57d0b781ab8e608e693c1caa2 100644 (file)
@@ -1037,12 +1037,13 @@ class YoutubeIE(YoutubeBaseInfoExtractor, SubtitlesInfoExtractor):
 
         if player_url is not None:
             try:
-                if player_url not in self._player_cache:
+                player_id = (player_url, len(s))
+                if player_id not in self._player_cache:
                     func = self._extract_signature_function(
                         video_id, player_url, len(s)
                     )
-                    self._player_cache[player_url] = func
-                func = self._player_cache[player_url]
+                    self._player_cache[player_id] = func
+                func = self._player_cache[player_id]
                 if self._downloader.params.get('youtube_print_sig_code'):
                     self._print_sig_code(func, len(s))
                 return func(s)
@@ -1087,7 +1088,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor, SubtitlesInfoExtractor):
         elif len(s) == 83:
             return s[80:63:-1] + s[0] + s[62:0:-1] + s[63]
         elif len(s) == 82:
-            return s[12] + s[79:12:-1] + s[80] + s[11::-1]
+            return s[80:37:-1] + s[7] + s[36:7:-1] + s[0] + s[6:0:-1] + s[37]
         elif len(s) == 81:
             return s[56] + s[79:56:-1] + s[41] + s[55:41:-1] + s[80] + s[40:34:-1] + s[0] + s[33:29:-1] + s[34] + s[28:9:-1] + s[29] + s[8:0:-1] + s[9]
         elif len(s) == 80:
@@ -1115,6 +1116,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor, SubtitlesInfoExtractor):
                 'lang': lang,
                 'v': video_id,
                 'fmt': self._downloader.params.get('subtitlesformat'),
+                'name': l[0],
             })
             url = u'http://www.youtube.com/api/timedtext?' + params
             sub_lang_list[lang] = url
@@ -1148,7 +1150,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor, SubtitlesInfoExtractor):
             list_page = self._download_webpage(list_url, video_id)
             caption_list = xml.etree.ElementTree.fromstring(list_page.encode('utf-8'))
             original_lang_node = caption_list.find('track')
-            if original_lang_node.attrib.get('kind') != 'asr' :
+            if original_lang_node is None or original_lang_node.attrib.get('kind') != 'asr' :
                 self._downloader.report_warning(u'Video doesn\'t have automatic captions')
                 return {}
             original_lang = original_lang_node.attrib['lang_code']
@@ -1248,10 +1250,11 @@ class YoutubeIE(YoutubeBaseInfoExtractor, SubtitlesInfoExtractor):
             url_map[itag] = format_url
         return url_map
 
-    def _real_extract(self, url):
-        if re.match(r'(?:https?://)?[^/]+/watch\?feature=[a-z_]+$', url):
-            self._downloader.report_warning(u'Did you forget to quote the URL? Remember that & is a meta-character in most shells, so you want to put the URL in quotes, like  youtube-dl \'http://www.youtube.com/watch?feature=foo&v=BaW_jenozKc\' (or simply  youtube-dl BaW_jenozKc  ).')
+    def _extract_annotations(self, video_id):
+        url = 'https://www.youtube.com/annotations_invideo?features=1&legacy=1&video_id=%s' % video_id
+        return self._download_webpage(url, video_id, note=u'Searching for annotations.', errnote=u'Unable to download video annotations.')
 
+    def _real_extract(self, url):
         # Extract original video URL from URL with redirection, like age verification, using next_url parameter
         mobj = re.search(self._NEXT_URL_RE, url)
         if mobj:
@@ -1383,6 +1386,11 @@ class YoutubeIE(YoutubeBaseInfoExtractor, SubtitlesInfoExtractor):
         else:
             video_duration = compat_urllib_parse.unquote_plus(video_info['length_seconds'][0])
 
+        # annotations
+        video_annotations = None
+        if self._downloader.params.get('writeannotations', False):
+                video_annotations = self._extract_annotations(video_id)
+
         # Decide which formats to download
 
         try:
@@ -1494,7 +1502,9 @@ class YoutubeIE(YoutubeBaseInfoExtractor, SubtitlesInfoExtractor):
                 'description':  video_description,
                 'player_url':   player_url,
                 'subtitles':    video_subtitles,
-                'duration':     video_duration
+                'duration':     video_duration,
+                'age_limit':    18 if age_gate else 0,
+                'annotations':  video_annotations
             })
         return results
 
@@ -1635,7 +1645,7 @@ class YoutubeChannelIE(InfoExtractor):
 
 class YoutubeUserIE(InfoExtractor):
     IE_DESC = u'YouTube.com user videos (URL or "ytuser" keyword)'
-    _VALID_URL = r'(?:(?:(?:https?://)?(?:\w+\.)?youtube\.com/(?:user/)?)|ytuser:)(?!feed/)([A-Za-z0-9_-]+)'
+    _VALID_URL = r'(?:(?:(?:https?://)?(?:\w+\.)?youtube\.com/(?:user/)?(?!(?:attribution_link|watch)(?:$|[^a-z_A-Z0-9-])))|ytuser:)(?!feed/)([A-Za-z0-9_-]+)'
     _TEMPLATE_URL = 'http://gdata.youtube.com/feeds/api/users/%s'
     _GDATA_PAGE_SIZE = 50
     _GDATA_URL = 'http://gdata.youtube.com/feeds/api/users/%s/uploads?max-results=%d&start-index=%d&alt=json'
@@ -1828,3 +1838,18 @@ class YoutubeFavouritesIE(YoutubeBaseInfoExtractor):
         webpage = self._download_webpage('https://www.youtube.com/my_favorites', 'Youtube Favourites videos')
         playlist_id = self._search_regex(r'list=(.+?)["&]', webpage, u'favourites playlist id')
         return self.url_result(playlist_id, 'YoutubePlaylist')
+
+
+class YoutubeTruncatedURLIE(InfoExtractor):
+    IE_NAME = 'youtube:truncated_url'
+    IE_DESC = False  # Do not list
+    _VALID_URL = r'(?:https?://)?[^/]+/watch\?feature=[a-z_]+$'
+
+    def _real_extract(self, url):
+        raise ExtractorError(
+            u'Did you forget to quote the URL? Remember that & is a meta '
+            u'character in most shells, so you want to put the URL in quotes, '
+            u'like  youtube-dl '
+            u'\'http://www.youtube.com/watch?feature=foo&v=BaW_jenozKc\''
+            u' (or simply  youtube-dl BaW_jenozKc  ).',
+            expected=True)
index f5f9cde99b0c65363a098923e4c350182896f7f1..bfb8f6bcd971dad03d5236c8e607b59ff81c667a 100644 (file)
@@ -9,6 +9,7 @@ import io
 import json
 import locale
 import os
+import pipes
 import platform
 import re
 import socket
@@ -175,7 +176,7 @@ def compat_ord(c):
 compiled_regex_type = type(re.compile(''))
 
 std_headers = {
-    'User-Agent': 'Mozilla/5.0 (X11; Linux x86_64; rv:10.0) Gecko/20100101 Firefox/10.0',
+    'User-Agent': 'Mozilla/5.0 (X11; Linux x86_64; rv:10.0) Gecko/20100101 Firefox/10.0 (Chrome)',
     'Accept-Charset': 'ISO-8859-1,utf-8;q=0.7,*;q=0.7',
     'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
     'Accept-Encoding': 'gzip, deflate',
@@ -229,6 +230,19 @@ else:
                 return f
         return None
 
+# On python2.6 the xml.etree.ElementTree.Element methods don't support
+# the namespace parameter
+def xpath_with_ns(path, ns_map):
+    components = [c.split(':') for c in path.split('/')]
+    replaced = []
+    for c in components:
+        if len(c) == 1:
+            replaced.append(c[0])
+        else:
+            ns, tag = c
+            replaced.append('{%s}%s' % (ns_map[ns], tag))
+    return '/'.join(replaced)
+
 def htmlentity_transform(matchobj):
     """Transforms an HTML entity to a character.
 
@@ -715,6 +729,7 @@ def unified_strdate(date_str):
         '%Y/%m/%d %H:%M:%S',
         '%d.%m.%Y %H:%M',
         '%Y-%m-%dT%H:%M:%SZ',
+        '%Y-%m-%dT%H:%M:%S',
     ]
     for expression in format_expressions:
         try:
@@ -830,3 +845,129 @@ def get_cachedir(params={}):
     cache_root = os.environ.get('XDG_CACHE_HOME',
                                 os.path.expanduser('~/.cache'))
     return params.get('cachedir', os.path.join(cache_root, 'youtube-dl'))
+
+
+# Cross-platform file locking
+if sys.platform == 'win32':
+    import ctypes.wintypes
+    import msvcrt
+
+    class OVERLAPPED(ctypes.Structure):
+        _fields_ = [
+            ('Internal', ctypes.wintypes.LPVOID),
+            ('InternalHigh', ctypes.wintypes.LPVOID),
+            ('Offset', ctypes.wintypes.DWORD),
+            ('OffsetHigh', ctypes.wintypes.DWORD),
+            ('hEvent', ctypes.wintypes.HANDLE),
+        ]
+
+    kernel32 = ctypes.windll.kernel32
+    LockFileEx = kernel32.LockFileEx
+    LockFileEx.argtypes = [
+        ctypes.wintypes.HANDLE,     # hFile
+        ctypes.wintypes.DWORD,      # dwFlags
+        ctypes.wintypes.DWORD,      # dwReserved
+        ctypes.wintypes.DWORD,      # nNumberOfBytesToLockLow
+        ctypes.wintypes.DWORD,      # nNumberOfBytesToLockHigh
+        ctypes.POINTER(OVERLAPPED)  # Overlapped
+    ]
+    LockFileEx.restype = ctypes.wintypes.BOOL
+    UnlockFileEx = kernel32.UnlockFileEx
+    UnlockFileEx.argtypes = [
+        ctypes.wintypes.HANDLE,     # hFile
+        ctypes.wintypes.DWORD,      # dwReserved
+        ctypes.wintypes.DWORD,      # nNumberOfBytesToLockLow
+        ctypes.wintypes.DWORD,      # nNumberOfBytesToLockHigh
+        ctypes.POINTER(OVERLAPPED)  # Overlapped
+    ]
+    UnlockFileEx.restype = ctypes.wintypes.BOOL
+    whole_low = 0xffffffff
+    whole_high = 0x7fffffff
+
+    def _lock_file(f, exclusive):
+        overlapped = OVERLAPPED()
+        overlapped.Offset = 0
+        overlapped.OffsetHigh = 0
+        overlapped.hEvent = 0
+        f._lock_file_overlapped_p = ctypes.pointer(overlapped)
+        handle = msvcrt.get_osfhandle(f.fileno())
+        if not LockFileEx(handle, 0x2 if exclusive else 0x0, 0,
+                          whole_low, whole_high, f._lock_file_overlapped_p):
+            raise OSError('Locking file failed: %r' % ctypes.FormatError())
+
+    def _unlock_file(f):
+        assert f._lock_file_overlapped_p
+        handle = msvcrt.get_osfhandle(f.fileno())
+        if not UnlockFileEx(handle, 0,
+                            whole_low, whole_high, f._lock_file_overlapped_p):
+            raise OSError('Unlocking file failed: %r' % ctypes.FormatError())
+
+else:
+    import fcntl
+
+    def _lock_file(f, exclusive):
+        fcntl.lockf(f, fcntl.LOCK_EX if exclusive else fcntl.LOCK_SH)
+
+    def _unlock_file(f):
+        fcntl.lockf(f, fcntl.LOCK_UN)
+
+
+class locked_file(object):
+    def __init__(self, filename, mode, encoding=None):
+        assert mode in ['r', 'a', 'w']
+        self.f = io.open(filename, mode, encoding=encoding)
+        self.mode = mode
+
+    def __enter__(self):
+        exclusive = self.mode != 'r'
+        try:
+            _lock_file(self.f, exclusive)
+        except IOError:
+            self.f.close()
+            raise
+        return self
+
+    def __exit__(self, etype, value, traceback):
+        try:
+            _unlock_file(self.f)
+        finally:
+            self.f.close()
+
+    def __iter__(self):
+        return iter(self.f)
+
+    def write(self, *args):
+        return self.f.write(*args)
+
+    def read(self, *args):
+        return self.f.read(*args)
+
+
+def shell_quote(args):
+    return ' '.join(map(pipes.quote, args))
+
+
+def takewhile_inclusive(pred, seq):
+    """ Like itertools.takewhile, but include the latest evaluated element
+        (the first element so that Not pred(e)) """
+    for e in seq:
+        yield e
+        if not pred(e):
+            return
+
+
+def smuggle_url(url, data):
+    """ Pass additional data in a URL for internal use. """
+
+    sdata = compat_urllib_parse.urlencode(
+        {u'__youtubedl_smuggle': json.dumps(data)})
+    return url + u'#' + sdata
+
+
+def unsmuggle_url(smug_url):
+    if not '#__youtubedl_smuggle' in smug_url:
+        return smug_url, None
+    url, _, sdata = smug_url.rpartition(u'#')
+    jsond = compat_parse_qs(sdata)[u'__youtubedl_smuggle'][0]
+    data = json.loads(jsond)
+    return url, data
index e773e82dae44d0b8099aeead68b9ec3103b91294..a5b56d894093a772b31a3bd89c5058dd9f2725de 100644 (file)
@@ -1,2 +1,2 @@
 
-__version__ = '2013.10.04'
+__version__ = '2013.10.23'