| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit 897645d417c445f19ee183147c61e1bd0694868f.
Revert of commercial license header changes is required for
Qt 5.15.3 opensource release.
Task-number: QTBUG-91108
Change-Id: I4b21b5e105d34dc076a5ffad1a6d3b2793c2f163
Reviewed-by: Antti Kokko <antti.kokko@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Updated header.COMM to files in tqtc-qtbase/src/dbus,
tqtc-qtbase/src/gui and tqtc-qtbase/src/network. The documentation
files were not updated.
The commercial license header may contain some additional
lines so that its line count equals with the earlier license
header. Reason for this is that some autotests use hard coded
line numbers and a change in the line count causes failures
in tests.
Task-number: QTQAINFRA-4154
Change-Id: Id2d3db63c1f378812d8058fa8a118702a5829eb8
Reviewed-by: Jani Heikkinen <jani.heikkinen@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We actually do not need this "mode" in qwsi API. I think while
writing the patch from 00ae1e6b7b I got confused by focusing
on my test application. We can't know what the native event
filter will filter out, therefore it makes sense that we
unconditionally do filtering at qwsi level as well for user input
vs other events in QWindowSystemInterface::sendWindowSystemEvents().
Change-Id: Idb23152a24bf3ba3b91804427a6e78f991969c29
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit 7318328c2d658f6ca2e9443c6e3e3b0a179e9811)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Followup to ed3ed0b9db97a8fab0c03add23228b6b0a96f171
68916fede41d1eca5d07eb6b1db518d41a007616 and
3c159957f863cf8d367a9261e7016e52cd0348c1.
In QWindowSystemInterfacePrivate::fromNativeTouchPoints() and
QWindowSystemInterfacePrivate::toNativeTouchPoints() we continue using
struct TouchPoint's QRectF area as storage for the screen position +
ellipse diameters; as the comment says, this is _unrotated_, meaning
that rotation is stored separately, and area should not be construed as
the bounding box of the rotated ellipse. (In Qt 6 we can make the
QPA touchpoint look the same as the QTouchEvent::TouchPoint to
eliminate the need to calculate the center of the rect.)
In QGraphicsScenePrivate::updateTouchPointsForItem(), setRect() sets the
position and the ellipse diameters, but the latter is redundant because
the purpose of this function is to localize a touchpoint to the
coordinate system of a particular QGraphicsItem. Ellipse diameters
should stay the same.
In QApplicationPrivate::updateTouchPointsForWidget(), as in
QGraphicsScene, we are localizing touchpoints to a widget
and to the screen that the widget is shown on, so only the position
needs to be set, while preserving the sub-pixel resolution that
mapFromGlobal(QPoint) loses.
Fixes: QTBUG-83403
Change-Id: I61d29e14cbe38567767b164af6ae895082c5e1a1
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
|
|
|
|
| |
Change-Id: I49c285604694c93d37c9d1c7cd6d3b1509858319
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
|
|
|
|
|
|
|
|
| |
Return the value from handleWindowSystemEvent so platform plugins can
detect whether it was accepted or not.
Change-Id: I53ffb713afc8e0ec1789107c912433133cfaa11a
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
|\
| |
| |
| | |
Change-Id: I851c0328c3c38ea67b5ad115b205ac6a1262706e
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Don't move the native child window position for native child windows.
Initial-patch-by: Błażej Szczygieł <spaz16@wp.pl>
Task-number: QTBUG-82312
Fixes: QTBUG-79166
Change-Id: I117ef08da13c8e90ff60cf034126c9efdc17b836
Reviewed-by: Błażej Szczygieł <mumei6102@gmail.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
|
|\ \
| |/
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
.qmake.conf
src/plugins/platforms/xcb/qxcbscreen.cpp
src/widgets/accessible/qaccessiblewidget.cpp
Change-Id: Ib3138e61ba7981610940509a7ff02ba2dd281bf0
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Otherwise the expose event that AppKit triggers will be delivered before
we've propagated the theme change, and we fail to draw the UI using the
new theme.
Change-Id: I502122a2bf02a866d136106d831f0c2a0dfe26f2
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
There's no reason to use a class-static mutex object here.
Use a namespace-static QBasicMutex, port to qt_scoped_lock.
Change-Id: Ia9bd3c2fadbf1da25ef79bb393c899b678cbc182
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
|/
|
|
|
|
|
|
|
|
|
| |
Move away from using 0 as pointer literal.
Done using clang-tidy. This is not complete as
run-clang-tidy can't handle all of qtbase in one go.
Change-Id: I1076a21f32aac0dab078af6f175f7508145eece0
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
|
|
|
|
|
|
| |
Change-Id: I31b4ed6e6597e22172dcca7180750f1392b9ad68
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Instead of having each platform plugin deal with application termination
in their own weird ways, we now have a QPA API to signal that the system
requested the application to terminate.
On the QGuiApplication side this results in a Quit event being sent to
the application, which triggers the default behavior of closing all app
windows, and then finally calling QCoreApplication::quit().
The quit event replaces the misuse of a close event being sent to the
application. Close events are documented as being sent to windows.
The close events that are sent to individual windows as part of the
quit process can be ignored. This will skip the final quit() of
the application, and also inform the platform that the quit was
not accepted, in case that should be propagated further.
In the future the logic for closing windows should be unified
between the various approaches in closeAllWindows, shouldQuit,
and friends.
Change-Id: I0ed7f1c0d3f0bf1a755e1dd4066e1575fc3a28e1
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The evdev touch handler is thread based and calls
QWindowSystemInterface::handleTouchEvent. The global variable
in qwindowsysteminterface.cpp is used without being protected by mutexes
which causes data loss and crashes when multiple touch screens are used.
Fixes: QTBUG-63584
Change-Id: I8b5bb04cc517fab96ac428b2bd2bc128b2ca1a54
Reviewed-by: Johan Helsing <johan.helsing@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
|
|
|
|
|
|
| |
The base WindowSystemEvent has had an eventAccepted flag since 2014.
Change-Id: Ia0aa795083cd98ece83a4c1cc010d3a25e2489fd
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This makes it possible to test the effects of setting
Qt::AA_HighDpiScaling/QT_AUTO_SCREEN_SCALE_FACTOR, with different DPI
values on all platforms.
This also makes it possible to access the actual DPI values reported
by the OS/WS via the QPlatformScreen API.
A drawback is that there is no single place to check the environment
variable; currently done in three places. This may be
further simplified later on.
Done-with: Friedemann Kleint <Friedemann.Kleint@qt.io>
Task-number: QTBUG-53022
Change-Id: Idd6463219d3ae58fe0ab72c17686cce2eb9dbadd
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Semi-automated, just needed ~20 manual fixes:
$ find \( -iname \*.cpp -or -iname \*.h \) -exec perl -pe 's/(\.|->)load\(\)/$1loadRelaxed\(\)/g' -i \{\} +
$ find \( -iname \*.cpp -or -iname \*.h \) -exec perl -pe 's/(\.|->)store\(/$1storeRelaxed\(/g' -i \{\} +
It can be easily improved (e.g. for store check that there are no commas
after the opening parens). The most common offender is QLibrary::load,
and some code using std::atomic directly.
Change-Id: I07c38a3c8ed32c924ef4999e85c7e45cf48f0f6c
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
QPlatformIntegration""
This reverts commit 300940a6c9eb0f74cefda7d76a5d19f56ec50253.
The fixes for leaf modules landed already.
Task-number: QTBUG-74816
Change-Id: I1c7f0705c20d030419ceedca485106af73946b3c
Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit 7a64ffb7738dc975b5008800901c8cd8ab238a0f.
This change landed in 5.13 too early, so there is no baseline with both APIs in
dev. This will be reverted later when the fixes for leaf modules landed.
Task-number: QTBUG-74816
Change-Id: Ie5ee41fbf6be53b8fcb4289ac1ec3974e5bf6e42
Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
|
|\
| |
| |
| | |
Change-Id: I38389a69411f4549fed432f1181dbe23398b34a2
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The logic for removing QScreens from QGuiApplicationPrivate has been
moved into the QScreen destructor, similar to QWindow.
Change-Id: I18ad57d8dcf9f765c47be7c082bf075af3ebe69c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
|
| |\
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/gui/kernel/qplatformintegration.cpp
src/gui/kernel/qplatformintegration.h
src/plugins/platforms/wasm/qwasmintegration.cpp
src/plugins/platforms/xcb/qxcbconnection_screens.cpp
Change-Id: I15063d42e9a1e226d9d2d2d372f75141b84c5c1b
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
QWindowSystemInterface is the de facto API for any plumbing going from
the platform plugin to QtGui. Having the functions as protected members
of QPlatformIntegration was idiosyncratic, and resulted in awkward
workarounds to be able to call the functions from outside of the
QPlatformIntegration subclass.
The functions in QPlatformIntegration have been left in, but deprecated
so that platform plugins outside of qtbase have a chance to move over to
the new QWSI API before they are removed.
Change-Id: I327fec460db6b0faaf0ae2a151c20aa30dbe7182
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
|
|/
|
|
|
|
|
|
|
| |
LRESULT on Windows 64 is a 64bit type, adapt filter functions of
QAbstractNativeEventFilter and QAbstractEventDispatcher accordingly.
Fixes: QTBUG-72968
Change-Id: Ie53193e355f0b8e9bd59fa377f43e2b4664a2ded
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The new test tst_QTouchEvent::touchOnMultipleTouchscreens()
needs the touchpoint IDs to be predictable, but another test currently
has a QEXPECT_FAIL; without release events, g_pointIdMap continued to
hold the touchpoints that were there when the test failed. So it's
necessary to add QWindowSystemInterfacePrivate::clearPointIdMap()
to be able to call it in the test cleanup function.
Fixes: QTBUG-73830
Change-Id: Ia6a70d028be95cd2b6676db6363ec408c0b116bc
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Assert on receiving double clicks which are currently not implemented.
Task-number: QTBUG-71263
Task-number: QTBUG-70999
Change-Id: I85cd21665ecaf118584053de63745044728d8f5b
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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>
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
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
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
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>
|
|\ \
| |/
| |
| |
| |
| |
| |
| | |
Conflicts:
src/plugins/sqldrivers/sqlite/qsql_sqlite.cpp
tests/auto/corelib/io/qresourceengine/qresourceengine_test.pro
Change-Id: I3169f709cc2a1b75007cb23c02c4c79b74feeb04
|
| |
| |
| |
| |
| |
| |
| | |
Task-number: QTBUG-67777
Change-Id: I6d52b650fb33283010ef06259da83cdb2fd3483f
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
... instead of using a hack of directly accessing QGuiApplication
members.
The current QPA API was bad for two reasons:
1) It expects platform plugin authors to know about
internals of Qt Gui, particularly that QGuiApplication
uses QGuiApplication::{mouseButtons,keyboardModifiers}
to construct QDragMoveEvent and QDropEvent events. Which
results in the second reason why this is bad.
2) Platform plugins should not directly access member
variables of QGuiApplication, just to make sure that
QDragMoveEvent and QDropEvent events contain correct state.
Platform plugins should instead use QWindowSystemInterface
to communicate with Qt Gui (which is also the solution here).
The solution is to extend QWindowSystemInterface::handle{Drag,Drop}
to require mouse/keyboard state. We already do this for
some of the other methods, so it is nothing extraordinary.
This type of interface is also _required_ to support
drag-n-drops from other processes. We can't use
QGuiApplication::{mouseButtons,keyboardModifiers} when the
drag originates from another process, instead we need to
query mouse/keyboard state from the system.
This patch fixes drag-n-drops from others processes on XCB
platform plugin.
Task-number: QTBUG-57168
Change-Id: I3f8b0d2f76e9a32ae157622fef801829d629921d
Reviewed-by: Mikhail Svetkin <mikhail.svetkin@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
|
|\ \
| |/
| |
| | |
Change-Id: I8b5a10d897a926078895ae41f48cdbd2474902b8
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
WindowStateChangedEvent::oldState is of type Qt::WindowStates and should
therefore be set to QWindow::windowStates() instead of QWindow::windowState()
Change-Id: I6710624dd303642a31bfbb25bc07bf05b921d84c
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
|
|/
|
|
|
|
|
|
| |
Use QT_DEFINE_QPA_EVENT_HANDLER to define
QWindowSystemInterface::handleCloseEvent().
Change-Id: I4f1105f7aa78bdebddfe9062b388eb616e325e31
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
src/corelib/corelib.pro
src/corelib/global/qrandom.cpp
src/network/access/qhttpnetworkrequest_p.h
src/plugins/platforms/cocoa/qcocoamenu.mm
src/plugins/platforms/cocoa/qcocoansmenu.mm
src/plugins/platforms/cocoa/qcocoawindow.mm
src/plugins/platforms/cocoa/qnsview.mm
src/plugins/platforms/offscreen/qoffscreenintegration.h
src/widgets/kernel/qaction.cpp
src/widgets/widgets.pro
Done-with: Andy Shaw <andy.shaw@qt.io>
Change-Id: Ib01547cf4184023f19858ccf0ce7fb824fed2a8d
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Correctly scale the requested geometry in the constructor
of QWindowSystemInterfacePrivate::GeometryChangeEvent().
Amends 3a31c708790ba2bb3cf3dab32a17a83659a1acde.
Task-number: QTBUG-57608
Task-number: QTBUG-65580
Change-Id: I0ef60deda69bb61ab57972e02c342b7773e1da6b
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
|\ \
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
.qmake.conf
sc/corelib/io/qfsfileengine_p.h
src/corelib/io/qstorageinfo_unix.cpp
src/platformsupport/eglconvenience/qeglpbuffer_p.h
src/platformsupport/input/libinput/qlibinputkeyboard.cpp
src/platformsupport/input/libinput/qlibinputpointer.cpp
src/plugins/platforms/cocoa/qcocoamenu.mm
src/plugins/platforms/ios/qiosscreen.h
src/plugins/platforms/ios/qioswindow.h
src/plugins/platforms/ios/quiview.mm
src/printsupport/dialogs/qpagesetupdialog_unix_p.h
src/printsupport/dialogs/qprintpreviewdialog.cpp
src/printsupport/widgets/qcupsjobwidget_p.h
src/widgets/widgets/qmenu.cpp
tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp
tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp
Change-Id: Iecb4883122efe97ef0ed850271e6c51bab568e9c
|
| |\
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
.qmake.conf
mkspecs/win32-g++/qmake.conf
src/corelib/global/qglobal_p.h
src/corelib/global/qoperatingsystemversion_p.h
src/corelib/io/qfilesystemengine_win.cpp
src/network/bearer/qbearerengine.cpp
src/platformsupport/input/libinput/qlibinputpointer.cpp
src/sql/doc/snippets/code/doc_src_sql-driver.cpp
src/widgets/kernel/qwidget_p.h
src/widgets/kernel/qwidgetwindow.cpp
src/widgets/styles/qfusionstyle.cpp
tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp
Change-Id: I80e2722f481b12fff5d967c28f89208c0e9a1dd8
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The safe area margins of a window represent the area that is safe to
place content within, without intersecting areas of the screen where
system UI is placed, or where a screen bezel may cover the content.
QWidget will incorporate the safe area margins into its contents margins,
so that they are are never smaller than the safe area margins. This can be
disabled by unsetting the Qt::WA_ContentsMarginsRespectsSafeArea widget
attribute, which is set by default.
QLayouts will automatically use the contents area of a widget for their
layout, unless the Qt::WA_LayoutOnEntireRect attribute has been set. This
can be used, along with a contents margin of 0 on the actual layout,
to allow e.g. a background image to underlay the status bar and other
system areas on an iOS device, while still allowing child widgets of
that background to be inset based on the safe area.
[ChangeLog][iOS/tvOS] Qt will now take the safe area margins of the
device into account when computing layouts for QtWidgets.
Change-Id: Ife3827ab663f0625c1451e75b14fb8eeffb00754
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
|
|\ \ \
| |/ /
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/corelib/thread/qsemaphore.cpp
tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp
tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp
Change-Id: Id35b535e88df63fdfe4007ea92ed4a39c4b6d707
|
| |\ \
| | |/
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/corelib/io/qstandardpaths_win.cpp
src/plugins/platforms/ios/qioswindow.mm
src/plugins/platforms/ios/quiview.mm
tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp
Change-Id: I5deb0a0176a454a9c566e924d074ba60ce04f0bc
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Using QWindowSystemInterface::SynchronousDelivery reduces the chance
that we are flushing other events before delivering the application
state change. Those other events may conclude that the application
is still active, while in reality it is not, and do bad things.
Change-Id: I738c162fac22d2cd18de1e080bcd2cda78ec3f77
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
... and deprecate QWSI APIs that accepts mouse event without mouse button/
type data.
In the early days of Qt5 it was decided to centralize mouse button/type
handling in QGuiApplication (because of limitation of some now unknown
platform). This has proven to be problematic as mouse handling details
differ across platforms (e.g on X11 we do not receive mouse release event
when closing popup windows or ordinary windows that are closed from the
mouse press event). Instead of hacking around platform specific behaviors
in Qt Gui, we should move this task back to platform plugins (similar to
how this was done in Qt4 with native APIs sending mouse details directly
to QApplication). There are even cases where it simply is not possible
to deduce (from QGuiApplication) which button caused the event (e.g. when
more than one button is involved and some event goes missing). Besisdes,
throwing away information which is already available at QPA level (for free)
and trying to deduce it again at Qt Gui level seems impractical, fagile
(as probably noticed by people fixing all the unexpected issues) and adds
unnecessary complexity.
Note:
Removing the deprecated QWSI APIs from offscreen plugin depends on fixing
autotests that rely on QOffscreenCursor::setPos() logic.
For the convenience of testing use QT_QPA_DISABLE_ENHANCED_MOUSE to restore
to the old code path where QGuiApplication does the mouse state deducing.
Other platforms have similar issues. I do not have all supported platform
available on my desk, so other platform maintainers will need to take care
of porting those platforms to the new APIs. And mainly, I don't want to deal
with all the hacks that other platforms have added to workaround this broken
mouse logic.
In Qt6 we need to remove deprecated code path from QGuiApplication.
This patch:
- Extends QWindowSystemInterfacePrivate::MouseEvent ctor with QEvent::Type
and Qt::MouseButton. We use this extra data when processing mouse events in
QGuiApplication. This actually is similar to KeyEvent, where we do pass the
type (press or release) to QtGui.
- Refactors QGuiApplicationPrivate::processMouseEvent and qtestlib to use
the new APIs.
Task-number: QTBUG-59277
Task-number: QTBUG-62329
Task-number: QTBUG-63467
Change-Id: If94fd46a7cccfea8264dcb1368804c73334558b8
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
|
|/ /
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Non client area mouse events are mouse events too. There is no need
for a dedicated event type in QWindowSystemInterface.
Instead we pass the state through a 'nonClientArea' variable of the
mouse event, corresponding to QEvent::NonClientArea{Press,Release,Move}.
Change-Id: Ia0a188400787506c8fe0cfe58aee0776c1ab13c7
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
QtQuick is beginning to have a use for this, to distinguish native
gestures which come from actual trackpad rather than from the "core pointer".
It might as well use a real device ID instead of making one up,
as it has to do for the core pointer.
So far on macOS, the device ID isn't a real one; but that can be fixed,
as the qCDebug lines demonstrate (different trackpads have different IDs).
Change-Id: I5841deb1c4cc0b77a3b1df70904f70b3d2d71853
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
|
|\ \
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
src/widgets/kernel/qwidget.cpp
This merge also extends the expected output of the pairdiagnostics
teamcity output (added in dev in commit
c608ffc56ab37f9a9d5b9c34543126adb89e2b08) after the recent addition of
the flowId attribute to the teamcity output (commit
8f036562119dd35ce51dc9230304d893b906bd37 in 5.9).
Change-Id: I3868166e5efc45538544fffd14d8aba438f9173c
|
| |
| |
| |
| |
| |
| |
| |
| | |
Scale velocity and raw positions as does
QWindowSystemInterfacePrivate::fromNativeTouchPoints().
Change-Id: I4c9e03e4c2f4ca807319b1a7d1f4a9e56a25b06c
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Document that "visible"-but-obscured windows may not
get expose events for various audiences: QTestLib
users, platform plugin authors and on the QExposeEvent
itself. QWindow::exposeEvent() already has this documented
and is not changed.
Task-number: QTBUG-50414
Change-Id: I91042e8b1c70e48f10e692b2e80367d242a8ccbe
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
|