Fixed #54 Added missing typedef and stdbool.h

This commit is contained in:
Filippo Cucchetto 2017-03-02 22:09:19 +01:00
parent 2402c43f10
commit 87ffb698b8
1 changed files with 35 additions and 0 deletions

View File

@ -16,6 +16,9 @@
#define DOS_CALL
#endif
#ifndef __cplusplus
#include <stdbool.h>
#endif
#ifdef __cplusplus
extern "C"
@ -163,6 +166,10 @@ struct DosQVariantArray {
DosQVariant** data;
};
#ifndef __cplusplus
typedef struct DosQVariantArray DosQVariantArray;
#endif
/// The data needed for registering a custom type in the QML environment
/**
* This is used from dos_qdeclarative_qmlregistertype() and dos_qdeclarative_qmlregistersingletontype() calls.
@ -188,6 +195,10 @@ struct QmlRegisterType {
DeleteDObject deleteDObject;
};
#ifndef __cplusplus
typedef struct QmlRegisterType QmlRegisterType;
#endif
/// Represents a single signal definition
struct SignalDefinition {
/// The signal name
@ -198,6 +209,10 @@ struct SignalDefinition {
int *parametersMetaTypes;
};
#ifndef __cplusplus
typedef struct SignalDefinition SignalDefinition;
#endif
/// Represents a set of signal definitions
struct SignalDefinitions {
/// The total number of signals
@ -206,6 +221,10 @@ struct SignalDefinitions {
SignalDefinition *definitions;
};
#ifndef __cplusplus
typedef struct SignalDefinitions SignalDefinitions;
#endif
/// Represents a single slot definition
struct SlotDefinition {
/// The slot name
@ -218,6 +237,10 @@ struct SlotDefinition {
int *parametersMetaTypes;
};
#ifndef __cplusplus
typedef struct SlotDefinition SlotDefinition;
#endif
/// Represents a set of slot definitions
struct SlotDefinitions {
/// The total number of slots
@ -226,6 +249,10 @@ struct SlotDefinitions {
SlotDefinition *definitions;
};
#ifndef __cplusplus
typedef struct SlotDefinitions SlotDefinitions;
#endif
/// Represents a single property definition
struct PropertyDefinition {
/// The property name
@ -242,6 +269,10 @@ struct PropertyDefinition {
const char *notifySignal;
};
#ifndef __cplusplus
typedef struct PropertyDefinition PropertyDefinition;
#endif
/// Represents a set of property definitions
struct PropertyDefinitions {
/// The total number of properties
@ -250,6 +281,10 @@ struct PropertyDefinitions {
PropertyDefinition *definitions;
};
#ifndef __cplusplus
typedef struct PropertyDefinitions PropertyDefinitions;
#endif
#ifdef __cplusplus
}
#endif