summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorMnikolenko ProductEngine <mnikolenko@productengine.com>2014-05-20 11:34:24 +0300
committerMnikolenko ProductEngine <mnikolenko@productengine.com>2014-05-20 11:34:24 +0300
commit16a5c9346d04f20c536e9034947873f1202eb32e (patch)
tree947beab1a9f2973e31adbe15fd2ad9516ca94ba2 /indra
parent1c82f376c2368f8f91627b3a45b2d6900d938ff4 (diff)
MAINT-3064 FIXED Select next session in the list if selected session is nearby chat and it's not the only one.
Diffstat (limited to 'indra')
-rwxr-xr-xindra/newview/llviewermenu.cpp23
-rwxr-xr-xindra/newview/skins/default/xui/en/menu_viewer.xml12
2 files changed, 30 insertions, 5 deletions
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index 1daa85176a..aef8bc21ec 100755
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -64,6 +64,7 @@
#include "llfloaterinventory.h"
#include "llfloaterimcontainer.h"
#include "llfloaterland.h"
+#include "llfloaterimnearbychat.h"
#include "llfloaterpathfindingcharacters.h"
#include "llfloaterpathfindinglinksets.h"
#include "llfloaterpay.h"
@@ -5660,6 +5661,25 @@ void toggle_debug_menus(void*)
// gExportDialog = LLUploadDialog::modalUploadDialog("Exporting selected objects...");
// }
//
+
+class LLCommunicateNearbyChat : public view_listener_t
+{
+ bool handleEvent(const LLSD& userdata)
+ {
+ LLFloaterIMContainer* im_box = LLFloaterIMContainer::getInstance();
+ bool nearby_visible = LLFloaterReg::getTypedInstance<LLFloaterIMNearbyChat>("nearby_chat")->isInVisibleChain();
+ if(nearby_visible && im_box->getSelectedSession() == LLUUID() && im_box->getConversationListItemSize() > 1)
+ {
+ im_box->selectNextorPreviousConversation(false);
+ }
+ else
+ {
+ LLFloaterReg::toggleInstanceOrBringToFront("nearby_chat");
+ }
+ return true;
+ }
+};
+
class LLWorldSetHomeLocation : public view_listener_t
{
bool handleEvent(const LLSD& userdata)
@@ -8577,6 +8597,9 @@ void initialize_menus()
// Me > Movement
view_listener_t::addMenu(new LLAdvancedAgentFlyingInfo(), "Agent.getFlying");
+ //Communicate Nearby chat
+ view_listener_t::addMenu(new LLCommunicateNearbyChat(), "Communicate.NearbyChat");
+
// Communicate > Voice morphing > Subscribe...
commit.add("Communicate.VoiceMorphing.Subscribe", boost::bind(&handle_voice_morphing_subscribe));
LLVivoxVoiceClient * voice_clientp = LLVivoxVoiceClient::getInstance();
diff --git a/indra/newview/skins/default/xui/en/menu_viewer.xml b/indra/newview/skins/default/xui/en/menu_viewer.xml
index b1c1b236f0..acec017622 100755
--- a/indra/newview/skins/default/xui/en/menu_viewer.xml
+++ b/indra/newview/skins/default/xui/en/menu_viewer.xml
@@ -259,8 +259,7 @@
function="Floater.Visible"
parameter="nearby_chat" />
<menu_item_check.on_click
- function="Floater.ToggleOrBringToFront"
- parameter="nearby_chat" />
+ function="Communicate.NearbyChat"/>
</menu_item_check>
<menu_item_check
label="Speak"
@@ -363,13 +362,16 @@
function="SideTray.PanelPeopleTab"
parameter="nearby_panel" />
</menu_item_check>
- <menu_item_call
+ <menu_item_check
label="Block List"
name="Block List">
- <menu_item_call.on_click
+ <menu_item_check.on_check
+ function="SideTray.CheckPanelPeopleTab"
+ parameter="blocked_panel" />
+ <menu_item_check.on_click
function="SideTray.PanelPeopleTab"
parameter="blocked_panel" />
- </menu_item_call>
+ </menu_item_check>
<menu_item_separator/>
<menu_item_check
name="Do Not Disturb"