VisClass: 5.5 Working with Visible Object Trees: Visible Object Window Operations

Up: GEOS SDK TechDocs | Up | Prev: 5.4 Sending Messages Through the Tree | Next: 6 Visible Layers and 32-Bit Graphics
MSG_VIS_OPEN_WIN, MSG_VIS_CLOSE_WIN, MSG_VIS_WIN_ABOUT_TO_BE_CLOSED, MSG_VIS_MOVE_RESIZE_WIN

Typically, windows will be managed entirely by generic UI objects and the Specific UI library currently in use. You can, however, manage your own VisClass -based window objects by using messages normally used only by Specific UI objects. This is a difficult and complex task, however, and it is not recommended. The four messages used for this purpose are detailed below.

MSG_VIS_OPEN_WIN

void	MSG_VIS_OPEN_WIN(
        WindowHandle parentWindow);

This message is sent to a window or portal object to open its window. The graphics window will be opened and drawn on the screen, and a visual update will propagate down the displayed visible tree.

Source: Visual update mechanism.

Destination: A window group (VTF_IS_WINDOW) or portal (VTF_IS_PORTAL) object.

Parameters: parentWindow The window handle of the open window in which the new window will be created.

Return: Nothing.

Interception: The window group or portal must intercept in order to open the new graphics window and set initial parameters ( VCI_window ).

MSG_VIS_CLOSE_WIN

void	MSG_VIS_CLOSE_WIN();

This message is sent to a window or portal object that has its graphics window currently on the screen. The window and its visible branch will be closed (taken off the screen).

Source: Visual update mechanism.

Destination: A window group (VTF_IS_WINDOW) or portal (VTF_IS_PORTAL) object.

Interception: The window group or portal may intercept if more needs to be done than simply closing the graphics window.

MSG_VIS_WIN_ABOUT_TO_BE_CLOSED

void	MSG_VIS_WIN_ABOUT_TO_BE_CLOSED();

This message notifies the recipient that the window it's displayed in is about to be closed. The default handler for this will remove the visible branch of the window off the screen so no redraws will occur before the window closes.

Source: Visual update mechanism.

Destination: The window group (VTF_IS_WINDOW) or portal (VTF_IS_PORTAL) object that is being closed; the message will then propagate down the visible tree.

Interception: May be intercepted by either the window group or the VisContent object if the default behavior is not appropriate for the object.

MSG_VIS_MOVE_RESIZE_WIN

void	MSG_VIS_MOVE_RESIZE_WIN();

This message causes the window object to move and/or resize itself based on the bounds of its content object. This message is used only by window or portal objects and is rarely, if ever, used by objects in your applications.

Source: Part of the visual update mechanism--typically called by the window object on itself in its MSG_VIS_UPDATE_WINDOWS_AND_IMAGE handler.

Destination: The window group (VTF_IS_WINDOW) or portal (VTF_IS_PORTAL) object to be resized or moved.

Interception: The window object may intercept if it does not want to resize to the bounds of its content object.


Up: GEOS SDK TechDocs | Up | Prev: 5.4 Sending Messages Through the Tree | Next: 6 Visible Layers and 32-Bit Graphics