python: Add wmfs_uicb python function
This commit is contained in:
11
src/event.c
11
src/event.c
@@ -174,7 +174,7 @@ clientmessageevent(XClientMessageEvent *ev)
|
||||
{
|
||||
uchar *ret_func = NULL;
|
||||
uchar *ret_cmd = NULL;
|
||||
char *cmd;
|
||||
char *cmd = NULL;
|
||||
|
||||
if(XGetWindowProperty(dpy, ROOT, net_atom[wmfs_function], 0, 4096,
|
||||
False, net_atom[utf8_string], &rt, &rf, &ir, &il, &ret_func) == Success)
|
||||
@@ -183,15 +183,16 @@ clientmessageevent(XClientMessageEvent *ev)
|
||||
if(XGetWindowProperty(dpy, ROOT, net_atom[wmfs_cmd], 0, 4096,
|
||||
False, net_atom[utf8_string], &rt, &rf, &ir, &il, &ret_cmd) == Success)
|
||||
printf("%s\n", ret_cmd);
|
||||
|
||||
/*
|
||||
if(strcmp((char*)ret_cmd, "NULL") == 0)
|
||||
cmd = NULL;
|
||||
else
|
||||
strcpy(cmd, (char*)ret_cmd);
|
||||
else
|
||||
if(ret_cmd != NULL)
|
||||
strcpy(cmd, (char*)ret_cmd)*/
|
||||
|
||||
void (*func)(uicb_t) = name_to_func((char*)ret_func, func_list);
|
||||
|
||||
func(cmd);
|
||||
func((uicb_t)ret_cmd);
|
||||
|
||||
if(ret_cmd)
|
||||
XFree(ret_cmd);
|
||||
|
||||
Reference in New Issue
Block a user