Update name in radar if somebody nearby changes their display name

meow-7.2.2
Ansariel 2013-04-19 08:38:56 +02:00
parent 6d218b8d0e
commit d7aa745b76
3 changed files with 22 additions and 0 deletions

View File

@ -1016,3 +1016,12 @@ void FSRadar::updateNames()
it->second->updateName();
}
}
void FSRadar::updateName(const LLUUID& avatar_id)
{
FSRadarEntry* entry = getEntry(avatar_id);
if (entry)
{
entry->updateName();
}
}

View File

@ -64,6 +64,7 @@ public:
void teleportToAvatar(const LLUUID& targetAv);
void requestRadarChannelAlertSync();
void updateNames();
void updateName(const LLUUID& avatar_id);
static void onRadarNameFmtClicked(const LLSD& userdata);
static bool radarNameFmtCheck(const LLSD& userdata);

View File

@ -39,6 +39,8 @@
#include "llhttpnode.h"
#include "llnotificationsutil.h"
#include "llui.h" // getLanguage()
#include "fsradar.h"
#include "lggcontactsets.h"
#include "llviewercontrol.h"
@ -215,6 +217,16 @@ class LLDisplayNameUpdate : public LLHTTPNode
{
LLViewerDisplayName::sNameChangedSignal();
}
// <FS:Ansariel> Update name in radar
else
{
FSRadar* radar = FSRadar::getInstance();
if (radar)
{
radar->updateName(agent_id);
}
}
// </FS:Ansariel>
}
};