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

Side by Side Diff: chrome/browser/ui/passwords/manage_passwords_state.h

Issue 1776673003: Fix the password bubble titles for android. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix the tests Created 4 years, 9 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_STATE_H_ 5 #ifndef CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_STATE_H_
6 #define CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_STATE_H_ 6 #define CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_STATE_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 void OnUpdatePassword( 50 void OnUpdatePassword(
51 scoped_ptr<password_manager::PasswordFormManager> form_manager); 51 scoped_ptr<password_manager::PasswordFormManager> form_manager);
52 52
53 // Move to CREDENTIAL_REQUEST_STATE. 53 // Move to CREDENTIAL_REQUEST_STATE.
54 void OnRequestCredentials( 54 void OnRequestCredentials(
55 ScopedVector<autofill::PasswordForm> local_credentials, 55 ScopedVector<autofill::PasswordForm> local_credentials,
56 ScopedVector<autofill::PasswordForm> federated_credentials, 56 ScopedVector<autofill::PasswordForm> federated_credentials,
57 const GURL& origin); 57 const GURL& origin);
58 58
59 // Move to AUTO_SIGNIN_STATE. |local_forms| can't be empty. 59 // Move to AUTO_SIGNIN_STATE. |local_forms| can't be empty.
60 void OnAutoSignin(ScopedVector<autofill::PasswordForm> local_forms); 60 void OnAutoSignin(ScopedVector<autofill::PasswordForm> local_forms,
61 const GURL& origin);
61 62
62 // Move to CONFIRMATION_STATE. 63 // Move to CONFIRMATION_STATE.
63 void OnAutomaticPasswordSave( 64 void OnAutomaticPasswordSave(
64 scoped_ptr<password_manager::PasswordFormManager> form_manager); 65 scoped_ptr<password_manager::PasswordFormManager> form_manager);
65 66
66 // Move to MANAGE_STATE or INACTIVE_STATE for PSL matched passwords. 67 // Move to MANAGE_STATE or INACTIVE_STATE for PSL matched passwords.
67 // |password_form_map| contains best matches from the password store for the 68 // |password_form_map| contains best matches from the password store for the
68 // form which was autofilled, |origin| is an origin of the form which was 69 // form which was autofilled, |origin| is an origin of the form which was
69 // autofilled. In addition, |federated_matches|, if not null, contains stored 70 // autofilled. In addition, |federated_matches|, if not null, contains stored
70 // federated credentials to show to the user as well. 71 // federated credentials to show to the user as well.
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 121
121 // Add |form| to the internal state. 122 // Add |form| to the internal state.
122 void AddForm(const autofill::PasswordForm& form); 123 void AddForm(const autofill::PasswordForm& form);
123 // Updates |form| in the internal state. 124 // Updates |form| in the internal state.
124 bool UpdateForm(const autofill::PasswordForm& form); 125 bool UpdateForm(const autofill::PasswordForm& form);
125 // Removes |form| from the internal state. 126 // Removes |form| from the internal state.
126 void DeleteForm(const autofill::PasswordForm& form); 127 void DeleteForm(const autofill::PasswordForm& form);
127 128
128 void SetState(password_manager::ui::State state); 129 void SetState(password_manager::ui::State state);
129 130
130 // The origin of the current page. It's used to determine which PasswordStore 131 // The origin of the current page for which the state is stored. It's used to
131 // changes are applicable to the internal state. 132 // determine which PasswordStore changes are applicable to the internal state.
132 GURL origin_; 133 GURL origin_;
133 134
134 // Contains the password that was submitted. 135 // Contains the password that was submitted.
135 scoped_ptr<password_manager::PasswordFormManager> form_manager_; 136 scoped_ptr<password_manager::PasswordFormManager> form_manager_;
136 137
137 // Weak references to the passwords for the current status. The hard pointers 138 // Weak references to the passwords for the current status. The hard pointers
138 // are scattered between |form_manager_| and |local_credentials_forms_|. If 139 // are scattered between |form_manager_| and |local_credentials_forms_|. If
139 // |form_manager_| is nullptr then all the forms are stored in 140 // |form_manager_| is nullptr then all the forms are stored in
140 // |local_credentials_forms_|. |current_forms_weak_| remains empty. 141 // |local_credentials_forms_|. |current_forms_weak_| remains empty.
141 std::vector<const autofill::PasswordForm*> current_forms_weak_; 142 std::vector<const autofill::PasswordForm*> current_forms_weak_;
(...skipping 12 matching lines...) Expand all
154 // The current state of the password manager UI. 155 // The current state of the password manager UI.
155 password_manager::ui::State state_; 156 password_manager::ui::State state_;
156 157
157 // The client used for logging. 158 // The client used for logging.
158 password_manager::PasswordManagerClient* client_; 159 password_manager::PasswordManagerClient* client_;
159 160
160 DISALLOW_COPY_AND_ASSIGN(ManagePasswordsState); 161 DISALLOW_COPY_AND_ASSIGN(ManagePasswordsState);
161 }; 162 };
162 163
163 #endif // CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_STATE_H_ 164 #endif // CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_STATE_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/passwords/manage_passwords_bubble_model.cc ('k') | chrome/browser/ui/passwords/manage_passwords_state.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698