From 1a7b140eb8f3f03354452c4669aabae2f141b9c8 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Wed, 10 Feb 2016 15:56:40 +0100 Subject: String fixes. - Avoid conversion from QString to QByteArray. - Replace a = a.mid() by a.remove(). - Replace a = a.left() by a.truncate(). - Streamline code extracting an error code. Change-Id: I43c1f04e947632f725bbb86af5abf108b2b02261 Reviewed-by: Oliver Wolff --- tools/testcon/invokemethod.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tools/testcon') diff --git a/tools/testcon/invokemethod.cpp b/tools/testcon/invokemethod.cpp index 0f898b1..ec6024c 100644 --- a/tools/testcon/invokemethod.cpp +++ b/tools/testcon/invokemethod.cpp @@ -114,7 +114,7 @@ void InvokeMethod::on_comboMethods_activated(const QString &method) const QMetaObject *mo = activex->metaObject(); const QMetaMethod slot = mo->method(mo->indexOfSlot(method.toLatin1())); QString signature = QString::fromLatin1(slot.methodSignature()); - signature = signature.mid(signature.indexOf(QLatin1Char('(')) + 1); + signature.remove(0, signature.indexOf(QLatin1Char('(')) + 1); signature.truncate(signature.length()-1); QList pnames = slot.parameterNames(); -- cgit v1.2.3