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

Side by Side Diff: chrome/browser/ui/views/login_view.h

Issue 138363004: Views Textfield fixes and cleanup. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sync and rebase. Created 6 years, 11 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
« no previous file with comments | « chrome/browser/ui/views/find_bar_view.cc ('k') | chrome/browser/ui/views/login_view.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_VIEWS_LOGIN_VIEW_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_LOGIN_VIEW_H_
6 #define CHROME_BROWSER_UI_VIEWS_LOGIN_VIEW_H_ 6 #define CHROME_BROWSER_UI_VIEWS_LOGIN_VIEW_H_
7 7
8 #include "chrome/browser/ui/login/login_model.h" 8 #include "chrome/browser/ui/login/login_model.h"
9 #include "ui/views/view.h" 9 #include "ui/views/view.h"
10 10
11 namespace views { 11 namespace views {
12 class Label; 12 class Label;
13 class Textfield; 13 class Textfield;
14 class LoginModel; 14 class LoginModel;
15 } // namespace views 15 } // namespace views
16 16
17 // This class is responsible for displaying the contents of a login window 17 // This class is responsible for displaying the contents of a login window
18 // for HTTP/FTP authentication. 18 // for HTTP/FTP authentication.
19 class LoginView : public views::View, public LoginModelObserver { 19 class LoginView : public views::View, public LoginModelObserver {
20 public: 20 public:
21 // |model| is observed for the entire lifetime of the LoginView. 21 // |model| is observed for the entire lifetime of the LoginView.
22 // Therefore |model| should not be destroyed before the LoginView 22 // Therefore |model| should not be destroyed before the LoginView object.
23 // object. 23 LoginView(const base::string16& explanation, LoginModel* model);
24 LoginView(const base::string16& explanation,
25 LoginModel* model);
26 virtual ~LoginView(); 24 virtual ~LoginView();
27 25
28 // Access the data in the username/password text fields. 26 // Access the data in the username/password text fields.
29 base::string16 GetUsername(); 27 base::string16 GetUsername();
30 base::string16 GetPassword(); 28 base::string16 GetPassword();
31 29
32 // LoginModelObserver implementation. 30 // LoginModelObserver implementation.
33 virtual void OnAutofillDataAvailable(const base::string16& username, 31 virtual void OnAutofillDataAvailable(const base::string16& username,
34 const base::string16& password) OVERRIDE; 32 const base::string16& password) OVERRIDE;
35 virtual void OnLoginModelDestroying() OVERRIDE; 33 virtual void OnLoginModelDestroying() OVERRIDE;
(...skipping 14 matching lines...) Expand all
50 views::Label* message_label_; 48 views::Label* message_label_;
51 49
52 // If not null, points to a model we need to notify of our own destruction 50 // If not null, points to a model we need to notify of our own destruction
53 // so it doesn't try and access this when its too late. 51 // so it doesn't try and access this when its too late.
54 LoginModel* login_model_; 52 LoginModel* login_model_;
55 53
56 DISALLOW_COPY_AND_ASSIGN(LoginView); 54 DISALLOW_COPY_AND_ASSIGN(LoginView);
57 }; 55 };
58 56
59 #endif // CHROME_BROWSER_UI_VIEWS_LOGIN_VIEW_H_ 57 #endif // CHROME_BROWSER_UI_VIEWS_LOGIN_VIEW_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/find_bar_view.cc ('k') | chrome/browser/ui/views/login_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698