Work in progress

This commit is contained in:
jonjenssen authored and JJ committed 2026-06-17 13:55:32 +02:00
1 parent 650bac4002
commit 797d9ac2db
10 files changed
+70 -22

No files matched your search

@@ -774,7 +774,7 @@ std::vector<RimViewWindow*> RiuPlotMainWindow::viewWindows()
for ( auto v : RimProject::current()->descendantsOfType<RimPlotWindow>() )
{
views.push_back( v );
if ( v->dockWidget() ) views.push_back( v );
}
return views;
@@ -913,27 +913,29 @@ void RiuPlotMainWindow::selectedObjectsChanged( caf::PdmUiTreeView* projectTree,
if ( selectedWindow )
{
if ( selectedWindow->viewWidget() )
{
setBlockViewSelectionOnSubWindowActivated( true );
setActiveViewer( selectedWindow->dockWindowName() );
setBlockViewSelectionOnSubWindowActivated( false );
}
m_activePlotViewWindow = selectedWindow;
if ( firstSelectedObject )
if ( auto multiSummaryPlot = firstSelectedObject->firstAncestorOrThisOfType<RimSummaryMultiPlot>() )
{
auto multiSummaryPlot = firstSelectedObject->firstAncestorOrThisOfType<RimSummaryMultiPlot>();
if ( multiSummaryPlot )
{
updateMultiPlotToolBar();
setBlockViewSelectionOnSubWindowActivated( true );
setActiveViewer( multiSummaryPlot->dockWindowName() );
setBlockViewSelectionOnSubWindowActivated( false );
auto summaryPlot = firstSelectedObject->firstAncestorOrThisOfType<RimSummaryPlot>();
if ( summaryPlot )
{
multiSummaryPlot->makeSureIsVisible( summaryPlot );
}
updateMultiPlotToolBar();
auto summaryPlot = firstSelectedObject->firstAncestorOrThisOfType<RimSummaryPlot>();
if ( summaryPlot )
{
multiSummaryPlot->makeSureIsVisible( summaryPlot );
}
}
else
{
if ( selectedWindow->dockWidget() )
{
setBlockViewSelectionOnSubWindowActivated( true );
setActiveViewer( selectedWindow->dockWindowName() );
setBlockViewSelectionOnSubWindowActivated( false );
}
}
@@ -987,9 +989,11 @@ void RiuPlotMainWindow::customMenuRequested( const QPoint& pos )
//--------------------------------------------------------------------------------------------------
void RiuPlotMainWindow::dragEnterEvent( QDragEnterEvent* event )
{
// QPoint curpos = m_mdiArea->mapFromGlobal( QCursor::pos() );
// if ( m_mdiArea->rect().contains( curpos ) ) event->acceptProposedAction();
if ( m_centralDockWidget != nullptr )
{
QPoint curpos = m_centralDockWidget->mapFromGlobal( QCursor::pos() );
if ( m_centralDockWidget->rect().contains( curpos ) ) event->acceptProposedAction();
}
}
//--------------------------------------------------------------------------------------------------