summaryrefslogtreecommitdiffabout
path: root/korganizer
authorzautrix <zautrix>2005-01-30 01:41:12 (UTC)
committer zautrix <zautrix>2005-01-30 01:41:12 (UTC)
commit949c6e28c83668176fd9c29e12668322c6ae627f (patch) (unidiff)
treef5b21c9fe6d9f1906a7bca6899b44bcf359f2cc6 /korganizer
parenta8fae20ad7bcb59df9a603c88accf3a10401c2f9 (diff)
downloadkdepimpi-949c6e28c83668176fd9c29e12668322c6ae627f.zip
kdepimpi-949c6e28c83668176fd9c29e12668322c6ae627f.tar.gz
kdepimpi-949c6e28c83668176fd9c29e12668322c6ae627f.tar.bz2
bugs
Diffstat (limited to 'korganizer') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/koagendaview.cpp16
-rw-r--r--korganizer/koeventviewer.cpp5
-rw-r--r--korganizer/koeventviewerdialog.cpp1
3 files changed, 17 insertions, 5 deletions
diff --git a/korganizer/koagendaview.cpp b/korganizer/koagendaview.cpp
index e0a1a21..1864e22 100644
--- a/korganizer/koagendaview.cpp
+++ b/korganizer/koagendaview.cpp
@@ -1104,112 +1104,118 @@ void KOAgendaView::fillAgenda()
1104 int count = 0; 1104 int count = 0;
1105 int max = event->dtStart().daysTo( event->dtEnd() ) +2; 1105 int max = event->dtStart().daysTo( event->dtEnd() ) +2;
1106 while (! event->recursOn( dateit ) && count <= max ) { 1106 while (! event->recursOn( dateit ) && count <= max ) {
1107 ++count; 1107 ++count;
1108 dateit = dateit.addDays( -1 ); 1108 dateit = dateit.addDays( -1 );
1109 } 1109 }
1110 bool ok; 1110 bool ok;
1111 QDateTime nextOcstart = event->getNextOccurence( QDateTime(dateit) ,&ok ); 1111 QDateTime nextOcstart = event->getNextOccurence( QDateTime(dateit) ,&ok );
1112 if ( ok ) 1112 if ( ok )
1113 { 1113 {
1114 int secs = event->dtStart().secsTo( event->dtEnd() ); 1114 int secs = event->dtStart().secsTo( event->dtEnd() );
1115 QDateTime nextOcend =nextOcstart.addSecs( secs ); ; 1115 QDateTime nextOcend =nextOcstart.addSecs( secs ); ;
1116 beginX = currentDate.daysTo(nextOcstart.date()) + curCol; 1116 beginX = currentDate.daysTo(nextOcstart.date()) + curCol;
1117 endX = currentDate.daysTo(nextOcend.date()) + curCol; 1117 endX = currentDate.daysTo(nextOcend.date()) + curCol;
1118 1118
1119 } 1119 }
1120 } 1120 }
1121 int startY = mAgenda->timeToY(event->dtStart().time()); 1121 int startY = mAgenda->timeToY(event->dtStart().time());
1122 int endY = mAgenda->timeToY(event->dtEnd().time()) - 1; 1122 int endY = mAgenda->timeToY(event->dtEnd().time()) - 1;
1123 //qDebug("insert %d %d %d %d %d ",beginX,endX,startY,endY , curCol ); 1123 //qDebug("insert %d %d %d %d %d ",beginX,endX,startY,endY , curCol );
1124 if ((beginX <= 0 && curCol == 0) || beginX == curCol) { 1124 if ((beginX <= 0 && curCol == 0) || beginX == curCol) {
1125 //qDebug("insert!!! "); 1125 //qDebug("insert!!! ");
1126 mAgenda->insertMultiItem(event,currentDate,beginX,endX,startY,endY); 1126 mAgenda->insertMultiItem(event,currentDate,beginX,endX,startY,endY);
1127 } 1127 }
1128 if (beginX == curCol) { 1128 if (beginX == curCol) {
1129 mMaxY[curCol] = mAgenda->timeToY(QTime(23,59)); 1129 mMaxY[curCol] = mAgenda->timeToY(QTime(23,59));
1130 if (startY < mMinY[curCol]) mMinY[curCol] = startY; 1130 if (startY < mMinY[curCol]) mMinY[curCol] = startY;
1131 } else if (endX == curCol) { 1131 } else if (endX == curCol) {
1132 mMinY[curCol] = mAgenda->timeToY(QTime(0,0)); 1132 mMinY[curCol] = mAgenda->timeToY(QTime(0,0));
1133 if (endY > mMaxY[curCol]) mMaxY[curCol] = endY; 1133 if (endY > mMaxY[curCol]) mMaxY[curCol] = endY;
1134 } else { 1134 } else {
1135 mMinY[curCol] = mAgenda->timeToY(QTime(0,0)); 1135 mMinY[curCol] = mAgenda->timeToY(QTime(0,0));
1136 mMaxY[curCol] = mAgenda->timeToY(QTime(23,59)); 1136 mMaxY[curCol] = mAgenda->timeToY(QTime(23,59));
1137 } 1137 }
1138 } else { 1138 } else {
1139 int startY = mAgenda->timeToY(event->dtStart().time()); 1139 int startY = mAgenda->timeToY(event->dtStart().time());
1140 int endY = mAgenda->timeToY(event->dtEnd().time()) - 1; 1140 int endY = mAgenda->timeToY(event->dtEnd().time()) - 1;
1141 if (endY < startY) endY = startY; 1141 if (endY < startY) endY = startY;
1142 mAgenda->insertItem(event,currentDate,curCol,startY,endY); 1142 mAgenda->insertItem(event,currentDate,curCol,startY,endY);
1143 if (startY < mMinY[curCol]) mMinY[curCol] = startY; 1143 if (startY < mMinY[curCol]) mMinY[curCol] = startY;
1144 if (endY > mMaxY[curCol]) mMaxY[curCol] = endY; 1144 if (endY > mMaxY[curCol]) mMaxY[curCol] = endY;
1145 } 1145 }
1146 } 1146 }
1147 // ---------- [display Todos -------------- 1147 // ---------- [display Todos --------------
1148 unsigned int numTodo; 1148 unsigned int numTodo;
1149 for (numTodo = 0; numTodo < todos.count(); ++numTodo) { 1149 for (numTodo = 0; numTodo < todos.count(); ++numTodo) {
1150 Todo *todo = todos.at(numTodo); 1150 Todo *todo = todos.at(numTodo);
1151 1151
1152 if ( ! todo->hasDueDate() ) continue; // todo shall not be displayed if it has no date 1152 if ( ! todo->hasDueDate() && !todo->hasCompletedDate()) continue; // todo shall not be displayed if it has no date
1153 1153
1154 // ToDo items shall be displayed for the day they are due, but only showed today if they are already overdue. 1154 // ToDo items shall be displayed for the day they are due, but only showed today if they are already overdue.
1155 // Already completed items can be displayed on their original due date 1155 // Already completed items can be displayed on their original due date
1156 //if not KOPrefs::instance()->mShowTodoInAgenda, show overdue in agenda 1156 //if not KOPrefs::instance()->mShowTodoInAgenda, show overdue in agenda
1157 bool overdue = (!todo->isCompleted()) && (todo->dtDue() < today) && KOPrefs::instance()->mShowTodoInAgenda; 1157 bool overdue = (!todo->isCompleted()) && (todo->dtDue() < today) && KOPrefs::instance()->mShowTodoInAgenda;
1158 1158
1159 if ( ((todo->dtDue().date() == currentDate) && !overdue) || 1159 if ( ((todo->dtDue().date() == currentDate) && !overdue) || ( todo->hasCompletedDate() && todo->completed().date() == currentDate )||
1160 ((currentDate == today) && overdue) ) { 1160 ((currentDate == today) && overdue) ) {
1161 if ( todo->doesFloat() || overdue ) { // Todo has no due-time set or is already overdue 1161 if ( (todo->doesFloat() || overdue ) && !todo->hasCompletedDate() ) { // Todo has no due-time set or is already overdue
1162 if ( KOPrefs::instance()->mShowTodoInAgenda ) 1162 if ( KOPrefs::instance()->mShowTodoInAgenda )
1163 mAllDayAgenda->insertAllDayItem(todo, currentDate, curCol, curCol); 1163 mAllDayAgenda->insertAllDayItem(todo, currentDate, curCol, curCol);
1164 } 1164 }
1165 else { 1165 else {
1166 1166 QDateTime dt;
1167 int endY = mAgenda->timeToY(todo->dtDue().time()) - 1; 1167 if ( todo->hasCompletedDate() )
1168 dt = todo->completed();
1169 else
1170 dt = todo->dtDue();;
1171
1172
1173 int endY = mAgenda->timeToY(dt.time()) - 1;
1168 int hi = (18/KOPrefs::instance()->mHourSize); 1174 int hi = (18/KOPrefs::instance()->mHourSize);
1169 //qDebug("hei %d ",KOPrefs::instance()->mHourSize); 1175 //qDebug("hei %d ",KOPrefs::instance()->mHourSize);
1170 int startY = endY -hi; 1176 int startY = endY -hi;
1171 1177
1172 mAgenda->insertItem(todo,currentDate,curCol,startY,endY); 1178 mAgenda->insertItem(todo,currentDate,curCol,startY,endY);
1173 1179
1174 if (startY < mMinY[curCol]) mMinY[curCol] = startY; 1180 if (startY < mMinY[curCol]) mMinY[curCol] = startY;
1175 if (endY > mMaxY[curCol]) mMaxY[curCol] = endY; 1181 if (endY > mMaxY[curCol]) mMaxY[curCol] = endY;
1176 } 1182 }
1177 } 1183 }
1178 } 1184 }
1179 // ---------- display Todos] -------------- 1185 // ---------- display Todos] --------------
1180 1186
1181 ++curCol; 1187 ++curCol;
1182 } 1188 }
1183 mAgenda->hideUnused(); 1189 mAgenda->hideUnused();
1184 mAllDayAgenda->hideUnused(); 1190 mAllDayAgenda->hideUnused();
1185 mAgenda->checkScrollBoundaries(); 1191 mAgenda->checkScrollBoundaries();
1186 1192
1187 deleteSelectedDateTime(); 1193 deleteSelectedDateTime();
1188 1194
1189 createDayLabels(); 1195 createDayLabels();
1190 emit incidenceSelected( 0 ); 1196 emit incidenceSelected( 0 );
1191 1197
1192 if ( globalFlagBlockAgenda == 2 ) { 1198 if ( globalFlagBlockAgenda == 2 ) {
1193 if ( KOPrefs::instance()->mSetTimeToDayStartAt ) 1199 if ( KOPrefs::instance()->mSetTimeToDayStartAt )
1194 setStartHour( KOPrefs::instance()->mDayBegins ); 1200 setStartHour( KOPrefs::instance()->mDayBegins );
1195 else if ( KOPrefs::instance()->mCenterOnCurrentTime ) 1201 else if ( KOPrefs::instance()->mCenterOnCurrentTime )
1196 setStartHour( QTime::currentTime ().hour() ); 1202 setStartHour( QTime::currentTime ().hour() );
1197 // qApp->processEvents(); 1203 // qApp->processEvents();
1198 } 1204 }
1199 qApp->processEvents(); 1205 qApp->processEvents();
1200 //qDebug("qApp->processEvents(); END "); 1206 //qDebug("qApp->processEvents(); END ");
1201 globalFlagBlockAgenda = 0; 1207 globalFlagBlockAgenda = 0;
1202 1208
1203 // mAgenda->hideUnused(); 1209 // mAgenda->hideUnused();
1204 //mAllDayAgenda->hideUnused(); 1210 //mAllDayAgenda->hideUnused();
1205 mAllDayAgenda->drawContentsToPainter(); 1211 mAllDayAgenda->drawContentsToPainter();
1206 mAgenda->drawContentsToPainter(); 1212 mAgenda->drawContentsToPainter();
1207 repaintAgenda(); 1213 repaintAgenda();
1208 // mAgenda->finishUpdate(); 1214 // mAgenda->finishUpdate();
1209 //mAllDayAgenda->finishUpdate(); 1215 //mAllDayAgenda->finishUpdate();
1210 1216
1211 // repaintAgenda(); 1217 // repaintAgenda();
1212 //qApp->processEvents(); 1218 //qApp->processEvents();
1213 // globalFlagBlockAgenda = 0; 1219 // globalFlagBlockAgenda = 0;
1214} 1220}
1215void KOAgendaView::repaintAgenda() 1221void KOAgendaView::repaintAgenda()
diff --git a/korganizer/koeventviewer.cpp b/korganizer/koeventviewer.cpp
index 2f0fa9e..36a2947 100644
--- a/korganizer/koeventviewer.cpp
+++ b/korganizer/koeventviewer.cpp
@@ -334,98 +334,103 @@ void KOEventViewer::appendTodo(Todo *event, int mode )
334 if ( mColorMode == 1 ) { 334 if ( mColorMode == 1 ) {
335 mText +="<font color=\"#00A000\">"; 335 mText +="<font color=\"#00A000\">";
336 } 336 }
337 if ( mColorMode == 2 ) { 337 if ( mColorMode == 2 ) {
338 mText +="<font color=\"#B00000\">"; 338 mText +="<font color=\"#B00000\">";
339 } 339 }
340 if ( mode == 1 ) { 340 if ( mode == 1 ) {
341 addTag("h2",i18n( "Local: " ) +event->summary()); 341 addTag("h2",i18n( "Local: " ) +event->summary());
342 } else { 342 } else {
343 addTag("h2",i18n( "Remote: " ) +event->summary()); 343 addTag("h2",i18n( "Remote: " ) +event->summary());
344 } 344 }
345 addTag("h3",i18n( "Last modified: " ) + KGlobal::locale()->formatDateTime(event->lastModified(),shortDate, true ) ); 345 addTag("h3",i18n( "Last modified: " ) + KGlobal::locale()->formatDateTime(event->lastModified(),shortDate, true ) );
346 if ( mColorMode ) 346 if ( mColorMode )
347 mText += "</font>"; 347 mText += "</font>";
348 } 348 }
349 mMailSubject += i18n( "Todo " )+ event->summary(); 349 mMailSubject += i18n( "Todo " )+ event->summary();
350 if (event->cancelled ()) { 350 if (event->cancelled ()) {
351 mText +="<font color=\"#B00000\">"; 351 mText +="<font color=\"#B00000\">";
352 addTag("i",i18n("This todo has been cancelled!")); 352 addTag("i",i18n("This todo has been cancelled!"));
353 mText.append("<br>"); 353 mText.append("<br>");
354 mText += "</font>"; 354 mText += "</font>";
355 mMailSubject += i18n("(cancelled)"); 355 mMailSubject += i18n("(cancelled)");
356 } 356 }
357 357
358 if (!event->location().isEmpty()) { 358 if (!event->location().isEmpty()) {
359 addTag("b",i18n("Location: ")); 359 addTag("b",i18n("Location: "));
360 mText.append(event->location()+"<br>"); 360 mText.append(event->location()+"<br>");
361 mMailSubject += i18n(" at ") + event->location(); 361 mMailSubject += i18n(" at ") + event->location();
362 } 362 }
363 if (event->hasStartDate()) { 363 if (event->hasStartDate()) {
364 mText.append(i18n("<p><b>Start on:</b> %1</p>").arg(event->dtStartStr(KOPrefs::instance()->mShortDateInViewer))); 364 mText.append(i18n("<p><b>Start on:</b> %1</p>").arg(event->dtStartStr(KOPrefs::instance()->mShortDateInViewer)));
365 } 365 }
366 if (event->hasDueDate()) { 366 if (event->hasDueDate()) {
367 mText.append(i18n("<p><b>Due on:</b> %1</p>").arg(event->dtDueStr(KOPrefs::instance()->mShortDateInViewer))); 367 mText.append(i18n("<p><b>Due on:</b> %1</p>").arg(event->dtDueStr(KOPrefs::instance()->mShortDateInViewer)));
368 mMailSubject += i18n(" - " )+event->dtDueStr( true ); 368 mMailSubject += i18n(" - " )+event->dtDueStr( true );
369 } 369 }
370 addTag("b",i18n("Access: ")); 370 addTag("b",i18n("Access: "));
371 mText.append(event->secrecyStr()+"<br>"); 371 mText.append(event->secrecyStr()+"<br>");
372 if (!event->description().isEmpty()) { 372 if (!event->description().isEmpty()) {
373 addTag("p",i18n("<b>Details: </b>")); 373 addTag("p",i18n("<b>Details: </b>"));
374 addTag("p",event->description()); 374 addTag("p",event->description());
375 } 375 }
376 376
377 formatCategories(event); 377 formatCategories(event);
378 378
379 mText.append(i18n("<p><b>Priority:</b> %2</p>") 379 mText.append(i18n("<p><b>Priority:</b> %2</p>")
380 .arg(QString::number(event->priority()))); 380 .arg(QString::number(event->priority())));
381 381
382 if ( event->percentComplete() == 100 && event->hasCompletedDate() ) {
383 mText.append(i18n("<p><i>Completed on %1</i></p>")
384 .arg( event->completedStr() ));
385 } else {
382 mText.append(i18n("<p><i>%1 % completed</i></p>") 386 mText.append(i18n("<p><i>%1 % completed</i></p>")
383 .arg(event->percentComplete())); 387 .arg(event->percentComplete()));
388 }
384 389
385 formatReadOnly(event); 390 formatReadOnly(event);
386 formatAttendees(event); 391 formatAttendees(event);
387 if ( event->relatedTo() ) { 392 if ( event->relatedTo() ) {
388 addTag("b",i18n("Parent todo: ")); 393 addTag("b",i18n("Parent todo: "));
389 mText.append(event->relatedTo()->summary()+" [" +QString::number(event->relatedTo()->priority()) + "/" + QString::number(((Todo*)event->relatedTo())->percentComplete())+"%] <br>"); 394 mText.append(event->relatedTo()->summary()+" [" +QString::number(event->relatedTo()->priority()) + "/" + QString::number(((Todo*)event->relatedTo())->percentComplete())+"%] <br>");
390 } 395 }
391 QPtrList<Incidence> Relations = event->relations(); 396 QPtrList<Incidence> Relations = event->relations();
392 Incidence *to; 397 Incidence *to;
393 if ( Relations.first() ) 398 if ( Relations.first() )
394 addTag("b",i18n("Sub todos:<br>")); 399 addTag("b",i18n("Sub todos:<br>"));
395 for (to=Relations.first();to;to=Relations.next()) { 400 for (to=Relations.first();to;to=Relations.next()) {
396 mText.append( to->summary()+" [" +QString::number(to->priority()) + "/" + QString::number(((Todo*)to)->percentComplete())+"%]<br>"); 401 mText.append( to->summary()+" [" +QString::number(to->priority()) + "/" + QString::number(((Todo*)to)->percentComplete())+"%]<br>");
397 402
398 } 403 }
399 setText(mText); 404 setText(mText);
400} 405}
401 406
402void KOEventViewer::formatCategories(Incidence *event) 407void KOEventViewer::formatCategories(Incidence *event)
403{ 408{
404 if (!event->categoriesStr().isEmpty()) { 409 if (!event->categoriesStr().isEmpty()) {
405 if (event->categories().count() == 1) { 410 if (event->categories().count() == 1) {
406 addTag("h3",i18n("Category")); 411 addTag("h3",i18n("Category"));
407 } else { 412 } else {
408 addTag("h3",i18n("Categories")); 413 addTag("h3",i18n("Categories"));
409 } 414 }
410 addTag("p",event->categoriesStr()); 415 addTag("p",event->categoriesStr());
411 } 416 }
412} 417}
413void KOEventViewer::formatAttendees(Incidence *event) 418void KOEventViewer::formatAttendees(Incidence *event)
414{ 419{
415 QPtrList<Attendee> attendees = event->attendees(); 420 QPtrList<Attendee> attendees = event->attendees();
416 if (attendees.count()) { 421 if (attendees.count()) {
417 422
418 423
419 QString iconPath = KGlobal::iconLoader()->iconPath("mailappt",KIcon::Small); 424 QString iconPath = KGlobal::iconLoader()->iconPath("mailappt",KIcon::Small);
420 QString NOiconPath = KGlobal::iconLoader()->iconPath("nomailappt",KIcon::Small); 425 QString NOiconPath = KGlobal::iconLoader()->iconPath("nomailappt",KIcon::Small);
421 addTag("h3",i18n("Organizer")); 426 addTag("h3",i18n("Organizer"));
422 mText.append("<ul><li>"); 427 mText.append("<ul><li>");
423#ifndef KORG_NOKABC 428#ifndef KORG_NOKABC
424 429
425#ifdef DESKTOP_VERSION 430#ifdef DESKTOP_VERSION
426 KABC::AddressBook *add_book = KABC::StdAddressBook::self(); 431 KABC::AddressBook *add_book = KABC::StdAddressBook::self();
427 KABC::Addressee::List addressList; 432 KABC::Addressee::List addressList;
428 addressList = add_book->findByEmail(event->organizer()); 433 addressList = add_book->findByEmail(event->organizer());
429 KABC::Addressee o = addressList.first(); 434 KABC::Addressee o = addressList.first();
430 if (!o.isEmpty() && addressList.size()<2) { 435 if (!o.isEmpty() && addressList.size()<2) {
431 mText += "<a href=\"uid:" + o.uid() + "\">"; 436 mText += "<a href=\"uid:" + o.uid() + "\">";
diff --git a/korganizer/koeventviewerdialog.cpp b/korganizer/koeventviewerdialog.cpp
index 3979ed2..f6f7258 100644
--- a/korganizer/koeventviewerdialog.cpp
+++ b/korganizer/koeventviewerdialog.cpp
@@ -176,84 +176,85 @@ void KOEventViewerDialog::setJournal(Journal *j)
176 findButton( User1 )->setText( i18n("Agenda")); 176 findButton( User1 )->setText( i18n("Agenda"));
177 } 177 }
178} 178}
179 179
180void KOEventViewerDialog::addText(QString text) 180void KOEventViewerDialog::addText(QString text)
181{ 181{
182 mEventViewer->addText(text); 182 mEventViewer->addText(text);
183 findButton( Close )->setFocus(); 183 findButton( Close )->setFocus();
184} 184}
185void KOEventViewerDialog::editIncidence() 185void KOEventViewerDialog::editIncidence()
186{ 186{
187 if ( mSyncMode ) { 187 if ( mSyncMode ) {
188 mSyncResult = 2; 188 mSyncResult = 2;
189 accept(); 189 accept();
190 return; 190 return;
191 } 191 }
192 if ( mIncidence ){ 192 if ( mIncidence ){
193#ifndef DESKTOP_VERSION 193#ifndef DESKTOP_VERSION
194 hide(); 194 hide();
195#endif 195#endif
196 emit editIncidence( mIncidence ); 196 emit editIncidence( mIncidence );
197 } 197 }
198} 198}
199void KOEventViewerDialog::showIncidence() 199void KOEventViewerDialog::showIncidence()
200{ 200{
201 201
202 if ( mSyncMode ) { 202 if ( mSyncMode ) {
203 mSyncResult = 1; 203 mSyncResult = 1;
204 accept(); 204 accept();
205 return; 205 return;
206 } 206 }
207 207
208 if ( mIncidence ){ 208 if ( mIncidence ){
209#ifndef DESKTOP_VERSION 209#ifndef DESKTOP_VERSION
210 hide(); 210 hide();
211#endif 211#endif
212 QDate date; 212 QDate date;
213 if ( mIncidence->type() == "Todo" ) { 213 if ( mIncidence->type() == "Todo" ) {
214 /* 214 /*
215 if ( ((Todo*)mIncidence)->hasDueDate() ) 215 if ( ((Todo*)mIncidence)->hasDueDate() )
216 date = ((Todo*)mIncidence)->dtDue().date(); 216 date = ((Todo*)mIncidence)->dtDue().date();
217 else { 217 else {
218 globalFlagBlockAgenda = 2; 218 globalFlagBlockAgenda = 2;
219 emit showAgendaView( false ); 219 emit showAgendaView( false );
220 return; 220 return;
221 } 221 }
222 */ 222 */
223 ((Todo*)mIncidence)->setCompleted( true ); 223 ((Todo*)mIncidence)->setCompleted( true );
224 ((Todo*)mIncidence)->setCompleted(QDateTime::currentDateTime() );
224 hide(); 225 hide();
225 emit todoCompleted(((Todo*)mIncidence)); 226 emit todoCompleted(((Todo*)mIncidence));
226 return; 227 return;
227 228
228 } else 229 } else
229 date = mIncidence->dtStart().date(); 230 date = mIncidence->dtStart().date();
230 globalFlagBlockAgenda = 1; 231 globalFlagBlockAgenda = 1;
231 emit showAgendaView( false ); 232 emit showAgendaView( false );
232 globalFlagBlockAgenda = 2; 233 globalFlagBlockAgenda = 2;
233 emit jumpToTime( date ); 234 emit jumpToTime( date );
234 } 235 }
235} 236}
236void KOEventViewerDialog::keyPressEvent ( QKeyEvent * e ) 237void KOEventViewerDialog::keyPressEvent ( QKeyEvent * e )
237{ 238{
238 switch ( e->key() ) { 239 switch ( e->key() ) {
239 240
240 case Qt::Key_A : 241 case Qt::Key_A :
241 case Qt::Key_L : 242 case Qt::Key_L :
242 showIncidence(); 243 showIncidence();
243 break; 244 break;
244 case Qt::Key_E : 245 case Qt::Key_E :
245 case Qt::Key_R : 246 case Qt::Key_R :
246 editIncidence(); 247 editIncidence();
247 break; 248 break;
248 case Qt::Key_C: 249 case Qt::Key_C:
249 case Qt::Key_Escape: 250 case Qt::Key_Escape:
250 close(); 251 close();
251 break; 252 break;
252 case Qt::Key_I: 253 case Qt::Key_I:
253 accept(); 254 accept();
254 break; 255 break;
255 default: 256 default:
256 break; 257 break;
257 } 258 }
258 259
259} 260}