Improve method name to reflect implementation.

RimColorLegendCollection::allColorLegeds is better than
RimColorLegendCollection::customColorLegends since method returns both kinds
of color legends.
This commit is contained in:
Kristian Bendiksen authored and Magne Sjaastad committed 2020-05-24 17:26:51 +02:00
1 parent 0b9577df71
commit 30ee125749
4 files changed
+5 -5

No files matched your search

@@ -122,7 +122,7 @@ void RimColorLegendCollection::createStandardColorLegends()
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
std::vector<RimColorLegend*> RimColorLegendCollection::customColorLegends() const
std::vector<RimColorLegend*> RimColorLegendCollection::allColorLegends() const
{
std::vector<RimColorLegend*> allLegends;
@@ -155,7 +155,7 @@ void RimColorLegendCollection::fieldChangedByUi( const caf::PdmFieldHandle* chan
//--------------------------------------------------------------------------------------------------
RimColorLegend* RimColorLegendCollection::findByName( const QString& name ) const
{
std::vector<RimColorLegend*> allLegends = customColorLegends();
std::vector<RimColorLegend*> allLegends = allColorLegends();
for ( auto legend : allLegends )
{
if ( legend->colorLegendName() == name )
@@ -50,7 +50,7 @@ public:
void deleteCustomColorLegends();
std::vector<RimColorLegend*> customColorLegends() const;
std::vector<RimColorLegend*> allColorLegends() const;
void fieldChangedByUi( const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue ) override;
@@ -1064,7 +1064,7 @@ QList<caf::PdmOptionItemInfo>
{
RimProject* project = RimProject::current();
RimColorLegendCollection* colorLegendCollection = project->colorLegendCollection();
std::vector<RimColorLegend*> colorLegends = colorLegendCollection->customColorLegends();
std::vector<RimColorLegend*> colorLegends = colorLegendCollection->allColorLegends();
for ( RimColorLegend* colorLegend : colorLegends )
{
@@ -1038,7 +1038,7 @@ QList<caf::PdmOptionItemInfo> RimWellLogTrack::calculateValueOptions( const caf:
{
RimProject* project = RimProject::current();
RimColorLegendCollection* colorLegendCollection = project->colorLegendCollection();
std::vector<RimColorLegend*> colorLegends = colorLegendCollection->customColorLegends();
std::vector<RimColorLegend*> colorLegends = colorLegendCollection->allColorLegends();
for ( RimColorLegend* colorLegend : colorLegends )
{