Controlling the Stage Window

When you open a movie file, the MCI Movie Driver loads the movie file but does not display the stage window. The MCI Movie Driver creates a default stage window when it opens the movie; the window remains hidden until you issue an MCI_PLAY or MCI_WINDOW command message. By default, the driver creates a pop-up window with a caption, a thick frame, a system menu, and minimize and maximize boxes. You can change the default options when you open the movie.

An application can create its own window and then supply the window handle to the MCI Movie Driver. To do this, use the MCI_WINDOW command message with the MCI_ANIM_WINDOW_HWND flag. The MCI_WINDOW command message can also display the current stage window in various states (for example, restored, minimized, maximized, or hidden) and set the window-caption text.

You can get a handle to the default stage window using the MCI_STATUS command. See “Opening a Movie File,” earlier in this chapter, for a code fragment that obtains the stage-window handle. With this handle, you can use any window-manager functions to manipulate the stage window.