| Index: extensions/renderer/resources/guest_view/web_view/web_view.js
|
| diff --git a/extensions/renderer/resources/guest_view/web_view/web_view.js b/extensions/renderer/resources/guest_view/web_view/web_view.js
|
| index 1b40d156f2ef994b235fb4ed3f581d6d8aafa698..d1d367769a13f69ace45ac0717029eaa91edad3b 100644
|
| --- a/extensions/renderer/resources/guest_view/web_view/web_view.js
|
| +++ b/extensions/renderer/resources/guest_view/web_view/web_view.js
|
| @@ -55,6 +55,10 @@ WebViewImpl.setupElement = function(proto) {
|
|
|
| // Initiates navigation once the <webview> element is attached to the DOM.
|
| WebViewImpl.prototype.onElementAttached = function() {
|
| + // Mark all attributes as dirty on attachment.
|
| + for (var i in this.attributes) {
|
| + this.attributes[i].dirty = true;
|
| + }
|
| for (var i in this.attributes) {
|
| this.attributes[i].attach();
|
| }
|
| @@ -64,6 +68,9 @@ WebViewImpl.prototype.onElementAttached = function() {
|
| WebViewImpl.prototype.onElementDetached = function() {
|
| this.guest.destroy();
|
| for (var i in this.attributes) {
|
| + this.attributes[i].dirty = false;
|
| + }
|
| + for (var i in this.attributes) {
|
| this.attributes[i].detach();
|
| }
|
| };
|
| @@ -167,7 +174,9 @@ WebViewImpl.prototype.onAttach = function(storagePartitionId) {
|
| WebViewImpl.prototype.buildContainerParams = function() {
|
| var params = { 'userAgentOverride': this.userAgentOverride };
|
| for (var i in this.attributes) {
|
| - params[i] = this.attributes[i].getValue();
|
| + var value = this.attributes[i].getValueIfDirty();
|
| + if (value)
|
| + params[i] = value;
|
| }
|
| return params;
|
| };
|
|
|