Skip to content

Add support for ext-data-control #51

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 28, 2025
Merged

Add support for ext-data-control #51

merged 1 commit into from
Feb 28, 2025

Conversation

YaLTeR
Copy link
Owner

@YaLTeR YaLTeR commented Feb 25, 2025

Since the protocol is more or less exactly the same as wlr-data-control, I added some wrappers and macros to re-use the same existing code for both protocols.

Some things I didn't do because it seemed like too much effort:

  1. Would be nice to add new traits over the types in data_control instead of macros to reduce the curse and to avoid duplicate codegen.
  2. I didn't add copy and paste tests over ext-data-control; don't think it's worth the effort since it would be using the same server-side impl code anyway.

The only (if I didn't miss something) API breaking change is that I got rid of name in the MissingProtocol error and instead spelled it out in the message. This is not strictly required, but might as well do it, I'll bump minor for this anyway.

@bugaevc wanna take a look? I tested this on niri v25.02, verifying via WAYLAND_DEBUG that it used ext-data-control.

The diff is best viewed ignoring whitespace.

Since the protocol is more or less exactly the same as wlr-data-control, I
added some wrappers and macros to re-use the same existing code for both
protocols.
@YaLTeR YaLTeR merged commit e977111 into master Feb 28, 2025
12 checks passed
@YaLTeR YaLTeR deleted the ext-data-control branch February 28, 2025 06:37
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