Skip to content

Commit

Permalink
Fixed flickering issue with mouse movement
Browse files Browse the repository at this point in the history
  • Loading branch information
JLErvin committed Jun 23, 2019
1 parent 8d72619 commit 72eca92
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/wm.c
Original file line number Diff line number Diff line change
Expand Up @@ -489,9 +489,10 @@ handle_button_press(XEvent *e)
struct client *c;
int x, y, ocx, ocy, nx, ny, di;
unsigned int dui;
Window child, dummy;
/*Window child, dummy;*/
Window dummy;

XQueryPointer(display, root, &dummy, &child, &x, &y, &di, &di, &dui);
XQueryPointer(display, root, &dummy, &dummy, &x, &y, &di, &di, &dui);
fprintf(stderr, WINDOW_MANAGER_NAME": Handling button press event\n");
c = get_client_from_window(bev->window);
if (c == NULL)
Expand All @@ -507,6 +508,8 @@ handle_button_press(XEvent *e)
case ConfigureRequest:
case Expose:
case MapRequest:
draw_text(c, true);
break;
case MotionNotify:
fprintf(stderr, WINDOW_MANAGER_NAME": Handling motion notify event\n");
nx = ocx + (ev.xmotion.x - x);
Expand Down

0 comments on commit 72eca92

Please sign in to comment.