-rw-r--r-- | kabc/addressbook.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kabc/addressbook.cpp b/kabc/addressbook.cpp index c61b387..47d298a 100644 --- a/kabc/addressbook.cpp +++ b/kabc/addressbook.cpp | |||
@@ -406,49 +406,49 @@ AddressBook::Iterator AddressBook::find( const Addressee &a ) | |||
406 | } | 406 | } |
407 | 407 | ||
408 | Addressee AddressBook::findByUid( const QString &uid ) | 408 | Addressee AddressBook::findByUid( const QString &uid ) |
409 | { | 409 | { |
410 | Iterator it; | 410 | Iterator it; |
411 | for ( it = begin(); it != end(); ++it ) { | 411 | for ( it = begin(); it != end(); ++it ) { |
412 | if ( uid == (*it).uid() ) { | 412 | if ( uid == (*it).uid() ) { |
413 | return *it; | 413 | return *it; |
414 | } | 414 | } |
415 | } | 415 | } |
416 | return Addressee(); | 416 | return Addressee(); |
417 | } | 417 | } |
418 | 418 | ||
419 | Addressee::List AddressBook::allAddressees() | 419 | Addressee::List AddressBook::allAddressees() |
420 | { | 420 | { |
421 | return d->mAddressees; | 421 | return d->mAddressees; |
422 | } | 422 | } |
423 | 423 | ||
424 | Addressee::List AddressBook::findByName( const QString &name ) | 424 | Addressee::List AddressBook::findByName( const QString &name ) |
425 | { | 425 | { |
426 | Addressee::List results; | 426 | Addressee::List results; |
427 | 427 | ||
428 | Iterator it; | 428 | Iterator it; |
429 | for ( it = begin(); it != end(); ++it ) { | 429 | for ( it = begin(); it != end(); ++it ) { |
430 | if ( name == (*it).name() ) { | 430 | if ( name == (*it).realName() ) { |
431 | results.append( *it ); | 431 | results.append( *it ); |
432 | } | 432 | } |
433 | } | 433 | } |
434 | 434 | ||
435 | return results; | 435 | return results; |
436 | } | 436 | } |
437 | 437 | ||
438 | Addressee::List AddressBook::findByEmail( const QString &email ) | 438 | Addressee::List AddressBook::findByEmail( const QString &email ) |
439 | { | 439 | { |
440 | Addressee::List results; | 440 | Addressee::List results; |
441 | QStringList mailList; | 441 | QStringList mailList; |
442 | 442 | ||
443 | Iterator it; | 443 | Iterator it; |
444 | for ( it = begin(); it != end(); ++it ) { | 444 | for ( it = begin(); it != end(); ++it ) { |
445 | mailList = (*it).emails(); | 445 | mailList = (*it).emails(); |
446 | for ( QStringList::Iterator ite = mailList.begin(); ite != mailList.end(); ++ite ) { | 446 | for ( QStringList::Iterator ite = mailList.begin(); ite != mailList.end(); ++ite ) { |
447 | if ( email == (*ite) ) { | 447 | if ( email == (*ite) ) { |
448 | results.append( *it ); | 448 | results.append( *it ); |
449 | } | 449 | } |
450 | } | 450 | } |
451 | } | 451 | } |
452 | 452 | ||
453 | return results; | 453 | return results; |
454 | } | 454 | } |