Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Jannik Hellenkamp
website
Commits
7405e59d
Commit
7405e59d
authored
Jul 23, 2018
by
Julian Rother
Browse files
Enabled hls previewing for live sources
parent
db5a4f29
Changes
1
Hide whitespace changes
Inline
Side-by-side
templates/streaming.html
View file @
7405e59d
...
...
@@ -21,7 +21,7 @@
<div
class=
"row"
>
<div
style=
"background-image: url('{{ config.VIDEOPREFIX }}/thumbnail/s_{{ source.id }}.jpg')"
class=
"col-sm-2 col-xs-12 thumbnailimg"
>
{% if source.clientid %}
<a
href=
"#"
data-toggle=
"modal"
data-target=
"#preview-player"
data-srcname=
"{{ source.name }}"
data-src
id
=
"{{ source.
id
}}"
>
<a
href=
"#"
data-toggle=
"modal"
data-target=
"#preview-player"
data-srcname=
"{{ source.name }}"
data-src
key
=
"{{ source.
key
}}"
>
<span
class=
"glyphicon glyphicon-play-circle playpreviewbtn"
></span>
</a>
{% endif %}
...
...
@@ -77,7 +77,7 @@
$
(
'
#preview-player
'
).
on
(
'
show.bs.modal
'
,
function
(
e
)
{
var
btn
=
$
(
e
.
relatedTarget
);
$
(
this
).
find
(
'
.modal-title
'
).
text
(
'
Vorschau von
'
+
btn
.
data
(
'
srcname
'
));
$
(
this
).
find
(
'
.modal-body
'
).
html
(
'
<video id="previewplayer" style="width: 100%" class="video-js vjs-default-skin vjs-big-play-centered" width="640" height="320" controls><source type="application/x-mpegURL" src="{{config.VIDEOPREFIX}}/hls/preview/
'
+
btn
.
data
(
'
src
id
'
)
+
'
.m3u8"/></video>
'
);
$
(
this
).
find
(
'
.modal-body
'
).
html
(
'
<video id="previewplayer" style="width: 100%" class="video-js vjs-default-skin vjs-big-play-centered" width="640" height="320" controls><source type="application/x-mpegURL" src="{{config.VIDEOPREFIX}}/hls/preview/
'
+
btn
.
data
(
'
src
key
'
)
+
'
.m3u8"/></video>
'
);
var
player
=
videojs
(
'
previewplayer
'
);
player
.
play
();
});
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment