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

Unified Diff: components/autofill/core/common/password_autofill_util.cc

Issue 697233002: Remove flag to disable ignore autocomplete='off' for password forms. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: Created 6 years, 1 month 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
Index: components/autofill/core/common/password_autofill_util.cc
diff --git a/components/autofill/core/common/password_autofill_util.cc b/components/autofill/core/common/password_autofill_util.cc
deleted file mode 100644
index 6e71fec5c30fd31fcd235d8911aba494a1c1e987..0000000000000000000000000000000000000000
--- a/components/autofill/core/common/password_autofill_util.cc
+++ /dev/null
@@ -1,39 +0,0 @@
-// Copyright 2013 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "components/autofill/core/common/password_autofill_util.h"
-
-#include "base/command_line.h"
-#include "base/metrics/field_trial.h"
-#include "components/autofill/core/common/autofill_switches.h"
-
-namespace autofill {
-
-namespace {
-
-const char kDisableIgnoreAutocompleteOffFieldTrialName[] =
- "DisableIgnoreAutocompleteOff";
-const char kEnablingGroup[] = "ENABLED";
-
-bool InDisableIgnoreAutocompleteOffGroup() {
- std::string group_name = base::FieldTrialList::FindFullName(
- kDisableIgnoreAutocompleteOffFieldTrialName);
-
- return group_name.compare(kEnablingGroup) == 0;
-}
-
-} // namespace
-
-// We ignore autocomplete='off' unless the user has specified the command line
-// flag instructing otherwise or is in the field trial group specifying that
-// ignore autocomplete='off' should be disabled.
-bool ShouldIgnoreAutocompleteOffForPasswordFields() {
- // TODO(jww): The field trial is scheduled to end 2014/9/1. At latest, we
- // should remove the field trial and switch by then.
- return !InDisableIgnoreAutocompleteOffGroup() &&
- !CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kDisableIgnoreAutocompleteOff);
-}
-
-} // namespace autofill

Powered by Google App Engine
This is Rietveld 408576698