VirtualBox

Ignore:
Timestamp:
Feb 2, 2007 1:57:12 PM (18 years ago)
Author:
vboxsync
Message:

FE/Qt: Latest fixes to VDM and media enumeration process (better cooperation between media cobmoboxes, modal and modeless VDMs during the enumeration).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/ui/VBoxVMSettingsDlg.ui.h

    r441 r548  
    658658{
    659659    /* setup necessary combobox item */
    660     cbHDA->setRequiredItem (uuidHDA);
    661     cbHDB->setRequiredItem (uuidHDB);
    662     cbHDD->setRequiredItem (uuidHDD);
    663     cbISODVD->setRequiredItem (uuidISODVD);
    664     cbISOFloppy->setRequiredItem (uuidISOFloppy);
    665     /* request for refresh every combo-box */
    666     cbHDA->setReadyForRefresh();
    667     cbHDB->setReadyForRefresh();
    668     cbHDD->setReadyForRefresh();
    669     cbISODVD->setReadyForRefresh();
    670     cbISOFloppy->setReadyForRefresh();
    671     /* starting media-enumerating process */
    672     vboxGlobal().startEnumeratingMedia();
     660    cbHDA->setCurrentItem (uuidHDA);
     661    cbHDB->setCurrentItem (uuidHDB);
     662    cbHDD->setCurrentItem (uuidHDD);
     663    cbISODVD->setCurrentItem (uuidISODVD);
     664    cbISOFloppy->setCurrentItem (uuidISOFloppy);
     665    /* check if the enumeration process has been started yet */
     666    if (!vboxGlobal().isMediaEnumerationStarted())
     667        vboxGlobal().startEnumeratingMedia();
     668    else
     669    {
     670        cbHDA->refresh();
     671        cbHDB->refresh();
     672        cbHDD->refresh();
     673        cbISODVD->refresh();
     674        cbISOFloppy->refresh();
     675    }
    673676}
    674677
     
    677680{
    678681    uuidHDA = grbHDA->isChecked() ? cbHDA->getId() : QUuid();
    679     cbHDA->setRequiredItem (uuidHDA);
    680682    txHDA->setText (getHdInfo (grbHDA, uuidHDA));
    681683    /* revailidate */
     
    687689{
    688690    uuidHDB = grbHDB->isChecked() ? cbHDB->getId() : QUuid();
    689     cbHDB->setRequiredItem (uuidHDB);
    690691    txHDB->setText (getHdInfo (grbHDB, uuidHDB));
    691692    /* revailidate */
     
    697698{
    698699    uuidHDD = grbHDD->isChecked() ? cbHDD->getId() : QUuid();
    699     cbHDD->setRequiredItem (uuidHDD);
    700700    txHDD->setText (getHdInfo (grbHDD, uuidHDD));
    701701    /* revailidate */
     
    707707{
    708708    uuidISODVD = bgDVD->isChecked() ? cbISODVD->getId() : QUuid();
    709     cbISODVD->setRequiredItem (uuidISODVD);
    710709    /* revailidate */
    711710    wvalDVD->revalidate();
     
    716715{
    717716    uuidISOFloppy = bgFloppy->isChecked() ? cbISOFloppy->getId() : QUuid();
    718     cbISOFloppy->setRequiredItem (uuidISOFloppy);
    719717    /* revailidate */
    720718    wvalFloppy->revalidate();
     
    12881286
    12891287    /* request for media shortcuts update */
    1290     cbHDA->setBelongsTo(machine.GetId());
    1291     cbHDB->setBelongsTo(machine.GetId());
    1292     cbHDD->setBelongsTo(machine.GetId());
     1288    cbHDA->setBelongsTo (machine.GetId());
     1289    cbHDB->setBelongsTo (machine.GetId());
     1290    cbHDD->setBelongsTo (machine.GetId());
    12931291    updateShortcuts();
    12941292
     
    15411539    QUuid machineId = cmachine.GetId();
    15421540    dlg.setup (type, true, &machineId, (const VBoxMediaList*)0, cmachine);
    1543     if (dlg.exec() == VBoxDiskImageManagerDlg::Accepted)
    1544         *id = dlg.getSelectedUuid();
    1545     updateShortcuts();
     1541    *id = dlg.exec() == VBoxDiskImageManagerDlg::Accepted ?
     1542        dlg.getSelectedUuid() : cbb->getId();
     1543    cbb->setCurrentItem (*id);
    15461544    cbb->setFocus();
     1545
     1546    /* revalidate pages with custom validation */
     1547    wvalHDD->revalidate();
     1548    wvalDVD->revalidate();
     1549    wvalFloppy->revalidate();
    15471550}
    15481551
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