]> _ Git - fluidbook-html5.git/commitdiff
wait #5730 @0.5
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Tue, 14 Feb 2023 11:23:42 +0000 (12:23 +0100)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Tue, 14 Feb 2023 11:23:42 +0000 (12:23 +0100)
js/libs/fluidbook/fluidbook.video.js
style/fluidbook.video.less

index 8b74dccd7a1c6419f8ca99f53799081d6685489b..9a1a011fc369925f68d7d58ebcd4506e72c05608 100644 (file)
@@ -82,7 +82,7 @@ FluidbookVideo.prototype = {
         var $this = this;
 
         $(".videoContainer").each(function () {
-            if($(this).closest('.rightclone').length>0 && $(this).is(':hidden')){
+            if ($(this).closest('.rightclone').length > 0 && $(this).is(':hidden')) {
                 return;
             }
 
@@ -219,7 +219,7 @@ FluidbookVideo.prototype = {
 
             $this.resizeControls(); // Make sure player controls are the right size
 
-           if (autoplay) {
+            if (autoplay) {
                 var promise = player.play();
 
                 if (promise !== undefined) {
@@ -230,7 +230,7 @@ FluidbookVideo.prototype = {
                         console.log('autoplay nok');
                         // Autoplay was prevented.
                     });
-                }else{
+                } else {
 
                 }
             }
@@ -291,7 +291,9 @@ FluidbookVideo.prototype = {
             // console.log(id + ' player paused');
 
             // Show play button (ref: http://stackoverflow.com/a/25296575)
-            this.bigPlayButton.show();
+            if (controls) {
+                this.bigPlayButton.show();
+            }
 
             // Now the issue is that we need to hide it again if we start playing
             // So every time we do this, we can create a one-time listener for play events.
index 5fd5840369ae8c29ce4b0937995a445b6c930446..1c2a9c3a5a0d089d1ad50874f86d34b2d3b4925e 100644 (file)
 
 .vjs-fluidbook-skin .vjs-big-play-button {
   background-image: url(@video-bigplay-image);
+}
+
+.vjs-controls-disabled.vjs-fluidbook-skin {
+  .vjs-big-play-button {
+    visibility: hidden;
+    display: none;
+    opacity: 0;
+  }
 }
\ No newline at end of file