Changeset 26964 in vbox for trunk/src/VBox
- Timestamp:
- Mar 2, 2010 5:53:21 PM (15 years ago)
- Location:
- trunk/src/VBox
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMachineView.cpp
r26929 r26964 1100 1100 if (uisession()->isMouseSupportsAbsolute()) 1101 1101 { 1102 /* Should we hide/show pointer? */ 1103 if (uisession()->isHidingHostPointer()) 1102 /* Should we use guest pointer shape? */ 1103 if (uisession()->isValidPointerShapePresent()) 1104 viewport()->setCursor(uisession()->cursor()); 1105 /* Should we hide pointer at all? */ 1106 else if (uisession()->isHidingHostPointer()) 1104 1107 viewport()->setCursor(Qt::BlankCursor); 1105 else1106 viewport()->setCursor(uisession()->cursor());1107 1108 } 1108 1109 } -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UISession.cpp
r26921 r26964 554 554 , m_fIsMouseCaptured(false) 555 555 , m_fIsMouseIntegrated(true) 556 , m_fIsValidPointerShapePresent(false) 556 557 , m_fIsHideHostPointer(true) 557 558 { … … 973 974 AssertMsg(pShapeData, ("Shape data must not be NULL!\n")); 974 975 976 m_fIsValidPointerShapePresent = false; 975 977 const uchar *srcAndMaskPtr = pShapeData; 976 978 uint andMaskSize = (uWidth + 7) / 8 * uHeight; … … 1095 1097 DestroyIcon(m_alphaCursor); 1096 1098 m_alphaCursor = hAlphaCursor; 1099 m_fIsValidPointerShapePresent = true; 1097 1100 } 1098 1101 } … … 1151 1154 /* Set the new cursor: */ 1152 1155 m_cursor = QCursor(XcursorImageLoadCursor(QX11Info::display(), img)); 1156 m_fIsValidPointerShapePresent = true; 1153 1157 1154 1158 XcursorImageDestroy(img); … … 1190 1194 /* Set the new cursor: */ 1191 1195 m_cursor = QCursor(QPixmap::fromImage(image), uXHot, uYHot); 1196 m_fIsValidPointerShapePresent = true; 1192 1197 NOREF(srcShapePtrScan); 1193 1198 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UISession.h
r26952 r26964 114 114 bool isMouseCaptured() const { return m_fIsMouseCaptured; } 115 115 bool isMouseIntegrated() const { return m_fIsMouseIntegrated; } 116 bool isValidPointerShapePresent() const { return m_fIsValidPointerShapePresent; } 116 117 bool isHidingHostPointer() const { return m_fIsMouseCaptured || (m_fIsMouseSupportsAbsolute && m_fIsHideHostPointer); } 117 118 … … 211 212 bool m_fIsMouseCaptured : 1; 212 213 bool m_fIsMouseIntegrated : 1; 214 bool m_fIsValidPointerShapePresent : 1; 213 215 bool m_fIsHideHostPointer : 1; 214 216 -
trunk/src/VBox/Main/MouseImpl.cpp
r26935 r26964 428 428 HRESULT rc = convertDisplayWidth(x, &mouseXAbs); 429 429 ComAssertComRCRet(rc, rc); 430 if (mouseXAbs > 0xffff) 431 mouseXAbs = mLastAbsX; 430 /// TODO: Remove those strings? 431 //if (mouseXAbs > 0xffff) 432 // mouseXAbs = mLastAbsX; 432 433 433 434 uint32_t mouseYAbs; 434 435 rc = convertDisplayHeight(y, &mouseYAbs); 435 436 ComAssertComRCRet(rc, rc); 436 if (mouseYAbs > 0xffff) 437 mouseYAbs = mLastAbsY; 437 /// TODO: Remove those strings? 438 //if (mouseYAbs > 0xffff) 439 // mouseYAbs = mLastAbsY; 438 440 439 441 uint32_t fButtons = mouseButtonsToPDM(buttonState);
Note:
See TracChangeset
for help on using the changeset viewer.