From 950647690b6434024c2a975b7745627fbff799dc Mon Sep 17 00:00:00 2001 From: "dcheng@chromium.org" Date: Wed, 16 Jul 2014 18:40:00 +0000 Subject: Remove redundant WebContents field in WebContentsObserver implementation BUG=none Review URL: https://codereview.chromium.org/396743002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@283453 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/dom_distiller/tab_utils.cc | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'chrome/browser/dom_distiller') diff --git a/chrome/browser/dom_distiller/tab_utils.cc b/chrome/browser/dom_distiller/tab_utils.cc index 1fbcd3f..7ddd29c 100644 --- a/chrome/browser/dom_distiller/tab_utils.cc +++ b/chrome/browser/dom_distiller/tab_utils.cc @@ -61,9 +61,6 @@ class SelfDeletingRequestDelegate : public ViewRequestDelegate, // The handle to the view request towards the DomDistillerService. It // needs to be kept around to ensure the distillation request finishes. scoped_ptr viewer_handle_; - - // The WebContents this class is tracking. - content::WebContents* web_contents_; }; void SelfDeletingRequestDelegate::DidNavigateMainFrame( @@ -83,12 +80,10 @@ void SelfDeletingRequestDelegate::WebContentsDestroyed() { SelfDeletingRequestDelegate::SelfDeletingRequestDelegate( content::WebContents* web_contents) - : web_contents_(web_contents) { - content::WebContentsObserver::Observe(web_contents_); + : WebContentsObserver(web_contents) { } SelfDeletingRequestDelegate::~SelfDeletingRequestDelegate() { - content::WebContentsObserver::Observe(NULL); } void SelfDeletingRequestDelegate::OnArticleReady( -- cgit v1.1