OSDN Git Service
(root)
/
kde
/
Katie.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7f3d575
)
optimize QIcuCodec::allMibs()
author
Ivailo Monev
<xakepa10@laimg.moc>
Tue, 14 Jul 2020 16:22:07 +0000
(16:22 +0000)
committer
Ivailo Monev
<xakepa10@laimg.moc>
Tue, 14 Jul 2020 16:22:07 +0000
(16:22 +0000)
Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
src/core/codecs/qicucodec.cpp
patch
|
blob
|
history
diff --git
a/src/core/codecs/qicucodec.cpp
b/src/core/codecs/qicucodec.cpp
index
f6f3ac0
..
49b35fc
100644
(file)
--- a/
src/core/codecs/qicucodec.cpp
+++ b/
src/core/codecs/qicucodec.cpp
@@
-1112,9
+1112,10
@@
QList<int> QIcuCodec::allMibs()
{
QList<int> allmibs;
- foreach(const QByteArray &name, QIcuCodec::allCodecs()) {
+ for (int i = 0; i < ucnv_countAvailable(); i++) {
+ const char *name = ucnv_getAvailableName(i);
for (qint16 i = 0; i < MIBTblSize; i++) {
- if (ucnv_compareNames(name
.constData()
, MIBTbl[i].name) == 0) {
+ if (ucnv_compareNames(name, MIBTbl[i].name) == 0) {
allmibs.append(MIBTbl[i].mib);
}
}