summaryrefslogtreecommitdiff
path: root/app/cwm/client.c
diff options
context:
space:
mode:
authorOkan Demirmen <okan@cvs.openbsd.org>2009-06-20 00:55:43 +0000
committerOkan Demirmen <okan@cvs.openbsd.org>2009-06-20 00:55:43 +0000
commite5a5f4e8a3187fa354c2694c1ef151df017d643c (patch)
treef618b506d52466cbb2cece7bafc7e02e9c0f4ff1 /app/cwm/client.c
parent6fc03fb607ca82bdbaaaacc755bbf3e4392aa94d (diff)
compact a bit by condensing a few if-else's; from Thomas Pfaff
"go on then" oga@
Diffstat (limited to 'app/cwm/client.c')
-rw-r--r--app/cwm/client.c14
1 files changed, 3 insertions, 11 deletions
diff --git a/app/cwm/client.c b/app/cwm/client.c
index 7c6b470bd..5e694cbcd 100644
--- a/app/cwm/client.c
+++ b/app/cwm/client.c
@@ -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);
}