diff options
author | Don Kjer <don@lindenlab.com> | 2011-04-14 18:27:31 +0000 |
---|---|---|
committer | Don Kjer <don@lindenlab.com> | 2011-04-14 18:27:31 +0000 |
commit | 01f4570c795b197e74bfa96139631c43df8d0664 (patch) | |
tree | 7c1952cc51adec21025f537281e59f828e75224d /indra/newview/llavataractions.cpp | |
parent | 2bf967149626672584b17b53fb5d2e6186f3d896 (diff) | |
parent | 88a7262340f2fc5085f4ac6600790518d01292d6 (diff) |
Merge with viewer-development
Diffstat (limited to 'indra/newview/llavataractions.cpp')
-rwxr-xr-x | indra/newview/llavataractions.cpp | 41 |
1 files changed, 11 insertions, 30 deletions
diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index afa8b62c74..ca7ec7cc30 100755 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -279,7 +279,7 @@ bool LLAvatarActions::isCalling(const LLUUID &id) //static bool LLAvatarActions::canCall() { - return LLVoiceClient::getInstance()->voiceEnabled() && LLVoiceClient::getInstance()->isVoiceWorking(); + return LLVoiceClient::getInstance()->voiceEnabled() && LLVoiceClient::getInstance()->isVoiceWorking(); } // static @@ -300,40 +300,21 @@ void LLAvatarActions::startConference(const uuid_vec_t& ids) make_ui_sound("UISndStartIM"); } +static void on_avatar_name_show_profile(const LLUUID& agent_id, const LLAvatarName& av_name) +{ + llinfos << "opening web profile for " << av_name.mUsername << llendl; + std::string url = getProfileURL(av_name.mUsername); + + // PROFILES: open in webkit window + LLWeb::loadWebURLInternal(url, "", agent_id.asString()); +} + // static void LLAvatarActions::showProfile(const LLUUID& id) { if (id.notNull()) { - LLSD params; - params["id"] = id; - params["open_tab_name"] = "panel_profile"; - - // PROFILES: open in webkit window - std::string full_name; - if (gCacheName->getFullName(id,full_name)) - { - std::string agent_name = LLCacheName::buildUsername(full_name); - llinfos << "opening web profile for " << agent_name << llendl; - std::string url = getProfileURL(agent_name); - LLWeb::loadWebURLInternal(url, "", id.asString()); - } - else - { - llwarns << "no name info for agent id " << id << llendl; - } -#if 0 - //Show own profile - if(gAgent.getID() == id) - { - LLSideTray::getInstance()->showPanel("panel_me", params); - } - //Show other user profile - else - { - LLSideTray::getInstance()->showPanel("panel_profile_view", params); - } -#endif + LLAvatarNameCache::get(id, boost::bind(&on_avatar_name_show_profile, _1, _2)); } } |