diff options
author | Merov Linden <merov@lindenlab.com> | 2013-02-23 11:22:09 -0800 |
---|---|---|
committer | Merov Linden <merov@lindenlab.com> | 2013-02-23 11:22:09 -0800 |
commit | 7f51bd7897a3ced0edc74a32b9148febd7866721 (patch) | |
tree | 3e98aa8bc6f23d69afa01549c680c2989930192b /indra/newview/llfloaterimnearbychat.cpp | |
parent | 86150b4019d1a84b4af73f0ea18c47baff955562 (diff) |
CHUI-568 : Fixed! Implemented Ctrl-H for Nearby Chat, taking into account the existence of other conversations and docked/torn off state
Diffstat (limited to 'indra/newview/llfloaterimnearbychat.cpp')
-rw-r--r-- | indra/newview/llfloaterimnearbychat.cpp | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/indra/newview/llfloaterimnearbychat.cpp b/indra/newview/llfloaterimnearbychat.cpp index 80051eb7f1..a3b81e037a 100644 --- a/indra/newview/llfloaterimnearbychat.cpp +++ b/indra/newview/llfloaterimnearbychat.cpp @@ -136,23 +136,21 @@ BOOL LLFloaterIMNearbyChat::postBuild() } // virtual -void LLFloaterIMNearbyChat::closeFloater(bool app_quitting) -{ - llinfos << "Merov debug : LLFloaterIMNearbyChat::closeFloater! " << llendl; - LLFloater::closeFloater(app_quitting); -} - -// virtual void LLFloaterIMNearbyChat::closeHostedFloater() { - if (getHost()) + // Should check how many conversations are ongoing. Close all if 1 only (the Nearby Chat), select next one otherwise + LLFloaterIMContainer* floater_container = LLFloaterIMContainer::getInstance(); + if (floater_container->getConversationListItemSize() == 1) { - llinfos << "Merov debug : LLFloaterIMNearbyChat::closeHostedFloater : hosted -> do nothing" << llendl; + floater_container->closeFloater(); } else { - llinfos << "Merov debug : LLFloaterIMNearbyChat::closeHostedFloater : close floater " << llendl; - LLFloater::closeFloater(); + if (!getHost()) + { + setVisible(FALSE); + } + floater_container->selectNextConversation(LLUUID()); } } |