Struct mpris::ProgressTick
source · pub struct ProgressTick<'a> {
pub player_quit: bool,
pub progress_changed: bool,
pub track_list_changed: bool,
pub progress: &'a Progress,
pub track_list: Option<&'a TrackList>,
}
Expand description
Return value of ProgressTracker::tick
, which gives details about the latest refresh.
Fields§
§player_quit: bool
true
if Player
quit. This likely means that the player is no longer running.
If the player is no longer running, then fetching new data will not be possible,
so they will all be reused (progress_changed
and
track_list_changed
should all be false
).
progress_changed: bool
true
if Progress
data changed (beyond the calculated position
)
Examples:
- Playback status changed
- Metadata changed for the track
- Volume was decreased
track_list_changed: bool
true
if TrackList
data changed. This will always be false
if player does not support
track lists.
Examples:
- Track was added
- Track was removed
- Metadata changed for a track
progress: &'a Progress
The current Progress
from the ProgressTracker
. progress_changed
tells you if this was reused from the last tick or if it’s a new one.
track_list: Option<&'a TrackList>
The current TrackList
from the ProgressTracker
. track_list_changed
tells you if this was changed since the last tick.