mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Merge pull request #9048 from OPM/9047-performance-avoid-update-project
- Avoid update of project when creating new objects - Added icon resource cache - Avoid use of descendantsIncludingThisOfType()
This commit is contained in:
@@ -107,6 +107,8 @@ void RicCreateMultipleFracturesFeature::slotAppendFractures()
|
||||
RiuCreateMultipleFractionsUi* multipleFractionsUi = this->multipleFractionsUi();
|
||||
if ( !multipleFractionsUi ) return;
|
||||
|
||||
std::set<RimWellPathFractureCollection*> fractureCollectionToUpdate;
|
||||
|
||||
auto items = multipleFractionsUi->locationsForNewFractures();
|
||||
for ( auto item : items )
|
||||
{
|
||||
@@ -127,6 +129,7 @@ void RicCreateMultipleFracturesFeature::slotAppendFractures()
|
||||
|
||||
RimWellPathFracture* fracture = new RimWellPathFracture();
|
||||
fractureCollection->addFracture( fracture );
|
||||
fractureCollectionToUpdate.insert( fractureCollection );
|
||||
|
||||
fracture->setFractureUnit( item.wellPath->unitSystem() );
|
||||
fracture->setMeasuredDepth( item.measuredDepth );
|
||||
@@ -145,7 +148,11 @@ void RicCreateMultipleFracturesFeature::slotAppendFractures()
|
||||
RiaApplication* app = RiaApplication::instance();
|
||||
RimProject* proj = app->project();
|
||||
|
||||
proj->updateConnectedEditors();
|
||||
for ( auto coll : fractureCollectionToUpdate )
|
||||
{
|
||||
coll->updateConnectedEditors();
|
||||
}
|
||||
|
||||
proj->reloadCompletionTypeResultsInAllViews();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user