videoplayer.lzx
<library>
<include href="av/videoscreen.lzx"/>
<include href="av/videoslider.lzx"/>
<include href="utils/layouts/simplelayout.lzx"/>
<class name="videoplayer">
<attribute name="debug" value="false
"/>
<attribute name="stream" value="${vscreen.ms}"/>
<attribute name="type" type="string" value="http
"/>
<attribute name="url" type="string" value="
"/>
<attribute name="autoplay" value="false
"/>
<attribute name="starttime" value="0
" type="number"/>
<attribute name="showscreen" value="true
"/>
<attribute name="showslider" value="true
"/>
<attribute name="border" value="5
"/>
<attribute name="borderLeft" value="${this.border}"/>
<attribute name="borderRight" value="${this.border}"/>
<attribute name="borderTop" value="${this.border}"/>
<attribute name="borderBottom" value="${this.border}"/>
<attribute name="aspectRatio" value="$once{4/3}"/>
<attribute name="sliderGap" value="5
"/>
<attribute name="sliderHeight" value="${ this.showslider ? this.sliderHeightVal : 0}"/>
<attribute name="sliderHeightVal" value="16
"/>
<attribute name="screenWidth" value="${ this.width - (this.borderLeft + this.borderRight)}"/>
<attribute name="sliderTop" value="${ this.height - (this.borderBottom + this.sliderHeight)}"/>
<attribute name="showTimeDisplay" value="true
"/>
<attribute name="showVolumeControl" value="true
"/>
<attribute name="progressColor" value="0x00ff00
"/>
<method name="playVideo" args="url, type">
var ms =
this.vscreen.ms;
ms.setAttribute("type", type);
ms.setAttribute("url", url);
ms.play();
</method>
<simplelayout axis="y" spacing="${parent.sliderGap}"/>
<videoscreen name="vscreen" debug="${parent.debug}" width="${parent.width}" height="${parent.height - parent.sliderGap - parent.sliderHeight}" visible="${parent.showscreen}" type="${classroot.type}" autoplay="${classroot.autoplay}" url="${classroot.url}" volume="${parent.vslider.volume}" starttime="${parent.starttime}" borderTop="${parent.borderTop}" borderLeft="${parent.borderLeft}" borderBottom="${parent.borderBottom}" borderRight="${parent.borderRight}" aspectRatio="${parent.aspectRatio}"/>
<videoslider name="vslider" width="${parent.width}" height="${parent.sliderHeight}" visible="${parent.showslider}" ms="${classroot.vscreen.ms}" time="${classroot.vscreen.ms.time}" totaltime="${classroot.vscreen.ms.totaltime}" showTimeDisplay="${parent.showTimeDisplay}" showVolumeControl="${parent.showVolumeControl}" color="${parent.progressColor}"/>
</class>
</library>
Cross References
Includes
Classes