From 2d77f3df1ffd9a74202ca3f744446f48ef84757e Mon Sep 17 00:00:00 2001 From: Sainan Date: Fri, 10 Nov 2023 20:07:10 +0000 Subject: [PATCH] Fix test (hopefully) (#68) * Fix "bindings changed" * Also run workflow on PR --- .github/workflows/test.yml | 2 +- includes/wooting-analog-common.h | 33 -------------------------------- 2 files changed, 1 insertion(+), 34 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 0c52baa..c60f773 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,6 +1,6 @@ name: Test CI -on: push +on: [push, pull_request] env: CARGO_TERM_COLOR: always diff --git a/includes/wooting-analog-common.h b/includes/wooting-analog-common.h index a0273da..a7da57d 100644 --- a/includes/wooting-analog-common.h +++ b/includes/wooting-analog-common.h @@ -100,13 +100,6 @@ typedef enum WootingAnalogResult { WootingAnalogResult_DLLNotFound = -1990, } WootingAnalogResult; -/** - * The core `DeviceInfo` struct which contains all the interesting information - * for a particular device. This is for use internally and should be ignored if you're - * trying to use it when trying to interact with the SDK using the wrapper - */ -typedef struct WootingAnalog_DeviceInfo WootingAnalog_DeviceInfo; - typedef uint64_t WootingAnalog_DeviceID; /** @@ -141,29 +134,3 @@ typedef struct WootingAnalog_DeviceInfo_FFI { */ enum WootingAnalog_DeviceType device_type; } WootingAnalog_DeviceInfo_FFI; - -#ifdef __cplusplus -extern "C" { -#endif // __cplusplus - -/** - * Create a new device info struct. This is only for use in Plugins that are written in C - * Rust plugins should use the native constructor - * The memory for the struct has been allocated in Rust. So `drop_device_info` must be called - * for the memory to be properly released - */ -struct WootingAnalog_DeviceInfo *new_device_info(uint16_t vendor_id, - uint16_t product_id, - char *manufacturer_name, - char *device_name, - WootingAnalog_DeviceID device_id, - enum WootingAnalog_DeviceType device_type); - -/** - * Drops the given `DeviceInfo` - */ -void drop_device_info(struct WootingAnalog_DeviceInfo *device); - -#ifdef __cplusplus -} // extern "C" -#endif // __cplusplus