diff options
author | Leyla Farazha <leyla@lindenlab.com> | 2010-05-28 13:28:05 -0700 |
---|---|---|
committer | Leyla Farazha <leyla@lindenlab.com> | 2010-05-28 13:28:05 -0700 |
commit | def61c6999f83cc3c85cdccb6ac9f744c032c694 (patch) | |
tree | 26b8792d46466453eee415b6579a08ca1c81699a /indra/newview/llavataractions.cpp | |
parent | 9874e4d1818661580d72f41a507b41d3e07aecd5 (diff) |
removing deprecated add friend callback path for server 1.24
Diffstat (limited to 'indra/newview/llavataractions.cpp')
-rw-r--r-- | indra/newview/llavataractions.cpp | 34 |
1 files changed, 4 insertions, 30 deletions
diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index 6534f7921c..89711de6f0 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -81,22 +81,13 @@ void LLAvatarActions::requestFriendshipDialog(const LLUUID& id, const std::strin } LLSD args; - args["NAME"] = LLSLURL("agent", id, "inspect").getSLURLString(); + args["NAME"] = LLSLURL("agent", id, "completename").getSLURLString(); LLSD payload; payload["id"] = id; payload["name"] = name; - // Look for server versions like: Second Life Server 1.24.4.95600 - if (gLastVersionChannel.find(" 1.24.") != std::string::npos) - { - // Old and busted server version, doesn't support friend - // requests with messages. - LLNotificationsUtil::add("AddFriend", args, payload, &callbackAddFriend); - } - else - { - LLNotificationsUtil::add("AddFriendWithMessage", args, payload, &callbackAddFriendWithMessage); - } - + + LLNotificationsUtil::add("AddFriendWithMessage", args, payload, &callbackAddFriendWithMessage); + // add friend to recent people list LLRecentPeople::instance().add(id); } @@ -716,23 +707,6 @@ bool LLAvatarActions::handleUnfreeze(const LLSD& notification, const LLSD& respo } return false; } -// static -bool LLAvatarActions::callbackAddFriend(const LLSD& notification, const LLSD& response) -{ - S32 option = LLNotificationsUtil::getSelectedOption(notification, response); - if (option == 0) - { - // Servers older than 1.25 require the text of the message to be the - // calling card folder ID for the offering user. JC - LLUUID calling_card_folder_id = - gInventory.findCategoryUUIDForType(LLFolderType::FT_CALLINGCARD); - std::string message = calling_card_folder_id.asString(); - requestFriendship(notification["payload"]["id"].asUUID(), - notification["payload"]["name"].asString(), - message); - } - return false; -} // static void LLAvatarActions::requestFriendship(const LLUUID& target_id, const std::string& target_name, const std::string& message) |