mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Fix bug in QwtPlotWidget highlight reset
QwtPlotShapeItem objects were not reset
This commit is contained in:
committed by
Magne Sjaastad
parent
c916459a55
commit
3c296202c2
@@ -1055,7 +1055,7 @@ void RiuQwtPlotWidget::resetPlotItemHighlighting( bool doUpdateCurveOrder )
|
||||
{
|
||||
if ( !m_originalZValues.empty() )
|
||||
{
|
||||
auto plotItemList = m_plot->itemList();
|
||||
const auto& plotItemList = m_plot->itemList();
|
||||
for ( QwtPlotItem* plotItem : plotItemList )
|
||||
{
|
||||
if ( auto* plotCurve = dynamic_cast<QwtPlotCurve*>( plotItem ) )
|
||||
@@ -1071,7 +1071,13 @@ void RiuQwtPlotWidget::resetPlotItemHighlighting( bool doUpdateCurveOrder )
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
m_originalZValues.clear();
|
||||
}
|
||||
|
||||
const auto& plotItemList = m_plot->itemList();
|
||||
for ( QwtPlotItem* plotItem : plotItemList )
|
||||
{
|
||||
auto* plotShapeItem = dynamic_cast<QwtPlotShapeItem*>( plotItem );
|
||||
if ( plotShapeItem )
|
||||
{
|
||||
@@ -1085,8 +1091,6 @@ void RiuQwtPlotWidget::resetPlotItemHighlighting( bool doUpdateCurveOrder )
|
||||
plotShapeItem->setZ( plotShapeItem->z() - 100.0 );
|
||||
}
|
||||
}
|
||||
m_originalZValues.clear();
|
||||
}
|
||||
|
||||
resetPlotAxisHighlighting();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user