author | zautrix <zautrix> | 2004-12-04 13:59:01 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-12-04 13:59:01 (UTC) |
commit | a3b1470f3da722d044505f78bef9de51b2107802 (patch) (side-by-side diff) | |
tree | 52965f580d00f865231661ff3d51af5c881e77cc | |
parent | 7828f46413766ee5db72dc9bd457eac0868f0646 (diff) | |
download | kdepimpi-a3b1470f3da722d044505f78bef9de51b2107802.zip kdepimpi-a3b1470f3da722d044505f78bef9de51b2107802.tar.gz kdepimpi-a3b1470f3da722d044505f78bef9de51b2107802.tar.bz2 |
monthview changes
-rw-r--r-- | bin/kdepim/WhatsNew.txt | 6 | ||||
-rw-r--r-- | korganizer/calendarview.cpp | 3 | ||||
-rw-r--r-- | korganizer/datenavigator.cpp | 6 | ||||
-rw-r--r-- | korganizer/datenavigator.h | 1 | ||||
-rw-r--r-- | korganizer/interfaces/korganizer/baseview.h | 1 | ||||
-rw-r--r-- | korganizer/komonthview.h | 1 |
6 files changed, 18 insertions, 0 deletions
diff --git a/bin/kdepim/WhatsNew.txt b/bin/kdepim/WhatsNew.txt index eb7cf13..4fff7e1 100644 --- a/bin/kdepim/WhatsNew.txt +++ b/bin/kdepim/WhatsNew.txt @@ -21,6 +21,12 @@ Create a symlink to the SD card: ls -s /mnt/card/localmail Now KOpieMail will store all mails on the SD card. +KO/Pi Monthview: +Now "Go to Today" selects the current month from day 1-end, +not the current date + some days. +I.e. "Go to Today" shows now always +the current month with first day of month in the first row. + ********** VERSION 1.9.13 ************ diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp index 3908dbb..47cd488 100644 --- a/korganizer/calendarview.cpp +++ b/korganizer/calendarview.cpp @@ -1991,6 +1991,9 @@ void CalendarView::writeFilterSettings(KConfig *config) void CalendarView::goToday() { + if ( mViewManager->currentView()->isMonthView() ) + mNavigator->selectTodayMonth(); + else mNavigator->selectToday(); } diff --git a/korganizer/datenavigator.cpp b/korganizer/datenavigator.cpp index e26e20b..3156b2b 100644 --- a/korganizer/datenavigator.cpp +++ b/korganizer/datenavigator.cpp @@ -199,6 +199,12 @@ void DateNavigator::selectWorkWeek( const QDate &d ) 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(); diff --git a/korganizer/datenavigator.h b/korganizer/datenavigator.h index 747e3d3..4a19e17 100644 --- a/korganizer/datenavigator.h +++ b/korganizer/datenavigator.h @@ -61,6 +61,7 @@ class DateNavigator : public QObject void selectWeekByDay( int weekDay, const QDate & ); void selectToday(); + void selectTodayMonth(); void selectPreviousYear(); void selectPreviousMonth(); diff --git a/korganizer/interfaces/korganizer/baseview.h b/korganizer/interfaces/korganizer/baseview.h index 09f8ba3..2ac9de1 100644 --- a/korganizer/interfaces/korganizer/baseview.h +++ b/korganizer/interfaces/korganizer/baseview.h @@ -134,6 +134,7 @@ class BaseView : public QWidget /** Return if this view is a view for displaying events. */ virtual bool isEventView() { return false; } + virtual bool isMonthView() { return false; } public slots: /** diff --git a/korganizer/komonthview.h b/korganizer/komonthview.h index d976246..e94952f 100644 --- a/korganizer/komonthview.h +++ b/korganizer/komonthview.h @@ -200,6 +200,7 @@ class KOMonthView: public KOEventView virtual void printPreview(CalPrinter *calPrinter, const QDate &, const QDate &); + bool isMonthView() { return true; } MonthViewCell * selectedCell(); public slots: |