diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp index 92f5cd320..a7087cbd6 100644 --- a/indra/newview/llimview.cpp +++ b/indra/newview/llimview.cpp @@ -1137,11 +1137,17 @@ LLFloaterIMPanel* LLIMMgr::createFloater( gFloaterView->addChild(floater); // reparent to floater view LLFloater* focused_floater = gFloaterView->getFocusedFloater(); // obtain the focused floater floater->open(); // make the new chat floater appear + static LLCachedControl minimize("OtherChatsTornOffAndMinimized"); if (focused_floater != NULL) // there was a focused floater { floater->setMinimized(true); // so minimize this one, for now focused_floater->setFocus(true); // and work around focus being removed by focusing on the last } + else if (minimize) + { + floater->setFocus(false); // work around focus being granted to new floater + floater->setMinimized(true); + } } mFloaters.insert(floater->getHandle()); return floater; @@ -1184,6 +1190,7 @@ LLFloaterIMPanel* LLIMMgr::createFloater( } else if (minimize) { + floater->setFocus(false); // work around focus being granted to new floater floater->setMinimized(true); } }