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

Unified Diff: components/autofill/content/renderer/password_autofill_agent.cc

Issue 902893003: Do not save passwords after back-navigation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Just rebased Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/test/data/password/dummy_submit.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/autofill/content/renderer/password_autofill_agent.cc
diff --git a/components/autofill/content/renderer/password_autofill_agent.cc b/components/autofill/content/renderer/password_autofill_agent.cc
index 0f642204976bdf0169fb66af846ba9bde4e36b19..fa91a4f5658d01bd7a5df09f83c5adedb3cf58ae 100644
--- a/components/autofill/content/renderer/password_autofill_agent.cc
+++ b/components/autofill/content/renderer/password_autofill_agent.cc
@@ -1082,7 +1082,9 @@ void PasswordAutofillAgent::LegacyDidStartProvisionalLoad(
navigated_frame->provisionalDataSource());
content::NavigationState* navigation_state =
document_state->navigation_state();
- if (ui::PageTransitionIsWebTriggerable(navigation_state->transition_type()) &&
+ ui::PageTransition type = navigation_state->transition_type();
+ if (ui::PageTransitionIsWebTriggerable(type) &&
+ ui::PageTransitionIsNewNavigation(type) &&
!blink::WebUserGestureIndicator::isProcessingUserGesture()) {
// If onsubmit has been called, try and save that form.
if (provisionally_saved_form_) {
« no previous file with comments | « chrome/test/data/password/dummy_submit.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698