Diffstat (limited to 'korganizer/datenavigator.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | korganizer/datenavigator.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/korganizer/datenavigator.cpp b/korganizer/datenavigator.cpp index e26e20b..3156b2b 100644 --- a/korganizer/datenavigator.cpp +++ b/korganizer/datenavigator.cpp @@ -194,16 +194,22 @@ void DateNavigator::selectWorkWeek( const QDate &d ) int weekStart = KGlobal::locale()->weekStartDay(); if ( weekStart != 1 && dayOfWeek >= weekStart ) { firstDate = firstDate.addDays( 7 ); } selectDates( firstDate, 5 ); } +void DateNavigator::selectTodayMonth() +{ + QDate date = QDate::currentDate().addDays( 1-QDate::currentDate().day() ); + selectDates( date , date.daysInMonth ()); + +} void DateNavigator::selectToday() { QDate d = QDate::currentDate(); int dateCount = mSelectedDates.count(); if ( dateCount == 5 ) selectWorkWeek( d ); else if ( dateCount == 7 ) selectWeek( d ); |