author | zecke <zecke> | 2002-11-03 11:03:20 (UTC) |
---|---|---|
committer | zecke <zecke> | 2002-11-03 11:03:20 (UTC) |
commit | 207f7430db6c90e88825ea2bedc9ae1bf68e3d99 (patch) (unidiff) | |
tree | fb69b58f130c0b0a17224989f26aa4af5939b33e | |
parent | 485fae36510cb42690c9df55fae64312b1e656ae (diff) | |
download | opie-207f7430db6c90e88825ea2bedc9ae1bf68e3d99.zip opie-207f7430db6c90e88825ea2bedc9ae1bf68e3d99.tar.gz opie-207f7430db6c90e88825ea2bedc9ae1bf68e3d99.tar.bz2 |
Patch by Simon Hausmann to suit gcc3 needs
many thanks
-rw-r--r-- | libopie/oclickablelabel.cpp | 2 | ||||
-rw-r--r-- | libopie/ofileselector.cc | 9 | ||||
-rw-r--r-- | libopie/ofileselector.h | 2 | ||||
-rw-r--r-- | libopie/ofileselector/odefaultfactories.cpp | 4 | ||||
-rw-r--r-- | libopie/ofileselector/odefaultfactories.h | 1 | ||||
-rw-r--r-- | libopie/ofileselector/ofileselector.cpp | 3 | ||||
-rw-r--r-- | libopie/pim/opimaccessbackend.h | 4 | ||||
-rw-r--r-- | libopie/pim/opimaccesstemplate.h | 10 | ||||
-rw-r--r-- | libopie/pim/orecordlist.h | 4 | ||||
-rw-r--r-- | libopie/pim/otodo.cpp | 2 | ||||
-rw-r--r-- | libopie2/opiepim/backend/opimaccessbackend.h | 4 | ||||
-rw-r--r-- | libopie2/opiepim/core/opimaccesstemplate.h | 10 | ||||
-rw-r--r-- | libopie2/opiepim/orecordlist.h | 4 | ||||
-rw-r--r-- | libopie2/opiepim/otodo.cpp | 2 |
14 files changed, 28 insertions, 33 deletions
diff --git a/libopie/oclickablelabel.cpp b/libopie/oclickablelabel.cpp index 43a0524..5768529 100644 --- a/libopie/oclickablelabel.cpp +++ b/libopie/oclickablelabel.cpp | |||
@@ -8,25 +8,25 @@ OClickableLabel::OClickableLabel(QWidget* parent, | |||
8 | { | 8 | { |
9 | textInverted=false; | 9 | textInverted=false; |
10 | isToggle=false; | 10 | isToggle=false; |
11 | isDown=false; | 11 | isDown=false; |
12 | showState(false); | 12 | showState(false); |
13 | setFrameShadow(Sunken); | 13 | setFrameShadow(Sunken); |
14 | } | 14 | } |
15 | 15 | ||
16 | void OClickableLabel::setToggleButton(bool t) { | 16 | void OClickableLabel::setToggleButton(bool t) { |
17 | isToggle=t; | 17 | isToggle=t; |
18 | } | 18 | } |
19 | 19 | ||
20 | void OClickableLabel::mousePressEvent( QMouseEvent *e ) { | 20 | void OClickableLabel::mousePressEvent( QMouseEvent * /*e*/ ) { |
21 | if (isToggle && isDown) { | 21 | if (isToggle && isDown) { |
22 | showState(false); | 22 | showState(false); |
23 | } else { | 23 | } else { |
24 | showState(true); | 24 | showState(true); |
25 | } | 25 | } |
26 | } | 26 | } |
27 | 27 | ||
28 | void OClickableLabel::mouseReleaseEvent( QMouseEvent *e ) { | 28 | void OClickableLabel::mouseReleaseEvent( QMouseEvent *e ) { |
29 | if (rect().contains(e->pos()) && isToggle) isDown=!isDown; | 29 | if (rect().contains(e->pos()) && isToggle) isDown=!isDown; |
30 | 30 | ||
31 | if (isToggle && isDown) { | 31 | if (isToggle && isDown) { |
32 | showState(true); | 32 | showState(true); |
diff --git a/libopie/ofileselector.cc b/libopie/ofileselector.cc index 9534667..6a6a300 100644 --- a/libopie/ofileselector.cc +++ b/libopie/ofileselector.cc | |||
@@ -366,25 +366,25 @@ QStringList OFileSelector::selectedPaths() const | |||
366 | QStringList list; | 366 | QStringList list; |
367 | list << selectedPath(); | 367 | list << selectedPath(); |
368 | return list; | 368 | return list; |
369 | } | 369 | } |
370 | QString OFileSelector::directory()const | 370 | QString OFileSelector::directory()const |
371 | { | 371 | { |
372 | if( m_selector == NORMAL ) | 372 | if( m_selector == NORMAL ) |
373 | return QPEApplication::documentDir(); | 373 | return QPEApplication::documentDir(); |
374 | 374 | ||
375 | return QDir(m_currentDir).absPath(); | 375 | return QDir(m_currentDir).absPath(); |
376 | } | 376 | } |
377 | 377 | ||
378 | int OFileSelector::fileCount() | 378 | int OFileSelector::fileCount() const |
379 | { | 379 | { |
380 | int count; | 380 | int count; |
381 | switch( m_selector ){ | 381 | switch( m_selector ){ |
382 | case NORMAL: | 382 | case NORMAL: |
383 | count = m_select->fileCount(); | 383 | count = m_select->fileCount(); |
384 | break; | 384 | break; |
385 | //case CUSTOM: | 385 | //case CUSTOM: |
386 | case EXTENDED: | 386 | case EXTENDED: |
387 | case EXTENDED_ALL: | 387 | case EXTENDED_ALL: |
388 | default: | 388 | default: |
389 | count = m_View->childCount(); | 389 | count = m_View->childCount(); |
390 | break; | 390 | break; |
@@ -673,25 +673,25 @@ void OFileSelector::initVars() | |||
673 | m_lay = 0; | 673 | m_lay = 0; |
674 | m_Oselector = 0; | 674 | m_Oselector = 0; |
675 | m_boxToolbar = 0; | 675 | m_boxToolbar = 0; |
676 | m_boxOk = 0; | 676 | m_boxOk = 0; |
677 | m_boxName = 0; | 677 | m_boxName = 0; |
678 | m_boxView = 0; | 678 | m_boxView = 0; |
679 | m_custom = 0; | 679 | m_custom = 0; |
680 | m_edit = 0; | 680 | m_edit = 0; |
681 | m_fnLabel = 0; | 681 | m_fnLabel = 0; |
682 | m_new = 0; | 682 | m_new = 0; |
683 | m_close = 0; | 683 | m_close = 0; |
684 | } | 684 | } |
685 | void OFileSelector::addFile(const QString &mime, QFileInfo *info, bool symlink) | 685 | void OFileSelector::addFile(const QString &/*mime*/, QFileInfo *info, bool symlink) |
686 | { | 686 | { |
687 | if(!m_files) | 687 | if(!m_files) |
688 | return; | 688 | return; |
689 | // if( !compliesMime(info->absFilePath(), mime ) ) | 689 | // if( !compliesMime(info->absFilePath(), mime ) ) |
690 | // return; | 690 | // return; |
691 | MimeType type( info->absFilePath() ); | 691 | MimeType type( info->absFilePath() ); |
692 | if (!compliesMime( type.id() ) ) | 692 | if (!compliesMime( type.id() ) ) |
693 | return; | 693 | return; |
694 | 694 | ||
695 | QPixmap pix = type.pixmap(); | 695 | QPixmap pix = type.pixmap(); |
696 | QString dir; | 696 | QString dir; |
697 | QString name; | 697 | QString name; |
@@ -705,25 +705,25 @@ void OFileSelector::addFile(const QString &mime, QFileInfo *info, bool symlink) | |||
705 | name = info->fileName(); | 705 | name = info->fileName(); |
706 | if( ( m_mode == OPEN && !info->isReadable() )|| | 706 | if( ( m_mode == OPEN && !info->isReadable() )|| |
707 | ( m_mode == SAVE && !info->isWritable() ) ){ | 707 | ( m_mode == SAVE && !info->isWritable() ) ){ |
708 | 708 | ||
709 | locked = true; pix = Resource::loadPixmap("locked"); | 709 | locked = true; pix = Resource::loadPixmap("locked"); |
710 | } | 710 | } |
711 | } | 711 | } |
712 | new OFileSelectorItem( m_View, pix, name, | 712 | new OFileSelectorItem( m_View, pix, name, |
713 | info->lastModified().toString(), | 713 | info->lastModified().toString(), |
714 | QString::number( info->size() ), | 714 | QString::number( info->size() ), |
715 | dir, locked ); | 715 | dir, locked ); |
716 | } | 716 | } |
717 | void OFileSelector::addDir(const QString &mime, QFileInfo *info, bool symlink ) | 717 | void OFileSelector::addDir(const QString &/*mime*/, QFileInfo *info, bool symlink ) |
718 | { | 718 | { |
719 | if(!m_dir) | 719 | if(!m_dir) |
720 | return; | 720 | return; |
721 | if( m_selector == EXTENDED_ALL || m_selector == EXTENDED ){ | 721 | if( m_selector == EXTENDED_ALL || m_selector == EXTENDED ){ |
722 | bool locked = false; | 722 | bool locked = false; |
723 | QString name; | 723 | QString name; |
724 | QPixmap pix; | 724 | QPixmap pix; |
725 | if( ( m_mode == OPEN && !info->isReadable() ) || ( m_mode == SAVE && !info->isWritable() ) ){ | 725 | if( ( m_mode == OPEN && !info->isReadable() ) || ( m_mode == SAVE && !info->isWritable() ) ){ |
726 | locked = true; | 726 | locked = true; |
727 | if( symlink ) | 727 | if( symlink ) |
728 | pix = (*m_pixmaps)["symlinkedlocked"]; | 728 | pix = (*m_pixmaps)["symlinkedlocked"]; |
729 | else | 729 | else |
@@ -1009,25 +1009,24 @@ bool OFileSelector::compliesMime( const QString& mime ) { | |||
1009 | else qWarning("found"), list = it.data(); | 1009 | else qWarning("found"), list = it.data(); |
1010 | } | 1010 | } |
1011 | // dump it now | 1011 | // dump it now |
1012 | //for ( QStringList::Iterator it = list.begin(); it != list.end(); ++it ) { | 1012 | //for ( QStringList::Iterator it = list.begin(); it != list.end(); ++it ) { |
1013 | // qWarning( "%s", (*it).latin1() ); | 1013 | // qWarning( "%s", (*it).latin1() ); |
1014 | //} | 1014 | //} |
1015 | 1015 | ||
1016 | 1016 | ||
1017 | if ( list.contains(mime) ) return true; | 1017 | if ( list.contains(mime) ) return true; |
1018 | qWarning("list doesn't contain it "); | 1018 | qWarning("list doesn't contain it "); |
1019 | QStringList::Iterator it2; | 1019 | QStringList::Iterator it2; |
1020 | int pos; | 1020 | int pos; |
1021 | int pos2; | ||
1022 | for ( it2 = list.begin(); it2 != list.end(); ++it2 ) { | 1021 | for ( it2 = list.begin(); it2 != list.end(); ++it2 ) { |
1023 | pos = (*it2).findRev("/*"); | 1022 | pos = (*it2).findRev("/*"); |
1024 | if ( pos >= 0 ) { | 1023 | if ( pos >= 0 ) { |
1025 | if ( mime.contains( (*it2).left(pos) ) ) return true; | 1024 | if ( mime.contains( (*it2).left(pos) ) ) return true; |
1026 | } | 1025 | } |
1027 | } | 1026 | } |
1028 | return false; | 1027 | return false; |
1029 | } | 1028 | } |
1030 | void OFileSelector::slotFileSelected( const QString &string ) | 1029 | void OFileSelector::slotFileSelected( const QString &string ) |
1031 | { | 1030 | { |
1032 | if( m_shLne ) | 1031 | if( m_shLne ) |
1033 | m_edit->setText( string ); | 1032 | m_edit->setText( string ); |
@@ -1096,25 +1095,25 @@ void OFileSelector::slotClicked( int button, QListViewItem *item, const QPoint & | |||
1096 | } | 1095 | } |
1097 | } | 1096 | } |
1098 | } | 1097 | } |
1099 | void OFileSelector::slotRightButton(int button, QListViewItem *item, const QPoint &, int ) | 1098 | void OFileSelector::slotRightButton(int button, QListViewItem *item, const QPoint &, int ) |
1100 | { | 1099 | { |
1101 | if( item == 0 ) | 1100 | if( item == 0 ) |
1102 | return; | 1101 | return; |
1103 | 1102 | ||
1104 | if( button != Qt::RightButton ) | 1103 | if( button != Qt::RightButton ) |
1105 | return; | 1104 | return; |
1106 | slotContextMenu( item ); | 1105 | slotContextMenu( item ); |
1107 | } | 1106 | } |
1108 | void OFileSelector::slotContextMenu( QListViewItem *item) | 1107 | void OFileSelector::slotContextMenu( QListViewItem * /*item*/) |
1109 | { | 1108 | { |
1110 | 1109 | ||
1111 | } | 1110 | } |
1112 | void OFileSelector::slotChangedDir() | 1111 | void OFileSelector::slotChangedDir() |
1113 | { | 1112 | { |
1114 | OFileSelectorItem *sel = (OFileSelectorItem*)m_View->currentItem(); | 1113 | OFileSelectorItem *sel = (OFileSelectorItem*)m_View->currentItem(); |
1115 | if(sel->isDir() ){ | 1114 | if(sel->isDir() ){ |
1116 | QStringList str = QStringList::split("->", sel->text(1) ); | 1115 | QStringList str = QStringList::split("->", sel->text(1) ); |
1117 | cd( sel->directory() + "/" + str[0].stripWhiteSpace() ); | 1116 | cd( sel->directory() + "/" + str[0].stripWhiteSpace() ); |
1118 | } | 1117 | } |
1119 | } | 1118 | } |
1120 | void OFileSelector::slotOpen() | 1119 | void OFileSelector::slotOpen() |
diff --git a/libopie/ofileselector.h b/libopie/ofileselector.h index f2d5f84..17c494e 100644 --- a/libopie/ofileselector.h +++ b/libopie/ofileselector.h | |||
@@ -171,25 +171,25 @@ class OFileSelector : public QWidget { | |||
171 | 171 | ||
172 | // void updateLay(); | 172 | // void updateLay(); |
173 | 173 | ||
174 | void reparse(); // re reads the dir | 174 | void reparse(); // re reads the dir |
175 | 175 | ||
176 | QString selectedName( )const; | 176 | QString selectedName( )const; |
177 | QStringList selectedNames()const; | 177 | QStringList selectedNames()const; |
178 | 178 | ||
179 | QString selectedPath() const; | 179 | QString selectedPath() const; |
180 | QStringList selectedPaths() const; | 180 | QStringList selectedPaths() const; |
181 | 181 | ||
182 | QString directory()const; | 182 | QString directory()const; |
183 | int fileCount(); | 183 | int fileCount() const; |
184 | 184 | ||
185 | /* the user needs to delete it */ | 185 | /* the user needs to delete it */ |
186 | DocLnk selectedDocument()const; | 186 | DocLnk selectedDocument()const; |
187 | /* the user needs to delete it */ | 187 | /* the user needs to delete it */ |
188 | QValueList<DocLnk> selectedDocuments()const; | 188 | QValueList<DocLnk> selectedDocuments()const; |
189 | 189 | ||
190 | signals: | 190 | signals: |
191 | void fileSelected( const DocLnk & ); | 191 | void fileSelected( const DocLnk & ); |
192 | void fileSelected( const QString & ); | 192 | void fileSelected( const QString & ); |
193 | void dirSelected(const QString &dir ); | 193 | void dirSelected(const QString &dir ); |
194 | void closeMe(); | 194 | void closeMe(); |
195 | void ok(); | 195 | void ok(); |
diff --git a/libopie/ofileselector/odefaultfactories.cpp b/libopie/ofileselector/odefaultfactories.cpp index c8efffb..2f8ef9b 100644 --- a/libopie/ofileselector/odefaultfactories.cpp +++ b/libopie/ofileselector/odefaultfactories.cpp | |||
@@ -1,23 +1,19 @@ | |||
1 | #include "ofilelistview.h" | 1 | #include "ofilelistview.h" |
2 | #include "ofileiconview.h" | ||
3 | #include "olocallister.h" | 2 | #include "olocallister.h" |
4 | 3 | ||
5 | 4 | ||
6 | #include "odefaultfactories.h" | 5 | #include "odefaultfactories.h" |
7 | 6 | ||
8 | extern "C" { | 7 | extern "C" { |
9 | 8 | ||
10 | 9 | ||
11 | OFileView* newFileIconView( OFileSelector* sel, QWidget* parent ) { | ||
12 | return new OFileIconView( parent, sel ); | ||
13 | } | ||
14 | 10 | ||
15 | OFileView* newFileListView( OFileSelector* sel, QWidget* par ) { | 11 | OFileView* newFileListView( OFileSelector* sel, QWidget* par ) { |
16 | return new OFileListView(par, sel ); | 12 | return new OFileListView(par, sel ); |
17 | } | 13 | } |
18 | 14 | ||
19 | OLister* newLocalLister( OFileSelector* sel) { | 15 | OLister* newLocalLister( OFileSelector* sel) { |
20 | return new OLocalLister( sel ); | 16 | return new OLocalLister( sel ); |
21 | } | 17 | } |
22 | 18 | ||
23 | }; | 19 | }; |
diff --git a/libopie/ofileselector/odefaultfactories.h b/libopie/ofileselector/odefaultfactories.h index b4c35af..0cc90e5 100644 --- a/libopie/ofileselector/odefaultfactories.h +++ b/libopie/ofileselector/odefaultfactories.h | |||
@@ -1,17 +1,16 @@ | |||
1 | #ifndef OPIE_DEFAULT_FACTORIES_H | 1 | #ifndef OPIE_DEFAULT_FACTORIES_H |
2 | #define OPIE_DEFAULT_FACTORIES_H | 2 | #define OPIE_DEFAULT_FACTORIES_H |
3 | 3 | ||
4 | #include "ofilefactory.h" | 4 | #include "ofilefactory.h" |
5 | 5 | ||
6 | extern "C" { | 6 | extern "C" { |
7 | 7 | ||
8 | OFileView* newFileIconView( OFileSelector*, QWidget* parent ); | ||
9 | OFileView* newFileListView( OFileSelector*, QWidget* parent ); | 8 | OFileView* newFileListView( OFileSelector*, QWidget* parent ); |
10 | 9 | ||
11 | OLister* newLocalLister(OFileSelector* ); | 10 | OLister* newLocalLister(OFileSelector* ); |
12 | 11 | ||
13 | 12 | ||
14 | }; | 13 | }; |
15 | 14 | ||
16 | 15 | ||
17 | #endif | 16 | #endif |
diff --git a/libopie/ofileselector/ofileselector.cpp b/libopie/ofileselector/ofileselector.cpp index c6e923f..abc2889 100644 --- a/libopie/ofileselector/ofileselector.cpp +++ b/libopie/ofileselector/ofileselector.cpp | |||
@@ -967,25 +967,26 @@ void OFileSelector::setView( const QString& lis ) { | |||
967 | m_fileView = factory()->view( list, this, m_mainView ); | 967 | m_fileView = factory()->view( list, this, m_mainView ); |
968 | m_mainView->setWidget( m_fileView->widget() ); | 968 | m_mainView->setWidget( m_fileView->widget() ); |
969 | reparse(); | 969 | reparse(); |
970 | } | 970 | } |
971 | } | 971 | } |
972 | /* | 972 | /* |
973 | * the factory | 973 | * the factory |
974 | */ | 974 | */ |
975 | void OFileSelector::initFactory() { | 975 | void OFileSelector::initFactory() { |
976 | m_fileFactory = new OFileFactory(); | 976 | m_fileFactory = new OFileFactory(); |
977 | m_fileFactory->addLister(tr("Files"), newLocalLister ); | 977 | m_fileFactory->addLister(tr("Files"), newLocalLister ); |
978 | m_fileFactory->addView(tr("List View"), newFileListView ); | 978 | m_fileFactory->addView(tr("List View"), newFileListView ); |
979 | m_fileFactory->addView(tr("Documents"), newFileIconView ); | 979 | /* dummy entry */ |
980 | m_fileFactory->addView(tr("Documents"), newFileListView ); | ||
980 | } | 981 | } |
981 | 982 | ||
982 | void OFileSelector::fillList() { | 983 | void OFileSelector::fillList() { |
983 | qWarning("fill list"); | 984 | qWarning("fill list"); |
984 | if (!m_viewCheck ) | 985 | if (!m_viewCheck ) |
985 | return; | 986 | return; |
986 | 987 | ||
987 | m_viewCheck->clear(); | 988 | m_viewCheck->clear(); |
988 | QStringList list = factory()->views(); | 989 | QStringList list = factory()->views(); |
989 | qWarning("views: " + list.join(";") ); | 990 | qWarning("views: " + list.join(";") ); |
990 | for (QStringList::Iterator it = list.begin(); it != list.end(); ++it ) { | 991 | for (QStringList::Iterator it = list.begin(); it != list.end(); ++it ) { |
991 | qWarning( (*it) ); | 992 | qWarning( (*it) ); |
diff --git a/libopie/pim/opimaccessbackend.h b/libopie/pim/opimaccessbackend.h index 0bd2723..4f00bc9 100644 --- a/libopie/pim/opimaccessbackend.h +++ b/libopie/pim/opimaccessbackend.h | |||
@@ -48,25 +48,25 @@ public: | |||
48 | * queryByExample for T with the SortOrder | 48 | * queryByExample for T with the SortOrder |
49 | * sort | 49 | * sort |
50 | */ | 50 | */ |
51 | virtual QArray<int> queryByExample( const T& t, int sort ) = 0; | 51 | virtual QArray<int> queryByExample( const T& t, int sort ) = 0; |
52 | 52 | ||
53 | /** | 53 | /** |
54 | * find the OPimRecord with uid @param uid | 54 | * find the OPimRecord with uid @param uid |
55 | * returns T and T.isEmpty() if nothing was found | 55 | * returns T and T.isEmpty() if nothing was found |
56 | */ | 56 | */ |
57 | virtual T find(int uid )const = 0; | 57 | virtual T find(int uid )const = 0; |
58 | 58 | ||
59 | virtual T find(int uid, const QArray<int>& items, | 59 | virtual T find(int uid, const QArray<int>& items, |
60 | uint current, Frontend::CacheDirection )const ; | 60 | uint current, typename Frontend::CacheDirection )const ; |
61 | /** | 61 | /** |
62 | * clear the back end | 62 | * clear the back end |
63 | */ | 63 | */ |
64 | virtual void clear() = 0; | 64 | virtual void clear() = 0; |
65 | 65 | ||
66 | /** | 66 | /** |
67 | * add T | 67 | * add T |
68 | */ | 68 | */ |
69 | virtual bool add( const T& t ) = 0; | 69 | virtual bool add( const T& t ) = 0; |
70 | 70 | ||
71 | /** | 71 | /** |
72 | * remove | 72 | * remove |
@@ -118,24 +118,24 @@ void OPimAccessBackend<T>::setFrontend( Frontend* fr ) { | |||
118 | template <class T> | 118 | template <class T> |
119 | void OPimAccessBackend<T>::cache( const T& t )const { | 119 | void OPimAccessBackend<T>::cache( const T& t )const { |
120 | if (m_front ) | 120 | if (m_front ) |
121 | m_front->cache( t ); | 121 | m_front->cache( t ); |
122 | } | 122 | } |
123 | template <class T> | 123 | template <class T> |
124 | void OPimAccessBackend<T>::setSaneCacheSize( int size) { | 124 | void OPimAccessBackend<T>::setSaneCacheSize( int size) { |
125 | if (m_front ) | 125 | if (m_front ) |
126 | m_front->setSaneCacheSize( size ); | 126 | m_front->setSaneCacheSize( size ); |
127 | } | 127 | } |
128 | template <class T> | 128 | template <class T> |
129 | T OPimAccessBackend<T>::find( int uid, const QArray<int>&, | 129 | T OPimAccessBackend<T>::find( int uid, const QArray<int>&, |
130 | uint, Frontend::CacheDirection )const { | 130 | uint, typename Frontend::CacheDirection )const { |
131 | return find( uid ); | 131 | return find( uid ); |
132 | } | 132 | } |
133 | template <class T> | 133 | template <class T> |
134 | void OPimAccessBackend<T>::setReadAhead( uint count ) { | 134 | void OPimAccessBackend<T>::setReadAhead( uint count ) { |
135 | m_read = count; | 135 | m_read = count; |
136 | } | 136 | } |
137 | template <class T> | 137 | template <class T> |
138 | uint OPimAccessBackend<T>::readAhead()const { | 138 | uint OPimAccessBackend<T>::readAhead()const { |
139 | return m_read; | 139 | return m_read; |
140 | } | 140 | } |
141 | #endif | 141 | #endif |
diff --git a/libopie/pim/opimaccesstemplate.h b/libopie/pim/opimaccesstemplate.h index c5523a8..6de68b1 100644 --- a/libopie/pim/opimaccesstemplate.h +++ b/libopie/pim/opimaccesstemplate.h | |||
@@ -70,25 +70,25 @@ public: | |||
70 | */ | 70 | */ |
71 | virtual List queryByExample( const T& t, int querySettings ); | 71 | virtual List queryByExample( const T& t, int querySettings ); |
72 | 72 | ||
73 | /** | 73 | /** |
74 | * find the OPimRecord uid | 74 | * find the OPimRecord uid |
75 | */ | 75 | */ |
76 | virtual T find( int uid )const; | 76 | virtual T find( int uid )const; |
77 | 77 | ||
78 | /** | 78 | /** |
79 | * read ahead cache find method ;) | 79 | * read ahead cache find method ;) |
80 | */ | 80 | */ |
81 | virtual T find( int uid, const QArray<int>&, | 81 | virtual T find( int uid, const QArray<int>&, |
82 | uint current, CacheDirection dir = Forward )const; | 82 | uint current, typename OTemplateBase<T>::CacheDirection dir = OTemplateBase<T>::Forward )const; |
83 | 83 | ||
84 | /* invalidate cache here */ | 84 | /* invalidate cache here */ |
85 | /** | 85 | /** |
86 | * clears the backend and invalidates the backend | 86 | * clears the backend and invalidates the backend |
87 | */ | 87 | */ |
88 | virtual void clear() ; | 88 | virtual void clear() ; |
89 | 89 | ||
90 | /** | 90 | /** |
91 | * add T to the backend | 91 | * add T to the backend |
92 | * @param t The item to add. | 92 | * @param t The item to add. |
93 | * @return <i>true</i> if added successfully. | 93 | * @return <i>true</i> if added successfully. |
94 | */ | 94 | */ |
@@ -156,46 +156,46 @@ bool OPimAccessTemplate<T>::load() { | |||
156 | return m_backEnd->load(); | 156 | return m_backEnd->load(); |
157 | } | 157 | } |
158 | template <class T> | 158 | template <class T> |
159 | bool OPimAccessTemplate<T>::reload() { | 159 | bool OPimAccessTemplate<T>::reload() { |
160 | invalidateCache(); // zecke: I think this should be added (se) | 160 | invalidateCache(); // zecke: I think this should be added (se) |
161 | return m_backEnd->reload(); | 161 | return m_backEnd->reload(); |
162 | } | 162 | } |
163 | template <class T> | 163 | template <class T> |
164 | bool OPimAccessTemplate<T>::save() { | 164 | bool OPimAccessTemplate<T>::save() { |
165 | return m_backEnd->save(); | 165 | return m_backEnd->save(); |
166 | } | 166 | } |
167 | template <class T> | 167 | template <class T> |
168 | OPimAccessTemplate<T>::List OPimAccessTemplate<T>::allRecords()const { | 168 | typename OPimAccessTemplate<T>::List OPimAccessTemplate<T>::allRecords()const { |
169 | QArray<int> ints = m_backEnd->allRecords(); | 169 | QArray<int> ints = m_backEnd->allRecords(); |
170 | List lis(ints, this ); | 170 | List lis(ints, this ); |
171 | return lis; | 171 | return lis; |
172 | } | 172 | } |
173 | template <class T> | 173 | template <class T> |
174 | OPimAccessTemplate<T>::List | 174 | typename OPimAccessTemplate<T>::List |
175 | OPimAccessTemplate<T>::queryByExample( const T& t, int sortOrder ) { | 175 | OPimAccessTemplate<T>::queryByExample( const T& t, int sortOrder ) { |
176 | QArray<int> ints = m_backEnd->queryByExample( t, sortOrder ); | 176 | QArray<int> ints = m_backEnd->queryByExample( t, sortOrder ); |
177 | 177 | ||
178 | List lis(ints, this ); | 178 | List lis(ints, this ); |
179 | return lis; | 179 | return lis; |
180 | } | 180 | } |
181 | template <class T> | 181 | template <class T> |
182 | T OPimAccessTemplate<T>::find( int uid ) const{ | 182 | T OPimAccessTemplate<T>::find( int uid ) const{ |
183 | T t = m_backEnd->find( uid ); | 183 | T t = m_backEnd->find( uid ); |
184 | cache( t ); | 184 | cache( t ); |
185 | return t; | 185 | return t; |
186 | } | 186 | } |
187 | template <class T> | 187 | template <class T> |
188 | T OPimAccessTemplate<T>::find( int uid, const QArray<int>& ar, | 188 | T OPimAccessTemplate<T>::find( int uid, const QArray<int>& ar, |
189 | uint current, CacheDirection dir )const { | 189 | uint current, typename OTemplateBase<T>::CacheDirection dir )const { |
190 | /* | 190 | /* |
191 | * better do T.isEmpty() | 191 | * better do T.isEmpty() |
192 | * after a find this way we would | 192 | * after a find this way we would |
193 | * avoid two finds in QCache... | 193 | * avoid two finds in QCache... |
194 | */ | 194 | */ |
195 | // qWarning("find it now %d", uid ); | 195 | // qWarning("find it now %d", uid ); |
196 | if (m_cache.contains( uid ) ) { | 196 | if (m_cache.contains( uid ) ) { |
197 | return m_cache.find( uid ); | 197 | return m_cache.find( uid ); |
198 | } | 198 | } |
199 | 199 | ||
200 | T t = m_backEnd->find( uid, ar, current, dir ); | 200 | T t = m_backEnd->find( uid, ar, current, dir ); |
201 | cache( t ); | 201 | cache( t ); |
@@ -221,25 +221,25 @@ bool OPimAccessTemplate<T>::remove( int uid ) { | |||
221 | return m_backEnd->remove( uid ); | 221 | return m_backEnd->remove( uid ); |
222 | } | 222 | } |
223 | template <class T> | 223 | template <class T> |
224 | bool OPimAccessTemplate<T>::replace( const T& t ) { | 224 | bool OPimAccessTemplate<T>::replace( const T& t ) { |
225 | m_cache.replace( t ); | 225 | m_cache.replace( t ); |
226 | return m_backEnd->replace( t ); | 226 | return m_backEnd->replace( t ); |
227 | } | 227 | } |
228 | template <class T> | 228 | template <class T> |
229 | void OPimAccessTemplate<T>::invalidateCache() { | 229 | void OPimAccessTemplate<T>::invalidateCache() { |
230 | m_cache.invalidate(); | 230 | m_cache.invalidate(); |
231 | } | 231 | } |
232 | template <class T> | 232 | template <class T> |
233 | OPimAccessTemplate<T>::BackEnd* OPimAccessTemplate<T>::backEnd() { | 233 | typename OPimAccessTemplate<T>::BackEnd* OPimAccessTemplate<T>::backEnd() { |
234 | return m_backEnd; | 234 | return m_backEnd; |
235 | } | 235 | } |
236 | template <class T> | 236 | template <class T> |
237 | bool OPimAccessTemplate<T>::wasChangedExternally()const { | 237 | bool OPimAccessTemplate<T>::wasChangedExternally()const { |
238 | return false; | 238 | return false; |
239 | } | 239 | } |
240 | template <class T> | 240 | template <class T> |
241 | void OPimAccessTemplate<T>::setBackEnd( BackEnd* end ) { | 241 | void OPimAccessTemplate<T>::setBackEnd( BackEnd* end ) { |
242 | m_backEnd = end; | 242 | m_backEnd = end; |
243 | if (m_backEnd ) | 243 | if (m_backEnd ) |
244 | m_backEnd->setFrontend( this ); | 244 | m_backEnd->setFrontend( this ); |
245 | } | 245 | } |
diff --git a/libopie/pim/orecordlist.h b/libopie/pim/orecordlist.h index 8ed41e2..b77a4ab 100644 --- a/libopie/pim/orecordlist.h +++ b/libopie/pim/orecordlist.h | |||
@@ -238,30 +238,30 @@ uint ORecordListIterator<T>::count()const { | |||
238 | } | 238 | } |
239 | template <class T> | 239 | template <class T> |
240 | ORecordList<T>::ORecordList( const QArray<int>& ids, | 240 | ORecordList<T>::ORecordList( const QArray<int>& ids, |
241 | const Base* acc ) | 241 | const Base* acc ) |
242 | : m_ids( ids ), m_acc( acc ) | 242 | : m_ids( ids ), m_acc( acc ) |
243 | { | 243 | { |
244 | } | 244 | } |
245 | template <class T> | 245 | template <class T> |
246 | ORecordList<T>::~ORecordList() { | 246 | ORecordList<T>::~ORecordList() { |
247 | /* nothing to do here */ | 247 | /* nothing to do here */ |
248 | } | 248 | } |
249 | template <class T> | 249 | template <class T> |
250 | ORecordList<T>::Iterator ORecordList<T>::begin() { | 250 | typename ORecordList<T>::Iterator ORecordList<T>::begin() { |
251 | Iterator it( m_ids, m_acc ); | 251 | Iterator it( m_ids, m_acc ); |
252 | return it; | 252 | return it; |
253 | } | 253 | } |
254 | template <class T> | 254 | template <class T> |
255 | ORecordList<T>::Iterator ORecordList<T>::end() { | 255 | typename ORecordList<T>::Iterator ORecordList<T>::end() { |
256 | Iterator it( m_ids, m_acc ); | 256 | Iterator it( m_ids, m_acc ); |
257 | it.m_end = true; | 257 | it.m_end = true; |
258 | it.m_current = m_ids.count(); | 258 | it.m_current = m_ids.count(); |
259 | 259 | ||
260 | return it; | 260 | return it; |
261 | } | 261 | } |
262 | template <class T> | 262 | template <class T> |
263 | uint ORecordList<T>::count()const { | 263 | uint ORecordList<T>::count()const { |
264 | return m_ids.count(); | 264 | return m_ids.count(); |
265 | } | 265 | } |
266 | template <class T> | 266 | template <class T> |
267 | T ORecordList<T>::operator[]( uint i ) { | 267 | T ORecordList<T>::operator[]( uint i ) { |
diff --git a/libopie/pim/otodo.cpp b/libopie/pim/otodo.cpp index 0d5b1d3..4d5cb79 100644 --- a/libopie/pim/otodo.cpp +++ b/libopie/pim/otodo.cpp | |||
@@ -390,16 +390,16 @@ void OTodo::copy( OTodoData* src, OTodoData* dest ) { | |||
390 | dest->desc = src->desc; | 390 | dest->desc = src->desc; |
391 | dest->sum = src->sum; | 391 | dest->sum = src->sum; |
392 | dest->extra = src->extra; | 392 | dest->extra = src->extra; |
393 | dest->prog = src->prog; | 393 | dest->prog = src->prog; |
394 | dest->hasAlarmDateTime = src->hasAlarmDateTime; | 394 | dest->hasAlarmDateTime = src->hasAlarmDateTime; |
395 | dest->alarmDateTime = src->alarmDateTime; | 395 | dest->alarmDateTime = src->alarmDateTime; |
396 | dest->state = src->state; | 396 | dest->state = src->state; |
397 | dest->recur = src->recur; | 397 | dest->recur = src->recur; |
398 | } | 398 | } |
399 | QString OTodo::type() const { | 399 | QString OTodo::type() const { |
400 | return QString::fromLatin1("OTodo"); | 400 | return QString::fromLatin1("OTodo"); |
401 | } | 401 | } |
402 | QString OTodo::recordField(int id )const { | 402 | QString OTodo::recordField(int /*id*/ )const { |
403 | return QString::null; | 403 | return QString::null; |
404 | } | 404 | } |
405 | 405 | ||
diff --git a/libopie2/opiepim/backend/opimaccessbackend.h b/libopie2/opiepim/backend/opimaccessbackend.h index 0bd2723..4f00bc9 100644 --- a/libopie2/opiepim/backend/opimaccessbackend.h +++ b/libopie2/opiepim/backend/opimaccessbackend.h | |||
@@ -48,25 +48,25 @@ public: | |||
48 | * queryByExample for T with the SortOrder | 48 | * queryByExample for T with the SortOrder |
49 | * sort | 49 | * sort |
50 | */ | 50 | */ |
51 | virtual QArray<int> queryByExample( const T& t, int sort ) = 0; | 51 | virtual QArray<int> queryByExample( const T& t, int sort ) = 0; |
52 | 52 | ||
53 | /** | 53 | /** |
54 | * find the OPimRecord with uid @param uid | 54 | * find the OPimRecord with uid @param uid |
55 | * returns T and T.isEmpty() if nothing was found | 55 | * returns T and T.isEmpty() if nothing was found |
56 | */ | 56 | */ |
57 | virtual T find(int uid )const = 0; | 57 | virtual T find(int uid )const = 0; |
58 | 58 | ||
59 | virtual T find(int uid, const QArray<int>& items, | 59 | virtual T find(int uid, const QArray<int>& items, |
60 | uint current, Frontend::CacheDirection )const ; | 60 | uint current, typename Frontend::CacheDirection )const ; |
61 | /** | 61 | /** |
62 | * clear the back end | 62 | * clear the back end |
63 | */ | 63 | */ |
64 | virtual void clear() = 0; | 64 | virtual void clear() = 0; |
65 | 65 | ||
66 | /** | 66 | /** |
67 | * add T | 67 | * add T |
68 | */ | 68 | */ |
69 | virtual bool add( const T& t ) = 0; | 69 | virtual bool add( const T& t ) = 0; |
70 | 70 | ||
71 | /** | 71 | /** |
72 | * remove | 72 | * remove |
@@ -118,24 +118,24 @@ void OPimAccessBackend<T>::setFrontend( Frontend* fr ) { | |||
118 | template <class T> | 118 | template <class T> |
119 | void OPimAccessBackend<T>::cache( const T& t )const { | 119 | void OPimAccessBackend<T>::cache( const T& t )const { |
120 | if (m_front ) | 120 | if (m_front ) |
121 | m_front->cache( t ); | 121 | m_front->cache( t ); |
122 | } | 122 | } |
123 | template <class T> | 123 | template <class T> |
124 | void OPimAccessBackend<T>::setSaneCacheSize( int size) { | 124 | void OPimAccessBackend<T>::setSaneCacheSize( int size) { |
125 | if (m_front ) | 125 | if (m_front ) |
126 | m_front->setSaneCacheSize( size ); | 126 | m_front->setSaneCacheSize( size ); |
127 | } | 127 | } |
128 | template <class T> | 128 | template <class T> |
129 | T OPimAccessBackend<T>::find( int uid, const QArray<int>&, | 129 | T OPimAccessBackend<T>::find( int uid, const QArray<int>&, |
130 | uint, Frontend::CacheDirection )const { | 130 | uint, typename Frontend::CacheDirection )const { |
131 | return find( uid ); | 131 | return find( uid ); |
132 | } | 132 | } |
133 | template <class T> | 133 | template <class T> |
134 | void OPimAccessBackend<T>::setReadAhead( uint count ) { | 134 | void OPimAccessBackend<T>::setReadAhead( uint count ) { |
135 | m_read = count; | 135 | m_read = count; |
136 | } | 136 | } |
137 | template <class T> | 137 | template <class T> |
138 | uint OPimAccessBackend<T>::readAhead()const { | 138 | uint OPimAccessBackend<T>::readAhead()const { |
139 | return m_read; | 139 | return m_read; |
140 | } | 140 | } |
141 | #endif | 141 | #endif |
diff --git a/libopie2/opiepim/core/opimaccesstemplate.h b/libopie2/opiepim/core/opimaccesstemplate.h index c5523a8..6de68b1 100644 --- a/libopie2/opiepim/core/opimaccesstemplate.h +++ b/libopie2/opiepim/core/opimaccesstemplate.h | |||
@@ -70,25 +70,25 @@ public: | |||
70 | */ | 70 | */ |
71 | virtual List queryByExample( const T& t, int querySettings ); | 71 | virtual List queryByExample( const T& t, int querySettings ); |
72 | 72 | ||
73 | /** | 73 | /** |
74 | * find the OPimRecord uid | 74 | * find the OPimRecord uid |
75 | */ | 75 | */ |
76 | virtual T find( int uid )const; | 76 | virtual T find( int uid )const; |
77 | 77 | ||
78 | /** | 78 | /** |
79 | * read ahead cache find method ;) | 79 | * read ahead cache find method ;) |
80 | */ | 80 | */ |
81 | virtual T find( int uid, const QArray<int>&, | 81 | virtual T find( int uid, const QArray<int>&, |
82 | uint current, CacheDirection dir = Forward )const; | 82 | uint current, typename OTemplateBase<T>::CacheDirection dir = OTemplateBase<T>::Forward )const; |
83 | 83 | ||
84 | /* invalidate cache here */ | 84 | /* invalidate cache here */ |
85 | /** | 85 | /** |
86 | * clears the backend and invalidates the backend | 86 | * clears the backend and invalidates the backend |
87 | */ | 87 | */ |
88 | virtual void clear() ; | 88 | virtual void clear() ; |
89 | 89 | ||
90 | /** | 90 | /** |
91 | * add T to the backend | 91 | * add T to the backend |
92 | * @param t The item to add. | 92 | * @param t The item to add. |
93 | * @return <i>true</i> if added successfully. | 93 | * @return <i>true</i> if added successfully. |
94 | */ | 94 | */ |
@@ -156,46 +156,46 @@ bool OPimAccessTemplate<T>::load() { | |||
156 | return m_backEnd->load(); | 156 | return m_backEnd->load(); |
157 | } | 157 | } |
158 | template <class T> | 158 | template <class T> |
159 | bool OPimAccessTemplate<T>::reload() { | 159 | bool OPimAccessTemplate<T>::reload() { |
160 | invalidateCache(); // zecke: I think this should be added (se) | 160 | invalidateCache(); // zecke: I think this should be added (se) |
161 | return m_backEnd->reload(); | 161 | return m_backEnd->reload(); |
162 | } | 162 | } |
163 | template <class T> | 163 | template <class T> |
164 | bool OPimAccessTemplate<T>::save() { | 164 | bool OPimAccessTemplate<T>::save() { |
165 | return m_backEnd->save(); | 165 | return m_backEnd->save(); |
166 | } | 166 | } |
167 | template <class T> | 167 | template <class T> |
168 | OPimAccessTemplate<T>::List OPimAccessTemplate<T>::allRecords()const { | 168 | typename OPimAccessTemplate<T>::List OPimAccessTemplate<T>::allRecords()const { |
169 | QArray<int> ints = m_backEnd->allRecords(); | 169 | QArray<int> ints = m_backEnd->allRecords(); |
170 | List lis(ints, this ); | 170 | List lis(ints, this ); |
171 | return lis; | 171 | return lis; |
172 | } | 172 | } |
173 | template <class T> | 173 | template <class T> |
174 | OPimAccessTemplate<T>::List | 174 | typename OPimAccessTemplate<T>::List |
175 | OPimAccessTemplate<T>::queryByExample( const T& t, int sortOrder ) { | 175 | OPimAccessTemplate<T>::queryByExample( const T& t, int sortOrder ) { |
176 | QArray<int> ints = m_backEnd->queryByExample( t, sortOrder ); | 176 | QArray<int> ints = m_backEnd->queryByExample( t, sortOrder ); |
177 | 177 | ||
178 | List lis(ints, this ); | 178 | List lis(ints, this ); |
179 | return lis; | 179 | return lis; |
180 | } | 180 | } |
181 | template <class T> | 181 | template <class T> |
182 | T OPimAccessTemplate<T>::find( int uid ) const{ | 182 | T OPimAccessTemplate<T>::find( int uid ) const{ |
183 | T t = m_backEnd->find( uid ); | 183 | T t = m_backEnd->find( uid ); |
184 | cache( t ); | 184 | cache( t ); |
185 | return t; | 185 | return t; |
186 | } | 186 | } |
187 | template <class T> | 187 | template <class T> |
188 | T OPimAccessTemplate<T>::find( int uid, const QArray<int>& ar, | 188 | T OPimAccessTemplate<T>::find( int uid, const QArray<int>& ar, |
189 | uint current, CacheDirection dir )const { | 189 | uint current, typename OTemplateBase<T>::CacheDirection dir )const { |
190 | /* | 190 | /* |
191 | * better do T.isEmpty() | 191 | * better do T.isEmpty() |
192 | * after a find this way we would | 192 | * after a find this way we would |
193 | * avoid two finds in QCache... | 193 | * avoid two finds in QCache... |
194 | */ | 194 | */ |
195 | // qWarning("find it now %d", uid ); | 195 | // qWarning("find it now %d", uid ); |
196 | if (m_cache.contains( uid ) ) { | 196 | if (m_cache.contains( uid ) ) { |
197 | return m_cache.find( uid ); | 197 | return m_cache.find( uid ); |
198 | } | 198 | } |
199 | 199 | ||
200 | T t = m_backEnd->find( uid, ar, current, dir ); | 200 | T t = m_backEnd->find( uid, ar, current, dir ); |
201 | cache( t ); | 201 | cache( t ); |
@@ -221,25 +221,25 @@ bool OPimAccessTemplate<T>::remove( int uid ) { | |||
221 | return m_backEnd->remove( uid ); | 221 | return m_backEnd->remove( uid ); |
222 | } | 222 | } |
223 | template <class T> | 223 | template <class T> |
224 | bool OPimAccessTemplate<T>::replace( const T& t ) { | 224 | bool OPimAccessTemplate<T>::replace( const T& t ) { |
225 | m_cache.replace( t ); | 225 | m_cache.replace( t ); |
226 | return m_backEnd->replace( t ); | 226 | return m_backEnd->replace( t ); |
227 | } | 227 | } |
228 | template <class T> | 228 | template <class T> |
229 | void OPimAccessTemplate<T>::invalidateCache() { | 229 | void OPimAccessTemplate<T>::invalidateCache() { |
230 | m_cache.invalidate(); | 230 | m_cache.invalidate(); |
231 | } | 231 | } |
232 | template <class T> | 232 | template <class T> |
233 | OPimAccessTemplate<T>::BackEnd* OPimAccessTemplate<T>::backEnd() { | 233 | typename OPimAccessTemplate<T>::BackEnd* OPimAccessTemplate<T>::backEnd() { |
234 | return m_backEnd; | 234 | return m_backEnd; |
235 | } | 235 | } |
236 | template <class T> | 236 | template <class T> |
237 | bool OPimAccessTemplate<T>::wasChangedExternally()const { | 237 | bool OPimAccessTemplate<T>::wasChangedExternally()const { |
238 | return false; | 238 | return false; |
239 | } | 239 | } |
240 | template <class T> | 240 | template <class T> |
241 | void OPimAccessTemplate<T>::setBackEnd( BackEnd* end ) { | 241 | void OPimAccessTemplate<T>::setBackEnd( BackEnd* end ) { |
242 | m_backEnd = end; | 242 | m_backEnd = end; |
243 | if (m_backEnd ) | 243 | if (m_backEnd ) |
244 | m_backEnd->setFrontend( this ); | 244 | m_backEnd->setFrontend( this ); |
245 | } | 245 | } |
diff --git a/libopie2/opiepim/orecordlist.h b/libopie2/opiepim/orecordlist.h index 8ed41e2..b77a4ab 100644 --- a/libopie2/opiepim/orecordlist.h +++ b/libopie2/opiepim/orecordlist.h | |||
@@ -238,30 +238,30 @@ uint ORecordListIterator<T>::count()const { | |||
238 | } | 238 | } |
239 | template <class T> | 239 | template <class T> |
240 | ORecordList<T>::ORecordList( const QArray<int>& ids, | 240 | ORecordList<T>::ORecordList( const QArray<int>& ids, |
241 | const Base* acc ) | 241 | const Base* acc ) |
242 | : m_ids( ids ), m_acc( acc ) | 242 | : m_ids( ids ), m_acc( acc ) |
243 | { | 243 | { |
244 | } | 244 | } |
245 | template <class T> | 245 | template <class T> |
246 | ORecordList<T>::~ORecordList() { | 246 | ORecordList<T>::~ORecordList() { |
247 | /* nothing to do here */ | 247 | /* nothing to do here */ |
248 | } | 248 | } |
249 | template <class T> | 249 | template <class T> |
250 | ORecordList<T>::Iterator ORecordList<T>::begin() { | 250 | typename ORecordList<T>::Iterator ORecordList<T>::begin() { |
251 | Iterator it( m_ids, m_acc ); | 251 | Iterator it( m_ids, m_acc ); |
252 | return it; | 252 | return it; |
253 | } | 253 | } |
254 | template <class T> | 254 | template <class T> |
255 | ORecordList<T>::Iterator ORecordList<T>::end() { | 255 | typename ORecordList<T>::Iterator ORecordList<T>::end() { |
256 | Iterator it( m_ids, m_acc ); | 256 | Iterator it( m_ids, m_acc ); |
257 | it.m_end = true; | 257 | it.m_end = true; |
258 | it.m_current = m_ids.count(); | 258 | it.m_current = m_ids.count(); |
259 | 259 | ||
260 | return it; | 260 | return it; |
261 | } | 261 | } |
262 | template <class T> | 262 | template <class T> |
263 | uint ORecordList<T>::count()const { | 263 | uint ORecordList<T>::count()const { |
264 | return m_ids.count(); | 264 | return m_ids.count(); |
265 | } | 265 | } |
266 | template <class T> | 266 | template <class T> |
267 | T ORecordList<T>::operator[]( uint i ) { | 267 | T ORecordList<T>::operator[]( uint i ) { |
diff --git a/libopie2/opiepim/otodo.cpp b/libopie2/opiepim/otodo.cpp index 0d5b1d3..4d5cb79 100644 --- a/libopie2/opiepim/otodo.cpp +++ b/libopie2/opiepim/otodo.cpp | |||
@@ -390,16 +390,16 @@ void OTodo::copy( OTodoData* src, OTodoData* dest ) { | |||
390 | dest->desc = src->desc; | 390 | dest->desc = src->desc; |
391 | dest->sum = src->sum; | 391 | dest->sum = src->sum; |
392 | dest->extra = src->extra; | 392 | dest->extra = src->extra; |
393 | dest->prog = src->prog; | 393 | dest->prog = src->prog; |
394 | dest->hasAlarmDateTime = src->hasAlarmDateTime; | 394 | dest->hasAlarmDateTime = src->hasAlarmDateTime; |
395 | dest->alarmDateTime = src->alarmDateTime; | 395 | dest->alarmDateTime = src->alarmDateTime; |
396 | dest->state = src->state; | 396 | dest->state = src->state; |
397 | dest->recur = src->recur; | 397 | dest->recur = src->recur; |
398 | } | 398 | } |
399 | QString OTodo::type() const { | 399 | QString OTodo::type() const { |
400 | return QString::fromLatin1("OTodo"); | 400 | return QString::fromLatin1("OTodo"); |
401 | } | 401 | } |
402 | QString OTodo::recordField(int id )const { | 402 | QString OTodo::recordField(int /*id*/ )const { |
403 | return QString::null; | 403 | return QString::null; |
404 | } | 404 | } |
405 | 405 | ||