{"action":"created","comment":{"url":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/comments/23425017","id":23425017,"diff_hunk":"@@ -221,11 +267,44 @@ function hookButtonsToCanvas(qid, c) {\n \n         if (ajaxSave) {\n           updateScribble(qid,c);\n+        } else {\n+          var ansField = $('#answers_' + qid);\n+          ansField.val(getJSON(qid,canvas));\n         }\n       });\n   }\n }\n \n+function renderCanvas(c, scribingImage, isEditMode, qid) {\n+  c.clear();\n+  c.setWidth(Math.min($('#scribing-container-' + qid).width(), scribingImage.width));","path":"app/assets/javascripts/scribing_canvas.js","position":143,"original_position":143,"commit_id":"5823681a3f0b7bf88053331d83936d40bbecce99","original_commit_id":"5823681a3f0b7bf88053331d83936d40bbecce99","user":{"login":"houndci","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci","html_url":"https://github.com/houndci","followers_url":"https://api.github.com/users/houndci/followers","following_url":"https://api.github.com/users/houndci/following{/other_user}","gists_url":"https://api.github.com/users/houndci/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci/subscriptions","organizations_url":"https://api.github.com/users/houndci/orgs","repos_url":"https://api.github.com/users/houndci/repos","events_url":"https://api.github.com/users/houndci/events{/privacy}","received_events_url":"https://api.github.com/users/houndci/received_events","type":"User","site_admin":false},"body":"Line is too long.","created_at":"2015-01-23T01:02:15Z","updated_at":"2015-01-23T01:02:15Z","html_url":"https://github.com/Coursemology/coursemology.org/pull/366#discussion_r23425017","pull_request_url":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/366","_links":{"self":{"href":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/comments/23425017"},"html":{"href":"https://github.com/Coursemology/coursemology.org/pull/366#discussion_r23425017"},"pull_request":{"href":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/366"}}},"pull_request":{"url":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/366","id":27559069,"html_url":"https://github.com/Coursemology/coursemology.org/pull/366","diff_url":"https://github.com/Coursemology/coursemology.org/pull/366.diff","patch_url":"https://github.com/Coursemology/coursemology.org/pull/366.patch","issue_url":"https://api.github.com/repos/Coursemology/coursemology.org/issues/366","number":366,"state":"open","locked":false,"title":"Fix scribing scaling","user":{"login":"kxmbrian","id":6252919,"avatar_url":"https://avatars.githubusercontent.com/u/6252919?v=3","gravatar_id":"","url":"https://api.github.com/users/kxmbrian","html_url":"https://github.com/kxmbrian","followers_url":"https://api.github.com/users/kxmbrian/followers","following_url":"https://api.github.com/users/kxmbrian/following{/other_user}","gists_url":"https://api.github.com/users/kxmbrian/gists{/gist_id}","starred_url":"https://api.github.com/users/kxmbrian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kxmbrian/subscriptions","organizations_url":"https://api.github.com/users/kxmbrian/orgs","repos_url":"https://api.github.com/users/kxmbrian/repos","events_url":"https://api.github.com/users/kxmbrian/events{/privacy}","received_events_url":"https://api.github.com/users/kxmbrian/received_events","type":"User","site_admin":false},"body":"Fix for #336. Scribbles should now display consistently on different browser / screen / canvas sizes.\r\n\r\nOther minor improvements also included.","created_at":"2015-01-17T17:04:11Z","updated_at":"2015-01-23T01:02:15Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ad684bc8ddc5d10511cd3665504d6b443de15acd","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/366/commits","review_comments_url":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/366/comments","review_comment_url":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/comments/{number}","comments_url":"https://api.github.com/repos/Coursemology/coursemology.org/issues/366/comments","statuses_url":"https://api.github.com/repos/Coursemology/coursemology.org/statuses/5823681a3f0b7bf88053331d83936d40bbecce99","head":{"label":"kxmbrian:fix-scribing-scaling","ref":"fix-scribing-scaling","sha":"5823681a3f0b7bf88053331d83936d40bbecce99","user":{"login":"kxmbrian","id":6252919,"avatar_url":"https://avatars.githubusercontent.com/u/6252919?v=3","gravatar_id":"","url":"https://api.github.com/users/kxmbrian","html_url":"https://github.com/kxmbrian","followers_url":"https://api.github.com/users/kxmbrian/followers","following_url":"https://api.github.com/users/kxmbrian/following{/other_user}","gists_url":"https://api.github.com/users/kxmbrian/gists{/gist_id}","starred_url":"https://api.github.com/users/kxmbrian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kxmbrian/subscriptions","organizations_url":"https://api.github.com/users/kxmbrian/orgs","repos_url":"https://api.github.com/users/kxmbrian/repos","events_url":"https://api.github.com/users/kxmbrian/events{/privacy}","received_events_url":"https://api.github.com/users/kxmbrian/received_events","type":"User","site_admin":false},"repo":{"id":15742980,"name":"coursemology.org","full_name":"kxmbrian/coursemology.org","owner":{"login":"kxmbrian","id":6252919,"avatar_url":"https://avatars.githubusercontent.com/u/6252919?v=3","gravatar_id":"","url":"https://api.github.com/users/kxmbrian","html_url":"https://github.com/kxmbrian","followers_url":"https://api.github.com/users/kxmbrian/followers","following_url":"https://api.github.com/users/kxmbrian/following{/other_user}","gists_url":"https://api.github.com/users/kxmbrian/gists{/gist_id}","starred_url":"https://api.github.com/users/kxmbrian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kxmbrian/subscriptions","organizations_url":"https://api.github.com/users/kxmbrian/orgs","repos_url":"https://api.github.com/users/kxmbrian/repos","events_url":"https://api.github.com/users/kxmbrian/events{/privacy}","received_events_url":"https://api.github.com/users/kxmbrian/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/kxmbrian/coursemology.org","description":"Coursemology","fork":true,"url":"https://api.github.com/repos/kxmbrian/coursemology.org","forks_url":"https://api.github.com/repos/kxmbrian/coursemology.org/forks","keys_url":"https://api.github.com/repos/kxmbrian/coursemology.org/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kxmbrian/coursemology.org/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kxmbrian/coursemology.org/teams","hooks_url":"https://api.github.com/repos/kxmbrian/coursemology.org/hooks","issue_events_url":"https://api.github.com/repos/kxmbrian/coursemology.org/issues/events{/number}","events_url":"https://api.github.com/repos/kxmbrian/coursemology.org/events","assignees_url":"https://api.github.com/repos/kxmbrian/coursemology.org/assignees{/user}","branches_url":"https://api.github.com/repos/kxmbrian/coursemology.org/branches{/branch}","tags_url":"https://api.github.com/repos/kxmbrian/coursemology.org/tags","blobs_url":"https://api.github.com/repos/kxmbrian/coursemology.org/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kxmbrian/coursemology.org/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kxmbrian/coursemology.org/git/refs{/sha}","trees_url":"https://api.github.com/repos/kxmbrian/coursemology.org/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kxmbrian/coursemology.org/statuses/{sha}","languages_url":"https://api.github.com/repos/kxmbrian/coursemology.org/languages","stargazers_url":"https://api.github.com/repos/kxmbrian/coursemology.org/stargazers","contributors_url":"https://api.github.com/repos/kxmbrian/coursemology.org/contributors","subscribers_url":"https://api.github.com/repos/kxmbrian/coursemology.org/subscribers","subscription_url":"https://api.github.com/repos/kxmbrian/coursemology.org/subscription","commits_url":"https://api.github.com/repos/kxmbrian/coursemology.org/commits{/sha}","git_commits_url":"https://api.github.com/repos/kxmbrian/coursemology.org/git/commits{/sha}","comments_url":"https://api.github.com/repos/kxmbrian/coursemology.org/comments{/number}","issue_comment_url":"https://api.github.com/repos/kxmbrian/coursemology.org/issues/comments/{number}","contents_url":"https://api.github.com/repos/kxmbrian/coursemology.org/contents/{+path}","compare_url":"https://api.github.com/repos/kxmbrian/coursemology.org/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kxmbrian/coursemology.org/merges","archive_url":"https://api.github.com/repos/kxmbrian/coursemology.org/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kxmbrian/coursemology.org/downloads","issues_url":"https://api.github.com/repos/kxmbrian/coursemology.org/issues{/number}","pulls_url":"https://api.github.com/repos/kxmbrian/coursemology.org/pulls{/number}","milestones_url":"https://api.github.com/repos/kxmbrian/coursemology.org/milestones{/number}","notifications_url":"https://api.github.com/repos/kxmbrian/coursemology.org/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kxmbrian/coursemology.org/labels{/name}","releases_url":"https://api.github.com/repos/kxmbrian/coursemology.org/releases{/id}","created_at":"2014-01-08T17:45:23Z","updated_at":"2015-01-17T08:20:07Z","pushed_at":"2015-01-23T01:02:09Z","git_url":"git://github.com/kxmbrian/coursemology.org.git","ssh_url":"git@github.com:kxmbrian/coursemology.org.git","clone_url":"https://github.com/kxmbrian/coursemology.org.git","svn_url":"https://github.com/kxmbrian/coursemology.org","homepage":"","size":32748,"stargazers_count":0,"watchers_count":0,"language":"Ruby","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":"development"}},"base":{"label":"Coursemology:development","ref":"development","sha":"305e5e8c64b02857b7787d19f4967e6f106ab216","user":{"login":"Coursemology","id":4427741,"avatar_url":"https://avatars.githubusercontent.com/u/4427741?v=3","gravatar_id":"","url":"https://api.github.com/users/Coursemology","html_url":"https://github.com/Coursemology","followers_url":"https://api.github.com/users/Coursemology/followers","following_url":"https://api.github.com/users/Coursemology/following{/other_user}","gists_url":"https://api.github.com/users/Coursemology/gists{/gist_id}","starred_url":"https://api.github.com/users/Coursemology/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Coursemology/subscriptions","organizations_url":"https://api.github.com/users/Coursemology/orgs","repos_url":"https://api.github.com/users/Coursemology/repos","events_url":"https://api.github.com/users/Coursemology/events{/privacy}","received_events_url":"https://api.github.com/users/Coursemology/received_events","type":"Organization","site_admin":false},"repo":{"id":10055153,"name":"coursemology.org","full_name":"Coursemology/coursemology.org","owner":{"login":"Coursemology","id":4427741,"avatar_url":"https://avatars.githubusercontent.com/u/4427741?v=3","gravatar_id":"","url":"https://api.github.com/users/Coursemology","html_url":"https://github.com/Coursemology","followers_url":"https://api.github.com/users/Coursemology/followers","following_url":"https://api.github.com/users/Coursemology/following{/other_user}","gists_url":"https://api.github.com/users/Coursemology/gists{/gist_id}","starred_url":"https://api.github.com/users/Coursemology/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Coursemology/subscriptions","organizations_url":"https://api.github.com/users/Coursemology/orgs","repos_url":"https://api.github.com/users/Coursemology/repos","events_url":"https://api.github.com/users/Coursemology/events{/privacy}","received_events_url":"https://api.github.com/users/Coursemology/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Coursemology/coursemology.org","description":"","fork":false,"url":"https://api.github.com/repos/Coursemology/coursemology.org","forks_url":"https://api.github.com/repos/Coursemology/coursemology.org/forks","keys_url":"https://api.github.com/repos/Coursemology/coursemology.org/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Coursemology/coursemology.org/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Coursemology/coursemology.org/teams","hooks_url":"https://api.github.com/repos/Coursemology/coursemology.org/hooks","issue_events_url":"https://api.github.com/repos/Coursemology/coursemology.org/issues/events{/number}","events_url":"https://api.github.com/repos/Coursemology/coursemology.org/events","assignees_url":"https://api.github.com/repos/Coursemology/coursemology.org/assignees{/user}","branches_url":"https://api.github.com/repos/Coursemology/coursemology.org/branches{/branch}","tags_url":"https://api.github.com/repos/Coursemology/coursemology.org/tags","blobs_url":"https://api.github.com/repos/Coursemology/coursemology.org/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Coursemology/coursemology.org/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Coursemology/coursemology.org/git/refs{/sha}","trees_url":"https://api.github.com/repos/Coursemology/coursemology.org/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Coursemology/coursemology.org/statuses/{sha}","languages_url":"https://api.github.com/repos/Coursemology/coursemology.org/languages","stargazers_url":"https://api.github.com/repos/Coursemology/coursemology.org/stargazers","contributors_url":"https://api.github.com/repos/Coursemology/coursemology.org/contributors","subscribers_url":"https://api.github.com/repos/Coursemology/coursemology.org/subscribers","subscription_url":"https://api.github.com/repos/Coursemology/coursemology.org/subscription","commits_url":"https://api.github.com/repos/Coursemology/coursemology.org/commits{/sha}","git_commits_url":"https://api.github.com/repos/Coursemology/coursemology.org/git/commits{/sha}","comments_url":"https://api.github.com/repos/Coursemology/coursemology.org/comments{/number}","issue_comment_url":"https://api.github.com/repos/Coursemology/coursemology.org/issues/comments/{number}","contents_url":"https://api.github.com/repos/Coursemology/coursemology.org/contents/{+path}","compare_url":"https://api.github.com/repos/Coursemology/coursemology.org/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Coursemology/coursemology.org/merges","archive_url":"https://api.github.com/repos/Coursemology/coursemology.org/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Coursemology/coursemology.org/downloads","issues_url":"https://api.github.com/repos/Coursemology/coursemology.org/issues{/number}","pulls_url":"https://api.github.com/repos/Coursemology/coursemology.org/pulls{/number}","milestones_url":"https://api.github.com/repos/Coursemology/coursemology.org/milestones{/number}","notifications_url":"https://api.github.com/repos/Coursemology/coursemology.org/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Coursemology/coursemology.org/labels{/name}","releases_url":"https://api.github.com/repos/Coursemology/coursemology.org/releases{/id}","created_at":"2013-05-14T13:04:30Z","updated_at":"2015-01-20T07:14:23Z","pushed_at":"2015-01-20T07:14:22Z","git_url":"git://github.com/Coursemology/coursemology.org.git","ssh_url":"git@github.com:Coursemology/coursemology.org.git","clone_url":"https://github.com/Coursemology/coursemology.org.git","svn_url":"https://github.com/Coursemology/coursemology.org","homepage":"coursemology.org","size":38259,"stargazers_count":27,"watchers_count":27,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":31,"mirror_url":null,"open_issues_count":67,"forks":31,"open_issues":67,"watchers":27,"default_branch":"development"}},"_links":{"self":{"href":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/366"},"html":{"href":"https://github.com/Coursemology/coursemology.org/pull/366"},"issue":{"href":"https://api.github.com/repos/Coursemology/coursemology.org/issues/366"},"comments":{"href":"https://api.github.com/repos/Coursemology/coursemology.org/issues/366/comments"},"review_comments":{"href":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/366/comments"},"review_comment":{"href":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/Coursemology/coursemology.org/pulls/366/commits"},"statuses":{"href":"https://api.github.com/repos/Coursemology/coursemology.org/statuses/5823681a3f0b7bf88053331d83936d40bbecce99"}}}}