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

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

Issue 462563002: Add ManagePasswordsBubbleManageViewController and unit tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix views Created 6 years, 3 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
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 CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_MODEL_H_ 5 #ifndef CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_MODEL_H_
6 #define CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_MODEL_H_ 6 #define CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_MODEL_H_
7 7
8 #include "chrome/browser/ui/passwords/manage_passwords_bubble.h" 8 #include "chrome/browser/ui/passwords/manage_passwords_bubble.h"
9 #include "components/autofill/core/common/password_form.h" 9 #include "components/autofill/core/common/password_form.h"
10 #include "components/password_manager/core/browser/password_manager_metrics_util .h" 10 #include "components/password_manager/core/browser/password_manager_metrics_util .h"
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 95
96 // Gets the reason the bubble was dismissed. 96 // Gets the reason the bubble was dismissed.
97 password_manager::metrics_util::UIDismissalReason dismissal_reason() const { 97 password_manager::metrics_util::UIDismissalReason dismissal_reason() const {
98 return dismissal_reason_; 98 return dismissal_reason_;
99 } 99 }
100 100
101 // State setter. 101 // State setter.
102 void set_state(password_manager::ui::State state) { state_ = state; } 102 void set_state(password_manager::ui::State state) { state_ = state; }
103 #endif 103 #endif
104 104
105 // Upper limits on the size of the username and password fields.
106 static int UsernameFieldWidth();
107 static int PasswordFieldWidth();
108
105 private: 109 private:
106 password_manager::ui::State state_; 110 password_manager::ui::State state_;
107 base::string16 title_; 111 base::string16 title_;
108 autofill::PasswordForm pending_credentials_; 112 autofill::PasswordForm pending_credentials_;
109 autofill::ConstPasswordFormMap best_matches_; 113 autofill::ConstPasswordFormMap best_matches_;
110 base::string16 manage_link_; 114 base::string16 manage_link_;
111 base::string16 save_confirmation_text_; 115 base::string16 save_confirmation_text_;
112 gfx::Range save_confirmation_link_range_; 116 gfx::Range save_confirmation_link_range_;
113 117
114 password_manager::metrics_util::UIDisplayDisposition display_disposition_; 118 password_manager::metrics_util::UIDisplayDisposition display_disposition_;
115 password_manager::metrics_util::UIDismissalReason dismissal_reason_; 119 password_manager::metrics_util::UIDismissalReason dismissal_reason_;
116 120
117 DISALLOW_COPY_AND_ASSIGN(ManagePasswordsBubbleModel); 121 DISALLOW_COPY_AND_ASSIGN(ManagePasswordsBubbleModel);
118 }; 122 };
119 123
120 #endif // CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_MODEL_H_ 124 #endif // CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_MODEL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698