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

Side by Side Diff: components/autofill/core/browser/autofill_manager.cc

Issue 818103002: Make callers of CommandLine use it via the base:: namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 12 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 unified diff | Download patch
OLDNEW
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/core/browser/autofill_manager.h" 5 #include "components/autofill/core/browser/autofill_manager.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <limits> 9 #include <limits>
10 #include <map> 10 #include <map>
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after
282 282
283 int AutofillManager::AccessAddressBookPromptCount() { 283 int AutofillManager::AccessAddressBookPromptCount() {
284 if (!personal_data_) 284 if (!personal_data_)
285 return 0; 285 return 0;
286 return personal_data_->AccessAddressBookPromptCount(); 286 return personal_data_->AccessAddressBookPromptCount();
287 } 287 }
288 #endif // defined(OS_MACOSX) && !defined(OS_IOS) 288 #endif // defined(OS_MACOSX) && !defined(OS_IOS)
289 289
290 bool AutofillManager::ShouldShowScanCreditCard(const FormData& form, 290 bool AutofillManager::ShouldShowScanCreditCard(const FormData& form,
291 const FormFieldData& field) { 291 const FormFieldData& field) {
292 if (CommandLine::ForCurrentProcess()->HasSwitch( 292 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
293 autofill::switches::kDisableCreditCardScan)) { 293 autofill::switches::kDisableCreditCardScan)) {
294 return false; 294 return false;
295 } 295 }
296 296
297 if (!client_->HasCreditCardScanFeature()) 297 if (!client_->HasCreditCardScanFeature())
298 return false; 298 return false;
299 299
300 AutofillField* autofill_field = GetAutofillField(form, field); 300 AutofillField* autofill_field = GetAutofillField(form, field);
301 return autofill_field && 301 return autofill_field &&
302 autofill_field->Type().GetStorableType() == CREDIT_CARD_NUMBER; 302 autofill_field->Type().GetStorableType() == CREDIT_CARD_NUMBER;
(...skipping 944 matching lines...) Expand 10 before | Expand all | Expand 10 after
1247 return false; 1247 return false;
1248 1248
1249 // Disregard forms that we wouldn't ever autofill in the first place. 1249 // Disregard forms that we wouldn't ever autofill in the first place.
1250 if (!form.ShouldBeParsed()) 1250 if (!form.ShouldBeParsed())
1251 return false; 1251 return false;
1252 1252
1253 return true; 1253 return true;
1254 } 1254 }
1255 1255
1256 } // namespace autofill 1256 } // namespace autofill
OLDNEW
« no previous file with comments | « components/autofill/content/renderer/password_autofill_agent.cc ('k') | components/copresence/rpc/rpc_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698