summaryrefslogtreecommitdiffstats
path: root/src/widgets
Commit message (Collapse)AuthorAgeFilesLines
* Update copyright year in Digia's license headersSergio Ahumada2013-01-18599-602/+602
| | | | | Change-Id: Ic804938fc352291d011800d21e549c10acac66fb Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Merge remote-tracking branch 'gerrit/release' into stableFrederik Gladhorn2013-01-154-3/+9
|\ | | | | | | Change-Id: Ieb104d0e390218a063082c93bc9c7e412af2166d
| * Check for existence of QWindow in QApplication::isBlockedByModal.Friedemann Kleint2013-01-151-1/+6
| | | | | | | | | | | | | | | | | | | | Warn if window == 0 is passed in QApplicationPrivate::isWindowBlocked(). Task-number: QTBUG-28637 Change-Id: I1213ea371813eeb90f962cc39235ddfccc663d45 Reviewed-by: Jing Bai <jing.bai@digia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
| * QStyleAnimation: use QAbstractAnimation::DeleteWhenStoppedJ-P Nurmi2013-01-122-2/+1
| | | | | | | | | | | | | | | | | | | | This ensures that unexpectedly stopped (for example, when minimizing a window) style animations are removed from QCommonStyle. Task-number: QTBUG-28978 Change-Id: I1403502d85e0614d8644892a2231938c29a8c9c2 Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com> Reviewed-by: Kai Koehne <kai.koehne@digia.com>
| * Minimized, maximized and fullscreen are mutually exclusive.Shawn Rutledge2013-01-111-0/+2
| | | | | | | | | | | | | | | | | | | | Only if minimized does QWidgetWindow need to remember the previous state. Maybe it's OK to restore from fullscreen to maximized though. Task-number: QTBUG-29030 Change-Id: I1e2724c8811366c9536a3e372ce281e8d473a4ac Reviewed-by: J-P Nurmi <jpnurmi@digia.com> Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
* | set gtk-entry im-module to none in gtkstyleWeng Xuetian2013-01-141-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | in qt5, gtkstyle use gtk_widget_send_focus_change, this had a side effect that will trigger real gtk im module, if qt load the same qt and gtk im module for same input method, it will cause conflicts for qt im module. The only gtk widget have im-module property is GtkEntry and GtkTextView, since only GtkEntry is used here, we only need to override im-module for GtkEntry. gtk-im-context-none exists in gtk+ since 2.19.5, and for older version, it will also harmlessly fallback to gtk-im-context-simple. Change-Id: I4ffb93453e77c8d5db3349b084342bdca8e4a571 Reviewed-by: Liang Qi <liang.qi@digia.com> Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
* | QMenu: Fix nested popup when keyboard shortcut is usedOrgad Shaneh2013-01-141-1/+1
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-20403 Change-Id: I2a5fe00dd16e9dc1ec0d742a8f48083fc2954996 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Jarek Kobus <jaroslaw.kobus@digia.com>
* | Docs: fix the minimum required GTK+ versionJ-P Nurmi2013-01-141-1/+1
| | | | | | | | | | | | | | | | The minimum GTK+ version was bumped from from 2.10 to 2.18 (sep 2009) in commit 2cce297b58ae50486094a6dcc148484a4a4bace5. Change-Id: I77a48c8a3b0955b00e399f714949d08293abbebd Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* | Fix memory leak in windows vista styleJian Liang2013-01-111-3/+21
| | | | | | | | | | | | | | | | | | | | | | Introduce a function named deleteClonedAnimationStyleOption() in qwindowsvistastyle.cpp to delete style option cloned by clonedAnimationStyleOption() to prevent object leak which is hold by the actual style option object. Change-Id: I1afd95ddab237059ce3460ac0b52a65de102eaa5 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* | Doc: corrected typo "the the"Nico Vertriest2013-01-117-7/+7
| | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-28756 Spurious repetition of the definite article Trailing space issue corrected. Change-Id: I3a051f5dc291e546d8d67d6775e84b388bdc0363 Reviewed-by: Topi Reiniö <topi.reinio@digia.com> Reviewed-by: Geir Vattekar <geir.vattekar@digia.com>
* | Fix QVariant in a static build.Jędrzej Nowacki2013-01-101-0/+4
| | | | | | | | | | | | | | | | | | The patch cases registration of QVariant handler for widgets. Task-number: QTBUG-28528 Change-Id: I645e8054bb96db0b92edf5df36f206ec1965ad40 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* | Use pos() if the widget is a child of a native windowAndy Shaw2013-01-101-3/+6
| | | | | | | | | | | | | | | | | | | | If the widget is embedded in a native window then pos() should be used instead of mapToGlobal() so that the right position is used. This was reproduced with the qtwinmigrate solution as the dialogs were not centered correctly. Change-Id: I2ce7771f8c1a73aa74ab11faf4f9c57b922eefab Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* | Update translucency correctly in QtWidgets.Friedemann Kleint2013-01-091-2/+9
| | | | | | | | | | | | | | | | | | | | | | Fixes breakage introduced by cdc436ebe625153c626784a15cb224556fca3728 . Top level widgets with translucent backgrounds were invisible since opacity was set to 0. Task-number: QTBUG-28531 Change-Id: I97058ac1b971422f3bda3a5ffed479ec55bfe5d4 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* | Compile in 32-bit mode.Morten Johan Sørvig2013-01-091-2/+2
| | | | | | | | | | | | | | CGRect == NSRect only in 64-bit mode. Change-Id: I069b5b050ccf02654a65375c3ab0f58f7d5cc659 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* | Don't scale 0-region or region without rectsTor Arne Vestbø2013-01-091-0/+3
|/ | | | | Change-Id: Ieb523dadc5d726e26645b3a90652be95c2707ea8 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* Replace macro qdoc with Q_QDOCDebao Zhang2013-01-081-1/+1
| | | | | | | | Both qdoc and Q_QDOC are used in source code, which looks not good. Change-Id: I4f3a71670278b0758d92bfa5db086a07e1b1acfd Reviewed-by: hjk <qthjk@ovi.com> Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* QWindowsVistaStyle: fix frame renderingJ-P Nurmi2013-01-071-22/+26
| | | | | | | | | | A regression caused by 79a389 - it should only draw a styled frame for text input widgets. Task-number: QTBUG-28876 Change-Id: I5cda920b7db55f35e0ab6cee460c0e27951d29b9 Reviewed-by: Jonathan Liu <net147@gmail.com> Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Add QStyleHelper:isInstanceOf()J-P Nurmi2013-01-072-3/+16
| | | | | | | Task-number: QTBUG-28876 Change-Id: I343dff1c47c52e0431c09b6097da09f34e626f54 Reviewed-by: Jonathan Liu <net147@gmail.com> Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Do not send QAccessible::Focus when current index is changed.Jan Arve Saether2013-01-041-3/+5
| | | | | | | | | | | | This had the unfortunate side-effect that focus was reported to change (but it didn't) just because the qtabbar was shown. Found by clicking the different categories on the left-hand side of the options dialog in Qt Creator. So, what happened was that clicking "Text Editor" would move the accessibility focus (that the AT client saw) to the "Font & Colors" tab) Change-Id: I19a508f6a32a77696079d24c3c6408cb6c3d9fd5 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Fix QGuiApplication::keyboardModifiers() and QGuiApplication::mouseButtons()Jon Severinsson2013-01-041-7/+39
| | | | | | | | | | | | | | | | | Previous commit b2363a935c8dac fixed keyboardModifiers() after QPA event processing, but broke QTestLib, which expects spontaneous input events sent to qApp->notify() to update keyboardModifiers() and mouseButtons(). The commit also did not fix mouseButtons() after QPA event processing, and missed keyboardModifiers() after QPA Tablet event processing. This commit fixes all these shortcommings in b2363a935c8dac. Includes test case by David Faure <faure@kde.org> Task-Number: QTBUG-26887 Change-Id: I8518b06c4ce86ea7b35120e3353a45ea2a81d356 Reviewed-by: David Faure (KDE) <faure@kde.org> Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* QGtkStyle: exclude Xlib calls on MacJ-P Nurmi2013-01-031-1/+10
| | | | | | | Task-number: QTBUG-28769 Change-Id: I3f83b6011acf43e5136a762d0f8841b3a910cecb Reviewed-by: Andy Shaw <andy.shaw@digia.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Fix warning found by clang:Thiago Macieira2012-12-311-1/+1
| | | | | | | | kernel/qwidgetsfunctions_wince.h:61:34: error: no newline at end of file [-Werror,-Wnewline-eof] Change-Id: Icbc35227946652db53fc8454d1d42043aa7c15b9 Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Remove unused function _q_qgraphicsItemSetFlagThiago Macieira2012-12-291-18/+0
| | | | | | | | | | | | | | | Clang reports: graphicsview/qgraphicsitem.cpp:1779:13: error: function '_q_qgraphicsItemSetFlag' is not needed and will not be emitted [-Werror,-Wunneeded-internal-declaration] static void _q_qgraphicsItemSetFlag(QGraphicsItem *item, QGraphicsItem::GraphicsItemFlag flag, ^ According to the public Git history, in Qt 4.5.1 this function was already unused. The only reason it wasn't caught so far is that it is recursive: it calls itself. So it is used... by itself. Change-Id: I6fc6b33cb314b845525dc9315d0ad742e113d5cd Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Fix warnings reported by Clang in QtWidgetThiago Macieira2012-12-291-1/+1
| | | | | | | | | | qwizard.cpp:919:24: error: equality comparison with extraneous parentheses [-Werror,-Wparentheses-equality] if ((info.wizStyle == QWizard::AeroStyle) ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~ Change-Id: I477cc4e331633682b79df3cb0113558e9019280c Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Fixed typo 'collasping' in QTreeView documentationThorbjørn Lindeijer2012-12-281-1/+1
| | | | | | Change-Id: Ib49c3500c4b3a40a7eaf17404cecc2c38de90530 Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com> Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* Mac: Bring back proper layout in QMessageBoxGabriel de Dietrich2012-12-242-16/+16
| | | | | | | | Resolved by s/Q_WS_MAC/Q_OS_MAC where appropriate. Task-number: QTBUG-28738 Change-Id: I8f1239839bffb092387d527af78e9dbe1628ef67 Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Bump Qt version to 5.0.1Sergio Ahumada2012-12-211-5/+5
| | | | | Change-Id: Ie8f437b8dfe8a67c7b34321439dd988a02612437 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix some typosSergio Ahumada2012-12-212-2/+2
| | | | | Change-Id: I4e8d9bd8ea66ec810e4f1fbfd8ddbf25c4b3d980 Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
* Mac: fix transient QScrollBar flashingJ-P Nurmi2012-12-201-1/+1
| | | | | | Task-number: QTBUG-28669 Change-Id: I9825584f15c34709f7897533220911b6bf3ea21d Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Style animations: fix QCommonStylePrivate::stopAnimation()J-P Nurmi2012-12-201-1/+3
| | | | | | | | | | Explicitly delete animations, and remove the check for stopped state as that is already done by QAbstractAnimation::stop() and we want to delete the animation regardless of the current state. Task-number: QTBUG-28506 Change-Id: I3e34316e5077a8627ff5e6d3babd1873bbbaa774 Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Mac: Ignore ScrollBarAlwaysOn policy for transient scrollbarsGabriel de Dietrich2012-12-191-11/+14
| | | | | Change-Id: I8a542263df64a21cad6b8cddc5ab1d8a93e153d5 Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Mac: New rendering for disclose triangle, get proper color when selectedGabriel de Dietrich2012-12-192-16/+27
| | | | | Change-Id: I2be0a28df3f5dd2fdfae13be6ec98763a04187c1 Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Check for gtk_adjustment_configure as this is not always implementedAndy Shaw2012-12-191-1/+3
| | | | | | | | | | | | | Some implementations seem to not have the gtk_adjustment_configure function implemented so we check for this so that there is no problem when it tries to use it. Task-number: QTBUG-23569 QTBUG-25760 Change-Id: I777ce09268f86907f3da3cede408c9a41be566cf Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com> Reviewed-by: Karim Pinter <karim.pinter@digia.com>
* Accessibility indexes are no longer 1-based.Frederik Gladhorn2012-12-181-5/+5
| | | | | | | | | | The updates for focus/selection in QTreeView were still adding +1 as it was required in Qt 4. Task-number: QTBUG-28174 Change-Id: Ib9fea7e20d431a0ef0db18494e7bdda06a0646b0 Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Fix focusproxy-relayed crash in QGraphicsItem destructor.Andreas Aardal Hanssen2012-12-171-0/+1
| | | | | | | | | | | | | | | | | | | | Makes tst_qgraphicsitem::tst_focusProxyDeletion not crash. valgrind reported the error when running tst_qgraphicsitem. The crash was very real; when deleting an item that has another item as a focus proxy, the proxy still had a reference to the deleted item's focusProxy pointer. I'm not a huge fan of whitebox testing but thought this crash justifies a modification of the test to make it fail, instead of just passing silently with a warning only given by valgrind and friends. FTR the reason the test doesn't crash hard is that the memory is freed but not reused within the scope of the test. So the access to the pointer d_ptr->focusProxy succeeds, it just accesses memory that might as well have been reclaimed. But this is quite undefined... Task-number: QTBUG-28321 Change-Id: I2624631f5e5c2a8aa8bd4efe1fc128eba6c61f56 Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Accessibility: Activate in QGuiApp instead of QApp.Frederik Gladhorn2012-12-161-4/+0
| | | | | | | | This makes it possible to use accessibility with QQuickWindow. Change-Id: I5fccd5f25021c4953b03e146705f48a198dbaaa7 Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Call QAccessible::updateAccessibility when caret moves in QTextEditJosé Millán Soto2012-12-163-1/+16
| | | | | Change-Id: I3b9e5d8e67b4928558b642a4d23aa60ae9dfde60 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Remove unused private member.Frederik Gladhorn2012-12-141-2/+0
| | | | | | Change-Id: I54f3f748763dd5959552df864af38558c136dc87 Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* add missing include when Q_NO_USING_KEYWORD is definedJing Bai2012-12-141-0/+3
| | | | | | Task-number: QTBUG-28446 Change-Id: I348de023035a15f3c769610abdaf0ebd7273ca34 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix empty window title regression, add application display name to window titleDavid Faure2012-12-141-31/+8
| | | | | | | | | | | | | | | This increases consistency a lot: all windows and dialogs from a Qt application will show the app display name in the caption, on Windows and X11. This helps identifying which app a dialog belongs to, which is especially useful when the dialog is very generic and shows up unexpectedly. For compatibility reasons, the app name is added to the caption only if setApplicationDisplayName() was called -- or if the caption would be completely empty. The standard Qt4 case (setWindowTitle + no display name) is unchanged. Change-Id: Ib284c62c1f4c0bc923e5bc2d10247d95e9aa76c1 Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
* Fix QGtkPainter::reset() to reset the clip rectJ-P Nurmi2012-12-131-0/+1
| | | | | | | | | | | | Due to preparation for GTK3 support, QGtkStyle::drawXxx() no longer creates a local instance of QGtkPainter upon every call, but QGtkStylePrivate::gtkPainter() will (in the future) dynamically choose between QGtk[2|3]Painter. The same painter instance is now re-used between the calls, but wasn't properly reseted between. Task-number: QTBUG-28557 Change-Id: I29be318dbb54d97ed23dfb88d406a3a833db4369 Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Fix QWidget::setWindowOpacity() when called before show().Friedemann Kleint2012-12-121-2/+1
| | | | | | | | | Pass opacity from the QWidget to QWindow and to the platform windows. Task-number: QTBUG-28477 Change-Id: If5a85d9183bd1ca33dac2052936ecd1e6c0b5f6c Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
* QMenu: Do not set snapToMouse if a caused-widget exists.Friedemann Kleint2012-12-121-1/+1
| | | | | | | | | | | | When clicking at the bottom-right corner of a menu in a menu bar, it appears at the wrong position. Add test and stabilize RTL-tests by making sure the layout direction is cleared should they fail. Task-number: QTBUG-28031 Task-number: QTBUG-2596 Change-Id: Ibc5ae916388753908e9f3ee98e8859faaa0c8723 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Mac: disable transient scrollbar animations for non-QScrollBarsJ-P Nurmi2012-12-113-8/+12
| | | | | | | | Task-number: QTBUG-28389 Task-number: QTBUG-28380 Change-Id: I91edd9c8aba60118d722bbf9ad5b85f994398823 Reviewed-by: J-P Nurmi <jpnurmi@digia.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* QApplication docs: restore console mode -snippetJ-P Nurmi2012-12-112-14/+25
| | | | | Change-Id: I1f8ce949ae660a209a2092a2863d5c25e2908004 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* QScrollBar::initStyleOption(): fix QStyle::State_On handlingJ-P Nurmi2012-12-111-1/+1
| | | | | | | | | | | | | QWindowsStyle considers QStyle::State_On as pressed, whereas QMacStyle uses the same state for transient scrollbars. Thus, to indicate transient scrollbars, QScrollBar::initStyleOption() must set QStyle::State_On only when the current style actually supports transient scrollbars. Task-number: QTBUG-28523 Change-Id: I94d207b1e8c5c4bd6f4b99e8b4f1661197fbe9dd Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* QGraphicsView - fix rubberband to expand on wheel eventThorbjørn Lund Martsum2012-12-111-4/+4
| | | | | | | | | | | | | | | | | In SHA 51914375b615ddcac711171ac31779fea01b4323 the rubberband selection was fixed, so it followed the scene-point on mousemove. However wheelEvent could move the view - but avoid update of the rubberband (that would not be updated until next mouse-move). This patch fixes that (and generally improves rubberband behavior) since QGraphicsViewPrivate::mouseMoveEventHandler is called by replayLastMouseEvent, which is called from various places, where we need to update the rubberband (e.g scrollContentsBy). Change-Id: I1b78c27edaaecea797a2319086d7a11d437d2bd3 Reviewed-by: Andy Shaw <andy.shaw@digia.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* QGraphicsView - move rubberband-handling into a private functionThorbjørn Lund Martsum2012-12-112-48/+55
| | | | | | | | | | | | | This patch moves the rubberband-handling from QGraphicsView::mouseMoveEvent to QGraphicsViewPrivate::updateRubberBand. This function is then called from QGraphicsView::mouseMoveEvent. I have removed some d-> and added some q-> but beside that nothing is changed in the code. Change-Id: Iab70c55635c43733e0e02bb70e2bb03b90bf62f0 Reviewed-by: Andy Shaw <andy.shaw@digia.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Remove QT_DLL and QT_NODLL defines.Stephen Kelly2012-12-111-2/+2
| | | | | | | Task-number: QTBUG-28044 Change-Id: Ib8c4e1e8e52703aa6590875c34f05b6bc71db808 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* QGraphicsView - add const to a not modified local variableThorbjørn Lund Martsum2012-12-111-1/+1
| | | | | | | | | The QPointF ep is not modified. There is no reason it shouldn't be const. Change-Id: I41fb8f9ae5296a7a40f7eb8be13fc14d56915e3f Reviewed-by: Andy Shaw <andy.shaw@digia.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>