Removed SDL_INIT_TIMER
This is no longer necessary before calling SDL_AddTimer()
This commit is contained in:
1 parent
9275c533ca
commit
f3e419596b
10 files changed
+6
-52
No files matched your search
@@ -178,8 +178,6 @@ static Uint64 SDLTest_GenerateExecKey(const char *runSeed, const char *suiteName
|
||||
/**
|
||||
* Set timeout handler for test.
|
||||
*
|
||||
* Note: SDL_Init(SDL_INIT_TIMER) will be called if it wasn't done so before.
|
||||
*
|
||||
* \param timeout Timeout interval in seconds.
|
||||
* \param callback Function that will be called after timeout has elapsed.
|
||||
*
|
||||
@@ -200,14 +198,6 @@ static SDL_TimerID SDLTest_SetTestTimeout(int timeout, SDL_TimerCallback callbac
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* Init SDL timer if not initialized before */
|
||||
if (!SDL_WasInit(SDL_INIT_TIMER)) {
|
||||
if (!SDL_InitSubSystem(SDL_INIT_TIMER)) {
|
||||
SDLTest_LogError("Failed to init timer subsystem: %s", SDL_GetError());
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
/* Set timer */
|
||||
timeoutInMilliseconds = timeout * 1000;
|
||||
timerID = SDL_AddTimer(timeoutInMilliseconds, callback, 0x0);
|
||||
|
||||
Reference in new issue
Block a user