Cancel pose stand when quitting.

This fixes the bug that if you Quit while in the Singularity -> Pose
Stand, then you are permanently hovering over the group until you go
into Advanced -> Debug Settings and reset AscentAvatarZModifier.

It also fixes that before, when you changed AscentAvatarZModifier
in Advanced -> Debug Settings then you saw no effect (until the
viewer would sent an AvatarAppearance message.

After this patch, changing any of the AscentAvatar*Modifier settings
has immediate visible effect, and a pose stand (Z-offset) is reset
when quitting.
This commit is contained in:
Aleric Inglewood
2011-05-17 02:42:06 +02:00
parent addb7a559e
commit 3656939269
4 changed files with 27 additions and 4 deletions

View File

@@ -548,6 +548,7 @@ bool handleAscentSelfTag(const LLSD& newvalue)
gAgent.getAvatarObject()->mClientTag = "";
return true;
}
bool handleAscentGlobalTag(const LLSD& newvalue)
{
S32 object_count = gObjectList.getNumObjects();
@@ -560,6 +561,13 @@ bool handleAscentGlobalTag(const LLSD& newvalue)
return true;
}
bool handleAscentAvatarModifier(const LLSD& newvalue)
{
llinfos << "Calling gAgent.sendAgentSetAppearance() because AscentAvatar*Modifier changed." << llendl;
gAgent.sendAgentSetAppearance();
return true;
}
// [Ansariel: Display name support]
static bool handlePhoenixNameSystemChanged(const LLSD& newvalue)
{
@@ -725,6 +733,9 @@ void settings_setup_listeners()
gSavedSettings.getControl("AscentReportClientUUID")->getSignal()->connect(boost::bind(&handleAscentSelfTag,_1));
gSavedSettings.getControl("AscentShowFriendsTag")->getSignal()->connect(boost::bind(&handleAscentGlobalTag,_1));
gSavedSettings.getControl("AscentUseStatusColors")->getSignal()->connect(boost::bind(&handleAscentGlobalTag,_1));
gSavedSettings.getControl("AscentAvatarXModifier")->getSignal()->connect(boost::bind(&handleAscentAvatarModifier, _1));
gSavedSettings.getControl("AscentAvatarYModifier")->getSignal()->connect(boost::bind(&handleAscentAvatarModifier, _1));
gSavedSettings.getControl("AscentAvatarZModifier")->getSignal()->connect(boost::bind(&handleAscentAvatarModifier, _1));
// [Ansariel: Display name support]
gSavedSettings.getControl("PhoenixNameSystem")->getSignal()->connect(boost::bind(&handlePhoenixNameSystemChanged, _1));