summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Add changes file for Qt 5.11.0v5.11.0-rc2v5.11.0-rc1v5.11.0Antti Kokko2018-04-241-0/+82
| | | | | Change-Id: I28be178f23f1dfd2f253daabe6772106c007eace Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Compositor: Fix mapToSurface for surfaces with bufferScale != 1Johan Klokkhammer Helsing2018-04-211-2/+2
| | | | | | | | | Since QWaylandSurface::size (public API) returns the buffer size in pixels and not the size in surface local coordinates, we need to also account for the surface buffer_scale in order to get surface local coordinates. Change-Id: I79a396c55b674b1ac42ca17e1e88e50c1506ce83 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Fix typo in wayland formatsAllan Sandfeld Jensen2018-04-161-1/+1
| | | | | Change-Id: Ic4a8c64fa0e1b56a8d21316c96e3eeb3f20fb8b1 Reviewed-by: Johan Helsing <johan.helsing@qt.io>
* Compositor: Add documentation for WaylandSurface::surfaceDestroyedv5.11.0-beta4v5.11.0-beta3Johan Klokkhammer Helsing2018-03-271-0/+13
| | | | | Change-Id: Ia4118d5242e6bf6dfb703db76e53ea09fbc25041 Reviewed-by: Martin Smith <martin.smith@qt.io>
* Compositor: Add documentation for WaylandSurface::childAddedJohan Klokkhammer Helsing2018-03-271-0/+12
| | | | | Change-Id: Ibcaa85986764545128a18981e17dac9838606f69 Reviewed-by: Martin Smith <martin.smith@qt.io>
* Compositor: Add documentation for XdgSurfaceV6::toplevel and popupJohan Klokkhammer Helsing2018-03-261-0/+34
| | | | | | Change-Id: I8ad5f8ad60081647aef2472fea462f37ff62b8b4 Reviewed-by: Topi Reiniö <topi.reinio@qt.io> Reviewed-by: Martin Smith <martin.smith@qt.io>
* Compositor: Add documentation for XdgShellV6Johan Klokkhammer Helsing2018-03-261-0/+77
| | | | | | Change-Id: Ic6976f8368be7bbd61652fc1b62b6439d3509b81 Reviewed-by: Topi Reiniö <topi.reinio@qt.io> Reviewed-by: Martin Smith <martin.smith@qt.io>
* Fix crash when calling setVisible for EGL windows twice within one slotJohan Klokkhammer Helsing2018-03-233-11/+19
| | | | | | Task-number: QTBUG-63411 Change-Id: I56c367a1801d215e93bf195332272cfee300cdd8 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Make the minimal-cpp example a real compositorPaul Olav Tvete2018-03-214-22/+23
| | | | | | | | | Use the ivi-application protocol, since a compositor without a shell is not really a proper compositor. Use the IVI id to determine the position instead of generating a random position for each frame. Change-Id: I2ede824c656e4c2ef88117cf0f0b8d27ad80b6e2 Reviewed-by: Johan Helsing <johan.helsing@qt.io>
* Fix QWaylandXdgToplevelV6Private::lastSentConfigure()Johan Klokkhammer Helsing2018-03-211-1/+1
| | | | | | | | | | | Previously it would return the first pending configure instead of the last. This could sometimes cause sent state or size to get lost if handleFocusReceived() and one of the sendConfigure variants happened in rapid succession. Change-Id: I8cb379c4bcb7b05c027f7ede31e946ac5717d305 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
* Ensure a QWaylandQuickItem has keyboard focus before sending key eventsJohan Klokkhammer Helsing2018-03-211-1/+4
| | | | | | | | | If a QWaylandQuickItem had gotten focus in other ways than through QWaylandQuickItem::takeFocus, then the keyboard focus would not be updated. Change-Id: I6b5ee6d33449f0048e1c44765c1723eaa82ffd69 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
* xdg-shell v5,v6 shell integrations: Fix crash when showing popupsJohan Klokkhammer Helsing2018-03-204-7/+8
| | | | | | | | | | | | | | | | If a popup was shown without any input events happening first, it would cause nullptr dereferences in both xdg-shell v5 and v6. Fixes crashes in: - tst_QAccessibility::comboBoxTest - tst_QAccessibility::menuTest - tst_QWindow::touchInterruptedByPopup - tst_QFocusEvent::checkReason_Popup Task-number: QTBUG-67150 Change-Id: Ib3e06326f71e4ab5f74727cb4f79626a21c34d55 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Compositor: Fix various documentation issues for XdgShellV6Johan Klokkhammer Helsing2018-03-181-27/+25
| | | | | Change-Id: Ibb7063e10cd99294025935d073a96a7e8bf6ea22 Reviewed-by: Martin Smith <martin.smith@qt.io>
* Compositor: Don't call send_configure variants with an invalid sizeJohan Klokkhammer Helsing2018-03-153-0/+12
| | | | | | | | Print a warning and return instead. Change-Id: I1db5109f633ee2dc7d252b387c207f474784da43 Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Compositor API: Don't try to configure negative sizesJohan Klokkhammer Helsing2018-03-153-3/+7
| | | | | | Change-Id: Ie9df312a1926ea5190f6e91268b8920ad519d794 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
* Run shell agnostic tests on all shellsJohan Klokkhammer Helsing2018-03-132-0/+8
| | | | | | | And not just the default one. Change-Id: I6debbda9ae249f5f9df914901dc60722253b7d09 Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
* Mocking compositor: Don't leak wl_shell_surfacesJohan Klokkhammer Helsing2018-03-121-0/+4
| | | | | Change-Id: Ic133b41bdcfb98418be4a0141f382734f1d5db85 Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Add client-side tests for ivi-applicationJohan Klokkhammer Helsing2018-03-128-0/+363
| | | | | | | | Tests ivi surface creation and configuration. Task-number: QTBUG-66512 Change-Id: Idff60eb99eb34b7fce1c935bd036ef18a8f97d7c Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Don't try to create compatibility GL context when profile is unsetv5.11.0-beta2Johan Klokkhammer Helsing2018-03-091-4/+12
| | | | | | | | Context creation would sometimes fail because of this. Change-Id: Icf73a42ee2bb984ebfc09b7ed98f094d544134b8 Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io> Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Send configure events in shell-agnostic client testsJohan Klokkhammer Helsing2018-03-089-10/+78
| | | | | | | | | | xdg-shell >= unstable v6 requires surfaces to be configured before buffers can be attached. Make sure to send a configure event when a compositor would normally do it. Task-number: QTBUG-66510 Change-Id: Icbff6ebaa597e858d92d621849aa0df7a8a976f3 Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Client test for xdg-shell v6 configure eventsJohan Klokkhammer Helsing2018-03-086-34/+176
| | | | | | Task-number: QTBUG-66689 Change-Id: Ifdf38a9ab73357fdbe61e77f0464b227ddd2e8ac Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* QWindow::requestActivate() is not supported on WaylandJohan Klokkhammer Helsing2018-03-082-2/+3
| | | | | | | | | | Return false for the WindowActivation capability to ensure we don't run tests that require it. Change-Id: Ia24d6eef02d462a25f3d50597debda9e062b3955 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
* Fix nullptr dereference in client testsJohan Klokkhammer Helsing2018-03-081-1/+2
| | | | | Change-Id: I932cd20f17b5486a1161569c5e9a3feebabeee8e Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
* Test what happens when wl_display_connect failsJohan Klokkhammer Helsing2018-03-083-1/+65
| | | | | | | | | A failed wl_display_connect should make the platform plugin fail gracefully. Add a test for it to make sure. Change-Id: I87a3d9ee151fcdb1bc6ad9ffba44ad5014ede005 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
* Show warning when trying to minimize on wl-shellJohan Klokkhammer Helsing2018-03-071-1/+1
| | | | | Change-Id: Ice040dad70d0bcaf8bd101da5956ae75e211fe91 Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
* Add logging category for Wayland platform pluginJohan Klokkhammer Helsing2018-03-052-0/+5
| | | | | | Change-Id: Ic42119e47afc7bda72eb985fe86d1343a762c274 Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io> Reviewed-by: David Edmundson <davidedmundson@kde.org>
* Test for null pointer before using itAntonio Larrosa2018-03-051-1/+1
| | | | | | | | Task-number: QTBUG-66867 Change-Id: Ibbe407fa3ac32141b52fa0086e9f1ebfd27052ba Done-with: Fabian Vogt <fvogt@suse.de> Reviewed-by: Johan Helsing <johan.helsing@qt.io> Reviewed-by: Jan Grulich <jgrulich@redhat.com>
* Client: Implement QPlatformWindow::startSystemMove()Johan Klokkhammer Helsing2018-03-059-9/+24
| | | | | | | | | Hooks into what we already use for the window decorations. Task-number: QTBUG-58044 Change-Id: Idcd971f69d52a5bb760bb6bffb26e9f5bdd429df Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Remove unused variable QWaylandPointerPrivate::hasEnteredJohan Klokkhammer Helsing2018-03-011-1/+0
| | | | | Change-Id: I0aa381466ad48e47d87c8e3bcff3a162e91b13b3 Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>
* Ensure paintGL() is called in tst_WaylandClient::glWindow()Johan Klokkhammer Helsing2018-02-281-0/+4
| | | | | | | | The test is still skipped due to CI problems, though (QTBUG-65802). Task-number: QTBUG-66511 Change-Id: I79a67a80708de4cf2a7347a96c4b6344182d3ae0 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Use override when applicableJohan Klokkhammer Helsing2018-02-2886-118/+118
| | | | | | | | | | Applied automatic fixes using clang-tidy's modernize-use-override. This adds the "override" keyword where it's possible and also removes the "virtual" keyword when redundant. Change-Id: I899950e5cf8782785d30a245a9c69c1720905d50 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Use default member initialization for raw pointersJohan Klokkhammer Helsing2018-02-2879-150/+150
| | | | | | | | Initialize to nullptr to prevent undefined behavior. Change-Id: I7753c0be77a886d62ecb1cd7b86fc8c98340b0b8 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Init variables where they are declared when possible (clang-tidy)Johan Klokkhammer Helsing2018-02-27169-841/+385
| | | | | | | | | | | | | | | | | | | | clang-tidy -p compile_commands.json $file \ -checks='-*,modernize-use-default-member-init,readability-redundant-member-init' \ -config='{CheckOptions: [{key: modernize-use-default-member-init.UseAssignment, value: "1"}]}' \ -header-filter='qtwayland' \ -fix Afterwards I ran search and replace on the diff to clean up some whitespace errors: - Replaced '(\n\+[^:\n]*)(:\s+\+\s+)' with '$1: ' - Replaced '(\n\+[^,\n]*)(,\s+\+\s+)' with '$1, ' - Replaced '\n\+\s*\n' with '\n' I also had to do some manual edits, because for some reason, this particular clang-tidy check doesn't trigger for some files. Change-Id: I3b3909bac4bf20108bbe8ad1e01bcc54236dae1b Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Client: Fail gracefully when wl_display_connect failsJohan Klokkhammer Helsing2018-02-268-9/+52
| | | | | | | | | | | | | [ChangeLog][QPA plugin] If we're unable to create a connection to the Wayland display, fail gracefully so other platform integrations can be tried instead. This also adds QWaylandIntegration::hasFailed() which can later be extended to report that the platform plugin is unusable for other reasons. I.e. no compatible shell extensions or similar. Task-number: QTBUG-59762 Change-Id: I0f1ae73982e2860814235c1a189741d130e1db3e Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Client tests: Use generated classes for mocking shellsJohan Klokkhammer Helsing2018-02-268-237/+160
| | | | | | | | | Removes a lot of boiler-plate code and makes the two shells more similar. This also makes it easier to extend the shells with additional mocking functionality. Change-Id: I4a846b06eeda695527d7c5679df339beae983af6 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Fix use after free in tst_WaylandClient::dontCrashOnMultipleCommitsv5.11.0-beta1Kari Oikarinen2018-02-211-12/+14
| | | | | | | | QBackingStore had a pointer to TestWindow window, but it was destroyed only after the TestWindow was already deleted. Change-Id: Id8fe38277cf843d532f2d8c2fdbe1f69d0309a7f Reviewed-by: Johan Helsing <johan.helsing@qt.io>
* Fix crash when connecting a new screenJohan Klokkhammer Helsing2018-02-216-4/+65
| | | | | | | | | | | | | | | | | | | | | | In QWaylandWindow::virtualSiblings, don't include screens that have not been added yet. I.e. QWaylandScreens for which QPlatformIntegration::screenAdded has not yet been called. There are two reasons why this crash wasn't covered by the removePrimaryScreen() test. First of all, the mock output didn't send wl_output.done events when updating the mode/geometry. These wayland events are what causes QWindowSystemInterface::handleScreenGeometryChange() to be called (where virtualSiblings are called). Furthermore, virtualSiblings is only called when the geometry actually changes, so add a new test that changes the screen geometry of the existing screen while a new one is being added (i.e. moves it to the right). Task-number: QTBUG-62044 Change-Id: I623fbf8799d21c6b9293e7120ded301277639cc6 Reviewed-by: David Edmundson <davidedmundson@kde.org> Reviewed-by: Aleix Pol Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Fix flakiness in tst_WaylandClient::eventsJohan Klokkhammer Helsing2018-02-211-9/+11
| | | | | | | | | | | | | | | | | | | | | The test was flaky because we have a workaround for a bug in Weston where Weston fails to send the last wl_touch.frame event (QTBUG-36602). We've worked around it by letting our client handle the wl_touch.up event before the frame event if it's the last up event. This caused a race condition in our tests, though (which include the frame event). Because Q_TRY_COMPARE(window.touchEventCount, 1) would pass and the window was sometimes destroyed before the frame event had been sent by the compositor thread. Work around it by moving the touch testing before the pointer testing, so the surface is still alive when the compositor tries to send the frame event. That way the test will not be flaky, and will continue to work when we eventually remove the workaround in QWaylandInputDevice. Task-number: QTBUG-66537 Change-Id: I5673445682810e75343c6df2d1b2a4f1c1b21bcb Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* Use nullptr instead of 0 or NULLJohan Klokkhammer Helsing2018-02-2061-164/+164
| | | | | | | | Applied automatic fixes using clang-tidy's modernize-use-nullptr, and some manual cleanup to prevent QFlag macros to be affected. Change-Id: I88f94390185bc6e6f23693b68723cd5710815ae6 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Merge remote-tracking branch 'origin/5.9' into 5.11Liang Qi2018-02-180-0/+0
|\ | | | | | | | | | | | | Conflicts: .qmake.conf Change-Id: I509ec9f1f76f7476885f520ae05d3d6f83996398
| * Bump versionOswald Buddenhagen2018-02-021-1/+1
| | | | | | | | Change-Id: Iaf19695d09733bada6e2ba7394116d3b4c098332
* | Merge remote-tracking branch 'origin/5.10.1' into 5.11v5.11.0-alpha1Liang Qi2018-02-141-0/+29
|\ \ | | | | | | | | | Change-Id: I324e50a52462ab8188ef91446f15641a95ae0ddf
| * | Add changes file for Qt 5.10.1v5.10.1Antti Kokko2018-02-051-0/+29
| | | | | | | | | | | | | | | Change-Id: If1c56ae9507d8f0ee3c605b32ab2ef75a3c24693 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* | | Merge remote-tracking branch 'origin/5.10' into 5.11Liang Qi2018-02-123-2/+96
|\ \ \ | | | | | | | | | | | | Change-Id: I851b9b1bdfaa8be403d69f43b82a3f745038cc1c
| * \ \ Merge remote-tracking branch 'origin/5.9' into 5.105.10Liang Qi2018-02-023-2/+96
| |\ \ \ | | |/ / | |/| / | | |/ | | | | | | | | | Conflicts: src/compositor/extensions/extensions.pri Change-Id: Ia9a5bd52b7cac9a4f66e7c5deb43d89f0c792325
| | * Add documentation for QWaylandShellSurfaceJohan Klokkhammer Helsing2018-01-262-0/+94
| | | | | | | | | | | | | | | | | | Change-Id: I5948aea1afdd8b9a71e6de128a5203eb9422f5e1 Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io> Reviewed-by: Martin Smith <martin.smith@qt.io>
| | * Fix incorrect documentation of QWaylandQuickItem::paintEnabledJohan Klokkhammer Helsing2018-01-221-2/+2
| | | | | | | | | | | | | | | | | | Change-Id: Id24b417687843709d9f7df499c4e8c8428f658b6 Reviewed-by: Martin Smith <martin.smith@qt.io> Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* | | Compositor API: Add support for hardware compositingJohan Klokkhammer Helsing2018-02-0932-9/+1489
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ChangeLog][Compositor] Add a tech preview for a plugin-based hardware layer API and a VSP2 implementation (for Renesas R-Car M3 and H3). Task-number: QTBUG-64600 Task-number: QTBUG-64604 Change-Id: Ia4abfb6343cf4f006ba408d293ec9464cd6f31b7 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* | | Fix compilation for Renesas R-Car M3Johan Klokkhammer Helsing2018-02-082-2/+2
| | | | | | | | | | | | | | | Change-Id: Ib85001884bb880a18d8aa1241da0eb614a6b58ba Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* | | Test that xdg_toplevel_v6s are destroyed before xdg_surface_v6sJohan Klokkhammer Helsing2018-02-011-4/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | Adds an assert so tst_WaylandClientXdgShellV6::createDestroyWindow verifies deletion order. Task-number: QTBUG-65568 Change-Id: I0b4dd350f811495a9c7a78811915647fb713a43a Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io>