changeset 1558:314b6dc507d9

fix
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 20 Aug 2020 11:38:56 +0200
parents a6f339d8e4c2
children 97b34cb88600
files Applications/StoneWebViewer/WebAssembly/StoneWebViewer.cpp OrthancStone/Resources/CMake/OrthancStoneConfiguration.cmake OrthancStone/Sources/Scene2DViewport/LayerHolder.cpp OrthancStone/Sources/Viewport/IViewport.h OrthancStone/Sources/Viewport/IViewportInteractor.h OrthancStone/Sources/Viewport/WebAssemblyCairoViewport.cpp OrthancStone/Sources/Viewport/WebAssemblyViewport.cpp OrthancStone/Sources/Viewport/WebAssemblyViewport.h OrthancStone/Sources/Viewport/WebGLViewport.cpp OrthancStone/Sources/Viewport/WebGLViewportsRegistry.cpp OrthancStone/Sources/Volumes/VolumeSceneLayerSource.cpp
diffstat 11 files changed, 21 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/Applications/StoneWebViewer/WebAssembly/StoneWebViewer.cpp	Thu Aug 20 11:17:16 2020 +0200
+++ b/Applications/StoneWebViewer/WebAssembly/StoneWebViewer.cpp	Thu Aug 20 11:38:56 2020 +0200
@@ -74,12 +74,13 @@
 #include <Scene2D/ColorTextureSceneLayer.h>
 #include <Scene2D/FloatTextureSceneLayer.h>
 #include <Scene2D/PolylineSceneLayer.h>
+#include <Scene2DViewport/ViewportController.h>
 #include <StoneException.h>
 #include <Toolbox/DicomInstanceParameters.h>
 #include <Toolbox/GeometryToolbox.h>
 #include <Toolbox/SortedFrames.h>
+#include <Viewport/WebAssemblyCairoViewport.h>
 #include <Viewport/WebGLViewport.h>
-#include <Viewport/WebAssemblyCairoViewport.h>
 
 #include <boost/make_shared.hpp>
 #include <stdio.h>
--- a/OrthancStone/Resources/CMake/OrthancStoneConfiguration.cmake	Thu Aug 20 11:17:16 2020 +0200
+++ b/OrthancStone/Resources/CMake/OrthancStoneConfiguration.cmake	Thu Aug 20 11:38:56 2020 +0200
@@ -486,7 +486,7 @@
   ${ORTHANC_STONE_ROOT}/Sources/Toolbox/UndoRedoStack.h
   
   ${ORTHANC_STONE_ROOT}/Sources/Viewport/IViewport.h
-  ${ORTHANC_STONE_ROOT}/Sources/Viewport/DefaultViewportInteractor.h
+  ${ORTHANC_STONE_ROOT}/Sources/Viewport/DefaultViewportInteractor.cpp
   
   ${ORTHANC_STONE_ROOT}/Sources/Volumes/IGeometryProvider.h
   ${ORTHANC_STONE_ROOT}/Sources/Volumes/IVolumeSlicer.cpp
--- a/OrthancStone/Sources/Scene2DViewport/LayerHolder.cpp	Thu Aug 20 11:17:16 2020 +0200
+++ b/OrthancStone/Sources/Scene2DViewport/LayerHolder.cpp	Thu Aug 20 11:38:56 2020 +0200
@@ -24,6 +24,7 @@
 #include "../Scene2D/Scene2D.h"
 #include "../Viewport/IViewport.h"
 #include "../StoneException.h"
+#include "ViewportController.h"
 
 namespace OrthancStone
 {
--- a/OrthancStone/Sources/Viewport/IViewport.h	Thu Aug 20 11:17:16 2020 +0200
+++ b/OrthancStone/Sources/Viewport/IViewport.h	Thu Aug 20 11:38:56 2020 +0200
@@ -21,10 +21,11 @@
 #pragma once
 
 #include "../Scene2D/ICompositor.h"
-#include "../Scene2DViewport/ViewportController.h"
 
 namespace OrthancStone
 {
+  class ViewportController;
+  
   /**
    * Class that combines a Scene2D with a canvas where to draw the
    * scene. A call to "Refresh()" will update the content of the
--- a/OrthancStone/Sources/Viewport/IViewportInteractor.h	Thu Aug 20 11:17:16 2020 +0200
+++ b/OrthancStone/Sources/Viewport/IViewportInteractor.h	Thu Aug 20 11:38:56 2020 +0200
@@ -20,11 +20,11 @@
 
 #pragma once
 
+#include "IViewport.h"
+#include "../Scene2DViewport/IFlexiblePointerTracker.h"
+
 namespace OrthancStone
 {
-  class IViewport;
-  class PointerEvent;
-  
   class IViewportInteractor : public boost::noncopyable
   {
   public:
--- a/OrthancStone/Sources/Viewport/WebAssemblyCairoViewport.cpp	Thu Aug 20 11:17:16 2020 +0200
+++ b/OrthancStone/Sources/Viewport/WebAssemblyCairoViewport.cpp	Thu Aug 20 11:38:56 2020 +0200
@@ -22,13 +22,16 @@
 #if defined(ORTHANC_BUILDING_STONE_LIBRARY) && ORTHANC_BUILDING_STONE_LIBRARY == 1
 #  include "WebAssemblyCairoViewport.h"
 #  include "../Scene2D/CairoCompositor.h"
+#  include "../Scene2DViewport/ViewportController.h"
 #else
 // This is the case when using the WebAssembly side module, and this
 // source file must be compiled within the WebAssembly main module
 #  include <Viewport/WebAssemblyCairoViewport.h>
 #  include <Scene2D/CairoCompositor.h>
+#  include <Scene2DViewport/ViewportController.h>
 #endif
 
+
 #include <Images/Image.h>
 
 #include <boost/math/special_functions/round.hpp>
--- a/OrthancStone/Sources/Viewport/WebAssemblyViewport.cpp	Thu Aug 20 11:17:16 2020 +0200
+++ b/OrthancStone/Sources/Viewport/WebAssemblyViewport.cpp	Thu Aug 20 11:38:56 2020 +0200
@@ -21,15 +21,18 @@
 
 #if defined(ORTHANC_BUILDING_STONE_LIBRARY) && ORTHANC_BUILDING_STONE_LIBRARY == 1
 #  include "WebAssemblyViewport.h"
+#  include "DefaultViewportInteractor.h"
 #  include "../Toolbox/GenericToolbox.h"
+#  include "../Scene2DViewport/ViewportController.h"
 #else
 // This is the case when using the WebAssembly side module, and this
 // source file must be compiled within the WebAssembly main module
 #  include <Viewport/WebAssemblyViewport.h>
 #  include <Toolbox/GenericToolbox.h>
+#  include <Scene2DViewport/ViewportController.h>
+#  include <Viewport/DefaultViewportInteractor.h>
 #endif
 
-#include "DefaultViewportInteractor.h"
 
 #include <OrthancException.h>
 
--- a/OrthancStone/Sources/Viewport/WebAssemblyViewport.h	Thu Aug 20 11:17:16 2020 +0200
+++ b/OrthancStone/Sources/Viewport/WebAssemblyViewport.h	Thu Aug 20 11:38:56 2020 +0200
@@ -32,6 +32,7 @@
 #endif
 
 #include "IViewport.h"
+#include "IViewportInteractor.h"
 
 #include <Compatibility.h>
 
@@ -40,6 +41,7 @@
 
 #include <memory>
 #include <string>
+#include <boost/enable_shared_from_this.hpp>
 
 namespace OrthancStone
 {
--- a/OrthancStone/Sources/Viewport/WebGLViewport.cpp	Thu Aug 20 11:17:16 2020 +0200
+++ b/OrthancStone/Sources/Viewport/WebGLViewport.cpp	Thu Aug 20 11:38:56 2020 +0200
@@ -23,6 +23,7 @@
 
 #include "../StoneException.h"
 #include "../Scene2D/OpenGLCompositor.h"
+#include "../Scene2DViewport/ViewportController.h"
 
 namespace OrthancStone
 {
--- a/OrthancStone/Sources/Viewport/WebGLViewportsRegistry.cpp	Thu Aug 20 11:17:16 2020 +0200
+++ b/OrthancStone/Sources/Viewport/WebGLViewportsRegistry.cpp	Thu Aug 20 11:38:56 2020 +0200
@@ -22,6 +22,7 @@
 #include "WebGLViewportsRegistry.h"
 
 #include "../Toolbox/GenericToolbox.h"
+#include "../Scene2DViewport/ViewportController.h"
 
 #include <OrthancException.h>
 
--- a/OrthancStone/Sources/Volumes/VolumeSceneLayerSource.cpp	Thu Aug 20 11:17:16 2020 +0200
+++ b/OrthancStone/Sources/Volumes/VolumeSceneLayerSource.cpp	Thu Aug 20 11:38:56 2020 +0200
@@ -24,6 +24,7 @@
 #include "../Scene2D/NullLayer.h"
 #include "../Viewport/IViewport.h"
 #include "../StoneException.h"
+#include "../Scene2DViewport/ViewportController.h"
 
 #include <OrthancException.h>