Changeset 90440 in vbox
- Timestamp:
- Jul 30, 2021 8:00:15 PM (4 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/log.h
r90048 r90440 545 545 /** Main group, IProgress. */ 546 546 LOG_GROUP_MAIN_PROGRESS, 547 /** Main group, IProgressCreatedEvent. */ 548 LOG_GROUP_MAIN_PROGRESSCREATEDEVENT, 547 549 /** Main group, IProgressEvent. */ 548 550 LOG_GROUP_MAIN_PROGRESSEVENT, -
trunk/src/VBox/Main/idl/VirtualBox.xidl
r89777 r90440 2544 2544 <interface 2545 2545 name="IVirtualBox" extends="$unknown" 2546 uuid=" d0a0163f-e254-4e5b-a1f2-011cf991c38d"2546 uuid="0efe109d-9b2e-48cf-9969-3fb7b711062e" 2547 2547 wsmap="managed" 2548 2548 reservedMethods="8" reservedAttributes="12" … … 3562 3562 <param name="result" type="boolean" dir="return"> 3563 3563 <desc>If firmware of this type and version is available.</desc> 3564 </param> 3565 </method> 3566 3567 <method name="findProgressById"> 3568 <desc> 3569 Searches through all progress objects known to VBoxSVC for an 3570 instance with the given GUID. 3571 <note> 3572 The method returns an error if the given GUID does not 3573 correspond to any currently known progress object. 3574 </note> 3575 </desc> 3576 <param name="id" type="uuid" mod="string" dir="in"> 3577 <desc>GUID of the progress object to search for.</desc> 3578 </param> 3579 <param name="progressObject" type="IProgress" dir="return"> 3580 <desc>Found progress object.</desc> 3564 3581 </param> 3565 3582 </method> … … 24466 24483 <enum 24467 24484 name="VBoxEventType" 24468 uuid=" 2ab7c196-f232-11ea-a5d2-83b96bc30bcc"24485 uuid="c88a66ed-fbce-4c21-9196-12354bd96b89" 24469 24486 > 24470 24487 … … 24920 24937 </desc> 24921 24938 </const> 24939 <const name="OnProgressCreated" value="110"> 24940 <desc> 24941 See <link to="IProgressCreatedEvent"/>. 24942 </desc> 24943 </const> 24922 24944 <!-- End event marker --> 24923 24945 <!-- @todo rename to 'End' as it is exclusive (we use 'last' to be inclusive). --> 24924 <const name="Last" value="11 0">24946 <const name="Last" value="111"> 24925 24947 <desc> 24926 24948 Must be last event, used for iterations and structures relying on numerical event values. … … 27006 27028 <attribute name="progressId" readonly="yes" type="uuid" mod="string"> 27007 27029 <desc>GUID of the progress this event relates to.</desc> 27030 </attribute> 27031 27032 </interface> 27033 27034 <interface 27035 name="IProgressCreatedEvent" extends="IProgressEvent" 27036 uuid="a85bba40-1b93-47bb-b125-dec708c30fc0" 27037 wsmap="managed" autogen="VBoxEvent" id="OnProgressCreated"> 27038 <desc>Notification of a new progress object creation/deletion. 27039 Covers purely projess objects in VBoxSVC. This 27040 event is signaled on the event source of IVirtualBox, unlike 27041 the other progress events.</desc> 27042 27043 <attribute name="create" readonly="yes" type="boolean"> 27044 <desc>If @c true, the progress object was created, otherwise it 27045 was deleted.</desc> 27008 27046 </attribute> 27009 27047 -
trunk/src/VBox/Main/include/VirtualBoxImpl.h
r87949 r90440 158 158 int i_unloadVDPlugin(const char *pszPluginLibrary); 159 159 160 void i_onMediumRegistered(const Guid &aMediumId, const DeviceType_T aDevType, constBOOL aRegistered);160 void i_onMediumRegistered(const Guid &aMediumId, const DeviceType_T aDevType, BOOL aRegistered); 161 161 void i_onMediumConfigChanged(IMedium *aMedium); 162 162 void i_onMediumChanged(IMediumAttachment* aMediumAttachment); 163 163 void i_onStorageControllerChanged(const Guid &aMachineId, const com::Utf8Str &aControllerName); 164 void i_onStorageDeviceChanged(IMediumAttachment* aStorageDevice, const BOOL fRemoved, constBOOL fSilent);164 void i_onStorageDeviceChanged(IMediumAttachment* aStorageDevice, BOOL fRemoved, BOOL fSilent); 165 165 void i_onMachineStateChanged(const Guid &aId, MachineState_T aState); 166 166 void i_onMachineDataChanged(const Guid &aId, BOOL aTemporary = FALSE); … … 199 199 void i_onCloudProviderRegistered(const Utf8Str &aProviderId, BOOL aRegistered); 200 200 void i_onCloudProviderUninstall(const Utf8Str &aProviderId); 201 202 void i_onProgressCreated(const Guid &aId, BOOL aCreated); 201 203 202 204 #ifdef VBOX_WITH_CLOUD_NET … … 390 392 com::Utf8Str &aFile, 391 393 BOOL *aResult); 394 HRESULT findProgressById(const com::Guid &aId, 395 ComPtr<IProgress> &aProgressObject); 392 396 393 397 static HRESULT i_setErrorStaticBoth(HRESULT aResultCode, int vrc, const Utf8Str &aText) -
trunk/src/VBox/Main/src-server/VirtualBoxImpl.cpp
r87949 r90440 1271 1271 AutoReadLock safeLock(m->mtxProgressOperations COMMA_LOCKVAL_SRC_POS); 1272 1272 ProgressMap pmap(m->mapProgressOperations); 1273 /* Can release lock now. The following code works on a copy of the map. */ 1274 safeLock.release(); 1273 1275 aProgressOperations.resize(pmap.size()); 1274 1276 size_t i = 0; … … 3515 3517 3516 3518 3519 void VirtualBox::i_onProgressCreated(const Guid &aId, BOOL aCreated) 3520 { 3521 ::FireProgressCreatedEvent(m->pEventSource, aId.toString(), aCreated); 3522 } 3523 3524 3517 3525 /** 3518 3526 * @note Locks the list of other objects for reading. … … 5792 5800 5793 5801 5802 HRESULT VirtualBox::findProgressById(const com::Guid &aId, 5803 ComPtr<IProgress> &aProgressObject) 5804 { 5805 if (!aId.isValid()) 5806 return setError(E_INVALIDARG, 5807 tr("The provided progress object GUID is invalid")); 5808 5809 /* protect mProgressOperations */ 5810 AutoReadLock safeLock(m->mtxProgressOperations COMMA_LOCKVAL_SRC_POS); 5811 5812 ProgressMap::const_iterator it = m->mapProgressOperations.find(aId); 5813 if (it != m->mapProgressOperations.end()) 5814 { 5815 aProgressObject = it->second; 5816 return S_OK; 5817 } 5818 return setError(E_INVALIDARG, 5819 tr("The progress object with the given GUID could not be found")); 5820 } 5821 5822 5794 5823 #ifdef RT_OS_WINDOWS 5795 5824 #include <psapi.h> … … 5998 6027 5999 6028 /** 6000 * Wat hces @a a_pidClient for termination.6029 * Watches @a a_pidClient for termination. 6001 6030 * 6002 6031 * @returns true if successfully enabled watching of it, false if not.
Note:
See TracChangeset
for help on using the changeset viewer.