rename NameFuncLink to name_func_list_t

This commit is contained in:
Julien Danjou 2008-01-12 14:34:53 +01:00
parent b8ff99f652
commit e6c0449009
6 changed files with 10 additions and 11 deletions

View File

@ -61,10 +61,9 @@ typedef struct
unsigned int button;
} MouseButton;
extern const NameFuncLink UicbList[];
extern const NameFuncLink WidgetList[];
extern const NameFuncLink LayoutsList[];
extern const name_func_link_t UicbList[];
extern const name_func_link_t WidgetList[];
extern const name_func_link_t LayoutsList[];
static unsigned int
get_numlockmask(Display *disp)

View File

@ -38,7 +38,7 @@
extern AwesomeConf globalconf;
const NameFuncLink LayoutsList[] =
const name_func_link_t LayoutsList[] =
{
{"tile", layout_tile},
{"tileleft", layout_tileleft},

2
uicb.c
View File

@ -33,7 +33,7 @@
extern AwesomeConf globalconf;
const NameFuncLink UicbList[] =
const name_func_link_t UicbList[] =
{
/* xutil.c */
{"spawn", uicb_spawn},

4
util.c
View File

@ -68,13 +68,13 @@ compute_new_value_from_arg(const char *arg, double current_value)
/** Lookup for a function pointer from its name
* in the given NameFuncLink list
* in the given name_func_link_t list
* \param funcname Function name
* \param list Function and name link list
* \return function pointer
*/
void *
name_func_lookup(const char *funcname, const NameFuncLink * list)
name_func_lookup(const char *funcname, const name_func_link_t *list)
{
int i;

4
util.h
View File

@ -31,7 +31,7 @@ typedef struct
{
const char *name;
void *func;
} NameFuncLink;
} name_func_link_t;
/** \brief replace \c NULL strings with emtpy strings */
#define NONULL(x) (x ? x : "")
@ -220,7 +220,7 @@ void die(const char *, ...) __attribute__ ((noreturn)) __attribute__ ((format(pr
void eprint(const char *, ...) __attribute__ ((noreturn)) __attribute__ ((format(printf, 1, 2)));
double compute_new_value_from_arg(const char *, double);
void warn(const char *, ...) __attribute__ ((format(printf, 1, 2)));
void *name_func_lookup(const char *, const NameFuncLink *);
void *name_func_lookup(const char *, const name_func_link_t *);
#endif
// vim: filetype=c:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=80

View File

@ -27,7 +27,7 @@
extern AwesomeConf globalconf;
const NameFuncLink WidgetList[] =
const name_func_link_t WidgetList[] =
{
{"taglist", taglist_new},
{"layoutinfo", layoutinfo_new},