| OLD | NEW |
| 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 #include "components/autofill/content/renderer/password_autofill_agent.h" | 5 #include "components/autofill/content/renderer/password_autofill_agent.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
| 10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
| (...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 208 } | 208 } |
| 209 return false; | 209 return false; |
| 210 } | 210 } |
| 211 | 211 |
| 212 // Log a message including the name, method and action of |form|. | 212 // Log a message including the name, method and action of |form|. |
| 213 void LogHTMLForm(SavePasswordProgressLogger* logger, | 213 void LogHTMLForm(SavePasswordProgressLogger* logger, |
| 214 SavePasswordProgressLogger::StringID message_id, | 214 SavePasswordProgressLogger::StringID message_id, |
| 215 const blink::WebFormElement& form) { | 215 const blink::WebFormElement& form) { |
| 216 logger->LogHTMLForm(message_id, | 216 logger->LogHTMLForm(message_id, |
| 217 form.name().utf8(), | 217 form.name().utf8(), |
| 218 form.method().utf8(), | |
| 219 GURL(form.action().utf8())); | 218 GURL(form.action().utf8())); |
| 220 } | 219 } |
| 221 | 220 |
| 222 } // namespace | 221 } // namespace |
| 223 | 222 |
| 224 //////////////////////////////////////////////////////////////////////////////// | 223 //////////////////////////////////////////////////////////////////////////////// |
| 225 // PasswordAutofillAgent, public: | 224 // PasswordAutofillAgent, public: |
| 226 | 225 |
| 227 PasswordAutofillAgent::PasswordAutofillAgent(content::RenderView* render_view) | 226 PasswordAutofillAgent::PasswordAutofillAgent(content::RenderView* render_view) |
| 228 : content::RenderViewObserver(render_view), | 227 : content::RenderViewObserver(render_view), |
| (...skipping 845 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1074 username->setSelectionRange(username_selection_start_, | 1073 username->setSelectionRange(username_selection_start_, |
| 1075 username->value().length()); | 1074 username->value().length()); |
| 1076 } | 1075 } |
| 1077 if (!password->suggestedValue().isEmpty()) { | 1076 if (!password->suggestedValue().isEmpty()) { |
| 1078 password->setSuggestedValue(blink::WebString()); | 1077 password->setSuggestedValue(blink::WebString()); |
| 1079 password->setAutofilled(was_password_autofilled_); | 1078 password->setAutofilled(was_password_autofilled_); |
| 1080 } | 1079 } |
| 1081 } | 1080 } |
| 1082 | 1081 |
| 1083 } // namespace autofill | 1082 } // namespace autofill |
| OLD | NEW |