VirtualBox

Changeset 8201 in vbox for trunk/src


Ignore:
Timestamp:
Apr 19, 2008 10:05:59 PM (17 years ago)
Author:
vboxsync
Message:

FE/Qt: Hard Disk UI: Fixed OSE (No SATA so far).

File:
1 edited

Legend:

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

    r8193 r8201  
    568568    mMachine = aMachine;
    569569
    570     mCbSATA->setChecked (mMachine.GetSATAController().GetEnabled());
     570    {
     571        CSATAController ctl = mMachine.GetSATAController();
     572        if (ctl.isNull())
     573        {
     574            /* hide the SATA check box if the SATA controller is not available
     575             * (i.e. in VirtualBox OSE) */
     576            mCbSATA->setHidden (true);
     577        }
     578        else
     579        {
     580            mCbSATA->setChecked (ctl.GetEnabled());
     581        }
     582    }
    571583
    572584    CHardDiskAttachmentEnumerator en =
     
    587599void VBoxHardDiskSettings::putBackToMachine()
    588600{
    589     mMachine.GetSATAController().SetEnabled (mCbSATA->isChecked());
     601    CSATAController ctl = mMachine.GetSATAController();
     602    if (!ctl.isNull())
     603    {
     604        ctl.SetEnabled (mCbSATA->isChecked());
     605    }
    590606
    591607    /* Detach all attached Hard Disks */
     
    621637    }
    622638
    623     mMachine.GetSATAController().SetPortCount (maxSATAPort);
     639    if (!ctl.isNull())
     640    {
     641        mMachine.GetSATAController().SetPortCount (maxSATAPort);
     642    }
    624643}
    625644
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