mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-12 20:43:25 +00:00
Fix video-js resize
This commit is contained in:
@@ -12,6 +12,10 @@
|
|||||||
preload="auto" xposter="my_video_poster.png" width="{{ displayWidth|round }}" height="{{ displayHeight | round }}"
|
preload="auto" xposter="my_video_poster.png" width="{{ displayWidth|round }}" height="{{ displayHeight | round }}"
|
||||||
data-setup="{}">
|
data-setup="{}">
|
||||||
{% for name, subdef in arraySubdefs %}
|
{% for name, subdef in arraySubdefs %}
|
||||||
|
{% if loop.first %}
|
||||||
|
<input type="hidden" name="width" value="{{subdef.get_width()}}"/>
|
||||||
|
<input type="hidden" name="height" value="{{subdef.get_height()}}"/>
|
||||||
|
{% endif %}
|
||||||
{% if session.is_authenticated() == true %}
|
{% if session.is_authenticated() == true %}
|
||||||
{% set url = subdef.get_url() %}
|
{% set url = subdef.get_url() %}
|
||||||
{% else %}
|
{% else %}
|
||||||
@@ -26,7 +30,11 @@
|
|||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
try {
|
try {
|
||||||
_V_("video_preview_tooltip", {}, function(){
|
_V_("video_preview_tooltip", {}, function(){
|
||||||
|
var player = this;
|
||||||
|
$('#video_preview_tooltip').parent().bind('resize-video-js', function(){
|
||||||
|
player.width($(this).width());
|
||||||
|
player.height($(this).height());
|
||||||
|
});
|
||||||
});
|
});
|
||||||
} catch(err) {
|
} catch(err) {
|
||||||
console.error('An error has been catched during the execution of VideoJS', err);
|
console.error('An error has been catched during the execution of VideoJS', err);
|
||||||
|
@@ -498,6 +498,7 @@ function setPreview(){
|
|||||||
top: t,
|
top: t,
|
||||||
left: l
|
left: l
|
||||||
}).attr('width',w).attr('height',h);
|
}).attr('width',w).attr('height',h);
|
||||||
|
$('#PREVIEWIMGCONT .record').trigger('resize-video-js');
|
||||||
}
|
}
|
||||||
|
|
||||||
function classicMode(){
|
function classicMode(){
|
||||||
|
Reference in New Issue
Block a user