I found this to be a much more reliable way to determine the keyboard is visible and finished animating.