aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlxmlhttprequest.cpp
diff options
context:
space:
mode:
authorAnton Kudryavtsev <a.kudryavtsev@netris.ru>2016-07-06 14:35:24 +0300
committerShawn Rutledge <shawn.rutledge@qt.io>2016-07-06 12:16:51 +0000
commitabdc94b268fed68f068b99291ab81d85e3c84d6c (patch)
tree2fdfd506d00a0afea8a9381089291b987231d948 /src/qml/qml/qqmlxmlhttprequest.cpp
parent00a85fb5c9eebe8458d0f9c9be7745c5e26fa9b4 (diff)
Replace QString::trimmed() with QStringRef::trimmed()
... where it's possible. Reduce allocations. Change-Id: I503507f8f29e2455113c48e50389a6fdf80e1d16 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/qml/qqmlxmlhttprequest.cpp')
-rw-r--r--src/qml/qml/qqmlxmlhttprequest.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qml/qml/qqmlxmlhttprequest.cpp b/src/qml/qml/qqmlxmlhttprequest.cpp
index 74de30c96c..201d634411 100644
--- a/src/qml/qml/qqmlxmlhttprequest.cpp
+++ b/src/qml/qml/qqmlxmlhttprequest.cpp
@@ -715,7 +715,7 @@ ReturnedValue Text::method_isElementContentWhitespace(CallContext *ctx)
Scoped<Node> r(scope, ctx->thisObject().as<Node>());
if (!r) return Encode::undefined();
- return Encode(r->d()->d->data.trimmed().isEmpty());
+ return Encode(QStringRef(&r->d()->d->data).trimmed().isEmpty());
}
ReturnedValue Text::method_wholeText(CallContext *ctx)