summaryrefslogtreecommitdiffstats
path: root/src/corelib/tools/qcollator_win.cpp
diff options
context:
space:
mode:
authorEdward Welbourne <edward.welbourne@qt.io>2018-12-11 17:41:24 +0100
committerEdward Welbourne <edward.welbourne@qt.io>2019-03-08 17:07:57 +0000
commit830e06a3f8173621a99426e7da6ad9704eb701b3 (patch)
tree9e7aa67988234db565aa765e0c58f63603532d22 /src/corelib/tools/qcollator_win.cpp
parentcdd3bd1d2cb3f5c23159a987c19b6919f08d68b7 (diff)
Clean up the QCollator code and comments
Broke over-long lines. Reflowed documentation, refined a phrasing, corrected some out of date details and typos. Change-Id: Ic3835bb198bd062f85b3c466b56dc9636d4d3fe4 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Diffstat (limited to 'src/corelib/tools/qcollator_win.cpp')
-rw-r--r--src/corelib/tools/qcollator_win.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/corelib/tools/qcollator_win.cpp b/src/corelib/tools/qcollator_win.cpp
index 9cbdd96ee0..4adbf4adf8 100644
--- a/src/corelib/tools/qcollator_win.cpp
+++ b/src/corelib/tools/qcollator_win.cpp
@@ -94,9 +94,10 @@ int QCollator::compare(QStringView s1, QStringView s2) const
d->init();
//* from Windows documentation *
- // Returns one of the following values if successful. To maintain the C runtime convention of
- // comparing strings, the value 2 can be subtracted from a nonzero return value. Then, the
- // meaning of <0, ==0, and >0 is consistent with the C runtime.
+ // Returns one of the following values if successful. To maintain the C
+ // runtime convention of comparing strings, the value 2 can be subtracted
+ // from a nonzero return value. Then, the meaning of <0, ==0, and >0 is
+ // consistent with the C runtime.
#ifndef USE_COMPARESTRINGEX
return CompareString(d->localeID, d->collator,
@@ -137,7 +138,9 @@ QCollatorSortKey QCollator::sortKey(const QString &string) const
NULL, NULL, 0);
#endif
if (finalSize == 0) {
- qWarning() << "there were problems when generating the ::sortKey by LCMapStringW with error:" << GetLastError();
+ qWarning()
+ << "there were problems when generating the ::sortKey by LCMapStringW with error:"
+ << GetLastError();
}
return QCollatorSortKey(new QCollatorSortKeyPrivate(std::move(ret)));
}