comparison nodejs/njs_mb_supp.h @ 1056:88bd0eee2b00

Rename X_supp_njs.[ch] to njs_mb_supp.[ch].
author Thinker K.F. Li <thinker@codemud.net>
date Wed, 24 Nov 2010 15:58:04 +0800
parents nodejs/X_supp_njs.h@1375aa8629ac
children 3a03b0953e22
comparison
equal deleted inserted replaced
1055:1375aa8629ac 1056:88bd0eee2b00
1 // -*- indent-tabs-mode: t; tab-width: 8; c-basic-offset: 4; -*-
2 // vim: sw=4:ts=8:sts=4
3 #ifndef __NJS_MB_SUPP_H_
4 #define __NJS_MB_SUPP_H_
5
6 #include <ev.h>
7 #include <mb_backend.h>
8
9 typedef struct _njs_runtime {
10 mb_rt_t *mb_rt;
11 } njs_runtime_t;
12
13 extern void njs_mb_reg_timer_man(void);
14 extern void njs_mb_reg_IO_man(void);
15 /* extern void njs_mb_init_handle_connection(njs_runtime_t *rt); */
16 extern void njs_mb_free(njs_runtime_t *rt);
17 extern njs_runtime_t *njs_mb_new(char *display_name, int w, int h);
18 extern void njs_mb_free_keep_win(njs_runtime_t *rt);
19 extern njs_runtime_t *njs_mb_new_with_win(void *display, long win);
20 extern int njs_mb_flush(njs_runtime_t *rt);
21 extern void njs_mb_handle_single_event(njs_runtime_t *rt, void *evt);
22 extern void njs_mb_no_more_event(njs_runtime_t *rt);
23 extern mb_rt_t *_njs_mb_get_runtime(njs_runtime_t *rt);
24
25 #define njs_mb_kbevents(rt) mb_runtime_kbevents((rt)->xrt)
26 #define njs_mb_rdman(rt) mb_runtime_rdman((rt)->xrt)
27 #define njs_mb_timer_man(rt) mb_runtime_timer_man((rt)->xrt)
28 #define njs_mb_ob_factory(rt) mb_runtime_ob_factory((rt)->xrt)
29 #define njs_mb_img_ldr(rt) mb_runtime_img_ldr((rt)->xrt)
30
31 #endif /* __NJS_MB_SUPP_H_ */