summaryrefslogtreecommitdiff
path: root/indra/newview/llvoavatarself.cpp
diff options
context:
space:
mode:
authorLoren Shih <seraph@lindenlab.com>2009-11-02 17:28:49 -0500
committerLoren Shih <seraph@lindenlab.com>2009-11-02 17:28:49 -0500
commited48829af44e557459b2b2f0d24cb0e27df328ba (patch)
tree680f08da7fa11d22585389e8f55d30cf8b0159b6 /indra/newview/llvoavatarself.cpp
parent88ec0b0dca6c20d149e0cd5dc466d723964b02bd (diff)
parent7add9de18f3964f0c52f68931bfcb88b9f81966c (diff)
Merge commit.
--HG-- branch : avatar-pipeline
Diffstat (limited to 'indra/newview/llvoavatarself.cpp')
-rw-r--r--indra/newview/llvoavatarself.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp
index 758db538a2..44fd81f0d1 100644
--- a/indra/newview/llvoavatarself.cpp
+++ b/indra/newview/llvoavatarself.cpp
@@ -1080,6 +1080,7 @@ const LLViewerJointAttachment *LLVOAvatarSelf::attachObject(LLViewerObject *view
if (attachment->isObjectAttached(viewer_object))
{
const LLUUID& attachment_id = viewer_object->getItemID();
+ LLAppearanceManager::registerAttachment(attachment_id);
LLViewerInventoryItem *item = gInventory.getItem(attachment_id);
if (item)
{
@@ -1096,12 +1097,12 @@ const LLViewerJointAttachment *LLVOAvatarSelf::attachObject(LLViewerObject *view
//virtual
BOOL LLVOAvatarSelf::detachObject(LLViewerObject *viewer_object)
{
- const LLUUID item_id = viewer_object->getItemID();
+ const LLUUID attachment_id = viewer_object->getItemID();
if (LLVOAvatar::detachObject(viewer_object))
{
// the simulator should automatically handle permission revocation
- stopMotionFromSource(item_id);
+ stopMotionFromSource(attachment_id);
LLFollowCamMgr::setCameraActive(viewer_object->getID(), FALSE);
LLViewerObject::const_child_list_t& child_list = viewer_object->getChildren();
@@ -1127,11 +1128,12 @@ BOOL LLVOAvatarSelf::detachObject(LLViewerObject *viewer_object)
else
{
LLAppearanceManager::dumpCat(LLAppearanceManager::getCOF(),"Removing attachment link:");
- LLAppearanceManager::removeItemLinks(item_id, false);
+ LLAppearanceManager::removeItemLinks(attachment_id, false);
+ LLAppearanceManager::unregisterAttachment(attachment_id);
}
// BAP - needs to change for label to track link.
- gInventory.addChangedMask(LLInventoryObserver::LABEL, item_id);
+ gInventory.addChangedMask(LLInventoryObserver::LABEL, attachment_id);
gInventory.notifyObservers();
return TRUE;
}