mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Merge remote-tracking branch 'refs/remotes/origin/dev'
Conflicts: ApplicationCode/ProjectDataModel/RimEclipseWellCollection.cpp ApplicationCode/Resources/ResInsight.qrc
This commit is contained in:
@@ -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();
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user