{"action":"created","comment":{"url":"https://api.github.com/repos/servo/webrender/pulls/comments/89333786","pull_request_review_id":9879431,"id":89333786,"diff_hunk":"@@ -296,6 +298,40 @@ impl Frame {\n     }\n \n     /// Returns true if any layers actually changed position or false otherwise.\n+    pub fn scroll_layers(&mut self,\n+                         origin: Point2D<f32>,\n+                         pipeline_id: PipelineId,\n+                         scroll_root_id: ServoScrollRootId)\n+                          -> bool {\n+        let origin = LayerPoint::new(origin.x.max(0.0), origin.y.max(0.0));\n+\n+        let mut scrolled_a_layer = false;\n+        let mut found_layer = false;\n+        for (layer_id, layer) in self.layers.iter_mut() {\n+            if layer_id.pipeline_id != pipeline_id {\n+                continue;\n+            }\n+\n+            match layer_id.info {\n+                ScrollLayerInfo::Scrollable(_, id) if id != scroll_root_id => continue,\n+                ScrollLayerInfo::Fixed => continue,\n+                _ => {}\n+            }\n+\n+            found_layer = true;\n+            scrolled_a_layer = layer.set_scroll_origin(&origin);","path":"webrender/src/frame.rs","position":50,"original_position":50,"commit_id":"979f65dad9ae0537733d1d1dfc36a14cb23032d2","original_commit_id":"979f65dad9ae0537733d1d1dfc36a14cb23032d2","user":{"login":"emilio","id":1323194,"avatar_url":"https://avatars.githubusercontent.com/u/1323194?v=3","gravatar_id":"","url":"https://api.github.com/users/emilio","html_url":"https://github.com/emilio","followers_url":"https://api.github.com/users/emilio/followers","following_url":"https://api.github.com/users/emilio/following{/other_user}","gists_url":"https://api.github.com/users/emilio/gists{/gist_id}","starred_url":"https://api.github.com/users/emilio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emilio/subscriptions","organizations_url":"https://api.github.com/users/emilio/orgs","repos_url":"https://api.github.com/users/emilio/repos","events_url":"https://api.github.com/users/emilio/events{/privacy}","received_events_url":"https://api.github.com/users/emilio/received_events","type":"User","site_admin":false},"body":"probably you want this to be `scrolled_a_layer |= layer.set_scroll_origin(&origin)`, right?\r\n\r\nOtherwise (if we can just scroll one layer) we might as well break from the loop when that happens, right?","created_at":"2016-11-23T15:06:18Z","updated_at":"2016-11-23T15:08:06Z","html_url":"https://github.com/servo/webrender/pull/590#discussion_r89333786","pull_request_url":"https://api.github.com/repos/servo/webrender/pulls/590","_links":{"self":{"href":"https://api.github.com/repos/servo/webrender/pulls/comments/89333786"},"html":{"href":"https://github.com/servo/webrender/pull/590#discussion_r89333786"},"pull_request":{"href":"https://api.github.com/repos/servo/webrender/pulls/590"}}},"pull_request":{"url":"https://api.github.com/repos/servo/webrender/pulls/590","id":95016138,"html_url":"https://github.com/servo/webrender/pull/590","diff_url":"https://github.com/servo/webrender/pull/590.diff","patch_url":"https://github.com/servo/webrender/pull/590.patch","issue_url":"https://api.github.com/repos/servo/webrender/issues/590","number":590,"state":"open","locked":false,"title":"Add API for scrolling individual layers","user":{"login":"mrobinson","id":13536,"avatar_url":"https://avatars.githubusercontent.com/u/13536?v=3","gravatar_id":"","url":"https://api.github.com/users/mrobinson","html_url":"https://github.com/mrobinson","followers_url":"https://api.github.com/users/mrobinson/followers","following_url":"https://api.github.com/users/mrobinson/following{/other_user}","gists_url":"https://api.github.com/users/mrobinson/gists{/gist_id}","starred_url":"https://api.github.com/users/mrobinson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrobinson/subscriptions","organizations_url":"https://api.github.com/users/mrobinson/orgs","repos_url":"https://api.github.com/users/mrobinson/repos","events_url":"https://api.github.com/users/mrobinson/events{/privacy}","received_events_url":"https://api.github.com/users/mrobinson/received_events","type":"User","site_admin":false},"body":"This will allow Servo to reimplement scroll_to_fragment.\n\n<!-- Reviewable:start -->\n---\nThis change is [<img src=\"https://reviewable.io/review_button.svg\" height=\"34\" align=\"absmiddle\" alt=\"Reviewable\"/>](https://reviewable.io/reviews/servo/webrender/590)\n<!-- Reviewable:end -->\n","created_at":"2016-11-23T14:44:41Z","updated_at":"2016-11-23T15:08:06Z","closed_at":null,"merged_at":null,"merge_commit_sha":"86b159b0dc84bed97bfb45b2790651650ece5a5a","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/servo/webrender/pulls/590/commits","review_comments_url":"https://api.github.com/repos/servo/webrender/pulls/590/comments","review_comment_url":"https://api.github.com/repos/servo/webrender/pulls/comments{/number}","comments_url":"https://api.github.com/repos/servo/webrender/issues/590/comments","statuses_url":"https://api.github.com/repos/servo/webrender/statuses/979f65dad9ae0537733d1d1dfc36a14cb23032d2","head":{"label":"mrobinson:scroll-to-fragment","ref":"scroll-to-fragment","sha":"979f65dad9ae0537733d1d1dfc36a14cb23032d2","user":{"login":"mrobinson","id":13536,"avatar_url":"https://avatars.githubusercontent.com/u/13536?v=3","gravatar_id":"","url":"https://api.github.com/users/mrobinson","html_url":"https://github.com/mrobinson","followers_url":"https://api.github.com/users/mrobinson/followers","following_url":"https://api.github.com/users/mrobinson/following{/other_user}","gists_url":"https://api.github.com/users/mrobinson/gists{/gist_id}","starred_url":"https://api.github.com/users/mrobinson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrobinson/subscriptions","organizations_url":"https://api.github.com/users/mrobinson/orgs","repos_url":"https://api.github.com/users/mrobinson/repos","events_url":"https://api.github.com/users/mrobinson/events{/privacy}","received_events_url":"https://api.github.com/users/mrobinson/received_events","type":"User","site_admin":false},"repo":{"id":56342369,"name":"webrender","full_name":"mrobinson/webrender","owner":{"login":"mrobinson","id":13536,"avatar_url":"https://avatars.githubusercontent.com/u/13536?v=3","gravatar_id":"","url":"https://api.github.com/users/mrobinson","html_url":"https://github.com/mrobinson","followers_url":"https://api.github.com/users/mrobinson/followers","following_url":"https://api.github.com/users/mrobinson/following{/other_user}","gists_url":"https://api.github.com/users/mrobinson/gists{/gist_id}","starred_url":"https://api.github.com/users/mrobinson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mrobinson/subscriptions","organizations_url":"https://api.github.com/users/mrobinson/orgs","repos_url":"https://api.github.com/users/mrobinson/repos","events_url":"https://api.github.com/users/mrobinson/events{/privacy}","received_events_url":"https://api.github.com/users/mrobinson/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mrobinson/webrender","description":"A very incomplete proof of concept GPU renderer for Servo","fork":true,"url":"https://api.github.com/repos/mrobinson/webrender","forks_url":"https://api.github.com/repos/mrobinson/webrender/forks","keys_url":"https://api.github.com/repos/mrobinson/webrender/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mrobinson/webrender/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mrobinson/webrender/teams","hooks_url":"https://api.github.com/repos/mrobinson/webrender/hooks","issue_events_url":"https://api.github.com/repos/mrobinson/webrender/issues/events{/number}","events_url":"https://api.github.com/repos/mrobinson/webrender/events","assignees_url":"https://api.github.com/repos/mrobinson/webrender/assignees{/user}","branches_url":"https://api.github.com/repos/mrobinson/webrender/branches{/branch}","tags_url":"https://api.github.com/repos/mrobinson/webrender/tags","blobs_url":"https://api.github.com/repos/mrobinson/webrender/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mrobinson/webrender/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mrobinson/webrender/git/refs{/sha}","trees_url":"https://api.github.com/repos/mrobinson/webrender/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mrobinson/webrender/statuses/{sha}","languages_url":"https://api.github.com/repos/mrobinson/webrender/languages","stargazers_url":"https://api.github.com/repos/mrobinson/webrender/stargazers","contributors_url":"https://api.github.com/repos/mrobinson/webrender/contributors","subscribers_url":"https://api.github.com/repos/mrobinson/webrender/subscribers","subscription_url":"https://api.github.com/repos/mrobinson/webrender/subscription","commits_url":"https://api.github.com/repos/mrobinson/webrender/commits{/sha}","git_commits_url":"https://api.github.com/repos/mrobinson/webrender/git/commits{/sha}","comments_url":"https://api.github.com/repos/mrobinson/webrender/comments{/number}","issue_comment_url":"https://api.github.com/repos/mrobinson/webrender/issues/comments{/number}","contents_url":"https://api.github.com/repos/mrobinson/webrender/contents/{+path}","compare_url":"https://api.github.com/repos/mrobinson/webrender/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mrobinson/webrender/merges","archive_url":"https://api.github.com/repos/mrobinson/webrender/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mrobinson/webrender/downloads","issues_url":"https://api.github.com/repos/mrobinson/webrender/issues{/number}","pulls_url":"https://api.github.com/repos/mrobinson/webrender/pulls{/number}","milestones_url":"https://api.github.com/repos/mrobinson/webrender/milestones{/number}","notifications_url":"https://api.github.com/repos/mrobinson/webrender/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mrobinson/webrender/labels{/name}","releases_url":"https://api.github.com/repos/mrobinson/webrender/releases{/id}","deployments_url":"https://api.github.com/repos/mrobinson/webrender/deployments","created_at":"2016-04-15T18:46:17Z","updated_at":"2016-04-15T18:46:18Z","pushed_at":"2016-11-23T14:43:56Z","git_url":"git://github.com/mrobinson/webrender.git","ssh_url":"git@github.com:mrobinson/webrender.git","clone_url":"https://github.com/mrobinson/webrender.git","svn_url":"https://github.com/mrobinson/webrender","homepage":"https://doc.servo.org/webrender/","size":3659,"stargazers_count":0,"watchers_count":0,"language":"Rust","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":"servo:master","ref":"master","sha":"82a0ca4811cc1444010a579104767443f49212c6","user":{"login":"servo","id":2566135,"avatar_url":"https://avatars.githubusercontent.com/u/2566135?v=3","gravatar_id":"","url":"https://api.github.com/users/servo","html_url":"https://github.com/servo","followers_url":"https://api.github.com/users/servo/followers","following_url":"https://api.github.com/users/servo/following{/other_user}","gists_url":"https://api.github.com/users/servo/gists{/gist_id}","starred_url":"https://api.github.com/users/servo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/servo/subscriptions","organizations_url":"https://api.github.com/users/servo/orgs","repos_url":"https://api.github.com/users/servo/repos","events_url":"https://api.github.com/users/servo/events{/privacy}","received_events_url":"https://api.github.com/users/servo/received_events","type":"Organization","site_admin":false},"repo":{"id":42894575,"name":"webrender","full_name":"servo/webrender","owner":{"login":"servo","id":2566135,"avatar_url":"https://avatars.githubusercontent.com/u/2566135?v=3","gravatar_id":"","url":"https://api.github.com/users/servo","html_url":"https://github.com/servo","followers_url":"https://api.github.com/users/servo/followers","following_url":"https://api.github.com/users/servo/following{/other_user}","gists_url":"https://api.github.com/users/servo/gists{/gist_id}","starred_url":"https://api.github.com/users/servo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/servo/subscriptions","organizations_url":"https://api.github.com/users/servo/orgs","repos_url":"https://api.github.com/users/servo/repos","events_url":"https://api.github.com/users/servo/events{/privacy}","received_events_url":"https://api.github.com/users/servo/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/servo/webrender","description":"A very incomplete proof of concept GPU renderer for Servo","fork":false,"url":"https://api.github.com/repos/servo/webrender","forks_url":"https://api.github.com/repos/servo/webrender/forks","keys_url":"https://api.github.com/repos/servo/webrender/keys{/key_id}","collaborators_url":"https://api.github.com/repos/servo/webrender/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/servo/webrender/teams","hooks_url":"https://api.github.com/repos/servo/webrender/hooks","issue_events_url":"https://api.github.com/repos/servo/webrender/issues/events{/number}","events_url":"https://api.github.com/repos/servo/webrender/events","assignees_url":"https://api.github.com/repos/servo/webrender/assignees{/user}","branches_url":"https://api.github.com/repos/servo/webrender/branches{/branch}","tags_url":"https://api.github.com/repos/servo/webrender/tags","blobs_url":"https://api.github.com/repos/servo/webrender/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/servo/webrender/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/servo/webrender/git/refs{/sha}","trees_url":"https://api.github.com/repos/servo/webrender/git/trees{/sha}","statuses_url":"https://api.github.com/repos/servo/webrender/statuses/{sha}","languages_url":"https://api.github.com/repos/servo/webrender/languages","stargazers_url":"https://api.github.com/repos/servo/webrender/stargazers","contributors_url":"https://api.github.com/repos/servo/webrender/contributors","subscribers_url":"https://api.github.com/repos/servo/webrender/subscribers","subscription_url":"https://api.github.com/repos/servo/webrender/subscription","commits_url":"https://api.github.com/repos/servo/webrender/commits{/sha}","git_commits_url":"https://api.github.com/repos/servo/webrender/git/commits{/sha}","comments_url":"https://api.github.com/repos/servo/webrender/comments{/number}","issue_comment_url":"https://api.github.com/repos/servo/webrender/issues/comments{/number}","contents_url":"https://api.github.com/repos/servo/webrender/contents/{+path}","compare_url":"https://api.github.com/repos/servo/webrender/compare/{base}...{head}","merges_url":"https://api.github.com/repos/servo/webrender/merges","archive_url":"https://api.github.com/repos/servo/webrender/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/servo/webrender/downloads","issues_url":"https://api.github.com/repos/servo/webrender/issues{/number}","pulls_url":"https://api.github.com/repos/servo/webrender/pulls{/number}","milestones_url":"https://api.github.com/repos/servo/webrender/milestones{/number}","notifications_url":"https://api.github.com/repos/servo/webrender/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/servo/webrender/labels{/name}","releases_url":"https://api.github.com/repos/servo/webrender/releases{/id}","deployments_url":"https://api.github.com/repos/servo/webrender/deployments","created_at":"2015-09-21T21:27:30Z","updated_at":"2016-11-18T21:36:03Z","pushed_at":"2016-11-23T14:44:47Z","git_url":"git://github.com/servo/webrender.git","ssh_url":"git@github.com:servo/webrender.git","clone_url":"https://github.com/servo/webrender.git","svn_url":"https://github.com/servo/webrender","homepage":"https://doc.servo.org/webrender/","size":4025,"stargazers_count":515,"watchers_count":515,"language":"Rust","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":66,"mirror_url":null,"open_issues_count":71,"forks":66,"open_issues":71,"watchers":515,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/servo/webrender/pulls/590"},"html":{"href":"https://github.com/servo/webrender/pull/590"},"issue":{"href":"https://api.github.com/repos/servo/webrender/issues/590"},"comments":{"href":"https://api.github.com/repos/servo/webrender/issues/590/comments"},"review_comments":{"href":"https://api.github.com/repos/servo/webrender/pulls/590/comments"},"review_comment":{"href":"https://api.github.com/repos/servo/webrender/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/servo/webrender/pulls/590/commits"},"statuses":{"href":"https://api.github.com/repos/servo/webrender/statuses/979f65dad9ae0537733d1d1dfc36a14cb23032d2"}}}}
{"actor":{"display_login":"emilio"}}