summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDenis Dzyubenko <denis.dzyubenko@nokia.com>2010-06-14 08:12:07 (GMT)
committerDenis Dzyubenko <denis.dzyubenko@nokia.com>2010-06-15 13:14:44 (GMT)
commit0e0e74f23566de7ae408a2e7091001941508b694 (patch)
tree181b1f5f40b340b5b64782ed4a27504fb15e3e2c /src
parent20a39c16f236f999cd1694cdc47a3739efcbbfe4 (diff)
downloadQt-0e0e74f23566de7ae408a2e7091001941508b694.zip
Qt-0e0e74f23566de7ae408a2e7091001941508b694.tar.gz
Qt-0e0e74f23566de7ae408a2e7091001941508b694.tar.bz2
Use native locale aware string comparison on Symbian.
Fix to use the native CompareC function instead. Task-number: QTBUG-11350 Reviewed-by: Miikka Heikkinen
Diffstat (limited to 'src')
-rw-r--r--src/corelib/tools/qstring.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/corelib/tools/qstring.cpp b/src/corelib/tools/qstring.cpp
index 1d5fab3..57f79a0 100644
--- a/src/corelib/tools/qstring.cpp
+++ b/src/corelib/tools/qstring.cpp
@@ -4768,6 +4768,10 @@ int QString::localeAwareCompare_helper(const QChar *data1, int length1,
CFRelease(thisString);
CFRelease(otherString);
return result;
+#elif defined(Q_OS_SYMBIAN)
+ TPtrC p1 = TPtrC16(reinterpret_cast<const TUint16 *>(data1), length1);
+ TPtrC p2 = TPtrC16(reinterpret_cast<const TUint16 *>(data2), length2);
+ return p1.CompareC(p2);
#elif defined(Q_OS_UNIX)
// declared in <string.h>
int delta = strcoll(toLocal8Bit_helper(data1, length1), toLocal8Bit_helper(data2, length2));