summaryrefslogtreecommitdiffabout
authorzautrix <zautrix>2005-01-24 18:27:06 (UTC)
committer zautrix <zautrix>2005-01-24 18:27:06 (UTC)
commitbb33b559609356149ae51cb50c081b3e82aecafb (patch) (unidiff)
tree4878aa5887bf1c539845ce9c4e5470eea94d41cc
parent77f93c632b66b5c8d92e4c63330362272ca1fc40 (diff)
downloadkdepimpi-bb33b559609356149ae51cb50c081b3e82aecafb.zip
kdepimpi-bb33b559609356149ae51cb50c081b3e82aecafb.tar.gz
kdepimpi-bb33b559609356149ae51cb50c081b3e82aecafb.tar.bz2
pixmap update fix
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--kmicromail/mailistviewitem.cpp5
-rw-r--r--kmicromail/opiemail.cpp2
-rw-r--r--kmicromail/viewmail.h4
-rw-r--r--kmicromail/viewmailbase.cpp6
4 files changed, 9 insertions, 8 deletions
diff --git a/kmicromail/mailistviewitem.cpp b/kmicromail/mailistviewitem.cpp
index 137c482..5119744 100644
--- a/kmicromail/mailistviewitem.cpp
+++ b/kmicromail/mailistviewitem.cpp
@@ -14,14 +14,17 @@ MailListViewItem::MailListViewItem(QListView * parent, MailListViewItem * item )
14void MailListViewItem::showEntry() 14void MailListViewItem::showEntry()
15{ 15{
16 if ( mail_data->getFlags().testBit( FLAG_ANSWERED ) == true) { 16 if ( mail_data->getFlags().testBit( FLAG_ANSWERED ) == true) {
17 setPixmap( 0, SmallIcon ( "kmmsgreplied") ); 17 setPixmap( 0, SmallIcon ( "kmmsgreplied") );
18 mKeyMap.insert(0, "r" );
18 } else if ( mail_data->getFlags().testBit( FLAG_SEEN ) == true ) { 19 } else if ( mail_data->getFlags().testBit( FLAG_SEEN ) == true ) {
19 /* I think it looks nicer if there are not such a log of icons but only on mails 20 /* I think it looks nicer if there are not such a log of icons but only on mails
20 replied or new - Alwin*/ 21 replied or new - Alwin*/
21 //setPixmap( 0,SmallIcon ("kmmsgunseen") ); 22 //setPixmap( 0,SmallIcon ("kmmsgunseen") );
23 mKeyMap.insert(0, "s" );
22 } else { 24 } else {
23 setPixmap( 0,SmallIcon ( "kmmsgnew") ); 25 setPixmap( 0,SmallIcon ( "kmmsgnew") );
26 mKeyMap.insert(0, "u" );
24 } 27 }
25 QString fsize = mail_data->MsgsizeString(); 28 QString fsize = mail_data->MsgsizeString();
26 // 1.23 29 // 1.23
27 // 11.23 30 // 11.23
@@ -66,9 +69,9 @@ void MailListViewItem::setSortKey(int column,const QString &key)
66} 69}
67QString MailListViewItem::key(int column, bool) const 70QString MailListViewItem::key(int column, bool) const
68{ 71{
69 // to make is fast, we use here special cases 72 // to make is fast, we use here special cases
70 if ( column == 3 || column == 4 ) { 73 if ( column == 3 || column == 4 || column == 0) {
71 return *mKeyMap.find(column); 74 return *mKeyMap.find(column);
72 } 75 }
73 if ( column == 1 ) { 76 if ( column == 1 ) {
74 if ( text(1).left(4).lower() == "re: " ) 77 if ( text(1).left(4).lower() == "re: " )
diff --git a/kmicromail/opiemail.cpp b/kmicromail/opiemail.cpp
index 760e3b0..68f0eb3 100644
--- a/kmicromail/opiemail.cpp
+++ b/kmicromail/opiemail.cpp
@@ -414,8 +414,10 @@ void OpieMail::displayMail()
414 folderView->refreshCurrent(); 414 folderView->refreshCurrent();
415 } 415 }
416 else 416 else
417 { 417 {
418 QListViewItem*item = mailView->currentItem();
419 if (item)
418 ( (MailListViewItem*)item )->setPixmap( 0, QPixmap() ); 420 ( (MailListViewItem*)item )->setPixmap( 0, QPixmap() );
419 } 421 }
420} 422}
421void OpieMail::slotGetAllMail() 423void OpieMail::slotGetAllMail()
diff --git a/kmicromail/viewmail.h b/kmicromail/viewmail.h
index 561989e..fc5edcf 100644
--- a/kmicromail/viewmail.h
+++ b/kmicromail/viewmail.h
@@ -4,11 +4,13 @@
4#include "viewmailbase.h" 4#include "viewmailbase.h"
5#include <libmailwrapper/mailtypes.h> 5#include <libmailwrapper/mailtypes.h>
6 6
7#include <qdialog.h> 7#include <qdialog.h>
8#include <qapplication.h>
8 9
9#include <qlistview.h> 10#include <qlistview.h>
10#include <qmap.h> 11#include <qmap.h>
12#include <klocale.h>
11#include <qstringlist.h> 13#include <qstringlist.h>
12#include <qvaluelist.h> 14#include <qvaluelist.h>
13 15
14//namespace Opie { namespace MM { class OImageScrollView; } } 16//namespace Opie { namespace MM { class OImageScrollView; } }
@@ -51,9 +53,9 @@ protected:
51 AttachItem* searchParent(const QValueList<int>&path); 53 AttachItem* searchParent(const QValueList<int>&path);
52 AttachItem* lastChild(AttachItem*parent); 54 AttachItem* lastChild(AttachItem*parent);
53 55
54protected slots: 56protected slots:
55 void slotNextMail() { emit showNextMail(this); }; 57 void slotNextMail() { setCaption(i18n("Displaying next mail...please wait!")); qApp->processEvents();emit showNextMail(this); };
56 void slotReply(); 58 void slotReply();
57 void slotForward(); 59 void slotForward();
58 void setText(); 60 void setText();
59 void slotItemClicked( QListViewItem * item , const QPoint & point, int c ); 61 void slotItemClicked( QListViewItem * item , const QPoint & point, int c );
diff --git a/kmicromail/viewmailbase.cpp b/kmicromail/viewmailbase.cpp
index 9365c23..3a41ba0 100644
--- a/kmicromail/viewmailbase.cpp
+++ b/kmicromail/viewmailbase.cpp
@@ -48,27 +48,21 @@ ViewMailBase::ViewMailBase(QWidget *parent, const char *name, WFlags fl)
48 attachbutton->addTo(toolbar); 48 attachbutton->addTo(toolbar);
49 attachbutton->addTo(mailmenu); 49 attachbutton->addTo(mailmenu);
50 connect(attachbutton, SIGNAL(toggled(bool)), SLOT(slotChangeAttachview(bool))); 50 connect(attachbutton, SIGNAL(toggled(bool)), SLOT(slotChangeAttachview(bool)));
51 51
52
53 showHtml = new QAction( i18n( "Show Html" ), SmallIcon( "html" ), 0, 0, this, 0, true ); 52 showHtml = new QAction( i18n( "Show Html" ), SmallIcon( "html" ), 0, 0, this, 0, true );
54 showHtml->addTo( toolbar ); 53 showHtml->addTo( toolbar );
55 showHtml->addTo( mailmenu ); 54 showHtml->addTo( mailmenu );
56 55
57 deleteMail = new QAction(i18n("Delete Mail"),SmallIcon("trash"), 0, 0, this); 56 deleteMail = new QAction(i18n("Delete Mail"),SmallIcon("trash"), 0, 0, this);
58 deleteMail->addTo(toolbar); 57 deleteMail->addTo(toolbar);
59 deleteMail->addTo(mailmenu); 58 deleteMail->addTo(mailmenu);
60 59
61
62
63 nextMail = new QAction(i18n("Show next mail"),SmallIcon("enter"), 0, 0, this); 60 nextMail = new QAction(i18n("Show next mail"),SmallIcon("enter"), 0, 0, this);
64 QLabel *spacer = new QLabel(toolbar); 61 QLabel *spacer = new QLabel(toolbar);
65 nextMail->addTo(toolbar); 62 nextMail->addTo(toolbar);
66 nextMail->addTo(mailmenu); 63 nextMail->addTo(mailmenu);
67 64
68
69
70
71 closeMail = new QAction(i18n("Close"),SmallIcon("exit"), 0, 0, this); 65 closeMail = new QAction(i18n("Close"),SmallIcon("exit"), 0, 0, this);
72 //QLabel *spacer = new QLabel(toolbar); 66 //QLabel *spacer = new QLabel(toolbar);
73 spacer->setBackgroundMode(QWidget::PaletteButton); 67 spacer->setBackgroundMode(QWidget::PaletteButton);
74 toolbar->setStretchableWidget(spacer); 68 toolbar->setStretchableWidget(spacer);