summaryrefslogtreecommitdiffabout
authorzautrix <zautrix>2004-12-13 12:35:00 (UTC)
committer zautrix <zautrix>2004-12-13 12:35:00 (UTC)
commit7ac6c21e832b7d16bd0888d0b66252b6e152005a (patch) (unidiff)
treec7610e0e25020f19af82ac6257c2debab2638316
parent17b25691f0332e648dd1d800e89ccf4e1da8955d (diff)
downloadkdepimpi-7ac6c21e832b7d16bd0888d0b66252b6e152005a.zip
kdepimpi-7ac6c21e832b7d16bd0888d0b66252b6e152005a.tar.gz
kdepimpi-7ac6c21e832b7d16bd0888d0b66252b6e152005a.tar.bz2
many bugfixes
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--bin/kdepim/WhatsNew.txt10
-rw-r--r--kaddressbook/kabcore.cpp7
-rw-r--r--kaddressbook/viewmanager.cpp11
-rw-r--r--kmicromail/libmailwrapper/settings.cpp2
-rw-r--r--kmicromail/opiemail.cpp27
-rw-r--r--kmicromail/opiemail.h2
-rw-r--r--kmicromail/viewmail.cpp5
-rw-r--r--kmicromail/viewmail.h1
-rw-r--r--korganizer/calendarview.cpp24
-rw-r--r--qtcompat/qinputdialog.cpp7
10 files changed, 78 insertions, 18 deletions
diff --git a/bin/kdepim/WhatsNew.txt b/bin/kdepim/WhatsNew.txt
index 46d59a3..ec75fad 100644
--- a/bin/kdepim/WhatsNew.txt
+++ b/bin/kdepim/WhatsNew.txt
@@ -12,4 +12,14 @@ event/todo/journal you have deleted.
12A journal is deleted, if you clear all the text of the journal. 12A journal is deleted, if you clear all the text of the journal.
13 13
14Fixed the bug of the editor dialogs in KO/Pi of version 1.9.14.
15
16KA/Pi starting in 480x640 resolution:
17Hide the filter action in toolbar
18and added icons for undo/delete/redo in toolbar.
19
20Change in OM/Pi ViewMail dialog:
21When clicking on the "delete" icon the mail is deleted after confirmation as usual. But the edit dialog is not closed as before, now the next mail in the folder is shown automatically (if there is any).
22
23Fixed a crash when deleting mail-accounts in OM/Pi.
14 24
15 25
diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp
index b7edccd..f6bdda4 100644
--- a/kaddressbook/kabcore.cpp
+++ b/kaddressbook/kabcore.cpp
@@ -788,4 +788,5 @@ void KABCore::resizeEvent(QResizeEvent* e )
788 if ( !mMiniSplitter ) 788 if ( !mMiniSplitter )
789 return; 789 return;
790 //qDebug("KABCore::resizeEvent(QResizeEvent* e ) ");
790 if ( QApplication::desktop()->width() >= 480 ) { 791 if ( QApplication::desktop()->width() >= 480 ) {
791 if (QApplication::desktop()->width() == 640 ) { // e.g. 640x480 792 if (QApplication::desktop()->width() == 640 ) { // e.g. 640x480
@@ -2193,9 +2194,11 @@ void KABCore::addActionsManually()
2193 mActionSave->plug( tb ); 2194 mActionSave->plug( tb );
2194 mViewManager->getFilterAction()->plug ( tb); 2195 mViewManager->getFilterAction()->plug ( tb);
2195 if (KGlobal::getDesktopSize() == KGlobal::Desktop ) { 2196 //LR hide filteraction on started in 480x640
2197 if (QApplication::desktop()->width() == 480 ) {
2198 mViewManager->getFilterAction()->setComboWidth( 0 );
2199 }
2196 mActionUndo->plug( tb ); 2200 mActionUndo->plug( tb );
2197 mActionDelete->plug( tb ); 2201 mActionDelete->plug( tb );
2198 mActionRedo->plug( tb ); 2202 mActionRedo->plug( tb );
2199 }
2200 } else { 2203 } else {
2201 mActionSave->plug( tb ); 2204 mActionSave->plug( tb );
diff --git a/kaddressbook/viewmanager.cpp b/kaddressbook/viewmanager.cpp
index 0d91c12..33bef5a 100644
--- a/kaddressbook/viewmanager.cpp
+++ b/kaddressbook/viewmanager.cpp
@@ -61,4 +61,5 @@ $Id$
61 61
62#include <qlayout.h> 62#include <qlayout.h>
63#include <qapplication.h>
63#include <qwidgetstack.h> 64#include <qwidgetstack.h>
64 65
@@ -107,5 +108,8 @@ void ViewManager::restoreSettings()
107 mActionSelectFilter->setItems( filterNames() ); 108 mActionSelectFilter->setItems( filterNames() );
108 mActionSelectFilter->setCurrentItem( KABPrefs::instance()->mCurrentFilter ); 109 mActionSelectFilter->setCurrentItem( KABPrefs::instance()->mCurrentFilter );
109 mActionSelectFilter->setComboWidth( 150 ); 110 int cw = 150;
111 if (QApplication::desktop()->width() == 480 )
112 cw = 0;
113 mActionSelectFilter->setComboWidth( cw );
110 // Tell the views to reread their config, since they may have 114 // Tell the views to reread their config, since they may have
111 // been modified by global settings 115 // been modified by global settings
@@ -598,5 +602,8 @@ void ViewManager::configureFilters()
598 mActionSelectFilter->setCurrentItem( pos ); 602 mActionSelectFilter->setCurrentItem( pos );
599 setActiveFilter( pos ); 603 setActiveFilter( pos );
600 mActionSelectFilter->setComboWidth( 150 ); 604 int cw = 150;
605 if (QApplication::desktop()->width() == 480 )
606 cw = 0;
607 mActionSelectFilter->setComboWidth( cw );
601} 608}
602 609
diff --git a/kmicromail/libmailwrapper/settings.cpp b/kmicromail/libmailwrapper/settings.cpp
index 04afe7c..19093b1 100644
--- a/kmicromail/libmailwrapper/settings.cpp
+++ b/kmicromail/libmailwrapper/settings.cpp
@@ -51,6 +51,6 @@ void Settings::addAccount( Account *account )
51void Settings::delAccount( Account *account ) 51void Settings::delAccount( Account *account )
52{ 52{
53 accounts.remove( account );
54 account->remove(); 53 account->remove();
54 accounts.remove( account );
55} 55}
56 56
diff --git a/kmicromail/opiemail.cpp b/kmicromail/opiemail.cpp
index ec192ea..915b3e8 100644
--- a/kmicromail/opiemail.cpp
+++ b/kmicromail/opiemail.cpp
@@ -300,8 +300,33 @@ void OpieMail::replyMail()
300 300
301} 301}
302void OpieMail::closeViewMail(ViewMail * vm)
303{
304 vm->hide();
305}
306void OpieMail::deleteAndDisplayNextMail(ViewMail * vm)
307{
308 QListViewItem*item = mailView->currentItem();
309 if (!item ) {
310 closeViewMail(vm);
311 return;
312 }
313 RecMailP mail = ((MailListViewItem*)item)->data();
314 mail->Wrapper()->deleteMail( mail );
315 item = item->itemBelow();
316 if (!item ) {
317 closeViewMail(vm);
318 return;
319 }
320 mailView->setCurrentItem(item);
321 mail = ((MailListViewItem*)item)->data();
322 RecBodyP body = folderView->fetchBody(mail);
323 vm->setBody( body );
324 vm->setMail( mail );
325}
302void OpieMail::displayNextMail(ViewMail * vm) 326void OpieMail::displayNextMail(ViewMail * vm)
303{ 327{
304 QListViewItem*item = mailView->currentItem(); 328 QListViewItem*item = mailView->currentItem();
305 if (!item) return; 329 if (!item) return;
330 ( (MailListViewItem*)item )->setPixmap( 0, QPixmap() );
306 item = item->itemBelow(); 331 item = item->itemBelow();
307 if (!item) { 332 if (!item) {
@@ -330,4 +355,6 @@ void OpieMail::displayMail()
330#endif 355#endif
331 connect( &readMail,SIGNAL( showNextMail(ViewMail *) ), this, SLOT( displayNextMail(ViewMail *) ) ); 356 connect( &readMail,SIGNAL( showNextMail(ViewMail *) ), this, SLOT( displayNextMail(ViewMail *) ) );
357 connect( &readMail,SIGNAL( deleteAndDisplayNextMail(ViewMail *) ), this, SLOT(deleteAndDisplayNextMail(ViewMail *) ) );
358
332 readMail.exec(); 359 readMail.exec();
333 360
diff --git a/kmicromail/opiemail.h b/kmicromail/opiemail.h
index 30968a7..a81a34c 100644
--- a/kmicromail/opiemail.h
+++ b/kmicromail/opiemail.h
@@ -27,4 +27,5 @@ public slots:
27 virtual void message(const QCString &msg, const QByteArray &data); 27 virtual void message(const QCString &msg, const QByteArray &data);
28protected slots: 28protected slots:
29 virtual void deleteAndDisplayNextMail(ViewMail * vm);
29 virtual void displayNextMail(ViewMail * vm); 30 virtual void displayNextMail(ViewMail * vm);
30 virtual void slotSendQueued(); 31 virtual void slotSendQueued();
@@ -48,4 +49,5 @@ protected slots:
48 49
49private: 50private:
51 void closeViewMail(ViewMail * vm);
50 QString mPendingEmail; 52 QString mPendingEmail;
51 QString mPendingName; 53 QString mPendingName;
diff --git a/kmicromail/viewmail.cpp b/kmicromail/viewmail.cpp
index 60c764c..6d88cad 100644
--- a/kmicromail/viewmail.cpp
+++ b/kmicromail/viewmail.cpp
@@ -507,6 +507,7 @@ void ViewMail::slotDeleteMail( )
507 if ( QMessageBox::warning(this, i18n("Delete Mail"), QString( i18n("<p>Do you really want to delete this mail? <br><br>" ) + m_mail[0] + " - " + m_mail[1] ) , QMessageBox::Yes, QMessageBox::No ) == QMessageBox::Yes ) 507 if ( QMessageBox::warning(this, i18n("Delete Mail"), QString( i18n("<p>Do you really want to delete this mail? <br><br>" ) + m_mail[0] + " - " + m_mail[1] ) , QMessageBox::Yes, QMessageBox::No ) == QMessageBox::Yes )
508 { 508 {
509 m_recMail->Wrapper()->deleteMail( m_recMail ); 509 emit deleteAndDisplayNextMail( this);
510 hide(); 510 //m_recMail->Wrapper()->deleteMail( m_recMail );
511 //hide();
511 deleted = true; 512 deleted = true;
512 } 513 }
diff --git a/kmicromail/viewmail.h b/kmicromail/viewmail.h
index c2c2ce3..d85b8b2 100644
--- a/kmicromail/viewmail.h
+++ b/kmicromail/viewmail.h
@@ -45,4 +45,5 @@ public:
45 signals: 45 signals:
46 void showNextMail(ViewMail*); 46 void showNextMail(ViewMail*);
47 void deleteAndDisplayNextMail(ViewMail *);
47protected: 48protected:
48 QString deHtml(const QString &string); 49 QString deHtml(const QString &string);
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp
index 15c5dd9..a46cd87 100644
--- a/korganizer/calendarview.cpp
+++ b/korganizer/calendarview.cpp
@@ -2474,6 +2474,7 @@ void CalendarView::showEventEditor()
2474 mEventEditor->show(); 2474 mEventEditor->show();
2475#else 2475#else
2476 if ( mEventEditor->width() != QApplication::desktop()->width() ) { 2476 if ( mEventEditor->width() < QApplication::desktop()->width() -60 || mEventEditor->width() > QApplication::desktop()->width() ) {
2477 qDebug("CalendarView: recreate mEventEditor "); 2477 topLevelWidget()->setCaption( i18n("Recreating edit dialog. Please wait...") );
2478 qDebug("CalendarView: recreate mEventEditor %d %d", mEventEditor->width(), QApplication::desktop()->width() );
2478 delete mEventEditor; 2479 delete mEventEditor;
2479 mEventEditor = mDialogManager->getEventEditor(); 2480 mEventEditor = mDialogManager->getEventEditor();
@@ -2487,6 +2488,7 @@ void CalendarView::showTodoEditor()
2487 mTodoEditor->show(); 2488 mTodoEditor->show();
2488#else 2489#else
2489 if ( mTodoEditor->width() != QApplication::desktop()->width() ) { 2490 if ( mTodoEditor->width() < QApplication::desktop()->width() -60|| mTodoEditor->width() > QApplication::desktop()->width() ) {
2490 qDebug("CalendarView: recreate mTodoEditor "); 2491 topLevelWidget()->setCaption( i18n("Recreating edit dialog. Please wait...") );
2492 qDebug("CalendarView: recreate mTodoEditor %d %d ", mTodoEditor->width() ,QApplication::desktop()->width() );
2491 delete mTodoEditor; 2493 delete mTodoEditor;
2492 mTodoEditor = mDialogManager->getTodoEditor(); 2494 mTodoEditor = mDialogManager->getTodoEditor();
@@ -2543,6 +2545,6 @@ void CalendarView::cloneIncidence(Incidence * orgInc )
2543 if ( newInc->type() == "Todo" ) { 2545 if ( newInc->type() == "Todo" ) {
2544 Todo* t = (Todo*) newInc; 2546 Todo* t = (Todo*) newInc;
2545 mTodoEditor->editTodo( t );
2546 showTodoEditor(); 2547 showTodoEditor();
2548 mTodoEditor->editTodo( t );
2547 if ( mTodoEditor->exec() ) { 2549 if ( mTodoEditor->exec() ) {
2548 mCalendar->addTodo( t ); 2550 mCalendar->addTodo( t );
@@ -2554,6 +2556,6 @@ void CalendarView::cloneIncidence(Incidence * orgInc )
2554 else { 2556 else {
2555 Event* e = (Event*) newInc; 2557 Event* e = (Event*) newInc;
2556 mEventEditor->editEvent( e );
2557 showEventEditor(); 2558 showEventEditor();
2559 mEventEditor->editEvent( e );
2558 if ( mEventEditor->exec() ) { 2560 if ( mEventEditor->exec() ) {
2559 mCalendar->addEvent( e ); 2561 mCalendar->addEvent( e );
@@ -2607,4 +2609,5 @@ void CalendarView::newEvent(QDateTime fromHint, QDateTime toHint, bool allDay)
2607{ 2609{
2608 2610
2611 showEventEditor();
2609 mEventEditor->newEvent(fromHint,toHint,allDay); 2612 mEventEditor->newEvent(fromHint,toHint,allDay);
2610 if ( mFilterView->filtersEnabled() ) { 2613 if ( mFilterView->filtersEnabled() ) {
@@ -2616,5 +2619,4 @@ void CalendarView::newEvent(QDateTime fromHint, QDateTime toHint, bool allDay)
2616 mEventEditor->setSecrecy( filter->getSecrecy() ); 2619 mEventEditor->setSecrecy( filter->getSecrecy() );
2617 } 2620 }
2618 showEventEditor();
2619} 2621}
2620void CalendarView::todoAdded(Todo * t) 2622void CalendarView::todoAdded(Todo * t)
@@ -2645,4 +2647,5 @@ void CalendarView::newTodo()
2645{ 2647{
2646 2648
2649 showTodoEditor();
2647 mTodoEditor->newTodo(QDateTime::currentDateTime().addDays(7),0,true); 2650 mTodoEditor->newTodo(QDateTime::currentDateTime().addDays(7),0,true);
2648 if ( mFilterView->filtersEnabled() ) { 2651 if ( mFilterView->filtersEnabled() ) {
@@ -2654,5 +2657,4 @@ void CalendarView::newTodo()
2654 mTodoEditor->setSecrecy( filter->getSecrecy() ); 2657 mTodoEditor->setSecrecy( filter->getSecrecy() );
2655 } 2658 }
2656 showTodoEditor();
2657} 2659}
2658 2660
@@ -2666,6 +2668,6 @@ void CalendarView::newSubTodo(Todo *parentEvent)
2666{ 2668{
2667 2669
2668 mTodoEditor->newTodo(QDateTime::currentDateTime().addDays(7),parentEvent,true);
2669 showTodoEditor(); 2670 showTodoEditor();
2671 mTodoEditor->newTodo(QDateTime::currentDateTime().addDays(7),parentEvent,true);
2670} 2672}
2671 2673
@@ -2688,6 +2690,6 @@ void CalendarView::editEvent( Event *event )
2688 return; 2690 return;
2689 } 2691 }
2690 mEventEditor->editEvent( event , mFlagEditDescription);
2691 showEventEditor(); 2692 showEventEditor();
2693 mEventEditor->editEvent( event , mFlagEditDescription);
2692} 2694}
2693void CalendarView::editJournal( Journal *jour ) 2695void CalendarView::editJournal( Journal *jour )
@@ -2706,6 +2708,6 @@ void CalendarView::editTodo( Todo *todo )
2706 return; 2708 return;
2707 } 2709 }
2708 mTodoEditor->editTodo( todo ,mFlagEditDescription);
2709 showTodoEditor(); 2710 showTodoEditor();
2711 mTodoEditor->editTodo( todo ,mFlagEditDescription);
2710 2712
2711} 2713}
diff --git a/qtcompat/qinputdialog.cpp b/qtcompat/qinputdialog.cpp
index 770b281..64c581e 100644
--- a/qtcompat/qinputdialog.cpp
+++ b/qtcompat/qinputdialog.cpp
@@ -36,4 +36,6 @@
36**********************************************************************/ 36**********************************************************************/
37 37
38//Edited Lutz Rogowski 2004-12-13
39
38#include "qinputdialog.h" 40#include "qinputdialog.h"
39 41
@@ -454,4 +456,9 @@ QString QInputDialog::getItem( const QString &caption, const QString &label, con
454 bool ok_ = FALSE; 456 bool ok_ = FALSE;
455 QString result; 457 QString result;
458 int fixWid = 320;
459 if ( QApplication::desktop()->width() <= 240 ) {
460 fixWid = 230;
461 }
462 dlg->setFixedWidth( fixWid);
456 ok_ = dlg->exec() == QDialog::Accepted; 463 ok_ = dlg->exec() == QDialog::Accepted;
457 if ( ok ) 464 if ( ok )