summaryrefslogtreecommitdiff
path: root/indra/newview/llmoveview.cpp
diff options
context:
space:
mode:
authorLoren Shih <seraph@lindenlab.com>2010-03-29 12:00:26 -0400
committerLoren Shih <seraph@lindenlab.com>2010-03-29 12:00:26 -0400
commit94e6e10739c8321b6fb651a109901380ef92975a (patch)
tree629fec2892c2bb0bce4f35f42ef4cad54408f174 /indra/newview/llmoveview.cpp
parent46fe5d49caef6c8db3df9d88f0d0ec773ef28095 (diff)
EXT-6536 : Make LLVOAvatarSelf a singleton
Superficial cleanup to replace all instances of "LLVOAvatarSelf *avatarp = gAgent.getAvatarObject" with "gAgentAvatar".
Diffstat (limited to 'indra/newview/llmoveview.cpp')
-rw-r--r--indra/newview/llmoveview.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/indra/newview/llmoveview.cpp b/indra/newview/llmoveview.cpp
index 58fac14349..b47acefc76 100644
--- a/indra/newview/llmoveview.cpp
+++ b/indra/newview/llmoveview.cpp
@@ -42,7 +42,7 @@
#include "llagent.h"
#include "llagentcamera.h"
-#include "llvoavatarself.h" // to check gAgent.getAvatarObject()->isSitting()
+#include "llvoavatarself.h" // to check gAgentAvatar->isSitting()
#include "llbottomtray.h"
#include "llbutton.h"
#include "llfloaterreg.h"
@@ -332,7 +332,7 @@ void LLFloaterMove::setMovementMode(const EMovementMode mode)
updateButtonsWithMovementMode(mode);
bool bHideModeButtons = MM_FLY == mode
- || (gAgent.getAvatarObject() && gAgent.getAvatarObject()->isSitting());
+ || (isAgentAvatarValid() && gAgentAvatar->isSitting());
showModeButtons(!bHideModeButtons);
@@ -388,9 +388,9 @@ void LLFloaterMove::initMovementMode()
}
setMovementMode(initMovementMode);
- if (gAgent.getAvatarObject())
+ if (isAgentAvatarValid())
{
- setEnabled(!gAgent.getAvatarObject()->isSitting());
+ setEnabled(!gAgentAvatar->isSitting());
}
}
@@ -491,7 +491,7 @@ void LLFloaterMove::onOpen(const LLSD& key)
showModeButtons(FALSE);
}
- if (gAgent.getAvatarObject() && gAgent.getAvatarObject()->isSitting())
+ if (isAgentAvatarValid() && gAgentAvatar->isSitting())
{
setSittingMode(TRUE);
showModeButtons(FALSE);