summaryrefslogtreecommitdiffabout
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--bin/kdepim/WhatsNew.txt13
-rw-r--r--bin/kdepim/korganizer/germantranslation.txt9
-rw-r--r--korganizer/calendarview.cpp25
-rw-r--r--korganizer/kotodoview.cpp6
-rw-r--r--libkcal/calendar.cpp10
-rw-r--r--libkcal/calendar.h5
-rw-r--r--libkcal/incidence.cpp14
-rw-r--r--libkcal/incidence.h1
8 files changed, 73 insertions, 10 deletions
diff --git a/bin/kdepim/WhatsNew.txt b/bin/kdepim/WhatsNew.txt
index be0d2b2..aa6ab0a 100644
--- a/bin/kdepim/WhatsNew.txt
+++ b/bin/kdepim/WhatsNew.txt
@@ -1,5 +1,18 @@
1Info about the changes in new versions of KDE-Pim/Pi 1Info about the changes in new versions of KDE-Pim/Pi
2 2
3********** VERSION 2.0.27 ************
4
5More bugfixes.
6Added possibility to clone in KO/Pi a todo with all its subtodos.
7Added a timetracker funtionality in KO/Pi for todos in the todo view.
8If a todo is set to started and then to stopped it is saving information about the runtime in
9<yourhome>/kdepim/apps/timetrackerdir.
10To read, display, print this information an external program is needed which will be developed.
11It will display the data in a Gantt timetable view with one row for each todo.
12It will have many possibilities sorting the data after category, parent todos, attendees, ... and for creating/printing status reports/summaries.
13Merging of data from different computers/users will be quite easy because every run is stored in a single file.
14The program will be only available for the desktop (Linux+Windows) and it will be not Open Source.
15
3********** VERSION 2.0.26 ************ 16********** VERSION 2.0.26 ************
4 17
5Added two more fields to the KA/Pi view config: 18Added two more fields to the KA/Pi view config:
diff --git a/bin/kdepim/korganizer/germantranslation.txt b/bin/kdepim/korganizer/germantranslation.txt
index 5257bff..9476a89 100644
--- a/bin/kdepim/korganizer/germantranslation.txt
+++ b/bin/kdepim/korganizer/germantranslation.txt
@@ -1158,7 +1158,7 @@
1158{ "Only items due in the &range:","Nur Items in dem Zeitraum:" }, 1158{ "Only items due in the &range:","Nur Items in dem Zeitraum:" },
1159{ "Todo List","Todo Liste" }, 1159{ "Todo List","Todo Liste" },
1160{ "&Title:","&Titel:" }, 1160{ "&Title:","&Titel:" },
1161{ "Co&nnect subtodos with its parent","Verbinde Unter-Todos mit ihren Ober-Todos" }, 1161{ "Co&nnect subtodos with its parent","Verbinde Untertodos mit ihren Ober-Todos" },
1162{ "Todo list","Todo Liste" }, 1162{ "Todo list","Todo Liste" },
1163{ "&Print...","Drucke..." }, 1163{ "&Print...","Drucke..." },
1164{ "<qt>Printing on printer <b>%1</b></qt>","<qt>Drucke auf Drucker <b>%1</b></qt>" }, 1164{ "<qt>Printing on printer <b>%1</b></qt>","<qt>Drucke auf Drucker <b>%1</b></qt>" },
@@ -1177,7 +1177,7 @@
1177{ "public","öffentl." }, 1177{ "public","öffentl." },
1178{ "private","privat" }, 1178{ "private","privat" },
1179{ "confidential","vertraul." }, 1179{ "confidential","vertraul." },
1180{ "\nhas sub-todos.\nAll completed sub-todos\nwill be deleted as well!","\nhat Unter-Todos.\nAlle erledigten Unter-Todos\nwerden auch gelöscht!" }, 1180{ "\nhas sub-todos.\nAll completed sub-todos\nwill be deleted as well!","\nhat Untertodos.\nAlle erledigten Untertodos\nwerden auch gelöscht!" },
1181{ "Yesterday","Gestern" }, 1181{ "Yesterday","Gestern" },
1182{ "Day after tomorrow","Übermorgen" }, 1182{ "Day after tomorrow","Übermorgen" },
1183{ "Tomorrow","Morgen" }, 1183{ "Tomorrow","Morgen" },
@@ -1343,6 +1343,11 @@
1343{ "Todo is stopped","Todo ist gestoppt" }, 1343{ "Todo is stopped","Todo ist gestoppt" },
1344{ "Start todo","Starte Todo" }, 1344{ "Start todo","Starte Todo" },
1345{ "The todo\n%1\nis stopped.\nDo you want to set\nthe state to started?","Das Todo\n%1\nist gestoppt.\nWollen Sie es auf\ngestartet setzen?" }, 1345{ "The todo\n%1\nis stopped.\nDo you want to set\nthe state to started?","Das Todo\n%1\nist gestoppt.\nWollen Sie es auf\ngestartet setzen?" },
1346{ "The todo\n%1\nwill be cloned!\nIt has subtodos!\nDo you want to clone\nall subtodos as well?","Das Todo\n%1\nwird geklont!\nEs hat Untertodos!\nMöchten Sie\nalle Untertodos auch klonen?" },
1347{ "Todo has subtodos","Todo hat Untertodos" },
1348{ "","" },
1349{ "","" },
1350{ "","" },
1346{ "","" }, 1351{ "","" },
1347{ "","" }, 1352{ "","" },
1348{ "","" }, 1353{ "","" },
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp
index c530037..bd7376a 100644
--- a/korganizer/calendarview.cpp
+++ b/korganizer/calendarview.cpp
@@ -2704,11 +2704,32 @@ void CalendarView::cloneIncidence(Incidence * orgInc )
2704 2704
2705 if ( newInc->type() == "Todo" ) { 2705 if ( newInc->type() == "Todo" ) {
2706 Todo* t = (Todo*) newInc; 2706 Todo* t = (Todo*) newInc;
2707 bool cloneSub = false;
2708 if ( orgInc->relations().count() ) {
2709 int result = KMessageBox::warningYesNoCancel(this,
2710 i18n("The todo\n%1\nwill be cloned!\nIt has subtodos!\nDo you want to clone\nall subtodos as well?").arg( newInc->summary().left ( 25 ) ),
2711 i18n("Todo has subtodos"),
2712 i18n("Yes"),
2713 i18n("No"));
2714
2715 if ( result == KMessageBox::Cancel ) {
2716 delete t;
2717 return;
2718 }
2719 if (result == KMessageBox::Yes) cloneSub = true;
2720 }
2707 showTodoEditor(); 2721 showTodoEditor();
2708 mTodoEditor->editTodo( t ); 2722 mTodoEditor->editTodo( t );
2709 if ( mTodoEditor->exec() ) { 2723 if ( mTodoEditor->exec() ) {
2710 mCalendar->addTodo( t ); 2724 if ( cloneSub ) {
2711 updateView(); 2725 orgInc->cloneRelations( t );
2726 mCalendar->addIncidenceBranch( t );
2727 updateView();
2728
2729 } else {
2730 mCalendar->addTodo( t );
2731 updateView();
2732 }
2712 } else { 2733 } else {
2713 delete t; 2734 delete t;
2714 } 2735 }
diff --git a/korganizer/kotodoview.cpp b/korganizer/kotodoview.cpp
index 7ee1eef..9b5d4ce 100644
--- a/korganizer/kotodoview.cpp
+++ b/korganizer/kotodoview.cpp
@@ -1119,19 +1119,19 @@ void KOTodoView::itemDoubleClicked(QListViewItem *item)
1119} 1119}
1120void KOTodoView::toggleRunningItem() 1120void KOTodoView::toggleRunningItem()
1121{ 1121{
1122 qDebug("KOTodoView::toggleRunning() "); 1122 // qDebug("KOTodoView::toggleRunning() ");
1123 if ( ! mActiveItem ) 1123 if ( ! mActiveItem )
1124 return; 1124 return;
1125 Todo * t = mActiveItem->todo(); 1125 Todo * t = mActiveItem->todo();
1126 if ( t->isRunning() ) { 1126 if ( t->isRunning() ) {
1127 int result = KMessageBox::warningContinueCancel(this, 1127 int result = KMessageBox::warningContinueCancel(this,
1128 i18n("The todo\n%1\nis started.\nDo you want to set\nthe state to stopped?").arg(mActiveItem->text(0).left( 20 ) ),i18n("Todo is started"),i18n("Stop todo"),i18n("Cancel"), true); 1128 i18n("The todo\n%1\nis started.\nDo you want to set\nthe state to stopped?").arg(mActiveItem->text(0).left( 25 ) ),i18n("Todo is started"),i18n("Stop todo"),i18n("Cancel"), true);
1129 if (result != KMessageBox::Continue) return; 1129 if (result != KMessageBox::Continue) return;
1130 t->setRunning( false ); 1130 t->setRunning( false );
1131 mActiveItem->construct(); 1131 mActiveItem->construct();
1132 } else { 1132 } else {
1133 int result = KMessageBox::warningContinueCancel(this, 1133 int result = KMessageBox::warningContinueCancel(this,
1134 i18n("The todo\n%1\nis stopped.\nDo you want to set\nthe state to started?").arg(mActiveItem->text(0).left( 20 ) ),i18n("Todo is stopped"),i18n("Start todo"),i18n("Cancel"), true); 1134 i18n("The todo\n%1\nis stopped.\nDo you want to set\nthe state to started?").arg(mActiveItem->text(0).left( 25 ) ),i18n("Todo is stopped"),i18n("Start todo"),i18n("Cancel"), true);
1135 if (result != KMessageBox::Continue) return; 1135 if (result != KMessageBox::Continue) return;
1136 t->setRunning( true ); 1136 t->setRunning( true );
1137 mActiveItem->construct(); 1137 mActiveItem->construct();
diff --git a/libkcal/calendar.cpp b/libkcal/calendar.cpp
index 406cd48..ed39ddb 100644
--- a/libkcal/calendar.cpp
+++ b/libkcal/calendar.cpp
@@ -335,7 +335,15 @@ QPtrList<Event> Calendar::events()
335 mFilter->apply(&el); 335 mFilter->apply(&el);
336 return el; 336 return el;
337} 337}
338 338void Calendar::addIncidenceBranch(Incidence *i)
339{
340 addIncidence( i );
341 Incidence * inc;
342 QPtrList<Incidence> Relations = i->relations();
343 for (inc=Relations.first();inc;inc=Relations.next()) {
344 addIncidenceBranch( inc );
345 }
346}
339 347
340bool Calendar::addIncidence(Incidence *i) 348bool Calendar::addIncidence(Incidence *i)
341{ 349{
diff --git a/libkcal/calendar.h b/libkcal/calendar.h
index 2f2c3aa..ab40970 100644
--- a/libkcal/calendar.h
+++ b/libkcal/calendar.h
@@ -139,7 +139,10 @@ public:
139 139
140 @return true on success, false on error. 140 @return true on success, false on error.
141 */ 141 */
142 virtual bool addIncidence( Incidence * ); 142 virtual bool addIncidence( Incidence * );
143
144 // Adds an incidence and all relatedto incidences to the cal
145 void addIncidenceBranch( Incidence * );
143 /** 146 /**
144 Return filtered list of all incidences of this calendar. 147 Return filtered list of all incidences of this calendar.
145 */ 148 */
diff --git a/libkcal/incidence.cpp b/libkcal/incidence.cpp
index 6bca12c..78fa24f 100644
--- a/libkcal/incidence.cpp
+++ b/libkcal/incidence.cpp
@@ -263,7 +263,19 @@ void Incidence::recreate()
263 setIDStr( ":" ); 263 setIDStr( ":" );
264 setLastModified(QDateTime::currentDateTime()); 264 setLastModified(QDateTime::currentDateTime());
265} 265}
266 266void Incidence::cloneRelations( Incidence * newInc )
267{
268 // newInc is already a clone of this incidence
269 Incidence * inc;
270 Incidence * cloneInc;
271 QPtrList<Incidence> Relations = relations();
272 for (inc=Relations.first();inc;inc=Relations.next()) {
273 cloneInc = inc->clone();
274 cloneInc->recreate();
275 cloneInc->setRelatedTo( newInc );
276 inc->cloneRelations( cloneInc );
277 }
278}
267void Incidence::setReadOnly( bool readOnly ) 279void Incidence::setReadOnly( bool readOnly )
268{ 280{
269 IncidenceBase::setReadOnly( readOnly ); 281 IncidenceBase::setReadOnly( readOnly );
diff --git a/libkcal/incidence.h b/libkcal/incidence.h
index f8da342..60070a2 100644
--- a/libkcal/incidence.h
+++ b/libkcal/incidence.h
@@ -112,6 +112,7 @@ class Incidence : public IncidenceBase
112 virtual bool accept(Visitor &) { return false; } 112 virtual bool accept(Visitor &) { return false; }
113 113
114 virtual Incidence *clone() = 0; 114 virtual Incidence *clone() = 0;
115 virtual void cloneRelations( Incidence * );
115 116
116 virtual QDateTime getNextAlarmDateTime( bool * ok, int * offset ) const = 0; 117 virtual QDateTime getNextAlarmDateTime( bool * ok, int * offset ) const = 0;
117 void setReadOnly( bool ); 118 void setReadOnly( bool );