Mercurial > dwm-meillo
comparison client.c @ 142:9b9deafa0508
committed a patch which fixes the hints of Jukka
author | arg@10ksloc.org |
---|---|
date | Tue, 01 Aug 2006 11:49:19 +0200 |
parents | 30d1302dbe3b |
children | 36cabfe408cd |
comparison
equal
deleted
inserted
replaced
141:32cd156749d1 | 142:9b9deafa0508 |
---|---|
71 return; | 71 return; |
72 | 72 |
73 if(sel->ismax) | 73 if(sel->ismax) |
74 togglemax(NULL); | 74 togglemax(NULL); |
75 | 75 |
76 if(!(c = getnext(sel->next, tsel))) | 76 if(!(c = getnext(sel->next))) |
77 c = getnext(clients, tsel); | 77 c = getnext(clients); |
78 if(c) { | 78 if(c) { |
79 higher(c); | 79 higher(c); |
80 focus(c); | 80 focus(c); |
81 } | 81 } |
82 } | 82 } |
258 | 258 |
259 settitle(c); | 259 settitle(c); |
260 arrange(NULL); | 260 arrange(NULL); |
261 | 261 |
262 /* mapping the window now prevents flicker */ | 262 /* mapping the window now prevents flicker */ |
263 if(c->tags[tsel]) { | 263 XMapRaised(dpy, c->win); |
264 XMapRaised(dpy, c->win); | 264 XMapRaised(dpy, c->title); |
265 XMapRaised(dpy, c->title); | 265 if(c->tags[tsel]) |
266 focus(c); | 266 focus(c); |
267 } | |
268 else { | |
269 XMapRaised(dpy, c->win); | |
270 XMapRaised(dpy, c->title); | |
271 | |
272 } | |
273 } | |
274 | |
275 void | |
276 pop(Client *c) | |
277 { | |
278 Client **l; | |
279 | |
280 for(l = &clients; *l && *l != c; l = &(*l)->next); | |
281 if(c->prev) | |
282 c->prev->next = c->next; | |
283 if(c->next) | |
284 c->next->prev = c->prev; | |
285 *l = c->next; | |
286 | |
287 c->prev = NULL; | |
288 if(clients) | |
289 clients->prev = c; | |
290 c->next = clients; | |
291 clients = c; | |
292 arrange(NULL); | |
293 } | 267 } |
294 | 268 |
295 void | 269 void |
296 resize(Client *c, Bool sizehints, Corner sticky) | 270 resize(Client *c, Bool sizehints, Corner sticky) |
297 { | 271 { |
455 c->prev->next = c->next; | 429 c->prev->next = c->next; |
456 if(c->next) | 430 if(c->next) |
457 c->next->prev = c->prev; | 431 c->next->prev = c->prev; |
458 *l = c->next; | 432 *l = c->next; |
459 if(sel == c) { | 433 if(sel == c) { |
460 sel = getnext(c->next, tsel); | 434 sel = getnext(c->next); |
461 if(!sel) | 435 if(!sel) |
462 sel = getprev(c->prev); | 436 sel = getprev(c->prev); |
463 if(!sel) | 437 if(!sel) |
464 sel = clients; | 438 sel = clients; |
465 } | 439 } |
479 Client *c, **l; | 453 Client *c, **l; |
480 | 454 |
481 if(!sel) | 455 if(!sel) |
482 return; | 456 return; |
483 | 457 |
484 if(sel == getnext(clients, tsel) && sel->next) { | 458 if(sel == getnext(clients) && sel->next) { |
485 if((c = getnext(sel->next, tsel))) | 459 if((c = getnext(sel->next))) |
486 sel = c; | 460 sel = c; |
487 } | 461 } |
488 | 462 |
489 /* pop */ | 463 /* pop */ |
490 for(l = &clients; *l && *l != sel; l = &(*l)->next); | 464 for(l = &clients; *l && *l != sel; l = &(*l)->next); |