Fix missing hanlder `windowShouldClose` on OSX