summaryrefslogtreecommitdiffstats
path: root/src/tools/uic3/parser.cpp
diff options
context:
space:
mode:
authorThierry Bastian <thierry.bastian@nokia.com>2009-05-28 08:27:50 (GMT)
committerThierry Bastian <thierry.bastian@nokia.com>2009-05-28 08:31:07 (GMT)
commitf390f9b51cf8686e9ed44f13a33c7349b9e96a09 (patch)
tree162c768769713a7215bca64daf8f2bdc75c9fbee /src/tools/uic3/parser.cpp
parent0bb0699d403b7541472a72a4057ecf0ca366a7cd (diff)
downloadQt-f390f9b51cf8686e9ed44f13a33c7349b9e96a09.zip
Qt-f390f9b51cf8686e9ed44f13a33c7349b9e96a09.tar.gz
Qt-f390f9b51cf8686e9ed44f13a33c7349b9e96a09.tar.bz2
improved string operations all over the place
used character operations whenever possible better usage of QLatin1String
Diffstat (limited to 'src/tools/uic3/parser.cpp')
-rw-r--r--src/tools/uic3/parser.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/tools/uic3/parser.cpp b/src/tools/uic3/parser.cpp
index 744dd30..395cc4d 100644
--- a/src/tools/uic3/parser.cpp
+++ b/src/tools/uic3/parser.cpp
@@ -48,14 +48,14 @@ QT_BEGIN_NAMESPACE
QString Parser::cleanArgs(const QString &func)
{
QString slot(func);
- int begin = slot.indexOf(QLatin1String("(")) + 1;
+ int begin = slot.indexOf(QLatin1Char('(')) + 1;
QString args = slot.mid(begin);
- args = args.left(args.indexOf(QLatin1String(")")));
+ args = args.left(args.indexOf(QLatin1Char(')')));
QStringList lst = args.split(QLatin1Char(','));
QString res = slot.left(begin);
for (QStringList::Iterator it = lst.begin(); it != lst.end(); ++it) {
if (it != lst.begin())
- res += QLatin1String(",");
+ res += QLatin1Char(',');
QString arg = *it;
int pos = 0;
if ((pos = arg.indexOf(QLatin1Char('&'))) != -1) {
@@ -65,7 +65,7 @@ QString Parser::cleanArgs(const QString &func)
} else {
arg = arg.simplified();
if ((pos = arg.indexOf(QLatin1Char(':'))) != -1)
- arg = arg.left(pos).simplified() + QLatin1String(":") + arg.mid(pos + 1).simplified();
+ arg = arg.left(pos).simplified() + QLatin1Char(':') + arg.mid(pos + 1).simplified();
QStringList l = arg.split(QLatin1Char(' '));
if (l.count() == 2) {
if (l[0] != QLatin1String("const")
@@ -73,12 +73,12 @@ QString Parser::cleanArgs(const QString &func)
&& l[0] != QLatin1String("var"))
arg = l[0];
} else if (l.count() == 3) {
- arg = l[0] + QLatin1String(" ") + l[1];
+ arg = l[0] + QLatin1Char(' ') + l[1];
}
}
res += arg;
}
- res += QLatin1String(")");
+ res += QLatin1Char(')');
return res;
}