diff options
author | okan | 2009-06-20 00:55:41 +0000 |
---|---|---|
committer | okan | 2009-06-20 00:55:41 +0000 |
commit | c54416ae163702858ce97808753af16c8c9b5921 (patch) | |
tree | e9d3394584e6cb28ee5e25f556f7ce000bb9cdc6 /client.c | |
parent | c6af5e9b967797d315037b26aa05fec5b3e6ef44 (diff) | |
download | cwm-c54416ae163702858ce97808753af16c8c9b5921.tar.gz |
compact a bit by condensing a few if-else's; from Thomas Pfaff
"go on then" oga@
Diffstat (limited to 'client.c')
-rw-r--r-- | client.c | 14 |
1 files changed, 3 insertions, 11 deletions
@@ -15,7 +15,7 @@ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * - * $Id: client.c,v 1.54 2009/06/20 00:22:39 okan Exp $ + * $Id: client.c,v 1.55 2009/06/20 00:55:41 okan Exp $ */ #include "headers.h" @@ -113,11 +113,7 @@ client_new(Window win, struct screen_ctx *sc, int mapped) /* Notify client of its configuration. */ xev_reconfig(cc); - if (state == IconicState) - client_hide(cc); - else - client_unhide(cc); - + (state == IconicState) ? client_hide(cc) : client_unhide(cc); xu_setstate(cc, cc->state); XSync(X_Dpy, False); @@ -345,11 +341,7 @@ client_ptrwarp(struct client_ctx *cc) y = cc->geom.height / 2; } - if (cc->state == IconicState) - client_unhide(cc); - else - client_raise(cc); - + (cc->state == IconicState) ? client_unhide(cc) : client_raise(cc); xu_ptr_setpos(cc->win, x, y); } |