Video - AppDaddy-Software-Solutions-Inc/framework-markup-language GitHub Wiki

<VIDEO/> : ViewableWidget

The VIDEO widget displays a video from a url with associated controls.

Restrictions:

-The VIDEO once loaded will remain in memory until the application reloads.

Attributes

Name Type Default Description Req
url string null The url the video will be retrieved from.
controls bool true If video control buttons are displayed
loop bool false If the video loops once playing.
volume double 1.0 Sound volume. Can be 0.0 -> 1.0
speed double 1.0 Playback speed
autoplay bool false Start playing video immediately after load

Properties

Name Values Default Description
playing bool false If video is playing

Events

Name Description
oninitialized A list of ; seperated event(s) to execute when the video player is initialized

Methods

Name Description
play() Starts the video player from the beginning
stop() Stops the video player (if playing) and resets to the start position
pause() Stops the video player
resume() Starts the video player from its current position
rewind() Starts the video player from the beginning
seek(int position) Starts the video player from the specified position

Examples

Video Example

<FML title="VIDEO (example1)" linkable="true">

  <BOX center="true">
    <BOX width="50%" height="50%">
      <VIDEO id="video1" url="{url}" controls="{show}" loop="true" oninitialized="video1.play();"/>
    </BOX>

    <SELECT id="show">
      <OPTION label="SHOW CONTROLS" value="1"/>
      <OPTION label="HIDE CONTROLS" value="0"/>
    </SELECT>

    <SELECT id="url" value="https://flutter.github.io/assets-for-api-docs/assets/videos/bee.mp4">
      <OPTION label="Bee" value="https://flutter.github.io/assets-for-api-docs/assets/videos/bee.mp4"/>
      <OPTION label="Butterfly" value="https://flutter.github.io/assets-for-api-docs/assets/videos/butterfly.mp4"/>
    </SELECT>
  </BOX>

</FML>

logo See it in Action

Other Widgets You May Find Useful:

⚠️ **GitHub.com Fallback** ⚠️