{"action":"created","comment":{"url":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/comments/55359381","id":55359381,"diff_hunk":"@@ -0,0 +1,609 @@\n+package org.scalajs.dom.experimental\n+\n+import org.scalajs.dom.raw.{WebGLShader, WebGLRenderingContext}\n+import scala.scalajs.js\n+\n+package object webgl {\n+  /**\n+    * Abstract class that maps a string enum onto a WebGL extension type\n+    *\n+    * @param value the string enum to pass the underlying `getExtension`\n+    * @tparam T the type that will be returned by the `getExtension`\n+    */\n+  abstract class WebGLExtensionIdentifier[T](val value: String)\n+\n+  /**\n+    * Provides 32-bit floating point texture support.\n+    * (Khronos Extension)\n+    *\n+    * @see https://www.khronos.org/registry/webgl/extensions/OES_texture_float/\n+    */\n+  case object OES_texture_float\n+    extends WebGLExtensionIdentifier[extensions.OESTextureFloat](\"OES_texture_float\")","path":"src/main/scala/org/scalajs/dom/experimental/WebGL.scala","position":22,"original_position":22,"commit_id":"ccd9599b27654a92db352b30bbb067cadd259a9f","original_commit_id":"ccd9599b27654a92db352b30bbb067cadd259a9f","user":{"login":"sjrd","id":535934,"avatar_url":"https://avatars.githubusercontent.com/u/535934?v=3","gravatar_id":"","url":"https://api.github.com/users/sjrd","html_url":"https://github.com/sjrd","followers_url":"https://api.github.com/users/sjrd/followers","following_url":"https://api.github.com/users/sjrd/following{/other_user}","gists_url":"https://api.github.com/users/sjrd/gists{/gist_id}","starred_url":"https://api.github.com/users/sjrd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sjrd/subscriptions","organizations_url":"https://api.github.com/users/sjrd/orgs","repos_url":"https://api.github.com/users/sjrd/repos","events_url":"https://api.github.com/users/sjrd/events{/privacy}","received_events_url":"https://api.github.com/users/sjrd/received_events","type":"User","site_admin":false},"body":"Here the preferred indentation would be 4 spaces before `extends`, and also break after the `(`:\r\n```scala\r\ncase object OES_texture_float\r\n    extends WebGLExtensionIdentifier[extensions.OESTextureFloat](\r\n    \"OES_texture_float\")\r\n```","created_at":"2016-03-08T13:42:28Z","updated_at":"2016-03-08T13:42:28Z","html_url":"https://github.com/scala-js/scala-js-dom/pull/197#discussion_r55359381","pull_request_url":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/197","_links":{"self":{"href":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/comments/55359381"},"html":{"href":"https://github.com/scala-js/scala-js-dom/pull/197#discussion_r55359381"},"pull_request":{"href":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/197"}}},"pull_request":{"url":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/197","id":55000446,"html_url":"https://github.com/scala-js/scala-js-dom/pull/197","diff_url":"https://github.com/scala-js/scala-js-dom/pull/197.diff","patch_url":"https://github.com/scala-js/scala-js-dom/pull/197.patch","issue_url":"https://api.github.com/repos/scala-js/scala-js-dom/issues/197","number":197,"state":"open","locked":false,"title":"Add WebGL Extensions","user":{"login":"mseddon","id":4021991,"avatar_url":"https://avatars.githubusercontent.com/u/4021991?v=3","gravatar_id":"","url":"https://api.github.com/users/mseddon","html_url":"https://github.com/mseddon","followers_url":"https://api.github.com/users/mseddon/followers","following_url":"https://api.github.com/users/mseddon/following{/other_user}","gists_url":"https://api.github.com/users/mseddon/gists{/gist_id}","starred_url":"https://api.github.com/users/mseddon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mseddon/subscriptions","organizations_url":"https://api.github.com/users/mseddon/orgs","repos_url":"https://api.github.com/users/mseddon/repos","events_url":"https://api.github.com/users/mseddon/events{/privacy}","received_events_url":"https://api.github.com/users/mseddon/received_events","type":"User","site_admin":false},"body":"This is a WIP WebGL extensions patch for general comment (actual facades currently untested).\r\n\r\n1. Is the typing with case objects used here the most succinct way to do it?\r\n2. Is returning `Option[ExtensionType]` in the `getExtension` pimp sensible, or should we just allow it to return `null` references?\r\n3. Since WebGL exposes the `getExtension` method, should this even BE in `experimental`, or should we import this stuff in along with `org.scalajs.dom.webgl`? `getExtension`, by definition, is going to successfully return any given extension based on the combination of video driver version, browser version and operation system, so you really never know what will happen until you try it.","created_at":"2016-01-04T17:33:25Z","updated_at":"2016-03-08T13:42:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"827a21a6537fc9e02ae535347849ea2c3bcdb7d5","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/197/commits","review_comments_url":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/197/comments","review_comment_url":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/comments{/number}","comments_url":"https://api.github.com/repos/scala-js/scala-js-dom/issues/197/comments","statuses_url":"https://api.github.com/repos/scala-js/scala-js-dom/statuses/ccd9599b27654a92db352b30bbb067cadd259a9f","head":{"label":"mseddon:webgl-extensions","ref":"webgl-extensions","sha":"ccd9599b27654a92db352b30bbb067cadd259a9f","user":{"login":"mseddon","id":4021991,"avatar_url":"https://avatars.githubusercontent.com/u/4021991?v=3","gravatar_id":"","url":"https://api.github.com/users/mseddon","html_url":"https://github.com/mseddon","followers_url":"https://api.github.com/users/mseddon/followers","following_url":"https://api.github.com/users/mseddon/following{/other_user}","gists_url":"https://api.github.com/users/mseddon/gists{/gist_id}","starred_url":"https://api.github.com/users/mseddon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mseddon/subscriptions","organizations_url":"https://api.github.com/users/mseddon/orgs","repos_url":"https://api.github.com/users/mseddon/repos","events_url":"https://api.github.com/users/mseddon/events{/privacy}","received_events_url":"https://api.github.com/users/mseddon/received_events","type":"User","site_admin":false},"repo":{"id":35538956,"name":"scala-js-dom","full_name":"mseddon/scala-js-dom","owner":{"login":"mseddon","id":4021991,"avatar_url":"https://avatars.githubusercontent.com/u/4021991?v=3","gravatar_id":"","url":"https://api.github.com/users/mseddon","html_url":"https://github.com/mseddon","followers_url":"https://api.github.com/users/mseddon/followers","following_url":"https://api.github.com/users/mseddon/following{/other_user}","gists_url":"https://api.github.com/users/mseddon/gists{/gist_id}","starred_url":"https://api.github.com/users/mseddon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mseddon/subscriptions","organizations_url":"https://api.github.com/users/mseddon/orgs","repos_url":"https://api.github.com/users/mseddon/repos","events_url":"https://api.github.com/users/mseddon/events{/privacy}","received_events_url":"https://api.github.com/users/mseddon/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mseddon/scala-js-dom","description":"statically typed dom wrappers for scala-js","fork":true,"url":"https://api.github.com/repos/mseddon/scala-js-dom","forks_url":"https://api.github.com/repos/mseddon/scala-js-dom/forks","keys_url":"https://api.github.com/repos/mseddon/scala-js-dom/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mseddon/scala-js-dom/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mseddon/scala-js-dom/teams","hooks_url":"https://api.github.com/repos/mseddon/scala-js-dom/hooks","issue_events_url":"https://api.github.com/repos/mseddon/scala-js-dom/issues/events{/number}","events_url":"https://api.github.com/repos/mseddon/scala-js-dom/events","assignees_url":"https://api.github.com/repos/mseddon/scala-js-dom/assignees{/user}","branches_url":"https://api.github.com/repos/mseddon/scala-js-dom/branches{/branch}","tags_url":"https://api.github.com/repos/mseddon/scala-js-dom/tags","blobs_url":"https://api.github.com/repos/mseddon/scala-js-dom/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mseddon/scala-js-dom/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mseddon/scala-js-dom/git/refs{/sha}","trees_url":"https://api.github.com/repos/mseddon/scala-js-dom/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mseddon/scala-js-dom/statuses/{sha}","languages_url":"https://api.github.com/repos/mseddon/scala-js-dom/languages","stargazers_url":"https://api.github.com/repos/mseddon/scala-js-dom/stargazers","contributors_url":"https://api.github.com/repos/mseddon/scala-js-dom/contributors","subscribers_url":"https://api.github.com/repos/mseddon/scala-js-dom/subscribers","subscription_url":"https://api.github.com/repos/mseddon/scala-js-dom/subscription","commits_url":"https://api.github.com/repos/mseddon/scala-js-dom/commits{/sha}","git_commits_url":"https://api.github.com/repos/mseddon/scala-js-dom/git/commits{/sha}","comments_url":"https://api.github.com/repos/mseddon/scala-js-dom/comments{/number}","issue_comment_url":"https://api.github.com/repos/mseddon/scala-js-dom/issues/comments{/number}","contents_url":"https://api.github.com/repos/mseddon/scala-js-dom/contents/{+path}","compare_url":"https://api.github.com/repos/mseddon/scala-js-dom/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mseddon/scala-js-dom/merges","archive_url":"https://api.github.com/repos/mseddon/scala-js-dom/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mseddon/scala-js-dom/downloads","issues_url":"https://api.github.com/repos/mseddon/scala-js-dom/issues{/number}","pulls_url":"https://api.github.com/repos/mseddon/scala-js-dom/pulls{/number}","milestones_url":"https://api.github.com/repos/mseddon/scala-js-dom/milestones{/number}","notifications_url":"https://api.github.com/repos/mseddon/scala-js-dom/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mseddon/scala-js-dom/labels{/name}","releases_url":"https://api.github.com/repos/mseddon/scala-js-dom/releases{/id}","deployments_url":"https://api.github.com/repos/mseddon/scala-js-dom/deployments","created_at":"2015-05-13T09:04:03Z","updated_at":"2016-01-21T11:21:59Z","pushed_at":"2016-03-08T13:31:10Z","git_url":"git://github.com/mseddon/scala-js-dom.git","ssh_url":"git@github.com:mseddon/scala-js-dom.git","clone_url":"https://github.com/mseddon/scala-js-dom.git","svn_url":"https://github.com/mseddon/scala-js-dom","homepage":null,"size":2160,"stargazers_count":0,"watchers_count":0,"language":"Scala","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":"scala-js:master","ref":"master","sha":"8647b75e5e9301634b1e44fbf9ebc309c7120463","user":{"login":"scala-js","id":6039724,"avatar_url":"https://avatars.githubusercontent.com/u/6039724?v=3","gravatar_id":"","url":"https://api.github.com/users/scala-js","html_url":"https://github.com/scala-js","followers_url":"https://api.github.com/users/scala-js/followers","following_url":"https://api.github.com/users/scala-js/following{/other_user}","gists_url":"https://api.github.com/users/scala-js/gists{/gist_id}","starred_url":"https://api.github.com/users/scala-js/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scala-js/subscriptions","organizations_url":"https://api.github.com/users/scala-js/orgs","repos_url":"https://api.github.com/users/scala-js/repos","events_url":"https://api.github.com/users/scala-js/events{/privacy}","received_events_url":"https://api.github.com/users/scala-js/received_events","type":"Organization","site_admin":false},"repo":{"id":13578796,"name":"scala-js-dom","full_name":"scala-js/scala-js-dom","owner":{"login":"scala-js","id":6039724,"avatar_url":"https://avatars.githubusercontent.com/u/6039724?v=3","gravatar_id":"","url":"https://api.github.com/users/scala-js","html_url":"https://github.com/scala-js","followers_url":"https://api.github.com/users/scala-js/followers","following_url":"https://api.github.com/users/scala-js/following{/other_user}","gists_url":"https://api.github.com/users/scala-js/gists{/gist_id}","starred_url":"https://api.github.com/users/scala-js/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scala-js/subscriptions","organizations_url":"https://api.github.com/users/scala-js/orgs","repos_url":"https://api.github.com/users/scala-js/repos","events_url":"https://api.github.com/users/scala-js/events{/privacy}","received_events_url":"https://api.github.com/users/scala-js/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/scala-js/scala-js-dom","description":"statically typed dom wrappers for scala-js","fork":false,"url":"https://api.github.com/repos/scala-js/scala-js-dom","forks_url":"https://api.github.com/repos/scala-js/scala-js-dom/forks","keys_url":"https://api.github.com/repos/scala-js/scala-js-dom/keys{/key_id}","collaborators_url":"https://api.github.com/repos/scala-js/scala-js-dom/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/scala-js/scala-js-dom/teams","hooks_url":"https://api.github.com/repos/scala-js/scala-js-dom/hooks","issue_events_url":"https://api.github.com/repos/scala-js/scala-js-dom/issues/events{/number}","events_url":"https://api.github.com/repos/scala-js/scala-js-dom/events","assignees_url":"https://api.github.com/repos/scala-js/scala-js-dom/assignees{/user}","branches_url":"https://api.github.com/repos/scala-js/scala-js-dom/branches{/branch}","tags_url":"https://api.github.com/repos/scala-js/scala-js-dom/tags","blobs_url":"https://api.github.com/repos/scala-js/scala-js-dom/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/scala-js/scala-js-dom/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/scala-js/scala-js-dom/git/refs{/sha}","trees_url":"https://api.github.com/repos/scala-js/scala-js-dom/git/trees{/sha}","statuses_url":"https://api.github.com/repos/scala-js/scala-js-dom/statuses/{sha}","languages_url":"https://api.github.com/repos/scala-js/scala-js-dom/languages","stargazers_url":"https://api.github.com/repos/scala-js/scala-js-dom/stargazers","contributors_url":"https://api.github.com/repos/scala-js/scala-js-dom/contributors","subscribers_url":"https://api.github.com/repos/scala-js/scala-js-dom/subscribers","subscription_url":"https://api.github.com/repos/scala-js/scala-js-dom/subscription","commits_url":"https://api.github.com/repos/scala-js/scala-js-dom/commits{/sha}","git_commits_url":"https://api.github.com/repos/scala-js/scala-js-dom/git/commits{/sha}","comments_url":"https://api.github.com/repos/scala-js/scala-js-dom/comments{/number}","issue_comment_url":"https://api.github.com/repos/scala-js/scala-js-dom/issues/comments{/number}","contents_url":"https://api.github.com/repos/scala-js/scala-js-dom/contents/{+path}","compare_url":"https://api.github.com/repos/scala-js/scala-js-dom/compare/{base}...{head}","merges_url":"https://api.github.com/repos/scala-js/scala-js-dom/merges","archive_url":"https://api.github.com/repos/scala-js/scala-js-dom/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/scala-js/scala-js-dom/downloads","issues_url":"https://api.github.com/repos/scala-js/scala-js-dom/issues{/number}","pulls_url":"https://api.github.com/repos/scala-js/scala-js-dom/pulls{/number}","milestones_url":"https://api.github.com/repos/scala-js/scala-js-dom/milestones{/number}","notifications_url":"https://api.github.com/repos/scala-js/scala-js-dom/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/scala-js/scala-js-dom/labels{/name}","releases_url":"https://api.github.com/repos/scala-js/scala-js-dom/releases{/id}","deployments_url":"https://api.github.com/repos/scala-js/scala-js-dom/deployments","created_at":"2013-10-15T02:35:07Z","updated_at":"2016-02-16T08:30:02Z","pushed_at":"2016-03-08T13:31:10Z","git_url":"git://github.com/scala-js/scala-js-dom.git","ssh_url":"git@github.com:scala-js/scala-js-dom.git","clone_url":"https://github.com/scala-js/scala-js-dom.git","svn_url":"https://github.com/scala-js/scala-js-dom","homepage":null,"size":2316,"stargazers_count":110,"watchers_count":110,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":53,"mirror_url":null,"open_issues_count":10,"forks":53,"open_issues":10,"watchers":110,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/197"},"html":{"href":"https://github.com/scala-js/scala-js-dom/pull/197"},"issue":{"href":"https://api.github.com/repos/scala-js/scala-js-dom/issues/197"},"comments":{"href":"https://api.github.com/repos/scala-js/scala-js-dom/issues/197/comments"},"review_comments":{"href":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/197/comments"},"review_comment":{"href":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/scala-js/scala-js-dom/pulls/197/commits"},"statuses":{"href":"https://api.github.com/repos/scala-js/scala-js-dom/statuses/ccd9599b27654a92db352b30bbb067cadd259a9f"}}}}