-rw-r--r-- | core/pim/todo/tableview.cpp | 34 |
1 files changed, 18 insertions, 16 deletions
diff --git a/core/pim/todo/tableview.cpp b/core/pim/todo/tableview.cpp index 0d298f4..0b1c579 100644 --- a/core/pim/todo/tableview.cpp +++ b/core/pim/todo/tableview.cpp | |||
@@ -29,15 +29,16 @@ | |||
29 | #include <cmath> | 29 | #include <cmath> |
30 | #include <cctype> | 30 | #include <cctype> |
31 | 31 | ||
32 | #include <qcombobox.h> | 32 | #include <opie2/odebug.h> |
33 | #include <qlineedit.h> | 33 | #include <opie2/opimrecurrence.h> |
34 | #include <qtimer.h> | ||
35 | #include <qpopupmenu.h> | ||
36 | 34 | ||
37 | #include <qpe/config.h> | 35 | #include <qpe/config.h> |
38 | #include <qpe/resource.h> | 36 | #include <qpe/resource.h> |
39 | 37 | ||
40 | #include <opie2/opimrecurrence.h> | 38 | #include <qcombobox.h> |
39 | #include <qlineedit.h> | ||
40 | #include <qtimer.h> | ||
41 | #include <qpopupmenu.h> | ||
41 | 42 | ||
42 | #include "mainwindow.h" | 43 | #include "mainwindow.h" |
43 | //#include "tableitems.h" | 44 | //#include "tableitems.h" |
@@ -194,7 +195,7 @@ void TableView::showOverDue( bool ) { | |||
194 | } | 195 | } |
195 | 196 | ||
196 | void TableView::updateView( ) { | 197 | void TableView::updateView( ) { |
197 | qWarning("update view"); | 198 | Opie::Core::owarn << "update view" << oendl; |
198 | m_row = false; | 199 | m_row = false; |
199 | static int id; | 200 | static int id; |
200 | id = startTimer(4000 ); | 201 | id = startTimer(4000 ); |
@@ -208,7 +209,7 @@ void TableView::updateView( ) { | |||
208 | it = sorted().begin(); | 209 | it = sorted().begin(); |
209 | end = sorted().end(); | 210 | end = sorted().end(); |
210 | 211 | ||
211 | qWarning("setTodos"); | 212 | Opie::Core::owarn << "setTodos" << oendl; |
212 | QTime time; | 213 | QTime time; |
213 | time.start(); | 214 | time.start(); |
214 | m_enablePaint = false; | 215 | m_enablePaint = false; |
@@ -254,11 +255,11 @@ void TableView::removeEvent( int ) { | |||
254 | updateView(); | 255 | updateView(); |
255 | } | 256 | } |
256 | void TableView::setShowCompleted( bool b) { | 257 | void TableView::setShowCompleted( bool b) { |
257 | qWarning("Show Completed %d" , b ); | 258 | Opie::Core::owarn << "Show Completed " << b << oendl; |
258 | updateView(); | 259 | updateView(); |
259 | } | 260 | } |
260 | void TableView::setShowDeadline( bool b ) { | 261 | void TableView::setShowDeadline( bool b ) { |
261 | qWarning( "Show DeadLine %d" , b ); | 262 | Opie::Core::owarn << "Show Deadline " << b << oendl; |
262 | if ( b ) | 263 | if ( b ) |
263 | showColumn( 3 ); | 264 | showColumn( 3 ); |
264 | else | 265 | else |
@@ -281,7 +282,7 @@ void TableView::setShowDeadline( bool b ) { | |||
281 | setColumnWidth( 2, col2width ); | 282 | setColumnWidth( 2, col2width ); |
282 | } | 283 | } |
283 | void TableView::setShowCategory( const QString& str) { | 284 | void TableView::setShowCategory( const QString& str) { |
284 | qWarning("setShowCategory"); | 285 | Opie::Core::owarn << "setShowCategory" << oendl; |
285 | if ( str != m_oleCat || m_first ) | 286 | if ( str != m_oleCat || m_first ) |
286 | updateView(); | 287 | updateView(); |
287 | 288 | ||
@@ -346,14 +347,15 @@ void TableView::slotClicked(int row, int col, int, | |||
346 | void TableView::slotPressed(int row, int col, int, | 347 | void TableView::slotPressed(int row, int col, int, |
347 | const QPoint& point) { | 348 | const QPoint& point) { |
348 | 349 | ||
349 | qWarning("pressed row %d col %d x:%d+y:%d", row,col,point.x(),point.y() ); | 350 | Opie::Core::owarn << "pressed row " << row << " col " << col << " x:" << point.x() |
351 | << "+y:" << point.y() << oendl; | ||
350 | m_prevP = point; | 352 | m_prevP = point; |
351 | /* TextColumn column */ | 353 | /* TextColumn column */ |
352 | if ( col == 2 && cellGeometry( row, col ).contains( point ) ) | 354 | if ( col == 2 && cellGeometry( row, col ).contains( point ) ) |
353 | m_menuTimer->start( 750, TRUE ); | 355 | m_menuTimer->start( 750, TRUE ); |
354 | } | 356 | } |
355 | void TableView::slotValueChanged( int, int ) { | 357 | void TableView::slotValueChanged( int, int ) { |
356 | qWarning("Value Changed"); | 358 | Opie::Core::owarn << "Value Changed" << oendl; |
357 | } | 359 | } |
358 | void TableView::slotCurrentChanged(int, int ) { | 360 | void TableView::slotCurrentChanged(int, int ) { |
359 | m_menuTimer->stop(); | 361 | m_menuTimer->stop(); |
@@ -369,7 +371,7 @@ QWidget* TableView::widget() { | |||
369 | * to a sort() and update() | 371 | * to a sort() and update() |
370 | */ | 372 | */ |
371 | void TableView::sortColumn( int col, bool asc, bool ) { | 373 | void TableView::sortColumn( int col, bool asc, bool ) { |
372 | qWarning("bool %d", asc ); | 374 | Opie::Core::owarn << "bool " << asc << oendl; |
373 | setSortOrder( col ); | 375 | setSortOrder( col ); |
374 | setAscending( asc ); | 376 | setAscending( asc ); |
375 | updateView(); | 377 | updateView(); |
@@ -492,7 +494,7 @@ QWidget* TableView::createEditor(int row, int col, bool )const { | |||
492 | } | 494 | } |
493 | } | 495 | } |
494 | void TableView::setCellContentFromEditor(int row, int col ) { | 496 | void TableView::setCellContentFromEditor(int row, int col ) { |
495 | qWarning("set cell content from editor"); | 497 | Opie::Core::owarn << "set cell content from editor" << oendl; |
496 | if ( col == 1 ) { | 498 | if ( col == 1 ) { |
497 | QWidget* wid = cellWidget(row, 1 ); | 499 | QWidget* wid = cellWidget(row, 1 ); |
498 | if ( wid->inherits("QComboBox") ) { | 500 | if ( wid->inherits("QComboBox") ) { |
@@ -528,7 +530,7 @@ void TableView::slotPriority() { | |||
528 | * | 530 | * |
529 | */ | 531 | */ |
530 | void TableView::timerEvent( QTimerEvent* ) { | 532 | void TableView::timerEvent( QTimerEvent* ) { |
531 | // qWarning("sorted %d", sorted().count() ); | 533 | // Opie::Core::owarn << "sorted " << sorted().count() << oendl; |
532 | if (sorted().count() == 0 ) | 534 | if (sorted().count() == 0 ) |
533 | return; | 535 | return; |
534 | 536 | ||
@@ -576,7 +578,7 @@ void TableView::contentsMouseReleaseEvent( QMouseEvent* e) { | |||
576 | int row = rowAt(m_prevP.y()); | 578 | int row = rowAt(m_prevP.y()); |
577 | int colOld = columnAt(m_prevP.x() ); | 579 | int colOld = columnAt(m_prevP.x() ); |
578 | int colNew = columnAt(e->x() ); | 580 | int colNew = columnAt(e->x() ); |
579 | qWarning("colNew: %d colOld: %d", colNew, colOld ); | 581 | Opie::Core::owarn << "colNew: " << colNew << " colOld: " << colOld << oendl; |
580 | if ( row == rowAt( e->y() ) && row != -1 && | 582 | if ( row == rowAt( e->y() ) && row != -1 && |
581 | colOld != colNew ) { | 583 | colOld != colNew ) { |
582 | TodoView::complete( sorted()[row] ); | 584 | TodoView::complete( sorted()[row] ); |