diff options
Diffstat (limited to 'indra/newview/llimfloater.cpp')
-rw-r--r-- | indra/newview/llimfloater.cpp | 29 |
1 files changed, 25 insertions, 4 deletions
diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index 47a168e354..ff1eb10366 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -122,9 +122,13 @@ void LLIMFloater::onFocusReceived() void LLIMFloater::onClose(bool app_quitting) { setTyping(false); - // SJB: We want the close button to hide the session window, not end it - // *NOTE: Yhis is functional, but not ideal - it's still closing the floater; we really want to change the behavior of the X button instead. - //gIMMgr->leaveSession(mSessionID); + + // The source of much argument and design thrashing + // Should the window hide or the session close when the X is clicked? + // + // Last change: + // EXT-3516 X Button should end IM session, _ button should hide + gIMMgr->leaveSession(mSessionID); } /* static */ @@ -469,7 +473,7 @@ bool LLIMFloater::toggle(const LLUUID& session_id) if(!isChatMultiTab()) { LLIMFloater* floater = LLFloaterReg::findTypedInstance<LLIMFloater>("impanel", session_id); - if (floater && floater->getVisible() && floater->isDocked()) + if (floater && floater->getVisible()) { // clicking on chiclet to close floater just hides it to maintain existing // scroll/text entry state @@ -947,3 +951,20 @@ void LLIMFloater::initIMFloater() // init chat window type before user changed it in preferences isChatMultiTab(); } + +//static +void LLIMFloater::sRemoveTypingIndicator(const LLSD& data) +{ + LLUUID session_id = data["session_id"]; + if (session_id.isNull()) return; + + LLUUID from_id = data["from_id"]; + if (gAgentID == from_id || LLUUID::null == from_id) return; + + LLIMFloater* floater = LLIMFloater::findInstance(session_id); + if (!floater) return; + + if (IM_NOTHING_SPECIAL != floater->mDialog) return; + + floater->removeTypingIndicator(); +} |