made hideKeyboard more robust

Robustified hideKeyboard code.  Works with existing tests but will be adding new functional tests for swipe fallback.
kk, sounds good. I'll remove tap.  Do you mean the "tapOut" strategy or the "tap()" function or both?