diff options
Diffstat (limited to 'xbmc/addons/kodi-addon-dev-kit/include/kodi/kodi_peripheral_dll.h')
| -rw-r--r-- | xbmc/addons/kodi-addon-dev-kit/include/kodi/kodi_peripheral_dll.h | 62 |
1 files changed, 22 insertions, 40 deletions
diff --git a/xbmc/addons/kodi-addon-dev-kit/include/kodi/kodi_peripheral_dll.h b/xbmc/addons/kodi-addon-dev-kit/include/kodi/kodi_peripheral_dll.h index f9d7482..b353316 100644 --- a/xbmc/addons/kodi-addon-dev-kit/include/kodi/kodi_peripheral_dll.h +++ b/xbmc/addons/kodi-addon-dev-kit/include/kodi/kodi_peripheral_dll.h | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | * Copyright (C) 2014-2016 Team Kodi | 2 | * Copyright (C) 2014-2017 Team Kodi |
| 3 | * http://kodi.tv | 3 | * http://kodi.tv |
| 4 | * | 4 | * |
| 5 | * This Program is free software; you can redistribute it and/or modify | 5 | * This Program is free software; you can redistribute it and/or modify |
| @@ -32,24 +32,6 @@ extern "C" | |||
| 32 | /// @name Peripheral operations | 32 | /// @name Peripheral operations |
| 33 | ///{ | 33 | ///{ |
| 34 | /*! | 34 | /*! |
| 35 | * @brief Get the PERIPHERAL_API_VERSION used to compile this peripheral add-on | ||
| 36 | * @return KODI_PERIPHERAL_API_VERSION from kodi_peripheral_types.h | ||
| 37 | * @remarks Valid implementation required | ||
| 38 | * | ||
| 39 | * Used to check if the implementation is compatible with the frontend. | ||
| 40 | */ | ||
| 41 | const char* GetPeripheralAPIVersion(void); | ||
| 42 | |||
| 43 | /*! | ||
| 44 | * @brief Get the KODI_PERIPHERAL_MIN_API_VERSION used to compile this peripheral add-on | ||
| 45 | * @return KODI_PERIPHERAL_MIN_API_VERSION from kodi_peripheral_types.h | ||
| 46 | * @remarks Valid implementation required | ||
| 47 | * | ||
| 48 | * Used to check if the implementation is compatible with the frontend. | ||
| 49 | */ | ||
| 50 | const char* GetMinimumPeripheralAPIVersion(void); | ||
| 51 | |||
| 52 | /*! | ||
| 53 | * @brief Get the list of features that this add-on provides | 35 | * @brief Get the list of features that this add-on provides |
| 54 | * @param pCapabilities The add-on's capabilities. | 36 | * @param pCapabilities The add-on's capabilities. |
| 55 | * @return PERIPHERAL_NO_ERROR if the properties were fetched successfully. | 37 | * @return PERIPHERAL_NO_ERROR if the properties were fetched successfully. |
| @@ -230,30 +212,30 @@ extern "C" | |||
| 230 | * pClient. Note that get_addon() is defined here, so it will be available in | 212 | * pClient. Note that get_addon() is defined here, so it will be available in |
| 231 | * all compiled peripheral add-ons. | 213 | * all compiled peripheral add-ons. |
| 232 | */ | 214 | */ |
| 233 | void __declspec(dllexport) get_addon(struct PeripheralAddon* pClient) | 215 | void __declspec(dllexport) get_addon(void* ptr) |
| 234 | { | 216 | { |
| 235 | pClient->GetPeripheralAPIVersion = GetPeripheralAPIVersion; | 217 | AddonInstance_Peripheral* pClient = static_cast<AddonInstance_Peripheral*>(ptr); |
| 236 | pClient->GetMinimumPeripheralAPIVersion = GetMinimumPeripheralAPIVersion; | 218 | |
| 237 | pClient->GetAddonCapabilities = GetAddonCapabilities; | 219 | pClient->toAddon.GetAddonCapabilities = GetAddonCapabilities; |
| 238 | pClient->PerformDeviceScan = PerformDeviceScan; | 220 | pClient->toAddon.PerformDeviceScan = PerformDeviceScan; |
| 239 | pClient->FreeScanResults = FreeScanResults; | 221 | pClient->toAddon.FreeScanResults = FreeScanResults; |
| 240 | pClient->GetEvents = GetEvents; | 222 | pClient->toAddon.GetEvents = GetEvents; |
| 241 | pClient->FreeEvents = FreeEvents; | 223 | pClient->toAddon.FreeEvents = FreeEvents; |
| 242 | pClient->SendEvent = SendEvent; | 224 | pClient->toAddon.SendEvent = SendEvent; |
| 243 | 225 | ||
| 244 | #ifdef PERIPHERAL_ADDON_JOYSTICKS | 226 | #ifdef PERIPHERAL_ADDON_JOYSTICKS |
| 245 | pClient->GetJoystickInfo = GetJoystickInfo; | 227 | pClient->toAddon.GetJoystickInfo = GetJoystickInfo; |
| 246 | pClient->FreeJoystickInfo = FreeJoystickInfo; | 228 | pClient->toAddon.FreeJoystickInfo = FreeJoystickInfo; |
| 247 | pClient->GetFeatures = GetFeatures; | 229 | pClient->toAddon.GetFeatures = GetFeatures; |
| 248 | pClient->FreeFeatures = FreeFeatures; | 230 | pClient->toAddon.FreeFeatures = FreeFeatures; |
| 249 | pClient->MapFeatures = MapFeatures; | 231 | pClient->toAddon.MapFeatures = MapFeatures; |
| 250 | pClient->GetIgnoredPrimitives = GetIgnoredPrimitives; | 232 | pClient->toAddon.GetIgnoredPrimitives = GetIgnoredPrimitives; |
| 251 | pClient->FreePrimitives = FreePrimitives; | 233 | pClient->toAddon.FreePrimitives = FreePrimitives; |
| 252 | pClient->SetIgnoredPrimitives = SetIgnoredPrimitives; | 234 | pClient->toAddon.SetIgnoredPrimitives = SetIgnoredPrimitives; |
| 253 | pClient->SaveButtonMap = SaveButtonMap; | 235 | pClient->toAddon.SaveButtonMap = SaveButtonMap; |
| 254 | pClient->RevertButtonMap = RevertButtonMap; | 236 | pClient->toAddon.RevertButtonMap = RevertButtonMap; |
| 255 | pClient->ResetButtonMap = ResetButtonMap; | 237 | pClient->toAddon.ResetButtonMap = ResetButtonMap; |
| 256 | pClient->PowerOffJoystick = PowerOffJoystick; | 238 | pClient->toAddon.PowerOffJoystick = PowerOffJoystick; |
| 257 | #endif | 239 | #endif |
| 258 | } | 240 | } |
| 259 | 241 | ||
