From e4953b7262d8122747569efee194b6eb46d40749 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Thu, 14 Jan 2010 16:46:57 +0100 Subject: fix qm generation under windows Reviewed-by: Daniel Molkentin --- translations/translations.pro | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/translations/translations.pro b/translations/translations.pro index ef09dc3..05dd968 100644 --- a/translations/translations.pro +++ b/translations/translations.pro @@ -14,7 +14,7 @@ LIBS = updateqm.input = TRANSLATIONS updateqm.output = ${QMAKE_FILE_BASE}.qm isEmpty(vcproj):updateqm.variable_out = PRE_TARGETDEPS -updateqm.commands = @echo lrelease ${QMAKE_FILE_IN}; $$LRELEASE ${QMAKE_FILE_IN} -qm ${QMAKE_FILE_OUT} +updateqm.commands = @echo lrelease ${QMAKE_FILE_IN} && $$LRELEASE ${QMAKE_FILE_IN} -qm ${QMAKE_FILE_OUT} updateqm.name = LRELEASE ${QMAKE_FILE_IN} updateqm.CONFIG += no_link QMAKE_EXTRA_COMPILERS += updateqm -- cgit v0.12 From 13d9af283210acf4e8e46075fda2104c20aceb7a Mon Sep 17 00:00:00 2001 From: Harald Fernengel Date: Fri, 15 Jan 2010 14:16:48 +0100 Subject: use same small color dialog on S60 and Maemo 5 Reviewed-By: Jason Barron --- src/gui/dialogs/qcolordialog.cpp | 45 +++++++++++++++++++++++++--------------- 1 file changed, 28 insertions(+), 17 deletions(-) diff --git a/src/gui/dialogs/qcolordialog.cpp b/src/gui/dialogs/qcolordialog.cpp index e9031ac..83ecc30 100644 --- a/src/gui/dialogs/qcolordialog.cpp +++ b/src/gui/dialogs/qcolordialog.cpp @@ -68,6 +68,10 @@ #include "private/qt_s60_p.h" #endif +#if defined(Q_WS_S60) || defined(Q_WS_MAEMO_5) +# define QT_SMALL_COLORDIALOG +#endif + QT_BEGIN_NAMESPACE //////////// QWellArray BEGIN @@ -1072,14 +1076,17 @@ QColorShower::QColorShower(QColorDialog *parent) gl->setMargin(gl->spacing()); lab = new QColorShowLabel(this); -#ifdef Q_WS_S60 +#ifdef QT_SMALL_COLORDIALOG +# ifdef Q_WS_S60 QS60Data s60Data = QS60Data(); const bool nonTouchUI = !s60Data.hasTouchscreen; +# elif defined Q_WS_MAEMO_5 + const bool nonTouchUI = false; +# endif #endif - #ifndef Q_WS_WINCE -#ifdef Q_WS_S60 +#ifdef QT_SMALL_COLORDIALOG lab->setMinimumHeight(60); #endif lab->setMinimumWidth(60); @@ -1090,7 +1097,7 @@ QColorShower::QColorShower(QColorDialog *parent) // In S60, due to small screen and different screen layouts need to re-arrange the widgets. // For QVGA screens only the comboboxes and color label are visible. // For nHD screens only color and luminence pickers and color label are visible. -#ifndef Q_WS_S60 +#if !defined(QT_SMALL_COLORDIALOG) gl->addWidget(lab, 0, 0, -1, 1); #else if (nonTouchUI) @@ -1108,7 +1115,7 @@ QColorShower::QColorShower(QColorDialog *parent) lblHue->setBuddy(hEd); #endif lblHue->setAlignment(Qt::AlignRight|Qt::AlignVCenter); -#ifndef Q_WS_S60 +#if !defined(QT_SMALL_COLORDIALOG) gl->addWidget(lblHue, 0, 1); gl->addWidget(hEd, 0, 2); #else @@ -1127,7 +1134,7 @@ QColorShower::QColorShower(QColorDialog *parent) lblSat->setBuddy(sEd); #endif lblSat->setAlignment(Qt::AlignRight|Qt::AlignVCenter); -#ifndef Q_WS_S60 +#if !defined(QT_SMALL_COLORDIALOG) gl->addWidget(lblSat, 1, 1); gl->addWidget(sEd, 1, 2); #else @@ -1146,7 +1153,7 @@ QColorShower::QColorShower(QColorDialog *parent) lblVal->setBuddy(vEd); #endif lblVal->setAlignment(Qt::AlignRight|Qt::AlignVCenter); -#ifndef Q_WS_S60 +#if !defined(QT_SMALL_COLORDIALOG) gl->addWidget(lblVal, 2, 1); gl->addWidget(vEd, 2, 2); #else @@ -1165,7 +1172,7 @@ QColorShower::QColorShower(QColorDialog *parent) lblRed->setBuddy(rEd); #endif lblRed->setAlignment(Qt::AlignRight|Qt::AlignVCenter); -#ifndef Q_WS_S60 +#if !defined(QT_SMALL_COLORDIALOG) gl->addWidget(lblRed, 0, 3); gl->addWidget(rEd, 0, 4); #else @@ -1184,7 +1191,7 @@ QColorShower::QColorShower(QColorDialog *parent) lblGreen->setBuddy(gEd); #endif lblGreen->setAlignment(Qt::AlignRight|Qt::AlignVCenter); -#ifndef Q_WS_S60 +#if !defined(QT_SMALL_COLORDIALOG) gl->addWidget(lblGreen, 1, 3); gl->addWidget(gEd, 1, 4); #else @@ -1203,7 +1210,7 @@ QColorShower::QColorShower(QColorDialog *parent) lblBlue->setBuddy(bEd); #endif lblBlue->setAlignment(Qt::AlignRight|Qt::AlignVCenter); -#ifndef Q_WS_S60 +#if !defined(QT_SMALL_COLORDIALOG) gl->addWidget(lblBlue, 2, 3); gl->addWidget(bEd, 2, 4); #else @@ -1222,7 +1229,7 @@ QColorShower::QColorShower(QColorDialog *parent) alphaLab->setBuddy(alphaEd); #endif alphaLab->setAlignment(Qt::AlignRight|Qt::AlignVCenter); -#ifndef Q_WS_S60 +#if !defined(QT_SMALL_COLORDIALOG) gl->addWidget(alphaLab, 3, 1, 1, 3); gl->addWidget(alphaEd, 3, 4); #else @@ -1467,7 +1474,7 @@ void QColorDialogPrivate::init(const QColor &initial) leftLay = 0; -#if (defined(Q_WS_WINCE) || defined(Q_WS_S60)) +#if defined(Q_WS_WINCE) || defined(QT_SMALL_COLORDIALOG) smallDisplay = true; const int lumSpace = 20; #else @@ -1497,9 +1504,13 @@ void QColorDialogPrivate::init(const QColor &initial) } #endif -#if defined(Q_WS_S60) +#if defined(QT_SMALL_COLORDIALOG) +# if defined(Q_WS_S60) QS60Data s60Data = QS60Data(); const bool nonTouchUI = !s60Data.hasTouchscreen; +# elif defined(Q_WS_MAEMO_5) + const bool nonTouchUI = false; +# endif #endif if (!smallDisplay) { @@ -1532,7 +1543,7 @@ void QColorDialogPrivate::init(const QColor &initial) leftLay->addWidget(addCusBt); } else { // better color picker size for small displays -#ifdef Q_WS_S60 +#if defined(QT_SMALL_COLORDIALOG) QSize screenSize = QApplication::desktop()->availableGeometry(QCursor::pos()).size(); pWidth = pHeight = qMin(screenSize.width(), screenSize.height()); pHeight -= 20; @@ -1558,7 +1569,7 @@ void QColorDialogPrivate::init(const QColor &initial) cp->setFrameStyle(QFrame::Panel + QFrame::Sunken); -#if defined(Q_WS_S60) +#if defined(QT_SMALL_COLORDIALOG) if (!nonTouchUI) { pickLay->addWidget(cp); cLay->addSpacing(lumSpace); @@ -1572,7 +1583,7 @@ void QColorDialogPrivate::init(const QColor &initial) cLay->addSpacing(lumSpace); lp = new QColorLuminancePicker(q); -#if defined(Q_WS_S60) +#if defined(QT_SMALL_COLORDIALOG) QSize screenSize = QApplication::desktop()->availableGeometry(QCursor::pos()).size(); const int minDimension = qMin(screenSize.height(), screenSize.width()); //set picker to be finger-usable @@ -1596,7 +1607,7 @@ void QColorDialogPrivate::init(const QColor &initial) QObject::connect(cs, SIGNAL(newCol(QRgb)), q, SLOT(_q_newColorTypedIn(QRgb))); QObject::connect(cs, SIGNAL(currentColorChanged(QColor)), q, SIGNAL(currentColorChanged(QColor))); -#if defined(Q_WS_S60) +#if defined(QT_SMALL_COLORDIALOG) if (!nonTouchUI) pWidth -= cp->size().width(); topLay->addWidget(cs); -- cgit v0.12 From 7d8c3cb2e531ce6df8d14096b0b3d31f517e767a Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Tue, 19 Jan 2010 10:43:43 +0100 Subject: another attempt at fixing the translations build make qmake generate proper dependencies on lrelease in vcproj/sln files --- translations/translations.pri | 8 ++++++-- translations/translations.pro | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/translations/translations.pri b/translations/translations.pri index 7a24a4f..8896654 100644 --- a/translations/translations.pri +++ b/translations/translations.pri @@ -8,8 +8,12 @@ defineReplace(prependAll) { return ($$result) } -LUPDATE = $$QT_BUILD_TREE/bin/lupdate -locations relative -no-ui-lines -LUPDATE ~= s,/,$$QMAKE_DIR_SEP, +LUPDATE = $$QT_BUILD_TREE/bin/lupdate +win32 { + LUPDATE ~= s,/,$$QMAKE_DIR_SEP, + LUPDATE = $${LUPDATE}.exe +} +LUPDATE += -locations relative -no-ui-lines ###### Qt Libraries diff --git a/translations/translations.pro b/translations/translations.pro index 05dd968..f1b9c99 100644 --- a/translations/translations.pro +++ b/translations/translations.pro @@ -1,7 +1,10 @@ TRANSLATIONS = $$files(*.ts) LRELEASE = $$QT_BUILD_TREE/bin/lrelease -LRELEASE ~= s,/,$$QMAKE_DIR_SEP, +win32 { + LRELEASE ~= s,/,$$QMAKE_DIR_SEP, + LRELEASE = $${LRELEASE}.exe +} contains(TEMPLATE_PREFIX, vc):vcproj = 1 @@ -14,7 +17,8 @@ LIBS = updateqm.input = TRANSLATIONS updateqm.output = ${QMAKE_FILE_BASE}.qm isEmpty(vcproj):updateqm.variable_out = PRE_TARGETDEPS -updateqm.commands = @echo lrelease ${QMAKE_FILE_IN} && $$LRELEASE ${QMAKE_FILE_IN} -qm ${QMAKE_FILE_OUT} +updateqm.commands = $$LRELEASE ${QMAKE_FILE_IN} -qm ${QMAKE_FILE_OUT} +silent:updateqm.commands = @echo lrelease ${QMAKE_FILE_IN} && $$updateqm.commands updateqm.name = LRELEASE ${QMAKE_FILE_IN} updateqm.CONFIG += no_link QMAKE_EXTRA_COMPILERS += updateqm -- cgit v0.12 From ed5fed36f38b9de0452cc427db679266d249f216 Mon Sep 17 00:00:00 2001 From: Kent Hansen Date: Tue, 19 Jan 2010 11:16:36 +0100 Subject: Remove QtScript connection when receiver QObject has been deleted We don't want to have to listen to the destroyed() signal for every receiver object of a connection, and likewise we don't want to create a QObject to handle each connection; instead, remove the connection lazily at signal emission time after we've detected that the receiver has been deleted. Task-number: QTBUG-7313 Reviewed-by: Simon Hausmann --- src/script/bridge/qscriptqobject.cpp | 9 ++++++++- .../qscriptextqobject/tst_qscriptextqobject.cpp | 23 ++++++++++++++++++++++ 2 files changed, 31 insertions(+), 1 deletion(-) diff --git a/src/script/bridge/qscriptqobject.cpp b/src/script/bridge/qscriptqobject.cpp index 3f4f6bb..db312bc 100644 --- a/src/script/bridge/qscriptqobject.cpp +++ b/src/script/bridge/qscriptqobject.cpp @@ -2220,7 +2220,14 @@ void QObjectConnectionManager::execute(int slotIndex, void **argv) JSC::call(exec, slot, callType, callData, thisObject, jscArgs); if (exec->hadException()) { - engine->emitSignalHandlerException(); + if (slot.inherits(&QtFunction::info) && !static_cast(JSC::asObject(slot))->qobject()) { + // The function threw an error because the target QObject has been deleted. + // The connections list is stale; remove the signal handler and ignore the exception. + removeSignalHandler(sender(), signalIndex, receiver, slot); + exec->clearException(); + } else { + engine->emitSignalHandlerException(); + } } } diff --git a/tests/auto/qscriptextqobject/tst_qscriptextqobject.cpp b/tests/auto/qscriptextqobject/tst_qscriptextqobject.cpp index de9d37e..b4ce561 100644 --- a/tests/auto/qscriptextqobject/tst_qscriptextqobject.cpp +++ b/tests/auto/qscriptextqobject/tst_qscriptextqobject.cpp @@ -532,6 +532,7 @@ private slots: void prototypes(); void objectDeleted(); void connectToDestroyedSignal(); + void emitAfterReceiverDeleted(); private: QScriptEngine *m_engine; @@ -3020,5 +3021,27 @@ void tst_QScriptExtQObject::connectToDestroyedSignal() #endif } +void tst_QScriptExtQObject::emitAfterReceiverDeleted() +{ + for (int x = 0; x < 2; ++x) { + MyQObject *obj = new MyQObject; + QScriptValue scriptObj = m_engine->newQObject(obj); + if (x == 0) { + // Connecting from JS + m_engine->globalObject().setProperty("obj", scriptObj); + QVERIFY(m_engine->evaluate("myObject.mySignal.connect(obj, 'mySlot()')").isUndefined()); + } else { + // Connecting from C++ + qScriptConnect(m_myObject, SIGNAL(mySignal()), scriptObj, scriptObj.property("mySlot")); + } + delete obj; + QSignalSpy signalHandlerExceptionSpy(m_engine, SIGNAL(signalHandlerException(QScriptValue))); + QVERIFY(!m_engine->hasUncaughtException()); + m_myObject->emitMySignal(); + QCOMPARE(signalHandlerExceptionSpy.count(), 0); + QVERIFY(!m_engine->hasUncaughtException()); + } +} + QTEST_MAIN(tst_QScriptExtQObject) #include "tst_qscriptextqobject.moc" -- cgit v0.12 From 26a0d799cd6e987666228afa9cfe017d226c4fdd Mon Sep 17 00:00:00 2001 From: Markus Goetz Date: Tue, 19 Jan 2010 10:25:53 +0100 Subject: QNativeSocketEngine windows: Fix performance degredation in write() We had an hack in the code that chunked writes. Try to avoid this since the hack is probably only needed for older windows versions. Task-number: QTBUG-7344 Reviewed-by: Peter Hartmann --- src/network/socket/qnativesocketengine_win.cpp | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/network/socket/qnativesocketengine_win.cpp b/src/network/socket/qnativesocketengine_win.cpp index 81bffd9..8257545 100644 --- a/src/network/socket/qnativesocketengine_win.cpp +++ b/src/network/socket/qnativesocketengine_win.cpp @@ -994,9 +994,9 @@ qint64 QNativeSocketEnginePrivate::nativeWrite(const char *data, qint64 len) { Q_Q(QNativeSocketEngine); qint64 ret = 0; - // don't send more than 49152 per call to WSASendTo to avoid getting a WSAENOBUFS + qint64 bytesToSend = len; + for (;;) { - qint64 bytesToSend = qMin(49152, len - ret); WSABUF buf; buf.buf = (char*)data + ret; buf.len = bytesToSend; @@ -1014,6 +1014,12 @@ qint64 QNativeSocketEnginePrivate::nativeWrite(const char *data, qint64 len) continue; } else if (WSAGetLastError() == WSAEWOULDBLOCK) { break; + } else if (WSAGetLastError() == WSAENOBUFS) { + // this function used to not send more than 49152 per call to WSASendTo + // to avoid getting a WSAENOBUFS. However this is a performance regression + // and we think it only appears with old windows versions. We now handle the + // WSAENOBUFS and hope it never appears anyway. + // just go on, the next loop run we will try a smaller number } else { int err = WSAGetLastError(); WS_ERROR_DEBUG(err); @@ -1029,6 +1035,9 @@ qint64 QNativeSocketEnginePrivate::nativeWrite(const char *data, qint64 len) } break; } + + // for next send: + bytesToSend = qMin(49152, len - ret); } #if defined (QNATIVESOCKETENGINE_DEBUG) -- cgit v0.12 From 001549276ac554e57d90c0c30130b7796ae69419 Mon Sep 17 00:00:00 2001 From: Thomas Zander Date: Tue, 19 Jan 2010 11:54:00 +0100 Subject: Fix Typo Reviewed-by: Alan Alpert --- doc/src/snippets/qstring/main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/src/snippets/qstring/main.cpp b/doc/src/snippets/qstring/main.cpp index 629586e..3be504c 100644 --- a/doc/src/snippets/qstring/main.cpp +++ b/doc/src/snippets/qstring/main.cpp @@ -802,7 +802,7 @@ void Widget::toLowerFunction() { //! [75] QString str = "Qt by NOKIA"; - str = str.toLower(); // str == "qy by nokia" + str = str.toLower(); // str == "qt by nokia" //! [75] } -- cgit v0.12 From 5f81705a5db458d944f22d1162c0e9a772d75c19 Mon Sep 17 00:00:00 2001 From: Tom Cooksey Date: Tue, 19 Jan 2010 12:56:49 +0100 Subject: Fix X11/EGL builds using OpenGL ES 1.1 Task-number: QTBUG-7399 Reviewed-By: TrustMe --- src/opengl/qpixmapdata_x11gl_egl.cpp | 51 +++++++++++++++++++++++++++++++----- 1 file changed, 45 insertions(+), 6 deletions(-) diff --git a/src/opengl/qpixmapdata_x11gl_egl.cpp b/src/opengl/qpixmapdata_x11gl_egl.cpp index a5e0239..55aa1d0 100644 --- a/src/opengl/qpixmapdata_x11gl_egl.cpp +++ b/src/opengl/qpixmapdata_x11gl_egl.cpp @@ -39,10 +39,19 @@ ** ****************************************************************************/ +#include + #include #include #include + +#if !defined(QT_OPENGL_ES_1) && !defined(QT_OPENGL_ES_1_CL) #include +#endif + +#ifndef QT_OPENGL_ES_2 +#include +#endif #include "qpixmapdata_x11gl_p.h" @@ -187,7 +196,14 @@ QX11GLPixmapData::~QX11GLPixmapData() { } -static QGL2PaintEngineEx* qt_gl2_engine_for_pixmaps = 0; +#if !defined(QT_OPENGL_ES_1) && !defined(QT_OPENGL_ES_1_CL) +Q_GLOBAL_STATIC(QGL2PaintEngineEx, qt_gl_pixmap_2_engine) +#endif + +#ifndef QT_OPENGL_ES_2 +Q_GLOBAL_STATIC(QOpenGLPaintEngine, qt_gl_pixmap_engine) +#endif + QPaintEngine* QX11GLPixmapData::paintEngine() const { @@ -202,18 +218,41 @@ QPaintEngine* QX11GLPixmapData::paintEngine() const : qPixmapRGBSharedEglContext); } - if (!qt_gl2_engine_for_pixmaps) - qt_gl2_engine_for_pixmaps = new QGL2PaintEngineEx(); + QPaintEngine* engine; + +#if defined(QT_OPENGL_ES_1) || defined(QT_OPENGL_ES_1_CL) + engine = qt_gl_pixmap_engine(); +#elif defined(QT_OPENGL_ES_2) + engine = qt_gl_pixmap_2_engine(); +#else + if (qt_gl_preferGL2Engine()) + engine = qt_gl_pixmap_2_engine(); + else + engine = qt_gl_pixmap_engine(); +#endif + + // Support multiple painters on multiple pixmaps simultaniously - if (qt_gl2_engine_for_pixmaps->isActive()) { + if (engine->isActive()) { qWarning("Pixmap paint engine already active"); - QPaintEngine* engine = new QGL2PaintEngineEx(); + +#if defined(QT_OPENGL_ES_1) || defined(QT_OPENGL_ES_1_CL) + engine = new QOpenGLPaintEngine; +#elif defined(QT_OPENGL_ES_2) + engine = new QGL2PaintEngineEx; +#else + if (qt_gl_preferGL2Engine()) + engine = new QGL2PaintEngineEx; + else + engine = new QOpenGLPaintEngine; +#endif + engine->setAutoDestruct(true); return engine; } - return qt_gl2_engine_for_pixmaps; + return engine; } void QX11GLPixmapData::beginPaint() -- cgit v0.12 From 00b3098906dd7d4cfe7be3448e4eb90506d27012 Mon Sep 17 00:00:00 2001 From: Prasanth Ullattil Date: Tue, 19 Jan 2010 12:49:12 +0100 Subject: Designer crashes when previewing QMainWindow with native Toolbar on Mac The crash happens when a QMainWindow with a native toolbar is reparented. While re-parenting, the QToolBar triggers a new setParent() with the MacWindowToolBarButtonHint. This messes up the internal state, hence the crash. To avoid re-entering setParent() for the QMainWindow, this hint is set depending on the unifiedTitleAndToolBarOnMac property. This patch also fixes a related issue in Cocoa, we need to remove the reused NSToolbar from the old window while recreating the QMainWindow. Task-number: QTBUG-7162 Reviewed-by: Richard Moe Gustavsen --- src/gui/kernel/qwidget_mac.mm | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/gui/kernel/qwidget_mac.mm b/src/gui/kernel/qwidget_mac.mm index 354a666..b18830f 100644 --- a/src/gui/kernel/qwidget_mac.mm +++ b/src/gui/kernel/qwidget_mac.mm @@ -110,6 +110,7 @@ #include "qevent_p.h" #include "qdnd_p.h" #include +#include "qmainwindow.h" QT_BEGIN_NAMESPACE @@ -1721,6 +1722,15 @@ bool QWidgetPrivate::qt_widget_rgn(QWidget *widget, short wcode, RgnHandle rgn, void QWidgetPrivate::determineWindowClass() { Q_Q(QWidget); +#if !defined(QT_NO_MAINWINDOW) && !defined(QT_NO_TOOLBAR) + // Make sure that QMainWindow has the MacWindowToolBarButtonHint when the + // unifiedTitleAndToolBarOnMac property is ON. This is to avoid reentry of + // setParent() triggered by the QToolBar::event(QEvent::ParentChange). + QMainWindow *mainWindow = qobject_cast(q); + if (mainWindow && mainWindow->unifiedTitleAndToolBarOnMac()) { + data.window_flags |= Qt::MacWindowToolBarButtonHint; + } +#endif #ifndef QT_MAC_USE_COCOA // ### COCOA:Interleave these better! @@ -2743,7 +2753,9 @@ void QWidgetPrivate::setParent_sys(QWidget *parent, Qt::WindowFlags f) } if (wasWindow) { oldToolbar = [oldWindow toolbar]; + [oldToolbar retain]; oldToolbarVisible = [oldToolbar isVisible]; + [oldWindow setToolbar:nil]; } #endif } @@ -2787,6 +2799,7 @@ void QWidgetPrivate::setParent_sys(QWidget *parent, Qt::WindowFlags f) if (oldToolbar && !(f & Qt::FramelessWindowHint)) { OSWindowRef newWindow = qt_mac_window_for(q); [newWindow setToolbar:oldToolbar]; + [oldToolbar release]; [oldToolbar setVisible:oldToolbarVisible]; } #endif -- cgit v0.12 From 57473d5d2a7bd6ae3117f61ff29264a1b790bb01 Mon Sep 17 00:00:00 2001 From: Gunnar Sletta Date: Tue, 19 Jan 2010 15:08:01 +0100 Subject: Fixed y-inverted pixmaps on N900. The QGLPixmapData used default bind options, which means that the pixmap is always flipped up-side-down and rendered with flipping. The opaque pixmaps were uploaded unflipped which caused the bug. Ideally we do not want pixmap flipping so change the default in gl pixmaps and tag it accordingly. Reviewed-by: Samuel --- src/opengl/qpixmapdata_gl.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/opengl/qpixmapdata_gl.cpp b/src/opengl/qpixmapdata_gl.cpp index 1bfb6e3..6d47687 100644 --- a/src/opengl/qpixmapdata_gl.cpp +++ b/src/opengl/qpixmapdata_gl.cpp @@ -252,6 +252,10 @@ QGLPixmapData::QGLPixmapData(PixelType type) { setSerialNumber(++qt_gl_pixmap_serial); m_glDevice.setPixmapData(this); + + // Set InteralBindOptions minus the memory managed, since this + // QGLTexture is not managed as part of the internal texture cache + m_texture.options = QGLContext::PremultipliedAlphaBindOption; } QGLPixmapData::~QGLPixmapData() @@ -340,18 +344,18 @@ void QGLPixmapData::ensureCreated() const } if (!m_source.isNull()) { + glBindTexture(target, m_texture.id); if (external_format == GL_RGB) { const QImage tx = m_source.convertToFormat(QImage::Format_RGB888); - - glBindTexture(target, m_texture.id); glTexSubImage2D(target, 0, 0, 0, w, h, external_format, GL_UNSIGNED_BYTE, tx.bits()); } else { const QImage tx = ctx->d_func()->convertToGLFormat(m_source, true, external_format); - - glBindTexture(target, m_texture.id); glTexSubImage2D(target, 0, 0, 0, w, h, external_format, GL_UNSIGNED_BYTE, tx.bits()); + // convertToGLFormat will flip the Y axis, so it needs to + // be drawn upside down + m_texture.options |= QGLContext::InvertedYBindOption; } if (useFramebufferObjects()) -- cgit v0.12 From 417cc9c0724bd9f2170648175dd9461813c9bfe5 Mon Sep 17 00:00:00 2001 From: Jason McDonald Date: Wed, 20 Jan 2010 00:19:29 +1000 Subject: Add released version of 4.6.1 changes file for posterity. Reviewed-by: Trust Me --- dist/changes-4.6.1 | 261 +++++++++++++++++++++-------------------------------- 1 file changed, 104 insertions(+), 157 deletions(-) diff --git a/dist/changes-4.6.1 b/dist/changes-4.6.1 index 6e95fd5..3df6887 100644 --- a/dist/changes-4.6.1 +++ b/dist/changes-4.6.1 @@ -20,12 +20,6 @@ Merge Request: http://qt.gitorious.org * General * **************************************************************************** -New features ------------- - - - SomeClass, SomeOtherClass - * New classes for foo, bar and baz - Optimizations ------------- @@ -44,8 +38,8 @@ QtCore - QFile * Improve performance of getting the canonical filename on Linux - and Symbian by using realpath() system call - * Avoid stat() when opening a file + and Symbian by using realpath() system call. + * Avoid stat() when opening a file. - QLibrary and QPluginLoader * Do not look at the Qt patch-level version embedded in plugins' @@ -60,7 +54,7 @@ QtCore - QXmlStreamreader * [merge request 1926] Fix parsing of DTDs that contain empty markup - declarations + declarations. QtGui ----- @@ -68,32 +62,21 @@ QtGui - QApplication * [QTBUG-6654] Fix crashes when deleting QWidgets in touch event handlers. - - QPixmapCache - * Fixed a small leak when using the new QPixmapCAche::Key based API. - - QPixmap - * load() and loadFromData() can now support compressed GL textures - in the DDS, ETC1, PVRTC2, and PVRTC4 formats if the OpenGL graphics - system is active and the appropriate extensions are present in the - GL implementation. - * [QTBUG-6840] Fixed load() to not modify referenced copies. - * [QTBUG-5840] Fixed a crash in fromImage() when passing in a null image. - * [QTBUG-6116] Fixed memory leak where a global object was not destroyed - at program exit. - - QRasterPixmapData - * [QTBUG-6985] Fixed metric() to return the correct height in mm. - - QGraphicsObject - * 'id' property was removed. Use the 'objectName' property instead. - - QPrinter - * [QTBUG-3412] QGraphicsProxyWidgets are now rendered correctly when - printing a QGraphicsScene to PDF format. - - QPainter - * [QTBUG-5939] Fixed incorrect redirection matrix that was causing - wrong transformation for QGraphicsProxyWidgets. - * [QTBUG-6684] Added optimizations of 32-bit blend functions - for ARM platforms with NEON support. - QGraphicsEffect * [QTBUG-5918] Fixed redraw bugs when using graphics effects on items while animating them by transformations. + - QGraphicsItem + * [QTBUG-5917] Fixed memory leaks when removing a QGraphicsEffect from + a QGraphicsItem or QWidget with setGraphicsEffect(0). + * [QTBUG-5859] Fixes incorrect rounding of the exposed rectangle of the + QGraphicsItem causing painting issues when scaling the QGraphicsView. + * [QTBUG-5071] Fixes transformation problems when grouping/ungrouping + the item with a QGraphicsItemGroup. + - QGraphicsObject + * 'id' property was removed. Use the 'objectName' property instead. + - QGraphicsScene + * [QTBUG-6654] Fix crashes when deleting QGraphicsItems in touch + event handlers. - QGraphicsView * [QTBUG-6935] When using CacheBackground, the background is now correctly repainted after the QGraphicsView is shown after being @@ -101,29 +84,37 @@ QtGui * [QTBUG-6835] Mouse tracking is now automatically enabled when using AnchorUnderMouse for view transformation. * [QTBUG-6958] Fix speed regression in _q_polishItems() - * [QTBUG-6544] Fix a crash on the focus chain when removing items from the scene. + * [QTBUG-6544] Fix a crash on the focus chain when removing items from + the scene. * Fix a crash in KDE/Plasma with QGraphicsView with topLevels. - - QGraphicsItem - * [QTBUG-5917] Fixed memory leaks when removing a QGraphicsEffect from - a QGraphicsItem or QWidget with setGraphicsEffect(0). - * [QTBUG-5859] Fixes incorrect rounding of the exposed rectangle of the - QGraphicsItem causing painting issues when scaling the QGraphicsView. - * [QTBUG-5071] Fixes transformation problems when grouping/ungrouping - the item with a QGraphicsItemGroup. - QGraphicsWidget - * [QTBUG-6272] Only call updateFont if the font have changed. + * [QTBUG-6272] Only call updateFont if the font has changed. + - QPainter + * [QTBUG-5939] Fixed incorrect redirection matrix that was causing + wrong transformation for QGraphicsProxyWidgets. + * [QTBUG-6684] Added optimizations of 32-bit blend functions + for ARM platforms with NEON support. + - QPixmap + * load() and loadFromData() can now support compressed GL textures + in the DDS, ETC1, PVRTC2, and PVRTC4 formats if the OpenGL graphics + system is active and the appropriate extensions are present in the + GL implementation. + * [QTBUG-6840] Fixed load() to not modify referenced copies. + * [QTBUG-5840] Fixed a crash in fromImage() when passing in a null image. + * [QTBUG-6116] Fixed memory leak where a global object was not destroyed + at program exit. + - QPixmapCache + * Fixed a small leak when using the new QPixmapCache::Key based API. + - QPrinter + * [QTBUG-3412] QGraphicsProxyWidgets are now rendered correctly when + printing a QGraphicsScene to PDF format. + - QRasterPixmapData + * [QTBUG-6985] Fixed metric() to return the correct height in mm. - QTextDocument * [QTBUG-5397] Fixed printing of QTextDocuments not including custom text objects. - - - QTextDocument * [QTBUG-6051] Fixed an endless loop when printing a QTextDocument. - - QGraphicsScene - * [QTBUG-6654] Fix crashes when deleting QGraphicsItems in touch - event handlers. - - QtDBus ------ @@ -132,49 +123,54 @@ QtDBus correctly when the sender name changes/appears on the bus. * [QTBUG-7041] Fixed marshalling of booleans in release mode. * [QT-2307] Fixed calls with the QDBus::BlockWithGui mode. - - QDBusInterface * Made it continue working even when the remote object introspection fails. - - QDBusInterface and qdbuscpp2xml * [QTBUG-5563] Fixed an issue with generating annotations in - signals - + signals. - QDBusPendingReply and QDBusReply * [QTBUG-6571] Fixed a crash that would happen if you tried to - make a call with a disconnected QDBusConnection + make a call with a disconnected QDBusConnection. QtMultimedia ------------ - QAudioOutput * [Merge request 418] Fixed compilation the example provided for - QAudioOutput::start + QAudioOutput::start. QtNetwork --------- - QNetworkAccessManager - * HTTP: Smaller improvements - * HTTP: Send our locale with the HTTP request - * HTTP: Start Accept-language and Authorization header with capital letter - * HTTP: Fix caching algorithm, matching RFC 2612 and the documentation - * HTTP [QTBUG-7060]: Fix an issue with headers like "private, max-age=300" - * file: Introduce special subclass for higher performance with file:// URLs + * HTTP: Send our locale with the HTTP request. + * HTTP: Start Accept-language and Authorization header with capital letter. + * HTTP: Fix caching algorithm, matching RFC 2612 and the documentation. + * HTTP [QTBUG-7060]: Fix an issue with headers like "private, max-age=300". + * file: Introduce special subclass for higher performance with file:// URLs. - QTcpSocket - * [QTBUG-5799] Fix waitForConnected() on Windows + * [QTBUG-5799] Fix waitForConnected() on Windows. - QNetworkProxyFactory * Fixed systemProxyForQuery(), it could sometimes return invalid empty list - on Windows + on Windows. - QNetworkCookieJar - * [QTBUG-5815] do not check paths when accepting cookies + * [QTBUG-5815] Do not check paths when accepting cookies. - QHostInfo - * Use 5 parallel threads for host lookup instead of 1 + * Use five parallel threads for host lookup instead of one. QtOpenGL -------- + - QGL2PaintEngineEx + * Performance: Don't mark brush as dirty if it hasn't changed. + * Performance: Use 3x3 PMV matrices rather than 4x4. + * Performance: Move the 0.5 offset we add for aliased rendering to + updateMatrix(). + * Performance: Remove superfluous enable/disable vertex attrib arrays. + * Performance: Track the glVertexAttribPointer and only update it if it's + changed. + * [QTBUG-7094] Introduce new "snapToPixelGrid" flag for drawText. - QGLContext * bindTexture(QString) now supports DDS, ETC1, PVRTC2, and PVRTC4 compressed textures if the appropriate extensions are present @@ -187,31 +183,24 @@ QtOpenGL * bindTexture(QImage): Fix GL_BGRA formats under OpenGL/ES by using the same value for both internal and external texture formats. * [QTBUG-5041] Disable depth testing while in renderText(). - - QGLPaintDevice - * [QTBUG-6204] Rebind window surface fbo after native GL rendering. - QGLEngineSelector * [QTBUG-5638] Detect GL2 based on fragment shaders, not programs. Fragment programs are a GL1 feature. - QGLFramebufferObject * [QTBUG-6712] Update docs to better explain how QPainter changes the GL state when used on an FBO. - - QGLPixmapData - * [QTBUG-6902] Align GL_RGB data on a 4-byte line boundary. - - QTriangulatingStroker - * [QTBUG-6045] Crash in dashed line handling in the GL stroker. - QGLGlyphCache * [QTBUG-6936] Fix memory leak of QGLGlyphCoord objects. + - QGLPaintDevice + * [QTBUG-6204] Rebind window surface FBO after native GL rendering. + - QGLPixmapData + * [QTBUG-6902] Align GL_RGB data on a 4-byte line boundary. - QGLWidget * [QTBUG-5002, QTBUG-6931] Fixed QGLWidget::renderText(). - * Fixed WA_TranslucentBackground for QGLWidgets on X11/EGL - * Fix EGL surface leaks when re-parenting on X11/EGL - - QGL2PaintEngineEx - * Performance: Don't mark brush as dirty if it hasn't changed - * Performance: Use 3x3 PMV matrices rather than 4x4 - * Performance: Move the 0.5 offset we add for aliased rendering to updateMatrix() - * Performance: Remove superfluous enable/disable vertex arrtib arrays - * Performance: Track the glVertexAttribPointer and only update it if it's changed - * [QTBUG-7094] Introduce new "snapToPixelGrid" flag for drawText + * Fixed WA_TranslucentBackground for QGLWidgets on X11/EGL. + * Fix EGL surface leaks when re-parenting on X11/EGL. + - QTriangulatingStroker + * [QTBUG-6045] Crash in dashed line handling in the GL stroker. QtOpenVG -------- @@ -227,32 +216,29 @@ QtOpenVG QtWebKit -------- - - Fixed user agent string on Symbian (webkit.org/b/31961) - - QWebInspector: Don't disable when hiding (webkit.org/b/31851) - - Fix JavaScript prompt behaviour for empty/null strings (webkit.org/b/30914) - - Fixed lastIndexOf() on Symbian (webkit.org/b/31773) - - Fixed crash with Flash on Windows with MinGW - - Fixed wrapping of QObjects with recurring identity (webkit.org/b/31681) - - Fixed compilation with ICC - - Fixed assertion when dragging SVG images (webkit.org/b/32511) - - Fixed crash with ACID3 test on Symbian - - Fixed security issue XSL stylesheets and security origins. - - Added the framecapture example to the default build (merge request 2235) - -QtScript --------- - - - foo - * bar + - Fixed user agent string on Symbian (webkit.org/b/31961). + - QWebInspector: Don't disable when hiding (webkit.org/b/31851). + - Fix JavaScript prompt behaviour for empty/null strings (webkit.org/b/30914). + - Fixed lastIndexOf() on Symbian (webkit.org/b/31773). + - Fixed crash with Flash on Windows with MinGW. + - Fixed wrapping of QObjects with recurring identity (webkit.org/b/31681). + - Fixed compilation with ICC. + - Fixed assertion when dragging SVG images (webkit.org/b/32511). + - Added the framecapture example to the default build (merge request 2235) + - Fixed crash with ACID3 test on Symbian + - Fixed security issue XSL stylesheets and security origins. QtSql ----- - - [QTBUG-5373] Fixed QSqlRelationalTableModel doesn't correctly work with relation in other database schema. - - [QTBUG-5298] (OCI) Fixed QSqlDatabase.tables() does not work with system tables. - - [QTBUG-6421] Fixed setForwardOnly() for both OCI and SQLite - - [QTBUG-6618] (ODBC) Fixed segfault when error string is larger than 256 chars. - - [QTBUG-4461] (OCI) Fixed problem with clobs being handled as binary + - [QTBUG-5373] Fixed QSqlRelationalTableModel doesn't correctly work with + relation in other database schema. + - [QTBUG-5298] (OCI) Fixed QSqlDatabase.tables() does not work with system + tables. + - [QTBUG-6421] Fixed setForwardOnly() for both OCI and SQLite. + - [QTBUG-6618] (ODBC) Fixed segfault when error string is larger than 256 + chars. + - [QTBUG-4461] (OCI) Fixed problem with clobs being handled as binary. QtSvg ----- @@ -262,13 +248,6 @@ QtSvg offsets. * [QTBUG-6899] Fixed crash when parsing invalid coordinate list. - -QtXml ------ - - - foo - * bar - Qt Plugins ---------- @@ -283,13 +262,6 @@ Qt Plugins - PNG plugin * [QTBUG-7161] Avoid a deep copy of QImage::bits() in the png writer. -Third party components ----------------------- - - - Updated foo to version 2.3.9. - - - Updated bar to the latest version from baz.org. - **************************************************************************** * Platform Specific Changes * @@ -300,89 +272,70 @@ Qt for Unix (X11 and Mac OS X) - [QTBUG-6755] Ensure we don't call select(2) with a negative timeout if the timer expires during timeout recalculation. - - Added mkspecs for Sun CC that enable -library=stlport by default, to restore STL capability with that compiler. - - - [QTBUG-6576] Fixed compilation on HP-UX 11.11 - - - [QTBUG-6961] Fixed compilation on HURD + - [QTBUG-6576] Fixed compilation on HP-UX 11.11. + - [QTBUG-6961] Fixed compilation on HURD. Qt for Linux/X11 ---------------- - [QTBUG-5732] Fixed querying of GLX extensions under X11. - [QTBUG-5547] Fixed handling of the "..." button. - - Added new mkspec for Maemo targets (linux-g++-maemo) - - Added new mkspec for Scratchbox host compiler (unsupported/linux-host-g++) - + - Added new mkspec for Maemo targets (linux-g++-maemo). + - Added new mkspec for Scratchbox host compiler (unsupported/linux-host-g++). - QGuiEventDispatcherGlib (internal class) * Fix regression introduced in 4.6.0 that could cause X11 event processing to starve timer events. - - QFileSystemWatcher * [QTBUG-4840] Fix memory leak in the dnotify implementation. - - QIcon * [QTBUG-6121] Fixed a problem causing svg-based icon themes to look fuzzy. - - QGtkStyle * [QTBUG-6484] Ensure that gtk-enable-mnemonics is respected. Qt for Windows -------------- - - [QTBUG-5145] Compile fixes for win32-icc. + - [QTBUG-5145] Compile fixes for win32-icc. - QAtomicPointer * [QTBUG-6079] Fix compilation for 64-bit Windows targets. - - QEventDispatchWin32 (internal class) * [QTBUG-6083] Fix a performance regression introduced in 4.6.0 that would cause all Qt posted events to be sent at 15-16ms intervals (instead of as quickly as possible). - Vista/XP styles * [QTBUG-6271] Fixed a compatibility issue with MDI windows in - certain non-standard themes. + certain non-standard themes. Qt for Mac OS X --------------- - QPixmap * [QTBUG-5070] Fixed a crash on Mac that could occur when loading - pixmaps of different sizes into the same QPixmap object. - - [QTBUG-6973] Fixed a memory leak when using QWidget::setWindowIcon() in carbon. + pixmaps of different sizes into the same QPixmap object. + - [QTBUG-6973] Fixed a memory leak when using QWidget::setWindowIcon() in + Carbon. - [QTBUG-5186] Fixed a bug which caused drag and drop icons to show incorrectly. - - [QTBUG-6636] Fixed a crash due to stack overflow in QColorDialog on cocoa. + - [QTBUG-6636] Fixed a crash due to stack overflow in QColorDialog on Cocoa. - [QTBUG-6378] Fix a text cursor rendering bug. - - [QTBUG-6636] Fixed a crash when calling removeToolBar on Mac native toolbars using cocoa. - - [QTBUG-5613] Fixed a bug where the application refued to quit when showing a single modal dialog. - - Gestures are now available for the Carbon port also when building Qt against SDK < 10.6 - -Qt for Embedded Linux ---------------------- - - - - -DirectFB --------- - - - - -Qt for Windows CE ------------------ - - - + - [QTBUG-6636] Fixed a crash when calling removeToolBar on Mac native toolbars + using Cocoa. + - [QTBUG-5613] Fixed a bug where the application refused to quit when showing + a single modal dialog. + - Gestures are now available for the Carbon port also when building Qt against + SDK < 10.6 Qt for Symbian -------------- - QApplication * [QTBUG-6098] Added a flag to avoid construction of application panes. - - Other: * [QTBUG-4990] Rewrote most of the regular pointer handling. + **************************************************************************** * Tools * **************************************************************************** @@ -397,12 +350,6 @@ Qt for Symbian * [QTBUG-5824] Fixed code generation to generate a call to QMainWindow::setCentralWidget() for promoted widgets as well. - - qdoc3 - * bar - - - Linguist - * baz - **************************************************************************** * Important Behavior Changes * **************************************************************************** -- cgit v0.12 From e318e3985247e0be91ae4f94afef7a39ea9928c6 Mon Sep 17 00:00:00 2001 From: Alexis Menard Date: Tue, 19 Jan 2010 15:22:49 +0100 Subject: Make the qWarnings in the animation API more useful. Task-number:QTBUG-6895 Reviewed-by:Thierry --- src/corelib/animation/qpropertyanimation.cpp | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/src/corelib/animation/qpropertyanimation.cpp b/src/corelib/animation/qpropertyanimation.cpp index eec5b30..cfd7cc2 100644 --- a/src/corelib/animation/qpropertyanimation.cpp +++ b/src/corelib/animation/qpropertyanimation.cpp @@ -256,7 +256,8 @@ void QPropertyAnimation::updateState(QAbstractAnimation::State newState, Q_D(QPropertyAnimation); if (!d->target && oldState == Stopped) { - qWarning("QPropertyAnimation::updateState: Changing state of an animation without target"); + qWarning("QPropertyAnimation::updateState (%s): Changing state of an animation without target", + d->propertyName.constData()); return; } @@ -279,10 +280,16 @@ void QPropertyAnimation::updateState(QAbstractAnimation::State newState, if (oldState == Stopped) { d->setDefaultStartEndValue(d->targetValue->property(d->propertyName.constData())); //let's check if we have a start value and an end value - if (!startValue().isValid() && (d->direction == Backward || !d->defaultStartEndValue.isValid())) - qWarning("QPropertyAnimation::updateState: starting an animation without start value"); - if (!endValue().isValid() && (d->direction == Forward || !d->defaultStartEndValue.isValid())) - qWarning("QPropertyAnimation::updateState: starting an animation without end value"); + if (!startValue().isValid() && (d->direction == Backward || !d->defaultStartEndValue.isValid())) { + qWarning("QPropertyAnimation::updateState (%s, %s, %s): starting an animation without start value", + d->propertyName.constData(), d->target.data()->metaObject()->className(), + qPrintable(d->target.data()->objectName())); + } + if (!endValue().isValid() && (d->direction == Forward || !d->defaultStartEndValue.isValid())) { + qWarning("QPropertyAnimation::updateState (%s, %s, %s): starting an animation without end value", + d->propertyName.constData(), d->target.data()->metaObject()->className(), + qPrintable(d->target.data()->objectName())); + } } } else if (hash.value(key) == this) { hash.remove(key); -- cgit v0.12 From beab6d886504c011af9b973d1d0a81ce8e700e30 Mon Sep 17 00:00:00 2001 From: kh1 Date: Tue, 19 Jan 2010 15:27:13 +0100 Subject: Return some fake data if we can't handle the network request. Since we are the only handler for network request and cannot forward the request to our parent (e.g. unwanted net access), we work arround the case we can't handle it. We do create a reply with dummy data which will prevent some blocking and allows further processing of requested data. Task-number: QTBUG-7427 Reviewed-by: kh --- tools/assistant/tools/assistant/helpviewer.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/assistant/tools/assistant/helpviewer.cpp b/tools/assistant/tools/assistant/helpviewer.cpp index a9abda5..1900c7e 100644 --- a/tools/assistant/tools/assistant/helpviewer.cpp +++ b/tools/assistant/tools/assistant/helpviewer.cpp @@ -151,7 +151,8 @@ QNetworkReply *HelpNetworkAccessManager::createRequest(Operation /*op*/, mimeType = QLatin1String("text/html"); } - return new HelpNetworkReply(request, helpEngine->fileData(url), mimeType); + const QByteArray &ba = helpEngine->fileData(url); + return new HelpNetworkReply(request, ba.isEmpty() ? " " : ba, mimeType); } class HelpPage : public QWebPage -- cgit v0.12 From 0586f10054b681492b23db85a31b10fc2b6c301e Mon Sep 17 00:00:00 2001 From: Jason McDonald Date: Wed, 20 Jan 2010 01:25:53 +1000 Subject: Add skeleton changes file for 4.6.2. Reviewed-by: Trust Me --- dist/changes-4.6.2 | 159 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 159 insertions(+) create mode 100644 dist/changes-4.6.2 diff --git a/dist/changes-4.6.2 b/dist/changes-4.6.2 new file mode 100644 index 0000000..d35f945 --- /dev/null +++ b/dist/changes-4.6.2 @@ -0,0 +1,159 @@ +Qt 4.6.2 is a bug-fix release. It maintains both forward and backward +compatibility (source and binary) with Qt 4.6.0. For more details, +refer to the online documentation included in this distribution. The +documentation is also available online: + + http://qt.nokia.com/doc/4.6 + +The Qt version 4.6 series is binary compatible with the 4.5.x series. +Applications compiled for 4.5 will continue to run with 4.6. + +Some of the changes listed in this file include issue tracking numbers +corresponding to tasks in the Qt Bug Tracker, the (now obsolete) Task +Tracker, or the Merge Request queue of the public source repository. + +Qt Bug Tracker: http://bugreports.qt.nokia.com +Task Tracker: http://qt.nokia.com/developer/task-tracker +Merge Request: http://qt.gitorious.org + +**************************************************************************** +* General * +**************************************************************************** + +New features +------------ + + - SomeClass, SomeOtherClass + * New classes for foo, bar and baz + +Optimizations +------------- + + - Optimized foo in QSomeClass + * See list of Important Behavior Changes below + + +**************************************************************************** +* Library * +**************************************************************************** + +QtCore +------ + + - foo + * bar + +QtGui +----- + + - foo + * bar + +QtDBus +------ + + - foo + * bar + +QtNetwork +--------- + + - foo + * bar + +QtOpenGL +-------- + + - foo + * bar + +QtScript +-------- + + - foo + * bar + +QtSql +----- + + - foo + * bar + +QtXml +----- + + - foo + * bar + +Qt Plugins +---------- + + - foo + * bar + +Third party components +---------------------- + + - Updated foo to version 2.3.9. + + - Updated bar to the latest version from baz.org. + + +**************************************************************************** +* Platform Specific Changes * +**************************************************************************** + +Qt for Unix (X11 and Mac OS X) +------------------------------ + + - + +Qt for Linux/X11 +---------------- + + - + +Qt for Windows +-------------- + + - + +Qt for Mac OS X +--------------- + + - + +Qt for Embedded Linux +--------------------- + + - + +DirectFB +-------- + + - + +Qt for Windows CE +----------------- + + - + +**************************************************************************** +* Tools * +**************************************************************************** + + - Designer + * foo + + - qdoc3 + * bar + + - Linguist + * baz + +**************************************************************************** +* Important Behavior Changes * +**************************************************************************** + + - + -- cgit v0.12 From 71a8c4ea5049767a2a83c689fd89a4b685e62aa4 Mon Sep 17 00:00:00 2001 From: Jason McDonald Date: Wed, 20 Jan 2010 01:45:46 +1000 Subject: Bump version to 4.6.2. Reviewed-by: Trust Me --- src/corelib/global/qglobal.h | 4 ++-- src/plugins/qpluginbase.pri | 2 +- src/qbase.pri | 2 +- tests/auto/mediaobject/dummy/dummy.pro | 2 +- tests/auto/selftests/expected_cmptest.txt | 2 +- tests/auto/selftests/expected_crashes_3.txt | 2 +- tests/auto/selftests/expected_longstring.txt | 2 +- tests/auto/selftests/expected_maxwarnings.txt | 2 +- tests/auto/selftests/expected_skip.txt | 2 +- tests/auto/selftests/expected_xunit.txt | 4 ++-- tests/auto/uic/baseline/config_fromuic3.ui.h | 2 +- tools/assistant/tools/assistant/doc/assistant.qdocconf | 2 +- tools/qdoc3/test/assistant.qdocconf | 2 +- tools/qdoc3/test/designer.qdocconf | 2 +- tools/qdoc3/test/linguist.qdocconf | 2 +- tools/qdoc3/test/qmake.qdocconf | 2 +- tools/qdoc3/test/qt-build-docs.qdocconf | 6 +++--- tools/qdoc3/test/qt.qdocconf | 6 +++--- 18 files changed, 24 insertions(+), 24 deletions(-) diff --git a/src/corelib/global/qglobal.h b/src/corelib/global/qglobal.h index f350d1a..abdafc3 100644 --- a/src/corelib/global/qglobal.h +++ b/src/corelib/global/qglobal.h @@ -44,11 +44,11 @@ #include -#define QT_VERSION_STR "4.6.1" +#define QT_VERSION_STR "4.6.2" /* QT_VERSION is (major << 16) + (minor << 8) + patch. */ -#define QT_VERSION 0x040601 +#define QT_VERSION 0x040602 /* can be used like #if (QT_VERSION >= QT_VERSION_CHECK(4, 4, 0)) */ diff --git a/src/plugins/qpluginbase.pri b/src/plugins/qpluginbase.pri index b66f8f9..3af8b40 100644 --- a/src/plugins/qpluginbase.pri +++ b/src/plugins/qpluginbase.pri @@ -1,6 +1,6 @@ TEMPLATE = lib isEmpty(QT_MAJOR_VERSION) { - VERSION=4.6.1 + VERSION=4.6.2 } else { VERSION=$${QT_MAJOR_VERSION}.$${QT_MINOR_VERSION}.$${QT_PATCH_VERSION} } diff --git a/src/qbase.pri b/src/qbase.pri index d1a2a75..d9832a1 100644 --- a/src/qbase.pri +++ b/src/qbase.pri @@ -4,7 +4,7 @@ INCLUDEPATH *= $$QMAKE_INCDIR_QT/$$TARGET #just for today to have some compat isEmpty(QT_ARCH):!isEmpty(ARCH):QT_ARCH=$$ARCH #another compat that will rot for change #215700 TEMPLATE = lib isEmpty(QT_MAJOR_VERSION) { - VERSION=4.6.1 + VERSION=4.6.2 } else { VERSION=$${QT_MAJOR_VERSION}.$${QT_MINOR_VERSION}.$${QT_PATCH_VERSION} } diff --git a/tests/auto/mediaobject/dummy/dummy.pro b/tests/auto/mediaobject/dummy/dummy.pro index 5417b50..2f27c4a 100644 --- a/tests/auto/mediaobject/dummy/dummy.pro +++ b/tests/auto/mediaobject/dummy/dummy.pro @@ -1,7 +1,7 @@ TEMPLATE = lib isEmpty(QT_MAJOR_VERSION) { - VERSION=4.6.1 + VERSION=4.6.2 } else { VERSION=$${QT_MAJOR_VERSION}.$${QT_MINOR_VERSION}.$${QT_PATCH_VERSION} } diff --git a/tests/auto/selftests/expected_cmptest.txt b/tests/auto/selftests/expected_cmptest.txt index a941f21..1b65adf 100644 --- a/tests/auto/selftests/expected_cmptest.txt +++ b/tests/auto/selftests/expected_cmptest.txt @@ -1,5 +1,5 @@ ********* Start testing of tst_Cmptest ********* -Config: Using QTest library 4.6.1, Qt 4.6.1 +Config: Using QTest library 4.6.2, Qt 4.6.2 PASS : tst_Cmptest::initTestCase() PASS : tst_Cmptest::compare_boolfuncs() PASS : tst_Cmptest::compare_pointerfuncs() diff --git a/tests/auto/selftests/expected_crashes_3.txt b/tests/auto/selftests/expected_crashes_3.txt index 692fddb..aabe83d 100644 --- a/tests/auto/selftests/expected_crashes_3.txt +++ b/tests/auto/selftests/expected_crashes_3.txt @@ -1,5 +1,5 @@ ********* Start testing of tst_Crashes ********* -Config: Using QTest library 4.6.1, Qt 4.6.1 +Config: Using QTest library 4.6.2, Qt 4.6.2 PASS : tst_Crashes::initTestCase() QFATAL : tst_Crashes::crash() Received signal 11 FAIL! : tst_Crashes::crash() Received a fatal error. diff --git a/tests/auto/selftests/expected_longstring.txt b/tests/auto/selftests/expected_longstring.txt index 5755c97..3fe237a 100644 --- a/tests/auto/selftests/expected_longstring.txt +++ b/tests/auto/selftests/expected_longstring.txt @@ -1,5 +1,5 @@ ********* Start testing of tst_LongString ********* -Config: Using QTest library 4.6.1, Qt 4.6.1 +Config: Using QTest library 4.6.2, Qt 4.6.2 PASS : tst_LongString::initTestCase() FAIL! : tst_LongString::failWithLongString() Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo. Nullam dictum felis eu pede mollis pretium. Integer tincidunt. Cras dapibus. Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum. Aenean imperdiet. Etiam ultricies nisi vel augue. Curabitur ullamcorper ultricies nisi. Nam eget dui. diff --git a/tests/auto/selftests/expected_maxwarnings.txt b/tests/auto/selftests/expected_maxwarnings.txt index 032a3e8..8bafeff 100644 --- a/tests/auto/selftests/expected_maxwarnings.txt +++ b/tests/auto/selftests/expected_maxwarnings.txt @@ -1,5 +1,5 @@ ********* Start testing of MaxWarnings ********* -Config: Using QTest library 4.6.1, Qt 4.6.1 +Config: Using QTest library 4.6.2, Qt 4.6.2 PASS : MaxWarnings::initTestCase() QWARN : MaxWarnings::warn() 0 QWARN : MaxWarnings::warn() 1 diff --git a/tests/auto/selftests/expected_skip.txt b/tests/auto/selftests/expected_skip.txt index e687759..c4ef92d 100644 --- a/tests/auto/selftests/expected_skip.txt +++ b/tests/auto/selftests/expected_skip.txt @@ -1,5 +1,5 @@ ********* Start testing of tst_Skip ********* -Config: Using QTest library 4.6.1, Qt 4.6.1 +Config: Using QTest library 4.6.2, Qt 4.6.2 PASS : tst_Skip::initTestCase() SKIP : tst_Skip::test() skipping all Loc: [/home/rmcgover/depot/qt-git/mainline/tests/auto/selftests/skip/tst_skip.cpp(68)] diff --git a/tests/auto/selftests/expected_xunit.txt b/tests/auto/selftests/expected_xunit.txt index d5cd531..5ec4668 100644 --- a/tests/auto/selftests/expected_xunit.txt +++ b/tests/auto/selftests/expected_xunit.txt @@ -1,8 +1,8 @@ - - + + diff --git a/tests/auto/uic/baseline/config_fromuic3.ui.h b/tests/auto/uic/baseline/config_fromuic3.ui.h index ec20d05..93dcfb5 100644 --- a/tests/auto/uic/baseline/config_fromuic3.ui.h +++ b/tests/auto/uic/baseline/config_fromuic3.ui.h @@ -45,7 +45,7 @@ ** Form generated from reading UI file 'config_fromuic3.ui' ** ** Created: Thu Dec 17 12:48:42 2009 -** by: Qt User Interface Compiler version 4.6.1 +** by: Qt User Interface Compiler version 4.6.2 ** ** WARNING! All changes made in this file will be lost when recompiling UI file! ********************************************************************************/ diff --git a/tools/assistant/tools/assistant/doc/assistant.qdocconf b/tools/assistant/tools/assistant/doc/assistant.qdocconf index 584c3ce..b8726a4 100644 --- a/tools/assistant/tools/assistant/doc/assistant.qdocconf +++ b/tools/assistant/tools/assistant/doc/assistant.qdocconf @@ -12,5 +12,5 @@ HTML.footer = "


\n" \ "\n" \ "\n" \ "\n" \ - "\n" \ + "\n" \ "
Copyright © 2010 Nokia Corporation and/or its subsidiary(-ies)Trademarks
Qt 4.6.1
Qt 4.6.2
" diff --git a/tools/qdoc3/test/assistant.qdocconf b/tools/qdoc3/test/assistant.qdocconf index adca7b4..38da552 100644 --- a/tools/qdoc3/test/assistant.qdocconf +++ b/tools/qdoc3/test/assistant.qdocconf @@ -17,7 +17,7 @@ qhp.Assistant.namespace = com.trolltech.assistant.460 qhp.Assistant.virtualFolder = qdoc qhp.Assistant.indexTitle = Qt Assistant Manual qhp.Assistant.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png -qhp.Assistant.filterAttributes = qt 4.6.1 tools assistant +qhp.Assistant.filterAttributes = qt 4.6.2 tools assistant qhp.Assistant.customFilters.Assistant.name = Qt Assistant Manual qhp.Assistant.customFilters.Assistant.filterAttributes = qt tools assistant qhp.Assistant.subprojects = manual examples diff --git a/tools/qdoc3/test/designer.qdocconf b/tools/qdoc3/test/designer.qdocconf index d30ade9..57d21a9 100644 --- a/tools/qdoc3/test/designer.qdocconf +++ b/tools/qdoc3/test/designer.qdocconf @@ -17,7 +17,7 @@ qhp.Designer.namespace = com.trolltech.designer.460 qhp.Designer.virtualFolder = qdoc qhp.Designer.indexTitle = Qt Designer Manual qhp.Designer.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png -qhp.Designer.filterAttributes = qt 4.6.1 tools designer +qhp.Designer.filterAttributes = qt 4.6.2 tools designer qhp.Designer.customFilters.Designer.name = Qt Designer Manual qhp.Designer.customFilters.Designer.filterAttributes = qt tools designer qhp.Designer.subprojects = manual examples diff --git a/tools/qdoc3/test/linguist.qdocconf b/tools/qdoc3/test/linguist.qdocconf index f06671b..5860b33 100644 --- a/tools/qdoc3/test/linguist.qdocconf +++ b/tools/qdoc3/test/linguist.qdocconf @@ -17,7 +17,7 @@ qhp.Linguist.namespace = com.trolltech.linguist.460 qhp.Linguist.virtualFolder = qdoc qhp.Linguist.indexTitle = Qt Linguist Manual qhp.Linguist.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png -qhp.Linguist.filterAttributes = qt 4.6.1 tools linguist +qhp.Linguist.filterAttributes = qt 4.6.2 tools linguist qhp.Linguist.customFilters.Linguist.name = Qt Linguist Manual qhp.Linguist.customFilters.Linguist.filterAttributes = qt tools linguist qhp.Linguist.subprojects = manual examples diff --git a/tools/qdoc3/test/qmake.qdocconf b/tools/qdoc3/test/qmake.qdocconf index ad27d75..0e7d960 100644 --- a/tools/qdoc3/test/qmake.qdocconf +++ b/tools/qdoc3/test/qmake.qdocconf @@ -17,7 +17,7 @@ qhp.qmake.namespace = com.trolltech.qmake.460 qhp.qmake.virtualFolder = qdoc qhp.qmake.indexTitle = QMake Manual qhp.qmake.extraFiles = classic.css images/qt-logo.png images/trolltech-logo.png -qhp.qmake.filterAttributes = qt 4.6.1 tools qmake +qhp.qmake.filterAttributes = qt 4.6.2 tools qmake qhp.qmake.customFilters.qmake.name = qmake Manual qhp.qmake.customFilters.qmake.filterAttributes = qt tools qmake qhp.qmake.subprojects = manual diff --git a/tools/qdoc3/test/qt-build-docs.qdocconf b/tools/qdoc3/test/qt-build-docs.qdocconf index e9b9eb8..def4e67 100644 --- a/tools/qdoc3/test/qt-build-docs.qdocconf +++ b/tools/qdoc3/test/qt-build-docs.qdocconf @@ -32,9 +32,9 @@ qhp.Qt.extraFiles = classic.css \ images/dynamiclayouts-example.png \ images/stylesheet-coffee-plastique.png -qhp.Qt.filterAttributes = qt 4.6.1 qtrefdoc -qhp.Qt.customFilters.Qt.name = Qt 4.6.1 -qhp.Qt.customFilters.Qt.filterAttributes = qt 4.6.1 +qhp.Qt.filterAttributes = qt 4.6.2 qtrefdoc +qhp.Qt.customFilters.Qt.name = Qt 4.6.2 +qhp.Qt.customFilters.Qt.filterAttributes = qt 4.6.2 qhp.Qt.subprojects = classes overviews examples qhp.Qt.subprojects.classes.title = Classes qhp.Qt.subprojects.classes.indexTitle = Qt's Classes diff --git a/tools/qdoc3/test/qt.qdocconf b/tools/qdoc3/test/qt.qdocconf index a99f73e..1aefa98 100644 --- a/tools/qdoc3/test/qt.qdocconf +++ b/tools/qdoc3/test/qt.qdocconf @@ -34,9 +34,9 @@ qhp.Qt.extraFiles = classic.css \ images/dynamiclayouts-example.png \ images/stylesheet-coffee-plastique.png -qhp.Qt.filterAttributes = qt 4.6.1 qtrefdoc -qhp.Qt.customFilters.Qt.name = Qt 4.6.1 -qhp.Qt.customFilters.Qt.filterAttributes = qt 4.6.1 +qhp.Qt.filterAttributes = qt 4.6.2 qtrefdoc +qhp.Qt.customFilters.Qt.name = Qt 4.6.2 +qhp.Qt.customFilters.Qt.filterAttributes = qt 4.6.2 qhp.Qt.subprojects = classes overviews examples qhp.Qt.subprojects.classes.title = Classes qhp.Qt.subprojects.classes.indexTitle = Qt's Classes -- cgit v0.12 From 83a97dd0f2473a5c9cc1b6b0eba93de657d66ed4 Mon Sep 17 00:00:00 2001 From: Jason McDonald Date: Wed, 20 Jan 2010 02:03:45 +1000 Subject: Fix copyright year. Reviewed-by: Trust Me --- doc/src/modules.qdoc | 2 +- src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp | 2 +- src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h | 2 +- src/xmlpatterns/parser/qquerytransformparser.cpp | 2 +- src/xmlpatterns/parser/qquerytransformparser_p.h | 2 +- src/xmlpatterns/parser/qxslttokenlookup.cpp | 2 +- src/xmlpatterns/parser/qxslttokenlookup_p.h | 2 +- tests/auto/maketestselftest/tst_maketestselftest.cpp | 2 +- tests/auto/uic/baseline/config_fromuic3.ui | 2 +- tests/auto/uic/baseline/config_fromuic3.ui.h | 2 +- util/qlalr/doc/qlalr.qdocconf | 2 +- 11 files changed, 11 insertions(+), 11 deletions(-) diff --git a/doc/src/modules.qdoc b/doc/src/modules.qdoc index 298e0be..44d6ed6 100644 --- a/doc/src/modules.qdoc +++ b/doc/src/modules.qdoc @@ -1046,7 +1046,7 @@ distributed under the following license. \legalese - Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).\br + Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).\br All rights reserved.\br Contact: Nokia Corporation (qt-info@nokia.com) diff --git a/src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp b/src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp index 0720170..fed1658 100644 --- a/src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp +++ b/src/opengl/gl2paintengineex/qtextureglyphcache_gl.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/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h b/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h index 393893c..2a8a782 100644 --- a/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h +++ b/src/opengl/gl2paintengineex/qtextureglyphcache_gl_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/xmlpatterns/parser/qquerytransformparser.cpp b/src/xmlpatterns/parser/qquerytransformparser.cpp index c250d0c..6daa470 100644 --- a/src/xmlpatterns/parser/qquerytransformparser.cpp +++ b/src/xmlpatterns/parser/qquerytransformparser.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/xmlpatterns/parser/qquerytransformparser_p.h b/src/xmlpatterns/parser/qquerytransformparser_p.h index 204b6f8..0b316ec 100644 --- a/src/xmlpatterns/parser/qquerytransformparser_p.h +++ b/src/xmlpatterns/parser/qquerytransformparser_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/xmlpatterns/parser/qxslttokenlookup.cpp b/src/xmlpatterns/parser/qxslttokenlookup.cpp index a46ec8a..781ba0d 100644 --- a/src/xmlpatterns/parser/qxslttokenlookup.cpp +++ b/src/xmlpatterns/parser/qxslttokenlookup.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/xmlpatterns/parser/qxslttokenlookup_p.h b/src/xmlpatterns/parser/qxslttokenlookup_p.h index b45407d..6d004b0 100644 --- a/src/xmlpatterns/parser/qxslttokenlookup_p.h +++ b/src/xmlpatterns/parser/qxslttokenlookup_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/tests/auto/maketestselftest/tst_maketestselftest.cpp b/tests/auto/maketestselftest/tst_maketestselftest.cpp index ea7f36c..c674202 100644 --- a/tests/auto/maketestselftest/tst_maketestselftest.cpp +++ b/tests/auto/maketestselftest/tst_maketestselftest.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/tests/auto/uic/baseline/config_fromuic3.ui b/tests/auto/uic/baseline/config_fromuic3.ui index 0bd6256..2e7addb 100644 --- a/tests/auto/uic/baseline/config_fromuic3.ui +++ b/tests/auto/uic/baseline/config_fromuic3.ui @@ -3,7 +3,7 @@ ********************************************************************* ** -** 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/tests/auto/uic/baseline/config_fromuic3.ui.h b/tests/auto/uic/baseline/config_fromuic3.ui.h index 93dcfb5..6e22dc7 100644 --- a/tests/auto/uic/baseline/config_fromuic3.ui.h +++ b/tests/auto/uic/baseline/config_fromuic3.ui.h @@ -1,7 +1,7 @@ /* ********************************************************************* ** -** 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/util/qlalr/doc/qlalr.qdocconf b/util/qlalr/doc/qlalr.qdocconf index 391844b..ea9eaa6 100644 --- a/util/qlalr/doc/qlalr.qdocconf +++ b/util/qlalr/doc/qlalr.qdocconf @@ -59,7 +59,7 @@ HTML.postheader = "\n" \ "
\n" \ - "\n" \ + "\n" \ "\n" \ "\n" \ "
Copyright © 2009 Nokia Corporation and/or its subsidiary(-ies)Copyright © 2010 Nokia Corporation and/or its subsidiary(-ies)Trademarks
Qt \\version
" -- cgit v0.12 From c5809ade611d93c165dbde8c6ee618da73b0ad48 Mon Sep 17 00:00:00 2001 From: Nils Jeisecke Date: Wed, 13 Jan 2010 11:14:42 +0100 Subject: Memory leak in native Toolbar cleanup in Cocoa The QCocoaToolBarDelegate is not released when destroying the QMainWindowLayout. Task-number: QTBUG-7307 Reviewed-by: Prasanth Ullattil --- src/gui/widgets/qmainwindowlayout_mac.mm | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/gui/widgets/qmainwindowlayout_mac.mm b/src/gui/widgets/qmainwindowlayout_mac.mm index e41c2be..ee79f5a 100644 --- a/src/gui/widgets/qmainwindowlayout_mac.mm +++ b/src/gui/widgets/qmainwindowlayout_mac.mm @@ -476,6 +476,17 @@ void QMainWindowLayout::cleanUpMacToolbarItems() CFRelease(toolbarItemsCopy.at(i)); toolbarItemsCopy.clear(); unifiedToolbarHash.clear(); + +#ifdef QT_MAC_USE_COCOA + QMacCocoaAutoReleasePool pool; + + OSWindowRef window = qt_mac_window_for(layoutState.mainWindow); + NSToolbar *macToolbar = [window toolbar]; + if (macToolbar) { + [[macToolbar delegate] release]; + [macToolbar setDelegate:nil]; + } +#endif } void QMainWindowLayout::fixSizeInUnifiedToolbar(QToolBar *tb) const -- cgit v0.12 From 5f92bc9dd9f05f4824711b03406bdbe222ff73e9 Mon Sep 17 00:00:00 2001 From: Aaron Kennedy Date: Mon, 11 Jan 2010 16:28:49 +1000 Subject: QMetaObject::disconnectOne() Adds a disconnectOne() method that allows a single signal/slot connection to be disconnected, as required by QTBUG-6781. Reviewed-by: Warwick Allison Reviewed-by: Olivier Goffart --- src/corelib/kernel/qmetaobject_p.h | 6 ++-- src/corelib/kernel/qobject.cpp | 28 ++++++++++++--- src/corelib/kernel/qobjectdefs.h | 2 ++ tests/auto/qobject/tst_qobject.cpp | 73 ++++++++++++++++++++++++++++++++++++++ 4 files changed, 102 insertions(+), 7 deletions(-) diff --git a/src/corelib/kernel/qmetaobject_p.h b/src/corelib/kernel/qmetaobject_p.h index 79a7304..3bbb050 100644 --- a/src/corelib/kernel/qmetaobject_p.h +++ b/src/corelib/kernel/qmetaobject_p.h @@ -124,14 +124,16 @@ struct QMetaObjectPrivate #ifndef QT_NO_QOBJECT //defined in qobject.cpp + enum DisconnectType { DisconnectAll, DisconnectOne }; static bool connect(const QObject *sender, int signal_index, const QObject *receiver, int method_index, int type = 0, int *types = 0); static bool disconnect(const QObject *sender, int signal_index, - const QObject *receiver, int method_index); + const QObject *receiver, int method_index, + DisconnectType = DisconnectAll); static inline bool disconnectHelper(QObjectPrivate::Connection *c, const QObject *receiver, int method_index, - QMutex *senderMutex); + QMutex *senderMutex, DisconnectType); #endif }; diff --git a/src/corelib/kernel/qobject.cpp b/src/corelib/kernel/qobject.cpp index 8346fe4..5298fff 100644 --- a/src/corelib/kernel/qobject.cpp +++ b/src/corelib/kernel/qobject.cpp @@ -2945,7 +2945,6 @@ bool QMetaObjectPrivate::connect(const QObject *sender, int signal_index, return true; } - /*!\internal */ bool QMetaObject::disconnect(const QObject *sender, int signal_index, @@ -2956,12 +2955,27 @@ bool QMetaObject::disconnect(const QObject *sender, int signal_index, receiver, method_index); } +/*!\internal + +Disconnect a single signal connection. If QMetaObject::connect() has been called +multiple times for the same sender, signal_index, receiver and method_index only +one of these connections will be removed. + */ +bool QMetaObject::disconnectOne(const QObject *sender, int signal_index, + const QObject *receiver, int method_index) +{ + signal_index = methodIndexToSignalIndex(sender->metaObject(), signal_index); + return QMetaObjectPrivate::disconnect(sender, signal_index, + receiver, method_index, + QMetaObjectPrivate::DisconnectOne); +} + /*! \internal Helper function to remove the connection from the senders list and setting the receivers to 0 */ bool QMetaObjectPrivate::disconnectHelper(QObjectPrivate::Connection *c, const QObject *receiver, int method_index, - QMutex *senderMutex) + QMutex *senderMutex, DisconnectType disconnectType) { bool success = false; while (c) { @@ -2987,6 +3001,9 @@ bool QMetaObjectPrivate::disconnectHelper(QObjectPrivate::Connection *c, c->receiver = 0; success = true; + + if (disconnectType == DisconnectOne) + return success; } c = c->nextConnectionList; } @@ -2997,7 +3014,8 @@ bool QMetaObjectPrivate::disconnectHelper(QObjectPrivate::Connection *c, Same as the QMetaObject::disconnect, but \a signal_index must be the result of QObjectPrivate::signalIndex */ bool QMetaObjectPrivate::disconnect(const QObject *sender, int signal_index, - const QObject *receiver, int method_index) + const QObject *receiver, int method_index, + DisconnectType disconnectType) { if (!sender) return false; @@ -3021,7 +3039,7 @@ bool QMetaObjectPrivate::disconnect(const QObject *sender, int signal_index, for (signal_index = -1; signal_index < connectionLists->count(); ++signal_index) { QObjectPrivate::Connection *c = (*connectionLists)[signal_index].first; - if (disconnectHelper(c, receiver, method_index, senderMutex)) { + if (disconnectHelper(c, receiver, method_index, senderMutex, disconnectType)) { success = true; connectionLists->dirty = true; } @@ -3029,7 +3047,7 @@ bool QMetaObjectPrivate::disconnect(const QObject *sender, int signal_index, } else if (signal_index < connectionLists->count()) { QObjectPrivate::Connection *c = (*connectionLists)[signal_index].first; - if (disconnectHelper(c, receiver, method_index, senderMutex)) { + if (disconnectHelper(c, receiver, method_index, senderMutex, disconnectType)) { success = true; connectionLists->dirty = true; } diff --git a/src/corelib/kernel/qobjectdefs.h b/src/corelib/kernel/qobjectdefs.h index a0d9cf3..8ed7f3f 100644 --- a/src/corelib/kernel/qobjectdefs.h +++ b/src/corelib/kernel/qobjectdefs.h @@ -334,6 +334,8 @@ struct Q_CORE_EXPORT QMetaObject // internal index-based disconnect static bool disconnect(const QObject *sender, int signal_index, const QObject *receiver, int method_index); + static bool disconnectOne(const QObject *sender, int signal_index, + const QObject *receiver, int method_index); // internal slot-name based connect static void connectSlotsByName(QObject *o); diff --git a/tests/auto/qobject/tst_qobject.cpp b/tests/auto/qobject/tst_qobject.cpp index d342581..4fa6aaa 100644 --- a/tests/auto/qobject/tst_qobject.cpp +++ b/tests/auto/qobject/tst_qobject.cpp @@ -127,6 +127,7 @@ private slots: void overloads(); void isSignalConnected(); void qMetaObjectConnect(); + void qMetaObjectDisconnectOne(); protected: }; @@ -3269,5 +3270,77 @@ void tst_QObject::qMetaObjectConnect() } +void tst_QObject::qMetaObjectDisconnectOne() +{ + SenderObject *s = new SenderObject; + ReceiverObject *r1 = new ReceiverObject; + + int signal1Index = s->metaObject()->indexOfSignal("signal1()"); + int signal3Index = s->metaObject()->indexOfSignal("signal3()"); + int slot1Index = r1->metaObject()->indexOfSlot("slot1()"); + int slot2Index = r1->metaObject()->indexOfSlot("slot2()"); + + QVERIFY(signal1Index > 0); + QVERIFY(signal3Index > 0); + QVERIFY(slot1Index > 0); + QVERIFY(slot2Index > 0); + + QVERIFY( QMetaObject::connect(s, signal1Index, r1, slot1Index) ); + QVERIFY( QMetaObject::connect(s, signal3Index, r1, slot2Index) ); + QVERIFY( QMetaObject::connect(s, signal3Index, r1, slot2Index) ); + QVERIFY( QMetaObject::connect(s, signal3Index, r1, slot2Index) ); + + r1->reset(); + QCOMPARE( r1->count_slot1, 0 ); + QCOMPARE( r1->count_slot2, 0 ); + + s->emitSignal1(); + QCOMPARE( r1->count_slot1, 1 ); + QCOMPARE( r1->count_slot2, 0 ); + + s->emitSignal3(); + QCOMPARE( r1->count_slot1, 1 ); + QCOMPARE( r1->count_slot2, 3 ); + + r1->reset(); + QVERIFY( QMetaObject::disconnectOne(s, signal1Index, r1, slot1Index) ); + QVERIFY( QMetaObject::disconnectOne(s, signal3Index, r1, slot2Index) ); + + s->emitSignal1(); + QCOMPARE( r1->count_slot1, 0 ); + QCOMPARE( r1->count_slot2, 0 ); + + s->emitSignal3(); + QCOMPARE( r1->count_slot1, 0 ); + QCOMPARE( r1->count_slot2, 2 ); + + r1->reset(); + QVERIFY( false == QMetaObject::disconnectOne(s, signal1Index, r1, slot1Index) ); + QVERIFY( QMetaObject::disconnectOne(s, signal3Index, r1, slot2Index) ); + + s->emitSignal1(); + QCOMPARE( r1->count_slot1, 0 ); + QCOMPARE( r1->count_slot2, 0 ); + + s->emitSignal3(); + QCOMPARE( r1->count_slot1, 0 ); + QCOMPARE( r1->count_slot2, 1 ); + + r1->reset(); + QVERIFY( false == QMetaObject::disconnectOne(s, signal1Index, r1, slot1Index) ); + QVERIFY( QMetaObject::disconnectOne(s, signal3Index, r1, slot2Index) ); + + s->emitSignal1(); + QCOMPARE( r1->count_slot1, 0 ); + QCOMPARE( r1->count_slot2, 0 ); + + s->emitSignal3(); + QCOMPARE( r1->count_slot1, 0 ); + QCOMPARE( r1->count_slot2, 0 ); + + delete s; + delete r1; +} + QTEST_MAIN(tst_QObject) #include "tst_qobject.moc" -- cgit v0.12