diff options
author | Henrik Rydberg <rydberg@euromail.se> | 2010-12-20 16:49:53 +0100 |
---|---|---|
committer | Henrik Rydberg <rydberg@euromail.se> | 2010-12-22 12:31:28 +0100 |
commit | 0e2ab3b5940e70493aaabdfe5e8da1c75db4db72 (patch) | |
tree | a253d231d73f06efd8c47cbb7dec51a0291de37b | |
parent | db1fdc76ceb5d1bbe32c193e13eb4357da5d0b81 (diff) | |
download | mtdev-git-0e2ab3b5940e70493aaabdfe5e8da1c75db4db72.tar.gz |
Allow use in c++ applications
Reported-by: Armando Visconti <armando.visconti@st.com>
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
-rw-r--r-- | include/mtdev-mapping.h | 8 | ||||
-rw-r--r-- | include/mtdev-plumbing.h | 8 | ||||
-rw-r--r-- | include/mtdev.h | 8 |
3 files changed, 24 insertions, 0 deletions
diff --git a/include/mtdev-mapping.h b/include/mtdev-mapping.h index cb4c326..0e47970 100644 --- a/include/mtdev-mapping.h +++ b/include/mtdev-mapping.h @@ -31,6 +31,10 @@ #ifndef _MTDEV_MAPPING_H #define _MTDEV_MAPPING_H +#ifdef __cplusplus +extern "C" { +#endif + #include <mtdev.h> #define MTDEV_TOUCH_MAJOR 0 @@ -76,4 +80,8 @@ static inline unsigned int mtdev_mt2abs(unsigned int mtcode) return mtdev_map_mt2abs[mtcode]; } +#ifdef __cplusplus +} +#endif + #endif diff --git a/include/mtdev-plumbing.h b/include/mtdev-plumbing.h index 137fbc2..cadc1f7 100644 --- a/include/mtdev-plumbing.h +++ b/include/mtdev-plumbing.h @@ -29,6 +29,10 @@ #ifndef _MTDEV_PLUMBING_H #define _MTDEV_PLUMBING_H +#ifdef __cplusplus +extern "C" { +#endif + #include <mtdev.h> /** @@ -102,4 +106,8 @@ int mtdev_empty(struct mtdev *dev); */ void mtdev_get_event(struct mtdev *dev, struct input_event* ev); +#ifdef __cplusplus +} +#endif + #endif diff --git a/include/mtdev.h b/include/mtdev.h index 84625a5..15bc53b 100644 --- a/include/mtdev.h +++ b/include/mtdev.h @@ -29,6 +29,10 @@ #ifndef _MTDEV_H #define _MTDEV_H +#ifdef __cplusplus +extern "C" { +#endif + #include <linux/input.h> /* includes available in 2.6.30-rc5 */ @@ -169,4 +173,8 @@ int mtdev_get(struct mtdev *dev, int fd, struct input_event* ev, int ev_max); */ void mtdev_close(struct mtdev *dev); +#ifdef __cplusplus +} +#endif + #endif |