2014-07-29 01:49:54 -05:00
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
//
|
|
|
|
// Copyright (C) 2011-2012 Statoil ASA, Ceetron AS
|
|
|
|
//
|
|
|
|
// ResInsight is free software: you can redistribute it and/or modify
|
|
|
|
// it under the terms of the GNU General Public License as published by
|
|
|
|
// the Free Software Foundation, either version 3 of the License, or
|
|
|
|
// (at your option) any later version.
|
|
|
|
//
|
|
|
|
// ResInsight is distributed in the hope that it will be useful, but WITHOUT ANY
|
|
|
|
// WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
|
|
// FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
//
|
|
|
|
// See the GNU General Public License at <http://www.gnu.org/licenses/gpl.html>
|
|
|
|
// for more details.
|
|
|
|
//
|
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "cafAppEnum.h"
|
|
|
|
#include "cafPdmField.h"
|
|
|
|
#include "cafPdmObject.h"
|
|
|
|
|
2014-07-30 07:26:39 -05:00
|
|
|
class RimResultSlot;
|
|
|
|
class RimReservoirView;
|
|
|
|
|
2014-07-29 01:49:54 -05:00
|
|
|
//==================================================================================================
|
|
|
|
///
|
|
|
|
///
|
|
|
|
//==================================================================================================
|
2014-08-06 05:47:27 -05:00
|
|
|
class RimFaultResultSlot : public caf::PdmObject
|
2014-07-29 01:49:54 -05:00
|
|
|
{
|
|
|
|
CAF_PDM_HEADER_INIT;
|
|
|
|
|
|
|
|
public:
|
2014-08-06 05:47:27 -05:00
|
|
|
RimFaultResultSlot();
|
|
|
|
virtual ~RimFaultResultSlot();
|
2014-07-31 03:49:23 -05:00
|
|
|
|
2014-07-30 07:26:39 -05:00
|
|
|
void setReservoirView(RimReservoirView* ownerReservoirView);
|
2014-07-31 01:46:30 -05:00
|
|
|
|
2014-08-01 02:40:35 -05:00
|
|
|
caf::PdmField<bool> showCustomFaultResult;
|
2014-09-04 02:30:00 -05:00
|
|
|
caf::PdmField<bool> hideNncsWhenNoResultIsAvailable;
|
2014-07-31 07:05:40 -05:00
|
|
|
|
2014-08-26 04:47:14 -05:00
|
|
|
bool hasValidCustomResult();
|
2014-09-04 02:30:00 -05:00
|
|
|
bool isNncResultAvailable();
|
2014-08-26 04:47:14 -05:00
|
|
|
RimResultSlot* customFaultResult();
|
2014-07-31 03:49:23 -05:00
|
|
|
|
2014-08-26 04:47:14 -05:00
|
|
|
void updateFieldVisibility();
|
2014-08-01 05:55:43 -05:00
|
|
|
|
|
|
|
virtual QList<caf::PdmOptionItemInfo> calculateValueOptions( const caf::PdmFieldHandle* fieldNeedingOptions, bool * useOptionsOnly );
|
2014-07-30 07:26:39 -05:00
|
|
|
|
|
|
|
protected:
|
2014-08-01 02:40:35 -05:00
|
|
|
virtual void initAfterRead();
|
|
|
|
virtual caf::PdmFieldHandle* objectToggleField();
|
|
|
|
virtual void fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue);
|
2014-08-01 05:55:43 -05:00
|
|
|
virtual void defineUiOrdering(QString uiConfigName, caf::PdmUiOrdering& uiOrdering) ;
|
2014-07-30 07:26:39 -05:00
|
|
|
|
|
|
|
private:
|
2014-07-31 04:09:48 -05:00
|
|
|
caf::PdmField<RimResultSlot*> m_customFaultResult;
|
|
|
|
caf::PdmPointer<RimReservoirView> m_reservoirView;
|
2014-07-29 01:49:54 -05:00
|
|
|
};
|
|
|
|
|