Skip to content

Add separate cursor and pointer options in DRM#785

Open
zhovner wants to merge 1 commit into
Igalia:masterfrom
flipperdevices:drm-pointer-events-without-cursor
Open

Add separate cursor and pointer options in DRM#785
zhovner wants to merge 1 commit into
Igalia:masterfrom
flipperdevices:drm-pointer-events-without-cursor

Conversation

@zhovner
Copy link
Copy Markdown

@zhovner zhovner commented Apr 28, 2026

There is no way to enable touchpad/trackball/mouse input without drawing a mouse cursor sprite.

Pointer event delivery in the DRM platform was gated on cursor.enabled, which only becomes true after init_cursor() successfully allocates a hardware cursor plane. Drivers that lack a DRM_PLANE_TYPE_CURSOR plane (e.g. drm_simple_kms_helper panels) silently dropped every libinput pointer event, making COG_PLATFORM_DRM_CURSOR effectively the master switch for pointer input rather than just the on-screen cursor sprite as its name implies.

Split into two independent options, each settable via env var, configuration file [drm] section, or -O command-line parameter:

cursor — draw a hardware cursor plane sprite (COG_PLATFORM_DRM_CURSOR)
pointer — forward libinput pointer events to WPE (COG_PLATFORM_DRM_POINTER)

Both default to off; cursor=on implies pointer=on so the legacy single-flag behaviour of COG_PLATFORM_DRM_CURSOR=1 is preserved.

Pointer event delivery in the DRM platform was gated on cursor.enabled,
which only becomes true after init_cursor() successfully allocates a
hardware cursor plane. Drivers that lack a DRM_PLANE_TYPE_CURSOR plane
(e.g. drm_simple_kms_helper panels) silently dropped every libinput
pointer event, making COG_PLATFORM_DRM_CURSOR effectively the master
switch for pointer input rather than just the on-screen cursor sprite
as its name implies.

Split into two independent options, each settable via env var,
configuration file [drm] section, or -O command-line parameter:

  cursor   draw a hardware cursor plane sprite (COG_PLATFORM_DRM_CURSOR)
  pointer  forward libinput pointer events to WPE (COG_PLATFORM_DRM_POINTER)

Both default to off; cursor=on implies pointer=on so the legacy
single-flag behaviour of COG_PLATFORM_DRM_CURSOR=1 is preserved.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant