author | zautrix <zautrix> | 2005-02-07 21:52:19 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-02-07 21:52:19 (UTC) |
commit | d7a005e6c1a27d1084f30b940d54291a8d660f0e (patch) (unidiff) | |
tree | c6ce04abf039acde589431f104bbb066ba4917a1 /korganizer/datenavigator.cpp | |
parent | edaad9a9d7ede1b4bc50b9e758eaf32a5fbb547e (diff) | |
download | kdepimpi-d7a005e6c1a27d1084f30b940d54291a8d660f0e.zip kdepimpi-d7a005e6c1a27d1084f30b940d54291a8d660f0e.tar.gz kdepimpi-d7a005e6c1a27d1084f30b940d54291a8d660f0e.tar.bz2 |
fixes
Diffstat (limited to 'korganizer/datenavigator.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | korganizer/datenavigator.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/korganizer/datenavigator.cpp b/korganizer/datenavigator.cpp index d2824de..8b7c993 100644 --- a/korganizer/datenavigator.cpp +++ b/korganizer/datenavigator.cpp | |||
@@ -155,6 +155,14 @@ void DateNavigator::selectWeek() | |||
155 | void DateNavigator::selectWeek( int num ) | 155 | void DateNavigator::selectWeek( int num ) |
156 | { | 156 | { |
157 | int year = mSelectedDates.first().year(); | 157 | int year = mSelectedDates.first().year(); |
158 | QDate d = QDate ( year, 1,1); | ||
159 | while ( d.dayOfWeek() != 4 ) | ||
160 | d = d.addDays( 1 ); | ||
161 | selectWeek( d.addDays ( (num-1) *7 ) ); | ||
162 | } | ||
163 | void DateNavigator::selectWeekFromMonthView( int num ) | ||
164 | { | ||
165 | int year = mSelectedDates.first().year(); | ||
158 | if ( mSelectedDates.first().dayOfYear() > 300 && num < 10 ) | 166 | if ( mSelectedDates.first().dayOfYear() > 300 && num < 10 ) |
159 | ++year; | 167 | ++year; |
160 | if ( mSelectedDates.first().dayOfYear() < 70 && num > 40 ) | 168 | if ( mSelectedDates.first().dayOfYear() < 70 && num > 40 ) |