summaryrefslogtreecommitdiff
path: root/libopie2
Unidiff
Diffstat (limited to 'libopie2') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opiepim/private/opimcontactsortvector.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/libopie2/opiepim/private/opimcontactsortvector.cpp b/libopie2/opiepim/private/opimcontactsortvector.cpp
index 9e186fe..8c7d5ca 100644
--- a/libopie2/opiepim/private/opimcontactsortvector.cpp
+++ b/libopie2/opiepim/private/opimcontactsortvector.cpp
@@ -38,15 +38,15 @@ OPimContactSortVector::OPimContactSortVector( uint size, bool asc, int sort )
38int OPimContactSortVector::compareItems( const OPimContact& left, 38int OPimContactSortVector::compareItems( const OPimContact& left,
39 const OPimContact& right ) { 39 const OPimContact& right ) {
40 if ( left.uid() == right.uid() ) 40 if ( left.uid() == right.uid() )
41 return 0; 41 return 0;
42 42
43 bool soTitle, soSummary, soFirstName, soMiddleName, soSuffix, soEmail, 43 bool soTitle, soSummary, soFirstName, soMiddleName, soSuffix, soEmail,
44 soNick, soAnni, soBirth, soGender; 44 soNick, soFileAs, soAnni, soBirth, soGender;
45 soTitle = soSummary = soFirstName = soMiddleName = soSuffix = soEmail = 45 soTitle = soSummary = soFirstName = soMiddleName = soSuffix = soEmail =
46 soNick = soAnni = soBirth = soGender = false; 46 soNick = soFileAs = soAnni = soBirth = soGender = false;
47 int ret = 0; 47 int ret = 0;
48 bool asc = sortAscending(); 48 bool asc = sortAscending();
49 49
50 switch( sortOrder() ) { 50 switch( sortOrder() ) {
51 case OPimContactAccess::SortSummary: 51 case OPimContactAccess::SortSummary:
52 ret = testString( left.fileAs(), right.fileAs() ); 52 ret = testString( left.fileAs(), right.fileAs() );
@@ -73,12 +73,16 @@ int OPimContactSortVector::compareItems( const OPimContact& left,
73 soEmail = true; 73 soEmail = true;
74 break; 74 break;
75 case OPimContactAccess::SortNickname: 75 case OPimContactAccess::SortNickname:
76 ret = testString( left.nickname(), right.nickname() ); 76 ret = testString( left.nickname(), right.nickname() );
77 soNick = true; 77 soNick = true;
78 break; 78 break;
79 case OPimContactAccess::SortFileAsName:
80 ret = testString( left.fileAs(), right.fileAs() );
81 soFileAs = true;
82 break;
79 case OPimContactAccess::SortAnniversary: 83 case OPimContactAccess::SortAnniversary:
80 ret = testDate( left.anniversary(), right.anniversary() ); 84 ret = testDate( left.anniversary(), right.anniversary() );
81 soAnni = true; 85 soAnni = true;
82 break; 86 break;
83 case OPimContactAccess::SortByDate: 87 case OPimContactAccess::SortByDate:
84 case OPimContactAccess::SortBirthday: 88 case OPimContactAccess::SortBirthday: