Diffstat (limited to 'core/pim/todo/mainwindow.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/pim/todo/mainwindow.cpp | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/core/pim/todo/mainwindow.cpp b/core/pim/todo/mainwindow.cpp index f0642c4..d552928 100644 --- a/core/pim/todo/mainwindow.cpp +++ b/core/pim/todo/mainwindow.cpp | |||
@@ -27,8 +27,9 @@ | |||
27 | */ | 27 | */ |
28 | 28 | ||
29 | #include <unistd.h> | 29 | #include <unistd.h> |
30 | 30 | ||
31 | #include <opie2/odebug.h> | ||
31 | #include <opie2/opimrecurrence.h> | 32 | #include <opie2/opimrecurrence.h> |
32 | #include <opie2/opimnotifymanager.h> | 33 | #include <opie2/opimnotifymanager.h> |
33 | #include <opie2/otodoaccessvcal.h> | 34 | #include <opie2/otodoaccessvcal.h> |
34 | #include <opie2/oapplicationfactory.h> | 35 | #include <opie2/oapplicationfactory.h> |
@@ -294,9 +295,9 @@ QPopupMenu* MainWindow::contextMenu( int , bool recur ) { | |||
294 | 295 | ||
295 | return menu; | 296 | return menu; |
296 | } | 297 | } |
297 | QPopupMenu* MainWindow::options() { | 298 | QPopupMenu* MainWindow::options() { |
298 | qWarning("Options"); | 299 | Opie::Core::owarn << "Options" << oendl; |
299 | return m_options; | 300 | return m_options; |
300 | } | 301 | } |
301 | QPopupMenu* MainWindow::edit() { | 302 | QPopupMenu* MainWindow::edit() { |
302 | return m_edit; | 303 | return m_edit; |
@@ -313,9 +314,9 @@ OPimTodoAccess::List MainWindow::sorted( bool asc, int sortOrder ) { | |||
313 | cat = currentCatId(); | 314 | cat = currentCatId(); |
314 | if ( m_curCat == QWidget::tr("Unfiled") ) | 315 | if ( m_curCat == QWidget::tr("Unfiled") ) |
315 | cat = -1; | 316 | cat = -1; |
316 | 317 | ||
317 | qWarning(" Category %d %s", cat, m_curCat.latin1() ); | 318 | Opie::Core::owarn << " Category " << cat << " " << m_curCat << oendl; |
318 | 319 | ||
319 | int filter = 1; | 320 | int filter = 1; |
320 | 321 | ||
321 | if (!m_completed ) | 322 | if (!m_completed ) |
@@ -372,9 +373,9 @@ void MainWindow::closeEvent( QCloseEvent* e ) { | |||
372 | return; | 373 | return; |
373 | } | 374 | } |
374 | bool quit = false; | 375 | bool quit = false; |
375 | if ( m_todoMgr.saveAll() ){ | 376 | if ( m_todoMgr.saveAll() ){ |
376 | qWarning("saved"); | 377 | Opie::Core::owarn << "saved" << oendl; |
377 | quit = true; | 378 | quit = true; |
378 | }else { | 379 | }else { |
379 | if ( QMessageBox::critical( this, QWidget::tr("Out of space"), | 380 | if ( QMessageBox::critical( this, QWidget::tr("Out of space"), |
380 | QWidget::tr("Todo was unable\n" | 381 | QWidget::tr("Todo was unable\n" |
@@ -535,9 +536,9 @@ void MainWindow::slotEdit() { | |||
535 | void MainWindow::setCategory( int c) { | 536 | void MainWindow::setCategory( int c) { |
536 | if ( c <= 0 ) return; | 537 | if ( c <= 0 ) return; |
537 | 538 | ||
538 | 539 | ||
539 | qWarning("Iterating over cats %d", c ); | 540 | Opie::Core::owarn << "Iterating over cats " << c << oendl; |
540 | for ( unsigned int i = 1; i < m_catMenu->count(); i++ ) | 541 | for ( unsigned int i = 1; i < m_catMenu->count(); i++ ) |
541 | m_catMenu->setItemChecked(i, c == (int)i ); | 542 | m_catMenu->setItemChecked(i, c == (int)i ); |
542 | 543 | ||
543 | if (c == 1 ) { | 544 | if (c == 1 ) { |
@@ -679,9 +680,9 @@ void MainWindow::slotShowDue(bool ov) { | |||
679 | raiseCurrentView(); | 680 | raiseCurrentView(); |
680 | } | 681 | } |
681 | void MainWindow::slotShow( int uid ) { | 682 | void MainWindow::slotShow( int uid ) { |
682 | if ( uid == 0 ) return; | 683 | if ( uid == 0 ) return; |
683 | qWarning("slotShow"); | 684 | Opie::Core::owarn << "slotShow" << oendl; |
684 | currentShow()->slotShow( event( uid ) ); | 685 | currentShow()->slotShow( event( uid ) ); |
685 | m_stack->raiseWidget( currentShow()->widget() ); | 686 | m_stack->raiseWidget( currentShow()->widget() ); |
686 | } | 687 | } |
687 | void MainWindow::slotShowNext() { | 688 | void MainWindow::slotShowNext() { |
@@ -738,9 +739,9 @@ void MainWindow::setReadAhead( uint count ) { | |||
738 | if (m_todoMgr.todoDB() ) | 739 | if (m_todoMgr.todoDB() ) |
739 | m_todoMgr.todoDB()->setReadAhead( count ); | 740 | m_todoMgr.todoDB()->setReadAhead( count ); |
740 | } | 741 | } |
741 | void MainWindow::slotQuickEntered() { | 742 | void MainWindow::slotQuickEntered() { |
742 | qWarning("entered"); | 743 | Opie::Core::owarn << "entered" << oendl; |
743 | OPimTodo todo = quickEditor()->todo(); | 744 | OPimTodo todo = quickEditor()->todo(); |
744 | if (todo.isEmpty() ) | 745 | if (todo.isEmpty() ) |
745 | return; | 746 | return; |
746 | 747 | ||
@@ -785,9 +786,9 @@ void MainWindow::slotComplete( const OPimTodo& todo ) { | |||
785 | */ | 786 | */ |
786 | QDate date; | 787 | QDate date; |
787 | if ( to2.recurrence().nextOcurrence( to2.dueDate().addDays(1), date ) ) { | 788 | if ( to2.recurrence().nextOcurrence( to2.dueDate().addDays(1), date ) ) { |
788 | int dayDiff = to.dueDate().daysTo( date ); | 789 | int dayDiff = to.dueDate().daysTo( date ); |
789 | qWarning("day diff is %d", dayDiff ); | 790 | Opie::Core::owarn << "day diff is " << dayDiff << oendl; |
790 | QDate inval; | 791 | QDate inval; |
791 | /* generate a new uid for the old record */ | 792 | /* generate a new uid for the old record */ |
792 | to.setUid( 1 ); | 793 | to.setUid( 1 ); |
793 | 794 | ||
@@ -948,17 +949,17 @@ namespace { | |||
948 | } | 949 | } |
949 | void addAlarms( const OPimNotifyManager::Alarms& als, int uid ) { | 950 | void addAlarms( const OPimNotifyManager::Alarms& als, int uid ) { |
950 | OPimNotifyManager::Alarms::ConstIterator it; | 951 | OPimNotifyManager::Alarms::ConstIterator it; |
951 | for ( it = als.begin(); it != als.end(); ++it ) { | 952 | for ( it = als.begin(); it != als.end(); ++it ) { |
952 | qWarning("Adding alarm for %s", (*it).dateTime().toString().latin1() ); | 953 | Opie::Core::owarn << "Adding alarm for " << (*it).dateTime().toString() << oendl; |
953 | AlarmServer::addAlarm( (*it).dateTime(), "QPE/Application/todolist", "alarm(QDateTime,int)", uid ); | 954 | AlarmServer::addAlarm( (*it).dateTime(), "QPE/Application/todolist", "alarm(QDateTime,int)", uid ); |
954 | } | 955 | } |
955 | 956 | ||
956 | } | 957 | } |
957 | void removeAlarms( const OPimNotifyManager::Alarms& als, int uid ) { | 958 | void removeAlarms( const OPimNotifyManager::Alarms& als, int uid ) { |
958 | OPimNotifyManager::Alarms::ConstIterator it; | 959 | OPimNotifyManager::Alarms::ConstIterator it; |
959 | for ( it = als.begin(); it != als.end(); ++it ) { | 960 | for ( it = als.begin(); it != als.end(); ++it ) { |
960 | qWarning("Removinf alarm for %s", (*it).dateTime().toString().latin1() ); | 961 | Opie::Core::owarn << "Removinf alarm for " << (*it).dateTime().toString() << oendl; |
961 | AlarmServer::deleteAlarm( (*it).dateTime(), "QPE/Application/todolist", "alarm(QDateTime,int)", uid ); | 962 | AlarmServer::deleteAlarm( (*it).dateTime(), "QPE/Application/todolist", "alarm(QDateTime,int)", uid ); |
962 | } | 963 | } |
963 | } | 964 | } |
964 | } | 965 | } |