author | harlekin <harlekin> | 2004-03-01 16:38:12 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2004-03-01 16:38:12 (UTC) |
commit | 49615014f281a58bd9bde5543692ffddab052755 (patch) (side-by-side diff) | |
tree | fea29073a62a2217ce25976e492772f0636dce80 | |
parent | 032f2d909293fb29e6c7e3cf9cce1a12484c80f7 (diff) | |
download | opie-49615014f281a58bd9bde5543692ffddab052755.zip opie-49615014f281a58bd9bde5543692ffddab052755.tar.gz opie-49615014f281a58bd9bde5543692ffddab052755.tar.bz2 |
osearch libopie1->libopie2
-rw-r--r-- | core/pim/osearch/adresssearch.cpp | 19 | ||||
-rw-r--r-- | core/pim/osearch/adresssearch.h | 8 | ||||
-rw-r--r-- | core/pim/osearch/applnkitem.cpp | 3 | ||||
-rw-r--r-- | core/pim/osearch/applnksearch.cpp | 13 | ||||
-rw-r--r-- | core/pim/osearch/contactitem.cpp | 7 | ||||
-rw-r--r-- | core/pim/osearch/contactitem.h | 9 | ||||
-rw-r--r-- | core/pim/osearch/datebooksearch.cpp | 19 | ||||
-rw-r--r-- | core/pim/osearch/datebooksearch.h | 4 | ||||
-rw-r--r-- | core/pim/osearch/doclnkitem.cpp | 3 | ||||
-rw-r--r-- | core/pim/osearch/doclnksearch.cpp | 18 | ||||
-rw-r--r-- | core/pim/osearch/eventitem.cpp | 10 | ||||
-rw-r--r-- | core/pim/osearch/eventitem.h | 8 | ||||
-rw-r--r-- | core/pim/osearch/mainwindow.cpp | 50 | ||||
-rw-r--r-- | core/pim/osearch/mainwindow.h | 1 | ||||
-rw-r--r-- | core/pim/osearch/olistview.cpp | 9 | ||||
-rw-r--r-- | core/pim/osearch/osearch.pro | 2 | ||||
-rw-r--r-- | core/pim/osearch/resultitem.cpp | 4 | ||||
-rw-r--r-- | core/pim/osearch/resultitem.h | 4 | ||||
-rw-r--r-- | core/pim/osearch/searchgroup.cpp | 8 | ||||
-rw-r--r-- | core/pim/osearch/todoitem.cpp | 16 | ||||
-rw-r--r-- | core/pim/osearch/todoitem.h | 9 | ||||
-rw-r--r-- | core/pim/osearch/todosearch.cpp | 14 | ||||
-rw-r--r-- | core/pim/osearch/todosearch.h | 8 |
23 files changed, 137 insertions, 109 deletions
diff --git a/core/pim/osearch/adresssearch.cpp b/core/pim/osearch/adresssearch.cpp index 7681ea2..dbd6df6 100644 --- a/core/pim/osearch/adresssearch.cpp +++ b/core/pim/osearch/adresssearch.cpp @@ -13,2 +13,5 @@ #include "adresssearch.h" +#include "contactitem.h" + +#include <qpe/resource.h> @@ -17,6 +20,2 @@ //#include <qwhatsthis.h> -#include <qpe/resource.h> -#include <opie/ocontactaccess.h> - -#include "contactitem.h" @@ -26,6 +25,6 @@ AdressSearch::AdressSearch(QListView* parent, QString name): _contacts = 0; - QIconSet is = Resource::loadIconSet( "addressbook/AddressBookSmall" ); + QIconSet is = Resource::loadIconSet( "addressbook/AddressBookSmall" ); setPixmap( 0, is.pixmap( QIconSet::Large, true ) ); - - + + // QWhatsThis::add( this, QObject::tr("Search the addressbook") ); @@ -46,3 +45,3 @@ void AdressSearch::load() { - _contacts = new OContactAccess("osearch"); + _contacts = new OPimContactAccess("osearch"); } @@ -51,5 +50,5 @@ int AdressSearch::search() { - ORecordList<OContact> results = _contacts->matchRegexp(_search); + OPimRecordList<OPimContact> results = _contacts->matchRegexp(_search); for (uint i = 0; i < results.count(); i++) { - (void)new ContactItem( this, new OContact( results[i] )); + (void)new ContactItem( this, new OPimContact( results[i] )); } diff --git a/core/pim/osearch/adresssearch.h b/core/pim/osearch/adresssearch.h index d5c7622..028521a 100644 --- a/core/pim/osearch/adresssearch.h +++ b/core/pim/osearch/adresssearch.h @@ -1,3 +1 @@ -// -// // C++ Interface: $MODULE$ @@ -16,4 +14,6 @@ #include "searchgroup.h" +#include <opie2/ocontactaccess.h> + +using namespace Opie; -class OContactAccess; @@ -34,3 +34,3 @@ protected: private: - OContactAccess *_contacts; + OPimContactAccess *_contacts; }; diff --git a/core/pim/osearch/applnkitem.cpp b/core/pim/osearch/applnkitem.cpp index 2c4a4cb..06c2b1e 100644 --- a/core/pim/osearch/applnkitem.cpp +++ b/core/pim/osearch/applnkitem.cpp @@ -15,5 +15,6 @@ #include <qpe/applnk.h> -#include <qfileinfo.h> #include <qpe/qcopenvelope_qws.h> +#include <qfileinfo.h> + AppLnkItem::AppLnkItem(OListViewItem* parent, AppLnk *app) diff --git a/core/pim/osearch/applnksearch.cpp b/core/pim/osearch/applnksearch.cpp index e8170c5..1c84d66 100644 --- a/core/pim/osearch/applnksearch.cpp +++ b/core/pim/osearch/applnksearch.cpp @@ -13,2 +13,3 @@ #include "applnksearch.h" +#include "applnkitem.h" @@ -16,7 +17,5 @@ #include <qpe/qpeapplication.h> -#include <qiconset.h> #include <qpe/resource.h> -#include "applnkitem.h" - +#include <qiconset.h> @@ -45,3 +44,3 @@ int AppLnkSearch::search() QList<AppLnk> appList = _apps->children(); - + for ( AppLnk *app = appList.first(); app != 0; app = appList.next() ){ @@ -49,3 +48,3 @@ int AppLnkSearch::search() || (_search.match(app->comment()) != -1) - || (_search.match(app->exec()) != -1) ) { + || (_search.match(app->exec()) != -1) ) { insertItem( app ); @@ -53,4 +52,4 @@ int AppLnkSearch::search() if (searchFile( app )) - insertItem( app ); - qApp->processEvents( 100 ); + insertItem( app ); + qApp->processEvents( 100 ); } diff --git a/core/pim/osearch/contactitem.cpp b/core/pim/osearch/contactitem.cpp index c4738ae..eedc374 100644 --- a/core/pim/osearch/contactitem.cpp +++ b/core/pim/osearch/contactitem.cpp @@ -14,4 +14,2 @@ -#include <qpixmap.h> -#include <opie/ocontact.h> #include <qpe/resource.h> @@ -19,3 +17,6 @@ -ContactItem::ContactItem(OListViewItem* parent, OContact *contact) +#include <qpixmap.h> + + +ContactItem::ContactItem(OListViewItem* parent, OPimContact *contact) : ResultItem(parent) diff --git a/core/pim/osearch/contactitem.h b/core/pim/osearch/contactitem.h index d6303e2..3c553fc 100644 --- a/core/pim/osearch/contactitem.h +++ b/core/pim/osearch/contactitem.h @@ -15,5 +15,8 @@ +#include <opie2/opimrecord.h> +#include <opie2/opimcontact.h> + #include "resultitem.h" -class OContact; +using namespace Opie; @@ -25,3 +28,3 @@ class ContactItem : public ResultItem public: - ContactItem(OListViewItem* parent, OContact *contact); + ContactItem(OListViewItem* parent, OPimContact *contact); @@ -36,3 +39,3 @@ private: void setIcon(); - OContact *_contact; + OPimContact *_contact; diff --git a/core/pim/osearch/datebooksearch.cpp b/core/pim/osearch/datebooksearch.cpp index 50c76e0..2b4660a 100644 --- a/core/pim/osearch/datebooksearch.cpp +++ b/core/pim/osearch/datebooksearch.cpp @@ -4,3 +4,3 @@ // -// Description: +// Description: // @@ -13,10 +13,11 @@ #include "datebooksearch.h" - #include "eventitem.h" +#include <opie2/opimevent.h> +#include <opie2/opimrecurrence.h> + + #include <qpe/resource.h> #include <qpe/config.h> -#include <opie/oevent.h> -#include <opie/orecur.h> -#include <opie/odatebookaccess.h> + #include <qiconset.h> @@ -26,2 +27,4 @@ + + DatebookSearch::DatebookSearch(QListView* parent, QString name) @@ -61,5 +64,5 @@ int DatebookSearch::search() { - ORecordList<OEvent> results = _dates->matchRegexp(_search); + OPimRecordList<OPimEvent> results = _dates->matchRegexp(_search); for (uint i = 0; i < results.count(); i++) - insertItem( new OEvent( results[i] ) ); + insertItem( new OPimEvent( results[i] ) ); return _resultCount; @@ -69,3 +72,3 @@ void DatebookSearch::insertItem( void *rec ) { - OEvent *ev = (OEvent*)rec; + OPimEvent *ev = (OPimEvent*)rec; if ( !actionShowPastEvents->isOn() && diff --git a/core/pim/osearch/datebooksearch.h b/core/pim/osearch/datebooksearch.h index a6d115e..2af727d 100644 --- a/core/pim/osearch/datebooksearch.h +++ b/core/pim/osearch/datebooksearch.h @@ -16,4 +16,6 @@ #include "searchgroup.h" +#include <opie2/odatebookaccess.h> + +using namespace Opie; -class ODateBookAccess; class QAction; diff --git a/core/pim/osearch/doclnkitem.cpp b/core/pim/osearch/doclnkitem.cpp index 56eb26a..1516b8e 100644 --- a/core/pim/osearch/doclnkitem.cpp +++ b/core/pim/osearch/doclnkitem.cpp @@ -15,2 +15,4 @@ #include <qpe/applnk.h> +#include <qpe/qcopenvelope_qws.h> + #include <qfile.h> @@ -18,3 +20,2 @@ #include <qfileinfo.h> -#include <qpe/qcopenvelope_qws.h> diff --git a/core/pim/osearch/doclnksearch.cpp b/core/pim/osearch/doclnksearch.cpp index b03dbd8..c73dcbf 100644 --- a/core/pim/osearch/doclnksearch.cpp +++ b/core/pim/osearch/doclnksearch.cpp @@ -13,2 +13,13 @@ + +#include "doclnkitem.h" +#include "doclnksearch.h" + +#include <opie2/owait.h> + +#include <qpe/applnk.h> +#include <qpe/config.h> +#include <qpe/resource.h> +#include <qpe/qpeapplication.h> + #include <qaction.h> @@ -18,10 +29,3 @@ #include <qtextstream.h> -#include <qpe/applnk.h> -#include <qpe/config.h> -#include <qpe/resource.h> -#include <qpe/qpeapplication.h> -#include <opie/owait.h> -#include "doclnkitem.h" -#include "doclnksearch.h" diff --git a/core/pim/osearch/eventitem.cpp b/core/pim/osearch/eventitem.cpp index 3228093..f6e34fe 100644 --- a/core/pim/osearch/eventitem.cpp +++ b/core/pim/osearch/eventitem.cpp @@ -14,10 +14,10 @@ -#include <qdatetime.h> -#include <qpixmap.h> + #include <qpe/resource.h> #include <qpe/qcopenvelope_qws.h> -//#include <qwhatsthis.h> -#include <opie/oevent.h> -EventItem::EventItem(OListViewItem* parent, OEvent *event) +#include <qdatetime.h> +#include <qpixmap.h> + +EventItem::EventItem(OListViewItem* parent, OPimEvent *event) : ResultItem(parent) diff --git a/core/pim/osearch/eventitem.h b/core/pim/osearch/eventitem.h index 5f9c9fc..68923f1 100644 --- a/core/pim/osearch/eventitem.h +++ b/core/pim/osearch/eventitem.h @@ -17,3 +17,5 @@ -class OEvent; +#include <opie2/opimevent.h> + +using namespace Opie; @@ -25,3 +27,3 @@ class EventItem : public ResultItem public: - EventItem(OListViewItem* parent, OEvent *event); + EventItem(OListViewItem* parent, OPimEvent *event); @@ -35,3 +37,3 @@ private: void setIcon(); - OEvent *_event; + OPimEvent *_event; diff --git a/core/pim/osearch/mainwindow.cpp b/core/pim/osearch/mainwindow.cpp index 55302cb..95f5967 100644 --- a/core/pim/osearch/mainwindow.cpp +++ b/core/pim/osearch/mainwindow.cpp @@ -12,3 +12,23 @@ +#include "olistview.h" +#include "olistviewitem.h" +#include "resultitem.h" +#include "adresssearch.h" +#include "todosearch.h" +#include "datebooksearch.h" +#include "applnksearch.h" +#include "doclnksearch.h" +#include "mainwindow.h" +#include <opie2/owait.h> + +#include <qpe/qpemessagebox.h> +#include <qpe/resource.h> +#include <qpe/config.h> + +#include <qpe/qpeapplication.h> +#include <qpe/config.h> +#include <qpe/global.h> + +#include <qtoolbar.h> #include <qaction.h> @@ -31,22 +51,6 @@ #include <qmenubar.h> -#include <qpe/qpemessagebox.h> -#include <qpe/resource.h> -#include <qpe/config.h> -#include <qtoolbar.h> -#include <qpe/qpeapplication.h> -#include <qpe/config.h> -#include <qpe/global.h> -#include <opie/owait.h> -#include "olistview.h" -#include "olistviewitem.h" -#include "resultitem.h" -#include "adresssearch.h" -#include "todosearch.h" -#include "datebooksearch.h" -#include "applnksearch.h" -#include "doclnksearch.h" -#include "mainwindow.h" -static const char* const image1_data[] = { + +static const char* const image1_data[] = { "14 14 3 1", @@ -180,3 +184,3 @@ void MainWindow::makeMenu() LabelEnterText->setText( tr( "Search for: " ) ); - + addToolBar( searchBar, "Search", QMainWindow::Top, TRUE ); @@ -187,9 +191,9 @@ void MainWindow::makeMenu() searchBar->setStretchableWidget( searchEdit ); - + //Search button SearchAllAction->addTo( searchBar ); - + //image ripped of off opie-login/loginwindow.cpp QPixmap image1( ( const char** ) image1_data ); - + //Clear text @@ -198,3 +202,3 @@ void MainWindow::makeMenu() ClearSearchText->setPixmap( image1 ); - + connect( searchEdit, SIGNAL( textChanged( const QString & ) ),this, SLOT( setSearch( const QString & ) ) ); diff --git a/core/pim/osearch/mainwindow.h b/core/pim/osearch/mainwindow.h index 9886053..bf3081f 100644 --- a/core/pim/osearch/mainwindow.h +++ b/core/pim/osearch/mainwindow.h @@ -18,3 +18,2 @@ #include <qlist.h> - #include <qmap.h> diff --git a/core/pim/osearch/olistview.cpp b/core/pim/osearch/olistview.cpp index e678d63..7a7cb26 100644 --- a/core/pim/osearch/olistview.cpp +++ b/core/pim/osearch/olistview.cpp @@ -12,5 +12,8 @@ #include "olistviewitem.h" -#include <qmessagebox.h> + #include <qpe/qpeapplication.h> +#include <qmessagebox.h> + + OListView::OListView(QWidget *parent, const char *name ) @@ -19,6 +22,6 @@ OListView::OListView(QWidget *parent, const char *name ) - setRootIsDecorated( true ); + setRootIsDecorated( true ); addColumn(tr("Results"),qApp->desktop()->width() - 9 ); //setColumnWidthMode(0, Manual); - + setSorting( -1 ); diff --git a/core/pim/osearch/osearch.pro b/core/pim/osearch/osearch.pro index c988f48..7412de9 100644 --- a/core/pim/osearch/osearch.pro +++ b/core/pim/osearch/osearch.pro @@ -37,3 +37,3 @@ INCLUDEPATH = $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include -LIBS += -lqpe -lopie +LIBS += -lqpe -lopiecore2 -lopiepim2 -lopieui2 include ( $(OPIEDIR)/include.pro ) diff --git a/core/pim/osearch/resultitem.cpp b/core/pim/osearch/resultitem.cpp index 2c1e95a..f051b12 100644 --- a/core/pim/osearch/resultitem.cpp +++ b/core/pim/osearch/resultitem.cpp @@ -14,6 +14,4 @@ -#include <qmessagebox.h> - -#include <opie/otodo.h> +#include <qmessagebox.h> diff --git a/core/pim/osearch/resultitem.h b/core/pim/osearch/resultitem.h index 9e87f99..1c14e8f 100644 --- a/core/pim/osearch/resultitem.h +++ b/core/pim/osearch/resultitem.h @@ -15,6 +15,6 @@ -#include <qintdict.h> - #include "olistviewitem.h" +#include <qintdict.h> + /** diff --git a/core/pim/osearch/searchgroup.cpp b/core/pim/osearch/searchgroup.cpp index 0b58176..5377b9f 100644 --- a/core/pim/osearch/searchgroup.cpp +++ b/core/pim/osearch/searchgroup.cpp @@ -12,2 +12,6 @@ // +#include "olistviewitem.h" +#include "searchgroup.h" + +#include <opie2/owait.h> @@ -16,6 +20,2 @@ #include <qapplication.h> -#include <opie/owait.h> - -#include "olistviewitem.h" -#include "searchgroup.h" diff --git a/core/pim/osearch/todoitem.cpp b/core/pim/osearch/todoitem.cpp index 9808a04..c20f1fd 100644 --- a/core/pim/osearch/todoitem.cpp +++ b/core/pim/osearch/todoitem.cpp @@ -14,4 +14,3 @@ -#include <opie/otodo.h> -#include <qpixmap.h> + #include <qpe/resource.h> @@ -19,3 +18,6 @@ -TodoItem::TodoItem(OListViewItem* parent, OTodo *todo) +#include <qpixmap.h> + + +TodoItem::TodoItem(OListViewItem* parent, OPimTodo *todo) : ResultItem(parent) @@ -63,12 +65,12 @@ void TodoItem::setIcon() break; - case OTodo::Description: + case OPimTodo::Description: icon = Resource::loadPixmap( "txt" ); break; - case OTodo::Summary: + case OPimTodo::Summary: icon = Resource::loadPixmap( "osearch/summary" ); break; - case OTodo::Priority: + case OPimTodo::Priority: icon = Resource::loadPixmap( "todo/priority1" ); break; - case OTodo::HasDate: + case OPimTodo::HasDate: icon = Resource::loadPixmap( "osearch/clock" ); diff --git a/core/pim/osearch/todoitem.h b/core/pim/osearch/todoitem.h index cc78e57..7c8537b 100644 --- a/core/pim/osearch/todoitem.h +++ b/core/pim/osearch/todoitem.h @@ -15,4 +15,7 @@ + +#include <opie2/opimtodo.h> #include "resultitem.h" -class OTodo; + +using namespace Opie; @@ -24,3 +27,3 @@ class TodoItem : public ResultItem public: - TodoItem(OListViewItem* parent, OTodo *todo); + TodoItem(OListViewItem* parent, OPimTodo *todo); ~TodoItem(); @@ -33,3 +36,3 @@ private: void setIcon(); - OTodo *_todo; + OPimTodo *_todo; diff --git a/core/pim/osearch/todosearch.cpp b/core/pim/osearch/todosearch.cpp index 8de875e..5042803 100644 --- a/core/pim/osearch/todosearch.cpp +++ b/core/pim/osearch/todosearch.cpp @@ -13,7 +13,7 @@ #include "todosearch.h" +#include "todoitem.h" -#include <opie/otodoaccess.h> -#include <opie/otodo.h> #include <qpe/resource.h> #include <qpe/config.h> + #include <qiconset.h> @@ -21,3 +21,3 @@ #include <qpopupmenu.h> -#include "todoitem.h" + @@ -51,3 +51,3 @@ void TodoSearch::load() { - _todos = new OTodoAccess(); + _todos = new OPimTodoAccess(); _todos->load(); @@ -57,5 +57,5 @@ int TodoSearch::search() { - ORecordList<OTodo> results = _todos->matchRegexp(_search); + OPimRecordList<OPimTodo> results = _todos->matchRegexp(_search); for (uint i = 0; i < results.count(); i++) - insertItem( new OTodo( results[i] )); + insertItem( new OPimTodo( results[i] )); return _resultCount; @@ -65,3 +65,3 @@ void TodoSearch::insertItem( void *rec ) { - OTodo *todo = (OTodo*)rec; + OPimTodo *todo = (OPimTodo*)rec; if (!actionShowCompleted->isOn() && diff --git a/core/pim/osearch/todosearch.h b/core/pim/osearch/todosearch.h index ee175da..740e483 100644 --- a/core/pim/osearch/todosearch.h +++ b/core/pim/osearch/todosearch.h @@ -17,5 +17,9 @@ -class OTodoAccess; +#include <opie2/otodoaccess.h> +#include <opie2/opimtodo.h> + class QAction; +using namespace Opie; + /** @@ -37,3 +41,3 @@ protected: private: - OTodoAccess *_todos; + OPimTodoAccess *_todos; QAction *actionShowCompleted; |