summaryrefslogtreecommitdiff
path: root/openbox/timer.c
diff options
context:
space:
mode:
authorDana Jansens <danakj@orodu.net>2003-07-10 17:06:30 +0000
committerDana Jansens <danakj@orodu.net>2003-07-10 17:06:30 +0000
commit85112c4d0831067251de1295fbb6974db94af2ba (patch)
tree488bae2036bad327337b90018c87f3054e7803d9 /openbox/timer.c
parent122d55fbadea0409fbc902a1740e1c8ff3aecd88 (diff)
prefix the Timer->ObTimer and TimeoutHandler->ObTimeoutHandler shitz
Diffstat (limited to 'openbox/timer.c')
-rw-r--r--openbox/timer.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/openbox/timer.c b/openbox/timer.c
index e4591544..b49f4dea 100644
--- a/openbox/timer.c
+++ b/openbox/timer.c
@@ -8,7 +8,7 @@ static GTimeVal now;
static GTimeVal ret_wait;
static GSList *timers; /* nearest timer is at the top */
-#define NEAREST_TIMEOUT (((Timer*)timers->data)->timeout)
+#define NEAREST_TIMEOUT (((ObTimer*)timers->data)->timeout)
static long timecompare(GTimeVal *a, GTimeVal *b)
{
@@ -19,11 +19,11 @@ static long timecompare(GTimeVal *a, GTimeVal *b)
}
-static void insert_timer(Timer *self)
+static void insert_timer(ObTimer *self)
{
GSList *it;
for (it = timers; it != NULL; it = it->next) {
- Timer *t = it->data;
+ ObTimer *t = it->data;
if (timecompare(&self->timeout, &t->timeout) <= 0) {
timers = g_slist_insert_before(timers, it, self);
break;
@@ -49,9 +49,9 @@ void timer_shutdown()
timers = NULL;
}
-Timer *timer_start(long delay, TimeoutHandler cb, void *data)
+ObTimer *timer_start(long delay, ObTimeoutHandler cb, void *data)
{
- Timer *self = g_new(Timer, 1);
+ ObTimer *self = g_new(ObTimer, 1);
self->delay = delay;
self->action = cb;
self->data = data;
@@ -64,7 +64,7 @@ Timer *timer_start(long delay, TimeoutHandler cb, void *data)
return self;
}
-void timer_stop(Timer *self)
+void timer_stop(ObTimer *self)
{
self->del_me = TRUE;
}
@@ -96,7 +96,7 @@ void timer_dispatch(GTimeVal **wait)
g_get_current_time(&now);
while (timers != NULL) {
- Timer *curr = timers->data; /* get the top element */
+ ObTimer *curr = timers->data; /* get the top element */
/* since timer_stop doesn't actually free the timer, we have to do our
real freeing in here.
*/