Diffstat (limited to 'kabc/converter/qtopia/qtopiaconverter.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | kabc/converter/qtopia/qtopiaconverter.cpp | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/kabc/converter/qtopia/qtopiaconverter.cpp b/kabc/converter/qtopia/qtopiaconverter.cpp index e3dd3e6..f451b8b 100644 --- a/kabc/converter/qtopia/qtopiaconverter.cpp +++ b/kabc/converter/qtopia/qtopiaconverter.cpp @@ -46,22 +46,19 @@ QtopiaConverter::~QtopiaConverter() deinit(); } bool QtopiaConverter::init() { catDB = new Categories(); - if (catDB) - { + + if (!catDB) + return false; + catDB->load( categoryFileName() ); return true; } - else - { - return false; - } -} void QtopiaConverter::deinit() { if (catDB) { delete catDB; @@ -206,13 +203,13 @@ bool QtopiaConverter::qtopiaToAddressee( const PimContact &contact, Addressee &a else if (contact.gender() == PimContact::Female) addr.insertCustom( "KADDRESSBOOK", "X-Gender", "female"); if (contact.anniversary().isValid()) { QString dt = KGlobal::locale()->formatDate(contact.anniversary(), true, KLocale::ISODate); //US - qDebug("OpieConverter::opieToAddressee found:%s", dt.latin1()); + qDebug("OpieConverter::qtopiaToAddressee found:%s", dt.latin1()); addr.insertCustom( "KADDRESSBOOK", "X-Anniversary", dt); } addr.insertCustom( "KADDRESSBOOK", "X-Children", contact.children() ); if (contact.birthday().isValid()) addr.setBirthday( contact.birthday() ); |