mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#8078 Intersections: Improve names of surface items
This commit is contained in:
@@ -456,7 +456,7 @@ void RimEclipseView::onCreateDisplayModel()
|
||||
else if ( this->cellResult()->hasStaticResult() || this->cellEdgeResult()->hasResult() ||
|
||||
this->eclipsePropertyFilterCollection()->hasActiveFilters() ||
|
||||
this->intersectionCollection()->hasAnyActiveSeparateResults() ||
|
||||
this->surfaceInViewCollection()->hasAnyActiveSeparateResults() )
|
||||
( this->surfaceInViewCollection() && this->surfaceInViewCollection()->hasAnyActiveSeparateResults() ) )
|
||||
{
|
||||
// The one and only static result entry
|
||||
timeStepIndices.push_back( 0 );
|
||||
|
||||
@@ -257,17 +257,24 @@ QString RimSurfaceIntersectionBand::objectName() const
|
||||
{
|
||||
QString text;
|
||||
|
||||
auto firstSurface = surfaces[0];
|
||||
RimSurfaceCollection* surfColl = nullptr;
|
||||
firstSurface->firstAncestorOfType( surfColl );
|
||||
if ( surfColl )
|
||||
auto firstSurface = surfaces[0];
|
||||
if ( firstSurface )
|
||||
{
|
||||
text += surfColl->collectionName();
|
||||
RimSurfaceCollection* surfColl = nullptr;
|
||||
firstSurface->firstAncestorOfType( surfColl );
|
||||
if ( surfColl )
|
||||
{
|
||||
text += surfColl->collectionName();
|
||||
}
|
||||
}
|
||||
|
||||
if ( surfaces[0] )
|
||||
text += "( " + surfaces[0]->userDescription() + " - " + surfaces[1]->userDescription() + " )";
|
||||
return text;
|
||||
auto secondSurface = surfaces[0];
|
||||
|
||||
if ( firstSurface && secondSurface )
|
||||
{
|
||||
text += "( " + firstSurface->fullName() + " - " + secondSurface->fullName() + " )";
|
||||
return text;
|
||||
}
|
||||
}
|
||||
|
||||
return "Surface Band";
|
||||
|
||||
@@ -128,17 +128,17 @@ QString RimSurfaceIntersectionCurve::objectName() const
|
||||
{
|
||||
if ( m_surface1() )
|
||||
{
|
||||
QString text;
|
||||
|
||||
RimSurfaceCollection* surfColl = nullptr;
|
||||
m_surface1()->firstAncestorOfType( surfColl );
|
||||
if ( surfColl )
|
||||
RimEnsembleSurface* ensembleSurface = nullptr;
|
||||
m_surface1()->firstAncestorOfType( ensembleSurface );
|
||||
if ( ensembleSurface )
|
||||
{
|
||||
text += surfColl->collectionName();
|
||||
QString text;
|
||||
text += ensembleSurface->collectionName();
|
||||
text += "( " + m_surface1()->fullName() + " )";
|
||||
return text;
|
||||
}
|
||||
|
||||
if ( m_surface1() ) text += "( " + m_surface1()->userDescription() + " )";
|
||||
return text;
|
||||
return m_surface1()->fullName();
|
||||
}
|
||||
|
||||
return "Surface Curve";
|
||||
@@ -160,7 +160,7 @@ void RimSurfaceIntersectionCurve::appendOptionItemsForSources( int
|
||||
|
||||
for ( auto surf : currentCollection->surfaces() )
|
||||
{
|
||||
auto itemInfo = caf::PdmOptionItemInfo( surf->userDescription(), surf, false, surfaceIcon );
|
||||
auto itemInfo = caf::PdmOptionItemInfo( surf->fullName(), surf, false, surfaceIcon );
|
||||
itemInfo.setLevel( currentLevel + 1 );
|
||||
options.push_back( itemInfo );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user