1254 lines
56 KiB
Swift
1254 lines
56 KiB
Swift
// WARNING: Please don't edit this file. It was generated by Swift/WinRT v0.0.1
|
|
// swiftlint:disable all
|
|
import Foundation
|
|
@_spi(WinRTInternal) @_spi(WinRTImplements) import WindowsFoundation
|
|
import CWinRT
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audiobufferaccessmode)
|
|
public typealias AudioBufferAccessMode = __x_ABI_CWindows_CMedia_CAudioBufferAccessMode
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audioprocessing)
|
|
public typealias AudioProcessing = __x_ABI_CWindows_CMedia_CAudioProcessing
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediaplaybackautorepeatmode)
|
|
public typealias MediaPlaybackAutoRepeatMode = __x_ABI_CWindows_CMedia_CMediaPlaybackAutoRepeatMode
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediaplaybackstatus)
|
|
public typealias MediaPlaybackStatus = __x_ABI_CWindows_CMedia_CMediaPlaybackStatus
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediaplaybacktype)
|
|
public typealias MediaPlaybackType = __x_ABI_CWindows_CMedia_CMediaPlaybackType
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontrollerstate)
|
|
public typealias MediaTimelineControllerState = __x_ABI_CWindows_CMedia_CMediaTimelineControllerState
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.soundlevel)
|
|
public typealias SoundLevel = __x_ABI_CWindows_CMedia_CSoundLevel
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsbutton)
|
|
public typealias SystemMediaTransportControlsButton = __x_ABI_CWindows_CMedia_CSystemMediaTransportControlsButton
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsproperty)
|
|
public typealias SystemMediaTransportControlsProperty = __x_ABI_CWindows_CMedia_CSystemMediaTransportControlsProperty
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audiobuffer)
|
|
public final class AudioBuffer : WinRTClass, WindowsFoundation.IClosable, WindowsFoundation.IMemoryBuffer {
|
|
private typealias SwiftABI = __ABI_Windows_Media.IAudioBuffer
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CIAudioBuffer
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CIAudioBuffer>?) -> AudioBuffer? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
override public func queryInterface(_ iid: WindowsFoundation.IID) -> IUnknownRef? {
|
|
return super.queryInterface(iid)
|
|
}
|
|
private lazy var _IClosable: __ABI_Windows_Foundation.IClosable! = getInterfaceForCaching()
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audiobuffer.close)
|
|
public func close() throws {
|
|
try _IClosable.CloseImpl()
|
|
}
|
|
|
|
private lazy var _IMemoryBuffer: __ABI_Windows_Foundation.IMemoryBuffer! = getInterfaceForCaching()
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audiobuffer.createreference)
|
|
public func createReference() throws -> WindowsFoundation.AnyIMemoryBufferReference! {
|
|
try _IMemoryBuffer.CreateReferenceImpl()
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audiobuffer.capacity)
|
|
public var capacity : UInt32 {
|
|
get { try! _default.get_CapacityImpl() }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audiobuffer.length)
|
|
public var length : UInt32 {
|
|
get { try! _default.get_LengthImpl() }
|
|
set { try! _default.put_LengthImpl(newValue) }
|
|
}
|
|
|
|
deinit {
|
|
_IClosable = nil
|
|
_IMemoryBuffer = nil
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audioframe)
|
|
public final class AudioFrame : WinRTClass, WindowsFoundation.IClosable, IMediaFrame {
|
|
private typealias SwiftABI = __ABI_Windows_Media.IAudioFrame
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CIAudioFrame
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CIAudioFrame>?) -> AudioFrame? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
override public func queryInterface(_ iid: WindowsFoundation.IID) -> IUnknownRef? {
|
|
return super.queryInterface(iid)
|
|
}
|
|
private static let _IAudioFrameFactory: __ABI_Windows_Media.IAudioFrameFactory = try! RoGetActivationFactory(HString("Windows.Media.AudioFrame"))
|
|
public init(_ capacity: UInt32) {
|
|
super.init(try! Self._IAudioFrameFactory.CreateImpl(capacity))
|
|
}
|
|
|
|
private lazy var _IClosable: __ABI_Windows_Foundation.IClosable! = getInterfaceForCaching()
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audioframe.close)
|
|
public func close() throws {
|
|
try _IClosable.CloseImpl()
|
|
}
|
|
|
|
private lazy var _IMediaFrame: __ABI_Windows_Media.IMediaFrame! = getInterfaceForCaching()
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audioframe.duration)
|
|
public var duration : WindowsFoundation.TimeSpan? {
|
|
get { try! _IMediaFrame.get_DurationImpl() }
|
|
set { try! _IMediaFrame.put_DurationImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audioframe.extendedproperties)
|
|
public var extendedProperties : WindowsFoundation.AnyIPropertySet! {
|
|
get { try! _IMediaFrame.get_ExtendedPropertiesImpl() }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audioframe.isdiscontinuous)
|
|
public var isDiscontinuous : Bool {
|
|
get { try! _IMediaFrame.get_IsDiscontinuousImpl() }
|
|
set { try! _IMediaFrame.put_IsDiscontinuousImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audioframe.isreadonly)
|
|
public var isReadOnly : Bool {
|
|
get { try! _IMediaFrame.get_IsReadOnlyImpl() }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audioframe.relativetime)
|
|
public var relativeTime : WindowsFoundation.TimeSpan? {
|
|
get { try! _IMediaFrame.get_RelativeTimeImpl() }
|
|
set { try! _IMediaFrame.put_RelativeTimeImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audioframe.systemrelativetime)
|
|
public var systemRelativeTime : WindowsFoundation.TimeSpan? {
|
|
get { try! _IMediaFrame.get_SystemRelativeTimeImpl() }
|
|
set { try! _IMediaFrame.put_SystemRelativeTimeImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audioframe.type)
|
|
public var type : String {
|
|
get { try! _IMediaFrame.get_TypeImpl() }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.audioframe.lockbuffer)
|
|
public func lockBuffer(_ mode: AudioBufferAccessMode) throws -> AudioBuffer! {
|
|
try _default.LockBufferImpl(mode)
|
|
}
|
|
|
|
deinit {
|
|
_IClosable = nil
|
|
_IMediaFrame = nil
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.autorepeatmodechangerequestedeventargs)
|
|
public final class AutoRepeatModeChangeRequestedEventArgs : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.IAutoRepeatModeChangeRequestedEventArgs
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CIAutoRepeatModeChangeRequestedEventArgs
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CIAutoRepeatModeChangeRequestedEventArgs>?) -> AutoRepeatModeChangeRequestedEventArgs? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.autorepeatmodechangerequestedeventargs.requestedautorepeatmode)
|
|
public var requestedAutoRepeatMode : MediaPlaybackAutoRepeatMode {
|
|
get { try! _default.get_RequestedAutoRepeatModeImpl() }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imagedisplayproperties)
|
|
public final class ImageDisplayProperties : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.IImageDisplayProperties
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CIImageDisplayProperties
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CIImageDisplayProperties>?) -> ImageDisplayProperties? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imagedisplayproperties.subtitle)
|
|
public var subtitle : String {
|
|
get { try! _default.get_SubtitleImpl() }
|
|
set { try! _default.put_SubtitleImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imagedisplayproperties.title)
|
|
public var title : String {
|
|
get { try! _default.get_TitleImpl() }
|
|
set { try! _default.put_TitleImpl(newValue) }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller)
|
|
public final class MediaTimelineController : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.IMediaTimelineController
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CIMediaTimelineController
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CIMediaTimelineController>?) -> MediaTimelineController? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
override public init() {
|
|
super.init(try! RoActivateInstance(HString("Windows.Media.MediaTimelineController")))
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.start)
|
|
public func start() throws {
|
|
try _default.StartImpl()
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.resume)
|
|
public func resume() throws {
|
|
try _default.ResumeImpl()
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.pause)
|
|
public func pause() throws {
|
|
try _default.PauseImpl()
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.clockrate)
|
|
public var clockRate : Double {
|
|
get { try! _default.get_ClockRateImpl() }
|
|
set { try! _default.put_ClockRateImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.position)
|
|
public var position : WindowsFoundation.TimeSpan {
|
|
get { try! _default.get_PositionImpl() }
|
|
set { try! _default.put_PositionImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.state)
|
|
public var state : MediaTimelineControllerState {
|
|
get { try! _default.get_StateImpl() }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.positionchanged)
|
|
public lazy var positionChanged : Event<TypedEventHandler<MediaTimelineController?, Any?>> = {
|
|
.init(
|
|
add: { [weak self] in
|
|
guard let this = self?._default else { return .init() }
|
|
return try! this.add_PositionChangedImpl($0)
|
|
},
|
|
remove: { [weak self] in
|
|
try? self?._default.remove_PositionChangedImpl($0)
|
|
}
|
|
)
|
|
}()
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.statechanged)
|
|
public lazy var stateChanged : Event<TypedEventHandler<MediaTimelineController?, Any?>> = {
|
|
.init(
|
|
add: { [weak self] in
|
|
guard let this = self?._default else { return .init() }
|
|
return try! this.add_StateChangedImpl($0)
|
|
},
|
|
remove: { [weak self] in
|
|
try? self?._default.remove_StateChangedImpl($0)
|
|
}
|
|
)
|
|
}()
|
|
|
|
private lazy var _IMediaTimelineController2: __ABI_Windows_Media.IMediaTimelineController2! = getInterfaceForCaching()
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.duration)
|
|
public var duration : WindowsFoundation.TimeSpan? {
|
|
get { try! _IMediaTimelineController2.get_DurationImpl() }
|
|
set { try! _IMediaTimelineController2.put_DurationImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.isloopingenabled)
|
|
public var isLoopingEnabled : Bool {
|
|
get { try! _IMediaTimelineController2.get_IsLoopingEnabledImpl() }
|
|
set { try! _IMediaTimelineController2.put_IsLoopingEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.ended)
|
|
public lazy var ended : Event<TypedEventHandler<MediaTimelineController?, Any?>> = {
|
|
.init(
|
|
add: { [weak self] in
|
|
guard let this = self?._IMediaTimelineController2 else { return .init() }
|
|
return try! this.add_EndedImpl($0)
|
|
},
|
|
remove: { [weak self] in
|
|
try? self?._IMediaTimelineController2.remove_EndedImpl($0)
|
|
}
|
|
)
|
|
}()
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontroller.failed)
|
|
public lazy var failed : Event<TypedEventHandler<MediaTimelineController?, MediaTimelineControllerFailedEventArgs?>> = {
|
|
.init(
|
|
add: { [weak self] in
|
|
guard let this = self?._IMediaTimelineController2 else { return .init() }
|
|
return try! this.add_FailedImpl($0)
|
|
},
|
|
remove: { [weak self] in
|
|
try? self?._IMediaTimelineController2.remove_FailedImpl($0)
|
|
}
|
|
)
|
|
}()
|
|
|
|
deinit {
|
|
_default = nil
|
|
_IMediaTimelineController2 = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontrollerfailedeventargs)
|
|
public final class MediaTimelineControllerFailedEventArgs : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.IMediaTimelineControllerFailedEventArgs
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CIMediaTimelineControllerFailedEventArgs
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CIMediaTimelineControllerFailedEventArgs>?) -> MediaTimelineControllerFailedEventArgs? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimelinecontrollerfailedeventargs.extendederror)
|
|
public var extendedError : HRESULT {
|
|
get { try! _default.get_ExtendedErrorImpl() }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.musicdisplayproperties)
|
|
public final class MusicDisplayProperties : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.IMusicDisplayProperties
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CIMusicDisplayProperties
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CIMusicDisplayProperties>?) -> MusicDisplayProperties? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.musicdisplayproperties.albumartist)
|
|
public var albumArtist : String {
|
|
get { try! _default.get_AlbumArtistImpl() }
|
|
set { try! _default.put_AlbumArtistImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.musicdisplayproperties.artist)
|
|
public var artist : String {
|
|
get { try! _default.get_ArtistImpl() }
|
|
set { try! _default.put_ArtistImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.musicdisplayproperties.title)
|
|
public var title : String {
|
|
get { try! _default.get_TitleImpl() }
|
|
set { try! _default.put_TitleImpl(newValue) }
|
|
}
|
|
|
|
private lazy var _IMusicDisplayProperties2: __ABI_Windows_Media.IMusicDisplayProperties2! = getInterfaceForCaching()
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.musicdisplayproperties.albumtitle)
|
|
public var albumTitle : String {
|
|
get { try! _IMusicDisplayProperties2.get_AlbumTitleImpl() }
|
|
set { try! _IMusicDisplayProperties2.put_AlbumTitleImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.musicdisplayproperties.genres)
|
|
public var genres : WindowsFoundation.AnyIVector<String>! {
|
|
get { try! _IMusicDisplayProperties2.get_GenresImpl() }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.musicdisplayproperties.tracknumber)
|
|
public var trackNumber : UInt32 {
|
|
get { try! _IMusicDisplayProperties2.get_TrackNumberImpl() }
|
|
set { try! _IMusicDisplayProperties2.put_TrackNumberImpl(newValue) }
|
|
}
|
|
|
|
private lazy var _IMusicDisplayProperties3: __ABI_Windows_Media.IMusicDisplayProperties3! = getInterfaceForCaching()
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.musicdisplayproperties.albumtrackcount)
|
|
public var albumTrackCount : UInt32 {
|
|
get { try! _IMusicDisplayProperties3.get_AlbumTrackCountImpl() }
|
|
set { try! _IMusicDisplayProperties3.put_AlbumTrackCountImpl(newValue) }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
_IMusicDisplayProperties2 = nil
|
|
_IMusicDisplayProperties3 = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.playbackpositionchangerequestedeventargs)
|
|
public final class PlaybackPositionChangeRequestedEventArgs : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.IPlaybackPositionChangeRequestedEventArgs
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CIPlaybackPositionChangeRequestedEventArgs
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CIPlaybackPositionChangeRequestedEventArgs>?) -> PlaybackPositionChangeRequestedEventArgs? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.playbackpositionchangerequestedeventargs.requestedplaybackposition)
|
|
public var requestedPlaybackPosition : WindowsFoundation.TimeSpan {
|
|
get { try! _default.get_RequestedPlaybackPositionImpl() }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.playbackratechangerequestedeventargs)
|
|
public final class PlaybackRateChangeRequestedEventArgs : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.IPlaybackRateChangeRequestedEventArgs
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CIPlaybackRateChangeRequestedEventArgs
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CIPlaybackRateChangeRequestedEventArgs>?) -> PlaybackRateChangeRequestedEventArgs? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.playbackratechangerequestedeventargs.requestedplaybackrate)
|
|
public var requestedPlaybackRate : Double {
|
|
get { try! _default.get_RequestedPlaybackRateImpl() }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.shuffleenabledchangerequestedeventargs)
|
|
public final class ShuffleEnabledChangeRequestedEventArgs : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.IShuffleEnabledChangeRequestedEventArgs
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CIShuffleEnabledChangeRequestedEventArgs
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CIShuffleEnabledChangeRequestedEventArgs>?) -> ShuffleEnabledChangeRequestedEventArgs? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.shuffleenabledchangerequestedeventargs.requestedshuffleenabled)
|
|
public var requestedShuffleEnabled : Bool {
|
|
get { try! _default.get_RequestedShuffleEnabledImpl() }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols)
|
|
public final class SystemMediaTransportControls : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.ISystemMediaTransportControls
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CISystemMediaTransportControls
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CISystemMediaTransportControls>?) -> SystemMediaTransportControls? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
private static let _ISystemMediaTransportControlsStatics: __ABI_Windows_Media.ISystemMediaTransportControlsStatics = try! RoGetActivationFactory(HString("Windows.Media.SystemMediaTransportControls"))
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.getforcurrentview)
|
|
public static func getForCurrentView() -> SystemMediaTransportControls! {
|
|
return try! _ISystemMediaTransportControlsStatics.GetForCurrentViewImpl()
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.displayupdater)
|
|
public var displayUpdater : SystemMediaTransportControlsDisplayUpdater! {
|
|
get { try! _default.get_DisplayUpdaterImpl() }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.ischanneldownenabled)
|
|
public var isChannelDownEnabled : Bool {
|
|
get { try! _default.get_IsChannelDownEnabledImpl() }
|
|
set { try! _default.put_IsChannelDownEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.ischannelupenabled)
|
|
public var isChannelUpEnabled : Bool {
|
|
get { try! _default.get_IsChannelUpEnabledImpl() }
|
|
set { try! _default.put_IsChannelUpEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.isenabled)
|
|
public var isEnabled : Bool {
|
|
get { try! _default.get_IsEnabledImpl() }
|
|
set { try! _default.put_IsEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.isfastforwardenabled)
|
|
public var isFastForwardEnabled : Bool {
|
|
get { try! _default.get_IsFastForwardEnabledImpl() }
|
|
set { try! _default.put_IsFastForwardEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.isnextenabled)
|
|
public var isNextEnabled : Bool {
|
|
get { try! _default.get_IsNextEnabledImpl() }
|
|
set { try! _default.put_IsNextEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.ispauseenabled)
|
|
public var isPauseEnabled : Bool {
|
|
get { try! _default.get_IsPauseEnabledImpl() }
|
|
set { try! _default.put_IsPauseEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.isplayenabled)
|
|
public var isPlayEnabled : Bool {
|
|
get { try! _default.get_IsPlayEnabledImpl() }
|
|
set { try! _default.put_IsPlayEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.ispreviousenabled)
|
|
public var isPreviousEnabled : Bool {
|
|
get { try! _default.get_IsPreviousEnabledImpl() }
|
|
set { try! _default.put_IsPreviousEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.isrecordenabled)
|
|
public var isRecordEnabled : Bool {
|
|
get { try! _default.get_IsRecordEnabledImpl() }
|
|
set { try! _default.put_IsRecordEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.isrewindenabled)
|
|
public var isRewindEnabled : Bool {
|
|
get { try! _default.get_IsRewindEnabledImpl() }
|
|
set { try! _default.put_IsRewindEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.isstopenabled)
|
|
public var isStopEnabled : Bool {
|
|
get { try! _default.get_IsStopEnabledImpl() }
|
|
set { try! _default.put_IsStopEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.playbackstatus)
|
|
public var playbackStatus : MediaPlaybackStatus {
|
|
get { try! _default.get_PlaybackStatusImpl() }
|
|
set { try! _default.put_PlaybackStatusImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.soundlevel)
|
|
public var soundLevel : SoundLevel {
|
|
get { try! _default.get_SoundLevelImpl() }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.buttonpressed)
|
|
public lazy var buttonPressed : Event<TypedEventHandler<SystemMediaTransportControls?, SystemMediaTransportControlsButtonPressedEventArgs?>> = {
|
|
.init(
|
|
add: { [weak self] in
|
|
guard let this = self?._default else { return .init() }
|
|
return try! this.add_ButtonPressedImpl($0)
|
|
},
|
|
remove: { [weak self] in
|
|
try? self?._default.remove_ButtonPressedImpl($0)
|
|
}
|
|
)
|
|
}()
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.propertychanged)
|
|
public lazy var propertyChanged : Event<TypedEventHandler<SystemMediaTransportControls?, SystemMediaTransportControlsPropertyChangedEventArgs?>> = {
|
|
.init(
|
|
add: { [weak self] in
|
|
guard let this = self?._default else { return .init() }
|
|
return try! this.add_PropertyChangedImpl($0)
|
|
},
|
|
remove: { [weak self] in
|
|
try? self?._default.remove_PropertyChangedImpl($0)
|
|
}
|
|
)
|
|
}()
|
|
|
|
private lazy var _ISystemMediaTransportControls2: __ABI_Windows_Media.ISystemMediaTransportControls2! = getInterfaceForCaching()
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.updatetimelineproperties)
|
|
public func updateTimelineProperties(_ timelineProperties: SystemMediaTransportControlsTimelineProperties!) throws {
|
|
try _ISystemMediaTransportControls2.UpdateTimelinePropertiesImpl(timelineProperties)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.autorepeatmode)
|
|
public var autoRepeatMode : MediaPlaybackAutoRepeatMode {
|
|
get { try! _ISystemMediaTransportControls2.get_AutoRepeatModeImpl() }
|
|
set { try! _ISystemMediaTransportControls2.put_AutoRepeatModeImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.playbackrate)
|
|
public var playbackRate : Double {
|
|
get { try! _ISystemMediaTransportControls2.get_PlaybackRateImpl() }
|
|
set { try! _ISystemMediaTransportControls2.put_PlaybackRateImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.shuffleenabled)
|
|
public var shuffleEnabled : Bool {
|
|
get { try! _ISystemMediaTransportControls2.get_ShuffleEnabledImpl() }
|
|
set { try! _ISystemMediaTransportControls2.put_ShuffleEnabledImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.autorepeatmodechangerequested)
|
|
public lazy var autoRepeatModeChangeRequested : Event<TypedEventHandler<SystemMediaTransportControls?, AutoRepeatModeChangeRequestedEventArgs?>> = {
|
|
.init(
|
|
add: { [weak self] in
|
|
guard let this = self?._ISystemMediaTransportControls2 else { return .init() }
|
|
return try! this.add_AutoRepeatModeChangeRequestedImpl($0)
|
|
},
|
|
remove: { [weak self] in
|
|
try? self?._ISystemMediaTransportControls2.remove_AutoRepeatModeChangeRequestedImpl($0)
|
|
}
|
|
)
|
|
}()
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.playbackpositionchangerequested)
|
|
public lazy var playbackPositionChangeRequested : Event<TypedEventHandler<SystemMediaTransportControls?, PlaybackPositionChangeRequestedEventArgs?>> = {
|
|
.init(
|
|
add: { [weak self] in
|
|
guard let this = self?._ISystemMediaTransportControls2 else { return .init() }
|
|
return try! this.add_PlaybackPositionChangeRequestedImpl($0)
|
|
},
|
|
remove: { [weak self] in
|
|
try? self?._ISystemMediaTransportControls2.remove_PlaybackPositionChangeRequestedImpl($0)
|
|
}
|
|
)
|
|
}()
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.playbackratechangerequested)
|
|
public lazy var playbackRateChangeRequested : Event<TypedEventHandler<SystemMediaTransportControls?, PlaybackRateChangeRequestedEventArgs?>> = {
|
|
.init(
|
|
add: { [weak self] in
|
|
guard let this = self?._ISystemMediaTransportControls2 else { return .init() }
|
|
return try! this.add_PlaybackRateChangeRequestedImpl($0)
|
|
},
|
|
remove: { [weak self] in
|
|
try? self?._ISystemMediaTransportControls2.remove_PlaybackRateChangeRequestedImpl($0)
|
|
}
|
|
)
|
|
}()
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrols.shuffleenabledchangerequested)
|
|
public lazy var shuffleEnabledChangeRequested : Event<TypedEventHandler<SystemMediaTransportControls?, ShuffleEnabledChangeRequestedEventArgs?>> = {
|
|
.init(
|
|
add: { [weak self] in
|
|
guard let this = self?._ISystemMediaTransportControls2 else { return .init() }
|
|
return try! this.add_ShuffleEnabledChangeRequestedImpl($0)
|
|
},
|
|
remove: { [weak self] in
|
|
try? self?._ISystemMediaTransportControls2.remove_ShuffleEnabledChangeRequestedImpl($0)
|
|
}
|
|
)
|
|
}()
|
|
|
|
deinit {
|
|
_default = nil
|
|
_ISystemMediaTransportControls2 = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsbuttonpressedeventargs)
|
|
public final class SystemMediaTransportControlsButtonPressedEventArgs : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.ISystemMediaTransportControlsButtonPressedEventArgs
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CISystemMediaTransportControlsButtonPressedEventArgs
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CISystemMediaTransportControlsButtonPressedEventArgs>?) -> SystemMediaTransportControlsButtonPressedEventArgs? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsbuttonpressedeventargs.button)
|
|
public var button : SystemMediaTransportControlsButton {
|
|
get { try! _default.get_ButtonImpl() }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsdisplayupdater)
|
|
public final class SystemMediaTransportControlsDisplayUpdater : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.ISystemMediaTransportControlsDisplayUpdater
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CISystemMediaTransportControlsDisplayUpdater
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CISystemMediaTransportControlsDisplayUpdater>?) -> SystemMediaTransportControlsDisplayUpdater? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsdisplayupdater.copyfromfileasync)
|
|
public func copyFromFileAsync(_ type: MediaPlaybackType, _ source: UWP.StorageFile!) throws -> WindowsFoundation.AnyIAsyncOperation<Bool>! {
|
|
try _default.CopyFromFileAsyncImpl(type, source)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsdisplayupdater.clearall)
|
|
public func clearAll() throws {
|
|
try _default.ClearAllImpl()
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsdisplayupdater.update)
|
|
public func update() throws {
|
|
try _default.UpdateImpl()
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsdisplayupdater.appmediaid)
|
|
public var appMediaId : String {
|
|
get { try! _default.get_AppMediaIdImpl() }
|
|
set { try! _default.put_AppMediaIdImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsdisplayupdater.imageproperties)
|
|
public var imageProperties : ImageDisplayProperties! {
|
|
get { try! _default.get_ImagePropertiesImpl() }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsdisplayupdater.musicproperties)
|
|
public var musicProperties : MusicDisplayProperties! {
|
|
get { try! _default.get_MusicPropertiesImpl() }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsdisplayupdater.thumbnail)
|
|
public var thumbnail : UWP.RandomAccessStreamReference! {
|
|
get { try! _default.get_ThumbnailImpl() }
|
|
set { try! _default.put_ThumbnailImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsdisplayupdater.type)
|
|
public var type : MediaPlaybackType {
|
|
get { try! _default.get_TypeImpl() }
|
|
set { try! _default.put_TypeImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolsdisplayupdater.videoproperties)
|
|
public var videoProperties : VideoDisplayProperties! {
|
|
get { try! _default.get_VideoPropertiesImpl() }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolspropertychangedeventargs)
|
|
public final class SystemMediaTransportControlsPropertyChangedEventArgs : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.ISystemMediaTransportControlsPropertyChangedEventArgs
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CISystemMediaTransportControlsPropertyChangedEventArgs
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CISystemMediaTransportControlsPropertyChangedEventArgs>?) -> SystemMediaTransportControlsPropertyChangedEventArgs? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolspropertychangedeventargs.property)
|
|
public var property : SystemMediaTransportControlsProperty {
|
|
get { try! _default.get_PropertyImpl() }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolstimelineproperties)
|
|
public final class SystemMediaTransportControlsTimelineProperties : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.ISystemMediaTransportControlsTimelineProperties
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CISystemMediaTransportControlsTimelineProperties
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CISystemMediaTransportControlsTimelineProperties>?) -> SystemMediaTransportControlsTimelineProperties? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
override public init() {
|
|
super.init(try! RoActivateInstance(HString("Windows.Media.SystemMediaTransportControlsTimelineProperties")))
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolstimelineproperties.endtime)
|
|
public var endTime : WindowsFoundation.TimeSpan {
|
|
get { try! _default.get_EndTimeImpl() }
|
|
set { try! _default.put_EndTimeImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolstimelineproperties.maxseektime)
|
|
public var maxSeekTime : WindowsFoundation.TimeSpan {
|
|
get { try! _default.get_MaxSeekTimeImpl() }
|
|
set { try! _default.put_MaxSeekTimeImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolstimelineproperties.minseektime)
|
|
public var minSeekTime : WindowsFoundation.TimeSpan {
|
|
get { try! _default.get_MinSeekTimeImpl() }
|
|
set { try! _default.put_MinSeekTimeImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolstimelineproperties.position)
|
|
public var position : WindowsFoundation.TimeSpan {
|
|
get { try! _default.get_PositionImpl() }
|
|
set { try! _default.put_PositionImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.systemmediatransportcontrolstimelineproperties.starttime)
|
|
public var startTime : WindowsFoundation.TimeSpan {
|
|
get { try! _default.get_StartTimeImpl() }
|
|
set { try! _default.put_StartTimeImpl(newValue) }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.videodisplayproperties)
|
|
public final class VideoDisplayProperties : WinRTClass {
|
|
private typealias SwiftABI = __ABI_Windows_Media.IVideoDisplayProperties
|
|
private typealias CABI = __x_ABI_CWindows_CMedia_CIVideoDisplayProperties
|
|
private lazy var _default: SwiftABI! = getInterfaceForCaching()
|
|
@_spi(WinRTInternal)
|
|
override public func _getABI<T>() -> UnsafeMutablePointer<T>? {
|
|
if T.self == CABI.self {
|
|
return RawPointer(_default)
|
|
}
|
|
return super._getABI()
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public static func from(abi: ComPtr<__x_ABI_CWindows_CMedia_CIVideoDisplayProperties>?) -> VideoDisplayProperties? {
|
|
guard let abi = abi else { return nil }
|
|
return .init(fromAbi: WindowsFoundation.IInspectable(abi))
|
|
}
|
|
|
|
@_spi(WinRTInternal)
|
|
public init(fromAbi: WindowsFoundation.IInspectable) {
|
|
super.init(fromAbi)
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.videodisplayproperties.subtitle)
|
|
public var subtitle : String {
|
|
get { try! _default.get_SubtitleImpl() }
|
|
set { try! _default.put_SubtitleImpl(newValue) }
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.videodisplayproperties.title)
|
|
public var title : String {
|
|
get { try! _default.get_TitleImpl() }
|
|
set { try! _default.put_TitleImpl(newValue) }
|
|
}
|
|
|
|
private lazy var _IVideoDisplayProperties2: __ABI_Windows_Media.IVideoDisplayProperties2! = getInterfaceForCaching()
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.videodisplayproperties.genres)
|
|
public var genres : WindowsFoundation.AnyIVector<String>! {
|
|
get { try! _IVideoDisplayProperties2.get_GenresImpl() }
|
|
}
|
|
|
|
deinit {
|
|
_default = nil
|
|
_IVideoDisplayProperties2 = nil
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimerange)
|
|
public struct MediaTimeRange: Hashable, Codable {
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimerange.start)
|
|
public var start: WindowsFoundation.TimeSpan = .init()
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.mediatimerange.end)
|
|
public var end: WindowsFoundation.TimeSpan = .init()
|
|
public init() {}
|
|
public init(start: WindowsFoundation.TimeSpan, end: WindowsFoundation.TimeSpan) {
|
|
self.start = start
|
|
self.end = end
|
|
}
|
|
public static func from(abi: __x_ABI_CWindows_CMedia_CMediaTimeRange) -> MediaTimeRange {
|
|
.init(start: .from(abi: abi.Start), end: .from(abi: abi.End))
|
|
}
|
|
}
|
|
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe)
|
|
public protocol IMediaFrame : WindowsFoundation.IClosable {
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.duration)
|
|
var duration: WindowsFoundation.TimeSpan? { get set }
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.extendedproperties)
|
|
var extendedProperties: WindowsFoundation.AnyIPropertySet! { get }
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.isdiscontinuous)
|
|
var isDiscontinuous: Bool { get set }
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.isreadonly)
|
|
var isReadOnly: Bool { get }
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.relativetime)
|
|
var relativeTime: WindowsFoundation.TimeSpan? { get set }
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.systemrelativetime)
|
|
var systemRelativeTime: WindowsFoundation.TimeSpan? { get set }
|
|
/// [Open Microsoft documentation](https://learn.microsoft.com/uwp/api/windows.media.imediaframe.type)
|
|
var type: String { get }
|
|
}
|
|
|
|
extension IMediaFrame {
|
|
public func queryInterface(_ iid: WindowsFoundation.IID) -> IUnknownRef? {
|
|
switch iid {
|
|
case __ABI_Windows_Media.IMediaFrameWrapper.IID:
|
|
let wrapper = __ABI_Windows_Media.IMediaFrameWrapper(self)
|
|
return wrapper!.queryInterface(iid)
|
|
case __ABI_Windows_Foundation.IClosableWrapper.IID:
|
|
let wrapper = __ABI_Windows_Foundation.IClosableWrapper(self)
|
|
return wrapper!.queryInterface(iid)
|
|
default: return nil
|
|
}
|
|
}
|
|
}
|
|
public typealias AnyIMediaFrame = any IMediaFrame
|
|
|
|
extension UWP.AudioBufferAccessMode {
|
|
public static var read : UWP.AudioBufferAccessMode {
|
|
__x_ABI_CWindows_CMedia_CAudioBufferAccessMode_Read
|
|
}
|
|
public static var readWrite : UWP.AudioBufferAccessMode {
|
|
__x_ABI_CWindows_CMedia_CAudioBufferAccessMode_ReadWrite
|
|
}
|
|
public static var write : UWP.AudioBufferAccessMode {
|
|
__x_ABI_CWindows_CMedia_CAudioBufferAccessMode_Write
|
|
}
|
|
}
|
|
extension UWP.AudioBufferAccessMode: @retroactive Hashable, @retroactive Codable {}
|
|
|
|
extension UWP.AudioProcessing {
|
|
public static var `default` : UWP.AudioProcessing {
|
|
__x_ABI_CWindows_CMedia_CAudioProcessing_Default
|
|
}
|
|
public static var raw : UWP.AudioProcessing {
|
|
__x_ABI_CWindows_CMedia_CAudioProcessing_Raw
|
|
}
|
|
}
|
|
extension UWP.AudioProcessing: @retroactive Hashable, @retroactive Codable {}
|
|
|
|
extension UWP.MediaPlaybackAutoRepeatMode {
|
|
public static var none : UWP.MediaPlaybackAutoRepeatMode {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackAutoRepeatMode_None
|
|
}
|
|
public static var track : UWP.MediaPlaybackAutoRepeatMode {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackAutoRepeatMode_Track
|
|
}
|
|
public static var list : UWP.MediaPlaybackAutoRepeatMode {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackAutoRepeatMode_List
|
|
}
|
|
}
|
|
extension UWP.MediaPlaybackAutoRepeatMode: @retroactive Hashable, @retroactive Codable {}
|
|
|
|
extension UWP.MediaPlaybackStatus {
|
|
public static var closed : UWP.MediaPlaybackStatus {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackStatus_Closed
|
|
}
|
|
public static var changing : UWP.MediaPlaybackStatus {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackStatus_Changing
|
|
}
|
|
public static var stopped : UWP.MediaPlaybackStatus {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackStatus_Stopped
|
|
}
|
|
public static var playing : UWP.MediaPlaybackStatus {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackStatus_Playing
|
|
}
|
|
public static var paused : UWP.MediaPlaybackStatus {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackStatus_Paused
|
|
}
|
|
}
|
|
extension UWP.MediaPlaybackStatus: @retroactive Hashable, @retroactive Codable {}
|
|
|
|
extension UWP.MediaPlaybackType {
|
|
public static var unknown : UWP.MediaPlaybackType {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackType_Unknown
|
|
}
|
|
public static var music : UWP.MediaPlaybackType {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackType_Music
|
|
}
|
|
public static var video : UWP.MediaPlaybackType {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackType_Video
|
|
}
|
|
public static var image : UWP.MediaPlaybackType {
|
|
__x_ABI_CWindows_CMedia_CMediaPlaybackType_Image
|
|
}
|
|
}
|
|
extension UWP.MediaPlaybackType: @retroactive Hashable, @retroactive Codable {}
|
|
|
|
extension UWP.MediaTimelineControllerState {
|
|
public static var paused : UWP.MediaTimelineControllerState {
|
|
__x_ABI_CWindows_CMedia_CMediaTimelineControllerState_Paused
|
|
}
|
|
public static var running : UWP.MediaTimelineControllerState {
|
|
__x_ABI_CWindows_CMedia_CMediaTimelineControllerState_Running
|
|
}
|
|
public static var stalled : UWP.MediaTimelineControllerState {
|
|
__x_ABI_CWindows_CMedia_CMediaTimelineControllerState_Stalled
|
|
}
|
|
public static var error : UWP.MediaTimelineControllerState {
|
|
__x_ABI_CWindows_CMedia_CMediaTimelineControllerState_Error
|
|
}
|
|
}
|
|
extension UWP.MediaTimelineControllerState: @retroactive Hashable, @retroactive Codable {}
|
|
|
|
extension UWP.SoundLevel {
|
|
public static var muted : UWP.SoundLevel {
|
|
__x_ABI_CWindows_CMedia_CSoundLevel_Muted
|
|
}
|
|
public static var low : UWP.SoundLevel {
|
|
__x_ABI_CWindows_CMedia_CSoundLevel_Low
|
|
}
|
|
public static var full : UWP.SoundLevel {
|
|
__x_ABI_CWindows_CMedia_CSoundLevel_Full
|
|
}
|
|
}
|
|
extension UWP.SoundLevel: @retroactive Hashable, @retroactive Codable {}
|
|
|
|
extension UWP.SystemMediaTransportControlsButton {
|
|
public static var play : UWP.SystemMediaTransportControlsButton {
|
|
__x_ABI_CWindows_CMedia_CSystemMediaTransportControlsButton_Play
|
|
}
|
|
public static var pause : UWP.SystemMediaTransportControlsButton {
|
|
__x_ABI_CWindows_CMedia_CSystemMediaTransportControlsButton_Pause
|
|
}
|
|
public static var stop : UWP.SystemMediaTransportControlsButton {
|
|
__x_ABI_CWindows_CMedia_CSystemMediaTransportControlsButton_Stop
|
|
}
|
|
public static var record : UWP.SystemMediaTransportControlsButton {
|
|
__x_ABI_CWindows_CMedia_CSystemMediaTransportControlsButton_Record
|
|
}
|
|
public static var fastForward : UWP.SystemMediaTransportControlsButton {
|
|
__x_ABI_CWindows_CMedia_CSystemMediaTransportControlsButton_FastForward
|
|
}
|
|
public static var rewind : UWP.SystemMediaTransportControlsButton {
|
|
__x_ABI_CWindows_CMedia_CSystemMediaTransportControlsButton_Rewind
|
|
}
|
|
public static var next : UWP.SystemMediaTransportControlsButton {
|
|
__x_ABI_CWindows_CMedia_CSystemMediaTransportControlsButton_Next
|
|
}
|
|
public static var previous : UWP.SystemMediaTransportControlsButton {
|
|
__x_ABI_CWindows_CMedia_CSystemMediaTransportControlsButton_Previous
|
|
}
|
|
public static var channelUp : UWP.SystemMediaTransportControlsButton {
|
|
__x_ABI_CWindows_CMedia_CSystemMediaTransportControlsButton_ChannelUp
|
|
}
|
|
public static var channelDown : UWP.SystemMediaTransportControlsButton {
|
|
__x_ABI_CWindows_CMedia_CSystemMediaTransportControlsButton_ChannelDown
|
|
}
|
|
}
|
|
extension UWP.SystemMediaTransportControlsButton: @retroactive Hashable, @retroactive Codable {}
|
|
|
|
extension UWP.SystemMediaTransportControlsProperty {
|
|
public static var soundLevel : UWP.SystemMediaTransportControlsProperty {
|
|
__x_ABI_CWindows_CMedia_CSystemMediaTransportControlsProperty_SoundLevel
|
|
}
|
|
}
|
|
extension UWP.SystemMediaTransportControlsProperty: @retroactive Hashable, @retroactive Codable {}
|
|
|