summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llimfloatercontainer.cpp7
-rw-r--r--indra/newview/llimfloatercontainer.h1
2 files changed, 8 insertions, 0 deletions
diff --git a/indra/newview/llimfloatercontainer.cpp b/indra/newview/llimfloatercontainer.cpp
index 9539553121..ba034609e9 100644
--- a/indra/newview/llimfloatercontainer.cpp
+++ b/indra/newview/llimfloatercontainer.cpp
@@ -100,6 +100,7 @@ void LLIMFloaterContainer::addFloater(LLFloater* floaterp,
icon = LLUICtrlFactory::instance().createWidget<LLGroupIconCtrl>(icon_params);
mSessions[session_id] = floaterp;
+ floaterp->mCloseSignal.connect(boost::bind(&LLIMFloaterContainer::onCloseFloater, this, session_id));
}
else
{
@@ -110,10 +111,16 @@ void LLIMFloaterContainer::addFloater(LLFloater* floaterp,
icon = LLUICtrlFactory::instance().createWidget<LLAvatarIconCtrl>(icon_params);
mSessions[avatar_id] = floaterp;
+ floaterp->mCloseSignal.connect(boost::bind(&LLIMFloaterContainer::onCloseFloater, this, avatar_id));
}
mTabContainer->setTabImage(floaterp, icon);
}
+void LLIMFloaterContainer::onCloseFloater(LLUUID& id)
+{
+ mSessions.erase(id);
+}
+
void LLIMFloaterContainer::processProperties(void* data, enum EAvatarProcessorType type)
{
if (APT_PROPERTIES == type)
diff --git a/indra/newview/llimfloatercontainer.h b/indra/newview/llimfloatercontainer.h
index daf367da11..b07ef2d71d 100644
--- a/indra/newview/llimfloatercontainer.h
+++ b/indra/newview/llimfloatercontainer.h
@@ -51,6 +51,7 @@ public:
/*virtual*/ BOOL postBuild();
/*virtual*/ void onOpen(const LLSD& key);
+ void onCloseFloater(LLUUID& id);
/*virtual*/ void addFloater(LLFloater* floaterp,
BOOL select_added_floater,