summaryrefslogtreecommitdiff
path: root/examples/qpepim-addressbook
Side-by-side diff
Diffstat (limited to 'examples/qpepim-addressbook') (more/less context) (ignore whitespace changes)
-rw-r--r--examples/qpepim-addressbook/abexample.desktop6
-rw-r--r--examples/qpepim-addressbook/abexample.pngbin1262 -> 0 bytes
-rw-r--r--examples/qpepim-addressbook/addressbookdumper.cpp65
-rw-r--r--examples/qpepim-addressbook/addressbookdumper.h39
-rw-r--r--examples/qpepim-addressbook/main.cpp47
-rw-r--r--examples/qpepim-addressbook/qpepim-abexample.control9
-rw-r--r--examples/qpepim-addressbook/qpepim-addressbook.pro8
7 files changed, 0 insertions, 174 deletions
diff --git a/examples/qpepim-addressbook/abexample.desktop b/examples/qpepim-addressbook/abexample.desktop
deleted file mode 100644
index 24b44d1..0000000
--- a/examples/qpepim-addressbook/abexample.desktop
+++ b/dev/null
@@ -1,6 +0,0 @@
-[Desktop Entry]
-Comment=Simple QPEPIM Example
-Exec=abexample
-Icon=abexample
-Type=Application
-Name=AB QPEPIM
diff --git a/examples/qpepim-addressbook/abexample.png b/examples/qpepim-addressbook/abexample.png
deleted file mode 100644
index f63d0bc..0000000
--- a/examples/qpepim-addressbook/abexample.png
+++ b/dev/null
Binary files differ
diff --git a/examples/qpepim-addressbook/addressbookdumper.cpp b/examples/qpepim-addressbook/addressbookdumper.cpp
deleted file mode 100644
index c47e05c..0000000
--- a/examples/qpepim-addressbook/addressbookdumper.cpp
+++ b/dev/null
@@ -1,65 +0,0 @@
-/**********************************************************************
-** Copyright (C) 2000-2002 Trolltech AS. All rights reserved.
-**
-** This file is part of the Qtopia Environment.
-**
-** This file may be distributed and/or modified under the terms of the
-** GNU General Public License version 2 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file.
-**
-** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
-** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-**
-** See http://www.trolltech.com/gpl/ for GPL licensing information.
-**
-** Contact info@trolltech.com if any conditions of this licensing are
-** not clear to you.
-**
-**********************************************************************/
-
-#include <qpe/contact.h>
-#include <qvaluelist.h>
-#include "addressbookdumper.h"
-
-AddressBookDumper::AddressBookDumper(QWidget* parent) : QMultiLineEdit(parent) {
- // connect(&m_ABAccess, SIGNAL(addressbookUpdated()), this, SLOT(abChanged()));
-}
-
-AddressBookDumper::~AddressBookDumper() {
-}
-
-void AddressBookDumper::abChanged() {
- QString newText;
- QValueList<Contact> contacts = m_ABAccess.contacts();
- QValueListConstIterator<Contact> it;
- for (it = contacts.begin() ; it != contacts.end(); it++) {
- newText.append((*it).firstName() + " " + (*it).lastName() + "\n");
- }
- setText(newText);
-}
-
-void AddressBookDumper::startBigEdit() {
- if (m_ABAccess.startBlockEdit())
- qDebug("*** Block edit successfully started.");
- else
- qDebug("*** Block edit start failed.");
-}
-
-void AddressBookDumper::endBigEdit() {
- if (m_ABAccess.endBlockEdit())
- qDebug("*** Block edit successfully ended.");
- else
- qDebug("*** Block edit end failed.");
-}
-
-void AddressBookDumper::addContact() {
- Contact foo;
- foo.setFirstName("Foo");
- foo.setLastName("Bar");
- foo.setFileAs();
- if (m_ABAccess.addContact(foo))
- qDebug("*** Add succeeded..");
- else
- qDebug("*** Add failed..");
-}
diff --git a/examples/qpepim-addressbook/addressbookdumper.h b/examples/qpepim-addressbook/addressbookdumper.h
deleted file mode 100644
index cc83d32..0000000
--- a/examples/qpepim-addressbook/addressbookdumper.h
+++ b/dev/null
@@ -1,39 +0,0 @@
-/**********************************************************************
-** Copyright (C) 2000-2002 Trolltech AS. All rights reserved.
-**
-** This file is part of the Qtopia Environment.
-**
-** This file may be distributed and/or modified under the terms of the
-** GNU General Public License version 2 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file.
-**
-** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
-** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-**
-** See http://www.trolltech.com/gpl/ for GPL licensing information.
-**
-** Contact info@trolltech.com if any conditions of this licensing are
-** not clear to you.
-**
-**********************************************************************/
-
-#include <qmultilineedit.h>
-#include <qpe/pim/addressbookaccess.h>
-
-class AddressBookDumper : public QMultiLineEdit {
- Q_OBJECT
-
- public:
- AddressBookDumper(QWidget* parent);
- ~AddressBookDumper();
-
- public slots:
- void abChanged();
- void startBigEdit();
- void endBigEdit();
- void addContact();
-
- private:
- AddressBookAccess m_ABAccess;
-};
diff --git a/examples/qpepim-addressbook/main.cpp b/examples/qpepim-addressbook/main.cpp
deleted file mode 100644
index 590fffe..0000000
--- a/examples/qpepim-addressbook/main.cpp
+++ b/dev/null
@@ -1,47 +0,0 @@
-/**********************************************************************
-** Copyright (C) 2000-2002 Trolltech AS. All rights reserved.
-**
-** This file is part of the Qtopia Environment.
-**
-** This file may be distributed and/or modified under the terms of the
-** GNU General Public License version 2 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file.
-**
-** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
-** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-**
-** See http://www.trolltech.com/gpl/ for GPL licensing information.
-**
-** Contact info@trolltech.com if any conditions of this licensing are
-** not clear to you.
-**
-**********************************************************************/
-
-#include <qpe/qpeapplication.h>
-#ifdef QWS
-#include <qpe/qcopenvelope_qws.h>
-#endif
-#include <qapplication.h>
-#include <qpe/pim/addressbookaccess.h>
-#include "addressbookdumper.h"
-#include <qvbox.h>
-#include <qpushbutton.h>
-
-int main( int argc, char ** argv )
-{
- QPEApplication a( argc, argv );
- QVBox* vbox = new QVBox(0L);
- QPushButton* clicker = new QPushButton("Refresh", vbox);
- QPushButton* startBigEditButton = new QPushButton("Start Big Edit", vbox);
- QPushButton* endBigEditButton = new QPushButton("End Big Edit", vbox);
- QPushButton* addContactButton = new QPushButton("Add Contact", vbox);
- AddressBookDumper* abDumper = new AddressBookDumper(vbox);
- QObject::connect(clicker, SIGNAL(clicked()), abDumper, SLOT(abChanged()));
- QObject::connect(startBigEditButton, SIGNAL(clicked()), abDumper, SLOT(startBigEdit()));
- QObject::connect(endBigEditButton, SIGNAL(clicked()), abDumper, SLOT(endBigEdit()));
- QObject::connect(addContactButton, SIGNAL(clicked()), abDumper, SLOT(addContact()));
- a.setMainWidget(vbox);
- vbox->show();
- return a.exec();
-}
diff --git a/examples/qpepim-addressbook/qpepim-abexample.control b/examples/qpepim-addressbook/qpepim-abexample.control
deleted file mode 100644
index 5a31c97..0000000
--- a/examples/qpepim-addressbook/qpepim-abexample.control
+++ b/dev/null
@@ -1,9 +0,0 @@
-Files: bin/abexample apps/Applications/abexample.desktop
-Priority: optional
-Section: qpe/applications
-Maintainer: Warwick Allison <warwick@trolltech.com>
-Architecture: arm
-Version: $QPE_VERSION-1
-Depends: qpe-pim, qpe-base ($QPE_VERSION)
-Description: Example Addressbook reader
- Simple example for using the QPEPIM access library.
diff --git a/examples/qpepim-addressbook/qpepim-addressbook.pro b/examples/qpepim-addressbook/qpepim-addressbook.pro
deleted file mode 100644
index 7e918e0..0000000
--- a/examples/qpepim-addressbook/qpepim-addressbook.pro
+++ b/dev/null
@@ -1,8 +0,0 @@
-TEMPLATE = app
-CONFIG = qt warn_on debug
-
-HEADERS = addressbookdumper.h
-SOURCES = main.cpp addressbookdumper.cpp
-TARGET = abexample
-INCLUDEPATH = $(QPEDIR)/include
-LIBS += -lqpepim -lqpe -lqte