diff options
author | Qt Forward Merge Bot <qt_forward_merge_bot@qt-project.org> | 2019-11-01 01:00:44 +0100 |
---|---|---|
committer | Qt Forward Merge Bot <qt_forward_merge_bot@qt-project.org> | 2019-11-01 01:00:45 +0100 |
commit | 7a13a091161851b7fa38d838d3c6ef3a96e19422 (patch) | |
tree | f8902e9b8dca7f10c519de9a90919d34fc34240b | |
parent | 36e277e91732d6d75fb6d9cb691fe9c0f83f6178 (diff) | |
parent | 37b4c07c705d068d00863ee0373322f8a94cb06e (diff) |
Merge remote-tracking branch 'origin/5.14' into 5.15
Change-Id: Ic13ef00d76c81295076bb2432576db70ec84fe29
-rw-r--r-- | examples/corelib/tools/customtype/message.cpp | 15 | ||||
-rw-r--r-- | examples/corelib/tools/customtype/message.h | 7 | ||||
-rw-r--r-- | examples/corelib/tools/customtypesending/message.cpp | 13 | ||||
-rw-r--r-- | examples/corelib/tools/customtypesending/message.h | 7 | ||||
-rw-r--r-- | examples/corelib/tools/doc/src/customtype.qdoc | 5 | ||||
-rw-r--r-- | src/3rdparty/double-conversion/double-conversion.cc | 5 | ||||
-rw-r--r-- | src/corelib/statemachine/qstatemachine.cpp | 2 | ||||
-rw-r--r-- | src/corelib/time/qmilankoviccalendar.cpp | 2 | ||||
-rw-r--r-- | src/gui/painting/qdrawhelper.cpp | 4 | ||||
-rw-r--r-- | src/plugins/platforms/cocoa/qcocoascreen.mm | 9 | ||||
-rw-r--r-- | src/widgets/widgets/qwidgettextcontrol.cpp | 2 | ||||
-rw-r--r-- | tests/auto/gui/rhi/qrhi/tst_qrhi.cpp | 3 |
12 files changed, 20 insertions, 54 deletions
diff --git a/examples/corelib/tools/customtype/message.cpp b/examples/corelib/tools/customtype/message.cpp index cc96aee978..e83697cb74 100644 --- a/examples/corelib/tools/customtype/message.cpp +++ b/examples/corelib/tools/customtype/message.cpp @@ -52,21 +52,6 @@ #include <QDebug> -//! [Message class implementation] -Message::Message() -{ -} - -Message::Message(const Message &other) - : m_body(other.m_body), m_headers(other.m_headers) -{ -} - -Message::~Message() -{ -} -//! [Message class implementation] - Message::Message(const QString &body, const QStringList &headers) : m_body(body), m_headers(headers) { diff --git a/examples/corelib/tools/customtype/message.h b/examples/corelib/tools/customtype/message.h index c1b8243237..bc30c45425 100644 --- a/examples/corelib/tools/customtype/message.h +++ b/examples/corelib/tools/customtype/message.h @@ -58,9 +58,10 @@ class Message { public: - Message(); - Message(const Message &other); - ~Message(); + Message() = default; + ~Message() = default; + Message(const Message &) = default; + Message &operator=(const Message &) = default; Message(const QString &body, const QStringList &headers); diff --git a/examples/corelib/tools/customtypesending/message.cpp b/examples/corelib/tools/customtypesending/message.cpp index 9386b93898..76f90e5144 100644 --- a/examples/corelib/tools/customtypesending/message.cpp +++ b/examples/corelib/tools/customtypesending/message.cpp @@ -50,19 +50,6 @@ #include "message.h" -Message::Message() -{ -} - -Message::Message(const Message &other) - : m_body(other.m_body), m_headers(other.m_headers) -{ -} - -Message::~Message() -{ -} - Message::Message(const QString &body, const QStringList &headers) : m_body(body), m_headers(headers) { diff --git a/examples/corelib/tools/customtypesending/message.h b/examples/corelib/tools/customtypesending/message.h index a93f111e45..38b5c8205f 100644 --- a/examples/corelib/tools/customtypesending/message.h +++ b/examples/corelib/tools/customtypesending/message.h @@ -58,9 +58,10 @@ class Message { public: - Message(); - Message(const Message &other); - ~Message(); + Message() = default; + ~Message() = default; + Message(const Message &) = default; + Message &operator=(const Message &) = default; Message(const QString &body, const QStringList &headers); diff --git a/examples/corelib/tools/doc/src/customtype.qdoc b/examples/corelib/tools/doc/src/customtype.qdoc index 7ccfc95c70..fb63bc539c 100644 --- a/examples/corelib/tools/doc/src/customtype.qdoc +++ b/examples/corelib/tools/doc/src/customtype.qdoc @@ -81,11 +81,6 @@ \section1 The Message Class Implementation - The implementation of the default constructor, copy constructor and destructor - are straightforward for the \c Message class: - - \snippet tools/customtype/message.cpp Message class implementation - The streaming operator is implemented in the following way: \snippet tools/customtype/message.cpp custom type streaming operator diff --git a/src/3rdparty/double-conversion/double-conversion.cc b/src/3rdparty/double-conversion/double-conversion.cc index 9cf13bdbf7..8c52755cfb 100644 --- a/src/3rdparty/double-conversion/double-conversion.cc +++ b/src/3rdparty/double-conversion/double-conversion.cc @@ -38,6 +38,11 @@ #include <double-conversion/strtod.h> #include <double-conversion/utils.h> +// Fix warning C4244: 'argument': conversion from 'const uc16' to 'char', possible loss of data +#ifdef _MSC_VER + __pragma(warning(disable: 4244)) +#endif + namespace double_conversion { const DoubleToStringConverter& DoubleToStringConverter::EcmaScriptConverter() { diff --git a/src/corelib/statemachine/qstatemachine.cpp b/src/corelib/statemachine/qstatemachine.cpp index a97700e5d0..44e4e151cb 100644 --- a/src/corelib/statemachine/qstatemachine.cpp +++ b/src/corelib/statemachine/qstatemachine.cpp @@ -2599,7 +2599,7 @@ void QStateMachine::setGlobalRestorePolicy(QState::RestorePolicy restorePolicy) /*! Adds the given \a state to this state machine. The state becomes a top-level - state. + state and the state machine takes ownership of the state. If the state is already in a different machine, it will first be removed from its old machine, and then added to this machine. diff --git a/src/corelib/time/qmilankoviccalendar.cpp b/src/corelib/time/qmilankoviccalendar.cpp index 68d74947b9..673713a266 100644 --- a/src/corelib/time/qmilankoviccalendar.cpp +++ b/src/corelib/time/qmilankoviccalendar.cpp @@ -56,8 +56,6 @@ using namespace QRoundingDown; \brief The QMilankovicCalendar class provides Milanković calendar system implementation. - \section1 - The Revised Julian calendar, also known as the Milanković calendar, or, less formally, new calendar, is a calendar, developed and proposed by the Serbian scientist Milutin Milanković in 1923, which effectively discontinued diff --git a/src/gui/painting/qdrawhelper.cpp b/src/gui/painting/qdrawhelper.cpp index e5f752b94e..e8d129d047 100644 --- a/src/gui/painting/qdrawhelper.cpp +++ b/src/gui/painting/qdrawhelper.cpp @@ -6044,11 +6044,11 @@ static inline void alphargbblend_argb32(quint32 *dst, uint coverage, const QRgba // nothing } else if (coverage == 0xffffffff && qAlpha(src) == 255) { blend_pixel(*dst, src); - } else if (!colorProfile) { - *dst = rgbBlend(*dst, src, coverage); } else if (*dst < 0xff000000) { // Give up and do a naive gray alphablend. Needed to deal with ARGB32 and invalid ARGB32_premultiplied, see QTBUG-60571 blend_pixel(*dst, src, qRgbAvg(coverage)); + } else if (!colorProfile) { + *dst = rgbBlend(*dst, src, coverage); } else if (srcLinear.isOpaque()) { rgbBlendPixel(dst, coverage, srcLinear, colorProfile); } else { diff --git a/src/plugins/platforms/cocoa/qcocoascreen.mm b/src/plugins/platforms/cocoa/qcocoascreen.mm index 40273bac84..bd5c95b9d0 100644 --- a/src/plugins/platforms/cocoa/qcocoascreen.mm +++ b/src/plugins/platforms/cocoa/qcocoascreen.mm @@ -375,15 +375,6 @@ void QCocoaScreen::deliverUpdateRequests() // it on the main thread yet, because the processing of the update request is taking // too long, or because the update request was deferred due to window live resizing. qDeferredDebug(screenUpdates) << ", " << framesAheadOfDelivery << " frame(s) ahead"; - - // We skip the frame completely if we're live-resizing, to not put any extra - // strain on the main thread runloop. Otherwise we assume we should push frames - // as fast as possible, and hopefully the callback will be delivered on the - // main thread just when the previous finished. - if (qt_apple_sharedApplication().keyWindow.inLiveResize) { - qDeferredDebug(screenUpdates) << "; waiting for main thread to catch up"; - return; - } } qDeferredDebug(screenUpdates) << "; signaling dispatch source"; diff --git a/src/widgets/widgets/qwidgettextcontrol.cpp b/src/widgets/widgets/qwidgettextcontrol.cpp index dce18f9100..1c169c3325 100644 --- a/src/widgets/widgets/qwidgettextcontrol.cpp +++ b/src/widgets/widgets/qwidgettextcontrol.cpp @@ -2481,7 +2481,7 @@ void QWidgetTextControl::setExtraSelections(const QList<QTextEdit::ExtraSelectio { Q_D(QWidgetTextControl); - QHash<int, int> hash; + QMultiHash<int, int> hash; for (int i = 0; i < d->extraSelections.count(); ++i) { const QAbstractTextDocumentLayout::Selection &esel = d->extraSelections.at(i); hash.insert(esel.cursor.anchor(), i); diff --git a/tests/auto/gui/rhi/qrhi/tst_qrhi.cpp b/tests/auto/gui/rhi/qrhi/tst_qrhi.cpp index 768b227ecd..533d6b17b1 100644 --- a/tests/auto/gui/rhi/qrhi/tst_qrhi.cpp +++ b/tests/auto/gui/rhi/qrhi/tst_qrhi.cpp @@ -1590,6 +1590,9 @@ void tst_QRhi::renderToWindowSimple() QScopedPointer<QWindow> window(new QWindow); switch (impl) { case QRhi::OpenGLES2: +#if QT_CONFIG(opengl) + window->setFormat(QRhiGles2InitParams::adjustedFormat()); +#endif Q_FALLTHROUGH(); case QRhi::D3D11: window->setSurfaceType(QSurface::OpenGLSurface); |