summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/newview/llimview.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp
index 141d43c608..afac94af07 100644
--- a/indra/newview/llimview.cpp
+++ b/indra/newview/llimview.cpp
@@ -182,18 +182,19 @@ void on_new_message(const LLSD& msg)
{
conversations_floater_status = CLOSED;
}
- else if (!session_floater || !LLFloater::isVisible(session_floater)
- || session_floater->isMinimized() || !session_floater->hasFocus())
+ else if (!im_box->hasFocus() &&
+ !(session_floater && LLFloater::isVisible(session_floater)
+ && !session_floater->isMinimized() && session_floater->hasFocus()))
{
conversations_floater_status = NOT_ON_TOP;
}
- else if ((session_floater->hasFocus()) && (im_box->getSelectedSession() == session_id))
+ else if (im_box->getSelectedSession() != session_id)
{
- conversations_floater_status = ON_TOP_AND_ITEM_IS_SELECTED;
+ conversations_floater_status = ON_TOP;
}
else
{
- conversations_floater_status = ON_TOP;
+ conversations_floater_status = ON_TOP_AND_ITEM_IS_SELECTED;
}
// determine user prefs for this session
@@ -226,7 +227,7 @@ void on_new_message(const LLSD& msg)
// 0. nothing - exit
if (("none" == user_preferences ||
ON_TOP_AND_ITEM_IS_SELECTED == conversations_floater_status)
- && session_floater->isMessagePaneExpanded())
+ && session_floater->isMessagePaneExpanded())
{
return;
}