28 #include <tdefiledialog.h> 29 #include <tdeio/netaccess.h> 30 #include <tdelocale.h> 31 #include <tdemessagebox.h> 33 #include <kstandarddirs.h> 34 #include <tdetempfile.h> 37 #include "xxportmanager.h" 39 #include "pab_xxport.h" 41 K_EXPORT_KADDRESSBOOK_XXFILTER( libkaddrbk_pab_xxport, PABXXPort ) 43 PABXXPort::PABXXPort( TDEABC::AddressBook *ab, TQWidget *parent, const char *name ) 44 : KAB::XXPort( ab, parent, name ) 46 createImportAction( i18n( "Import MS Exchange Personal Address Book (.PAB)") ); 49 TDEABC::AddresseeList PABXXPort::importContacts( const TQString& ) const 51 TDEABC::AddresseeList addrList; 53 TQString fileName = KFileDialog::getOpenFileName( TQDir::homeDirPath(), 54 "*.[pP][aA][bB]|" + i18n( "MS Exchange Personal Address Book Files (*.pab)"), 0 ); 55 if ( fileName.isEmpty() ) 57 if ( !TQFile::exists( fileName ) ) { 58 KMessageBox::sorry( parentWidget(), i18n( "<qt>Could not find a MS Exchange Personal Address Book <b>%1</b>.</qt>" ).arg( fileName ) ); 69 #include "pab_xxport.moc"
|