From 48111a2ab847bb3bacf658b3771d0324157fc751 Mon Sep 17 00:00:00 2001 From: James Cook Date: Fri, 22 Jan 2010 16:53:18 -0800 Subject: Converted friend request names to SLID-compatible --- indra/newview/llavataractions.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index 40c9bb6afa..8c4dfaea50 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -62,6 +62,7 @@ #include "llimfloater.h" #include "lltrans.h" #include "llcallingcard.h" +#include "llslurl.h" // IDEVO // static void LLAvatarActions::requestFriendshipDialog(const LLUUID& id, const std::string& name) @@ -73,7 +74,7 @@ void LLAvatarActions::requestFriendshipDialog(const LLUUID& id, const std::strin } LLSD args; - args["NAME"] = name; + args["NAME"] = LLSLURL::buildCommand("agent", id, "inspect"); LLSD payload; payload["id"] = id; payload["name"] = name; @@ -102,7 +103,7 @@ void LLAvatarActions::requestFriendshipDialog(const LLUUID& id) } std::string full_name; - gCacheName->getFullName(id, full_name); + // IDEVO gCacheName->getFullName(id, full_name); requestFriendshipDialog(id, full_name); } -- cgit v1.2.3 From c0b7c93c18783d6a426cf43265f34c86bdeceb4a Mon Sep 17 00:00:00 2001 From: James Cook Date: Thu, 4 Feb 2010 20:38:40 -0800 Subject: Converted all gCacheName->getName to getFullName for SLID compatibility Also eliminated notification "ObjectGiveItemUnknownUser" because the SLURL-based name lookup will always retrieve the user name. Fixed a bug with ObjectGiveItem where the SLURL would be incorrect for a group. --- indra/newview/llavataractions.cpp | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index bfd3d12efb..7935c32d82 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -129,11 +129,10 @@ void LLAvatarActions::removeFriendsDialog(const std::vector& ids) if(ids.size() == 1) { LLUUID agent_id = ids[0]; - std::string first, last; - if(gCacheName->getName(agent_id, first, last)) + std::string full_name; + if(gCacheName->getFullName(agent_id, full_name)) { - args["FIRST_NAME"] = first; - args["LAST_NAME"] = last; + args["NAME"] = full_name; } msgType = "RemoveFromFriends"; @@ -617,9 +616,9 @@ bool LLAvatarActions::isBlocked(const LLUUID& id) // static bool LLAvatarActions::canBlock(const LLUUID& id) { - std::string firstname, lastname; - gCacheName->getName(id, firstname, lastname); - bool is_linden = !LLStringUtil::compareStrings(lastname, "Linden"); + std::string full_name; + gCacheName->getFullName(id, full_name); + bool is_linden = (full_name.find("Linden") != std::string::npos); bool is_self = id == gAgentID; return !is_self && !is_linden; } -- cgit v1.2.3 From 42176145c9e81dd99b65f88152df50a7b3ccf834 Mon Sep 17 00:00:00 2001 From: James Cook Date: Mon, 8 Feb 2010 14:55:30 -0800 Subject: Converted names build from avatar object LLNameValue pairs to SLID Added temporary getDisplayName() to LLCacheName Moved temporary placeholder display names into LLCacheName Eliminated rarely used LLAgentUI::buildName in favor of buildFullName Standardized buildFullName capitalization --- indra/newview/llavataractions.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index 7935c32d82..7f20eb02ea 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -103,7 +103,7 @@ void LLAvatarActions::requestFriendshipDialog(const LLUUID& id) } std::string full_name; - // IDEVO gCacheName->getFullName(id, full_name); + gCacheName->getFullName(id, full_name); requestFriendshipDialog(id, full_name); } -- cgit v1.2.3 From d3582dc3ffb1ecb8a8888d17c4196c1c446a9a9a Mon Sep 17 00:00:00 2001 From: James Cook Date: Fri, 19 Feb 2010 15:14:44 -0800 Subject: IM window titles are Display Name (SLID) --- indra/newview/llavataractions.cpp | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index 9e136b7cfb..298e221460 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -35,11 +35,11 @@ #include "llavataractions.h" +#include "llavatarnamecache.h" // IDEVO #include "llsd.h" #include "lldarray.h" #include "llnotifications.h" #include "llnotificationsutil.h" - #include "roles_constants.h" // for GP_MEMBER_INVITE #include "llagent.h" @@ -187,6 +187,14 @@ void LLAvatarActions::startIM(const LLUUID& id) return; } + // IDEVO + LLAvatarName av_name; + if (LLAvatarNameCache::useDisplayNames() + && LLAvatarNameCache::get(id, &av_name)) + { + name = av_name.mDisplayName + " (" + av_name.mSLID + ")"; + } + LLUUID session_id = gIMMgr->addSession(name, IM_NOTHING_SPECIAL, id); if (session_id != LLUUID::null) { @@ -218,6 +226,13 @@ void LLAvatarActions::startCall(const LLUUID& id) std::string name; gCacheName->getFullName(id, name); + // IDEVO + LLAvatarName av_name; + if (LLAvatarNameCache::useDisplayNames() + && LLAvatarNameCache::get(id, &av_name)) + { + name = av_name.mDisplayName + " (" + av_name.mSLID + ")"; + } LLUUID session_id = gIMMgr->addSession(name, IM_NOTHING_SPECIAL, id, true); if (session_id != LLUUID::null) { -- cgit v1.2.3 From bee1a091469f8d1f2277e8d5b4cc9981e8060bde Mon Sep 17 00:00:00 2001 From: James Cook Date: Wed, 12 May 2010 16:32:25 -0700 Subject: DEV-50013 IM window titles use correct name lookup method --- indra/newview/llavataractions.cpp | 65 +++++++++++++++++---------------------- 1 file changed, 28 insertions(+), 37 deletions(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index 85a087d6f6..fe6ca60d7c 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -187,28 +187,11 @@ void LLAvatarActions::offerTeleport(const uuid_vec_t& ids) handle_lure(ids); } -// static -void LLAvatarActions::startIM(const LLUUID& id) +static void on_avatar_name_cache_start_im(const LLUUID& agent_id, + const LLAvatarName& av_name) { - if (id.isNull()) - return; - - std::string name; - if (!gCacheName->getFullName(id, name)) - { - gCacheName->get(id, FALSE, boost::bind(&LLAvatarActions::startIM, id)); - return; - } - - // IDEVO - LLAvatarName av_name; - if (LLAvatarNameCache::useDisplayNames() - && LLAvatarNameCache::get(id, &av_name)) - { - name = av_name.mDisplayName + " (" + av_name.mSLID + ")"; - } - - LLUUID session_id = gIMMgr->addSession(name, IM_NOTHING_SPECIAL, id); + std::string name = av_name.getNameAndSLID(); + LLUUID session_id = gIMMgr->addSession(name, IM_NOTHING_SPECIAL, agent_id); if (session_id != LLUUID::null) { LLIMFloater::show(session_id); @@ -216,6 +199,16 @@ void LLAvatarActions::startIM(const LLUUID& id) make_ui_sound("UISndStartIM"); } +// static +void LLAvatarActions::startIM(const LLUUID& id) +{ + if (id.isNull()) + return; + + LLAvatarNameCache::get(id, + boost::bind(&on_avatar_name_cache_start_im, _1, _2)); +} + // static void LLAvatarActions::endIM(const LLUUID& id) { @@ -229,6 +222,18 @@ void LLAvatarActions::endIM(const LLUUID& id) } } +static void on_avatar_name_cache_start_call(const LLUUID& agent_id, + const LLAvatarName& av_name) +{ + std::string name = av_name.getNameAndSLID(); + LLUUID session_id = gIMMgr->addSession(name, IM_NOTHING_SPECIAL, agent_id, true); + if (session_id != LLUUID::null) + { + gIMMgr->startCall(session_id); + } + make_ui_sound("UISndStartIM"); +} + // static void LLAvatarActions::startCall(const LLUUID& id) { @@ -236,22 +241,8 @@ void LLAvatarActions::startCall(const LLUUID& id) { return; } - - std::string name; - gCacheName->getFullName(id, name); - // IDEVO - LLAvatarName av_name; - if (LLAvatarNameCache::useDisplayNames() - && LLAvatarNameCache::get(id, &av_name)) - { - name = av_name.mDisplayName + " (" + av_name.mSLID + ")"; - } - LLUUID session_id = gIMMgr->addSession(name, IM_NOTHING_SPECIAL, id, true); - if (session_id != LLUUID::null) - { - gIMMgr->startCall(session_id); - } - make_ui_sound("UISndStartIM"); + LLAvatarNameCache::get(id, + boost::bind(&on_avatar_name_cache_start_call, _1, _2)); } // static -- cgit v1.2.3 From 894261e4e4aea8a15bef33fdf34807812a1c73bb Mon Sep 17 00:00:00 2001 From: James Cook Date: Thu, 13 May 2010 16:30:15 -0700 Subject: Fix build errors introduced in last merge --- indra/newview/llavataractions.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index e1e9e03889..708ef1895e 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -79,7 +79,7 @@ void LLAvatarActions::requestFriendshipDialog(const LLUUID& id, const std::strin } LLSD args; - args["NAME"] = LLSLURL::buildCommand("agent", id, "inspect"); + args["NAME"] = LLSLURL("agent", id, "inspect").getSLURLString(); LLSD payload; payload["id"] = id; payload["name"] = name; -- cgit v1.2.3 From d674d11f895b8f3d578cded931cdc1c430379c95 Mon Sep 17 00:00:00 2001 From: James Cook Date: Fri, 21 May 2010 17:11:31 -0700 Subject: Rename LLAvatarName::getNameAndSLID() to getCompleteName() Discussed with Leyla/Richard --- indra/newview/llavataractions.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index 708ef1895e..1d1a127dae 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -190,7 +190,7 @@ void LLAvatarActions::offerTeleport(const uuid_vec_t& ids) static void on_avatar_name_cache_start_im(const LLUUID& agent_id, const LLAvatarName& av_name) { - std::string name = av_name.getNameAndSLID(); + std::string name = av_name.getCompleteName(); LLUUID session_id = gIMMgr->addSession(name, IM_NOTHING_SPECIAL, agent_id); if (session_id != LLUUID::null) { @@ -225,7 +225,7 @@ void LLAvatarActions::endIM(const LLUUID& id) static void on_avatar_name_cache_start_call(const LLUUID& agent_id, const LLAvatarName& av_name) { - std::string name = av_name.getNameAndSLID(); + std::string name = av_name.getCompleteName(); LLUUID session_id = gIMMgr->addSession(name, IM_NOTHING_SPECIAL, agent_id, true); if (session_id != LLUUID::null) { -- cgit v1.2.3 From b26d3f37bef4e10be2b5f7f4f6408485ed3ccae7 Mon Sep 17 00:00:00 2001 From: Leyla Farazha Date: Tue, 25 May 2010 15:07:23 -0700 Subject: fixed merge problem --- indra/newview/llavataractions.cpp | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index 6cef0b5119..6534f7921c 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -490,26 +490,24 @@ namespace action_give_inventory * @param avatar_names - avatar names request to be sent. * @param avatar_uuids - avatar names request to be sent. */ - static void give_inventory(const std::vector& avatar_names, const uuid_vec_t& avatar_uuids) + static void give_inventory(const uuid_vec_t& avatar_uuids, const std::vector avatar_names) { - llassert(avatar_names.size() == avatar_uuids.size()); - LLInventoryPanel* active_panel = LLInventoryPanel::getActiveInventoryPanel(FALSE); if (NULL == active_panel) return; const uuid_set_t inventory_selected_uuids = active_panel->getRootFolder()->getSelectionList(); if (inventory_selected_uuids.empty()) return; - S32 count = llmin(avatar_names.size(), avatar_uuids.size()); + S32 count = avatar_uuids.size(); // iterate through avatars for(S32 i = 0; i < count; ++i) { - const std::string& avatar_name = avatar_names[i]; + LLAvatarName av_name = avatar_names[i]; const LLUUID& avatar_uuid = avatar_uuids[i]; // Start up IM before give the item - const LLUUID session_id = gIMMgr->addSession(avatar_name, IM_NOTHING_SPECIAL, avatar_uuid); + const LLUUID session_id = gIMMgr->addSession(av_name.getCompleteName(), IM_NOTHING_SPECIAL, avatar_uuid); uuid_set_t::const_iterator it = inventory_selected_uuids.begin(); const uuid_set_t::const_iterator it_end = inventory_selected_uuids.end(); -- cgit v1.2.3 From def61c6999f83cc3c85cdccb6ac9f744c032c694 Mon Sep 17 00:00:00 2001 From: Leyla Farazha Date: Fri, 28 May 2010 13:28:05 -0700 Subject: removing deprecated add friend callback path for server 1.24 --- indra/newview/llavataractions.cpp | 34 ++++------------------------------ 1 file changed, 4 insertions(+), 30 deletions(-) (limited to 'indra/newview/llavataractions.cpp') 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) -- cgit v1.2.3 From 26b601b99e43eac623c81a60e93094577b06d209 Mon Sep 17 00:00:00 2001 From: Leyla Farazha Date: Fri, 28 May 2010 15:45:23 -0700 Subject: Getting rid of some more old gCacheName calls --- indra/newview/llavataractions.cpp | 37 ++++++++++++++++--------------------- 1 file changed, 16 insertions(+), 21 deletions(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index 89711de6f0..6699449625 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -92,6 +92,11 @@ void LLAvatarActions::requestFriendshipDialog(const LLUUID& id, const std::strin LLRecentPeople::instance().add(id); } +void on_avatar_name_friendship(const LLUUID& id, const LLAvatarName av_name) +{ + LLAvatarActions::requestFriendshipDialog(id, av_name.getCompleteName()); +} + // static void LLAvatarActions::requestFriendshipDialog(const LLUUID& id) { @@ -100,9 +105,7 @@ void LLAvatarActions::requestFriendshipDialog(const LLUUID& id) return; } - std::string full_name; - gCacheName->getFullName(id, full_name); - requestFriendshipDialog(id, full_name); + LLAvatarNameCache::get(id, boost::bind(&on_avatar_name_friendship, _1, _2)); } // static @@ -127,10 +130,10 @@ void LLAvatarActions::removeFriendsDialog(const uuid_vec_t& ids) if(ids.size() == 1) { LLUUID agent_id = ids[0]; - std::string full_name; - if(gCacheName->getFullName(agent_id, full_name)) + LLAvatarName av_name; + if(LLAvatarNameCache::get(agent_id, &av_name)) { - args["NAME"] = full_name; + args["NAME"] = av_name.mDisplayName; } msgType = "RemoveFromFriends"; @@ -158,14 +161,6 @@ void LLAvatarActions::offerTeleport(const LLUUID& invitee) if (invitee.isNull()) return; - //waiting until Name Cache gets updated with corresponding avatar name - std::string just_to_request_name; - if (!gCacheName->getFullName(invitee, just_to_request_name)) - { - gCacheName->get(invitee, FALSE, boost::bind((void (*)(const LLUUID&)) &LLAvatarActions::offerTeleport, invitee)); - return; - } - LLDynamicArray ids; ids.push_back(invitee); offerTeleport(ids); @@ -331,14 +326,14 @@ void LLAvatarActions::showProfile(const LLUUID& id) // static void LLAvatarActions::showOnMap(const LLUUID& id) { - std::string name; - if (!gCacheName->getFullName(id, name)) + LLAvatarName av_name; + if (!LLAvatarNameCache::get(id, &av_name)) { - gCacheName->get(id, FALSE, boost::bind(&LLAvatarActions::showOnMap, id)); + LLAvatarNameCache::get(id, boost::bind(&LLAvatarActions::showOnMap, id)); return; } - gFloaterWorldMap->trackAvatar(id, name); + gFloaterWorldMap->trackAvatar(id, av_name.mDisplayName); LLFloaterReg::showInstance("world_map"); } @@ -535,7 +530,7 @@ void LLAvatarActions::toggleBlock(const LLUUID& id) { std::string name; - gCacheName->getFullName(id, name); + gCacheName->getFullName(id, name); // needed for mute LLMute mute(id, name, LLMute::AGENT); if (LLMuteList::getInstance()->isMuted(mute.mID, mute.mName)) @@ -739,7 +734,7 @@ bool LLAvatarActions::isFriend(const LLUUID& id) bool LLAvatarActions::isBlocked(const LLUUID& id) { std::string name; - gCacheName->getFullName(id, name); + gCacheName->getFullName(id, name); // needed for mute return LLMuteList::getInstance()->isMuted(id, name); } @@ -747,7 +742,7 @@ bool LLAvatarActions::isBlocked(const LLUUID& id) bool LLAvatarActions::canBlock(const LLUUID& id) { std::string full_name; - gCacheName->getFullName(id, full_name); + gCacheName->getFullName(id, full_name); // needed for mute bool is_linden = (full_name.find("Linden") != std::string::npos); bool is_self = id == gAgentID; return !is_self && !is_linden; -- cgit v1.2.3 From 0789897d6127637f2b5f99d8e107fbd3df577173 Mon Sep 17 00:00:00 2001 From: Leyla Farazha Date: Wed, 2 Jun 2010 16:31:05 -0700 Subject: removed "SESSION_NAME" in favor of doing a gCacheName lookup reviewed by James --- indra/newview/llavataractions.cpp | 1 - 1 file changed, 1 deletion(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index 6699449625..d1ed4922f4 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -719,7 +719,6 @@ void LLAvatarActions::requestFriendship(const LLUUID& target_id, const std::stri LLSD payload; payload["from_id"] = target_id; - payload["SESSION_NAME"] = target_name; payload["SUPPRESS_TOAST"] = true; LLNotificationsUtil::add("FriendshipOffered", args, payload); } -- cgit v1.2.3 From 36ff13ddf01966260d304605d1d5cb3201389c84 Mon Sep 17 00:00:00 2001 From: Leyla Farazha Date: Thu, 3 Jun 2010 16:04:48 -0700 Subject: LLAvatarActions merge fix --- indra/newview/llavataractions.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index f6d104cf0a..02dbfd0af6 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -467,14 +467,15 @@ namespace action_give_inventory return acceptable; } - static void build_residents_string(const std::vector& avatar_names, std::string& residents_string) + static void build_residents_string(const std::vector avatar_names, std::string& residents_string) { llassert(avatar_names.size() > 0); const std::string& separator = LLTrans::getString("words_separator"); - for (std::vector::const_iterator it = avatar_names.begin(); ; ) + for (std::vector::const_iterator it = avatar_names.begin(); ; ) { - residents_string.append(*it); + LLAvatarName av_name = *it; + residents_string.append(av_name.mDisplayName); if (++it == avatar_names.end()) { break; @@ -511,7 +512,7 @@ namespace action_give_inventory struct LLShareInfo : public LLSingleton { - std::vector mAvatarNames; + std::vector mAvatarNames; uuid_vec_t mAvatarUuids; }; @@ -542,7 +543,7 @@ namespace action_give_inventory // iterate through avatars for(S32 i = 0; i < count; ++i) { - const std::string& avatar_name = LLShareInfo::instance().mAvatarNames[i]; + const std::string& avatar_name = LLShareInfo::instance().mAvatarNames[i].getLegacyName(); const LLUUID& avatar_uuid = LLShareInfo::instance().mAvatarUuids[i]; // Start up IM before give the item @@ -608,16 +609,15 @@ namespace action_give_inventory * @param avatar_names - avatar names request to be sent. * @param avatar_uuids - avatar names request to be sent. */ - static void give_inventory(const std::vector& avatar_names, const uuid_vec_t& avatar_uuids) + static void give_inventory(const uuid_vec_t& avatar_uuids, const std::vector avatar_names) { llassert(avatar_names.size() == avatar_uuids.size()); - LLInventoryPanel* active_panel = LLInventoryPanel::getActiveInventoryPanel(FALSE); if (NULL == active_panel) { return; - } + } const uuid_set_t inventory_selected_uuids = active_panel->getRootFolder()->getSelectionList(); if (inventory_selected_uuids.empty()) -- cgit v1.2.3 From 9696e94b2453e631f2c3bbb437e34196bc34652b Mon Sep 17 00:00:00 2001 From: James Cook Date: Fri, 4 Jun 2010 12:19:11 -0700 Subject: Comment out code that won't compile, fix later --- indra/newview/llavataractions.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index f6d104cf0a..f7db30e023 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -643,11 +643,12 @@ namespace action_give_inventory //static void LLAvatarActions::shareWithAvatars() { - using namespace action_give_inventory; - - LLFloaterAvatarPicker* picker = - LLFloaterAvatarPicker::show(boost::bind(give_inventory, _1, _2), TRUE, FALSE); - picker->setOkBtnEnableCb(boost::bind(is_give_inventory_acceptable)); + llerrs << "Needs to be fixed to work with LLAvatarName" << llendl; +// using namespace action_give_inventory; +// +// LLFloaterAvatarPicker* picker = +// LLFloaterAvatarPicker::show(boost::bind(give_inventory, _1, _2), TRUE, FALSE); +// picker->setOkBtnEnableCb(boost::bind(is_give_inventory_acceptable)); } // static -- cgit v1.2.3 From 6be9f280ff5b2e2eba3bb9c3f14d7166579d1a49 Mon Sep 17 00:00:00 2001 From: Leyla Farazha Date: Fri, 4 Jun 2010 13:17:07 -0700 Subject: Reverting commenting out of code since fix is in --- indra/newview/llavataractions.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'indra/newview/llavataractions.cpp') diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index ebd8296fda..02dbfd0af6 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -643,12 +643,11 @@ namespace action_give_inventory //static void LLAvatarActions::shareWithAvatars() { - llerrs << "Needs to be fixed to work with LLAvatarName" << llendl; -// using namespace action_give_inventory; -// -// LLFloaterAvatarPicker* picker = -// LLFloaterAvatarPicker::show(boost::bind(give_inventory, _1, _2), TRUE, FALSE); -// picker->setOkBtnEnableCb(boost::bind(is_give_inventory_acceptable)); + using namespace action_give_inventory; + + LLFloaterAvatarPicker* picker = + LLFloaterAvatarPicker::show(boost::bind(give_inventory, _1, _2), TRUE, FALSE); + picker->setOkBtnEnableCb(boost::bind(is_give_inventory_acceptable)); } // static -- cgit v1.2.3