Avoid duplicate window resizes in XEvent loop.