summaryrefslogtreecommitdiff
path: root/indra/newview/llviewerobjectlist.cpp
diff options
context:
space:
mode:
authorWilliam Todd Stinson <stinson@lindenlab.com>2012-11-02 17:56:35 -0700
committerWilliam Todd Stinson <stinson@lindenlab.com>2012-11-02 17:56:35 -0700
commit3b39ec165aa837d02bf1bf57ff8f3aab3229659c (patch)
treefd718fca322b7c4419a3eaee4a6940f54f8bd659 /indra/newview/llviewerobjectlist.cpp
parent6e2b3527cc95b92bf136b65fd2ee344d4c879faa (diff)
parent1f305e8624e130683fc5d8fceac7a8159515376b (diff)
Pull and merge from ssh://hg@bitbucket.org/lindenlab/viewer-beta.
Diffstat (limited to 'indra/newview/llviewerobjectlist.cpp')
-rw-r--r--indra/newview/llviewerobjectlist.cpp15
1 files changed, 9 insertions, 6 deletions
diff --git a/indra/newview/llviewerobjectlist.cpp b/indra/newview/llviewerobjectlist.cpp
index e399b45cba..9e5c3f14f8 100644
--- a/indra/newview/llviewerobjectlist.cpp
+++ b/indra/newview/llviewerobjectlist.cpp
@@ -948,7 +948,7 @@ void LLViewerObjectList::update(LLAgent &agent, LLWorld &world)
std::vector<LLViewerObject*>::iterator idle_end = idle_list.begin()+idle_count;
if (gSavedSettings.getBOOL("FreezeTime"))
- {
+ {
for (std::vector<LLViewerObject*>::iterator iter = idle_list.begin();
iter != idle_end; iter++)
@@ -969,14 +969,14 @@ void LLViewerObjectList::update(LLAgent &agent, LLWorld &world)
llassert(objectp->isActive());
objectp->idleUpdate(agent, world, frame_time);
- }
+ }
//update flexible objects
LLVolumeImplFlexible::updateClass();
//update animated textures
LLViewerTextureAnim::updateClass();
- }
+ }
@@ -1401,9 +1401,9 @@ void LLViewerObjectList::removeFromActiveList(LLViewerObject* objectp)
mActiveObjects[idx]->setListIndex(idx);
}
- mActiveObjects.pop_back();
+ mActiveObjects.pop_back();
+ }
}
-}
void LLViewerObjectList::updateActive(LLViewerObject *objectp)
{
@@ -1446,8 +1446,11 @@ void LLViewerObjectList::updateActive(LLViewerObject *objectp)
}
}
- llassert(objectp->isActive() || objectp->getListIndex() == -1);
+ //post condition: if object is active, it must be on the active list
+ llassert(!active || std::find(mActiveObjects.begin(), mActiveObjects.end(), objectp) != mActiveObjects.end());
+ //post condition: if object is not active, it must not be on the active list
+ llassert(active || std::find(mActiveObjects.begin(), mActiveObjects.end(), objectp) == mActiveObjects.end());
}
void LLViewerObjectList::updateObjectCost(LLViewerObject* object)