diff Applications/StoneWebViewer/WebApplication/app.js @ 1720:b8d19f53aaca

display the instance number, and the wc/ww info (work-in-progress)
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 01 Dec 2020 12:13:43 +0100
parents 65c03d33c345
children d4a8e2b19a65
line wrap: on
line diff
--- a/Applications/StoneWebViewer/WebApplication/app.js	Tue Dec 01 10:42:45 2020 +0100
+++ b/Applications/StoneWebViewer/WebApplication/app.js	Tue Dec 01 12:13:43 2020 +0100
@@ -137,7 +137,10 @@
       cineFramesPerSecond: 30,
       cineTimeoutId: null,
       cineLoadingFrame: false,
-      videoUri: ''
+      videoUri: '',
+      windowingCenter: 0, 
+      windowingWidth: 0,
+      instanceNumber: 0
     }
   },
   watch: {
@@ -155,6 +158,9 @@
       this.cineMode = '';
       this.cineLoadingFrame = false;
       this.cineRate = 30;   // Default value
+      this.windowingCenter = 0;
+      this.windowingWidth = 0;
+      this.instanceNumber = 0;
       
       if (this.cineTimeoutId !== null) {
         clearTimeout(this.cineTimeoutId);
@@ -239,6 +245,7 @@
         that.currentFrame = (args.detail.currentFrame + 1);
         that.numberOfFrames = args.detail.numberOfFrames;
         that.quality = args.detail.quality;
+        that.instanceNumber = args.detail.instanceNumber;
       }
     });
 
@@ -274,6 +281,14 @@
         });
       }
     });
+
+    window.addEventListener('WindowingUpdated', function(args) {
+      if (args.detail.canvasId == that.canvasId) {
+        that.windowingCenter = args.detail.windowingCenter;
+        that.windowingWidth = args.detail.windowingWidth;
+        console.log(that.windowingCenter + ' ' + that.windowingWidth);
+      }
+    });
   },
   methods: {
     DragDrop: function(event) {