If box->width/height is <= 0, the box doesn't contain any points, and so
there is no closest point. wlr_box_closest_point should return NAN in this
case.
In addition, we need to handle empty boxes in a few other
output-layout-related places, because outputs can have size 0x0 when
they are created or destroyed.
Without this information, compositors have no way to tell whether
or not to consider the position information valid. Most notably,
a compositor needs to know if it should pick a position for the
surface or use the position sent in the configure request.
This allows wlroots based compositors to properly use graphic tablets
with the wayland backend.
This should be a decent quality of life improvement when working on
tablet related features.
Since e26217c51e3a5e1d7dfc95a8a76299e056497981, touchpoints can outlive
surfaces. This works fine as long as the client stays around, but fails
horribly otherwise; therefore we have to make sure that touchpoints don't
outlive their clients.
Fixes#1788
When the surface is closed, we destroy all pending serials waiting to be
accepted. This means we need to ignore any future ack events, because we
can have the following events:
1. -> configure()
2. -> close()
3. <- ack_configure()
At point 3, wlroots will error the client because of invalid serial,
however the client hasn't processed close() yet.
Instead of checking that the path property is not 0 to determine if the
connector is an MST connector, check if the path contains the mst:
string.
Fixes#1813
This destroys the xdg popups associated with a layer surface when the
layer surface is unmapped. It does not make sense to keep the popups
open when unmapped.
libinput_event_touch_get_slot always returns -1 for single touch devices. Using
libinput_event_touch_get_seat_slot instead ensures that they are assigned actual
slot ids.
Also, this is what Weston does, so this change yields a more consistent
behaviour between different compositors.
From the xdg-shell specification:
If the parent is unmapped then its children are managed as
though the parent of the now-unmapped parent has become the
parent of this surface. If no parent exists for the now-unmapped
parent then the children are managed as though they have no
parent surface.
It's added to manager->input_methods list in manager_get_input_method, but
wasn't removed anywhere, leading to possible use-after-free in
wlr_input_method_manager_v2_destroy.
Instead of waiting for the next pageflip, destroy the output immediately
since we can now handle flips for outputs which no longer exist.
Also demote the missing crtc on flip to debug.
Fixes#1739
This adds support for xdg-output-unstable-v1 version 3, added in [1].
The xdg_output.done event is now deprecated and is replaced with
wl_output.done.
[1]: 962dd53537