| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit 6bb05fed8fdb564f3ff0136bbdaf4efd6088797d.
Revert of commercial license headers is required for Qt 5.15.3
opensource release.
Task-number: QTBUG-91108
Change-Id: Ia867596ca140b1c37717baafe07cbcddd2a9b1fd
Reviewed-by: Akseli Salovaara <akseli.salovaara@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Updated header.COMM to the files in tqtc-qtwayland. Examples,
tests and documentation files are 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-4214
Change-Id: Ib716dd7c17587d0155b6903f5cf62be3f99384bf
Reviewed-by: Antti Kokko <antti.kokko@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
This shouldn't change any behavior, but lets the shell integrations choose
if they want to use the extremely hacky QWaylandWindow::transientParent().
Hint: Not all shells need the hacks, and not all shells need them in all cases,
and some shells may need even more hacks.
Change-Id: Id105e4feb83cc9c14dcf07dcca55fcd5e63d4a2b
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The problem:
The code in QWaylandWindow::setWindowStateInternal made many assumptions about
how the shell surface responded to new window states, and when and if they were
applied. Particularly:
- The shell integrations support different subsets of Qt::WindowStates, so it
doesn't make sense to map from states to setFullscreen, setNormal, etc. in
QWaylandWindow because it really depends on the shell integration how it
should be handled.
- Some states are not supported/unknown on some shells and should immediately be
rejected.
- On some shells, particularly those where the current state is unknown, flags
need to be resent even though they didn't change.
- Should handleWindowStatesChanged be called immediately (client decides) or
should it wait for a configure event (compositor decides)? I.e. the mState
variable only makes sense for some shells.
Furthermore, when state changes come from the compositors, some shell
integrations require that a configure event is acked by the client and that the
next committed buffer's size and content matches that configure event.
Previously, we would just ack immediately and still send a buffer with the old
size before a correct frame was drawn. i.e. sending incorrect acks, which would
lead to protocol errors on some compositors.
Additionally, QWaylandWindow::createDecoration() also assumed that windows
should have decorations unless they are fullscreen. This is not always the
case, particularly on ivi-application and probably on future shell integrations
for embedded or tiling window managers etc.
The Solution:
The responsibility of mapping requested window states to Wayland requests have
been moved to the QWaylandShellSurface implementation. QWaylandWindow now calls
a new virtual, QWaylandShellSurface::requestWindowStates(Qt::WindowStates),
instead of trying to be smart about it. The virtual getters and setters for
window states have now been removed from the QWaylandShellSurface interface.
It's now also the shell surface implementation's responsibility to call
QWaylandWindow::handleWindowStatesChanged if and when it knows a new state is
effective.
QWaylandWindow::configure has been replaced with
QWaylandWindow::applyConfigureWhenPossible(), which causes another new virtual,
QWaylandShellSurface::applyConfigure(), to be called whenever we're free to
resize and change the states of the next buffer (this is when states should be
acked). This means that shells that use acked states need to store the pending
states themselves, call applyConfigureWhenPossible(), wait for applyConfigure()
to be called, call resizeFromApplyConfigure() and handleWindowStatesChanged(),
and finally ack the applied state.
Acked state for xdg-shell v5 and v6 has now been implemented, which also means
we've now:
[ChangeLog][QPA plugin] Implemented support for maximizing, minimizing, and
setting fullscreen with xdg-shell unstable v6.
[ChangeLog][QPA plugin] QWindow::isActive now follows configure events on
xdg-shell unstable v6 (like v5).
QWaylandWindow::createDecoration queries QWaylandShellSurface::wantsDecoration
before creating window decorations, instead of using the previously unreliable
QWaylandWindow::isFullscreen().
[ChangeLog][QPA plugin] Window decorations are now automatically disabled for
ivi-application.
The refactor also removes a couple of hacks:
- QWindowSystemInterface::flushWindowSystemEvents() was called in
QWaylandWindow::setWindowStates. Since this hack was introduced, the events
now have oldState and newState members, and their values seem to make sense
(ensured in the tests).
- The hack for unminimizing on xdg-shell v5 in QWaylandWindow::createDecoration
was not needed anymore.
Finally, tests have been added for xdg-shell v6 to ensure that the right Wayland
requests are sent, that we respond to configure events from the compositor, and
that the Qt events and signals emitted on the client side make sense.
Task-number: QTBUG-53702
Task-number: QTBUG-63417
Task-number: QTBUG-63748
Task-number: QTBUG-66928
Change-Id: Ib4c36b69105750f9dbdcc78adcf71e2e994cc70d
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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>
|
|
|
|
|
|
|
| |
Change-Id: I9699a957430b8d3574ce29acb91b7ada9ea6209b
Reviewed-by: Jan Arne Petersen <jan.petersen@kdab.com>
Reviewed-by: Johan Helsing <johan.helsing@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
|
|
|
|
|
|
|
|
|
|
| |
Currently tests are licensed under GPL-EXCEPT, examples under BSD and
src under LGPL so replase old license headers with new & proper ones.
Also remove old & unused license files
Task-number: QTBUG-57147
Change-Id: Ia6a738798736c275dc309ccfa5b627dc2178d241
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
|
|
|
|
|
|
| |
Change-Id: I2c2debe47fcb173f02aef5f4e60e52c35ad7b395
Reviewed-by: Yusuke Binsaki <yusuke.binsaki@itage.co.jp>
Reviewed-by: Giulio Camuffo <giulio.camuffo@kdab.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This changes the shell surface handling for windows, and instead of
creating the shell surface at initialization time, and then attaching
a null buffer to hide it, it creates the shell surface on setVisible(true),
and destroys it on setVisible(false).
This fixes hiding when using xdg_shell, as that interface defines that
attaching a null buffer to an xdg_surface is an error.
Also this should help with bugged EGL drivers which attach a buffer
after eglSwapBuffers() returns, which used to cause a newly hidden
window to get a new valid buffer after we attached a null one, showing
it again.
Task-number: QTBUG-47902
Change-Id: I8e0a0442319a98cc1361803ea7be1d079b36fc8c
Reviewed-by: Johan Helsing <johan.helsing@qt.io>
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
|
|
IVI-shell provides a shell interface for Weston, which maps the GENIVI
API (http://www.genivi.org) for In-Vehicle Infotainment as Wayland-Ivi-Extension
(http://wiki.projects.genivi.org/index.php/Wayland_IVI_Extension_Design).
This patch is included in two protocol. The first is ivi-application protocol
which provided by weston. Next is ivi-controller protocol which provided by
Genivi's wayland-ivi-extension.
In IVI use case, the client create and destroy surface with the unique ID
by using ivi-application protocol. On the other hand, the controller such as
HMI Controller control some properties, which are visibility, position, size,
etc, with created the unique ID by using ivi-controller protocol.
It means the unique ID is necessary to create and control the ivi-surface and
the the ivi-layer. However Qt has no API to set the some surface or layer ID.
In this ivi-shell plugin, the unique ID can be set via the environment
parameter so that we can control the ivi-surface and ivi-layer. The
name of environment parameter is QT_IVI_SURFACE_ID.
QT_IVI_SURFACE_ID will be used as ivi-surface and ivi-layer. If application
needs more than two surfaces, ivi-surface IDs will be incremented.
When QT_IVI_SURFACE_ID isn't set, ivi-surface and ivi-layer ID will be
generated internally. The ID consists of the process ID and the surface
ID which is incremented in ivi-shell plugin.
The process ID is used as lower 22 bit per 32bit. 23 to 32 bit is used as
the surface IDs in a process.
e.g. When the process ID is 0x765 and create two surfaces,
ivi-layer ID is 0x765 and ivi-surface IDs are 0x765 and 0x00400765.
+------------+---------------------------+
|31 23|22 0|
+------------+---------------------------+
|0000 0000 00|00 0000 0000 0000 0000 0000|
|<- ID ->|<- process ID ->|
+------------+---------------------------+
We can set QT_WAYLAND_SHELL_INTEGRATION of the environment
parameter to "ivi-shell" to use IVI-shell.
Change-Id: Iddcfb3de89dc022530c0285524cf6bbf640147b6
Reviewed-by: Giulio Camuffo <giuliocamuffo@gmail.com>
|