Skip to content

Commit

Permalink
Clean up.
Browse files Browse the repository at this point in the history
  • Loading branch information
Frodo161 committed Sep 15, 2023
1 parent 4bd1451 commit 4de2bdf
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 15 deletions.
4 changes: 2 additions & 2 deletions app/assets/javascripts/thyme/display_manager.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ class DisplayManager {
constructor(elements, func) {
/*
elements = An array containing JQuery references on the HTML elements
that should be hidden, when the display is too small.
that should be hidden, when the display is too small.
func = A reference on a function that is called when the display
changes from small to large. Use this for player specific behaviour.
changes from small to large. Use this for player specific behaviour.
*/
this.elements = elements;
this.func = func;
Expand Down
16 changes: 3 additions & 13 deletions app/assets/javascripts/thyme_player.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,8 @@ $(document).on('turbolinks:load', function() {
annotationManager.updateMarkers();
}
};
window.onresize = resizeContainer;
video.onloadedmetadata = resizeContainer;



Expand All @@ -190,10 +192,9 @@ $(document).on('turbolinks:load', function() {
/*
MISC
*/
// auto show/hide control bar
const controlBarHider = new ControlBarHider('video-controlBar', 3000);
controlBarHider.install();

displayManager.updateControlBarType();
thymeUtility.playOnClick();
thymeUtility.setUpMaxTime('max-time');

Expand All @@ -211,15 +212,4 @@ $(document).on('turbolinks:load', function() {
return;
}

//setupHypervideo();

function updateControlBarType() {
displayManager.updateControlBarType();
};

updateControlBarType();

window.onresize = resizeContainer;
video.onloadedmetadata = resizeContainer;

});

0 comments on commit 4de2bdf

Please sign in to comment.