Go-SDL
Go-SDL copied to clipboard
Event parameters
The current event handling functions pass around a copy of a 24-bytes struct for each call, which should be avoided.
You mean where PollEvent() and WaitEvent() allocate new instances of C.SDL_Event? If so, then I've made some modifications to get around it. Note that the return value of previous calls to either function now becomes invalid at the next call to either one; I've also modified the comments for both functions to say so. I'll submit a pull request for it once the fix for issue 54 gets pulled.