mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
(#396) Save/Restore of WellLog plots partly in place.
Cleaned up ownership in WellLog plot classes initAfterRead() is implemented moved code related to command features from the WellLog classes Still plots are not redrawn/reloaded when opening a project file.
This commit is contained in:
@@ -50,7 +50,7 @@ void RicNewWellLogPlotCurveFeature::onActionTriggered(bool isChecked)
|
||||
RimWellLogPlotCurve* curve = new RimWellLogExtractionCurve();
|
||||
wellLogPlotTrace->addCurve(curve);
|
||||
|
||||
curve->setUiName(QString("Curve %1").arg(wellLogPlotTrace->curves.size()));
|
||||
curve->setDescription(QString("Curve %1").arg(wellLogPlotTrace->curveCount()));
|
||||
|
||||
wellLogPlotTrace->updateConnectedEditors();
|
||||
RiuMainWindow::instance()->setCurrentObjectInTreeView(curve);
|
||||
|
||||
@@ -24,6 +24,8 @@
|
||||
#include "cafSelectionManager.h"
|
||||
|
||||
#include <QAction>
|
||||
#include "RimWellLogPlotTrace.h"
|
||||
#include "RiuMainWindow.h"
|
||||
|
||||
|
||||
CAF_CMD_SOURCE_INIT(RicNewWellLogPlotTraceFeature, "RicNewWellLogPlotTraceFeature");
|
||||
@@ -44,7 +46,12 @@ void RicNewWellLogPlotTraceFeature::onActionTriggered(bool isChecked)
|
||||
RimWellLogPlot* wellLogPlot = selectedWellLogPlot();
|
||||
if (wellLogPlot)
|
||||
{
|
||||
wellLogPlot->addTrace();
|
||||
RimWellLogPlotTrace* trace = new RimWellLogPlotTrace;
|
||||
wellLogPlot->addTrace(trace);
|
||||
trace->setUiName(QString("Trace %1").arg(wellLogPlot->traceCount()));
|
||||
|
||||
wellLogPlot->updateConnectedEditors();
|
||||
RiuMainWindow::instance()->setCurrentObjectInTreeView(trace);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user