fix hidden floatbar consumes a lot of cpu

This commit is contained in:
Markus Mattes
2018-09-18 21:46:02 +02:00
parent 21e4804a7f
commit 36fc5dde21

View File

@@ -127,7 +127,7 @@ void xf_floatbar_hide_and_show(xfContext* xfc)
floatbar->y = floatbar->y - 1;
XMoveWindow(xfc->display, floatbar->handle, floatbar->x, floatbar->y);
}
else if (floatbar->y < 0)
else if (floatbar->y < 0 && (floatbar->last_motion_y_root < 10))
{
floatbar->y = floatbar->y + 1;
XMoveWindow(xfc->display, floatbar->handle, floatbar->x, floatbar->y);