summaryrefslogtreecommitdiff
path: root/indra/newview/llagent.cpp
diff options
context:
space:
mode:
authorMonroe Linden <monroe@lindenlab.com>2010-08-13 14:01:51 -0700
committerMonroe Linden <monroe@lindenlab.com>2010-08-13 14:01:51 -0700
commit1dd490ff88e7ee54b689e01529ffb88a3fc7491b (patch)
tree487ab551a0fc567bd94672c4a7e06625cc8b99ec /indra/newview/llagent.cpp
parent7f085551431aa912a4a2be28e2b714d12f723809 (diff)
parent4ef75f35c195a4e2657a0e01d6b92cd40e6779f5 (diff)
Automated merge with ssh://hg.lindenlab.com/dessie/viewer-public
Diffstat (limited to 'indra/newview/llagent.cpp')
-rw-r--r--indra/newview/llagent.cpp27
1 files changed, 26 insertions, 1 deletions
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp
index e85d108bb2..70bda3893e 100644
--- a/indra/newview/llagent.cpp
+++ b/indra/newview/llagent.cpp
@@ -44,6 +44,7 @@
#include "llcallingcard.h"
#include "llchannelmanager.h"
#include "llconsole.h"
+#include "llfirstuse.h"
#include "llfloatercamera.h"
#include "llfloaterreg.h"
#include "llfloatertools.h"
@@ -232,8 +233,9 @@ LLAgent::LLAgent() :
mControlsTakenPassedOnCount[i] = 0;
}
-
mListener.reset(new LLAgentListener(*this));
+
+ mMoveTimer.stop();
}
// Requires gSavedSettings to be initialized.
@@ -242,6 +244,8 @@ LLAgent::LLAgent() :
//-----------------------------------------------------------------------------
void LLAgent::init()
{
+ mMoveTimer.start();
+
gSavedSettings.declareBOOL("SlowMotionAnimation", FALSE, "Declared in code", FALSE);
gSavedSettings.getControl("SlowMotionAnimation")->getSignal()->connect(boost::bind(&handleSlowMotionAnimation, _2));
@@ -306,6 +310,9 @@ void LLAgent::ageChat()
//-----------------------------------------------------------------------------
void LLAgent::moveAt(S32 direction, bool reset)
{
+ mMoveTimer.reset();
+ LLFirstUse::notMoving(false);
+
// age chat timer so it fades more quickly when you are intentionally moving
ageChat();
@@ -331,6 +338,9 @@ void LLAgent::moveAt(S32 direction, bool reset)
//-----------------------------------------------------------------------------
void LLAgent::moveAtNudge(S32 direction)
{
+ mMoveTimer.reset();
+ LLFirstUse::notMoving(false);
+
// age chat timer so it fades more quickly when you are intentionally moving
ageChat();
@@ -353,6 +363,9 @@ void LLAgent::moveAtNudge(S32 direction)
//-----------------------------------------------------------------------------
void LLAgent::moveLeft(S32 direction)
{
+ mMoveTimer.reset();
+ LLFirstUse::notMoving(false);
+
// age chat timer so it fades more quickly when you are intentionally moving
ageChat();
@@ -375,6 +388,9 @@ void LLAgent::moveLeft(S32 direction)
//-----------------------------------------------------------------------------
void LLAgent::moveLeftNudge(S32 direction)
{
+ mMoveTimer.reset();
+ LLFirstUse::notMoving(false);
+
// age chat timer so it fades more quickly when you are intentionally moving
ageChat();
@@ -397,6 +413,9 @@ void LLAgent::moveLeftNudge(S32 direction)
//-----------------------------------------------------------------------------
void LLAgent::moveUp(S32 direction)
{
+ mMoveTimer.reset();
+ LLFirstUse::notMoving(false);
+
// age chat timer so it fades more quickly when you are intentionally moving
ageChat();
@@ -1534,6 +1553,12 @@ void LLAgent::propagate(const F32 dt)
//-----------------------------------------------------------------------------
void LLAgent::updateAgentPosition(const F32 dt, const F32 yaw_radians, const S32 mouse_x, const S32 mouse_y)
{
+ if (mMoveTimer.getStarted() && mMoveTimer.getElapsedTimeF32() > gSavedSettings.getF32("NotMovingHintTimeout"))
+ {
+ LLFirstUse::notMoving();
+ mMoveTimer.stop();
+ }
+
propagate(dt);
// static S32 cameraUpdateCount = 0;