Commit d893a14a by kimth

Load player before turning off caption

parent 8673460b
......@@ -10,11 +10,6 @@ class @Video
@fetchMetadata()
@parseSpeed()
if $.cookie('hide_captions') == 'true'
@el.addClass('closed')
else
@el.removeClass('closed')
$("#video_#{@id}").data('video', this).addClass('video-load-complete')
if YT.Player
......@@ -24,6 +19,11 @@ class @Video
$('.course-content .video').each ->
$(this).data('video').embed()
if $.cookie('hide_captions') == 'true'
@el.addClass('closed')
else
@el.removeClass('closed')
youtubeId: (speed)->
@videos[speed || @speed]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment