From 2c72fa23e3aad2dc54a65bf3c9635eafa9c8786e Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sat, 18 Jul 2015 14:27:20 -0400 Subject: Don't dispatch nothing events. --- pugl/pugl_internal.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'pugl') diff --git a/pugl/pugl_internal.h b/pugl/pugl_internal.h index 993f319..f83f2c7 100644 --- a/pugl/pugl_internal.h +++ b/pugl/pugl_internal.h @@ -1,5 +1,5 @@ /* - Copyright 2012-2014 David Robillard + Copyright 2012-2015 David Robillard Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above @@ -250,7 +250,9 @@ puglDecodeUTF8(const uint8_t* buf) static void puglDispatchEvent(PuglView* view, const PuglEvent* event) { - if (view->eventFunc) { + if (event->type == PUGL_NOTHING) { + return; + } else if (view->eventFunc) { view->eventFunc(view, event); } -- cgit v1.2.1