summaryrefslogtreecommitdiff
path: root/indra/newview/llscreenchannel.cpp
diff options
context:
space:
mode:
authorAlexei Arabadji <aarabadji@productengine.com>2009-11-12 18:57:27 +0200
committerAlexei Arabadji <aarabadji@productengine.com>2009-11-12 18:57:27 +0200
commit4c637196e4c511c7d199a66759671e16e9a7566b (patch)
tree3036fd958f032b2cfbf7cbe2e5e3a6baede037ce /indra/newview/llscreenchannel.cpp
parentb4e3d34791497188537680a4556ccacaa004db09 (diff)
fixed EXT-2397 "Notification and IM toasts stop to appear after pressing Reply in any IM toast"
--HG-- branch : product-engine
Diffstat (limited to 'indra/newview/llscreenchannel.cpp')
-rw-r--r--indra/newview/llscreenchannel.cpp19
1 files changed, 12 insertions, 7 deletions
diff --git a/indra/newview/llscreenchannel.cpp b/indra/newview/llscreenchannel.cpp
index b667fbf5fd..1f36c3d26e 100644
--- a/indra/newview/llscreenchannel.cpp
+++ b/indra/newview/llscreenchannel.cpp
@@ -63,7 +63,7 @@ LLScreenChannelBase::LLScreenChannelBase(const LLUUID& id) :
,mCanStoreToasts(true)
,mHiddenToastsNum(0)
,mOverflowToastHidden(false)
- ,mIsHovering(false)
+ ,mHoveredToast(NULL)
,mControlHovering(false)
,mShowToasts(true)
{
@@ -216,8 +216,10 @@ void LLScreenChannel::deleteToast(LLToast* toast)
// update channel's Hovering state
// turning hovering off manually because onMouseLeave won't happen if a toast was closed using a keyboard
- if(toast->hasFocus())
- setHovering(false);
+ if(mHoveredToast == toast)
+ {
+ mHoveredToast = NULL;
+ }
// close the toast
toast->closeFloater();
@@ -352,7 +354,7 @@ void LLScreenChannel::modifyToastByNotificationID(LLUUID id, LLPanel* panel)
//--------------------------------------------------------------------------
void LLScreenChannel::redrawToasts()
{
- if(mToastList.size() == 0 || mIsHovering)
+ if(mToastList.size() == 0 || isHovering())
return;
hideToastsFromScreen();
@@ -654,7 +656,10 @@ void LLScreenChannel::onToastHover(LLToast* toast, bool mouse_enter)
// we must check this to prevent incorrect setting for hovering in a channel
std::map<LLToast*, bool>::iterator it_first, it_second;
S32 stack_size = mToastEventStack.size();
- mIsHovering = mouse_enter;
+ if(mouse_enter)
+ {
+ mHoveredToast = toast;
+ }
switch(stack_size)
{
@@ -666,7 +671,7 @@ void LLScreenChannel::onToastHover(LLToast* toast, bool mouse_enter)
if((*it_first).second && !mouse_enter && ((*it_first).first != toast) )
{
mToastEventStack.clear();
- mIsHovering = true;
+ mHoveredToast = toast;
}
else
{
@@ -678,7 +683,7 @@ void LLScreenChannel::onToastHover(LLToast* toast, bool mouse_enter)
LL_ERRS ("LLScreenChannel::onToastHover: stack size error " ) << stack_size << llendl;
}
- if(!mIsHovering)
+ if(!isHovering())
redrawToasts();
}