Changeset 19614 in vbox for trunk/src/VBox/Main
- Timestamp:
- May 12, 2009 12:27:21 PM (16 years ago)
- svn:sync-xref-src-repo-rev:
- 47192
- Location:
- trunk/src/VBox/Main
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/MouseImpl.cpp
r15716 r19614 59 59 { 60 60 mpDrv = NULL; 61 mLastAbsX = 0; 62 mLastAbsY = 0; 61 63 return S_OK; 62 64 } … … 315 317 fButtons |= PDMIMOUSEPORT_BUTTON_MIDDLE; 316 318 317 vrc = mpDrv->pUpPort->pfnPutEvent(mpDrv->pUpPort, 1, 1, dz, 318 fButtons); 319 /* This is a workaround. In order to alert the Guest Additions to the 320 * fact that the absolute pointer position has changed, we send a 321 * a minute movement event to the PS/2 mouse device. But in order 322 * to avoid the mouse jiggling every time the use clicks, we check to 323 * see if the position has really changed since the last mouse event. 324 */ 325 if ((mLastAbsX == mouseXAbs) && (mLastAbsY == mouseYAbs)) 326 vrc = mpDrv->pUpPort->pfnPutEvent(mpDrv->pUpPort, 0, 0, dz, 327 fButtons); 328 else 329 vrc = mpDrv->pUpPort->pfnPutEvent(mpDrv->pUpPort, 1, 1, dz, 330 fButtons); 331 mLastAbsX = mouseXAbs; 332 mLastAbsY = mouseYAbs; 319 333 if (RT_FAILURE (vrc)) 320 334 rc = setError (VBOX_E_IPRT_ERROR, -
trunk/src/VBox/Main/include/MouseImpl.h
r19239 r19614 106 106 107 107 LONG uHostCaps; 108 uint32_t mLastAbsX; 109 uint32_t mLastAbsY; 108 110 }; 109 111
Note:
See TracChangeset
for help on using the changeset viewer.