diff options
Diffstat (limited to 'indra/newview/llimfloatercontainer.cpp')
-rw-r--r-- | indra/newview/llimfloatercontainer.cpp | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/indra/newview/llimfloatercontainer.cpp b/indra/newview/llimfloatercontainer.cpp index 49521b5987..2f248f3596 100644 --- a/indra/newview/llimfloatercontainer.cpp +++ b/indra/newview/llimfloatercontainer.cpp @@ -110,8 +110,8 @@ void LLIMFloaterContainer::addFloater(LLFloater* floaterp, icon_params.avatar_id = avatar_id; icon = LLUICtrlFactory::instance().createWidget<LLAvatarIconCtrl>(icon_params); - mSessions[avatar_id] = floaterp; - floaterp->mCloseSignal.connect(boost::bind(&LLIMFloaterContainer::onCloseFloater, this, avatar_id)); + mSessions[session_id] = floaterp; + floaterp->mCloseSignal.connect(boost::bind(&LLIMFloaterContainer::onCloseFloater, this, session_id)); } mTabContainer->setTabImage(floaterp, icon); } @@ -123,7 +123,7 @@ void LLIMFloaterContainer::onCloseFloater(LLUUID& id) void LLIMFloaterContainer::onNewMessageReceived(const LLSD& data) { - LLUUID session_id = data["from_id"].asUUID(); + LLUUID session_id = data["session_id"].asUUID(); LLFloater* floaterp = get_ptr_in_map(mSessions, session_id); LLFloater* current_floater = LLMultiFloater::getActiveFloater(); @@ -145,4 +145,18 @@ LLIMFloaterContainer* LLIMFloaterContainer::getInstance() return LLFloaterReg::getTypedInstance<LLIMFloaterContainer>("im_container"); } +void LLIMFloaterContainer::setMinimized(BOOL b) +{ + if (isMinimized() == b) return; + + LLMultiFloater::setMinimized(b); + + if (isMinimized()) return; + + if (getActiveFloater()) + { + getActiveFloater()->setVisible(TRUE); + } +} + // EOF |