Changeset 18197 in vbox for trunk/src/VBox/Main
- Timestamp:
- Mar 24, 2009 3:44:24 PM (16 years ago)
- svn:sync-xref-src-repo-rev:
- 44915
- Location:
- trunk/src/VBox/Main
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/ApplianceImpl.cpp
r18177 r18197 1323 1323 nameVBox); 1324 1324 1325 /* VM description */ 1325 1326 if (!vsysThis.strDescription.isEmpty()) 1326 1327 pNewDesc->addEntry(VirtualSystemDescriptionType_Description, … … 1328 1329 vsysThis.strDescription, 1329 1330 vsysThis.strDescription); 1331 1332 /* VM license */ 1333 if (!vsysThis.strLicenseText.isEmpty()) 1334 pNewDesc->addEntry(VirtualSystemDescriptionType_License, 1335 "", 1336 vsysThis.strLicenseText, 1337 vsysThis.strLicenseText); 1330 1338 1331 1339 /* Now that we know the OS type, get our internal defaults based on that. */ … … 2374 2382 2375 2383 llHardDisksCreated.push_back(dstHdVBox); 2376 2377 2384 /* Now use the new uuid to attach the disk image to our new machine */ 2378 2385 ComPtr<IMachine> sMachine; … … 3420 3427 * @return 3421 3428 */ 3429 STDMETHODIMP VirtualSystemDescription::GetValuesByType(VirtualSystemDescriptionType_T aType, 3430 VirtualSystemDescriptionValueType_T aWhich, 3431 ComSafeArrayOut(BSTR, aValues)) 3432 { 3433 if (ComSafeArrayOutIsNull(aValues)) 3434 return E_POINTER; 3435 3436 AutoCaller autoCaller(this); 3437 CheckComRCReturnRC(autoCaller.rc()); 3438 3439 AutoReadLock alock(this); 3440 3441 std::list<VirtualSystemDescriptionEntry*> vsd = findByType (aType); 3442 com::SafeArray<BSTR> sfaValues((ULONG)vsd.size()); 3443 3444 list<VirtualSystemDescriptionEntry*>::const_iterator it; 3445 size_t i = 0; 3446 for (it = vsd.begin(); 3447 it != vsd.end(); 3448 ++it, ++i) 3449 { 3450 const VirtualSystemDescriptionEntry *vsde = (*it); 3451 3452 Bstr bstr; 3453 switch (aWhich) 3454 { 3455 case VirtualSystemDescriptionValueType_Reference: bstr = vsde->strRef; break; 3456 case VirtualSystemDescriptionValueType_Original: bstr = vsde->strOvf; break; 3457 case VirtualSystemDescriptionValueType_Auto: bstr = vsde->strVbox; break; 3458 case VirtualSystemDescriptionValueType_ExtraConfig: bstr = vsde->strExtraConfig; break; 3459 } 3460 3461 bstr.cloneTo(&sfaValues[i]); 3462 } 3463 3464 sfaValues.detachTo(ComSafeArrayOutArg(aValues)); 3465 3466 return S_OK; 3467 } 3468 3469 /** 3470 * Public method implementation. 3471 * @return 3472 */ 3422 3473 STDMETHODIMP VirtualSystemDescription::SetFinalValues(ComSafeArrayIn(BOOL, aEnabled), 3423 3474 ComSafeArrayIn(IN_BSTR, argVboxValues), -
trunk/src/VBox/Main/idl/VirtualBox.xidl
r18177 r18197 3224 3224 <enum 3225 3225 name="VirtualSystemDescriptionType" 3226 uuid=" 8ac36d00-bb7c-4a35-a835-3f004b27427b"3226 uuid="325e7fec-ce06-4174-9654-98f99478d03f" 3227 3227 > 3228 3228 <desc>Used with <link to="IVirtualSystemDescription" /> to describe the type of … … 3233 3233 <const name="Name" value="3" /> 3234 3234 <const name="Description" value="4" /> 3235 <const name="CPU" value="5" /> 3236 <const name="Memory" value="6" /> 3237 <const name="HardDiskControllerIDE" value="7" /> 3238 <const name="HardDiskControllerSATA" value="8" /> 3239 <const name="HardDiskControllerSCSI" value="9" /> 3240 <const name="HardDiskImage" value="10" /> 3241 <const name="Floppy" value="11" /> 3242 <const name="CDROM" value="12" /> 3243 <const name="NetworkAdapter" value="13" /> 3244 <const name="USBController" value="14" /> 3245 <const name="SoundCard" value="15" /> 3235 <const name="License" value="5" /> 3236 <const name="CPU" value="6" /> 3237 <const name="Memory" value="7" /> 3238 <const name="HardDiskControllerIDE" value="8" /> 3239 <const name="HardDiskControllerSATA" value="9" /> 3240 <const name="HardDiskControllerSCSI" value="10" /> 3241 <const name="HardDiskImage" value="11" /> 3242 <const name="Floppy" value="12" /> 3243 <const name="CDROM" value="13" /> 3244 <const name="NetworkAdapter" value="14" /> 3245 <const name="USBController" value="15" /> 3246 <const name="SoundCard" value="16" /> 3247 3248 </enum> 3249 3250 <enum 3251 name="VirtualSystemDescriptionValueType" 3252 uuid="56d9403f-3425-4118-9919-36f2a9b8c77c" 3253 > 3254 <desc>Used with <link to="GetValuesByType" /> to describe the value 3255 type to fetch.</desc> 3256 3257 <const name="Reference" value="1" /> 3258 <const name="Original" value="2" /> 3259 <const name="Auto" value="3" /> 3260 <const name="ExtraConfig" value="4" /> 3246 3261 3247 3262 </enum> … … 3401 3416 3402 3417 <param name="aExtraConfigValues" type="wstring" dir="out" safearray="yes"> 3418 <desc></desc> 3419 </param> 3420 3421 </method> 3422 3423 <method name="getValuesByType"> 3424 <desc>This is the same as <link to="getDescriptionByType" /> except that you can specify which 3425 value types should be returned. See <link to="VirtualSystemDescriptionValueType" /> for possible 3426 values.</desc> 3427 3428 <param name="aType" type="VirtualSystemDescriptionType" dir="in"> 3429 <desc></desc> 3430 </param> 3431 3432 <param name="aWhich" type="VirtualSystemDescriptionValueType" dir="in"> 3433 <desc></desc> 3434 </param> 3435 3436 <param name="aValues" type="wstring" dir="out" safearray="yes"> 3403 3437 <desc></desc> 3404 3438 </param>
Note:
See TracChangeset
for help on using the changeset viewer.