summaryrefslogtreecommitdiffstats
path: root/content/browser/browser_plugin/browser_plugin_guest.cc
diff options
context:
space:
mode:
authorrouslan@chromium.org <rouslan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-09-09 23:14:42 +0000
committerrouslan@chromium.org <rouslan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-09-09 23:14:42 +0000
commit97efb659d66738fa9b461ecd33f75a78f99278fe (patch)
tree575cc018d81f711492587a359d2a321829fb1033 /content/browser/browser_plugin/browser_plugin_guest.cc
parent629b0d75da698bed10ad473c14e33ae24e59d2ff (diff)
downloadchromium_src-97efb659d66738fa9b461ecd33f75a78f99278fe.zip
chromium_src-97efb659d66738fa9b461ecd33f75a78f99278fe.tar.gz
chromium_src-97efb659d66738fa9b461ecd33f75a78f99278fe.tar.bz2
Revert 222090 "<webview>: Cleanup WebRequest event listeners whe..."
Browser test WebViewTest.Shim_TestWebRequestListenerSurvivesReparenting failed on win xp: http://build.chromium.org/p/chromium.win/builders/XP%20Tests%20%283%29/builds/24239 > <webview>: Cleanup WebRequest event listeners when embedder destroyed > > <webivew> WebRequest event listeners should survive reparenting of the <webview> within the same embedder WebContents. Currently, event listeners are lost when the <webview> is removed from the DOM. This CL solves this problem. > > Note that there is still a problem where custom elements break if the original page that created the element is closed. I have written a test that exercises this problem and I've left the test disabled until we fix the problem. > > BUG=281551 > Test=WebViewTest.Shim_TestWebRequestListenerSurvivesReparenting > > Review URL: https://chromiumcodereview.appspot.com/23514016 TBR=fsamuel@chromium.org Review URL: https://codereview.chromium.org/23965004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@222123 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/browser/browser_plugin/browser_plugin_guest.cc')
-rw-r--r--content/browser/browser_plugin/browser_plugin_guest.cc10
1 files changed, 2 insertions, 8 deletions
diff --git a/content/browser/browser_plugin/browser_plugin_guest.cc b/content/browser/browser_plugin/browser_plugin_guest.cc
index 29a28fc..9408e76 100644
--- a/content/browser/browser_plugin/browser_plugin_guest.cc
+++ b/content/browser/browser_plugin/browser_plugin_guest.cc
@@ -319,7 +319,8 @@ class BrowserPluginGuest::EmbedderRenderViewHostObserver
// RenderViewHostObserver:
virtual void RenderViewHostDestroyed(
RenderViewHost* render_view_host) OVERRIDE {
- browser_plugin_guest_->EmbedderDestroyed();
+ browser_plugin_guest_->embedder_web_contents_ = NULL;
+ browser_plugin_guest_->Destroy();
}
private:
@@ -423,13 +424,6 @@ int BrowserPluginGuest::RequestPermission(
return request_id;
}
-void BrowserPluginGuest::EmbedderDestroyed() {
- embedder_web_contents_ = NULL;
- if (delegate_)
- delegate_->EmbedderDestroyed();
- Destroy();
-}
-
void BrowserPluginGuest::Destroy() {
is_in_destruction_ = true;
if (!attached() && opener())