diff options
author | okan | 2017-04-26 21:10:54 +0000 |
---|---|---|
committer | okan | 2017-04-26 21:10:54 +0000 |
commit | 330b5911cc616eb9653cf2add7574885d4b91304 (patch) | |
tree | 9681cfe439a028482c6ae169fa06fac7090fd5b3 /client.c | |
parent | 978cbcbbb085230a4d270c6288c8e7a1554e3a9b (diff) | |
download | cwm-330b5911cc616eb9653cf2add7574885d4b91304.tar.gz |
Switch bwidth type; unfortunately X11 is inconsistent.
Diffstat (limited to '')
-rw-r--r-- | client.c | 12 |
1 files changed, 6 insertions, 6 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. * - * $OpenBSD: client.c,v 1.237 2017/04/24 13:31:19 okan Exp $ + * $OpenBSD: client.c,v 1.238 2017/04/26 21:10:54 okan Exp $ */ #include <sys/types.h> @@ -545,7 +545,7 @@ client_draw_border(struct client_ctx *cc) if (cc->flags & CLIENT_URGENCY) pixel = sc->xftcolor[CWM_COLOR_BORDER_URGENCY].pixel; - XSetWindowBorderWidth(X_Dpy, cc->win, cc->bwidth); + XSetWindowBorderWidth(X_Dpy, cc->win, (unsigned int)cc->bwidth); XSetWindowBorder(X_Dpy, cc->win, pixel); } @@ -743,13 +743,13 @@ client_placecalc(struct client_ctx *cc) wmax = DisplayWidth(X_Dpy, sc->which); hmax = DisplayHeight(X_Dpy, sc->which); - if (cc->geom.x + ((int)cc->bwidth * 2) >= wmax) + if (cc->geom.x + (cc->bwidth * 2) >= wmax) cc->geom.x = wmax - (cc->bwidth * 2); - if (cc->geom.x + cc->geom.w - ((int)cc->bwidth * 2) < 0) + if (cc->geom.x + cc->geom.w - (cc->bwidth * 2) < 0) cc->geom.x = -cc->geom.w; - if (cc->geom.y + ((int)cc->bwidth * 2) >= hmax) + if (cc->geom.y + (cc->bwidth * 2) >= hmax) cc->geom.y = hmax - (cc->bwidth * 2); - if (cc->geom.y + cc->geom.h - ((int)cc->bwidth * 2) < 0) + if (cc->geom.y + cc->geom.h - (cc->bwidth * 2) < 0) cc->geom.y = -cc->geom.h; } else { struct geom area; |