Skip to content
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

bindsym/code: add group support #4351

Merged
merged 1 commit into from
Aug 1, 2019
Merged

Conversation

RedSoxFan
Copy link
Member

@RedSoxFan RedSoxFan commented Jul 19, 2019

This is built on #4342 so that'll have to be merged first. #4342 has been merged

Closes #3662

This adds support for specifying a binding for a specific group. Any
binding without a group listed will be available in all groups. The
priority for matching bindings is as follows: input device, group, and
locked state.

For full compatibility with i3, this also adds Mode_switch as an alias
for Group2. Since i3 only supports this for backwards compatibility
with older versions of i3, it is implemented here, but not documented.

@RedSoxFan RedSoxFan marked this pull request as ready for review July 23, 2019 18:35
@RedSoxFan
Copy link
Member Author

Rebased and ready for review

}
char *end;
int group = strtol(split->items[i] + strlen("Group"), &end, 10);
if (group < 1 || group > 4) {
Copy link
Member

@emersion emersion Jul 26, 2019

Choose a reason for hiding this comment

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

Could also check end[0] != '\0' for cases like Group1asdf

Copy link
Member Author

Choose a reason for hiding this comment

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

Added

This adds support for specifying a binding for a specific group. Any
binding without a group listed will be available in all groups. The
priority for matching bindings is as follows: input device, group, and
locked state.

For full compatibility with i3, this also adds Mode_switch as an alias
for Group2. Since i3 only supports this for backwards compatibility
with older versions of i3, it is implemented here, but not documented.
Copy link
Member

@emersion emersion left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for the patch!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Add support for Group in bindsym/bindcode
2 participants