Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(599)

Unified Diff: third_party/WebKit/Source/devtools/front_end/elements/PropertiesWidget.js

Issue 2978713002: DevTools: migrate PropertiesWidget to shadow (Closed)
Patch Set: rebase Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/devtools/front_end/elements/elementsPanel.css » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/devtools/front_end/elements/PropertiesWidget.js
diff --git a/third_party/WebKit/Source/devtools/front_end/elements/PropertiesWidget.js b/third_party/WebKit/Source/devtools/front_end/elements/PropertiesWidget.js
index f20b517a7e4de6ef524d0721b2815c951fc2ba76..04dca765058e115de212fead2c9878352b0048a4 100644
--- a/third_party/WebKit/Source/devtools/front_end/elements/PropertiesWidget.js
+++ b/third_party/WebKit/Source/devtools/front_end/elements/PropertiesWidget.js
@@ -32,7 +32,8 @@
*/
Elements.PropertiesWidget = class extends UI.ThrottledWidget {
constructor() {
- super();
+ super(true /* isWebComponent */);
+ this.registerRequiredCSS('elements/propertiesWidget.css');
SDK.targetManager.addModelListener(SDK.DOMModel, SDK.DOMModel.Events.AttrModified, this._onNodeChange, this);
SDK.targetManager.addModelListener(SDK.DOMModel, SDK.DOMModel.Events.AttrRemoved, this._onNodeChange, this);
@@ -65,7 +66,7 @@ Elements.PropertiesWidget = class extends UI.ThrottledWidget {
}
if (!this._node) {
- this.element.removeChildren();
+ this.contentElement.removeChildren();
this.sections = [];
return Promise.resolve();
}
@@ -127,7 +128,7 @@ Elements.PropertiesWidget = class extends UI.ThrottledWidget {
for (var i = 0; i < sections.length; ++i)
expanded.push(sections[i].expanded);
- this.element.removeChildren();
+ this.contentElement.removeChildren();
this.sections = [];
// Get array of property user-friendly names.
@@ -140,7 +141,7 @@ Elements.PropertiesWidget = class extends UI.ThrottledWidget {
var section = new ObjectUI.ObjectPropertiesSection(property, title);
section.element.classList.add('properties-widget-section');
this.sections.push(section);
- this.element.appendChild(section.element);
+ this.contentElement.appendChild(section.element);
if (expanded[this.sections.length - 1])
section.expand();
section.addEventListener(UI.TreeOutline.Events.ElementExpanded, this._propertyExpanded, this);
« no previous file with comments | « no previous file | third_party/WebKit/Source/devtools/front_end/elements/elementsPanel.css » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698