enigma-dev/enigma-dev — pull request #872 by sorlok (2014-11-26 04:19:22+00:00)
Title: Fixes a bug with reparenting window managers on xlib.

So the current windowing code is actually a bit broken on xlib; if you transition between windows of the same size or drag windows around, you'll get wild inaccuracies in windowX/windowY. I read up on this a bit, and it turns out that reparenting window managers (that is, almost any modern Linux desktop) will do a whole lot of magic to manage windowX/Y for you, and they get all confused if you try to track it.

Thus, this fix removes windowX/Y entirely, and accomplishes the same thing by recalculating them only when needed. Tested on An Untitled Story, and it fixes the bugs I was seeing there relating to window positioning.