Allow linking of contour map views

* Place copy of contour map in correct collection
* Allow linking of contour maps
* Improve handling of contour views and 3D views
* Guard nullptr
* Guard assert seen on Linux
* Zoom all on contour map when unlinked to reset zoom
If a contour map is linked to a 3D view, the view can get distorted. Call ZoomAll to reset to sensible defaults.

* Remove default rainbow legend
This commit is contained in:
Magne Sjaastad authored and GitHub committed 2022-11-04 15:48:25 +01:00
1 parent f77b3673b0
commit d4086ee371
20 files changed
+157 -159

No files matched your search

@@ -23,7 +23,6 @@
#include "RiaOptionItemFactory.h"
#include "RimCase.h"
#include "RimEclipseContourMapView.h"
#include "RimGridView.h"
#include "RimViewLinker.h"
@@ -79,17 +78,7 @@ RimGridView* RicLinkVisibleViewsFeatureUi::masterView()
//--------------------------------------------------------------------------------------------------
std::vector<RimGridView*> RicLinkVisibleViewsFeatureUi::masterViewCandidates() const
{
std::vector<RimGridView*> masterCandidates;
// Set Active view as master view if the active view isn't a contour map.
for ( size_t i = 0; i < m_allViews.size(); i++ )
{
RimEclipseContourMapView* contourMap = dynamic_cast<RimEclipseContourMapView*>( m_allViews[i] );
if ( contourMap == nullptr )
{
masterCandidates.push_back( m_allViews[i] );
}
}
return masterCandidates;
return m_allViews;
}
//--------------------------------------------------------------------------------------------------