aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorgotmor <gotmor@f2baff5b-bf2c-0410-a398-912abdc3d8b2>2007-06-13 15:41:38 +0000
committergotmor <gotmor@f2baff5b-bf2c-0410-a398-912abdc3d8b2>2007-06-13 15:41:38 +0000
commit6dc9d363f149eebe9fd5a0c7c7e9761e09cca9c5 (patch)
treeb15a43d6855d941c1a38a2c8c19b9df36ff7974b
parent7da191e7673d26b2b1573546a81a2594b0a57774 (diff)
downloaddzen-6dc9d363f149eebe9fd5a0c7c7e9761e09cca9c5.tar.gz
dzen-6dc9d363f149eebe9fd5a0c7c7e9761e09cca9c5.zip
warnings
git-svn-id: http://dzen.googlecode.com/svn/trunk@88 f2baff5b-bf2c-0410-a398-912abdc3d8b2
-rw-r--r--README2
-rw-r--r--action.c8
-rw-r--r--action.h3
3 files changed, 7 insertions, 6 deletions
diff --git a/README b/README
index 8225b6e..bfd34a6 100644
--- a/README
+++ b/README
@@ -41,7 +41,7 @@ necessary as root):
Note: By default dzen will not be compiled with Xinerama support.
- Uncomment the respective line in config.mk to change this.
+ Uncomment the respective lines in config.mk to change this.
Contact:
diff --git a/action.c b/action.c
index 9fb400e..a8f3f70 100644
--- a/action.c
+++ b/action.c
@@ -91,7 +91,7 @@ add_handler(long evid, int hpos, void * hcb) {
while(item) {
if(item->id == evid) {
item->action[hpos] = emalloc(sizeof(As));
- item->action[hpos]->handler = hcb;
+ item->action[hpos]->handler = (handlerf) hcb;
break;
}
item = item->next;
@@ -164,15 +164,15 @@ get_ev_id(char *evname) {
return -1;
}
-void *
+handlerf
get_action_handler(char *acname) {
int i;
for(i=0; ac_lookup_table[i].name; i++) {
if(strcmp(ac_lookup_table[i].name, acname) == 0)
- return ac_lookup_table[i].handler;
+ return (handlerf) ac_lookup_table[i].handler;
}
- return (void *)NULL;
+ return (handlerf)NULL;
}
diff --git a/action.h b/action.h
index 9ec1752..c446340 100644
--- a/action.h
+++ b/action.h
@@ -10,6 +10,7 @@
/* Event, Action data structures */
typedef struct AS As;
typedef struct _ev_list ev_list;
+typedef int (* handlerf)(char **);
enum ev_id {
/* startup, exit */
@@ -51,7 +52,7 @@ struct AS {
/* utility functions */
void do_action(long);
int get_ev_id(char *);
-void * get_action_handler(char *);
+handlerf get_action_handler(char *);
void fill_ev_table(char *);
void free_event_list(void);
int find_event(long);