mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#4240 Project Tree : Keep selection when clicking on cells
When current selection in project tree is part of a 3D view, update the selection accordingly. If an item unrelated to 3D view is selected, do nothing when clicking in the 3D view.
This commit is contained in:
@@ -1240,6 +1240,12 @@ void RiuMainWindow::slotSubWindowActivated(QMdiSubWindow* subWindow)
|
|||||||
RimProject* proj = RiaApplication::instance()->project();
|
RimProject* proj = RiaApplication::instance()->project();
|
||||||
if (!proj) return;
|
if (!proj) return;
|
||||||
|
|
||||||
|
if (!caf::SelectionManager::instance()->selectedItemAncestorOfType<Rim3dView>())
|
||||||
|
{
|
||||||
|
// Do not try to manipulate the tree selection if no object part of a 3D view is currently selected
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
// Find the activated 3D view
|
// Find the activated 3D view
|
||||||
|
|
||||||
Rim3dView* activatedView = nullptr;
|
Rim3dView* activatedView = nullptr;
|
||||||
|
|||||||
Reference in New Issue
Block a user