summaryrefslogtreecommitdiffabout
path: root/pluginopiekabc/opieaddressbookplugin.cpp
authorulf69 <ulf69>2004-08-06 18:24:25 (UTC)
committer ulf69 <ulf69>2004-08-06 18:24:25 (UTC)
commit79bb2950bd27b5e138d2fd7afe2ab37b6b036cae (patch) (side-by-side diff)
treeabd40f9f1f6cb2a73e2410e67c7889efb855c85f /pluginopiekabc/opieaddressbookplugin.cpp
parentaeb62a1841266e1bec8250a1af9ec3231eb25655 (diff)
downloadkdepimpi-79bb2950bd27b5e138d2fd7afe2ab37b6b036cae.zip
kdepimpi-79bb2950bd27b5e138d2fd7afe2ab37b6b036cae.tar.gz
kdepimpi-79bb2950bd27b5e138d2fd7afe2ab37b6b036cae.tar.bz2
functionality now handled by kabc resourceadapter
Diffstat (limited to 'pluginopiekabc/opieaddressbookplugin.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--pluginopiekabc/opieaddressbookplugin.cpp71
1 files changed, 0 insertions, 71 deletions
diff --git a/pluginopiekabc/opieaddressbookplugin.cpp b/pluginopiekabc/opieaddressbookplugin.cpp
deleted file mode 100644
index 0b22289..0000000
--- a/pluginopiekabc/opieaddressbookplugin.cpp
+++ b/dev/null
@@ -1,71 +0,0 @@
-#include <stdio.h>
-#include <qwidget.h>
-#include <qlayout.h>
-#include <qlistbox.h>
-#include <opie/ocontact.h>
-#include <opie/orecordlist.h>
-#include "opieaddressbookplugin.h"
-#include "opieaddressee.h"
-
-OpieAddressBookPlugin::OpieAddressBookPlugin() : ref(0) {
-
- access = new OContactAccess("OpieAddressBookPlugin");
-
-}
-
-KABC::Addressee::List OpieAddressBookPlugin::getAddressees() {
- KABC::Addressee::List results;
- OContactAccess access("OpieAddressBookPlugin");
- OContactAccess::List::Iterator it;
- ORecordList<OContact> accessList = access.sorted(true,0,0,0);
- for(it = accessList.begin(); it != accessList.end(); ++it ) {
- OpieAddressee addressee( *it );
- results.append(addressee);
- }
- return results;
-}
-
-QString OpieAddressBookPlugin::name() {
- return QString::QString("OpieAddressBookPlugin");
-}
-
-
-KABC::Addressee::List OpieAddressBookPlugin::findByEmail(const QString &email) {
-printf("OpieAddressBookPlugin::findByEmail: email=%s\n", email.ascii());
- KABC::Addressee::List results;
-
- ORecordList<OContact> accessList = access->sorted(true,0,0,0);
- OContactAccess::List::Iterator it;
- for(it = accessList.begin(); it != accessList.end(); ++it ) {
- OContact contact = *it;
- QStringList emailList = contact.emailList();
- QStringList foundEmails = emailList.grep(email,false);
- if (foundEmails.count() >= 1) {
- OpieAddressee a(contact);
- printf("Found Contact %s\n", a.formattedName().ascii());
- results.append(a);
- }
- }
- return results;
-
-}
-
-QRESULT OpieAddressBookPlugin::queryInterface( const QUuid &uuid, QUnknownInterface **iface )
-{
-printf("Start: OpieAddressBookPlugin::queryInterface\n");
- *iface = 0;
- if ( uuid == IID_QUnknown )
- *iface = this;
- else if ( uuid == IID_KOAddressBookInterface )
- *iface = this;
- if ( *iface )
- (*iface)->addRef();
- return QS_OK;
-printf("End: OpieAddressBookPlugin::queryInterface\n");
-}
-
-Q_EXPORT_INTERFACE()
-{
- Q_CREATE_INSTANCE( OpieAddressBookPlugin )
-}
-