The hardware volume keys on the receivers page, best effort (decision D32): if exactly one player of YAACC is active (playing or paused) and it plays to a remote receiver (a UPnP renderer, an OpenHome device, an FCast receiver, a Snapcast group or a Sendspin player) that can be asked for its volume, the keys change that receiver's volume by {@value STEP} percent per press and a short message shows the receiver and the new volume (the system's volume bar does not appear for a key that was taken).
More...
|
| static Player | target (Collection<? extends Player > players) |
| |
|
static int | step (int currentPercent, boolean up) |
| | The volume in percent after a press: one step up or down, between 0 and 100.
|
| |
| static boolean | onKeyDown (final Context context, final boolean up, Collection<? extends Player > players) |
| |
|
|
static final int | STEP = 5 |
| | Percent per key press.
|
| |
The hardware volume keys on the receivers page, best effort (decision D32): if exactly one player of YAACC is active (playing or paused) and it plays to a remote receiver (a UPnP renderer, an OpenHome device, an FCast receiver, a Snapcast group or a Sendspin player) that can be asked for its volume, the keys change that receiver's volume by {@value STEP} percent per press and a short message shows the receiver and the new volume (the system's volume bar does not appear for a key that was taken).
With no active player, with more than one, or when the one that is active plays on this phone, the keys are the system's, as before: a local player uses the phone's own stream, which the system already handles. A Snapcast group that has the focus on the page comes first (de.yaacc.browser.VolumeKeyHosts). Only players of YAACC are considered: nothing is changed on a receiver that another sender plays.
◆ onKeyDown()
| static boolean de.yaacc.player.PlayerVolumeKeys.onKeyDown |
( |
final Context | context, |
|
|
final boolean | up, |
|
|
Collection<? extends Player > | players ) |
|
static |
- Parameters
-
| up | true for the volume up key |
- Returns
- true if a receiver takes the key (the volume is changed on a worker thread, the message shows afterwards); false leaves the key to the system
◆ target()
| static Player de.yaacc.player.PlayerVolumeKeys.target |
( |
Collection<? extends Player > | players | ) |
|
|
static |
The documentation for this class was generated from the following file:
- /github/workspace/yaacc/src/main/java/de/yaacc/player/PlayerVolumeKeys.java