Rework group names: stash the group name inside the group_ctx as opposed

to having to manage an array outside in screen_ctx for group names and
shortcuts.  Simplifies (and moves bits for) reading, and constructing
data for, EWMH's _NET_DESKTOP_NAMES.
This commit is contained in:
okan
2014-09-06 16:08:58 +00:00
parent 87d604f119
commit 142f52a0aa
5 changed files with 41 additions and 64 deletions

View File

@ -204,6 +204,7 @@ TAILQ_HEAD(cycle_entry_q, client_ctx);
struct group_ctx {
TAILQ_ENTRY(group_ctx) entry;
struct client_ctx_q clients;
char *name;
int num;
};
TAILQ_HEAD(group_ctx_q, group_ctx);
@ -242,9 +243,7 @@ struct screen_ctx {
struct group_ctx groups[CALMWM_NGROUPS];
struct group_ctx_q groupq;
int group_hideall;
int group_nonames;
struct group_ctx *group_active;
char **group_names;
};
TAILQ_HEAD(screen_ctx_q, screen_ctx);