Microsoft DirectX 8.0 |
The MSWebDVD Microsoft® ActiveX® control notifies your application when various types of internal events occur or when certain information is encountered on the disc.
Most of the events relate to user operation (UOP) controls. DVD authors can encode the disc so that any DVD command (such as PlayForwards, Pause, ShowMenu, and so on) can be disabled at any time. For example, most discs will not allow users to fast forward or show a menu while the FBI warning is playing. After the warning is over, the disc permits these operations. By handling the UOP events, your application can update its user interface to show the user which commands are currently permitted by the disc. The most common way to do this is by disabling a button. For example, if your application received a PlayForwards event with bEnabled set to false, you could disable the Play button. When it received that event with bEnabled set to true, you could enable the button again.
There are three events that do not relate to UOP controls. The DVDNotify event notifies your application of many different types of DVD-related events, which are identified in the EventCode parameter. Some events have additional information in he Param1 and Param2 parameters. The ReadyStateChange event notifies your application of changes in the MSWebDVD ReadyState property, which is a property common to all ActiveX controls. The UpdateOverlay event is sent to applications only if they are hosting MSWebDVD in windowless mode. Applications need to respond to this event only if they are displaying floating buttons over the video rectangle in full screen mode.
For code samples showing how to handle events, see Handling DVD Event Notifications.
MSWebDVD Methods and Properties
Events
Event Description ChangeCurrentAngle Sent when the disc enables or disables changing the angle. ChangeCurrentAudioStream Sent when the disc enables or disables changing the audio stream. ChangeCurrentSubpictureStream Sent when the ChangeCurrentSubpictureStream command has been enabled or disabled. DVDNotify Notifies an application of many different DVD events and disc instructions. PauseOn Sent when the Pause command has been enabled or disabled. PlayAtTime Sent when the PlayAtTime command has been enabled or disabled. PlayAtTimeInTitle Sent when the PlayAtTimeInTitle command has been enabled or disabled. PlayBackwards Sent when the PlayBackwards command has been enabled or disabled. PlayChapter Sent when the PlayChapter command has been enabled or disabled. PlayChapterInTitle Sent when the PlayChapterInTitle command has been enabled or disabled. PlayForwards Sent when the PlayForwards command has been enabled or disabled. PlayNextChapter Sent when the PlayNextChapter command has been enabled or disabled. PlayPrevChapter Sent when the PlayPrevChapter command has been enabled or disabled. PlayTitle Sent when the ReturnFromSubmenu command has been enabled or disabled. ReadyStateChange Sent when the ReadyState property of the MSWebDVD control has changed. ReplayChapter Sent when the ReplayChapter command has been enabled or disabled. Resume Sent when the Resume command has been enabled or disabled. ReturnFromSubmenu Sent when the ReturnFromSubmenu command has been enabled or disabled. SelectOrActivatButton Sent when the disc enables or disables the selection or activation of menu buttons. ShowMenu Sent when the disc enables or disables the showing of a menu. StillOff Sent when the StillOff command has been enabled or disabled. Stop Sent when the Stop command has been enabled or disabled. UpdateOverlay Sent when the overlay surface has been moved or resized or its color key has changed.
Sent when the disc enables or disables changing the angle.
Syntax
ChangeCurrentAngle(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the disc enables or disables changing the audio stream.
Syntax
ChangeCurrentAudioStream(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the disc enables or disables changing the subpicture stream.
Syntax
ChangeCurrentSubpictureStream(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Notifies an application of many different DVD events and disc instructions.
Syntax
DVDNotify(EventCode, Param1, Param2)
Parameters
EventCode Specifies the DVD event. Param1 Can contain additional information related to the event. param2 Can contain additional information related to the event.
See Also
DVD Event Notification Codes gives a full explanation of all DVD event notification codes and their parameters.
Sent when the PauseOn command has been enabled or disabled.
Syntax
PauseOn(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the PlayAtTime command has been enabled or disabled.
Syntax
PlayAtTime(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the PlayAtTimeInTitle command has been enabled or disabled.
Syntax
PlayAtTimeInTitle(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the PlayBackwards command has been enabled or disabled.
Syntax
PlayBackwards(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the PlayChapter command has been enabled or disabled.
Syntax
PlayChapter(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the PlayChapterInTitle command has been enabled or disabled.
Syntax
PlayChapterInTitle(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the PlayForwards command has been enabled or disabled.
Syntax
PlayForwards(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the PlayNextChapter command has been enabled or disabled.
Syntax
PlayNextChapter(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the PlayPrevChapter command has been enabled or disabled.
Syntax
PlayPrevChapter(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the PlayTitle command has been enabled or disabled.
Syntax
PlayTitle(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the ReadyState property of the MSWebDVD control has changed.
Syntax
ReadyStateChange(ReadyState)
Parameters
ReadyState Indicates the new value of the ReadyState property. Can be one of the following values: READYSTATE_UNINITIALIZED = 0; READYSTATE_LOADING = 1; READYSTATE_LOADED = 2; READYSTATE_INTERACTIVE = 3; READYSTATE_COMPLETE = 4.
Sent when the ReplayChapter command has been enabled or disabled.
Syntax
ReplayChapter(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the Resume command has been enabled or disabled.
Syntax
Resume(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the ReturnFromSubmenu command has been enabled or disabled.
Syntax
ReturnFromSubmenu(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the disc enables or disables the selection or activation of menu buttons.
Syntax
SelectOrActivatButton(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the disc enables or disables the showing of a menu.
Syntax
ShowMenu(DVDMenuIDConstants, bEnabled)
Parameters
DVDMenuIDConstants Number value specifying which menu has been enabled or disabled. Can be one of the following values:
2 Title 3 Root 4 Subpicture 5 Audio 6 Angle 7 Chapter bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the StillOff command has been enabled or disabled.
Syntax
StillOff(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the Stop command has been enabled or disabled.
Syntax
Stop(bEnabled)
Parameters
bEnabled Boolean value that indicates whether the operation is enabled or disabled.
Sent when the overlay surface has been moved or resized or its color key has changed.
Syntax
UpdateOverlay()
Remarks
Applications should never be concerned about the overlay surface being resized or moved. This is all handled internally. But this event is also sent when the color key changes. That means that if an application is hosting MSWebDVD as a windowless control and displaying floating buttons on top of the video surface in full-screen mode, it should respond to this event by getting the new value of the ColorKey property so that it can draw the buttons properly.