summaryrefslogtreecommitdiffstats
path: root/profile.c
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2011-10-25 02:51:16 -0700
committerGravatar Dirk Hohndel <dirk@hohndel.org>2011-10-25 02:51:16 -0700
commit98efa0794aa12eea203216e6f5e7e0bdd336d488 (patch)
treeb616cfbb25a4051cd63fca8c6964c25a2cc627f2 /profile.c
parent499cc0c87c61d517c7953a945da39f4db249f364 (diff)
downloadsubsurface-98efa0794aa12eea203216e6f5e7e0bdd336d488.tar.gz
Add menu item and dialog to select which events to display
Right now they are displayed in one hbox which doesn't work if you have many events - but the code itself works and correctly toggles the events on and off. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'profile.c')
-rw-r--r--profile.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/profile.c b/profile.c
index 810c47391..56716f5f7 100644
--- a/profile.c
+++ b/profile.c
@@ -174,6 +174,15 @@ static struct ev_select *ev_namelist;
static int evn_allocated;
static int evn_used;
+void evn_foreach(void (*callback)(const char *, int *, void *), void *data)
+{
+ int i;
+
+ for (i = 0; i < evn_used; i++) {
+ callback(ev_namelist[i].ev_name, &ev_namelist[i].plot_ev, data);
+ }
+}
+
void remember_event(const char *eventname)
{
int i=0, len;