diff options
author | Jef <jef@targetspot.com> | 2024-09-24 08:54:57 -0400 |
---|---|---|
committer | Jef <jef@targetspot.com> | 2024-09-24 08:54:57 -0400 |
commit | 20d28e80a5c861a9d5f449ea911ab75b4f37ad0d (patch) | |
tree | 12f17f78986871dd2cfb0a56e5e93b545c1ae0d0 /Src/gracenote/GracenoteFactory.cpp | |
parent | 537bcbc86291b32fc04ae4133ce4d7cac8ebe9a7 (diff) | |
download | winamp-20d28e80a5c861a9d5f449ea911ab75b4f37ad0d.tar.gz |
Initial community commit
Diffstat (limited to 'Src/gracenote/GracenoteFactory.cpp')
-rw-r--r-- | Src/gracenote/GracenoteFactory.cpp | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/Src/gracenote/GracenoteFactory.cpp b/Src/gracenote/GracenoteFactory.cpp new file mode 100644 index 00000000..fcdc943e --- /dev/null +++ b/Src/gracenote/GracenoteFactory.cpp @@ -0,0 +1,61 @@ +#include "api.h" +#include "GracenoteFactory.h" +#include "GracenoteApi.h" +GracenoteApi gracenoteApi; +static const char serviceName[] = "Gracenote API"; + +FOURCC GracenoteFactory::GetServiceType() +{ + return WaSvc::UNIQUE; +} + +const char *GracenoteFactory::GetServiceName() +{ + return serviceName; +} + +GUID GracenoteFactory::GetGUID() +{ + return gracenoteApiGUID; +} + +void *GracenoteFactory::GetInterface(int global_lock) +{ + return &gracenoteApi; +// if (global_lock) +// WASABI_API_SVC->service_lock(this, (void *)ifc); +} + +int GracenoteFactory::SupportNonLockingInterface() +{ + return 1; +} + +int GracenoteFactory::ReleaseInterface(void *ifc) +{ + //WASABI_API_SVC->service_unlock(ifc); + return 1; +} + +const char *GracenoteFactory::GetTestString() +{ + return NULL; +} + +int GracenoteFactory::ServiceNotify(int msg, int param1, int param2) +{ + return 1; +} + +#define CBCLASS GracenoteFactory +START_DISPATCH; +CB(WASERVICEFACTORY_GETSERVICETYPE, GetServiceType) +CB(WASERVICEFACTORY_GETSERVICENAME, GetServiceName) +CB(WASERVICEFACTORY_GETGUID, GetGUID) +CB(WASERVICEFACTORY_GETINTERFACE, GetInterface) +CB(WASERVICEFACTORY_SUPPORTNONLOCKINGGETINTERFACE, SupportNonLockingInterface) +CB(WASERVICEFACTORY_RELEASEINTERFACE, ReleaseInterface) +CB(WASERVICEFACTORY_GETTESTSTRING, GetTestString) +CB(WASERVICEFACTORY_SERVICENOTIFY, ServiceNotify) +END_DISPATCH; +#undef CBCLASS |