VirtualBox

Changeset 95396 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Jun 27, 2022 4:07:40 PM (3 years ago)
Author:
vboxsync
Message:

FE/Qt, vboxshell.py: Restore previous touchscreen-only GUI event behavior, and let vboxshell.py show which multi-touch event type it is. bugref:9891

Location:
trunk/src/VBox/Frontends
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VBoxShell/vboxshell.py

    r94189 r95396  
    335335
    336336def printMouseEvent(_ctx, mev):
    337     print("Mouse : mode=%d x=%d y=%d z=%d w=%d buttons=%x" % (mev.mode, mev.x, mev.y, mev.z, mev.w, mev.buttons))
     337    print("Mouse: mode=%d x=%d y=%d z=%d w=%d buttons=%x" % (mev.mode, mev.x, mev.y, mev.z, mev.w, mev.buttons))
    338338
    339339def printKbdEvent(ctx, kev):
     
    341341
    342342def printMultiTouchEvent(ctx, mtev):
    343     print("MultiTouch : contacts=%d time=%d" % (mtev.contactCount, mtev.scanTime))
     343    print("MultiTouch: %s contacts=%d time=%d" \
     344        % ("touchscreen" if mtev.isTouchScreen else "touchpad", mtev.contactCount, mtev.scanTime))
    344345    xPositions = ctx['global'].getArray(mtev, 'xPositions')
    345346    yPositions = ctx['global'].getArray(mtev, 'yPositions')
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMouseHandler.cpp

    r95369 r95396  
    12011201    bool fTouchScreen = (pTouchEvent->device()->type() == QTouchDevice::TouchScreen);
    12021202#endif
     1203    /* Compatibility with previous behavior. If there is no touchpad configured
     1204     * then treat all multitouch events as touchscreen ones: */
     1205    fTouchScreen |= !uisession()->isMouseSupportsTouchPad();
    12031206
    12041207    if (fTouchScreen)
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