VirtualBox

Changeset 78002 in vbox for trunk/src/VBox/Frontends


Ignore:
Timestamp:
Apr 3, 2019 4:02:03 PM (6 years ago)
Author:
vboxsync
Message:

FE/Qt: bugref:6699: Handle only events sent to required object and call to base-class afterwards, eventFilter is a virtual function first of all.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/guestctrl/UIFileManagerTable.cpp

    r77936 r78002  
    11081108bool UIFileManagerTable::eventFilter(QObject *pObject, QEvent *pEvent) /* override */
    11091109{
    1110     Q_UNUSED(pObject);
     1110    /* Handle only events sent to m_pView: */
     1111    if (pObject != m_pView)
     1112        return QIWithRetranslateUI<QWidget>::eventFilter(pObject, pEvent);
     1113
    11111114    if (pEvent->type() == QEvent::KeyPress)
    11121115    {
     
    11551158                return true;
    11561159            }
    1157         }/* if (pKeyEvent) */
    1158     }/* if (pEvent->type() == QEvent::KeyPress) */
     1160        }
     1161    }
    11591162    else if (pEvent->type() == QEvent::FocusOut)
    11601163    {
    11611164        disableSelectionSearch();
    11621165    }
    1163     /* Dont hold up the @pEvent but rather send it to the target @pObject: */
    1164     return false;
     1166
     1167    /* Call to base-class: */
     1168    return QIWithRetranslateUI<QWidget>::eventFilter(pObject, pEvent);
    11651169}
    11661170
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