| Index: content/renderer/render_frame_impl.cc
|
| diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
|
| index 92bfb3d6a3cf230ce5cc86dc21238ab1ee03e6b3..784e988182b1e4e89324d0bd2c1066c69f1e365f 100644
|
| --- a/content/renderer/render_frame_impl.cc
|
| +++ b/content/renderer/render_frame_impl.cc
|
| @@ -284,13 +284,9 @@ WebKit::WebNavigationPolicy RenderFrameImpl::decidePolicyForNavigation(
|
|
|
| void RenderFrameImpl::willSendSubmitEvent(WebKit::WebFrame* frame,
|
| const WebKit::WebFormElement& form) {
|
| - // Some login forms have onSubmit handlers that put a hash of the password
|
| - // into a hidden field and then clear the password. (Issue 28910.)
|
| - // This method gets called before any of those handlers run, so save away
|
| - // a copy of the password in case it gets lost.
|
| - DocumentState* document_state =
|
| - DocumentState::FromDataSource(frame->dataSource());
|
| - document_state->set_password_form_data(CreatePasswordForm(form));
|
| + // Call back to RenderViewImpl for observers to be notified.
|
| + // TODO(nasko): Remove once we have RenderFrameObserver.
|
| + render_view_->willSendSubmitEvent(frame, form);
|
| }
|
|
|
| void RenderFrameImpl::willSubmitForm(WebKit::WebFrame* frame,
|
| @@ -311,25 +307,6 @@ void RenderFrameImpl::willSubmitForm(WebKit::WebFrame* frame,
|
| internal_data->set_searchable_form_url(web_searchable_form_data.url());
|
| internal_data->set_searchable_form_encoding(
|
| web_searchable_form_data.encoding().utf8());
|
| - scoped_ptr<PasswordForm> password_form_data =
|
| - CreatePasswordForm(form);
|
| -
|
| - // In order to save the password that the user actually typed and not one
|
| - // that may have gotten transformed by the site prior to submit, recover it
|
| - // from the form contents already stored by |willSendSubmitEvent| into the
|
| - // dataSource's NavigationState (as opposed to the provisionalDataSource's,
|
| - // which is what we're storing into now.)
|
| - if (password_form_data) {
|
| - DocumentState* old_document_state =
|
| - DocumentState::FromDataSource(frame->dataSource());
|
| - if (old_document_state) {
|
| - PasswordForm* old_form_data = old_document_state->password_form_data();
|
| - if (old_form_data && old_form_data->action == password_form_data->action)
|
| - password_form_data->password_value = old_form_data->password_value;
|
| - }
|
| - }
|
| -
|
| - document_state->set_password_form_data(password_form_data.Pass());
|
|
|
| // Call back to RenderViewImpl for observers to be notified.
|
| // TODO(nasko): Remove once we have RenderFrameObserver.
|
|
|