public class SoundActionHandler extends ActionHandler
This code is copyright the Big Faceless Organization. You're welcome to use, modify and distribute it in any form in your own projects, provided those projects continue to make use of the Big Faceless PDF library.
Constructor and Description |
---|
SoundActionHandler()
Create a new SoundActionHandler
|
Modifier and Type | Method and Description |
---|---|
boolean |
matches(DocumentPanel panel,
PDFAction action)
Return true if this ActionFactory can handle the specified
PDFAction |
static void |
playSound(PDFSound sound,
boolean mix,
boolean repeat,
JComponent root)
Play a sound.
|
void |
run(DocumentPanel docpanel,
PDFAction action)
Run the specified action
|
toString
getAllEnabledFeatures, getAllFeatures, getCustomJavaScript, getFeatureProperty, getFeatureURLProperty, getName, initialize, isEnabledByDefault, setFeatureName, teardown
public SoundActionHandler()
public boolean matches(DocumentPanel panel, PDFAction action)
ActionHandler
PDFAction
matches
in class ActionHandler
public void run(DocumentPanel docpanel, PDFAction action)
ActionHandler
run
in class ActionHandler
docpanel
- the DocumentPanel running the actionaction
- the actionpublic static void playSound(PDFSound sound, boolean mix, boolean repeat, JComponent root)
sound
- the PDFSound objectmix
- whether to mix this sound (true) or if it should be the only sound playing (false)repeat
- whether the sound should repeat until the next non-mixed sound is playedroot
- the Component owning the sound.Copyright © 2001-2017 Big Faceless Organization