| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #include "chrome/browser/ui/views/login_view.h" | 5 #include "chrome/browser/ui/views/login_view.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "base/message_loop.h" | 10 #include "base/message_loop.h" |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 } | 100 } |
| 101 | 101 |
| 102 /////////////////////////////////////////////////////////////////////////////// | 102 /////////////////////////////////////////////////////////////////////////////// |
| 103 // LoginView, views::View, views::LoginModelObserver overrides: | 103 // LoginView, views::View, views::LoginModelObserver overrides: |
| 104 | 104 |
| 105 void LoginView::OnAutofillDataAvailable(const string16& username, | 105 void LoginView::OnAutofillDataAvailable(const string16& username, |
| 106 const string16& password) { | 106 const string16& password) { |
| 107 if (username_field_->text().empty()) { | 107 if (username_field_->text().empty()) { |
| 108 username_field_->SetText(username); | 108 username_field_->SetText(username); |
| 109 password_field_->SetText(password); | 109 password_field_->SetText(password); |
| 110 username_field_->SelectAll(); | 110 username_field_->SelectAll(true); |
| 111 } | 111 } |
| 112 } | 112 } |
| OLD | NEW |