Changeset 44503 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Feb 1, 2013 6:28:53 AM (12 years ago)
- Location:
- trunk/src/VBox/Frontends
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxManage/VBoxManageList.cpp
r44498 r44503 271 271 COMGETTER(Id)(description.asOutParam())); 272 272 273 ULONG caps; 273 ULONG caps = 0; 274 com::SafeArray <MediumFormatCapabilities_T> mediumFormatCap; 274 275 CHECK_ERROR(mediumFormats[i], 275 COMGETTER(Capabilities)(&caps)); 276 COMGETTER(Capabilities)(ComSafeArrayAsOutParam(mediumFormatCap))); 277 for (ULONG j = 0; j < mediumFormatCap.size(); j++) 278 caps |= mediumFormatCap[j]; 279 276 280 277 281 RTPrintf("Backend %u: id='%ls' description='%ls' capabilities=%#06x extensions='", -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIMessageCenter.cpp
r44453 r44503 1459 1459 .arg(aMedium.location()); 1460 1460 1461 qulonglong caps = 0; 1462 QVector<KMediumFormatCapabilities> capabilities; 1463 capabilities = aMedium.medium().GetMediumFormat().GetCapabilities(); 1464 for (int i = 0; i < capabilities.size(); i++) 1465 caps |= capabilities[i]; 1466 1461 1467 if (aMedium.type() == UIMediumType_HardDisk && 1462 aMedium.medium().GetMediumFormat().GetCapabilities()& MediumFormatCapabilities_File)1468 caps & MediumFormatCapabilities_File) 1463 1469 { 1464 1470 if (aMedium.state() == KMediumState_Inaccessible) -
trunk/src/VBox/Frontends/VirtualBox/src/medium/UIMediumManager.cpp
r43424 r44503 1142 1142 * will give a corresponding hint. Therefore, once the code is 1143 1143 * changed below, the hint should be re-checked for validity. */ 1144 1145 qulonglong caps = 0; 1146 QVector<KMediumFormatCapabilities> capabilities; 1147 capabilities = item->medium().medium().GetMediumFormat().GetCapabilities(); 1148 for (int i = 0; i < capabilities.size(); i++) 1149 caps |= capabilities[i]; 1150 1144 1151 if (item->state() != KMediumState_Inaccessible && 1145 item->medium().medium().GetMediumFormat().GetCapabilities()& MediumFormatCapabilities_File)1152 caps & MediumFormatCapabilities_File) 1146 1153 { 1147 1154 int rc = msgCenter(). -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/clonevd/UIWizardCloneVDPageBasic2.cpp
r41587 r44503 39 39 { 40 40 /* Check that medium format supports creation: */ 41 ULONG uFormatCapabilities = medFormat.GetCapabilities(); 41 //ULONG uFormatCapabilities = medFormat.GetCapabilities(); 42 ULONG uFormatCapabilities = 0; 43 QVector<KMediumFormatCapabilities> capabilities; 44 capabilities = medFormat.GetCapabilities(); 45 for (ULONG i = 0; i < capabilities.size(); i++) 46 uFormatCapabilities |= capabilities[i]; 47 42 48 if (!(uFormatCapabilities & MediumFormatCapabilities_CreateFixed || 43 49 uFormatCapabilities & MediumFormatCapabilities_CreateDynamic)) … … 149 155 /* Show variant page only if there is something to show: */ 150 156 CMediumFormat medFormat = mediumFormat(); 151 ULONG uCapabilities = medFormat.GetCapabilities(); 157 // ULONG uCapabilities = medFormat.GetCapabilities(); 158 ULONG uCapabilities = 0; 159 QVector<KMediumFormatCapabilities> capabilities; 160 capabilities = medFormat.GetCapabilities(); 161 for (ULONG i = 0; i < capabilities.size(); i++) 162 uCapabilities |= capabilities[i]; 163 152 164 int cTest = 0; 153 165 if (uCapabilities & KMediumFormatCapabilities_CreateDynamic) -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/clonevd/UIWizardCloneVDPageBasic3.cpp
r41587 r44503 145 145 /* Setup visibility: */ 146 146 CMediumFormat mediumFormat = field("mediumFormat").value<CMediumFormat>(); 147 ULONG uCapabilities = mediumFormat.GetCapabilities(); 147 ULONG uCapabilities = 0; 148 QVector<KMediumFormatCapabilities> capabilities; 149 capabilities = mediumFormat.GetCapabilities(); 150 for (ULONG i = 0; i < capabilities.size(); i++) 151 uCapabilities |= capabilities[i]; 152 148 153 bool fIsCreateDynamicPossible = uCapabilities & KMediumFormatCapabilities_CreateDynamic; 149 154 bool fIsCreateFixedPossible = uCapabilities & KMediumFormatCapabilities_CreateFixed; -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/clonevd/UIWizardCloneVDPageExpert.cpp
r41615 r44503 187 187 188 188 /* Enable/disable widgets: */ 189 ULONG uCapabilities = mf.GetCapabilities(); 189 ULONG uCapabilities = 0; 190 QVector<KMediumFormatCapabilities> capabilities; 191 capabilities = mf.GetCapabilities(); 192 for (ULONG i = 0; i < capabilities.size(); i++) 193 uCapabilities |= capabilities[i]; 194 190 195 bool fIsCreateDynamicPossible = uCapabilities & KMediumFormatCapabilities_CreateDynamic; 191 196 bool fIsCreateFixedPossible = uCapabilities & KMediumFormatCapabilities_CreateFixed; -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvd/UIWizardNewVDPageBasic1.cpp
r41587 r44503 39 39 { 40 40 /* Check that medium format supports creation: */ 41 ULONG uFormatCapabilities = medFormat.GetCapabilities(); 41 ULONG uFormatCapabilities = 0; 42 QVector<KMediumFormatCapabilities> capabilities; 43 capabilities = medFormat.GetCapabilities(); 44 for (ULONG i = 0; i < capabilities.size(); i++) 45 uFormatCapabilities |= capabilities[i]; 46 42 47 if (!(uFormatCapabilities & MediumFormatCapabilities_CreateFixed || 43 48 uFormatCapabilities & MediumFormatCapabilities_CreateDynamic)) … … 149 154 /* Show variant page only if there is something to show: */ 150 155 CMediumFormat mf = mediumFormat(); 151 ULONG uCapabilities = mf.GetCapabilities(); 156 ULONG uCapabilities = 0; 157 QVector<KMediumFormatCapabilities> capabilities; 158 capabilities = mf.GetCapabilities(); 159 for (ULONG i = 0; i < capabilities.size(); i++) 160 uCapabilities |= capabilities[i]; 161 152 162 int cTest = 0; 153 163 if (uCapabilities & KMediumFormatCapabilities_CreateDynamic) -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvd/UIWizardNewVDPageBasic2.cpp
r41587 r44503 145 145 /* Setup visibility: */ 146 146 CMediumFormat mediumFormat = field("mediumFormat").value<CMediumFormat>(); 147 ULONG uCapabilities = mediumFormat.GetCapabilities(); 147 ULONG uCapabilities = 0; 148 QVector<KMediumFormatCapabilities> capabilities; 149 capabilities = mediumFormat.GetCapabilities(); 150 for (ULONG i = 0; i < capabilities.size(); i++) 151 uCapabilities |= capabilities[i]; 152 148 153 bool fIsCreateDynamicPossible = uCapabilities & KMediumFormatCapabilities_CreateDynamic; 149 154 bool fIsCreateFixedPossible = uCapabilities & KMediumFormatCapabilities_CreateFixed; -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/newvd/UIWizardNewVDPageExpert.cpp
r41833 r44503 189 189 190 190 /* Enable/disable widgets: */ 191 ULONG uCapabilities = mf.GetCapabilities(); 191 ULONG uCapabilities = 0; 192 QVector<KMediumFormatCapabilities> capabilities; 193 capabilities = mf.GetCapabilities(); 194 for (ULONG i = 0; i < capabilities.size(); i++) 195 uCapabilities |= capabilities[i]; 196 192 197 bool fIsCreateDynamicPossible = uCapabilities & KMediumFormatCapabilities_CreateDynamic; 193 198 bool fIsCreateFixedPossible = uCapabilities & KMediumFormatCapabilities_CreateFixed;
Note:
See TracChangeset
for help on using the changeset viewer.