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

Side by Side Diff: chrome/browser/autofill/api/autofill_client.h

Issue 10837363: Introduce AutofillClient and use it to get rid of PasswordManager dependency. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_AUTOFILL_API_AUTOFILL_CLIENT_H_
6 #define CHROME_BROWSER_AUTOFILL_API_AUTOFILL_CLIENT_H_
7
8 class InfoBarTabService;
9 class PrefServiceBase;
10
11 namespace autofill {
12
13 // A delegate interface that needs to be supplied to AutofillManager
14 // by the embedder.
15 //
16 // Each client instance is associated with a given context within
17 // which an AutofillManager is used (e.g. a single tab), so when we
18 // say "for the client" below, we mean "in the execution context the
19 // client is associated with" (e.g. for the tab the AutofillManager is
20 // attached to).
21 class AutofillClient {
Ilya Sherman 2012/08/22 03:38:03 Hmm, this seems like it is more of a host than a c
22 public:
23 virtual ~AutofillClient() {}
24
25 // Gets the infobar service associated with the client.
26 //
27 // TODO(joi): Given the approach (which we will likely use more
28 // widely) of a context associated with the instance of the client,
29 // it seems right to rename InfoBarTabService to just
30 // InfoBarService. Naming the getter appropriately, will name the
31 // class itself in a follow-up change.
32 virtual InfoBarTabService* GetInfoBarService() = 0;
33
34 // Gets the preferences associated with the client.
35 virtual PrefServiceBase* GetPrefs() = 0;
36
37 // Returns true if saving passwords is currently enabled for the
38 // client.
39 virtual bool IsSavingPasswordsEnabled() = 0;
40 };
41
42 } // namespace autofill
43
44 #endif // CHROME_BROWSER_AUTOFILL_API_AUTOFILL_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698