{"action":"created","comment":{"url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/comments/44607492","id":44607492,"diff_hunk":"@@ -0,0 +1,61 @@\n+package edu.wpi.grip.ui.preview;\n+\n+import com.google.common.eventbus.EventBus;\n+import com.google.common.eventbus.Subscribe;\n+import edu.wpi.grip.core.OutputSocket;\n+import edu.wpi.grip.core.events.SocketChangedEvent;\n+import javafx.scene.control.Label;\n+import javafx.scene.control.TextField;\n+import javafx.scene.layout.GridPane;\n+import org.bytedeco.javacpp.IntPointer;\n+\n+import static org.bytedeco.javacpp.opencv_core.*;\n+\n+/**\n+ * A {@link SocketPreviewView} for OpenCV points and sizes\n+ */\n+public class PointSizeSocketPreviewView extends SocketPreviewView<IntPointer> {\n+\n+    private final TextField x, y;\n+\n+    /**\n+     * @param eventBus The EventBus used by the application\n+     * @param socket   An output socket to preview\n+     */\n+    public PointSizeSocketPreviewView(EventBus eventBus, OutputSocket<IntPointer> socket) {\n+        super(eventBus, socket);\n+\n+        x = new TextField();\n+        x.setEditable(false);\n+        y = new TextField();\n+        y.setEditable(false);\n+\n+        final GridPane gridPane = new GridPane();\n+        gridPane.add(x, 1, 0);\n+        gridPane.add(y, 1, 1);\n+\n+        // The only difference between point and size previews is the labels\n+        if (socket.getSocketHint().getType().equals(Point.class)) {\n+            gridPane.add(new Label(\"x: \"), 0, 0);\n+            gridPane.add(new Label(\"y: \"), 0, 1);\n+        } else if (socket.getSocketHint().getType().equals(Size.class)) {\n+            gridPane.add(new Label(\"width: \"), 0, 0);\n+            gridPane.add(new Label(\"height: \"), 0, 1);\n+        }\n+\n+        this.updateTextFields();\n+        this.setContent(gridPane);\n+    }\n+\n+    @Subscribe\n+    public void onSocketChanged(SocketChangedEvent event) {","path":"src/main/java/edu/wpi/grip/ui/preview/PointSizeSocketPreviewView.java","position":51,"original_position":51,"commit_id":"5e983057104780a4e7a4bdc71f04e38dfda6e7f8","original_commit_id":"5e983057104780a4e7a4bdc71f04e38dfda6e7f8","user":{"login":"WPIRoboticsProjects-Bot","id":14011429,"avatar_url":"https://avatars.githubusercontent.com/u/14011429?v=3","gravatar_id":"","url":"https://api.github.com/users/WPIRoboticsProjects-Bot","html_url":"https://github.com/WPIRoboticsProjects-Bot","followers_url":"https://api.github.com/users/WPIRoboticsProjects-Bot/followers","following_url":"https://api.github.com/users/WPIRoboticsProjects-Bot/following{/other_user}","gists_url":"https://api.github.com/users/WPIRoboticsProjects-Bot/gists{/gist_id}","starred_url":"https://api.github.com/users/WPIRoboticsProjects-Bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WPIRoboticsProjects-Bot/subscriptions","organizations_url":"https://api.github.com/users/WPIRoboticsProjects-Bot/orgs","repos_url":"https://api.github.com/users/WPIRoboticsProjects-Bot/repos","events_url":"https://api.github.com/users/WPIRoboticsProjects-Bot/events{/privacy}","received_events_url":"https://api.github.com/users/WPIRoboticsProjects-Bot/received_events","type":"User","site_admin":false},"body":"![Codacy](https://www.codacy.com/versioned/images/favicon.png) Issue found: [Parameter 'event' is not assigned and could be declared final](https://www.codacy.com/app/WPIRoboticsProjects/GRIP/file/1312743850/issues/source?bid=2943107&fileBranchId=2952672#l51)","created_at":"2015-11-12T00:25:47Z","updated_at":"2015-11-12T00:25:47Z","html_url":"https://github.com/WPIRoboticsProjects/GRIP/pull/130#discussion_r44607492","pull_request_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/130","_links":{"self":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/comments/44607492"},"html":{"href":"https://github.com/WPIRoboticsProjects/GRIP/pull/130#discussion_r44607492"},"pull_request":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/130"}}},"pull_request":{"url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/130","id":50448483,"html_url":"https://github.com/WPIRoboticsProjects/GRIP/pull/130","diff_url":"https://github.com/WPIRoboticsProjects/GRIP/pull/130.diff","patch_url":"https://github.com/WPIRoboticsProjects/GRIP/pull/130.patch","issue_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/130","number":130,"state":"open","locked":false,"title":"Add more preview enhancements","user":{"login":"ThomasJClark","id":3964980,"avatar_url":"https://avatars.githubusercontent.com/u/3964980?v=3","gravatar_id":"","url":"https://api.github.com/users/ThomasJClark","html_url":"https://github.com/ThomasJClark","followers_url":"https://api.github.com/users/ThomasJClark/followers","following_url":"https://api.github.com/users/ThomasJClark/following{/other_user}","gists_url":"https://api.github.com/users/ThomasJClark/gists{/gist_id}","starred_url":"https://api.github.com/users/ThomasJClark/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ThomasJClark/subscriptions","organizations_url":"https://api.github.com/users/ThomasJClark/orgs","repos_url":"https://api.github.com/users/ThomasJClark/repos","events_url":"https://api.github.com/users/ThomasJClark/events{/privacy}","received_events_url":"https://api.github.com/users/ThomasJClark/received_events","type":"User","site_admin":false},"body":"Points and sizes can be previewed, and the background image in blob/line\r\npreviews can be disabled","created_at":"2015-11-11T22:54:11Z","updated_at":"2015-11-12T00:25:47Z","closed_at":null,"merged_at":null,"merge_commit_sha":"989584fd2e928a2aaede1f126a2a17c409a42cc9","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/130/commits","review_comments_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/130/comments","review_comment_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/comments{/number}","comments_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/130/comments","statuses_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/statuses/5e983057104780a4e7a4bdc71f04e38dfda6e7f8","head":{"label":"ThomasJClark:preview-gui","ref":"preview-gui","sha":"5e983057104780a4e7a4bdc71f04e38dfda6e7f8","user":{"login":"ThomasJClark","id":3964980,"avatar_url":"https://avatars.githubusercontent.com/u/3964980?v=3","gravatar_id":"","url":"https://api.github.com/users/ThomasJClark","html_url":"https://github.com/ThomasJClark","followers_url":"https://api.github.com/users/ThomasJClark/followers","following_url":"https://api.github.com/users/ThomasJClark/following{/other_user}","gists_url":"https://api.github.com/users/ThomasJClark/gists{/gist_id}","starred_url":"https://api.github.com/users/ThomasJClark/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ThomasJClark/subscriptions","organizations_url":"https://api.github.com/users/ThomasJClark/orgs","repos_url":"https://api.github.com/users/ThomasJClark/repos","events_url":"https://api.github.com/users/ThomasJClark/events{/privacy}","received_events_url":"https://api.github.com/users/ThomasJClark/received_events","type":"User","site_admin":false},"repo":{"id":41703859,"name":"GRIP","full_name":"ThomasJClark/GRIP","owner":{"login":"ThomasJClark","id":3964980,"avatar_url":"https://avatars.githubusercontent.com/u/3964980?v=3","gravatar_id":"","url":"https://api.github.com/users/ThomasJClark","html_url":"https://github.com/ThomasJClark","followers_url":"https://api.github.com/users/ThomasJClark/followers","following_url":"https://api.github.com/users/ThomasJClark/following{/other_user}","gists_url":"https://api.github.com/users/ThomasJClark/gists{/gist_id}","starred_url":"https://api.github.com/users/ThomasJClark/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ThomasJClark/subscriptions","organizations_url":"https://api.github.com/users/ThomasJClark/orgs","repos_url":"https://api.github.com/users/ThomasJClark/repos","events_url":"https://api.github.com/users/ThomasJClark/events{/privacy}","received_events_url":"https://api.github.com/users/ThomasJClark/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ThomasJClark/GRIP","description":"Program for rapidly developing computer vision applications","fork":true,"url":"https://api.github.com/repos/ThomasJClark/GRIP","forks_url":"https://api.github.com/repos/ThomasJClark/GRIP/forks","keys_url":"https://api.github.com/repos/ThomasJClark/GRIP/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ThomasJClark/GRIP/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ThomasJClark/GRIP/teams","hooks_url":"https://api.github.com/repos/ThomasJClark/GRIP/hooks","issue_events_url":"https://api.github.com/repos/ThomasJClark/GRIP/issues/events{/number}","events_url":"https://api.github.com/repos/ThomasJClark/GRIP/events","assignees_url":"https://api.github.com/repos/ThomasJClark/GRIP/assignees{/user}","branches_url":"https://api.github.com/repos/ThomasJClark/GRIP/branches{/branch}","tags_url":"https://api.github.com/repos/ThomasJClark/GRIP/tags","blobs_url":"https://api.github.com/repos/ThomasJClark/GRIP/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ThomasJClark/GRIP/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ThomasJClark/GRIP/git/refs{/sha}","trees_url":"https://api.github.com/repos/ThomasJClark/GRIP/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ThomasJClark/GRIP/statuses/{sha}","languages_url":"https://api.github.com/repos/ThomasJClark/GRIP/languages","stargazers_url":"https://api.github.com/repos/ThomasJClark/GRIP/stargazers","contributors_url":"https://api.github.com/repos/ThomasJClark/GRIP/contributors","subscribers_url":"https://api.github.com/repos/ThomasJClark/GRIP/subscribers","subscription_url":"https://api.github.com/repos/ThomasJClark/GRIP/subscription","commits_url":"https://api.github.com/repos/ThomasJClark/GRIP/commits{/sha}","git_commits_url":"https://api.github.com/repos/ThomasJClark/GRIP/git/commits{/sha}","comments_url":"https://api.github.com/repos/ThomasJClark/GRIP/comments{/number}","issue_comment_url":"https://api.github.com/repos/ThomasJClark/GRIP/issues/comments{/number}","contents_url":"https://api.github.com/repos/ThomasJClark/GRIP/contents/{+path}","compare_url":"https://api.github.com/repos/ThomasJClark/GRIP/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ThomasJClark/GRIP/merges","archive_url":"https://api.github.com/repos/ThomasJClark/GRIP/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ThomasJClark/GRIP/downloads","issues_url":"https://api.github.com/repos/ThomasJClark/GRIP/issues{/number}","pulls_url":"https://api.github.com/repos/ThomasJClark/GRIP/pulls{/number}","milestones_url":"https://api.github.com/repos/ThomasJClark/GRIP/milestones{/number}","notifications_url":"https://api.github.com/repos/ThomasJClark/GRIP/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ThomasJClark/GRIP/labels{/name}","releases_url":"https://api.github.com/repos/ThomasJClark/GRIP/releases{/id}","created_at":"2015-08-31T22:30:05Z","updated_at":"2015-10-07T03:27:13Z","pushed_at":"2015-11-12T00:22:09Z","git_url":"git://github.com/ThomasJClark/GRIP.git","ssh_url":"git@github.com:ThomasJClark/GRIP.git","clone_url":"https://github.com/ThomasJClark/GRIP.git","svn_url":"https://github.com/ThomasJClark/GRIP","homepage":"http://wpi.edu","size":2975,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"WPIRoboticsProjects:master","ref":"master","sha":"6024f890774ca66158d24ee7107317c03ed621c0","user":{"login":"WPIRoboticsProjects","id":14004340,"avatar_url":"https://avatars.githubusercontent.com/u/14004340?v=3","gravatar_id":"","url":"https://api.github.com/users/WPIRoboticsProjects","html_url":"https://github.com/WPIRoboticsProjects","followers_url":"https://api.github.com/users/WPIRoboticsProjects/followers","following_url":"https://api.github.com/users/WPIRoboticsProjects/following{/other_user}","gists_url":"https://api.github.com/users/WPIRoboticsProjects/gists{/gist_id}","starred_url":"https://api.github.com/users/WPIRoboticsProjects/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WPIRoboticsProjects/subscriptions","organizations_url":"https://api.github.com/users/WPIRoboticsProjects/orgs","repos_url":"https://api.github.com/users/WPIRoboticsProjects/repos","events_url":"https://api.github.com/users/WPIRoboticsProjects/events{/privacy}","received_events_url":"https://api.github.com/users/WPIRoboticsProjects/received_events","type":"Organization","site_admin":false},"repo":{"id":41505521,"name":"GRIP","full_name":"WPIRoboticsProjects/GRIP","owner":{"login":"WPIRoboticsProjects","id":14004340,"avatar_url":"https://avatars.githubusercontent.com/u/14004340?v=3","gravatar_id":"","url":"https://api.github.com/users/WPIRoboticsProjects","html_url":"https://github.com/WPIRoboticsProjects","followers_url":"https://api.github.com/users/WPIRoboticsProjects/followers","following_url":"https://api.github.com/users/WPIRoboticsProjects/following{/other_user}","gists_url":"https://api.github.com/users/WPIRoboticsProjects/gists{/gist_id}","starred_url":"https://api.github.com/users/WPIRoboticsProjects/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WPIRoboticsProjects/subscriptions","organizations_url":"https://api.github.com/users/WPIRoboticsProjects/orgs","repos_url":"https://api.github.com/users/WPIRoboticsProjects/repos","events_url":"https://api.github.com/users/WPIRoboticsProjects/events{/privacy}","received_events_url":"https://api.github.com/users/WPIRoboticsProjects/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/WPIRoboticsProjects/GRIP","description":"Program for rapidly developing computer vision applications","fork":false,"url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP","forks_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/forks","keys_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/keys{/key_id}","collaborators_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/teams","hooks_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/hooks","issue_events_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/events{/number}","events_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/events","assignees_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/assignees{/user}","branches_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/branches{/branch}","tags_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/tags","blobs_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/git/refs{/sha}","trees_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/git/trees{/sha}","statuses_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/statuses/{sha}","languages_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/languages","stargazers_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/stargazers","contributors_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/contributors","subscribers_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/subscribers","subscription_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/subscription","commits_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/commits{/sha}","git_commits_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/git/commits{/sha}","comments_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/comments{/number}","issue_comment_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/comments{/number}","contents_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/contents/{+path}","compare_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/compare/{base}...{head}","merges_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/merges","archive_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/downloads","issues_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues{/number}","pulls_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls{/number}","milestones_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/milestones{/number}","notifications_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/labels{/name}","releases_url":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/releases{/id}","created_at":"2015-08-27T18:59:07Z","updated_at":"2015-11-08T19:04:41Z","pushed_at":"2015-11-12T00:22:09Z","git_url":"git://github.com/WPIRoboticsProjects/GRIP.git","ssh_url":"git@github.com:WPIRoboticsProjects/GRIP.git","clone_url":"https://github.com/WPIRoboticsProjects/GRIP.git","svn_url":"https://github.com/WPIRoboticsProjects/GRIP","homepage":"http://wpiroboticsprojects.github.io/GRIP","size":9425,"stargazers_count":6,"watchers_count":6,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":5,"mirror_url":null,"open_issues_count":19,"forks":5,"open_issues":19,"watchers":6,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/130"},"html":{"href":"https://github.com/WPIRoboticsProjects/GRIP/pull/130"},"issue":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/130"},"comments":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/issues/130/comments"},"review_comments":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/130/comments"},"review_comment":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/pulls/130/commits"},"statuses":{"href":"https://api.github.com/repos/WPIRoboticsProjects/GRIP/statuses/5e983057104780a4e7a4bdc71f04e38dfda6e7f8"}}}}