summaryrefslogtreecommitdiff
path: root/indra/newview/llimfloater.cpp
diff options
context:
space:
mode:
authorAlexanderP ProductEngine <apaschenko@productengine.com>2012-10-02 19:36:46 +0300
committerAlexanderP ProductEngine <apaschenko@productengine.com>2012-10-02 19:36:46 +0300
commita8159facdeb478abf094d8ba8ad229c0e282f9f6 (patch)
tree0e10ddf1e9a640036d2118effe7b44a70346e5bd /indra/newview/llimfloater.cpp
parent177716ee4f2ba573c6f4384737fe985f1795e8aa (diff)
CHUI-374 FIXED (Nearby chat is torn off and cannot be docked if nearby chat is received while conversation floater is closed) Nearby_chat is created only after the creation of the im_container
Diffstat (limited to 'indra/newview/llimfloater.cpp')
-rw-r--r--indra/newview/llimfloater.cpp28
1 files changed, 15 insertions, 13 deletions
diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp
index d11504d312..99337bd5f3 100644
--- a/indra/newview/llimfloater.cpp
+++ b/indra/newview/llimfloater.cpp
@@ -111,23 +111,25 @@ void LLIMFloater::onClickCloseBtn()
{
LLIMModel::LLIMSession* session = LLIMModel::instance().findIMSession(mSessionID);
- if (session == NULL)
+ if (session != NULL)
{
- llwarns << "Empty session with id: " << (mSessionID.asString()) << llendl;
- return;
- }
+ bool is_call_with_chat = session->isGroupSessionType()
+ || session->isAdHocSessionType() || session->isP2PSessionType();
- bool is_call_with_chat = session->isGroupSessionType()
- || session->isAdHocSessionType() || session->isP2PSessionType();
+ LLVoiceChannel* voice_channel = LLIMModel::getInstance()->getVoiceChannel(mSessionID);
- LLVoiceChannel* voice_channel = LLIMModel::getInstance()->getVoiceChannel(mSessionID);
-
- if (is_call_with_chat && voice_channel != NULL
- && voice_channel->isActive())
+ if (is_call_with_chat && voice_channel != NULL
+ && voice_channel->isActive())
+ {
+ LLSD payload;
+ payload["session_id"] = mSessionID;
+ LLNotificationsUtil::add("ConfirmLeaveCall", LLSD(), payload, confirmLeaveCallCallback);
+ return;
+ }
+ }
+ else
{
- LLSD payload;
- payload["session_id"] = mSessionID;
- LLNotificationsUtil::add("ConfirmLeaveCall", LLSD(), payload, confirmLeaveCallCallback);
+ llwarns << "Empty session with id: " << (mSessionID.asString()) << llendl;
return;
}