From ea8fb7238e6f12383ee4bc081475fa6235637581 Mon Sep 17 00:00:00 2001 From: Josh Bell Date: Sat, 31 Mar 2007 01:41:19 +0000 Subject: svn merge -r 59364:59813 svn+ssh://svn.lindenlab.com/svn/linden/branches/maintenance --> release --- indra/llui/llscrollbar.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'indra/llui/llscrollbar.cpp') diff --git a/indra/llui/llscrollbar.cpp b/indra/llui/llscrollbar.cpp index c21bbdcc75..f4aea3fa11 100644 --- a/indra/llui/llscrollbar.cpp +++ b/indra/llui/llscrollbar.cpp @@ -214,7 +214,7 @@ BOOL LLScrollbar::handleMouseDown(S32 x, S32 y, MASK mask) { // Start dragging the thumb // No handler needed for focus lost since this clas has no state that depends on it. - gFocusMgr.setMouseCapture( this, NULL ); + gFocusMgr.setMouseCapture( this ); mDragStartX = x; mDragStartY = y; mOrigRect.mTop = mThumbRect.mTop; @@ -255,7 +255,7 @@ BOOL LLScrollbar::handleHover(S32 x, S32 y, MASK mask) // because they'll capture the mouse whenever they need hover events. BOOL handled = FALSE; - if( gFocusMgr.getMouseCapture() == this ) + if( hasMouseCapture() ) { S32 height = mRect.getHeight(); S32 width = mRect.getWidth(); @@ -408,9 +408,9 @@ BOOL LLScrollbar::handleDragAndDrop(S32 x, S32 y, MASK mask, BOOL drop, BOOL LLScrollbar::handleMouseUp(S32 x, S32 y, MASK mask) { BOOL handled = FALSE; - if( gFocusMgr.getMouseCapture() == this ) + if( hasMouseCapture() ) { - gFocusMgr.setMouseCapture( NULL, NULL ); + gFocusMgr.setMouseCapture( NULL ); handled = TRUE; } else @@ -442,7 +442,7 @@ void LLScrollbar::draw() screenPointToLocal(cursor_pos_gl.mX, cursor_pos_gl.mY, &local_mouse_x, &local_mouse_y); BOOL other_captor = gFocusMgr.getMouseCapture() && gFocusMgr.getMouseCapture() != this; - BOOL hovered = mEnabled && !other_captor && (gFocusMgr.getMouseCapture() == this || mThumbRect.pointInRect(local_mouse_x, local_mouse_y)); + BOOL hovered = mEnabled && !other_captor && (hasMouseCapture() || mThumbRect.pointInRect(local_mouse_x, local_mouse_y)); if (hovered) { mCurGlowStrength = lerp(mCurGlowStrength, mHoverGlowStrength, LLCriticalDamp::getInterpolant(0.05f)); -- cgit v1.2.3