Implement/match ViewManager::RemoveAll (#616)

* Implement/match ViewManager::RemoveAll

* Use const_iterator

* const

* Naming
This commit is contained in:
Christian Semmler
2024-03-02 14:26:19 -05:00
committed by GitHub
parent 6de17cf1b6
commit de5cd98b76
7 changed files with 52 additions and 18 deletions

View File

@@ -829,10 +829,10 @@ void LegoOmni::DeleteObject(MxDSAction& p_dsAction)
LegoROI* LegoOmni::FindROI(const char* p_name)
{
ViewManager* viewManager = GetVideoManager()->Get3DManager()->GetLego3DView()->GetViewManager();
CompoundObject& unk0x08 = viewManager->GetUnknown0x08();
const CompoundObject& rois = viewManager->GetROIs();
if (p_name != NULL && *p_name != '\0' && unk0x08.size() > 0) {
for (CompoundObject::iterator it = unk0x08.begin(); it != unk0x08.end(); it++) {
if (p_name != NULL && *p_name != '\0' && rois.size() > 0) {
for (CompoundObject::const_iterator it = rois.begin(); it != rois.end(); it++) {
LegoROI* roi = (LegoROI*) *it;
const char* name = roi->GetName();