#1670 Add const and move some functions to private section

This commit is contained in:
Magne Sjaastad 2017-06-28 12:37:26 +02:00
parent 1de6986ba2
commit 7cc95c3fa8
2 changed files with 9 additions and 14 deletions

View File

@ -288,11 +288,10 @@ QList<caf::PdmOptionItemInfo> RimCellRangeFilter::calculateValueOptions(const ca
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
bool RimCellRangeFilter::isRangeFilterControlled()
bool RimCellRangeFilter::isRangeFilterControlled() const
{
RimView* rimView = NULL;
firstAncestorOrThisOfType(rimView);
CVF_ASSERT(rimView);
RimView* rimView = nullptr;
firstAncestorOrThisOfTypeAsserted(rimView);
bool isRangeFilterControlled = false;
if (rimView && rimView->viewController() && rimView->viewController()->isRangeFiltersControlled())

View File

@ -44,9 +44,6 @@ public:
RimCellRangeFilter();
virtual ~RimCellRangeFilter();
RimCellRangeFilterCollection* parentContainer();
void setDefaultValues();
caf::PdmField<int> gridIndex; // The index of the grid that this filter applies to
caf::PdmField<bool> propagateToSubGrids; // Do propagate the effects to the sub-grids
@ -57,9 +54,8 @@ public:
caf::PdmField<int> cellCountJ;
caf::PdmField<int> cellCountK;
void computeAndSetValidValues();
void updateActiveState();
void setDefaultValues();
void updateActiveState();
protected:
virtual void fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue);
@ -70,10 +66,10 @@ protected:
virtual QList<caf::PdmOptionItemInfo> calculateValueOptions( const caf::PdmFieldHandle* fieldNeedingOptions, bool * useOptionsOnly );
private:
bool isRangeFilterControlled();
private:
const cvf::StructGridInterface* selectedGrid();
RimCellRangeFilterCollection* parentContainer();
bool isRangeFilterControlled() const;
void computeAndSetValidValues();
const cvf::StructGridInterface* selectedGrid();
};