Skip to content

Conversation

@metux
Copy link
Contributor

@metux metux commented Sep 9, 2025

No need to have an actual (const) variable for something that can easily
be a #define. And also moving it into the only source file actually
using it.

Signed-off-by: Enrico Weigelt, metux IT consult [email protected]

No need to have an actual (const) variable for something that can easily
be a #define. And also moving it into the only source file actually
using it.

Signed-off-by: Enrico Weigelt, metux IT consult <[email protected]>
metux added a commit that referenced this pull request Sep 9, 2025
metux added a commit that referenced this pull request Sep 9, 2025
metux added a commit that referenced this pull request Sep 9, 2025
metux added a commit that referenced this pull request Sep 9, 2025
metux added a commit that referenced this pull request Sep 9, 2025
metux added a commit that referenced this pull request Sep 9, 2025
const Mask DeviceOwnerGrabButtonMask = (1L << 17);
const Mask DevicePresenceNotifyMask = (1L << 18);
const Mask DevicePropertyNotifyMask = (1L << 19);
const Mask XIAllMasks = (1L << 20) - 1;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, I actually like the old version more. It makes sense to have it defined together with other masks, otherwise it’s too easy to forget about XIAllMasks, if a new DeviceProperty*Mask is added or removed. And it’s immediately clear why it’s 20 there when we have other definitions nearby.

metux added a commit that referenced this pull request Sep 10, 2025
metux added a commit that referenced this pull request Sep 11, 2025
metux added a commit that referenced this pull request Sep 15, 2025
metux added a commit that referenced this pull request Sep 15, 2025
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.

3 participants