mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#1750 Range filter: Set default values of sliders to extremal values
This commit is contained in:
@@ -79,6 +79,27 @@ RimCellRangeFilter::~RimCellRangeFilter()
|
|||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
void RimCellRangeFilter::fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue)
|
void RimCellRangeFilter::fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue)
|
||||||
{
|
{
|
||||||
|
if (changedField == &gridIndex)
|
||||||
|
{
|
||||||
|
const cvf::StructGridInterface* grid = selectedGrid();
|
||||||
|
|
||||||
|
if (grid && grid->cellCountI() > 0 && grid->cellCountJ() > 0 && grid->cellCountK() > 0)
|
||||||
|
{
|
||||||
|
cellCountI = static_cast<int>(grid->cellCountI());
|
||||||
|
startIndexI = 1;
|
||||||
|
|
||||||
|
cellCountJ = static_cast<int>(grid->cellCountJ());
|
||||||
|
startIndexJ = 1;
|
||||||
|
|
||||||
|
cellCountK = static_cast<int>(grid->cellCountK());
|
||||||
|
startIndexK = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
parentContainer()->updateDisplayModeNotifyManagedViews(this);
|
||||||
|
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (changedField != &name)
|
if (changedField != &name)
|
||||||
{
|
{
|
||||||
computeAndSetValidValues();
|
computeAndSetValidValues();
|
||||||
|
|||||||
Reference in New Issue
Block a user