Salome HOME
projects
/
modules
/
shaper.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Issue #676: ZFitall for display new object
[modules/shaper.git]
/
src
/
NewGeom
/
NewGeom_SalomeViewer.h
diff --git
a/src/NewGeom/NewGeom_SalomeViewer.h
b/src/NewGeom/NewGeom_SalomeViewer.h
index 4f8812803f6a6570ef39187a223ed4edf1a399e4..8012c4a015c25ad59a452ee9fe598ba28bc30ca3 100644
(file)
--- a/
src/NewGeom/NewGeom_SalomeViewer.h
+++ b/
src/NewGeom/NewGeom_SalomeViewer.h
@@
-9,6
+9,8
@@
#include <ModuleBase_IViewer.h>
#include <ModuleBase_IViewWindow.h>
#include <ModuleBase_IViewer.h>
#include <ModuleBase_IViewWindow.h>
+#include <OCCViewer_ViewWindow.h>
+
#include <V3d_View.hxx>
class SUIT_ViewWindow;
#include <V3d_View.hxx>
class SUIT_ViewWindow;
@@
-29,7
+31,7
@@
class NewGeom_SalomeView: public ModuleBase_IViewWindow
public:
/// Constructor
/// \param theViewer a reference to a viewer
public:
/// Constructor
/// \param theViewer a reference to a viewer
- NewGeom_SalomeView(OCCViewer_Viewer* theViewer)
{ myViewer = theViewer; }
+ NewGeom_SalomeView(OCCViewer_Viewer* theViewer)
;
virtual Handle(V3d_View) v3dView() const;
virtual Handle(V3d_View) v3dView() const;
@@
-43,9
+45,13
@@
public:
/// Returns current viewer
OCCViewer_Viewer* viewer() const { return myViewer; }
/// Returns current viewer
OCCViewer_Viewer* viewer() const { return myViewer; }
+ /// Sets the current view
+ void setCurrentView(SUIT_ViewWindow* theView) { myCurrentView = theView; }
+
private:
/// A reference to a viewer
OCCViewer_Viewer* myViewer;
private:
/// A reference to a viewer
OCCViewer_Viewer* myViewer;
+ SUIT_ViewWindow* myCurrentView;
};
};
@@
-120,6
+126,13
@@
Q_OBJECT
/// by mouse drugging. If this is impossible thet it has to return False.
virtual bool canDragByMouse() const;
/// by mouse drugging. If this is impossible thet it has to return False.
virtual bool canDragByMouse() const;
+ /// Activate or deactivate viewer
+ /// \param toActivate - activation flag
+ void activateViewer(bool toActivate);
+
+ // Fit all along Z (perpendicular to display)
+ virtual void Zfitall();
+
private slots:
void onMousePress(SUIT_ViewWindow*, QMouseEvent*);
void onMouseRelease(SUIT_ViewWindow*, QMouseEvent*);
private slots:
void onMousePress(SUIT_ViewWindow*, QMouseEvent*);
void onMouseRelease(SUIT_ViewWindow*, QMouseEvent*);
@@
-134,6
+147,7
@@
Q_OBJECT
void onActivated(SUIT_ViewWindow*);
void onSelectionChanged();
void onActivated(SUIT_ViewWindow*);
void onSelectionChanged();
+ void onViewTransformed(OCCViewer_ViewWindow::OperationType);
private:
NewGeom_OCCSelector* mySelector;
private:
NewGeom_OCCSelector* mySelector;