diff --git a/kmsearchpatternedit.cpp b/kmsearchpatternedit.cpp index cec16d31a..4799fd55a 100644 --- a/kmsearchpatternedit.cpp +++ b/kmsearchpatternedit.cpp @@ -51,7 +51,11 @@ static const struct { { "", I18N_NOOP( "All Recipients" ) }, { "", I18N_NOOP( "Size in Bytes" ) }, { "", I18N_NOOP( "Age in Days" ) }, - { "", I18N_NOOP( "Message Status" ) } + { "", I18N_NOOP( "Message Status" ) }, + { "Subject", I18N_NOOP( "Subject" ) }, + { "From", I18N_NOOP( "From" ) }, + { "To", I18N_NOOP( "To" ) }, + { "CC", I18N_NOOP( "CC" ) } }; static const int SpecialRuleFieldsCount = sizeof( SpecialRuleFields ) / sizeof( *SpecialRuleFields ); @@ -264,13 +268,13 @@ void KMSearchRuleWidget::initFieldList( bool headersOnly, bool absoluteDates ) mFilterFieldList.append( i18n( SpecialRuleFields[Size].displayName ) ); if ( !absoluteDates ) mFilterFieldList.append( i18n( SpecialRuleFields[AgeInDays].displayName ) ); - mFilterFieldList.append( i18n( SpecialRuleFields[Status].displayName ) ); + mFilterFieldList.append( i18n( SpecialRuleFields[Subject].displayName ) ); + mFilterFieldList.append( i18n( SpecialRuleFields[From].displayName ) ); + mFilterFieldList.append( i18n( SpecialRuleFields[To].displayName ) ); + mFilterFieldList.append( i18n( SpecialRuleFields[CC].displayName ) ); + // these others only represent message headers and you can add to // them as you like - mFilterFieldList.append("Subject"); - mFilterFieldList.append("From"); - mFilterFieldList.append("To"); - mFilterFieldList.append("CC"); mFilterFieldList.append("Reply-To"); mFilterFieldList.append("List-Id"); mFilterFieldList.append("Organization"); diff --git a/kmsearchpatternedit.h b/kmsearchpatternedit.h index 88846ca9b..4df2b3a70 100644 --- a/kmsearchpatternedit.h +++ b/kmsearchpatternedit.h @@ -56,7 +56,8 @@ public: be used to initialize the widget. */ explicit KMSearchRuleWidget( QWidget* parent=0, KMSearchRule* aRule=0, bool headersOnly = false, bool absoluteDates = false ); - enum { Message, Body, AnyHeader, Recipients, Size, AgeInDays, Status }; + enum { Message, Body, AnyHeader, Recipients, Size, AgeInDays, Status, + Subject, From, To, CC }; /** Set whether only header fields can be searched. If @p is true only header fields can be searched otherwise \ and \ searches