Skip to content

Commit

Permalink
(#396) Using toggle field of well log plots to toggle visibility
Browse files Browse the repository at this point in the history
  • Loading branch information
palhagen committed Aug 31, 2015
1 parent d0b6e54 commit eaff6f8
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions ApplicationCode/ProjectDataModel/RimWellLogPlot.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,15 @@ void RimWellLogPlot::updateViewerWidget()
RiuMainWindow::instance()->addWellLogViewer(m_viewer);
isViewerCreated = true;
}

if (m_viewer->parentWidget())
{
m_viewer->parentWidget()->showMaximized();
}
else
{
m_viewer->showMaximized();
}

RiuMainWindow::instance()->setActiveWellLogViewer(m_viewer);
}
Expand All @@ -87,6 +96,20 @@ void RimWellLogPlot::fieldChangedByUi(const caf::PdmFieldHandle* changedField, c
{
updateViewerWidget();
}
else
{
if (m_viewer)
{
if (m_viewer->parentWidget())
{
m_viewer->parentWidget()->hide();
}
else
{
m_viewer->hide();
}
}
}
}
}

Expand Down

0 comments on commit eaff6f8

Please sign in to comment.