Use an event hook to trap the WINDOWMOVE event and when the window moves, use SetGadgetShape() to move the hidden window to the other window's location. But you will have to go without CLIENTCOORDS in your window definition because GadgetX() and GadgetY() on the window object will return the top left of the window title bar itself, not the canvas, so setting the new window to those coords will make your second canvas align to the top left of the other window's title bar. At least, this is what I found.
Beyond that, you will also find that you can process normal events while a window is in the process of being moved. If you have TIMERTICK events they will trickle through to the event hook even while you're still holding down the mouse on the title bar. From the TIMERTICK you can update or move your other window every frame.
|