author | zautrix <zautrix> | 2005-02-09 10:33:00 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-02-09 10:33:00 (UTC) |
commit | 968099947455adc0e8681aedf8c161327e311f38 (patch) (side-by-side diff) | |
tree | 2c4983417cd6d7348765a58990eac50aed8700e6 /korganizer/koagendaview.cpp | |
parent | d0ab37d35ca9a9d919c9fc4856f3314bfef6dd5a (diff) | |
download | kdepimpi-968099947455adc0e8681aedf8c161327e311f38.zip kdepimpi-968099947455adc0e8681aedf8c161327e311f38.tar.gz kdepimpi-968099947455adc0e8681aedf8c161327e311f38.tar.bz2 |
start fix
-rw-r--r-- | korganizer/koagendaview.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/korganizer/koagendaview.cpp b/korganizer/koagendaview.cpp index 0d36946..13d8398 100644 --- a/korganizer/koagendaview.cpp +++ b/korganizer/koagendaview.cpp @@ -1512,48 +1512,58 @@ void KOAgendaView::deleteSelectedDateTime() mTimeSpanEnd.setDate(QDate()); mTimeSpanInAllDay = false; } void KOAgendaView::keyPressEvent ( QKeyEvent * e ) { e->ignore(); } void KOAgendaView::scrollOneHourUp() { mAgenda->scrollBy ( 0, -mAgenda->contentsHeight () / 24 ); } void KOAgendaView::scrollOneHourDown() { mAgenda->scrollBy ( 0, mAgenda->contentsHeight () / 24 ); } void KOAgendaView::setStartHour( int h ) { mAgenda->setStartHour( h ); } +void KOAgendaView::setInitStartHour() +{ + + if ( KOPrefs::instance()->mCenterOnCurrentTime ) + setStartHour( QTime::currentTime ().hour() ); + else + setStartHour( KOPrefs::instance()->mDayBegins ); + +} + void KOAgendaView::updateTodo( Todo * t, int ) { if ( !isVisible() ) return; bool remove = false; bool removeAD = false; QDate da; if ( t->hasCompletedDate() ) da = t->completed().date(); else da = t->dtDue().date(); if ( ! t->hasDueDate() && !t->hasCompletedDate() ) { remove = true; removeAD = true; } else { bool overdue = (!t->isCompleted()) && (t->dtDue() < QDate::currentDate()) && KOPrefs::instance()->mShowTodoInAgenda ; if ( overdue && QDate::currentDate() >= mSelectedDates.first() && QDate::currentDate() <= mSelectedDates.last()) { removeAD = false; remove = true; } |