summaryrefslogtreecommitdiff
path: root/openbox/event.c
diff options
context:
space:
mode:
authorMikael Magnusson <mikachu@gmail.com>2008-10-27 00:58:56 +0100
committerMikael Magnusson <mikachu@gmail.com>2008-10-27 00:58:56 +0100
commite6fea245756b59f83dc0f51d13feee9cf093a1a1 (patch)
treecefbc79a17772ac53d3df991d4c6a1c6a6319aaf /openbox/event.c
parent7b57ef12963a298c731d0ef4a67de9c985ac9ba4 (diff)
parentc564b6245fcfaf0efd523cfa17bc1a73fe640d68 (diff)
Merge branch 'backport' into work
Conflicts: openbox/client.c openbox/prop.c openbox/prop.h
Diffstat (limited to 'openbox/event.c')
-rw-r--r--openbox/event.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/openbox/event.c b/openbox/event.c
index aca69cc3..44b6eb70 100644
--- a/openbox/event.c
+++ b/openbox/event.c
@@ -2021,7 +2021,7 @@ void event_cancel_all_key_grabs(void)
XSync(obt_display, FALSE);
}
-gboolean event_time_after(Time t1, Time t2)
+gboolean event_time_after(guint32 t1, guint32 t2)
{
g_assert(t1 != CurrentTime);
g_assert(t2 != CurrentTime);
@@ -2034,8 +2034,10 @@ gboolean event_time_after(Time t1, Time t2)
- http://tronche.com/gui/x/xlib/input/pointer-grabbing.html
*/
- /* TIME_HALF is half of the number space of a Time type variable */
-#define TIME_HALF (Time)(1 << (sizeof(Time)*8-1))
+ /* TIME_HALF is not half of the number space of a Time type variable.
+ * Rather, it is half the number space of a timestamp value, which is
+ * always 32 bits. */
+#define TIME_HALF (guint32)(1 << 31)
if (t2 >= TIME_HALF)
/* t2 is in the second half so t1 might wrap around and be smaller than