VirtualBox

Changeset 106226 in vbox


Ignore:
Timestamp:
Oct 7, 2024 2:47:00 PM (8 weeks ago)
Author:
vboxsync
Message:

FE/Qt: bugref:10513: Advanced Settings Dialog: Install event-filter to all children widgets, not just some of them; This is required to properly update enabled/disabled state look&feel.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/settings/UIAdvancedSettingsDialog.cpp

    r106121 r106226  
    574574                                    }");
    575575#endif
    576         m_pLineEdit->installEventFilter(this);
    577576        connect(m_pLineEdit, &QILineEdit::textChanged,
    578577                this, &UIFilterEditor::sltHandleEditorTextChanged);
     
    10521051    }
    10531052
    1054     /* Install event-filters for all the required children.
    1055      * These children can be added together with pages. */
     1053    /* Install event-filters for all the widget children: */
    10561054    foreach (QWidget *pChild, findChildren<QWidget*>())
    1057     {
    1058         if (   qobject_cast<QAbstractButton*>(pChild)
    1059             || qobject_cast<QAbstractScrollArea*>(pChild)
    1060             || qobject_cast<QAbstractScrollArea*>(pChild->parent())
    1061             || qobject_cast<QAbstractSpinBox*>(pChild)
    1062             || qobject_cast<QAbstractSpinBox*>(pChild->parent())
    1063             || qobject_cast<QCheckBox*>(pChild)
    1064             || qobject_cast<QComboBox*>(pChild)
    1065             || qobject_cast<QLabel*>(pChild)
    1066             || qobject_cast<QLineEdit*>(pChild)
    1067             || qobject_cast<QSlider*>(pChild)
    1068             || qobject_cast<QSpinBox*>(pChild)
    1069             || qobject_cast<QTabWidget*>(pChild)
    1070             || qobject_cast<QTabWidget*>(pChild->parent()))
     1055        if (qobject_cast<QWidget*>(pChild))
    10711056            pChild->installEventFilter(this);
    1072     }
    10731057
    10741058    /* Choose page/tab finally: */
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