Player"

From Documentation
(Blanked the page)
 
Line 1: Line 1:
= Videoplayer =
 
  
*Java API: <javadoc>org.zkoss.zkmax.zul.Videoplayer</javadoc>
 
*JavaScript API: <javadoc directory="jsdoc">zkmax.med.Videoplayer</javadoc>
 
 
= Employment/Purpose =
 
An <tt>videoplayer</tt> component is used to play the video at the browser. Like <tt>audio</tt>, you could use the <tt>src</tt> property to specify an URL of an video resource, or the <tt>setContent</tt> method to specify a dynamically generated video. Developers might be able to control the play of an video by the <tt>play</tt>, <tt>stop</tt> and <tt>pause</tt> methods.
 
 
= Example =
 
[[Image:Player-Sample.png]]
 
 
<source lang="xml" >
 
<videoplayer src="zk.mp4" controls="true" autoplay="true" loop="true" />
 
</source>
 
 
= Supports HTML5 =
 
The videoplayer component support HTML 5, like <video>, it includes the properties like <tt>autoplay</tt>, <tt>controls</tt>, <tt>loop</tt>, <tt>muted</tt> and <tt>preload</tt>.
 
 
= Multiple Sources =
 
Most browsers do not support all the video formats,so we could specify multiple source files in different formats for different browsers. For examples:
 
<source lang="xml" >
 
<videoplayer src="zk.mp4, zk.webm, zk.ogg" />
 
</source>
 
 
= enableFullScreen =
 
The videoplayer component provides a client-side method <tt>enableFullScreen()</tt> to use full screen mode.
 
<source lang="xml" >
 
<videoplayer id="player" src="zk.mp4" />
 
<button xmlns:w="client" w:onClick="zk.$('$player').enableFullScreen()" />
 
</source>
 
 
= Properties =
 
== turnOffLight ==
 
The videoplayer component provides theater mode, If turnOffLight="true", the whole page will cover by translucent black except <videoplayer>.
 
 
[[Image:Player-turnOffLight.png]]
 
<source lang="xml" >
 
<videoplayer src="zk.mp4" turnOffLight="true" />
 
</source>
 
 
== currentTime ==
 
 
== paused ==
 
 
== volume ==
 
 
= Supported Events =
 
 
{| border="1" | width="100%"
 
! <center>Name</center>
 
! <center>Event Type</center>
 
|-
 
| None
 
| None
 
|}
 
*Inherited Supported Events: [[ZK_Component_Reference/Base_Components/XulElement#Supported_Events | XulElement]]
 
 
=Supported Children=
 
 
*NONE
 
 
= Use Cases =
 
 
{| border='1px' | width="100%"
 
! Version !! Description !! Example Location
 
|-
 
| &nbsp;
 
| &nbsp;
 
| &nbsp;
 
|}
 

Latest revision as of 10:41, 13 April 2018