Refactored general view stuff into RimView

Removing it from RimReservoirView and RimGeoMechView
This commit is contained in:
Jacob Støren
2015-04-29 22:19:49 +02:00
parent 4a21bb4a30
commit 4b7d593b3c
9 changed files with 228 additions and 192 deletions

View File

@@ -27,6 +27,7 @@
#include "cafPdmFieldCvfMat4d.h"
#include "cvfObject.h"
#include "RimView.h"
class RimGeoMechResultSlot;
class Rim3dOverlayInfoConfig;
@@ -40,7 +41,7 @@ class RigFemPart;
///
///
//==================================================================================================
class RimGeoMechView : public caf::PdmObject
class RimGeoMechView : public RimView
{
CAF_PDM_HEADER_INIT;
@@ -48,7 +49,6 @@ public:
RimGeoMechView(void);
virtual ~RimGeoMechView(void);
enum MeshModeType
{
FULL_MESH,
@@ -66,31 +66,22 @@ public:
void setGeoMechCase(RimGeoMechCase* gmCase);
void loadDataAndUpdate();
virtual void setCurrentTimeStep(int frameIdx){}
virtual void updateCurrentTimeStepAndRedraw(){}
virtual void endAnimation() {}
caf::PdmField<RimGeoMechResultSlot*> cellResult;
caf::PdmField<Rim3dOverlayInfoConfig*> overlayInfoConfig;
// Fields:
caf::PdmField<QString> name;
caf::PdmField<double> scaleZ;
caf::PdmField<bool> showWindow;
caf::PdmField<cvf::Mat4d> cameraPosition;
caf::PdmField< caf::AppEnum< MeshModeType > > meshMode;
caf::PdmField< caf::AppEnum< SurfaceModeType > > surfaceMode;
caf::PdmField< cvf::Color3f > backgroundColor;
protected:
virtual caf::PdmFieldHandle* userDescriptionField();
private:
void updateViewerWidget();
void updateViewerWidgetWindowTitle();
void createDisplayModelAndRedraw();
void updateViewerWidget();
void updateViewerWidgetWindowTitle();
void createDisplayModelAndRedraw();
QPointer<RiuViewer> m_viewer;
caf::PdmPointer<RimGeoMechCase> m_geomechCase;
cvf::ref<RivGeoMechPartMgr> m_geoMechVizModel;
caf::PdmPointer<RimGeoMechCase> m_geomechCase;
cvf::ref<RivGeoMechPartMgr> m_geoMechVizModel;
};
#include "cvfArray.h"