diff options
author | root <root> | 2010-03-16 17:11:48 +0000 |
---|---|---|
committer | root <root> | 2010-03-16 17:11:48 +0000 |
commit | a7d1fb9edba852f0dd014fdea85074d61d8a6d69 (patch) | |
tree | 4e671930882d2e228deacc17cc9ce26f408cbe9f /ev.h | |
parent | be7f614c904f7c6367ed5f4a4f9a6a5c263ad98e (diff) |
*** empty log message ***
Diffstat (limited to 'ev.h')
-rw-r--r-- | ev.h | 22 |
1 files changed, 13 insertions, 9 deletions
@@ -47,7 +47,7 @@ extern "C" { /*****************************************************************************/ #ifndef EV_FEATURES -# define EV_FEATURES 0x3f +# define EV_FEATURES 0x7f #endif #define EV_FEATURE_CODE ((EV_FEATURES) & 1) @@ -58,7 +58,7 @@ extern "C" { #define EV_FEATURE_BACKENDS ((EV_FEATURES) & 32) #define EV_FEATURE_OS ((EV_FEATURES) & 64) -/* these priorities are inclusive, higher priorities will be called earlier */ +/* these priorities are inclusive, higher priorities will be invoked earlier */ #ifndef EV_MINPRI # define EV_MINPRI (EV_FEATURE_CONFIG ? -2 : 0) #endif @@ -171,8 +171,15 @@ struct ev_loop; # define EV_INLINE static #endif +#ifndef EV_PROTOTYPES +# define EV_PROTOTYPES 1 +#endif + /*****************************************************************************/ +#define EV_VERSION_MAJOR 4 +#define EV_VERSION_MINOR 0 + /* eventmask, revents, events... */ #define EV_UNDEF -1 /* guaranteed to be invalid */ #define EV_NONE 0x00 /* no events */ @@ -199,12 +206,6 @@ struct ev_loop; #ifndef EV_COMMON # define EV_COMMON void *data; #endif -#ifndef EV_PROTOTYPES -# define EV_PROTOTYPES 1 -#endif - -#define EV_VERSION_MAJOR 3 -#define EV_VERSION_MINOR 9 #ifndef EV_CB_DECLARE # define EV_CB_DECLARE(type) void (*cb)(EV_P_ struct type *w, int revents); @@ -213,6 +214,9 @@ struct ev_loop; # define EV_CB_INVOKE(watcher,revents) (watcher)->cb (EV_A_ (watcher), (revents)) #endif +/* not official, do not use */ +#define EV_CB(type,name) void name (EV_P_ struct ev_ ## type *w, int revents) + /* * struct member types: * private: you may look at them, but not change them, @@ -232,7 +236,7 @@ struct ev_loop; #if EV_MINPRI == EV_MAXPRI # define EV_DECL_PRIORITY -#else +#elif !defined (EV_DECL_PRIORITY) # define EV_DECL_PRIORITY int priority; #endif |