mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Change API for PdmObjectHandle and PdmFieldHandle
* Refactor interface to PdmObjectHandle and PdmFieldHandle Return objects instead of passing in structures as parameters * Add nodiscard to several functions * Remove redundant this-> * Rename to ptrReferencedObjectsByType
This commit is contained in:
@@ -50,14 +50,12 @@ void RicDeleteItemExec::redo()
|
||||
caf::PdmChildArrayFieldHandle* listField = dynamic_cast<caf::PdmChildArrayFieldHandle*>( field );
|
||||
if ( listField )
|
||||
{
|
||||
std::vector<caf::PdmObjectHandle*> children;
|
||||
listField->children( &children );
|
||||
std::vector<caf::PdmObjectHandle*> children = listField->children();
|
||||
|
||||
caf::PdmObjectHandle* obj = children[m_commandData.m_indexToObject];
|
||||
caf::SelectionManager::instance()->removeObjectFromAllSelections( obj );
|
||||
|
||||
std::vector<caf::PdmObjectHandle*> referringObjects;
|
||||
obj->objectsWithReferringPtrFields( referringObjects );
|
||||
std::vector<caf::PdmObjectHandle*> referringObjects = obj->objectsWithReferringPtrFields();
|
||||
|
||||
if ( m_commandData.m_deletedObjectAsXml().isEmpty() )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user