author | zautrix <zautrix> | 2005-01-22 10:18:16 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-01-22 10:18:16 (UTC) |
commit | 6946f6ab0ee6eeafee0c8ff5d33fffc0826c7452 (patch) (unidiff) | |
tree | 006248579ca44ad2e0c1a67db55b1a8013180ed7 | |
parent | b715b109b70b8cd24a2d9da1d4863c44d79fb2a4 (diff) | |
download | kdepimpi-6946f6ab0ee6eeafee0c8ff5d33fffc0826c7452.zip kdepimpi-6946f6ab0ee6eeafee0c8ff5d33fffc0826c7452.tar.gz kdepimpi-6946f6ab0ee6eeafee0c8ff5d33fffc0826c7452.tar.bz2 |
some small fixes
-rw-r--r-- | bin/kdepim/WhatsNew.txt | 17 | ||||
-rw-r--r-- | bin/kdepim/korganizer/germantranslation.txt | 13 | ||||
-rw-r--r-- | korganizer/calendarview.cpp | 52 | ||||
-rw-r--r-- | korganizer/calendarview.h | 2 | ||||
-rw-r--r-- | korganizer/koeditorgeneral.cpp | 20 | ||||
-rw-r--r-- | korganizer/koeditorgeneral.h | 1 | ||||
-rw-r--r-- | korganizer/kotodoview.cpp | 5 | ||||
-rw-r--r-- | korganizer/mainwindow.cpp | 11 | ||||
-rw-r--r-- | libkcal/calendarlocal.cpp | 2 | ||||
-rw-r--r-- | microkde/kdatetbl.cpp | 5 |
10 files changed, 95 insertions, 33 deletions
diff --git a/bin/kdepim/WhatsNew.txt b/bin/kdepim/WhatsNew.txt index fbe16d8..adbfd67 100644 --- a/bin/kdepim/WhatsNew.txt +++ b/bin/kdepim/WhatsNew.txt | |||
@@ -1,8 +1,25 @@ | |||
1 | Info about the changes in new versions of KDE-Pim/Pi | 1 | Info about the changes in new versions of KDE-Pim/Pi |
2 | 2 | ||
3 | ********** VERSION 1.9.20 ************ | ||
4 | |||
5 | KO/Pi: | ||
6 | Made it possible to delete a Todo, which has sub-todos. | ||
7 | Fixed two small problems in the todo view. | ||
8 | Added missing German translation for filter edit and print dialog. | ||
9 | Made search dialog closeable by cancel key. | ||
10 | |||
11 | Made it possible to select in the date picker the (ligt grey ) | ||
12 | dates of the prev./next month with the mouse. | ||
13 | |||
14 | Added for the "dislplay one day" agenda mode info in the caption: | ||
15 | Now it is displayed, if the selected day is from "day before yesterday" | ||
16 | to "day after tomorrow". | ||
17 | |||
18 | |||
19 | |||
3 | ********** VERSION 1.9.19 ************ | 20 | ********** VERSION 1.9.19 ************ |
4 | 21 | ||
5 | Added a lot of missing translations to KA/Pi, | 22 | Added a lot of missing translations to KA/Pi, |
6 | Added some missing translations to KO/Pi and OM/Pi. | 23 | Added some missing translations to KO/Pi and OM/Pi. |
7 | 24 | ||
8 | Fixed some minor problems in KA/Pi + KO/Pi. | 25 | Fixed some minor problems in KA/Pi + KO/Pi. |
diff --git a/bin/kdepim/korganizer/germantranslation.txt b/bin/kdepim/korganizer/germantranslation.txt index 0eb46e8..d260be3 100644 --- a/bin/kdepim/korganizer/germantranslation.txt +++ b/bin/kdepim/korganizer/germantranslation.txt | |||
@@ -83,13 +83,12 @@ | |||
83 | { "<b>Original event:</b><p>","<b>Original Termin:</b><p>" }, | 83 | { "<b>Original event:</b><p>","<b>Original Termin:</b><p>" }, |
84 | { " - both are modified after last sync"," - beide wurden nach der letzten Syncronisation verändert" }, | 84 | { " - both are modified after last sync"," - beide wurden nach der letzten Syncronisation verändert" }, |
85 | { "Busy","Belegt" }, | 85 | { "Busy","Belegt" }, |
86 | { "&Cancel","Abbre&chen" }, | 86 | { "&Cancel","Abbre&chen" }, |
87 | { "Cancel","Abbrechen" }, | 87 | { "Cancel","Abbrechen" }, |
88 | { "Cannot delete To-Do\nwhich has children.","Kann Todo nicht löschen,\n da noch Einträge vorhanden sind" }, | 88 | { "Cannot delete To-Do\nwhich has children.","Kann Todo nicht löschen,\n da noch Einträge vorhanden sind" }, |
89 | { "Cannot delete To-Do which has children.","Kann Todo nicht löschen, da noch Einträge vorhanden sind" }, | ||
90 | { "Can't generate mail:\nNo event selected.","Kann e-Mail nicht erstellen:\nKein Termin ausgewählt." }, | 89 | { "Can't generate mail:\nNo event selected.","Kann e-Mail nicht erstellen:\nKein Termin ausgewählt." }, |
91 | { "Categories...","Kategorien..." }, | 90 | { "Categories...","Kategorien..." }, |
92 | { "Categories","Kategorien" }, | 91 | { "Categories","Kategorien" }, |
93 | { "Category","Kategorie" }, | 92 | { "Category","Kategorie" }, |
94 | { "Center View","Zentriere Ansicht" }, | 93 | { "Center View","Zentriere Ansicht" }, |
95 | { "Change","Ändere" }, | 94 | { "Change","Ändere" }, |
@@ -796,15 +795,15 @@ | |||
796 | { "Details of attendee","Teilnehmerdetails" }, | 795 | { "Details of attendee","Teilnehmerdetails" }, |
797 | { "Work phone:\n","Telefon Arbeit:\n" }, | 796 | { "Work phone:\n","Telefon Arbeit:\n" }, |
798 | { "Work mobile phone:\n","Mobiltelefon Arbeit:\n" }, | 797 | { "Work mobile phone:\n","Mobiltelefon Arbeit:\n" }, |
799 | { "Home phone:\n","Telefon privat:\n" }, | 798 | { "Home phone:\n","Telefon privat:\n" }, |
800 | { "Mobile home phone:\n","Mobiltelefon privat:\n" }, | 799 | { "Mobile home phone:\n","Mobiltelefon privat:\n" }, |
801 | { "Email:\n","Email:\n" }, | 800 | { "Email:\n","Email:\n" }, |
802 | { "Alarm disabled","Alarm deaktiviert" }, | 801 | { "Alarm disabled for this item","Alarm deaktiviert für dieses Item" }, |
803 | { "Audio.Al.: ","Audio Al.: " }, | 802 | { "Audio Al.: ","Audio Al.: " }, |
804 | { "Proc.Al.: ","Proc.Al.: " }, | 803 | { "Proc.Al.: ","Proz.Al.: " }, |
805 | { "No sound set","Kein Sound definiert" }, | 804 | { "No sound set","Kein Sound definiert" }, |
806 | { "*.wav|Wav Files","*.wav|Wav Dateien" }, | 805 | { "*.wav|Wav Files","*.wav|Wav Dateien" }, |
807 | { "No program set","Kein Programm definiert" }, | 806 | { "No program set","Kein Programm definiert" }, |
808 | { "Running '%1'","Ausführen '%1'" }, | 807 | { "Running '%1'","Ausführen '%1'" }, |
809 | { "Playing '%1'","Abspielen '%1'" }, | 808 | { "Playing '%1'","Abspielen '%1'" }, |
810 | { "Show Sync Events in WN/Agenda view","Zeige Sync Events in WN/Agenda Ansicht" }, | 809 | { "Show Sync Events in WN/Agenda view","Zeige Sync Events in WN/Agenda Ansicht" }, |
@@ -1188,11 +1187,15 @@ | |||
1188 | { "events","Ereignisse" }, | 1187 | { "events","Ereignisse" }, |
1189 | { "todos","Todos" }, | 1188 | { "todos","Todos" }, |
1190 | { "journals","Journale" }, | 1189 | { "journals","Journale" }, |
1191 | { "public","öffentlich" }, | 1190 | { "public","öffentlich" }, |
1192 | { "private","privat" }, | 1191 | { "private","privat" }, |
1193 | { "confidential","vertraulich" }, | 1192 | { "confidential","vertraulich" }, |
1194 | { "","" }, | 1193 | { "\nhas sub-todos.\nAll completed sub-todos\nwill be deleted as well!","\nhat Unter-Todos.\nAlle erledigten Unter-Todos\nwerden auch gelöscht!" }, |
1194 | { "Yesterday","Gestern" }, | ||
1195 | { "Day after tomorrow","Übermorgen" }, | ||
1196 | { "Tomorrow","Morgen" }, | ||
1197 | { "Day before yesterday","Vorgestern" }, | ||
1195 | { "","" }, | 1198 | { "","" }, |
1196 | { "","" }, | 1199 | { "","" }, |
1197 | { "","" }, | 1200 | { "","" }, |
1198 | { "","" }, | 1201 | { "","" }, |
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp index 8f05276..038da54 100644 --- a/korganizer/calendarview.cpp +++ b/korganizer/calendarview.cpp | |||
@@ -2182,15 +2182,15 @@ void CalendarView::updateView() | |||
2182 | 2182 | ||
2183 | void CalendarView::updateUnmanagedViews() | 2183 | void CalendarView::updateUnmanagedViews() |
2184 | { | 2184 | { |
2185 | mDateNavigator->updateDayMatrix(); | 2185 | mDateNavigator->updateDayMatrix(); |
2186 | } | 2186 | } |
2187 | 2187 | ||
2188 | int CalendarView::msgItemDelete() | 2188 | int CalendarView::msgItemDelete(const QString name) |
2189 | { | 2189 | { |
2190 | return KMessageBox::warningContinueCancel(this, | 2190 | return KMessageBox::warningContinueCancel(this,name +"\n\n"+ |
2191 | i18n("This item will be\npermanently deleted."), | 2191 | i18n("This item will be\npermanently deleted."), |
2192 | i18n("KO/Pi Confirmation"),i18n("Delete")); | 2192 | i18n("KO/Pi Confirmation"),i18n("Delete")); |
2193 | } | 2193 | } |
2194 | 2194 | ||
2195 | 2195 | ||
2196 | void CalendarView::edit_cut() | 2196 | void CalendarView::edit_cut() |
@@ -2885,46 +2885,49 @@ void CalendarView::deleteTodo(Todo *todo) | |||
2885 | { | 2885 | { |
2886 | if (!todo) { | 2886 | if (!todo) { |
2887 | KNotifyClient::beep(); | 2887 | KNotifyClient::beep(); |
2888 | return; | 2888 | return; |
2889 | } | 2889 | } |
2890 | if (KOPrefs::instance()->mConfirm) { | 2890 | if (KOPrefs::instance()->mConfirm) { |
2891 | switch (msgItemDelete()) { | 2891 | QString text = todo->summary().left(20); |
2892 | if (!todo->relations().isEmpty()) { | ||
2893 | text += i18n("\nhas sub-todos.\nAll completed sub-todos\nwill be deleted as well!"); | ||
2894 | |||
2895 | } | ||
2896 | switch (msgItemDelete(text)) { | ||
2892 | case KMessageBox::Continue: // OK | 2897 | case KMessageBox::Continue: // OK |
2898 | bool deleteT = false; | ||
2893 | if (!todo->relations().isEmpty()) { | 2899 | if (!todo->relations().isEmpty()) { |
2894 | KMessageBox::sorry(this,i18n("Cannot delete To-Do\nwhich has children."), | 2900 | deleteT = removeCompletedSubTodos( todo ); |
2895 | i18n("Delete To-Do")); | 2901 | } |
2896 | } else { | 2902 | // deleteT == true: todo already deleted in removeCompletedSubTodos |
2903 | if ( !deleteT ) { | ||
2897 | checkExternalId( todo ); | 2904 | checkExternalId( todo ); |
2898 | calendar()->deleteTodo(todo); | 2905 | calendar()->deleteTodo(todo); |
2899 | changeTodoDisplay( todo,KOGlobals::EVENTDELETED ); | 2906 | changeTodoDisplay( todo,KOGlobals::EVENTDELETED ); |
2900 | updateView(); | 2907 | updateView(); |
2901 | } | 2908 | } |
2902 | break; | 2909 | break; |
2903 | } // switch | 2910 | } // switch |
2904 | } else { | 2911 | } else { |
2905 | if (!todo->relations().isEmpty()) { | 2912 | checkExternalId( todo ); |
2906 | KMessageBox::sorry(this,i18n("Cannot delete To-Do\nwhich has children."), | 2913 | mCalendar->deleteTodo(todo); |
2907 | i18n("Delete To-Do")); | 2914 | changeTodoDisplay( todo,KOGlobals::EVENTDELETED ); |
2908 | } else { | 2915 | updateView(); |
2909 | checkExternalId( todo ); | ||
2910 | mCalendar->deleteTodo(todo); | ||
2911 | changeTodoDisplay( todo,KOGlobals::EVENTDELETED ); | ||
2912 | updateView(); | ||
2913 | } | ||
2914 | } | 2916 | } |
2917 | |||
2915 | emit updateSearchDialog(); | 2918 | emit updateSearchDialog(); |
2916 | } | 2919 | } |
2917 | void CalendarView::deleteJournal(Journal *jour) | 2920 | void CalendarView::deleteJournal(Journal *jour) |
2918 | { | 2921 | { |
2919 | if (!jour) { | 2922 | if (!jour) { |
2920 | KNotifyClient::beep(); | 2923 | KNotifyClient::beep(); |
2921 | return; | 2924 | return; |
2922 | } | 2925 | } |
2923 | if (KOPrefs::instance()->mConfirm) { | 2926 | if (KOPrefs::instance()->mConfirm) { |
2924 | switch (msgItemDelete()) { | 2927 | switch (msgItemDelete( jour->description().left(20))) { |
2925 | case KMessageBox::Continue: // OK | 2928 | case KMessageBox::Continue: // OK |
2926 | calendar()->deleteJournal(jour); | 2929 | calendar()->deleteJournal(jour); |
2927 | updateView(); | 2930 | updateView(); |
2928 | break; | 2931 | break; |
2929 | } // switch | 2932 | } // switch |
2930 | } else { | 2933 | } else { |
@@ -3480,12 +3483,29 @@ void CalendarView::showDates(const DateList &selectedDates) | |||
3480 | } | 3483 | } |
3481 | 3484 | ||
3482 | QString selDates; | 3485 | QString selDates; |
3483 | selDates = KGlobal::locale()->formatDate( selectedDates.first(), true); | 3486 | selDates = KGlobal::locale()->formatDate( selectedDates.first(), true); |
3484 | if (selectedDates.first() < selectedDates.last() ) | 3487 | if (selectedDates.first() < selectedDates.last() ) |
3485 | selDates += " - " + KGlobal::locale()->formatDate( selectedDates.last(),true); | 3488 | selDates += " - " + KGlobal::locale()->formatDate( selectedDates.last(),true); |
3489 | else { | ||
3490 | QString addString; | ||
3491 | if ( selectedDates.first() == QDateTime::currentDateTime().date() ) | ||
3492 | addString = i18n("Today"); | ||
3493 | else if ( selectedDates.first() == QDateTime::currentDateTime().date().addDays(1) ) | ||
3494 | addString = i18n("Tomorrow"); | ||
3495 | else if ( selectedDates.first() == QDateTime::currentDateTime().date().addDays(-1) ) | ||
3496 | addString = i18n("Yesterday"); | ||
3497 | else if ( selectedDates.first() == QDateTime::currentDateTime().date().addDays(-2) ) | ||
3498 | addString = i18n("Day before yesterday"); | ||
3499 | else if ( selectedDates.first() == QDateTime::currentDateTime().date().addDays(2) ) | ||
3500 | addString = i18n("Day after tomorrow"); | ||
3501 | if ( !addString.isEmpty() ) { | ||
3502 | topLevelWidget()->setCaption( addString+", " + selDates ); | ||
3503 | return; | ||
3504 | } | ||
3505 | } | ||
3486 | topLevelWidget()->setCaption( i18n("Dates: ") + selDates ); | 3506 | topLevelWidget()->setCaption( i18n("Dates: ") + selDates ); |
3487 | 3507 | ||
3488 | } | 3508 | } |
3489 | 3509 | ||
3490 | QPtrList<CalFilter> CalendarView::filters() | 3510 | QPtrList<CalFilter> CalendarView::filters() |
3491 | { | 3511 | { |
diff --git a/korganizer/calendarview.h b/korganizer/calendarview.h index e27da9a..c8d6bdd 100644 --- a/korganizer/calendarview.h +++ b/korganizer/calendarview.h | |||
@@ -482,13 +482,13 @@ class CalendarView : public KOrg::CalendarViewBase, public KCal::Calendar::Obser | |||
482 | //Attendee* getYourAttendee(Event *event); | 482 | //Attendee* getYourAttendee(Event *event); |
483 | void setBlockShowDates( bool b ) { mBlockShowDates = b ;} | 483 | void setBlockShowDates( bool b ) { mBlockShowDates = b ;} |
484 | protected: | 484 | protected: |
485 | void schedule(Scheduler::Method, Incidence *incidence = 0); | 485 | void schedule(Scheduler::Method, Incidence *incidence = 0); |
486 | 486 | ||
487 | // returns KMsgBox::OKCandel() | 487 | // returns KMsgBox::OKCandel() |
488 | int msgItemDelete(); | 488 | int msgItemDelete(const QString name); |
489 | void showEventEditor(); | 489 | void showEventEditor(); |
490 | void showTodoEditor(); | 490 | void showTodoEditor(); |
491 | void writeLocale(); | 491 | void writeLocale(); |
492 | Todo *selectedTodo(); | 492 | Todo *selectedTodo(); |
493 | 493 | ||
494 | private: | 494 | private: |
diff --git a/korganizer/koeditorgeneral.cpp b/korganizer/koeditorgeneral.cpp index 94e1f4c..b4fe965 100644 --- a/korganizer/koeditorgeneral.cpp +++ b/korganizer/koeditorgeneral.cpp | |||
@@ -280,12 +280,26 @@ void KOEditorGeneral::pickAlarmProgram() | |||
280 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Proc.Al.: ") + mAlarmProgram ); | 280 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Proc.Al.: ") + mAlarmProgram ); |
281 | if ( mAlarmSoundButton->isOn()) | 281 | if ( mAlarmSoundButton->isOn()) |
282 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Sound.Al.: ") + mAlarmSound ); | 282 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Sound.Al.: ") + mAlarmSound ); |
283 | } | 283 | } |
284 | 284 | ||
285 | 285 | ||
286 | QString KOEditorGeneral::getFittingPath( const QString s ) | ||
287 | { | ||
288 | int maxlen = 50; | ||
289 | if ( QApplication::desktop()->width() < 640 ) { | ||
290 | if ( QApplication::desktop()->width() < 320 ) | ||
291 | maxlen = 22; | ||
292 | else | ||
293 | maxlen = 35; | ||
294 | } | ||
295 | if ( s.length() > maxlen ) { | ||
296 | return "..."+s.right(maxlen -3); | ||
297 | } | ||
298 | return s; | ||
299 | } | ||
286 | 300 | ||
287 | void KOEditorGeneral::enableAlarmEdit(bool enable) | 301 | void KOEditorGeneral::enableAlarmEdit(bool enable) |
288 | { | 302 | { |
289 | if ( enable ) { | 303 | if ( enable ) { |
290 | if (!mAlarmProgramButton->isOn() && !mAlarmSoundButton->isOn()) { | 304 | if (!mAlarmProgramButton->isOn() && !mAlarmSoundButton->isOn()) { |
291 | mAlarmSoundButton->setOn( true ); | 305 | mAlarmSoundButton->setOn( true ); |
@@ -294,18 +308,18 @@ void KOEditorGeneral::enableAlarmEdit(bool enable) | |||
294 | else { | 308 | else { |
295 | if ( ! QFile::exists( mAlarmSound ) ) | 309 | if ( ! QFile::exists( mAlarmSound ) ) |
296 | mAlarmSound = KOPrefs::instance()->mDefaultAlarmFile; | 310 | mAlarmSound = KOPrefs::instance()->mDefaultAlarmFile; |
297 | } | 311 | } |
298 | } | 312 | } |
299 | if (mAlarmProgramButton->isOn()) | 313 | if (mAlarmProgramButton->isOn()) |
300 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Proc.Al.: ") + mAlarmProgram ); | 314 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Proc.Al.: ") + getFittingPath(mAlarmProgram) ); |
301 | if (!mAlarmSound.isEmpty() && mAlarmSoundButton->isOn()) | 315 | if (!mAlarmSound.isEmpty() && mAlarmSoundButton->isOn()) |
302 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Sound.Al.: ") + mAlarmSound ); | 316 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Audio Al.: ") + getFittingPath(mAlarmSound) ); |
303 | } | 317 | } |
304 | else { | 318 | else { |
305 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Alarm disabled")); | 319 | ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Alarm disabled for this item")); |
306 | 320 | ||
307 | } | 321 | } |
308 | mAlarmTimeEdit->setEnabled(enable); | 322 | mAlarmTimeEdit->setEnabled(enable); |
309 | mAlarmSoundButton->setEnabled(enable); | 323 | mAlarmSoundButton->setEnabled(enable); |
310 | mAlarmProgramButton->setEnabled(enable); | 324 | mAlarmProgramButton->setEnabled(enable); |
311 | mAlarmIncrCombo->setEnabled(enable); | 325 | mAlarmIncrCombo->setEnabled(enable); |
diff --git a/korganizer/koeditorgeneral.h b/korganizer/koeditorgeneral.h index c58335e..de8edaf 100644 --- a/korganizer/koeditorgeneral.h +++ b/korganizer/koeditorgeneral.h | |||
@@ -102,11 +102,12 @@ class KOEditorGeneral : public QObject | |||
102 | QComboBox *mSecrecyCombo; | 102 | QComboBox *mSecrecyCombo; |
103 | QCheckBox *mCancelBox; | 103 | QCheckBox *mCancelBox; |
104 | QPushButton *mCategoriesButton; | 104 | QPushButton *mCategoriesButton; |
105 | QLabel *mCategoriesLabel; | 105 | QLabel *mCategoriesLabel; |
106 | 106 | ||
107 | private: | 107 | private: |
108 | QString getFittingPath( const QString ) ; | ||
108 | QString mAlarmSound; | 109 | QString mAlarmSound; |
109 | QString mAlarmProgram; | 110 | QString mAlarmProgram; |
110 | }; | 111 | }; |
111 | 112 | ||
112 | #endif | 113 | #endif |
diff --git a/korganizer/kotodoview.cpp b/korganizer/kotodoview.cpp index 97b4a03..30adb06 100644 --- a/korganizer/kotodoview.cpp +++ b/korganizer/kotodoview.cpp | |||
@@ -815,18 +815,13 @@ void KOTodoView::showTodo() | |||
815 | } | 815 | } |
816 | } | 816 | } |
817 | 817 | ||
818 | void KOTodoView::deleteTodo() | 818 | void KOTodoView::deleteTodo() |
819 | { | 819 | { |
820 | if (mActiveItem) { | 820 | if (mActiveItem) { |
821 | if (mActiveItem->childCount()) { | ||
822 | KMessageBox::sorry(this,i18n("Cannot delete To-Do which has children."), | ||
823 | i18n("Delete To-Do")); | ||
824 | } else { | ||
825 | emit deleteTodoSignal(mActiveItem->todo()); | 821 | emit deleteTodoSignal(mActiveItem->todo()); |
826 | } | ||
827 | } | 822 | } |
828 | } | 823 | } |
829 | 824 | ||
830 | void KOTodoView::setNewPriority(int index) | 825 | void KOTodoView::setNewPriority(int index) |
831 | { | 826 | { |
832 | if (mActiveItem && !mActiveItem->todo()->isReadOnly ()) { | 827 | if (mActiveItem && !mActiveItem->todo()->isReadOnly ()) { |
diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp index 151b55b..7b07a2e 100644 --- a/korganizer/mainwindow.cpp +++ b/korganizer/mainwindow.cpp | |||
@@ -1701,13 +1701,22 @@ void MainWindow::configureToolBar( int item ) | |||
1701 | 1701 | ||
1702 | void MainWindow::setCaptionToDates() | 1702 | void MainWindow::setCaptionToDates() |
1703 | { | 1703 | { |
1704 | QString selDates; | 1704 | QString selDates; |
1705 | selDates = KGlobal::locale()->formatDate(mView->startDate(), true); | 1705 | selDates = KGlobal::locale()->formatDate(mView->startDate(), true); |
1706 | if (mView->startDate() < mView->endDate() ) | 1706 | if (mView->startDate() < mView->endDate() ) |
1707 | selDates += " - " + KGlobal::locale()->formatDate(mView->endDate(), true); | 1707 | selDates += " - " + KGlobal::locale()->formatDate(mView->endDate(), true); |
1708 | else { | ||
1709 | QString addString; | ||
1710 | if ( mView->startDate() == QDateTime::currentDateTime().date() ) | ||
1711 | addString = i18n("Today"); | ||
1712 | else if ( mView->startDate() == QDateTime::currentDateTime().date().addDays(1) ) | ||
1713 | addString = i18n("Tomorrow"); | ||
1714 | if ( !addString.isEmpty() ) | ||
1715 | selDates = addString+", "+selDates ; | ||
1716 | } | ||
1708 | setCaption( i18n("Dates: ") + selDates ); | 1717 | setCaption( i18n("Dates: ") + selDates ); |
1709 | 1718 | ||
1710 | } | 1719 | } |
1711 | // parameter item == 0: reinit | 1720 | // parameter item == 0: reinit |
1712 | void MainWindow::configureAgenda( int item ) | 1721 | void MainWindow::configureAgenda( int item ) |
1713 | { | 1722 | { |
diff --git a/libkcal/calendarlocal.cpp b/libkcal/calendarlocal.cpp index 12294c0..0eba6a9 100644 --- a/libkcal/calendarlocal.cpp +++ b/libkcal/calendarlocal.cpp | |||
@@ -199,14 +199,14 @@ bool CalendarLocal::addTodo( Todo *todo ) | |||
199 | } | 199 | } |
200 | 200 | ||
201 | void CalendarLocal::deleteTodo( Todo *todo ) | 201 | void CalendarLocal::deleteTodo( Todo *todo ) |
202 | { | 202 | { |
203 | // Handle orphaned children | 203 | // Handle orphaned children |
204 | if ( mUndoIncidence ) delete mUndoIncidence; | 204 | if ( mUndoIncidence ) delete mUndoIncidence; |
205 | mUndoIncidence = todo->clone(); | ||
206 | removeRelations( todo ); | 205 | removeRelations( todo ); |
206 | mUndoIncidence = todo->clone(); | ||
207 | 207 | ||
208 | if ( mTodoList.removeRef( todo ) ) { | 208 | if ( mTodoList.removeRef( todo ) ) { |
209 | setModified( true ); | 209 | setModified( true ); |
210 | } | 210 | } |
211 | } | 211 | } |
212 | 212 | ||
diff --git a/microkde/kdatetbl.cpp b/microkde/kdatetbl.cpp index 146291b..508ce31 100644 --- a/microkde/kdatetbl.cpp +++ b/microkde/kdatetbl.cpp | |||
@@ -341,24 +341,27 @@ KDateTable::contentsMousePressEvent(QMouseEvent *e) | |||
341 | col=columnAt(mouseCoord.x()); | 341 | col=columnAt(mouseCoord.x()); |
342 | if(row<0 || col<0) | 342 | if(row<0 || col<0) |
343 | { // the user clicked on the frame of the table | 343 | { // the user clicked on the frame of the table |
344 | return; | 344 | return; |
345 | } | 345 | } |
346 | pos=7*(row-1)+col+1; | 346 | pos=7*(row-1)+col+1; |
347 | #if 0 | ||
347 | if(pos+dayoff<=firstday) | 348 | if(pos+dayoff<=firstday) |
348 | { // this day is in the previous month | 349 | { // this day is in the previous month |
349 | KNotifyClient::beep(); | 350 | KNotifyClient::beep(); |
350 | return; | 351 | return; |
351 | } | 352 | } |
352 | if(firstday+numdays<pos+dayoff) | 353 | if(firstday+numdays<pos+dayoff) |
353 | { // this date is in the next month | 354 | { // this date is in the next month |
354 | KNotifyClient::beep(); | 355 | KNotifyClient::beep(); |
355 | return; | 356 | return; |
356 | } | 357 | } |
358 | #endif | ||
357 | temp=firstday+date.day()-dayoff-1; | 359 | temp=firstday+date.day()-dayoff-1; |
358 | setDate(QDate(date.year(), date.month(), pos-firstday+dayoff)); | 360 | QDate da = QDate(date.year(), date.month(),1); |
361 | setDate(da.addDays( pos-firstday+dayoff-1)); | ||
359 | updateCell(temp/7+1, temp%7); // Update the previously selected cell | 362 | updateCell(temp/7+1, temp%7); // Update the previously selected cell |
360 | updateCell(row, col); // Update the selected cell | 363 | updateCell(row, col); // Update the selected cell |
361 | // assert(QDate(date.year(), date.month(), pos-firstday+dayoff).isValid()); | 364 | // assert(QDate(date.year(), date.month(), pos-firstday+dayoff).isValid()); |
362 | emit(tableClicked()); | 365 | emit(tableClicked()); |
363 | } | 366 | } |
364 | 367 | ||