Skip to content
Snippets Groups Projects
Commit 04b84ce0 authored by Mnikolenko ProductEngine's avatar Mnikolenko ProductEngine
Browse files

MAINT-3290 FIXED Handle correctly Mouse Capture for LLTextBox.

parent dbb67c32
No related branches found
No related tags found
No related merge requests found
...@@ -59,11 +59,14 @@ BOOL LLTextBox::handleMouseDown(S32 x, S32 y, MASK mask) ...@@ -59,11 +59,14 @@ BOOL LLTextBox::handleMouseDown(S32 x, S32 y, MASK mask)
} }
if (!handled && mClickedCallback) if (!handled && mClickedCallback)
{
handled = TRUE;
}
if (handled)
{ {
// Route future Mouse messages here preemptively. (Release on mouse up.) // Route future Mouse messages here preemptively. (Release on mouse up.)
gFocusMgr.setMouseCapture( this ); gFocusMgr.setMouseCapture( this );
handled = TRUE;
} }
return handled; return handled;
...@@ -71,7 +74,7 @@ BOOL LLTextBox::handleMouseDown(S32 x, S32 y, MASK mask) ...@@ -71,7 +74,7 @@ BOOL LLTextBox::handleMouseDown(S32 x, S32 y, MASK mask)
BOOL LLTextBox::handleMouseUp(S32 x, S32 y, MASK mask) BOOL LLTextBox::handleMouseUp(S32 x, S32 y, MASK mask)
{ {
BOOL handled = FALSE; BOOL handled = LLTextBase::handleMouseUp(x, y, mask);
if (getSoundFlags() & MOUSE_UP) if (getSoundFlags() & MOUSE_UP)
{ {
...@@ -93,10 +96,6 @@ BOOL LLTextBox::handleMouseUp(S32 x, S32 y, MASK mask) ...@@ -93,10 +96,6 @@ BOOL LLTextBox::handleMouseUp(S32 x, S32 y, MASK mask)
handled = TRUE; handled = TRUE;
} }
} }
else
{
handled = LLTextBase::handleMouseUp(x, y, mask);
}
return handled; return handled;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment