diff options
author | Rohan McGovern <rohan.mcgovern@nokia.com> | 2012-02-29 09:18:59 +1000 |
---|---|---|
committer | Rohan McGovern <rohan.mcgovern@nokia.com> | 2012-02-29 09:23:14 +1000 |
commit | 98dd1781d9256f68025d2a2db408f4f5947f3214 (patch) | |
tree | dbe1424abd90014edb5546c920ca585ed62b46e3 /src/corelib/tools/qstring.h | |
parent | 6c1bdc1854a7700c2b3a345b95f6a2fdca84037d (diff) | |
parent | fa1b9070af66edb81b2a3735c1951f78b22bd666 (diff) |
Merge master -> api_changes
Includes fixes for tst_qfiledialog2, tst_qtextedit autotests on mac.
Change-Id: I49cac26894d31291a8339ccc1eb80b6a940f0827
Diffstat (limited to 'src/corelib/tools/qstring.h')
-rw-r--r-- | src/corelib/tools/qstring.h | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/src/corelib/tools/qstring.h b/src/corelib/tools/qstring.h index bdadba8bd4..6fc86fc04b 100644 --- a/src/corelib/tools/qstring.h +++ b/src/corelib/tools/qstring.h @@ -502,10 +502,10 @@ public: // ASCII compatibility #ifndef QT_NO_CAST_FROM_ASCII - inline QT_ASCII_CAST_WARN_CONSTRUCTOR QString(const char *ch) + inline QT_ASCII_CAST_WARN QString(const char *ch) : d(fromAscii_helper(ch, ch ? int(strlen(ch)) : -1)) {} - inline QT_ASCII_CAST_WARN_CONSTRUCTOR QString(const QByteArray &a) + inline QT_ASCII_CAST_WARN QString(const QByteArray &a) : d(fromAscii_helper(a.constData(), qstrnlen(a.constData(), a.size()))) {} inline QT_ASCII_CAST_WARN QString &operator=(const char *ch) @@ -609,9 +609,6 @@ private: Data *d; inline QString(Data *dd, int /*dummy*/) : d(dd) {} -#ifndef QT_NO_TEXTCODEC - static QTextCodec *codecForCStrings; -#endif static int grow(int); static void free(Data *); void realloc(); @@ -931,9 +928,6 @@ inline bool operator!=(const QString &s, QString::Null) { return !s.isNull(); } #ifndef QT_NO_CAST_FROM_ASCII inline bool qStringComparisonHelper(const QString &s1, const char *s2) { -# ifndef QT_NO_TEXTCODEC - if (QString::codecForCStrings) return (s1 == QString::fromAscii(s2, s2 ? int(strlen(s2)) : -1)); -# endif return (s1 == QLatin1String(s2)); } inline bool QString::operator==(const char *s) const @@ -1220,9 +1214,6 @@ inline bool operator>=(const QStringRef &s1, const QStringRef &s2) inline bool qStringComparisonHelper(const QStringRef &s1, const char *s2) { -# ifndef QT_NO_TEXTCODEC - if (QString::codecForCStrings) return (s1 == QString::fromAscii(s2, s2 ? int(strlen(s2)) : -1)); -# endif return (s1 == QLatin1String(s2)); } |