Skip to content

feat(computer): pointer press and release during a take-over - #1795

Merged
edenreich merged 1 commit into
mainfrom
feat/pointer-press-release
Nov 10, 2026
Merged

edenreich merged 1 commit into
mainfrom
feat/pointer-press-release

Conversation

@edenreich

@edenreich edenreich commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

Summary

A person who took a screen over could not drag: a click was always a press followed at once by a release. screen_input now accepts mouse_down and mouse_up, so a client can hold a button down, send move inputs and let go. That covers dragging a window, moving a file, selecting text with the pointer and sliders.

Resolves #1792

Changes

  • internal/computer/domain - the mouse_down and mouse_up action kinds, accepted as person inputs with a position and a button, and HeldButtons, the buttons a person pressed and has not let go of.
  • internal/computer/infrastructure/display - PressMouse and ReleaseMouse on DisplayController. GNOME Wayland sends one NotifyPointerButton, and X11, wlroots Wayland, macOS and Windows use robotgo's Toggle.
  • internal/computer/input_dispatch.go - a press or release moves the pointer to its position, then holds or lets go of the button.
  • internal/computer/screen_control.go - tracks the held buttons during a hold and releases them on hand-back, so the agent never gets the screen back mid-drag.
  • Docs - docs/browser-extension-protocol.md lists the new input kinds, and docs/computer-use.md mentions dragging.

The Computer tool is unchanged: the executor routes only its own kinds, so the agent cannot send a press or release.

Testing

  • task precommit:run and task test pass, with new tests for the input mapping, the held-button tracking, the dispatch and the controller's toggle calls. It builds for Linux, Windows and macOS.
  • TestToggleArguments is Linux-only and was vetted, not run, on the macOS machine this was written on.
  • Not verified on a real computer. A drag on a GNOME Wayland computer, such as moving a window by its title bar, still needs a manual check before merge.

Not included

  • A button is released on hand-back, but not when a client disconnects while it still holds the screen.
  • The Desktop app does not send these inputs yet.

Docs follow-up: inference-gateway/docs#1172.

A person who holds the screen can press a pointer button, move and let go, which drags. A button still down when the screen is handed back is released.

Resolves #1792
@github-project-automation github-project-automation Bot moved this to Todo in 2026 Nov 10, 2026
@edenreich
edenreich marked this pull request as ready for review November 10, 2026 00:27
@edenreich
edenreich requested a review from a team as a code owner November 10, 2026 00:27
@edenreich
edenreich merged commit 981fbe2 into main Nov 10, 2026
1 check passed
@edenreich
edenreich deleted the feat/pointer-press-release branch November 10, 2026 00:31
@edenreich edenreich moved this from Todo to Done in 2026 Nov 10, 2026
@inference-gateway-releaser

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 0.253.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@inference-gateway-releaser inference-gateway-releaser Bot added the released Shipped in a release label Nov 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

released Shipped in a release

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

[FEATURE] Pointer press and release during a take-over, so a person can drag

1 participant