mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-12 16:32:12 -05:00
Total Well Log Allocation Pie Chart: Guarded not yet created widget
This commit is contained in:
1 parent
45dc7a1c08
commit
6aea418084
1 file changed
+12
-5
@@ -143,10 +143,13 @@ QString RimTotalWellAllocationPlot::description() const
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimTotalWellAllocationPlot::addSlice(const QString& name, const cvf::Color3f& color, float value)
|
||||
{
|
||||
QColor sliceColor(color.rByte(), color.gByte(), color.bByte());
|
||||
if ( m_wellTotalAllocationPlotWidget )
|
||||
{
|
||||
QColor sliceColor(color.rByte(), color.gByte(), color.bByte());
|
||||
|
||||
m_wellTotalAllocationPlotWidget->addItem(name, sliceColor, value);
|
||||
m_wellTotalAllocationPlotWidget->update();
|
||||
m_wellTotalAllocationPlotWidget->addItem(name, sliceColor, value);
|
||||
m_wellTotalAllocationPlotWidget->update();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -155,8 +158,11 @@ void RimTotalWellAllocationPlot::addSlice(const QString& name, const cvf::Color3
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimTotalWellAllocationPlot::clearSlices()
|
||||
{
|
||||
m_wellTotalAllocationPlotWidget->clear();
|
||||
m_wellTotalAllocationPlotWidget->update();
|
||||
if ( m_wellTotalAllocationPlotWidget )
|
||||
{
|
||||
m_wellTotalAllocationPlotWidget->clear();
|
||||
m_wellTotalAllocationPlotWidget->update();
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -164,6 +170,7 @@ void RimTotalWellAllocationPlot::clearSlices()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimTotalWellAllocationPlot::loadDataAndUpdate()
|
||||
{
|
||||
updateMdiWindowVisibility();
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user