| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 24 matching lines...) Expand all Loading... |
| 35 * @implements {WebInspector.LayerView} | 35 * @implements {WebInspector.LayerView} |
| 36 */ | 36 */ |
| 37 WebInspector.LayerDetailsView = function(layerViewHost) | 37 WebInspector.LayerDetailsView = function(layerViewHost) |
| 38 { | 38 { |
| 39 WebInspector.Widget.call(this, true); | 39 WebInspector.Widget.call(this, true); |
| 40 this.registerRequiredCSS("layer_viewer/layerDetailsView.css"); | 40 this.registerRequiredCSS("layer_viewer/layerDetailsView.css"); |
| 41 this._layerViewHost = layerViewHost; | 41 this._layerViewHost = layerViewHost; |
| 42 this._layerViewHost.registerView(this); | 42 this._layerViewHost.registerView(this); |
| 43 this._emptyWidget = new WebInspector.EmptyWidget(WebInspector.UIString("Sele
ct a layer to see its details")); | 43 this._emptyWidget = new WebInspector.EmptyWidget(WebInspector.UIString("Sele
ct a layer to see its details")); |
| 44 this._buildContent(); | 44 this._buildContent(); |
| 45 } | 45 }; |
| 46 | 46 |
| 47 /** | 47 /** |
| 48 * @enum {string} | 48 * @enum {string} |
| 49 */ | 49 */ |
| 50 /** @enum {symbol} */ | 50 /** @enum {symbol} */ |
| 51 WebInspector.LayerDetailsView.Events = { | 51 WebInspector.LayerDetailsView.Events = { |
| 52 PaintProfilerRequested: Symbol("PaintProfilerRequested") | 52 PaintProfilerRequested: Symbol("PaintProfilerRequested") |
| 53 } | 53 }; |
| 54 | 54 |
| 55 /** | 55 /** |
| 56 * @type {!Object.<string, string>} | 56 * @type {!Object.<string, string>} |
| 57 */ | 57 */ |
| 58 WebInspector.LayerDetailsView.CompositingReasonDetail = { | 58 WebInspector.LayerDetailsView.CompositingReasonDetail = { |
| 59 "transform3D": WebInspector.UIString("Composition due to association with an
element with a CSS 3D transform."), | 59 "transform3D": WebInspector.UIString("Composition due to association with an
element with a CSS 3D transform."), |
| 60 "video": WebInspector.UIString("Composition due to association with a <video
> element."), | 60 "video": WebInspector.UIString("Composition due to association with a <video
> element."), |
| 61 "canvas": WebInspector.UIString("Composition due to the element being a <can
vas> element."), | 61 "canvas": WebInspector.UIString("Composition due to the element being a <can
vas> element."), |
| 62 "plugin": WebInspector.UIString("Composition due to association with a plugi
n."), | 62 "plugin": WebInspector.UIString("Composition due to association with a plugi
n."), |
| 63 "iFrame": WebInspector.UIString("Composition due to association with an <ifr
ame> element."), | 63 "iFrame": WebInspector.UIString("Composition due to association with an <ifr
ame> element."), |
| (...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 222 for (var i = 0; i < compositingReasons.length; ++i) { | 222 for (var i = 0; i < compositingReasons.length; ++i) { |
| 223 var text = WebInspector.LayerDetailsView.CompositingReasonDetail[com
positingReasons[i]] || compositingReasons[i]; | 223 var text = WebInspector.LayerDetailsView.CompositingReasonDetail[com
positingReasons[i]] || compositingReasons[i]; |
| 224 // If the text is more than one word but does not terminate with per
iod, add the period. | 224 // If the text is more than one word but does not terminate with per
iod, add the period. |
| 225 if (/\s.*[^.]$/.test(text)) | 225 if (/\s.*[^.]$/.test(text)) |
| 226 text += "."; | 226 text += "."; |
| 227 list.createChild("li").textContent = text; | 227 list.createChild("li").textContent = text; |
| 228 } | 228 } |
| 229 }, | 229 }, |
| 230 | 230 |
| 231 __proto__: WebInspector.Widget.prototype | 231 __proto__: WebInspector.Widget.prototype |
| 232 } | 232 }; |
| OLD | NEW |