mediaplayer 0.4.3

Safe Rust bindings for MediaPlayer.framework on macOS — now playing, remote commands, artwork, and explicit iOS-only stubs
Documentation
1
2
3
4
5
6
7
8
9
10
//! Smoke example for the explicit macOS-unavailable `MPPlayableContentDataSource` wrapper.

use mediaplayer::PlayableContentDataSource;

fn main() {
    assert!(!PlayableContentDataSource::is_supported());
    println!("{}", PlayableContentDataSource::unavailable_reason());
    let err = PlayableContentDataSource::new().expect_err("MPPlayableContentDataSource should be unavailable on macOS");
    println!("{err}");
}