mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-09 06:25:19 +00:00
vbox: Add registerDomainEvent
This commit is contained in:
parent
1eda86b049
commit
37cf7594cf
@ -1493,6 +1493,16 @@ _vboxDomainSnapshotRestore(virDomainPtr dom,
|
|||||||
#if VBOX_API_VERSION <= 2002000 || VBOX_API_VERSION >= 4000000
|
#if VBOX_API_VERSION <= 2002000 || VBOX_API_VERSION >= 4000000
|
||||||
/* No Callback support for VirtualBox 2.2.* series */
|
/* No Callback support for VirtualBox 2.2.* series */
|
||||||
/* No Callback support for VirtualBox 4.* series */
|
/* No Callback support for VirtualBox 4.* series */
|
||||||
|
|
||||||
|
static void
|
||||||
|
_registerDomainEvent(virDriverPtr driver)
|
||||||
|
{
|
||||||
|
driver->connectDomainEventRegister = NULL;
|
||||||
|
driver->connectDomainEventDeregister = NULL;
|
||||||
|
driver->connectDomainEventRegisterAny = NULL;
|
||||||
|
driver->connectDomainEventDeregisterAny = NULL;
|
||||||
|
}
|
||||||
|
|
||||||
#else /* !(VBOX_API_VERSION == 2002000 || VBOX_API_VERSION >= 4000000) */
|
#else /* !(VBOX_API_VERSION == 2002000 || VBOX_API_VERSION >= 4000000) */
|
||||||
|
|
||||||
/* Functions needed for Callbacks */
|
/* Functions needed for Callbacks */
|
||||||
@ -2035,6 +2045,15 @@ vboxConnectDomainEventDeregisterAny(virConnectPtr conn,
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
_registerDomainEvent(virDriverPtr driver)
|
||||||
|
{
|
||||||
|
driver->connectDomainEventRegister = vboxConnectDomainEventRegister; /* 0.7.0 */
|
||||||
|
driver->connectDomainEventDeregister = vboxConnectDomainEventDeregister; /* 0.7.0 */
|
||||||
|
driver->connectDomainEventRegisterAny = vboxConnectDomainEventRegisterAny; /* 0.8.0 */
|
||||||
|
driver->connectDomainEventDeregisterAny = vboxConnectDomainEventDeregisterAny; /* 0.8.0 */
|
||||||
|
}
|
||||||
|
|
||||||
#endif /* !(VBOX_API_VERSION == 2002000 || VBOX_API_VERSION >= 4000000) */
|
#endif /* !(VBOX_API_VERSION == 2002000 || VBOX_API_VERSION >= 4000000) */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -6382,6 +6401,7 @@ void NAME(InstallUniformedAPI)(vboxUniformedAPI *pVBoxAPI)
|
|||||||
pVBoxAPI->attachFloppy = _attachFloppy;
|
pVBoxAPI->attachFloppy = _attachFloppy;
|
||||||
pVBoxAPI->detachFloppy = _detachFloppy;
|
pVBoxAPI->detachFloppy = _detachFloppy;
|
||||||
pVBoxAPI->snapshotRestore = _vboxDomainSnapshotRestore;
|
pVBoxAPI->snapshotRestore = _vboxDomainSnapshotRestore;
|
||||||
|
pVBoxAPI->registerDomainEvent = _registerDomainEvent;
|
||||||
pVBoxAPI->UPFN = _UPFN;
|
pVBoxAPI->UPFN = _UPFN;
|
||||||
pVBoxAPI->UIID = _UIID;
|
pVBoxAPI->UIID = _UIID;
|
||||||
pVBoxAPI->UArray = _UArray;
|
pVBoxAPI->UArray = _UArray;
|
||||||
|
@ -493,6 +493,7 @@ typedef struct {
|
|||||||
int (*attachFloppy)(vboxGlobalData *data, IMachine *machine, const char *src);
|
int (*attachFloppy)(vboxGlobalData *data, IMachine *machine, const char *src);
|
||||||
int (*detachFloppy)(IMachine *machine);
|
int (*detachFloppy)(IMachine *machine);
|
||||||
int (*snapshotRestore)(virDomainPtr dom, IMachine *machine, ISnapshot *snapshot);
|
int (*snapshotRestore)(virDomainPtr dom, IMachine *machine, ISnapshot *snapshot);
|
||||||
|
void (*registerDomainEvent)(virDriverPtr driver);
|
||||||
vboxUniformedPFN UPFN;
|
vboxUniformedPFN UPFN;
|
||||||
vboxUniformedIID UIID;
|
vboxUniformedIID UIID;
|
||||||
vboxUniformedArray UArray;
|
vboxUniformedArray UArray;
|
||||||
|
Loading…
Reference in New Issue
Block a user