Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/indra/newview/llfloateravatarinfo.cpp b/indra/newview/llfloateravatarinfo.cpp
- index c9e5ba9..aab654d 100644
- --- a/indra/newview/llfloateravatarinfo.cpp
- +++ b/indra/newview/llfloateravatarinfo.cpp
- @@ -60,6 +60,37 @@ const LLRect FAI_RECT(0, 530, 420, 0);
- class LLAgentHandler : public LLCommandHandler
- {
- public:
- + void verbCallback(const std::string& verb, LLUUID agent_id, const LLAvatarName& avatar_name)
- + {
- + if (verb == "im")
- + {
- + gIMMgr->setFloaterOpen(TRUE);
- + gIMMgr->addSession( avatar_name.getCompleteName(), IM_NOTHING_SPECIAL, agent_id);
- + return;
- + }
- +
- + if (verb == "requestfriend")
- + {
- + LLPanelFriends::requestFriendshipDialog( agent_id, avatar_name.getCompleteName() );
- + return;
- + }
- +
- + if (verb == "mute")
- + {
- + LLFloaterMute::getInstance()->open();
- + LLMute mute(agent_id, avatar_name.getCompleteName(), LLMute::AGENT);
- + LLMuteList::getInstance()->add(mute);
- + return;
- + }
- +
- + if (verb == "unmute")
- + {
- + LLMute mute(agent_id, avatar_name.getCompleteName(), LLMute::AGENT);
- + LLMuteList::getInstance()->remove(mute);
- + return;
- + }
- + }
- +
- // requires trusted browser to trigger
- LLAgentHandler() : LLCommandHandler("agent", true) { }
- @@ -73,11 +104,44 @@ public:
- return false;
- }
- - if (params[1].asString() == "about")
- {
- LLFloaterAvatarInfo::show(agent_id);
- return true;
- }
- +
- + if (verb == "pay")
- + {
- + handle_pay_by_id(agent_id);
- + return true;
- + }
- +
- + if (verb == "offerteleport")
- + {
- + handle_lure(agent_id);
- + return true;
- + }
- +
- + if ((verb == "im") || (verb == "requestfriend") || (verb == "unmute"))
- + {
- + LLAvatarNameCache::get(agent_id, boost::bind(&LLAgentHandler::verbCallback, this, verb, _1, _2));
- + return true;
- + }
- +
- + if (verb == "mute")
- + {
- + if (LLMuteList::getInstance()->isMuted(agent_id))
- + {
- + LLFloaterMute::getInstance()->open();
- + LLFloaterMute::getInstance()->selectMute(agent_id);
- + }
- + else
- + {
- + LLAvatarNameCache::get(agent_id, boost::bind(&LLAgentHandler::verbCallback, this, verb, _1, _2));
- + }
- + return true;
- + }
- +
- +
- return false;
- }
- };
- diff --git a/indra/newview/llfloatergroupinfo.cpp b/indra/newview/llfloatergroupinfo.cpp
- index 67e2ebe..1020efc 100644
- --- a/indra/newview/llfloatergroupinfo.cpp
- +++ b/indra/newview/llfloatergroupinfo.cpp
- @@ -97,7 +97,7 @@ public:
- return false;
- }
- - if (tokens[1].asString() == "about")
- + if ((tokens[1].asString() == "about") || (tokens[1].asString() == "inspect"))
- {
- LLFloaterGroupInfo::showFromUUID(group_id);
- return true;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement