From 79f71c5d085828d532cfa93e5db1a645db32c502 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan-Arve=20S=C3=A6ther?= Date: Wed, 15 Apr 2009 13:25:22 +0200 Subject: My changes (cherry picked from commit 869c85e2f965a226416f0a142572ff749b30ba9e) --- dist/changes-4.5.1 | 25 +++++++++++++++++++------ 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index bbf0bf1..8d90ac9 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -46,6 +46,11 @@ 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 @@ -83,12 +88,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 @@ -142,7 +155,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. @@ -184,13 +197,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. @@ -250,8 +263,8 @@ Qt for Mac OS X - 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). +- 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. -- cgit v0.12 From cd21a97b85f9dfea2589961de1ca24f77b3a1dd9 Mon Sep 17 00:00:00 2001 From: Norwegian Rock Cat Date: Wed, 15 Apr 2009 13:14:31 +0200 Subject: BT: Namespace compile fixes for Cocoa. It worked in 4.5.0, so it should work in 4.5.1 too. (cherry picked from commit d7e8586e6ab009a6da1eb63aa6798d7c6a34c30d) --- src/gui/kernel/qcocoapanel_mac.mm | 8 +++++--- src/gui/kernel/qcocoawindow_mac.mm | 7 ++++--- src/gui/widgets/qcocoamenu_mac.mm | 6 ++++++ 3 files changed, 15 insertions(+), 6 deletions(-) diff --git a/src/gui/kernel/qcocoapanel_mac.mm b/src/gui/kernel/qcocoapanel_mac.mm index 9a7237d..ad0d8f6 100644 --- a/src/gui/kernel/qcocoapanel_mac.mm +++ b/src/gui/kernel/qcocoapanel_mac.mm @@ -49,8 +49,10 @@ #include +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(qt_mac_nativeview_for(widget)); + QT_MANGLE_NAMESPACE(QCocoaView) *view = static_cast(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 b5ee5a6..4158469 100644 --- a/src/gui/kernel/qcocoawindow_mac.mm +++ b/src/gui/kernel/qcocoawindow_mac.mm @@ -53,9 +53,10 @@ #include 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(qt_mac_nativeview_for(widget)); + QT_MANGLE_NAMESPACE(QCocoaView) *view = static_cast(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 8d3239e..147e591 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 -- cgit v0.12 From c076d7b1ef32f53ca871cc80e16c742dff9f3b09 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Trond=20Kjern=C3=A5sen?= Date: Wed, 15 Apr 2009 13:34:09 +0200 Subject: Reparenting QGLWidgets did sometimes caused warnings to be printed on Mac/Cocoa. Check if the view is visible before attaching it to a context. Task-number: related to 250066 Reviewed-by: Norwegian Rock Cat BT: yes (cherry picked from commit b646787cf0d67f4df00212f62a83432c641eae95) --- src/opengl/qgl_mac.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/opengl/qgl_mac.mm b/src/opengl/qgl_mac.mm index cc7d9a7..ad42efb 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(d->cx) view] != view) + if ([static_cast(d->cx) view] != view && ![view isHidden]) [static_cast(d->cx) setView:view]; } else if (d->paintDevice->devType() == QInternal::Pixmap) { const QPixmap *pm = static_cast(d->paintDevice); -- cgit v0.12 From 5595bb2f99d5d6a3c8bb20d3f150915cddc560de Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Wed, 15 Apr 2009 13:49:57 +0200 Subject: BT: Updated configure for OpenGL ES 2.0 Windows CE (cherry picked from commit 4cb80de7ade662deb5542f77cd3a36517fa9cd9b) --- configure.exe | Bin 1134592 -> 860160 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/configure.exe b/configure.exe index 13ca0e5..ff71f08 100644 Binary files a/configure.exe and b/configure.exe differ -- cgit v0.12 From 4f32aaebc26709daf449b460f3be68592bd29d12 Mon Sep 17 00:00:00 2001 From: Alexis Menard Date: Wed, 15 Apr 2009 14:14:27 +0200 Subject: Update the item if the text has changed but the boundingRect is the same. updateBoudingRect update the item only if the boundingRect change but if we have 123 as an initial text and then we set 321 as the new text, then nothing happen because the rect is the same. In case the boundingRect change then we call update 2 times but the item is already dirty so the second call will just return. BT:yes Reviewed-by: Andreas (cherry picked from commit 36b16a126e24cb8d8e5c34cfd807bc7c51ea49cf) --- src/gui/graphicsview/qgraphicsitem.cpp | 1 + tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp | 34 ++++++++++++++++++++++++++ 2 files changed, 35 insertions(+) diff --git a/src/gui/graphicsview/qgraphicsitem.cpp b/src/gui/graphicsview/qgraphicsitem.cpp index 801ba99..de4332c 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/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp b/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp index 29b6cdd..ef84f50 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 -- cgit v0.12 From 1ff9a2a4b9ce6d48fe468026a87795928e34c6ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Morten=20S=C3=B8rvig?= Date: Wed, 15 Apr 2009 14:35:32 +0200 Subject: My 4.5.1 changes. (cherry picked from commit 4e9c2364e8e9580aa317e9387338d45207ac4baa) --- dist/changes-4.5.1 | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index 8d90ac9..4fb155a 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -67,6 +67,9 @@ 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 @@ -260,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.) + +- 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. -- cgit v0.12 From 64b58a408129f845b897a225d20ace31d0427e66 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Samuel=20R=C3=B8dal?= Date: Wed, 15 Apr 2009 14:03:49 +0200 Subject: Prevent crash in qt_scrollRectInImage. Clip both against the source and target device rectangles. Task-number: 247937 Reviewed-by: Trond BT: yes (cherry picked from commit 9da65ead69c92df717b1a63fe3c98c0cc73270f9) --- dist/changes-4.5.1 | 4 ++++ src/gui/painting/qwindowsurface.cpp | 7 +++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index 4fb155a..bda151f 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -162,6 +162,10 @@ Third party components sorting is disabled * [248163] Fixed possible crash in the paintEvent when spans are used. +- QWidget + * [250388] Fixed potential crash in QWidget::scroll() when using the raster + graphics system. + - QWizard * [248107] Fixed bug on Vista causing Back button to connect twice to the back() signal. diff --git a/src/gui/painting/qwindowsurface.cpp b/src/gui/painting/qwindowsurface.cpp index 1adbcc5..7cb0dea2 100644 --- a/src/gui/painting/qwindowsurface.cpp +++ b/src/gui/painting/qwindowsurface.cpp @@ -310,10 +310,13 @@ void qt_scrollRectInImage(QImage &img, const QRect &rect, const QPoint &offset) int lineskip = img.bytesPerLine(); int depth = img.depth() >> 3; - - const QRect r = rect & QRect(0, 0, img.width(), img.height()); + const QRect imageRect(0, 0, img.width(), img.height()); + const QRect r = rect & imageRect & imageRect.translated(-offset); const QPoint p = rect.topLeft() + offset; + if (r.isEmpty()) + return; + const uchar *src; uchar *dest; -- cgit v0.12 From 793310766ff5db8739136847f4bc896999eae9e9 Mon Sep 17 00:00:00 2001 From: Kavindra Devi Palaraja Date: Wed, 15 Apr 2009 14:26:59 +0200 Subject: Doc - clarified that on Windows, for 32-bit programs running in WOW64 mode, the settings are stored in HKEY_LOCAL_MACHINE\Software\WOW6432node. Task-number: 232011 Reviewed-by: Martin Petersson (cherry picked from commit bbad83a64373b7e01f6abee98d854380f03aa6b6) --- src/corelib/io/qsettings.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/corelib/io/qsettings.cpp b/src/corelib/io/qsettings.cpp index 876a251..4ae1c17 100644 --- a/src/corelib/io/qsettings.cpp +++ b/src/corelib/io/qsettings.cpp @@ -2330,6 +2330,10 @@ void QConfFileSettingsPrivate::ensureSectionParsed(QConfFile *confFile, \o \c{HKEY_LOCAL_MACHINE\Software\MySoft} \endlist + \note On Windows, for 32-bit programs running in WOW64 mode, settings are + stored in the following registry path: + \c{HKEY_LOCAL_MACHINE\Software\WOW6432node}. + If the file format is IniFormat, the following files are used on Unix and Mac OS X: -- cgit v0.12 From 4282da271dab554c020f8b24e6679fea69d8e815 Mon Sep 17 00:00:00 2001 From: Jarek Kobus Date: Wed, 15 Apr 2009 15:15:25 +0200 Subject: Make the configured namespace part of QT_BUILD_KEY_COMPAT too. The eclipse integration is namespaced, but it still pulled in system plugins like the oxygen style through QT_BUILD_KEY_COMPAT check in QLibraryPrivate::isPlugin() Task: 250185 Reviewed-by: dt BT: yes (cherry picked from commit cca58cff45ea248ab9c65fd8ce088433af1c0fe0) --- configure | 3 +++ 1 file changed, 3 insertions(+) diff --git a/configure b/configure index ecdb92f..83d4078 100755 --- a/configure +++ b/configure @@ -6210,6 +6210,9 @@ QT_BUILD_KEY_COMPAT= if [ "$QT_CROSS_COMPILE" = "no" ]; then # previous versions of Qt used a build key built from the uname QT_BUILD_KEY_COMPAT="$CFG_USER_BUILD_KEY $UNAME_MACHINE $UNAME_SYSTEM $COMPILER $BUILD_OPTIONS" + if [ -n "$QT_NAMESPACE" ]; then + QT_BUILD_KEY_COMPAT="$QT_BUILD_KEY_COMPAT $QT_NAMESPACE" + fi fi # strip out leading/trailing/extra whitespace QT_BUILD_KEY=`echo $QT_BUILD_KEY | sed -e "s, *, ,g" -e "s,^ *,," -e "s, *$,,"` -- cgit v0.12 From 78d04fbe2cd9f4e38f859aa400f08b123433f041 Mon Sep 17 00:00:00 2001 From: "Bradley T. Hughes" Date: Wed, 15 Apr 2009 15:16:17 +0200 Subject: Update changelog with my changes (cherry picked from commit 0da501b644c0799d4e5e357b27847cb7a58583e4) --- dist/changes-4.5.1 | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index bda151f..9a64352 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -51,6 +51,9 @@ Third party components * [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 "&&". +- QAtomicInt + * [216492] Fix compilation on 64-bit PowerPC machines with gcc 4.3. + - QAuthenticator * [237979] fix implemenation of md5-sess @@ -108,6 +111,13 @@ Third party components - QHttp * [208445] cancel request upon receiving unknown authentication method +- QHostAddress + * [247330] Fix compilation on MinGW by adding a missing QPair include. + +- QLocalSocket + * Fix a bug that would cause QLocalSocket to disconnect 30 seconds + after a succesful delayed connection on UNIX. + - QMacStyle * [248769] Fix regression where QMacStyle would only draw tabs when passed a QStyleOptionTabV3. * Adjust the opacity value for popups. @@ -115,6 +125,14 @@ Third party components - QMainWindow * [248048] Fix a regression that would cause tooltips to disappear when using the unified toolbar. +- QMetaType + * [248890] Detailed description of QMetaType no longer contradicts + documentation of QMetaType::type() + +- QMutex + * Fix performance regression for contended mutexes as reported on + the qt4-preview-feedback list. + - QPainter * [247492] Fix rendering bug in raster paint engine causing one-pixel offset when drawing premultiplied ARGB32 images on RGB16 images. @@ -131,6 +149,10 @@ Third party components * [249175] Fix QPixmap::fromImage() of monochrome images to result in black/white pixels and not transparent/white pixels. +- QProcess + * [247865] Fix a crash when calling QProcess::start() and + startDetached() with an empty program string. + - QScrollBar * [247985] Stylesheet: added ability to style scrollbar menus. @@ -154,6 +176,10 @@ Third party components * Fixed crash while styling the title bar of a QMdiArea. * [246542] Fixed QToolButton::hover{ color:.... } +- QThread + * [249997] Add documentation indicating that the priority set by + the programmer may be ignored, for example on Linux. + - QTreeView * Fixed crash that may occurs when event are processed just after QSortFilterProxyModel has been invalidated -- cgit v0.12 From 939d9a8f3daffbc2e812040731e4cfc4a88e055e Mon Sep 17 00:00:00 2001 From: Paul Olav Tvete Date: Wed, 15 Apr 2009 16:14:09 +0200 Subject: Updated changes (cherry picked from commit 0da3eabece2d33e2f8cdf421bbd8e95787c170f7) --- dist/changes-4.5.1 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index 9a64352..dd81f7c 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -168,6 +168,9 @@ Third party components * [245668] set also protocol, verifyMode and verifyDepth in setSslConfiguration() +- QString + * [249517] Fixed regression in replace(int, int, QChar) when string is empty + - QStyleSheetStyle * Improved support for setting background and foreground roles in styles such as the text color in a combo box popup on Mac and Cleanlooks, or -- cgit v0.12 From 6bb5d34b9452d87f9c537e08efcb620d3752b0ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan-Arve=20S=C3=A6ther?= Date: Wed, 15 Apr 2009 16:15:14 +0200 Subject: Fixed and improved the example code (cherry picked from commit a1a3dd96aef2b2edd7eb7c563fabee124cdbfe5a) --- examples/layouts/flowlayout/flowlayout.cpp | 63 ++++++++++++++++++++++++------ examples/layouts/flowlayout/flowlayout.h | 9 ++++- 2 files changed, 58 insertions(+), 14 deletions(-) diff --git a/examples/layouts/flowlayout/flowlayout.cpp b/examples/layouts/flowlayout/flowlayout.cpp index 5464c7c..f628e94 100644 --- a/examples/layouts/flowlayout/flowlayout.cpp +++ b/examples/layouts/flowlayout/flowlayout.cpp @@ -43,16 +43,16 @@ #include "flowlayout.h" -FlowLayout::FlowLayout(QWidget *parent, int margin, int spacing) - : QLayout(parent) +FlowLayout::FlowLayout(QWidget *parent, int margin, int hSpacing, int vSpacing) + : QLayout(parent), m_hSpace(hSpacing), m_vSpace(vSpacing) { setMargin(margin); - setSpacing(spacing); } -FlowLayout::FlowLayout(int spacing) +FlowLayout::FlowLayout(int margin, int hSpacing, int vSpacing) + : m_hSpace(hSpacing), m_vSpace(vSpacing) { - setSpacing(spacing); + setMargin(margin); } FlowLayout::~FlowLayout() @@ -67,6 +67,24 @@ void FlowLayout::addItem(QLayoutItem *item) itemList.append(item); } +int FlowLayout::horizontalSpacing() const +{ + if (m_hSpace >= 0) { + return m_hSpace; + } else { + return smartSpacing(QStyle::PM_LayoutHorizontalSpacing); + } +} + +int FlowLayout::verticalSpacing() const +{ + if (m_vSpace >= 0) { + return m_vSpace; + } else { + return smartSpacing(QStyle::PM_LayoutVerticalSpacing); + } +} + int FlowLayout::count() const { return itemList.size(); @@ -125,20 +143,27 @@ QSize FlowLayout::minimumSize() const int FlowLayout::doLayout(const QRect &rect, bool testOnly) const { - int x = rect.x(); - int y = rect.y(); + int left, top, right, bottom; + getContentsMargins(&left, &top, &right, &bottom); + QRect effectiveRect = rect.adjusted(+left, +top, -right, -bottom); + int x = effectiveRect.x(); + int y = effectiveRect.y(); int lineHeight = 0; QLayoutItem *item; foreach (item, itemList) { QWidget *wid = item->widget(); - int spaceX = spacing() + wid->style()->layoutSpacing( + int spaceX = horizontalSpacing(); + if (spaceX == -1) + spaceX = wid->style()->layoutSpacing( QSizePolicy::PushButton, QSizePolicy::PushButton, Qt::Horizontal); - int spaceY = spacing() + wid->style()->layoutSpacing( + int spaceY = verticalSpacing(); + if (spaceY == -1) + spaceY = wid->style()->layoutSpacing( QSizePolicy::PushButton, QSizePolicy::PushButton, Qt::Vertical); int nextX = x + item->sizeHint().width() + spaceX; - if (nextX - spaceX > rect.right() && lineHeight > 0) { - x = rect.x(); + if (nextX - spaceX > effectiveRect.right() && lineHeight > 0) { + x = effectiveRect.x(); y = y + lineHeight + spaceY; nextX = x + item->sizeHint().width() + spaceX; lineHeight = 0; @@ -150,5 +175,19 @@ int FlowLayout::doLayout(const QRect &rect, bool testOnly) const x = nextX; lineHeight = qMax(lineHeight, item->sizeHint().height()); } - return y + lineHeight - rect.y(); + return y + lineHeight - rect.y() + bottom; } + +int FlowLayout::smartSpacing(QStyle::PixelMetric pm) const +{ + QObject *parent = this->parent(); + if (!parent) { + return -1; + } else if (parent->isWidgetType()) { + QWidget *pw = static_cast(parent); + return pw->style()->pixelMetric(pm, 0, pw); + } else { + return static_cast(parent)->spacing(); + } +} + diff --git a/examples/layouts/flowlayout/flowlayout.h b/examples/layouts/flowlayout/flowlayout.h index 24f4c4b..192501c 100644 --- a/examples/layouts/flowlayout/flowlayout.h +++ b/examples/layouts/flowlayout/flowlayout.h @@ -49,11 +49,13 @@ class FlowLayout : public QLayout { public: - FlowLayout(QWidget *parent, int margin = -1, int spacing = 0); - FlowLayout(int spacing = 0); + FlowLayout(QWidget *parent, int margin = -1, int hSpacing = -1, int vSpacing = -1); + FlowLayout(int margin = -1, int hSpacing = -1, int vSpacing = -1); ~FlowLayout(); void addItem(QLayoutItem *item); + int horizontalSpacing() const; + int verticalSpacing() const; Qt::Orientations expandingDirections() const; bool hasHeightForWidth() const; int heightForWidth(int) const; @@ -66,8 +68,11 @@ public: private: int doLayout(const QRect &rect, bool testOnly) const; + int smartSpacing(QStyle::PixelMetric pm) const; QList itemList; + int m_hSpace; + int m_vSpace; }; #endif -- cgit v0.12 From 6f7dfdc9a1c6f0b2bc090033f1c315e04dfd6611 Mon Sep 17 00:00:00 2001 From: Denis Dzyubenko Date: Tue, 14 Apr 2009 13:09:00 +0200 Subject: Changelog for 4.5.1 (cherry picked from commit c4846a0e62482abb28cdc973fb4823be3e71f4f7) --- dist/changes-4.5.1 | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index dd81f7c..0b06315 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -195,6 +195,14 @@ Third party components * [250388] Fixed potential crash in QWidget::scroll() when using the raster graphics system. +- QWidget + * [246852] Better handling WindowMaximizeButtonHint for widget with + layouts. + +-QLocale + * String-to-number conversion functions are now ignore trailing and + leading whitespaces in all locales as it is documented. + - QWizard * [248107] Fixed bug on Vista causing Back button to connect twice to the back() signal. @@ -222,6 +230,37 @@ Third party components Qt for Linux/X11 ---------------- + * Proper resetting input contexts when switching between multiple + input context plugins. + + * [244337] Improved input method handling when the widgets native + window id is recreated. + + * Input methods preedit strings are properly reset when user + switches focus without commiting a string. + + * [244607] Current focus widget is properly set and input method is + properly initialized when showing a toplevel that accepts + keyboard input. + + * Unicode conversion functions will handle Latin-1 character set + only if they are used before QCoreApplication/QApplication is + constructed. + + * Improved handling of failed unicode conversion. + + * [232632] Fixed reparenting widgets to a difference X11 screen. + + * [241888] The background of the drag-n-drop cursor is respected + according to the stylesheet. + + * Fixed clipboard handling when the user manually creates an + instance of the QDesktopWidget. + + * [226048] Fixed emitting a QDesktopWidget::resized() signal when + new screen appears or screen geometry is changed without + affecting the whole desktop geometry. + - Phonon/GStreamer * [244259] Fixed a problem where the backend would fail to indicate an error when streaming fails. @@ -263,6 +302,9 @@ Qt for Linux/X11 Qt for Windows -------------- + * [243583] Improved drag-and-drop handling when switching mouse + buttons fast. + - QCoreApplication * [247401] Fixed a bug that would cause a restarted timer to fire too early, causing Javascript in QtWebKit to consume 100% CPU on -- cgit v0.12 From 53297e17ee5cd602078d1fdcb51b6b326e46a4a5 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Wed, 15 Apr 2009 15:26:16 +0200 Subject: add some comments (cherry picked from commit 4f66b3c550ca1c90c33952ad8603cc6c1a702280) --- tools/linguist/shared/ui.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/linguist/shared/ui.cpp b/tools/linguist/shared/ui.cpp index 02a3539..d30f6e5 100644 --- a/tools/linguist/shared/ui.cpp +++ b/tools/linguist/shared/ui.cpp @@ -95,7 +95,7 @@ bool UiReader::startElement(const QString &namespaceURI, Q_UNUSED(namespaceURI); Q_UNUSED(localName); - if (qName == QLatin1String("item")) { + if (qName == QLatin1String("item")) { // UI3 menu entries flush(); if (!atts.value(QLatin1String("text")).isEmpty()) m_source = atts.value(QLatin1String("text")); @@ -123,15 +123,15 @@ bool UiReader::endElement(const QString &namespaceURI, m_accum.replace(QLatin1String("\r\n"), QLatin1String("\n")); - if (qName == QLatin1String("class")) { + if (qName == QLatin1String("class")) { // UI "header" if (m_context.isEmpty()) m_context = m_accum; } else if (qName == QLatin1String("string") && m_isTrString) { m_source = m_accum; - } else if (qName == QLatin1String("comment")) { + } else if (qName == QLatin1String("comment")) { // FIXME: what's that? m_comment = m_accum; flush(); - } else if (qName == QLatin1String("function")) { + } else if (qName == QLatin1String("function")) { // UI3 embedded code fetchtrInlinedCpp(m_accum, m_translator, m_context); } else { flush(); -- cgit v0.12 From 7c49be8d8053532bd4c42eff4536c18366f8208a Mon Sep 17 00:00:00 2001 From: Olivier Goffart Date: Tue, 14 Apr 2009 18:48:02 +0200 Subject: Fixes QSortFilterProxyModel not reporting child if the model need to fetchMore QSortFilterProxyModel::hasChildren need to construct the mapping. And when it tries to construct the mapping, it needs to fetch the childs, so there is none. Task-number: 250023 Reviewed-by: Marius Bugge Monsen (cherry picked from commit fd5f83e612729cebc5395c992bd98628bb9ea25f) --- src/gui/itemviews/qsortfilterproxymodel.cpp | 3 + .../tst_qsortfilterproxymodel.cpp | 87 ++++++++++++++++++++++ 2 files changed, 90 insertions(+) diff --git a/src/gui/itemviews/qsortfilterproxymodel.cpp b/src/gui/itemviews/qsortfilterproxymodel.cpp index 7cef88f..e49f40a 100644 --- a/src/gui/itemviews/qsortfilterproxymodel.cpp +++ b/src/gui/itemviews/qsortfilterproxymodel.cpp @@ -274,6 +274,9 @@ IndexMap::const_iterator QSortFilterProxyModelPrivate::create_mapping( Mapping *m = new Mapping; + if (model->canFetchMore(source_parent)) + model->fetchMore(source_parent); + int source_rows = model->rowCount(source_parent); for (int i = 0; i < source_rows; ++i) { if (q->filterAcceptsRow(i, source_parent)) diff --git a/tests/auto/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp b/tests/auto/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp index cf9b4aa..3a3d895 100644 --- a/tests/auto/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp +++ b/tests/auto/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp @@ -131,6 +131,7 @@ private slots: void task247867_insertRowsSort(); void task248868_staticSorting(); void task248868_dynamicSorting(); + void task250023_fetchMore(); protected: void buildHierarchy(const QStringList &data, QAbstractItemModel *model); @@ -2590,6 +2591,92 @@ void tst_QSortFilterProxyModel::task248868_dynamicSorting() } } +class QtTestModel: public QAbstractItemModel +{ + public: + QtTestModel(int _rows, int _cols, QObject *parent = 0): QAbstractItemModel(parent), + rows(_rows), cols(_cols), wrongIndex(false) { } + + bool canFetchMore(const QModelIndex &idx) const { + return !fetched.contains(idx); + } + + void fetchMore(const QModelIndex &idx) { + fetched.insert(idx); + } + + bool hasChildren(const QModelIndex & = QModelIndex()) const { + return true; + } + + int rowCount(const QModelIndex& parent = QModelIndex()) const { + return fetched.contains(parent) ? rows : 0; + } + int columnCount(const QModelIndex& parent = QModelIndex()) const { + return fetched.contains(parent) ? cols : 0; + } + + QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const + { + if (row < 0 || column < 0 || column >= cols || row >= rows) { + return QModelIndex(); + } + QModelIndex i = createIndex(row, column, int(parent.internalId() + 1)); + parentHash[i] = parent; + return i; + } + + QModelIndex parent(const QModelIndex &index) const + { + if (!parentHash.contains(index)) + return QModelIndex(); + return parentHash[index]; + } + + QVariant data(const QModelIndex &idx, int role) const + { + if (!idx.isValid()) + return QVariant(); + + if (role == Qt::DisplayRole) { + if (idx.row() < 0 || idx.column() < 0 || idx.column() >= cols || idx.row() >= rows) { + wrongIndex = true; + qWarning("Invalid modelIndex [%d,%d,%p]", idx.row(), idx.column(), + idx.internalPointer()); + } + return QString("[%1,%2]").arg(idx.row()).arg(idx.column()); + } + return QVariant(); + } + + QSet fetched; + int rows, cols; + mutable bool wrongIndex; + mutable QMap parentHash; +}; + +void tst_QSortFilterProxyModel::task250023_fetchMore() +{ + QtTestModel model(10,10); + QSortFilterProxyModel proxy; + proxy.setSourceModel(&model); + QVERIFY(proxy.canFetchMore(QModelIndex())); + QVERIFY(proxy.hasChildren()); + while (proxy.canFetchMore(QModelIndex())) + proxy.fetchMore(QModelIndex()); + QCOMPARE(proxy.rowCount(), 10); + QCOMPARE(proxy.columnCount(), 10); + + QModelIndex idx = proxy.index(1,1); + QVERIFY(idx.isValid()); + QVERIFY(proxy.canFetchMore(idx)); + QVERIFY(proxy.hasChildren(idx)); + while (proxy.canFetchMore(idx)) + proxy.fetchMore(idx); + QCOMPARE(proxy.rowCount(idx), 10); + QCOMPARE(proxy.columnCount(idx), 10); +} + QTEST_MAIN(tst_QSortFilterProxyModel) #include "tst_qsortfilterproxymodel.moc" -- cgit v0.12 From 41a2b73a4bf5e7e8e1c0af458a120e2cf75f8035 Mon Sep 17 00:00:00 2001 From: Bill King Date: Thu, 16 Apr 2009 13:48:20 +1000 Subject: Add sql changes to 4.5.1 changelog (cherry picked from commit b01d52de1f942755c59e22d50b84dd37ffc8e3fe) --- dist/changes-4.5.1 | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index 0b06315..8d306d9 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -218,10 +218,28 @@ Third party components * Fixed path fill styles (Zack Rusin) * Fixed pre-edit text handling with input methods. +- QSqlTableModel + * [189093] QSqlTableModel did not handle updates when one of the fields + had a NULL value. + * Made setTable() try and use the db's casing of the passed tablename. + **************************************************************************** * Database Drivers * **************************************************************************** + * Fixed DB2 driver returning double field as empty + * Fixed memory leak in DB2 driver + * [249059] Fixed QPSQL datetime/time fields with negative timezone offsets + not being handled correctly. + * Fixed DB2 not enquoting table/field names properly. + * Fixed an issue with ODBC & FreeTDS not accepting quotes in statements. + * Fixed sqlite2 driver not returning false on failing to exec a statement. + * PrecisionPolicy now works in the oracle driver. + * Fixed ODBC driver returning a list of tables when requested. + * Fixed Interbase retrieving scale/precision information on numeric/decimal fields. + * Stopped drivers doing quoting again when escapeIdentifier called twice. + * Fixed sqlite2 driver not quoting fields correctly. + * [232769] Fixed memory overflow issue on bound out strings in ODBC Driver **************************************************************************** * Platform Specific Changes * -- cgit v0.12 From d3005bd5eca03834a5563469ad844a1041e29317 Mon Sep 17 00:00:00 2001 From: "Bradley T. Hughes" Date: Thu, 16 Apr 2009 08:45:58 +0200 Subject: QX11Embed crashes on 64-bit Solaris The data passed to XChangeProperty should be long arrays, as this is what Xlib expects. Task-number: 244062 Reviewed-by: Rhys Weatherley (cherry picked from commit 1ae4c7b989b04f89a5069d5a5db78c0d8914972b) --- src/gui/kernel/qx11embed_x11.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/gui/kernel/qx11embed_x11.cpp b/src/gui/kernel/qx11embed_x11.cpp index 22cae87..f991275 100644 --- a/src/gui/kernel/qx11embed_x11.cpp +++ b/src/gui/kernel/qx11embed_x11.cpp @@ -481,7 +481,7 @@ QX11EmbedWidget::QX11EmbedWidget(QWidget *parent) | ExposureMask | StructureNotifyMask | SubstructureNotifyMask | PropertyChangeMask); - unsigned int data[] = {XEMBED_VERSION, XEMBED_MAPPED}; + long data[] = {XEMBED_VERSION, XEMBED_MAPPED}; XChangeProperty(x11Info().display(), internalWinId(), ATOM(_XEMBED_INFO), ATOM(_XEMBED_INFO), 32, PropModeReplace, (unsigned char*) data, 2); @@ -1571,7 +1571,7 @@ void QX11EmbedContainer::showEvent(QShowEvent *) { Q_D(QX11EmbedContainer); if (d->client) { - unsigned int data[] = {XEMBED_VERSION, XEMBED_MAPPED}; + long data[] = {XEMBED_VERSION, XEMBED_MAPPED}; XChangeProperty(x11Info().display(), d->client, ATOM(_XEMBED_INFO), ATOM(_XEMBED_INFO), 32, PropModeReplace, (unsigned char *) data, 2); } @@ -1587,8 +1587,7 @@ void QX11EmbedContainer::hideEvent(QHideEvent *) { Q_D(QX11EmbedContainer); if (d->client) { - unsigned int data[] = {XEMBED_VERSION, XEMBED_MAPPED}; - + long data[] = {XEMBED_VERSION, XEMBED_MAPPED}; XChangeProperty(x11Info().display(), d->client, ATOM(_XEMBED_INFO), ATOM(_XEMBED_INFO), 32, PropModeReplace, (unsigned char *) data, 2); } -- cgit v0.12 From 764a970587cf13943a608ebd8ed8bb9f2996e532 Mon Sep 17 00:00:00 2001 From: Bjoern Erik Nilsen Date: Thu, 16 Apr 2009 10:24:56 +0200 Subject: My 4.5.1 changes. (cherry picked from commit 97ff2bde044838be0d5210a86c2fafd23c05d994) --- dist/changes-4.5.1 | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index 8d306d9..271f25d 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -28,6 +28,19 @@ General Improvements - Embedded Dialogs demo * [246517] Fixed warnings and bugs in hover handling on Mac OS X + +Optimizations +------------- + +- Graphics View has been optimized in several areas + * Improved the performance of QGraphicsItem::clipPath. + * Improved the performance of QGraphicsItem::setPos. + * Improved the performance of QGraphicsItem::effectiveOpacity. + * Improved the performance of QGrahicsScene::items(*). + * Improved update handling. + * Reduced the number of floating point operations. + * Reduced QVariant overhead. + Third party components ---------------------- @@ -316,6 +329,10 @@ Qt for Linux/X11 * Event posted to a thread before it is started are not processed until others events are posted. +- QWidget + * [213512] Fixed a bug that would cause wrong clipping when using the + Qt::WA_PaintOutsidePaintEvent attribute. + Qt for Windows -------------- @@ -331,6 +348,10 @@ Qt for Windows * [248036] Fixed an issue where tool buttons would incorrectly hover when disabled. +- QWidget + * [248391] Fixed a bug that made it impossible to dynamically switch + from QPainter based graphics to native graphics API and back. + - [249576] Fixed a crash when using a combobox with Qt::NoFocus. - [244875] System menu will now be shown for a fullscreen window. - [240891] Corrected the focus behavior of native file dialogs, when application has multiple toplevels. @@ -357,6 +378,7 @@ Qt for Mac OS X * 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.) + * [239043] Fixed a bug that would cause QGraphicsProxyWidget to shrink when moving it. - QDesktopWidget * [244004] Support multiple screens that have different sizes properly. -- cgit v0.12 From 969a54bbd298b34cd160384998ec9e1d2cf5a5fa Mon Sep 17 00:00:00 2001 From: Olivier Goffart Date: Thu, 16 Apr 2009 10:40:11 +0200 Subject: Fix crash in the SQLQueryModel tests Amend fd5f83e612729cebc5395c992bd98628bb9ea25f calling fetchMore in create_mapping was a bad idea bacause it may lead to infinite recurtion Make a special case for hasChildren instead Task-number: 250023 Reviewed-by: Marius Bugge Monsen BT: yes (cherry picked from commit f8fba0d48a1f30540ddf15f0d36f415b192d1d8b) --- src/gui/itemviews/qsortfilterproxymodel.cpp | 7 ++++--- tests/auto/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp | 6 +++++- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/src/gui/itemviews/qsortfilterproxymodel.cpp b/src/gui/itemviews/qsortfilterproxymodel.cpp index e49f40a..011e326 100644 --- a/src/gui/itemviews/qsortfilterproxymodel.cpp +++ b/src/gui/itemviews/qsortfilterproxymodel.cpp @@ -274,9 +274,6 @@ IndexMap::const_iterator QSortFilterProxyModelPrivate::create_mapping( Mapping *m = new Mapping; - if (model->canFetchMore(source_parent)) - model->fetchMore(source_parent); - int source_rows = model->rowCount(source_parent); for (int i = 0; i < source_rows; ++i) { if (q->filterAcceptsRow(i, source_parent)) @@ -1572,6 +1569,10 @@ bool QSortFilterProxyModel::hasChildren(const QModelIndex &parent) const return false; if (!d->model->hasChildren(source_parent)) return false; + + if (d->model->canFetchMore(source_parent)) + return true; //we assume we might have children that can be fetched + QSortFilterProxyModelPrivate::Mapping *m = d->create_mapping(source_parent).value(); return m->source_rows.count() != 0 && m->source_columns.count() != 0; } diff --git a/tests/auto/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp b/tests/auto/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp index 3a3d895..940fbbb 100644 --- a/tests/auto/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp +++ b/tests/auto/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp @@ -2602,7 +2602,11 @@ class QtTestModel: public QAbstractItemModel } void fetchMore(const QModelIndex &idx) { + if (fetched.contains(idx)) + return; + beginInsertRows(idx, 0, rows-1); fetched.insert(idx); + endInsertRows(); } bool hasChildren(const QModelIndex & = QModelIndex()) const { @@ -2613,7 +2617,7 @@ class QtTestModel: public QAbstractItemModel return fetched.contains(parent) ? rows : 0; } int columnCount(const QModelIndex& parent = QModelIndex()) const { - return fetched.contains(parent) ? cols : 0; + return cols; } QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const -- cgit v0.12 From dc2bc84025af766f82fb4fd5a188ee3902583e73 Mon Sep 17 00:00:00 2001 From: Richard Moe Gustavsen Date: Thu, 16 Apr 2009 11:33:54 +0200 Subject: BT: Mac: QtDemo is really sluggish when opening menus This has to do with coalesced updates. The easy fix for now is to fix QtDemo itself, meaning: always use a steady timer for redrawing the viewport of the graphics view (as opposed to let each item on screen calling update whenever they move) Task-number: 250667 Reviewed-by: Trenton Schulz (cherry picked from commit 4aa94a353224c14265446276277a91339f2e415d) --- demos/qtdemo/colors.cpp | 3 +++ demos/qtdemo/menumanager.cpp | 3 --- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/demos/qtdemo/colors.cpp b/demos/qtdemo/colors.cpp index 94e44f3..32f2ad0 100644 --- a/demos/qtdemo/colors.cpp +++ b/demos/qtdemo/colors.cpp @@ -278,6 +278,9 @@ void Colors::parseArgs(int argc, char *argv[]) + "[-low] [-ticker-letters] [-ticker-speed] [-no-ticker-morph] " + "[-ticker-morph-speed] [-ticker-text]"); exit(0); + } else{ + QMessageBox::warning(0, "QtDemo", QString("Unrecognized argument:\n") + s); + exit(0); } } diff --git a/demos/qtdemo/menumanager.cpp b/demos/qtdemo/menumanager.cpp index 8df9eca..369972e 100644 --- a/demos/qtdemo/menumanager.cpp +++ b/demos/qtdemo/menumanager.cpp @@ -184,7 +184,6 @@ void MenuManager::itemSelected(int userCode, const QString &menuName) this->tickerInAnim->startDelay = 2000; this->ticker->useGuideQt(); this->score->queueMovie("ticker", Score::NEW_ANIMATION_ONLY); - this->window->switchTimerOnOff(true); } break; case MENU1: @@ -220,7 +219,6 @@ void MenuManager::itemSelected(int userCode, const QString &menuName) this->score->queueMovie(this->currentInfo + " -buttons", Score::NEW_ANIMATION_ONLY); if (!Colors::noTicker){ this->score->queueMovie("ticker -out", Score::NEW_ANIMATION_ONLY); - this->window->switchTimerOnOff(false); } break; case UP:{ @@ -257,7 +255,6 @@ void MenuManager::itemSelected(int userCode, const QString &menuName) this->ticker->doIntroTransitions = false; this->tickerInAnim->startDelay = 500; this->score->queueMovie("ticker", Score::NEW_ANIMATION_ONLY); - this->window->switchTimerOnOff(true); } } else if (this->currentMenuCode != ROOT) itemSelected(ROOT, Colors::rootMenuName); -- cgit v0.12 From ba33bce47493d05088b31539ededeb392dbebf8d Mon Sep 17 00:00:00 2001 From: Richard Moe Gustavsen Date: Thu, 16 Apr 2009 13:05:47 +0200 Subject: Changelog Changelog (cherry picked from commit b6a50971f51618a3965605d9223c8b2b06c23f29) --- dist/changes-4.5.1 | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index 271f25d..776e2a3 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -383,6 +383,21 @@ Qt for Mac OS X - QDesktopWidget * [244004] Support multiple screens that have different sizes properly. +- QDialog + * [239155] QDialog(foo, Qt::Sheet) with QComboBox have none native behavior. + * [218980] Modeless dialogs should be stacked above normal windows. + * [195904] Parent dialog is displayed on top of its modal child. + +- QFileDialog + * [219844] QFileDialog::getOpenFileName() search buttons lead to crash (native version). + * [225705] QFileDialog::getSaveFileName()'s filter does not display correctly. + +- QMenu + * [228017] QMenu should close when expanding a system menu. + +- Event system + * [210912] ShowEvent not sendt when reshowing a window after it was minimized. + - macdeployqt * The binary packages now includes the macdeployqt tool. * macdeployqt now runs 'strip' on the deployed binaries. @@ -397,6 +412,8 @@ Qt for Mac OS X - 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. +- [223525] Macmainwindow Demo Application (crashfix). + - Document a bit clearer how qt_mac_set_dock_menu() works. -- cgit v0.12 From c02086b100f588b725c355e94effe46a569ab80c Mon Sep 17 00:00:00 2001 From: Joerg Bornemann Date: Thu, 16 Apr 2009 13:09:00 +0200 Subject: change log updated for 4.5.1 (cherry picked from commit 78659fbe2d4ad8a01b41cb485f57b4a66c031fd5) --- dist/changes-4.5.1 | 1 + 1 file changed, 1 insertion(+) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index 776e2a3..dd41ef4 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -430,6 +430,7 @@ Qt for Embedded Linux Qt for Windows CE ----------------- + * [246619] Fixed tap and hold bug for QCheckbox. **************************************************************************** * Compiler Specific Changes * -- cgit v0.12 From 680ee5b476ab67a49484aeb10a1e8da190367dd1 Mon Sep 17 00:00:00 2001 From: Kavindra Devi Palaraja Date: Thu, 16 Apr 2009 16:39:10 +0200 Subject: Doc - Some minor cleanups in the documentation of QInputDialog. Also marked getInt() as since Qt 4.5 and finally modified the StandardDialogs example to reflect the fact that getInteger() is deprecated. Task-number: 251288 Reviewed-by: nrc BT: Yes (cherry picked from commit 08dff2935af2d71f2fe76182079da636c1bb6f5b) --- examples/dialogs/standarddialogs/dialog.cpp | 6 +- src/gui/dialogs/qinputdialog.cpp | 181 +++++++++++++++------------- 2 files changed, 99 insertions(+), 88 deletions(-) diff --git a/examples/dialogs/standarddialogs/dialog.cpp b/examples/dialogs/standarddialogs/dialog.cpp index d62bee2..111ef35 100644 --- a/examples/dialogs/standarddialogs/dialog.cpp +++ b/examples/dialogs/standarddialogs/dialog.cpp @@ -59,7 +59,7 @@ Dialog::Dialog(QWidget *parent) integerLabel = new QLabel; integerLabel->setFrameStyle(frameStyle); QPushButton *integerButton = - new QPushButton(tr("QInputDialog::get&Integer()")); + new QPushButton(tr("QInputDialog::get&Int()")); doubleLabel = new QLabel; doubleLabel->setFrameStyle(frameStyle); @@ -198,8 +198,8 @@ void Dialog::setInteger() { //! [0] bool ok; - int i = QInputDialog::getInteger(this, tr("QInputDialog::getInteger()"), - tr("Percentage:"), 25, 0, 100, 1, &ok); + int i = QInputDialog::getInt(this, tr("QInputDialog::getInteger()"), + tr("Percentage:"), 25, 0, 100, 1, &ok); if (ok) integerLabel->setText(tr("%1%").arg(i)); //! [0] diff --git a/src/gui/dialogs/qinputdialog.cpp b/src/gui/dialogs/qinputdialog.cpp index 3796e71..05f331b 100644 --- a/src/gui/dialogs/qinputdialog.cpp +++ b/src/gui/dialogs/qinputdialog.cpp @@ -424,26 +424,27 @@ void QInputDialogPrivate::_q_currentRowChanged(const QModelIndex &newIndex, /*! \class QInputDialog - \brief The QInputDialog class provides a simple convenience dialog to get a single value from the user. + \brief The QInputDialog class provides a simple convenience dialog to get a + single value from the user. \ingroup dialogs \mainclass - The input value can be a string, a number or an item from a list. A - label must be set to tell the user what they should enter. + The input value can be a string, a number or an item from a list. A label + must be set to tell the user what they should enter. - Four static convenience functions are provided: - getText(), getInt(), getDouble(), and getItem(). All the - functions can be used in a similar way, for example: + Four static convenience functions are provided: getText(), getInt(), + getDouble(), and getItem(). All the functions can be used in a similar way, + for example: \snippet examples/dialogs/standarddialogs/dialog.cpp 3 - The \c ok variable is set to true if the user clicks \gui OK; - otherwise it is set to false. + The \c ok variable is set to true if the user clicks \gui OK; otherwise it + is set to false. \img inputdialogs.png Input Dialogs - The \l{dialogs/standarddialogs}{Standard Dialogs} example shows - how to use QInputDialog as well as other built-in Qt dialogs. + The \l{dialogs/standarddialogs}{Standard Dialogs} example shows how to use + QInputDialog as well as other built-in Qt dialogs. \sa QMessageBox, {Standard Dialogs Example} */ @@ -452,11 +453,13 @@ void QInputDialogPrivate::_q_currentRowChanged(const QModelIndex &newIndex, \enum QInputDialog::InputMode \since 4.5 - This enum describes the different modes of input that can be selected for the dialog. + This enum describes the different modes of input that can be selected for + the dialog. \value TextInput Used to input text strings. \value IntInput Used to input integers. - \value DoubleInput Used to input floating point numbers with double precision accuracy. + \value DoubleInput Used to input floating point numbers with double + precision accuracy. \sa inputMode */ @@ -487,7 +490,8 @@ QInputDialog::~QInputDialog() \brief the mode used for input - This property help determines which widget is used for entering input into the dialog. + This property help determines which widget is used for entering input into + the dialog. */ void QInputDialog::setInputMode(InputMode mode) { @@ -1104,15 +1108,18 @@ void QInputDialog::done(int result) } /*! - Static convenience function to get a string from the user. \a - title is the text which is displayed in the title bar of the - dialog. \a label is the text which is shown to the user (it should - say what should be entered). \a text is the default text which is - placed in the line edit. The \a mode is the echo mode the line - edit will use. If \a ok is nonnull \e *\a ok will be set to true - if the user pressed \gui OK and to false if the user pressed - \gui Cancel. The dialog's parent is \a parent. The dialog will be - modal and uses the specified widget \a flags. + Static convenience function to get a string from the user. + + \a title is the text which is displayed in the title bar of the dialog. + \a label is the text which is shown to the user (it should say what should + be entered). + \a text is the default text which is placed in the line edit. + \a mode is the echo mode the line edit will use. + + If \a ok is nonnull \e *\a ok will be set to true if the user pressed + \gui OK and to false if the user pressed \gui Cancel. The dialog's parent + is \a parent. The dialog will be modal and uses the specified widget + \a flags. This function returns the text which has been entered in the line edit. It will not return an empty string. @@ -1121,11 +1128,11 @@ void QInputDialog::done(int result) \snippet examples/dialogs/standarddialogs/dialog.cpp 3 - \warning Do not delete \a parent during the execution of the dialog. - If you want to do this, you should create the dialog - yourself using one of the QInputDialog constructors. + \warning Do not delete \a parent during the execution of the dialog. If you + want to do this, you should create the dialog yourself using one of the + QInputDialog constructors. - \sa getInteger(), getDouble(), getItem() + \sa getInt(), getDouble(), getItem() */ QString QInputDialog::getText(QWidget *parent, const QString &title, const QString &label, @@ -1149,30 +1156,32 @@ QString QInputDialog::getText(QWidget *parent, const QString &title, const QStri } /*! - Static convenience function to get an integer input from the - user. \a title is the text which is displayed in the title bar - of the dialog. \a label is the text which is shown to the user - (it should say what should be entered). \a value is the default - integer which the spinbox will be set to. \a min and \a - max are the minimum and maximum values the user may choose, - and \a step is the amount by which the values change as the user - presses the arrow buttons to increment or decrement the value. - - If \a ok is nonnull *\a ok will be set to true if the user - pressed \gui OK and to false if the user pressed \gui Cancel. The - dialog's parent is \a parent. The dialog will be modal and uses - the widget \a flags. - - On success, this function returns the integer which has been - entered by the user; on failure, it returns the initial \a value. + \since 4.5 + + Static convenience function to get an integer input from the user. + + \a title is the text which is displayed in the title bar of the dialog. + \a label is the text which is shown to the user (it should say what should + be entered). + \a value is the default integer which the spinbox will be set to. + \a min and \a max are the minimum and maximum values the user may choose. + \a step is the amount by which the values change as the user presses the + arrow buttons to increment or decrement the value. + + If \a ok is nonnull *\a ok will be set to true if the user pressed \gui OK + and to false if the user pressed \gui Cancel. The dialog's parent is + \a parent. The dialog will be modal and uses the widget \a flags. + + On success, this function returns the integer which has been entered by the + user; on failure, it returns the initial \a value. Use this static function like this: \snippet examples/dialogs/standarddialogs/dialog.cpp 0 - \warning Do not delete \a parent during the execution of the dialog. - If you want to do this, you should create the dialog - yourself using one of the QInputDialog constructors. + \warning Do not delete \a parent during the execution of the dialog. If you + want to do this, you should create the dialog yourself using one of the + QInputDialog constructors. \sa getText(), getDouble(), getItem() */ @@ -1198,32 +1207,32 @@ int QInputDialog::getInt(QWidget *parent, const QString &title, const QString &l } /*! - Static convenience function to get a floating point number from - the user. \a title is the text which is displayed in the title - bar of the dialog. \a label is the text which is shown to the user - (it should say what should be entered). \a value is the default - floating point number that the line edit will be set to. \a - min and \a max are the minimum and maximum values the - user may choose, and \a decimals is the maximum number of decimal - places the number may have. - - If \a ok is nonnull, *\a ok will be set to true if the user - pressed \gui OK and to false if the user pressed \gui Cancel. The - dialog's parent is \a parent. The dialog will be modal and uses - the widget \a flags. - - This function returns the floating point number which has been - entered by the user. + Static convenience function to get a floating point number from the user. + + \a title is the text which is displayed in the title bar of the dialog. + \a label is the text which is shown to the user (it should say what should + be entered). + \a value is the default floating point number that the line edit will be + set to. + \a min and \a max are the minimum and maximum values the user may choose. + \a decimals is the maximum number of decimal places the number may have. + + If \a ok is nonnull, *\a ok will be set to true if the user pressed \gui OK + and to false if the user pressed \gui Cancel. The dialog's parent is + \a parent. The dialog will be modal and uses the widget \a flags. + + This function returns the floating point number which has been entered by + the user. Use this static function like this: \snippet examples/dialogs/standarddialogs/dialog.cpp 1 - \warning Do not delete \a parent during the execution of the dialog. - If you want to do this, you should create the dialog - yourself using one of the QInputDialog constructors. + \warning Do not delete \a parent during the execution of the dialog. If you + want to do this, you should create the dialog yourself using one of the + QInputDialog constructors. - \sa getText(), getInteger(), getItem() + \sa getText(), getInt(), getItem() */ double QInputDialog::getDouble(QWidget *parent, const QString &title, const QString &label, @@ -1248,32 +1257,34 @@ double QInputDialog::getDouble(QWidget *parent, const QString &title, const QStr } /*! - Static convenience function to let the user select an item from a - string list. \a title is the text which is displayed in the title - bar of the dialog. \a label is the text which is shown to the user (it - should say what should be entered). \a items is the - string list which is inserted into the combobox, and \a current is the number - of the item which should be the current item. If \a editable is true - the user can enter their own text; if \a editable is false the user - may only select one of the existing items. - - If \a ok is nonnull \e *\a ok will be set to true if the user - pressed \gui OK and to false if the user pressed \gui Cancel. The - dialog's parent is \a parent. The dialog will be modal and uses - the widget \a flags. - - This function returns the text of the current item, or if \a - editable is true, the current text of the combobox. + Static convenience function to let the user select an item from a string + list. + + \a title is the text which is displayed in the title bar of the dialog. + \a label is the text which is shown to the user (it should say what should + be entered). + \a items is the string list which is inserted into the combobox. + \a current is the number of the item which should be the current item. + + If \a editable is true the user can enter their own text; otherwise the + user may only select one of the existing items. + + If \a ok is nonnull \e *\a ok will be set to true if the user pressed + \gui OK and to false if the user pressed \gui Cancel. The dialog's parent + is \a parent. The dialog will be modal and uses the widget \a flags. + + This function returns the text of the current item, or if \a editable is + true, the current text of the combobox. Use this static function like this: \snippet examples/dialogs/standarddialogs/dialog.cpp 2 - \warning Do not delete \a parent during the execution of the dialog. - If you want to do this, you should create the dialog - yourself using one of the QInputDialog constructors. + \warning Do not delete \a parent during the execution of the dialog. If you + want to do this, you should create the dialog yourself using one of the + QInputDialog constructors. - \sa getText(), getInteger(), getDouble() + \sa getText(), getInt(), getDouble() */ QString QInputDialog::getItem(QWidget *parent, const QString &title, const QString &label, -- cgit v0.12 From e78d6b63ace3cbf291fc7e1270157ff7bd355b5d Mon Sep 17 00:00:00 2001 From: Kavindra Devi Palaraja Date: Thu, 16 Apr 2009 16:40:17 +0200 Subject: Doc - Changed the link provided in the README file to one that does not have a version number, so we do not have to update it each release. Task-number: 251352 Reviewed-by: TrustMe (cherry picked from commit 90ff6b0ad7397a6892185e8340d58dab4b85b032) --- examples/tutorials/addressbook/README | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/tutorials/addressbook/README b/examples/tutorials/addressbook/README index 2d528b5..9b7f908 100644 --- a/examples/tutorials/addressbook/README +++ b/examples/tutorials/addressbook/README @@ -4,7 +4,7 @@ Qt documentation, which can be viewed using Qt Assistant or a Web browser. The tutorial is also available online at -http://doc.trolltech.com/4.4/tutorial.html +http://doc.trolltech.com/tutorial.html All programs corresponding to the chapters in the tutorial should automatically be built when Qt is compiled, or will be provided as -- cgit v0.12 From 9376ea8aeeb261fd97d43c56d3f308950aec1122 Mon Sep 17 00:00:00 2001 From: Kavindra Devi Palaraja Date: Thu, 16 Apr 2009 16:41:39 +0200 Subject: Doc - Changed the namespace in the qdocconf file to reflect Qt 4.5.1 Task-number: 251346 Reviewed-by: TrustMe BT: Yes (cherry picked from commit fc8285ec610b02f440f692be90aed1e6925a8675) --- tools/qdoc3/test/qt.qdocconf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/qdoc3/test/qt.qdocconf b/tools/qdoc3/test/qt.qdocconf index 298311e..4d401a4 100644 --- a/tools/qdoc3/test/qt.qdocconf +++ b/tools/qdoc3/test/qt.qdocconf @@ -22,7 +22,7 @@ edition.DesktopLight.groups = -graphicsview-api qhp.projects = Qt qhp.Qt.file = qt.qhp -qhp.Qt.namespace = com.trolltech.qt.450 +qhp.Qt.namespace = com.trolltech.qt.451 qhp.Qt.virtualFolder = qdoc qhp.Qt.indexTitle = Qt Reference Documentation qhp.Qt.indexRoot = -- cgit v0.12 From b2c40a544c7cfcd7e6195b6ade0816b54e20ba64 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Thu, 16 Apr 2009 16:45:45 +0200 Subject: log my changes (cherry picked from commit 602da82d3c9413df41eb5b17bdf7e3c1586316b5) --- dist/changes-4.5.1 | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index dd41ef4..a15bfaa 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -457,12 +457,23 @@ Qt for Windows CE * [245503] Fixed redundant backslashes in string property in property browser. - Linguist + - Linguist GUI - - lupdate + * [248076] Fixed crash upon opening files for which we have no plural rules + * [249519] Fixed crash upon dropping text into non-focused lineedit + + - Entire Linguist toolchain - - lrelease + * [244035] Fixed endless loop in PO writer + * [247738] Improved handling of duplicated messages + * [248849] Fixed encoding in XLIFF writer + * [249022] Fixed TS' and QM's handling of messages which appear in multiple encodings + + - lupdate + * [248724] Fixed encoding of messages from .ui files if CODECFORTR is not utf8 + * [249633] Fixed processing of C++ backslash line continuations - rcc @@ -484,6 +495,7 @@ Qt for Windows CE * [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 + * Fixed moc and uic features to make shadow builds work even if a non-shadow build is present - configure -- cgit v0.12 From 78815e49fa25b40e437c125d73c11fb72aacd90f Mon Sep 17 00:00:00 2001 From: Kavindra Devi Palaraja Date: Thu, 16 Apr 2009 17:18:15 +0200 Subject: First round of change log cleanups. Reviewed-by: TrustMe BT: Yes (cherry picked from commit 0aa3203fa13bfbc42e77488765023832934dd36b) --- dist/changes-4.5.1 | 81 +++++++++++++++++++++++++++++++----------------------- 1 file changed, 46 insertions(+), 35 deletions(-) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index a15bfaa..e3aa57c 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -24,6 +24,11 @@ General Improvements -------------------- - Documentation and Examples + * Added printing feature for the Spreadsheet demo. + * [245675] Clarified the differences between QItemDelegate and + QStyledItemDelegate. + * [248752] Marked QPrintDialog::printer(), setPrinter() and addButton() + as Unix only functions, part of Qt3Support. - Embedded Dialogs demo * [246517] Fixed warnings and bugs in hover handling on Mac OS X @@ -50,90 +55,96 @@ Third party components **************************************************************************** - QAbstractItemModel - * [243195] Clrarified some warning messages printed if the model is invalid. + * [243195] Clarified some warning messages printed if the model is invalid. - QAbstractEventDispatcher - * [248805] Duplicates timerid could happen when timer are running while - the QObject is moved to another thread, and would stop timers from working. + * [248805] Duplicate timerids could occur when a timer is running while + the QObject is moved to another thread, stopping timers from working. - QAbstractSocket - * [192037] Emit disconnected only if we were connected before + * [192037] Emit the disconnected signal 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 "&&". + * [241161] Fixed a bug in browsing menus with the keyboard. + * [221731] Fixed a bug where the accessibility plugin could crash if + there was an "&" at the end or spin forever if a label had a sequence of + "&&". - QAtomicInt - * [216492] Fix compilation on 64-bit PowerPC machines with gcc 4.3. + * [216492] Fixed compilation on 64-bit PowerPC machines with gcc 4.3. - QAuthenticator - * [237979] fix implemenation of md5-sess + * [237979] Fixed implementation of md5-sess. - QByteArray - * [246233] QByteArray::fromHex() fails with input of size 1 + * [246233] QByteArray::fromHex() fails with input of size 1. - QColorDialog - * [247349] Fixed bug causing the wrong alpha value to be returned. + * [247349] Fixed a bug causing the wrong alpha value to be returned. - QCombobox - * [248094] Fixed scrollbar appearing while not required. + * [248094] Fixed scrollbar from appearing when not required. - QCompleter - * [250064] Fixed focus policy propagation regression. - * [246056] Fixed assertion failure in setCompletionPrefix(). + * [250064] Fixed a focus policy propagation regression. + * [246056] Fixed an assertion failure in setCompletionPrefix(). - QtConcurrent - * [244718] Reduce the number of calls to QThread::idealThreadCount(). + * [244718] Reduced the number of calls to QThread::idealThreadCount(). - QDirIterator - * [247645] Fix a bug that may loose all cached data inside the QFileInfo + * [247645] Fixed a bug that may loose all cached data inside QFileInfo. - QFile - * [244500] QFile::rename() doesn't always return false when the method fails - * [244485] Renaming a file does not change QFile::fileName() + * [244500] QFile::rename() does not 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 + * [205244] Return valid file info also for relative UNC paths. - QFileDialog - * [250194] QFileDialog and QSortFilterProxyModel index mapping issue - * [248332] QFileDialog is slow after visiting a large directory - * [221323] QFileDialog programatical file selection bug + * [250194] Fixed an issue with QFileDialog and QSortFilterProxyModel + index mapping. + * [248332] QFileDialog is slow after visiting a large directory. + * [221323] QFileDialog programmatical file selection bug. - QGraphicsItem - * [247890] Cached QGraphicsItems are not updated if update() is called when they are hidden + * [247890] Cached QGraphicsItems are not updated if update() is called + when they are hidden. * [250272] When an item is deleted it does not get removed from the - sceneeventfilters meaning a crash can occur - * Fixed slowdown regression in QGraphicsItem::ItemCoordinateCache + sceneeventfilters, meaning a crash can occur. + * Fixed a slow down regression in QGraphicsItem::ItemCoordinateCache. - QGraphicsGridLayout - * [242472] Fix a bug where the calculation of the maximum width of a column - was not calculated correctly. + * [242472] Fixed a bug where the calculation of the maximum width of a + column was incorrect. - QGraphicsScene - * [243707] Fixed crash when adding child before parent to scene + * [243707] Fixed a crash when adding child before parent to scene. --QGraphicsView - * [245766] Rubber Band drag mode not updated correctly when scrolling +- QGraphicsView + * [245766] Rubber Band drag mode does not update 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 + * [208445] Cancel request upon receiving unknown authentication method. - QHostAddress - * [247330] Fix compilation on MinGW by adding a missing QPair include. + * [247330] Fixed compilation on MinGW by adding a missing QPair include. - QLocalSocket - * Fix a bug that would cause QLocalSocket to disconnect 30 seconds + * Fixed a bug that would cause QLocalSocket to disconnect 30 seconds after a succesful delayed connection on UNIX. - QMacStyle - * [248769] Fix regression where QMacStyle would only draw tabs when passed a QStyleOptionTabV3. - * Adjust the opacity value for popups. + * [248769] Fixed a regression where QMacStyle would only draw tabs when + passed a QStyleOptionTabV3. + * Adjusted the opacity value for popups. - QMainWindow * [248048] Fix a regression that would cause tooltips to disappear when using the unified toolbar. -- cgit v0.12 From 6574991f7b17f1d627e67fc5de1eed09b5c2e095 Mon Sep 17 00:00:00 2001 From: Norwegian Rock Cat Date: Thu, 16 Apr 2009 17:15:16 +0200 Subject: BT:Stop widgets disappearing in unified when clicking the toolbar button The comment in the code pretty much says it all, so I'll repeat it: This is a workaround for NSToolbar. When a widget is hidden by clicking the toolbar button, Cocoa reparents the widgets to another window (but Qt doesn't know about it). When we start showing them, it reparents back, but at this point it's window is nil, but the window it's being brought into (the Qt one) is for sure created. This stops the hierarchy moving under our feet. Task-number: 251294 Reviewed-by: Prasanth Ullattil (cherry picked from commit 139265031939d676f049edd2c91918040e0659b4) --- src/gui/kernel/qwidget_mac.mm | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/gui/kernel/qwidget_mac.mm b/src/gui/kernel/qwidget_mac.mm index aa1f736..43f6725 100644 --- a/src/gui/kernel/qwidget_mac.mm +++ b/src/gui/kernel/qwidget_mac.mm @@ -465,7 +465,18 @@ Q_GUI_EXPORT OSWindowRef qt_mac_window_for(const QWidget *w) if (hiview){ OSWindowRef window = qt_mac_window_for(hiview); if (!window && qt_isGenuineQWidget(hiview)) { - w->window()->d_func()->createWindow_sys(); + QWidget *myWindow = w->window(); + // This is a workaround for NSToolbar. When a widget is hidden + // by clicking the toolbar button, Cocoa reparents the widgets + // to another window (but Qt doesn't know about it). + // When we start showing them, it reparents back, + // but at this point it's window is nil, but the window it's being brought + // into (the Qt one) is for sure created. + // This stops the hierarchy moving under our feet. + if (myWindow != w && qt_mac_window_for(qt_mac_nativeview_for(myWindow))) + return qt_mac_window_for(qt_mac_nativeview_for(myWindow)); + + myWindow->d_func()->createWindow_sys(); // Reget the hiview since the "create window could potentially move the view (I guess). hiview = qt_mac_nativeview_for(w); window = qt_mac_window_for(hiview); -- cgit v0.12 From 822647ae6c7720f3dc76b3aece4e330eb1780aa4 Mon Sep 17 00:00:00 2001 From: Rhys Weatherley Date: Fri, 17 Apr 2009 08:10:29 +1000 Subject: Document my changes for 4.5.1 (cherry picked from commit 90d7509e4a1543e43a49bfb25dd672d824c4fde3) --- dist/changes-4.5.1 | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/dist/changes-4.5.1 b/dist/changes-4.5.1 index e3aa57c..0b8dae2 100644 --- a/dist/changes-4.5.1 +++ b/dist/changes-4.5.1 @@ -133,6 +133,8 @@ Third party components - QHttp * [208445] Cancel request upon receiving unknown authentication method. + * Compile fixes for QT_BEGIN_NAMESPACE being in the wrong place in + some private headers. - QHostAddress * [247330] Fixed compilation on MinGW by adding a missing QPair include. @@ -168,6 +170,8 @@ Third party components * [247505] Fix missing fills of rectangles with negative width/height in raster paint engine. * [249628] Fix crash in OpenGL paint engine when filling using Qt::NoBrush. + * Compile fixes for OpenGL paint engine on OpenGL/ES 1.1 CommonLite + and OpenGL/ES 1.0. - QPixmap * [249175] Fix QPixmap::fromImage() of monochrome images to result in @@ -437,6 +441,8 @@ Qt for Embedded Linux --------------------- - Various improvements to the Qt DirectFB plugin. +- Fix recreation of temporary EGL surfaces in PowerVR gfxdriver. +- Document some necessary #define's for building the PowerVR gfxdriver. Qt for Windows CE ----------------- -- cgit v0.12