[ktn] xdg-desktop-portal-wlr-ktn

Screen sharing on sway and other wlroots compositors that asks once, even for single windows, and starts without waiting for the window to change

sudo pacman -S ktn/xdg-desktop-portal-wlr-ktn
Version0.8.4.20261004052721.gb835229-1
Updated
Upstream basev0.8.4
Upstreamhttps://github.com/emersion/xdg-desktop-portal-wlr
Sourcehttps://github.com/Kautiontape/xdg-desktop-portal-wlr
Providesxdg-desktop-portal-impl, xdg-desktop-portal-wlr=0.8.4
Conflictsxdg-desktop-portal-wlr
Dependsglibc, grim, libdrm, libinih, libpipewire, mesa, pipewire, pipewire-session-manager, slurp, systemd-libs, wayland, xdg-desktop-portal
Retire whenAn upstream release restores window shares from restore_data (toplevel_identifier) and delivers the first frame to late-starting consumers; checked by hand. Both patches to be offered upstream (the first against issue #170).

What it is

The standard xdg-desktop-portal backend for wlroots compositors such as sway, with two fixes:

Why it exists

Chromium and Electron apps (Discord clients like Vesktop, browsers, Slack) open a second portal session when a share actually starts, and another whenever the stream's quality changes. They pass a restore token from the first session so you aren't asked again. Stock xdpw only issues those tokens for monitors. Sharing a single window therefore pops the source picker two or three times, and backing out of any of them kills the share.

Separately, xdpw sends the first frame the instant a share starts, before the app's side of the PipeWire connection is necessarily ready, and then waits for the window to change before sending anything else. With an idle window, the app sits waiting: Vesktop's Go Live dialog doesn't appear until you touch the shared window. In testing this happened about one share in three.

How it differs from upstream