diff options
author | Kavindra Devi Palaraja <kavindra.palaraja@nokia.com> | 2009-04-15 12:38:56 (GMT) |
---|---|---|
committer | Kavindra Devi Palaraja <kavindra.palaraja@nokia.com> | 2009-04-15 13:08:35 (GMT) |
commit | 96a529868cc75523f03aae5eb9ffdf72e29aab96 (patch) | |
tree | d25789d0817c2adda7a3a641f3de38fd5a245cd2 | |
parent | bbad83a64373b7e01f6abee98d854380f03aa6b6 (diff) | |
parent | 4e9c2364e8e9580aa317e9387338d45207ac4baa (diff) | |
download | Qt-96a529868cc75523f03aae5eb9ffdf72e29aab96.zip Qt-96a529868cc75523f03aae5eb9ffdf72e29aab96.tar.gz Qt-96a529868cc75523f03aae5eb9ffdf72e29aab96.tar.bz2 |
Merge branch '4.5' of git@scm.dev.nokia.troll.no:qt/qt into 4.5
Merge commit '4e9c2364e8e9580aa317e9387338d45207ac4baa' into HEAD
-rw-r--r-- | configure.exe | bin | 1134592 -> 860160 bytes | |||
-rw-r--r-- | dist/changes-4.5.1 | 53 | ||||
-rw-r--r-- | src/gui/graphicsview/qgraphicsitem.cpp | 1 | ||||
-rw-r--r-- | src/gui/kernel/qcocoapanel_mac.mm | 8 | ||||
-rw-r--r-- | src/gui/kernel/qcocoawindow_mac.mm | 7 | ||||
-rw-r--r-- | src/gui/widgets/qcocoamenu_mac.mm | 6 | ||||
-rw-r--r-- | src/opengl/qgl_mac.mm | 2 | ||||
-rw-r--r-- | tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp | 34 |
8 files changed, 96 insertions, 15 deletions
diff --git a/configure.exe b/configure.exe Binary files differindex 13ca0e5..ff71f08 100644 --- a/configure.exe +++ b/configure.exe diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index 68edc78..4fb155a 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -46,9 +46,17 @@ Third party components - QAbstractSocket * [192037] Emit disconnected only if we were connected before +- QAccessible + * [241161] Fixed bug in browsing menus with the keyboard. + * [221731] Fixed bug where the accessibility plugin could crash if there + was an "&" at the end or spin forever if a label had a sequence of "&&". + - QAuthenticator * [237979] fix implemenation of md5-sess +- QByteArray + * [246233] QByteArray::fromHex() fails with input of size 1 + - QColorDialog * [247349] Fixed bug causing the wrong alpha value to be returned. @@ -59,9 +67,16 @@ Third party components * [250064] Fixed focus policy propagation regression. * [246056] Fixed assertion failure in setCompletionPrefix(). +- QtConcurrent + * [244718] Reduce the number of calls to QThread::idealThreadCount(). + - QDirIterator * [247645] Fix a bug that may loose all cached data inside the QFileInfo +- QFile + * [244500] QFile::rename() doesn't always return false when the method fails + * [244485] Renaming a file does not change QFile::fileName() + - QFileInfo * [205244] return valid file info also for relative UNC paths @@ -76,12 +91,20 @@ Third party components sceneeventfilters meaning a crash can occur * Fixed slowdown regression in QGraphicsItem::ItemCoordinateCache +- QGraphicsGridLayout + * [242472] Fix a bug where the calculation of the maximum width of a column + was not calculated correctly. + - QGraphicsScene * [243707] Fixed crash when adding child before parent to scene -QGraphicsView * [245766] Rubber Band drag mode not updated correctly when scrolling +- QGraphicsWidget + * [246215] Fixed a regression where we could cache the wrong size hint + because we called the virtual sizeHint() from the constructor. + - QHttp * [208445] cancel request upon receiving unknown authentication method @@ -135,7 +158,7 @@ Third party components * Fixed crash that may occurs when event are processed just after QSortFilterProxyModel has been invalidated * [246025] Fixed auto-expand that occurs while quicly collapsing an item after clicking on a child - * [248805] Calling programatically QTreeView::sortByColumn was not working if manual + * [248805] Calling programatically QTreeView::sortByColumn was not working if manual sorting is disabled * [248163] Fixed possible crash in the paintEvent when spans are used. @@ -177,13 +200,13 @@ Qt for Linux/X11 CD playback. - QGtkStyle - * The system palette is no longer strictly forced. Also behavior related + * The system palette is no longer strictly forced. Also behavior related to system theme changes have been improved. * [249363] QFrame is now styled as a GtkScrolledWindow. * [247653] Fixed a compilation issue on solaris. - * Fixed palette and styling issues with the background color of + * Fixed palette and styling issues with the background color of combo box popups. - * [239829] Disabled alt-key navigation for QGtkStyle to follow + * [239829] Disabled alt-key navigation for QGtkStyle to follow GTK+ behavior. * [238196] Allow middle click to set scrollbar position to follow GTK+ behavior. @@ -240,13 +263,24 @@ Qt for Mac OS X * Modify the colliding mice example to work better with coalesced updates. * Fixed a bug where the drag cursor was not updated when modifier keys are used. * [247947] Fixed a crash in drag and drop. + * The command + h shortcut is now enabled. (Hides the current window.) -- Fix a crash when showing a widget that is window modal but has no parent. -- [248803] Showing two dialogs at the same time don't get shared activation. -- Added QSysInfo::MV_10_6 as an enum to test against. -- Various compile fixes for Snow Leopard (preliminary support). +- QDesktopWidget + * [244004] Support multiple screens that have different sizes properly. + +- macdeployqt + * The binary packages now includes the macdeployqt tool. + * macdeployqt now runs 'strip' on the deployed binaries. + * Fixed issue preventing the QtSvg from being deployed. +- configure script + * Now supports "-arch i386" as an alias for "-arch x86". + * Detects invalid arch arguemnts and exits. +- Fix a crash when showing a widget that is window modal but has no parent. +- [248803] Showing two dialogs at the same time don't get shared activation. +- Added QSysInfo::MV_10_6 as an enum to test against. +- Various compile fixes for Snow Leopard (preliminary support). - The uninstall-qt.py script included in the binary package no longer complains about removing itself multiple times. - Document a bit clearer how qt_mac_set_dock_menu() works. @@ -301,6 +335,7 @@ Qt for Windows CE - moc + * [240368] moc parsing issue with "unsigned" subphrase - uic * [244998] Fixed include file generation for phonon widgets. @@ -314,6 +349,8 @@ Qt for Windows CE - qmake * [248806] Ensure that the Xcode generator includes the right path to frameworks. + * [201495] Comment processing in qmake prevented file from being moc'ed + * On Mac OS, properly escape file names in QMAKE_BUNDLE_DATA - configure diff --git a/src/gui/graphicsview/qgraphicsitem.cpp b/src/gui/graphicsview/qgraphicsitem.cpp index e6bcaa6..d1b8393 100644 --- a/src/gui/graphicsview/qgraphicsitem.cpp +++ b/src/gui/graphicsview/qgraphicsitem.cpp @@ -8489,6 +8489,7 @@ void QGraphicsSimpleTextItem::setText(const QString &text) return; d->text = text; d->updateBoundingRect(); + update(); } /*! diff --git a/src/gui/kernel/qcocoapanel_mac.mm b/src/gui/kernel/qcocoapanel_mac.mm index 95e20af..c69826f 100644 --- a/src/gui/kernel/qcocoapanel_mac.mm +++ b/src/gui/kernel/qcocoapanel_mac.mm @@ -49,8 +49,10 @@ #include <QtGui/QWidget> +QT_FORWARD_DECLARE_CLASS(QWidget); +QT_BEGIN_NAMESPACE extern Qt::MouseButton cocoaButton2QtButton(NSInteger buttonNum); // qcocoaview.mm - +QT_END_NAMESPACE QT_USE_NAMESPACE @implementation QT_MANGLE_NAMESPACE(QCocoaPanel) @@ -108,7 +110,7 @@ QT_USE_NAMESPACE [self retain]; QWidget *widget = [[QT_MANGLE_NAMESPACE(QCocoaWindowDelegate) sharedDelegate] qt_qwidgetForWindow:self]; - QCocoaView *view = static_cast<QCocoaView *>(qt_mac_nativeview_for(widget)); + QT_MANGLE_NAMESPACE(QCocoaView) *view = static_cast<QT_MANGLE_NAMESPACE(QCocoaView) *>(qt_mac_nativeview_for(widget)); Qt::MouseButton mouseButton = cocoaButton2QtButton([event buttonNumber]); // sometimes need to redirect mouse events to the popup. @@ -172,7 +174,7 @@ QT_USE_NAMESPACE + (Class)frameViewClassForStyleMask:(NSUInteger)styleMask { if (styleMask & QtMacCustomizeWindow) - return [QCocoaWindowCustomThemeFrame class]; + return [QT_MANGLE_NAMESPACE(QCocoaWindowCustomThemeFrame) class]; return [super frameViewClassForStyleMask:styleMask]; } diff --git a/src/gui/kernel/qcocoawindow_mac.mm b/src/gui/kernel/qcocoawindow_mac.mm index 972e477..89f481f 100644 --- a/src/gui/kernel/qcocoawindow_mac.mm +++ b/src/gui/kernel/qcocoawindow_mac.mm @@ -53,9 +53,10 @@ #include <QtGui/QWidget> QT_FORWARD_DECLARE_CLASS(QWidget); -QT_USE_NAMESPACE - +QT_BEGIN_NAMESPACE extern Qt::MouseButton cocoaButton2QtButton(NSInteger buttonNum); // qcocoaview.mm +QT_END_NAMESPACE +QT_USE_NAMESPACE @implementation NSWindow (QT_MANGLE_NAMESPACE(QWidgetIntegration)) @@ -130,7 +131,7 @@ extern Qt::MouseButton cocoaButton2QtButton(NSInteger buttonNum); // qcocoaview. [self retain]; QWidget *widget = [[QT_MANGLE_NAMESPACE(QCocoaWindowDelegate) sharedDelegate] qt_qwidgetForWindow:self]; - QCocoaView *view = static_cast<QCocoaView *>(qt_mac_nativeview_for(widget)); + QT_MANGLE_NAMESPACE(QCocoaView) *view = static_cast<QT_MANGLE_NAMESPACE(QCocoaView) *>(qt_mac_nativeview_for(widget)); Qt::MouseButton mouseButton = cocoaButton2QtButton([event buttonNumber]); // sometimes need to redirect mouse events to the popup. diff --git a/src/gui/widgets/qcocoamenu_mac.mm b/src/gui/widgets/qcocoamenu_mac.mm index c5fee66..6434289 100644 --- a/src/gui/widgets/qcocoamenu_mac.mm +++ b/src/gui/widgets/qcocoamenu_mac.mm @@ -55,11 +55,17 @@ QT_FORWARD_DECLARE_CLASS(QAction) QT_FORWARD_DECLARE_CLASS(QWidget) QT_FORWARD_DECLARE_CLASS(QApplication) +QT_FORWARD_DECLARE_CLASS(QCoreApplication) +QT_FORWARD_DECLARE_CLASS(QApplicationPrivate) +QT_FORWARD_DECLARE_CLASS(QKeyEvent) +QT_FORWARD_DECLARE_CLASS(QEvent) QT_BEGIN_NAMESPACE extern bool qt_sendSpontaneousEvent(QObject*, QEvent*); //qapplication.cpp QT_END_NAMESPACE +QT_USE_NAMESPACE + @implementation QT_MANGLE_NAMESPACE(QCocoaMenu) - (id)initWithQMenu:(QMenu*)menu diff --git a/src/opengl/qgl_mac.mm b/src/opengl/qgl_mac.mm index 3dbdaec..1319396 100644 --- a/src/opengl/qgl_mac.mm +++ b/src/opengl/qgl_mac.mm @@ -629,7 +629,7 @@ void QGLContext::updatePaintDevice() // ideally we would use QWidget::isVisible(), but we get "invalid drawable" errors if (![(NSWindow *)qt_mac_window_for(w) isVisible]) return; - if ([static_cast<NSOpenGLContext *>(d->cx) view] != view) + if ([static_cast<NSOpenGLContext *>(d->cx) view] != view && ![view isHidden]) [static_cast<NSOpenGLContext *>(d->cx) setView:view]; } else if (d->paintDevice->devType() == QInternal::Pixmap) { const QPixmap *pm = static_cast<const QPixmap *>(d->paintDevice); diff --git a/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp b/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp index 2d1be37..d500182 100644 --- a/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp +++ b/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp @@ -222,6 +222,7 @@ private slots: // task specific tests below me void task141694_textItemEnsureVisible(); void task128696_textItemEnsureMovable(); + void ensureUpdateOnTextItem(); void task177918_lineItemUndetected(); void task240400_clickOnTextItem_data(); void task240400_clickOnTextItem(); @@ -5272,6 +5273,39 @@ void tst_QGraphicsItem::task240400_clickOnTextItem() QCOMPARE(item->textCursor().columnNumber(), 0); } +class TextItem : public QGraphicsSimpleTextItem +{ +public: + TextItem(const QString& text) : QGraphicsSimpleTextItem(text) + { + updates = 0; + } + + void paint(QPainter * painter, const QStyleOptionGraphicsItem * option, QWidget * widget) + { + updates++; + QGraphicsSimpleTextItem::paint(painter, option, widget); + } + + int updates; +}; + +void tst_QGraphicsItem::ensureUpdateOnTextItem() +{ + QGraphicsScene scene; + TextItem *text1 = new TextItem(QLatin1String("123")); + scene.addItem(text1); + QGraphicsView view(&scene); + view.show(); + QTest::qWait(250); + QCOMPARE(text1->updates,1); + + //same bouding rect but we have to update + text1->setText(QLatin1String("321")); + QTest::qWait(250); + QCOMPARE(text1->updates,2); +} + void tst_QGraphicsItem::task243707_addChildBeforeParent() { // Task reports that adding the child before the parent leads to an |