diff options
Diffstat (limited to 'mediagoblin')
-rw-r--r-- | mediagoblin/static/css/base.css | 2 | ||||
l--------- | mediagoblin/static/extlib/video-js | 1 | ||||
l--------- | mediagoblin/static/js/extlib/video-js | 1 | ||||
-rw-r--r-- | mediagoblin/templates/mediagoblin/media_displays/video.html | 46 |
4 files changed, 23 insertions, 27 deletions
diff --git a/mediagoblin/static/css/base.css b/mediagoblin/static/css/base.css index f06b0af7..2085cfc9 100644 --- a/mediagoblin/static/css/base.css +++ b/mediagoblin/static/css/base.css @@ -168,7 +168,7 @@ footer { width: 640px; margin-left: 0px; margin-right: 10px; - float: left; + float: left; } .media_sidebar { diff --git a/mediagoblin/static/extlib/video-js b/mediagoblin/static/extlib/video-js new file mode 120000 index 00000000..65652d6e --- /dev/null +++ b/mediagoblin/static/extlib/video-js @@ -0,0 +1 @@ +../../../extlib/video-js/
\ No newline at end of file diff --git a/mediagoblin/static/js/extlib/video-js b/mediagoblin/static/js/extlib/video-js deleted file mode 120000 index 35da21ca..00000000 --- a/mediagoblin/static/js/extlib/video-js +++ /dev/null @@ -1 +0,0 @@ -../../../../extlib/video-js
\ No newline at end of file diff --git a/mediagoblin/templates/mediagoblin/media_displays/video.html b/mediagoblin/templates/mediagoblin/media_displays/video.html index d72de2ca..7d5ede8d 100644 --- a/mediagoblin/templates/mediagoblin/media_displays/video.html +++ b/mediagoblin/templates/mediagoblin/media_displays/video.html @@ -18,34 +18,30 @@ {% extends 'mediagoblin/user_pages/media.html' %} -{% block mediagoblin_head %} +{% block mediagoblin_head -%} {{ super() }} - <script type="text/javascript" - src="{{ request.staticdirect('/js/extlib/video-js/video.js') }}"></script> - <link href="{{ request.staticdirect('/css/vjs-mg-skin.css') }}" rel="stylesheet"> -{% endblock %} + <script type="text/javascript" src="{{ + request.staticdirect('/extlib/video-js/video.min.js') }}"></script> + <link href="{{ request.staticdirect('/css/vjs-mg-skin.css') + }}" rel="stylesheet"> +{%- endblock %} {% block mediagoblin_media %} - <div class="video-player" style="position: relative;"> - <video class="video-js vjs-mg-skin" - width="{{ media.media_data.width }}" - height="{{ media.media_data.height }}" - controls="controls" - preload="metadata" - data-setup=""> - <source src="{{ request.app.public_store.file_url( - media.media_files['webm_640']) }}" - type="video/webm; codecs="vp8, vorbis"" /> - <div class="no_html5"> - {%- trans -%}Sorry, this video will not work because - your web browser does not support HTML5 - video.{%- endtrans -%}<br/> - {%- trans -%}You can get a modern web browser that - can play this video at <a href="http://getfirefox.com"> - http://getfirefox.com</a>!{%- endtrans -%} - </div> - </video> - </div> + <video controls autoplay preload="auto" class="video-js vjs-mg-skin" + data-setup='{"height": {{ media.media_data.height }}, + "width": {{ media.media_data.width }} }'> + <source src="{{ request.app.public_store.file_url( + media.media_files['webm_640']) }}" + type="video/webm; codecs="vp8, vorbis"" /> + <div class="no_html5"> + {%- trans -%}Sorry, this video will not work because + your web browser does not support HTML5 + video.{%- endtrans -%}<br/> + {%- trans -%}You can get a modern web browser that + can play this video at <a href="http://getfirefox.com"> + http://getfirefox.com</a>!{%- endtrans -%} + </div> + </video> {% endblock %} {% block mediagoblin_sidebar %} |