-rw-r--r-- | bin/kdepim/korganizer/germantranslation.txt | 5 | ||||
-rw-r--r-- | kmicromail/editaccounts.cpp | 12 | ||||
-rw-r--r-- | kmicromail/libmailwrapper/smtpwrapper.cpp | 21 | ||||
-rw-r--r-- | korganizer/kolistview.cpp | 41 | ||||
-rw-r--r-- | korganizer/kolistview.h | 2 |
5 files changed, 66 insertions, 15 deletions
diff --git a/bin/kdepim/korganizer/germantranslation.txt b/bin/kdepim/korganizer/germantranslation.txt index 246ab3d..2084d0d 100644 --- a/bin/kdepim/korganizer/germantranslation.txt +++ b/bin/kdepim/korganizer/germantranslation.txt | |||
@@ -1297,4 +1297,8 @@ | |||
1297 | { "Export","Exportiere" }, | 1297 | { "Export","Exportiere" }, |
1298 | { "Beam","Beame" }, | 1298 | { "Beam","Beame" }, |
1299 | { "Export selected","Exportiere Selektierte" }, | ||
1300 | { "As iCal (ics) file...","Als iCal (ics) Datei..." }, | ||
1301 | { "As vCal (vcs) file...","Als vCal (vcs) Datei..." }, | ||
1302 | { "Journal/Details...","Journale/Details..." }, | ||
1299 | { "","" }, | 1303 | { "","" }, |
1300 | { "","" }, | 1304 | { "","" }, |
@@ -1304,3 +1308,2 @@ | |||
1304 | { "","" }, | 1308 | { "","" }, |
1305 | { "","" }, | 1309 | { "","" }, |
1306 | |||
diff --git a/kmicromail/editaccounts.cpp b/kmicromail/editaccounts.cpp index 49049f6..2c0f2d8 100644 --- a/kmicromail/editaccounts.cpp +++ b/kmicromail/editaccounts.cpp | |||
@@ -348,4 +348,5 @@ void IMAPconfig::slotConnectionToggle( int index ) | |||
348 | { | 348 | { |
349 | portLine->setText( IMAP_SSL_PORT ); | 349 | portLine->setText( IMAP_SSL_PORT ); |
350 | CommandEdit->hide(); | ||
350 | } | 351 | } |
351 | else if ( index == 3 ) | 352 | else if ( index == 3 ) |
@@ -357,4 +358,5 @@ void IMAPconfig::slotConnectionToggle( int index ) | |||
357 | { | 358 | { |
358 | portLine->setText( IMAP_PORT ); | 359 | portLine->setText( IMAP_PORT ); |
360 | CommandEdit->hide(); | ||
359 | } | 361 | } |
360 | } | 362 | } |
@@ -429,4 +431,5 @@ void POP3config::slotConnectionToggle( int index ) | |||
429 | { | 431 | { |
430 | portLine->setText( POP3_SSL_PORT ); | 432 | portLine->setText( POP3_SSL_PORT ); |
433 | CommandEdit->hide(); | ||
431 | } | 434 | } |
432 | else if ( index == 3 ) | 435 | else if ( index == 3 ) |
@@ -438,4 +441,5 @@ void POP3config::slotConnectionToggle( int index ) | |||
438 | { | 441 | { |
439 | portLine->setText( POP3_PORT ); | 442 | portLine->setText( POP3_PORT ); |
443 | CommandEdit->hide(); | ||
440 | } | 444 | } |
441 | } | 445 | } |
@@ -521,10 +525,11 @@ void SMTPconfig::chooseSig() | |||
521 | void SMTPconfig::slotConnectionToggle( int index ) | 525 | void SMTPconfig::slotConnectionToggle( int index ) |
522 | { | 526 | { |
523 | // 2 is ssl connection | 527 | // 3 is ssl connection |
524 | if ( index == 2 ) | 528 | if ( index == 3 ) |
525 | { | 529 | { |
526 | portLine->setText( SMTP_SSL_PORT ); | 530 | portLine->setText( SMTP_SSL_PORT ); |
531 | CommandEdit->hide(); | ||
527 | } | 532 | } |
528 | else if ( index == 3 ) | 533 | else if ( index == 4 ) |
529 | { | 534 | { |
530 | portLine->setText( SMTP_PORT ); | 535 | portLine->setText( SMTP_PORT ); |
@@ -534,4 +539,5 @@ void SMTPconfig::slotConnectionToggle( int index ) | |||
534 | { | 539 | { |
535 | portLine->setText( SMTP_PORT ); | 540 | portLine->setText( SMTP_PORT ); |
541 | CommandEdit->hide(); | ||
536 | } | 542 | } |
537 | } | 543 | } |
diff --git a/kmicromail/libmailwrapper/smtpwrapper.cpp b/kmicromail/libmailwrapper/smtpwrapper.cpp index 872a460..845c71c 100644 --- a/kmicromail/libmailwrapper/smtpwrapper.cpp +++ b/kmicromail/libmailwrapper/smtpwrapper.cpp | |||
@@ -245,5 +245,5 @@ void SMTPwrapper::connect_server() | |||
245 | } | 245 | } |
246 | } | 246 | } |
247 | if (try_tls) { | 247 | if (result && try_tls) { |
248 | qDebug("Smpt: Try tls "); | 248 | qDebug("Smpt: Try tls "); |
249 | err = start_smtp_tls(); | 249 | err = start_smtp_tls(); |
@@ -253,4 +253,6 @@ void SMTPwrapper::connect_server() | |||
253 | } else { | 253 | } else { |
254 | err = mailesmtp_ehlo(m_smtp); | 254 | err = mailesmtp_ehlo(m_smtp); |
255 | if ( err != MAILSMTP_NO_ERROR ) | ||
256 | result = 0; | ||
255 | } | 257 | } |
256 | } | 258 | } |
@@ -291,4 +293,8 @@ void SMTPwrapper::connect_server() | |||
291 | } | 293 | } |
292 | } | 294 | } |
295 | if ( result == 0 ) { | ||
296 | mailsmtp_free(m_smtp); | ||
297 | m_smtp = 0; | ||
298 | } | ||
293 | } | 299 | } |
294 | 300 | ||
@@ -347,5 +353,9 @@ bool SMTPwrapper::sendMail(const Opie::Core::OSmartPointer<Mail>&mail,bool later | |||
347 | delete sendProgress; | 353 | delete sendProgress; |
348 | sendProgress = 0; | 354 | sendProgress = 0; |
349 | mailmime_free( mimeMail ); | 355 | mailmime_free( mimeMail ); |
356 | if ( m_smtp ) { | ||
357 | mailsmtp_free(m_smtp); | ||
358 | m_smtp = 0; | ||
359 | } | ||
350 | } | 360 | } |
351 | return result; | 361 | return result; |
@@ -459,4 +469,5 @@ bool SMTPwrapper::flushOutbox() { | |||
459 | m_SmtpAccount->setPassword(oldPw); | 469 | m_SmtpAccount->setPassword(oldPw); |
460 | } | 470 | } |
471 | |||
461 | KConfig cfg( locateLocal("config", "kopiemailrc" ) ); | 472 | KConfig cfg( locateLocal("config", "kopiemailrc" ) ); |
462 | cfg.setGroup( "Status" ); | 473 | cfg.setGroup( "Status" ); |
@@ -468,5 +479,9 @@ bool SMTPwrapper::flushOutbox() { | |||
468 | sendProgress = 0; | 479 | sendProgress = 0; |
469 | wrap->deleteMails(mbox,mailsToRemove); | 480 | wrap->deleteMails(mbox,mailsToRemove); |
470 | delete wrap; | 481 | delete wrap; |
482 | if ( m_smtp ) { | ||
483 | mailsmtp_free(m_smtp); | ||
484 | m_smtp = 0; | ||
485 | } | ||
471 | return returnValue; | 486 | return returnValue; |
472 | } | 487 | } |
diff --git a/korganizer/kolistview.cpp b/korganizer/kolistview.cpp index 710a9f9..f235705 100644 --- a/korganizer/kolistview.cpp +++ b/korganizer/kolistview.cpp | |||
@@ -266,10 +266,12 @@ KOListView::KOListView(Calendar *calendar, QWidget *parent, | |||
266 | SLOT(deleteAll()),true); | 266 | SLOT(deleteAll()),true); |
267 | mPopupMenu->insertSeparator(); | 267 | mPopupMenu->insertSeparator(); |
268 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), | 268 | QPopupMenu * exportPO = new QPopupMenu ( this ); |
269 | i18n("Save selected to file..."),this, | 269 | mPopupMenu->insertItem( i18n("Export selected"), exportPO ); |
270 | SLOT(saveToFile()),true); | 270 | exportPO->insertItem( i18n("As iCal (ics) file..."),this, |
271 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), | 271 | SLOT(saveToFile())); |
272 | i18n("Save Journal/Description..."),this, | 272 | exportPO->insertItem( i18n("As vCal (vcs) file..."),this, |
273 | SLOT(saveDescriptionToFile()),true); | 273 | SLOT(saveToFileVCS())); |
274 | exportPO->insertItem( i18n("Journal/Details..."),this, | ||
275 | SLOT(saveDescriptionToFile())); | ||
274 | // mPopupMenu->insertSeparator(); | 276 | // mPopupMenu->insertSeparator(); |
275 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), | 277 | mPopupMenu->addAdditionalItem(QIconSet(QPixmap()), |
@@ -607,6 +609,14 @@ void KOListView::saveDescriptionToFile() | |||
607 | } | 609 | } |
608 | } | 610 | } |
611 | void KOListView::saveToFileVCS() | ||
612 | { | ||
613 | writeToFile( false ); | ||
614 | } | ||
609 | void KOListView::saveToFile() | 615 | void KOListView::saveToFile() |
610 | { | 616 | { |
617 | writeToFile( true ); | ||
618 | } | ||
619 | void KOListView::writeToFile( bool iCal ) | ||
620 | { | ||
611 | 621 | ||
612 | int icount = 0; | 622 | int icount = 0; |
@@ -623,4 +633,14 @@ void KOListView::saveToFile() | |||
623 | if ( icount ) { | 633 | if ( icount ) { |
624 | QString fn = KOPrefs::instance()->mLastSaveFile; | 634 | QString fn = KOPrefs::instance()->mLastSaveFile; |
635 | QString extension; | ||
636 | if ( iCal ) { | ||
637 | if ( fn.right( 4 ).lower() == ".vcs" ) { | ||
638 | fn = fn.left( fn.length() -3) + "ics"; | ||
639 | } | ||
640 | } else { | ||
641 | if ( fn.right( 4 ).lower() == ".ics" ) { | ||
642 | fn = fn.left( fn.length() -3) + "vcs"; | ||
643 | } | ||
644 | } | ||
625 | fn = KFileDialog::getSaveFileName( fn, i18n("Save filename"), this ); | 645 | fn = KFileDialog::getSaveFileName( fn, i18n("Save filename"), this ); |
626 | 646 | ||
@@ -648,6 +668,11 @@ void KOListView::saveToFile() | |||
648 | incidence = delSel.next(); | 668 | incidence = delSel.next(); |
649 | } | 669 | } |
650 | ICalFormat format; | 670 | if ( iCal ) { |
651 | format.save( &cal, fn ); | 671 | ICalFormat format; |
672 | format.save( &cal, fn ); | ||
673 | } else { | ||
674 | VCalFormat format; | ||
675 | format.save( &cal, fn ); | ||
676 | } | ||
652 | mes = i18n("KO/Pi:Saved %1").arg(fn ); | 677 | mes = i18n("KO/Pi:Saved %1").arg(fn ); |
653 | KOPrefs::instance()->mLastSaveFile = fn; | 678 | KOPrefs::instance()->mLastSaveFile = fn; |
diff --git a/korganizer/kolistview.h b/korganizer/kolistview.h index c86449d..0d9c525 100644 --- a/korganizer/kolistview.h +++ b/korganizer/kolistview.h | |||
@@ -273,4 +273,5 @@ class KOListView : public KOEventView | |||
273 | void deleteAll(); | 273 | void deleteAll(); |
274 | void saveToFile(); | 274 | void saveToFile(); |
275 | void saveToFileVCS(); | ||
275 | void saveDescriptionToFile(); | 276 | void saveDescriptionToFile(); |
276 | void beamSelected(); | 277 | void beamSelected(); |
@@ -289,4 +290,5 @@ class KOListView : public KOEventView | |||
289 | 290 | ||
290 | protected: | 291 | protected: |
292 | void writeToFile( bool iCal ); | ||
291 | void addEvents(QPtrList<Event> eventList); | 293 | void addEvents(QPtrList<Event> eventList); |
292 | void addIncidence(Incidence *); | 294 | void addIncidence(Incidence *); |