Skip to content

[Wayland] Delayed event.is_released() outside of game window #106284

Closed
@Damglador

Description

@Damglador

Tested versions

  • Reproducable on Godot v4.4.1.stable.arch_linux

System information

Godot v4.4.1.stable unknown - Arch Linux (KDE Plasma Wayland as DE) #1 SMP PREEMPT_DYNAMIC Fri, 09 May 2025 17:20:29 +0000 on Wayland - Wayland display driver, Single-window, 1 monitor - Vulkan (Mobile) - integrated AMD Radeon Graphics (RADV RENOIR) - AMD Ryzen 5 5600H with Radeon Graphics (12 threads)

Issue description

I have Emulate Touch From Mouse turned on and use the following function to get start and end point of a drag:

var startpos = null
var endpos = null
func _input(event: InputEvent) -> void:
	if event is InputEventScreenTouch:
		if event.is_pressed():
			startpos = event.get_position()
		if event.is_released():
			endpos = event.get_position()
			_launch(startpos, endpos)

When end of drag is inside the game window, it passes it to _launch in no time, but when it's outside of the window - it takes a second or so. This issue is not present on X11 or Windows builds of the game run under Wine in Wayland native mode

Steps to reproduce

  • Enable Wayland in project settings
  • Enable Emulate Touch From Mouse
  • Use the code below in a node of a scene
  • Click and hold LMB in the game window, move it out of the window and release it
func _input(event: InputEvent) -> void:
	if event is InputEventScreenTouch:
		if event.is_released():
			print("End of drag")

Minimal reproduction project (MRP)

MRP.zip

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions