From: ScottDowne Date: Wed, 2 Mar 2011 17:34:54 +0000 (-0500) Subject: [#378] subtitle position fix X-Git-Tag: v0.4~21^2 X-Git-Url: http://git.khamidou.com/?a=commitdiff_plain;h=2c11117c3a0cc5293d75f7c5cfa76595b8b7ffaa;p=popcorn-js.git [#378] subtitle position fix --- diff --git a/plugins/subtitle/popcorn.subtitle.js b/plugins/subtitle/popcorn.subtitle.js index 27ad26b..601b261 100644 --- a/plugins/subtitle/popcorn.subtitle.js +++ b/plugins/subtitle/popcorn.subtitle.js @@ -34,17 +34,6 @@ } ); }; - -/* - // Find element offset - if (element.offsetParent) { - do { - offsetX += element.offsetLeft; - offsetY += element.offsetTop; - } while ((element = element.offsetParent)); - } -*/ - Popcorn.plugin( "subtitle" , { manifest: { @@ -80,7 +69,7 @@ this.container.style.top = offset( this.video ).top + this.video.offsetHeight - 65 + "px"; this.container.style.left = offset( this.video ).left + "px"; - this.video.parentNode.appendChild( this.container ); + document.body.appendChild( this.container ); } // if a target is specified, use that