branches/KDE/3.5/kdepim/kmail

David Faure <[email protected]> Wed, 27 Sep 2006 11:12:18 +0000
Newsgroups gmane.comp.kde.devel.optimize
Message-ID <[email protected]>
SVN commit 588915 by dfaure:

SmallIcon can fall back to UserIcon if needed, but this means doing the lookup as a SmallIcon first, every time, which is slow.
This commit makes the "Find Messages" (Key_S) dialog pop up -much- faster in kmail (from 3s to 0, approximately ;).
I'll add a warning in trunk's iconloader when this fallback is being used.
CCMAIL: [email protected]


 M  +1 -1      rulewidgethandlermanager.cpp  


--- branches/KDE/3.5/kdepim/kmail/rulewidgethandlermanager.cpp #588914:588915
@@ -1055,7 +1055,7 @@
     QComboBox *statusCombo = new QComboBox( valueStack,
                                             "statusRuleValueCombo" );
     for ( int i = 0; i < KMail::StatusValueCountWithoutHidden; ++i ) {
-      statusCombo->insertItem( SmallIcon( KMail::StatusValues[ i ].icon ), i18n( KMail::StatusValues[ i ].text ) );
+      statusCombo->insertItem( UserIcon( KMail::StatusValues[ i ].icon ), i18n( KMail::StatusValues[ i ].text ) );
     }
     statusCombo->adjustSize();
     QObject::connect( statusCombo, SIGNAL( activated( int ) ),