diff options
| author | Patrick Haller <patrick_haller@ofs.edu.sg> | 2011-02-28 10:15:35 +0800 |
|---|---|---|
| committer | Patrick Haller <patrick_haller@ofs.edu.sg> | 2011-02-28 10:15:35 +0800 |
| commit | d961a8a4a60f70837a11a9794ec6467947cb2aa6 (patch) | |
| tree | 3bae77f60bbecbba1c32aab1a5d37d14bf551f84 /x-move-resize.c | |
| parent | a362603e1c476035bb4f57cc1836402718af90f9 (diff) | |
whitespace cleanup
Diffstat (limited to 'x-move-resize.c')
| -rw-r--r-- | x-move-resize.c | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/x-move-resize.c b/x-move-resize.c index b8911e3..53b3954 100644 --- a/x-move-resize.c +++ b/x-move-resize.c @@ -51,38 +51,38 @@ int die(Display *dpy, int return_value) { int main() { - Display * dpy; - Window root; - XWindowAttributes attr; - XButtonEvent start; - XEvent ev; + Display * dpy; + Window root; + XWindowAttributes attr; + XButtonEvent start; + XEvent ev; Cursor cursor; int cursor_shape = XC_X_cursor; start.button = 0; start.x_root = 0; start.y_root = 0; - if(!(dpy = XOpenDisplay(0x0))) return 1; + if(!(dpy = XOpenDisplay(0x0))) return 1; - root = DefaultRootWindow(dpy); + root = DefaultRootWindow(dpy); - XGrabButton(dpy, 1, 0, root, True, ButtonPressMask, GrabModeAsync, - GrabModeAsync, None, None); - XGrabButton(dpy, 3, 0, root, True, ButtonPressMask, GrabModeAsync, - GrabModeAsync, None, None); + XGrabButton(dpy, 1, 0, root, True, ButtonPressMask, GrabModeAsync, + GrabModeAsync, None, None); + XGrabButton(dpy, 3, 0, root, True, ButtonPressMask, GrabModeAsync, + GrabModeAsync, None, None); cursor = XCreateFontCursor(dpy, cursor_shape); XDefineCursor(dpy, root, cursor); - XSync (dpy, root); /* give xterm a chance */ - if (XGrabPointer (dpy, root, False, (ButtonPressMask | PointerMotionMask | ButtonReleaseMask), + XSync (dpy, root); /* give xterm a chance */ + if (XGrabPointer (dpy, root, False, (ButtonPressMask | PointerMotionMask | ButtonReleaseMask), GrabModeAsync, GrabModeAsync, None, cursor, CurrentTime) != GrabSuccess) return die(dpy, 1); - for(;;) - { + for(;;) + { if (! interruptibleXNextEvent(dpy, &ev)) continue; switch(ev.type) { - case ButtonPress: + case ButtonPress: if (ev.xbutton.subwindow == None) break; if( XGrabPointer(dpy, ev.xbutton.subwindow, False, @@ -108,5 +108,5 @@ int main() return die(dpy, 0); break; } - } + } } |
