gtk/gdk
Simon McVittie 79285bd63e gdkevents: Don't ignore modifiers that are not currently active
The X11 backend can mark modifiers like Shift as consumed even if they
aren't actually active, which seems to be something to do with making
shortcuts like `<Control><Shift>plus` and `<Control>plus` work as
intended regardless of whether the plus symbol is obtained by pressing
Shift and a key (like `+/=` on American, British or French keyboards)
or not (like `*/+` on German keyboards).

However, this can go badly wrong when the modifier is *not* pressed.
For example, terminals normally have separate bindings for `<Control>c`
(send SIGINT) and `<Control><Shift>c` (copy). If we disregard the
consumed modifiers completely, when the X11 backend marks Shift as
consumed, pressing Ctrl+c would send SIGINT *and* copy to the clipboard,
which is not what was intended.

By masking out the members of `consumed` that are not in `state`, we
get the same interpretation for X11 and Wayland, and ensure that
keyboard shortcuts that explicitly mention Shift can only be triggered
while holding Shift. It continues to be possible to trigger keyboard
shortcuts that do not explicitly mention Shift (such as `<Control>plus`)
while holding Shift, if the backend reports Shift as having been
consumed in order to generate the plus keysym.

Resolves: https://gitlab.gnome.org/GNOME/gtk/-/issues/5095
Bug-Debian: https://bugs.debian.org/1016927
Signed-off-by: Simon McVittie <smcv@debian.org>
2022-09-17 19:40:53 +01:00
..
broadway build: fix for use with glib 2.66.0 2022-08-06 21:11:08 +02:00
loaders Bump the jpeg memory limit 2022-08-22 10:48:00 -04:00
macos Merge branch 'gl-api-es-fix' into 'main' 2022-06-04 20:26:58 +00:00
wayland wayland/display: Remove duplicate update_scale() call 2022-09-03 00:53:02 +02:00
win32 gdk/win32: add missing Since tag for gdk_win32_display_get_egl_display 2022-08-25 17:33:25 +04:00
x11 Merge branch 'detect-stylus' into 'main' 2022-09-16 12:12:37 +00:00
COPYING
default_cursor.png
filetransferportal.c portal: Use the right mimetype for file transfers 2022-09-15 15:18:17 -04:00
filetransferportalprivate.h
gdk-autocleanup.h
gdk-private.h Some strdup avoidance 2022-08-25 14:33:30 -04:00
gdk.c gdk: Replace GTK_USE_PORTAL env var with GDK_DEBUG flag 2022-06-24 03:14:50 +02:00
gdk.h gdk: Split enums from types 2021-10-26 20:59:37 +02:00
gdkapplaunchcontext.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkapplaunchcontext.h gdk: Remove gdk.h include from gdk-private.h 2021-09-24 22:11:57 +02:00
gdkapplaunchcontextprivate.h
gdkarrayimpl.c gdkarray: Add a "stolen" boolean to splice() 2020-12-24 06:38:45 +01:00
gdkcairo.c cairo: Use GdkTexture for converting from pixbuf 2021-10-06 22:50:07 +02:00
gdkcairo.h gdk: Deprecate gdk_cairo_draw_from_gl() 2021-09-12 05:54:37 +02:00
gdkcairocontext.c gdk: Remove gdkinternals.h 2021-09-24 22:50:29 +02:00
gdkcairocontext.h
gdkcairocontextprivate.h
gdkcairoprivate.h gdk: Remove gdkinternals.h 2021-09-24 22:50:29 +02:00
gdkclipboard.c Some strdup avoidance 2022-08-25 14:33:30 -04:00
gdkclipboard.h
gdkclipboardprivate.h
gdkconfig.h.meson
gdkconfig.h.win32
gdkconfig.h.win32_vulkan
gdkconstructor.h
gdkcontentdeserializer.c Stop recursion in registering serializers 2022-09-06 23:35:48 -04:00
gdkcontentdeserializer.h gdk: Clean up docs syntax 2021-05-22 17:25:26 -04:00
gdkcontentformats.c Add constructors for GdkFileList 2022-07-28 14:41:35 +01:00
gdkcontentformats.h Add constructors for GdkFileList 2022-07-28 14:41:35 +01:00
gdkcontentformatsprivate.h
gdkcontentprovider.c Some strdup avoidance 2022-08-25 14:33:30 -04:00
gdkcontentprovider.h gdk: Clean up docs syntax 2021-05-22 17:25:26 -04:00
gdkcontentproviderimpl.c contentprovider: Switch wrong order in type check 2021-08-19 03:16:48 +02:00
gdkcontentproviderimpl.h
gdkcontentproviderprivate.h
gdkcontentserializer.c Stop recursion in registering serializers 2022-09-06 23:35:48 -04:00
gdkcontentserializer.h gdk: Clean up docs syntax 2021-05-22 17:25:26 -04:00
gdkcursor.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkcursor.h
gdkcursorprivate.h
gdkdebug.h gdk: Replace GTK_USE_PORTAL env var with GDK_DEBUG flag 2022-06-24 03:14:50 +02:00
gdkdevice.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkdevice.h gdk: Improve GdkTimeCoord docs 2022-06-06 08:55:51 -04:00
gdkdevicepad.c gdk: Clean up docs syntax 2021-05-22 17:25:26 -04:00
gdkdevicepad.h
gdkdevicepadprivate.h
gdkdeviceprivate.h gdk: Add gdk_device_get_timestamp 2021-03-26 10:30:33 -04:00
gdkdevicetool.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkdevicetool.h gdk: Split enums from types 2021-10-26 20:59:37 +02:00
gdkdevicetoolprivate.h
gdkdisplay.c egl: Fix invalid format string 2022-05-12 09:06:20 -04:00
gdkdisplay.h API: Add gdk_display_create_gl_context() 2021-10-20 20:31:33 +02:00
gdkdisplaymanager.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkdisplaymanager.h
gdkdisplaymanagerprivate.h
gdkdisplayprivate.h gdk: use EGL_KHR_swap_buffers_with_damage 2022-03-03 01:22:01 -08:00
gdkdrag.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkdrag.h gdk: Split enums from types 2021-10-26 20:59:37 +02:00
gdkdragprivate.h
gdkdragsurface.c gdk: Clean up docs syntax 2021-05-22 17:25:26 -04:00
gdkdragsurface.h
gdkdragsurfaceprivate.h
gdkdrawcontext.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkdrawcontext.h
gdkdrawcontextprivate.h gdk: hdr => high depth 2021-10-06 22:50:07 +02:00
gdkdrop.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkdrop.h gdk: Split enums from types 2021-10-26 20:59:37 +02:00
gdkdropprivate.h
gdkenums.h gdk: Split enums from types 2021-10-26 20:59:37 +02:00
gdkenumtypes.c.template
gdkenumtypes.h.template
gdkevents.c gdkevents: Don't ignore modifiers that are not currently active 2022-09-17 19:40:53 +01:00
gdkevents.h gdk: Add enum to indicate the unit of scroll deltas 2022-03-19 00:41:26 +01:00
gdkeventsprivate.h gdk/events: Add constructor for high-resolution scroll events 2022-08-10 14:23:58 +00:00
gdkframeclock.c gdk: Remove gdkinternals.h 2021-09-24 22:50:29 +02:00
gdkframeclock.h gdk: fix typo in frame clock docs 2022-09-01 12:16:10 -07:00
gdkframeclockidle.c frameclock: Run paint idle from flush idle 2022-07-10 21:33:32 +02:00
gdkframeclockidleprivate.h
gdkframeclockprivate.h
gdkframetimings.c docs: Rework the gdk docs 2021-03-11 16:37:31 +00:00
gdkframetimings.h
gdkgl.c gdk: Remove unused gdk_gl_texture_quads() function 2021-10-06 03:44:36 +02:00
gdkglcontext.c Merge branch 'gl-api-es-fix' into 'main' 2022-06-04 20:26:58 +00:00
gdkglcontext.h glcontext: Add gdk_gl_context_get_api() 2021-10-08 03:31:07 +02:00
gdkglcontextprivate.h Merge branch 'gl-api-es-fix' into 'main' 2022-06-04 20:26:58 +00:00
gdkglobals.c gdk: Remove gdkinternals.h 2021-09-24 22:50:29 +02:00
gdkgltexture.c gdk/gl: handle GL_RGBA/GL_UNSIGNED_NORMALIZED 2022-03-24 18:05:11 -07:00
gdkgltexture.h docs: Rework the gdk docs 2021-03-11 16:37:31 +00:00
gdkgltextureprivate.h
gdkhsla.c gdk_rgba_parse: Support HSL colors 2021-09-10 16:56:42 -05:00
gdkhslaprivate.h gdk: Remove gdk.h include from header 2021-09-24 22:11:57 +02:00
gdkintl.h Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkkeynames.c gdk: Remove gdkinternals.h 2021-09-24 22:50:29 +02:00
gdkkeys.c gdk: Drop an unused function 2022-07-16 09:43:46 -04:00
gdkkeys.h
gdkkeysprivate.h gdk: Drop an unused function 2022-07-16 09:43:46 -04:00
gdkkeysyms-update.pl Update the link to the development branch 2022-01-13 14:42:34 +00:00
gdkkeysyms.h Update the link to the development branch 2022-01-13 14:42:34 +00:00
gdkkeyuni.c gdk: Update keyboard symbols from libxkbcommon 2022-01-29 14:31:09 +02:00
gdkmarshalers.list surface: add missing va_marshaller for layout signal 2021-12-07 22:21:19 -08:00
gdkmemoryformat.c gdk: Add a rgb8 → rgba8 conversion macro 2022-03-03 16:05:52 +01:00
gdkmemoryformatprivate.h gdk: Split enums from types 2021-10-26 20:59:37 +02:00
gdkmemorytexture.c Fixes for gdk_memory_texture_new_subtexture 2022-05-13 09:30:46 -04:00
gdkmemorytexture.h gdk: Split enums from types 2021-10-26 20:59:37 +02:00
gdkmemorytextureprivate.h gl: Refactor texture uploading 2021-10-13 14:33:44 +02:00
gdkmonitor.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkmonitor.h
gdkmonitorprivate.h
gdkpaintable.c Some strdup avoidance 2022-08-25 14:33:30 -04:00
gdkpaintable.h docs: Fix vfunc references 2021-08-29 04:29:02 +02:00
gdkpango.c Use pango api better 2022-01-22 23:10:53 -05:00
gdkpango.h
gdkpipeiostream.c gdk: Plug a memleak 2022-08-19 02:38:11 +02:00
gdkpipeiostreamprivate.h
gdkpixbuf-drawable.c gdk: Rework gdk_pixbuf_get_from_texture() 2021-10-18 12:08:57 +02:00
gdkpixbuf.h
gdkpopup.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkpopup.h docs: Rework the gdk docs 2021-03-11 16:37:31 +00:00
gdkpopuplayout.c docs: More syntax fixes 2021-05-22 21:21:10 -04:00
gdkpopuplayout.h gdk: Split enums from types 2021-10-26 20:59:37 +02:00
gdkpopupprivate.h
gdkprofiler.c
gdkprofilerprivate.h profiler: allow using gdk profiler functions without braces 2021-02-08 11:29:32 -08:00
gdkrectangle.c gdk: Clean up docs syntax 2021-05-22 17:25:26 -04:00
gdkrectangle.h
gdkrgba.c docs: standard names are CSS names, not X11 names 2021-10-27 22:12:58 +00:00
gdkrgba.h Annotate gdk_rgba_to_string as malloc 2021-09-14 16:38:08 -04:00
gdkrgbaprivate.h rgba: Fix GDK_RGBA() macro to work with alpha 2022-02-08 01:34:19 +01:00
gdkseat.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdkseat.h
gdkseatdefault.c gdk/x11: Implement XI2.4 touchpad gesture support 2021-09-27 23:19:33 +03:00
gdkseatdefaultprivate.h
gdkseatprivate.h seat: improve api to take into account the tool type 2021-01-07 12:50:48 +01:00
gdksnapshot.c docs: Rework the gdk docs 2021-03-11 16:37:31 +00:00
gdksnapshot.h docs: Rework the gdk docs 2021-03-11 16:37:31 +00:00
gdksnapshotprivate.h
gdksurface.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdksurface.h
gdksurfaceprivate.h egl: Implement HDR support 2021-10-06 03:44:59 +02:00
gdktexture.c Remove all nicks and blurbs from param specs 2022-05-11 18:16:29 +02:00
gdktexture.h gdk: drop removed method from the header 2021-12-09 20:29:17 +00:00
gdktextureprivate.h gdk: Split enums from types 2021-10-26 20:59:37 +02:00
gdktoplevel.c Some strdup avoidance 2022-08-25 14:33:30 -04:00
gdktoplevel.h g-i: add missing since annotations 2021-11-13 17:50:53 +01:00
gdktoplevellayout.c gdk: Clean up docs syntax 2021-05-22 17:25:26 -04:00
gdktoplevellayout.h docs: Remove duplicate documentation stanzas 2021-03-11 16:37:31 +00:00
gdktoplevelprivate.h gdk/toplevel: Add gdk_toplevel_titlebar_gesture() 2021-07-29 21:39:32 +02:00
gdktoplevelsize.c gdktoplevelsize: Comment out some unused code 2021-05-03 07:44:38 -04:00
gdktoplevelsize.h docs: Remove duplicate documentation stanzas 2021-03-11 16:37:31 +00:00
gdktoplevelsizeprivate.h
gdktypes.h gdk: Split enums from types 2021-10-26 20:59:37 +02:00
gdkversionmacros.h.in Add 4.8 version macros 2022-02-22 22:55:48 -05:00
gdkvulkancontext.c docs: Cosmetics 2021-10-18 08:35:54 -04:00
gdkvulkancontext.h
gdkvulkancontextprivate.h gdk: Split enums from types 2021-10-26 20:59:37 +02:00
gen-gdk-gresources-xml.py gdk: Remove unused gdk_gl_texture_quads() function 2021-10-06 03:44:36 +02:00
gen-keyname-table.pl
keyname-table.h
keynames-translate.txt
keynames.txt
meson.build gdk: Split enums from types 2021-10-26 20:59:37 +02:00