VirtualBox

Changeset 28099 in vbox for trunk/src/VBox/Devices/VMMDev


Ignore:
Timestamp:
Apr 8, 2010 3:35:40 PM (15 years ago)
Author:
vboxsync
Message:

Devices/VMMDev: inform the guest if we have an absolute pointing device

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/VMMDev/VMMDev.cpp

    r28059 r28099  
    20052005    PDMCritSectEnter(&pThis->CritSect, VERR_SEM_BUSY);
    20062006
    2007     bool bCapsChanged = ((capabilities & VMMDEV_MOUSE_HOST_CAN_ABSOLUTE)
    2008                          != (pThis->mouseCapabilities & VMMDEV_MOUSE_HOST_CAN_ABSOLUTE));
    2009 
    2010     Log(("vmmdevSetMouseCapabilities: bCapsChanged %d\n", bCapsChanged));
    2011 
    2012     if (capabilities & VMMDEV_MOUSE_HOST_CANNOT_HWPOINTER)
    2013         pThis->mouseCapabilities |= VMMDEV_MOUSE_HOST_CANNOT_HWPOINTER;
    2014     else
    2015         pThis->mouseCapabilities &= ~VMMDEV_MOUSE_HOST_CANNOT_HWPOINTER;
    2016 
    2017     if (capabilities & VMMDEV_MOUSE_HOST_CAN_ABSOLUTE)
    2018         pThis->mouseCapabilities |= VMMDEV_MOUSE_HOST_CAN_ABSOLUTE;
    2019     else
    2020         pThis->mouseCapabilities &= ~VMMDEV_MOUSE_HOST_CAN_ABSOLUTE;
    2021 
    2022     if (bCapsChanged)
     2007    bool bNotify = (   (capabilities & VMMDEV_MOUSE_NOTIFY_GUEST_MASK)
     2008                    != (pThis->mouseCapabilities & VMMDEV_MOUSE_NOTIFY_GUEST_MASK));
     2009
     2010    Log(("vmmdevSetMouseCapabilities: bNotify %d\n", bNotify));
     2011
     2012    pThis->mouseCapabilities &= ~VMMDEV_MOUSE_HOST_MASK;
     2013    pThis->mouseCapabilities |= (capabilities & VMMDEV_MOUSE_HOST_MASK);
     2014    if (bNotify)
    20232015        VMMDevNotifyGuest (pThis, VMMDEV_EVENT_MOUSE_CAPABILITIES_CHANGED);
    20242016
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette