Important: The information in this document is obsolete and should not be used for new development.
MoveWindow
Use theMoveWindow
procedure to move a window on the desktop.
PROCEDURE MoveWindow (theWindow: WindowPtr; hGlobal, vGlobal: Integer; front: Boolean);
- theWindow
- A pointer to the window record of the window being moved.
- hGlobal
- The new location, in global coordinates, of the left edge of the window's port rectangle.
- vGlobal
- The new location, in global coordinates, of the top edge of the window's port rectangle.
- front
- A Boolean value specifying whether the window is to become the frontmost, active window. If the value of the front parameter is
FALSE
,MoveWindow
does not change its plane or status. If the value of the front parameter isTRUE
and the window isn't active,MoveWindow
makes it active by calling theSelectWindow
procedure.DESCRIPTION
TheMoveWindow
procedure moves the specified window to the location specified by thehGlobal
andvGlobal
parameters, without changing the window's size. The upper-left corner of the window's port rectangle is placed at the point (vGlobal
,hGlobal
). The local coordinates of the upper-left corner are unaffected.Your application doesn't normally call
MoveWindow
. When the user drags a window by dragging its title bar, you can callDragWindow
, which in turn callsMoveWindow
when the user releases the mouse button.