{"action":"opened","number":233,"pull_request":{"url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/pulls/233","id":91138820,"html_url":"https://github.com/michaeltyson/TPKeyboardAvoiding/pull/233","diff_url":"https://github.com/michaeltyson/TPKeyboardAvoiding/pull/233.diff","patch_url":"https://github.com/michaeltyson/TPKeyboardAvoiding/pull/233.patch","issue_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/issues/233","number":233,"state":"open","locked":false,"title":"fix the issue that origin contentInset of table view will be overrided","user":{"login":"canicelebrate","id":2613013,"avatar_url":"https://avatars.githubusercontent.com/u/2613013?v=3","gravatar_id":"","url":"https://api.github.com/users/canicelebrate","html_url":"https://github.com/canicelebrate","followers_url":"https://api.github.com/users/canicelebrate/followers","following_url":"https://api.github.com/users/canicelebrate/following{/other_user}","gists_url":"https://api.github.com/users/canicelebrate/gists{/gist_id}","starred_url":"https://api.github.com/users/canicelebrate/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/canicelebrate/subscriptions","organizations_url":"https://api.github.com/users/canicelebrate/orgs","repos_url":"https://api.github.com/users/canicelebrate/repos","events_url":"https://api.github.com/users/canicelebrate/events{/privacy}","received_events_url":"https://api.github.com/users/canicelebrate/received_events","type":"User","site_admin":false},"body":"**Test Environment**\r\n\r\niOS 10.0.2\r\n\r\nXcode 8.0\r\n\r\n**Problem:**\r\n\r\nAfter call resignFirstResponder on a TextField programmatically among a table view cell when the TextField is focused, iOS will trigger TPKeyboardAvoiding_keyboardWillShow again before TPKeyboardAvoiding_keyboardWillHide. But there is GCD delay in the method TPKeyboardAvoiding_keyboardWillShow, which results in that we set the contentInset of the table view after we restored its origin contentInset in the method TPKeyboardAvoiding_keyboardWillHide.\r\n\r\n**Analysis:**\r\n\r\nTo identify this case, we can simply check whether there is firstResponder underneath the table view before we set the contentInset of the table view. \r\n\r\n**Solution:**\r\n\r\nMove line below after we checked the firstResponder underneath the tableview/collectionview/scrollview\r\n\r\n`self.contentInset = [self TPKeyboardAvoiding_contentInsetForKeyboard];`","created_at":"2016-10-27T06:13:30Z","updated_at":"2016-10-27T06:13:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"fcf0390b0da0076b7fa08b14999b7f48f2966bfa","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/pulls/233/commits","review_comments_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/pulls/233/comments","review_comment_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/pulls/comments{/number}","comments_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/issues/233/comments","statuses_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/statuses/8471dd43dc481ff37e9df690f8be8b43a57e6333","head":{"label":"canicelebrate:master","ref":"master","sha":"8471dd43dc481ff37e9df690f8be8b43a57e6333","user":{"login":"canicelebrate","id":2613013,"avatar_url":"https://avatars.githubusercontent.com/u/2613013?v=3","gravatar_id":"","url":"https://api.github.com/users/canicelebrate","html_url":"https://github.com/canicelebrate","followers_url":"https://api.github.com/users/canicelebrate/followers","following_url":"https://api.github.com/users/canicelebrate/following{/other_user}","gists_url":"https://api.github.com/users/canicelebrate/gists{/gist_id}","starred_url":"https://api.github.com/users/canicelebrate/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/canicelebrate/subscriptions","organizations_url":"https://api.github.com/users/canicelebrate/orgs","repos_url":"https://api.github.com/users/canicelebrate/repos","events_url":"https://api.github.com/users/canicelebrate/events{/privacy}","received_events_url":"https://api.github.com/users/canicelebrate/received_events","type":"User","site_admin":false},"repo":{"id":72068228,"name":"TPKeyboardAvoiding","full_name":"canicelebrate/TPKeyboardAvoiding","owner":{"login":"canicelebrate","id":2613013,"avatar_url":"https://avatars.githubusercontent.com/u/2613013?v=3","gravatar_id":"","url":"https://api.github.com/users/canicelebrate","html_url":"https://github.com/canicelebrate","followers_url":"https://api.github.com/users/canicelebrate/followers","following_url":"https://api.github.com/users/canicelebrate/following{/other_user}","gists_url":"https://api.github.com/users/canicelebrate/gists{/gist_id}","starred_url":"https://api.github.com/users/canicelebrate/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/canicelebrate/subscriptions","organizations_url":"https://api.github.com/users/canicelebrate/orgs","repos_url":"https://api.github.com/users/canicelebrate/repos","events_url":"https://api.github.com/users/canicelebrate/events{/privacy}","received_events_url":"https://api.github.com/users/canicelebrate/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/canicelebrate/TPKeyboardAvoiding","description":"A drop-in universal solution for moving text fields out of the way of the keyboard in iOS","fork":true,"url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding","forks_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/forks","keys_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/keys{/key_id}","collaborators_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/teams","hooks_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/hooks","issue_events_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/issues/events{/number}","events_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/events","assignees_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/assignees{/user}","branches_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/branches{/branch}","tags_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/tags","blobs_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/git/refs{/sha}","trees_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/git/trees{/sha}","statuses_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/statuses/{sha}","languages_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/languages","stargazers_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/stargazers","contributors_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/contributors","subscribers_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/subscribers","subscription_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/subscription","commits_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/commits{/sha}","git_commits_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/git/commits{/sha}","comments_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/comments{/number}","issue_comment_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/issues/comments{/number}","contents_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/contents/{+path}","compare_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/compare/{base}...{head}","merges_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/merges","archive_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/downloads","issues_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/issues{/number}","pulls_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/pulls{/number}","milestones_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/milestones{/number}","notifications_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/labels{/name}","releases_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/releases{/id}","deployments_url":"https://api.github.com/repos/canicelebrate/TPKeyboardAvoiding/deployments","created_at":"2016-10-27T03:38:30Z","updated_at":"2016-10-27T03:38:31Z","pushed_at":"2016-10-27T03:49:46Z","git_url":"git://github.com/canicelebrate/TPKeyboardAvoiding.git","ssh_url":"git@github.com:canicelebrate/TPKeyboardAvoiding.git","clone_url":"https://github.com/canicelebrate/TPKeyboardAvoiding.git","svn_url":"https://github.com/canicelebrate/TPKeyboardAvoiding","homepage":"http://atastypixel.com/blog/a-drop-in-universal-solution-for-moving-text-fields-out-of-the-way-of-the-keyboard/","size":202,"stargazers_count":0,"watchers_count":0,"language":"Objective-C","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"michaeltyson:master","ref":"master","sha":"408b5a307a8dd0cc40bb27a7f4607e83c1b92d80","user":{"login":"michaeltyson","id":184008,"avatar_url":"https://avatars.githubusercontent.com/u/184008?v=3","gravatar_id":"","url":"https://api.github.com/users/michaeltyson","html_url":"https://github.com/michaeltyson","followers_url":"https://api.github.com/users/michaeltyson/followers","following_url":"https://api.github.com/users/michaeltyson/following{/other_user}","gists_url":"https://api.github.com/users/michaeltyson/gists{/gist_id}","starred_url":"https://api.github.com/users/michaeltyson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/michaeltyson/subscriptions","organizations_url":"https://api.github.com/users/michaeltyson/orgs","repos_url":"https://api.github.com/users/michaeltyson/repos","events_url":"https://api.github.com/users/michaeltyson/events{/privacy}","received_events_url":"https://api.github.com/users/michaeltyson/received_events","type":"User","site_admin":false},"repo":{"id":1614475,"name":"TPKeyboardAvoiding","full_name":"michaeltyson/TPKeyboardAvoiding","owner":{"login":"michaeltyson","id":184008,"avatar_url":"https://avatars.githubusercontent.com/u/184008?v=3","gravatar_id":"","url":"https://api.github.com/users/michaeltyson","html_url":"https://github.com/michaeltyson","followers_url":"https://api.github.com/users/michaeltyson/followers","following_url":"https://api.github.com/users/michaeltyson/following{/other_user}","gists_url":"https://api.github.com/users/michaeltyson/gists{/gist_id}","starred_url":"https://api.github.com/users/michaeltyson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/michaeltyson/subscriptions","organizations_url":"https://api.github.com/users/michaeltyson/orgs","repos_url":"https://api.github.com/users/michaeltyson/repos","events_url":"https://api.github.com/users/michaeltyson/events{/privacy}","received_events_url":"https://api.github.com/users/michaeltyson/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/michaeltyson/TPKeyboardAvoiding","description":"A drop-in universal solution for moving text fields out of the way of the keyboard in iOS","fork":false,"url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding","forks_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/forks","keys_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/keys{/key_id}","collaborators_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/teams","hooks_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/hooks","issue_events_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/issues/events{/number}","events_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/events","assignees_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/assignees{/user}","branches_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/branches{/branch}","tags_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/tags","blobs_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/git/refs{/sha}","trees_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/git/trees{/sha}","statuses_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/statuses/{sha}","languages_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/languages","stargazers_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/stargazers","contributors_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/contributors","subscribers_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/subscribers","subscription_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/subscription","commits_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/commits{/sha}","git_commits_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/git/commits{/sha}","comments_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/comments{/number}","issue_comment_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/issues/comments{/number}","contents_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/contents/{+path}","compare_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/compare/{base}...{head}","merges_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/merges","archive_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/downloads","issues_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/issues{/number}","pulls_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/pulls{/number}","milestones_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/milestones{/number}","notifications_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/labels{/name}","releases_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/releases{/id}","deployments_url":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/deployments","created_at":"2011-04-14T14:28:29Z","updated_at":"2016-10-26T23:39:58Z","pushed_at":"2016-10-27T06:13:31Z","git_url":"git://github.com/michaeltyson/TPKeyboardAvoiding.git","ssh_url":"git@github.com:michaeltyson/TPKeyboardAvoiding.git","clone_url":"https://github.com/michaeltyson/TPKeyboardAvoiding.git","svn_url":"https://github.com/michaeltyson/TPKeyboardAvoiding","homepage":"http://atastypixel.com/blog/a-drop-in-universal-solution-for-moving-text-fields-out-of-the-way-of-the-keyboard/","size":347,"stargazers_count":4857,"watchers_count":4857,"language":"Objective-C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":867,"mirror_url":null,"open_issues_count":77,"forks":867,"open_issues":77,"watchers":4857,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/pulls/233"},"html":{"href":"https://github.com/michaeltyson/TPKeyboardAvoiding/pull/233"},"issue":{"href":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/issues/233"},"comments":{"href":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/issues/233/comments"},"review_comments":{"href":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/pulls/233/comments"},"review_comment":{"href":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/pulls/233/commits"},"statuses":{"href":"https://api.github.com/repos/michaeltyson/TPKeyboardAvoiding/statuses/8471dd43dc481ff37e9df690f8be8b43a57e6333"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":0,"review_comments":0,"commits":1,"additions":3,"deletions":2,"changed_files":1}}
{"actor":{"display_login":"canicelebrate"}}