VirtualBox

Changeset 14566 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Nov 25, 2008 11:35:46 AM (16 years ago)
Author:
vboxsync
Message:

FE/Qt4: 64bit OSes removed from the list of host which doesn't supports HWVirtEx or Long Mode.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox4/src/VBoxOSTypeSelectorWidget.cpp

    r14481 r14566  
    154154    mCbType->clear();
    155155
     156    /* Check if host supports (AMD-V or VT-x) and long mode */
     157    CHost host = vboxGlobal().virtualBox().GetHost();
     158    bool mSupportsHWVirtEx = host.GetProcessorFeature (KProcessorFeature_HWVirtEx);
     159    bool mSupportsLongMode = host.GetProcessorFeature (KProcessorFeature_LongMode);
     160
    156161    /* Populate combo-box with OS Types related to currently selected Family ID */
    157162    QString familyId (mCbFamily->itemData (aIndex, RoleTypeID).toString());
     
    159164    for (int i = 0; i < types.size(); ++ i)
    160165    {
    161         mCbType->insertItem (i, types [i].GetDescription());
    162         mCbType->setItemData (i, types [i].GetId(), RoleTypeID);
     166        if (types [i].GetIs64Bit() && (!mSupportsHWVirtEx || !mSupportsLongMode))
     167            continue;
     168        int index = mCbType->count();
     169        mCbType->insertItem (index, types [i].GetDescription());
     170        mCbType->setItemData (index, types [i].GetId(), RoleTypeID);
    163171    }
    164172
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