Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package xwayland for openSUSE:Factory checked in at 2022-11-03 19:13:30 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/xwayland (Old) and /work/SRC/openSUSE:Factory/.xwayland.new.2275 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "xwayland" Thu Nov 3 19:13:30 2022 rev:16 rq:1032862 version:22.1.5 Changes: -------- --- /work/SRC/openSUSE:Factory/xwayland/xwayland.changes 2022-10-25 11:18:35.441948243 +0200 +++ /work/SRC/openSUSE:Factory/.xwayland.new.2275/xwayland.changes 2022-11-03 19:13:36.679805292 +0100 @@ -1,0 +2,13 @@ +Wed Nov 2 11:27:06 UTC 2022 - Stefan Dirsch <sndir...@suse.com> + +- Update to version 22.1.5 + * This is a follow-up release to address a couple of regressions + which found their way into the recent xwayland-22.1.4 release, + namely: + + Double scroll wheel events with some Wayland compositors + https://gitlab.freedesktop.org/xorg/xserver/-/issues/1392 + + Key keeps repeating when a window is closed while a key is pressed + https://gitlab.freedesktop.org/xorg/xserver/-/issues/1395 +- supersedes U_Do-not-ignore-leave-events.patch + +------------------------------------------------------------------- Old: ---- U_Do-not-ignore-leave-events.patch xwayland-22.1.4.tar.xz xwayland-22.1.4.tar.xz.sig New: ---- xwayland-22.1.5.tar.xz xwayland-22.1.5.tar.xz.sig ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ xwayland.spec ++++++ --- /var/tmp/diff_new_pack.oVZFWz/_old 2022-11-03 19:13:37.259808703 +0100 +++ /var/tmp/diff_new_pack.oVZFWz/_new 2022-11-03 19:13:37.263808727 +0100 @@ -24,7 +24,7 @@ %endif Name: xwayland -Version: 22.1.4 +Version: 22.1.5 Release: 0 URL: http://xorg.freedesktop.org/ Summary: X @@ -33,7 +33,6 @@ Source0: %{url}/archive/individual/xserver/%{name}-%{version}.tar.xz Source1: %{url}/archive/individual/xserver/%{name}-%{version}.tar.xz.sig Source2: xwayland.keyring -Patch0: U_Do-not-ignore-leave-events.patch BuildRequires: meson BuildRequires: ninja BuildRequires: pkgconfig ++++++ xwayland-22.1.4.tar.xz -> xwayland-22.1.5.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/xwayland-22.1.4/hw/xwayland/xwayland-input.c new/xwayland-22.1.5/hw/xwayland/xwayland-input.c --- old/xwayland-22.1.4/hw/xwayland/xwayland-input.c 2022-10-20 09:24:51.000000000 +0200 +++ new/xwayland-22.1.5/hw/xwayland/xwayland-input.c 2022-11-02 10:01:42.000000000 +0100 @@ -50,6 +50,12 @@ #include "pointer-gestures-unstable-v1-client-protocol.h" #include "xwayland-keyboard-grab-unstable-v1-client-protocol.h" +struct axis_discrete_pending { + struct xorg_list l; + uint32_t axis; + int32_t discrete; +}; + struct sync_pending { struct xorg_list l; DeviceIntPtr pending_dev; @@ -608,36 +614,6 @@ } static void -dispatch_scroll_motion(struct xwl_seat *xwl_seat) -{ - ValuatorMask mask; - const int divisor = 10; - wl_fixed_t dy = xwl_seat->pending_pointer_event.scroll_dy; - wl_fixed_t dx = xwl_seat->pending_pointer_event.scroll_dx; - int32_t discrete_dy = xwl_seat->pending_pointer_event.scroll_discrete_dy; - int32_t discrete_dx = xwl_seat->pending_pointer_event.scroll_discrete_dx; - - valuator_mask_zero(&mask); - if (xwl_seat->pending_pointer_event.has_vertical_scroll) - valuator_mask_set_double(&mask, - 3, - wl_fixed_to_double(dy) / divisor); - else if (xwl_seat->pending_pointer_event.has_vertical_scroll_discrete) - valuator_mask_set(&mask, 3, discrete_dy); - - if (xwl_seat->pending_pointer_event.has_horizontal_scroll) - valuator_mask_set_double(&mask, - 2, - wl_fixed_to_double(dx) / divisor); - else if (xwl_seat->pending_pointer_event.has_horizontal_scroll_discrete) - valuator_mask_set(&mask, 2, discrete_dx); - - QueuePointerEvents(get_pointer_device(xwl_seat), - MotionNotify, 0, POINTER_RELATIVE, &mask); -} - - -static void dispatch_pointer_motion_event(struct xwl_seat *xwl_seat) { Bool has_relative = xwl_seat->pending_pointer_event.has_relative; @@ -653,18 +629,8 @@ dispatch_absolute_motion(xwl_seat); } - if (xwl_seat->pending_pointer_event.has_vertical_scroll || - xwl_seat->pending_pointer_event.has_horizontal_scroll || - xwl_seat->pending_pointer_event.has_vertical_scroll_discrete || - xwl_seat->pending_pointer_event.has_horizontal_scroll_discrete) - dispatch_scroll_motion(xwl_seat); - xwl_seat->pending_pointer_event.has_absolute = FALSE; xwl_seat->pending_pointer_event.has_relative = FALSE; - xwl_seat->pending_pointer_event.has_vertical_scroll = FALSE; - xwl_seat->pending_pointer_event.has_horizontal_scroll = FALSE; - xwl_seat->pending_pointer_event.has_vertical_scroll_discrete = FALSE; - xwl_seat->pending_pointer_event.has_horizontal_scroll_discrete = FALSE; } static void @@ -721,17 +687,42 @@ uint32_t time, uint32_t axis, wl_fixed_t value) { struct xwl_seat *xwl_seat = data; + int index; + const int divisor = 10; + ValuatorMask mask; + struct axis_discrete_pending *pending = NULL; + struct axis_discrete_pending *iter; switch (axis) { case WL_POINTER_AXIS_VERTICAL_SCROLL: - xwl_seat->pending_pointer_event.has_vertical_scroll = TRUE; - xwl_seat->pending_pointer_event.scroll_dy = value; + index = 3; break; case WL_POINTER_AXIS_HORIZONTAL_SCROLL: - xwl_seat->pending_pointer_event.has_horizontal_scroll = TRUE; - xwl_seat->pending_pointer_event.scroll_dx = value; + index = 2; break; + default: + return; + } + + xorg_list_for_each_entry(iter, &xwl_seat->axis_discrete_pending, l) { + if (iter->axis == axis) { + pending = iter; + break; + } + } + + valuator_mask_zero(&mask); + + if (pending) { + valuator_mask_set(&mask, index, pending->discrete); + xorg_list_del(&pending->l); + free(pending); + } else { + valuator_mask_set_double(&mask, index, wl_fixed_to_double(value) / divisor); } + + QueuePointerEvents(get_pointer_device(xwl_seat), + MotionNotify, 0, POINTER_RELATIVE, &mask); } static void @@ -754,18 +745,6 @@ pointer_handle_axis_stop(void *data, struct wl_pointer *wl_pointer, uint32_t time, uint32_t axis) { - struct xwl_seat *xwl_seat = data; - - switch (axis) { - case WL_POINTER_AXIS_VERTICAL_SCROLL: - xwl_seat->pending_pointer_event.has_vertical_scroll = TRUE; - xwl_seat->pending_pointer_event.scroll_dy = 0; - break; - case WL_POINTER_AXIS_HORIZONTAL_SCROLL: - xwl_seat->pending_pointer_event.has_horizontal_scroll = TRUE; - xwl_seat->pending_pointer_event.scroll_dx = 0; - break; - } } static void @@ -774,16 +753,14 @@ { struct xwl_seat *xwl_seat = data; - switch (axis) { - case WL_POINTER_AXIS_VERTICAL_SCROLL: - xwl_seat->pending_pointer_event.has_vertical_scroll_discrete = TRUE; - xwl_seat->pending_pointer_event.scroll_discrete_dy = discrete; - break; - case WL_POINTER_AXIS_HORIZONTAL_SCROLL: - xwl_seat->pending_pointer_event.has_horizontal_scroll_discrete = TRUE; - xwl_seat->pending_pointer_event.scroll_discrete_dx = discrete; - break; - } + struct axis_discrete_pending *pending = malloc(sizeof *pending); + if (!pending) + return; + + pending->axis = axis; + pending->discrete = discrete; + + xorg_list_add(&pending->l, &xwl_seat->axis_discrete_pending); } static const struct wl_pointer_listener pointer_listener = { @@ -1053,9 +1030,6 @@ struct xwl_seat *xwl_seat = data; uint32_t *k; - if (surface != NULL && !is_surface_from_xwl_window(surface)) - return; - xwl_seat->xwl_screen->serial = serial; wl_array_for_each(k, &xwl_seat->keys) @@ -1759,6 +1733,7 @@ wl_array_init(&xwl_seat->keys); xorg_list_init(&xwl_seat->touches); + xorg_list_init(&xwl_seat->axis_discrete_pending); xorg_list_init(&xwl_seat->sync_pending); } @@ -1767,6 +1742,7 @@ { struct xwl_touch *xwl_touch, *next_xwl_touch; struct sync_pending *p, *npd; + struct axis_discrete_pending *ad, *ad_next; xorg_list_for_each_entry_safe(xwl_touch, next_xwl_touch, &xwl_seat->touches, link_touch) { @@ -1779,6 +1755,11 @@ free (p); } + xorg_list_for_each_entry_safe(ad, ad_next, &xwl_seat->axis_discrete_pending, l) { + xorg_list_del(&ad->l); + free(ad); + } + release_tablet_manager_seat(xwl_seat); release_grab(xwl_seat); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/xwayland-22.1.4/hw/xwayland/xwayland-input.h new/xwayland-22.1.5/hw/xwayland/xwayland-input.h --- old/xwayland-22.1.4/hw/xwayland/xwayland-input.h 2022-10-20 09:24:51.000000000 +0200 +++ new/xwayland-22.1.5/hw/xwayland/xwayland-input.h 2022-11-02 10:01:42.000000000 +0100 @@ -93,6 +93,7 @@ char *keymap; struct wl_surface *keyboard_focus; + struct xorg_list axis_discrete_pending; struct xorg_list sync_pending; struct xwl_pointer_warp_emulator *pointer_warp_emulator; @@ -110,15 +111,6 @@ double dy; double dx_unaccel; double dy_unaccel; - - wl_fixed_t scroll_dy; - wl_fixed_t scroll_dx; - int32_t scroll_discrete_dy; - int32_t scroll_discrete_dx; - Bool has_vertical_scroll; - Bool has_horizontal_scroll; - Bool has_vertical_scroll_discrete; - Bool has_horizontal_scroll_discrete; } pending_pointer_event; struct xorg_list tablets; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/xwayland-22.1.4/meson.build new/xwayland-22.1.5/meson.build --- old/xwayland-22.1.4/meson.build 2022-10-20 09:24:51.000000000 +0200 +++ new/xwayland-22.1.5/meson.build 2022-11-02 10:01:42.000000000 +0100 @@ -3,7 +3,7 @@ 'buildtype=debugoptimized', 'c_std=gnu99', ], - version: '22.1.4', + version: '22.1.5', meson_version: '>= 0.47.0', ) release_date = '2021-07-05'