From 076adeb0aa24e9bdc677435ddb6e444db58d5436 Mon Sep 17 00:00:00 2001 From: Simon Howard Date: Sun, 30 Aug 2009 12:07:04 +0000 Subject: Add method to clear all existing callbacks. Subversion-branch: /branches/opl-branch Subversion-revision: 1642 --- opl/opl_queue.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'opl/opl_queue.c') diff --git a/opl/opl_queue.c b/opl/opl_queue.c index fe5f1ef8..f9d4c377 100644 --- a/opl/opl_queue.c +++ b/opl/opl_queue.c @@ -65,6 +65,11 @@ int OPL_Queue_IsEmpty(opl_callback_queue_t *queue) return queue->num_entries == 0; } +void OPL_Queue_Clear(opl_callback_queue_t *queue) +{ + queue->num_entries = 0; +} + void OPL_Queue_Push(opl_callback_queue_t *queue, opl_callback_t callback, void *data, unsigned int time) -- cgit v1.2.3