summaryrefslogtreecommitdiff
path: root/indra/newview/llinventorymodel.cpp
diff options
context:
space:
mode:
authorLoren Shih <seraph@lindenlab.com>2010-03-26 14:33:48 -0400
committerLoren Shih <seraph@lindenlab.com>2010-03-26 14:33:48 -0400
commit46fe5d49caef6c8db3df9d88f0d0ec773ef28095 (patch)
tree87f8ae2f01d871b23b9d1c1ef9f9ce736dbc8c98 /indra/newview/llinventorymodel.cpp
parent0bcfbde3a4265d7963ea501622e512de8eab7f61 (diff)
EXT-6536 : Make LLVOAvatarSelf a singleton
Superficial cleanup so that all instances of gAgent.getAvatarObject() use "LLVOAvatarSelf *avatarp = gAgent.getAvatarObject".
Diffstat (limited to 'indra/newview/llinventorymodel.cpp')
-rw-r--r--indra/newview/llinventorymodel.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp
index 83a466a243..1f9840923c 100644
--- a/indra/newview/llinventorymodel.cpp
+++ b/indra/newview/llinventorymodel.cpp
@@ -3774,7 +3774,7 @@ bool LLInventoryCollectFunctor::itemTransferCommonlyAllowed(LLInventoryItem* ite
return false;
bool allowed = false;
- LLVOAvatarSelf* my_avatar = NULL;
+ LLVOAvatarSelf* avatarp = gAgent.getAvatarObject();
switch(item->getType())
{
@@ -3783,8 +3783,7 @@ bool LLInventoryCollectFunctor::itemTransferCommonlyAllowed(LLInventoryItem* ite
break;
case LLAssetType::AT_OBJECT:
- my_avatar = gAgent.getAvatarObject();
- if(my_avatar && !my_avatar->isWearingAttachment(item->getUUID()))
+ if(avatarp && !avatarp->isWearingAttachment(item->getUUID()))
{
allowed = true;
}