Added methods to GamePanel for allowing it to become paused automatically when it is minimized or loses keyboard focus.