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

Side by Side Diff: chrome/browser/autofill/credit_card.cc

Issue 6903091: Autofill Multi-Value: Additional profiles with same name and address not added to DOM UI (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address nits. Created 9 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « chrome/browser/autofill/credit_card.h ('k') | chrome/browser/autofill/personal_data_manager.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "chrome/browser/autofill/credit_card.h" 5 #include "chrome/browser/autofill/credit_card.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after
365 for (size_t index = 0; index < arraysize(types); ++index) { 365 for (size_t index = 0; index < arraysize(types); ++index) {
366 int comparison = GetInfo(types[index]).compare( 366 int comparison = GetInfo(types[index]).compare(
367 credit_card.GetInfo(types[index])); 367 credit_card.GetInfo(types[index]));
368 if (comparison != 0) 368 if (comparison != 0)
369 return comparison; 369 return comparison;
370 } 370 }
371 371
372 return 0; 372 return 0;
373 } 373 }
374 374
375 int CreditCard::CompareMulti(const CreditCard& credit_card) const {
376 return Compare(credit_card);
377 }
378
375 bool CreditCard::operator==(const CreditCard& credit_card) const { 379 bool CreditCard::operator==(const CreditCard& credit_card) const {
376 if (guid_ != credit_card.guid_) 380 if (guid_ != credit_card.guid_)
377 return false; 381 return false;
378 382
379 return Compare(credit_card) == 0; 383 return Compare(credit_card) == 0;
380 } 384 }
381 385
382 bool CreditCard::operator!=(const CreditCard& credit_card) const { 386 bool CreditCard::operator!=(const CreditCard& credit_card) const {
383 return !operator==(credit_card); 387 return !operator==(credit_card);
384 } 388 }
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
551 // send these strings to WK, which then asks WebKitClientImpl to load the image 555 // send these strings to WK, which then asks WebKitClientImpl to load the image
552 // data. 556 // data.
553 const char* const kAmericanExpressCard = "americanExpressCC"; 557 const char* const kAmericanExpressCard = "americanExpressCC";
554 const char* const kDinersCard = "dinersCC"; 558 const char* const kDinersCard = "dinersCC";
555 const char* const kDiscoverCard = "discoverCC"; 559 const char* const kDiscoverCard = "discoverCC";
556 const char* const kGenericCard = "genericCC"; 560 const char* const kGenericCard = "genericCC";
557 const char* const kJCBCard = "jcbCC"; 561 const char* const kJCBCard = "jcbCC";
558 const char* const kMasterCard = "masterCardCC"; 562 const char* const kMasterCard = "masterCardCC";
559 const char* const kSoloCard = "soloCC"; 563 const char* const kSoloCard = "soloCC";
560 const char* const kVisaCard = "visaCC"; 564 const char* const kVisaCard = "visaCC";
OLDNEW
« no previous file with comments | « chrome/browser/autofill/credit_card.h ('k') | chrome/browser/autofill/personal_data_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698