Ross Levis wrote: > I don't see anything in that blog to suggest it is not useful purposes other > than drag operations. One comment says... > > "We use LockWindowUpdate for avoiding extensive redraw operations when > reorganizing child windows/controls in an window. Without it you can see the > windows changing position, with it you don't and you just go from one layout > to the new one without flickering."
The problem is that there can be only one locked window. If more than one window needs to be locked, you're out of luck. You can't know whether other windows in the OS will need to be locked, but you can know whether any other windows will be performing dragging operations. The answer to that is always no because if the user is dragging your window, then the user cannot possibly be dragging anything else because there's only one mouse. > It sounds like the best method is to use DeferWindowPos but that looks much > more difficult to use. Add a call to BeginDeferWindowPos at the start, and a call to EndDeferWindowPos at the end. Then change all your window-moving methods to call DeferWindowPos. That call is only as complicated as you make it; you get to tell it which of the position parameters are valid and which should be ignored, just like calling regular SetWindowPos. -- Rob _______________________________________________ Delphi mailing list -> Delphi@elists.org http://lists.elists.org/cgi-bin/mailman/listinfo/delphi