Merge remote-tracking branch 'refs/remotes/origin/dev'

Conflicts:
	ApplicationCode/ProjectDataModel/RimEclipseWellCollection.cpp
	ApplicationCode/Resources/ResInsight.qrc
This commit is contained in:
Magne Sjaastad
2017-02-16 10:18:39 +01:00
128 changed files with 7589 additions and 3420 deletions

View File

@@ -1121,6 +1121,8 @@ void RimEclipseView::syncronizeWellsWithResults()
well->setWellResults(NULL, -1);
}
bool isAnyWellCreated = false;
// Find corresponding well from well result, or create a new
for (size_t wIdx = 0; wIdx < wellResults.size(); ++wIdx)
@@ -1131,6 +1133,8 @@ void RimEclipseView::syncronizeWellsWithResults()
{
well = new RimEclipseWell;
well->name = wellResults[wIdx]->m_wellName;
isAnyWellCreated = true;
}
newWells.push_back(well);
@@ -1153,10 +1157,16 @@ void RimEclipseView::syncronizeWellsWithResults()
// Set the new wells into the field.
this->wellCollection()->wells().insert(0, newWells);
// Make sure all the wells have their reservoirView ptr setup correctly
this->wellCollection()->setReservoirView(this);
// Sort wells before assigning colors, as the colors are distributed based on sorting
this->wellCollection()->sortWellsByName();
if (isAnyWellCreated)
{
this->wellCollection()->assignDefaultWellColors();
}
}
//--------------------------------------------------------------------------------------------------