- Add candidate interface for addons with custom configuration for LocalDevices.

- Add example implementation for Devices which need issue a Reset Command



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30300 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Oliver Ruiz Dorantes
2009-04-21 20:04:24 +00:00
parent a87124634a
commit c3053cacff
5 changed files with 174 additions and 0 deletions
+32
View File
@@ -0,0 +1,32 @@
#ifndef LOCAL_DEVICE_ADDON_H
#define LOCAL_DEVICE_ADDON_H
#include <bluetooth/LocalDevice.h>
#include <bluetooth/RemoteDevice.h>
class LocalDeviceAddOn {
public:
LocalDeviceAddOn();
virtual const char* GetName()=0;
virtual status_t InitCheck(LocalDevice* lDevice)=0;
virtual const char* GetActionDescription()=0;
virtual status_t TakeAction(LocalDevice* lDevice)=0;
virtual const char* GetActionOnRemoteDescription()=0;
virtual status_t TakeActionOnRemote(LocalDevice* lDevice, RemoteDevice* rDevice)=0;
virtual const char* GetOverridenPropertiesDescription()=0;
virtual BMessage* OverridenProperties(LocalDevice* lDevice, const char* property)=0;
};
#define INSTANTIATE_LOCAL_DEVICE_ADDON(addon) LocalDeviceAddOn* InstantiateLocalDeviceAddOn(){return new addon();}
#define EXPORT_LOCAL_DEVICE_ADDON extern "C" __declspec(dllexport) LocalDeviceAddOn* InstantiateLocalDeviceAddOn();
#endif