summaryrefslogtreecommitdiffabout
path: root/kaddressbook/views/contactlistview.cpp
Unidiff
Diffstat (limited to 'kaddressbook/views/contactlistview.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--kaddressbook/views/contactlistview.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/kaddressbook/views/contactlistview.cpp b/kaddressbook/views/contactlistview.cpp
index 5fb4163..ad43970 100644
--- a/kaddressbook/views/contactlistview.cpp
+++ b/kaddressbook/views/contactlistview.cpp
@@ -163,42 +163,42 @@ ContactListViewItem::ContactListViewItem(const KABC::Addressee &a,
163 : KListViewItem(parent), mAddressee(a), mFields( fields ), 163 : KListViewItem(parent), mAddressee(a), mFields( fields ),
164 parentListView( parent ), mDocument(doc) 164 parentListView( parent ), mDocument(doc)
165{ 165{
166 refresh(); 166 refresh();
167} 167}
168 168
169QString ContactListViewItem::key(int column, bool ascending) const 169QString ContactListViewItem::key(int column, bool ascending) const
170{ 170{
171#ifndef DESKTOP_VERSION 171#ifndef DESKTOP_VERSION
172 int lan = KGlobal::locale()->language(); 172 int lan = KGlobal::locale()->language();
173 //qDebug("language %d ", lan); 173 //qDebug("language %d ", lan);
174 if ( lan == 1 ) { //GERMAN 174 if ( lan == 1 ) { //GERMAN
175 QString ret = QListViewItem::key(column, ascending).utf8(); 175 QString ret = QListViewItem::key(column, ascending).lower().utf8();
176 int start = -1; 176 int start = -1;
177 while ( (start = ret.find( 'ä', start+1)) > 0 ) { 177 while ( (start = ret.find( 'ä', start+1)) > 0 ) {
178 ret.at(start-1) = 'a'; 178 ret.at(start-1) = 'a';
179 } 179 }
180 start = -1; 180 start = -1;
181 while ( (start = ret.find( 'ö', start+1)) > 0 ) { 181 while ( (start = ret.find( 'ö', start+1)) > 0 ) {
182 ret.at(start-1) = 'o'; 182 ret.at(start-1) = 'o';
183 } 183 }
184 start = -1; 184 start = -1;
185 while ( (start = ret.find( 'ü', start+1)) > 0 ) { 185 while ( (start = ret.find( 'ü', start+1)) > 0 ) {
186 ret.at(start-1) = 'o'; 186 ret.at(start-1) = 'o';
187 } 187 }
188 start = -1; 188 start = -1;
189 while ( (start = ret.find( 'ß', start+1)) > 0 ) { 189 while ( (start = ret.find( 'ß', start+1)) > 0 ) {
190 ret.at(start-1) = 's'; 190 ret.at(start-1) = 's';
191 } 191 }
192 //qDebug("conv string %s ", ret.latin1()); 192 qDebug("conv string %s ", ret.latin1());
193 193
194 return ret; 194 return ret;
195 195
196 } 196 }
197 else 197 else
198#endif 198#endif
199 return QListViewItem::key(column, ascending).lower(); 199 return QListViewItem::key(column, ascending).lower();
200} 200}
201 201
202void ContactListViewItem::paintCell(QPainter * p, 202void ContactListViewItem::paintCell(QPainter * p,
203 const QColorGroup & cg, 203 const QColorGroup & cg,
204 int column, 204 int column,