enjoy your embedded mode
git-svn-id: http://yolanda.mister-muffin.de/svn@348 7eef14d0-6ed0-489d-bf55-20463b2d70db
This commit is contained in:
parent
0f896875c4
commit
90762a2326
4 changed files with 102 additions and 90 deletions
|
@ -1,21 +1,35 @@
|
||||||
body
|
body
|
||||||
{
|
{
|
||||||
font-family: sans-serif;
|
margin: 0px;
|
||||||
font-size: 8pt;
|
padding: 0px;
|
||||||
font-weight: bold;
|
|
||||||
overflow: visible;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
div.watch-browserplugin, div.watch-cortadoapplet
|
form
|
||||||
{
|
{
|
||||||
float: left;
|
height: 100%;
|
||||||
text-align: left;
|
width: 100%;
|
||||||
width: 50%;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
div.embedded-backlink
|
button
|
||||||
{
|
{
|
||||||
float: right;
|
/* crude center hack */
|
||||||
text-align: right;
|
position: absolute;
|
||||||
width: 50%;
|
top: 50%;
|
||||||
|
left: 50%;
|
||||||
|
width: 15em;
|
||||||
|
height: 15em;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
button[name="playback"]
|
||||||
|
{
|
||||||
|
/* crude center hack */
|
||||||
|
margin-left: -15em;
|
||||||
|
margin-top: -7.5em;
|
||||||
|
}
|
||||||
|
|
||||||
|
button[name="download"]
|
||||||
|
{
|
||||||
|
/* crude center hack */
|
||||||
|
margin-left: 0em;
|
||||||
|
margin-top: -7.5em;
|
||||||
|
}
|
||||||
|
|
|
@ -178,7 +178,7 @@ form ol
|
||||||
|
|
||||||
#preview form button
|
#preview form button
|
||||||
{
|
{
|
||||||
/* crude center hack (second part in bridget.css) */
|
/* crude center hack */
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 50%;
|
top: 50%;
|
||||||
left: 50%;
|
left: 50%;
|
||||||
|
@ -188,14 +188,14 @@ form ol
|
||||||
|
|
||||||
#preview form button[name="playback"]
|
#preview form button[name="playback"]
|
||||||
{
|
{
|
||||||
/* crude center hack (second part in fake6.css) */
|
/* crude center hack */
|
||||||
margin-left: -15em;
|
margin-left: -15em;
|
||||||
margin-top: -7.5em;
|
margin-top: -7.5em;
|
||||||
}
|
}
|
||||||
|
|
||||||
#preview form button[name="download"]
|
#preview form button[name="download"]
|
||||||
{
|
{
|
||||||
/* crude center hack (second part in fake6.css) */
|
/* crude center hack */
|
||||||
margin-left: 0em;
|
margin-left: 0em;
|
||||||
margin-top: -7.5em;
|
margin-top: -7.5em;
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,91 +32,89 @@
|
||||||
|
|
||||||
<xsl:template match="/">
|
<xsl:template match="/">
|
||||||
<html>
|
<html>
|
||||||
<body>
|
|
||||||
|
|
||||||
<script type="text/javascript">
|
<head>
|
||||||
|
|
||||||
<!--
|
<link
|
||||||
this looks awfully ugly, but nevertheless generates javascript inside _valid_ XHTML
|
rel="stylesheet"
|
||||||
kudos to toby white who details the solution on http://scispace.net/tow21/weblog/718.html
|
type="text/css"
|
||||||
-->
|
media="screen"
|
||||||
|
href="/style/embedded.css"
|
||||||
|
/>
|
||||||
|
|
||||||
<xsl:text disable-output-escaping="yes"><![CDATA[
|
</head>
|
||||||
<![CDATA[
|
|
||||||
|
|
||||||
function hide_movie()
|
<body onload="hide_movie()">
|
||||||
{
|
|
||||||
document.getElementById('video').style.display = 'none';
|
|
||||||
document.getElementById('preview').style.display = 'block';
|
|
||||||
}
|
|
||||||
|
|
||||||
function show_movie()
|
<xsl:call-template name="video-script" />
|
||||||
{
|
|
||||||
document.getElementById('video').style.display = 'block';
|
|
||||||
document.getElementById('preview').style.display = 'none';
|
|
||||||
window.setTimeout("hide_movie()",
|
|
||||||
]]>
|
|
||||||
</xsl:text>
|
|
||||||
<!--
|
|
||||||
window.setTimeout is the stupidest hack i could imagine
|
|
||||||
it doesn't work reliably because of BUFFERING, but
|
|
||||||
3 seconds for initializing should be enough for short video ...
|
|
||||||
-->
|
|
||||||
<xsl:value-of select="(//video/@duration + 3) * 1000" />
|
|
||||||
<xsl:text disable-output-escaping="yes">
|
|
||||||
<![CDATA[
|
|
||||||
);
|
|
||||||
}
|
|
||||||
]]]]></xsl:text>
|
|
||||||
<xsl:text disable-output-escaping="yes">></xsl:text>
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<!-- <xsl:call-template name="video-script" />-->
|
|
||||||
|
|
||||||
<xsl:call-template name="video-object" />
|
<xsl:call-template name="video-object" />
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
||||||
|
<xsl:template name="video-script">
|
||||||
|
|
||||||
|
<script type="text/javascript">
|
||||||
|
|
||||||
|
<!--
|
||||||
|
this looks awfully ugly, but nevertheless generates javascript inside _valid_ XHTML
|
||||||
|
kudos to toby white who details the solution on http://scispace.net/tow21/weblog/718.html
|
||||||
|
-->
|
||||||
|
|
||||||
|
<xsl:text disable-output-escaping="yes"><![CDATA[
|
||||||
|
<![CDATA[
|
||||||
|
|
||||||
|
function hide_movie()
|
||||||
|
{
|
||||||
|
document.getElementById('video').style.display = 'none';
|
||||||
|
document.getElementById('preview').style.display = 'block';
|
||||||
|
}
|
||||||
|
|
||||||
|
function show_movie()
|
||||||
|
{
|
||||||
|
document.getElementById('video').style.display = 'block';
|
||||||
|
document.getElementById('preview').style.display = 'none';
|
||||||
|
window.setTimeout("hide_movie()",
|
||||||
|
]]>
|
||||||
|
</xsl:text>
|
||||||
|
<!--
|
||||||
|
window.setTimeout is the stupidest hack i could imagine
|
||||||
|
it doesn't work reliably because of BUFFERING, but
|
||||||
|
3 seconds for initializing should be enough for short video ...
|
||||||
|
-->
|
||||||
|
<xsl:value-of select="(//video/@duration + 3) * 1000" />
|
||||||
|
<xsl:text disable-output-escaping="yes">
|
||||||
|
<![CDATA[
|
||||||
|
);
|
||||||
|
}
|
||||||
|
]]]]></xsl:text>
|
||||||
|
<xsl:text disable-output-escaping="yes">></xsl:text>
|
||||||
|
</script>
|
||||||
|
|
||||||
|
</xsl:template>
|
||||||
|
|
||||||
<xsl:template name="video-object">
|
<xsl:template name="video-object">
|
||||||
|
|
||||||
<fieldset id="video">
|
<object id="video" type="application/ogg">
|
||||||
|
|
||||||
<legend>
|
<xsl:attribute name="width">
|
||||||
<!-- <xsl:value-of select="$lang_strings[@id='fieldset_video']" />-->
|
<xsl:value-of select="//video/@width" />
|
||||||
</legend>
|
</xsl:attribute>
|
||||||
|
<xsl:attribute name="height">
|
||||||
|
<xsl:value-of select="//video/@height" />
|
||||||
|
</xsl:attribute>
|
||||||
|
<xsl:attribute name="data">
|
||||||
|
<xsl:value-of select="concat(//video/rdf:RDF/cc:Work/@rdf:about,'view=true')" />
|
||||||
|
</xsl:attribute>
|
||||||
|
|
||||||
<object id="video" type="application/ogg">
|
enjoy your NOT OGG
|
||||||
|
|
||||||
<xsl:attribute name="width">
|
</object>
|
||||||
<xsl:value-of select="//video/@width" />
|
|
||||||
</xsl:attribute>
|
|
||||||
<xsl:attribute name="height">
|
|
||||||
<xsl:value-of select="//video/@height" />
|
|
||||||
</xsl:attribute>
|
|
||||||
<xsl:attribute name="data">
|
|
||||||
<xsl:value-of select="concat(//video/rdf:RDF/cc:Work/@rdf:about,'view=true')" />
|
|
||||||
</xsl:attribute>
|
|
||||||
|
|
||||||
<fieldset class="messagebox" id="error">
|
<div id="preview">
|
||||||
|
|
||||||
<span class="message">
|
|
||||||
<!-- <xsl:value-of select="$lang_strings[@id='error_no_ogg_plugin']" />-->
|
|
||||||
</span>
|
|
||||||
</fieldset>
|
|
||||||
|
|
||||||
<xsl:call-template name="pluginhelp" />
|
|
||||||
|
|
||||||
</object>
|
|
||||||
|
|
||||||
</fieldset>
|
|
||||||
|
|
||||||
<fieldset id="preview" style="display: none;">
|
|
||||||
|
|
||||||
<legend>
|
|
||||||
<!-- <xsl:value-of select="$lang_strings[@id='fieldset_preview']" />-->
|
|
||||||
</legend>
|
|
||||||
|
|
||||||
<img>
|
<img>
|
||||||
<xsl:attribute name="src">
|
<xsl:attribute name="src">
|
||||||
|
@ -143,11 +141,11 @@ kudos to toby white who details the solution on http://scispace.net/tow21/weblog
|
||||||
onclick="show_movie()"
|
onclick="show_movie()"
|
||||||
>
|
>
|
||||||
<xsl:attribute name="value">
|
<xsl:attribute name="value">
|
||||||
<!-- <xsl:value-of select="$lang_strings[@id='video_playback']" />-->
|
<!-- <xsl:value-of select="$lang_strings[@id='video_playback']" />-->
|
||||||
</xsl:attribute>
|
</xsl:attribute>
|
||||||
<img src="/images/tango/128x128/actions/player_play.png">
|
<img src="/images/tango/128x128/actions/player_play.png">
|
||||||
<xsl:attribute name="alt">
|
<xsl:attribute name="alt">
|
||||||
<!-- <xsl:value-of select="$lang_strings[@id='video_playback']" />-->
|
<!-- <xsl:value-of select="$lang_strings[@id='video_playback']" />-->
|
||||||
</xsl:attribute>
|
</xsl:attribute>
|
||||||
</img>
|
</img>
|
||||||
</button>
|
</button>
|
||||||
|
@ -156,17 +154,17 @@ kudos to toby white who details the solution on http://scispace.net/tow21/weblog
|
||||||
type="submit"
|
type="submit"
|
||||||
>
|
>
|
||||||
<xsl:attribute name="value">
|
<xsl:attribute name="value">
|
||||||
<!-- <xsl:value-of select="$lang_strings[@id='video_download']" />-->
|
<!-- <xsl:value-of select="$lang_strings[@id='video_download']" />-->
|
||||||
</xsl:attribute>
|
</xsl:attribute>
|
||||||
<img src="/images/tango/128x128/actions/document-save.png">
|
<img src="/images/tango/128x128/actions/document-save.png">
|
||||||
<xsl:attribute name="alt">
|
<xsl:attribute name="alt">
|
||||||
<!-- <xsl:value-of select="$lang_strings[@id='video_download']" />-->
|
<!-- <xsl:value-of select="$lang_strings[@id='video_download']" />-->
|
||||||
</xsl:attribute>
|
</xsl:attribute>
|
||||||
</img>
|
</img>
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
</fieldset>
|
</div>
|
||||||
|
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
||||||
|
|
|
@ -421,10 +421,10 @@ filesize
|
||||||
<xsl:value-of select="$lang_strings[@id='protip_embed']" />
|
<xsl:value-of select="$lang_strings[@id='protip_embed']" />
|
||||||
<br />
|
<br />
|
||||||
<code>
|
<code>
|
||||||
<object data="<xsl:value-of select="concat(//rdf:RDF/cc:Work/dc:identifier, 'embed=true')" />"
|
<object data="<xsl:value-of select="concat(//rdf:RDF/cc:Work/dc:identifier, 'xslt=xhtml-embed')" />"
|
||||||
type="application/xml"
|
type="application/xml"
|
||||||
width=<xsl:value-of select="//video/@width + 24" />
|
width="<xsl:value-of select="//video/@width" />"
|
||||||
height=<xsl:value-of select="//video/@height + 48" />
|
height="<xsl:value-of select="//video/@height + 16" />"
|
||||||
/>
|
/>
|
||||||
</code>
|
</code>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
Loading…
Reference in a new issue