diff options
Diffstat (limited to 'indra/newview/llfloaterimnearbychatlistener.cpp')
-rw-r--r-- | indra/newview/llfloaterimnearbychatlistener.cpp | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/indra/newview/llfloaterimnearbychatlistener.cpp b/indra/newview/llfloaterimnearbychatlistener.cpp index e61bf5ffc2..0618741cc4 100644 --- a/indra/newview/llfloaterimnearbychatlistener.cpp +++ b/indra/newview/llfloaterimnearbychatlistener.cpp @@ -33,7 +33,6 @@ #include "llagent.h" #include "llchat.h" -#include "llluamanager.h" #include "llviewercontrol.h" #include "stringize.h" @@ -50,34 +49,6 @@ LLFloaterIMNearbyChatListener::LLFloaterIMNearbyChatListener() "[\"channel\"] chat channel number [default = 0]\n" "[\"type\"] chat type \"whisper\", \"normal\", \"shout\" [default = \"normal\"]", &LLFloaterIMNearbyChatListener::sendChat); - - add("listen", - "Start listening to the Nearby chat, chat messages will be resent to the script event pump", - &LLFloaterIMNearbyChatListener::listenChat, - llsd::map("reply", LLSD())); - - add("stopListening", - "Stop listening to the Nearby chat", - &LLFloaterIMNearbyChatListener::stopListeningChat); - - mOutConnection = LLEventPumps::instance().obtain("LLNearbyChat").listen("LLFloaterIMNearbyChatListener", [this](const LLSD &data) - { - std::map<std::string, std::string> reply_pumps = mReplyPumps; - std::map<std::string, std::string> scripts = LLLUAmanager::getScriptNames(); - for (auto &it : reply_pumps) - { - //check if listener script is still running - if (scripts.find(it.first) != scripts.end()) - { - LLEventPumps::instance().obtain(it.second).post(data); - } - else - { - mReplyPumps.erase(it.first); - } - } - return false; - }); } @@ -132,13 +103,3 @@ void LLFloaterIMNearbyChatListener::sendChat(LLSD const & chat_data) gSavedSettings.getBOOL("PlayChatAnim")); } - -void LLFloaterIMNearbyChatListener::listenChat(LLSD const &chat_data) -{ - mReplyPumps[LLCoros::getName()] = chat_data["reply"].asString(); -} - -void LLFloaterIMNearbyChatListener::stopListeningChat(LLSD const &chat_data) -{ - mReplyPumps.erase(LLCoros::getName()); -} |