objc2_media_player/generated/
MPRemoteControlTypes.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use objc2::__framework_prelude::*;
4
5use crate::*;
6
7/// [Apple's documentation](https://developer.apple.com/documentation/mediaplayer/mpshuffletype?language=objc)
8// NS_ENUM
9#[repr(transparent)]
10#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
11pub struct MPShuffleType(pub NSInteger);
12impl MPShuffleType {
13    #[doc(alias = "MPShuffleTypeOff")]
14    pub const Off: Self = Self(0);
15    /// Nothing is shuffled during playback.
16    #[doc(alias = "MPShuffleTypeItems")]
17    pub const Items: Self = Self(1);
18    /// Individual items are shuffled during playback.
19    #[doc(alias = "MPShuffleTypeCollections")]
20    pub const Collections: Self = Self(2);
21}
22
23unsafe impl Encode for MPShuffleType {
24    const ENCODING: Encoding = NSInteger::ENCODING;
25}
26
27unsafe impl RefEncode for MPShuffleType {
28    const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
29}
30
31/// [Apple's documentation](https://developer.apple.com/documentation/mediaplayer/mprepeattype?language=objc)
32// NS_ENUM
33#[repr(transparent)]
34#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
35pub struct MPRepeatType(pub NSInteger);
36impl MPRepeatType {
37    #[doc(alias = "MPRepeatTypeOff")]
38    pub const Off: Self = Self(0);
39    /// Nothing is repeated during playback.
40    #[doc(alias = "MPRepeatTypeOne")]
41    pub const One: Self = Self(1);
42    /// Repeat a single item indefinitely.
43    #[doc(alias = "MPRepeatTypeAll")]
44    pub const All: Self = Self(2);
45}
46
47unsafe impl Encode for MPRepeatType {
48    const ENCODING: Encoding = NSInteger::ENCODING;
49}
50
51unsafe impl RefEncode for MPRepeatType {
52    const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
53}
54
55/// [Apple's documentation](https://developer.apple.com/documentation/mediaplayer/mpchangelanguageoptionsetting?language=objc)
56// NS_ENUM
57#[repr(transparent)]
58#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
59pub struct MPChangeLanguageOptionSetting(pub NSInteger);
60impl MPChangeLanguageOptionSetting {
61    #[doc(alias = "MPChangeLanguageOptionSettingNone")]
62    pub const None: Self = Self(0);
63    /// No Language Option Change
64    #[doc(alias = "MPChangeLanguageOptionSettingNowPlayingItemOnly")]
65    pub const NowPlayingItemOnly: Self = Self(1);
66    /// The Language Option change applies only the the now playing item
67    #[doc(alias = "MPChangeLanguageOptionSettingPermanent")]
68    pub const Permanent: Self = Self(2);
69}
70
71unsafe impl Encode for MPChangeLanguageOptionSetting {
72    const ENCODING: Encoding = NSInteger::ENCODING;
73}
74
75unsafe impl RefEncode for MPChangeLanguageOptionSetting {
76    const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
77}