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

Unified Diff: extensions/renderer/resources/guest_view/guest_view_container.js

Issue 1017863007: Refactored the attributes modules of extension_view and web_view into guest_view_attributes.js. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed comment. Created 5 years, 9 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
Index: extensions/renderer/resources/guest_view/guest_view_container.js
diff --git a/extensions/renderer/resources/guest_view/guest_view_container.js b/extensions/renderer/resources/guest_view/guest_view_container.js
index d1725d31fa37afb0f79b0caccd6c8f7c697525a1..3a3f837c7ad46d64f0183113d3aa63acc50158d7 100644
--- a/extensions/renderer/resources/guest_view/guest_view_container.js
+++ b/extensions/renderer/resources/guest_view/guest_view_container.js
@@ -168,11 +168,11 @@ GuestViewContainer.prototype.dispatchEvent = function(event) {
// Implemented by the specific view type, if needed.
GuestViewContainer.prototype.buildContainerParams = function() { return {}; };
-GuestViewContainer.prototype.handleAttributeMutation = function() {};
+// TODO(paulmeyer): remove once all view types use attribute objects.
+GuestViewContainer.prototype.handleAttributeMutation = function(
+ attributeName, oldValue, newValue) {};
GuestViewContainer.prototype.onElementAttached = function() {};
-GuestViewContainer.prototype.onElementDetached = function() {
- this.guest.destroy();
-};
+GuestViewContainer.prototype.onElementDetached = function() {};
// Registers the browser plugin <object> custom element. |viewType| is the
// name of the specific guestview container (e.g. 'webview').
@@ -243,6 +243,7 @@ function registerGuestViewElement(guestViewContainerType) {
}
internal.elementAttached = false;
internal.internalInstanceId = 0;
+ internal.guest.destroy();
internal.onElementDetached();
};

Powered by Google App Engine
This is Rietveld 408576698