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

Unified Diff: components/autofill/browser/autofill_external_delegate.h

Issue 17225008: Eliminate AutofillExternalDelegate being a WebContentsUserData (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Response to review Created 7 years, 6 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: components/autofill/browser/autofill_external_delegate.h
diff --git a/components/autofill/browser/autofill_external_delegate.h b/components/autofill/browser/autofill_external_delegate.h
index 1e1acef79650b6b815661f8159ad28d2f11ed757..cbf5f9dc5dcb0a85563f7f5013b20075a3152599 100644
--- a/components/autofill/browser/autofill_external_delegate.h
+++ b/components/autofill/browser/autofill_external_delegate.h
@@ -17,7 +17,6 @@
#include "components/autofill/common/password_form_fill_data.h"
#include "content/public/browser/notification_observer.h"
#include "content/public/browser/notification_registrar.h"
-#include "content/public/browser/web_contents_user_data.h"
#include "ui/gfx/rect.h"
namespace gfx {
@@ -25,6 +24,7 @@ class Rect;
}
namespace content {
+class RenderViewHost;
class WebContents;
}
@@ -38,15 +38,14 @@ class AutofillManager;
// Delegate for in-browser Autocomplete and Autofill display and selection.
class AutofillExternalDelegate
- : public content::WebContentsUserData<AutofillExternalDelegate>,
- public content::NotificationObserver,
+ : public content::NotificationObserver,
public AutofillPopupDelegate {
public:
- // Creates an AutofillExternalDelegate and attaches it to the specified
- // contents; the second argument is an AutofillManager managing Autofill for
- // that WebContents.
- static void CreateForWebContentsAndManager(content::WebContents* web_contents,
- AutofillManager* autofill_manager);
+ // Creates an AutofillExternalDelegate for the specified contents; the second
+ // argument is an AutofillManager managing Autofill for that WebContents.
+ AutofillExternalDelegate(content::WebContents* web_contents,
+ AutofillManager* autofill_manager);
+ virtual ~AutofillExternalDelegate();
// AutofillPopupDelegate implementation.
virtual void OnPopupShown(content::KeyboardListener* listener) OVERRIDE;
@@ -106,11 +105,6 @@ class AutofillExternalDelegate
const PasswordFormFillData& fill_data);
protected:
- friend class content::WebContentsUserData<AutofillExternalDelegate>;
- AutofillExternalDelegate(content::WebContents* web_contents,
- AutofillManager* autofill_manager);
- virtual ~AutofillExternalDelegate();
-
content::WebContents* web_contents() { return web_contents_; }
base::WeakPtr<AutofillExternalDelegate> GetWeakPtr();
« no previous file with comments | « chrome/browser/autofill/autofill_interactive_uitest.cc ('k') | components/autofill/browser/autofill_external_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698