//-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- void RimWellLogPlot::fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue) { if (changedField == &m_showWindow) { if (m_showWindow) { loadDataAndUpdate(); } else { updateViewerWidget(); } uiCapability()->updateUiIconFromToggleField(); } else if (changedField == &m_minVisibleDepth || changedField == &m_maxVisibleDepth) { applyDepthZoomFromVisibleDepth(); m_isAutoScaleDepthEnabled = false; } else if (changedField == &m_isAutoScaleDepthEnabled) { updateDepthZoom(); } else if (changedField == &m_userName) { updateViewerWidgetWindowTitle(); } if (changedField == &m_depthType || changedField == &m_depthUnit) { updateTracks(); } }
//-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- void RimWellLogPlot::setDepthZoomMinMax(double minimumDepth, double maximumDepth) { m_minVisibleDepth = minimumDepth; m_maxVisibleDepth = maximumDepth; m_minVisibleDepth.uiCapability()->updateConnectedEditors(); m_maxVisibleDepth.uiCapability()->updateConnectedEditors(); applyDepthZoomFromVisibleDepth(); }
//-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- void RimWellLogPlot::updateDepthZoom() { if (m_isAutoScaleDepthEnabled) { applyZoomAllDepths(); } else { applyDepthZoomFromVisibleDepth(); } }
//-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- void RimWellLogPlot::fieldChangedByUi(const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue) { RimViewWindow::fieldChangedByUi(changedField, oldValue, newValue); if (changedField == &m_minVisibleDepth || changedField == &m_maxVisibleDepth) { applyDepthZoomFromVisibleDepth(); m_isAutoScaleDepthEnabled = false; } else if (changedField == &m_isAutoScaleDepthEnabled) { updateDepthZoom(); } else if (changedField == &m_userName) { updateMdiWindowTitle(); } if ( changedField == &m_depthType ) { RimWellAllocationPlot* wellAllocPlot; firstAncestorOrThisOfType(wellAllocPlot); if (wellAllocPlot) wellAllocPlot->loadDataAndUpdate(); else if (isRftPlotChild()) rftPlot()->loadDataAndUpdate(); else updateTracks(); } if ( changedField == &m_depthUnit) { updateTracks(); } if ( changedField == &m_showTrackLegends) { updateTracks(); if (m_viewer) m_viewer->updateChildrenLayout(); } RimWellRftPlot* rftPlot(nullptr); this->firstAncestorOrThisOfType(rftPlot); if (rftPlot) { rftPlot->updateConnectedEditors(); } RimWellPltPlot* pltPlot(nullptr); this->firstAncestorOrThisOfType(pltPlot); if (pltPlot) { pltPlot->updateConnectedEditors(); } }