Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Macintosh Toolbox Essentials /
Chapter 4 - Window Manager / Using the Window Manager


Moving a Window

When the user drags a window by the title bar (except for the close and zoom box regions), the window should move, following the cursor as it moves on the
desktop. Your application can easily let the user move the window by calling the DragWindow procedure.

The DragWindow procedure draws an outline of the window on the screen and
moves the outline as the user moves the mouse. When the user releases the mouse button, DragWindow calls the MoveWindow function, which redraws the window in
its new location.

For an example of moving a window, see the inDrag case in Listing 4-9 on page 4-39.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
11 JUL 1996