{"action":"closed","number":4496,"pull_request":{"url":"https://api.github.com/repos/mapbox/mapbox-gl-native/pulls/4496","id":64374206,"html_url":"https://github.com/mapbox/mapbox-gl-native/pull/4496","diff_url":"https://github.com/mapbox/mapbox-gl-native/pull/4496.diff","patch_url":"https://github.com/mapbox/mapbox-gl-native/pull/4496.patch","issue_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/4496","number":4496,"state":"closed","locked":false,"title":"[android] Remove onStart() and onStop() lifecycle methods from MapView","user":{"login":"justasm","id":1081815,"avatar_url":"https://avatars.githubusercontent.com/u/1081815?v=3","gravatar_id":"","url":"https://api.github.com/users/justasm","html_url":"https://github.com/justasm","followers_url":"https://api.github.com/users/justasm/followers","following_url":"https://api.github.com/users/justasm/following{/other_user}","gists_url":"https://api.github.com/users/justasm/gists{/gist_id}","starred_url":"https://api.github.com/users/justasm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justasm/subscriptions","organizations_url":"https://api.github.com/users/justasm/orgs","repos_url":"https://api.github.com/users/justasm/repos","events_url":"https://api.github.com/users/justasm/events{/privacy}","received_events_url":"https://api.github.com/users/justasm/received_events","type":"User","site_admin":false},"body":"- Removes `onStart()` and `onStop()` from MapView and UserLocationView.\r\n- Moves sensor event listener registering / unregistering from UserLocationView `onStart()` and `onStop()` to `onResume()` and `onPause()`, respectively.\r\n\r\nMotivation:\r\n- Parity with the [Google Maps Android API v2 regarding MapView lifecycle requirements](https://developers.google.com/android/reference/com/google/android/gms/maps/MapView).\r\n- Simpler API for users who choose to manage MapView directly.\r\n- Android guidelines [recommend registering and unregistering sensor event listeners in `onResume()` and `onPause()`](http://developer.android.com/guide/topics/sensors/sensors_overview.html#sensors-monitor) to reduce battery drain in situations where the Activity is paused but not stopped, e.g. when the user locks the device and the screen is off.","created_at":"2016-03-28T20:52:11Z","updated_at":"2016-03-29T08:45:28Z","closed_at":"2016-03-29T08:45:28Z","merged_at":null,"merge_commit_sha":"fbd7df4f57cd3b5aba8a55d83da6014cd9f28b65","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/pulls/4496/commits","review_comments_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/pulls/4496/comments","review_comment_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/4496/comments","statuses_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/statuses/052a9320fc765507a92a4db55e845862b054c75f","head":{"label":"justasm:remove_onstart_onstop","ref":"remove_onstart_onstop","sha":"052a9320fc765507a92a4db55e845862b054c75f","user":{"login":"justasm","id":1081815,"avatar_url":"https://avatars.githubusercontent.com/u/1081815?v=3","gravatar_id":"","url":"https://api.github.com/users/justasm","html_url":"https://github.com/justasm","followers_url":"https://api.github.com/users/justasm/followers","following_url":"https://api.github.com/users/justasm/following{/other_user}","gists_url":"https://api.github.com/users/justasm/gists{/gist_id}","starred_url":"https://api.github.com/users/justasm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justasm/subscriptions","organizations_url":"https://api.github.com/users/justasm/orgs","repos_url":"https://api.github.com/users/justasm/repos","events_url":"https://api.github.com/users/justasm/events{/privacy}","received_events_url":"https://api.github.com/users/justasm/received_events","type":"User","site_admin":false},"repo":{"id":54892522,"name":"mapbox-gl-native","full_name":"justasm/mapbox-gl-native","owner":{"login":"justasm","id":1081815,"avatar_url":"https://avatars.githubusercontent.com/u/1081815?v=3","gravatar_id":"","url":"https://api.github.com/users/justasm","html_url":"https://github.com/justasm","followers_url":"https://api.github.com/users/justasm/followers","following_url":"https://api.github.com/users/justasm/following{/other_user}","gists_url":"https://api.github.com/users/justasm/gists{/gist_id}","starred_url":"https://api.github.com/users/justasm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/justasm/subscriptions","organizations_url":"https://api.github.com/users/justasm/orgs","repos_url":"https://api.github.com/users/justasm/repos","events_url":"https://api.github.com/users/justasm/events{/privacy}","received_events_url":"https://api.github.com/users/justasm/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/justasm/mapbox-gl-native","description":"Render Mapbox styles in mobile, desktop, and node applications using C++ and OpenGL","fork":true,"url":"https://api.github.com/repos/justasm/mapbox-gl-native","forks_url":"https://api.github.com/repos/justasm/mapbox-gl-native/forks","keys_url":"https://api.github.com/repos/justasm/mapbox-gl-native/keys{/key_id}","collaborators_url":"https://api.github.com/repos/justasm/mapbox-gl-native/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/justasm/mapbox-gl-native/teams","hooks_url":"https://api.github.com/repos/justasm/mapbox-gl-native/hooks","issue_events_url":"https://api.github.com/repos/justasm/mapbox-gl-native/issues/events{/number}","events_url":"https://api.github.com/repos/justasm/mapbox-gl-native/events","assignees_url":"https://api.github.com/repos/justasm/mapbox-gl-native/assignees{/user}","branches_url":"https://api.github.com/repos/justasm/mapbox-gl-native/branches{/branch}","tags_url":"https://api.github.com/repos/justasm/mapbox-gl-native/tags","blobs_url":"https://api.github.com/repos/justasm/mapbox-gl-native/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/justasm/mapbox-gl-native/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/justasm/mapbox-gl-native/git/refs{/sha}","trees_url":"https://api.github.com/repos/justasm/mapbox-gl-native/git/trees{/sha}","statuses_url":"https://api.github.com/repos/justasm/mapbox-gl-native/statuses/{sha}","languages_url":"https://api.github.com/repos/justasm/mapbox-gl-native/languages","stargazers_url":"https://api.github.com/repos/justasm/mapbox-gl-native/stargazers","contributors_url":"https://api.github.com/repos/justasm/mapbox-gl-native/contributors","subscribers_url":"https://api.github.com/repos/justasm/mapbox-gl-native/subscribers","subscription_url":"https://api.github.com/repos/justasm/mapbox-gl-native/subscription","commits_url":"https://api.github.com/repos/justasm/mapbox-gl-native/commits{/sha}","git_commits_url":"https://api.github.com/repos/justasm/mapbox-gl-native/git/commits{/sha}","comments_url":"https://api.github.com/repos/justasm/mapbox-gl-native/comments{/number}","issue_comment_url":"https://api.github.com/repos/justasm/mapbox-gl-native/issues/comments{/number}","contents_url":"https://api.github.com/repos/justasm/mapbox-gl-native/contents/{+path}","compare_url":"https://api.github.com/repos/justasm/mapbox-gl-native/compare/{base}...{head}","merges_url":"https://api.github.com/repos/justasm/mapbox-gl-native/merges","archive_url":"https://api.github.com/repos/justasm/mapbox-gl-native/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/justasm/mapbox-gl-native/downloads","issues_url":"https://api.github.com/repos/justasm/mapbox-gl-native/issues{/number}","pulls_url":"https://api.github.com/repos/justasm/mapbox-gl-native/pulls{/number}","milestones_url":"https://api.github.com/repos/justasm/mapbox-gl-native/milestones{/number}","notifications_url":"https://api.github.com/repos/justasm/mapbox-gl-native/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/justasm/mapbox-gl-native/labels{/name}","releases_url":"https://api.github.com/repos/justasm/mapbox-gl-native/releases{/id}","deployments_url":"https://api.github.com/repos/justasm/mapbox-gl-native/deployments","created_at":"2016-03-28T13:02:10Z","updated_at":"2016-03-28T13:02:14Z","pushed_at":"2016-03-28T21:24:10Z","git_url":"git://github.com/justasm/mapbox-gl-native.git","ssh_url":"git@github.com:justasm/mapbox-gl-native.git","clone_url":"https://github.com/justasm/mapbox-gl-native.git","svn_url":"https://github.com/justasm/mapbox-gl-native","homepage":"https://mapbox.com/mobile","size":35113,"stargazers_count":0,"watchers_count":0,"language":"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":"mapbox:master","ref":"master","sha":"3afdfc15a182707d24d288dcd32166c4a111d732","user":{"login":"mapbox","id":600935,"avatar_url":"https://avatars.githubusercontent.com/u/600935?v=3","gravatar_id":"","url":"https://api.github.com/users/mapbox","html_url":"https://github.com/mapbox","followers_url":"https://api.github.com/users/mapbox/followers","following_url":"https://api.github.com/users/mapbox/following{/other_user}","gists_url":"https://api.github.com/users/mapbox/gists{/gist_id}","starred_url":"https://api.github.com/users/mapbox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mapbox/subscriptions","organizations_url":"https://api.github.com/users/mapbox/orgs","repos_url":"https://api.github.com/users/mapbox/repos","events_url":"https://api.github.com/users/mapbox/events{/privacy}","received_events_url":"https://api.github.com/users/mapbox/received_events","type":"Organization","site_admin":false},"repo":{"id":16286131,"name":"mapbox-gl-native","full_name":"mapbox/mapbox-gl-native","owner":{"login":"mapbox","id":600935,"avatar_url":"https://avatars.githubusercontent.com/u/600935?v=3","gravatar_id":"","url":"https://api.github.com/users/mapbox","html_url":"https://github.com/mapbox","followers_url":"https://api.github.com/users/mapbox/followers","following_url":"https://api.github.com/users/mapbox/following{/other_user}","gists_url":"https://api.github.com/users/mapbox/gists{/gist_id}","starred_url":"https://api.github.com/users/mapbox/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mapbox/subscriptions","organizations_url":"https://api.github.com/users/mapbox/orgs","repos_url":"https://api.github.com/users/mapbox/repos","events_url":"https://api.github.com/users/mapbox/events{/privacy}","received_events_url":"https://api.github.com/users/mapbox/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mapbox/mapbox-gl-native","description":"Render Mapbox styles in mobile, desktop, and node applications using C++ and OpenGL","fork":false,"url":"https://api.github.com/repos/mapbox/mapbox-gl-native","forks_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/forks","keys_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/teams","hooks_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/hooks","issue_events_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/events{/number}","events_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/events","assignees_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/assignees{/user}","branches_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/branches{/branch}","tags_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/tags","blobs_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/git/refs{/sha}","trees_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/statuses/{sha}","languages_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/languages","stargazers_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/stargazers","contributors_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/contributors","subscribers_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/subscribers","subscription_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/subscription","commits_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/commits{/sha}","git_commits_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/git/commits{/sha}","comments_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/comments{/number}","issue_comment_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/comments{/number}","contents_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/contents/{+path}","compare_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/merges","archive_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/downloads","issues_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues{/number}","pulls_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/pulls{/number}","milestones_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/milestones{/number}","notifications_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/labels{/name}","releases_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/releases{/id}","deployments_url":"https://api.github.com/repos/mapbox/mapbox-gl-native/deployments","created_at":"2014-01-27T17:14:48Z","updated_at":"2016-03-28T20:40:50Z","pushed_at":"2016-03-29T08:05:24Z","git_url":"git://github.com/mapbox/mapbox-gl-native.git","ssh_url":"git@github.com:mapbox/mapbox-gl-native.git","clone_url":"https://github.com/mapbox/mapbox-gl-native.git","svn_url":"https://github.com/mapbox/mapbox-gl-native","homepage":"https://mapbox.com/mobile","size":68032,"stargazers_count":1169,"watchers_count":1169,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":297,"mirror_url":null,"open_issues_count":469,"forks":297,"open_issues":469,"watchers":1169,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-native/pulls/4496"},"html":{"href":"https://github.com/mapbox/mapbox-gl-native/pull/4496"},"issue":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/4496"},"comments":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-native/issues/4496/comments"},"review_comments":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-native/pulls/4496/comments"},"review_comment":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-native/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-native/pulls/4496/commits"},"statuses":{"href":"https://api.github.com/repos/mapbox/mapbox-gl-native/statuses/052a9320fc765507a92a4db55e845862b054c75f"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":1,"review_comments":0,"commits":1,"additions":9,"deletions":290,"changed_files":25}}