Fixed crashes after merge when trying to access the people panel

master
Ansariel 2012-01-21 14:07:03 +01:00
parent b4d00f3003
commit cce2e278d0
5 changed files with 8 additions and 8 deletions

View File

@ -94,7 +94,7 @@ FSLSLBridgeRequestRadarPosResponder::FSLSLBridgeRequestRadarPosResponder()
}
void FSLSLBridgeRequestRadarPosResponder::result(const LLSD& content)
{
LLPanel* panel_people = LLFloaterSidePanelContainer::getPanel("panel_people");
LLPanel* panel_people = LLFloaterSidePanelContainer::getPanel("people", "panel_people");
if (panel_people)
{
LLAvatarList* nearbyList = ((LLPanelPeople*)panel_people)->getNearbyList();

View File

@ -821,7 +821,7 @@ BOOL LLNetMap::handleToolTipAgent(const LLUUID& avatar_id)
// Ansariel: Try to get distance from the nearby people panel
// aka radar. This usually contains better data,
// especially when above 1020m.
LLPanel* panel_people = LLFloaterSidePanelContainer::getPanel("panel_people");
LLPanel* panel_people = LLFloaterSidePanelContainer::getPanel("people", "panel_people");
if (panel_people != NULL)
{
LLAvatarListItem* avatar_list_item = ((LLPanelPeople*)panel_people)->getNearbyList()->getAvatarListItem(avatar_id);
@ -1282,7 +1282,7 @@ void LLNetMap::startTracking()
{
if (mClosestAgentAtLastRightClick.notNull())
{
LLPanelPeople* panel_people = (LLPanelPeople*)LLFloaterSidePanelContainer::getPanel("panel_people");
LLPanelPeople* panel_people = (LLPanelPeople*)LLFloaterSidePanelContainer::getPanel("people", "panel_people");
if (panel_people != NULL)
{
panel_people->startTracking(mClosestAgentAtLastRightClick);

View File

@ -226,14 +226,14 @@ void NearbyMenu::teleportToAvatar()
// AO: wrapper for functionality managed by LLPanelPeople, because it manages the nearby avatar list.
// Will only work for avatars within radar range.
{
LLPanelPeople* peoplePanel = dynamic_cast<LLPanelPeople*>(LLFloaterSidePanelContainer::getPanel("panel_people"));
LLPanelPeople* peoplePanel = dynamic_cast<LLPanelPeople*>(LLFloaterSidePanelContainer::getPanel("people", "panel_people"));
peoplePanel->teleportToAvatar(mUUIDs.front());
}
// Ansariel: Avatar tracking feature
void NearbyMenu::onTrackAvatarMenuItemClick()
{
LLPanelPeople* peoplePanel = dynamic_cast<LLPanelPeople*>(LLFloaterSidePanelContainer::getPanel("panel_people"));
LLPanelPeople* peoplePanel = dynamic_cast<LLPanelPeople*>(LLFloaterSidePanelContainer::getPanel("people", "panel_people"));
peoplePanel->startTracking(mUUIDs.front());
}

View File

@ -5036,7 +5036,7 @@ void process_sound_trigger(LLMessageSystem *msg, void **)
// sound assets as a request for a full radar update to a channel
if ((owner_id == gAgent.getID()) && (sound_id.asString() == gSavedSettings.getString("RadarLegacyChannelAlertRefreshUUID")))
{
LLPanelPeople* pPeoplePanel = dynamic_cast<LLPanelPeople*>(LLFloaterSidePanelContainer::getPanel("panel_people"));
LLPanelPeople* pPeoplePanel = dynamic_cast<LLPanelPeople*>(LLFloaterSidePanelContainer::getPanel("people", "panel_people"));
if (pPeoplePanel)
pPeoplePanel->requestRadarChannelAlertSync();
return;

View File

@ -405,7 +405,7 @@ void RlvUIEnabler::onToggleShowMinimap()
// ND_MERGE
// Break/reestablish the visibility connection for the nearby people panel embedded minimap instance
LLPanel* pPeoplePanel = LLFloaterSidePanelContainer::getPanel("panel_people");
LLPanel* pPeoplePanel = LLFloaterSidePanelContainer::getPanel("people", "panel_people");
LLPanel* pNetMapPanel = (pPeoplePanel) ? pPeoplePanel->getChild<LLPanel>("minimaplayout", TRUE) : NULL; //AO: firestorm specific
RLV_ASSERT( (pPeoplePanel) && (pNetMapPanel) );
if (pNetMapPanel)
@ -426,7 +426,7 @@ void RlvUIEnabler::onToggleShowNames(bool fQuitting)
bool fEnable = !gRlvHandler.hasBehaviour(RLV_BHVR_SHOWNAMES);
// Refresh the nearby people list
LLPanelPeople* pPeoplePanel = dynamic_cast<LLPanelPeople*>(LLFloaterSidePanelContainer::getPanel("panel_people"));
LLPanelPeople* pPeoplePanel = dynamic_cast<LLPanelPeople*>(LLFloaterSidePanelContainer::getPanel("people", "panel_people"));
RLV_ASSERT( (pPeoplePanel) && (pPeoplePanel->getNearbyList()) );
if ( (pPeoplePanel) && (pPeoplePanel->getNearbyList()) )
pPeoplePanel->getNearbyList()->updateAvatarNames();