Index: chrome/renderer/resources/extensions/web_view.js |
diff --git a/chrome/renderer/resources/extensions/web_view.js b/chrome/renderer/resources/extensions/web_view.js |
index 73f4f1af30fd11ea1ec80dd466bb55b15eb1b0c0..79ca09a06fbf55c68483849a3ab2144babae75f8 100644 |
--- a/chrome/renderer/resources/extensions/web_view.js |
+++ b/chrome/renderer/resources/extensions/web_view.js |
@@ -156,8 +156,10 @@ WebView.prototype.handleObjectMutation_ = function(mutation) { |
this.node_.removeAttribute(mutation.attributeName); |
} else { |
// Update the <webview> attribute to match the BrowserPlugin attribute. |
- this.node_.setAttribute(mutation.attributeName, |
- this.objectNode_.getAttribute(mutation.attributeName)); |
+ var oldValue = this.node_.getAttribute(mutation.attributeName); |
+ var newValue = this.objectNode_.getAttribute(mutation.attributeName); |
+ if (newValue != oldValue) |
lazyboy
2013/02/12 21:50:37
Needs {} around if block.
Can you also add a note
|
+ this.node_.setAttribute(mutation.attributeName, newValue); |
} |
}; |