#2187 Summary Plot : Use prev/next buttons for plot source stepping

This commit is contained in:
Magne Sjaastad 2017-11-29 16:23:57 +01:00
parent fab0e92102
commit 2a0f1e2fe9
2 changed files with 17 additions and 1 deletions

View File

@ -32,6 +32,7 @@
#include "RimSummaryCurveCollection.h"
#include "RimSummaryPlot.h"
#include "cafPdmUiComboBoxEditor.h"
#include "cafPdmUiItem.h"
#include "cafPdmUiListEditor.h"
@ -550,3 +551,16 @@ caf::PdmValueField* RimSummaryPlotSourceStepping::valueFieldToModify()
return dynamic_cast<caf::PdmValueField*>(fieldToModify());
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
void RimSummaryPlotSourceStepping::defineEditorAttribute(const caf::PdmFieldHandle* field, QString uiConfigName,
caf::PdmUiEditorAttribute* attribute)
{
caf::PdmUiComboBoxEditorAttribute* myAttr = dynamic_cast<caf::PdmUiComboBoxEditorAttribute*>(attribute);
if (myAttr)
{
myAttr->showPreviousAndNextButtons = true;
}
}

View File

@ -52,6 +52,8 @@ private:
virtual void fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue,
const QVariant& newValue) override;
virtual void defineEditorAttribute(const caf::PdmFieldHandle* field, QString uiConfigName, caf::PdmUiEditorAttribute* attribute) override;
private:
RifSummaryReaderInterface* summaryReader() const;
RimSummaryCase* singleSummaryCase() const;