diff options
author | QC <qball@gmpclient.org> | 2015-09-19 20:59:50 +0200 |
---|---|---|
committer | QC <qball@gmpclient.org> | 2015-09-19 21:00:06 +0200 |
commit | 31fe5759b8bede7a31535c61977b9efe2438d789 (patch) | |
tree | f5f8222d560ed666f85e9ee5f98fa958b6c2f39d /source/x11-helper.c | |
parent | b18d68eff26429ed08d560b187c46770eb7db0b2 (diff) |
More line fixing.
Diffstat (limited to 'source/x11-helper.c')
-rw-r--r-- | source/x11-helper.c | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/source/x11-helper.c b/source/x11-helper.c index 7050eff7..a311528b 100644 --- a/source/x11-helper.c +++ b/source/x11-helper.c @@ -66,8 +66,8 @@ int window_get_prop ( Display *display, Window w, Atom prop, Atom *type, int *it unsigned char *ret = NULL; memset ( buffer, 0, bytes ); - if ( XGetWindowProperty ( display, w, prop, 0, bytes / 4, False, AnyPropertyType, type, &format, &nitems, &nbytes, - &ret ) == Success && ret && *type != None && format ) { + if ( XGetWindowProperty ( display, w, prop, 0, bytes / 4, False, AnyPropertyType, type, &format, &nitems, &nbytes, &ret ) == Success && + ret && *type != None && format ) { if ( format == 8 ) { memmove ( buffer, ret, MIN ( bytes, nitems ) ); } @@ -233,8 +233,8 @@ void monitor_active ( Display *display, workarea *mon ) } fprintf ( stderr, "Failed to find selected monitor.\n" ); } - if ( window_get_prop ( display, root, netatoms[_NET_ACTIVE_WINDOW], &type, &count, &id, sizeof ( Window ) ) - && type == XA_WINDOW && count > 0 ) { + if ( window_get_prop ( display, root, netatoms[_NET_ACTIVE_WINDOW], &type, &count, &id, sizeof ( Window ) ) + && type == XA_WINDOW && count > 0 ) { XWindowAttributes attr; if ( XGetWindowAttributes ( display, id, &attr ) ) { Window junkwin; @@ -444,9 +444,8 @@ static int ( *xerror )( Display *, XErrorEvent * ); */ static int display_oops ( Display *d, XErrorEvent *ee ) { - if ( ee->error_code == BadWindow - || ( ee->request_code == X_GrabButton && ee->error_code == BadAccess ) - || ( ee->request_code == X_GrabKey && ee->error_code == BadAccess )) { + if ( ee->error_code == BadWindow || ( ee->request_code == X_GrabButton && ee->error_code == BadAccess ) + || ( ee->request_code == X_GrabKey && ee->error_code == BadAccess ) ) { return 0; } @@ -475,7 +474,7 @@ void create_visual_and_colormap ( Display *display ) // Try to create TrueColor map if ( XMatchVisualInfo ( display, screen, 32, TrueColor, &vinfo ) ) { // Visual found, lets try to create map. - map = XCreateColormap ( display, DefaultRootWindow ( display ), vinfo.visual, AllocNone ); + map = XCreateColormap ( display, DefaultRootWindow ( display ), vinfo.visual, AllocNone ); truecolor = TRUE; } // Failed to create map. |