Skip to content
This repository has been archived by the owner on Nov 1, 2021. It is now read-only.

output: replace wlr_output.damage with a damage event #2065

Merged
merged 1 commit into from
Mar 12, 2020

Conversation

emersion
Copy link
Member

@emersion emersion commented Mar 12, 2020

This patch disambiguates the needs_frame event by uncoupling it from
damage. A new separate damage event is emitted when the backend damages
the output (this happens e.g. VT is changed or software cursors are
used). The event specifies the damaged region.

The wlr_output.damage field is removed. wlr_output is no longer
responsible for tracking its own damage, this is wlr_output_damage's
job.

This is a breaking change, but wlr_output_damage users shouldn't need an
update.

Bugs fixed:

  • Screen flashes on VT switch
  • Cursor damage issues on the X11 and headless backends

Closes: swaywm/sway#5086
References: #2059

cc @soreau @any1 @thejh @kchibisov


Breaking change: wlr_output.damage is removed, listen to wlr_output.events.damage instead.

This patch disambiguates the needs_frame event by uncoupling it from
damage. A new separate damage event is emitted when the backend damages
the output (this happens e.g. VT is changed or software cursors are
used). The event specifies the damaged region.

The wlr_output.damage field is removed. wlr_output is no longer
responsible for tracking its own damage, this is wlr_output_damage's
job.

This is a breaking change, but wlr_output_damage users shouldn't need an
update.

Bugs fixed:

- Screen flashes on VT switch
- Cursor damage issues on the X11 and headless backends

Closes: swaywm/sway#5086
@emersion emersion added the breaking Breaking change in public API label Mar 12, 2020
@soreau
Copy link
Contributor

soreau commented Mar 12, 2020

@emersion I tested this and it does indeed fix cursor problems on x11 backend. I also briefly tested drm and wayland backends, and didn't notice any problems. Thanks for the quick patch and cc.

@any1
Copy link
Contributor

any1 commented Mar 12, 2020

This fixes the issue on the headless backend.

@kchibisov
Copy link
Contributor

Seems to fix swaywm/sway#5086.

@ddevault
Copy link
Contributor

Thanks!

@ddevault ddevault merged commit e0bbafc into swaywm:master Mar 12, 2020
@emersion emersion added this to the 0.11.0 milestone Jul 15, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
breaking Breaking change in public API
Development

Successfully merging this pull request may close these issues.

Output flashes after tty switch
6 participants