// 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 UWP @_spi(WinRTInternal) @_spi(WinRTImplements) import WindowsFoundation import CWinRT public enum __IMPL_Microsoft_UI_Composition_SystemBackdrops { public enum ISystemBackdropControllerBridge : AbiInterfaceBridge { public typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropController public typealias SwiftABI = __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropController public typealias SwiftProjection = AnyISystemBackdropController public static func from(abi: ComPtr?) -> SwiftProjection? { guard let abi = abi else { return nil } return ISystemBackdropControllerImpl(abi) } public static func makeAbi() -> CABI { let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerVTable) { $0 } return .init(lpVtbl: vtblPtr) } } fileprivate class ISystemBackdropControllerImpl: ISystemBackdropController, WinRTAbiImpl { fileprivate typealias Bridge = ISystemBackdropControllerBridge fileprivate let _default: Bridge.SwiftABI fileprivate var thisPtr: WindowsFoundation.IInspectable { _default } fileprivate init(_ fromAbi: ComPtr) { _default = Bridge.SwiftABI(fromAbi) } /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontroller.settarget) fileprivate func setTarget(_ windowId: WinAppSDK.WindowId, _ desktopWindowTarget: UWP.CompositionTarget!) throws -> Bool { try _default.SetTargetWithWindowIdImpl(windowId, desktopWindowTarget) } /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontroller.settarget) fileprivate func setTarget(_ coreWindow: UWP.CoreWindow!, _ compositionTarget: UWP.CompositionTarget!) throws -> Bool { try _default.SetTargetWithCoreWindowImpl(coreWindow, compositionTarget) } private lazy var _IClosable: __ABI_Windows_Foundation.IClosable! = getInterfaceForCaching() /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontroller.close) fileprivate func close() throws { try _IClosable.CloseImpl() } } public enum ISystemBackdropControllerWithTargetsBridge : AbiInterfaceBridge { public typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerWithTargets public typealias SwiftABI = __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWithTargets public typealias SwiftProjection = AnyISystemBackdropControllerWithTargets public static func from(abi: ComPtr?) -> SwiftProjection? { guard let abi = abi else { return nil } return ISystemBackdropControllerWithTargetsImpl(abi) } public static func makeAbi() -> CABI { let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWithTargetsVTable) { $0 } return .init(lpVtbl: vtblPtr) } } fileprivate class ISystemBackdropControllerWithTargetsImpl: ISystemBackdropControllerWithTargets, WinRTAbiImpl { fileprivate typealias Bridge = ISystemBackdropControllerWithTargetsBridge fileprivate let _default: Bridge.SwiftABI fileprivate var thisPtr: WindowsFoundation.IInspectable { _default } fileprivate init(_ fromAbi: ComPtr) { _default = Bridge.SwiftABI(fromAbi) } /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.addsystembackdroptarget) fileprivate func addSystemBackdropTarget(_ systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop!) throws -> Bool { try _default.AddSystemBackdropTargetImpl(systemBackdropTarget) } /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.removeallsystembackdroptargets) fileprivate func removeAllSystemBackdropTargets() throws { try _default.RemoveAllSystemBackdropTargetsImpl() } /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.removesystembackdroptarget) fileprivate func removeSystemBackdropTarget(_ systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop!) throws -> Bool { try _default.RemoveSystemBackdropTargetImpl(systemBackdropTarget) } /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.setsystembackdropconfiguration) fileprivate func setSystemBackdropConfiguration(_ configuration: SystemBackdropConfiguration!) throws { try _default.SetSystemBackdropConfigurationImpl(configuration) } /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.state) fileprivate var state : SystemBackdropState { get { try! _default.get_StateImpl() } } /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.statechanged) fileprivate lazy var stateChanged : Event> = { .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 _IClosable: __ABI_Windows_Foundation.IClosable! = getInterfaceForCaching() /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.close) fileprivate func close() throws { try _IClosable.CloseImpl() } private lazy var _ISystemBackdropController: __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropController! = getInterfaceForCaching() /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.settarget) fileprivate func setTarget(_ windowId: WinAppSDK.WindowId, _ desktopWindowTarget: UWP.CompositionTarget!) throws -> Bool { try _ISystemBackdropController.SetTargetWithWindowIdImpl(windowId, desktopWindowTarget) } /// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.settarget) fileprivate func setTarget(_ coreWindow: UWP.CoreWindow!, _ compositionTarget: UWP.CompositionTarget!) throws -> Bool { try _ISystemBackdropController.SetTargetWithCoreWindowImpl(coreWindow, compositionTarget) } } }