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

Unified Diff: chrome/renderer/resources/extensions/web_view.js

Issue 12224094: Browser Plugin: Navigating to the same URL after crash should load a new guest (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed test + bug Created 7 years, 10 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 | chrome/test/data/extensions/platform_apps/web_view/shim/main.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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);
}
};
« no previous file with comments | « no previous file | chrome/test/data/extensions/platform_apps/web_view/shim/main.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698