changeset 1949:d3ae6858e77b

more consistent handling of numberOfFrames
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 15 Jul 2022 16:19:18 +0200
parents d459477804bf
children 6ffd65cfd2ee b33a104821a7
files Applications/StoneWebViewer/WebApplication/app.js Applications/StoneWebViewer/WebApplication/index.html
diffstat 2 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/Applications/StoneWebViewer/WebApplication/app.js	Fri Jul 15 16:17:23 2022 +0200
+++ b/Applications/StoneWebViewer/WebApplication/app.js	Fri Jul 15 16:19:18 2022 +0200
@@ -262,7 +262,7 @@
 
     window.addEventListener('FrameUpdated', function(args) {
       if (args.detail.canvasId == that.canvasId) {
-        that.currentFrame = (args.detail.currentFrame + 1);
+        that.currentFrame = args.detail.currentFrame;
         that.numberOfFrames = args.detail.numberOfFrames;
         that.quality = args.detail.quality;
         that.instanceNumber = args.detail.instanceNumber;
--- a/Applications/StoneWebViewer/WebApplication/index.html	Fri Jul 15 16:17:23 2022 +0200
+++ b/Applications/StoneWebViewer/WebApplication/index.html	Fri Jul 15 16:19:18 2022 +0200
@@ -704,7 +704,7 @@
                         </button>
                       </div>
                       <span data-toggle="tooltip" data-title="Current frame number">
-                        &nbsp;&nbsp;{{ currentFrame }} / {{ numberOfFrames }}&nbsp;&nbsp;
+                        &nbsp;&nbsp;{{ currentFrame + 1 }} / {{ numberOfFrames }}&nbsp;&nbsp;
                       </span>
                       <div class="btn-group btn-group-sm" role="group">                        
                         <button class="btn btn-primary" @click="IncrementFrame()">