VirtualBox

Changeset 102037 in vbox for trunk


Ignore:
Timestamp:
Nov 9, 2023 2:04:36 PM (16 months ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
160142
Message:

FE/Qt: bugref:10513: Changed requirements for Preferences / Update page; For Basic mode we've decided to hide not just some of radio-buttons but all the controls besides the main checkbox.

File:
1 edited

Legend:

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

    r101717 r102037  
    126126void UIUpdateSettingsEditor::handleFilterChange()
    127127{
    128     fetchValue();
     128    /* This stuff is for Expert mode only: */
     129    m_pWidgetUpdateSettings->setVisible(m_fInExpertMode);
    129130}
    130131
     
    309310        m_pCheckBox->setChecked(m_guiValue.isCheckEnabled());
    310311
    311         // Too tricky conditions .. update visibility for each button separately:
    312         if (m_mapRadioButtons.value(KUpdateChannel_Stable))
    313             m_mapRadioButtons.value(KUpdateChannel_Stable)
    314                 ->setVisible(   m_guiValue.updateChannel() == KUpdateChannel_Stable
    315                              || m_guiValue.supportedUpdateChannels().contains(KUpdateChannel_Stable));
    316         if (m_mapRadioButtons.value(KUpdateChannel_All))
    317             m_mapRadioButtons.value(KUpdateChannel_All)
    318                 ->setVisible(   m_guiValue.updateChannel() == KUpdateChannel_All
    319                              || m_guiValue.supportedUpdateChannels().contains(KUpdateChannel_All));
    320         if (m_mapRadioButtons.value(KUpdateChannel_WithBetas))
    321             m_mapRadioButtons.value(KUpdateChannel_WithBetas)
    322                 ->setVisible(   m_guiValue.updateChannel() == KUpdateChannel_WithBetas
    323                              || (   m_fInExpertMode
    324                                  && m_guiValue.supportedUpdateChannels().contains(KUpdateChannel_WithBetas)));
    325         if (m_mapRadioButtons.value(KUpdateChannel_WithTesting))
    326             m_mapRadioButtons.value(KUpdateChannel_WithTesting)
    327                 ->setVisible(   m_guiValue.updateChannel() == KUpdateChannel_WithTesting
    328                              || (   m_fInExpertMode
    329                                  && m_guiValue.supportedUpdateChannels().contains(KUpdateChannel_WithTesting)));
     312        foreach (KUpdateChannel enmChannel, m_mapRadioButtons.keys())
     313            if (m_mapRadioButtons.value(enmChannel))
     314                m_mapRadioButtons.value(enmChannel)
     315                    ->setVisible(   m_guiValue.updateChannel() == enmChannel
     316                                 || m_guiValue.supportedUpdateChannels().contains(enmChannel));
    330317
    331318        if (m_pCheckBox->isChecked())
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