diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-02-18 11:24:05 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-02-18 11:24:05 (GMT) |
commit | c18beac8163634b48bbf1e7280923e96f5ef0a51 (patch) | |
tree | ae6d5d595d1b46bcaa721efc95c98c97e078d214 /src/corelib | |
parent | fd3f9dd0f31efeea3aa0ec28b54c70d85712c7ba (diff) | |
parent | eeb121d54e345e92ab74d8c43e07d803a0e144ea (diff) | |
download | Qt-c18beac8163634b48bbf1e7280923e96f5ef0a51.zip Qt-c18beac8163634b48bbf1e7280923e96f5ef0a51.tar.gz Qt-c18beac8163634b48bbf1e7280923e96f5ef0a51.tar.bz2 |
Merge branch 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into master-integration
* 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1: (62 commits)
Compile.
Remove these friend declarations that aren't necessary in 4.7
Added a new flag to fine-tune gesture propagation policy
AIX has a #define for hz, so undef it
Revert "remove -lz from OPENSSL_LIBS so as to respect qt-zlib"
remove -lz from QT_LFLAGS_PSQL so as to respect qt-zlib
remove -lz from OPENSSL_LIBS so as to respect qt-zlib
Fix compilation with IBM xlC 7:
Fix compilation of Qt Assistant when WebKit isn't built.
Mac: QSystemTrayIcon::DoubleClick and midmouse not working
add test for toDateTime() using QLocale::LongFormat
remove debug info
add test case for QTBUG-7898 that QLocale::toDateTime(QString, FormatType) cannot convert value correctly
fix QTBUG-7898
QNAM HTTP: More micro optimization in QHttpNetworkRequest
QNAM HTTP: Some micro optimization in QHttpNetworkRequest
QNAM HTTP: Trivial optimization
Revert "Optimized QLocale to access system locale on demand."
doc: Added "\sa {QML Basic Types} to each QML basic type page.
Incorrect mouse coordinates used when compressing WM_MOUSEMOVE messages.
...
Diffstat (limited to 'src/corelib')
-rw-r--r-- | src/corelib/codecs/qtextcodec.h | 5 | ||||
-rw-r--r-- | src/corelib/global/qnamespace.h | 3 | ||||
-rw-r--r-- | src/corelib/global/qnamespace.qdoc | 1 | ||||
-rw-r--r-- | src/corelib/io/qdataurl.cpp | 2 | ||||
-rw-r--r-- | src/corelib/io/qdataurl_p.h | 2 | ||||
-rw-r--r-- | src/corelib/io/qdir.cpp | 18 | ||||
-rw-r--r-- | src/corelib/tools/qlocale.cpp | 2 | ||||
-rw-r--r-- | src/corelib/tools/qsharedpointer_impl.h | 49 |
8 files changed, 59 insertions, 23 deletions
diff --git a/src/corelib/codecs/qtextcodec.h b/src/corelib/codecs/qtextcodec.h index 5012b42..e37527d 100644 --- a/src/corelib/codecs/qtextcodec.h +++ b/src/corelib/codecs/qtextcodec.h @@ -171,11 +171,6 @@ public: private: const QTextCodec *c; QTextCodec::ConverterState state; - - friend class QXmlStreamWriter; - friend class QXmlStreamWriterPrivate; - friend class QCoreXmlStreamWriter; - friend class QCoreXmlStreamWriterPrivate; }; class Q_CORE_EXPORT QTextDecoder { diff --git a/src/corelib/global/qnamespace.h b/src/corelib/global/qnamespace.h index 35ff8e7..6ee8ae9 100644 --- a/src/corelib/global/qnamespace.h +++ b/src/corelib/global/qnamespace.h @@ -1725,7 +1725,8 @@ public: enum GestureFlag { DontStartGestureOnChildren = 0x01, - ReceivePartialGestures = 0x02 + ReceivePartialGestures = 0x02, + IgnoredGesturesPropagateToParent = 0x04 }; Q_DECLARE_FLAGS(GestureFlags, GestureFlag) diff --git a/src/corelib/global/qnamespace.qdoc b/src/corelib/global/qnamespace.qdoc index 1f1c8f7..db910ce 100644 --- a/src/corelib/global/qnamespace.qdoc +++ b/src/corelib/global/qnamespace.qdoc @@ -42,6 +42,7 @@ /*! \namespace Qt \inmodule QtCore + \target Qt Namespace \brief The Qt namespace contains miscellaneous identifiers used throughout the Qt library. diff --git a/src/corelib/io/qdataurl.cpp b/src/corelib/io/qdataurl.cpp index 9bb896e..4e2dec2 100644 --- a/src/corelib/io/qdataurl.cpp +++ b/src/corelib/io/qdataurl.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/corelib/io/qdataurl_p.h b/src/corelib/io/qdataurl_p.h index be5b10d..57cfd75 100644 --- a/src/corelib/io/qdataurl_p.h +++ b/src/corelib/io/qdataurl_p.h @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). +** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** diff --git a/src/corelib/io/qdir.cpp b/src/corelib/io/qdir.cpp index f5d803e..7cfdddf 100644 --- a/src/corelib/io/qdir.cpp +++ b/src/corelib/io/qdir.cpp @@ -89,8 +89,6 @@ public: QDirPrivate(const QDir *copy = 0); ~QDirPrivate(); - QString initFileEngine(const QString &file); - void updateFileLists() const; void sortFileList(QDir::SortFlags, QFileInfoList &, QStringList *, QFileInfoList *) const; @@ -146,6 +144,7 @@ public: } *data; inline void setPath(const QString &p) { + detach(false); QString path = p; if ((path.endsWith(QLatin1Char('/')) || path.endsWith(QLatin1Char('\\'))) && path.length() > 1) { @@ -155,8 +154,12 @@ public: path.truncate(path.length() - 1); } + delete data->fileEngine; + data->fileEngine = QAbstractFileEngine::create(path); + // set the path to be the qt friendly version so then we can operate on it using just / - data->path = initFileEngine(path); + data->path = data->fileEngine->fileName(QAbstractFileEngine::DefaultName); + data->clear(); } inline void reset() { detach(); @@ -310,15 +313,6 @@ inline void QDirPrivate::updateFileLists() const } } -inline QString QDirPrivate::initFileEngine(const QString &path) -{ - detach(false); - data->clear(); - delete data->fileEngine; - data->fileEngine = QAbstractFileEngine::create(path); - return data->fileEngine->fileName(QAbstractFileEngine::DefaultName); -} - void QDirPrivate::detach(bool createFileEngine) { qAtomicDetach(data); diff --git a/src/corelib/tools/qlocale.cpp b/src/corelib/tools/qlocale.cpp index ff10fa1..b4bfcaf 100644 --- a/src/corelib/tools/qlocale.cpp +++ b/src/corelib/tools/qlocale.cpp @@ -2917,7 +2917,7 @@ QDate QLocale::toDate(const QString &string, FormatType format) const #ifndef QT_NO_DATESTRING QDateTime QLocale::toDateTime(const QString &string, FormatType format) const { - return toDateTime(string, dateFormat(format)); + return toDateTime(string, dateTimeFormat(format)); } #endif diff --git a/src/corelib/tools/qsharedpointer_impl.h b/src/corelib/tools/qsharedpointer_impl.h index 8fbfcda..0dcea5f 100644 --- a/src/corelib/tools/qsharedpointer_impl.h +++ b/src/corelib/tools/qsharedpointer_impl.h @@ -653,6 +653,9 @@ public: T *value; }; +// +// operator== and operator!= +// template <class T, class X> bool operator==(const QSharedPointer<T> &ptr1, const QSharedPointer<X> &ptr2) { @@ -674,7 +677,6 @@ bool operator==(const T *ptr1, const QSharedPointer<X> &ptr2) { return ptr1 == ptr2.data(); } - template <class T, class X> bool operator!=(const QSharedPointer<T> &ptr1, const X *ptr2) { @@ -697,11 +699,54 @@ bool operator!=(const QSharedPointer<T> &ptr1, const QWeakPointer<X> &ptr2) return ptr2 != ptr1; } +// +// operator- +// template <class T, class X> -Q_INLINE_TEMPLATE typename T::difference_type operator-(const QSharedPointer<T> &ptr1, const QSharedPointer<X> &ptr2) +Q_INLINE_TEMPLATE typename QSharedPointer<T>::difference_type operator-(const QSharedPointer<T> &ptr1, const QSharedPointer<X> &ptr2) { return ptr1.data() - ptr2.data(); } +template <class T, class X> +Q_INLINE_TEMPLATE typename QSharedPointer<T>::difference_type operator-(const QSharedPointer<T> &ptr1, X *ptr2) +{ + return ptr1.data() - ptr2; +} +template <class T, class X> +Q_INLINE_TEMPLATE typename QSharedPointer<X>::difference_type operator-(T *ptr1, const QSharedPointer<X> &ptr2) +{ + return ptr1 - ptr2.data(); +} + +// +// operator< +// +template <class T, class X> +Q_INLINE_TEMPLATE bool operator<(const QSharedPointer<T> &ptr1, const QSharedPointer<X> &ptr2) +{ + return ptr1.data() < ptr2.data(); +} +template <class T, class X> +Q_INLINE_TEMPLATE bool operator<(const QSharedPointer<T> &ptr1, X *ptr2) +{ + return ptr1.data() < ptr2; +} +template <class T, class X> +Q_INLINE_TEMPLATE bool operator<(T *ptr1, const QSharedPointer<X> &ptr2) +{ + return ptr1 < ptr2.data(); +} + +// +// qHash +// +template <class T> inline uint qHash(const T *key); // defined in qhash.h +template <class T> +Q_INLINE_TEMPLATE uint qHash(const QSharedPointer<T> &ptr) +{ + return QT_PREPEND_NAMESPACE(qHash)<T>(ptr.data()); +} + template <class T> Q_INLINE_TEMPLATE QWeakPointer<T> QSharedPointer<T>::toWeakRef() const |