From 4c0ec19811a6192ae8c3739bd9caff7d91bb725f Mon Sep 17 00:00:00 2001 From: Vito Caputo Date: Sun, 5 Mar 2017 17:06:12 -0800 Subject: vwm: utilize vwm_xserver_t, minor refactor --- src/logo.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/logo.c') diff --git a/src/logo.c b/src/logo.c index 8fe7291..d8b3659 100644 --- a/src/logo.c +++ b/src/logo.c @@ -33,7 +33,7 @@ void vwm_draw_logo(vwm_t *vwm) XPoint points[VWM_LOGO_POINTS]; const vwm_screen_t *scr = vwm_screen_find(vwm, VWM_SCREEN_REL_POINTER); - XGrabServer(vwm->display); + XGrabServer(VWM_XDISPLAY(vwm)); /* use the dimensions of the pointer-containing screen */ width = scr->width; @@ -50,11 +50,11 @@ void vwm_draw_logo(vwm_t *vwm) points[i].y = (i % 2 * (float)height) + yoff; } - XDrawLines(vwm->display, VWM_XROOT(vwm), vwm->gc, points, sizeof(points) / sizeof(XPoint), CoordModeOrigin); - XFlush(vwm->display); + XDrawLines(VWM_XDISPLAY(vwm), VWM_XROOT(vwm), VWM_XGC(vwm), points, sizeof(points) / sizeof(XPoint), CoordModeOrigin); + XFlush(VWM_XDISPLAY(vwm)); usleep(3333); - XDrawLines(vwm->display, VWM_XROOT(vwm), vwm->gc, points, sizeof(points) / sizeof(XPoint), CoordModeOrigin); - XFlush(vwm->display); + XDrawLines(VWM_XDISPLAY(vwm), VWM_XROOT(vwm), VWM_XGC(vwm), points, sizeof(points) / sizeof(XPoint), CoordModeOrigin); + XFlush(VWM_XDISPLAY(vwm)); /* the width is shrunken as well, but only by as much as it is tall */ yoff++; @@ -62,5 +62,5 @@ void vwm_draw_logo(vwm_t *vwm) xoff += 2; } - XUngrabServer(vwm->display); + XUngrabServer(VWM_XDISPLAY(vwm)); } -- cgit v1.2.3