summaryrefslogtreecommitdiffstats
path: root/src/widgets/kernel
Commit message (Collapse)AuthorAgeFilesLines
* Fix usage of QGuiApplication::set/resetOverrideCursorChristian Ehrlicher2018-11-052-5/+5
| | | | | | | | | Replace all occurrences of QApplication::set/resetOverrideCursor with the QGuiApplication::set/resetOverrideCursor since it's a static function of QGuiApplication. Change-Id: Ic898ab50a7ad4ed2bc9c6acb26cf4a979c2f82af Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Merge remote-tracking branch 'origin/5.12' into devLiang Qi2018-10-254-63/+26
|\ | | | | | | | | | | | | | | | | Conflicts: src/corelib/animation/qpropertyanimation.cpp src/gui/image/qicon.cpp tests/auto/widgets/itemviews/qtableview/tst_qtableview.cpp Change-Id: I3698172b7b44ebb487cb38f50fd2c4a9f8a35b21
| * Remove empty function QWidgetPrivate::registerDropSite()Friedemann Kleint2018-10-172-10/+0
| | | | | | | | | | | | | | | | Apparently it is a left-over from Qt 4. Task-number: QTBUG-70240 Change-Id: I6b882728defef1ab78331b03e76459a7419cd386 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
| * xcb: respect QEventLoop::ExcludeUserInputEvents in native event handlersGatis Paeglis2018-10-161-5/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was a regression from Qt 4. Before this patch, we supported filtering events only at QWindowSystemInterface level, but to properly support filtering in QAbstractEventDispatcher::filterNativeEvent, we have to filter the events earlier. Now it is possible to enable/disable this feature for platforms that support native event filtering. The mapping of which events are user input events were taken from QWindowSystemInterfacePrivate::EventType. Task-number: QTBUG-69687 Change-Id: I9a5fb9f999451c47abcdc83fdcc129b5eeb55447 Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * Doc: Move literal code block to a separate fileCristian Maureira-Fredes2018-10-151-42/+6
| | | | | | | | | | | | | | | | | | | | | | We need to override this snippet for the documentation we generate for Qt for Python, and it is easier to have it on a separate file. Task-number: PYSIDE-801 Task-number: PYSIDE-691 Change-Id: Ideb5b6af25024279f167137d3b65660bb9c96a7e Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
| * QToolTip: Don't crash if a tool tip is shown outside screen geometryJohan Klokkhammer Helsing2018-10-151-6/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In some cases, a tool tip may be shown outside screen geometry, i.e. if: - QToolTip::showText is invoked manually with a position outside. - In tst_QToolTip::setPalette if there is no screen at (0, 0). This might happen in a multi-monitor setups where one screen is taller than the other. - On Wayland windows are (by design) not allowed to know their position on the screen. This means that global positions can't be trusted. This started crashing when QDesktopWidget::screenGeometry(pos) was replaced with QGuiApplication::screenAt(pos)->geometry() because screenAt will return null if no screen is found, while screenGeometry defaulted to the primary screen. This reverts to the old behavior of falling back to the primary screen. This won't solve the issue completely for the Wayland case, but at least we will stop crashing. Change-Id: I42dd07cc21c2f9f0ea0d69f0c25bd46d8a2615a0 Reviewed-by: Filipe Azevedo <filipe.azevedo@kdab.com> Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | Mark deprecated functions with QT_DEPRECATEDChristian Ehrlicher2018-10-213-2/+13
| | | | | | | | | | | | | | | | | | QWidget::isEnabledToTLW() and QApplication::setKeypadNavigationEnabled() are deprecated for a long time but not marked as deprecated. Therefore add QT_DEPRECATED and guard them with QT_DEPRECATED_SINCE(5, 13). Change-Id: I12a76597aaad71025e4b7ad251dd67be55f8f966 Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
* | Let QApplication emit paletteChangedFrederik Gladhorn2018-10-171-0/+1
| | | | | | | | | | | | | | | | | | | | Only QGuiApplication would emit the signal. Untangling the duplicate code is rather non-trivial, so left alone for now. Fixes: QTBUG-71186 Change-Id: I4021e3b9ff39718562f4fa3a03c092436b559e9a Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | QWidget: set brushOrigin in paintBackground() only when really neededChristian Ehrlicher2018-10-132-14/+18
|/ | | | | | | | | | | | | | | When painting the background for a QAbstractScrollArea, the brushOrigin was calculated for every brush type although it was not needed. Since this can be very time consuming (e.g for a QTreeView with non-uniform row sizes) it should be avoided when possible. Therefore check if the brush is a texture and skip the calculation if it is not the case. Also do not restore the old brushOrigin since the painter is not used at all afterwards. Task-number: QTBUG-61763 Change-Id: I66cbe1b796cb5cad4c78e656fb86d199d8e4bde9 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* QtWidgets: Fix Qt application coming to the foreground when launching app by ↵Friedemann Kleint2018-10-051-2/+5
| | | | | | | | | | popup menu Check on the application state before requesting activation. Fixes: QTBUG-70810 Change-Id: I550137dc00209b17f4b3c033287ceef1b871ff50 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Prevent instantiation of QGestureManager in ~QWidget, ~QGraphicsItem()Friedemann Kleint2018-10-034-5/+7
| | | | | | | | | | | Debugging PYSIDE-815 revealed that QGestureManager is instantiated in the application destruction sequence. To prevent that, add a "force" parameter defaulting to true to QGestureManager::instance() and pass false in the destructors and QGestureManager::gesturePending(). Change-Id: I1b76173c926c2a156252b88832b032508d8e8a73 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Make overloaded function appear in assistant indexJarek Kobus2018-10-011-1/+0
| | | | | | | | | | When there are overloaded function for one class, at least one of them mustn't possess \overload command, otherwise it won't appear at all in doc index. Task-number: QTBUG-59506 Change-Id: I650a3969cb45c1a5efdfc3a654e01d113c398f16 Reviewed-by: Martin Smith <martin.smith@qt.io>
* Doc: Remove expired link and add see also entry for style sheetsPaul Wicking2018-09-281-4/+2
| | | | | | | | | Remove link to qt.nokia.com and add see also link to Qt Style Sheets that contain the necessary information. Change-Id: I05f6f760f3f9735f99385bdb39507b0878ec220c Fixes: QTBUG-70805 Reviewed-by: Martin Smith <martin.smith@qt.io>
* Ensure that QTabletEvent is not pre-accepted before sendingShawn Rutledge2018-09-252-0/+2
| | | | | | | | | | | | | | | | | | | | | In QWidget-world it's normal for input events to have the accepted flag false by default, so that it's obvious after visiting a widget subclass that does not override a particular handler function that it did not handle that event type at all. For tablet events in particular, the contract (to which we've been paying more attention to ensure that QTBUG-47007 remains properly fixed) is that if a QTabletEvent is not accepted, a mouse event will follow. Tablet-unaware applications need to get the same mouse events from a Wacom stylus as they would receive from an actual mouse. In this case the issue was missing hover events (mouse movements in which no mouse button is pressed). Without those, the enterEvent and exitEvent virtuals are also not invoked properly. Task-number: QTBUG-47007 Task-number: QTBUG-65199 Change-Id: I957005aad9d2bf85a3a41bbdebe3e046e34dee4d Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* QLayout: Better document QLayout(QWidget *parent) behaviorChristian Ehrlicher2018-09-091-3/+4
| | | | | | | | | | | QLayout(QWidget *parent) directly calls parent->setLayout(this) which can lead to a runtime warning later on when someone tries to set the layout on the parent again. Task-number: QTBUG-69761 Change-Id: I21ef8895fd65f3e23e57527a6d38936e45417b63 Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
* Fix crash when setting Qt::WA_StaticContents on a transient childFriedemann Kleint2018-09-061-1/+1
| | | | | | | | | | Bail out of QWidgetBackingStore::updateLists() when a top level transient child is encountered, preventing from adding children of other top level windows to its list. Task-number: QTBUG-70085 Change-Id: Ibd748ab959af9bfe7fe0622494936b0c109ab25a Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* WebAssembly for QtBaseMorten Johan Sørvig2018-08-301-0/+10
| | | | | | | | | | | | This is the squashed diff from wip/webassembly to dev. Done-with: Peng Wu <peng.wu@intopalo.com> Done-with: Sami Enne <sami.enne@intopalo.com> Done-with: Morten Johan Sørvig <morten.sorvig@qt.io> Started-by: Andrew Knight <andrew.knight@intopalo.com> Change-Id: I6562433c0a38d6ec49ab675e0f104f2665f3392d Reviewed-by: Lorn Potter <lorn.potter@gmail.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* QWidget: fix setTabOrder for compound widgetsChristian Ehrlicher2018-08-301-1/+3
| | | | | | | | | | | | | When adjusting the tab order for compound widgets, it can happen that the order is already correct. The check for this case forgot one case which lead to a garbled focus chain. Task-number: QTBUG-68393 Task-number: QTBUG-69619 Task-number: QTBUG-10907 Change-Id: Ic3242746bdcf3a4db6ea8daa1498381500ca116d Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* QWidgetWindow: Ensure Qt::WA_Mapped is set on obscured parent widgetsFriedemann Kleint2018-08-211-0/+3
| | | | | | | | | | | | Frameless obscured windows do not receive WM_PAINT/expose events on Windows. Qt::WA_Mapped needs to be set on them to ensure updating works. Task-number: QTBUG-39220 Task-number: QTBUG-52039 Task-number: QTBUG-58575 Task-number: QTBUG-63927 Change-Id: Ic6c11f2be96378b6a6b61296f1f3e13cd49b50a6 Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* Modernize the "thread" featureUlf Hermann2018-08-171-1/+1
| | | | | | | | | | Add it to configure.json and replace all occurrences of QT_NO_THREAD with QT_CONFIG(thread). Add conditions for other features that depend on thread support. Remove conditions where we can use the QMutex and QThreadStorage stubs. Change-Id: I284e5d794fda9a4c6f4a1ab29e55aa686272a0eb Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* Merge remote-tracking branch 'origin/5.11' into devQt Forward Merge Bot2018-08-071-0/+6
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/corelib/doc/src/objectmodel/signalsandslots.qdoc src/plugins/platforms/cocoa/qcocoamenuloader.mm src/plugins/platforms/xcb/qxcbconnection.cpp src/plugins/platforms/xcb/qxcbconnection.h src/plugins/platforms/xcb/qxcbconnection_xi2.cpp src/plugins/platforms/xcb/qxcbwindow.cpp tests/auto/gui/image/qimage/tst_qimage.cpp Done-with: Gatis Paeglis <gatis.paeglis@qt.io> Change-Id: I9bd24ee9b00d4f26c8f344ce3970aa6e93935ff5
| * QWidget: Add note about fixPosIncludesFrame not supporting window statesTor Arne Vestbø2018-08-011-0/+6
| | | | | | | | | | Change-Id: Iee841e7e6552e24f2b62b0c2df5df3c432680eef Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* | QToolTip::mouseMoveEvent(): always call base classChristian Ehrlicher2018-08-041-7/+7
| | | | | | | | | | | | | | | | | | QLabel::mouseMoveEvent() only called the base class implementation when a rect was given to showText which could lead to inconsistent behavior. Change-Id: I3e537ba5ae7c3c67715975624d1ee9f0c04fa9a7 Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Don't ignore alpha values in grabFramebuffer methodsAllan Sandfeld Jensen2018-08-031-1/+2
| | | | | | | | | | | | | | | | | | Returns an ARGB32_Premultiplied image when the framebuffer is grabbed on a transparent QOpenGLWidget or QOpenGLWindow. Task-number: QTBUG-55245 Change-Id: I4b7778ecc38275be1ed9fb748c77c7e1f6b65a00 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | Don't trigger composeAndFlush for native child widgets unless neededTor Arne Vestbø2018-08-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The textureChildSeen flag is set on each widget the first time it has a child needing textures, which triggers the composeAndFlush codepath. If a top level widget had a child needing this codepath, but other native children not needing it, we ended up always using composeAndFlush for the native children, since we were checking textureChildSeen of the top level widget. We should check the child widget instead, which will never have the flag set unless itself had children that required composeAndFlush. This matches the logic in findAllTextureWidgetsRecursively, which also checks the child widget and not the top level widget. Done-width: Laszlo Agocs <laszlo.agocs@qt.io> Change-Id: I65064eef41e56d9c1a789a96cedb98b11e8a177a Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | Inline deprecated QTest::qWaitForWindowShownTor Arne Vestbø2018-07-202-7/+2
| | | | | | | | | | | | Change-Id: Ie8c3975643b9d7e60caf9de4dd3eaa13066a1028 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | Merge remote-tracking branch 'origin/5.11' into devQt Forward Merge Bot2018-07-171-6/+6
|\| | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/platforms/cocoa/qcocoawindow.mm src/plugins/platforms/xcb/qxcbintegration.cpp Conflicts git missed: src/plugins/platforms/qnx/qqnxglcontext.cpp Change-Id: I0582cdc9e66e43efe79038b9c43d4f9572ac88fc
| * Doc: Remove redundant \codePaul Wicking2018-07-131-4/+0
| | | | | | | | | | | | | | | | | | | | | | The preceding snippet contains the same line of code. It is unclear why this line is repeated, and it does not seem to serve a purpose. This patch removes the line of code and the QDoc command used to set it apart from the preceding snippet. Task-number: QTBUG-56772 Change-Id: I400b22aa75ee4542bfb67f7e47e3c31c577a39e5 Reviewed-by: Martin Smith <martin.smith@qt.io>
| * Doc: Explain emission of QAction::changed on calling QAction::togglePaul Wicking2018-07-111-2/+6
| | | | | | | | | | | | | | | | | | | | Extend description of QAction::checked() and QAction::toggled(), as it is not clear from the documentation that calling QAction::toggle causes the emission of a QAction::changed signal. Task-number: QTBUG-68213 Change-Id: I5afa4d9a6e6f001dff81271d1e34d0c515da3c24 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | testlib: Move qtestsystem helpers to their respective modulesTor Arne Vestbø2018-07-163-2/+183
| | | | | | | | | | | | | | | | | | | | | | | | | | Having the helpers in each respective module lets us implement the helpers using private APIs without forcing the test to add private dependencies. It also makes it easier to test Qt using a third party testing framework (for running the test suite), while still using the helpers for ensuring tests behave expectedly. Change-Id: I2a6ce24526ed345f3513548f11da05c7804c203f Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Fix build with '-no-feature-action' configurationValentin Fokin2018-07-122-0/+14
| | | | | | | | | | | | | | Task-number: QTBUG-68353 Change-Id: Ia949e4a72a363df5fba86504e5f7e3ce8a3ad347 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
* | QAccessibleTabButton: fix isValidFrederik Gladhorn2018-07-081-0/+1
| | | | | | | | | | | | | | | | | | | | | | The button interface is faking everything to represent the buttons when it comes to accessibility, since they are not represented by a QWidget. When the parent TabBar is in its destructor, isValid should return false to prevent accessing it. Task-number: QTBUG-69283 Change-Id: Ifedf3fa45f9106723afb0b04922b071a3c5467c3 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | Merge remote-tracking branch 'origin/5.11' into devLiang Qi2018-07-021-1/+2
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/platforms/cocoa/qnsview.mm src/plugins/platforms/cocoa/qnsview_dragging.mm src/plugins/platforms/ios/qiosinputcontext.mm src/plugins/platforms/xcb/qxcbconnection.cpp src/plugins/platforms/xcb/qxcbconnection_xi2.cpp src/plugins/platforms/xcb/qxcbwindow.cpp src/tools/androiddeployqt/main.cpp Was moved from qttools into qtbase in 5.11. So re-apply 32398e4d here. tests/auto/corelib/global/qlogging/test/test.pro tests/auto/corelib/global/qlogging/tst_qlogging.cpp tests/auto/corelib/io/qfile/tst_qfile.cpp tests/auto/corelib/kernel/qtimer/tst_qtimer.cpp tests/auto/corelib/thread/qthreadstorage/test/test.pro tests/auto/widgets/itemviews/qheaderview/tst_qheaderview.cpp tests/auto/widgets/kernel/qapplication/test/test.pro Done-with: Gatis Paeglis <gatis.paeglis@qt.io> Done-with: Mårten Nordheim <marten.nordheim@qt.io> Done-with: Oliver Wolff <oliver.wolff@qt.io> Change-Id: Id970486c5315a1718c540f00deb2633533e8fc7b
| * Don't set the wasDeleted flag in ~QWidgetLars Knoll2018-06-071-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Setting it too early can cause issues, as we are still doing lots of work here as e.g. calling hide() on children. But the flag is required when we delete the declarative data, so set and reset it when destroying that data. Amends c579f49e2a80a55a4004ff8e5b2ee76bda146387 Task-number: QTBUG-68637 Change-Id: I7ed35828c26912aa6d703ba6025e46b7911353fa Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Christian Stenger <christian.stenger@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Tracepoints: add tracing for QEventsGiuseppe D'Angelo2018-06-281-3/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add tracepoints in all the main codepaths for event handling: * QEvent ctors/dtor * QCoreApplication::postEvent, sendEvent and sendSpontaneousEvent * QCoreApplication / QApplication::notify, and around the handling of event filters as well I'm switching the name of the tracepoints themselves to have the very same casing of the functions in Qt's own source code, this improves readability a lot. The pre-existing ones will be changed in an upcoming patch. Change-Id: Iae2ba2bfdd76a82c85445bb5b86434e910427a70 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
* | widgets: fix QWidget::save/restoreGeometry()Gatis Paeglis2018-06-251-11/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QWidget::restoreGeometry() is calling QWidget::move() with restoredFrameGeometry, which internally calls setGeometry() and sets positionPolicy = QWindowPrivate::WindowFrameExclusive, which is invalid: restoredFrameGeometry is WindowFrameInclusive geometry. QPA plugins rely on correctly set policies when interpreting x,y. QWidget::move() was not designed for this AFAICT, so making it to accept frame geometry is no-op. It is widely used legacy code, changing it could cause regressions. Save/restore API was introduced in Qt 4.2, at that time we did not have APIs like QWindow::setFramePosition(), so its unclear why geometry() was not stored instead. The documentation also is somewhat unclear: "[..] save the geometry when the window closes [..]" Frame or client geometry? It does not specify. And from the code we see that frame geometry was passed as client geometry, not making the original intention clearer. Besides that, restoreGeometry() is full of other undocumented assumptions where to place windows and when to fail (fortunately its easy to write your own save/restore logic). Added a Qt 6 note in the source code. What this patch changes: Now we store geometry() in saveGeometry() and use that value in restoreGeometry() by setGeometry(). This does not cause any behavior difference in window positioning (tst_QWidget::saveRestoreGeometry still works). Geometry restored from data saved with earlier versions of saveGeometry() might be positioned at: x + leftMargin, y + topMargin. This patch makes tst_QWidget::saveRestoreGeometry to always fail instead of being flaky. Blacklisting for XCB instead of selected distros. Also enabled excluded code paths for XCB on tst_QDockWidget::restoreDockWidget(). It does not seem to be flaky, maybe it was in 2015, but lot of things have changed since then. Task-number: QTBUG-66708 Change-Id: Ic86a6fd091e2c71b7550b2f476386da704253cd4 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | widgetwindow: send DragMove for every DragEnterGatis Paeglis2018-06-252-47/+67
| | | | | | | | | | | | | | | | | | | | ... as specified in the documentation. This was a regression from Qt4 and can cause mouse cursor flickering durig dragging on e.g. custom widget where some areas of the widget do not accept drag-and-drop. Task-number: QTBUG-67155 Change-Id: Iaa6f9407181931ed8e3d6a8fec13fd59d3c8625d Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* | Add ObjectMode coordinate mode to QGradientEirik Aavitsland2018-06-221-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The ObjectBoundingMode coordinate mode of QGradient allows specifying the gradient coordinates relative to the object being painted. But if the gradient brush also has a transformation, that transformation is applied in the logical, not object, coordinate space. That behavior is counterintuitive. However, changing it now would break existing code. Instead, we introduce a new coordinate mode enum with the expected behavior, and document the old one as deprecated. This prepares to fix the bugs below in qtsvg, by making it possible to specify the same behavior in Qt as SVG has. [ChangeLog][QtGui][QGradient] Add ObjectMode coordinate mode [ChangeLog][Important Behavior Changes] QDataStream version bumped up to 18 to account for changes in the serialization of QGradient. Task-number: QTBUG-59978 Task-number: QTBUG-67995 Change-Id: I8820a2555359812f3e1a46e37d6ac2cc29a2091d Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Fix warning that QRegion::rects() is deprecatedThiago Macieira2018-06-181-1/+2
| | | | | | | | | | | | | | Since we do need a container so we can sort, use std::back_inserter. Change-Id: I6efb28c3145047559ec0fffd153880918eb47184 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* | Merge remote-tracking branch 'origin/5.11' into devLiang Qi2018-06-078-35/+39
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/corelib/kernel/qeventdispatcher_cf.mm src/gui/kernel/qguiapplication_p.h src/gui/kernel/qwindowsysteminterface.cpp src/gui/kernel/qwindowsysteminterface.h src/plugins/platforms/cocoa/qcocoawindow.mm src/plugins/platforms/cocoa/qnswindowdelegate.mm src/plugins/platforms/ios/qioseventdispatcher.mm src/plugins/platforms/windows/qwindowsdrag.h src/plugins/platforms/windows/qwindowsinternalmimedata.h src/plugins/platforms/windows/qwindowsmime.cpp src/plugins/platforms/winrt/qwinrtscreen.cpp Change-Id: Ic817f265c2386e83839d2bb9ef7419cb29705246
| * Render QOpenGLWidget/QQuickWidget with AlwaysStackOnTopAllan Sandfeld Jensen2018-05-311-14/+16
| | | | | | | | | | | | | | | | | | | | | | QWidget::render was ignoring QOpenGLWidget/QQuickWidget with AlwaysStackOnTop set, because normally they will be composited later, however when not doing a backing store render, they need to be painted right away as there is no later. Task-number: QTBUG-67533 Change-Id: I08e2eeee5e7a8f0dbbf43f659fcfa9068e8c46d1 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * Make sure we can build with -no-feature-draganddropJoerg Bornemann2018-05-298-21/+23
| | | | | | | | | | | | | | | | | | We move QInternalMimeData to a separate file, because this class is used, even if draganddrop is disabled. From now on, include qinternalmimedata_p.h instead of qdnd_p.h for QInternalMimeData. Change-Id: I594e08e2e90d574dc445119091686b4b69e4731b Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
* | QToolTip: replace deprecated QDesktopWidget::screenGeometry()Christian Ehrlicher2018-05-281-1/+1
| | | | | | | | | | | | | | | | QDesktopWidget::screenGeometry() was deprecated in 5.11 and replaced by QScreen::geometry() Change-Id: I23f5b6a4ed6b76cf558cd8d3ad49bc8029c16f61 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | Move default implementation of update requests to QPlatformWindowTor Arne Vestbø2018-05-071-2/+4
| | | | | | | | | | Change-Id: I4cbb8d2023068288e298ab21f5cd8bc258825c77 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | QShortcut: Try harder to find a widget for parentless menubarsGabriel de Dietrich2018-05-031-2/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add QPlatformMenuBar::parentWindow(). Since we call handleReparent() every so often, it's reasonable to be able to get its value back. While this parent window won't give us much information from the point of view of the actual QWidget parent for the menubar, the main reason we will need this is to check for modality blockage. Indeed, QApplicationPrivate::tryModalHelper() only cares about the widget's window since modality blockage is decided at the window level. Change-Id: Ie79f483424b01e430bc9168ba82489e30d15aec6 Task-number: QTBUG-67938 Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* | Merge remote-tracking branch 'origin/5.11' into devLiang Qi2018-05-032-11/+26
|\| | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/widgets/graphicsview/elasticnodes/graphwidget.cpp examples/widgets/graphicsview/elasticnodes/node.cpp examples/widgets/graphicsview/elasticnodes/node.h src/plugins/platforms/cocoa/qnsview.mm src/plugins/platforms/cocoa/qnsview_drawing.mm src/widgets/kernel/qmacgesturerecognizer_p.h Change-Id: I13cf06bac75d48d779d8ee7b5c91bfc976f2a32c
| * Fix crash in QMacPanGestureRecognizerJan Arve Saether2018-05-022-2/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The reason it crashed was this: 1. Button was pressed => _panTimer started with the graphics view as destination. 2. Button was released => the graphicsview is destroyed 3. 300 ms later: Qt tries to deliver TimerEvent from _panTimer to the graphics view. Unfortunately, the graphics view is deleted, but Qt doesn't know that... (*crash*) We therefore chose to start the timer with a destination we are controlling the lifetime of: the QMacPanGestureRecognizer. Inside the timerEvent of that we can check if the actual target is already destroyed. Task-number: QTBUG-60404 Change-Id: Iff8f5b7217de42c4c5cf551ca507f0cff1c99a78 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* | Merge remote-tracking branch 'origin/5.11' into devQt Forward Merge Bot2018-05-024-2/+5
|\| | | | | | | Change-Id: Ia082e20e2eb4b76afd4c1a1584ff4e5514655d7a
| * Convert features.toolbar to QT_[REQUIRE_]CONFIGStephan Binner2018-05-022-0/+4
| | | | | | | | | | | | | | | | Move declaration of pick/perp helpers up the dependency chain Change-Id: I7084ed829a057a0c45d60445c416fb07f2cb5624 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
| * Remove assert from QFormLayout::takeRow()Sergio Martins2018-04-301-2/+0
| | | | | | | | | | | | | | | | | | | | Having rows without fields is a supported use case so it shouldn't assert. Code works quite well in release mode, but crashes in debug mode. Change-Id: I1c4f736318489bae09780fcdb56136181afcac17 Reviewed-by: Samuel Gaist <samuel.gaist@edeltech.ch> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>