diff options
Diffstat (limited to 'chromium/third_party/catapult/tracing/tracing/value/diagnostics/generic.html')
-rw-r--r-- | chromium/third_party/catapult/tracing/tracing/value/diagnostics/generic.html | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/chromium/third_party/catapult/tracing/tracing/value/diagnostics/generic.html b/chromium/third_party/catapult/tracing/tracing/value/diagnostics/generic.html index 7ac19796e34..fae4fdd3119 100644 --- a/chromium/third_party/catapult/tracing/tracing/value/diagnostics/generic.html +++ b/chromium/third_party/catapult/tracing/tracing/value/diagnostics/generic.html @@ -15,25 +15,24 @@ tr.exportTo('tr.v.d', function() { * A Generic diagnostic can contain any Plain-Ol'-Data objects that can be * serialized using JSON.stringify(): null, boolean, number, string, array, * dict. Generic diagnostics cannot contain tr.v.Value objects! - * - * @constructor - * @param {*} value */ - function Generic(value) { - this.value = value; - } - - Generic.prototype = { - __proto__: tr.v.d.Diagnostic.prototype, + class Generic extends tr.v.d.Diagnostic { + /** + * @param {*} value + */ + constructor(value) { + super(); + this.value = value; + } - asDictInto_: function(d) { + asDictInto_(d) { d.value = this.value; } - }; - Generic.fromDict = function(d) { - return new Generic(d.value); - }; + static fromDict(d) { + return new Generic(d.value); + } + } tr.v.d.Diagnostic.register(Generic, { elementName: 'tr-v-ui-generic-diagnostic-span' |