]> Dogcows Code - chaz/openbox/commitdiff
more processor bummy
authorMarius Nita <marius@cs.pdx.edu>
Tue, 15 Apr 2003 04:03:52 +0000 (04:03 +0000)
committerMarius Nita <marius@cs.pdx.edu>
Tue, 15 Apr 2003 04:03:52 +0000 (04:03 +0000)
obcl/foo.conf
obcl/main.c
obcl/obcl.h
obcl/process.c

index b1fc57f47d21cea1643662f1449917351d9f2c14..a58905548d3d331f258fd80ee70baa24f979d916 100644 (file)
@@ -2,3 +2,8 @@ foo "marius", 23;
 foo "kyle", 15;
 foo "soren", 7;
 bah "blef","bummy";
+meh {
+    foo "marius", 24;
+    foo "blef", 542;
+    bah "hi";
+}
index a38b4cf67bff0f53fbf09c6633bb31efabb9fbb1..7c84b5e7f95b400401251fbca25c47bc45ad8d08 100644 (file)
@@ -25,6 +25,7 @@ int main()
     CLProc *p = cl_proc_new();
     cl_proc_add_handler_func(p, "foo", process_foo);
     cl_proc_add_handler_func(p, "bah", process_bah);
+    cl_proc_add_handler_proc(p,"meh",p);
 
     cl_process(lst, p);
 
index 37a04161a3c718bae21d6a8df742a935721c9f21..78415c1bd51a27ef0b633dd920592ccaf47e86cb 100644 (file)
@@ -90,6 +90,8 @@ void cl_proc_add_handler(CLProc *proc, gchar *str,
                          CLProcHandler *handler);
 void cl_proc_add_handler_func(CLProc *proc, gchar *str,
                               CLProcFunc func);
+void cl_proc_add_handler_proc(CLProc *proc, gchar *str,
+                              CLProc *hproc);
 void cl_proc_set_default(CLProc *proc, CLProcHandler *pf);
 void cl_proc_register_keywords(CLProc *proc, ...);
 void cl_process(GList *tree, CLProc *proc);
index f79fc631361ca3067c3a91a5ef0910cc8843706d..eb7cafd2ac3b8480addb1bee8e2c55e99a9ffc83 100644 (file)
@@ -61,6 +61,16 @@ void cl_proc_add_handler_func(CLProc *proc, gchar *str,
     cl_proc_add_handler(proc, str, ph);
 }
 
+void cl_proc_add_handler_proc(CLProc *proc, gchar *str,
+                              CLProc *hproc)
+{
+    CLProcHandler *ph;
+
+    g_assert(proc != NULL);
+    ph = cl_proc_handler_new_proc(hproc);
+    cl_proc_add_handler(proc, str, ph);
+}
+
 void cl_proc_set_default(CLProc *proc, CLProcHandler *ph)
 {
     g_assert(proc != NULL);
This page took 0.028046 seconds and 4 git commands to generate.