VirtualBox

Changeset 88014 in vbox


Ignore:
Timestamp:
Mar 8, 2021 12:52:42 PM (4 years ago)
Author:
vboxsync
Message:

FE/Qt: bugref:9950. Several fixes

Location:
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVM.cpp

    r88001 r88014  
    630630void UIWizardNewVM::setVirtualDisk(const CMedium &medium)
    631631{
    632     m_virtualDisk == medium;
     632    m_virtualDisk = medium;
    633633}
    634634
  • trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMPageBasic4.cpp

    r88001 r88014  
    6565void UIWizardNewVMPage4::getWithFileOpenDialog()
    6666{
    67     /* Get opened medium id: */
    6867    QUuid uMediumId;
    69 
    7068    int returnCode = uiCommon().openMediumSelectorDialog(thisImp(), UIMediumDeviceType_HardDisk,
    7169                                                           uMediumId,
     
    7472                                                           fieldImp("type").value<CGuestOSType>().GetId(),
    7573                                                           false /* don't show/enable the create action: */);
    76 
    7774    if (returnCode == static_cast<int>(UIMediumSelector::ReturnCode_Accepted) && !uMediumId.isNull())
    7875    {
     
    277274void UIWizardNewVMPageBasic4::sltGetWithFileOpenDialog()
    278275{
    279     /* Call to base-class: */
    280276    getWithFileOpenDialog();
    281277}
  • trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMPageExpert.cpp

    r88001 r88014  
    103103    registerField("selectedDiskSource", this, "selectedDiskSource");
    104104    registerField("mediumVariant", this, "mediumVariant");
    105 
    106     disableEnableUnattendedRelatedWidgets(isUnattendedEnabled());
    107     setEnableDiskSelectionWidgets(m_enmSelectedDiskSource == SelectedDiskSource_Existing);
    108     setEnableNewDiskWidgets(m_enmSelectedDiskSource == SelectedDiskSource_New);
    109105}
    110106
     
    134130}
    135131
    136 void UIWizardNewVMPageExpert::sltVirtualDiskSourceChanged()
    137 {
    138     /* Broadcast complete-change: */
    139     emit completeChanged();
    140 }
    141132
    142133void UIWizardNewVMPageExpert::sltGetWithFileOpenDialog()
    143134{
     135    getWithFileOpenDialog();
    144136}
    145137
     
    244236                this, &UIWizardNewVMPageExpert::sltInstallGACheckBoxToggle);
    245237
    246     if (m_pDiskEmpty)
    247     {
    248         connect(m_pDiskEmpty, &QRadioButton::toggled,
    249                 this, &UIWizardNewVMPageExpert::sltVirtualDiskSourceChanged);
    250         connect(m_pDiskEmpty, &QRadioButton::toggled,
    251                 this, &UIWizardNewVMPageExpert::sltValueModified);
    252     }
    253     if (m_pDiskNew)
    254     {
    255         connect(m_pDiskNew, &QRadioButton::toggled,
    256                 this, &UIWizardNewVMPageExpert::sltVirtualDiskSourceChanged);
    257         connect(m_pDiskNew, &QRadioButton::toggled,
    258                 this, &UIWizardNewVMPageExpert::sltValueModified);
    259     }
    260     if (m_pDiskExisting)
    261     {
    262         connect(m_pDiskExisting, &QRadioButton::toggled,
    263                 this, &UIWizardNewVMPageExpert::sltVirtualDiskSourceChanged);
    264         connect(m_pDiskExisting, &QRadioButton::toggled,
    265                 this, &UIWizardNewVMPageExpert::sltValueModified);
    266     }
    267     if (m_pDiskSelector)
    268         connect(m_pDiskSelector, static_cast<void(UIMediaComboBox::*)(int)>(&UIMediaComboBox::currentIndexChanged),
    269                 this, &UIWizardNewVMPageExpert::sltVirtualDiskSourceChanged);
    270238    if (m_pDiskSelectionButton)
    271239        connect(m_pDiskSelectionButton, &QIToolButton::clicked,
    272240                this, &UIWizardNewVMPageExpert::sltGetWithFileOpenDialog);
     241
    273242    if (m_pBaseMemoryEditor)
    274243        connect(m_pBaseMemoryEditor, &UIBaseMemoryEditor::sigValueChanged,
     
    290259
    291260    if (m_pDiskSourceButtonGroup)
     261    {
    292262        connect(m_pDiskSourceButtonGroup, static_cast<void(QButtonGroup::*)(QAbstractButton *)>(&QButtonGroup::buttonClicked),
    293263                this, &UIWizardNewVMPageExpert::sltSelectedDiskSourceChanged);
     264        connect(m_pDiskSourceButtonGroup, static_cast<void(QButtonGroup::*)(QAbstractButton *)>(&QButtonGroup::buttonClicked),
     265                this, &UIWizardNewVMPageExpert::sltValueModified);
     266    }
    294267}
    295268
     
    360333void UIWizardNewVMPageExpert::initializePage()
    361334{
    362     /* Translate page: */
    363     retranslateUi();
     335    disableEnableUnattendedRelatedWidgets(isUnattendedEnabled());
     336    setEnableDiskSelectionWidgets(m_enmSelectedDiskSource == SelectedDiskSource_Existing);
     337    setEnableNewDiskWidgets(m_enmSelectedDiskSource == SelectedDiskSource_New);
    364338    setOSTypeDependedValues();
    365339    disableEnableUnattendedRelatedWidgets(isUnattendedEnabled());
    366340    updateVirtualDiskPathFromMachinePathName();
    367341    updateWidgetAterMediumFormatChange();
     342    retranslateUi();
    368343}
    369344
  • trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvm/UIWizardNewVMPageExpert.h

    r88001 r88014  
    9191    void sltPathChanged(const QString &strNewPath);
    9292    void sltOsTypeChanged();
    93     void sltVirtualDiskSourceChanged();
     93    void sltMediaComboBoxIndexChanged();
    9494    void sltGetWithFileOpenDialog();
    9595    void sltISOPathChanged(const QString &strPath);
     
    100100    void sltMediumFormatChanged();
    101101    void sltMediumSizeChanged();
    102     void sltMediaComboBoxIndexChanged();
    103102    void sltSelectedDiskSourceChanged();
    104103
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