12 # define EAPI __attribute__ ((visibility("default")))
22 * - code to get battery info
23 * - code to get thermal info
24 * ecore evas fb isn't good enough for weird things, like multiple fb's, same happens here.
25 * backlight support using new kernel interface
28 * ecore_fb_li_device_close_all ? or a shutdown of the subsystem?
37 * @defgroup Ecore_FB_Group Ecore_FB - Frame buffer convenience functions.
39 * Functions used to set up and shut down the Ecore_Framebuffer functions.
45 * @typedef Ecore_Fb_Input_Device
46 * Input device handler.
48 typedef struct _Ecore_Fb_Input_Device Ecore_Fb_Input_Device;
51 * @enum _Ecore_Fb_Input_Device_Cap
52 * Device capabilities.
54 enum _Ecore_Fb_Input_Device_Cap
56 ECORE_FB_INPUT_DEVICE_CAP_NONE = 0x00000000,
57 ECORE_FB_INPUT_DEVICE_CAP_RELATIVE = 0x00000001,
58 ECORE_FB_INPUT_DEVICE_CAP_ABSOLUTE = 0x00000002,
59 ECORE_FB_INPUT_DEVICE_CAP_KEYS_OR_BUTTONS = 0x00000004
63 * @typedef Ecore_Fb_Input_Device_Cap
64 * Device capabilities.
66 typedef enum _Ecore_Fb_Input_Device_Cap Ecore_Fb_Input_Device_Cap;
68 EAPI extern int ECORE_FB_EVENT_KEY_DOWN; /**< FB Key Down event */
69 EAPI extern int ECORE_FB_EVENT_KEY_UP; /**< FB Key Up event */
70 EAPI extern int ECORE_FB_EVENT_MOUSE_BUTTON_DOWN; /**< FB Mouse Down event */
71 EAPI extern int ECORE_FB_EVENT_MOUSE_BUTTON_UP; /**< FB Mouse Up event */
72 EAPI extern int ECORE_FB_EVENT_MOUSE_MOVE; /**< FB Mouse Move event */
73 EAPI extern int ECORE_FB_EVENT_MOUSE_WHEEL; /**< FB Mouse Wheel event */
75 typedef struct _Ecore_Fb_Event_Key_Down Ecore_Fb_Event_Key_Down; /**< FB Key Down event */
76 typedef struct _Ecore_Fb_Event_Key_Up Ecore_Fb_Event_Key_Up; /**< FB Key Up event */
77 typedef struct _Ecore_Fb_Event_Mouse_Button_Down Ecore_Fb_Event_Mouse_Button_Down; /**< FB Mouse Down event */
78 typedef struct _Ecore_Fb_Event_Mouse_Button_Up Ecore_Fb_Event_Mouse_Button_Up; /**< FB Mouse Up event */
79 typedef struct _Ecore_Fb_Event_Mouse_Move Ecore_Fb_Event_Mouse_Move; /**< FB Mouse Move event */
80 typedef struct _Ecore_Fb_Event_Mouse_Wheel Ecore_Fb_Event_Mouse_Wheel; /**< FB Mouse Wheel event */
83 * @struct _Ecore_Fb_Event_Key_Down
84 * Framebuffer Key Down event.
86 struct _Ecore_Fb_Event_Key_Down
88 Ecore_Fb_Input_Device *dev; /**< The device associated with the event */
89 char *keyname; /**< The name of the key that was pressed */
90 char *keysymbol; /**< The logical symbol of the key that was pressed */
91 char *key_compose; /**< The UTF-8 string conversion if any */
95 * @struct _Ecore_Fb_Event_Key_Up
96 * Framebuffer Key Up event.
98 struct _Ecore_Fb_Event_Key_Up
100 Ecore_Fb_Input_Device *dev; /**< The device associated with the event */
101 char *keyname; /**< The name of the key that was released */
102 char *keysymbol; /**< The logical symbol of the key that was pressed */
103 char *key_compose; /**< The UTF-8 string conversion if any */
107 * @struct _Ecore_Fb_Event_Mouse_Button_Down
108 * Framebuffer Mouse Down event.
110 struct _Ecore_Fb_Event_Mouse_Button_Down
112 Ecore_Fb_Input_Device *dev; /**< The device associated with the event */
113 int button; /**< Mouse button that was pressed (1 - 32) */
114 int x; /**< Mouse co-ordinates when mouse button was pressed */
115 int y; /**< Mouse co-ordinates when mouse button was pressed */
116 int double_click : 1; /**< Set if click was a double click */
117 int triple_click : 1; /**< Set if click was a triple click */
121 * @struct _Ecore_Fb_Event_Mouse_Button_Up
122 * Framebuffer Mouse Up event.
124 struct _Ecore_Fb_Event_Mouse_Button_Up
126 Ecore_Fb_Input_Device *dev; /**< The device associated with the event */
127 int button; /**< Mouse button that was released (1 - 32) */
128 int x; /**< Mouse co-ordinates when mouse button was raised */
129 int y; /**< Mouse co-ordinates when mouse button was raised */
130 int double_click : 1; /**< Set if click was a double click */
131 int triple_click : 1; /**< Set if click was a triple click */
135 * @struct _Ecore_Fb_Event_Mouse_Move
136 * Framebuffer Mouse Move event.
138 struct _Ecore_Fb_Event_Mouse_Move
140 Ecore_Fb_Input_Device *dev; /**< The device associated with the event */
141 int x; /**< Mouse co-ordinates where the mouse cursor moved to */
142 int y; /**< Mouse co-ordinates where the mouse cursor moved to */
146 * @struct _Ecore_Fb_Event_Mouse_Wheel
147 * Framebuffer Mouse Wheel event.
149 struct _Ecore_Fb_Event_Mouse_Wheel
151 Ecore_Fb_Input_Device *dev;
153 int direction; /* 0 = vertical, 1 = horizontal */
154 int wheel; /* value 1 (left/up), -1 (right/down) */
158 EAPI void ecore_fb_callback_gain_set(void (*func) (void *data), void *data);
159 EAPI void ecore_fb_callback_lose_set(void (*func) (void *data), void *data);
162 EAPI Ecore_Fb_Input_Device *ecore_fb_input_device_open(const char *dev);
163 EAPI void ecore_fb_input_device_close(Ecore_Fb_Input_Device *dev);
164 EAPI void ecore_fb_input_device_listen(Ecore_Fb_Input_Device *dev, Eina_Bool listen);
165 EAPI const char *ecore_fb_input_device_name_get(Ecore_Fb_Input_Device *dev);
166 EAPI Ecore_Fb_Input_Device_Cap ecore_fb_input_device_cap_get(Ecore_Fb_Input_Device *dev);
167 EAPI void ecore_fb_input_device_axis_size_set(Ecore_Fb_Input_Device *dev, int w, int h);
168 EAPI void ecore_fb_input_threshold_click_set(Ecore_Fb_Input_Device *dev, double threshold);
169 EAPI double ecore_fb_input_threshold_click_get(Ecore_Fb_Input_Device *dev);
173 EAPI int ecore_fb_init(const char *name);
174 EAPI int ecore_fb_shutdown(void);
175 EAPI void ecore_fb_size_get(int *w, int *h);
177 EAPI void ecore_fb_touch_screen_calibrate_set(int xscale, int xtrans, int yscale, int ytrans, int xyswap);
178 EAPI void ecore_fb_touch_screen_calibrate_get(int *xscale, int *xtrans, int *yscale, int *ytrans, int *xyswap);