move poll to the SDL wrapper module