comparison mcabber/src/settings.c @ 867:7f056c566569

Commands /alias & /bind list the key bindings and aliases
author Mikael Berthe <mikael@lilotux.net>
date Wed, 24 May 2006 23:30:31 +0200
parents 1dd19363c73e
children a0ddc43b421e
comparison
equal deleted inserted replaced
866:b30df2ab457f 867:7f056c566569
321 break; 321 break;
322 } 322 }
323 return rstatus; 323 return rstatus;
324 } 324 }
325 325
326 // settings_foreach(type, pfunction, param)
327 // Call pfunction(param, key, value) for each setting with requested type.
328 void settings_foreach(guint type, void (*pfunc)(void *param, char *k, char *v),
329 void *param)
330 {
331 GSList **plist;
332 GSList *ptr;
333 T_setting *setting;
334
335 plist = get_list_ptr(type);
336
337 if (!*plist) return;
338
339 for (ptr = *plist ; ptr; ptr = g_slist_next(ptr)) {
340 setting = ptr->data;
341 pfunc(param, setting->name, setting->value);
342 }
343 }
344
326 /* vim: set expandtab cindent cinoptions=>2\:2(0: For Vim users... */ 345 /* vim: set expandtab cindent cinoptions=>2\:2(0: For Vim users... */