From e45389e64a42f9176b6dce5f78b23c8423975792 Mon Sep 17 00:00:00 2001 From: McCabe Maxsted Date: Tue, 13 Oct 2009 11:29:22 -0700 Subject: Parcel highlighting when selecting a name in radar is less buggy --- linden/indra/newview/llfloatermap.cpp | 19 ++++++++++--------- linden/indra/newview/llfloatermap.h | 6 +++--- linden/indra/newview/llviewermessage.cpp | 2 +- 3 files changed, 14 insertions(+), 13 deletions(-) (limited to 'linden') diff --git a/linden/indra/newview/llfloatermap.cpp b/linden/indra/newview/llfloatermap.cpp index 49563a6..256c52e 100644 --- a/linden/indra/newview/llfloatermap.cpp +++ b/linden/indra/newview/llfloatermap.cpp @@ -290,14 +290,14 @@ void LLFloaterMap::populateRadar() { if (distance < 20.0f) { - if (!getInChatList(avatar_ids[i])) + if (!isInChatList(avatar_ids[i])) { addToChatList(avatar_ids[i], dist_string); } } else { - if (getInChatList(avatar_ids[i])) + if (isInChatList(avatar_ids[i])) { removeFromChatList(avatar_ids[i]); } @@ -311,7 +311,7 @@ void LLFloaterMap::populateRadar() if (notify_sim) { - if (!getInChatList(avatar_ids[i]) && !getInSimAvList(avatar_ids[i])) + if (!isInChatList(avatar_ids[i]) && !getInSimAvList(avatar_ids[i])) { LLViewerObject *av_obj = gObjectList.findObject(avatar_ids[i]); if (av_obj != NULL && av_obj->isAvatar()) @@ -338,7 +338,7 @@ void LLFloaterMap::populateRadar() { // append typing string std::string typing = ""; - if (getIsTyping(avatar_ids[i])) + if (isTyping(avatar_ids[i])) { typing = getString("is_typing")+ " "; } @@ -397,7 +397,7 @@ void LLFloaterMap::updateChatList(std::vector agent_ids) } } -bool LLFloaterMap::getInChatList(LLUUID agent_id) +bool LLFloaterMap::isInChatList(LLUUID agent_id) { if (mChatAvatars.count(agent_id) > 0) { @@ -426,7 +426,7 @@ void LLFloaterMap::removeFromChatList(LLUUID agent_id) mChatAvatars.erase(agent_id); } -bool LLFloaterMap::getIsTyping(LLUUID agent_id) +bool LLFloaterMap::isTyping(LLUUID agent_id) { if (mTypingAvatars.count(agent_id) > 0) { @@ -439,7 +439,7 @@ void LLFloaterMap::updateTypingList(LLUUID agent_id, bool remove) { if (remove) { - if (getIsTyping(agent_id)) + if (isTyping(agent_id)) { mTypingAvatars.erase(agent_id); } @@ -503,7 +503,7 @@ void LLFloaterMap::toggleButtons() enable = mSelectedAvatar.notNull() ? visibleItemsSelected() : FALSE; enable_unmute = mSelectedAvatar.notNull() ? LLMuteList::getInstance()->isMuted(mSelectedAvatar) : FALSE; enable_track = gAgent.isGodlike() || is_agent_mappable(mSelectedAvatar); - enable_estate = getKickable(mSelectedAvatar); + enable_estate = isKickable(mSelectedAvatar); enable_friend = !is_agent_friend(mSelectedAvatar); } else @@ -552,7 +552,7 @@ void LLFloaterMap::toggleButtons() // [/RLVa:KB] } -BOOL LLFloaterMap::getKickable(const LLUUID &agent_id) +BOOL LLFloaterMap::isKickable(const LLUUID &agent_id) { if (agent_id.notNull()) { @@ -568,6 +568,7 @@ BOOL LLFloaterMap::getKickable(const LLUUID &agent_id) if (LLWorld::getInstance()->positionRegionValidGlobal(pos_global)) { LLParcel* parcel = LLViewerParcelMgr::getInstance()->selectParcelAt(pos_global)->getParcel(); + LLViewerParcelMgr::getInstance()->deselectLand(); BOOL new_value = (region != NULL); diff --git a/linden/indra/newview/llfloatermap.h b/linden/indra/newview/llfloatermap.h index af4d1cc..aedbcb8 100644 --- a/linden/indra/newview/llfloatermap.h +++ b/linden/indra/newview/llfloatermap.h @@ -52,7 +52,7 @@ public: // returns true if agent_id belongs to a developer listed in llfloatermap.cpp static bool isImpDev(LLUUID agent_id); - bool getIsTyping(LLUUID agent_id); + bool isTyping(LLUUID agent_id); void updateTypingList(LLUUID agent_id, bool remove); BOOL postBuild(); @@ -85,12 +85,12 @@ private: static void onList(LLUICtrl* ctrl, void* user_data); static void onRangeChange(LLFocusableElement* focus, void* user_data); BOOL visibleItemsSelected() const; - BOOL getKickable(const LLUUID &agent_id); + BOOL isKickable(const LLUUID &agent_id); void toggleButtons(); void populateRadar(); void updateChatList(std::vector agent_ids); - bool getInChatList(LLUUID agent_id); + bool isInChatList(LLUUID agent_id); void addToChatList(LLUUID agent_id, std::string distance); void removeFromChatList(LLUUID agent_id); diff --git a/linden/indra/newview/llviewermessage.cpp b/linden/indra/newview/llviewermessage.cpp index d784f52..3baeec0 100644 --- a/linden/indra/newview/llviewermessage.cpp +++ b/linden/indra/newview/llviewermessage.cpp @@ -2574,7 +2574,7 @@ void process_chat_from_simulator(LLMessageSystem *msg, void **user_data) if (LLFloaterMap::getInstance()) { - if (LLFloaterMap::getInstance()->getIsTyping(from_id)) + if (LLFloaterMap::getInstance()->isTyping(from_id)) { LLFloaterMap::getInstance()->updateTypingList(from_id, true); } -- cgit v1.1 From c48fd00d2069a48478f4fa5da8c303444a409cfe Mon Sep 17 00:00:00 2001 From: McCabe Maxsted Date: Tue, 13 Oct 2009 11:46:35 -0700 Subject: Combine the two mini-map mute buttons into one --- linden/indra/newview/llfloatermap.cpp | 13 ++++++++++++- .../newview/skins/default/xui/en-us/floater_mini_map.xml | 2 +- 2 files changed, 13 insertions(+), 2 deletions(-) (limited to 'linden') diff --git a/linden/indra/newview/llfloatermap.cpp b/linden/indra/newview/llfloatermap.cpp index 256c52e..31e57a0 100644 --- a/linden/indra/newview/llfloatermap.cpp +++ b/linden/indra/newview/llfloatermap.cpp @@ -520,10 +520,21 @@ void LLFloaterMap::toggleButtons() childSetEnabled("freeze_btn", enable_estate); childSetEnabled("eject_btn", enable_estate); childSetEnabled("mute_btn", enable); - childSetEnabled("unmute_btn", enable_unmute); childSetEnabled("ar_btn", enable); childSetEnabled("estate_eject_btn", enable_estate); + if (enable_unmute) + { + childSetVisible("mute_btn", false); + childSetEnabled("unmute_btn", true); + childSetVisible("unmute_btn", true); + } + else + { + childSetVisible("mute_btn", true); + childSetVisible("unmute_btn", false); + } + // [RLVa:KB] - Imprudence-1.2.0 // Bit clumsy, but this way the RLV stuff is in its own separate block and keeps the code above clean - Kitty if ( (rlv_handler_t::isEnabled()) && (mSelectedAvatar.notNull()) ) diff --git a/linden/indra/newview/skins/default/xui/en-us/floater_mini_map.xml b/linden/indra/newview/skins/default/xui/en-us/floater_mini_map.xml index 3c860e9..57f955f 100644 --- a/linden/indra/newview/skins/default/xui/en-us/floater_mini_map.xml +++ b/linden/indra/newview/skins/default/xui/en-us/floater_mini_map.xml @@ -70,7 +70,7 @@