mirror of
https://github.com/leahneukirchen/cwm.git
synced 2023-08-10 21:13:12 +03:00
add a "movetogroup" function, which hides the current window from
display and moves it to another group. useful with the recently added "grouponly" function, giving the ability to use groups as simple virtual desktops (similar to e.g. xmonad, dwm and scrotwm). this doesn't have default keyboard bindings; cwmrc(5) now shows how you could use these functions (use M-1...9 for grouponly1...9 and MS-1...9 for movetogroup1...9 to emulate the default dwm bindings). ok oga@
This commit is contained in:
11
group.c
11
group.c
@ -143,7 +143,16 @@ group_init(void)
|
||||
TAILQ_INSERT_TAIL(&Groupq, &Groups[i], entry);
|
||||
}
|
||||
|
||||
Group_active = &Groups[0];
|
||||
}
|
||||
|
||||
void
|
||||
group_movetogroup(struct client_ctx *cc, int idx)
|
||||
{
|
||||
if (idx < 0 || idx >= CALMWM_NGROUPS)
|
||||
err(1, "group_movetogroup: index out of range (%d)", idx);
|
||||
|
||||
client_hide(cc);
|
||||
_group_add(&Groups[idx], cc);
|
||||
}
|
||||
|
||||
/*
|
||||
|
Reference in New Issue
Block a user