mirror of
https://github.com/LGUG2Z/komorebi.git
synced 2026-11-13 12:23:38 +01:00
Resizing the tiles next to the edge of a window that is dragged lays out every window that is not the one dragged again at every frame. A window that has to lay itself out at a new size has nothing to show for a frame, a terminal that renders through a swap chain is not there at all and the wallpaper shows through where it was, and one that is slow to take a move, which File Explorer is, is seen at every size that it is on the way through. A recording of a drag shows whole terminals gone for a frame, and Explorer windows drawn twice, each of them at two sizes. With ghost movement, the first time a step has to resize a window a picture of it is taken before it is touched and put over it, the window is cloaked and its border is left to the picture. Every step moves the picture, and the border with it, to where the window is to be, with one call to DWM, and sends the window nowhere: the window is where it was, hidden. When the end of the drag has laid the workspace out, each of the windows that were covered is put, on a thread of its own, where the last step put its picture, made to paint itself, given the size change that a swap chain needs to be built again, and shown, and its picture fades out over it, as for a move that is animated. A new drag, before that, puts them where they were to go and shows them at once. The look at the windows after a drag leaves covered ones to this, and a window that is hidden by its workspace is not shown by it. Every step traces where the picture is to go and what part of it is shown there, and a picture that could not be moved says so at debug level.