2022-03-21 23:15:53 +00:00
|
|
|
// ======================================================================================
|
|
|
|
// cgo compilation (for desktop platforms and local tests)
|
|
|
|
// ======================================================================================
|
|
|
|
|
|
|
|
#include <stdio.h>
|
|
|
|
#include <stddef.h>
|
|
|
|
#include <stdbool.h>
|
|
|
|
#include "_cgo_export.h"
|
|
|
|
|
2023-10-28 23:37:53 +00:00
|
|
|
typedef void (*callback)(int retCode, const char *jsonEvent, void* userData);
|
2022-03-21 23:15:53 +00:00
|
|
|
|
2023-12-15 14:46:21 +00:00
|
|
|
bool ServiceSignalEvent(void *cb, const char *jsonEvent) {
|
|
|
|
if (cb) {
|
|
|
|
((callback)cb)(0, jsonEvent, NULL);
|
2022-03-21 23:15:53 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
return true;
|
|
|
|
}
|