summaryrefslogtreecommitdiff
path: root/indra/newview/llfloaterimsession.cpp
diff options
context:
space:
mode:
authorBrad Linden <brad@lindenlab.com>2024-08-20 09:44:14 -0700
committerBrad Linden <brad@lindenlab.com>2024-08-20 09:44:14 -0700
commit68f712615f6858d66aef1d030fb18debb1a2dae4 (patch)
tree08a0b93af46ca152d72238dffd9543af1b19ce2c /indra/newview/llfloaterimsession.cpp
parent9f7dd0177201fe080c287144b99a70125be1fb2b (diff)
parent1d017b76292cf8c7afad34ec54d7401e2f1795e5 (diff)
Merge remote-tracking branch 'origin/release/2024.06-atlasaurus' into develop
# Conflicts: # autobuild.xml # indra/newview/llvoicewebrtc.cpp
Diffstat (limited to 'indra/newview/llfloaterimsession.cpp')
-rw-r--r--indra/newview/llfloaterimsession.cpp17
1 files changed, 11 insertions, 6 deletions
diff --git a/indra/newview/llfloaterimsession.cpp b/indra/newview/llfloaterimsession.cpp
index 5dd78fe1db..557b3f27c5 100644
--- a/indra/newview/llfloaterimsession.cpp
+++ b/indra/newview/llfloaterimsession.cpp
@@ -138,8 +138,14 @@ void LLFloaterIMSession::onTearOffClicked()
}
// virtual
-void LLFloaterIMSession::onClickCloseBtn(bool)
+void LLFloaterIMSession::onClickCloseBtn(bool app_qutting)
{
+ if (app_qutting)
+ {
+ LLFloaterIMSessionTab::onClickCloseBtn();
+ return;
+ }
+
LLIMModel::LLIMSession* session = LLIMModel::instance().findIMSession(mSessionID);
if (session != NULL)
@@ -287,10 +293,8 @@ void LLFloaterIMSession::sendMsg(const std::string& msg)
LLFloaterIMSession::~LLFloaterIMSession()
{
mVoiceChannelStateChangeConnection.disconnect();
- if(LLVoiceClient::instanceExists())
- {
- LLVoiceClient::getInstance()->removeObserver(this);
- }
+
+ LLVoiceClient::removeObserver(this);
LLTransientFloaterMgr::getInstance()->removeControlView(LLTransientFloaterMgr::IM, this);
@@ -366,7 +370,7 @@ bool LLFloaterIMSession::postBuild()
childSetAction("voice_call_btn", boost::bind(&LLFloaterIMSession::onCallButtonClicked, this));
- LLVoiceClient::getInstance()->addObserver(this);
+ LLVoiceClient::addObserver(this);
//*TODO if session is not initialized yet, add some sort of a warning message like "starting session...blablabla"
//see LLFloaterIMPanel for how it is done (IB)
@@ -537,6 +541,7 @@ void LLFloaterIMSession::boundVoiceChannel()
LLVoiceChannel* voice_channel = LLIMModel::getInstance()->getVoiceChannel(mSessionID);
if(voice_channel)
{
+ mVoiceChannelStateChangeConnection.disconnect();
mVoiceChannelStateChangeConnection = voice_channel->setStateChangedCallback(
boost::bind(&LLFloaterIMSession::onVoiceChannelStateChanged, this, _1, _2));