DEV-39056 - Fix scroll wheel on prims

the scrollEvent() API's x and y are not the same as
handleScrollWheel's x and y. The latter is the position of the mouse
at the time of the event. The former is the 'scroll amount' in x and
y, respectively. All we have for 'scroll amount' here is 'clicks', and
no mask.
meow-7.2.2
Rick Pasetto 2009-10-08 12:53:40 -07:00
parent f343395f46
commit dfabf8c8c2
1 changed files with 5 additions and 1 deletions

View File

@ -304,7 +304,11 @@ BOOL LLViewerMediaFocus::handleScrollWheel(S32 x, S32 y, S32 clicks)
BOOL retval = FALSE;
if(mFocus.notNull() && mMediaImpl.notNull() && mMediaImpl->hasMedia())
{
mMediaImpl->getMediaPlugin()->scrollEvent(x, y, clicks);
// the scrollEvent() API's x and y are not the same as handleScrollWheel's x and y.
// The latter is the position of the mouse at the time of the event
// The former is the 'scroll amount' in x and y, respectively.
// All we have for 'scroll amount' here is 'clicks', and no mask.
mMediaImpl->getMediaPlugin()->scrollEvent(0, clicks, /*mask*/0);
retval = TRUE;
}
return retval;