#4863, #4865 Use autoname in the view dropdowns

This commit is contained in:
Jacob Støren
2019-10-14 12:08:54 +02:00
parent 308b3613b7
commit 440a152089
3 changed files with 10 additions and 13 deletions

View File

@@ -29,20 +29,8 @@ void RiaOptionItemFactory::appendOptionItemFromViewNameAndCaseName( Rim3dView*
{
if ( !view || !optionItems ) return;
QString caseName;
RimCase* rimCase = nullptr;
view->firstAncestorOrThisOfType( rimCase );
if ( rimCase )
{
caseName = rimCase->caseUserDescription();
}
else
{
caseName = "<Unnamed case>";
}
QString displayName = caseName + " : " + view->name();
QString displayName = view->autoName();
caf::QIconProvider iconProvider = view->uiCapability()->uiIconProvider();

View File

@@ -219,6 +219,14 @@ QString Rim3dView::name() const
return m_nameConfig->customName();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
QString Rim3dView::autoName() const
{
return m_nameConfig->name();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------

View File

@@ -109,6 +109,7 @@ public:
void setName( const QString& name );
QString name() const;
QString autoName() const;
// Implementation of RiuViewerToViewInterface
cvf::Color3f backgroundColor() const override