OWLNext 7.0
Borland's Object Windows Library for the modern age
|
Because you usually use an instance of TMDIFrame as your MDI frame window, you need to add application-wide behavior to your MDI client window class.
The frame window owns menus and tool bars but passes the commands they generate to the client window and to the application. A common message-response function would respond to the File|Open menu command to open another MDI child window.
TMDIClient has several member functions for manipulating MDI child windows. Commands from an MDI application's child-window menu control the child windows. TMDIClient automatically responds to those commands and performs the appropriate action:
Action | Menu command ID | TMDIClient member function |
Cascade | CM_CASCADECHILDREN | TMDIClient::CmCascadeChildren() |
Tile | CM_TILECHILDREN | TMDIClient::CmTileChildren() |
Tile Horizontally | CM_TILECHILDRENHORIZ | TMDIClient::CmTileChildrenHoriz() |
Arrange Icons | CM_ARRANGEICONS | TMDIClient::CmArrangeIcons() |
Close All | CM_CLOSECHILDREN | TMDIClient::CmCloseChildren() |
MDI child windows should not respond to any child-window menu commands. The MDI client window takes care of them.