2d098095e08a8ee96bdd2916a37614c90fd756f8
[framework/uifw/ecore.git] / src / lib / ecore_fb / ecore_fb_private.h
1 #ifndef _ECORE_FB_PRIVATE_H
2 #define _ECORE_FB_PRIVATE_H
3
4 #include "ecore_private.h"
5 #include "Ecore.h"
6 #include "Ecore_Data.h"
7
8 #include <stdio.h>
9 #include <unistd.h>
10 #include <termios.h>
11 #include <sys/types.h>
12 #include <sys/stat.h>
13 #include <sys/ioctl.h>
14 #include <linux/version.h>
15 #include <linux/kd.h>
16 #include <linux/vt.h>
17 #include <linux/fb.h>
18 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,15)) && (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,18))
19  #define kernel_ulong_t unsigned long 
20  #define BITS_PER_LONG 32
21  #include <linux/input.h>
22  #undef kernel_ulong_t <-added
23  #undef BITS_PER_LONG <-added
24 #else
25  #include <linux/input.h>
26 #endif
27
28 #include <signal.h>
29 #include <fcntl.h>
30 #include <errno.h>
31
32 /* ecore_fb_li.c */
33 struct _Ecore_Fb_Input_Device
34 {
35         int fd;
36         Ecore_Fd_Handler *handler;
37         int listen;
38         struct {
39                 Ecore_Fb_Input_Device_Cap cap;
40                 char *name;
41                 char *dev;
42         } info;
43         struct
44         {
45                 /* common mouse */
46                 int x,y;
47                 int w,h;
48                 
49                 double last;
50                 double prev;
51                 double threshold;
52                 /* absolute axis */
53                 int min_w, min_h;
54                 double rel_w, rel_h;
55
56         } mouse;
57         struct
58         {
59                 int shift;
60                 int ctrl;
61                 int alt;
62                 int lock;
63         } keyboard;
64 };
65
66 /* ecore_fb_ts.c */
67 EAPI int    ecore_fb_ts_init(void);
68 EAPI void   ecore_fb_ts_shutdown(void);
69
70 /* ecore_fb_vt.c */
71 int  ecore_fb_vt_init(void);
72 void ecore_fb_vt_shutdown(void);
73
74 /* hacks to stop people NEEDING #include <linux/h3600_ts.h> */
75 #ifndef TS_SET_CAL
76 #define TS_SET_CAL 0x4014660b
77 #endif
78 #ifndef TS_GET_CAL
79 #define TS_GET_CAL 0x8014660a
80 #endif
81   
82 #endif