Salome HOME
refs #416: to store the open state of object browser items in the binary array
[modules/gui.git] / src / SVTK / SVTK_ViewWindow.h
index 15c977e3eb0044b13232d805fb57a047ff0b4381..3ee736b38b5969a3e1af8eb9ff37075a6a4dfede 100755 (executable)
@@ -1,4 +1,4 @@
-// Copyright (C) 2007-2012  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2014  CEA/DEN, EDF R&D, OPEN CASCADE
 //
 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
@@ -6,7 +6,7 @@
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
-// version 2.1 of the License.
+// version 2.1 of the License, or (at your option) any later version.
 //
 // This library is distributed in the hope that it will be useful,
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -216,10 +216,10 @@ class SVTK_EXPORT SVTK_ViewWindow : public SUIT_ViewWindow
   SVTK_CubeAxesActor2D* GetCubeAxes();
 
   //! Redirect the request to #SVTK_Renderer::GetTrihedronSize
-  vtkFloatingPointType GetTrihedronSize() const;
+  double GetTrihedronSize() const;
 
   //! Redirect the request to #SVTK_Renderer::SetTrihedronSize
-  virtual void SetTrihedronSize( const vtkFloatingPointType, const bool = true );
+  virtual void SetTrihedronSize( const double, const bool = true );
 
   //! Set incremental speed
   virtual void SetIncrementalSpeed( const int, const int = 0 );
@@ -233,8 +233,11 @@ class SVTK_EXPORT SVTK_ViewWindow : public SUIT_ViewWindow
   //! Set zooming style
   virtual void SetZoomingStyle( const int );
 
-  //! Set dynamic preselection on/off
-  virtual void SetDynamicPreSelection( bool );
+  //! Set preselection mode
+  virtual void SetPreSelectionMode( Preselection_Mode );
+
+  //! Enable/disable selection
+  virtual void SetSelectionEnabled( bool );
 
   //! Customize space mouse buttons
   virtual void SetSpacemouseButtons( const int, const int, const int );
@@ -276,6 +279,8 @@ class SVTK_EXPORT SVTK_ViewWindow : public SUIT_ViewWindow
   //! To invoke a VTK event on #SVTK_RenderWindowInteractor instance
   void InvokeEvent(unsigned long theEvent, void* theCallData);
   
+  virtual SUIT_CameraProperties cameraProperties();
+  
  signals:
   void Show( QShowEvent * );
   void Hide( QHideEvent * );
@@ -289,7 +294,7 @@ public slots:
 
   void activateSetRotationGravity();
   void activateSetRotationSelected(void* theData);
-  void activateStartPointSelection();
+  void activateStartPointSelection( Selection_Mode );
 
   void onUpdateRate(bool theIsActivate);
   void onNonIsometric(bool theIsActivate);
@@ -313,7 +318,9 @@ public slots:
 
   void onSwitchInteractionStyle(bool theOn);
   void onSwitchZoomingStyle(bool theOn);
-  void onSwitchDynamicPreSelection(bool theOn);
+
+  void onSwitchPreSelectionMode(int theMode);
+  void onEnableSelection(bool theOn);
 
   void onStartRecording();
   void onPlayRecording();
@@ -372,6 +379,7 @@ public slots:
   virtual void synchronize(SVTK_ViewWindow*);
     
 protected slots:
+  void synchronize( SUIT_ViewWindow* );
   void onKeyPressed(QKeyEvent* event);
   void onKeyReleased(QKeyEvent* event);
   void onMousePressed(QMouseEvent* event);
@@ -408,7 +416,9 @@ protected:
          FrontId, BackId, TopId, BottomId, LeftId, RightId, ClockWiseId, AntiClockWiseId, ResetId,
         ViewTrihedronId, NonIsometric, GraduatedAxes, UpdateRate,
          ParallelModeId, ProjectionModeId, ViewParametersId, SynchronizeId, SwitchInteractionStyleId,
-         SwitchZoomingStyleId,SwitchDynamicPreselectionId,
+         SwitchZoomingStyleId, 
+        PreselectionId, StandardPreselectionId, DynamicPreselectionId, DisablePreselectionId, 
+        EnableSelectionId,
          StartRecordingId, PlayRecordingId, PauseRecordingId, StopRecordingId };
 
   SVTK_View* myView;
@@ -446,13 +456,6 @@ protected:
   vtkPVAxesWidget* myAxesWidget;
   Qtx::BackgroundData myBackground;
 
-private slots:
-  void onSynchronizeView(bool);
-  void updateSyncViews();
-
-private:
-  static void synchronizeView( SVTK_ViewWindow*, int );
-
 private:
   QImage myDumpImage;
 };