GitHub PullRequestReviewCommentEvent at 2014-02-24 22:32:53
Repository: WAVED
Actor: seanblue
Payload: {"comment":{"url":"https://api.github.com/repos/KSHSK/WAVED/pulls/comments/10014608","id":10014608,"diff_hunk":"@@ -0,0 +1,53 @@\n+/*global define*/\n+define([\n+        'models/WidgetViewModel',\n+        'models/Property/StringProperty',\n+        'util/defined',\n+        'knockout'\n+    ],function(\n+        WidgetViewModel,\n+        StringProperty,\n+        defined,\n+        ko){\n+    'use strict';\n+\n+    var ButtonWidgetViewModel = function(options) {\n+        options = (defined(options)) ? options : {};\n+        var hasHeight = defined(options.height);\n+        var hasWidth = defined(options.width);\n+        WidgetViewModel.call(this, options);\n+        if (defined(options.label)) {\n+            this.label = options.label;\n+        }\n+        else {\n+            var displayName = 'Label';\n+            this.label = new StringProperty({\n+                displayName: displayName,\n+                value: '',\n+                isValidValue: function(value) {\n+                    return value.length > 0 && value.length < 50;\n+                }\n+            });\n+        }\n+        if (!hasHeight) {\n+            this.height.value = 5;\n+        }\n+        if (!hasWidth) {\n+            this.width.value = 10;\n+        }\n+        ko.track(this);\n+    };\n+\n+    ButtonWidgetViewModel.prototype = Object.create(WidgetViewModel.prototype);\n+\n+    Object.defineProperties(ButtonWidgetViewModel.prototype, {\n+        properties: {\n+            get: function() {\n+                return [this.name, this.label, this.x, this.y, this.height, this.width, this.visible,","path":"Source/models/ButtonWidget/ButtonWidgetViewModel.js","position":46,"original_position":46,"commit_id":"709e87e2b966db0c895a49e13c59b31225834986","original_commit_id":"709e87e2b966db0c895a49e13c59b31225834986","user":{"login":"seanblue","id":5884067,"avatar_url":"https://gravatar.com/avatar/56a2fb3bf7fa47d27a2470273280aacf?d=https%3A%2F%2Fidenticons.github.com%2Fcbc6bf7aea85ec6aa7ffd821b4698ce2.png&r=x","gravatar_id":"56a2fb3bf7fa47d27a2470273280aacf","url":"https://api.github.com/users/seanblue","html_url":"https://github.com/seanblue","followers_url":"https://api.github.com/users/seanblue/followers","following_url":"https://api.github.com/users/seanblue/following{/other_user}","gists_url":"https://api.github.com/users/seanblue/gists{/gist_id}","starred_url":"https://api.github.com/users/seanblue/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seanblue/subscriptions","organizations_url":"https://api.github.com/users/seanblue/orgs","repos_url":"https://api.github.com/users/seanblue/repos","events_url":"https://api.github.com/users/seanblue/events{/privacy}","received_events_url":"https://api.github.com/users/seanblue/received_events","type":"User","site_admin":false},"body":"I think it's the same as your other code that uses `call()`. Like `SuperClass.myFunc.call(this)`. There are tutorials for it, but I can't confirm their reliability.","created_at":"2014-02-24T22:32:53Z","updated_at":"2014-02-24T22:32:53Z","html_url":"https://github.com/KSHSK/WAVED/pull/71#discussion_r10014608","pull_request_url":"https://api.github.com/repos/KSHSK/WAVED/pulls/71","_links":{"self":{"href":"https://api.github.com/repos/KSHSK/WAVED/pulls/comments/10014608"},"html":{"href":"https://github.com/KSHSK/WAVED/pull/71#discussion_r10014608"},"pull_request":{"href":"https://api.github.com/repos/KSHSK/WAVED/pulls/71"}}}}