Revert "Only store leading 13 bits of password hash."
[chromium-blink-merge.git] / chrome / browser / ui / views / passwords / manage_password_items_view.h
blobdc6d168962a2129983ada668cb173ee0373b9e71
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
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_UI_VIEWS_PASSWORDS_MANAGE_PASSWORD_ITEMS_VIEW_H_
6 #define CHROME_BROWSER_UI_VIEWS_PASSWORDS_MANAGE_PASSWORD_ITEMS_VIEW_H_
8 #include <vector>
10 #include "ui/views/view.h"
12 class ManagePasswordsBubbleModel;
14 namespace autofill {
15 struct PasswordForm;
18 // A custom view of individual credentials. The view is represented as a table
19 // where each row can be in three distinct states:
21 // * Present credentials to the user which she may choose to save.
22 // * Present already-saved credentials to the user for management.
23 // * Offer the user the ability to undo a deletion action.
24 class ManagePasswordItemsView : public views::View {
25 public:
26 ManagePasswordItemsView(
27 ManagePasswordsBubbleModel* manage_passwords_bubble_model,
28 const std::vector<const autofill::PasswordForm*>& password_forms);
30 private:
31 class PasswordFormRow;
33 ~ManagePasswordItemsView() override;
35 void AddRows();
36 void NotifyPasswordFormStatusChanged(
37 const autofill::PasswordForm& password_form, bool deleted);
39 // Changes the views according to the state of |password_forms_rows_|.
40 void Refresh();
42 std::vector<PasswordFormRow> password_forms_rows_;
43 ManagePasswordsBubbleModel* model_;
45 DISALLOW_COPY_AND_ASSIGN(ManagePasswordItemsView);
48 #endif // CHROME_BROWSER_UI_VIEWS_PASSWORDS_MANAGE_PASSWORD_ITEMS_VIEW_H_