summaryrefslogtreecommitdiff
authorzecke <zecke>2002-11-03 11:03:20 (UTC)
committer zecke <zecke>2002-11-03 11:03:20 (UTC)
commit207f7430db6c90e88825ea2bedc9ae1bf68e3d99 (patch) (unidiff)
treefb69b58f130c0b0a17224989f26aa4af5939b33e
parent485fae36510cb42690c9df55fae64312b1e656ae (diff)
downloadopie-207f7430db6c90e88825ea2bedc9ae1bf68e3d99.zip
opie-207f7430db6c90e88825ea2bedc9ae1bf68e3d99.tar.gz
opie-207f7430db6c90e88825ea2bedc9ae1bf68e3d99.tar.bz2
Patch by Simon Hausmann to suit gcc3 needs
many thanks
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--libopie/oclickablelabel.cpp2
-rw-r--r--libopie/ofileselector.cc9
-rw-r--r--libopie/ofileselector.h2
-rw-r--r--libopie/ofileselector/odefaultfactories.cpp4
-rw-r--r--libopie/ofileselector/odefaultfactories.h1
-rw-r--r--libopie/ofileselector/ofileselector.cpp3
-rw-r--r--libopie/pim/opimaccessbackend.h4
-rw-r--r--libopie/pim/opimaccesstemplate.h10
-rw-r--r--libopie/pim/orecordlist.h4
-rw-r--r--libopie/pim/otodo.cpp2
-rw-r--r--libopie2/opiepim/backend/opimaccessbackend.h4
-rw-r--r--libopie2/opiepim/core/opimaccesstemplate.h10
-rw-r--r--libopie2/opiepim/orecordlist.h4
-rw-r--r--libopie2/opiepim/otodo.cpp2
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
@@ -17,7 +17,7 @@ void OClickableLabel::setToggleButton(bool t) {
17 isToggle=t; 17 isToggle=t;
18} 18}
19 19
20void OClickableLabel::mousePressEvent( QMouseEvent *e ) { 20void OClickableLabel::mousePressEvent( QMouseEvent * /*e*/ ) {
21 if (isToggle && isDown) { 21 if (isToggle && isDown) {
22 showState(false); 22 showState(false);
23 } else { 23 } else {
diff --git a/libopie/ofileselector.cc b/libopie/ofileselector.cc
index 9534667..6a6a300 100644
--- a/libopie/ofileselector.cc
+++ b/libopie/ofileselector.cc
@@ -375,7 +375,7 @@ QString OFileSelector::directory()const
375 return QDir(m_currentDir).absPath(); 375 return QDir(m_currentDir).absPath();
376} 376}
377 377
378int OFileSelector::fileCount() 378int OFileSelector::fileCount() const
379{ 379{
380 int count; 380 int count;
381 switch( m_selector ){ 381 switch( m_selector ){
@@ -682,7 +682,7 @@ void OFileSelector::initVars()
682 m_new = 0; 682 m_new = 0;
683 m_close = 0; 683 m_close = 0;
684} 684}
685void OFileSelector::addFile(const QString &mime, QFileInfo *info, bool symlink) 685void OFileSelector::addFile(const QString &/*mime*/, QFileInfo *info, bool symlink)
686{ 686{
687 if(!m_files) 687 if(!m_files)
688 return; 688 return;
@@ -714,7 +714,7 @@ void OFileSelector::addFile(const QString &mime, QFileInfo *info, bool symlink)
714 QString::number( info->size() ), 714 QString::number( info->size() ),
715 dir, locked ); 715 dir, locked );
716} 716}
717void OFileSelector::addDir(const QString &mime, QFileInfo *info, bool symlink ) 717void OFileSelector::addDir(const QString &/*mime*/, QFileInfo *info, bool symlink )
718{ 718{
719 if(!m_dir) 719 if(!m_dir)
720 return; 720 return;
@@ -1018,7 +1018,6 @@ bool OFileSelector::compliesMime( const QString& mime ) {
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 ) {
@@ -1105,7 +1104,7 @@ void OFileSelector::slotRightButton(int button, QListViewItem *item, const QPoin
1105 return; 1104 return;
1106 slotContextMenu( item ); 1105 slotContextMenu( item );
1107} 1106}
1108void OFileSelector::slotContextMenu( QListViewItem *item) 1107void OFileSelector::slotContextMenu( QListViewItem * /*item*/)
1109{ 1108{
1110 1109
1111} 1110}
diff --git a/libopie/ofileselector.h b/libopie/ofileselector.h
index f2d5f84..17c494e 100644
--- a/libopie/ofileselector.h
+++ b/libopie/ofileselector.h
@@ -180,7 +180,7 @@ class OFileSelector : public QWidget {
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;
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,5 +1,4 @@
1#include "ofilelistview.h" 1#include "ofilelistview.h"
2#include "ofileiconview.h"
3#include "olocallister.h" 2#include "olocallister.h"
4 3
5 4
@@ -8,9 +7,6 @@
8extern "C" { 7extern "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 );
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
@@ -5,7 +5,6 @@
5 5
6extern "C" { 6extern "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* );
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
@@ -976,7 +976,8 @@ 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
982void OFileSelector::fillList() { 983void OFileSelector::fillList() {
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
@@ -57,7 +57,7 @@ public:
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 */
@@ -127,7 +127,7 @@ void OPimAccessBackend<T>::setSaneCacheSize( int size) {
127} 127}
128template <class T> 128template <class T>
129T OPimAccessBackend<T>::find( int uid, const QArray<int>&, 129T 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}
133template <class T> 133template <class T>
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
@@ -79,7 +79,7 @@ public:
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 /**
@@ -165,13 +165,13 @@ bool OPimAccessTemplate<T>::save() {
165 return m_backEnd->save(); 165 return m_backEnd->save();
166} 166}
167template <class T> 167template <class T>
168OPimAccessTemplate<T>::List OPimAccessTemplate<T>::allRecords()const { 168typename 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}
173template <class T> 173template <class T>
174OPimAccessTemplate<T>::List 174typename OPimAccessTemplate<T>::List
175OPimAccessTemplate<T>::queryByExample( const T& t, int sortOrder ) { 175OPimAccessTemplate<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
@@ -186,7 +186,7 @@ T OPimAccessTemplate<T>::find( int uid ) const{
186} 186}
187template <class T> 187template <class T>
188T OPimAccessTemplate<T>::find( int uid, const QArray<int>& ar, 188T 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
@@ -230,7 +230,7 @@ void OPimAccessTemplate<T>::invalidateCache() {
230 m_cache.invalidate(); 230 m_cache.invalidate();
231} 231}
232template <class T> 232template <class T>
233OPimAccessTemplate<T>::BackEnd* OPimAccessTemplate<T>::backEnd() { 233typename OPimAccessTemplate<T>::BackEnd* OPimAccessTemplate<T>::backEnd() {
234 return m_backEnd; 234 return m_backEnd;
235} 235}
236template <class T> 236template <class T>
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
@@ -247,12 +247,12 @@ ORecordList<T>::~ORecordList() {
247/* nothing to do here */ 247/* nothing to do here */
248} 248}
249template <class T> 249template <class T>
250ORecordList<T>::Iterator ORecordList<T>::begin() { 250typename 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}
254template <class T> 254template <class T>
255ORecordList<T>::Iterator ORecordList<T>::end() { 255typename 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();
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
@@ -399,7 +399,7 @@ void OTodo::copy( OTodoData* src, OTodoData* dest ) {
399QString OTodo::type() const { 399QString OTodo::type() const {
400 return QString::fromLatin1("OTodo"); 400 return QString::fromLatin1("OTodo");
401} 401}
402QString OTodo::recordField(int id )const { 402QString 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
@@ -57,7 +57,7 @@ public:
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 */
@@ -127,7 +127,7 @@ void OPimAccessBackend<T>::setSaneCacheSize( int size) {
127} 127}
128template <class T> 128template <class T>
129T OPimAccessBackend<T>::find( int uid, const QArray<int>&, 129T 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}
133template <class T> 133template <class T>
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
@@ -79,7 +79,7 @@ public:
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 /**
@@ -165,13 +165,13 @@ bool OPimAccessTemplate<T>::save() {
165 return m_backEnd->save(); 165 return m_backEnd->save();
166} 166}
167template <class T> 167template <class T>
168OPimAccessTemplate<T>::List OPimAccessTemplate<T>::allRecords()const { 168typename 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}
173template <class T> 173template <class T>
174OPimAccessTemplate<T>::List 174typename OPimAccessTemplate<T>::List
175OPimAccessTemplate<T>::queryByExample( const T& t, int sortOrder ) { 175OPimAccessTemplate<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
@@ -186,7 +186,7 @@ T OPimAccessTemplate<T>::find( int uid ) const{
186} 186}
187template <class T> 187template <class T>
188T OPimAccessTemplate<T>::find( int uid, const QArray<int>& ar, 188T 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
@@ -230,7 +230,7 @@ void OPimAccessTemplate<T>::invalidateCache() {
230 m_cache.invalidate(); 230 m_cache.invalidate();
231} 231}
232template <class T> 232template <class T>
233OPimAccessTemplate<T>::BackEnd* OPimAccessTemplate<T>::backEnd() { 233typename OPimAccessTemplate<T>::BackEnd* OPimAccessTemplate<T>::backEnd() {
234 return m_backEnd; 234 return m_backEnd;
235} 235}
236template <class T> 236template <class T>
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
@@ -247,12 +247,12 @@ ORecordList<T>::~ORecordList() {
247/* nothing to do here */ 247/* nothing to do here */
248} 248}
249template <class T> 249template <class T>
250ORecordList<T>::Iterator ORecordList<T>::begin() { 250typename 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}
254template <class T> 254template <class T>
255ORecordList<T>::Iterator ORecordList<T>::end() { 255typename 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();
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
@@ -399,7 +399,7 @@ void OTodo::copy( OTodoData* src, OTodoData* dest ) {
399QString OTodo::type() const { 399QString OTodo::type() const {
400 return QString::fromLatin1("OTodo"); 400 return QString::fromLatin1("OTodo");
401} 401}
402QString OTodo::recordField(int id )const { 402QString OTodo::recordField(int /*id*/ )const {
403 return QString::null; 403 return QString::null;
404} 404}
405 405