Presentation is loading. Please wait.

Presentation is loading. Please wait.

Slider A Slider Lets the user graphically select a value By sliding a knob within a bounded interval Can show both major tick marks and minor ones A listener.

Similar presentations


Presentation on theme: "Slider A Slider Lets the user graphically select a value By sliding a knob within a bounded interval Can show both major tick marks and minor ones A listener."— Presentation transcript:

1 Slider A Slider Lets the user graphically select a value By sliding a knob within a bounded interval Can show both major tick marks and minor ones A listener can be added to listen for value property change

2 Example Refer to BouncingBallApp Eclipse project A slider is added to control the speed of the ball movement The rate property is bound to The current value shown by the slider  Allowing the rate to vary between 0 and 20

3 Video and Audio (Media) Media Used to obtain the source of the media Currently, JavaFX supports MP3, AIFF, WAV, and MPEG4 audio formats and MPEG-4 video formats

4 Video and Audio (MediaPlayer) MediaPlayer Used to control and play the media

5 Video and Audio (MediaView) MediaView Displays the video

6 Example 1 Refer to MediaDemo Eclipse project Displays a video in a view play/pause button is used to play/pause video Rewind button is used to restart the video Slider is used to control the volume of the audio

7 Example 2 Refer to FlagAnthem Eclipse project The images for Denmark, Germany, India, Norway, UK, USA  http://cs.armstrong.edu/liang/common/image/ The audio clips for national anthems http://cs.armstrong.edu/liang/common/audio/anthem


Download ppt "Slider A Slider Lets the user graphically select a value By sliding a knob within a bounded interval Can show both major tick marks and minor ones A listener."

Similar presentations


Ads by Google