3 #include <livebox-service.h>
4 #include <livebox-errno.h>
8 #define EAPI __attribute__((visibility("default")))
10 enum lb_type { /*!< Must have to be sync with data-provider-master */
19 enum pd_type { /*!< Must have to be sync with data-provider-master */
29 DELETE = 0xDEADdead, /* Delete only for this client */
30 DESTROYED = 0x00DEAD00
33 struct livebox_common {
34 enum livebox_state state;
36 struct dlist *livebox_list;
56 enum livebox_delete_type delete_type;
62 enum livebox_visible_state visible;
79 /* For the filtering event */
96 /* For the filtering event */
105 struct requested_flag {
106 unsigned int created:1;
107 unsigned int deleted:1;
108 unsigned int pinup:1;
109 unsigned int group_changed:1;
110 unsigned int period_changed:1;
111 unsigned int size_changed:1;
112 unsigned int pd_created:1;
113 unsigned int pd_destroyed:1;
114 unsigned int update_mode:1;
115 unsigned int access_event:1;
116 unsigned int key_event:1;
122 unsigned int reserved:21;
127 struct livebox *handle;
134 enum livebox_state state;
139 enum livebox_visible_state visible;
140 struct livebox_common *common;
144 struct callback_table {
145 struct livebox_script_operators lb_ops;
146 struct livebox_script_operators pd_ops;
163 struct group_changed {
168 struct period_changed {
173 struct size_changed {
183 struct pd_destroyed {
193 struct access_event {
205 EAPI int livebox_init(void *disp)
207 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
210 EAPI int livebox_init_with_options(void *disp, int prevent_overwrite, double event_filter, int use_thread)
212 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
215 EAPI int livebox_fini(void)
217 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
220 EAPI int livebox_client_paused(void)
222 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
225 EAPI int livebox_client_resumed(void)
227 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
230 EAPI struct livebox *livebox_add(const char *pkgname, const char *content, const char *cluster, const char *category, double period, int type, ret_cb_t cb, void *data)
235 EAPI int livebox_del(struct livebox *handler, int type, ret_cb_t cb, void *data)
237 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
240 EAPI int livebox_set_event_handler(int (*cb)(struct livebox *handler, enum livebox_event_type event, void *data), void *data)
242 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
245 EAPI void *livebox_unset_event_handler(int (*cb)(struct livebox *handler, enum livebox_event_type event, void *data))
250 EAPI int livebox_set_fault_handler(int (*cb)(enum livebox_fault_type, const char *, const char *, const char *, void *), void *data)
252 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
255 EAPI void *livebox_unset_fault_handler(int (*cb)(enum livebox_fault_type, const char *, const char *, const char *, void *))
260 EAPI int livebox_activate(const char *pkgname, ret_cb_t cb, void *data)
262 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
265 EAPI int livebox_resize(struct livebox *handler, int type, ret_cb_t cb, void *data)
267 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
270 EAPI int livebox_click(struct livebox *handler, double x, double y)
272 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
275 EAPI int livebox_set_group(struct livebox *handler, const char *cluster, const char *category, ret_cb_t cb, void *data)
277 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
280 EAPI int livebox_get_group(struct livebox *handler, const char **cluster, const char **category)
282 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
285 EAPI double livebox_period(struct livebox *handler)
290 EAPI int livebox_set_period(struct livebox *handler, double period, ret_cb_t cb, void *data)
292 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
295 EAPI enum livebox_lb_type livebox_lb_type(struct livebox *handler)
297 return LB_TYPE_INVALID;
300 EAPI int livebox_is_user(struct livebox *handler)
302 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
305 EAPI const char *livebox_content(struct livebox *handler)
310 EAPI const char *livebox_category_title(struct livebox *handler)
315 EAPI const char *livebox_filename(struct livebox *handler)
320 EAPI const char *livebox_pkgname(struct livebox *handler)
325 EAPI double livebox_priority(struct livebox *handler)
330 EAPI void *livebox_acquire_fb(struct livebox *handler)
335 EAPI int livebox_release_fb(void *buffer)
337 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
340 EAPI int livebox_fb_refcnt(void *buffer)
342 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
345 EAPI void *livebox_acquire_pdfb(struct livebox *handler)
350 EAPI int livebox_release_pdfb(void *buffer)
352 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
355 EAPI int livebox_pdfb_refcnt(void *buffer)
357 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
360 EAPI int livebox_size(struct livebox *handler)
362 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
365 EAPI int livebox_get_pdsize(struct livebox *handler, int *w, int *h)
367 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
370 EAPI int livebox_get_supported_sizes(struct livebox *handler, int *cnt, int *size_list)
372 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
375 EAPI int livebox_lbfb_bufsz(struct livebox *handler)
377 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
380 EAPI int livebox_pdfb_bufsz(struct livebox *handler)
382 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
385 EAPI int livebox_mouse_event(struct livebox *handler, enum content_event_type type, double x, double y)
387 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
390 EAPI int livebox_access_event(struct livebox *handler, enum access_event_type type, double x, double y, ret_cb_t cb, void *data)
392 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
395 EAPI int livebox_key_event(struct livebox *handler, enum content_event_type type, unsigned int keycode, ret_cb_t cb, void *data)
397 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
400 EAPI int livebox_set_pinup(struct livebox *handler, int flag, ret_cb_t cb, void *data)
402 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
405 EAPI int livebox_is_pinned_up(struct livebox *handler)
407 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
410 EAPI int livebox_has_pinup(struct livebox *handler)
412 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
415 EAPI int livebox_has_pd(struct livebox *handler)
417 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
420 EAPI int livebox_create_pd(struct livebox *handler, ret_cb_t cb, void *data)
422 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
425 EAPI int livebox_create_pd_with_position(struct livebox *handler, double x, double y, ret_cb_t cb, void *data)
427 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
430 EAPI int livebox_move_pd(struct livebox *handler, double x, double y)
432 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
435 EAPI int livebox_destroy_pd(struct livebox *handler, ret_cb_t cb, void *data)
437 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
440 EAPI int livebox_pd_is_created(struct livebox *handler)
442 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
445 EAPI enum livebox_pd_type livebox_pd_type(struct livebox *handler)
447 return PD_TYPE_INVALID;
450 EAPI int livebox_is_exists(const char *pkgname)
452 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
455 EAPI int livebox_set_text_handler(struct livebox *handler, struct livebox_script_operators *ops)
457 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
460 EAPI int livebox_set_pd_text_handler(struct livebox *handler, struct livebox_script_operators *ops)
462 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
465 EAPI int livebox_emit_text_signal(struct livebox *handler, const char *emission, const char *source, double sx, double sy, double ex, double ey, ret_cb_t cb, void *data)
467 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
470 EAPI int livebox_set_data(struct livebox *handler, void *data)
472 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
475 EAPI void *livebox_get_data(struct livebox *handler)
480 EAPI int livebox_subscribe_group(const char *cluster, const char *category)
482 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
485 EAPI int livebox_unsubscribe_group(const char *cluster, const char *category)
487 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
490 EAPI int livebox_refresh_group(const char *cluster, const char *category, int force)
492 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
495 EAPI int livebox_refresh(struct livebox *handler, int force)
497 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
500 EAPI int livebox_lb_pixmap(const struct livebox *handler)
502 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
505 EAPI int livebox_pd_pixmap(const struct livebox *handler)
507 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
510 EAPI int livebox_acquire_pd_pixmap(struct livebox *handler, ret_cb_t cb, void *data)
512 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
515 EAPI int livebox_release_pd_pixmap(struct livebox *handler, int pixmap)
517 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
520 EAPI int livebox_acquire_lb_pixmap(struct livebox *handler, ret_cb_t cb, void *data)
522 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
525 EAPI int livebox_release_lb_pixmap(struct livebox *handler, int pixmap)
527 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
530 EAPI int livebox_set_visibility(struct livebox *handler, enum livebox_visible_state state)
532 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
535 EAPI enum livebox_visible_state livebox_visibility(struct livebox *handler)
537 return LB_VISIBLE_ERROR;
540 EAPI int livebox_set_update_mode(struct livebox *handler, int active_update, ret_cb_t cb, void *data)
542 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
545 EAPI int livebox_is_active_update(struct livebox *handler)
547 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
550 EAPI int livebox_sync_pd_fb(struct livebox *handler)
552 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
555 EAPI int livebox_sync_lb_fb(struct livebox *handler)
557 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
560 EAPI const char *livebox_alt_icon(struct livebox *handler)
565 EAPI const char *livebox_alt_name(struct livebox *handler)
570 EAPI int livebox_acquire_fb_lock(struct livebox *handler, int is_pd)
572 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
575 EAPI int livebox_release_fb_lock(struct livebox *handler, int is_pd)
577 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
580 EAPI int livebox_set_option(enum livebox_option_type option, int state)
582 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
585 EAPI int livebox_option(enum livebox_option_type option)
587 return LB_STATUS_ERROR_NOT_IMPLEMENTED;
590 EAPI int livebox_set_auto_launch_handler(int (*launch_handler)(struct livebox *handler, const char *appid, void *data), void *data)
592 return LB_STATUS_ERROR_NOT_IMPLEMENTED;