mirror of
https://github.com/swaywm/sway.git
synced 2026-02-22 01:40:39 -05:00
Remove enum movement_direction
There's no point having both movement_direction and wlr_direction. This replaces the former with the latter. As movement_direction also contained MOVE_PARENT and MOVE_CHILD items, these are now checked specifically in the focus command and handled in separate functions, just like the other focus variants.
This commit is contained in:
parent
b90af33570
commit
7be309710d
7 changed files with 86 additions and 114 deletions
|
|
@ -175,24 +175,3 @@ failed:
|
|||
free(current);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
bool sway_dir_to_wlr(enum movement_direction dir, enum wlr_direction *out) {
|
||||
switch (dir) {
|
||||
case MOVE_UP:
|
||||
*out = WLR_DIRECTION_UP;
|
||||
break;
|
||||
case MOVE_DOWN:
|
||||
*out = WLR_DIRECTION_DOWN;
|
||||
break;
|
||||
case MOVE_LEFT:
|
||||
*out = WLR_DIRECTION_LEFT;
|
||||
break;
|
||||
case MOVE_RIGHT:
|
||||
*out = WLR_DIRECTION_RIGHT;
|
||||
break;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue