Diffstat (limited to 'korganizer/datenavigator.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | korganizer/datenavigator.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/korganizer/datenavigator.cpp b/korganizer/datenavigator.cpp index 3156b2b..d2824de 100644 --- a/korganizer/datenavigator.cpp +++ b/korganizer/datenavigator.cpp @@ -205,18 +205,17 @@ void DateNavigator::selectTodayMonth() selectDates( date , date.daysInMonth ()); } void DateNavigator::selectToday() { QDate d = QDate::currentDate(); int dateCount = mSelectedDates.count(); - - if ( dateCount == 5 ) selectWorkWeek( d ); + if ( dateCount == 5 && d.dayOfWeek() < 6 ) selectWorkWeek( d ); else if ( dateCount == 7 ) selectWeek( d ); else selectDates( d, dateCount ); } void DateNavigator::selectPreviousYear() { QDate firstSelected = mSelectedDates.first(); int weekDay = firstSelected.dayOfWeek(); |