summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/3rdparty/webkit/JavaScriptCore/runtime/UString.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/3rdparty/webkit/JavaScriptCore/runtime/UString.h b/src/3rdparty/webkit/JavaScriptCore/runtime/UString.h
index d01b75d..bb0e7fb 100644
--- a/src/3rdparty/webkit/JavaScriptCore/runtime/UString.h
+++ b/src/3rdparty/webkit/JavaScriptCore/runtime/UString.h
@@ -77,6 +77,18 @@ namespace JSC {
friend class JIT;
public:
+
+#if PLATFORM(QT)
+
+ QString toQString() const
+ {
+ // Not sure with method is better, 2nd is shorter
+ //UString string
+ //QString::fromUtf8(string.toString().UTF8String().c_str())
+
+ return QString(reinterpret_cast<const QChar*>(this->data()), this->size());
+ }
+#endif
typedef CrossThreadRefCounted<OwnFastMallocPtr<UChar> > SharedUChar;
struct BaseString;
struct Rep : Noncopyable {