incorporated MBProgressHUD and using blocks for enhanced keyboard event handling