[vlc-devel] [PATCH 18/22] win32: CreateTimerQueueTimer and DeleteTimerQueueTimer not available on Winstore

Steve Lhomme robux4 at gmail.com
Fri Jul 31 16:55:02 CEST 2015


---
 src/win32/thread.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/src/win32/thread.c b/src/win32/thread.c
index 39711b4..774d4db 100644
--- a/src/win32/thread.c
+++ b/src/win32/thread.c
@@ -961,8 +961,10 @@ int vlc_timer_create (vlc_timer_t *id, void (*func) (void *), void *data)
 
 void vlc_timer_destroy (vlc_timer_t timer)
 {
+#if !VLC_WINSTORE_APP
     if (timer->handle != INVALID_HANDLE_VALUE)
         DeleteTimerQueueTimer (NULL, timer->handle, INVALID_HANDLE_VALUE);
+#endif
     free (timer);
 }
 
@@ -971,7 +973,9 @@ void vlc_timer_schedule (vlc_timer_t timer, bool absolute,
 {
     if (timer->handle != INVALID_HANDLE_VALUE)
     {
+#if !VLC_WINSTORE_APP
         DeleteTimerQueueTimer (NULL, timer->handle, NULL);
+#endif
         timer->handle = INVALID_HANDLE_VALUE;
     }
     if (value == 0)
@@ -982,8 +986,10 @@ void vlc_timer_schedule (vlc_timer_t timer, bool absolute,
     value = (value + 999) / 1000;
     interval = (interval + 999) / 1000;
 
+#if !VLC_WINSTORE_APP
     if (!CreateTimerQueueTimer (&timer->handle, NULL, vlc_timer_do, timer,
                                 value, interval, WT_EXECUTEDEFAULT))
+#endif
         abort ();
 }
 
-- 
2.4.2




More information about the vlc-devel mailing list