Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_AUTOFILL_MANAGER_H_ | 5 #ifndef COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_AUTOFILL_MANAGER_H_ |
| 6 #define COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_AUTOFILL_MANAGER_H_ | 6 #define COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_AUTOFILL_MANAGER_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "base/gtest_prod_util.h" | 10 #include "base/gtest_prod_util.h" |
| 11 #include "base/i18n/rtl.h" | 11 #include "base/i18n/rtl.h" |
| 12 #include "components/autofill/core/browser/autofill_client.h" | 12 #include "components/autofill/core/browser/autofill_client.h" |
| 13 #include "components/autofill/core/browser/autofill_popup_delegate.h" | 13 #include "components/autofill/core/browser/autofill_popup_delegate.h" |
| 14 #include "components/autofill/core/common/autofill_constants.h" | |
|
Garrett Casto
2014/12/05 19:30:54
Should include this in the cc file instead.
jww
2014/12/05 20:23:10
Done.
| |
| 14 #include "components/autofill/core/common/password_form_fill_data.h" | 15 #include "components/autofill/core/common/password_form_fill_data.h" |
| 15 | 16 |
| 16 namespace gfx { | 17 namespace gfx { |
| 17 class RectF; | 18 class RectF; |
| 18 } | 19 } |
| 19 | 20 |
| 20 namespace password_manager { | 21 namespace password_manager { |
| 21 | 22 |
| 22 class PasswordManagerClient; | 23 class PasswordManagerClient; |
| 23 class PasswordManagerDriver; | 24 class PasswordManagerDriver; |
| (...skipping 15 matching lines...) Expand all Loading... | |
| 39 int identifier) override; | 40 int identifier) override; |
| 40 void RemoveSuggestion(const base::string16& value, int identifier) override; | 41 void RemoveSuggestion(const base::string16& value, int identifier) override; |
| 41 void ClearPreviewedForm() override; | 42 void ClearPreviewedForm() override; |
| 42 | 43 |
| 43 // Invoked when a password mapping is added. | 44 // Invoked when a password mapping is added. |
| 44 void OnAddPasswordFormMapping( | 45 void OnAddPasswordFormMapping( |
| 45 int key, | 46 int key, |
| 46 const autofill::PasswordFormFillData& fill_data); | 47 const autofill::PasswordFormFillData& fill_data); |
| 47 | 48 |
| 48 // Handles a request from the renderer to show a popup with the given | 49 // Handles a request from the renderer to show a popup with the given |
| 49 // |suggestions| from the password manager. | 50 // |suggestions| from the password manager. |options| should be a bitwise mask |
| 51 // of autofill::ShowPasswordSuggestionsOptions values. | |
| 50 void OnShowPasswordSuggestions(int key, | 52 void OnShowPasswordSuggestions(int key, |
| 51 base::i18n::TextDirection text_direction, | 53 base::i18n::TextDirection text_direction, |
| 52 const base::string16& typed_username, | 54 const base::string16& typed_username, |
| 53 bool show_all, | 55 int options, |
| 54 const gfx::RectF& bounds); | 56 const gfx::RectF& bounds); |
| 55 | 57 |
| 56 // Invoked to clear any page specific cached values. | 58 // Invoked to clear any page specific cached values. |
| 57 void Reset(); | 59 void Reset(); |
| 58 | 60 |
| 59 // A public version of FillSuggestion(), only for use in tests. | 61 // A public version of FillSuggestion(), only for use in tests. |
| 60 bool FillSuggestionForTest(int key, const base::string16& username); | 62 bool FillSuggestionForTest(int key, const base::string16& username); |
| 61 | 63 |
| 62 // A public version of PreviewSuggestion(), only for use in tests. | 64 // A public version of PreviewSuggestion(), only for use in tests. |
| 63 bool PreviewSuggestionForTest(int key, const base::string16& username); | 65 bool PreviewSuggestionForTest(int key, const base::string16& username); |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 100 autofill::AutofillClient* const autofill_client_; // weak | 102 autofill::AutofillClient* const autofill_client_; // weak |
| 101 | 103 |
| 102 base::WeakPtrFactory<PasswordAutofillManager> weak_ptr_factory_; | 104 base::WeakPtrFactory<PasswordAutofillManager> weak_ptr_factory_; |
| 103 | 105 |
| 104 DISALLOW_COPY_AND_ASSIGN(PasswordAutofillManager); | 106 DISALLOW_COPY_AND_ASSIGN(PasswordAutofillManager); |
| 105 }; | 107 }; |
| 106 | 108 |
| 107 } // namespace password_manager | 109 } // namespace password_manager |
| 108 | 110 |
| 109 #endif // COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_AUTOFILL_MANAGER_H_ | 111 #endif // COMPONENTS_PASSWORD_MANAGER_CORE_BROWSER_PASSWORD_AUTOFILL_MANAGER_H_ |
| OLD | NEW |