diff options
author | AlexanderP ProductEngine <apaschenko@productengine.com> | 2012-06-18 21:11:56 +0300 |
---|---|---|
committer | AlexanderP ProductEngine <apaschenko@productengine.com> | 2012-06-18 21:11:56 +0300 |
commit | bc5e0eda1b1b9c289734bebe6a533565aadfd3a2 (patch) | |
tree | 372f21c43d094f959a2cb77e72ab0bd384fd5f1c | |
parent | 5207da8a63dcd4ab85dc3384c66340455a8aa7d1 (diff) |
CHUI-119 fixed bug with creating multiply instances of the nearby chat;
-rw-r--r-- | indra/newview/llimfloatercontainer.cpp | 3 | ||||
-rw-r--r-- | indra/newview/llnearbychat.cpp | 6 | ||||
-rwxr-xr-x | indra/newview/llviewerwindow.cpp | 2 |
3 files changed, 3 insertions, 8 deletions
diff --git a/indra/newview/llimfloatercontainer.cpp b/indra/newview/llimfloatercontainer.cpp index af5d587f20..8493a0e7b8 100644 --- a/indra/newview/llimfloatercontainer.cpp +++ b/indra/newview/llimfloatercontainer.cpp @@ -96,8 +96,7 @@ void LLIMFloaterContainer::onOpen(const LLSD& key) // If there's *no* conversation open so far, we force the opening of the nearby chat conversation // *TODO: find a way to move this to XML as a default panel or something like that LLSD name("chat_bar"); - LLSD key(""); - LLFloaterReg::toggleInstanceOrBringToFront(name,key); + LLFloaterReg::toggleInstanceOrBringToFront(name); } /* if (key.isDefined()) diff --git a/indra/newview/llnearbychat.cpp b/indra/newview/llnearbychat.cpp index fbaf451412..e4b891889c 100644 --- a/indra/newview/llnearbychat.cpp +++ b/indra/newview/llnearbychat.cpp @@ -130,6 +130,7 @@ LLNearbyChat::LLNearbyChat(const LLSD& key) mSpeakerMgr(NULL), mExpandedHeight(COLLAPSED_HEIGHT + EXPANDED_HEIGHT) { + mKey = LLSD(); mIsNearbyChat = true; mSpeakerMgr = LLLocalSpeakerMgr::getInstance(); } @@ -382,11 +383,6 @@ LLNearbyChat* LLNearbyChat::getInstance() return LLFloaterReg::getTypedInstance<LLNearbyChat>("chat_bar"); } -//static -//LLNearbyChat* LLNearbyChat::findInstance() -//{ -// return LLFloaterReg::findTypedInstance<LLNearbyChat>("chat_bar"); -//} void LLNearbyChat::showHistory() { diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index 7f14e021fd..016da1d994 100755 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -2555,7 +2555,7 @@ BOOL LLViewerWindow::handleKey(KEY key, MASK mask) if ( gSavedSettings.getS32("LetterKeysFocusChatBar") && !gAgentCamera.cameraMouselook() && !keyboard_focus && key < 0x80 && (mask == MASK_NONE || mask == MASK_SHIFT) ) { - LLLineEditor* chat_editor = LLFloaterReg::getTypedInstance<LLNearbyChat>("chat_bar")->getChatBox(); + LLLineEditor* chat_editor = LLNearbyChat::getInstance()->getChatBox(); if (chat_editor) { // passing NULL here, character will be added later when it is handled by character handler. |