Replaced SDL_Event with custom Event class