wmii

git clone git://oldgit.suckless.org/wmii/
Log | Files | Refs | README | LICENSE

commit 140535aad0d9d39a43208c6fb6473f7d7cbb7a55
parent 53b9c7b33f71351316588d6207c3baf54eac0be8
Author: Anselm R. Garbe <garbeam@wmii.de>
Date:   Mon, 10 Apr 2006 17:51:05 +0200

removed tag.c


Diffstat:
cmd/wm/tag.c | 63---------------------------------------------------------------
1 file changed, 0 insertions(+), 63 deletions(-)

diff --git a/cmd/wm/tag.c b/cmd/wm/tag.c @@ -1,63 +0,0 @@ -/* - * (C)opyright MMIV-MMVI Anselm R. Garbe <garbeam at gmail dot com> - * See LICENSE file for license details. - */ - -#include <stdlib.h> -#include <string.h> - -#include "wm.h" - -void -update_tags(Client *c) -{ - unsigned int i; - - if(c) { - char buf[256]; - char *toks[16]; - unsigned int j, n; - Bool match; - - fprintf(stderr, "tags: %s\n", c->tags); - cext_strlcpy(buf, c->tags, sizeof(buf)); - n = cext_tokenize(toks, 16, buf, '+'); - - for(i = 0; i < n; i++) { - View *v = get_view(toks[i]); - if(!clientofview(v, c)) - attach_toview(v, c); - } - - for(i = 0; i < c->view.size; i++) { - View *v = c->view.data[i]; - match = False; - for(j = 0; j < n; j++) { - if(!strncmp(v->name, toks[j], sizeof(v->name))) - match = True; - } - if(!match) - detach_fromview(v, c); - } - } - - for(i = 0; i < view.size; i++) - if(!hasclient(view.data[i])) - destroy_view(view.data[i]); - - if(view.size) - focus_view(view.data[sel]); - else - update_bar_tags(); -} - -void -retag() -{ - unsigned int i; - for(i = 0; i < client.size; i++) { - match_tags(client.data[i], False); - update_tags(client.data[i]); - } -} -