author | zecke <zecke> | 2002-12-10 16:55:46 (UTC) |
---|---|---|
committer | zecke <zecke> | 2002-12-10 16:55:46 (UTC) |
commit | 36375df6ff103e52455823f7afd64c4f4ae7fcb8 (patch) (unidiff) | |
tree | 7a74ca6c05e1d4def7d43de5b5441bed497406ba /core/pim | |
parent | 1bc8aa236cf01e0221e3c2748b2ab3eec4f0817a (diff) | |
download | opie-36375df6ff103e52455823f7afd64c4f4ae7fcb8.zip opie-36375df6ff103e52455823f7afd64c4f4ae7fcb8.tar.gz opie-36375df6ff103e52455823f7afd64c4f4ae7fcb8.tar.bz2 |
Shut up the compiler
-rw-r--r-- | core/pim/todo/mainwindow.cpp | 10 | ||||
-rw-r--r-- | core/pim/todo/mainwindow.h | 1 | ||||
-rw-r--r-- | core/pim/todo/tableview.cpp | 4 | ||||
-rw-r--r-- | core/pim/todo/todoeditor.cpp | 2 |
4 files changed, 5 insertions, 12 deletions
diff --git a/core/pim/todo/mainwindow.cpp b/core/pim/todo/mainwindow.cpp index b2b3b8f..0ab6230 100644 --- a/core/pim/todo/mainwindow.cpp +++ b/core/pim/todo/mainwindow.cpp | |||
@@ -52,25 +52,25 @@ | |||
52 | #include "templateeditor.h" | 52 | #include "templateeditor.h" |
53 | #include "tableview.h" | 53 | #include "tableview.h" |
54 | 54 | ||
55 | #include "textviewshow.h" | 55 | #include "textviewshow.h" |
56 | #include "todoeditor.h" | 56 | #include "todoeditor.h" |
57 | #include "mainwindow.h" | 57 | #include "mainwindow.h" |
58 | 58 | ||
59 | 59 | ||
60 | using namespace Todo; | 60 | using namespace Todo; |
61 | 61 | ||
62 | MainWindow::MainWindow( QWidget* parent, | 62 | MainWindow::MainWindow( QWidget* parent, |
63 | const char* name ) | 63 | const char* name ) |
64 | : OPimMainWindow("Todolist") | 64 | : OPimMainWindow("Todolist", parent, name) |
65 | { | 65 | { |
66 | 66 | ||
67 | m_syncing = false; | 67 | m_syncing = false; |
68 | m_counter = 0; | 68 | m_counter = 0; |
69 | m_tempManager = new TemplateManager(); | 69 | m_tempManager = new TemplateManager(); |
70 | m_tempManager->load(); | 70 | m_tempManager->load(); |
71 | 71 | ||
72 | initUI(); | 72 | initUI(); |
73 | initConfig(); | 73 | initConfig(); |
74 | initViews(); | 74 | initViews(); |
75 | initActions(); | 75 | initActions(); |
76 | initEditor(); | 76 | initEditor(); |
@@ -243,25 +243,25 @@ void MainWindow::initViews() { | |||
243 | */ | 243 | */ |
244 | } | 244 | } |
245 | void MainWindow::initEditor() { | 245 | void MainWindow::initEditor() { |
246 | m_curEdit = new Editor(); | 246 | m_curEdit = new Editor(); |
247 | } | 247 | } |
248 | void MainWindow::initShow() { | 248 | void MainWindow::initShow() { |
249 | m_curShow = new TextViewShow(this); | 249 | m_curShow = new TextViewShow(this); |
250 | m_stack->addWidget( m_curShow->widget() , m_counter++ ); | 250 | m_stack->addWidget( m_curShow->widget() , m_counter++ ); |
251 | } | 251 | } |
252 | MainWindow::~MainWindow() { | 252 | MainWindow::~MainWindow() { |
253 | delete templateManager(); | 253 | delete templateManager(); |
254 | } | 254 | } |
255 | void MainWindow::connectBase( ViewBase* base) { | 255 | void MainWindow::connectBase( ViewBase* ) { |
256 | // once templates and signals mix we'll use it again | 256 | // once templates and signals mix we'll use it again |
257 | } | 257 | } |
258 | QPopupMenu* MainWindow::contextMenu( int , bool recur ) { | 258 | QPopupMenu* MainWindow::contextMenu( int , bool recur ) { |
259 | QPopupMenu* menu = new QPopupMenu(); | 259 | QPopupMenu* menu = new QPopupMenu(); |
260 | 260 | ||
261 | m_editAction->addTo( menu ); | 261 | m_editAction->addTo( menu ); |
262 | m_deleteAction->addTo( menu ); | 262 | m_deleteAction->addTo( menu ); |
263 | m_duplicateAction->addTo( menu ); | 263 | m_duplicateAction->addTo( menu ); |
264 | 264 | ||
265 | menu->insertSeparator(); | 265 | menu->insertSeparator(); |
266 | 266 | ||
267 | /* | 267 | /* |
@@ -788,18 +788,12 @@ void MainWindow::add( const OPimRecord& rec) { | |||
788 | 788 | ||
789 | const OTodo& todo = static_cast<const OTodo&>(rec); | 789 | const OTodo& todo = static_cast<const OTodo&>(rec); |
790 | 790 | ||
791 | m_todoMgr.add(todo ); | 791 | m_todoMgr.add(todo ); |
792 | currentView()->addEvent( todo ); | 792 | currentView()->addEvent( todo ); |
793 | 793 | ||
794 | 794 | ||
795 | // I'm afraid we must call this every time now, otherwise | 795 | // I'm afraid we must call this every time now, otherwise |
796 | // spend expensive time comparing all these strings... | 796 | // spend expensive time comparing all these strings... |
797 | // but only call if we changed something -zecke | 797 | // but only call if we changed something -zecke |
798 | populateCategories(); | 798 | populateCategories(); |
799 | } | 799 | } |
800 | /* todo does not have the QDataStream<< and >> operators implemented :( | ||
801 | * FIXME | ||
802 | */ | ||
803 | OPimRecord* MainWindow::record( int rtti, const QByteArray& ) { | ||
804 | return 0l; | ||
805 | } | ||
diff --git a/core/pim/todo/mainwindow.h b/core/pim/todo/mainwindow.h index 14cfa82..87a9133 100644 --- a/core/pim/todo/mainwindow.h +++ b/core/pim/todo/mainwindow.h | |||
@@ -187,17 +187,16 @@ private slots: | |||
187 | void slotShowDetails(); | 187 | void slotShowDetails(); |
188 | void slotShowDue( bool ); | 188 | void slotShowDue( bool ); |
189 | /* reimplementation from opimmainwindow */ | 189 | /* reimplementation from opimmainwindow */ |
190 | protected slots: | 190 | protected slots: |
191 | void flush(); | 191 | void flush(); |
192 | void reload(); | 192 | void reload(); |
193 | int create(); | 193 | int create(); |
194 | bool remove( int uid ); | 194 | bool remove( int uid ); |
195 | void beam(int uid, int transport = IrDa ); | 195 | void beam(int uid, int transport = IrDa ); |
196 | void show( int uid ); | 196 | void show( int uid ); |
197 | void edit( int uid ); | 197 | void edit( int uid ); |
198 | void add( const OPimRecord& ); | 198 | void add( const OPimRecord& ); |
199 | OPimRecord* record( int rtti, const QByteArray& ); | ||
200 | }; | 199 | }; |
201 | }; | 200 | }; |
202 | 201 | ||
203 | #endif | 202 | #endif |
diff --git a/core/pim/todo/tableview.cpp b/core/pim/todo/tableview.cpp index 0f683c9..2434150 100644 --- a/core/pim/todo/tableview.cpp +++ b/core/pim/todo/tableview.cpp | |||
@@ -161,31 +161,31 @@ void TableView::updateView( ) { | |||
161 | 161 | ||
162 | qWarning("setTodos"); | 162 | qWarning("setTodos"); |
163 | QTime time; | 163 | QTime time; |
164 | time.start(); | 164 | time.start(); |
165 | m_enablePaint = false; | 165 | m_enablePaint = false; |
166 | setUpdatesEnabled( false ); | 166 | setUpdatesEnabled( false ); |
167 | viewport()->setUpdatesEnabled( false ); | 167 | viewport()->setUpdatesEnabled( false ); |
168 | 168 | ||
169 | setNumRows( it.count() ); | 169 | setNumRows( it.count() ); |
170 | if ( it.count() == 0 ) | 170 | if ( it.count() == 0 ) |
171 | killTimer(id); | 171 | killTimer(id); |
172 | 172 | ||
173 | int elc = time.elapsed(); | 173 | // int elc = time.elapsed(); |
174 | setUpdatesEnabled( true ); | 174 | setUpdatesEnabled( true ); |
175 | viewport()->setUpdatesEnabled( true ); | 175 | viewport()->setUpdatesEnabled( true ); |
176 | viewport()->update(); | 176 | viewport()->update(); |
177 | 177 | ||
178 | m_enablePaint = true; | 178 | m_enablePaint = true; |
179 | int el = time.elapsed(); | 179 | // int el = time.elapsed(); |
180 | } | 180 | } |
181 | void TableView::setTodo( int, const OTodo&) { | 181 | void TableView::setTodo( int, const OTodo&) { |
182 | sort(); | 182 | sort(); |
183 | 183 | ||
184 | /* repaint */ | 184 | /* repaint */ |
185 | repaint(); | 185 | repaint(); |
186 | } | 186 | } |
187 | void TableView::addEvent( const OTodo&) { | 187 | void TableView::addEvent( const OTodo&) { |
188 | 188 | ||
189 | /* fix problems of not showing the 'Haken' */ | 189 | /* fix problems of not showing the 'Haken' */ |
190 | updateView(); | 190 | updateView(); |
191 | } | 191 | } |
diff --git a/core/pim/todo/todoeditor.cpp b/core/pim/todo/todoeditor.cpp index 9b8c5cb..5aa7097 100644 --- a/core/pim/todo/todoeditor.cpp +++ b/core/pim/todo/todoeditor.cpp | |||
@@ -28,25 +28,25 @@ OTodo Editor::newTodo( int cur, | |||
28 | if ( QDialog::Accepted == ret ) { | 28 | if ( QDialog::Accepted == ret ) { |
29 | m_accepted = true; | 29 | m_accepted = true; |
30 | }else | 30 | }else |
31 | m_accepted = false; | 31 | m_accepted = false; |
32 | 32 | ||
33 | OTodo ev = e->todo(); | 33 | OTodo ev = e->todo(); |
34 | qWarning("Todo uid"); | 34 | qWarning("Todo uid"); |
35 | qWarning("Todo %s %d %d", ev.summary().latin1(), ev.progress(), ev.isCompleted() ); | 35 | qWarning("Todo %s %d %d", ev.summary().latin1(), ev.progress(), ev.isCompleted() ); |
36 | ev.setUid(1); | 36 | ev.setUid(1); |
37 | 37 | ||
38 | return ev; | 38 | return ev; |
39 | } | 39 | } |
40 | OTodo Editor::edit( QWidget *wid, | 40 | OTodo Editor::edit( QWidget *, |
41 | const OTodo& todo ) { | 41 | const OTodo& todo ) { |
42 | OTaskEditor *e = self(); | 42 | OTaskEditor *e = self(); |
43 | e->init( todo ); | 43 | e->init( todo ); |
44 | e->setCaption( QObject::tr( "Edit Task" ) ); | 44 | e->setCaption( QObject::tr( "Edit Task" ) ); |
45 | 45 | ||
46 | #if defined(Q_WS_QWS) || defined(_WS_QWS_) | 46 | #if defined(Q_WS_QWS) || defined(_WS_QWS_) |
47 | e->showMaximized(); | 47 | e->showMaximized(); |
48 | #endif | 48 | #endif |
49 | int ret = e->exec(); | 49 | int ret = e->exec(); |
50 | 50 | ||
51 | OTodo ev = e->todo(); | 51 | OTodo ev = e->todo(); |
52 | if ( ret == QDialog::Accepted ) | 52 | if ( ret == QDialog::Accepted ) |