summaryrefslogtreecommitdiffstats
path: root/webkit/glue/devtools/js/devtools.js
diff options
context:
space:
mode:
Diffstat (limited to 'webkit/glue/devtools/js/devtools.js')
-rw-r--r--webkit/glue/devtools/js/devtools.js23
1 files changed, 20 insertions, 3 deletions
diff --git a/webkit/glue/devtools/js/devtools.js b/webkit/glue/devtools/js/devtools.js
index 972ca02..2d387e4 100644
--- a/webkit/glue/devtools/js/devtools.js
+++ b/webkit/glue/devtools/js/devtools.js
@@ -564,12 +564,29 @@ WebInspector.ScopeChainSidebarPane.TreeElement.prototype.didResolveChildren_ =
*/
WebInspector.StylePropertyTreeElement.prototype.toggleEnabled =
function(event) {
- var disabled = !event.target.checked;
- var self = this;
- devtools.tools.getDomAgent().toggleNodeStyleAsync(this.style, !disabled,
+ var enabled = event.target.checked;
+ devtools.tools.getDomAgent().toggleNodeStyleAsync(
+ this.style,
+ enabled,
this.name,
function() {
WebInspector.panels.elements.sidebarPanes.styles.needsUpdate = true;
WebInspector.panels.elements.updateStyles(true);
});
};
+
+
+/**
+ * @override
+ */
+WebInspector.StylePropertyTreeElement.prototype.applyStyleText = function(
+ styleText, updateInterface) {
+ devtools.tools.getDomAgent().applyStyleTextAsync(this.style, this.name,
+ styleText,
+ function() {
+ if (updateInterface) {
+ WebInspector.panels.elements.sidebarPanes.styles.needsUpdate = true;
+ WebInspector.panels.elements.updateStyles(true);
+ }
+ });
+};