VirtualBox

Changeset 100351 in vbox


Ignore:
Timestamp:
Jul 3, 2023 3:04:01 PM (17 months ago)
Author:
vboxsync
Message:

FE/Qt: bugref:10450: Remaining migration fixes for mouse/touch related events.

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

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/activity/vmactivity/UIVMActivityMonitor.cpp

    r100245 r100351  
    361361void UIChart::mouseMoveEvent(QMouseEvent *pEvent)
    362362{
     363#ifndef VBOX_IS_QT6_OR_LATER /* QMouseEvent::pos, x, y were replaced with QSinglePointEvent::position in Qt6 */
    363364    int iX = width() - pEvent->x() - m_iMarginRight;
     365#else
     366    int iX = width() - pEvent->position().x() - m_iMarginRight;
     367#endif
    364368    m_iDataIndexUnderCursor = -1;
    365369    if (iX > m_iMarginLeft && iX <= width() - m_iMarginRight)
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMouseHandler.cpp

    r100344 r100351  
    12021202        return true;
    12031203
     1204#ifndef VBOX_IS_QT6_OR_LATER /* QTouchEvent::TouchPoint was replaced by QEventPoint in 6.0 */
    12041205    QVector<LONG64> contacts(pTouchEvent->touchPoints().size());
     1206#else
     1207    QVector<LONG64> contacts(pTouchEvent->points().size());
     1208#endif
    12051209
    12061210    long xShift = 0, yShift = 0;
     
    12701274        } else {
    12711275            /* Get relative touch-point normalized position: */
     1276#ifndef VBOX_IS_QT6_OR_LATER /* QEventPoint::pos was replaced with QEventPoint::position in Qt6 */
    12721277            QPointF rawTouchPoint = touchPoint.normalizedPos();
     1278#else
     1279            QPointF rawTouchPoint = touchPoint.normalizedPosition();
     1280#endif
    12731281
    12741282            /* Pass relative touch-point data as Normalized Integer: */
     
    12881296    }
    12891297
    1290     uimachine()->putEventMultiTouch(pTouchEvent->touchPoints().size(),
     1298    uimachine()->putEventMultiTouch(contacts.size(),
    12911299                                    contacts,
    12921300                                    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