diff options
author | Frederik Gladhorn <frederik.gladhorn@theqtcompany.com> | 2014-11-27 18:28:12 +0100 |
---|---|---|
committer | Frederik Gladhorn <frederik.gladhorn@theqtcompany.com> | 2014-11-27 18:28:12 +0100 |
commit | ce6990c3e742e0833df0561246554cf07a888efb (patch) | |
tree | 412380582040f5bb314eb90ae029b41a883aa439 /src/corelib | |
parent | 09e674849a40f5eb7e9f95fd2a952c621aec86d1 (diff) | |
parent | fa9bde7d3a12ede956339c570f7b32f95d231e57 (diff) | |
download | qtbase-ce6990c3e742e0833df0561246554cf07a888efb.tar.gz |
Merge remote-tracking branch 'origin/5.4' into dev
Change-Id: Id20053d261b4fbbcc0ac8ba49dd3ef2253fa4b95
Diffstat (limited to 'src/corelib')
-rw-r--r-- | src/corelib/json/qjsonarray.cpp | 10 | ||||
-rw-r--r-- | src/corelib/kernel/qcoreapplication.cpp | 2 | ||||
-rw-r--r-- | src/corelib/tools/qbytearray.cpp | 7 | ||||
-rw-r--r-- | src/corelib/tools/qstring.cpp | 4 |
4 files changed, 18 insertions, 5 deletions
diff --git a/src/corelib/json/qjsonarray.cpp b/src/corelib/json/qjsonarray.cpp index 73c53ea649..acbd7dda8f 100644 --- a/src/corelib/json/qjsonarray.cpp +++ b/src/corelib/json/qjsonarray.cpp @@ -709,6 +709,11 @@ bool QJsonArray::operator!=(const QJsonArray &other) const \internal */ +/*! \typedef QJsonArray::iterator::pointer + + \internal +*/ + /*! \fn QJsonArray::iterator::iterator() Constructs an uninitialized iterator. @@ -953,6 +958,11 @@ bool QJsonArray::operator!=(const QJsonArray &other) const \internal */ +/*! \typedef QJsonArray::const_iterator::pointer + + \internal +*/ + /*! \fn QJsonArray::const_iterator::const_iterator(const const_iterator &other) Constructs a copy of \a other. diff --git a/src/corelib/kernel/qcoreapplication.cpp b/src/corelib/kernel/qcoreapplication.cpp index 77900ba906..ca3d92bad1 100644 --- a/src/corelib/kernel/qcoreapplication.cpp +++ b/src/corelib/kernel/qcoreapplication.cpp @@ -2580,6 +2580,7 @@ void QCoreApplication::removeNativeEventFilter(QAbstractNativeEventFilter *filte \sa QAbstractEventDispatcher::hasPendingEvents() */ +#if QT_DEPRECATED_SINCE(5, 3) bool QCoreApplication::hasPendingEvents() { QAbstractEventDispatcher *eventDispatcher = QAbstractEventDispatcher::instance(); @@ -2587,6 +2588,7 @@ bool QCoreApplication::hasPendingEvents() return eventDispatcher->hasPendingEvents(); return false; } +#endif /*! Returns a pointer to the event dispatcher object for the main thread. If no diff --git a/src/corelib/tools/qbytearray.cpp b/src/corelib/tools/qbytearray.cpp index 36acfc4c09..26bf7d047d 100644 --- a/src/corelib/tools/qbytearray.cpp +++ b/src/corelib/tools/qbytearray.cpp @@ -3644,7 +3644,7 @@ QByteArray QByteArray::toBase64(Base64Options options) const const char padchar = '='; int padlen = 0; - QByteArray tmp((d->size * 4) / 3 + 3, Qt::Uninitialized); + QByteArray tmp((d->size + 2) / 3 * 4, Qt::Uninitialized); int i = 0; char *out = tmp.data(); @@ -3682,8 +3682,9 @@ QByteArray QByteArray::toBase64(Base64Options options) const *out++ = alphabet[m]; } } - - tmp.truncate(out - tmp.data()); + Q_ASSERT((options & OmitTrailingEquals) || (out == tmp.size() + tmp.data())); + if (options & OmitTrailingEquals) + tmp.truncate(out - tmp.data()); return tmp; } diff --git a/src/corelib/tools/qstring.cpp b/src/corelib/tools/qstring.cpp index 76069225eb..e830ed36e5 100644 --- a/src/corelib/tools/qstring.cpp +++ b/src/corelib/tools/qstring.cpp @@ -1723,9 +1723,9 @@ void QString::expand(int i) /*! \fn void QString::clear() - Clears the contents of the string and makes it empty. + Clears the contents of the string and makes it null. - \sa resize(), isEmpty() + \sa resize(), isNull() */ /*! \fn QString &QString::operator=(const QString &other) |