From d5d9668a59895874951fb3e5927ea0159270a6e8 Mon Sep 17 00:00:00 2001 From: Paul Guslisty Date: Thu, 25 Mar 2010 09:04:01 +0200 Subject: Fixed low bug EXT-6488 (Teleport menuitem is enabled for offline residents in the context menu and inspectors) - Added a check for a teleport offer ability. In XML created a paremeter and check it in source code. Reviewed by Leyla Farazha at https://codereview.productengine.com/secondlife/r/86/ --HG-- branch : product-engine --- indra/newview/llpanelpeoplemenus.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'indra/newview/llpanelpeoplemenus.cpp') diff --git a/indra/newview/llpanelpeoplemenus.cpp b/indra/newview/llpanelpeoplemenus.cpp index 854651cd01..313ed4b70e 100644 --- a/indra/newview/llpanelpeoplemenus.cpp +++ b/indra/newview/llpanelpeoplemenus.cpp @@ -226,6 +226,11 @@ bool NearbyMenu::enableContextMenuItem(const LLSD& userdata) return (LLAvatarTracker::instance().isBuddyOnline(id) && is_agent_mappable(id)) || gAgent.isGodlike(); } + else if(item == std::string("can_offer_teleport")) + { + const LLUUID& id = mUUIDs.front(); + return LLAvatarActions::canOfferTeleport(id); + } return false; } -- cgit v1.2.3 From 114e5ca0839bace7f247a6eadb6e06a28597501d Mon Sep 17 00:00:00 2001 From: Loren Shih Date: Mon, 29 Mar 2010 16:33:35 -0400 Subject: EXT-5940 : Typedef all vector's Superficial cleanup to change all typedef std::vector to use a common typedef uuid_vec_t instead. --- indra/newview/llpanelpeoplemenus.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'indra/newview/llpanelpeoplemenus.cpp') diff --git a/indra/newview/llpanelpeoplemenus.cpp b/indra/newview/llpanelpeoplemenus.cpp index 854651cd01..8b365c6433 100644 --- a/indra/newview/llpanelpeoplemenus.cpp +++ b/indra/newview/llpanelpeoplemenus.cpp @@ -72,7 +72,7 @@ ContextMenu::~ContextMenu() } } -void ContextMenu::show(LLView* spawning_view, const std::vector& uuids, S32 x, S32 y) +void ContextMenu::show(LLView* spawning_view, const uuid_vec_t& uuids, S32 x, S32 y) { if (mMenu) { @@ -177,7 +177,7 @@ bool NearbyMenu::enableContextMenuItem(const LLSD& userdata) bool result = (mUUIDs.size() > 0); - std::vector::const_iterator + uuid_vec_t::const_iterator id = mUUIDs.begin(), uuids_end = mUUIDs.end(); @@ -200,7 +200,7 @@ bool NearbyMenu::enableContextMenuItem(const LLSD& userdata) bool result = (mUUIDs.size() > 0); - std::vector::const_iterator + uuid_vec_t::const_iterator id = mUUIDs.begin(), uuids_end = mUUIDs.end(); -- cgit v1.2.3