mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-27 07:30:20 -05:00
Release 2025.09.0
This commit is contained in:
1 parent
c33402f5ea
commit
917136fec8
1053 files changed
+61952
-11833
No files matched your search
@@ -74,6 +74,30 @@ void RiuPlotMainWindowTools::selectAsCurrentItem( const caf::PdmObject* object )
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
const caf::PdmObject* RiuPlotMainWindowTools::firstVisibleAncestorOrThis( const caf::PdmObject* object )
|
||||
{
|
||||
if ( RiaGuiApplication::isRunning() )
|
||||
{
|
||||
RiuPlotMainWindow* mpw = RiaGuiApplication::instance()->mainPlotWindow();
|
||||
|
||||
auto current = const_cast<caf::PdmObject*>( object );
|
||||
while ( current )
|
||||
{
|
||||
if ( mpw->getTreeViewWithItem( current ) )
|
||||
{
|
||||
return current;
|
||||
}
|
||||
|
||||
current = current->firstAncestorOfType<caf::PdmObject>();
|
||||
}
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
Reference in new issue
Block a user