Initial commit
This commit is contained in:
commit
518113b422
95
.gitignore
vendored
Normal file
95
.gitignore
vendored
Normal file
@ -0,0 +1,95 @@
|
|||||||
|
# Xcode
|
||||||
|
#
|
||||||
|
# gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore
|
||||||
|
|
||||||
|
## User settings
|
||||||
|
xcuserdata/
|
||||||
|
|
||||||
|
## compatibility with Xcode 8 and earlier (ignoring not required starting Xcode 9)
|
||||||
|
*.xcscmblueprint
|
||||||
|
*.xccheckout
|
||||||
|
|
||||||
|
## compatibility with Xcode 3 and earlier (ignoring not required starting Xcode 4)
|
||||||
|
build/
|
||||||
|
DerivedData/
|
||||||
|
*.moved-aside
|
||||||
|
*.pbxuser
|
||||||
|
!default.pbxuser
|
||||||
|
*.mode1v3
|
||||||
|
!default.mode1v3
|
||||||
|
*.mode2v3
|
||||||
|
!default.mode2v3
|
||||||
|
*.perspectivev3
|
||||||
|
!default.perspectivev3
|
||||||
|
|
||||||
|
## Obj-C/Swift specific
|
||||||
|
*.hmap
|
||||||
|
|
||||||
|
## App packaging
|
||||||
|
*.ipa
|
||||||
|
*.dSYM.zip
|
||||||
|
*.dSYM
|
||||||
|
|
||||||
|
## Playgrounds
|
||||||
|
timeline.xctimeline
|
||||||
|
playground.xcworkspace
|
||||||
|
|
||||||
|
# Swift Package Manager
|
||||||
|
#
|
||||||
|
# Add this line if you want to avoid checking in source code from Swift Package Manager dependencies.
|
||||||
|
# Packages/
|
||||||
|
# Package.pins
|
||||||
|
# Package.resolved
|
||||||
|
# *.xcodeproj
|
||||||
|
#
|
||||||
|
# Xcode automatically generates this directory with a .xcworkspacedata file and xcuserdata
|
||||||
|
# hence it is not needed unless you have added a package configuration file to your project
|
||||||
|
# .swiftpm
|
||||||
|
|
||||||
|
.build/
|
||||||
|
|
||||||
|
# CocoaPods
|
||||||
|
#
|
||||||
|
# We recommend against adding the Pods directory to your .gitignore. However
|
||||||
|
# you should judge for yourself, the pros and cons are mentioned at:
|
||||||
|
# https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control
|
||||||
|
#
|
||||||
|
# Pods/
|
||||||
|
#
|
||||||
|
# Add this line if you want to avoid checking in source code from the Xcode workspace
|
||||||
|
# *.xcworkspace
|
||||||
|
|
||||||
|
# Carthage
|
||||||
|
#
|
||||||
|
# Add this line if you want to avoid checking in source code from Carthage dependencies.
|
||||||
|
# Carthage/Checkouts
|
||||||
|
|
||||||
|
Carthage/Build/
|
||||||
|
|
||||||
|
# Accio dependency management
|
||||||
|
Dependencies/
|
||||||
|
.accio/
|
||||||
|
|
||||||
|
# fastlane
|
||||||
|
#
|
||||||
|
# It is recommended to not store the screenshots in the git repo.
|
||||||
|
# Instead, use fastlane to re-generate the screenshots whenever they are needed.
|
||||||
|
# For more information about the recommended setup visit:
|
||||||
|
# https://docs.fastlane.tools/best-practices/source-control/#source-control
|
||||||
|
|
||||||
|
fastlane/report.xml
|
||||||
|
fastlane/Preview.html
|
||||||
|
fastlane/screenshots/**/*.png
|
||||||
|
fastlane/test_output
|
||||||
|
|
||||||
|
# Code Injection
|
||||||
|
#
|
||||||
|
# After new code Injection tools there's a generated folder /iOSInjectionProject
|
||||||
|
# https://github.com/johnno1962/injectionforxcode
|
||||||
|
|
||||||
|
iOSInjectionProject/
|
||||||
|
|
||||||
|
.packages
|
||||||
|
.generated
|
||||||
|
swift-winrt.rsp
|
||||||
|
Package.resolved
|
||||||
11
.vscode/tasks.json
vendored
Normal file
11
.vscode/tasks.json
vendored
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
{
|
||||||
|
"version": "2.0.0",
|
||||||
|
"tasks": [
|
||||||
|
{
|
||||||
|
"type": "shell",
|
||||||
|
"label": "Generate swift-windowsappsdk bindings",
|
||||||
|
"command": "${workspaceFolder:swift-windowsappsdk}/generate-bindings.ps1",
|
||||||
|
"problemMatcher": []
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
29
LICENSE
Normal file
29
LICENSE
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
BSD 3-Clause License
|
||||||
|
|
||||||
|
Copyright (c) 2024, The Browser Company
|
||||||
|
All rights reserved.
|
||||||
|
|
||||||
|
Redistribution and use in source and binary forms, with or without
|
||||||
|
modification, are permitted provided that the following conditions are met:
|
||||||
|
|
||||||
|
1. Redistributions of source code must retain the above copyright notice, this
|
||||||
|
list of conditions and the following disclaimer.
|
||||||
|
|
||||||
|
2. Redistributions in binary form must reproduce the above copyright notice,
|
||||||
|
this list of conditions and the following disclaimer in the documentation
|
||||||
|
and/or other materials provided with the distribution.
|
||||||
|
|
||||||
|
3. Neither the name of the copyright holder nor the names of its
|
||||||
|
contributors may be used to endorse or promote products derived from
|
||||||
|
this software without specific prior written permission.
|
||||||
|
|
||||||
|
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||||
|
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||||
|
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||||
|
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||||
|
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||||
|
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||||
|
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||||
|
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||||
|
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||||
|
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
50
Package.swift
Normal file
50
Package.swift
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
// swift-tools-version: 5.10
|
||||||
|
|
||||||
|
import PackageDescription
|
||||||
|
import Foundation
|
||||||
|
|
||||||
|
let currentDirectory = Context.packageDirectory
|
||||||
|
|
||||||
|
let linkerSettings: [LinkerSetting] = [
|
||||||
|
/* Figure out magic incantation so we can delay load these dlls
|
||||||
|
.unsafeFlags(["-L\(currentDirectory)/Sources/CWinAppSDK/nuget/lib"]),
|
||||||
|
.unsafeFlags(["-Xlinker" , "/DELAYLOAD:Microsoft.WindowsAppRuntime.Bootstrap.dll"]),
|
||||||
|
*/
|
||||||
|
]
|
||||||
|
|
||||||
|
let package = Package(
|
||||||
|
name: "swift-windowsappsdk",
|
||||||
|
products: [
|
||||||
|
.library(name: "WinAppSDK", type: .dynamic, targets: ["WinAppSDK"]),
|
||||||
|
.library(name: "CWinAppSDK", targets: ["CWinAppSDK"]),
|
||||||
|
],
|
||||||
|
dependencies: [
|
||||||
|
.package(url: "https://github.com/thebrowsercompany/swift-cwinrt", branch: "main"),
|
||||||
|
.package(url: "https://github.com/thebrowsercompany/swift-uwp", branch: "main"),
|
||||||
|
.package(url: "https://github.com/thebrowsercompany/swift-windowsfoundation", branch: "main"),
|
||||||
|
],
|
||||||
|
targets: [
|
||||||
|
.target(
|
||||||
|
name: "WinAppSDK",
|
||||||
|
dependencies: [
|
||||||
|
.product(name: "CWinRT", package: "swift-cwinrt"),
|
||||||
|
.product(name: "UWP", package: "swift-uwp"),
|
||||||
|
.product(name: "WindowsFoundation", package: "swift-windowsfoundation"),
|
||||||
|
"CWinAppSDK"
|
||||||
|
]
|
||||||
|
),
|
||||||
|
.target(
|
||||||
|
name: "CWinAppSDK",
|
||||||
|
resources: [
|
||||||
|
.copy("nuget/bin/Microsoft.WindowsAppRuntime.Bootstrap.dll"),
|
||||||
|
],
|
||||||
|
linkerSettings: linkerSettings
|
||||||
|
),
|
||||||
|
.testTarget(
|
||||||
|
name: "WinAppSDKTests",
|
||||||
|
dependencies: [
|
||||||
|
"WinAppSDK",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
]
|
||||||
|
)
|
||||||
31
README.md
Normal file
31
README.md
Normal file
@ -0,0 +1,31 @@
|
|||||||
|
# swift-windowsappsdk
|
||||||
|
Swift Language Bindings for the Windows App SDK APIs
|
||||||
|
|
||||||
|
These APIs are intendened to be used in conjuction with the following projects:
|
||||||
|
- [swift-winui](https://github.com/thebrowsercompany/swift-winui)
|
||||||
|
- [swift-win2d](https://github.com/thebrowsercompany/swift-win2d)
|
||||||
|
|
||||||
|
## APIs
|
||||||
|
These projections contains a subset of APIs for the Windows App SDK, minus those of WinUI (`Microsoft.UI.Xaml`). See official documentation for more information on these components:
|
||||||
|
|
||||||
|
- [API Docs](https://learn.microsoft.com/en-us/windows/windows-app-sdk/api/winrt/)
|
||||||
|
- [Official GitHub repo](https://github.com/microsoft/WindowsAppSDK)
|
||||||
|
|
||||||
|
### SDK Versions
|
||||||
|
|
||||||
|
1. Windows SDK: `10.0.18362.0`
|
||||||
|
2. Windows App SDK: `1.5-preview1`
|
||||||
|
|
||||||
|
## Project Configuration
|
||||||
|
The bindings are generated from WinMD files, found in NuGet packages on Nuget.org. There are two key files which drive this:
|
||||||
|
1. projections.json - this specifies the project/package and which apis to include in the projection
|
||||||
|
2. generate-bindings.ps1 - this file reads `projections.json` and generates the appropriate bindings.
|
||||||
|
|
||||||
|
## Filing Issues
|
||||||
|
|
||||||
|
Please file any issues you have with this repository on https://github.com/thebrowsercompany/swift-winrt
|
||||||
|
|
||||||
|
## Known Issues and Limitations
|
||||||
|
- The developer experience for consuming WinRT APIs from Swift is a work in progress. Due to current limitations, not all APIs can be generated as this causes export limit issues.
|
||||||
|
|
||||||
|
- The APIs listed in projections.json are required for the other `swift-*` projects to build. Modify a projections.json in any one of those projects could require an update here.
|
||||||
26
Sources/CWinAppSDK/delayloadhelper.c
Normal file
26
Sources/CWinAppSDK/delayloadhelper.c
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
#include <wtypesbase.h>
|
||||||
|
#include <minwindef.h>
|
||||||
|
#include <winnt.h>
|
||||||
|
#include "delayimp.h"
|
||||||
|
#include <stdio.h>
|
||||||
|
|
||||||
|
FARPROC WINAPI delayHook(unsigned dliNotify, PDelayLoadInfo pdli)
|
||||||
|
{
|
||||||
|
switch (dliNotify) {
|
||||||
|
case dliFailLoadLib :
|
||||||
|
printf("dliFailLoadLib: %s\n", pdli->szDll);
|
||||||
|
if (strcmp(pdli->szDll, "Microsoft.WindowsAppRuntime.Boostrap.dll") == 0) {
|
||||||
|
return (FARPROC)LoadLibraryW(L"swift-windowsappsdk_CWinAppSDK.resources\\Microsoft.WindowsAppRuntime.Bootstrap.dll");
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
|
||||||
|
default :
|
||||||
|
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
const PfnDliHook __pfnDliNotifyHook2 = delayHook;
|
||||||
|
const PfnDliHook __pfnDliFailureHook2 = delayHook;
|
||||||
16
Sources/CWinAppSDK/include/CWinAppSDK-Bridging-Header.h
Normal file
16
Sources/CWinAppSDK/include/CWinAppSDK-Bridging-Header.h
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
#include <wtypesbase.h>
|
||||||
|
#include <minwindef.h>
|
||||||
|
#include <winnt.h>
|
||||||
|
#include <combaseapi.h>
|
||||||
|
|
||||||
|
#include <roapi.h>
|
||||||
|
#include <winstring.h>
|
||||||
|
#include "stdlib.h"
|
||||||
|
|
||||||
|
// Headers are placed in a seperate directory because we only want to expose
|
||||||
|
// those which we know compile and work with Swift.
|
||||||
|
#include <../nuget/include/MddBootstrap.h>
|
||||||
|
#include <../nuget/include/WindowsAppSDK-VersionInfo.h>
|
||||||
|
|
||||||
|
// re-define the string to make it visible in Swift. (#define only supports numbers & strings)
|
||||||
|
static PCWSTR WINDOWSAPPSDK_RELEASE_VERSION_TAG_SWIFT = WINDOWSAPPSDK_RELEASE_VERSION_TAG_W;
|
||||||
7
Sources/CWinAppSDK/include/module.modulemap
Normal file
7
Sources/CWinAppSDK/include/module.modulemap
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
module CWinAppSDK {
|
||||||
|
header "CWinAppSDK-Bridging-Header.h"
|
||||||
|
// Don't actually link since we can't get delay loading to work. These DLLs are loaded manually via LoadLibrary/GetProcAddress
|
||||||
|
//link "Microsoft.WindowsAppRuntime.Bootstrap"
|
||||||
|
//link "delayimp"
|
||||||
|
export *
|
||||||
|
}
|
||||||
Binary file not shown.
133
Sources/CWinAppSDK/nuget/include/MRM.h
Normal file
133
Sources/CWinAppSDK/nuget/include/MRM.h
Normal file
@ -0,0 +1,133 @@
|
|||||||
|
// Copyright (c) Microsoft Corporation and Contributors.
|
||||||
|
// Licensed under the MIT License.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C"
|
||||||
|
{
|
||||||
|
#endif
|
||||||
|
|
||||||
|
DECLARE_HANDLE(MrmManagerHandle);
|
||||||
|
DECLARE_HANDLE(MrmContextHandle);
|
||||||
|
DECLARE_HANDLE(MrmMapHandle);
|
||||||
|
|
||||||
|
enum MrmType
|
||||||
|
{
|
||||||
|
MrmType_Unknown,
|
||||||
|
MrmType_String,
|
||||||
|
MrmType_Path,
|
||||||
|
MrmType_Embedded
|
||||||
|
};
|
||||||
|
|
||||||
|
struct MrmResourceData
|
||||||
|
{
|
||||||
|
UINT32 size;
|
||||||
|
void* data;
|
||||||
|
};
|
||||||
|
|
||||||
|
STDAPI MrmCreateResourceManager(_In_ PCWSTR priFileName, _Out_ MrmManagerHandle* resourceManager);
|
||||||
|
STDAPI_(void) MrmDestroyResourceManager(_In_opt_ MrmManagerHandle resourceManager);
|
||||||
|
|
||||||
|
STDAPI MrmCreateResourceContext(_In_ MrmManagerHandle resourceManager, _Out_ MrmContextHandle* resourceContext);
|
||||||
|
STDAPI_(void) MrmFreeQualifierNamesOrValues(UINT32 size, _In_reads_(size) PWSTR* names);
|
||||||
|
STDAPI MrmGetAllQualifierNames(_In_ MrmContextHandle resourceContext, _Out_ UINT32* size, _Outptr_result_buffer_(*size) PWSTR** names);
|
||||||
|
STDAPI MrmGetQualifier(_In_ MrmContextHandle resourceContext, _In_ PCWSTR qualifierName, _Outptr_ PWSTR* qualifierValue);
|
||||||
|
STDAPI MrmSetQualifier(_In_ MrmContextHandle resourceContext, _In_ PCWSTR qualifierName, _In_ PCWSTR qualifierValue);
|
||||||
|
STDAPI_(void) MrmDestroyResourceContext(_In_opt_ MrmContextHandle resourceContext);
|
||||||
|
|
||||||
|
// Resource maps are owned by the resource manager and so do not need to be destroyed.
|
||||||
|
STDAPI MrmGetChildResourceMap(
|
||||||
|
_In_ MrmManagerHandle resourceManager,
|
||||||
|
_In_opt_ MrmMapHandle resourceMap,
|
||||||
|
_In_ PCWSTR childResourceMapName,
|
||||||
|
_Out_ MrmMapHandle* childResourceMap);
|
||||||
|
|
||||||
|
STDAPI MrmGetResourceCount(_In_ MrmManagerHandle resourceManager, _In_opt_ MrmMapHandle resourceMap, _Out_ UINT32* count);
|
||||||
|
|
||||||
|
STDAPI MrmLoadStringResource(
|
||||||
|
_In_ MrmManagerHandle resourceManager,
|
||||||
|
_In_opt_ MrmContextHandle resourceContext,
|
||||||
|
_In_opt_ MrmMapHandle resourceMap,
|
||||||
|
_In_ PCWSTR resourceId,
|
||||||
|
_Outptr_ PWSTR* resourceString);
|
||||||
|
|
||||||
|
STDAPI MrmLoadStringResourceFromResourceUri(
|
||||||
|
_In_ MrmManagerHandle resourceManager,
|
||||||
|
_In_opt_ MrmContextHandle resourceContext,
|
||||||
|
_In_ PCWSTR resourceUri,
|
||||||
|
_Outptr_ PWSTR* resourceString);
|
||||||
|
|
||||||
|
STDAPI MrmLoadEmbeddedResource(
|
||||||
|
_In_ MrmManagerHandle resourceManager,
|
||||||
|
_In_opt_ MrmContextHandle resourceContext,
|
||||||
|
_In_opt_ MrmMapHandle resourceMap,
|
||||||
|
_In_ PCWSTR resourceId,
|
||||||
|
_Out_ MrmResourceData* data);
|
||||||
|
|
||||||
|
STDAPI MrmLoadEmbeddedResourceFromResourceUri(
|
||||||
|
_In_ MrmManagerHandle resourceManager,
|
||||||
|
_In_opt_ MrmContextHandle resourceContext,
|
||||||
|
_In_ PCWSTR resourceUri,
|
||||||
|
_Out_ MrmResourceData* data);
|
||||||
|
|
||||||
|
STDAPI MrmLoadStringOrEmbeddedResource(
|
||||||
|
_In_ MrmManagerHandle resourceManager,
|
||||||
|
_In_opt_ MrmContextHandle resourceContext,
|
||||||
|
_In_opt_ MrmMapHandle resourceMap,
|
||||||
|
_In_ PCWSTR resourceId,
|
||||||
|
_Out_ MrmType* resourceType,
|
||||||
|
_Outptr_result_maybenull_ PWSTR* resourceString,
|
||||||
|
_Out_ MrmResourceData* data);
|
||||||
|
|
||||||
|
STDAPI MrmLoadStringOrEmbeddedResourceWithQualifierValues(
|
||||||
|
_In_ MrmManagerHandle resourceManager,
|
||||||
|
_In_opt_ MrmContextHandle resourceContext,
|
||||||
|
_In_opt_ MrmMapHandle resourceMap,
|
||||||
|
_In_ PCWSTR resourceId,
|
||||||
|
_Out_ MrmType* resourceType,
|
||||||
|
_Outptr_result_maybenull_ PWSTR* resourceString,
|
||||||
|
_Out_ MrmResourceData* data,
|
||||||
|
_Out_ UINT32* qualifierCount,
|
||||||
|
_Outptr_result_buffer_(*qualifierCount) PWSTR** qualifierNames,
|
||||||
|
_Outptr_result_buffer_(*qualifierCount) PWSTR** qualifierValues);
|
||||||
|
|
||||||
|
STDAPI MrmLoadStringOrEmbeddedFromResourceUri(
|
||||||
|
_In_ MrmManagerHandle resourceManager,
|
||||||
|
_In_opt_ MrmContextHandle resourceContext,
|
||||||
|
_In_ PCWSTR resourceUri,
|
||||||
|
_Out_ MrmType* resourceType,
|
||||||
|
_Outptr_result_maybenull_ PWSTR* resourceString,
|
||||||
|
_Out_ MrmResourceData* data);
|
||||||
|
|
||||||
|
STDAPI MrmLoadStringOrEmbeddedResourceByIndex(
|
||||||
|
_In_ MrmManagerHandle resourceManager,
|
||||||
|
_In_opt_ MrmContextHandle resourceContext,
|
||||||
|
_In_opt_ MrmMapHandle resourceMap,
|
||||||
|
UINT32 index,
|
||||||
|
_Out_ MrmType* resourceType,
|
||||||
|
_Outptr_ PWSTR* resourceName,
|
||||||
|
_Outptr_result_maybenull_ PWSTR* resourceString,
|
||||||
|
_Out_ MrmResourceData* data);
|
||||||
|
|
||||||
|
STDAPI MrmLoadStringOrEmbeddedResourceByIndexWithQualifierValues(
|
||||||
|
_In_ MrmManagerHandle resourceManager,
|
||||||
|
_In_opt_ MrmContextHandle resourceContext,
|
||||||
|
_In_opt_ MrmMapHandle resourceMap,
|
||||||
|
UINT32 index,
|
||||||
|
_Out_ MrmType* resourceType,
|
||||||
|
_Outptr_ PWSTR* resourceName,
|
||||||
|
_Outptr_result_maybenull_ PWSTR* resourceString,
|
||||||
|
_Out_ MrmResourceData* data,
|
||||||
|
_Out_ UINT32* qualifierCount,
|
||||||
|
_Outptr_result_buffer_(*qualifierCount) PWSTR** qualifierNames,
|
||||||
|
_Outptr_result_buffer_(*qualifierCount) PWSTR** qualifierValues);
|
||||||
|
|
||||||
|
STDAPI_(void*) MrmAllocateBuffer(size_t size);
|
||||||
|
STDAPI_(void) MrmFreeResource(_In_opt_ void* resource);
|
||||||
|
|
||||||
|
STDAPI MrmGetFilePathFromName(_In_opt_ PCWSTR filename, _Outptr_ PWSTR* filePath);
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
#endif
|
||||||
338
Sources/CWinAppSDK/nuget/include/MddBootstrap.h
Normal file
338
Sources/CWinAppSDK/nuget/include/MddBootstrap.h
Normal file
@ -0,0 +1,338 @@
|
|||||||
|
// Copyright (c) Microsoft Corporation and Contributors.
|
||||||
|
// Licensed under the MIT License.
|
||||||
|
|
||||||
|
#if !defined(MDDBOOTSTRAP_H)
|
||||||
|
#define MDDBOOTSTRAP_H
|
||||||
|
|
||||||
|
#include <appmodel.h>
|
||||||
|
|
||||||
|
#if defined(__cplusplus)
|
||||||
|
#define MDDBOOTSTRAP_NOEXCEPT noexcept
|
||||||
|
#else
|
||||||
|
#define MDDBOOTSTRAP_NOEXCEPT
|
||||||
|
#endif // defined(__cplusplus)
|
||||||
|
|
||||||
|
/// Options for Bootstrap initialization
|
||||||
|
typedef enum MddBootstrapInitializeOptions
|
||||||
|
{
|
||||||
|
/// Default behavior
|
||||||
|
MddBootstrapInitializeOptions_None = 0,
|
||||||
|
|
||||||
|
/// If not successful call DebugBreak()
|
||||||
|
MddBootstrapInitializeOptions_OnError_DebugBreak = 0x0001,
|
||||||
|
|
||||||
|
/// If not successful call DebugBreak() if a debugger is attached to the process
|
||||||
|
MddBootstrapInitializeOptions_OnError_DebugBreak_IfDebuggerAttached = 0x0002,
|
||||||
|
|
||||||
|
/// If not successful perform a fail-fast
|
||||||
|
MddBootstrapInitializeOptions_OnError_FailFast = 0x0004,
|
||||||
|
|
||||||
|
/// If a compatible Windows App Runtime framework package is not found show UI
|
||||||
|
MddBootstrapInitializeOptions_OnNoMatch_ShowUI = 0x0008,
|
||||||
|
|
||||||
|
/// Do nothing (do not error) if the process has package identity
|
||||||
|
MddBootstrapInitializeOptions_OnPackageIdentity_NOOP = 0x0010,
|
||||||
|
} MddBootstrapInitializeOptions;
|
||||||
|
#if defined(__cplusplus)
|
||||||
|
DEFINE_ENUM_FLAG_OPERATORS(MddBootstrapInitializeOptions)
|
||||||
|
#endif // defined(__cplusplus)
|
||||||
|
|
||||||
|
/// Initialize the calling process to use Windows App Runtime framework package.
|
||||||
|
///
|
||||||
|
/// Find a Windows App Runtime framework package meeting the criteria and make it available
|
||||||
|
/// for use by the current process. If multiple packages meet the criteria the best
|
||||||
|
/// candidate is selected.
|
||||||
|
///
|
||||||
|
/// If called multiple times the parameters must be compatible with the framework package
|
||||||
|
/// resolved by the first initialization call (i.e. the framework package currently in use).
|
||||||
|
/// If the request is not compatible with the framework package currently in use
|
||||||
|
/// the API fails and an error is returned.
|
||||||
|
///
|
||||||
|
/// @param majorMinorVersion the major and minor version to use, e..g 0x00010002 for Major.Minor=1.2
|
||||||
|
/// @param versionTag the version pre-release identifier, or NULL if none.
|
||||||
|
/// @param minVersion the minimum version to use
|
||||||
|
STDAPI MddBootstrapInitialize(
|
||||||
|
UINT32 majorMinorVersion,
|
||||||
|
PCWSTR versionTag,
|
||||||
|
PACKAGE_VERSION minVersion) MDDBOOTSTRAP_NOEXCEPT;
|
||||||
|
|
||||||
|
/// Initialize the calling process to use Windows App Runtime framework package.
|
||||||
|
///
|
||||||
|
/// Find a Windows App Runtime framework package meeting the criteria and make it available
|
||||||
|
/// for use by the current process. If multiple packages meet the criteria the best
|
||||||
|
/// candidate is selected.
|
||||||
|
///
|
||||||
|
/// If called multiple times the parameters must be compatible with the framework package
|
||||||
|
/// resolved by the first initialization call (i.e. the framework package currently in use).
|
||||||
|
/// If the request is not compatible with the framework package currently in use
|
||||||
|
/// the API fails and an error is returned.
|
||||||
|
///
|
||||||
|
/// @param majorMinorVersion the major and minor version to use, e..g 0x00010002 for Major.Minor=1.2
|
||||||
|
/// @param versionTag the version pre-release identifier, or NULL if none.
|
||||||
|
/// @param minVersion the minimum version to use
|
||||||
|
STDAPI MddBootstrapInitialize2(
|
||||||
|
UINT32 majorMinorVersion,
|
||||||
|
PCWSTR versionTag,
|
||||||
|
PACKAGE_VERSION minVersion,
|
||||||
|
MddBootstrapInitializeOptions options) MDDBOOTSTRAP_NOEXCEPT;
|
||||||
|
|
||||||
|
/// Undo the changes made by MddBoostrapInitialize().
|
||||||
|
///
|
||||||
|
/// @warning Packages made available via MddBootstrapInitialize2() and
|
||||||
|
/// the Dynamic Dependencies API should not be used after this call.
|
||||||
|
STDAPI_(void) MddBootstrapShutdown() MDDBOOTSTRAP_NOEXCEPT;
|
||||||
|
|
||||||
|
// C++ friendly APIs
|
||||||
|
#if defined(__cplusplus)
|
||||||
|
#if defined(WINDOWSAPPSDK_RELEASE_MAJORMINOR) && defined(WINDOWSAPPSDK_RELEASE_VERSION_TAG_W) && defined(WINDOWSAPPSDK_RUNTIME_VERSION_UINT64)
|
||||||
|
|
||||||
|
#include <memory>
|
||||||
|
#include <stdint.h>
|
||||||
|
|
||||||
|
namespace Microsoft::Windows::ApplicationModel
|
||||||
|
{
|
||||||
|
class PackageVersion : public PACKAGE_VERSION
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
PackageVersion()
|
||||||
|
{
|
||||||
|
Version = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Create an instance with the value `major.minor.build.revision`.
|
||||||
|
PackageVersion(uint16_t major, uint16_t minor = 0, uint16_t build = 0, uint16_t revision = 0) :
|
||||||
|
PACKAGE_VERSION()
|
||||||
|
{
|
||||||
|
Major = major;
|
||||||
|
Minor = minor;
|
||||||
|
Build = build;
|
||||||
|
Revision = revision;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Create an instance from a version as a uint64.
|
||||||
|
PackageVersion(uint64_t version)
|
||||||
|
{
|
||||||
|
Version = version;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Return the version as a uint64.
|
||||||
|
uint64_t ToVersion() const
|
||||||
|
{
|
||||||
|
return Version;
|
||||||
|
}
|
||||||
|
|
||||||
|
#if defined(_XSTRING_) && defined(_STRSAFE_H_INCLUDED_) && defined(WI_VERIFY)
|
||||||
|
// Return the string as a formatted value "major.minor.build.revision".
|
||||||
|
std::wstring ToString() const
|
||||||
|
{
|
||||||
|
return ToString(Major, Minor, Build, Revision);
|
||||||
|
}
|
||||||
|
|
||||||
|
static std::wstring ToString(uint16_t major, uint16_t minor, uint16_t build, uint16_t revision)
|
||||||
|
{
|
||||||
|
wchar_t formattedVersion[5 + 1 + 5 + 1 + 5 + 1 + 5 + 1]{}; // "12345.12345.12345.12345" + null-terminator
|
||||||
|
WI_VERIFY(SUCCEEDED(StringCchPrintfW(formattedVersion, ARRAYSIZE(formattedVersion), L"%hu.%hu.%hu.%hu", major, minor, build, revision)));
|
||||||
|
return std::wstring(formattedVersion);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
};
|
||||||
|
|
||||||
|
namespace DynamicDependency::Bootstrap
|
||||||
|
{
|
||||||
|
// Automate Boostrap shutdown when leaving scope
|
||||||
|
namespace details
|
||||||
|
{
|
||||||
|
struct mddbootstrapshutdown_t;
|
||||||
|
|
||||||
|
struct mddbootstrapshutdown_deleter_t
|
||||||
|
{
|
||||||
|
void operator()(mddbootstrapshutdown_t*)
|
||||||
|
{
|
||||||
|
MddBootstrapShutdown();
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
using unique_mddbootstrapshutdown = std::unique_ptr<details::mddbootstrapshutdown_t, details::mddbootstrapshutdown_deleter_t>;
|
||||||
|
|
||||||
|
/// Options for Bootstrap initialization APIs.
|
||||||
|
/// @see InitializeFailFast(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
|
||||||
|
/// @see Initialize(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
|
||||||
|
/// @see InitializeNoThrow(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
|
||||||
|
enum class InitializeOptions
|
||||||
|
{
|
||||||
|
/// Default behavior
|
||||||
|
None = MddBootstrapInitializeOptions_None,
|
||||||
|
|
||||||
|
/// If not successful call DebugBreak()
|
||||||
|
OnError_DebugBreak = MddBootstrapInitializeOptions_OnError_DebugBreak,
|
||||||
|
|
||||||
|
/// If not successful call DebugBreak() if a debugger is attached to the process
|
||||||
|
OnError_DebugBreak_IfDebuggerAttached = MddBootstrapInitializeOptions_OnError_DebugBreak_IfDebuggerAttached,
|
||||||
|
|
||||||
|
/// If not successful perform a fail-fast
|
||||||
|
OnError_FailFast = MddBootstrapInitializeOptions_OnError_FailFast,
|
||||||
|
|
||||||
|
/// If a compatible Windows App Runtime framework package is not found show UI
|
||||||
|
OnNoMatch_ShowUI = MddBootstrapInitializeOptions_OnNoMatch_ShowUI,
|
||||||
|
|
||||||
|
/// Do nothing (do not error) if the process has package identity
|
||||||
|
OnPackageIdentity_NOOP = MddBootstrapInitializeOptions_OnPackageIdentity_NOOP,
|
||||||
|
};
|
||||||
|
DEFINE_ENUM_FLAG_OPERATORS(InitializeOptions)
|
||||||
|
|
||||||
|
/// Call MddBootstrapInitialize2() and aborts the process (via std::abort()) if it fails;
|
||||||
|
/// returns an RAII object that reverts the initialization on success.
|
||||||
|
///
|
||||||
|
/// Initialize the calling process to use Windows App SDK's framework package.
|
||||||
|
///
|
||||||
|
/// Find a Windows App SDK framework package meeting the criteria and make it available
|
||||||
|
/// for use by the current process. If multiple packages meet the criteria the best
|
||||||
|
/// candidate is selected.
|
||||||
|
///
|
||||||
|
/// @param majorMinorVersion major and minor version of Windows App SDK's framework package, encoded as `0xMMMMNNNN` where M=Major, N=Minor (e.g. 1.2 == 0x00010002).
|
||||||
|
/// @param versionTag version tag (if any), e.g. "preview1".
|
||||||
|
/// @param minVersion the minimum version to use
|
||||||
|
/// @param options optional behavior
|
||||||
|
/// @see Initialize(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
|
||||||
|
/// @see InitializeNoThrow(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
|
||||||
|
/// @see Shutdown()
|
||||||
|
/// ~~~~~
|
||||||
|
/// #include <windows.h>
|
||||||
|
///
|
||||||
|
/// #include <WindowsAppSDK-VersionInfo.h>
|
||||||
|
/// #include <MddBootstrap.h>
|
||||||
|
///
|
||||||
|
/// #include <iostream>
|
||||||
|
///
|
||||||
|
/// namespace MddBootstrap { using namespace ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap; }
|
||||||
|
///
|
||||||
|
/// int main()
|
||||||
|
/// {
|
||||||
|
/// auto mddBootstrapShutdown = MddBootstrap::InitializeFailFast();
|
||||||
|
/// std::cout << "hello world";
|
||||||
|
/// return 0;
|
||||||
|
/// }
|
||||||
|
/// ~~~~~
|
||||||
|
[[nodiscard]] inline unique_mddbootstrapshutdown InitializeFailFast(
|
||||||
|
uint32_t majorMinorVersion = WINDOWSAPPSDK_RELEASE_MAJORMINOR,
|
||||||
|
PCWSTR versionTag = WINDOWSAPPSDK_RELEASE_VERSION_TAG_W,
|
||||||
|
PackageVersion minVersion = WINDOWSAPPSDK_RUNTIME_VERSION_UINT64,
|
||||||
|
InitializeOptions options = ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap::InitializeOptions::None)
|
||||||
|
{
|
||||||
|
const auto hr{ ::MddBootstrapInitialize2(majorMinorVersion, versionTag, minVersion, static_cast<MddBootstrapInitializeOptions>(options)) };
|
||||||
|
if (FAILED(hr))
|
||||||
|
{
|
||||||
|
std::abort();
|
||||||
|
}
|
||||||
|
return unique_mddbootstrapshutdown(reinterpret_cast<details::mddbootstrapshutdown_t*>(1));
|
||||||
|
}
|
||||||
|
|
||||||
|
#if defined(_CPPUNWIND) && defined(WINRT_BASE_H)
|
||||||
|
/// Call MddBootstrapInitialize2() and throws an exception if it fails;
|
||||||
|
/// returns an RAII object that reverts the initialization on success.
|
||||||
|
///
|
||||||
|
/// Initialize the calling process to use Windows App SDK's framework package.
|
||||||
|
///
|
||||||
|
/// Find a Windows App SDK framework package meeting the criteria and make it available
|
||||||
|
/// for use by the current process. If multiple packages meet the criteria the best
|
||||||
|
/// candidate is selected.
|
||||||
|
///
|
||||||
|
/// @param majorMinorVersion major and minor version of Windows App SDK's framework package, encoded as `0xMMMMNNNN` where M=Major, N=Minor (e.g. 1.2 == 0x00010002).
|
||||||
|
/// @param versionTag version tag (if any), e.g. "preview1".
|
||||||
|
/// @param minVersion the minimum version to use
|
||||||
|
/// @param options optional behavior
|
||||||
|
/// @see Initialize_failfast(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
|
||||||
|
/// @see Initialize_nothrow(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
|
||||||
|
/// @see Shutdown()
|
||||||
|
/// @exception winrt::hresult_error thrown if intialization fails; see code() for more details.
|
||||||
|
/// ~~~~~
|
||||||
|
/// #include <windows.h>
|
||||||
|
///
|
||||||
|
/// #include <winrt\base.h>
|
||||||
|
///
|
||||||
|
/// #include <WindowsAppSDK-VersionInfo.h>
|
||||||
|
/// #include <MddBootstrap.h>
|
||||||
|
///
|
||||||
|
/// #include <iostream>
|
||||||
|
///
|
||||||
|
/// namespace MddBootstrap { using namespace ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap; }
|
||||||
|
///
|
||||||
|
/// int main()
|
||||||
|
/// {
|
||||||
|
/// try
|
||||||
|
/// {
|
||||||
|
/// auto mddBootstrapCleanup = MddBootstrap::Initialize();
|
||||||
|
/// std::cout << "hello world";
|
||||||
|
/// }
|
||||||
|
/// catch (const winrt::hresult_error& ex)
|
||||||
|
/// {
|
||||||
|
/// const auto hr{ ex.code() };
|
||||||
|
/// std::cout << "Error 0x" << std::hex << hr << " in Bootstrap initialization";
|
||||||
|
/// return hr;
|
||||||
|
/// }
|
||||||
|
/// return 0;
|
||||||
|
/// }
|
||||||
|
/// ~~~~~
|
||||||
|
[[nodiscard]] inline unique_mddbootstrapshutdown Initialize(
|
||||||
|
uint32_t majorMinorVersion = WINDOWSAPPSDK_RELEASE_MAJORMINOR,
|
||||||
|
PCWSTR versionTag = WINDOWSAPPSDK_RELEASE_VERSION_TAG_W,
|
||||||
|
PackageVersion minVersion = WINDOWSAPPSDK_RUNTIME_VERSION_UINT64,
|
||||||
|
InitializeOptions options = ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap::InitializeOptions::None)
|
||||||
|
{
|
||||||
|
winrt::check_hresult(::MddBootstrapInitialize2(majorMinorVersion, versionTag, minVersion, static_cast<MddBootstrapInitializeOptions>(options)));
|
||||||
|
return unique_mddbootstrapshutdown(reinterpret_cast<details::mddbootstrapshutdown_t*>(1));
|
||||||
|
}
|
||||||
|
#endif // defined(_CPPUNWIND) && defined(WINRT_BASE_H)
|
||||||
|
|
||||||
|
/// Call MddBootstrapInitialize2() and returns a failure HRESULT if it fails.
|
||||||
|
///
|
||||||
|
/// Initialize the calling process to use Windows App SDK's framework package.
|
||||||
|
///
|
||||||
|
/// Find a Windows App SDK framework package meeting the criteria and make it available
|
||||||
|
/// for use by the current process. If multiple packages meet the criteria the best
|
||||||
|
/// candidate is selected.
|
||||||
|
///
|
||||||
|
/// @param majorMinorVersion major and minor version of Windows App SDK's framework package, encoded as `0xMMMMNNNN` where M=Major, N=Minor (e.g. 1.2 == 0x00010002).
|
||||||
|
/// @param versionTag version tag (if any), e.g. "preview1".
|
||||||
|
/// @param minVersion the minimum version to use
|
||||||
|
/// @param options optional behavior
|
||||||
|
/// @see InitializeFailFast(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
|
||||||
|
/// @see Initialize(uint32_t, PCWSTR, PackageVersion, InitializeOptions)
|
||||||
|
/// @see Shutdown()
|
||||||
|
/// ~~~~~
|
||||||
|
/// #include <windows.h>
|
||||||
|
///
|
||||||
|
/// #include <WindowsAppSDK-VersionInfo.h>
|
||||||
|
/// #include <MddBootstrap.h>
|
||||||
|
///
|
||||||
|
/// #include <iostream>
|
||||||
|
///
|
||||||
|
/// namespace MddBootstrap { using namespace ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap; }
|
||||||
|
///
|
||||||
|
/// int main()
|
||||||
|
/// {
|
||||||
|
/// const auto hr{ MddBootstrap::InitializeNoThrow() };
|
||||||
|
/// if (FAILED(hr))
|
||||||
|
/// {
|
||||||
|
/// std::cout << "Error 0x" << std::hex << hr << " in Bootstrap initialization";
|
||||||
|
/// return hr;
|
||||||
|
/// }
|
||||||
|
/// auto mddBootstrapShutdown{ MddBootstrap::unique_mddbootstrapshutdown(reinterpret_cast<MddBootstrap::details::mddbootstrapshutdown_t*>(1)) };
|
||||||
|
/// std::cout << "hello world";
|
||||||
|
/// return 0;
|
||||||
|
/// }
|
||||||
|
/// ~~~~~
|
||||||
|
inline HRESULT InitializeNoThrow(
|
||||||
|
uint32_t majorMinorVersion = WINDOWSAPPSDK_RELEASE_MAJORMINOR,
|
||||||
|
PCWSTR versionTag = WINDOWSAPPSDK_RELEASE_VERSION_TAG_W,
|
||||||
|
PackageVersion minVersion = WINDOWSAPPSDK_RUNTIME_VERSION_UINT64,
|
||||||
|
InitializeOptions options = ::Microsoft::Windows::ApplicationModel::DynamicDependency::Bootstrap::InitializeOptions::None)
|
||||||
|
{
|
||||||
|
return ::MddBootstrapInitialize2(majorMinorVersion, versionTag, minVersion, static_cast<MddBootstrapInitializeOptions>(options));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif // defined(WINDOWSAPPSDK_RELEASE_MAJORMINOR) && defined(WINDOWSAPPSDK_RELEASE_VERSION_TAG_W) && defined(WINDOWSAPPSDK_RUNTIME_VERSION_UINT64)
|
||||||
|
#endif // defined(__cplusplus)
|
||||||
|
|
||||||
|
#endif // MDDBOOTSTRAP_H
|
||||||
@ -0,0 +1,121 @@
|
|||||||
|
|
||||||
|
//---------------------------------------------------------------------------
|
||||||
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
|
//---------------------------------------------------------------------------
|
||||||
|
|
||||||
|
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||||
|
#pragma once
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <winrt/Microsoft.ui.composition.h>
|
||||||
|
#include <sdkddkver.h>
|
||||||
|
|
||||||
|
namespace winrt {
|
||||||
|
namespace Microsoft {
|
||||||
|
namespace UI {
|
||||||
|
namespace Composition {
|
||||||
|
|
||||||
|
#undef INTERFACE
|
||||||
|
#define INTERFACE ICompositionDrawingSurfaceInterop
|
||||||
|
DECLARE_INTERFACE_IID_(ICompositionDrawingSurfaceInterop, ::IUnknown, "2D6355C2-AD57-4EAE-92E4-4C3EFF65D578")
|
||||||
|
{
|
||||||
|
IFACEMETHOD(BeginDraw)(
|
||||||
|
_In_opt_ const RECT * updateRect,
|
||||||
|
_In_ REFIID iid,
|
||||||
|
_COM_Outptr_ void ** updateObject,
|
||||||
|
_Out_ POINT * updateOffset
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
IFACEMETHOD(EndDraw)(
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
IFACEMETHOD(Resize)(
|
||||||
|
_In_ SIZE sizePixels
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
IFACEMETHOD(Scroll)(
|
||||||
|
_In_opt_ const RECT * scrollRect,
|
||||||
|
_In_opt_ const RECT * clipRect,
|
||||||
|
_In_ int offsetX,
|
||||||
|
_In_ int offsetY
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
IFACEMETHOD(ResumeDraw)(
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
IFACEMETHOD(SuspendDraw)(
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
#undef INTERFACE
|
||||||
|
#define INTERFACE ICompositionDrawingSurfaceInterop2
|
||||||
|
DECLARE_INTERFACE_IID_(ICompositionDrawingSurfaceInterop2, ICompositionDrawingSurfaceInterop, "D4B71A65-3052-4ABE-9183-E98DE02A41A9")
|
||||||
|
{
|
||||||
|
IFACEMETHOD(CopySurface)(
|
||||||
|
_In_ ::IUnknown* destinationResource,
|
||||||
|
_In_ int destinationOffsetX,
|
||||||
|
_In_ int destinationOffsetY,
|
||||||
|
_In_opt_ const RECT * sourceRectangle
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
#undef INTERFACE
|
||||||
|
#define INTERFACE ICompositionGraphicsDeviceInterop
|
||||||
|
DECLARE_INTERFACE_IID_(ICompositionGraphicsDeviceInterop, ::IUnknown, "4AFA8030-BC70-4B0C-B1C7-6E69F933DC83")
|
||||||
|
{
|
||||||
|
IFACEMETHOD(GetRenderingDevice)(
|
||||||
|
_COM_Outptr_ ::IUnknown ** value
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
IFACEMETHOD(SetRenderingDevice)(
|
||||||
|
_In_ ::IUnknown * value
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#undef INTERFACE
|
||||||
|
#define INTERFACE ICompositorInterop
|
||||||
|
DECLARE_INTERFACE_IID_(ICompositorInterop, ::IUnknown, "FAB19398-6D19-4D8A-B752-8F096C396069")
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
HRESULT CreateGraphicsDevice(
|
||||||
|
_In_ ::IUnknown * renderingDevice,
|
||||||
|
_Out_ ICompositionGraphicsDevice* result)
|
||||||
|
{
|
||||||
|
return CreateGraphicsDevice_Abi(
|
||||||
|
renderingDevice,
|
||||||
|
winrt::put_abi(*result));
|
||||||
|
}
|
||||||
|
|
||||||
|
private:
|
||||||
|
IFACEMETHOD(CreateGraphicsDevice_Abi)(
|
||||||
|
_In_ ::IUnknown * renderingDevice,
|
||||||
|
_COM_Outptr_ void** result // ICompositionGraphicsDevice**
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
#pragma region Desktop Family
|
||||||
|
#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)
|
||||||
|
|
||||||
|
namespace Interactions
|
||||||
|
{
|
||||||
|
|
||||||
|
#undef INTERFACE
|
||||||
|
#define INTERFACE IVisualInteractionSourceInterop
|
||||||
|
DECLARE_INTERFACE_IID_(IVisualInteractionSourceInterop, ::IUnknown, "AA170AEE-01D7-4954-89D2-8554415D6946")
|
||||||
|
{
|
||||||
|
IFACEMETHOD(TryRedirectForManipulation)(
|
||||||
|
_In_ const POINTER_INFO& pointerInfo
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // Interactions
|
||||||
|
|
||||||
|
#endif /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */
|
||||||
|
#pragma endregion
|
||||||
|
|
||||||
|
|
||||||
|
} // namespace Composition
|
||||||
|
} // namespace UI
|
||||||
|
} // namespace Microsoft
|
||||||
|
} // namespace winrt
|
||||||
@ -0,0 +1,12 @@
|
|||||||
|
//---------------------------------------------------------------------------
|
||||||
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
|
//---------------------------------------------------------------------------
|
||||||
|
|
||||||
|
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||||
|
#pragma once
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <wtypes.h>
|
||||||
|
|
||||||
|
extern "C" BOOL __stdcall
|
||||||
|
ContentPreTranslateMessage(const MSG *pmsg);
|
||||||
@ -0,0 +1,30 @@
|
|||||||
|
//---------------------------------------------------------------------------
|
||||||
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
|
//---------------------------------------------------------------------------
|
||||||
|
|
||||||
|
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||||
|
#pragma once
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <sdkddkver.h>
|
||||||
|
|
||||||
|
namespace winrt {
|
||||||
|
namespace Microsoft {
|
||||||
|
namespace UI {
|
||||||
|
namespace Input {
|
||||||
|
|
||||||
|
#undef INTERFACE
|
||||||
|
#define INTERFACE IInputCursorStaticsInterop
|
||||||
|
|
||||||
|
DECLARE_INTERFACE_IID_(IInputCursorStaticsInterop, IInspectable, "ac6f5065-90c4-46ce-beb7-05e138e54117")
|
||||||
|
{
|
||||||
|
IFACEMETHOD(CreateFromHCursor)(
|
||||||
|
_In_ HCURSOR cursor,
|
||||||
|
_Out_ IInputCursor * *result
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
} // namespace Input
|
||||||
|
} // namespace UI
|
||||||
|
} // namespace Microsoft
|
||||||
|
} // namespace winrt
|
||||||
@ -0,0 +1,63 @@
|
|||||||
|
//---------------------------------------------------------------------------
|
||||||
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
|
//---------------------------------------------------------------------------
|
||||||
|
|
||||||
|
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||||
|
#pragma once
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <sdkddkver.h>
|
||||||
|
|
||||||
|
namespace winrt {
|
||||||
|
namespace Microsoft {
|
||||||
|
namespace UI {
|
||||||
|
namespace Input {
|
||||||
|
|
||||||
|
|
||||||
|
// Ever wondered what all of the macros do for these manual COM-style interface definitions? I
|
||||||
|
// know I did! And Raymond Chen has the answers: https://devblogs.microsoft.com/oldnewthing/20041005-00/?p=37653
|
||||||
|
//
|
||||||
|
// Since we don't support C code calling these interfaces, we've opted to forego a few of the usual
|
||||||
|
// requirements. Specifically, we don't use "#undef INTERFACE / #define INTERFACE", we don't use the
|
||||||
|
// BEGIN and END macros, we don't use the THIS or THIS_ macros, and we don't repeat the base class
|
||||||
|
// members.
|
||||||
|
|
||||||
|
interface IInputPreTranslateKeyboardSourceHandler;
|
||||||
|
|
||||||
|
DECLARE_INTERFACE_IID_(IInputPreTranslateKeyboardSourceInterop, IUnknown, "C3244A48-DCB4-416C-901A-FFC5E50C2FFA")
|
||||||
|
{
|
||||||
|
IFACEMETHOD(SetPreTranslateHandler)(
|
||||||
|
_In_ IInputPreTranslateKeyboardSourceHandler* handler
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
DECLARE_INTERFACE_IID_(IInputPreTranslateKeyboardSourceHandler, IUnknown, "9A4B69AA-E3BE-4590-95F5-3AAA7B12B260")
|
||||||
|
{
|
||||||
|
// "keyboardModifiers" are flags that can hold a combination of the following values:
|
||||||
|
//
|
||||||
|
// FVIRTKEY 0x0001 Message is WM_(SYS)KEYDOWN or WM_(SYS)KEYUP.
|
||||||
|
// FSHIFT 0x0004 VK_SHIFT is pressed.
|
||||||
|
// FCONTROL 0x0008 VK_CONTROL is pressed (or VK_RCONTROL when the AltGr key is present and pressed).
|
||||||
|
// FALT 0x0010 VK_MENU is pressed (or VK_LMENU when the AltGr key is present and pressed).
|
||||||
|
|
||||||
|
IFACEMETHOD(OnDirectMessage)(
|
||||||
|
_In_ IInputPreTranslateKeyboardSourceInterop* source,
|
||||||
|
_In_ const MSG* msg,
|
||||||
|
_In_ UINT keyboardModifiers,
|
||||||
|
_Inout_ bool* handled
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
IFACEMETHOD(OnTreeMessage)(
|
||||||
|
_In_ IInputPreTranslateKeyboardSourceInterop* source,
|
||||||
|
_In_ const MSG* msg,
|
||||||
|
_In_ UINT keyboardModifiers,
|
||||||
|
_Inout_ bool* handled
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
} // namespace Input
|
||||||
|
} // namespace UI
|
||||||
|
} // namespace Microsoft
|
||||||
|
} // namespace winrt
|
||||||
151
Sources/CWinAppSDK/nuget/include/Microsoft.UI.Interop.h
Normal file
151
Sources/CWinAppSDK/nuget/include/Microsoft.UI.Interop.h
Normal file
@ -0,0 +1,151 @@
|
|||||||
|
//----------------------------------------------------------------------------
|
||||||
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
|
//----------------------------------------------------------------------------
|
||||||
|
|
||||||
|
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||||
|
#pragma once
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <winrt/Microsoft.UI.h>
|
||||||
|
|
||||||
|
namespace ABI::Microsoft::UI
|
||||||
|
{
|
||||||
|
using WindowId = winrt::Microsoft::UI::WindowId;
|
||||||
|
using DisplayId = winrt::Microsoft::UI::DisplayId;
|
||||||
|
using IconId = winrt::Microsoft::UI::IconId;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
namespace winrt::Microsoft::UI
|
||||||
|
{
|
||||||
|
|
||||||
|
typedef HRESULT (STDAPICALLTYPE *PfnGetWindowIdFromWindow)(_In_ HWND hwnd, _Out_ ABI::Microsoft::UI::WindowId* windowId);
|
||||||
|
typedef HRESULT (STDAPICALLTYPE *PfnGetWindowFromWindowId)(_In_ ABI::Microsoft::UI::WindowId windowId, _Out_ HWND* hwnd);
|
||||||
|
typedef HRESULT (STDAPICALLTYPE *PfnGetDisplayIdFromMonitor)(_In_ HMONITOR hmonitor, _Out_ ABI::Microsoft::UI::DisplayId* displayId);
|
||||||
|
typedef HRESULT (STDAPICALLTYPE *PfnGetMonitorFromDisplayId)(_In_ ABI::Microsoft::UI::DisplayId displayId, _Out_ HMONITOR* hmonitor);
|
||||||
|
typedef HRESULT (STDAPICALLTYPE *PfnGetIconIdFromIcon)(_In_ HICON hicon, _Out_ ABI::Microsoft::UI::IconId* iconId);
|
||||||
|
typedef HRESULT (STDAPICALLTYPE *PfnGetIconFromIconId)(_In_ ABI::Microsoft::UI::IconId iconId, _Out_ HICON* hicon);
|
||||||
|
|
||||||
|
typedef struct _InteropImpl
|
||||||
|
{
|
||||||
|
PfnGetWindowIdFromWindow pfnGetWindowIdFromWindow;
|
||||||
|
PfnGetWindowFromWindowId pfnGetWindowFromWindowId;
|
||||||
|
PfnGetDisplayIdFromMonitor pfnGetDisplayIdFromMonitor;
|
||||||
|
PfnGetMonitorFromDisplayId pfnGetMonitorFromDisplayId;
|
||||||
|
PfnGetIconIdFromIcon pfnGetIconIdFromIcon;
|
||||||
|
PfnGetIconFromIconId pfnGetIconFromIconId;
|
||||||
|
} InteropImpl;
|
||||||
|
|
||||||
|
#pragma warning(push)
|
||||||
|
#pragma warning(disable:4505) // linker warning: unreferenced local function has been removed
|
||||||
|
|
||||||
|
__declspec(selectany) InteropImpl s_impl { nullptr };
|
||||||
|
__declspec(selectany) HMODULE s_module { nullptr };
|
||||||
|
|
||||||
|
|
||||||
|
// Load the FrameworkUdk library if needed and store pointers to the handle conversion functions.
|
||||||
|
// We need this approach because third-party apps cannot link to the FrameworkUdk directly.
|
||||||
|
// Note that in unpackaged apps this will only work after a call to MddBootstrapInitialize().
|
||||||
|
static void EnsureInteropImplLoaded()
|
||||||
|
{
|
||||||
|
if (s_module == nullptr)
|
||||||
|
{
|
||||||
|
HMODULE hmod = ::GetModuleHandle(TEXT("Microsoft.Internal.FrameworkUdk.dll"));
|
||||||
|
if (hmod == nullptr)
|
||||||
|
{
|
||||||
|
hmod = ::LoadLibrary(TEXT("Microsoft.Internal.FrameworkUdk.dll"));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (hmod != nullptr)
|
||||||
|
{
|
||||||
|
// In case of race conditions, this should be idempotent
|
||||||
|
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetWindowIdFromWindow) = ::GetProcAddress(hmod, "Windowing_GetWindowIdFromWindow");
|
||||||
|
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetWindowFromWindowId) = ::GetProcAddress(hmod, "Windowing_GetWindowFromWindowId");
|
||||||
|
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetDisplayIdFromMonitor) = ::GetProcAddress(hmod, "Windowing_GetDisplayIdFromMonitor");
|
||||||
|
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetMonitorFromDisplayId) = ::GetProcAddress(hmod, "Windowing_GetMonitorFromDisplayId");
|
||||||
|
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetIconIdFromIcon) = ::GetProcAddress(hmod, "Windowing_GetIconIdFromIcon");
|
||||||
|
*reinterpret_cast<FARPROC*>(&s_impl.pfnGetIconFromIconId) = ::GetProcAddress(hmod, "Windowing_GetIconFromIconId");
|
||||||
|
|
||||||
|
winrt::check_bool(
|
||||||
|
(s_impl.pfnGetWindowIdFromWindow != nullptr) &&
|
||||||
|
(s_impl.pfnGetWindowFromWindowId != nullptr) &&
|
||||||
|
(s_impl.pfnGetDisplayIdFromMonitor != nullptr) &&
|
||||||
|
(s_impl.pfnGetMonitorFromDisplayId != nullptr) &&
|
||||||
|
(s_impl.pfnGetIconIdFromIcon != nullptr) &&
|
||||||
|
(s_impl.pfnGetIconFromIconId != nullptr));
|
||||||
|
|
||||||
|
// Store our HMODULE if none has been set so far
|
||||||
|
::InterlockedCompareExchangePointer(reinterpret_cast<volatile PVOID*>(&s_module), hmod, nullptr);
|
||||||
|
|
||||||
|
// It is possible that due to race conditions the FrameworkUdk dll ends up loaded multiple
|
||||||
|
// times. The expectation is that the FrameworkUdk dll will remain loaded for the lifetime
|
||||||
|
// of the process so we won't attempt to mitigate the extra lib refcounts.
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
winrt::check_bool(s_module != nullptr);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static winrt::Microsoft::UI::WindowId GetWindowIdFromWindow(_In_ const HWND& hwnd)
|
||||||
|
{
|
||||||
|
::ABI::Microsoft::UI::WindowId abiWindowId = {};
|
||||||
|
EnsureInteropImplLoaded();
|
||||||
|
winrt::check_hresult(s_impl.pfnGetWindowIdFromWindow(hwnd, &abiWindowId));
|
||||||
|
winrt::Microsoft::UI::WindowId winrtWindowId { abiWindowId.Value };
|
||||||
|
return winrtWindowId;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static HWND GetWindowFromWindowId(_In_ const winrt::Microsoft::UI::WindowId& windowId)
|
||||||
|
{
|
||||||
|
HWND hwnd = nullptr;
|
||||||
|
EnsureInteropImplLoaded();
|
||||||
|
::ABI::Microsoft::UI::WindowId abiWindowId { windowId.Value };
|
||||||
|
winrt::check_hresult(s_impl.pfnGetWindowFromWindowId(abiWindowId, &hwnd));
|
||||||
|
return hwnd;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static winrt::Microsoft::UI::DisplayId GetDisplayIdFromMonitor(_In_ const HMONITOR& hmonitor)
|
||||||
|
{
|
||||||
|
::ABI::Microsoft::UI::DisplayId abiDisplayId = {};
|
||||||
|
EnsureInteropImplLoaded();
|
||||||
|
winrt::check_hresult(s_impl.pfnGetDisplayIdFromMonitor(hmonitor, &abiDisplayId));
|
||||||
|
winrt::Microsoft::UI::DisplayId winrtDisplayId { abiDisplayId.Value };
|
||||||
|
return winrtDisplayId;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static HMONITOR GetMonitorFromDisplayId(_In_ const winrt::Microsoft::UI::DisplayId& displayId)
|
||||||
|
{
|
||||||
|
HMONITOR hmonitor = nullptr;
|
||||||
|
EnsureInteropImplLoaded();
|
||||||
|
::ABI::Microsoft::UI::DisplayId abiDisplayId { displayId.Value };
|
||||||
|
winrt::check_hresult(s_impl.pfnGetMonitorFromDisplayId(abiDisplayId, &hmonitor));
|
||||||
|
return hmonitor;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static winrt::Microsoft::UI::IconId GetIconIdFromIcon(_In_ const HICON& hicon)
|
||||||
|
{
|
||||||
|
::ABI::Microsoft::UI::IconId abiIconId = {};
|
||||||
|
EnsureInteropImplLoaded();
|
||||||
|
winrt::check_hresult(s_impl.pfnGetIconIdFromIcon(hicon, &abiIconId));
|
||||||
|
winrt::Microsoft::UI::IconId winrtIconId { abiIconId.Value };
|
||||||
|
return winrtIconId;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static HICON GetIconFromIconId(_In_ const winrt::Microsoft::UI::IconId& iconId)
|
||||||
|
{
|
||||||
|
HICON hicon = nullptr;
|
||||||
|
EnsureInteropImplLoaded();
|
||||||
|
::ABI::Microsoft::UI::IconId abiIconId { iconId.Value };
|
||||||
|
winrt::check_hresult(s_impl.pfnGetIconFromIconId(abiIconId, &hicon));
|
||||||
|
return hicon;
|
||||||
|
}
|
||||||
|
|
||||||
|
#pragma warning(pop)
|
||||||
|
|
||||||
|
} // namespace winrt::Microsoft::UI
|
||||||
226
Sources/CWinAppSDK/nuget/include/MsixDynamicDependency.h
Normal file
226
Sources/CWinAppSDK/nuget/include/MsixDynamicDependency.h
Normal file
@ -0,0 +1,226 @@
|
|||||||
|
// Copyright (c) Microsoft Corporation and Contributors.
|
||||||
|
// Licensed under the MIT License.
|
||||||
|
|
||||||
|
#if !defined(MSIXDYNAMICDEPENDENCY_H)
|
||||||
|
#define MSIXDYNAMICDEPENDENCY_H
|
||||||
|
|
||||||
|
#include <appmodel.h>
|
||||||
|
|
||||||
|
#include <stdint.h>
|
||||||
|
|
||||||
|
/// MSIX Dynamic Dependency HRESULT: Windows App Runtime is not in the package graph.
|
||||||
|
#define MDD_E_WINDOWSAPPRUNTIME_NOT_IN_PACKAGE_GRAPH _HRESULT_TYPEDEF_(0x80040001L)
|
||||||
|
|
||||||
|
/// MSIX Dynamic Dependency HRESULT: Data Store not found (Windows App Runtime's Main package not registered?)
|
||||||
|
#define MDD_E_WINDOWSAPPRUNTIME_DATASTORE_NOT_FOUND _HRESULT_TYPEDEF_(0x80040002L)
|
||||||
|
|
||||||
|
/// MSIX Dynamic Dependency: Bootstrap initialization is scanning for an applicable DynamicDependencyLifetimeManager (DDLM) package
|
||||||
|
#define MDD_E_BOOTSTRAP_INITIALIZE_SCAN_FOR_DDLM _HRESULT_TYPEDEF_(0x80040010L)
|
||||||
|
|
||||||
|
/// MSIX Dynamic Dependency: Bootstrap initialization found a DynamicDependencyLifetimeManager (DDLM) but doesn't match the criteria
|
||||||
|
#define MDD_E_BOOTSTRAP_INITIALIZE_DDLM_SCAN_NO_MATCH _HRESULT_TYPEDEF_(0x80040011L)
|
||||||
|
|
||||||
|
/// MSIX Dynamic Dependency: Bootstrap initialization found a DynamicDependencyLifetimeManager (DDLM) that does match the criteria
|
||||||
|
#define MDD_E_BOOTSTRAP_INITIALIZE_DDLM_SCAN_MATCH _HRESULT_TYPEDEF_(0x80040012L)
|
||||||
|
|
||||||
|
/// MSIX Dynamic Dependency: Bootstrap initialization found an applicable DynamicDependencyLifetimeManager (DDLM) best matching the criteria
|
||||||
|
#define MDD_E_BOOTSTRAP_INITIALIZE_DDLM_FOUND _HRESULT_TYPEDEF_(0x80040013L)
|
||||||
|
|
||||||
|
/// MSIX Dynamic Dependency: Bootstrap initialization request is incompatible with current Bootstrap initialization state.
|
||||||
|
#define MDD_E_BOOTSTRAP_INITIALIZE_INCOMPATIBLE _HRESULT_TYPEDEF_(0x80040014L)
|
||||||
|
|
||||||
|
#if defined(__cplusplus)
|
||||||
|
|
||||||
|
enum class MddCreatePackageDependencyOptions : uint32_t
|
||||||
|
{
|
||||||
|
None = 0,
|
||||||
|
|
||||||
|
/// Disable dependency resolution when pinning a package dependency.
|
||||||
|
DoNotVerifyDependencyResolution = 0x00000001,
|
||||||
|
|
||||||
|
/// Define the package dependency for the system, accessible to all users
|
||||||
|
/// (default is the package dependency is defined for a specific user).
|
||||||
|
/// This option requires the caller has adminitrative privileges.
|
||||||
|
ScopeIsSystem = 0x00000002,
|
||||||
|
};
|
||||||
|
DEFINE_ENUM_FLAG_OPERATORS(MddCreatePackageDependencyOptions)
|
||||||
|
|
||||||
|
enum class MddPackageDependencyLifetimeKind
|
||||||
|
{
|
||||||
|
/// The current process is the lifetime artifact. The package dependency
|
||||||
|
/// is implicitly deleted when the process terminates.
|
||||||
|
Process = 0,
|
||||||
|
|
||||||
|
/// The lifetime artifact is an absolute filename or path.
|
||||||
|
/// The package dependency is implicitly deleted when this is deleted.
|
||||||
|
FilePath = 1,
|
||||||
|
|
||||||
|
/// The lifetime artifact is a registry key in the format
|
||||||
|
/// 'root\\subkey' where root is one of the following: HKLM, HKCU, HKCR, HKU.
|
||||||
|
/// The package dependency is implicitly deleted when this is deleted.
|
||||||
|
RegistryKey = 2,
|
||||||
|
};
|
||||||
|
|
||||||
|
enum class MddAddPackageDependencyOptions : uint32_t
|
||||||
|
{
|
||||||
|
None = 0,
|
||||||
|
PrependIfRankCollision = 0x00000001,
|
||||||
|
};
|
||||||
|
DEFINE_ENUM_FLAG_OPERATORS(MddAddPackageDependencyOptions)
|
||||||
|
|
||||||
|
#define MDD_PACKAGE_DEPENDENCY_RANK_DEFAULT 0
|
||||||
|
|
||||||
|
enum class MddPackageDependencyProcessorArchitectures : uint32_t
|
||||||
|
{
|
||||||
|
None = 0,
|
||||||
|
Neutral = 0x00000001,
|
||||||
|
X86 = 0x00000002,
|
||||||
|
X64 = 0x00000004,
|
||||||
|
Arm = 0x00000008,
|
||||||
|
Arm64 = 0x00000010,
|
||||||
|
X86OnArm64 = 0x00000020,
|
||||||
|
};
|
||||||
|
DEFINE_ENUM_FLAG_OPERATORS(MddPackageDependencyProcessorArchitectures)
|
||||||
|
|
||||||
|
DECLARE_HANDLE(MDD_PACKAGEDEPENDENCY_CONTEXT);
|
||||||
|
|
||||||
|
/// Define a package dependency. The criteria for a PackageDependency
|
||||||
|
/// (package family name, minimum version, etc)
|
||||||
|
/// may match multiple packages, but ensures Deployment won't remove
|
||||||
|
/// a package if it's the only one satisfying the PackageDependency.
|
||||||
|
///
|
||||||
|
/// @note A package matching a PackageDependency pin can still be removed
|
||||||
|
/// as long as there's another package that satisfies the PackageDependency.
|
||||||
|
/// For example, if Fwk-v1 is installed and a PackageDependency specifies
|
||||||
|
/// MinVersion=1 and then Fwk-v2 is installed, Deployment could remove
|
||||||
|
/// Fwk-v1 because Fwk-v2 will satisfy the PackageDependency. After Fwk-v1
|
||||||
|
/// is removed Deployment won't remove Fwk-v2 because it's the only package
|
||||||
|
/// satisfying the PackageDependency. Thus Fwk-v1 and Fwk-v2 (and any other
|
||||||
|
/// package matching the PackageDependency) are 'loosely pinned'. Deployment
|
||||||
|
/// guarantees it won't remove a package if it would make a PackageDependency
|
||||||
|
/// unsatisfied.
|
||||||
|
///
|
||||||
|
/// A PackageDependency specifies criteria (package family, minimum version, etc)
|
||||||
|
/// and not a specific package. Deployment reserves the right to use a different
|
||||||
|
/// package (e.g. higher version) to satisfy the PackageDependency if/when
|
||||||
|
/// one becomes available.
|
||||||
|
///
|
||||||
|
/// @param user the user scope of the package dependency. If NULL the caller's
|
||||||
|
/// user context is used. MUST be NULL if MddCreatePackageDependencyOptions::ScopeIsSystem
|
||||||
|
/// is specified
|
||||||
|
/// @param lifetimeArtifact MUST be NULL if lifetimeKind=MddPackageDependencyLifetimeKind::Process
|
||||||
|
/// @param packageDependencyId allocated via HeapAlloc; use HeapFree to deallocate
|
||||||
|
///
|
||||||
|
/// @note MddTryCreatePackageDependency() fails if the PackageDependency cannot be resolved to a specific
|
||||||
|
/// package. This package resolution check is skipped if
|
||||||
|
/// MddCreatePackageDependencyOptions::DoNotVerifyDependencyResolution is specified. This is useful
|
||||||
|
/// for installers running as user contexts other than the target user (e.g. installers
|
||||||
|
/// running as LocalSystem).
|
||||||
|
STDAPI MddTryCreatePackageDependency(
|
||||||
|
PSID user,
|
||||||
|
_In_ PCWSTR packageFamilyName,
|
||||||
|
PACKAGE_VERSION minVersion,
|
||||||
|
MddPackageDependencyProcessorArchitectures packageDependencyProcessorArchitectures,
|
||||||
|
MddPackageDependencyLifetimeKind lifetimeKind,
|
||||||
|
PCWSTR lifetimeArtifact,
|
||||||
|
MddCreatePackageDependencyOptions options,
|
||||||
|
_Outptr_result_maybenull_ PWSTR* packageDependencyId) noexcept;
|
||||||
|
|
||||||
|
/// Undefine a package dependency. Removing a pin on a PackageDependency is typically done at uninstall-time.
|
||||||
|
/// This implicitly occurs if the package dependency's 'lifetime artifact' (specified via MddTryCreatePackageDependency)
|
||||||
|
/// is deleted. Packages that are not referenced by other packages and have no pins are elegible to be removed.
|
||||||
|
///
|
||||||
|
/// @warn MddDeletePackageDependency() requires the caller have administrative privileges
|
||||||
|
/// if the package dependency was pinned with MddCreatePackageDependencyOptions::ScopeIsSystem.
|
||||||
|
STDAPI_(void) MddDeletePackageDependency(
|
||||||
|
_In_ PCWSTR packageDependencyId) noexcept;
|
||||||
|
|
||||||
|
/// Resolve a previously-pinned PackageDependency to a specific package and
|
||||||
|
/// add it to the invoking process' package graph. Once the dependency has
|
||||||
|
/// been added other code-loading methods (LoadLibrary, CoCreateInstance, etc)
|
||||||
|
/// can find the binaries in the resolved package.
|
||||||
|
///
|
||||||
|
/// Package resolution is specific to a user and can return different values
|
||||||
|
/// for different users on a system.
|
||||||
|
///
|
||||||
|
/// Each successful MddAddPackageDependency() adds the resolved packaged to the
|
||||||
|
/// calling process' package graph, even if already present. There is no
|
||||||
|
/// duplicate 'detection' or 'filtering' applied by the API (multiple
|
||||||
|
/// references from a package is not harmful). Once resolution is complete
|
||||||
|
/// the package dependency stays resolved for that user until the last reference across
|
||||||
|
/// all processes for that user is removed via MddRemovePackageDependency (or
|
||||||
|
/// process termination).
|
||||||
|
///
|
||||||
|
/// MddAddPackageDependency() adds the resolved package to the caller's package graph,
|
||||||
|
/// per the rank specified. A process' package graph is a list of packages sorted by
|
||||||
|
/// rank in ascending order (-infinity...0...+infinity). If package(s) are present in the
|
||||||
|
/// package graph with the same rank as the call to MddAddPackageDependency the resolved
|
||||||
|
/// package is (by default) added after others of the same rank. To add a package
|
||||||
|
/// before others o the same rank, specify MddAddPackageDependencyOptions::PrependIfRankCollision.
|
||||||
|
///
|
||||||
|
/// Every MddAddPackageDependency can be balanced by a MddRemovePackageDependency
|
||||||
|
/// to remove the entry from the package graph. If the process terminates all package
|
||||||
|
/// references are removed, but any pins stay behind.
|
||||||
|
///
|
||||||
|
/// MddAddPackageDependency adds the resolved package to the process' package
|
||||||
|
/// graph, per the rank and options parameters. The process' package
|
||||||
|
/// graph is used to search for DLLs (per Dynamic-Link Library Search Order),
|
||||||
|
/// WinRT objects and other resources; the caller can now load DLLs, activate
|
||||||
|
/// WinRT objects and use other resources from the framework package until
|
||||||
|
/// MddRemovePackageDependency is called. The packageDependencyId parameter
|
||||||
|
/// must match a package dependency defined for the calling user or the
|
||||||
|
/// system (i.e. pinned with MddCreatePackageDependencyOptions::ScopeIsSystem) else
|
||||||
|
/// an error is returned.
|
||||||
|
///
|
||||||
|
/// @param packageDependencyContext valid until passed to MddRemovePackageDependency()
|
||||||
|
/// @param packageFullName allocated via HeapAlloc; use HeapFree to deallocate
|
||||||
|
STDAPI MddAddPackageDependency(
|
||||||
|
_In_ PCWSTR packageDependencyId,
|
||||||
|
INT32 rank,
|
||||||
|
MddAddPackageDependencyOptions options,
|
||||||
|
_Out_ MDD_PACKAGEDEPENDENCY_CONTEXT* packageDependencyContext,
|
||||||
|
_Outptr_opt_result_maybenull_ PWSTR* packageFullName) noexcept;
|
||||||
|
|
||||||
|
/// Remove a resolved PackageDependency from the current process' package graph
|
||||||
|
/// (i.e. undo MddAddPackageDependency). Used at runtime (i.e. the moral equivalent
|
||||||
|
/// of Windows' RemoveDllDirectory()).
|
||||||
|
///
|
||||||
|
/// @note This does not unload loaded resources (DLLs etc). After removing
|
||||||
|
/// a package dependency any files loaded from the package can continue
|
||||||
|
/// to be used; future file resolution will fail to see the removed
|
||||||
|
/// package dependency.
|
||||||
|
STDAPI_(void) MddRemovePackageDependency(
|
||||||
|
_In_ MDD_PACKAGEDEPENDENCY_CONTEXT packageDependencyContext) noexcept;
|
||||||
|
|
||||||
|
/// Return the package full name that would be used if the
|
||||||
|
/// PackageDependency were to be resolved. Does not add the
|
||||||
|
/// package to the process graph.
|
||||||
|
///
|
||||||
|
/// @param packageFullName allocated via HeapAlloc; use HeapFree to deallocate.
|
||||||
|
/// If the package dependency cannot be resolved the function
|
||||||
|
/// succeeds but packageFullName is nullptr.
|
||||||
|
STDAPI MddGetResolvedPackageFullNameForPackageDependency(
|
||||||
|
_In_ PCWSTR packageDependencyId,
|
||||||
|
_Outptr_result_maybenull_ PWSTR* packageFullName) noexcept;
|
||||||
|
|
||||||
|
/// Return the package dependency for the context.
|
||||||
|
///
|
||||||
|
/// @param packageDependencyId allocated via HeapAlloc; use HeapFree to deallocate.
|
||||||
|
/// If the package dependency context cannot be resolved
|
||||||
|
/// the function succeeds but packageDependencyId is nullptr.
|
||||||
|
STDAPI MddGetIdForPackageDependencyContext(
|
||||||
|
_In_ MDD_PACKAGEDEPENDENCY_CONTEXT packageDependencyContext,
|
||||||
|
_Outptr_result_maybenull_ PWSTR* packageDependencyId) noexcept;
|
||||||
|
|
||||||
|
/// Return the package graph's current revision id.
|
||||||
|
STDAPI_(UINT32) MddGetPackageGraphRevisionId() noexcept;
|
||||||
|
|
||||||
|
/// Return the package graph's current revision id.
|
||||||
|
///
|
||||||
|
/// @note This API is deprecated and will be removed in a future release.
|
||||||
|
/// Use MddGetPackageGraphRevisionId().
|
||||||
|
STDAPI_(UINT32) MddGetGenerationId() noexcept;
|
||||||
|
|
||||||
|
#endif // defined(__cplusplus)
|
||||||
|
|
||||||
|
#endif // MSIXDYNAMICDEPENDENCY_H
|
||||||
21
Sources/CWinAppSDK/nuget/include/Security.AccessControl.h
Normal file
21
Sources/CWinAppSDK/nuget/include/Security.AccessControl.h
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
// Copyright (c) Microsoft Corporation and Contributors.
|
||||||
|
// Licensed under the MIT License.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <Windows.h>
|
||||||
|
|
||||||
|
struct AppContainerNameAndAccess
|
||||||
|
{
|
||||||
|
PCWSTR appContainerName;
|
||||||
|
UINT32 accessMask;
|
||||||
|
};
|
||||||
|
|
||||||
|
STDAPI GetSecurityDescriptorForAppContainerNames(
|
||||||
|
UINT32 accessRequestCount,
|
||||||
|
_In_reads_(accessRequestCount) const AppContainerNameAndAccess* accessRequests,
|
||||||
|
_In_opt_ PSID principal,
|
||||||
|
UINT32 principalAccessMask,
|
||||||
|
_Outptr_ PSECURITY_DESCRIPTOR* securityDescriptor,
|
||||||
|
_Out_opt_ UINT32* securityDescriptorSize
|
||||||
|
);
|
||||||
48014
Sources/CWinAppSDK/nuget/include/WebView2.h
Normal file
48014
Sources/CWinAppSDK/nuget/include/WebView2.h
Normal file
File diff suppressed because it is too large
Load Diff
71
Sources/CWinAppSDK/nuget/include/WindowsAppRuntimeInsights.h
Normal file
71
Sources/CWinAppSDK/nuget/include/WindowsAppRuntimeInsights.h
Normal file
@ -0,0 +1,71 @@
|
|||||||
|
// Copyright (c) Microsoft Corporation and Contributors.
|
||||||
|
// Licensed under the MIT License.
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#if __has_include(<wil/tracelogging.h>)
|
||||||
|
#ifndef __WINDOWSAPPRUNTIMEINSIGHTS_INCLUDED
|
||||||
|
#define __WINDOWSAPPRUNTIMEINSIGHTS_INCLUDED
|
||||||
|
|
||||||
|
#ifdef __WIL_TRACELOGGING_H_INCLUDED
|
||||||
|
#error "WIL Tracelogging.h must not be explicitly included when including this file"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <wil/resource.h>
|
||||||
|
#include <string>
|
||||||
|
namespace Microsoft::WindowsAppRuntime::Insights
|
||||||
|
{
|
||||||
|
class RuntimeInformation
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
static std::string WindowsAppRuntimeVersion()
|
||||||
|
{
|
||||||
|
const uint32_t c_versionResourceId{ 10000 };
|
||||||
|
static std::string version{ LoadStringFromResource(c_versionResourceId) };
|
||||||
|
return version;
|
||||||
|
}
|
||||||
|
|
||||||
|
static std::string WindowsAppRuntimeChannel()
|
||||||
|
{
|
||||||
|
const uint32_t c_channelResourceId{ 10001 };
|
||||||
|
static std::string channel{ LoadStringFromResource(c_channelResourceId) };
|
||||||
|
return channel;
|
||||||
|
}
|
||||||
|
|
||||||
|
private:
|
||||||
|
static std::string LoadStringFromResource(uint32_t id)
|
||||||
|
{
|
||||||
|
const uint32_t c_ResourceMaxLength{ 100 };
|
||||||
|
char resourceValue[c_ResourceMaxLength]{};
|
||||||
|
static wil::unique_hmodule module{ LoadResourceModule() };
|
||||||
|
if (module)
|
||||||
|
{
|
||||||
|
const auto resourceValueLength{ ::LoadStringA(module.get(), id, resourceValue, ARRAYSIZE(resourceValue)) };
|
||||||
|
LOG_LAST_ERROR_IF_MSG(resourceValueLength == 0, "Failed to load resource string. id: %u", id);
|
||||||
|
}
|
||||||
|
return resourceValue;
|
||||||
|
}
|
||||||
|
|
||||||
|
static wil::unique_hmodule LoadResourceModule()
|
||||||
|
{
|
||||||
|
const PCWSTR c_resourceDllName{ L"Microsoft.WindowsAppRuntime.Insights.Resource.dll" };
|
||||||
|
wil::unique_hmodule resourceDllHandle(::LoadLibraryW(c_resourceDllName));
|
||||||
|
LOG_LAST_ERROR_IF_NULL_MSG(resourceDllHandle, "Unable to load resource dll. %ls", c_resourceDllName);
|
||||||
|
return resourceDllHandle;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
#define _GENERIC_PARTB_FIELDS_ENABLED \
|
||||||
|
TraceLoggingStruct(4, "COMMON_WINDOWSAPPSDK_PARAMS"), \
|
||||||
|
TraceLoggingString(::Microsoft::WindowsAppRuntime::Insights::RuntimeInformation::WindowsAppRuntimeVersion().c_str(), "Version"), \
|
||||||
|
TraceLoggingString(::Microsoft::WindowsAppRuntime::Insights::RuntimeInformation::WindowsAppRuntimeChannel().c_str(), "WindowsAppSDKChannel"), \
|
||||||
|
TraceLoggingBool(wil::details::IsDebuggerPresent(), "IsDebugging"), \
|
||||||
|
TraceLoggingBool(true, "UTCReplace_AppSessionGuid")
|
||||||
|
|
||||||
|
#include <wil/tracelogging.h>
|
||||||
|
|
||||||
|
#endif // __WINDOWSAPPRUNTIMEINSIGHTS_INCLUDED
|
||||||
|
#else
|
||||||
|
#error "WIL package must be referenced before including this header"
|
||||||
|
#endif
|
||||||
285
Sources/CWinAppSDK/nuget/include/WindowsAppSDK-VersionInfo.h
Normal file
285
Sources/CWinAppSDK/nuget/include/WindowsAppSDK-VersionInfo.h
Normal file
@ -0,0 +1,285 @@
|
|||||||
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
|
// Licensed under the MIT License. See LICENSE in the project root for license information.
|
||||||
|
|
||||||
|
#ifndef __WINDOWSAPPSDK_VERSIONINFO_H__
|
||||||
|
#define __WINDOWSAPPSDK_VERSIONINFO_H__
|
||||||
|
|
||||||
|
// Release information
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_MAJOR 1
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_MINOR 5
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_PATCH 0
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_MAJORMINOR 0x00010005
|
||||||
|
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_CHANNEL "preview"
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_CHANNEL_W L"preview"
|
||||||
|
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_VERSION_TAG "preview1"
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_VERSION_TAG_W L"preview1"
|
||||||
|
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_VERSION_SHORTTAG "p1"
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_VERSION_SHORTTAG_W L"p1"
|
||||||
|
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_FORMATTED_VERSION_TAG "-preview1"
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_FORMATTED_VERSION_TAG_W L"-preview1"
|
||||||
|
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_FORMATTED_VERSION_SHORTTAG "-p1"
|
||||||
|
#define WINDOWSAPPSDK_RELEASE_FORMATTED_VERSION_SHORTTAG_W L"-p1"
|
||||||
|
|
||||||
|
// Runtime information
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_IDENTITY_PUBLISHER "CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_IDENTITY_PUBLISHER_W L"CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_IDENTITY_PUBLISHERID "8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_IDENTITY_PUBLISHERID_W L"8wekyb3d8bbwe"
|
||||||
|
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_VERSION_MAJOR 5000u
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_VERSION_MINOR 35u
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_VERSION_BUILD 2034u
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_VERSION_REVISION 0u
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_VERSION_UINT64 0x1388002307F20000u
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_VERSION_DOTQUADSTRING "5000.35.2034.0"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_VERSION_DOTQUADSTRING_W L"5000.35.2034.0"
|
||||||
|
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_FRAMEWORK_PACKAGEFAMILYNAME "Microsoft.WindowsAppRuntime.1.5-preview1_8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_FRAMEWORK_PACKAGEFAMILYNAME_W L"Microsoft.WindowsAppRuntime.1.5-preview1_8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_MAIN_PACKAGEFAMILYNAME "MicrosoftCorporationII.WinAppRuntime.Main.1.5-p1_8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_MAIN_PACKAGEFAMILYNAME_W L"MicrosoftCorporationII.WinAppRuntime.Main.1.5-p1_8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_SINGLETON_PACKAGEFAMILYNAME "MicrosoftCorporationII.WinAppRuntime.Singleton-p1_8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_SINGLETON_PACKAGEFAMILYNAME_W L"MicrosoftCorporationII.WinAppRuntime.Singleton-p1_8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_X86_PACKAGEFAMILYNAME "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x8-p1_8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_X86_PACKAGEFAMILYNAME_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x8-p1_8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_X64_PACKAGEFAMILYNAME "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x6-p1_8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_X64_PACKAGEFAMILYNAME_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x6-p1_8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_ARM64_PACKAGEFAMILYNAME "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-a6-p1_8wekyb3d8bbwe"
|
||||||
|
#define WINDOWSAPPSDK_RUNTIME_PACKAGE_DDLM_ARM64_PACKAGEFAMILYNAME_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-a6-p1_8wekyb3d8bbwe"
|
||||||
|
|
||||||
|
#ifdef RC_INVOKED
|
||||||
|
// Only first 31 characters are significant for ResourceCompiler macro names (anything beyond that's silently ignored)
|
||||||
|
// These definitions provide RC-compatible equivalents to the macros above. Here's the translation key:
|
||||||
|
// * WAS == WINDOWSAPPSDK
|
||||||
|
// * WASR == WINDOWSAPPSDK_RUNTIME
|
||||||
|
// * FMT == FORMATTED
|
||||||
|
// * STAG == SHORTTAG
|
||||||
|
// * PKG == PACKAGE
|
||||||
|
// * FAMILY == PACKAGEFAMILYNAME
|
||||||
|
|
||||||
|
// Release information
|
||||||
|
#define WAS_RELEASE_MAJOR 1
|
||||||
|
#define WAS_RELEASE_MINOR 5
|
||||||
|
#define WAS_RELEASE_PATCH 0
|
||||||
|
#define WAS_RELEASE_MAJORMINOR 0x00010005
|
||||||
|
|
||||||
|
#define WAS_RELEASE_CHANNEL "preview"
|
||||||
|
#define WAS_RELEASE_CHANNEL_W L"preview"
|
||||||
|
|
||||||
|
#define WAS_RELEASE_VERSION_TAG "preview1"
|
||||||
|
#define WAS_RELEASE_VERSION_TAG_W L"preview1"
|
||||||
|
|
||||||
|
#define WAS_RELEASE_VERSION_STAG "p1"
|
||||||
|
#define WAS_RELEASE_VERSION_STAG_W L"p1"
|
||||||
|
|
||||||
|
#define WAS_RELEASE_FMT_VERSION_TAG "-preview1"
|
||||||
|
#define WAS_RELEASE_FMT_VERSION_TAG_W L"-preview1"
|
||||||
|
|
||||||
|
#define WAS_RELEASE_FMT_VERSION_STAG "-p1"
|
||||||
|
#define WAS_RELEASE_FMT_VERSION_STAG_W L"-p1"
|
||||||
|
|
||||||
|
// Runtime information
|
||||||
|
#define WASR_IDENTITY_PUBLISHER "CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
|
||||||
|
#define WASR_IDENTITY_PUBLISHER_W L"CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US"
|
||||||
|
#define WASR_IDENTITY_PUBLISHERID "8wekyb3d8bbwe"
|
||||||
|
#define WASR_IDENTITY_PUBLISHERID_W L"8wekyb3d8bbwe"
|
||||||
|
|
||||||
|
#define WASR_VERSION_MAJOR 5000
|
||||||
|
#define WASR_VERSION_MINOR 35
|
||||||
|
#define WASR_VERSION_BUILD 2034
|
||||||
|
#define WASR_VERSION_REVISION 0
|
||||||
|
#define WASR_VERSION_UINT64 0x1388002307F20000
|
||||||
|
#define WASR_VERSION_DOTQUADSTRING "5000.35.2034.0"
|
||||||
|
#define WASR_VERSION_DOTQUADSTRING_W L"5000.35.2034.0"
|
||||||
|
|
||||||
|
#define WASR_PKG_FRAMEWORK_FAMILY "Microsoft.WindowsAppRuntime.1.5-preview1_8wekyb3d8bbwe"
|
||||||
|
#define WASR_PKG_FRAMEWORK_FAMILY_W L"Microsoft.WindowsAppRuntime.1.5-preview1_8wekyb3d8bbwe"
|
||||||
|
#define WASR_PKG_MAIN_FAMILY "MicrosoftCorporationII.WinAppRuntime.Main.1.5-p1_8wekyb3d8bbwe"
|
||||||
|
#define WASR_PKG_MAIN_FAMILY_W L"MicrosoftCorporationII.WinAppRuntime.Main.1.5-p1_8wekyb3d8bbwe"
|
||||||
|
#define WASR_PKG_SINGLETON_FAMILY "MicrosoftCorporationII.WinAppRuntime.Singleton-p1_8wekyb3d8bbwe"
|
||||||
|
#define WASR_PKG_SINGLETON_FAMILY_W L"MicrosoftCorporationII.WinAppRuntime.Singleton-p1_8wekyb3d8bbwe"
|
||||||
|
#define WASR_PKG_DDLM_X86_FAMILY "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x8-p1_8wekyb3d8bbwe"
|
||||||
|
#define WASR_PKG_DDLM_X86_FAMILY_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x8-p1_8wekyb3d8bbwe"
|
||||||
|
#define WASR_PKG_DDLM_X64_FAMILY "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x6-p1_8wekyb3d8bbwe"
|
||||||
|
#define WASR_PKG_DDLM_X64_FAMILY_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x6-p1_8wekyb3d8bbwe"
|
||||||
|
#define WASR_PKG_DDLM_ARM64_FAMILY "Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-a6-p1_8wekyb3d8bbwe"
|
||||||
|
#define WASR_PKG_DDLM_ARM64_FAMILY_W L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-a6-p1_8wekyb3d8bbwe"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
#include <stdint.h>
|
||||||
|
namespace Microsoft::WindowsAppSDK
|
||||||
|
{
|
||||||
|
/// Build-time constants for the Windows App SDK release
|
||||||
|
namespace Release
|
||||||
|
{
|
||||||
|
/// The major version of the Windows App SDK release.
|
||||||
|
constexpr uint16_t Major = 1;
|
||||||
|
|
||||||
|
/// The minor version of the Windows App SDK release.
|
||||||
|
constexpr uint16_t Minor = 5;
|
||||||
|
|
||||||
|
/// The patch version of the Windows App SDK release.
|
||||||
|
constexpr uint16_t Patch = 0;
|
||||||
|
|
||||||
|
/// The major and minor version of the Windows App SDK release, encoded as a uint32_t (0xMMMMNNNN where M=major, N=minor).
|
||||||
|
constexpr uint32_t MajorMinor = 0x00010005;
|
||||||
|
|
||||||
|
/// The Windows App SDK release's channel; for example, "preview", or empty string for stable.
|
||||||
|
constexpr PCWSTR Channel = L"preview";
|
||||||
|
|
||||||
|
/// The Windows App SDK release's version tag; for example, "preview2", or empty string for stable.
|
||||||
|
constexpr PCWSTR VersionTag = L"preview1";
|
||||||
|
|
||||||
|
/// The Windows App SDK release's short-form version tag; for example, "p2", or empty string for stable.
|
||||||
|
constexpr PCWSTR VersionShortTag = L"p1";
|
||||||
|
|
||||||
|
/// The Windows App SDK release's version tag, formatted for concatenation when constructing identifiers; for example, "-preview2", or empty string for stable.
|
||||||
|
constexpr PCWSTR FormattedVersionTag = L"-preview1";
|
||||||
|
|
||||||
|
/// The Windows App SDK release's short-form version tag, formatted for concatenation when constructing identifiers; for example, "-p2", or empty string for stable.
|
||||||
|
constexpr PCWSTR FormattedVersionShortTag = L"-p1";
|
||||||
|
}
|
||||||
|
|
||||||
|
/// Build-time constants for the Windows App SDK runtime
|
||||||
|
namespace Runtime
|
||||||
|
{
|
||||||
|
namespace Identity
|
||||||
|
{
|
||||||
|
/// The Windows App SDK runtime's package identity's Publisher.
|
||||||
|
constexpr PCWSTR Publisher = L"CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US";
|
||||||
|
|
||||||
|
/// The Windows App SDK runtime's package identity's PublisherId.
|
||||||
|
constexpr PCWSTR PublisherId = L"8wekyb3d8bbwe";
|
||||||
|
}
|
||||||
|
|
||||||
|
namespace Version
|
||||||
|
{
|
||||||
|
/// The major version of the Windows App SDK runtime; for example, 1000.
|
||||||
|
constexpr uint16_t Major = 5000;
|
||||||
|
|
||||||
|
/// The minor version of the Windows App SDK runtime; for example, 446.
|
||||||
|
constexpr uint16_t Minor = 35;
|
||||||
|
|
||||||
|
/// The build version of the Windows App SDK runtime; for example, 804.
|
||||||
|
constexpr uint16_t Build = 2034;
|
||||||
|
|
||||||
|
/// The revision version of the Windows App SDK runtime; for example, 0.
|
||||||
|
constexpr uint16_t Revision = 0;
|
||||||
|
|
||||||
|
/// The version of the Windows App SDK runtime, as a uint64l for example, 0x03E801BE03240000.
|
||||||
|
constexpr uint64_t UInt64 = 0x1388002307F20000;
|
||||||
|
|
||||||
|
/// The version of the Windows App SDK runtime, as a string (const wchar_t*); for example, "1000.446.804.0".
|
||||||
|
constexpr PCWSTR DotQuadString = L"5000.35.2034.0";
|
||||||
|
}
|
||||||
|
|
||||||
|
namespace Packages
|
||||||
|
{
|
||||||
|
namespace Framework
|
||||||
|
{
|
||||||
|
/// The Windows App SDK runtime's Framework package's family name.
|
||||||
|
constexpr PCWSTR PackageFamilyName = L"Microsoft.WindowsAppRuntime.1.5-preview1_8wekyb3d8bbwe";
|
||||||
|
}
|
||||||
|
namespace Main
|
||||||
|
{
|
||||||
|
/// The Windows App SDK runtime's Main package's family name.
|
||||||
|
constexpr PCWSTR PackageFamilyName = L"MicrosoftCorporationII.WinAppRuntime.Main.1.5-p1_8wekyb3d8bbwe";
|
||||||
|
}
|
||||||
|
namespace Singleton
|
||||||
|
{
|
||||||
|
/// The Windows App SDK runtime's Singleton package's family name.
|
||||||
|
constexpr PCWSTR PackageFamilyName = L"MicrosoftCorporationII.WinAppRuntime.Singleton-p1_8wekyb3d8bbwe";
|
||||||
|
}
|
||||||
|
namespace DDLM
|
||||||
|
{
|
||||||
|
namespace X86
|
||||||
|
{
|
||||||
|
/// The Windows App SDK runtime's Dynamic Dependency Lifetime Manager (DDLM) package's family name, for x86.
|
||||||
|
constexpr PCWSTR PackageFamilyName = L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x8-p1_8wekyb3d8bbwe";
|
||||||
|
}
|
||||||
|
namespace X64
|
||||||
|
{
|
||||||
|
/// The Windows App SDK runtime's Dynamic Dependency Lifetime Manager (DDLM) package's family name, for x64.
|
||||||
|
constexpr PCWSTR PackageFamilyName = L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-x6-p1_8wekyb3d8bbwe";
|
||||||
|
}
|
||||||
|
namespace Arm64
|
||||||
|
{
|
||||||
|
/// The Windows App SDK runtime's Dynamic Dependency Lifetime Manager (DDLM) package's family name, for arm64.
|
||||||
|
constexpr PCWSTR PackageFamilyName = L"Microsoft.WinAppRuntime.DDLM.5000.35.2034.0-a6-p1_8wekyb3d8bbwe";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// Run-time query'able version information for the Windows App SDK.
|
||||||
|
struct VersionInfo
|
||||||
|
{
|
||||||
|
/// Run-time query'able version information for the Windows App SDK release
|
||||||
|
struct Release
|
||||||
|
{
|
||||||
|
/// The major version of the Windows App SDK release.
|
||||||
|
uint16_t Major;
|
||||||
|
|
||||||
|
/// The minor version of the Windows App SDK release.
|
||||||
|
uint16_t Minor;
|
||||||
|
|
||||||
|
/// The patch version of the Windows App SDK release.
|
||||||
|
uint16_t Patch;
|
||||||
|
|
||||||
|
/// The major and minor version of the Windows App SDK release, encoded as a uint32_t (0xMMMMNNNN where M=major, N=minor).
|
||||||
|
uint32_t MajorMinor;
|
||||||
|
|
||||||
|
/// The Windows App SDK release's channel; for example, "preview", or empty string for stable.
|
||||||
|
PCWSTR Channel;
|
||||||
|
|
||||||
|
/// The Windows App SDK release's version tag; for example, "preview2", or empty string for stable.
|
||||||
|
PCWSTR VersionTag;
|
||||||
|
|
||||||
|
/// The Windows App SDK release's short-form version tag; for example, "p2", or empty string for stable.
|
||||||
|
PCWSTR VersionShortTag;
|
||||||
|
} Release;
|
||||||
|
|
||||||
|
/// Run-time query'able version information for the Windows App SDK runtime
|
||||||
|
struct Runtime
|
||||||
|
{
|
||||||
|
struct Identity
|
||||||
|
{
|
||||||
|
/// The Windows App SDK runtime's package identity's Publisher.
|
||||||
|
PCWSTR Publisher;
|
||||||
|
|
||||||
|
/// The Windows App SDK runtime's package identity's PublisherId.
|
||||||
|
PCWSTR PublisherId;
|
||||||
|
} Identity;
|
||||||
|
|
||||||
|
struct Version
|
||||||
|
{
|
||||||
|
/// The major version of the Windows App SDK runtime; for example, 1000.
|
||||||
|
uint16_t Major;
|
||||||
|
|
||||||
|
/// The minor version of the Windows App SDK runtime; for example, 446.
|
||||||
|
uint16_t Minor;
|
||||||
|
|
||||||
|
/// The build version of the Windows App SDK runtime; for example, 804.
|
||||||
|
uint16_t Build;
|
||||||
|
|
||||||
|
/// The revision version of the Windows App SDK runtime; for example, 0.
|
||||||
|
uint16_t Revision;
|
||||||
|
|
||||||
|
/// The version of the Windows App SDK runtime, as a uint64l for example, 0x03E801BE03240000.
|
||||||
|
uint64_t UInt64;
|
||||||
|
|
||||||
|
/// The version of the Windows App SDK runtime, as a string (const wchar_t*); for example, "1000.446.804.0".
|
||||||
|
PCWSTR DotQuadString;
|
||||||
|
} Version;
|
||||||
|
} Runtime;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
#endif // __cplusplus
|
||||||
|
|
||||||
|
#endif // _WINDOWSAPPSDK_VERSIONINFO_H__
|
||||||
5151
Sources/CWinAppSDK/nuget/include/dwrite.h
Normal file
5151
Sources/CWinAppSDK/nuget/include/dwrite.h
Normal file
File diff suppressed because it is too large
Load Diff
1924
Sources/CWinAppSDK/nuget/include/dwrite_1.h
Normal file
1924
Sources/CWinAppSDK/nuget/include/dwrite_1.h
Normal file
File diff suppressed because it is too large
Load Diff
980
Sources/CWinAppSDK/nuget/include/dwrite_2.h
Normal file
980
Sources/CWinAppSDK/nuget/include/dwrite_2.h
Normal file
@ -0,0 +1,980 @@
|
|||||||
|
//+--------------------------------------------------------------------------
|
||||||
|
//
|
||||||
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
|
//
|
||||||
|
// Abstract:
|
||||||
|
// DirectX Typography Services public API definitions.
|
||||||
|
//
|
||||||
|
//----------------------------------------------------------------------------
|
||||||
|
|
||||||
|
#ifndef DWRITE_2_H_INCLUDED
|
||||||
|
#define DWRITE_2_H_INCLUDED
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include "dwrite_1.h"
|
||||||
|
|
||||||
|
|
||||||
|
interface IDWriteFontFallback;
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// How to align glyphs to the margin.
|
||||||
|
/// </summary>
|
||||||
|
enum DWRITE_OPTICAL_ALIGNMENT
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Align to the default metrics of the glyph.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_OPTICAL_ALIGNMENT_NONE,
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Align glyphs to the margins. Without this, some small whitespace
|
||||||
|
/// may be present between the text and the margin from the glyph's side
|
||||||
|
/// bearing values. Note that glyphs may still overhang outside the
|
||||||
|
/// margin, such as flourishes or italic slants.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_OPTICAL_ALIGNMENT_NO_SIDE_BEARINGS,
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Whether to enable grid-fitting of glyph outlines (a.k.a. hinting).
|
||||||
|
/// </summary>
|
||||||
|
enum DWRITE_GRID_FIT_MODE
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Choose grid fitting base on the font's gasp table information.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_GRID_FIT_MODE_DEFAULT,
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Always disable grid fitting, using the ideal glyph outlines.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_GRID_FIT_MODE_DISABLED,
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Enable grid fitting, adjusting glyph outlines for device pixel display.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_GRID_FIT_MODE_ENABLED
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Overall metrics associated with text after layout.
|
||||||
|
/// All coordinates are in device independent pixels (DIPs).
|
||||||
|
/// </summary>
|
||||||
|
struct DWRITE_TEXT_METRICS1 : DWRITE_TEXT_METRICS
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// The height of the formatted text taking into account the
|
||||||
|
/// trailing whitespace at the end of each line, which will
|
||||||
|
/// matter for vertical reading directions.
|
||||||
|
/// </summary>
|
||||||
|
FLOAT heightIncludingTrailingWhitespace;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The text renderer interface represents a set of application-defined
|
||||||
|
/// callbacks that perform rendering of text, inline objects, and decorations
|
||||||
|
/// such as underlines.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_BEGIN_INTERFACE(IDWriteTextRenderer1, "D3E0E934-22A0-427E-AAE4-7D9574B59DB1") : IDWriteTextRenderer
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// IDWriteTextLayout::Draw calls this function to instruct the client to
|
||||||
|
/// render a run of glyphs.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="clientDrawingContext">The context passed to
|
||||||
|
/// IDWriteTextLayout::Draw.</param>
|
||||||
|
/// <param name="baselineOriginX">X-coordinate of the baseline.</param>
|
||||||
|
/// <param name="baselineOriginY">Y-coordinate of the baseline.</param>
|
||||||
|
/// <param name="orientationAngle">Orientation of the glyph run.</param>
|
||||||
|
/// <param name="measuringMode">Specifies measuring method for glyphs in
|
||||||
|
/// the run. Renderer implementations may choose different rendering
|
||||||
|
/// modes for given measuring methods, but best results are seen when
|
||||||
|
/// the rendering mode matches the corresponding measuring mode:
|
||||||
|
/// DWRITE_RENDERING_MODE_CLEARTYPE_NATURAL for DWRITE_MEASURING_MODE_NATURAL
|
||||||
|
/// DWRITE_RENDERING_MODE_CLEARTYPE_GDI_CLASSIC for DWRITE_MEASURING_MODE_GDI_CLASSIC
|
||||||
|
/// DWRITE_RENDERING_MODE_CLEARTYPE_GDI_NATURAL for DWRITE_MEASURING_MODE_GDI_NATURAL
|
||||||
|
/// </param>
|
||||||
|
/// <param name="glyphRun">The glyph run to draw.</param>
|
||||||
|
/// <param name="glyphRunDescription">Properties of the characters
|
||||||
|
/// associated with this run.</param>
|
||||||
|
/// <param name="clientDrawingEffect">The drawing effect set in
|
||||||
|
/// IDWriteTextLayout::SetDrawingEffect.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
/// <remarks>
|
||||||
|
/// If a non-identity orientation is passed, the glyph run should be
|
||||||
|
/// rotated around the given baseline x and y coordinates. The function
|
||||||
|
/// IDWriteAnalyzer2::GetGlyphOrientationTransform will return the
|
||||||
|
/// necessary transform for you, which can be combined with any existing
|
||||||
|
/// world transform on the drawing context.
|
||||||
|
/// </remarks>
|
||||||
|
STDMETHOD(DrawGlyphRun)(
|
||||||
|
_In_opt_ void* clientDrawingContext,
|
||||||
|
FLOAT baselineOriginX,
|
||||||
|
FLOAT baselineOriginY,
|
||||||
|
DWRITE_GLYPH_ORIENTATION_ANGLE orientationAngle,
|
||||||
|
DWRITE_MEASURING_MODE measuringMode,
|
||||||
|
_In_ DWRITE_GLYPH_RUN const* glyphRun,
|
||||||
|
_In_ DWRITE_GLYPH_RUN_DESCRIPTION const* glyphRunDescription,
|
||||||
|
_In_opt_ IUnknown* clientDrawingEffect
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// IDWriteTextLayout::Draw calls this function to instruct the client to draw
|
||||||
|
/// an underline.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="clientDrawingContext">The context passed to
|
||||||
|
/// IDWriteTextLayout::Draw.</param>
|
||||||
|
/// <param name="baselineOriginX">X-coordinate of the baseline.</param>
|
||||||
|
/// <param name="baselineOriginY">Y-coordinate of the baseline.</param>
|
||||||
|
/// <param name="orientationAngle">Orientation of the underline.</param>
|
||||||
|
/// <param name="underline">Underline logical information.</param>
|
||||||
|
/// <param name="clientDrawingEffect">The drawing effect set in
|
||||||
|
/// IDWriteTextLayout::SetDrawingEffect.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
/// <remarks>
|
||||||
|
/// A single underline can be broken into multiple calls, depending on
|
||||||
|
/// how the formatting changes attributes. If font sizes/styles change
|
||||||
|
/// within an underline, the thickness and offset will be averaged
|
||||||
|
/// weighted according to characters.
|
||||||
|
///
|
||||||
|
/// To get the correct top coordinate of the underline rect, add
|
||||||
|
/// underline::offset to the baseline's Y. Otherwise the underline will
|
||||||
|
/// be immediately under the text. The x coordinate will always be passed
|
||||||
|
/// as the left side, regardless of text directionality. This simplifies
|
||||||
|
/// drawing and reduces the problem of round-off that could potentially
|
||||||
|
/// cause gaps or a double stamped alpha blend. To avoid alpha overlap,
|
||||||
|
/// round the end points to the nearest device pixel.
|
||||||
|
/// </remarks>
|
||||||
|
STDMETHOD(DrawUnderline)(
|
||||||
|
_In_opt_ void* clientDrawingContext,
|
||||||
|
FLOAT baselineOriginX,
|
||||||
|
FLOAT baselineOriginY,
|
||||||
|
DWRITE_GLYPH_ORIENTATION_ANGLE orientationAngle,
|
||||||
|
_In_ DWRITE_UNDERLINE const* underline,
|
||||||
|
_In_opt_ IUnknown* clientDrawingEffect
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// IDWriteTextLayout::Draw calls this function to instruct the client to draw
|
||||||
|
/// a strikethrough.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="clientDrawingContext">The context passed to
|
||||||
|
/// IDWriteTextLayout::Draw.</param>
|
||||||
|
/// <param name="baselineOriginX">X-coordinate of the baseline.</param>
|
||||||
|
/// <param name="baselineOriginY">Y-coordinate of the baseline.</param>
|
||||||
|
/// <param name="orientationAngle">Orientation of the strikethrough.</param>
|
||||||
|
/// <param name="strikethrough">Strikethrough logical information.</param>
|
||||||
|
/// <param name="clientDrawingEffect">The drawing effect set in
|
||||||
|
/// IDWriteTextLayout::SetDrawingEffect.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
/// <remarks>
|
||||||
|
/// A single strikethrough can be broken into multiple calls, depending on
|
||||||
|
/// how the formatting changes attributes. Strikethrough is not averaged
|
||||||
|
/// across font sizes/styles changes.
|
||||||
|
/// To get the correct top coordinate of the strikethrough rect,
|
||||||
|
/// add strikethrough::offset to the baseline's Y.
|
||||||
|
/// Like underlines, the x coordinate will always be passed as the left side,
|
||||||
|
/// regardless of text directionality.
|
||||||
|
/// </remarks>
|
||||||
|
STDMETHOD(DrawStrikethrough)(
|
||||||
|
_In_opt_ void* clientDrawingContext,
|
||||||
|
FLOAT baselineOriginX,
|
||||||
|
FLOAT baselineOriginY,
|
||||||
|
DWRITE_GLYPH_ORIENTATION_ANGLE orientationAngle,
|
||||||
|
_In_ DWRITE_STRIKETHROUGH const* strikethrough,
|
||||||
|
_In_opt_ IUnknown* clientDrawingEffect
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// IDWriteTextLayout::Draw calls this application callback when it needs to
|
||||||
|
/// draw an inline object.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="clientDrawingContext">The context passed to
|
||||||
|
/// IDWriteTextLayout::Draw.</param>
|
||||||
|
/// <param name="originX">X-coordinate at the top-left corner of the
|
||||||
|
/// inline object.</param>
|
||||||
|
/// <param name="originY">Y-coordinate at the top-left corner of the
|
||||||
|
/// inline object.</param>
|
||||||
|
/// <param name="orientationAngle">Orientation of the inline object.</param>
|
||||||
|
/// <param name="inlineObject">The object set using IDWriteTextLayout::SetInlineObject.</param>
|
||||||
|
/// <param name="isSideways">The object should be drawn on its side.</param>
|
||||||
|
/// <param name="isRightToLeft">The object is in an right-to-left context
|
||||||
|
/// and should be drawn flipped.</param>
|
||||||
|
/// <param name="clientDrawingEffect">The drawing effect set in
|
||||||
|
/// IDWriteTextLayout::SetDrawingEffect.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
/// <remarks>
|
||||||
|
/// The right-to-left flag is a hint to draw the appropriate visual for
|
||||||
|
/// that reading direction. For example, it would look strange to draw an
|
||||||
|
/// arrow pointing to the right to indicate a submenu. The sideways flag
|
||||||
|
/// similarly hints that the object is drawn in a different orientation.
|
||||||
|
/// If a non-identity orientation is passed, the top left of the inline
|
||||||
|
/// object should be rotated around the given x and y coordinates.
|
||||||
|
/// IDWriteAnalyzer2::GetGlyphOrientationTransform returns the necessary
|
||||||
|
/// transform for this.
|
||||||
|
/// </remarks>
|
||||||
|
STDMETHOD(DrawInlineObject)(
|
||||||
|
_In_opt_ void* clientDrawingContext,
|
||||||
|
FLOAT originX,
|
||||||
|
FLOAT originY,
|
||||||
|
DWRITE_GLYPH_ORIENTATION_ANGLE orientationAngle,
|
||||||
|
_In_ IDWriteInlineObject* inlineObject,
|
||||||
|
BOOL isSideways,
|
||||||
|
BOOL isRightToLeft,
|
||||||
|
_In_opt_ IUnknown* clientDrawingEffect
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
using IDWriteTextRenderer::DrawGlyphRun;
|
||||||
|
using IDWriteTextRenderer::DrawUnderline;
|
||||||
|
using IDWriteTextRenderer::DrawStrikethrough;
|
||||||
|
using IDWriteTextRenderer::DrawInlineObject;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The format of text used for text layout.
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// This object may not be thread-safe and it may carry the state of text format change.
|
||||||
|
/// </remarks>
|
||||||
|
DWRITE_BEGIN_INTERFACE(IDWriteTextFormat1, "5F174B49-0D8B-4CFB-8BCA-F1CCE9D06C67") : IDWriteTextFormat
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Set the preferred orientation of glyphs when using a vertical reading direction.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="glyphOrientation">Preferred glyph orientation.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(SetVerticalGlyphOrientation)(
|
||||||
|
DWRITE_VERTICAL_GLYPH_ORIENTATION glyphOrientation
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get the preferred orientation of glyphs when using a vertical reading
|
||||||
|
/// direction.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD_(DWRITE_VERTICAL_GLYPH_ORIENTATION, GetVerticalGlyphOrientation)() PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Set whether or not the last word on the last line is wrapped.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="isLastLineWrappingEnabled">Line wrapping option.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(SetLastLineWrapping)(
|
||||||
|
BOOL isLastLineWrappingEnabled
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get whether or not the last word on the last line is wrapped.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD_(BOOL, GetLastLineWrapping)() PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Set how the glyphs align to the edges the margin. Default behavior is
|
||||||
|
/// to align glyphs using their default glyphs metrics which include side
|
||||||
|
/// bearings.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="opticalAlignment">Optical alignment option.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(SetOpticalAlignment)(
|
||||||
|
DWRITE_OPTICAL_ALIGNMENT opticalAlignment
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get how the glyphs align to the edges the margin.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD_(DWRITE_OPTICAL_ALIGNMENT, GetOpticalAlignment)() PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Apply a custom font fallback onto layout. If none is specified,
|
||||||
|
/// layout uses the system fallback list.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="fontFallback">Custom font fallback created from
|
||||||
|
/// IDWriteFontFallbackBuilder::CreateFontFallback or from
|
||||||
|
/// IDWriteFactory2::GetSystemFontFallback.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(SetFontFallback)(
|
||||||
|
IDWriteFontFallback* fontFallback
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get the current font fallback object.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD(GetFontFallback)(
|
||||||
|
_COM_Outptr_ IDWriteFontFallback** fontFallback
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The text layout interface represents a block of text after it has
|
||||||
|
/// been fully analyzed and formatted.
|
||||||
|
///
|
||||||
|
/// All coordinates are in device independent pixels (DIPs).
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_BEGIN_INTERFACE(IDWriteTextLayout2, "1093C18F-8D5E-43F0-B064-0917311B525E") : IDWriteTextLayout1
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// GetMetrics retrieves overall metrics for the formatted string.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="textMetrics">The returned metrics.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
/// <remarks>
|
||||||
|
/// Drawing effects like underline and strikethrough do not contribute
|
||||||
|
/// to the text size, which is essentially the sum of advance widths and
|
||||||
|
/// line heights. Additionally, visible swashes and other graphic
|
||||||
|
/// adornments may extend outside the returned width and height.
|
||||||
|
/// </remarks>
|
||||||
|
STDMETHOD(GetMetrics)(
|
||||||
|
_Out_ DWRITE_TEXT_METRICS1* textMetrics
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
using IDWriteTextLayout::GetMetrics;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Set the preferred orientation of glyphs when using a vertical reading direction.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="glyphOrientation">Preferred glyph orientation.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(SetVerticalGlyphOrientation)(
|
||||||
|
DWRITE_VERTICAL_GLYPH_ORIENTATION glyphOrientation
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get the preferred orientation of glyphs when using a vertical reading
|
||||||
|
/// direction.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD_(DWRITE_VERTICAL_GLYPH_ORIENTATION, GetVerticalGlyphOrientation)() PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Set whether or not the last word on the last line is wrapped.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="isLastLineWrappingEnabled">Line wrapping option.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(SetLastLineWrapping)(
|
||||||
|
BOOL isLastLineWrappingEnabled
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get whether or not the last word on the last line is wrapped.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD_(BOOL, GetLastLineWrapping)() PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Set how the glyphs align to the edges the margin. Default behavior is
|
||||||
|
/// to align glyphs using their default glyphs metrics which include side
|
||||||
|
/// bearings.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="opticalAlignment">Optical alignment option.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(SetOpticalAlignment)(
|
||||||
|
DWRITE_OPTICAL_ALIGNMENT opticalAlignment
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get how the glyphs align to the edges the margin.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD_(DWRITE_OPTICAL_ALIGNMENT, GetOpticalAlignment)() PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Apply a custom font fallback onto layout. If none is specified,
|
||||||
|
/// layout uses the system fallback list.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="fontFallback">Custom font fallback created from
|
||||||
|
/// IDWriteFontFallbackBuilder::CreateFontFallback or
|
||||||
|
/// IDWriteFactory2::GetSystemFontFallback.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(SetFontFallback)(
|
||||||
|
IDWriteFontFallback* fontFallback
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Get the current font fallback object.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD(GetFontFallback)(
|
||||||
|
_COM_Outptr_ IDWriteFontFallback** fontFallback
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The text analyzer interface represents a set of application-defined
|
||||||
|
/// callbacks that perform rendering of text, inline objects, and decorations
|
||||||
|
/// such as underlines.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_BEGIN_INTERFACE(IDWriteTextAnalyzer2, "553A9FF3-5693-4DF7-B52B-74806F7F2EB9") : IDWriteTextAnalyzer1
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Returns 2x3 transform matrix for the respective angle to draw the
|
||||||
|
/// glyph run or other object.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="glyphOrientationAngle">The angle reported to one of the application callbacks,
|
||||||
|
/// including IDWriteTextAnalysisSink1::SetGlyphOrientation and IDWriteTextRenderer1::Draw*.</param>
|
||||||
|
/// <param name="isSideways">Whether the run's glyphs are sideways or not.</param>
|
||||||
|
/// <param name="originX">X origin of the element, be it a glyph run or underline or other.</param>
|
||||||
|
/// <param name="originY">Y origin of the element, be it a glyph run or underline or other.</param>
|
||||||
|
/// <param name="transform">Returned transform.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
/// <remarks>
|
||||||
|
/// This rotates around the given origin x and y, returning a translation component
|
||||||
|
/// such that the glyph run, text decoration, or inline object is drawn with the
|
||||||
|
/// right orientation at the expected coordinate.
|
||||||
|
/// </remarks>
|
||||||
|
STDMETHOD(GetGlyphOrientationTransform)(
|
||||||
|
DWRITE_GLYPH_ORIENTATION_ANGLE glyphOrientationAngle,
|
||||||
|
BOOL isSideways,
|
||||||
|
FLOAT originX,
|
||||||
|
FLOAT originY,
|
||||||
|
_Out_ DWRITE_MATRIX* transform
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Returns a list of typographic feature tags for the given script and language.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="fontFace">The font face to get features from.</param>
|
||||||
|
/// <param name="scriptAnalysis">Script analysis result from AnalyzeScript.</param>
|
||||||
|
/// <param name="localeName">The locale to use when selecting the feature,
|
||||||
|
/// such en-us or ja-jp.</param>
|
||||||
|
/// <param name="maxTagCount">Maximum tag count.</param>
|
||||||
|
/// <param name="actualTagCount">Actual tag count. If greater than
|
||||||
|
/// maxTagCount, E_NOT_SUFFICIENT_BUFFER is returned, and the call
|
||||||
|
/// should be retried with a larger buffer.</param>
|
||||||
|
/// <param name="tags">Feature tag list.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(GetTypographicFeatures)(
|
||||||
|
IDWriteFontFace* fontFace,
|
||||||
|
DWRITE_SCRIPT_ANALYSIS scriptAnalysis,
|
||||||
|
_In_opt_z_ WCHAR const* localeName,
|
||||||
|
UINT32 maxTagCount,
|
||||||
|
_Out_ UINT32* actualTagCount,
|
||||||
|
_Out_writes_(maxTagCount) DWRITE_FONT_FEATURE_TAG* tags
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Returns an array of which glyphs are affected by a given feature.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="fontFace">The font face to read glyph information from.</param>
|
||||||
|
/// <param name="scriptAnalysis">Script analysis result from AnalyzeScript.</param>
|
||||||
|
/// <param name="localeName">The locale to use when selecting the feature,
|
||||||
|
/// such en-us or ja-jp.</param>
|
||||||
|
/// <param name="featureTag">OpenType feature name to use, which may be one
|
||||||
|
/// of the DWRITE_FONT_FEATURE_TAG values or a custom feature using
|
||||||
|
/// DWRITE_MAKE_OPENTYPE_TAG.</param>
|
||||||
|
/// <param name="glyphCount">Number of glyph indices to check.</param>
|
||||||
|
/// <param name="glyphIndices">Glyph indices to check for feature application.</param>
|
||||||
|
/// <param name="featureApplies">Output of which glyphs are affected by the
|
||||||
|
/// feature, where for each glyph affected, the respective array index
|
||||||
|
/// will be 1. The result is returned per-glyph without regard to
|
||||||
|
/// neighboring context of adjacent glyphs.</param>
|
||||||
|
/// </remarks>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(CheckTypographicFeature)(
|
||||||
|
IDWriteFontFace* fontFace,
|
||||||
|
DWRITE_SCRIPT_ANALYSIS scriptAnalysis,
|
||||||
|
_In_opt_z_ WCHAR const* localeName,
|
||||||
|
DWRITE_FONT_FEATURE_TAG featureTag,
|
||||||
|
UINT32 glyphCount,
|
||||||
|
_In_reads_(glyphCount) UINT16 const* glyphIndices,
|
||||||
|
_Out_writes_(glyphCount) UINT8* featureApplies
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
using IDWriteTextAnalyzer1::GetGlyphOrientationTransform;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// A font fallback definition used for mapping characters to fonts capable of
|
||||||
|
/// supporting them.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_BEGIN_INTERFACE(IDWriteFontFallback, "EFA008F9-F7A1-48BF-B05C-F224713CC0FF") : IUnknown
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Determines an appropriate font to use to render the range of text.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="source">The text source implementation holds the text and
|
||||||
|
/// locale.</param>
|
||||||
|
/// <param name="textLength">Length of the text to analyze.</param>
|
||||||
|
/// <param name="baseFontCollection">Default font collection to use.</param>
|
||||||
|
/// <param name="baseFamilyName">Family name of the base font. If you pass
|
||||||
|
/// null, no matching will be done against the family.</param>
|
||||||
|
/// <param name="baseWeight">Desired weight.</param>
|
||||||
|
/// <param name="baseStyle">Desired style.</param>
|
||||||
|
/// <param name="baseStretch">Desired stretch.</param>
|
||||||
|
/// <param name="mappedLength">Length of text mapped to the mapped font.
|
||||||
|
/// This will always be less or equal to the input text length and
|
||||||
|
/// greater than zero (if the text length is non-zero) so that the
|
||||||
|
/// caller advances at least one character each call.</param>
|
||||||
|
/// <param name="mappedFont">The font that should be used to render the
|
||||||
|
/// first mappedLength characters of the text. If it returns NULL,
|
||||||
|
/// then no known font can render the text, and mappedLength is the
|
||||||
|
/// number of unsupported characters to skip.</param>
|
||||||
|
/// <param name="scale">Scale factor to multiply the em size of the
|
||||||
|
/// returned font by.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(MapCharacters)(
|
||||||
|
IDWriteTextAnalysisSource* analysisSource,
|
||||||
|
UINT32 textPosition,
|
||||||
|
UINT32 textLength,
|
||||||
|
_In_opt_ IDWriteFontCollection* baseFontCollection,
|
||||||
|
_In_opt_z_ WCHAR const* baseFamilyName,
|
||||||
|
DWRITE_FONT_WEIGHT baseWeight,
|
||||||
|
DWRITE_FONT_STYLE baseStyle,
|
||||||
|
DWRITE_FONT_STRETCH baseStretch,
|
||||||
|
_Out_range_(0, textLength) UINT32* mappedLength,
|
||||||
|
_COM_Outptr_result_maybenull_ IDWriteFont** mappedFont,
|
||||||
|
_Out_ FLOAT* scale
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Builder used to create a font fallback definition by appending a series of
|
||||||
|
/// fallback mappings, followed by a creation call.
|
||||||
|
/// </summary>
|
||||||
|
/// <remarks>
|
||||||
|
/// This object may not be thread-safe.
|
||||||
|
/// </remarks>
|
||||||
|
DWRITE_BEGIN_INTERFACE(IDWriteFontFallbackBuilder, "FD882D06-8ABA-4FB8-B849-8BE8B73E14DE") : IUnknown
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Appends a single mapping to the list. Call this once for each additional mapping.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="ranges">Unicode ranges that apply to this mapping.</param>
|
||||||
|
/// <param name="rangesCount">Number of Unicode ranges.</param>
|
||||||
|
/// <param name="localeName">Locale of the context (e.g. document locale).</param>
|
||||||
|
/// <param name="baseFamilyName">Base family name to match against, if applicable.</param>
|
||||||
|
/// <param name="fontCollection">Explicit font collection for this mapping (optional).</param>
|
||||||
|
/// <param name="targetFamilyNames">List of target family name strings.</param>
|
||||||
|
/// <param name="targetFamilyNamesCount">Number of target family names.</param>
|
||||||
|
/// <param name="scale">Scale factor to multiply the result target font by.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(AddMapping)(
|
||||||
|
_In_reads_(rangesCount) DWRITE_UNICODE_RANGE const* ranges,
|
||||||
|
UINT32 rangesCount,
|
||||||
|
_In_reads_(targetFamilyNamesCount) WCHAR const** targetFamilyNames,
|
||||||
|
UINT32 targetFamilyNamesCount,
|
||||||
|
_In_opt_ IDWriteFontCollection* fontCollection = NULL,
|
||||||
|
_In_opt_z_ WCHAR const* localeName = NULL,
|
||||||
|
_In_opt_z_ WCHAR const* baseFamilyName = NULL,
|
||||||
|
FLOAT scale = 1.0f
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Appends all the mappings from an existing font fallback object.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="fontFallback">Font fallback to read mappings from.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(AddMappings)(
|
||||||
|
IDWriteFontFallback* fontFallback
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Creates the finalized fallback object from the mappings added.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="fontFallback">Created fallback list.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(CreateFontFallback)(
|
||||||
|
_COM_Outptr_ IDWriteFontFallback** fontFallback
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// DWRITE_COLOR_F
|
||||||
|
/// </summary>
|
||||||
|
#ifndef D3DCOLORVALUE_DEFINED
|
||||||
|
|
||||||
|
typedef struct _D3DCOLORVALUE {
|
||||||
|
union {
|
||||||
|
FLOAT r;
|
||||||
|
FLOAT dvR;
|
||||||
|
};
|
||||||
|
union {
|
||||||
|
FLOAT g;
|
||||||
|
FLOAT dvG;
|
||||||
|
};
|
||||||
|
union {
|
||||||
|
FLOAT b;
|
||||||
|
FLOAT dvB;
|
||||||
|
};
|
||||||
|
union {
|
||||||
|
FLOAT a;
|
||||||
|
FLOAT dvA;
|
||||||
|
};
|
||||||
|
} D3DCOLORVALUE;
|
||||||
|
|
||||||
|
#define D3DCOLORVALUE_DEFINED
|
||||||
|
#endif // D3DCOLORVALUE_DEFINED
|
||||||
|
|
||||||
|
typedef D3DCOLORVALUE DWRITE_COLOR_F;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The IDWriteFont interface represents a physical font in a font collection.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_BEGIN_INTERFACE(IDWriteFont2, "29748ed6-8c9c-4a6a-be0b-d912e8538944") : IDWriteFont1
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Returns TRUE if the font contains tables that can provide color information
|
||||||
|
/// (including COLR, CPAL, SVG, CBDT, sbix tables), or FALSE if not. Note that
|
||||||
|
/// TRUE is returned even in the case when the font tables contain only grayscale
|
||||||
|
/// images.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD_(BOOL, IsColorFont)() PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The interface that represents an absolute reference to a font face.
|
||||||
|
/// It contains font face type, appropriate file references and face identification data.
|
||||||
|
/// Various font data such as metrics, names and glyph outlines is obtained from IDWriteFontFace.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_BEGIN_INTERFACE(IDWriteFontFace2, "d8b768ff-64bc-4e66-982b-ec8e87f693f7") : IDWriteFontFace1
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Returns TRUE if the font contains tables that can provide color information
|
||||||
|
/// (including COLR, CPAL, SVG, CBDT, sbix tables), or FALSE if not. Note that
|
||||||
|
/// TRUE is returned even in the case when the font tables contain only grayscale
|
||||||
|
/// images.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD_(BOOL, IsColorFont)() PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Returns the number of color palettes defined by the font. The return
|
||||||
|
/// value is zero if the font has no color information. Color fonts must
|
||||||
|
/// have at least one palette, with palette index zero being the default.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD_(UINT32, GetColorPaletteCount)() PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Returns the number of entries in each color palette. All color palettes
|
||||||
|
/// in a font have the same number of palette entries. The return value is
|
||||||
|
/// zero if the font has no color information.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD_(UINT32, GetPaletteEntryCount)() PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Reads color values from the font's color palette.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="colorPaletteIndex">Zero-based index of the color palette. If the
|
||||||
|
/// font does not have a palette with the specified index, the method returns
|
||||||
|
/// DWRITE_E_NOCOLOR.<param>
|
||||||
|
/// <param name="firstEntryIndex">Zero-based index of the first palette entry
|
||||||
|
/// to read.</param>
|
||||||
|
/// <param name="entryCount">Number of palette entries to read.</param>
|
||||||
|
/// <param name="paletteEntries">Array that receives the color values.<param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// The return value is E_INVALIDARG if firstEntryIndex + entryCount is greater
|
||||||
|
/// than the actual number of palette entries as returned by GetPaletteEntryCount.
|
||||||
|
/// The return value is DWRITE_E_NOCOLOR if the font does not have a palette
|
||||||
|
/// with the specified palette index.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(GetPaletteEntries)(
|
||||||
|
UINT32 colorPaletteIndex,
|
||||||
|
UINT32 firstEntryIndex,
|
||||||
|
UINT32 entryCount,
|
||||||
|
_Out_writes_(entryCount) DWRITE_COLOR_F* paletteEntries
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Determines the recommended text rendering and grid-fit mode to be used based on the
|
||||||
|
/// font, size, world transform, and measuring mode.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="fontEmSize">Logical font size in DIPs.</param>
|
||||||
|
/// <param name="dpiX">Number of pixels per logical inch in the horizontal direction.</param>
|
||||||
|
/// <param name="dpiY">Number of pixels per logical inch in the vertical direction.</param>
|
||||||
|
/// <param name="transform">Specifies the world transform.</param>
|
||||||
|
/// <param name="outlineThreshold">Specifies the quality of the graphics system's outline rendering,
|
||||||
|
/// affects the size threshold above which outline rendering is used.</param>
|
||||||
|
/// <param name="measuringMode">Specifies the method used to measure during text layout. For proper
|
||||||
|
/// glyph spacing, the function returns a rendering mode that is compatible with the specified
|
||||||
|
/// measuring mode.</param>
|
||||||
|
/// <param name="renderingParams">Rendering parameters object. This parameter is necessary in case the rendering parameters
|
||||||
|
/// object overrides the rendering mode.</param>
|
||||||
|
/// <param name="renderingMode">Receives the recommended rendering mode.</param>
|
||||||
|
/// <param name="gridFitMode">Receives the recommended grid-fit mode.</param>
|
||||||
|
/// <remarks>
|
||||||
|
/// This method should be used to determine the actual rendering mode in cases where the rendering
|
||||||
|
/// mode of the rendering params object is DWRITE_RENDERING_MODE_DEFAULT, and the actual grid-fit
|
||||||
|
/// mode when the rendering params object is DWRITE_GRID_FIT_MODE_DEFAULT.
|
||||||
|
/// </remarks>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(GetRecommendedRenderingMode)(
|
||||||
|
FLOAT fontEmSize,
|
||||||
|
FLOAT dpiX,
|
||||||
|
FLOAT dpiY,
|
||||||
|
_In_opt_ DWRITE_MATRIX const* transform,
|
||||||
|
BOOL isSideways,
|
||||||
|
DWRITE_OUTLINE_THRESHOLD outlineThreshold,
|
||||||
|
DWRITE_MEASURING_MODE measuringMode,
|
||||||
|
_In_opt_ IDWriteRenderingParams* renderingParams,
|
||||||
|
_Out_ DWRITE_RENDERING_MODE* renderingMode,
|
||||||
|
_Out_ DWRITE_GRID_FIT_MODE* gridFitMode
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
using IDWriteFontFace1::GetRecommendedRenderingMode;
|
||||||
|
};
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Reserved palette entry index that does not specify any palette entry.
|
||||||
|
/// </summary>
|
||||||
|
#define DWRITE_NO_PALETTE_INDEX 0xFFFF
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Represents a color glyph run. The IDWriteFactory2::TranslateColorGlyphRun
|
||||||
|
/// method returns an ordered collection of color glyph runs, which can be
|
||||||
|
/// layered on top of each other to produce a color representation of the
|
||||||
|
/// given base glyph run.
|
||||||
|
/// </summary>
|
||||||
|
struct DWRITE_COLOR_GLYPH_RUN
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Glyph run to render.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_GLYPH_RUN glyphRun;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Optional glyph run description.
|
||||||
|
/// </summary>
|
||||||
|
_Maybenull_ DWRITE_GLYPH_RUN_DESCRIPTION* glyphRunDescription;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Location at which to draw this glyph run.
|
||||||
|
/// </summary>
|
||||||
|
FLOAT baselineOriginX;
|
||||||
|
FLOAT baselineOriginY;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Color to use for this layer, if any. If the paletteIndex member is
|
||||||
|
/// DWRITE_NO_PALETTE_INDEX (0xFFFF) then no color is specifed by the font,
|
||||||
|
/// this member is set to { 0, 0, 0, 0 }, and the client should use the
|
||||||
|
/// current foreground brush. Otherwise, this member is set to a color from
|
||||||
|
/// the font's color palette, i.e., the same color that would be returned
|
||||||
|
/// by IDWriteFontFace2::GetPaletteEntries for the current palette index.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_COLOR_F runColor;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Zero-based index of this layer's color entry in the current color
|
||||||
|
/// palette, or DWRITE_NO_PALETTE_INDEX (0xFFFF) if this layer
|
||||||
|
/// is to be rendered using the current foreground brush.
|
||||||
|
/// </summary>
|
||||||
|
UINT16 paletteIndex;
|
||||||
|
};
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Enumerator for an ordered collection of color glyph runs.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_BEGIN_INTERFACE(IDWriteColorGlyphRunEnumerator, "d31fbe17-f157-41a2-8d24-cb779e0560e8") : IUnknown
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Advances to the first or next color run. The runs are enumerated
|
||||||
|
/// in order from back to front.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="hasRun">Receives TRUE if there is a current run or
|
||||||
|
/// FALSE if the end of the sequence has been reached.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(MoveNext)(
|
||||||
|
_Out_ BOOL* hasRun
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Gets the current color glyph run.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="colorGlyphRun">Receives a pointer to the color
|
||||||
|
/// glyph run. The pointer remains valid until the next call to
|
||||||
|
/// MoveNext or until the interface is released.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code. An error is returned if there is
|
||||||
|
/// no current glyph run, i.e., if MoveNext has not yet been called
|
||||||
|
/// or if the end of the sequence has been reached.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(GetCurrentRun)(
|
||||||
|
_Outptr_ DWRITE_COLOR_GLYPH_RUN const** colorGlyphRun
|
||||||
|
) PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The interface that represents text rendering settings for glyph rasterization and filtering.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_BEGIN_INTERFACE(IDWriteRenderingParams2, "F9D711C3-9777-40AE-87E8-3E5AF9BF0948") : IDWriteRenderingParams1
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Gets the grid fitting mode.
|
||||||
|
/// </summary>
|
||||||
|
STDMETHOD_(DWRITE_GRID_FIT_MODE, GetGridFitMode)() PURE;
|
||||||
|
};
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The root factory interface for all DWrite objects.
|
||||||
|
/// </summary>
|
||||||
|
DWRITE_BEGIN_INTERFACE(IDWriteFactory2, "0439fc60-ca44-4994-8dee-3a9af7b732ec") : IDWriteFactory1
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Get the system-appropriate font fallback mapping list.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="fontFallback">The system fallback list.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(GetSystemFontFallback)(
|
||||||
|
_COM_Outptr_ IDWriteFontFallback** fontFallback
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Create a custom font fallback builder.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="fontFallbackBuilder">Empty font fallback builder.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(CreateFontFallbackBuilder)(
|
||||||
|
_COM_Outptr_ IDWriteFontFallbackBuilder** fontFallbackBuilder
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Translates a glyph run to a sequence of color glyph runs, which can be
|
||||||
|
/// rendered to produce a color representation of the original "base" run.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="baselineOriginX">Horizontal origin of the base glyph run in
|
||||||
|
/// pre-transform coordinates.</param>
|
||||||
|
/// <param name="baselineOriginY">Vertical origin of the base glyph run in
|
||||||
|
/// pre-transform coordinates.</param>
|
||||||
|
/// <param name="glyphRun">Pointer to the original "base" glyph run.</param>
|
||||||
|
/// <param name="glyphRunDescription">Optional glyph run description.</param>
|
||||||
|
/// <param name="measuringMode">Measuring mode, needed to compute the origins
|
||||||
|
/// of each glyph.</param>
|
||||||
|
/// <param name="worldToDeviceTransform">Matrix converting from the client's
|
||||||
|
/// coordinate space to device coordinates (pixels), i.e., the world transform
|
||||||
|
/// multiplied by any DPI scaling.</param>
|
||||||
|
/// <param name="colorPaletteIndex">Zero-based index of the color palette to use.
|
||||||
|
/// Valid indices are less than the number of palettes in the font, as returned
|
||||||
|
/// by IDWriteFontFace2::GetColorPaletteCount.</param>
|
||||||
|
/// <param name="colorLayers">If the function succeeds, receives a pointer
|
||||||
|
/// to an enumerator object that can be used to obtain the color glyph runs.
|
||||||
|
/// If the base run has no color glyphs, then the output pointer is NULL
|
||||||
|
/// and the method returns DWRITE_E_NOCOLOR.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Returns DWRITE_E_NOCOLOR if the font has no color information, the base
|
||||||
|
/// glyph run does not contain any color glyphs, or the specified color palette
|
||||||
|
/// index is out of range. In this case, the client should render the base glyph
|
||||||
|
/// run. Otherwise, returns a standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(TranslateColorGlyphRun)(
|
||||||
|
FLOAT baselineOriginX,
|
||||||
|
FLOAT baselineOriginY,
|
||||||
|
_In_ DWRITE_GLYPH_RUN const* glyphRun,
|
||||||
|
_In_opt_ DWRITE_GLYPH_RUN_DESCRIPTION const* glyphRunDescription,
|
||||||
|
DWRITE_MEASURING_MODE measuringMode,
|
||||||
|
_In_opt_ DWRITE_MATRIX const* worldToDeviceTransform,
|
||||||
|
UINT32 colorPaletteIndex,
|
||||||
|
_COM_Outptr_ IDWriteColorGlyphRunEnumerator** colorLayers
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Creates a rendering parameters object with the specified properties.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="gamma">The gamma value used for gamma correction, which must be greater than zero and cannot exceed 256.</param>
|
||||||
|
/// <param name="enhancedContrast">The amount of contrast enhancement, zero or greater.</param>
|
||||||
|
/// <param name="clearTypeLevel">The degree of ClearType level, from 0.0f (no ClearType) to 1.0f (full ClearType).</param>
|
||||||
|
/// <param name="pixelGeometry">The geometry of a device pixel.</param>
|
||||||
|
/// <param name="renderingMode">Method of rendering glyphs. In most cases, this should be DWRITE_RENDERING_MODE_DEFAULT to automatically use an appropriate mode.</param>
|
||||||
|
/// <param name="gridFitMode">How to grid fit glyph outlines. In most cases, this should be DWRITE_GRID_FIT_DEFAULT to automatically choose an appropriate mode.</param>
|
||||||
|
/// <param name="renderingParams">Holds the newly created rendering parameters object, or NULL in case of failure.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(CreateCustomRenderingParams)(
|
||||||
|
FLOAT gamma,
|
||||||
|
FLOAT enhancedContrast,
|
||||||
|
FLOAT grayscaleEnhancedContrast,
|
||||||
|
FLOAT clearTypeLevel,
|
||||||
|
DWRITE_PIXEL_GEOMETRY pixelGeometry,
|
||||||
|
DWRITE_RENDERING_MODE renderingMode,
|
||||||
|
DWRITE_GRID_FIT_MODE gridFitMode,
|
||||||
|
_COM_Outptr_ IDWriteRenderingParams2** renderingParams
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
using IDWriteFactory::CreateCustomRenderingParams;
|
||||||
|
using IDWriteFactory1::CreateCustomRenderingParams;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Creates a glyph run analysis object, which encapsulates information
|
||||||
|
/// used to render a glyph run.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="glyphRun">Structure specifying the properties of the glyph run.</param>
|
||||||
|
/// <param name="transform">Optional transform applied to the glyphs and their positions. This transform is applied after the
|
||||||
|
/// scaling specified by the emSize and pixelsPerDip.</param>
|
||||||
|
/// <param name="renderingMode">Specifies the rendering mode, which must be one of the raster rendering modes (i.e., not default
|
||||||
|
/// and not outline).</param>
|
||||||
|
/// <param name="measuringMode">Specifies the method to measure glyphs.</param>
|
||||||
|
/// <param name="gridFitMode">How to grid-fit glyph outlines. This must be non-default.</param>
|
||||||
|
/// <param name="baselineOriginX">Horizontal position of the baseline origin, in DIPs.</param>
|
||||||
|
/// <param name="baselineOriginY">Vertical position of the baseline origin, in DIPs.</param>
|
||||||
|
/// <param name="glyphRunAnalysis">Receives a pointer to the newly created object.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
STDMETHOD(CreateGlyphRunAnalysis)(
|
||||||
|
_In_ DWRITE_GLYPH_RUN const* glyphRun,
|
||||||
|
_In_opt_ DWRITE_MATRIX const* transform,
|
||||||
|
DWRITE_RENDERING_MODE renderingMode,
|
||||||
|
DWRITE_MEASURING_MODE measuringMode,
|
||||||
|
DWRITE_GRID_FIT_MODE gridFitMode,
|
||||||
|
DWRITE_TEXT_ANTIALIAS_MODE antialiasMode,
|
||||||
|
FLOAT baselineOriginX,
|
||||||
|
FLOAT baselineOriginY,
|
||||||
|
_COM_Outptr_ IDWriteGlyphRunAnalysis** glyphRunAnalysis
|
||||||
|
) PURE;
|
||||||
|
|
||||||
|
using IDWriteFactory::CreateGlyphRunAnalysis;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* DWRITE_2_H_INCLUDED */
|
||||||
4677
Sources/CWinAppSDK/nuget/include/dwrite_3.h
Normal file
4677
Sources/CWinAppSDK/nuget/include/dwrite_3.h
Normal file
File diff suppressed because it is too large
Load Diff
45
Sources/CWinAppSDK/nuget/include/dwrite_core.h
Normal file
45
Sources/CWinAppSDK/nuget/include/dwrite_core.h
Normal file
@ -0,0 +1,45 @@
|
|||||||
|
#define DWRITE_CORE 1
|
||||||
|
#include "dwrite_3.h"
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Creates a factory object that is used for subsequent creation of individual DWriteCore objects.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="factoryType">Identifies whether the factory object will be shared or isolated.</param>
|
||||||
|
/// <param name="iid">Identifies the DirectWrite factory interface, such as UUIDOF(IDWriteFactory).</param>
|
||||||
|
/// <param name="factory">Receives the DirectWrite factory object.</param>
|
||||||
|
/// <returns>
|
||||||
|
/// Standard HRESULT error code.
|
||||||
|
/// </returns>
|
||||||
|
/// <remarks>
|
||||||
|
/// This is functionally the same as the DWriteCreateFactory function exported by the system version
|
||||||
|
/// of DirectWrite. The DWriteCore function has a different name to avoid ambiguity.
|
||||||
|
/// </remarks>
|
||||||
|
EXTERN_C HRESULT DWRITE_EXPORT DWriteCoreCreateFactory(
|
||||||
|
_In_ DWRITE_FACTORY_TYPE factoryType,
|
||||||
|
_In_ REFIID iid,
|
||||||
|
_COM_Outptr_ IUnknown** factory
|
||||||
|
);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Registers an object that receives internal DWriteCore events.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="eventSink">Event sink object to register.</param>
|
||||||
|
/// <returns>Standard HRESULT error code.</returns>
|
||||||
|
/// <remarks>This method does NOT add a reference to the event sink object.
|
||||||
|
/// The caller is expected to hold a reference to the event sink object until
|
||||||
|
/// it later unregisters it by calling DWriteUnregisterEventSink.</remarks>
|
||||||
|
EXTERN_C HRESULT DWRITE_EXPORT DWriteCoreRegisterEventSink(
|
||||||
|
IDWriteEventSink* eventSink
|
||||||
|
);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Unregisters an event sink object that was previously registered
|
||||||
|
/// using DWriteCoreRegisterEventSink.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="eventSink">Event sink object to unregister.</param>
|
||||||
|
/// </remarks>Since DWriteCore does not hold a reference to the event sink, this
|
||||||
|
/// call can be made by the event sink object's destructor.</remarks>
|
||||||
|
EXTERN_C void DWRITE_EXPORT DWriteCoreUnregisterEventSink(
|
||||||
|
IDWriteEventSink* eventSink
|
||||||
|
);
|
||||||
|
|
||||||
@ -0,0 +1,970 @@
|
|||||||
|
|
||||||
|
|
||||||
|
/* this ALWAYS GENERATED file contains the definitions for the interfaces */
|
||||||
|
|
||||||
|
|
||||||
|
/* File created by MIDL compiler version 8.01.0628 */
|
||||||
|
/* @@MIDL_FILE_HEADING( ) */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/* verify that the <rpcndr.h> version is high enough to compile this file*/
|
||||||
|
#ifndef __REQUIRED_RPCNDR_H_VERSION__
|
||||||
|
#define __REQUIRED_RPCNDR_H_VERSION__ 500
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* verify that the <rpcsal.h> version is high enough to compile this file*/
|
||||||
|
#ifndef __REQUIRED_RPCSAL_H_VERSION__
|
||||||
|
#define __REQUIRED_RPCSAL_H_VERSION__ 100
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include "rpc.h"
|
||||||
|
#include "rpcndr.h"
|
||||||
|
|
||||||
|
#ifndef __RPCNDR_H_VERSION__
|
||||||
|
#error this stub requires an updated version of <rpcndr.h>
|
||||||
|
#endif /* __RPCNDR_H_VERSION__ */
|
||||||
|
|
||||||
|
#ifndef COM_NO_WINDOWS_H
|
||||||
|
#include "windows.h"
|
||||||
|
#include "ole2.h"
|
||||||
|
#endif /*COM_NO_WINDOWS_H*/
|
||||||
|
|
||||||
|
#ifndef __microsoft2Eui2Examl2Ehosting2Ereferencetracker_h__
|
||||||
|
#define __microsoft2Eui2Examl2Ehosting2Ereferencetracker_h__
|
||||||
|
|
||||||
|
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||||
|
#pragma once
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef DECLSPEC_XFGVIRT
|
||||||
|
#if defined(_CONTROL_FLOW_GUARD_XFG)
|
||||||
|
#define DECLSPEC_XFGVIRT(base, func) __declspec(xfg_virtual(base, func))
|
||||||
|
#else
|
||||||
|
#define DECLSPEC_XFGVIRT(base, func)
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* Forward Declarations */
|
||||||
|
|
||||||
|
#ifndef __IReferenceTrackerTarget_FWD_DEFINED__
|
||||||
|
#define __IReferenceTrackerTarget_FWD_DEFINED__
|
||||||
|
typedef interface IReferenceTrackerTarget IReferenceTrackerTarget;
|
||||||
|
|
||||||
|
#endif /* __IReferenceTrackerTarget_FWD_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef __IReferenceTracker_FWD_DEFINED__
|
||||||
|
#define __IReferenceTracker_FWD_DEFINED__
|
||||||
|
typedef interface IReferenceTracker IReferenceTracker;
|
||||||
|
|
||||||
|
#endif /* __IReferenceTracker_FWD_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef __IReferenceTrackerManager_FWD_DEFINED__
|
||||||
|
#define __IReferenceTrackerManager_FWD_DEFINED__
|
||||||
|
typedef interface IReferenceTrackerManager IReferenceTrackerManager;
|
||||||
|
|
||||||
|
#endif /* __IReferenceTrackerManager_FWD_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef __IFindReferenceTargetsCallback_FWD_DEFINED__
|
||||||
|
#define __IFindReferenceTargetsCallback_FWD_DEFINED__
|
||||||
|
typedef interface IFindReferenceTargetsCallback IFindReferenceTargetsCallback;
|
||||||
|
|
||||||
|
#endif /* __IFindReferenceTargetsCallback_FWD_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef __IReferenceTrackerHost_FWD_DEFINED__
|
||||||
|
#define __IReferenceTrackerHost_FWD_DEFINED__
|
||||||
|
typedef interface IReferenceTrackerHost IReferenceTrackerHost;
|
||||||
|
|
||||||
|
#endif /* __IReferenceTrackerHost_FWD_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef __IReferenceTrackerExtension_FWD_DEFINED__
|
||||||
|
#define __IReferenceTrackerExtension_FWD_DEFINED__
|
||||||
|
typedef interface IReferenceTrackerExtension IReferenceTrackerExtension;
|
||||||
|
|
||||||
|
#endif /* __IReferenceTrackerExtension_FWD_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef __ITrackerOwner_FWD_DEFINED__
|
||||||
|
#define __ITrackerOwner_FWD_DEFINED__
|
||||||
|
typedef interface ITrackerOwner ITrackerOwner;
|
||||||
|
|
||||||
|
#endif /* __ITrackerOwner_FWD_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
/* header files for imported files */
|
||||||
|
#include "oaidl.h"
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C"{
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
/* interface __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0000 */
|
||||||
|
/* [local] */
|
||||||
|
|
||||||
|
#pragma warning(push)
|
||||||
|
#pragma warning(disable:4668)
|
||||||
|
#pragma warning(disable:4001)
|
||||||
|
#pragma once
|
||||||
|
#pragma warning(pop)
|
||||||
|
#if (NTDDI_VERSION >= NTDDI_WIN8)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0000_v0_0_c_ifspec;
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0000_v0_0_s_ifspec;
|
||||||
|
|
||||||
|
#ifndef __IReferenceTrackerTarget_INTERFACE_DEFINED__
|
||||||
|
#define __IReferenceTrackerTarget_INTERFACE_DEFINED__
|
||||||
|
|
||||||
|
/* interface IReferenceTrackerTarget */
|
||||||
|
/* [unique][local][uuid][object] */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID IID_IReferenceTrackerTarget;
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
|
||||||
|
MIDL_INTERFACE("64bd43f8-bfee-4ec4-b7eb-2935158dae21")
|
||||||
|
IReferenceTrackerTarget : public IUnknown
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual ULONG STDMETHODCALLTYPE AddRefFromReferenceTracker( void) = 0;
|
||||||
|
|
||||||
|
virtual ULONG STDMETHODCALLTYPE ReleaseFromReferenceTracker( void) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE Peg( void) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE Unpeg( void) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#else /* C style interface */
|
||||||
|
|
||||||
|
typedef struct IReferenceTrackerTargetVtbl
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
|
||||||
|
IReferenceTrackerTarget * This,
|
||||||
|
/* [in] */ REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, AddRef)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
IReferenceTrackerTarget * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, Release)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
IReferenceTrackerTarget * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerTarget, AddRefFromReferenceTracker)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRefFromReferenceTracker )(
|
||||||
|
IReferenceTrackerTarget * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerTarget, ReleaseFromReferenceTracker)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *ReleaseFromReferenceTracker )(
|
||||||
|
IReferenceTrackerTarget * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerTarget, Peg)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *Peg )(
|
||||||
|
IReferenceTrackerTarget * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerTarget, Unpeg)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *Unpeg )(
|
||||||
|
IReferenceTrackerTarget * This);
|
||||||
|
|
||||||
|
END_INTERFACE
|
||||||
|
} IReferenceTrackerTargetVtbl;
|
||||||
|
|
||||||
|
interface IReferenceTrackerTarget
|
||||||
|
{
|
||||||
|
CONST_VTBL struct IReferenceTrackerTargetVtbl *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
|
||||||
|
|
||||||
|
#define IReferenceTrackerTarget_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerTarget_AddRef(This) \
|
||||||
|
( (This)->lpVtbl -> AddRef(This) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerTarget_Release(This) \
|
||||||
|
( (This)->lpVtbl -> Release(This) )
|
||||||
|
|
||||||
|
|
||||||
|
#define IReferenceTrackerTarget_AddRefFromReferenceTracker(This) \
|
||||||
|
( (This)->lpVtbl -> AddRefFromReferenceTracker(This) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerTarget_ReleaseFromReferenceTracker(This) \
|
||||||
|
( (This)->lpVtbl -> ReleaseFromReferenceTracker(This) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerTarget_Peg(This) \
|
||||||
|
( (This)->lpVtbl -> Peg(This) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerTarget_Unpeg(This) \
|
||||||
|
( (This)->lpVtbl -> Unpeg(This) )
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* C style interface */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* __IReferenceTrackerTarget_INTERFACE_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef __IReferenceTracker_INTERFACE_DEFINED__
|
||||||
|
#define __IReferenceTracker_INTERFACE_DEFINED__
|
||||||
|
|
||||||
|
/* interface IReferenceTracker */
|
||||||
|
/* [unique][local][uuid][object] */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID IID_IReferenceTracker;
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
|
||||||
|
MIDL_INTERFACE("11d3b13a-180e-4789-a8be-7712882893e6")
|
||||||
|
IReferenceTracker : public IUnknown
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE ConnectFromTrackerSource( void) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE DisconnectFromTrackerSource( void) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE FindTrackerTargets(
|
||||||
|
/* [annotation][in] */
|
||||||
|
_In_ IFindReferenceTargetsCallback *callback) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE GetReferenceTrackerManager(
|
||||||
|
/* [annotation][out] */
|
||||||
|
_Out_ IReferenceTrackerManager **value) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE AddRefFromTrackerSource( void) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE ReleaseFromTrackerSource( void) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE PegFromTrackerSource( void) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#else /* C style interface */
|
||||||
|
|
||||||
|
typedef struct IReferenceTrackerVtbl
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
|
||||||
|
IReferenceTracker * This,
|
||||||
|
/* [in] */ REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, AddRef)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
IReferenceTracker * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, Release)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
IReferenceTracker * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTracker, ConnectFromTrackerSource)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *ConnectFromTrackerSource )(
|
||||||
|
IReferenceTracker * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTracker, DisconnectFromTrackerSource)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *DisconnectFromTrackerSource )(
|
||||||
|
IReferenceTracker * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTracker, FindTrackerTargets)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *FindTrackerTargets )(
|
||||||
|
IReferenceTracker * This,
|
||||||
|
/* [annotation][in] */
|
||||||
|
_In_ IFindReferenceTargetsCallback *callback);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTracker, GetReferenceTrackerManager)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *GetReferenceTrackerManager )(
|
||||||
|
IReferenceTracker * This,
|
||||||
|
/* [annotation][out] */
|
||||||
|
_Out_ IReferenceTrackerManager **value);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTracker, AddRefFromTrackerSource)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *AddRefFromTrackerSource )(
|
||||||
|
IReferenceTracker * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTracker, ReleaseFromTrackerSource)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *ReleaseFromTrackerSource )(
|
||||||
|
IReferenceTracker * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTracker, PegFromTrackerSource)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *PegFromTrackerSource )(
|
||||||
|
IReferenceTracker * This);
|
||||||
|
|
||||||
|
END_INTERFACE
|
||||||
|
} IReferenceTrackerVtbl;
|
||||||
|
|
||||||
|
interface IReferenceTracker
|
||||||
|
{
|
||||||
|
CONST_VTBL struct IReferenceTrackerVtbl *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
|
||||||
|
|
||||||
|
#define IReferenceTracker_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define IReferenceTracker_AddRef(This) \
|
||||||
|
( (This)->lpVtbl -> AddRef(This) )
|
||||||
|
|
||||||
|
#define IReferenceTracker_Release(This) \
|
||||||
|
( (This)->lpVtbl -> Release(This) )
|
||||||
|
|
||||||
|
|
||||||
|
#define IReferenceTracker_ConnectFromTrackerSource(This) \
|
||||||
|
( (This)->lpVtbl -> ConnectFromTrackerSource(This) )
|
||||||
|
|
||||||
|
#define IReferenceTracker_DisconnectFromTrackerSource(This) \
|
||||||
|
( (This)->lpVtbl -> DisconnectFromTrackerSource(This) )
|
||||||
|
|
||||||
|
#define IReferenceTracker_FindTrackerTargets(This,callback) \
|
||||||
|
( (This)->lpVtbl -> FindTrackerTargets(This,callback) )
|
||||||
|
|
||||||
|
#define IReferenceTracker_GetReferenceTrackerManager(This,value) \
|
||||||
|
( (This)->lpVtbl -> GetReferenceTrackerManager(This,value) )
|
||||||
|
|
||||||
|
#define IReferenceTracker_AddRefFromTrackerSource(This) \
|
||||||
|
( (This)->lpVtbl -> AddRefFromTrackerSource(This) )
|
||||||
|
|
||||||
|
#define IReferenceTracker_ReleaseFromTrackerSource(This) \
|
||||||
|
( (This)->lpVtbl -> ReleaseFromTrackerSource(This) )
|
||||||
|
|
||||||
|
#define IReferenceTracker_PegFromTrackerSource(This) \
|
||||||
|
( (This)->lpVtbl -> PegFromTrackerSource(This) )
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* C style interface */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* __IReferenceTracker_INTERFACE_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef __IReferenceTrackerManager_INTERFACE_DEFINED__
|
||||||
|
#define __IReferenceTrackerManager_INTERFACE_DEFINED__
|
||||||
|
|
||||||
|
/* interface IReferenceTrackerManager */
|
||||||
|
/* [unique][local][uuid][object] */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID IID_IReferenceTrackerManager;
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
|
||||||
|
MIDL_INTERFACE("3cf184b4-7ccb-4dda-8455-7e6ce99a3298")
|
||||||
|
IReferenceTrackerManager : public IUnknown
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE ReferenceTrackingStarted( void) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE FindTrackerTargetsCompleted(
|
||||||
|
/* [annotation][in] */
|
||||||
|
_In_ boolean findFailed) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE ReferenceTrackingCompleted( void) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE SetReferenceTrackerHost(
|
||||||
|
/* [annotation][in] */
|
||||||
|
_In_ IReferenceTrackerHost *value) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#else /* C style interface */
|
||||||
|
|
||||||
|
typedef struct IReferenceTrackerManagerVtbl
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
|
||||||
|
IReferenceTrackerManager * This,
|
||||||
|
/* [in] */ REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, AddRef)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
IReferenceTrackerManager * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, Release)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
IReferenceTrackerManager * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerManager, ReferenceTrackingStarted)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *ReferenceTrackingStarted )(
|
||||||
|
IReferenceTrackerManager * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerManager, FindTrackerTargetsCompleted)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *FindTrackerTargetsCompleted )(
|
||||||
|
IReferenceTrackerManager * This,
|
||||||
|
/* [annotation][in] */
|
||||||
|
_In_ boolean findFailed);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerManager, ReferenceTrackingCompleted)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *ReferenceTrackingCompleted )(
|
||||||
|
IReferenceTrackerManager * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerManager, SetReferenceTrackerHost)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *SetReferenceTrackerHost )(
|
||||||
|
IReferenceTrackerManager * This,
|
||||||
|
/* [annotation][in] */
|
||||||
|
_In_ IReferenceTrackerHost *value);
|
||||||
|
|
||||||
|
END_INTERFACE
|
||||||
|
} IReferenceTrackerManagerVtbl;
|
||||||
|
|
||||||
|
interface IReferenceTrackerManager
|
||||||
|
{
|
||||||
|
CONST_VTBL struct IReferenceTrackerManagerVtbl *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
|
||||||
|
|
||||||
|
#define IReferenceTrackerManager_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerManager_AddRef(This) \
|
||||||
|
( (This)->lpVtbl -> AddRef(This) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerManager_Release(This) \
|
||||||
|
( (This)->lpVtbl -> Release(This) )
|
||||||
|
|
||||||
|
|
||||||
|
#define IReferenceTrackerManager_ReferenceTrackingStarted(This) \
|
||||||
|
( (This)->lpVtbl -> ReferenceTrackingStarted(This) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerManager_FindTrackerTargetsCompleted(This,findFailed) \
|
||||||
|
( (This)->lpVtbl -> FindTrackerTargetsCompleted(This,findFailed) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerManager_ReferenceTrackingCompleted(This) \
|
||||||
|
( (This)->lpVtbl -> ReferenceTrackingCompleted(This) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerManager_SetReferenceTrackerHost(This,value) \
|
||||||
|
( (This)->lpVtbl -> SetReferenceTrackerHost(This,value) )
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* C style interface */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* __IReferenceTrackerManager_INTERFACE_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef __IFindReferenceTargetsCallback_INTERFACE_DEFINED__
|
||||||
|
#define __IFindReferenceTargetsCallback_INTERFACE_DEFINED__
|
||||||
|
|
||||||
|
/* interface IFindReferenceTargetsCallback */
|
||||||
|
/* [unique][local][uuid][object] */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID IID_IFindReferenceTargetsCallback;
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
|
||||||
|
MIDL_INTERFACE("04b3486c-4687-4229-8d14-505ab584dd88")
|
||||||
|
IFindReferenceTargetsCallback : public IUnknown
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE FoundTrackerTarget(
|
||||||
|
/* [annotation][in] */
|
||||||
|
_In_ IReferenceTrackerTarget *target) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#else /* C style interface */
|
||||||
|
|
||||||
|
typedef struct IFindReferenceTargetsCallbackVtbl
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
|
||||||
|
IFindReferenceTargetsCallback * This,
|
||||||
|
/* [in] */ REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, AddRef)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
IFindReferenceTargetsCallback * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, Release)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
IFindReferenceTargetsCallback * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IFindReferenceTargetsCallback, FoundTrackerTarget)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *FoundTrackerTarget )(
|
||||||
|
IFindReferenceTargetsCallback * This,
|
||||||
|
/* [annotation][in] */
|
||||||
|
_In_ IReferenceTrackerTarget *target);
|
||||||
|
|
||||||
|
END_INTERFACE
|
||||||
|
} IFindReferenceTargetsCallbackVtbl;
|
||||||
|
|
||||||
|
interface IFindReferenceTargetsCallback
|
||||||
|
{
|
||||||
|
CONST_VTBL struct IFindReferenceTargetsCallbackVtbl *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
|
||||||
|
|
||||||
|
#define IFindReferenceTargetsCallback_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define IFindReferenceTargetsCallback_AddRef(This) \
|
||||||
|
( (This)->lpVtbl -> AddRef(This) )
|
||||||
|
|
||||||
|
#define IFindReferenceTargetsCallback_Release(This) \
|
||||||
|
( (This)->lpVtbl -> Release(This) )
|
||||||
|
|
||||||
|
|
||||||
|
#define IFindReferenceTargetsCallback_FoundTrackerTarget(This,target) \
|
||||||
|
( (This)->lpVtbl -> FoundTrackerTarget(This,target) )
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* C style interface */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* __IFindReferenceTargetsCallback_INTERFACE_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
/* interface __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0004 */
|
||||||
|
/* [local] */
|
||||||
|
|
||||||
|
typedef /* [public][public][v1_enum] */
|
||||||
|
enum __MIDL___MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0004_0001
|
||||||
|
{
|
||||||
|
XAML_REFERENCETRACKER_DISCONNECT_DEFAULT = 0,
|
||||||
|
XAML_REFERENCETRACKER_DISCONNECT_SUSPEND = 1
|
||||||
|
} XAML_REFERENCETRACKER_DISCONNECT;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0004_v0_0_c_ifspec;
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0004_v0_0_s_ifspec;
|
||||||
|
|
||||||
|
#ifndef __IReferenceTrackerHost_INTERFACE_DEFINED__
|
||||||
|
#define __IReferenceTrackerHost_INTERFACE_DEFINED__
|
||||||
|
|
||||||
|
/* interface IReferenceTrackerHost */
|
||||||
|
/* [unique][local][uuid][object] */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID IID_IReferenceTrackerHost;
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
|
||||||
|
MIDL_INTERFACE("29a71c6a-3c42-4416-a39d-e2825a07a773")
|
||||||
|
IReferenceTrackerHost : public IUnknown
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE DisconnectUnusedReferenceSources(
|
||||||
|
/* [in] */ XAML_REFERENCETRACKER_DISCONNECT options) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE ReleaseDisconnectedReferenceSources( void) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE NotifyEndOfReferenceTrackingOnThread( void) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE GetTrackerTarget(
|
||||||
|
IUnknown *unknown,
|
||||||
|
IReferenceTrackerTarget **newReference) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE AddMemoryPressure(
|
||||||
|
UINT64 bytesAllocated) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE RemoveMemoryPressure(
|
||||||
|
UINT64 bytesAllocated) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#else /* C style interface */
|
||||||
|
|
||||||
|
typedef struct IReferenceTrackerHostVtbl
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
|
||||||
|
IReferenceTrackerHost * This,
|
||||||
|
/* [in] */ REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, AddRef)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
IReferenceTrackerHost * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, Release)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
IReferenceTrackerHost * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerHost, DisconnectUnusedReferenceSources)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *DisconnectUnusedReferenceSources )(
|
||||||
|
IReferenceTrackerHost * This,
|
||||||
|
/* [in] */ XAML_REFERENCETRACKER_DISCONNECT options);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerHost, ReleaseDisconnectedReferenceSources)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *ReleaseDisconnectedReferenceSources )(
|
||||||
|
IReferenceTrackerHost * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerHost, NotifyEndOfReferenceTrackingOnThread)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *NotifyEndOfReferenceTrackingOnThread )(
|
||||||
|
IReferenceTrackerHost * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerHost, GetTrackerTarget)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *GetTrackerTarget )(
|
||||||
|
IReferenceTrackerHost * This,
|
||||||
|
IUnknown *unknown,
|
||||||
|
IReferenceTrackerTarget **newReference);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerHost, AddMemoryPressure)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *AddMemoryPressure )(
|
||||||
|
IReferenceTrackerHost * This,
|
||||||
|
UINT64 bytesAllocated);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IReferenceTrackerHost, RemoveMemoryPressure)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *RemoveMemoryPressure )(
|
||||||
|
IReferenceTrackerHost * This,
|
||||||
|
UINT64 bytesAllocated);
|
||||||
|
|
||||||
|
END_INTERFACE
|
||||||
|
} IReferenceTrackerHostVtbl;
|
||||||
|
|
||||||
|
interface IReferenceTrackerHost
|
||||||
|
{
|
||||||
|
CONST_VTBL struct IReferenceTrackerHostVtbl *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
|
||||||
|
|
||||||
|
#define IReferenceTrackerHost_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerHost_AddRef(This) \
|
||||||
|
( (This)->lpVtbl -> AddRef(This) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerHost_Release(This) \
|
||||||
|
( (This)->lpVtbl -> Release(This) )
|
||||||
|
|
||||||
|
|
||||||
|
#define IReferenceTrackerHost_DisconnectUnusedReferenceSources(This,options) \
|
||||||
|
( (This)->lpVtbl -> DisconnectUnusedReferenceSources(This,options) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerHost_ReleaseDisconnectedReferenceSources(This) \
|
||||||
|
( (This)->lpVtbl -> ReleaseDisconnectedReferenceSources(This) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerHost_NotifyEndOfReferenceTrackingOnThread(This) \
|
||||||
|
( (This)->lpVtbl -> NotifyEndOfReferenceTrackingOnThread(This) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerHost_GetTrackerTarget(This,unknown,newReference) \
|
||||||
|
( (This)->lpVtbl -> GetTrackerTarget(This,unknown,newReference) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerHost_AddMemoryPressure(This,bytesAllocated) \
|
||||||
|
( (This)->lpVtbl -> AddMemoryPressure(This,bytesAllocated) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerHost_RemoveMemoryPressure(This,bytesAllocated) \
|
||||||
|
( (This)->lpVtbl -> RemoveMemoryPressure(This,bytesAllocated) )
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* C style interface */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* __IReferenceTrackerHost_INTERFACE_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
/* interface __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0005 */
|
||||||
|
/* [local] */
|
||||||
|
|
||||||
|
#if (NTDDI_VERSION >= NTDDI_WIN10_RS2)
|
||||||
|
|
||||||
|
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0005_v0_0_c_ifspec;
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0005_v0_0_s_ifspec;
|
||||||
|
|
||||||
|
#ifndef __IReferenceTrackerExtension_INTERFACE_DEFINED__
|
||||||
|
#define __IReferenceTrackerExtension_INTERFACE_DEFINED__
|
||||||
|
|
||||||
|
/* interface IReferenceTrackerExtension */
|
||||||
|
/* [unique][local][uuid][object] */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID IID_IReferenceTrackerExtension;
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
|
||||||
|
MIDL_INTERFACE("4e897caa-59d5-4613-8f8c-f7ebd1f399b0")
|
||||||
|
IReferenceTrackerExtension : public IUnknown
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#else /* C style interface */
|
||||||
|
|
||||||
|
typedef struct IReferenceTrackerExtensionVtbl
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
|
||||||
|
IReferenceTrackerExtension * This,
|
||||||
|
/* [in] */ REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, AddRef)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
IReferenceTrackerExtension * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, Release)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
IReferenceTrackerExtension * This);
|
||||||
|
|
||||||
|
END_INTERFACE
|
||||||
|
} IReferenceTrackerExtensionVtbl;
|
||||||
|
|
||||||
|
interface IReferenceTrackerExtension
|
||||||
|
{
|
||||||
|
CONST_VTBL struct IReferenceTrackerExtensionVtbl *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
|
||||||
|
|
||||||
|
#define IReferenceTrackerExtension_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerExtension_AddRef(This) \
|
||||||
|
( (This)->lpVtbl -> AddRef(This) )
|
||||||
|
|
||||||
|
#define IReferenceTrackerExtension_Release(This) \
|
||||||
|
( (This)->lpVtbl -> Release(This) )
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* C style interface */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* __IReferenceTrackerExtension_INTERFACE_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
/* interface __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0006 */
|
||||||
|
/* [local] */
|
||||||
|
|
||||||
|
typedef struct TrackerHandle__
|
||||||
|
{
|
||||||
|
int unused;
|
||||||
|
} TrackerHandle__;
|
||||||
|
|
||||||
|
typedef /* [unique] */ __RPC_unique_pointer TrackerHandle__ *TrackerHandle;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0006_v0_0_c_ifspec;
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0006_v0_0_s_ifspec;
|
||||||
|
|
||||||
|
#ifndef __ITrackerOwner_INTERFACE_DEFINED__
|
||||||
|
#define __ITrackerOwner_INTERFACE_DEFINED__
|
||||||
|
|
||||||
|
/* interface ITrackerOwner */
|
||||||
|
/* [unique][local][uuid][object] */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID IID_ITrackerOwner;
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
|
||||||
|
MIDL_INTERFACE("eb24c20b-9816-4ac7-8cff-36f67a118f4e")
|
||||||
|
ITrackerOwner : public IUnknown
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE CreateTrackerHandle(
|
||||||
|
/* [retval][out] */ TrackerHandle *returnValue) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE DeleteTrackerHandle(
|
||||||
|
/* [in] */ TrackerHandle handle) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE SetTrackerValue(
|
||||||
|
/* [in] */ TrackerHandle handle,
|
||||||
|
/* [in] */ IUnknown *value) = 0;
|
||||||
|
|
||||||
|
virtual boolean STDMETHODCALLTYPE TryGetSafeTrackerValue(
|
||||||
|
/* [in] */ TrackerHandle handle,
|
||||||
|
/* [retval][out] */ IUnknown **returnValue) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#else /* C style interface */
|
||||||
|
|
||||||
|
typedef struct ITrackerOwnerVtbl
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
|
||||||
|
ITrackerOwner * This,
|
||||||
|
/* [in] */ REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, AddRef)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
ITrackerOwner * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, Release)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
ITrackerOwner * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(ITrackerOwner, CreateTrackerHandle)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *CreateTrackerHandle )(
|
||||||
|
ITrackerOwner * This,
|
||||||
|
/* [retval][out] */ TrackerHandle *returnValue);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(ITrackerOwner, DeleteTrackerHandle)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *DeleteTrackerHandle )(
|
||||||
|
ITrackerOwner * This,
|
||||||
|
/* [in] */ TrackerHandle handle);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(ITrackerOwner, SetTrackerValue)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *SetTrackerValue )(
|
||||||
|
ITrackerOwner * This,
|
||||||
|
/* [in] */ TrackerHandle handle,
|
||||||
|
/* [in] */ IUnknown *value);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(ITrackerOwner, TryGetSafeTrackerValue)
|
||||||
|
boolean ( STDMETHODCALLTYPE *TryGetSafeTrackerValue )(
|
||||||
|
ITrackerOwner * This,
|
||||||
|
/* [in] */ TrackerHandle handle,
|
||||||
|
/* [retval][out] */ IUnknown **returnValue);
|
||||||
|
|
||||||
|
END_INTERFACE
|
||||||
|
} ITrackerOwnerVtbl;
|
||||||
|
|
||||||
|
interface ITrackerOwner
|
||||||
|
{
|
||||||
|
CONST_VTBL struct ITrackerOwnerVtbl *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
|
||||||
|
|
||||||
|
#define ITrackerOwner_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define ITrackerOwner_AddRef(This) \
|
||||||
|
( (This)->lpVtbl -> AddRef(This) )
|
||||||
|
|
||||||
|
#define ITrackerOwner_Release(This) \
|
||||||
|
( (This)->lpVtbl -> Release(This) )
|
||||||
|
|
||||||
|
|
||||||
|
#define ITrackerOwner_CreateTrackerHandle(This,returnValue) \
|
||||||
|
( (This)->lpVtbl -> CreateTrackerHandle(This,returnValue) )
|
||||||
|
|
||||||
|
#define ITrackerOwner_DeleteTrackerHandle(This,handle) \
|
||||||
|
( (This)->lpVtbl -> DeleteTrackerHandle(This,handle) )
|
||||||
|
|
||||||
|
#define ITrackerOwner_SetTrackerValue(This,handle,value) \
|
||||||
|
( (This)->lpVtbl -> SetTrackerValue(This,handle,value) )
|
||||||
|
|
||||||
|
#define ITrackerOwner_TryGetSafeTrackerValue(This,handle,returnValue) \
|
||||||
|
( (This)->lpVtbl -> TryGetSafeTrackerValue(This,handle,returnValue) )
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* C style interface */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* __ITrackerOwner_INTERFACE_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
/* interface __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0007 */
|
||||||
|
/* [local] */
|
||||||
|
|
||||||
|
#endif // NTDDI_VERSION >= NTDDI_WIN10_RS2
|
||||||
|
#endif // NTDDI_VERSION >= NTDDI_WIN8
|
||||||
|
|
||||||
|
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0007_v0_0_c_ifspec;
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ehosting2Ereferencetracker_0000_0007_v0_0_s_ifspec;
|
||||||
|
|
||||||
|
/* Additional Prototypes for ALL interfaces */
|
||||||
|
|
||||||
|
/* end of Additional Prototypes */
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
1054
Sources/CWinAppSDK/nuget/include/microsoft.ui.xaml.media.dxinterop.h
Normal file
1054
Sources/CWinAppSDK/nuget/include/microsoft.ui.xaml.media.dxinterop.h
Normal file
File diff suppressed because it is too large
Load Diff
177
Sources/CWinAppSDK/nuget/include/microsoft.ui.xaml.window.h
Normal file
177
Sources/CWinAppSDK/nuget/include/microsoft.ui.xaml.window.h
Normal file
@ -0,0 +1,177 @@
|
|||||||
|
|
||||||
|
|
||||||
|
/* this ALWAYS GENERATED file contains the definitions for the interfaces */
|
||||||
|
|
||||||
|
|
||||||
|
/* File created by MIDL compiler version 8.01.0628 */
|
||||||
|
/* @@MIDL_FILE_HEADING( ) */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/* verify that the <rpcndr.h> version is high enough to compile this file*/
|
||||||
|
#ifndef __REQUIRED_RPCNDR_H_VERSION__
|
||||||
|
#define __REQUIRED_RPCNDR_H_VERSION__ 500
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* verify that the <rpcsal.h> version is high enough to compile this file*/
|
||||||
|
#ifndef __REQUIRED_RPCSAL_H_VERSION__
|
||||||
|
#define __REQUIRED_RPCSAL_H_VERSION__ 100
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include "rpc.h"
|
||||||
|
#include "rpcndr.h"
|
||||||
|
|
||||||
|
#ifndef __RPCNDR_H_VERSION__
|
||||||
|
#error this stub requires an updated version of <rpcndr.h>
|
||||||
|
#endif /* __RPCNDR_H_VERSION__ */
|
||||||
|
|
||||||
|
#ifndef COM_NO_WINDOWS_H
|
||||||
|
#include "windows.h"
|
||||||
|
#include "ole2.h"
|
||||||
|
#endif /*COM_NO_WINDOWS_H*/
|
||||||
|
|
||||||
|
#ifndef __microsoft2Eui2Examl2Ewindow_h__
|
||||||
|
#define __microsoft2Eui2Examl2Ewindow_h__
|
||||||
|
|
||||||
|
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||||
|
#pragma once
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef DECLSPEC_XFGVIRT
|
||||||
|
#if defined(_CONTROL_FLOW_GUARD_XFG)
|
||||||
|
#define DECLSPEC_XFGVIRT(base, func) __declspec(xfg_virtual(base, func))
|
||||||
|
#else
|
||||||
|
#define DECLSPEC_XFGVIRT(base, func)
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* Forward Declarations */
|
||||||
|
|
||||||
|
#ifndef __IWindowNative_FWD_DEFINED__
|
||||||
|
#define __IWindowNative_FWD_DEFINED__
|
||||||
|
typedef interface IWindowNative IWindowNative;
|
||||||
|
|
||||||
|
#endif /* __IWindowNative_FWD_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
/* header files for imported files */
|
||||||
|
#include "oaidl.h"
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C"{
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
/* interface __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0000 */
|
||||||
|
/* [local] */
|
||||||
|
|
||||||
|
#if (NTDDI_VERSION >= NTDDI_WIN10_RS4)
|
||||||
|
|
||||||
|
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0000_v0_0_c_ifspec;
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0000_v0_0_s_ifspec;
|
||||||
|
|
||||||
|
#ifndef __IWindowNative_INTERFACE_DEFINED__
|
||||||
|
#define __IWindowNative_INTERFACE_DEFINED__
|
||||||
|
|
||||||
|
/* interface IWindowNative */
|
||||||
|
/* [unique][local][uuid][object] */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID IID_IWindowNative;
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
|
||||||
|
MIDL_INTERFACE("EECDBF0E-BAE9-4CB6-A68E-9598E1CB57BB")
|
||||||
|
IWindowNative : public IUnknown
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_WindowHandle(
|
||||||
|
/* [retval][out] */ HWND *hWnd) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#else /* C style interface */
|
||||||
|
|
||||||
|
typedef struct IWindowNativeVtbl
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
|
||||||
|
IWindowNative * This,
|
||||||
|
/* [in] */ REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, AddRef)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
IWindowNative * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, Release)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
IWindowNative * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IWindowNative, get_WindowHandle)
|
||||||
|
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_WindowHandle )(
|
||||||
|
IWindowNative * This,
|
||||||
|
/* [retval][out] */ HWND *hWnd);
|
||||||
|
|
||||||
|
END_INTERFACE
|
||||||
|
} IWindowNativeVtbl;
|
||||||
|
|
||||||
|
interface IWindowNative
|
||||||
|
{
|
||||||
|
CONST_VTBL struct IWindowNativeVtbl *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
|
||||||
|
|
||||||
|
#define IWindowNative_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define IWindowNative_AddRef(This) \
|
||||||
|
( (This)->lpVtbl -> AddRef(This) )
|
||||||
|
|
||||||
|
#define IWindowNative_Release(This) \
|
||||||
|
( (This)->lpVtbl -> Release(This) )
|
||||||
|
|
||||||
|
|
||||||
|
#define IWindowNative_get_WindowHandle(This,hWnd) \
|
||||||
|
( (This)->lpVtbl -> get_WindowHandle(This,hWnd) )
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* C style interface */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* __IWindowNative_INTERFACE_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
/* interface __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0001 */
|
||||||
|
/* [local] */
|
||||||
|
|
||||||
|
#endif // NTDDI_VERSION >= NTDDI_WIN10_RS4
|
||||||
|
|
||||||
|
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0001_v0_0_c_ifspec;
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_microsoft2Eui2Examl2Ewindow_0000_0001_v0_0_s_ifspec;
|
||||||
|
|
||||||
|
/* Additional Prototypes for ALL interfaces */
|
||||||
|
|
||||||
|
/* end of Additional Prototypes */
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
25
Sources/CWinAppSDK/nuget/include/wil_msixdynamicdependency.h
Normal file
25
Sources/CWinAppSDK/nuget/include/wil_msixdynamicdependency.h
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
// Copyright (c) Microsoft Corporation and Contributors.
|
||||||
|
// Licensed under the MIT License.
|
||||||
|
|
||||||
|
namespace wil
|
||||||
|
{
|
||||||
|
#if defined(_APISETLIBLOADER_) && !defined(__WIL_APISETLIBLOADER_)
|
||||||
|
#define __WIL_APISETLIBLOADER_
|
||||||
|
typedef unique_any<DLL_DIRECTORY_COOKIE, decltype(&::RemoveDllDirectory), ::RemoveDllDirectory> unique_dll_directory_cookie;
|
||||||
|
#endif // __WIL_APISETLIBLOADER_
|
||||||
|
|
||||||
|
#if defined(MSIXDYNAMICDEPENDENCY_H) && !defined(__WIL_MSIXDYNAMICDEPENDENCY_H)
|
||||||
|
#define __WIL_MSIXDYNAMICDEPENDENCY_H
|
||||||
|
typedef unique_any<MDD_PACKAGEDEPENDENCY_CONTEXT, decltype(&::MddRemovePackageDependency), ::MddRemovePackageDependency> unique_mdd_package_dependency_context;
|
||||||
|
#endif // __WIL_MSIXDYNAMICDEPENDENCY_H
|
||||||
|
|
||||||
|
#if defined(_APPMODEL_H_) && !defined(__WIL_APPMODEL_H_) && WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)
|
||||||
|
#define __WIL_APPMODEL_H_
|
||||||
|
typedef unique_any<PACKAGE_INFO_REFERENCE, decltype(&::ClosePackageInfo), ::ClosePackageInfo> unique_package_info_reference;
|
||||||
|
#endif // __WIL_APPMODEL_H_
|
||||||
|
#if defined(__WIL_APPMODEL_H_) && !defined(__WIL_APPMODEL_H_STL) && defined(WIL_RESOURCE_STL)
|
||||||
|
#define __WIL_APPMODEL_H_STL
|
||||||
|
typedef shared_any<unique_package_info_reference> shared_package_info_reference;
|
||||||
|
typedef weak_any<shared_package_info_reference> weak_package_info_reference;
|
||||||
|
#endif // __WIL_APPMODEL_H_STL
|
||||||
|
}
|
||||||
702
Sources/CWinAppSDK/nuget/include/winrtdirect3d11.h
Normal file
702
Sources/CWinAppSDK/nuget/include/winrtdirect3d11.h
Normal file
@ -0,0 +1,702 @@
|
|||||||
|
/* Header file automatically generated from winrtdirect3d11.idl */
|
||||||
|
/*
|
||||||
|
* File built with Microsoft(R) MIDLRT Compiler Engine Version 10.00.0231
|
||||||
|
*/
|
||||||
|
|
||||||
|
#pragma warning( disable: 4049 ) /* more than 64k source lines */
|
||||||
|
|
||||||
|
/* verify that the <rpcndr.h> version is high enough to compile this file*/
|
||||||
|
#ifndef __REQUIRED_RPCNDR_H_VERSION__
|
||||||
|
#define __REQUIRED_RPCNDR_H_VERSION__ 500
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* verify that the <rpcsal.h> version is high enough to compile this file*/
|
||||||
|
#ifndef __REQUIRED_RPCSAL_H_VERSION__
|
||||||
|
#define __REQUIRED_RPCSAL_H_VERSION__ 100
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <rpc.h>
|
||||||
|
#include <rpcndr.h>
|
||||||
|
|
||||||
|
#ifndef __RPCNDR_H_VERSION__
|
||||||
|
#error this stub requires an updated version of <rpcndr.h>
|
||||||
|
#endif /* __RPCNDR_H_VERSION__ */
|
||||||
|
|
||||||
|
#ifndef COM_NO_WINDOWS_H
|
||||||
|
#include <windows.h>
|
||||||
|
#include <ole2.h>
|
||||||
|
#endif /*COM_NO_WINDOWS_H*/
|
||||||
|
#ifndef __winrtdirect3d11_h__
|
||||||
|
#define __winrtdirect3d11_h__
|
||||||
|
#ifndef __winrtdirect3d11_p_h__
|
||||||
|
#define __winrtdirect3d11_p_h__
|
||||||
|
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
// Ensure that the setting of the /ns_prefix command line switch is consistent for all headers.
|
||||||
|
// If you get an error from the compiler indicating "warning C4005: 'CHECK_NS_PREFIX_STATE': macro redefinition", this
|
||||||
|
// indicates that you have included two different headers with different settings for the /ns_prefix MIDL command line switch
|
||||||
|
#if !defined(DISABLE_NS_PREFIX_CHECKS)
|
||||||
|
#if defined(MIDL_NS_PREFIX)
|
||||||
|
#define CHECK_NS_PREFIX_STATE "always"
|
||||||
|
#else
|
||||||
|
#define CHECK_NS_PREFIX_STATE "never"
|
||||||
|
#endif // MIDL_NS_PREFIX
|
||||||
|
#endif // !defined(DISABLE_NS_PREFIX_CHECKS)
|
||||||
|
|
||||||
|
|
||||||
|
#pragma push_macro("ABI_CONCAT")
|
||||||
|
#pragma push_macro("ABI_PARAMETER")
|
||||||
|
#pragma push_macro("ABI_NAMESPACE_BEGIN")
|
||||||
|
#pragma push_macro("ABI_NAMESPACE_END")
|
||||||
|
#pragma push_macro("C_IID")
|
||||||
|
#undef ABI_CONCAT
|
||||||
|
#undef ABI_PARAMETER
|
||||||
|
#undef ABI_NAMESPACE_BEGIN
|
||||||
|
#undef ABI_NAMESPACE_END
|
||||||
|
#undef C_IID
|
||||||
|
#define ABI_CONCAT(x,y) x##y
|
||||||
|
|
||||||
|
// /ns_prefix optional state
|
||||||
|
#if defined(MIDL_NS_PREFIX)
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
#define ABI_PARAMETER(x) ABI::x
|
||||||
|
#define ABI_NAMESPACE_BEGIN namespace ABI {
|
||||||
|
#define ABI_NAMESPACE_END }
|
||||||
|
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||||
|
#define C_ABI_PARAMETER(x) ABI_CONCAT(__x_ABI_C, x)
|
||||||
|
#endif // !defined(__cplusplus)
|
||||||
|
#define C_IID(x) ABI_CONCAT(IID___x_ABI_C, x)
|
||||||
|
#else
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
#define ABI_PARAMETER(x) x
|
||||||
|
#define ABI_NAMESPACE_BEGIN
|
||||||
|
#define ABI_NAMESPACE_END
|
||||||
|
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||||
|
#define C_ABI_PARAMETER(x) ABI_CONCAT(__x_, x)
|
||||||
|
#endif // !defined(__cplusplus)
|
||||||
|
#define C_IID(x) ABI_CONCAT(IID___x_, x)
|
||||||
|
#endif // defined(MIDL_NS_PREFIX)
|
||||||
|
|
||||||
|
#pragma push_macro("MIDL_CONST_ID")
|
||||||
|
#undef MIDL_CONST_ID
|
||||||
|
#define MIDL_CONST_ID const __declspec(selectany)
|
||||||
|
|
||||||
|
|
||||||
|
// API Contract Inclusion Definitions
|
||||||
|
#if !defined(SPECIFIC_API_CONTRACT_DEFINITIONS)
|
||||||
|
#if !defined(WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION)
|
||||||
|
#define WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION 0x70000
|
||||||
|
#endif // defined(WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION)
|
||||||
|
#define WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION 0x40000
|
||||||
|
#endif // defined(WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION)
|
||||||
|
#define WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION 0x130000
|
||||||
|
#endif // defined(WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION)
|
||||||
|
#define WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION 0x30000
|
||||||
|
#endif // defined(WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_PHONE_PHONECONTRACT_VERSION)
|
||||||
|
#define WINDOWS_PHONE_PHONECONTRACT_VERSION 0x10000
|
||||||
|
#endif // defined(WINDOWS_PHONE_PHONECONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION)
|
||||||
|
#define WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION 0x10000
|
||||||
|
#endif // defined(WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION)
|
||||||
|
#define WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION 0x10000
|
||||||
|
#endif // defined(WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION)
|
||||||
|
|
||||||
|
#endif // defined(SPECIFIC_API_CONTRACT_DEFINITIONS)
|
||||||
|
|
||||||
|
|
||||||
|
// Header files for imported files
|
||||||
|
#include "inspectable.h"
|
||||||
|
#include "Windows.Foundation.h"
|
||||||
|
#include "WinRTDirectXCommon.h"
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
/* Forward Declarations */
|
||||||
|
#ifndef ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
|
||||||
|
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
namespace Direct3D11 {
|
||||||
|
interface IDirect3DDevice;
|
||||||
|
} /* Direct3D11 */
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
#define __x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice ABI_PARAMETER(Windows::Graphics::DirectX::Direct3D11::IDirect3DDevice)
|
||||||
|
|
||||||
|
#endif // ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
|
||||||
|
|
||||||
|
#ifndef ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
|
||||||
|
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
namespace Direct3D11 {
|
||||||
|
interface IDirect3DSurface;
|
||||||
|
} /* Direct3D11 */
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
#define __x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface ABI_PARAMETER(Windows::Graphics::DirectX::Direct3D11::IDirect3DSurface)
|
||||||
|
|
||||||
|
#endif // ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#pragma warning (push)
|
||||||
|
#pragma warning (disable:4668)
|
||||||
|
#pragma warning (disable:4001)
|
||||||
|
#pragma once
|
||||||
|
#pragma warning (pop)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DMultisampleDescription
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
namespace Direct3D11 {
|
||||||
|
/* [contract, version, version] */
|
||||||
|
typedef
|
||||||
|
struct Direct3DMultisampleDescription
|
||||||
|
{
|
||||||
|
INT32 Count;
|
||||||
|
INT32 Quality;
|
||||||
|
} Direct3DMultisampleDescription;
|
||||||
|
|
||||||
|
} /* Direct3D11 */
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DSurfaceDescription
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
namespace Direct3D11 {
|
||||||
|
/* [contract, version, version] */
|
||||||
|
typedef
|
||||||
|
struct Direct3DSurfaceDescription
|
||||||
|
{
|
||||||
|
INT32 Width;
|
||||||
|
INT32 Height;
|
||||||
|
ABI_PARAMETER(Windows::Graphics::DirectX::DirectXPixelFormat) Format;
|
||||||
|
ABI_PARAMETER(Windows::Graphics::DirectX::Direct3D11::Direct3DMultisampleDescription) MultisampleDescription;
|
||||||
|
} Direct3DSurfaceDescription;
|
||||||
|
|
||||||
|
} /* Direct3D11 */
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DUsage
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
namespace Direct3D11 {
|
||||||
|
/* [contract, version, version] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum Direct3DUsage : int
|
||||||
|
{
|
||||||
|
Direct3DUsage_Default = 0,
|
||||||
|
Direct3DUsage_Immutable = 1,
|
||||||
|
Direct3DUsage_Dynamic = 2,
|
||||||
|
Direct3DUsage_Staging = 3,
|
||||||
|
} Direct3DUsage;
|
||||||
|
|
||||||
|
} /* Direct3D11 */
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DBindings
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
namespace Direct3D11 {
|
||||||
|
/* [contract, flags, version, version] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum Direct3DBindings : unsigned int
|
||||||
|
{
|
||||||
|
Direct3DBindings_VertexBuffer = 0x1,
|
||||||
|
Direct3DBindings_IndexBuffer = 0x2,
|
||||||
|
Direct3DBindings_ConstantBuffer = 0x4,
|
||||||
|
Direct3DBindings_ShaderResource = 0x8,
|
||||||
|
Direct3DBindings_StreamOutput = 0x10,
|
||||||
|
Direct3DBindings_RenderTarget = 0x20,
|
||||||
|
Direct3DBindings_DepthStencil = 0x40,
|
||||||
|
Direct3DBindings_UnorderedAccess = 0x80,
|
||||||
|
Direct3DBindings_Decoder = 0x200,
|
||||||
|
Direct3DBindings_VideoEncoder = 0x400,
|
||||||
|
} Direct3DBindings;
|
||||||
|
|
||||||
|
DEFINE_ENUM_FLAG_OPERATORS(Direct3DBindings)
|
||||||
|
|
||||||
|
} /* Direct3D11 */
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Interface Windows.Graphics.DirectX.Direct3D11.IDirect3DDevice
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Any object which implements this interface must also implement the following interfaces:
|
||||||
|
* Windows.Foundation.IClosable
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
#if !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__)
|
||||||
|
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__
|
||||||
|
extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_Graphics_DirectX_Direct3D11_IDirect3DDevice[] = L"Windows.Graphics.DirectX.Direct3D11.IDirect3DDevice";
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
namespace Direct3D11 {
|
||||||
|
/* [object, contract, uuid("A37624AB-8D5F-4650-9D3E-9EAE3D9BC670"), version, version] */
|
||||||
|
MIDL_INTERFACE("A37624AB-8D5F-4650-9D3E-9EAE3D9BC670")
|
||||||
|
IDirect3DDevice : public IInspectable
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE Trim(void) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
MIDL_CONST_ID IID & IID_IDirect3DDevice=__uuidof(IDirect3DDevice);
|
||||||
|
|
||||||
|
} /* Direct3D11 */
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
|
||||||
|
EXTERN_C const IID C_IID(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice);
|
||||||
|
#endif /* !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__) */
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Interface Windows.Graphics.DirectX.Direct3D11.IDirect3DSurface
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Any object which implements this interface must also implement the following interfaces:
|
||||||
|
* Windows.Foundation.IClosable
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
#if !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__)
|
||||||
|
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__
|
||||||
|
extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_Graphics_DirectX_Direct3D11_IDirect3DSurface[] = L"Windows.Graphics.DirectX.Direct3D11.IDirect3DSurface";
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
namespace Direct3D11 {
|
||||||
|
/* [object, contract, uuid("0BF4A146-13C1-4694-BEE3-7ABF15EAF586"), version, version] */
|
||||||
|
MIDL_INTERFACE("0BF4A146-13C1-4694-BEE3-7ABF15EAF586")
|
||||||
|
IDirect3DSurface : public IInspectable
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
/* [propget] */virtual HRESULT STDMETHODCALLTYPE get_Description(
|
||||||
|
/* [retval, out] */__RPC__out ABI_PARAMETER(Windows::Graphics::DirectX::Direct3D11::Direct3DSurfaceDescription) * value
|
||||||
|
) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
MIDL_CONST_ID IID & IID_IDirect3DSurface=__uuidof(IDirect3DSurface);
|
||||||
|
|
||||||
|
} /* Direct3D11 */
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
|
||||||
|
EXTERN_C const IID C_IID(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface);
|
||||||
|
#endif /* !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__) */
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
#else // !defined(__cplusplus)
|
||||||
|
/* Forward Declarations */
|
||||||
|
#ifndef ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
|
||||||
|
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
|
||||||
|
typedef interface C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice);
|
||||||
|
|
||||||
|
#endif // ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_FWD_DEFINED__
|
||||||
|
|
||||||
|
#ifndef ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
|
||||||
|
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
|
||||||
|
typedef interface C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface);
|
||||||
|
|
||||||
|
#endif // ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_FWD_DEFINED__
|
||||||
|
|
||||||
|
|
||||||
|
#pragma warning (push)
|
||||||
|
#pragma warning (disable:4668)
|
||||||
|
#pragma warning (disable:4001)
|
||||||
|
#pragma once
|
||||||
|
#pragma warning (pop)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DMultisampleDescription
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
/* [contract, version, version] */
|
||||||
|
typedef
|
||||||
|
struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DMultisampleDescription)
|
||||||
|
{
|
||||||
|
INT32 Count;
|
||||||
|
INT32 Quality;
|
||||||
|
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DMultisampleDescription);
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DSurfaceDescription
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
/* [contract, version, version] */
|
||||||
|
typedef
|
||||||
|
struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DSurfaceDescription)
|
||||||
|
{
|
||||||
|
INT32 Width;
|
||||||
|
INT32 Height;
|
||||||
|
C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXPixelFormat) Format;
|
||||||
|
C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DMultisampleDescription) MultisampleDescription;
|
||||||
|
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DSurfaceDescription);
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DUsage
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
/* [contract, version, version] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DUsage)
|
||||||
|
{
|
||||||
|
Direct3DUsage_Default = 0,
|
||||||
|
Direct3DUsage_Immutable = 1,
|
||||||
|
Direct3DUsage_Dynamic = 2,
|
||||||
|
Direct3DUsage_Staging = 3,
|
||||||
|
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DUsage);
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.Direct3D11.Direct3DBindings
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
/* [contract, flags, version, version] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DBindings)
|
||||||
|
{
|
||||||
|
Direct3DBindings_VertexBuffer = 0x1,
|
||||||
|
Direct3DBindings_IndexBuffer = 0x2,
|
||||||
|
Direct3DBindings_ConstantBuffer = 0x4,
|
||||||
|
Direct3DBindings_ShaderResource = 0x8,
|
||||||
|
Direct3DBindings_StreamOutput = 0x10,
|
||||||
|
Direct3DBindings_RenderTarget = 0x20,
|
||||||
|
Direct3DBindings_DepthStencil = 0x40,
|
||||||
|
Direct3DBindings_UnorderedAccess = 0x80,
|
||||||
|
Direct3DBindings_Decoder = 0x200,
|
||||||
|
Direct3DBindings_VideoEncoder = 0x400,
|
||||||
|
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DBindings);
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Interface Windows.Graphics.DirectX.Direct3D11.IDirect3DDevice
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Any object which implements this interface must also implement the following interfaces:
|
||||||
|
* Windows.Foundation.IClosable
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
#if !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__)
|
||||||
|
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__
|
||||||
|
extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_Graphics_DirectX_Direct3D11_IDirect3DDevice[] = L"Windows.Graphics.DirectX.Direct3D11.IDirect3DDevice";
|
||||||
|
/* [object, contract, uuid("A37624AB-8D5F-4650-9D3E-9EAE3D9BC670"), version, version] */
|
||||||
|
typedef struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDeviceVtbl)
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface)(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This,
|
||||||
|
/* [in] */ __RPC__in REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject
|
||||||
|
);
|
||||||
|
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This
|
||||||
|
);
|
||||||
|
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This
|
||||||
|
);
|
||||||
|
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *GetIids )(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This,
|
||||||
|
/* [out] */ __RPC__out ULONG *iidCount,
|
||||||
|
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids
|
||||||
|
);
|
||||||
|
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This,
|
||||||
|
/* [out] */ __RPC__deref_out_opt HSTRING *className
|
||||||
|
);
|
||||||
|
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This,
|
||||||
|
/* [OUT ] */ __RPC__out TrustLevel *trustLevel
|
||||||
|
);
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *Trim )(
|
||||||
|
C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice) * This
|
||||||
|
);
|
||||||
|
END_INTERFACE
|
||||||
|
|
||||||
|
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDeviceVtbl);
|
||||||
|
|
||||||
|
interface C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)
|
||||||
|
{
|
||||||
|
CONST_VTBL struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDeviceVtbl) *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl->QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_AddRef(This) \
|
||||||
|
( (This)->lpVtbl->AddRef(This) )
|
||||||
|
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_Release(This) \
|
||||||
|
( (This)->lpVtbl->Release(This) )
|
||||||
|
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_GetIids(This,iidCount,iids) \
|
||||||
|
( (This)->lpVtbl->GetIids(This,iidCount,iids) )
|
||||||
|
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_GetRuntimeClassName(This,className) \
|
||||||
|
( (This)->lpVtbl->GetRuntimeClassName(This,className) )
|
||||||
|
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice)_GetTrustLevel(This,trustLevel) \
|
||||||
|
( (This)->lpVtbl->GetTrustLevel(This,trustLevel) )
|
||||||
|
|
||||||
|
#define __x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_Trim(This) \
|
||||||
|
( (This)->lpVtbl->Trim(This) )
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID C_IID(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice);
|
||||||
|
#endif /* !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DDevice_INTERFACE_DEFINED__) */
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Interface Windows.Graphics.DirectX.Direct3D11.IDirect3DSurface
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Any object which implements this interface must also implement the following interfaces:
|
||||||
|
* Windows.Foundation.IClosable
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
#if !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__)
|
||||||
|
#define ____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__
|
||||||
|
extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_Graphics_DirectX_Direct3D11_IDirect3DSurface[] = L"Windows.Graphics.DirectX.Direct3D11.IDirect3DSurface";
|
||||||
|
/* [object, contract, uuid("0BF4A146-13C1-4694-BEE3-7ABF15EAF586"), version, version] */
|
||||||
|
typedef struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurfaceVtbl)
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface)(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This,
|
||||||
|
/* [in] */ __RPC__in REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject
|
||||||
|
);
|
||||||
|
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This
|
||||||
|
);
|
||||||
|
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This
|
||||||
|
);
|
||||||
|
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *GetIids )(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This,
|
||||||
|
/* [out] */ __RPC__out ULONG *iidCount,
|
||||||
|
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids
|
||||||
|
);
|
||||||
|
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This,
|
||||||
|
/* [out] */ __RPC__deref_out_opt HSTRING *className
|
||||||
|
);
|
||||||
|
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
|
||||||
|
__RPC__in C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This,
|
||||||
|
/* [OUT ] */ __RPC__out TrustLevel *trustLevel
|
||||||
|
);
|
||||||
|
/* [propget] */HRESULT ( STDMETHODCALLTYPE *get_Description )(
|
||||||
|
C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface) * This,
|
||||||
|
/* [retval, out] */__RPC__out C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CDirect3DSurfaceDescription) * value
|
||||||
|
);
|
||||||
|
END_INTERFACE
|
||||||
|
|
||||||
|
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurfaceVtbl);
|
||||||
|
|
||||||
|
interface C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)
|
||||||
|
{
|
||||||
|
CONST_VTBL struct C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurfaceVtbl) *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl->QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_AddRef(This) \
|
||||||
|
( (This)->lpVtbl->AddRef(This) )
|
||||||
|
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_Release(This) \
|
||||||
|
( (This)->lpVtbl->Release(This) )
|
||||||
|
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_GetIids(This,iidCount,iids) \
|
||||||
|
( (This)->lpVtbl->GetIids(This,iidCount,iids) )
|
||||||
|
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_GetRuntimeClassName(This,className) \
|
||||||
|
( (This)->lpVtbl->GetRuntimeClassName(This,className) )
|
||||||
|
|
||||||
|
#define C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface)_GetTrustLevel(This,trustLevel) \
|
||||||
|
( (This)->lpVtbl->GetTrustLevel(This,trustLevel) )
|
||||||
|
|
||||||
|
#define __x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_get_Description(This,value) \
|
||||||
|
( (This)->lpVtbl->get_Description(This,value) )
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID C_IID(Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface);
|
||||||
|
#endif /* !defined(____x_Windows_CGraphics_CDirectX_CDirect3D11_CIDirect3DSurface_INTERFACE_DEFINED__) */
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
#endif // defined(__cplusplus)
|
||||||
|
#pragma pop_macro("MIDL_CONST_ID")
|
||||||
|
#pragma pop_macro("C_IID")
|
||||||
|
#pragma pop_macro("ABI_CONCAT")
|
||||||
|
#pragma pop_macro("ABI_PARAMETER")
|
||||||
|
#pragma pop_macro("ABI_NAMESPACE_BEGIN")
|
||||||
|
#pragma pop_macro("ABI_NAMESPACE_END")
|
||||||
|
|
||||||
|
|
||||||
|
#endif // __winrtdirect3d11_p_h__
|
||||||
|
|
||||||
|
#endif // __winrtdirect3d11_h__
|
||||||
684
Sources/CWinAppSDK/nuget/include/winrtdirectxcommon.h
Normal file
684
Sources/CWinAppSDK/nuget/include/winrtdirectxcommon.h
Normal file
@ -0,0 +1,684 @@
|
|||||||
|
/* Header file automatically generated from winrtdirectxcommon.idl */
|
||||||
|
/*
|
||||||
|
* File built with Microsoft(R) MIDLRT Compiler Engine Version 10.00.0231
|
||||||
|
*/
|
||||||
|
|
||||||
|
#pragma warning( disable: 4049 ) /* more than 64k source lines */
|
||||||
|
|
||||||
|
/* verify that the <rpcndr.h> version is high enough to compile this file*/
|
||||||
|
#ifndef __REQUIRED_RPCNDR_H_VERSION__
|
||||||
|
#define __REQUIRED_RPCNDR_H_VERSION__ 500
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* verify that the <rpcsal.h> version is high enough to compile this file*/
|
||||||
|
#ifndef __REQUIRED_RPCSAL_H_VERSION__
|
||||||
|
#define __REQUIRED_RPCSAL_H_VERSION__ 100
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <rpc.h>
|
||||||
|
#include <rpcndr.h>
|
||||||
|
|
||||||
|
#ifndef __RPCNDR_H_VERSION__
|
||||||
|
#error this stub requires an updated version of <rpcndr.h>
|
||||||
|
#endif /* __RPCNDR_H_VERSION__ */
|
||||||
|
|
||||||
|
#ifndef COM_NO_WINDOWS_H
|
||||||
|
#include <windows.h>
|
||||||
|
#include <ole2.h>
|
||||||
|
#endif /*COM_NO_WINDOWS_H*/
|
||||||
|
#ifndef __winrtdirectxcommon_h__
|
||||||
|
#define __winrtdirectxcommon_h__
|
||||||
|
#ifndef __winrtdirectxcommon_p_h__
|
||||||
|
#define __winrtdirectxcommon_p_h__
|
||||||
|
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
// Ensure that the setting of the /ns_prefix command line switch is consistent for all headers.
|
||||||
|
// If you get an error from the compiler indicating "warning C4005: 'CHECK_NS_PREFIX_STATE': macro redefinition", this
|
||||||
|
// indicates that you have included two different headers with different settings for the /ns_prefix MIDL command line switch
|
||||||
|
#if !defined(DISABLE_NS_PREFIX_CHECKS)
|
||||||
|
#if defined(MIDL_NS_PREFIX)
|
||||||
|
#define CHECK_NS_PREFIX_STATE "always"
|
||||||
|
#else
|
||||||
|
#define CHECK_NS_PREFIX_STATE "never"
|
||||||
|
#endif // MIDL_NS_PREFIX
|
||||||
|
#endif // !defined(DISABLE_NS_PREFIX_CHECKS)
|
||||||
|
|
||||||
|
|
||||||
|
#pragma push_macro("ABI_CONCAT")
|
||||||
|
#pragma push_macro("ABI_PARAMETER")
|
||||||
|
#pragma push_macro("ABI_NAMESPACE_BEGIN")
|
||||||
|
#pragma push_macro("ABI_NAMESPACE_END")
|
||||||
|
#pragma push_macro("C_IID")
|
||||||
|
#undef ABI_CONCAT
|
||||||
|
#undef ABI_PARAMETER
|
||||||
|
#undef ABI_NAMESPACE_BEGIN
|
||||||
|
#undef ABI_NAMESPACE_END
|
||||||
|
#undef C_IID
|
||||||
|
#define ABI_CONCAT(x,y) x##y
|
||||||
|
|
||||||
|
// /ns_prefix optional state
|
||||||
|
#if defined(MIDL_NS_PREFIX)
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
#define ABI_PARAMETER(x) ABI::x
|
||||||
|
#define ABI_NAMESPACE_BEGIN namespace ABI {
|
||||||
|
#define ABI_NAMESPACE_END }
|
||||||
|
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||||
|
#define C_ABI_PARAMETER(x) ABI_CONCAT(__x_ABI_C, x)
|
||||||
|
#endif // !defined(__cplusplus)
|
||||||
|
#define C_IID(x) ABI_CONCAT(IID___x_ABI_C, x)
|
||||||
|
#else
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
#define ABI_PARAMETER(x) x
|
||||||
|
#define ABI_NAMESPACE_BEGIN
|
||||||
|
#define ABI_NAMESPACE_END
|
||||||
|
#else // !defined(__cplusplus) || defined(CINTERFACE)
|
||||||
|
#define C_ABI_PARAMETER(x) ABI_CONCAT(__x_, x)
|
||||||
|
#endif // !defined(__cplusplus)
|
||||||
|
#define C_IID(x) ABI_CONCAT(IID___x_, x)
|
||||||
|
#endif // defined(MIDL_NS_PREFIX)
|
||||||
|
|
||||||
|
#pragma push_macro("MIDL_CONST_ID")
|
||||||
|
#undef MIDL_CONST_ID
|
||||||
|
#define MIDL_CONST_ID const __declspec(selectany)
|
||||||
|
|
||||||
|
|
||||||
|
// API Contract Inclusion Definitions
|
||||||
|
#if !defined(SPECIFIC_API_CONTRACT_DEFINITIONS)
|
||||||
|
#if !defined(WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION)
|
||||||
|
#define WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION 0x70000
|
||||||
|
#endif // defined(WINDOWS_APPLICATIONMODEL_CALLS_CALLSPHONECONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION)
|
||||||
|
#define WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION 0x40000
|
||||||
|
#endif // defined(WINDOWS_FOUNDATION_FOUNDATIONCONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION)
|
||||||
|
#define WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION 0x130000
|
||||||
|
#endif // defined(WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION)
|
||||||
|
#define WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION 0x30000
|
||||||
|
#endif // defined(WINDOWS_NETWORKING_SOCKETS_CONTROLCHANNELTRIGGERCONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_PHONE_PHONECONTRACT_VERSION)
|
||||||
|
#define WINDOWS_PHONE_PHONECONTRACT_VERSION 0x10000
|
||||||
|
#endif // defined(WINDOWS_PHONE_PHONECONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION)
|
||||||
|
#define WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION 0x10000
|
||||||
|
#endif // defined(WINDOWS_PHONE_PHONEINTERNALCONTRACT_VERSION)
|
||||||
|
|
||||||
|
#if !defined(WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION)
|
||||||
|
#define WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION 0x10000
|
||||||
|
#endif // defined(WINDOWS_UI_WEBUI_CORE_WEBUICOMMANDBARCONTRACT_VERSION)
|
||||||
|
|
||||||
|
#endif // defined(SPECIFIC_API_CONTRACT_DEFINITIONS)
|
||||||
|
|
||||||
|
|
||||||
|
// Header files for imported files
|
||||||
|
#include "inspectable.h"
|
||||||
|
#include "Windows.Foundation.h"
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
/* Forward Declarations */
|
||||||
|
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
#pragma warning (push)
|
||||||
|
#pragma warning (disable:4668)
|
||||||
|
#pragma warning (disable:4001)
|
||||||
|
#pragma once
|
||||||
|
#pragma warning (pop)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.DirectXAlphaMode
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 2.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x20000
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
/* [contract, version, version] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum DirectXAlphaMode : int
|
||||||
|
{
|
||||||
|
DirectXAlphaMode_Unspecified = 0,
|
||||||
|
DirectXAlphaMode_Premultiplied = 1,
|
||||||
|
DirectXAlphaMode_Straight = 2,
|
||||||
|
DirectXAlphaMode_Ignore = 3,
|
||||||
|
} DirectXAlphaMode;
|
||||||
|
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x20000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.DirectXPixelFormat
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
/* [contract, version, version] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum DirectXPixelFormat : int
|
||||||
|
{
|
||||||
|
DirectXPixelFormat_Unknown = 0,
|
||||||
|
DirectXPixelFormat_R32G32B32A32Typeless = 1,
|
||||||
|
DirectXPixelFormat_R32G32B32A32Float = 2,
|
||||||
|
DirectXPixelFormat_R32G32B32A32UInt = 3,
|
||||||
|
DirectXPixelFormat_R32G32B32A32Int = 4,
|
||||||
|
DirectXPixelFormat_R32G32B32Typeless = 5,
|
||||||
|
DirectXPixelFormat_R32G32B32Float = 6,
|
||||||
|
DirectXPixelFormat_R32G32B32UInt = 7,
|
||||||
|
DirectXPixelFormat_R32G32B32Int = 8,
|
||||||
|
DirectXPixelFormat_R16G16B16A16Typeless = 9,
|
||||||
|
DirectXPixelFormat_R16G16B16A16Float = 10,
|
||||||
|
DirectXPixelFormat_R16G16B16A16UIntNormalized = 11,
|
||||||
|
DirectXPixelFormat_R16G16B16A16UInt = 12,
|
||||||
|
DirectXPixelFormat_R16G16B16A16IntNormalized = 13,
|
||||||
|
DirectXPixelFormat_R16G16B16A16Int = 14,
|
||||||
|
DirectXPixelFormat_R32G32Typeless = 15,
|
||||||
|
DirectXPixelFormat_R32G32Float = 16,
|
||||||
|
DirectXPixelFormat_R32G32UInt = 17,
|
||||||
|
DirectXPixelFormat_R32G32Int = 18,
|
||||||
|
DirectXPixelFormat_R32G8X24Typeless = 19,
|
||||||
|
DirectXPixelFormat_D32FloatS8X24UInt = 20,
|
||||||
|
DirectXPixelFormat_R32FloatX8X24Typeless = 21,
|
||||||
|
DirectXPixelFormat_X32TypelessG8X24UInt = 22,
|
||||||
|
DirectXPixelFormat_R10G10B10A2Typeless = 23,
|
||||||
|
DirectXPixelFormat_R10G10B10A2UIntNormalized = 24,
|
||||||
|
DirectXPixelFormat_R10G10B10A2UInt = 25,
|
||||||
|
DirectXPixelFormat_R11G11B10Float = 26,
|
||||||
|
DirectXPixelFormat_R8G8B8A8Typeless = 27,
|
||||||
|
DirectXPixelFormat_R8G8B8A8UIntNormalized = 28,
|
||||||
|
DirectXPixelFormat_R8G8B8A8UIntNormalizedSrgb = 29,
|
||||||
|
DirectXPixelFormat_R8G8B8A8UInt = 30,
|
||||||
|
DirectXPixelFormat_R8G8B8A8IntNormalized = 31,
|
||||||
|
DirectXPixelFormat_R8G8B8A8Int = 32,
|
||||||
|
DirectXPixelFormat_R16G16Typeless = 33,
|
||||||
|
DirectXPixelFormat_R16G16Float = 34,
|
||||||
|
DirectXPixelFormat_R16G16UIntNormalized = 35,
|
||||||
|
DirectXPixelFormat_R16G16UInt = 36,
|
||||||
|
DirectXPixelFormat_R16G16IntNormalized = 37,
|
||||||
|
DirectXPixelFormat_R16G16Int = 38,
|
||||||
|
DirectXPixelFormat_R32Typeless = 39,
|
||||||
|
DirectXPixelFormat_D32Float = 40,
|
||||||
|
DirectXPixelFormat_R32Float = 41,
|
||||||
|
DirectXPixelFormat_R32UInt = 42,
|
||||||
|
DirectXPixelFormat_R32Int = 43,
|
||||||
|
DirectXPixelFormat_R24G8Typeless = 44,
|
||||||
|
DirectXPixelFormat_D24UIntNormalizedS8UInt = 45,
|
||||||
|
DirectXPixelFormat_R24UIntNormalizedX8Typeless = 46,
|
||||||
|
DirectXPixelFormat_X24TypelessG8UInt = 47,
|
||||||
|
DirectXPixelFormat_R8G8Typeless = 48,
|
||||||
|
DirectXPixelFormat_R8G8UIntNormalized = 49,
|
||||||
|
DirectXPixelFormat_R8G8UInt = 50,
|
||||||
|
DirectXPixelFormat_R8G8IntNormalized = 51,
|
||||||
|
DirectXPixelFormat_R8G8Int = 52,
|
||||||
|
DirectXPixelFormat_R16Typeless = 53,
|
||||||
|
DirectXPixelFormat_R16Float = 54,
|
||||||
|
DirectXPixelFormat_D16UIntNormalized = 55,
|
||||||
|
DirectXPixelFormat_R16UIntNormalized = 56,
|
||||||
|
DirectXPixelFormat_R16UInt = 57,
|
||||||
|
DirectXPixelFormat_R16IntNormalized = 58,
|
||||||
|
DirectXPixelFormat_R16Int = 59,
|
||||||
|
DirectXPixelFormat_R8Typeless = 60,
|
||||||
|
DirectXPixelFormat_R8UIntNormalized = 61,
|
||||||
|
DirectXPixelFormat_R8UInt = 62,
|
||||||
|
DirectXPixelFormat_R8IntNormalized = 63,
|
||||||
|
DirectXPixelFormat_R8Int = 64,
|
||||||
|
DirectXPixelFormat_A8UIntNormalized = 65,
|
||||||
|
DirectXPixelFormat_R1UIntNormalized = 66,
|
||||||
|
DirectXPixelFormat_R9G9B9E5SharedExponent = 67,
|
||||||
|
DirectXPixelFormat_R8G8B8G8UIntNormalized = 68,
|
||||||
|
DirectXPixelFormat_G8R8G8B8UIntNormalized = 69,
|
||||||
|
DirectXPixelFormat_BC1Typeless = 70,
|
||||||
|
DirectXPixelFormat_BC1UIntNormalized = 71,
|
||||||
|
DirectXPixelFormat_BC1UIntNormalizedSrgb = 72,
|
||||||
|
DirectXPixelFormat_BC2Typeless = 73,
|
||||||
|
DirectXPixelFormat_BC2UIntNormalized = 74,
|
||||||
|
DirectXPixelFormat_BC2UIntNormalizedSrgb = 75,
|
||||||
|
DirectXPixelFormat_BC3Typeless = 76,
|
||||||
|
DirectXPixelFormat_BC3UIntNormalized = 77,
|
||||||
|
DirectXPixelFormat_BC3UIntNormalizedSrgb = 78,
|
||||||
|
DirectXPixelFormat_BC4Typeless = 79,
|
||||||
|
DirectXPixelFormat_BC4UIntNormalized = 80,
|
||||||
|
DirectXPixelFormat_BC4IntNormalized = 81,
|
||||||
|
DirectXPixelFormat_BC5Typeless = 82,
|
||||||
|
DirectXPixelFormat_BC5UIntNormalized = 83,
|
||||||
|
DirectXPixelFormat_BC5IntNormalized = 84,
|
||||||
|
DirectXPixelFormat_B5G6R5UIntNormalized = 85,
|
||||||
|
DirectXPixelFormat_B5G5R5A1UIntNormalized = 86,
|
||||||
|
DirectXPixelFormat_B8G8R8A8UIntNormalized = 87,
|
||||||
|
DirectXPixelFormat_B8G8R8X8UIntNormalized = 88,
|
||||||
|
DirectXPixelFormat_R10G10B10XRBiasA2UIntNormalized = 89,
|
||||||
|
DirectXPixelFormat_B8G8R8A8Typeless = 90,
|
||||||
|
DirectXPixelFormat_B8G8R8A8UIntNormalizedSrgb = 91,
|
||||||
|
DirectXPixelFormat_B8G8R8X8Typeless = 92,
|
||||||
|
DirectXPixelFormat_B8G8R8X8UIntNormalizedSrgb = 93,
|
||||||
|
DirectXPixelFormat_BC6HTypeless = 94,
|
||||||
|
DirectXPixelFormat_BC6H16UnsignedFloat = 95,
|
||||||
|
DirectXPixelFormat_BC6H16Float = 96,
|
||||||
|
DirectXPixelFormat_BC7Typeless = 97,
|
||||||
|
DirectXPixelFormat_BC7UIntNormalized = 98,
|
||||||
|
DirectXPixelFormat_BC7UIntNormalizedSrgb = 99,
|
||||||
|
DirectXPixelFormat_Ayuv = 100,
|
||||||
|
DirectXPixelFormat_Y410 = 101,
|
||||||
|
DirectXPixelFormat_Y416 = 102,
|
||||||
|
DirectXPixelFormat_NV12 = 103,
|
||||||
|
DirectXPixelFormat_P010 = 104,
|
||||||
|
DirectXPixelFormat_P016 = 105,
|
||||||
|
DirectXPixelFormat_Opaque420 = 106,
|
||||||
|
DirectXPixelFormat_Yuy2 = 107,
|
||||||
|
DirectXPixelFormat_Y210 = 108,
|
||||||
|
DirectXPixelFormat_Y216 = 109,
|
||||||
|
DirectXPixelFormat_NV11 = 110,
|
||||||
|
DirectXPixelFormat_AI44 = 111,
|
||||||
|
DirectXPixelFormat_IA44 = 112,
|
||||||
|
DirectXPixelFormat_P8 = 113,
|
||||||
|
DirectXPixelFormat_A8P8 = 114,
|
||||||
|
DirectXPixelFormat_B4G4R4A4UIntNormalized = 115,
|
||||||
|
DirectXPixelFormat_P208 = 130,
|
||||||
|
DirectXPixelFormat_V208 = 131,
|
||||||
|
DirectXPixelFormat_V408 = 132,
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
|
||||||
|
|
||||||
|
DirectXPixelFormat_SamplerFeedbackMinMipOpaque = 189,
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
|
||||||
|
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
|
||||||
|
|
||||||
|
DirectXPixelFormat_SamplerFeedbackMipRegionUsedOpaque = 190,
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
|
||||||
|
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x100000
|
||||||
|
|
||||||
|
DirectXPixelFormat_A4B4G4R4 = 191,
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x100000
|
||||||
|
|
||||||
|
} DirectXPixelFormat;
|
||||||
|
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.DirectXColorSpace
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 6.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x60000
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
/* [contract] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum DirectXColorSpace : int
|
||||||
|
{
|
||||||
|
DirectXColorSpace_RgbFullG22NoneP709 = 0,
|
||||||
|
DirectXColorSpace_RgbFullG10NoneP709 = 1,
|
||||||
|
DirectXColorSpace_RgbStudioG22NoneP709 = 2,
|
||||||
|
DirectXColorSpace_RgbStudioG22NoneP2020 = 3,
|
||||||
|
DirectXColorSpace_Reserved = 4,
|
||||||
|
DirectXColorSpace_YccFullG22NoneP709X601 = 5,
|
||||||
|
DirectXColorSpace_YccStudioG22LeftP601 = 6,
|
||||||
|
DirectXColorSpace_YccFullG22LeftP601 = 7,
|
||||||
|
DirectXColorSpace_YccStudioG22LeftP709 = 8,
|
||||||
|
DirectXColorSpace_YccFullG22LeftP709 = 9,
|
||||||
|
DirectXColorSpace_YccStudioG22LeftP2020 = 10,
|
||||||
|
DirectXColorSpace_YccFullG22LeftP2020 = 11,
|
||||||
|
DirectXColorSpace_RgbFullG2084NoneP2020 = 12,
|
||||||
|
DirectXColorSpace_YccStudioG2084LeftP2020 = 13,
|
||||||
|
DirectXColorSpace_RgbStudioG2084NoneP2020 = 14,
|
||||||
|
DirectXColorSpace_YccStudioG22TopLeftP2020 = 15,
|
||||||
|
DirectXColorSpace_YccStudioG2084TopLeftP2020 = 16,
|
||||||
|
DirectXColorSpace_RgbFullG22NoneP2020 = 17,
|
||||||
|
DirectXColorSpace_YccStudioGHlgTopLeftP2020 = 18,
|
||||||
|
DirectXColorSpace_YccFullGHlgTopLeftP2020 = 19,
|
||||||
|
DirectXColorSpace_RgbStudioG24NoneP709 = 20,
|
||||||
|
DirectXColorSpace_RgbStudioG24NoneP2020 = 21,
|
||||||
|
DirectXColorSpace_YccStudioG24LeftP709 = 22,
|
||||||
|
DirectXColorSpace_YccStudioG24LeftP2020 = 23,
|
||||||
|
DirectXColorSpace_YccStudioG24TopLeftP2020 = 24,
|
||||||
|
} DirectXColorSpace;
|
||||||
|
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x60000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.DirectXPrimitiveTopology
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 8.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x80000
|
||||||
|
ABI_NAMESPACE_BEGIN
|
||||||
|
namespace Windows {
|
||||||
|
namespace Graphics {
|
||||||
|
namespace DirectX {
|
||||||
|
/* [contract] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum DirectXPrimitiveTopology : int
|
||||||
|
{
|
||||||
|
DirectXPrimitiveTopology_Undefined = 0,
|
||||||
|
DirectXPrimitiveTopology_PointList = 1,
|
||||||
|
DirectXPrimitiveTopology_LineList = 2,
|
||||||
|
DirectXPrimitiveTopology_LineStrip = 3,
|
||||||
|
DirectXPrimitiveTopology_TriangleList = 4,
|
||||||
|
DirectXPrimitiveTopology_TriangleStrip = 5,
|
||||||
|
} DirectXPrimitiveTopology;
|
||||||
|
|
||||||
|
} /* DirectX */
|
||||||
|
} /* Graphics */
|
||||||
|
} /* Windows */
|
||||||
|
ABI_NAMESPACE_END
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x80000
|
||||||
|
|
||||||
|
|
||||||
|
#else // !defined(__cplusplus)
|
||||||
|
/* Forward Declarations */
|
||||||
|
|
||||||
|
#pragma once
|
||||||
|
#pragma warning (push)
|
||||||
|
#pragma warning (disable:4668)
|
||||||
|
#pragma warning (disable:4001)
|
||||||
|
#pragma once
|
||||||
|
#pragma warning (pop)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.DirectXAlphaMode
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 2.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x20000
|
||||||
|
/* [contract, version, version] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXAlphaMode)
|
||||||
|
{
|
||||||
|
DirectXAlphaMode_Unspecified = 0,
|
||||||
|
DirectXAlphaMode_Premultiplied = 1,
|
||||||
|
DirectXAlphaMode_Straight = 2,
|
||||||
|
DirectXAlphaMode_Ignore = 3,
|
||||||
|
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXAlphaMode);
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x20000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.DirectXPixelFormat
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 1.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
/* [contract, version, version] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXPixelFormat)
|
||||||
|
{
|
||||||
|
DirectXPixelFormat_Unknown = 0,
|
||||||
|
DirectXPixelFormat_R32G32B32A32Typeless = 1,
|
||||||
|
DirectXPixelFormat_R32G32B32A32Float = 2,
|
||||||
|
DirectXPixelFormat_R32G32B32A32UInt = 3,
|
||||||
|
DirectXPixelFormat_R32G32B32A32Int = 4,
|
||||||
|
DirectXPixelFormat_R32G32B32Typeless = 5,
|
||||||
|
DirectXPixelFormat_R32G32B32Float = 6,
|
||||||
|
DirectXPixelFormat_R32G32B32UInt = 7,
|
||||||
|
DirectXPixelFormat_R32G32B32Int = 8,
|
||||||
|
DirectXPixelFormat_R16G16B16A16Typeless = 9,
|
||||||
|
DirectXPixelFormat_R16G16B16A16Float = 10,
|
||||||
|
DirectXPixelFormat_R16G16B16A16UIntNormalized = 11,
|
||||||
|
DirectXPixelFormat_R16G16B16A16UInt = 12,
|
||||||
|
DirectXPixelFormat_R16G16B16A16IntNormalized = 13,
|
||||||
|
DirectXPixelFormat_R16G16B16A16Int = 14,
|
||||||
|
DirectXPixelFormat_R32G32Typeless = 15,
|
||||||
|
DirectXPixelFormat_R32G32Float = 16,
|
||||||
|
DirectXPixelFormat_R32G32UInt = 17,
|
||||||
|
DirectXPixelFormat_R32G32Int = 18,
|
||||||
|
DirectXPixelFormat_R32G8X24Typeless = 19,
|
||||||
|
DirectXPixelFormat_D32FloatS8X24UInt = 20,
|
||||||
|
DirectXPixelFormat_R32FloatX8X24Typeless = 21,
|
||||||
|
DirectXPixelFormat_X32TypelessG8X24UInt = 22,
|
||||||
|
DirectXPixelFormat_R10G10B10A2Typeless = 23,
|
||||||
|
DirectXPixelFormat_R10G10B10A2UIntNormalized = 24,
|
||||||
|
DirectXPixelFormat_R10G10B10A2UInt = 25,
|
||||||
|
DirectXPixelFormat_R11G11B10Float = 26,
|
||||||
|
DirectXPixelFormat_R8G8B8A8Typeless = 27,
|
||||||
|
DirectXPixelFormat_R8G8B8A8UIntNormalized = 28,
|
||||||
|
DirectXPixelFormat_R8G8B8A8UIntNormalizedSrgb = 29,
|
||||||
|
DirectXPixelFormat_R8G8B8A8UInt = 30,
|
||||||
|
DirectXPixelFormat_R8G8B8A8IntNormalized = 31,
|
||||||
|
DirectXPixelFormat_R8G8B8A8Int = 32,
|
||||||
|
DirectXPixelFormat_R16G16Typeless = 33,
|
||||||
|
DirectXPixelFormat_R16G16Float = 34,
|
||||||
|
DirectXPixelFormat_R16G16UIntNormalized = 35,
|
||||||
|
DirectXPixelFormat_R16G16UInt = 36,
|
||||||
|
DirectXPixelFormat_R16G16IntNormalized = 37,
|
||||||
|
DirectXPixelFormat_R16G16Int = 38,
|
||||||
|
DirectXPixelFormat_R32Typeless = 39,
|
||||||
|
DirectXPixelFormat_D32Float = 40,
|
||||||
|
DirectXPixelFormat_R32Float = 41,
|
||||||
|
DirectXPixelFormat_R32UInt = 42,
|
||||||
|
DirectXPixelFormat_R32Int = 43,
|
||||||
|
DirectXPixelFormat_R24G8Typeless = 44,
|
||||||
|
DirectXPixelFormat_D24UIntNormalizedS8UInt = 45,
|
||||||
|
DirectXPixelFormat_R24UIntNormalizedX8Typeless = 46,
|
||||||
|
DirectXPixelFormat_X24TypelessG8UInt = 47,
|
||||||
|
DirectXPixelFormat_R8G8Typeless = 48,
|
||||||
|
DirectXPixelFormat_R8G8UIntNormalized = 49,
|
||||||
|
DirectXPixelFormat_R8G8UInt = 50,
|
||||||
|
DirectXPixelFormat_R8G8IntNormalized = 51,
|
||||||
|
DirectXPixelFormat_R8G8Int = 52,
|
||||||
|
DirectXPixelFormat_R16Typeless = 53,
|
||||||
|
DirectXPixelFormat_R16Float = 54,
|
||||||
|
DirectXPixelFormat_D16UIntNormalized = 55,
|
||||||
|
DirectXPixelFormat_R16UIntNormalized = 56,
|
||||||
|
DirectXPixelFormat_R16UInt = 57,
|
||||||
|
DirectXPixelFormat_R16IntNormalized = 58,
|
||||||
|
DirectXPixelFormat_R16Int = 59,
|
||||||
|
DirectXPixelFormat_R8Typeless = 60,
|
||||||
|
DirectXPixelFormat_R8UIntNormalized = 61,
|
||||||
|
DirectXPixelFormat_R8UInt = 62,
|
||||||
|
DirectXPixelFormat_R8IntNormalized = 63,
|
||||||
|
DirectXPixelFormat_R8Int = 64,
|
||||||
|
DirectXPixelFormat_A8UIntNormalized = 65,
|
||||||
|
DirectXPixelFormat_R1UIntNormalized = 66,
|
||||||
|
DirectXPixelFormat_R9G9B9E5SharedExponent = 67,
|
||||||
|
DirectXPixelFormat_R8G8B8G8UIntNormalized = 68,
|
||||||
|
DirectXPixelFormat_G8R8G8B8UIntNormalized = 69,
|
||||||
|
DirectXPixelFormat_BC1Typeless = 70,
|
||||||
|
DirectXPixelFormat_BC1UIntNormalized = 71,
|
||||||
|
DirectXPixelFormat_BC1UIntNormalizedSrgb = 72,
|
||||||
|
DirectXPixelFormat_BC2Typeless = 73,
|
||||||
|
DirectXPixelFormat_BC2UIntNormalized = 74,
|
||||||
|
DirectXPixelFormat_BC2UIntNormalizedSrgb = 75,
|
||||||
|
DirectXPixelFormat_BC3Typeless = 76,
|
||||||
|
DirectXPixelFormat_BC3UIntNormalized = 77,
|
||||||
|
DirectXPixelFormat_BC3UIntNormalizedSrgb = 78,
|
||||||
|
DirectXPixelFormat_BC4Typeless = 79,
|
||||||
|
DirectXPixelFormat_BC4UIntNormalized = 80,
|
||||||
|
DirectXPixelFormat_BC4IntNormalized = 81,
|
||||||
|
DirectXPixelFormat_BC5Typeless = 82,
|
||||||
|
DirectXPixelFormat_BC5UIntNormalized = 83,
|
||||||
|
DirectXPixelFormat_BC5IntNormalized = 84,
|
||||||
|
DirectXPixelFormat_B5G6R5UIntNormalized = 85,
|
||||||
|
DirectXPixelFormat_B5G5R5A1UIntNormalized = 86,
|
||||||
|
DirectXPixelFormat_B8G8R8A8UIntNormalized = 87,
|
||||||
|
DirectXPixelFormat_B8G8R8X8UIntNormalized = 88,
|
||||||
|
DirectXPixelFormat_R10G10B10XRBiasA2UIntNormalized = 89,
|
||||||
|
DirectXPixelFormat_B8G8R8A8Typeless = 90,
|
||||||
|
DirectXPixelFormat_B8G8R8A8UIntNormalizedSrgb = 91,
|
||||||
|
DirectXPixelFormat_B8G8R8X8Typeless = 92,
|
||||||
|
DirectXPixelFormat_B8G8R8X8UIntNormalizedSrgb = 93,
|
||||||
|
DirectXPixelFormat_BC6HTypeless = 94,
|
||||||
|
DirectXPixelFormat_BC6H16UnsignedFloat = 95,
|
||||||
|
DirectXPixelFormat_BC6H16Float = 96,
|
||||||
|
DirectXPixelFormat_BC7Typeless = 97,
|
||||||
|
DirectXPixelFormat_BC7UIntNormalized = 98,
|
||||||
|
DirectXPixelFormat_BC7UIntNormalizedSrgb = 99,
|
||||||
|
DirectXPixelFormat_Ayuv = 100,
|
||||||
|
DirectXPixelFormat_Y410 = 101,
|
||||||
|
DirectXPixelFormat_Y416 = 102,
|
||||||
|
DirectXPixelFormat_NV12 = 103,
|
||||||
|
DirectXPixelFormat_P010 = 104,
|
||||||
|
DirectXPixelFormat_P016 = 105,
|
||||||
|
DirectXPixelFormat_Opaque420 = 106,
|
||||||
|
DirectXPixelFormat_Yuy2 = 107,
|
||||||
|
DirectXPixelFormat_Y210 = 108,
|
||||||
|
DirectXPixelFormat_Y216 = 109,
|
||||||
|
DirectXPixelFormat_NV11 = 110,
|
||||||
|
DirectXPixelFormat_AI44 = 111,
|
||||||
|
DirectXPixelFormat_IA44 = 112,
|
||||||
|
DirectXPixelFormat_P8 = 113,
|
||||||
|
DirectXPixelFormat_A8P8 = 114,
|
||||||
|
DirectXPixelFormat_B4G4R4A4UIntNormalized = 115,
|
||||||
|
DirectXPixelFormat_P208 = 130,
|
||||||
|
DirectXPixelFormat_V208 = 131,
|
||||||
|
DirectXPixelFormat_V408 = 132,
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
|
||||||
|
|
||||||
|
DirectXPixelFormat_SamplerFeedbackMinMipOpaque = 189,
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
|
||||||
|
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
|
||||||
|
|
||||||
|
DirectXPixelFormat_SamplerFeedbackMipRegionUsedOpaque = 190,
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0xa0000
|
||||||
|
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x100000
|
||||||
|
|
||||||
|
DirectXPixelFormat_A4B4G4R4 = 191,
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x100000
|
||||||
|
|
||||||
|
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXPixelFormat);
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x10000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.DirectXColorSpace
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 6.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x60000
|
||||||
|
/* [contract] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXColorSpace)
|
||||||
|
{
|
||||||
|
DirectXColorSpace_RgbFullG22NoneP709 = 0,
|
||||||
|
DirectXColorSpace_RgbFullG10NoneP709 = 1,
|
||||||
|
DirectXColorSpace_RgbStudioG22NoneP709 = 2,
|
||||||
|
DirectXColorSpace_RgbStudioG22NoneP2020 = 3,
|
||||||
|
DirectXColorSpace_Reserved = 4,
|
||||||
|
DirectXColorSpace_YccFullG22NoneP709X601 = 5,
|
||||||
|
DirectXColorSpace_YccStudioG22LeftP601 = 6,
|
||||||
|
DirectXColorSpace_YccFullG22LeftP601 = 7,
|
||||||
|
DirectXColorSpace_YccStudioG22LeftP709 = 8,
|
||||||
|
DirectXColorSpace_YccFullG22LeftP709 = 9,
|
||||||
|
DirectXColorSpace_YccStudioG22LeftP2020 = 10,
|
||||||
|
DirectXColorSpace_YccFullG22LeftP2020 = 11,
|
||||||
|
DirectXColorSpace_RgbFullG2084NoneP2020 = 12,
|
||||||
|
DirectXColorSpace_YccStudioG2084LeftP2020 = 13,
|
||||||
|
DirectXColorSpace_RgbStudioG2084NoneP2020 = 14,
|
||||||
|
DirectXColorSpace_YccStudioG22TopLeftP2020 = 15,
|
||||||
|
DirectXColorSpace_YccStudioG2084TopLeftP2020 = 16,
|
||||||
|
DirectXColorSpace_RgbFullG22NoneP2020 = 17,
|
||||||
|
DirectXColorSpace_YccStudioGHlgTopLeftP2020 = 18,
|
||||||
|
DirectXColorSpace_YccFullGHlgTopLeftP2020 = 19,
|
||||||
|
DirectXColorSpace_RgbStudioG24NoneP709 = 20,
|
||||||
|
DirectXColorSpace_RgbStudioG24NoneP2020 = 21,
|
||||||
|
DirectXColorSpace_YccStudioG24LeftP709 = 22,
|
||||||
|
DirectXColorSpace_YccStudioG24LeftP2020 = 23,
|
||||||
|
DirectXColorSpace_YccStudioG24TopLeftP2020 = 24,
|
||||||
|
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXColorSpace);
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x60000
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Typedef of Windows.Graphics.DirectX.DirectXPrimitiveTopology
|
||||||
|
*
|
||||||
|
* Introduced to Windows.Foundation.UniversalApiContract in version 8.0
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
#if WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x80000
|
||||||
|
/* [contract] */
|
||||||
|
typedef /* [v1_enum] */
|
||||||
|
enum C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXPrimitiveTopology)
|
||||||
|
{
|
||||||
|
DirectXPrimitiveTopology_Undefined = 0,
|
||||||
|
DirectXPrimitiveTopology_PointList = 1,
|
||||||
|
DirectXPrimitiveTopology_LineList = 2,
|
||||||
|
DirectXPrimitiveTopology_LineStrip = 3,
|
||||||
|
DirectXPrimitiveTopology_TriangleList = 4,
|
||||||
|
DirectXPrimitiveTopology_TriangleStrip = 5,
|
||||||
|
} C_ABI_PARAMETER(Windows_CGraphics_CDirectX_CDirectXPrimitiveTopology);
|
||||||
|
#endif // WINDOWS_FOUNDATION_UNIVERSALAPICONTRACT_VERSION >= 0x80000
|
||||||
|
|
||||||
|
|
||||||
|
#endif // defined(__cplusplus)
|
||||||
|
#pragma pop_macro("MIDL_CONST_ID")
|
||||||
|
#pragma pop_macro("C_IID")
|
||||||
|
#pragma pop_macro("ABI_CONCAT")
|
||||||
|
#pragma pop_macro("ABI_PARAMETER")
|
||||||
|
#pragma pop_macro("ABI_NAMESPACE_BEGIN")
|
||||||
|
#pragma pop_macro("ABI_NAMESPACE_END")
|
||||||
|
|
||||||
|
|
||||||
|
#endif // __winrtdirectxcommon_p_h__
|
||||||
|
|
||||||
|
#endif // __winrtdirectxcommon_h__
|
||||||
299
Sources/CWinAppSDK/nuget/include/xamlom.winui.h
Normal file
299
Sources/CWinAppSDK/nuget/include/xamlom.winui.h
Normal file
@ -0,0 +1,299 @@
|
|||||||
|
|
||||||
|
|
||||||
|
/* this ALWAYS GENERATED file contains the definitions for the interfaces */
|
||||||
|
|
||||||
|
|
||||||
|
/* File created by MIDL compiler version 8.01.0628 */
|
||||||
|
/* @@MIDL_FILE_HEADING( ) */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/* verify that the <rpcndr.h> version is high enough to compile this file*/
|
||||||
|
#ifndef __REQUIRED_RPCNDR_H_VERSION__
|
||||||
|
#define __REQUIRED_RPCNDR_H_VERSION__ 500
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* verify that the <rpcsal.h> version is high enough to compile this file*/
|
||||||
|
#ifndef __REQUIRED_RPCSAL_H_VERSION__
|
||||||
|
#define __REQUIRED_RPCSAL_H_VERSION__ 100
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include "rpc.h"
|
||||||
|
#include "rpcndr.h"
|
||||||
|
|
||||||
|
#ifndef __RPCNDR_H_VERSION__
|
||||||
|
#error this stub requires an updated version of <rpcndr.h>
|
||||||
|
#endif /* __RPCNDR_H_VERSION__ */
|
||||||
|
|
||||||
|
#ifndef COM_NO_WINDOWS_H
|
||||||
|
#include "windows.h"
|
||||||
|
#include "ole2.h"
|
||||||
|
#endif /*COM_NO_WINDOWS_H*/
|
||||||
|
|
||||||
|
#ifndef __xamlom2Ewinui_h__
|
||||||
|
#define __xamlom2Ewinui_h__
|
||||||
|
|
||||||
|
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
|
||||||
|
#pragma once
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef DECLSPEC_XFGVIRT
|
||||||
|
#if defined(_CONTROL_FLOW_GUARD_XFG)
|
||||||
|
#define DECLSPEC_XFGVIRT(base, func) __declspec(xfg_virtual(base, func))
|
||||||
|
#else
|
||||||
|
#define DECLSPEC_XFGVIRT(base, func)
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* Forward Declarations */
|
||||||
|
|
||||||
|
#ifndef __IVisualTreeServiceCallback3_FWD_DEFINED__
|
||||||
|
#define __IVisualTreeServiceCallback3_FWD_DEFINED__
|
||||||
|
typedef interface IVisualTreeServiceCallback3 IVisualTreeServiceCallback3;
|
||||||
|
|
||||||
|
#endif /* __IVisualTreeServiceCallback3_FWD_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef __IXamlDiagnostics2_FWD_DEFINED__
|
||||||
|
#define __IXamlDiagnostics2_FWD_DEFINED__
|
||||||
|
typedef interface IXamlDiagnostics2 IXamlDiagnostics2;
|
||||||
|
|
||||||
|
#endif /* __IXamlDiagnostics2_FWD_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
/* header files for imported files */
|
||||||
|
#include "XamlOM.h"
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C"{
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
/* interface __MIDL_itf_XamlOM2EWinUI_0000_0000 */
|
||||||
|
/* [local] */
|
||||||
|
|
||||||
|
#pragma region Application Family
|
||||||
|
#if WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP)
|
||||||
|
#pragma warning(push)
|
||||||
|
#pragma warning(disable:4668)
|
||||||
|
#pragma warning(disable:4001)
|
||||||
|
#pragma once
|
||||||
|
#pragma warning(pop)
|
||||||
|
// Win32 API definitions
|
||||||
|
#define E_NOTFOUND HRESULT_FROM_WIN32(ERROR_NOT_FOUND)
|
||||||
|
#define E_UNKNOWNTYPE MAKE_HRESULT(SEVERITY_ERROR, FACILITY_XAML, 40L)
|
||||||
|
|
||||||
|
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_XamlOM2EWinUI_0000_0000_v0_0_c_ifspec;
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_XamlOM2EWinUI_0000_0000_v0_0_s_ifspec;
|
||||||
|
|
||||||
|
#ifndef __IVisualTreeServiceCallback3_INTERFACE_DEFINED__
|
||||||
|
#define __IVisualTreeServiceCallback3_INTERFACE_DEFINED__
|
||||||
|
|
||||||
|
/* interface IVisualTreeServiceCallback3 */
|
||||||
|
/* [unique][uuid][object] */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID IID_IVisualTreeServiceCallback3;
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
|
||||||
|
MIDL_INTERFACE("765DF10A-08C8-46B0-82C9-297CFC4CEAD7")
|
||||||
|
IVisualTreeServiceCallback3 : public IUnknown
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE OnXamlRootChange(
|
||||||
|
/* [in] */ InstanceHandle root,
|
||||||
|
/* [in] */ VisualMutationType mutationType) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#else /* C style interface */
|
||||||
|
|
||||||
|
typedef struct IVisualTreeServiceCallback3Vtbl
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
|
||||||
|
__RPC__in IVisualTreeServiceCallback3 * This,
|
||||||
|
/* [in] */ __RPC__in REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, AddRef)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
__RPC__in IVisualTreeServiceCallback3 * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, Release)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
__RPC__in IVisualTreeServiceCallback3 * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IVisualTreeServiceCallback3, OnXamlRootChange)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *OnXamlRootChange )(
|
||||||
|
__RPC__in IVisualTreeServiceCallback3 * This,
|
||||||
|
/* [in] */ InstanceHandle root,
|
||||||
|
/* [in] */ VisualMutationType mutationType);
|
||||||
|
|
||||||
|
END_INTERFACE
|
||||||
|
} IVisualTreeServiceCallback3Vtbl;
|
||||||
|
|
||||||
|
interface IVisualTreeServiceCallback3
|
||||||
|
{
|
||||||
|
CONST_VTBL struct IVisualTreeServiceCallback3Vtbl *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
|
||||||
|
|
||||||
|
#define IVisualTreeServiceCallback3_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define IVisualTreeServiceCallback3_AddRef(This) \
|
||||||
|
( (This)->lpVtbl -> AddRef(This) )
|
||||||
|
|
||||||
|
#define IVisualTreeServiceCallback3_Release(This) \
|
||||||
|
( (This)->lpVtbl -> Release(This) )
|
||||||
|
|
||||||
|
|
||||||
|
#define IVisualTreeServiceCallback3_OnXamlRootChange(This,root,mutationType) \
|
||||||
|
( (This)->lpVtbl -> OnXamlRootChange(This,root,mutationType) )
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* C style interface */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* __IVisualTreeServiceCallback3_INTERFACE_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef __IXamlDiagnostics2_INTERFACE_DEFINED__
|
||||||
|
#define __IXamlDiagnostics2_INTERFACE_DEFINED__
|
||||||
|
|
||||||
|
/* interface IXamlDiagnostics2 */
|
||||||
|
/* [unique][uuid][object] */
|
||||||
|
|
||||||
|
|
||||||
|
EXTERN_C const IID IID_IXamlDiagnostics2;
|
||||||
|
|
||||||
|
#if defined(__cplusplus) && !defined(CINTERFACE)
|
||||||
|
|
||||||
|
MIDL_INTERFACE("523A35EE-EB38-4AE6-A3E1-5B7D0D547BD0")
|
||||||
|
IXamlDiagnostics2 : public IUnknown
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE GetUiLayerForXamlRoot(
|
||||||
|
/* [in] */ InstanceHandle instanceHandle,
|
||||||
|
/* [retval][out] */ __RPC__deref_out_opt IInspectable **ppLayer) = 0;
|
||||||
|
|
||||||
|
virtual HRESULT STDMETHODCALLTYPE HitTestForXamlRoot(
|
||||||
|
/* [in] */ InstanceHandle instanceHandle,
|
||||||
|
/* [in] */ RECT rect,
|
||||||
|
/* [out] */ __RPC__out unsigned int *pCount,
|
||||||
|
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*pCount) InstanceHandle **ppInstanceHandles) = 0;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#else /* C style interface */
|
||||||
|
|
||||||
|
typedef struct IXamlDiagnostics2Vtbl
|
||||||
|
{
|
||||||
|
BEGIN_INTERFACE
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, QueryInterface)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
|
||||||
|
__RPC__in IXamlDiagnostics2 * This,
|
||||||
|
/* [in] */ __RPC__in REFIID riid,
|
||||||
|
/* [annotation][iid_is][out] */
|
||||||
|
_COM_Outptr_ void **ppvObject);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, AddRef)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *AddRef )(
|
||||||
|
__RPC__in IXamlDiagnostics2 * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IUnknown, Release)
|
||||||
|
ULONG ( STDMETHODCALLTYPE *Release )(
|
||||||
|
__RPC__in IXamlDiagnostics2 * This);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IXamlDiagnostics2, GetUiLayerForXamlRoot)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *GetUiLayerForXamlRoot )(
|
||||||
|
__RPC__in IXamlDiagnostics2 * This,
|
||||||
|
/* [in] */ InstanceHandle instanceHandle,
|
||||||
|
/* [retval][out] */ __RPC__deref_out_opt IInspectable **ppLayer);
|
||||||
|
|
||||||
|
DECLSPEC_XFGVIRT(IXamlDiagnostics2, HitTestForXamlRoot)
|
||||||
|
HRESULT ( STDMETHODCALLTYPE *HitTestForXamlRoot )(
|
||||||
|
__RPC__in IXamlDiagnostics2 * This,
|
||||||
|
/* [in] */ InstanceHandle instanceHandle,
|
||||||
|
/* [in] */ RECT rect,
|
||||||
|
/* [out] */ __RPC__out unsigned int *pCount,
|
||||||
|
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*pCount) InstanceHandle **ppInstanceHandles);
|
||||||
|
|
||||||
|
END_INTERFACE
|
||||||
|
} IXamlDiagnostics2Vtbl;
|
||||||
|
|
||||||
|
interface IXamlDiagnostics2
|
||||||
|
{
|
||||||
|
CONST_VTBL struct IXamlDiagnostics2Vtbl *lpVtbl;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef COBJMACROS
|
||||||
|
|
||||||
|
|
||||||
|
#define IXamlDiagnostics2_QueryInterface(This,riid,ppvObject) \
|
||||||
|
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
|
||||||
|
|
||||||
|
#define IXamlDiagnostics2_AddRef(This) \
|
||||||
|
( (This)->lpVtbl -> AddRef(This) )
|
||||||
|
|
||||||
|
#define IXamlDiagnostics2_Release(This) \
|
||||||
|
( (This)->lpVtbl -> Release(This) )
|
||||||
|
|
||||||
|
|
||||||
|
#define IXamlDiagnostics2_GetUiLayerForXamlRoot(This,instanceHandle,ppLayer) \
|
||||||
|
( (This)->lpVtbl -> GetUiLayerForXamlRoot(This,instanceHandle,ppLayer) )
|
||||||
|
|
||||||
|
#define IXamlDiagnostics2_HitTestForXamlRoot(This,instanceHandle,rect,pCount,ppInstanceHandles) \
|
||||||
|
( (This)->lpVtbl -> HitTestForXamlRoot(This,instanceHandle,rect,pCount,ppInstanceHandles) )
|
||||||
|
|
||||||
|
#endif /* COBJMACROS */
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* C style interface */
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif /* __IXamlDiagnostics2_INTERFACE_DEFINED__ */
|
||||||
|
|
||||||
|
|
||||||
|
/* interface __MIDL_itf_XamlOM2EWinUI_0000_0002 */
|
||||||
|
/* [local] */
|
||||||
|
|
||||||
|
#endif /* WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP) */
|
||||||
|
#pragma endregion
|
||||||
|
|
||||||
|
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_XamlOM2EWinUI_0000_0002_v0_0_c_ifspec;
|
||||||
|
extern RPC_IF_HANDLE __MIDL_itf_XamlOM2EWinUI_0000_0002_v0_0_s_ifspec;
|
||||||
|
|
||||||
|
/* Additional Prototypes for ALL interfaces */
|
||||||
|
|
||||||
|
/* end of Additional Prototypes */
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
BIN
Sources/CWinAppSDK/nuget/lib/DWriteCore.lib
Normal file
BIN
Sources/CWinAppSDK/nuget/lib/DWriteCore.lib
Normal file
Binary file not shown.
BIN
Sources/CWinAppSDK/nuget/lib/MRM.lib
Normal file
BIN
Sources/CWinAppSDK/nuget/lib/MRM.lib
Normal file
Binary file not shown.
Binary file not shown.
BIN
Sources/CWinAppSDK/nuget/lib/Microsoft.WindowsAppRuntime.lib
Normal file
BIN
Sources/CWinAppSDK/nuget/lib/Microsoft.WindowsAppRuntime.lib
Normal file
Binary file not shown.
@ -0,0 +1,8 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
public enum __ABI_Microsoft_Graphics_DirectX {
|
||||||
|
}
|
||||||
@ -0,0 +1,8 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
public enum __IMPL_Microsoft_Graphics_DirectX {
|
||||||
|
}
|
||||||
396
Sources/WinAppSDK/Generated/Microsoft.Graphics.DirectX.swift
Normal file
396
Sources/WinAppSDK/Generated/Microsoft.Graphics.DirectX.swift
Normal file
@ -0,0 +1,396 @@
|
|||||||
|
// 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/windows/windows-app-sdk/api/winrt/microsoft.graphics.directx.directxalphamode)
|
||||||
|
public typealias DirectXAlphaMode = __x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXAlphaMode
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.graphics.directx.directxpixelformat)
|
||||||
|
public typealias DirectXPixelFormat = __x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat
|
||||||
|
extension WinAppSDK.DirectXAlphaMode {
|
||||||
|
public static var unspecified : WinAppSDK.DirectXAlphaMode {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXAlphaMode_Unspecified
|
||||||
|
}
|
||||||
|
public static var premultiplied : WinAppSDK.DirectXAlphaMode {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXAlphaMode_Premultiplied
|
||||||
|
}
|
||||||
|
public static var straight : WinAppSDK.DirectXAlphaMode {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXAlphaMode_Straight
|
||||||
|
}
|
||||||
|
public static var ignore : WinAppSDK.DirectXAlphaMode {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXAlphaMode_Ignore
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension WinAppSDK.DirectXAlphaMode: @retroactive Hashable, @retroactive Codable {}
|
||||||
|
|
||||||
|
extension WinAppSDK.DirectXPixelFormat {
|
||||||
|
public static var unknown : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_Unknown
|
||||||
|
}
|
||||||
|
public static var r32g32b32a32Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32B32A32Typeless
|
||||||
|
}
|
||||||
|
public static var r32g32b32a32Float : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32B32A32Float
|
||||||
|
}
|
||||||
|
public static var r32g32b32a32uInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32B32A32UInt
|
||||||
|
}
|
||||||
|
public static var r32g32b32a32Int : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32B32A32Int
|
||||||
|
}
|
||||||
|
public static var r32g32b32Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32B32Typeless
|
||||||
|
}
|
||||||
|
public static var r32g32b32Float : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32B32Float
|
||||||
|
}
|
||||||
|
public static var r32g32b32uInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32B32UInt
|
||||||
|
}
|
||||||
|
public static var r32g32b32Int : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32B32Int
|
||||||
|
}
|
||||||
|
public static var r16g16b16a16Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16B16A16Typeless
|
||||||
|
}
|
||||||
|
public static var r16g16b16a16Float : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16B16A16Float
|
||||||
|
}
|
||||||
|
public static var r16g16b16a16uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16B16A16UIntNormalized
|
||||||
|
}
|
||||||
|
public static var r16g16b16a16uInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16B16A16UInt
|
||||||
|
}
|
||||||
|
public static var r16g16b16a16IntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16B16A16IntNormalized
|
||||||
|
}
|
||||||
|
public static var r16g16b16a16Int : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16B16A16Int
|
||||||
|
}
|
||||||
|
public static var r32g32Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32Typeless
|
||||||
|
}
|
||||||
|
public static var r32g32Float : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32Float
|
||||||
|
}
|
||||||
|
public static var r32g32uInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32UInt
|
||||||
|
}
|
||||||
|
public static var r32g32Int : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G32Int
|
||||||
|
}
|
||||||
|
public static var r32g8x24Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32G8X24Typeless
|
||||||
|
}
|
||||||
|
public static var d32FloatS8X24UInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_D32FloatS8X24UInt
|
||||||
|
}
|
||||||
|
public static var r32FloatX8X24Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32FloatX8X24Typeless
|
||||||
|
}
|
||||||
|
public static var x32TypelessG8X24UInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_X32TypelessG8X24UInt
|
||||||
|
}
|
||||||
|
public static var r10g10b10a2Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R10G10B10A2Typeless
|
||||||
|
}
|
||||||
|
public static var r10g10b10a2uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R10G10B10A2UIntNormalized
|
||||||
|
}
|
||||||
|
public static var r10g10b10a2uInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R10G10B10A2UInt
|
||||||
|
}
|
||||||
|
public static var r11g11b10Float : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R11G11B10Float
|
||||||
|
}
|
||||||
|
public static var r8g8b8a8Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8B8A8Typeless
|
||||||
|
}
|
||||||
|
public static var r8g8b8a8uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8B8A8UIntNormalized
|
||||||
|
}
|
||||||
|
public static var r8g8b8a8uIntNormalizedSrgb : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8B8A8UIntNormalizedSrgb
|
||||||
|
}
|
||||||
|
public static var r8g8b8a8uInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8B8A8UInt
|
||||||
|
}
|
||||||
|
public static var r8g8b8a8IntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8B8A8IntNormalized
|
||||||
|
}
|
||||||
|
public static var r8g8b8a8Int : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8B8A8Int
|
||||||
|
}
|
||||||
|
public static var r16g16Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16Typeless
|
||||||
|
}
|
||||||
|
public static var r16g16Float : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16Float
|
||||||
|
}
|
||||||
|
public static var r16g16uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16UIntNormalized
|
||||||
|
}
|
||||||
|
public static var r16g16uInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16UInt
|
||||||
|
}
|
||||||
|
public static var r16g16IntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16IntNormalized
|
||||||
|
}
|
||||||
|
public static var r16g16Int : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16G16Int
|
||||||
|
}
|
||||||
|
public static var r32Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32Typeless
|
||||||
|
}
|
||||||
|
public static var d32Float : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_D32Float
|
||||||
|
}
|
||||||
|
public static var r32Float : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32Float
|
||||||
|
}
|
||||||
|
public static var r32uInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32UInt
|
||||||
|
}
|
||||||
|
public static var r32Int : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R32Int
|
||||||
|
}
|
||||||
|
public static var r24g8Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R24G8Typeless
|
||||||
|
}
|
||||||
|
public static var d24uIntNormalizedS8UInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_D24UIntNormalizedS8UInt
|
||||||
|
}
|
||||||
|
public static var r24uIntNormalizedX8Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R24UIntNormalizedX8Typeless
|
||||||
|
}
|
||||||
|
public static var x24TypelessG8UInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_X24TypelessG8UInt
|
||||||
|
}
|
||||||
|
public static var r8g8Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8Typeless
|
||||||
|
}
|
||||||
|
public static var r8g8uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8UIntNormalized
|
||||||
|
}
|
||||||
|
public static var r8g8uInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8UInt
|
||||||
|
}
|
||||||
|
public static var r8g8IntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8IntNormalized
|
||||||
|
}
|
||||||
|
public static var r8g8Int : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8Int
|
||||||
|
}
|
||||||
|
public static var r16Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16Typeless
|
||||||
|
}
|
||||||
|
public static var r16Float : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16Float
|
||||||
|
}
|
||||||
|
public static var d16uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_D16UIntNormalized
|
||||||
|
}
|
||||||
|
public static var r16uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16UIntNormalized
|
||||||
|
}
|
||||||
|
public static var r16uInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16UInt
|
||||||
|
}
|
||||||
|
public static var r16IntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16IntNormalized
|
||||||
|
}
|
||||||
|
public static var r16Int : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R16Int
|
||||||
|
}
|
||||||
|
public static var r8Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8Typeless
|
||||||
|
}
|
||||||
|
public static var r8uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8UIntNormalized
|
||||||
|
}
|
||||||
|
public static var r8uInt : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8UInt
|
||||||
|
}
|
||||||
|
public static var r8IntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8IntNormalized
|
||||||
|
}
|
||||||
|
public static var r8Int : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8Int
|
||||||
|
}
|
||||||
|
public static var a8uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_A8UIntNormalized
|
||||||
|
}
|
||||||
|
public static var r1uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R1UIntNormalized
|
||||||
|
}
|
||||||
|
public static var r9g9b9e5SharedExponent : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R9G9B9E5SharedExponent
|
||||||
|
}
|
||||||
|
public static var r8g8b8g8uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R8G8B8G8UIntNormalized
|
||||||
|
}
|
||||||
|
public static var g8r8g8b8uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_G8R8G8B8UIntNormalized
|
||||||
|
}
|
||||||
|
public static var bc1Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC1Typeless
|
||||||
|
}
|
||||||
|
public static var bc1uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC1UIntNormalized
|
||||||
|
}
|
||||||
|
public static var bc1uIntNormalizedSrgb : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC1UIntNormalizedSrgb
|
||||||
|
}
|
||||||
|
public static var bc2Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC2Typeless
|
||||||
|
}
|
||||||
|
public static var bc2uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC2UIntNormalized
|
||||||
|
}
|
||||||
|
public static var bc2uIntNormalizedSrgb : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC2UIntNormalizedSrgb
|
||||||
|
}
|
||||||
|
public static var bc3Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC3Typeless
|
||||||
|
}
|
||||||
|
public static var bc3uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC3UIntNormalized
|
||||||
|
}
|
||||||
|
public static var bc3uIntNormalizedSrgb : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC3UIntNormalizedSrgb
|
||||||
|
}
|
||||||
|
public static var bc4Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC4Typeless
|
||||||
|
}
|
||||||
|
public static var bc4uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC4UIntNormalized
|
||||||
|
}
|
||||||
|
public static var bc4IntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC4IntNormalized
|
||||||
|
}
|
||||||
|
public static var bc5Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC5Typeless
|
||||||
|
}
|
||||||
|
public static var bc5uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC5UIntNormalized
|
||||||
|
}
|
||||||
|
public static var bc5IntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC5IntNormalized
|
||||||
|
}
|
||||||
|
public static var b5g6r5uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_B5G6R5UIntNormalized
|
||||||
|
}
|
||||||
|
public static var b5g5r5a1uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_B5G5R5A1UIntNormalized
|
||||||
|
}
|
||||||
|
public static var b8g8r8a8uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_B8G8R8A8UIntNormalized
|
||||||
|
}
|
||||||
|
public static var b8g8r8x8uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_B8G8R8X8UIntNormalized
|
||||||
|
}
|
||||||
|
public static var r10g10b10xrBiasA2UIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_R10G10B10XRBiasA2UIntNormalized
|
||||||
|
}
|
||||||
|
public static var b8g8r8a8Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_B8G8R8A8Typeless
|
||||||
|
}
|
||||||
|
public static var b8g8r8a8uIntNormalizedSrgb : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_B8G8R8A8UIntNormalizedSrgb
|
||||||
|
}
|
||||||
|
public static var b8g8r8x8Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_B8G8R8X8Typeless
|
||||||
|
}
|
||||||
|
public static var b8g8r8x8uIntNormalizedSrgb : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_B8G8R8X8UIntNormalizedSrgb
|
||||||
|
}
|
||||||
|
public static var bc6hTypeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC6HTypeless
|
||||||
|
}
|
||||||
|
public static var bc6h16UnsignedFloat : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC6H16UnsignedFloat
|
||||||
|
}
|
||||||
|
public static var bc6h16Float : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC6H16Float
|
||||||
|
}
|
||||||
|
public static var bc7Typeless : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC7Typeless
|
||||||
|
}
|
||||||
|
public static var bc7uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC7UIntNormalized
|
||||||
|
}
|
||||||
|
public static var bc7uIntNormalizedSrgb : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_BC7UIntNormalizedSrgb
|
||||||
|
}
|
||||||
|
public static var ayuv : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_Ayuv
|
||||||
|
}
|
||||||
|
public static var y410 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_Y410
|
||||||
|
}
|
||||||
|
public static var y416 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_Y416
|
||||||
|
}
|
||||||
|
public static var nv12 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_NV12
|
||||||
|
}
|
||||||
|
public static var p010 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_P010
|
||||||
|
}
|
||||||
|
public static var p016 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_P016
|
||||||
|
}
|
||||||
|
public static var opaque420 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_Opaque420
|
||||||
|
}
|
||||||
|
public static var yuy2 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_Yuy2
|
||||||
|
}
|
||||||
|
public static var y210 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_Y210
|
||||||
|
}
|
||||||
|
public static var y216 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_Y216
|
||||||
|
}
|
||||||
|
public static var nv11 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_NV11
|
||||||
|
}
|
||||||
|
public static var ai44 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_AI44
|
||||||
|
}
|
||||||
|
public static var ia44 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_IA44
|
||||||
|
}
|
||||||
|
public static var p8 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_P8
|
||||||
|
}
|
||||||
|
public static var a8p8 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_A8P8
|
||||||
|
}
|
||||||
|
public static var b4g4r4a4uIntNormalized : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_B4G4R4A4UIntNormalized
|
||||||
|
}
|
||||||
|
public static var p208 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_P208
|
||||||
|
}
|
||||||
|
public static var v208 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_V208
|
||||||
|
}
|
||||||
|
public static var v408 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_V408
|
||||||
|
}
|
||||||
|
public static var samplerFeedbackMinMipOpaque : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_SamplerFeedbackMinMipOpaque
|
||||||
|
}
|
||||||
|
public static var samplerFeedbackMipRegionUsedOpaque : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_SamplerFeedbackMipRegionUsedOpaque
|
||||||
|
}
|
||||||
|
public static var a4b4g4r4 : WinAppSDK.DirectXPixelFormat {
|
||||||
|
__x_ABI_CMicrosoft_CGraphics_CDirectX_CDirectXPixelFormat_A4B4G4R4
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension WinAppSDK.DirectXPixelFormat: @retroactive Hashable, @retroactive Codable {}
|
||||||
|
|
||||||
176
Sources/WinAppSDK/Generated/Microsoft.UI+ABI.swift
Normal file
176
Sources/WinAppSDK/Generated/Microsoft.UI+ABI.swift
Normal file
@ -0,0 +1,176 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CIClosableNotifier: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x2989E93B, Data2: 0xED0F, Data3: 0x5E79, Data4: ( 0x90,0xF2,0xEA,0xC5,0x92,0xFC,0x6E,0x6A ))// 2989E93B-ED0F-5E79-90F2-EAC592FC6E6A
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CIClosableNotifierHandler: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x478CEC68, Data2: 0xEA8E, Data3: 0x52FC, Data4: ( 0x87,0xE2,0xC8,0x19,0xDE,0x00,0x0F,0x92 ))// 478CEC68-EA8E-52FC-87E2-C819DE000F92
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum __ABI_Microsoft_UI {
|
||||||
|
public class IClosableNotifier: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CIClosableNotifier }
|
||||||
|
|
||||||
|
open func get_IsClosedImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CIClosableNotifier.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsClosed(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
open func add_ClosedImpl(_ handler: WinAppSDK.ClosableNotifierHandler?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = __ABI_Microsoft_UI.ClosableNotifierHandlerWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CIClosableNotifier.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_Closed(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
open func remove_ClosedImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CIClosableNotifier.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_Closed(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
open func add_FrameworkClosedImpl(_ handler: WinAppSDK.ClosableNotifierHandler?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = __ABI_Microsoft_UI.ClosableNotifierHandlerWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CIClosableNotifier.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_FrameworkClosed(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
open func remove_FrameworkClosedImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CIClosableNotifier.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_FrameworkClosed(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
internal static var IClosableNotifierVTable: __x_ABI_CMicrosoft_CUI_CIClosableNotifierVtbl = .init(
|
||||||
|
QueryInterface: { IClosableNotifierWrapper.queryInterface($0, $1, $2) },
|
||||||
|
AddRef: { IClosableNotifierWrapper.addRef($0) },
|
||||||
|
Release: { IClosableNotifierWrapper.release($0) },
|
||||||
|
GetIids: {
|
||||||
|
let size = MemoryLayout<WindowsFoundation.IID>.size
|
||||||
|
let iids = CoTaskMemAlloc(UInt64(size) * 3).assumingMemoryBound(to: WindowsFoundation.IID.self)
|
||||||
|
iids[0] = IUnknown.IID
|
||||||
|
iids[1] = IInspectable.IID
|
||||||
|
iids[2] = __ABI_Microsoft_UI.IClosableNotifierWrapper.IID
|
||||||
|
$1!.pointee = 3
|
||||||
|
$2!.pointee = iids
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetRuntimeClassName: {
|
||||||
|
_ = $0
|
||||||
|
let hstring = try! HString("Microsoft.UI.IClosableNotifier").detach()
|
||||||
|
$1!.pointee = hstring
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetTrustLevel: {
|
||||||
|
_ = $0
|
||||||
|
$1!.pointee = TrustLevel(rawValue: 0)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
get_IsClosed: {
|
||||||
|
guard let __unwrapped__instance = IClosableNotifierWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let value = __unwrapped__instance.isClosed
|
||||||
|
$1?.initialize(to: .init(from: value))
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
add_Closed: {
|
||||||
|
guard let __unwrapped__instance = IClosableNotifierWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
guard let handler = __ABI_Microsoft_UI.ClosableNotifierHandlerWrapper.unwrapFrom(abi: ComPtr($1)) else { return E_INVALIDARG }
|
||||||
|
let token = __unwrapped__instance.closed.addHandler(handler)
|
||||||
|
$2?.initialize(to: .from(swift: token))
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
remove_Closed: {
|
||||||
|
guard let __unwrapped__instance = IClosableNotifierWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let token: EventRegistrationToken = $1
|
||||||
|
__unwrapped__instance.closed.removeHandler(token)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
add_FrameworkClosed: {
|
||||||
|
guard let __unwrapped__instance = IClosableNotifierWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
guard let handler = __ABI_Microsoft_UI.ClosableNotifierHandlerWrapper.unwrapFrom(abi: ComPtr($1)) else { return E_INVALIDARG }
|
||||||
|
let token = __unwrapped__instance.frameworkClosed.addHandler(handler)
|
||||||
|
$2?.initialize(to: .from(swift: token))
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
remove_FrameworkClosed: {
|
||||||
|
guard let __unwrapped__instance = IClosableNotifierWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let token: EventRegistrationToken = $1
|
||||||
|
__unwrapped__instance.frameworkClosed.removeHandler(token)
|
||||||
|
return S_OK
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
public typealias IClosableNotifierWrapper = InterfaceWrapperBase<__IMPL_Microsoft_UI.IClosableNotifierBridge>
|
||||||
|
}
|
||||||
|
extension __x_ABI_CMicrosoft_CUI_CDisplayId {
|
||||||
|
public static func from(swift: WinAppSDK.DisplayId) -> __x_ABI_CMicrosoft_CUI_CDisplayId {
|
||||||
|
.init(Value: swift.value)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension __x_ABI_CMicrosoft_CUI_CIconId {
|
||||||
|
public static func from(swift: WinAppSDK.IconId) -> __x_ABI_CMicrosoft_CUI_CIconId {
|
||||||
|
.init(Value: swift.value)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension __x_ABI_CMicrosoft_CUI_CWindowId {
|
||||||
|
public static func from(swift: WinAppSDK.WindowId) -> __x_ABI_CMicrosoft_CUI_CWindowId {
|
||||||
|
.init(Value: swift.value)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// MARK - ClosableNotifierHandler
|
||||||
|
extension __ABI_Microsoft_UI {
|
||||||
|
public class ClosableNotifierHandler: WindowsFoundation.IUnknown {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CIClosableNotifierHandler }
|
||||||
|
|
||||||
|
open func InvokeImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CIClosableNotifierHandler.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Invoke(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
typealias ClosableNotifierHandlerWrapper = InterfaceWrapperBase<__IMPL_Microsoft_UI.ClosableNotifierHandlerBridge>
|
||||||
|
internal static var ClosableNotifierHandlerVTable: __x_ABI_CMicrosoft_CUI_CIClosableNotifierHandlerVtbl = .init(
|
||||||
|
QueryInterface: { ClosableNotifierHandlerWrapper.queryInterface($0, $1, $2) },
|
||||||
|
AddRef: { ClosableNotifierHandlerWrapper.addRef($0) },
|
||||||
|
Release: { ClosableNotifierHandlerWrapper.release($0) },
|
||||||
|
Invoke: {
|
||||||
|
guard let __unwrapped__instance = ClosableNotifierHandlerWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
__unwrapped__instance()
|
||||||
|
return S_OK
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}
|
||||||
|
public extension WinRTDelegateBridge where CABI == __x_ABI_CMicrosoft_CUI_CIClosableNotifierHandler {
|
||||||
|
static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI.ClosableNotifierHandlerVTable) { $0 }
|
||||||
|
return .init(lpVtbl:vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
78
Sources/WinAppSDK/Generated/Microsoft.UI+Impl.swift
Normal file
78
Sources/WinAppSDK/Generated/Microsoft.UI+Impl.swift
Normal file
@ -0,0 +1,78 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
public enum __IMPL_Microsoft_UI {
|
||||||
|
public enum IClosableNotifierBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CIClosableNotifier
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI.IClosableNotifier
|
||||||
|
public typealias SwiftProjection = AnyIClosableNotifier
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return IClosableNotifierImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI.IClosableNotifierVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class IClosableNotifierImpl: IClosableNotifier, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = IClosableNotifierBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.iclosablenotifier.isclosed)
|
||||||
|
fileprivate var isClosed : Bool {
|
||||||
|
get { try! _default.get_IsClosedImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.iclosablenotifier.closed)
|
||||||
|
fileprivate lazy var closed : Event<ClosableNotifierHandler> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._default else { return .init() }
|
||||||
|
return try! this.add_ClosedImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._default.remove_ClosedImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.iclosablenotifier.frameworkclosed)
|
||||||
|
fileprivate lazy var frameworkClosed : Event<ClosableNotifierHandler> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._default else { return .init() }
|
||||||
|
return try! this.add_FrameworkClosedImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._default.remove_FrameworkClosedImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class ClosableNotifierHandlerBridge : WinRTDelegateBridge {
|
||||||
|
public typealias Handler = ClosableNotifierHandler
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CIClosableNotifierHandler
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI.ClosableNotifierHandler
|
||||||
|
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> Handler? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
let _default = SwiftABI(abi)
|
||||||
|
let handler: Handler = { () in
|
||||||
|
try! _default.InvokeImpl()
|
||||||
|
}
|
||||||
|
return handler
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
7121
Sources/WinAppSDK/Generated/Microsoft.UI.Composition+ABI.swift
Normal file
7121
Sources/WinAppSDK/Generated/Microsoft.UI.Composition+ABI.swift
Normal file
File diff suppressed because it is too large
Load Diff
205
Sources/WinAppSDK/Generated/Microsoft.UI.Composition+Impl.swift
Normal file
205
Sources/WinAppSDK/Generated/Microsoft.UI.Composition+Impl.swift
Normal file
@ -0,0 +1,205 @@
|
|||||||
|
// 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 {
|
||||||
|
public enum IAnimationObjectBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CIAnimationObject
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Composition.IAnimationObject
|
||||||
|
public typealias SwiftProjection = AnyIAnimationObject
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return IAnimationObjectImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Composition.IAnimationObjectVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class IAnimationObjectImpl: IAnimationObject, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = IAnimationObjectBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.ianimationobject.populatepropertyinfo)
|
||||||
|
fileprivate func populatePropertyInfo(_ propertyName: String, _ propertyInfo: AnimationPropertyInfo!) throws {
|
||||||
|
try _default.PopulatePropertyInfoImpl(propertyName, propertyInfo)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum ICompositionAnimationBaseBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CICompositionAnimationBase
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Composition.ICompositionAnimationBase
|
||||||
|
public typealias SwiftProjection = AnyICompositionAnimationBase
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return ICompositionAnimationBaseImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Composition.ICompositionAnimationBaseVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class ICompositionAnimationBaseImpl: ICompositionAnimationBase, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = ICompositionAnimationBaseBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum ICompositionSupportsSystemBackdropBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CICompositionSupportsSystemBackdrop
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Composition.ICompositionSupportsSystemBackdrop
|
||||||
|
public typealias SwiftProjection = AnyICompositionSupportsSystemBackdrop
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return ICompositionSupportsSystemBackdropImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Composition.ICompositionSupportsSystemBackdropVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class ICompositionSupportsSystemBackdropImpl: ICompositionSupportsSystemBackdrop, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = ICompositionSupportsSystemBackdropBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.icompositionsupportssystembackdrop.systembackdrop)
|
||||||
|
fileprivate var systemBackdrop : UWP.CompositionBrush! {
|
||||||
|
get { try! _default.get_SystemBackdropImpl() }
|
||||||
|
set { try! _default.put_SystemBackdropImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum ICompositionSurfaceBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CICompositionSurface
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Composition.ICompositionSurface
|
||||||
|
public typealias SwiftProjection = AnyICompositionSurface
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return ICompositionSurfaceImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Composition.ICompositionSurfaceVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class ICompositionSurfaceImpl: ICompositionSurface, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = ICompositionSurfaceBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum ICompositionSurfaceFacadeBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CICompositionSurfaceFacade
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Composition.ICompositionSurfaceFacade
|
||||||
|
public typealias SwiftProjection = AnyICompositionSurfaceFacade
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return ICompositionSurfaceFacadeImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Composition.ICompositionSurfaceFacadeVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class ICompositionSurfaceFacadeImpl: ICompositionSurfaceFacade, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = ICompositionSurfaceFacadeBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.icompositionsurfacefacade.getrealsurface)
|
||||||
|
fileprivate func getRealSurface() throws -> AnyICompositionSurface! {
|
||||||
|
try _default.GetRealSurfaceImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum IVisualElementBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CIVisualElement
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Composition.IVisualElement
|
||||||
|
public typealias SwiftProjection = AnyIVisualElement
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return IVisualElementImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Composition.IVisualElementVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class IVisualElementImpl: IVisualElement, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = IVisualElementBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum IVisualElement2Bridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CIVisualElement2
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Composition.IVisualElement2
|
||||||
|
public typealias SwiftProjection = AnyIVisualElement2
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return IVisualElement2Impl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Composition.IVisualElement2VTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class IVisualElement2Impl: IVisualElement2, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = IVisualElement2Bridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.ivisualelement2.getvisualinternal)
|
||||||
|
fileprivate func getVisualInternal() throws -> Visual! {
|
||||||
|
try _default.GetVisualInternalImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,88 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
public enum __IMPL_Microsoft_UI_Composition_Interactions {
|
||||||
|
public enum ICompositionInteractionSourceBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CInteractions_CICompositionInteractionSource
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Composition_Interactions.ICompositionInteractionSource
|
||||||
|
public typealias SwiftProjection = AnyICompositionInteractionSource
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return ICompositionInteractionSourceImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Composition_Interactions.ICompositionInteractionSourceVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class ICompositionInteractionSourceImpl: ICompositionInteractionSource, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = ICompositionInteractionSourceBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum IInteractionTrackerOwnerBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CInteractions_CIInteractionTrackerOwner
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Composition_Interactions.IInteractionTrackerOwner
|
||||||
|
public typealias SwiftProjection = AnyIInteractionTrackerOwner
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return IInteractionTrackerOwnerImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Composition_Interactions.IInteractionTrackerOwnerVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class IInteractionTrackerOwnerImpl: IInteractionTrackerOwner, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = IInteractionTrackerOwnerBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.interactions.iinteractiontrackerowner.customanimationstateentered)
|
||||||
|
fileprivate func customAnimationStateEntered(_ sender: InteractionTracker!, _ args: InteractionTrackerCustomAnimationStateEnteredArgs!) throws {
|
||||||
|
try _default.CustomAnimationStateEnteredImpl(sender, args)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.interactions.iinteractiontrackerowner.idlestateentered)
|
||||||
|
fileprivate func idleStateEntered(_ sender: InteractionTracker!, _ args: InteractionTrackerIdleStateEnteredArgs!) throws {
|
||||||
|
try _default.IdleStateEnteredImpl(sender, args)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.interactions.iinteractiontrackerowner.inertiastateentered)
|
||||||
|
fileprivate func inertiaStateEntered(_ sender: InteractionTracker!, _ args: InteractionTrackerInertiaStateEnteredArgs!) throws {
|
||||||
|
try _default.InertiaStateEnteredImpl(sender, args)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.interactions.iinteractiontrackerowner.interactingstateentered)
|
||||||
|
fileprivate func interactingStateEntered(_ sender: InteractionTracker!, _ args: InteractionTrackerInteractingStateEnteredArgs!) throws {
|
||||||
|
try _default.InteractingStateEnteredImpl(sender, args)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.interactions.iinteractiontrackerowner.requestignored)
|
||||||
|
fileprivate func requestIgnored(_ sender: InteractionTracker!, _ args: InteractionTrackerRequestIgnoredArgs!) throws {
|
||||||
|
try _default.RequestIgnoredImpl(sender, args)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.interactions.iinteractiontrackerowner.valueschanged)
|
||||||
|
fileprivate func valuesChanged(_ sender: InteractionTracker!, _ args: InteractionTrackerValuesChangedArgs!) throws {
|
||||||
|
try _default.ValuesChangedImpl(sender, args)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,542 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x7C20A6AF, Data2: 0x8EB3, Data3: 0x5F08, Data4: ( 0xBD,0xFC,0x6D,0x35,0xE3,0x5D,0xFE,0x45 ))// 7C20A6AF-8EB3-5F08-BDFC-6D35E35DFE45
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController2: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x88E0A368, Data2: 0xDFC7, Data3: 0x5971, Data4: ( 0xA5,0x0B,0x40,0xDF,0x5A,0xA5,0xF5,0xC2 ))// 88E0A368-DFC7-5971-A50B-40DF5AA5F5C2
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController3: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x30D917E6, Data2: 0x02D3, Data3: 0x59CA, Data4: ( 0xB4,0x40,0xBF,0x9D,0x2E,0x7C,0xC1,0x40 ))// 30D917E6-02D3-59CA-B440-BF9D2E7CC140
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicControllerStatics: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xA9E8F790, Data2: 0x79EF, Data3: 0x5416, Data4: ( 0x9B,0x67,0x6B,0xCF,0xE8,0x67,0xC8,0xB7 ))// A9E8F790-79EF-5416-9B67-6BCFE867C8B7
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x2DE996A9, Data2: 0x0A2A, Data3: 0x5889, Data4: ( 0xA8,0x9C,0x1F,0x84,0x06,0x0A,0x8C,0xAB ))// 2DE996A9-0A2A-5889-A89C-1F84060A8CAB
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController2: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xF1ED4A52, Data2: 0xD9CA, Data3: 0x506E, Data4: ( 0x95,0x86,0xCA,0xAE,0xFD,0x3A,0xA9,0x71 ))// F1ED4A52-D9CA-506E-9586-CAAEFD3AA971
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaControllerStatics: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x7D85D834, Data2: 0xD514, Data3: 0x5250, Data4: ( 0xB7,0xC4,0x0B,0x78,0x50,0xD1,0xEF,0xDC ))// 7D85D834-D514-5250-B7C4-0B7850D1EFDC
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xEBCCE1B9, Data2: 0x0E0C, Data3: 0x5431, Data4: ( 0xAB,0x0E,0x00,0xF3,0xF0,0x66,0x99,0x62 ))// EBCCE1B9-0E0C-5431-AB0E-00F3F0669962
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropController: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x5632D76C, Data2: 0x0B74, Data3: 0x5B52, Data4: ( 0xAA,0x33,0x80,0x26,0x20,0x68,0xAE,0xB2 ))// 5632D76C-0B74-5B52-AA33-80262068AEB2
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerWithTargets: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x9C56FE7C, Data2: 0x98EB, Data3: 0x5F89, Data4: ( 0xAD,0x97,0xDA,0xD5,0x7F,0xC3,0x0C,0x8C ))// 9C56FE7C-98EB-5F89-AD97-DAD57FC30C8C
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum __ABI_Microsoft_UI_Composition_SystemBackdrops {
|
||||||
|
public class IDesktopAcrylicController: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController }
|
||||||
|
|
||||||
|
internal func get_FallbackColorImpl() throws -> UWP.Color {
|
||||||
|
var value: __x_ABI_CWindows_CUI_CColor = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_FallbackColor(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_FallbackColorImpl(_ value: UWP.Color) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_FallbackColor(pThis, .from(swift: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_LuminosityOpacityImpl() throws -> Float {
|
||||||
|
var value: FLOAT = 0.0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_LuminosityOpacity(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_LuminosityOpacityImpl(_ value: Float) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_LuminosityOpacity(pThis, value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_TintColorImpl() throws -> UWP.Color {
|
||||||
|
var value: __x_ABI_CWindows_CUI_CColor = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_TintColor(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_TintColorImpl(_ value: UWP.Color) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_TintColor(pThis, .from(swift: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_TintOpacityImpl() throws -> Float {
|
||||||
|
var value: FLOAT = 0.0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_TintOpacity(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_TintOpacityImpl(_ value: Float) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_TintOpacity(pThis, value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDesktopAcrylicController2: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController2 }
|
||||||
|
|
||||||
|
internal func ResetPropertiesImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController2.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.ResetProperties(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDesktopAcrylicController3: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController3 }
|
||||||
|
|
||||||
|
internal func get_KindImpl() throws -> WinAppSDK.DesktopAcrylicKind {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CDesktopAcrylicKind = .init(0)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController3.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Kind(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_KindImpl(_ value: WinAppSDK.DesktopAcrylicKind) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController3.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_Kind(pThis, value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDesktopAcrylicControllerStatics: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicControllerStatics }
|
||||||
|
|
||||||
|
internal func IsSupportedImpl() throws -> Bool {
|
||||||
|
var result: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicControllerStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.IsSupported(pThis, &result))
|
||||||
|
}
|
||||||
|
return .init(from: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IMicaController: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController }
|
||||||
|
|
||||||
|
internal func get_FallbackColorImpl() throws -> UWP.Color {
|
||||||
|
var value: __x_ABI_CWindows_CUI_CColor = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_FallbackColor(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_FallbackColorImpl(_ value: UWP.Color) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_FallbackColor(pThis, .from(swift: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_LuminosityOpacityImpl() throws -> Float {
|
||||||
|
var value: FLOAT = 0.0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_LuminosityOpacity(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_LuminosityOpacityImpl(_ value: Float) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_LuminosityOpacity(pThis, value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_TintColorImpl() throws -> UWP.Color {
|
||||||
|
var value: __x_ABI_CWindows_CUI_CColor = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_TintColor(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_TintColorImpl(_ value: UWP.Color) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_TintColor(pThis, .from(swift: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_TintOpacityImpl() throws -> Float {
|
||||||
|
var value: FLOAT = 0.0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_TintOpacity(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_TintOpacityImpl(_ value: Float) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_TintOpacity(pThis, value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IMicaController2: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController2 }
|
||||||
|
|
||||||
|
internal func get_KindImpl() throws -> WinAppSDK.MicaKind {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CMicaKind = .init(0)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController2.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Kind(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_KindImpl(_ value: WinAppSDK.MicaKind) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController2.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_Kind(pThis, value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func ResetPropertiesImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController2.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.ResetProperties(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IMicaControllerStatics: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaControllerStatics }
|
||||||
|
|
||||||
|
internal func IsSupportedImpl() throws -> Bool {
|
||||||
|
var result: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaControllerStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.IsSupported(pThis, &result))
|
||||||
|
}
|
||||||
|
return .init(from: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class ISystemBackdropConfiguration: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration }
|
||||||
|
|
||||||
|
internal func get_HighContrastBackgroundColorImpl() throws -> UWP.Color? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_HighContrastBackgroundColor(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return WinAppSDK.__x_ABI_C__FIReference_1___x_ABI_CWindows__CUI__CColorWrapper.unwrapFrom(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_HighContrastBackgroundColorImpl(_ value: UWP.Color?) throws {
|
||||||
|
let valueWrapper = WinAppSDK.__x_ABI_C__FIReference_1___x_ABI_CWindows__CUI__CColorWrapper(value)
|
||||||
|
let _value = try! valueWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_HighContrastBackgroundColor(pThis, _value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsHighContrastImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsHighContrast(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_IsHighContrastImpl(_ value: Bool) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_IsHighContrast(pThis, .init(from: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsInputActiveImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsInputActive(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_IsInputActiveImpl(_ value: Bool) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_IsInputActive(pThis, .init(from: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_ThemeImpl() throws -> WinAppSDK.SystemBackdropTheme {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CSystemBackdropTheme = .init(0)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Theme(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_ThemeImpl(_ value: WinAppSDK.SystemBackdropTheme) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_Theme(pThis, value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class ISystemBackdropController: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropController }
|
||||||
|
|
||||||
|
open func SetTargetWithWindowIdImpl(_ windowId: WinAppSDK.WindowId, _ desktopWindowTarget: UWP.CompositionTarget?) throws -> Bool {
|
||||||
|
var result: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.SetTargetWithWindowId(pThis, .from(swift: windowId), RawPointer(desktopWindowTarget), &result))
|
||||||
|
}
|
||||||
|
return .init(from: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
open func SetTargetWithCoreWindowImpl(_ coreWindow: UWP.CoreWindow?, _ compositionTarget: UWP.CompositionTarget?) throws -> Bool {
|
||||||
|
var result: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.SetTargetWithCoreWindow(pThis, RawPointer(coreWindow), RawPointer(compositionTarget), &result))
|
||||||
|
}
|
||||||
|
return .init(from: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
internal static var ISystemBackdropControllerVTable: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerVtbl = .init(
|
||||||
|
QueryInterface: { ISystemBackdropControllerWrapper.queryInterface($0, $1, $2) },
|
||||||
|
AddRef: { ISystemBackdropControllerWrapper.addRef($0) },
|
||||||
|
Release: { ISystemBackdropControllerWrapper.release($0) },
|
||||||
|
GetIids: {
|
||||||
|
let size = MemoryLayout<WindowsFoundation.IID>.size
|
||||||
|
let iids = CoTaskMemAlloc(UInt64(size) * 4).assumingMemoryBound(to: WindowsFoundation.IID.self)
|
||||||
|
iids[0] = IUnknown.IID
|
||||||
|
iids[1] = IInspectable.IID
|
||||||
|
iids[2] = __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWrapper.IID
|
||||||
|
iids[3] = __ABI_Windows_Foundation.IClosableWrapper.IID
|
||||||
|
$1!.pointee = 4
|
||||||
|
$2!.pointee = iids
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetRuntimeClassName: {
|
||||||
|
_ = $0
|
||||||
|
let hstring = try! HString("Microsoft.UI.Composition.SystemBackdrops.ISystemBackdropController").detach()
|
||||||
|
$1!.pointee = hstring
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetTrustLevel: {
|
||||||
|
_ = $0
|
||||||
|
$1!.pointee = TrustLevel(rawValue: 0)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
SetTargetWithWindowId: {
|
||||||
|
do {
|
||||||
|
guard let __unwrapped__instance = ISystemBackdropControllerWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let windowId: WinAppSDK.WindowId = .from(abi: $1)
|
||||||
|
let desktopWindowTarget: UWP.CompositionTarget? = .from(abi: ComPtr($2))
|
||||||
|
let result = try __unwrapped__instance.setTarget(windowId, desktopWindowTarget)
|
||||||
|
$3?.initialize(to: .init(from: result))
|
||||||
|
return S_OK
|
||||||
|
} catch { return failWith(err: E_FAIL) }
|
||||||
|
},
|
||||||
|
|
||||||
|
SetTargetWithCoreWindow: {
|
||||||
|
do {
|
||||||
|
guard let __unwrapped__instance = ISystemBackdropControllerWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let coreWindow: UWP.CoreWindow? = .from(abi: ComPtr($1))
|
||||||
|
let compositionTarget: UWP.CompositionTarget? = .from(abi: ComPtr($2))
|
||||||
|
let result = try __unwrapped__instance.setTarget(coreWindow, compositionTarget)
|
||||||
|
$3?.initialize(to: .init(from: result))
|
||||||
|
return S_OK
|
||||||
|
} catch { return failWith(err: E_FAIL) }
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
public typealias ISystemBackdropControllerWrapper = InterfaceWrapperBase<__IMPL_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerBridge>
|
||||||
|
public class ISystemBackdropControllerWithTargets: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerWithTargets }
|
||||||
|
|
||||||
|
open func get_StateImpl() throws -> WinAppSDK.SystemBackdropState {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CSystemBackdropState = .init(0)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerWithTargets.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_State(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
open func AddSystemBackdropTargetImpl(_ systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop?) throws -> Bool {
|
||||||
|
var result: boolean = 0
|
||||||
|
let systemBackdropTargetWrapper = __ABI_Microsoft_UI_Composition.ICompositionSupportsSystemBackdropWrapper(systemBackdropTarget)
|
||||||
|
let _systemBackdropTarget = try! systemBackdropTargetWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerWithTargets.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.AddSystemBackdropTarget(pThis, _systemBackdropTarget, &result))
|
||||||
|
}
|
||||||
|
return .init(from: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
open func RemoveAllSystemBackdropTargetsImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerWithTargets.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.RemoveAllSystemBackdropTargets(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
open func RemoveSystemBackdropTargetImpl(_ systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop?) throws -> Bool {
|
||||||
|
var result: boolean = 0
|
||||||
|
let systemBackdropTargetWrapper = __ABI_Microsoft_UI_Composition.ICompositionSupportsSystemBackdropWrapper(systemBackdropTarget)
|
||||||
|
let _systemBackdropTarget = try! systemBackdropTargetWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerWithTargets.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.RemoveSystemBackdropTarget(pThis, _systemBackdropTarget, &result))
|
||||||
|
}
|
||||||
|
return .init(from: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
open func SetSystemBackdropConfigurationImpl(_ configuration: WinAppSDK.SystemBackdropConfiguration?) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerWithTargets.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.SetSystemBackdropConfiguration(pThis, RawPointer(configuration)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
open func add_StateChangedImpl(_ handler: TypedEventHandler<WinAppSDK.AnyISystemBackdropControllerWithTargets?, Any?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CUI__CComposition__CSystemBackdrops__CISystemBackdropControllerWithTargets_IInspectableWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerWithTargets.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_StateChanged(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
open func remove_StateChangedImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerWithTargets.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_StateChanged(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
internal static var ISystemBackdropControllerWithTargetsVTable: __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropControllerWithTargetsVtbl = .init(
|
||||||
|
QueryInterface: { ISystemBackdropControllerWithTargetsWrapper.queryInterface($0, $1, $2) },
|
||||||
|
AddRef: { ISystemBackdropControllerWithTargetsWrapper.addRef($0) },
|
||||||
|
Release: { ISystemBackdropControllerWithTargetsWrapper.release($0) },
|
||||||
|
GetIids: {
|
||||||
|
let size = MemoryLayout<WindowsFoundation.IID>.size
|
||||||
|
let iids = CoTaskMemAlloc(UInt64(size) * 5).assumingMemoryBound(to: WindowsFoundation.IID.self)
|
||||||
|
iids[0] = IUnknown.IID
|
||||||
|
iids[1] = IInspectable.IID
|
||||||
|
iids[2] = __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWithTargetsWrapper.IID
|
||||||
|
iids[3] = __ABI_Windows_Foundation.IClosableWrapper.IID
|
||||||
|
iids[4] = __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWrapper.IID
|
||||||
|
$1!.pointee = 5
|
||||||
|
$2!.pointee = iids
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetRuntimeClassName: {
|
||||||
|
_ = $0
|
||||||
|
let hstring = try! HString("Microsoft.UI.Composition.SystemBackdrops.ISystemBackdropControllerWithTargets").detach()
|
||||||
|
$1!.pointee = hstring
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetTrustLevel: {
|
||||||
|
_ = $0
|
||||||
|
$1!.pointee = TrustLevel(rawValue: 0)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
get_State: {
|
||||||
|
guard let __unwrapped__instance = ISystemBackdropControllerWithTargetsWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let value = __unwrapped__instance.state
|
||||||
|
$1?.initialize(to: value)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
AddSystemBackdropTarget: {
|
||||||
|
do {
|
||||||
|
guard let __unwrapped__instance = ISystemBackdropControllerWithTargetsWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop? = __ABI_Microsoft_UI_Composition.ICompositionSupportsSystemBackdropWrapper.unwrapFrom(abi: ComPtr($1))
|
||||||
|
let result = try __unwrapped__instance.addSystemBackdropTarget(systemBackdropTarget)
|
||||||
|
$2?.initialize(to: .init(from: result))
|
||||||
|
return S_OK
|
||||||
|
} catch { return failWith(err: E_FAIL) }
|
||||||
|
},
|
||||||
|
|
||||||
|
RemoveAllSystemBackdropTargets: {
|
||||||
|
do {
|
||||||
|
guard let __unwrapped__instance = ISystemBackdropControllerWithTargetsWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
try __unwrapped__instance.removeAllSystemBackdropTargets()
|
||||||
|
return S_OK
|
||||||
|
} catch { return failWith(err: E_FAIL) }
|
||||||
|
},
|
||||||
|
|
||||||
|
RemoveSystemBackdropTarget: {
|
||||||
|
do {
|
||||||
|
guard let __unwrapped__instance = ISystemBackdropControllerWithTargetsWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop? = __ABI_Microsoft_UI_Composition.ICompositionSupportsSystemBackdropWrapper.unwrapFrom(abi: ComPtr($1))
|
||||||
|
let result = try __unwrapped__instance.removeSystemBackdropTarget(systemBackdropTarget)
|
||||||
|
$2?.initialize(to: .init(from: result))
|
||||||
|
return S_OK
|
||||||
|
} catch { return failWith(err: E_FAIL) }
|
||||||
|
},
|
||||||
|
|
||||||
|
SetSystemBackdropConfiguration: {
|
||||||
|
do {
|
||||||
|
guard let __unwrapped__instance = ISystemBackdropControllerWithTargetsWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let configuration: WinAppSDK.SystemBackdropConfiguration? = .from(abi: ComPtr($1))
|
||||||
|
try __unwrapped__instance.setSystemBackdropConfiguration(configuration)
|
||||||
|
return S_OK
|
||||||
|
} catch { return failWith(err: E_FAIL) }
|
||||||
|
},
|
||||||
|
|
||||||
|
add_StateChanged: {
|
||||||
|
guard let __unwrapped__instance = ISystemBackdropControllerWithTargetsWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
guard let handler = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CUI__CComposition__CSystemBackdrops__CISystemBackdropControllerWithTargets_IInspectableWrapper.unwrapFrom(abi: ComPtr($1)) else { return E_INVALIDARG }
|
||||||
|
let token = __unwrapped__instance.stateChanged.addHandler(handler)
|
||||||
|
$2?.initialize(to: .from(swift: token))
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
remove_StateChanged: {
|
||||||
|
guard let __unwrapped__instance = ISystemBackdropControllerWithTargetsWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let token: EventRegistrationToken = $1
|
||||||
|
__unwrapped__instance.stateChanged.removeHandler(token)
|
||||||
|
return S_OK
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
public typealias ISystemBackdropControllerWithTargetsWrapper = InterfaceWrapperBase<__IMPL_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWithTargetsBridge>
|
||||||
|
}
|
||||||
@ -0,0 +1,130 @@
|
|||||||
|
// 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<CABI>?) -> 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<Bridge.CABI>) {
|
||||||
|
_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<CABI>?) -> 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<Bridge.CABI>) {
|
||||||
|
_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<TypedEventHandler<ISystemBackdropControllerWithTargets?, 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 _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)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,522 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacrylickind)
|
||||||
|
public typealias DesktopAcrylicKind = __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CDesktopAcrylicKind
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micakind)
|
||||||
|
public typealias MicaKind = __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CMicaKind
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.systembackdropstate)
|
||||||
|
public typealias SystemBackdropState = __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CSystemBackdropState
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.systembackdroptheme)
|
||||||
|
public typealias SystemBackdropTheme = __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CSystemBackdropTheme
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller)
|
||||||
|
public final class DesktopAcrylicController : WinRTClass, WindowsFoundation.IClosable, ISystemBackdropController, ISystemBackdropControllerWithTargets, WinAppSDK.IClosableNotifier {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_UI_Composition_SystemBackdrops.IDesktopAcrylicController
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController
|
||||||
|
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_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIDesktopAcrylicController>?) -> DesktopAcrylicController? {
|
||||||
|
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)
|
||||||
|
}
|
||||||
|
override public init() {
|
||||||
|
super.init(try! RoActivateInstance(HString("Microsoft.UI.Composition.SystemBackdrops.DesktopAcrylicController")))
|
||||||
|
}
|
||||||
|
|
||||||
|
private static let _IDesktopAcrylicControllerStatics: __ABI_Microsoft_UI_Composition_SystemBackdrops.IDesktopAcrylicControllerStatics = try! RoGetActivationFactory(HString("Microsoft.UI.Composition.SystemBackdrops.DesktopAcrylicController"))
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.issupported)
|
||||||
|
public static func isSupported() -> Bool {
|
||||||
|
return try! _IDesktopAcrylicControllerStatics.IsSupportedImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.fallbackcolor)
|
||||||
|
public var fallbackColor : UWP.Color {
|
||||||
|
get { try! _default.get_FallbackColorImpl() }
|
||||||
|
set { try! _default.put_FallbackColorImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.luminosityopacity)
|
||||||
|
public var luminosityOpacity : Float {
|
||||||
|
get { try! _default.get_LuminosityOpacityImpl() }
|
||||||
|
set { try! _default.put_LuminosityOpacityImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.tintcolor)
|
||||||
|
public var tintColor : UWP.Color {
|
||||||
|
get { try! _default.get_TintColorImpl() }
|
||||||
|
set { try! _default.put_TintColorImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.tintopacity)
|
||||||
|
public var tintOpacity : Float {
|
||||||
|
get { try! _default.get_TintOpacityImpl() }
|
||||||
|
set { try! _default.put_TintOpacityImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
private lazy var _IDesktopAcrylicController2: __ABI_Microsoft_UI_Composition_SystemBackdrops.IDesktopAcrylicController2! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.resetproperties)
|
||||||
|
public func resetProperties() throws {
|
||||||
|
try _IDesktopAcrylicController2.ResetPropertiesImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
private lazy var _IDesktopAcrylicController3: __ABI_Microsoft_UI_Composition_SystemBackdrops.IDesktopAcrylicController3! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.kind)
|
||||||
|
public var kind : DesktopAcrylicKind {
|
||||||
|
get { try! _IDesktopAcrylicController3.get_KindImpl() }
|
||||||
|
set { try! _IDesktopAcrylicController3.put_KindImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
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.desktopacryliccontroller.close)
|
||||||
|
public 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.desktopacryliccontroller.settarget)
|
||||||
|
public 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.desktopacryliccontroller.settarget)
|
||||||
|
public func setTarget(_ coreWindow: UWP.CoreWindow!, _ compositionTarget: UWP.CompositionTarget!) throws -> Bool {
|
||||||
|
try _ISystemBackdropController.SetTargetWithCoreWindowImpl(coreWindow, compositionTarget)
|
||||||
|
}
|
||||||
|
|
||||||
|
private lazy var _ISystemBackdropControllerWithTargets: __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWithTargets! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.addsystembackdroptarget)
|
||||||
|
public func addSystemBackdropTarget(_ systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop!) throws -> Bool {
|
||||||
|
try _ISystemBackdropControllerWithTargets.AddSystemBackdropTargetImpl(systemBackdropTarget)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.removeallsystembackdroptargets)
|
||||||
|
public func removeAllSystemBackdropTargets() throws {
|
||||||
|
try _ISystemBackdropControllerWithTargets.RemoveAllSystemBackdropTargetsImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.removesystembackdroptarget)
|
||||||
|
public func removeSystemBackdropTarget(_ systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop!) throws -> Bool {
|
||||||
|
try _ISystemBackdropControllerWithTargets.RemoveSystemBackdropTargetImpl(systemBackdropTarget)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.setsystembackdropconfiguration)
|
||||||
|
public func setSystemBackdropConfiguration(_ configuration: SystemBackdropConfiguration!) throws {
|
||||||
|
try _ISystemBackdropControllerWithTargets.SetSystemBackdropConfigurationImpl(configuration)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.state)
|
||||||
|
public var state : SystemBackdropState {
|
||||||
|
get { try! _ISystemBackdropControllerWithTargets.get_StateImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.statechanged)
|
||||||
|
public lazy var stateChanged : Event<TypedEventHandler<ISystemBackdropControllerWithTargets?, Any?>> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._ISystemBackdropControllerWithTargets else { return .init() }
|
||||||
|
return try! this.add_StateChangedImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._ISystemBackdropControllerWithTargets.remove_StateChangedImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
private lazy var _IClosableNotifier: __ABI_Microsoft_UI.IClosableNotifier! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.isclosed)
|
||||||
|
public var isClosed : Bool {
|
||||||
|
get { try! _IClosableNotifier.get_IsClosedImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.closed)
|
||||||
|
public lazy var closed : Event<WinAppSDK.ClosableNotifierHandler> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._IClosableNotifier else { return .init() }
|
||||||
|
return try! this.add_ClosedImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._IClosableNotifier.remove_ClosedImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.desktopacryliccontroller.frameworkclosed)
|
||||||
|
public lazy var frameworkClosed : Event<WinAppSDK.ClosableNotifierHandler> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._IClosableNotifier else { return .init() }
|
||||||
|
return try! this.add_FrameworkClosedImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._IClosableNotifier.remove_FrameworkClosedImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
_IDesktopAcrylicController2 = nil
|
||||||
|
_IDesktopAcrylicController3 = nil
|
||||||
|
_IClosable = nil
|
||||||
|
_ISystemBackdropController = nil
|
||||||
|
_ISystemBackdropControllerWithTargets = nil
|
||||||
|
_IClosableNotifier = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller)
|
||||||
|
public final class MicaController : WinRTClass, WindowsFoundation.IClosable, ISystemBackdropController, ISystemBackdropControllerWithTargets, WinAppSDK.IClosableNotifier {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_UI_Composition_SystemBackdrops.IMicaController
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController
|
||||||
|
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_CMicrosoft_CUI_CComposition_CSystemBackdrops_CIMicaController>?) -> MicaController? {
|
||||||
|
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)
|
||||||
|
}
|
||||||
|
override public init() {
|
||||||
|
super.init(try! RoActivateInstance(HString("Microsoft.UI.Composition.SystemBackdrops.MicaController")))
|
||||||
|
}
|
||||||
|
|
||||||
|
private static let _IMicaControllerStatics: __ABI_Microsoft_UI_Composition_SystemBackdrops.IMicaControllerStatics = try! RoGetActivationFactory(HString("Microsoft.UI.Composition.SystemBackdrops.MicaController"))
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.issupported)
|
||||||
|
public static func isSupported() -> Bool {
|
||||||
|
return try! _IMicaControllerStatics.IsSupportedImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.fallbackcolor)
|
||||||
|
public var fallbackColor : UWP.Color {
|
||||||
|
get { try! _default.get_FallbackColorImpl() }
|
||||||
|
set { try! _default.put_FallbackColorImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.luminosityopacity)
|
||||||
|
public var luminosityOpacity : Float {
|
||||||
|
get { try! _default.get_LuminosityOpacityImpl() }
|
||||||
|
set { try! _default.put_LuminosityOpacityImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.tintcolor)
|
||||||
|
public var tintColor : UWP.Color {
|
||||||
|
get { try! _default.get_TintColorImpl() }
|
||||||
|
set { try! _default.put_TintColorImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.tintopacity)
|
||||||
|
public var tintOpacity : Float {
|
||||||
|
get { try! _default.get_TintOpacityImpl() }
|
||||||
|
set { try! _default.put_TintOpacityImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
private lazy var _IMicaController2: __ABI_Microsoft_UI_Composition_SystemBackdrops.IMicaController2! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.resetproperties)
|
||||||
|
public func resetProperties() throws {
|
||||||
|
try _IMicaController2.ResetPropertiesImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.kind)
|
||||||
|
public var kind : MicaKind {
|
||||||
|
get { try! _IMicaController2.get_KindImpl() }
|
||||||
|
set { try! _IMicaController2.put_KindImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
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.micacontroller.close)
|
||||||
|
public 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.micacontroller.settarget)
|
||||||
|
public 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.micacontroller.settarget)
|
||||||
|
public func setTarget(_ coreWindow: UWP.CoreWindow!, _ compositionTarget: UWP.CompositionTarget!) throws -> Bool {
|
||||||
|
try _ISystemBackdropController.SetTargetWithCoreWindowImpl(coreWindow, compositionTarget)
|
||||||
|
}
|
||||||
|
|
||||||
|
private lazy var _ISystemBackdropControllerWithTargets: __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWithTargets! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.addsystembackdroptarget)
|
||||||
|
public func addSystemBackdropTarget(_ systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop!) throws -> Bool {
|
||||||
|
try _ISystemBackdropControllerWithTargets.AddSystemBackdropTargetImpl(systemBackdropTarget)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.removeallsystembackdroptargets)
|
||||||
|
public func removeAllSystemBackdropTargets() throws {
|
||||||
|
try _ISystemBackdropControllerWithTargets.RemoveAllSystemBackdropTargetsImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.removesystembackdroptarget)
|
||||||
|
public func removeSystemBackdropTarget(_ systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop!) throws -> Bool {
|
||||||
|
try _ISystemBackdropControllerWithTargets.RemoveSystemBackdropTargetImpl(systemBackdropTarget)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.setsystembackdropconfiguration)
|
||||||
|
public func setSystemBackdropConfiguration(_ configuration: SystemBackdropConfiguration!) throws {
|
||||||
|
try _ISystemBackdropControllerWithTargets.SetSystemBackdropConfigurationImpl(configuration)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.state)
|
||||||
|
public var state : SystemBackdropState {
|
||||||
|
get { try! _ISystemBackdropControllerWithTargets.get_StateImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.statechanged)
|
||||||
|
public lazy var stateChanged : Event<TypedEventHandler<ISystemBackdropControllerWithTargets?, Any?>> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._ISystemBackdropControllerWithTargets else { return .init() }
|
||||||
|
return try! this.add_StateChangedImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._ISystemBackdropControllerWithTargets.remove_StateChangedImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
private lazy var _IClosableNotifier: __ABI_Microsoft_UI.IClosableNotifier! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.isclosed)
|
||||||
|
public var isClosed : Bool {
|
||||||
|
get { try! _IClosableNotifier.get_IsClosedImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.closed)
|
||||||
|
public lazy var closed : Event<WinAppSDK.ClosableNotifierHandler> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._IClosableNotifier else { return .init() }
|
||||||
|
return try! this.add_ClosedImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._IClosableNotifier.remove_ClosedImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.micacontroller.frameworkclosed)
|
||||||
|
public lazy var frameworkClosed : Event<WinAppSDK.ClosableNotifierHandler> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._IClosableNotifier else { return .init() }
|
||||||
|
return try! this.add_FrameworkClosedImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._IClosableNotifier.remove_FrameworkClosedImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
_IMicaController2 = nil
|
||||||
|
_IClosable = nil
|
||||||
|
_ISystemBackdropController = nil
|
||||||
|
_ISystemBackdropControllerWithTargets = nil
|
||||||
|
_IClosableNotifier = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.systembackdropconfiguration)
|
||||||
|
public final class SystemBackdropConfiguration : WinRTClass {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropConfiguration
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration
|
||||||
|
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_CMicrosoft_CUI_CComposition_CSystemBackdrops_CISystemBackdropConfiguration>?) -> SystemBackdropConfiguration? {
|
||||||
|
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("Microsoft.UI.Composition.SystemBackdrops.SystemBackdropConfiguration")))
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.systembackdropconfiguration.highcontrastbackgroundcolor)
|
||||||
|
public var highContrastBackgroundColor : UWP.Color? {
|
||||||
|
get { try! _default.get_HighContrastBackgroundColorImpl() }
|
||||||
|
set { try! _default.put_HighContrastBackgroundColorImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.systembackdropconfiguration.ishighcontrast)
|
||||||
|
public var isHighContrast : Bool {
|
||||||
|
get { try! _default.get_IsHighContrastImpl() }
|
||||||
|
set { try! _default.put_IsHighContrastImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.systembackdropconfiguration.isinputactive)
|
||||||
|
public var isInputActive : Bool {
|
||||||
|
get { try! _default.get_IsInputActiveImpl() }
|
||||||
|
set { try! _default.put_IsInputActiveImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.systembackdropconfiguration.theme)
|
||||||
|
public var theme : SystemBackdropTheme {
|
||||||
|
get { try! _default.get_ThemeImpl() }
|
||||||
|
set { try! _default.put_ThemeImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontroller)
|
||||||
|
public protocol ISystemBackdropController : WindowsFoundation.IClosable {
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontroller.settarget)
|
||||||
|
func setTarget(_ windowId: WinAppSDK.WindowId, _ desktopWindowTarget: UWP.CompositionTarget!) throws -> Bool
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontroller.settarget)
|
||||||
|
func setTarget(_ coreWindow: UWP.CoreWindow!, _ compositionTarget: UWP.CompositionTarget!) throws -> Bool
|
||||||
|
}
|
||||||
|
|
||||||
|
extension ISystemBackdropController {
|
||||||
|
public func queryInterface(_ iid: WindowsFoundation.IID) -> IUnknownRef? {
|
||||||
|
switch iid {
|
||||||
|
case __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWrapper.IID:
|
||||||
|
let wrapper = __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWrapper(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 AnyISystemBackdropController = any ISystemBackdropController
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets)
|
||||||
|
public protocol ISystemBackdropControllerWithTargets : WindowsFoundation.IClosable, ISystemBackdropController {
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.addsystembackdroptarget)
|
||||||
|
func addSystemBackdropTarget(_ systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop!) throws -> Bool
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.removeallsystembackdroptargets)
|
||||||
|
func removeAllSystemBackdropTargets() throws
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.removesystembackdroptarget)
|
||||||
|
func removeSystemBackdropTarget(_ systemBackdropTarget: WinAppSDK.AnyICompositionSupportsSystemBackdrop!) throws -> Bool
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.setsystembackdropconfiguration)
|
||||||
|
func setSystemBackdropConfiguration(_ configuration: WinAppSDK.SystemBackdropConfiguration!) throws
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.state)
|
||||||
|
var state: WinAppSDK.SystemBackdropState { get }
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.composition.systembackdrops.isystembackdropcontrollerwithtargets.statechanged)
|
||||||
|
var stateChanged: Event<TypedEventHandler<ISystemBackdropControllerWithTargets?, Any?>> { get }
|
||||||
|
}
|
||||||
|
|
||||||
|
extension ISystemBackdropControllerWithTargets {
|
||||||
|
public func queryInterface(_ iid: WindowsFoundation.IID) -> IUnknownRef? {
|
||||||
|
switch iid {
|
||||||
|
case __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWithTargetsWrapper.IID:
|
||||||
|
let wrapper = __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWithTargetsWrapper(self)
|
||||||
|
return wrapper!.queryInterface(iid)
|
||||||
|
case __ABI_Windows_Foundation.IClosableWrapper.IID:
|
||||||
|
let wrapper = __ABI_Windows_Foundation.IClosableWrapper(self)
|
||||||
|
return wrapper!.queryInterface(iid)
|
||||||
|
case __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWrapper.IID:
|
||||||
|
let wrapper = __ABI_Microsoft_UI_Composition_SystemBackdrops.ISystemBackdropControllerWrapper(self)
|
||||||
|
return wrapper!.queryInterface(iid)
|
||||||
|
default: return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public typealias AnyISystemBackdropControllerWithTargets = any ISystemBackdropControllerWithTargets
|
||||||
|
|
||||||
|
extension WinAppSDK.DesktopAcrylicKind {
|
||||||
|
public static var `default` : WinAppSDK.DesktopAcrylicKind {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CDesktopAcrylicKind_Default
|
||||||
|
}
|
||||||
|
public static var base : WinAppSDK.DesktopAcrylicKind {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CDesktopAcrylicKind_Base
|
||||||
|
}
|
||||||
|
public static var thin : WinAppSDK.DesktopAcrylicKind {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CDesktopAcrylicKind_Thin
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension WinAppSDK.DesktopAcrylicKind: @retroactive Hashable, @retroactive Codable {}
|
||||||
|
|
||||||
|
extension WinAppSDK.MicaKind {
|
||||||
|
public static var base : WinAppSDK.MicaKind {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CMicaKind_Base
|
||||||
|
}
|
||||||
|
public static var baseAlt : WinAppSDK.MicaKind {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CMicaKind_BaseAlt
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension WinAppSDK.MicaKind: @retroactive Hashable, @retroactive Codable {}
|
||||||
|
|
||||||
|
extension WinAppSDK.SystemBackdropState {
|
||||||
|
public static var active : WinAppSDK.SystemBackdropState {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CSystemBackdropState_Active
|
||||||
|
}
|
||||||
|
public static var fallback : WinAppSDK.SystemBackdropState {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CSystemBackdropState_Fallback
|
||||||
|
}
|
||||||
|
public static var highContrast : WinAppSDK.SystemBackdropState {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CSystemBackdropState_HighContrast
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension WinAppSDK.SystemBackdropState: @retroactive Hashable, @retroactive Codable {}
|
||||||
|
|
||||||
|
extension WinAppSDK.SystemBackdropTheme {
|
||||||
|
public static var `default` : WinAppSDK.SystemBackdropTheme {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CSystemBackdropTheme_Default
|
||||||
|
}
|
||||||
|
public static var light : WinAppSDK.SystemBackdropTheme {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CSystemBackdropTheme_Light
|
||||||
|
}
|
||||||
|
public static var dark : WinAppSDK.SystemBackdropTheme {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CComposition_CSystemBackdrops_CSystemBackdropTheme_Dark
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension WinAppSDK.SystemBackdropTheme: @retroactive Hashable, @retroactive Codable {}
|
||||||
|
|
||||||
7111
Sources/WinAppSDK/Generated/Microsoft.UI.Composition.swift
Normal file
7111
Sources/WinAppSDK/Generated/Microsoft.UI.Composition.swift
Normal file
File diff suppressed because it is too large
Load Diff
996
Sources/WinAppSDK/Generated/Microsoft.UI.Content+ABI.swift
Normal file
996
Sources/WinAppSDK/Generated/Microsoft.UI.Content+ABI.swift
Normal file
@ -0,0 +1,996 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentCoordinateConverter: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x10A11230, Data2: 0x5EB4, Data3: 0x5840, Data4: ( 0xA3,0x46,0x57,0x0F,0x4A,0x49,0x04,0x0F ))// 10A11230-5EB4-5840-A346-570F4A49040F
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentCoordinateConverterFactory: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xA4B216EE, Data2: 0x0E26, Data3: 0x56BD, Data4: ( 0x92,0x09,0xA7,0x5C,0xF9,0xD8,0x0F,0x27 ))// A4B216EE-0E26-56BD-9209-A75CF9D80F27
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentCoordinateConverterStatics: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xF56374CE, Data2: 0xB6DF, Data3: 0x5B42, Data4: ( 0xA5,0x8F,0x4E,0x3B,0xB0,0x39,0xE3,0xA9 ))// F56374CE-B6DF-5B42-A58F-4E3BB039E3A9
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentDeferral: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x470529F5, Data2: 0xCD93, Data3: 0x599B, Data4: ( 0x96,0x8E,0xF8,0xA6,0x89,0xBC,0x3A,0x07 ))// 470529F5-CD93-599B-968E-F8A689BC3A07
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentEnvironmentSettingChangedEventArgs: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x76478051, Data2: 0xFC80, Data3: 0x5EEC, Data4: ( 0xA3,0xF3,0x62,0x60,0x6A,0xBE,0x06,0xB7 ))// 76478051-FC80-5EEC-A3F3-62606ABE06B7
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentEnvironmentStateChangedEventArgs: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x8970FA4F, Data2: 0x10BA, Data3: 0x5F67, Data4: ( 0x97,0x0B,0x8C,0x72,0xBC,0x00,0x9B,0x67 ))// 8970FA4F-10BA-5F67-970B-8C72BC009B67
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIsland: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x5B2504BA, Data2: 0x361C, Data3: 0x50AA, Data4: ( 0xBD,0x6E,0x41,0x22,0xC6,0xD9,0x38,0x89 ))// 5B2504BA-361C-50AA-BD6E-4122C6D93889
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandAutomationProviderRequestedEventArgs: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x9FE24BED, Data2: 0x2B9C, Data3: 0x5137, Data4: ( 0x88,0x7F,0x40,0x3C,0x94,0x84,0x18,0x24 ))// 9FE24BED-2B9C-5137-887F-403C94841824
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandEnvironment: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xC334236D, Data2: 0xDA88, Data3: 0x566D, Data4: ( 0x81,0x1D,0x74,0xAE,0xF2,0xEB,0xA9,0x78 ))// C334236D-DA88-566D-811D-74AEF2EBA978
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandEnvironmentFactory: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x47A782D6, Data2: 0xB177, Data3: 0x5C1E, Data4: ( 0xBF,0x87,0x90,0x43,0x7D,0xD8,0x09,0xD0 ))// 47A782D6-B177-5C1E-BF87-90437DD809D0
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandFactory: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x82383F52, Data2: 0xE81A, Data3: 0x5EC9, Data4: ( 0xA9,0x54,0xBA,0xC8,0xA9,0x31,0xBA,0x7D ))// 82383F52-E81A-5EC9-A954-BAC8A931BA7D
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStateChangedEventArgs: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xC828EEB2, Data2: 0x0C62, Data3: 0x5B40, Data4: ( 0x9D,0x48,0x77,0xC0,0x60,0x83,0xC2,0x78 ))// C828EEB2-0C62-5B40-9D48-77C06083C278
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStatics: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x7B9EB7CC, Data2: 0x8C43, Data3: 0x5E0A, Data4: ( 0xAB,0x23,0xAB,0x48,0x62,0x8F,0xD2,0x23 ))// 7B9EB7CC-8C43-5E0A-AB23-AB48628FD223
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentSiteBridge: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xFAAAB99E, Data2: 0xA42B, Data3: 0x549C, Data4: ( 0x92,0xDF,0x3B,0x6D,0x6E,0x1E,0x36,0x8B ))// FAAAB99E-A42B-549C-92DF-3B6D6E1E368B
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentSiteEnvironmentView: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x5B6FE420, Data2: 0x0BB3, Data3: 0x54DD, Data4: ( 0x85,0x89,0x78,0x6C,0xF0,0x2E,0x38,0xF1 ))// 5B6FE420-0BB3-54DD-8589-786CF02E38F1
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentSiteEnvironmentViewFactory: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xC901EDF2, Data2: 0xF184, Data3: 0x5A64, Data4: ( 0x8D,0x58,0x8C,0xF8,0xEF,0xA8,0xB6,0x78 ))// C901EDF2-F184-5A64-8D58-8CF8EFA8B678
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x2D5D8DD5, Data2: 0x358E, Data3: 0x5B05, Data4: ( 0x99,0x3B,0xB2,0x66,0x6D,0x17,0x86,0xB3 ))// 2D5D8DD5-358E-5B05-993B-B2666D1786B3
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIContentSiteViewFactory: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x9EFD72F0, Data2: 0x63EF, Data3: 0x5B6A, Data4: ( 0xA5,0x0C,0x56,0x85,0xBD,0x81,0x00,0xF1 ))// 9EFD72F0-63EF-5B6A-A50C-5685BD8100F1
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIDesktopChildSiteBridge: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xB2F2FF7B, Data2: 0x1825, Data3: 0x51B0, Data4: ( 0xB8,0x0B,0x75,0x99,0x88,0x9C,0x56,0x9F ))// B2F2FF7B-1825-51B0-B80B-7599889C569F
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIDesktopChildSiteBridgeStatics: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xAB6B82DE, Data2: 0x6A47, Data3: 0x5DE3, Data4: ( 0xA8,0x60,0x61,0x3C,0x8D,0xB6,0x79,0xAB ))// AB6B82DE-6A47-5DE3-A860-613C8DB679AB
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xF0AE8750, Data2: 0x905C, Data3: 0x50A2, Data4: ( 0x8A,0x12,0x45,0x45,0xC6,0x24,0x5B,0xB4 ))// F0AE8750-905C-50A2-8A12-4545C6245BB4
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridgeFactory: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xD94EE1FF, Data2: 0x3AF1, Data3: 0x54D0, Data4: ( 0x93,0x11,0x65,0x2B,0x29,0xC5,0x7C,0x5B ))// D94EE1FF-3AF1-54D0-9311-652B29C57C5B
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridgeStatics: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xE0B38DAF, Data2: 0x9CD4, Data3: 0x50C5, Data4: ( 0x83,0xEE,0xC7,0x6E,0x3C,0xF3,0x4E,0xBA ))// E0B38DAF-9CD4-50C5-83EE-C76E3CF34EBA
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum __ABI_Microsoft_UI_Content {
|
||||||
|
public class IContentCoordinateConverter: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentCoordinateConverter }
|
||||||
|
|
||||||
|
internal func ConvertLocalToScreenWithPointImpl(_ localPoint: WindowsFoundation.Point) throws -> UWP.PointInt32 {
|
||||||
|
var result: __x_ABI_CWindows_CGraphics_CPointInt32 = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentCoordinateConverter.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.ConvertLocalToScreenWithPoint(pThis, .from(swift: localPoint), &result))
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func ConvertLocalToScreenWithRectImpl(_ localRect: WindowsFoundation.Rect) throws -> UWP.RectInt32 {
|
||||||
|
var result: __x_ABI_CWindows_CGraphics_CRectInt32 = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentCoordinateConverter.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.ConvertLocalToScreenWithRect(pThis, .from(swift: localRect), &result))
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func ConvertScreenToLocalWithPointImpl(_ screenPoint: UWP.PointInt32) throws -> WindowsFoundation.Point {
|
||||||
|
var result: __x_ABI_CWindows_CFoundation_CPoint = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentCoordinateConverter.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.ConvertScreenToLocalWithPoint(pThis, .from(swift: screenPoint), &result))
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func ConvertScreenToLocalWithRectImpl(_ screenRect: UWP.RectInt32) throws -> WindowsFoundation.Rect {
|
||||||
|
var result: __x_ABI_CWindows_CFoundation_CRect = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentCoordinateConverter.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.ConvertScreenToLocalWithRect(pThis, .from(swift: screenRect), &result))
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentCoordinateConverterFactory: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentCoordinateConverterFactory }
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentCoordinateConverterStatics: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentCoordinateConverterStatics }
|
||||||
|
|
||||||
|
internal func CreateForWindowIdImpl(_ windowId: WinAppSDK.WindowId) throws -> WinAppSDK.ContentCoordinateConverter? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentCoordinateConverterStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.CreateForWindowId(pThis, .from(swift: windowId), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentDeferral: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentDeferral }
|
||||||
|
|
||||||
|
internal func CompleteImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentDeferral.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Complete(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentEnvironmentSettingChangedEventArgs: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentEnvironmentSettingChangedEventArgs }
|
||||||
|
|
||||||
|
internal func get_SettingNameImpl() throws -> String {
|
||||||
|
var value: HSTRING?
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentEnvironmentSettingChangedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_SettingName(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentEnvironmentStateChangedEventArgs: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentEnvironmentStateChangedEventArgs }
|
||||||
|
|
||||||
|
internal func get_DidAppWindowIdChangeImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentEnvironmentStateChangedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DidAppWindowIdChange(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_DidDisplayIdChangeImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentEnvironmentStateChangedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DidDisplayIdChange(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentIsland: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIsland }
|
||||||
|
|
||||||
|
internal func get_ActualSizeImpl() throws -> WindowsFoundation.Vector2 {
|
||||||
|
var value: __x_ABI_CWindows_CFoundation_CNumerics_CVector2 = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_ActualSize(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_AppDataImpl() throws -> Any? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_AppData(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return __ABI_.AnyWrapper.unwrapFrom(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_AppDataImpl(_ value: Any?) throws {
|
||||||
|
let valueWrapper = __ABI_.AnyWrapper(value)
|
||||||
|
let _value = try! valueWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_AppData(pThis, _value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_CoordinateConverterImpl() throws -> WinAppSDK.ContentCoordinateConverter? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_CoordinateConverter(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_CustomPropertiesImpl() throws -> WindowsFoundation.AnyIPropertySet? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_CustomProperties(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return __ABI_Windows_Foundation_Collections.IPropertySetWrapper.unwrapFrom(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_DispatcherQueueImpl() throws -> WinAppSDK.DispatcherQueue? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DispatcherQueue(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_EnvironmentImpl() throws -> WinAppSDK.ContentIslandEnvironment? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Environment(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IdImpl() throws -> UInt64 {
|
||||||
|
var value: UINT64 = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Id(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsConnectedImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsConnected(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsHitTestVisibleWhenTransparentImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsHitTestVisibleWhenTransparent(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_IsHitTestVisibleWhenTransparentImpl(_ value: Bool) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_IsHitTestVisibleWhenTransparent(pThis, .init(from: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsIslandEnabledImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsIslandEnabled(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_IsIslandEnabledImpl(_ value: Bool) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_IsIslandEnabled(pThis, .init(from: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsIslandVisibleImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsIslandVisible(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_IsIslandVisibleImpl(_ value: Bool) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_IsIslandVisible(pThis, .init(from: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsSiteEnabledImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsSiteEnabled(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsSiteVisibleImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsSiteVisible(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_LayoutDirectionImpl() throws -> WinAppSDK.ContentLayoutDirection {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CContent_CContentLayoutDirection = .init(0)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_LayoutDirection(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_RasterizationScaleImpl() throws -> Float {
|
||||||
|
var value: FLOAT = 0.0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_RasterizationScale(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func GetAutomationHostProviderImpl() throws -> Any? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetAutomationHostProvider(pThis, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return __ABI_.AnyWrapper.unwrapFrom(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func GetStateChangeDeferralImpl() throws -> WinAppSDK.ContentDeferral? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetStateChangeDeferral(pThis, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func RequestSizeImpl(_ size: WindowsFoundation.Vector2) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.RequestSize(pThis, .from(swift: size)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func add_AutomationProviderRequestedImpl(_ handler: TypedEventHandler<WinAppSDK.ContentIsland?, WinAppSDK.ContentIslandAutomationProviderRequestedEventArgs?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CUI__CContent__CContentIsland___x_ABI_CMicrosoft__CUI__CContent__CContentIslandAutomationProviderRequestedEventArgsWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_AutomationProviderRequested(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func remove_AutomationProviderRequestedImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_AutomationProviderRequested(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func add_StateChangedImpl(_ handler: TypedEventHandler<WinAppSDK.ContentIsland?, WinAppSDK.ContentIslandStateChangedEventArgs?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CUI__CContent__CContentIsland___x_ABI_CMicrosoft__CUI__CContent__CContentIslandStateChangedEventArgsWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_StateChanged(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func remove_StateChangedImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIsland.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_StateChanged(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentIslandAutomationProviderRequestedEventArgs: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandAutomationProviderRequestedEventArgs }
|
||||||
|
|
||||||
|
internal func get_AutomationProviderImpl() throws -> Any? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandAutomationProviderRequestedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_AutomationProvider(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return __ABI_.AnyWrapper.unwrapFrom(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_AutomationProviderImpl(_ value: Any?) throws {
|
||||||
|
let valueWrapper = __ABI_.AnyWrapper(value)
|
||||||
|
let _value = try! valueWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandAutomationProviderRequestedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_AutomationProvider(pThis, _value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_HandledImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandAutomationProviderRequestedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Handled(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_HandledImpl(_ value: Bool) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandAutomationProviderRequestedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_Handled(pThis, .init(from: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentIslandEnvironment: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandEnvironment }
|
||||||
|
|
||||||
|
internal func get_AppWindowIdImpl() throws -> WinAppSDK.WindowId {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CWindowId = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandEnvironment.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_AppWindowId(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_DisplayIdImpl() throws -> WinAppSDK.DisplayId {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CDisplayId = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandEnvironment.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DisplayId(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func add_SettingChangedImpl(_ handler: TypedEventHandler<WinAppSDK.ContentIslandEnvironment?, WinAppSDK.ContentEnvironmentSettingChangedEventArgs?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CUI__CContent__CContentIslandEnvironment___x_ABI_CMicrosoft__CUI__CContent__CContentEnvironmentSettingChangedEventArgsWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandEnvironment.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_SettingChanged(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func remove_SettingChangedImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandEnvironment.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_SettingChanged(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func add_StateChangedImpl(_ handler: TypedEventHandler<WinAppSDK.ContentIslandEnvironment?, WinAppSDK.ContentEnvironmentStateChangedEventArgs?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CUI__CContent__CContentIslandEnvironment___x_ABI_CMicrosoft__CUI__CContent__CContentEnvironmentStateChangedEventArgsWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandEnvironment.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_StateChanged(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func remove_StateChangedImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandEnvironment.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_StateChanged(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentIslandEnvironmentFactory: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandEnvironmentFactory }
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentIslandFactory: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandFactory }
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentIslandStateChangedEventArgs: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStateChangedEventArgs }
|
||||||
|
|
||||||
|
internal func get_DidActualSizeChangeImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStateChangedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DidActualSizeChange(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_DidSiteEnabledChangeImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStateChangedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DidSiteEnabledChange(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_DidSiteVisibleChangeImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStateChangedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DidSiteVisibleChange(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_DidLayoutDirectionChangeImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStateChangedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DidLayoutDirectionChange(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_DidRasterizationScaleChangeImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStateChangedEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DidRasterizationScaleChange(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentIslandStatics: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStatics }
|
||||||
|
|
||||||
|
internal func CreateImpl(_ Root: WinAppSDK.Visual?) throws -> WinAppSDK.ContentIsland? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Create(pThis, RawPointer(Root), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func GetByVisualImpl(_ child: WinAppSDK.Visual?) throws -> WinAppSDK.ContentIsland? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetByVisual(pThis, RawPointer(child), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func GetFromIdImpl(_ id: UInt64) throws -> WinAppSDK.ContentIsland? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentIslandStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetFromId(pThis, id, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentSiteBridge: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentSiteBridge }
|
||||||
|
|
||||||
|
open func get_DispatcherQueueImpl() throws -> WinAppSDK.DispatcherQueue? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DispatcherQueue(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
open func get_LayoutDirectionOverrideImpl() throws -> WinAppSDK.ContentLayoutDirection? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_LayoutDirectionOverride(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return WinAppSDK.__x_ABI_C__FIReference_1___x_ABI_CMicrosoft__CUI__CContent__CContentLayoutDirectionWrapper.unwrapFrom(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
open func put_LayoutDirectionOverrideImpl(_ value: WinAppSDK.ContentLayoutDirection?) throws {
|
||||||
|
let valueWrapper = WinAppSDK.__x_ABI_C__FIReference_1___x_ABI_CMicrosoft__CUI__CContent__CContentLayoutDirectionWrapper(value)
|
||||||
|
let _value = try! valueWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_LayoutDirectionOverride(pThis, _value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
open func get_OverrideScaleImpl() throws -> Float {
|
||||||
|
var value: FLOAT = 0.0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_OverrideScale(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
open func put_OverrideScaleImpl(_ value: Float) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_OverrideScale(pThis, value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
internal static var IContentSiteBridgeVTable: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteBridgeVtbl = .init(
|
||||||
|
QueryInterface: { IContentSiteBridgeWrapper.queryInterface($0, $1, $2) },
|
||||||
|
AddRef: { IContentSiteBridgeWrapper.addRef($0) },
|
||||||
|
Release: { IContentSiteBridgeWrapper.release($0) },
|
||||||
|
GetIids: {
|
||||||
|
let size = MemoryLayout<WindowsFoundation.IID>.size
|
||||||
|
let iids = CoTaskMemAlloc(UInt64(size) * 4).assumingMemoryBound(to: WindowsFoundation.IID.self)
|
||||||
|
iids[0] = IUnknown.IID
|
||||||
|
iids[1] = IInspectable.IID
|
||||||
|
iids[2] = __ABI_Microsoft_UI_Content.IContentSiteBridgeWrapper.IID
|
||||||
|
iids[3] = __ABI_Windows_Foundation.IClosableWrapper.IID
|
||||||
|
$1!.pointee = 4
|
||||||
|
$2!.pointee = iids
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetRuntimeClassName: {
|
||||||
|
_ = $0
|
||||||
|
let hstring = try! HString("Microsoft.UI.Content.IContentSiteBridge").detach()
|
||||||
|
$1!.pointee = hstring
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetTrustLevel: {
|
||||||
|
_ = $0
|
||||||
|
$1!.pointee = TrustLevel(rawValue: 0)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
get_DispatcherQueue: {
|
||||||
|
guard let __unwrapped__instance = IContentSiteBridgeWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let value = __unwrapped__instance.dispatcherQueue
|
||||||
|
value?.copyTo($1)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
get_LayoutDirectionOverride: {
|
||||||
|
guard let __unwrapped__instance = IContentSiteBridgeWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let value = __unwrapped__instance.layoutDirectionOverride
|
||||||
|
let valueWrapper = WinAppSDK.__x_ABI_C__FIReference_1___x_ABI_CMicrosoft__CUI__CContent__CContentLayoutDirectionWrapper(value)
|
||||||
|
valueWrapper?.copyTo($1)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
put_LayoutDirectionOverride: {
|
||||||
|
guard let __unwrapped__instance = IContentSiteBridgeWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let value: WinAppSDK.ContentLayoutDirection? = WinAppSDK.__x_ABI_C__FIReference_1___x_ABI_CMicrosoft__CUI__CContent__CContentLayoutDirectionWrapper.unwrapFrom(abi: ComPtr($1))
|
||||||
|
__unwrapped__instance.layoutDirectionOverride = value
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
get_OverrideScale: {
|
||||||
|
guard let __unwrapped__instance = IContentSiteBridgeWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let value = __unwrapped__instance.overrideScale
|
||||||
|
$1?.initialize(to: value)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
put_OverrideScale: {
|
||||||
|
guard let __unwrapped__instance = IContentSiteBridgeWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let value: Float = $1
|
||||||
|
__unwrapped__instance.overrideScale = value
|
||||||
|
return S_OK
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
public typealias IContentSiteBridgeWrapper = InterfaceWrapperBase<__IMPL_Microsoft_UI_Content.IContentSiteBridgeBridge>
|
||||||
|
public class IContentSiteEnvironmentView: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentSiteEnvironmentView }
|
||||||
|
|
||||||
|
internal func get_AppWindowIdImpl() throws -> WinAppSDK.WindowId {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CWindowId = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteEnvironmentView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_AppWindowId(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_DisplayIdImpl() throws -> WinAppSDK.DisplayId {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CDisplayId = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteEnvironmentView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DisplayId(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentSiteEnvironmentViewFactory: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentSiteEnvironmentViewFactory }
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentSiteView: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView }
|
||||||
|
|
||||||
|
internal func get_ActualSizeImpl() throws -> WindowsFoundation.Vector2 {
|
||||||
|
var value: __x_ABI_CWindows_CFoundation_CNumerics_CVector2 = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_ActualSize(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_ClientSizeImpl() throws -> UWP.SizeInt32 {
|
||||||
|
var value: __x_ABI_CWindows_CGraphics_CSizeInt32 = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_ClientSize(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_CoordinateConverterImpl() throws -> WinAppSDK.ContentCoordinateConverter? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_CoordinateConverter(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_DispatcherQueueImpl() throws -> WinAppSDK.DispatcherQueue? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DispatcherQueue(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_EnvironmentViewImpl() throws -> WinAppSDK.ContentSiteEnvironmentView? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_EnvironmentView(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsConnectedImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsConnected(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsSiteEnabledImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsSiteEnabled(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsSiteVisibleImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsSiteVisible(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_LayoutDirectionImpl() throws -> WinAppSDK.ContentLayoutDirection {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CContent_CContentLayoutDirection = .init(0)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_LayoutDirection(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_OverrideScaleImpl() throws -> Float {
|
||||||
|
var value: FLOAT = 0.0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_OverrideScale(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_ParentScaleImpl() throws -> Float {
|
||||||
|
var value: FLOAT = 0.0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_ParentScale(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_RasterizationScaleImpl() throws -> Float {
|
||||||
|
var value: FLOAT = 0.0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_RasterizationScale(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_RequestedSizeImpl() throws -> WindowsFoundation.Vector2 {
|
||||||
|
var value: __x_ABI_CWindows_CFoundation_CNumerics_CVector2 = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_RequestedSize(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_ShouldApplyRasterizationScaleImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteView.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_ShouldApplyRasterizationScale(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IContentSiteViewFactory: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIContentSiteViewFactory }
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDesktopChildSiteBridge: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIDesktopChildSiteBridge }
|
||||||
|
|
||||||
|
internal func get_ResizePolicyImpl() throws -> WinAppSDK.ContentSizePolicy {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CContent_CContentSizePolicy = .init(0)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopChildSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_ResizePolicy(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_ResizePolicyImpl(_ value: WinAppSDK.ContentSizePolicy) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopChildSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_ResizePolicy(pThis, value))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_SiteViewImpl() throws -> WinAppSDK.ContentSiteView? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopChildSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_SiteView(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDesktopChildSiteBridgeStatics: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIDesktopChildSiteBridgeStatics }
|
||||||
|
|
||||||
|
internal func CreateImpl(_ compositor: WinAppSDK.Compositor?, _ parentWindowId: WinAppSDK.WindowId) throws -> WinAppSDK.DesktopChildSiteBridge? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopChildSiteBridgeStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Create(pThis, RawPointer(compositor), .from(swift: parentWindowId), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDesktopSiteBridge: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge }
|
||||||
|
|
||||||
|
internal func get_IsEnabledImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsEnabled(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsVisibleImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsVisible(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_WindowIdImpl() throws -> WinAppSDK.WindowId {
|
||||||
|
var value: __x_ABI_CMicrosoft_CUI_CWindowId = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_WindowId(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func ConnectImpl(_ content: WinAppSDK.ContentIsland?) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Connect(pThis, RawPointer(content)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func DisableImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Disable(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func EnableImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Enable(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func HideImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Hide(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func MoveAndResizeImpl(_ rect: UWP.RectInt32) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.MoveAndResize(pThis, .from(swift: rect)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func MoveInZOrderAtBottomImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.MoveInZOrderAtBottom(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func MoveInZOrderAtTopImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.MoveInZOrderAtTop(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func MoveInZOrderBelowImpl(_ windowId: WinAppSDK.WindowId) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.MoveInZOrderBelow(pThis, .from(swift: windowId)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func ShowImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridge.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Show(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDesktopSiteBridgeFactory: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridgeFactory }
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDesktopSiteBridgeStatics: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridgeStatics }
|
||||||
|
|
||||||
|
internal func IsSupportedImpl() throws -> Bool {
|
||||||
|
var result: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CContent_CIDesktopSiteBridgeStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.IsSupported(pThis, &result))
|
||||||
|
}
|
||||||
|
return .init(from: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
56
Sources/WinAppSDK/Generated/Microsoft.UI.Content+Impl.swift
Normal file
56
Sources/WinAppSDK/Generated/Microsoft.UI.Content+Impl.swift
Normal file
@ -0,0 +1,56 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
public enum __IMPL_Microsoft_UI_Content {
|
||||||
|
public enum IContentSiteBridgeBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CContent_CIContentSiteBridge
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Content.IContentSiteBridge
|
||||||
|
public typealias SwiftProjection = AnyIContentSiteBridge
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return IContentSiteBridgeImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Content.IContentSiteBridgeVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class IContentSiteBridgeImpl: IContentSiteBridge, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = IContentSiteBridgeBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.content.icontentsitebridge.dispatcherqueue)
|
||||||
|
fileprivate var dispatcherQueue : WinAppSDK.DispatcherQueue! {
|
||||||
|
get { try! _default.get_DispatcherQueueImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.content.icontentsitebridge.layoutdirectionoverride)
|
||||||
|
fileprivate var layoutDirectionOverride : ContentLayoutDirection? {
|
||||||
|
get { try! _default.get_LayoutDirectionOverrideImpl() }
|
||||||
|
set { try! _default.put_LayoutDirectionOverrideImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.content.icontentsitebridge.overridescale)
|
||||||
|
fileprivate var overrideScale : Float {
|
||||||
|
get { try! _default.get_OverrideScaleImpl() }
|
||||||
|
set { try! _default.put_OverrideScaleImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
private lazy var _IClosable: __ABI_Windows_Foundation.IClosable! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.content.icontentsitebridge.close)
|
||||||
|
fileprivate func close() throws {
|
||||||
|
try _IClosable.CloseImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
1094
Sources/WinAppSDK/Generated/Microsoft.UI.Content.swift
Normal file
1094
Sources/WinAppSDK/Generated/Microsoft.UI.Content.swift
Normal file
File diff suppressed because it is too large
Load Diff
390
Sources/WinAppSDK/Generated/Microsoft.UI.Dispatching+ABI.swift
Normal file
390
Sources/WinAppSDK/Generated/Microsoft.UI.Dispatching+ABI.swift
Normal file
@ -0,0 +1,390 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherExitDeferral: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x910B5AAC, Data2: 0x3310, Data3: 0x563E, Data4: ( 0x84,0x18,0xF3,0x00,0x55,0x79,0x72,0x9E ))// 910B5AAC-3310-563E-8418-F3005579729E
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xF6EBF8FA, Data2: 0xBE1C, Data3: 0x5BF6, Data4: ( 0xA4,0x67,0x73,0xDA,0x28,0x73,0x8A,0xE8 ))// F6EBF8FA-BE1C-5BF6-A467-73DA28738AE8
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue2: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x0CF48751, Data2: 0xF1AC, Data3: 0x59B8, Data4: ( 0xBA,0x52,0x6C,0xE7,0xA1,0x44,0x4D,0x6F ))// 0CF48751-F1AC-59B8-BA52-6CE7A1444D6F
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue3: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x14A7A175, Data2: 0x5C27, Data3: 0x5A35, Data4: ( 0xB0,0x79,0x21,0x96,0x0C,0xF7,0x64,0xA8 ))// 14A7A175-5C27-5A35-B079-21960CF764A8
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueController: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xBCE8178D, Data2: 0x2183, Data3: 0x584C, Data4: ( 0x9E,0x5B,0xF9,0x36,0x6F,0x6A,0xE4,0x84 ))// BCE8178D-2183-584C-9E5B-F9366F6AE484
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueController2: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x4C68EE2A, Data2: 0x1CB1, Data3: 0x5591, Data4: ( 0xA3,0xA2,0x9B,0x59,0x0B,0x8F,0x8B,0x9A ))// 4C68EE2A-1CB1-5591-A3A2-9B590B8F8B9A
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueControllerStatics: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xF18D6145, Data2: 0x722B, Data3: 0x593D, Data4: ( 0xBC,0xF2,0xA6,0x1E,0x71,0x3F,0x00,0x37 ))// F18D6145-722B-593D-BCF2-A61E713F0037
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueShutdownStartingEventArgs: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x32519BE5, Data2: 0x072B, Data3: 0x5660, Data4: ( 0xA7,0x0E,0x88,0x35,0xC9,0xB8,0x15,0x7D ))// 32519BE5-072B-5660-A70E-8835C9B8157D
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueStatics: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xCD3382EA, Data2: 0xA455, Data3: 0x5124, Data4: ( 0xB6,0x3A,0xCA,0x40,0xD3,0x4C,0xA2,0x3C ))// CD3382EA-A455-5124-B63A-CA40D34CA23C
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xAD4D63FD, Data2: 0x88FE, Data3: 0x541F, Data4: ( 0xAC,0x11,0xBF,0x2D,0xC1,0xED,0x2C,0xE5 ))// AD4D63FD-88FE-541F-AC11-BF2DC1ED2CE5
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueHandler: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x2E0872A9, Data2: 0x4E29, Data3: 0x5F14, Data4: ( 0xB6,0x88,0xFB,0x96,0xD5,0xF9,0xD5,0xF8 ))// 2E0872A9-4E29-5F14-B688-FB96D5F9D5F8
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum __ABI_Microsoft_UI_Dispatching {
|
||||||
|
public class IDispatcherExitDeferral: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherExitDeferral }
|
||||||
|
|
||||||
|
internal func CompleteImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherExitDeferral.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Complete(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDispatcherQueue: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue }
|
||||||
|
|
||||||
|
internal func CreateTimerImpl() throws -> WinAppSDK.DispatcherQueueTimer? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.CreateTimer(pThis, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func TryEnqueueImpl(_ callback: WinAppSDK.DispatcherQueueHandler?) throws -> Bool {
|
||||||
|
var result: boolean = 0
|
||||||
|
let callbackWrapper = __ABI_Microsoft_UI_Dispatching.DispatcherQueueHandlerWrapper(callback)
|
||||||
|
let _callback = try! callbackWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.TryEnqueue(pThis, _callback, &result))
|
||||||
|
}
|
||||||
|
return .init(from: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func TryEnqueueWithPriorityImpl(_ priority: WinAppSDK.DispatcherQueuePriority, _ callback: WinAppSDK.DispatcherQueueHandler?) throws -> Bool {
|
||||||
|
var result: boolean = 0
|
||||||
|
let callbackWrapper = __ABI_Microsoft_UI_Dispatching.DispatcherQueueHandlerWrapper(callback)
|
||||||
|
let _callback = try! callbackWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.TryEnqueueWithPriority(pThis, priority, _callback, &result))
|
||||||
|
}
|
||||||
|
return .init(from: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func add_ShutdownStartingImpl(_ handler: TypedEventHandler<WinAppSDK.DispatcherQueue?, WinAppSDK.DispatcherQueueShutdownStartingEventArgs?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CUI__CDispatching__CDispatcherQueue___x_ABI_CMicrosoft__CUI__CDispatching__CDispatcherQueueShutdownStartingEventArgsWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_ShutdownStarting(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func remove_ShutdownStartingImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_ShutdownStarting(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func add_ShutdownCompletedImpl(_ handler: TypedEventHandler<WinAppSDK.DispatcherQueue?, Any?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CUI__CDispatching__CDispatcherQueue_IInspectableWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_ShutdownCompleted(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func remove_ShutdownCompletedImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_ShutdownCompleted(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDispatcherQueue2: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue2 }
|
||||||
|
|
||||||
|
internal func get_HasThreadAccessImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue2.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_HasThreadAccess(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDispatcherQueue3: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue3 }
|
||||||
|
|
||||||
|
internal func EnqueueEventLoopExitImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue3.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.EnqueueEventLoopExit(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func EnsureSystemDispatcherQueueImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue3.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.EnsureSystemDispatcherQueue(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func RunEventLoopImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue3.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.RunEventLoop(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func RunEventLoopWithOptionsImpl(_ options: WinAppSDK.DispatcherRunOptions, _ deferral: WinAppSDK.DispatcherExitDeferral?) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue3.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.RunEventLoopWithOptions(pThis, options, RawPointer(deferral)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func add_FrameworkShutdownStartingImpl(_ handler: TypedEventHandler<WinAppSDK.DispatcherQueue?, WinAppSDK.DispatcherQueueShutdownStartingEventArgs?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CUI__CDispatching__CDispatcherQueue___x_ABI_CMicrosoft__CUI__CDispatching__CDispatcherQueueShutdownStartingEventArgsWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue3.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_FrameworkShutdownStarting(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func remove_FrameworkShutdownStartingImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue3.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_FrameworkShutdownStarting(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func add_FrameworkShutdownCompletedImpl(_ handler: TypedEventHandler<WinAppSDK.DispatcherQueue?, Any?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CUI__CDispatching__CDispatcherQueue_IInspectableWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue3.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_FrameworkShutdownCompleted(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func remove_FrameworkShutdownCompletedImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue3.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_FrameworkShutdownCompleted(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDispatcherQueueController: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueController }
|
||||||
|
|
||||||
|
internal func get_DispatcherQueueImpl() throws -> WinAppSDK.DispatcherQueue? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_DispatcherQueue(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func ShutdownQueueAsyncImpl() throws -> WindowsFoundation.AnyIAsyncAction? {
|
||||||
|
let (operation) = try ComPtrs.initialize { operationAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueController.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.ShutdownQueueAsync(pThis, &operationAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return __ABI_Windows_Foundation.IAsyncActionWrapper.unwrapFrom(abi: operation)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDispatcherQueueController2: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueController2 }
|
||||||
|
|
||||||
|
internal func ShutdownQueueImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueController2.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.ShutdownQueue(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDispatcherQueueControllerStatics: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueControllerStatics }
|
||||||
|
|
||||||
|
internal func CreateOnDedicatedThreadImpl() throws -> WinAppSDK.DispatcherQueueController? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueControllerStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.CreateOnDedicatedThread(pThis, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func CreateOnCurrentThreadImpl() throws -> WinAppSDK.DispatcherQueueController? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueControllerStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.CreateOnCurrentThread(pThis, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDispatcherQueueShutdownStartingEventArgs: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueShutdownStartingEventArgs }
|
||||||
|
|
||||||
|
internal func GetDeferralImpl() throws -> WindowsFoundation.Deferral? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueShutdownStartingEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetDeferral(pThis, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDispatcherQueueStatics: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueStatics }
|
||||||
|
|
||||||
|
internal func GetForCurrentThreadImpl() throws -> WinAppSDK.DispatcherQueue? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetForCurrentThread(pThis, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IDispatcherQueueTimer: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer }
|
||||||
|
|
||||||
|
internal func get_IntervalImpl() throws -> WindowsFoundation.TimeSpan {
|
||||||
|
var value: __x_ABI_CWindows_CFoundation_CTimeSpan = .init()
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Interval(pThis, &value))
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_IntervalImpl(_ value: WindowsFoundation.TimeSpan) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_Interval(pThis, .from(swift: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsRunningImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsRunning(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsRepeatingImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsRepeating(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func put_IsRepeatingImpl(_ value: Bool) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.put_IsRepeating(pThis, .init(from: value)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func StartImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Start(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func StopImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Stop(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func add_TickImpl(_ handler: TypedEventHandler<WinAppSDK.DispatcherQueueTimer?, Any?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CUI__CDispatching__CDispatcherQueueTimer_IInspectableWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_Tick(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func remove_TickImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_Tick(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
// MARK - DispatcherQueueHandler
|
||||||
|
extension __ABI_Microsoft_UI_Dispatching {
|
||||||
|
public class DispatcherQueueHandler: WindowsFoundation.IUnknown {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueHandler }
|
||||||
|
|
||||||
|
open func InvokeImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueHandler.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Invoke(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
typealias DispatcherQueueHandlerWrapper = InterfaceWrapperBase<__IMPL_Microsoft_UI_Dispatching.DispatcherQueueHandlerBridge>
|
||||||
|
internal static var DispatcherQueueHandlerVTable: __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueHandlerVtbl = .init(
|
||||||
|
QueryInterface: { DispatcherQueueHandlerWrapper.queryInterface($0, $1, $2) },
|
||||||
|
AddRef: { DispatcherQueueHandlerWrapper.addRef($0) },
|
||||||
|
Release: { DispatcherQueueHandlerWrapper.release($0) },
|
||||||
|
Invoke: {
|
||||||
|
guard let __unwrapped__instance = DispatcherQueueHandlerWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
__unwrapped__instance()
|
||||||
|
return S_OK
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}
|
||||||
|
public extension WinRTDelegateBridge where CABI == __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueHandler {
|
||||||
|
static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Dispatching.DispatcherQueueHandlerVTable) { $0 }
|
||||||
|
return .init(lpVtbl:vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@ -0,0 +1,22 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
public enum __IMPL_Microsoft_UI_Dispatching {
|
||||||
|
public class DispatcherQueueHandlerBridge : WinRTDelegateBridge {
|
||||||
|
public typealias Handler = DispatcherQueueHandler
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueHandler
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Dispatching.DispatcherQueueHandler
|
||||||
|
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> Handler? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
let _default = SwiftABI(abi)
|
||||||
|
let handler: Handler = { () in
|
||||||
|
try! _default.InvokeImpl()
|
||||||
|
}
|
||||||
|
return handler
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
366
Sources/WinAppSDK/Generated/Microsoft.UI.Dispatching.swift
Normal file
366
Sources/WinAppSDK/Generated/Microsoft.UI.Dispatching.swift
Normal file
@ -0,0 +1,366 @@
|
|||||||
|
// 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/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuepriority)
|
||||||
|
public typealias DispatcherQueuePriority = __x_ABI_CMicrosoft_CUI_CDispatching_CDispatcherQueuePriority
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherrunoptions)
|
||||||
|
public typealias DispatcherRunOptions = __x_ABI_CMicrosoft_CUI_CDispatching_CDispatcherRunOptions
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherexitdeferral)
|
||||||
|
public final class DispatcherExitDeferral : WinRTClass {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_UI_Dispatching.IDispatcherExitDeferral
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherExitDeferral
|
||||||
|
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_CMicrosoft_CUI_CDispatching_CIDispatcherExitDeferral>?) -> DispatcherExitDeferral? {
|
||||||
|
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("Microsoft.UI.Dispatching.DispatcherExitDeferral")))
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherexitdeferral.complete)
|
||||||
|
public func complete() throws {
|
||||||
|
try _default.CompleteImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue)
|
||||||
|
public final class DispatcherQueue : WinRTClass {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_UI_Dispatching.IDispatcherQueue
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueue
|
||||||
|
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_CMicrosoft_CUI_CDispatching_CIDispatcherQueue>?) -> DispatcherQueue? {
|
||||||
|
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 _IDispatcherQueueStatics: __ABI_Microsoft_UI_Dispatching.IDispatcherQueueStatics = try! RoGetActivationFactory(HString("Microsoft.UI.Dispatching.DispatcherQueue"))
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.getforcurrentthread)
|
||||||
|
public static func getForCurrentThread() -> DispatcherQueue! {
|
||||||
|
return try! _IDispatcherQueueStatics.GetForCurrentThreadImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.createtimer)
|
||||||
|
public func createTimer() throws -> DispatcherQueueTimer! {
|
||||||
|
try _default.CreateTimerImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.tryenqueue)
|
||||||
|
public func tryEnqueue(_ callback: DispatcherQueueHandler!) throws -> Bool {
|
||||||
|
try _default.TryEnqueueImpl(callback)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.tryenqueue)
|
||||||
|
public func tryEnqueue(_ priority: DispatcherQueuePriority, _ callback: DispatcherQueueHandler!) throws -> Bool {
|
||||||
|
try _default.TryEnqueueWithPriorityImpl(priority, callback)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.shutdowncompleted)
|
||||||
|
public lazy var shutdownCompleted : Event<TypedEventHandler<DispatcherQueue?, Any?>> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._default else { return .init() }
|
||||||
|
return try! this.add_ShutdownCompletedImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._default.remove_ShutdownCompletedImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.shutdownstarting)
|
||||||
|
public lazy var shutdownStarting : Event<TypedEventHandler<DispatcherQueue?, DispatcherQueueShutdownStartingEventArgs?>> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._default else { return .init() }
|
||||||
|
return try! this.add_ShutdownStartingImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._default.remove_ShutdownStartingImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
private lazy var _IDispatcherQueue2: __ABI_Microsoft_UI_Dispatching.IDispatcherQueue2! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.hasthreadaccess)
|
||||||
|
public var hasThreadAccess : Bool {
|
||||||
|
get { try! _IDispatcherQueue2.get_HasThreadAccessImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
private lazy var _IDispatcherQueue3: __ABI_Microsoft_UI_Dispatching.IDispatcherQueue3! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.enqueueeventloopexit)
|
||||||
|
public func enqueueEventLoopExit() throws {
|
||||||
|
try _IDispatcherQueue3.EnqueueEventLoopExitImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.ensuresystemdispatcherqueue)
|
||||||
|
public func ensureSystemDispatcherQueue() throws {
|
||||||
|
try _IDispatcherQueue3.EnsureSystemDispatcherQueueImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.runeventloop)
|
||||||
|
public func runEventLoop() throws {
|
||||||
|
try _IDispatcherQueue3.RunEventLoopImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.runeventloop)
|
||||||
|
public func runEventLoop(_ options: DispatcherRunOptions, _ deferral: DispatcherExitDeferral!) throws {
|
||||||
|
try _IDispatcherQueue3.RunEventLoopWithOptionsImpl(options, deferral)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.frameworkshutdowncompleted)
|
||||||
|
public lazy var frameworkShutdownCompleted : Event<TypedEventHandler<DispatcherQueue?, Any?>> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._IDispatcherQueue3 else { return .init() }
|
||||||
|
return try! this.add_FrameworkShutdownCompletedImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._IDispatcherQueue3.remove_FrameworkShutdownCompletedImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueue.frameworkshutdownstarting)
|
||||||
|
public lazy var frameworkShutdownStarting : Event<TypedEventHandler<DispatcherQueue?, DispatcherQueueShutdownStartingEventArgs?>> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._IDispatcherQueue3 else { return .init() }
|
||||||
|
return try! this.add_FrameworkShutdownStartingImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._IDispatcherQueue3.remove_FrameworkShutdownStartingImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
_IDispatcherQueue2 = nil
|
||||||
|
_IDispatcherQueue3 = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuecontroller)
|
||||||
|
public final class DispatcherQueueController : WinRTClass {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_UI_Dispatching.IDispatcherQueueController
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueController
|
||||||
|
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_CMicrosoft_CUI_CDispatching_CIDispatcherQueueController>?) -> DispatcherQueueController? {
|
||||||
|
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 _IDispatcherQueueControllerStatics: __ABI_Microsoft_UI_Dispatching.IDispatcherQueueControllerStatics = try! RoGetActivationFactory(HString("Microsoft.UI.Dispatching.DispatcherQueueController"))
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuecontroller.createondedicatedthread)
|
||||||
|
public static func createOnDedicatedThread() -> DispatcherQueueController! {
|
||||||
|
return try! _IDispatcherQueueControllerStatics.CreateOnDedicatedThreadImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuecontroller.createoncurrentthread)
|
||||||
|
public static func createOnCurrentThread() -> DispatcherQueueController! {
|
||||||
|
return try! _IDispatcherQueueControllerStatics.CreateOnCurrentThreadImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuecontroller.shutdownqueueasync)
|
||||||
|
public func shutdownQueueAsync() throws -> WindowsFoundation.AnyIAsyncAction! {
|
||||||
|
try _default.ShutdownQueueAsyncImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuecontroller.dispatcherqueue)
|
||||||
|
public var dispatcherQueue : DispatcherQueue! {
|
||||||
|
get { try! _default.get_DispatcherQueueImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
private lazy var _IDispatcherQueueController2: __ABI_Microsoft_UI_Dispatching.IDispatcherQueueController2! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuecontroller.shutdownqueue)
|
||||||
|
public func shutdownQueue() throws {
|
||||||
|
try _IDispatcherQueueController2.ShutdownQueueImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
_IDispatcherQueueController2 = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueueshutdownstartingeventargs)
|
||||||
|
public final class DispatcherQueueShutdownStartingEventArgs : WinRTClass {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_UI_Dispatching.IDispatcherQueueShutdownStartingEventArgs
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueShutdownStartingEventArgs
|
||||||
|
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_CMicrosoft_CUI_CDispatching_CIDispatcherQueueShutdownStartingEventArgs>?) -> DispatcherQueueShutdownStartingEventArgs? {
|
||||||
|
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/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueueshutdownstartingeventargs.getdeferral)
|
||||||
|
public func getDeferral() throws -> WindowsFoundation.Deferral! {
|
||||||
|
try _default.GetDeferralImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuetimer)
|
||||||
|
public final class DispatcherQueueTimer : WinRTClass {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_UI_Dispatching.IDispatcherQueueTimer
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer
|
||||||
|
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_CMicrosoft_CUI_CDispatching_CIDispatcherQueueTimer>?) -> DispatcherQueueTimer? {
|
||||||
|
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/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuetimer.start)
|
||||||
|
public func start() throws {
|
||||||
|
try _default.StartImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuetimer.stop)
|
||||||
|
public func stop() throws {
|
||||||
|
try _default.StopImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuetimer.interval)
|
||||||
|
public var interval : WindowsFoundation.TimeSpan {
|
||||||
|
get { try! _default.get_IntervalImpl() }
|
||||||
|
set { try! _default.put_IntervalImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuetimer.isrepeating)
|
||||||
|
public var isRepeating : Bool {
|
||||||
|
get { try! _default.get_IsRepeatingImpl() }
|
||||||
|
set { try! _default.put_IsRepeatingImpl(newValue) }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuetimer.isrunning)
|
||||||
|
public var isRunning : Bool {
|
||||||
|
get { try! _default.get_IsRunningImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.dispatching.dispatcherqueuetimer.tick)
|
||||||
|
public lazy var tick : Event<TypedEventHandler<DispatcherQueueTimer?, Any?>> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._default else { return .init() }
|
||||||
|
return try! this.add_TickImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._default.remove_TickImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public typealias DispatcherQueueHandler = () -> ()
|
||||||
|
extension WinAppSDK.DispatcherQueuePriority {
|
||||||
|
public static var low : WinAppSDK.DispatcherQueuePriority {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CDispatching_CDispatcherQueuePriority_Low
|
||||||
|
}
|
||||||
|
public static var normal : WinAppSDK.DispatcherQueuePriority {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CDispatching_CDispatcherQueuePriority_Normal
|
||||||
|
}
|
||||||
|
public static var high : WinAppSDK.DispatcherQueuePriority {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CDispatching_CDispatcherQueuePriority_High
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension WinAppSDK.DispatcherQueuePriority: @retroactive Hashable, @retroactive Codable {}
|
||||||
|
|
||||||
|
extension WinAppSDK.DispatcherRunOptions {
|
||||||
|
public static var none : WinAppSDK.DispatcherRunOptions {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CDispatching_CDispatcherRunOptions_None
|
||||||
|
}
|
||||||
|
public static var continueOnQuit : WinAppSDK.DispatcherRunOptions {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CDispatching_CDispatcherRunOptions_ContinueOnQuit
|
||||||
|
}
|
||||||
|
public static var quitOnlyLocalLoop : WinAppSDK.DispatcherRunOptions {
|
||||||
|
__x_ABI_CMicrosoft_CUI_CDispatching_CDispatcherRunOptions_QuitOnlyLocalLoop
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension WinAppSDK.DispatcherRunOptions: @retroactive Hashable, @retroactive Codable {}
|
||||||
|
|
||||||
2722
Sources/WinAppSDK/Generated/Microsoft.UI.Input+ABI.swift
Normal file
2722
Sources/WinAppSDK/Generated/Microsoft.UI.Input+ABI.swift
Normal file
File diff suppressed because it is too large
Load Diff
48
Sources/WinAppSDK/Generated/Microsoft.UI.Input+Impl.swift
Normal file
48
Sources/WinAppSDK/Generated/Microsoft.UI.Input+Impl.swift
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
public enum __IMPL_Microsoft_UI_Input {
|
||||||
|
public enum IPointerPointTransformBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CUI_CInput_CIPointerPointTransform
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_UI_Input.IPointerPointTransform
|
||||||
|
public typealias SwiftProjection = AnyIPointerPointTransform
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return IPointerPointTransformImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_UI_Input.IPointerPointTransformVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class IPointerPointTransformImpl: IPointerPointTransform, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = IPointerPointTransformBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.input.ipointerpointtransform.trytransform)
|
||||||
|
fileprivate func tryTransform(_ inPoint: WindowsFoundation.Point, _ outPoint: inout WindowsFoundation.Point) throws -> Bool {
|
||||||
|
try _default.TryTransformImpl(inPoint, &outPoint)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.input.ipointerpointtransform.trytransformbounds)
|
||||||
|
fileprivate func tryTransformBounds(_ inRect: WindowsFoundation.Rect, _ outRect: inout WindowsFoundation.Rect) throws -> Bool {
|
||||||
|
try _default.TryTransformBoundsImpl(inRect, &outRect)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.input.ipointerpointtransform.inverse)
|
||||||
|
fileprivate var inverse : AnyIPointerPointTransform! {
|
||||||
|
get { try! _default.get_InverseImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
3040
Sources/WinAppSDK/Generated/Microsoft.UI.Input.swift
Normal file
3040
Sources/WinAppSDK/Generated/Microsoft.UI.Input.swift
Normal file
File diff suppressed because it is too large
Load Diff
1270
Sources/WinAppSDK/Generated/Microsoft.UI.Windowing+ABI.swift
Normal file
1270
Sources/WinAppSDK/Generated/Microsoft.UI.Windowing+ABI.swift
Normal file
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,8 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
public enum __IMPL_Microsoft_UI_Windowing {
|
||||||
|
}
|
||||||
1026
Sources/WinAppSDK/Generated/Microsoft.UI.Windowing.swift
Normal file
1026
Sources/WinAppSDK/Generated/Microsoft.UI.Windowing.swift
Normal file
File diff suppressed because it is too large
Load Diff
76
Sources/WinAppSDK/Generated/Microsoft.UI.swift
Normal file
76
Sources/WinAppSDK/Generated/Microsoft.UI.swift
Normal file
@ -0,0 +1,76 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
public typealias ClosableNotifierHandler = () -> ()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.displayid)
|
||||||
|
public struct DisplayId: Hashable, Codable {
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.displayid.value)
|
||||||
|
public var value: UInt64 = 0
|
||||||
|
public init() {}
|
||||||
|
public init(value: UInt64) {
|
||||||
|
self.value = value
|
||||||
|
}
|
||||||
|
public static func from(abi: __x_ABI_CMicrosoft_CUI_CDisplayId) -> DisplayId {
|
||||||
|
.init(value: abi.Value)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.iconid)
|
||||||
|
public struct IconId: Hashable, Codable {
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.iconid.value)
|
||||||
|
public var value: UInt64 = 0
|
||||||
|
public init() {}
|
||||||
|
public init(value: UInt64) {
|
||||||
|
self.value = value
|
||||||
|
}
|
||||||
|
public static func from(abi: __x_ABI_CMicrosoft_CUI_CIconId) -> IconId {
|
||||||
|
.init(value: abi.Value)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.windowid)
|
||||||
|
public struct WindowId: Hashable, Codable {
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.windowid.value)
|
||||||
|
public var value: UInt64 = 0
|
||||||
|
public init() {}
|
||||||
|
public init(value: UInt64) {
|
||||||
|
self.value = value
|
||||||
|
}
|
||||||
|
public static func from(abi: __x_ABI_CMicrosoft_CUI_CWindowId) -> WindowId {
|
||||||
|
.init(value: abi.Value)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.iclosablenotifier)
|
||||||
|
public protocol IClosableNotifier : WinRTInterface {
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.iclosablenotifier.isclosed)
|
||||||
|
var isClosed: Bool { get }
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.iclosablenotifier.closed)
|
||||||
|
var closed: Event<ClosableNotifierHandler> { get }
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.ui.iclosablenotifier.frameworkclosed)
|
||||||
|
var frameworkClosed: Event<ClosableNotifierHandler> { get }
|
||||||
|
}
|
||||||
|
|
||||||
|
public extension EventSource where Handler == ClosableNotifierHandler {
|
||||||
|
func invoke() {
|
||||||
|
for handler in getInvocationList() {
|
||||||
|
handler()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
extension IClosableNotifier {
|
||||||
|
public func queryInterface(_ iid: WindowsFoundation.IID) -> IUnknownRef? {
|
||||||
|
switch iid {
|
||||||
|
case __ABI_Microsoft_UI.IClosableNotifierWrapper.IID:
|
||||||
|
let wrapper = __ABI_Microsoft_UI.IClosableNotifierWrapper(self)
|
||||||
|
return wrapper!.queryInterface(iid)
|
||||||
|
default: return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public typealias AnyIClosableNotifier = any IClosableNotifier
|
||||||
|
|
||||||
@ -0,0 +1,205 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIActivationRegistrationManagerStatics: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x5AC4E92E, Data2: 0x017B, Data3: 0x5D68, Data4: ( 0x81,0x98,0xF6,0x86,0x36,0xAB,0x99,0xD3 ))// 5AC4E92E-017B-5D68-8198-F68636AB99D3
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppActivationArguments: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x14F99EAF, Data2: 0x1580, Data3: 0x5062, Data4: ( 0xBD,0xC8,0xD5,0xD1,0xC3,0x11,0x38,0xFB ))// 14F99EAF-1580-5062-BDC8-D5D1C31138FB
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x75766AE4, Data2: 0x0239, Data3: 0x5A26, Data4: ( 0xB9,0xDA,0xD5,0xBF,0xC7,0x5A,0x48,0x66 ))// 75766AE4-0239-5A26-B9DA-D5BFC75A4866
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstanceStatics: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x4F414B25, Data2: 0x8330, Data3: 0x5A9B, Data4: ( 0xBB,0xC1,0x82,0x29,0xD4,0x79,0x64,0x9D ))// 4F414B25-8330-5A9B-BBC1-8229D479649D
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstanceStatics2: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xFE9F1885, Data2: 0x7160, Data3: 0x5397, Data4: ( 0xBA,0x9B,0x58,0x90,0xB2,0x4F,0xDC,0x04 ))// FE9F1885-7160-5397-BA9B-5890B24FDC04
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum __ABI_Microsoft_Windows_AppLifecycle {
|
||||||
|
public class IActivationRegistrationManagerStatics: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIActivationRegistrationManagerStatics }
|
||||||
|
|
||||||
|
internal func RegisterForProtocolActivationImpl(_ scheme: String, _ logo: String, _ displayName: String, _ exePath: String) throws {
|
||||||
|
let _scheme = try! HString(scheme)
|
||||||
|
let _logo = try! HString(logo)
|
||||||
|
let _displayName = try! HString(displayName)
|
||||||
|
let _exePath = try! HString(exePath)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIActivationRegistrationManagerStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.RegisterForProtocolActivation(pThis, _scheme.get(), _logo.get(), _displayName.get(), _exePath.get()))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func RegisterForStartupActivationImpl(_ taskId: String, _ exePath: String) throws {
|
||||||
|
let _taskId = try! HString(taskId)
|
||||||
|
let _exePath = try! HString(exePath)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIActivationRegistrationManagerStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.RegisterForStartupActivation(pThis, _taskId.get(), _exePath.get()))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func UnregisterForProtocolActivationImpl(_ scheme: String, _ exePath: String) throws {
|
||||||
|
let _scheme = try! HString(scheme)
|
||||||
|
let _exePath = try! HString(exePath)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIActivationRegistrationManagerStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.UnregisterForProtocolActivation(pThis, _scheme.get(), _exePath.get()))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func UnregisterForStartupActivationImpl(_ taskId: String) throws {
|
||||||
|
let _taskId = try! HString(taskId)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIActivationRegistrationManagerStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.UnregisterForStartupActivation(pThis, _taskId.get()))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IAppActivationArguments: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppActivationArguments }
|
||||||
|
|
||||||
|
internal func get_KindImpl() throws -> WinAppSDK.ExtendedActivationKind {
|
||||||
|
var value: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind = .init(0)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppActivationArguments.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Kind(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_DataImpl() throws -> Any? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppActivationArguments.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Data(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return __ABI_.AnyWrapper.unwrapFrom(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IAppInstance: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance }
|
||||||
|
|
||||||
|
internal func UnregisterKeyImpl() throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.UnregisterKey(pThis))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func RedirectActivationToAsyncImpl(_ args: WinAppSDK.AppActivationArguments?) throws -> WindowsFoundation.AnyIAsyncAction? {
|
||||||
|
let (operation) = try ComPtrs.initialize { operationAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.RedirectActivationToAsync(pThis, RawPointer(args), &operationAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return __ABI_Windows_Foundation.IAsyncActionWrapper.unwrapFrom(abi: operation)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func GetActivatedEventArgsImpl() throws -> WinAppSDK.AppActivationArguments? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetActivatedEventArgs(pThis, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func add_ActivatedImpl(_ handler: EventHandler<WinAppSDK.AppActivationArguments?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FIEventHandler_1___x_ABI_CMicrosoft__CWindows__CAppLifecycle__CAppActivationArgumentsWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_Activated(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func remove_ActivatedImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_Activated(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_KeyImpl() throws -> String {
|
||||||
|
var value: HSTRING?
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Key(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_IsCurrentImpl() throws -> Bool {
|
||||||
|
var value: boolean = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_IsCurrent(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_ProcessIdImpl() throws -> UInt32 {
|
||||||
|
var value: UINT32 = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_ProcessId(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IAppInstanceStatics: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstanceStatics }
|
||||||
|
|
||||||
|
internal func GetCurrentImpl() throws -> WinAppSDK.AppInstance? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstanceStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetCurrent(pThis, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func GetInstancesImpl() throws -> WindowsFoundation.AnyIVector<WinAppSDK.AppInstance?>? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstanceStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetInstances(pThis, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return WinAppSDK.__x_ABI_C__FIVector_1___x_ABI_CMicrosoft__CWindows__CAppLifecycle__CAppInstanceWrapper.unwrapFrom(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func FindOrRegisterForKeyImpl(_ key: String) throws -> WinAppSDK.AppInstance? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
let _key = try! HString(key)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstanceStatics.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.FindOrRegisterForKey(pThis, _key.get(), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IAppInstanceStatics2: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstanceStatics2 }
|
||||||
|
|
||||||
|
internal func RestartImpl(_ arguments: String) throws -> UWP.AppRestartFailureReason {
|
||||||
|
var result: __x_ABI_CWindows_CApplicationModel_CCore_CAppRestartFailureReason = .init(0)
|
||||||
|
let _arguments = try! HString(arguments)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstanceStatics2.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.Restart(pThis, _arguments.get(), &result))
|
||||||
|
}
|
||||||
|
return result
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,8 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
public enum __IMPL_Microsoft_Windows_AppLifecycle {
|
||||||
|
}
|
||||||
309
Sources/WinAppSDK/Generated/Microsoft.Windows.AppLifecycle.swift
Normal file
309
Sources/WinAppSDK/Generated/Microsoft.Windows.AppLifecycle.swift
Normal file
@ -0,0 +1,309 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.extendedactivationkind)
|
||||||
|
public typealias ExtendedActivationKind = __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.activationregistrationmanager)
|
||||||
|
public final class ActivationRegistrationManager {
|
||||||
|
private static let _IActivationRegistrationManagerStatics: __ABI_Microsoft_Windows_AppLifecycle.IActivationRegistrationManagerStatics = try! RoGetActivationFactory(HString("Microsoft.Windows.AppLifecycle.ActivationRegistrationManager"))
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.activationregistrationmanager.registerforprotocolactivation)
|
||||||
|
public static func registerForProtocolActivation(_ scheme: String, _ logo: String, _ displayName: String, _ exePath: String) {
|
||||||
|
try! _IActivationRegistrationManagerStatics.RegisterForProtocolActivationImpl(scheme, logo, displayName, exePath)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.activationregistrationmanager.registerforstartupactivation)
|
||||||
|
public static func registerForStartupActivation(_ taskId: String, _ exePath: String) {
|
||||||
|
try! _IActivationRegistrationManagerStatics.RegisterForStartupActivationImpl(taskId, exePath)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.activationregistrationmanager.unregisterforprotocolactivation)
|
||||||
|
public static func unregisterForProtocolActivation(_ scheme: String, _ exePath: String) {
|
||||||
|
try! _IActivationRegistrationManagerStatics.UnregisterForProtocolActivationImpl(scheme, exePath)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.activationregistrationmanager.unregisterforstartupactivation)
|
||||||
|
public static func unregisterForStartupActivation(_ taskId: String) {
|
||||||
|
try! _IActivationRegistrationManagerStatics.UnregisterForStartupActivationImpl(taskId)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appactivationarguments)
|
||||||
|
public final class AppActivationArguments : WinRTClass {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_Windows_AppLifecycle.IAppActivationArguments
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppActivationArguments
|
||||||
|
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_CMicrosoft_CWindows_CAppLifecycle_CIAppActivationArguments>?) -> AppActivationArguments? {
|
||||||
|
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/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appactivationarguments.data)
|
||||||
|
public var data : Any! {
|
||||||
|
get { try! _default.get_DataImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appactivationarguments.kind)
|
||||||
|
public var kind : ExtendedActivationKind {
|
||||||
|
get { try! _default.get_KindImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance)
|
||||||
|
public final class AppInstance : WinRTClass {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_Windows_AppLifecycle.IAppInstance
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance
|
||||||
|
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_CMicrosoft_CWindows_CAppLifecycle_CIAppInstance>?) -> AppInstance? {
|
||||||
|
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 _IAppInstanceStatics: __ABI_Microsoft_Windows_AppLifecycle.IAppInstanceStatics = try! RoGetActivationFactory(HString("Microsoft.Windows.AppLifecycle.AppInstance"))
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance.getcurrent)
|
||||||
|
public static func getCurrent() -> AppInstance! {
|
||||||
|
return try! _IAppInstanceStatics.GetCurrentImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance.getinstances)
|
||||||
|
public static func getInstances() -> WindowsFoundation.AnyIVector<AppInstance?>! {
|
||||||
|
return try! _IAppInstanceStatics.GetInstancesImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance.findorregisterforkey)
|
||||||
|
public static func findOrRegisterForKey(_ key: String) -> AppInstance! {
|
||||||
|
return try! _IAppInstanceStatics.FindOrRegisterForKeyImpl(key)
|
||||||
|
}
|
||||||
|
|
||||||
|
private static let _IAppInstanceStatics2: __ABI_Microsoft_Windows_AppLifecycle.IAppInstanceStatics2 = try! RoGetActivationFactory(HString("Microsoft.Windows.AppLifecycle.AppInstance"))
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance.restart)
|
||||||
|
public static func restart(_ arguments: String) -> UWP.AppRestartFailureReason {
|
||||||
|
return try! _IAppInstanceStatics2.RestartImpl(arguments)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance.unregisterkey)
|
||||||
|
public func unregisterKey() throws {
|
||||||
|
try _default.UnregisterKeyImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance.redirectactivationtoasync)
|
||||||
|
public func redirectActivationToAsync(_ args: AppActivationArguments!) throws -> WindowsFoundation.AnyIAsyncAction! {
|
||||||
|
try _default.RedirectActivationToAsyncImpl(args)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance.getactivatedeventargs)
|
||||||
|
public func getActivatedEventArgs() throws -> AppActivationArguments! {
|
||||||
|
try _default.GetActivatedEventArgsImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance.iscurrent)
|
||||||
|
public var isCurrent : Bool {
|
||||||
|
get { try! _default.get_IsCurrentImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance.key)
|
||||||
|
public var key : String {
|
||||||
|
get { try! _default.get_KeyImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance.processid)
|
||||||
|
public var processId : UInt32 {
|
||||||
|
get { try! _default.get_ProcessIdImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applifecycle.appinstance.activated)
|
||||||
|
public lazy var activated : Event<EventHandler<AppActivationArguments?>> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._default else { return .init() }
|
||||||
|
return try! this.add_ActivatedImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._default.remove_ActivatedImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
extension WinAppSDK.ExtendedActivationKind {
|
||||||
|
public static var launch : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_Launch
|
||||||
|
}
|
||||||
|
public static var search : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_Search
|
||||||
|
}
|
||||||
|
public static var shareTarget : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_ShareTarget
|
||||||
|
}
|
||||||
|
public static var file : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_File
|
||||||
|
}
|
||||||
|
public static var `protocol` : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_Protocol
|
||||||
|
}
|
||||||
|
public static var fileOpenPicker : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_FileOpenPicker
|
||||||
|
}
|
||||||
|
public static var fileSavePicker : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_FileSavePicker
|
||||||
|
}
|
||||||
|
public static var cachedFileUpdater : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_CachedFileUpdater
|
||||||
|
}
|
||||||
|
public static var contactPicker : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_ContactPicker
|
||||||
|
}
|
||||||
|
public static var device : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_Device
|
||||||
|
}
|
||||||
|
public static var printTaskSettings : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_PrintTaskSettings
|
||||||
|
}
|
||||||
|
public static var cameraSettings : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_CameraSettings
|
||||||
|
}
|
||||||
|
public static var restrictedLaunch : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_RestrictedLaunch
|
||||||
|
}
|
||||||
|
public static var appointmentsProvider : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_AppointmentsProvider
|
||||||
|
}
|
||||||
|
public static var contact : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_Contact
|
||||||
|
}
|
||||||
|
public static var lockScreenCall : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_LockScreenCall
|
||||||
|
}
|
||||||
|
public static var voiceCommand : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_VoiceCommand
|
||||||
|
}
|
||||||
|
public static var lockScreen : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_LockScreen
|
||||||
|
}
|
||||||
|
public static var pickerReturned : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_PickerReturned
|
||||||
|
}
|
||||||
|
public static var walletAction : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_WalletAction
|
||||||
|
}
|
||||||
|
public static var pickFileContinuation : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_PickFileContinuation
|
||||||
|
}
|
||||||
|
public static var pickSaveFileContinuation : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_PickSaveFileContinuation
|
||||||
|
}
|
||||||
|
public static var pickFolderContinuation : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_PickFolderContinuation
|
||||||
|
}
|
||||||
|
public static var webAuthenticationBrokerContinuation : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_WebAuthenticationBrokerContinuation
|
||||||
|
}
|
||||||
|
public static var webAccountProvider : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_WebAccountProvider
|
||||||
|
}
|
||||||
|
public static var componentUI : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_ComponentUI
|
||||||
|
}
|
||||||
|
public static var protocolForResults : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_ProtocolForResults
|
||||||
|
}
|
||||||
|
public static var toastNotification : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_ToastNotification
|
||||||
|
}
|
||||||
|
public static var print3DWorkflow : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_Print3DWorkflow
|
||||||
|
}
|
||||||
|
public static var dialReceiver : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_DialReceiver
|
||||||
|
}
|
||||||
|
public static var devicePairing : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_DevicePairing
|
||||||
|
}
|
||||||
|
public static var userDataAccountsProvider : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_UserDataAccountsProvider
|
||||||
|
}
|
||||||
|
public static var filePickerExperience : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_FilePickerExperience
|
||||||
|
}
|
||||||
|
public static var lockScreenComponent : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_LockScreenComponent
|
||||||
|
}
|
||||||
|
public static var contactPanel : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_ContactPanel
|
||||||
|
}
|
||||||
|
public static var printWorkflowForegroundTask : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_PrintWorkflowForegroundTask
|
||||||
|
}
|
||||||
|
public static var gameUIProvider : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_GameUIProvider
|
||||||
|
}
|
||||||
|
public static var startupTask : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_StartupTask
|
||||||
|
}
|
||||||
|
public static var commandLineLaunch : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_CommandLineLaunch
|
||||||
|
}
|
||||||
|
public static var barcodeScannerProvider : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_BarcodeScannerProvider
|
||||||
|
}
|
||||||
|
public static var printSupportJobUI : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_PrintSupportJobUI
|
||||||
|
}
|
||||||
|
public static var printSupportSettingsUI : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_PrintSupportSettingsUI
|
||||||
|
}
|
||||||
|
public static var phoneCallActivation : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_PhoneCallActivation
|
||||||
|
}
|
||||||
|
public static var vpnForeground : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_VpnForeground
|
||||||
|
}
|
||||||
|
public static var push : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_Push
|
||||||
|
}
|
||||||
|
public static var appNotification : WinAppSDK.ExtendedActivationKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CAppLifecycle_CExtendedActivationKind_AppNotification
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension WinAppSDK.ExtendedActivationKind: @retroactive Hashable, @retroactive Codable {}
|
||||||
|
|
||||||
@ -0,0 +1,385 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceCandidate: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x6C54BC0C, Data2: 0xEF1E, Data3: 0x57B8, Data4: ( 0xB4,0x78,0x34,0xFE,0xCE,0x73,0x73,0x56 ))// 6C54BC0C-EF1E-57B8-B478-34FECE737356
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceCandidateFactory: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xBB2B30F8, Data2: 0xC19B, Data3: 0x5F43, Data4: ( 0x88,0xD9,0x69,0xAD,0x72,0x8A,0x32,0xF4 ))// BB2B30F8-C19B-5F43-88D9-69AD728A32F4
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceContext: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x96FB48DC, Data2: 0xF77D, Data3: 0x55FF, Data4: ( 0xAF,0x12,0x34,0x86,0x1E,0x3D,0x49,0x39 ))// 96FB48DC-F77D-55FF-AF12-34861E3D4939
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceContext2: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x7A3B1158, Data2: 0x798C, Data3: 0x5949, Data4: ( 0x96,0x9D,0x03,0x51,0x0B,0x9C,0xE6,0xCA ))// 7A3B1158-798C-5949-969D-03510B9CE6CA
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManager: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xAC2291EF, Data2: 0x81BE, Data3: 0x5C99, Data4: ( 0xA0,0xAE,0xBC,0xEE,0x01,0x80,0xB8,0xA8 ))// AC2291EF-81BE-5C99-A0AE-BCEE0180B8A8
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManager2: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x7EC10160, Data2: 0xA154, Data3: 0x5C42, Data4: ( 0x82,0x68,0x30,0xE3,0x06,0xB1,0xF5,0x85 ))// 7EC10160-A154-5C42-8268-30E306B1F585
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManagerFactory: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0xD6ACF18F, Data2: 0x458A, Data3: 0x535B, Data4: ( 0xA5,0xC4,0xAC,0x2D,0xC4,0xE4,0x90,0x99 ))// D6ACF18F-458A-535B-A5C4-AC2DC4E49099
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x4ABBD9BC, Data2: 0xDF4E, Data3: 0x5C7B, Data4: ( 0x81,0x2C,0x7E,0x7B,0xB0,0xC2,0x23,0x77 ))// 4ABBD9BC-DF4E-5C7B-812C-7E7BB0C22377
|
||||||
|
}
|
||||||
|
|
||||||
|
private var IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceNotFoundEventArgs: WindowsFoundation.IID {
|
||||||
|
.init(Data1: 0x64ABB08B, Data2: 0xE77D, Data3: 0x5B26, Data4: ( 0x83,0x0F,0x15,0x94,0x1E,0x0E,0x82,0x00 ))// 64ABB08B-E77D-5B26-830F-15941E0E8200
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum __ABI_Microsoft_Windows_ApplicationModel_Resources {
|
||||||
|
public class IResourceCandidate: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceCandidate }
|
||||||
|
|
||||||
|
internal func get_ValueAsStringImpl() throws -> String {
|
||||||
|
var value: HSTRING?
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceCandidate.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_ValueAsString(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_KindImpl() throws -> WinAppSDK.ResourceCandidateKind {
|
||||||
|
var value: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CResourceCandidateKind = .init(0)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceCandidate.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Kind(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_QualifierValuesImpl() throws -> WindowsFoundation.AnyIMapView<String, String>? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceCandidate.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_QualifierValues(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return WinAppSDK.__x_ABI_C__FIMapView_2_HSTRING_HSTRINGWrapper.unwrapFrom(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IResourceCandidateFactory: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceCandidateFactory }
|
||||||
|
|
||||||
|
internal func CreateInstanceImpl(_ kind: WinAppSDK.ResourceCandidateKind, _ data: String) throws -> IResourceCandidate {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
let _data = try! HString(data)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceCandidateFactory.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.CreateInstance(pThis, kind, _data.get(), &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return IResourceCandidate(value!)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IResourceContext: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceContext }
|
||||||
|
|
||||||
|
open func get_QualifierValuesImpl() throws -> WindowsFoundation.AnyIMap<String, String>? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceContext.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_QualifierValues(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return WinAppSDK.__x_ABI_C__FIMap_2_HSTRING_HSTRINGWrapper.unwrapFrom(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
internal static var IResourceContextVTable: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceContextVtbl = .init(
|
||||||
|
QueryInterface: { IResourceContextWrapper.queryInterface($0, $1, $2) },
|
||||||
|
AddRef: { IResourceContextWrapper.addRef($0) },
|
||||||
|
Release: { IResourceContextWrapper.release($0) },
|
||||||
|
GetIids: {
|
||||||
|
let size = MemoryLayout<WindowsFoundation.IID>.size
|
||||||
|
let iids = CoTaskMemAlloc(UInt64(size) * 3).assumingMemoryBound(to: WindowsFoundation.IID.self)
|
||||||
|
iids[0] = IUnknown.IID
|
||||||
|
iids[1] = IInspectable.IID
|
||||||
|
iids[2] = __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceContextWrapper.IID
|
||||||
|
$1!.pointee = 3
|
||||||
|
$2!.pointee = iids
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetRuntimeClassName: {
|
||||||
|
_ = $0
|
||||||
|
let hstring = try! HString("Microsoft.Windows.ApplicationModel.Resources.IResourceContext").detach()
|
||||||
|
$1!.pointee = hstring
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetTrustLevel: {
|
||||||
|
_ = $0
|
||||||
|
$1!.pointee = TrustLevel(rawValue: 0)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
get_QualifierValues: {
|
||||||
|
guard let __unwrapped__instance = IResourceContextWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let value = __unwrapped__instance.qualifierValues
|
||||||
|
let valueWrapper = WinAppSDK.__x_ABI_C__FIMap_2_HSTRING_HSTRINGWrapper(value)
|
||||||
|
valueWrapper?.copyTo($1)
|
||||||
|
return S_OK
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
public typealias IResourceContextWrapper = InterfaceWrapperBase<__IMPL_Microsoft_Windows_ApplicationModel_Resources.IResourceContextBridge>
|
||||||
|
public class IResourceContext2: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceContext2 }
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IResourceManager: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManager }
|
||||||
|
|
||||||
|
open func get_MainResourceMapImpl() throws -> WinAppSDK.ResourceMap? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManager.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_MainResourceMap(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
open func CreateResourceContextImpl() throws -> WinAppSDK.ResourceContext? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManager.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.CreateResourceContext(pThis, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
open func add_ResourceNotFoundImpl(_ handler: TypedEventHandler<WinAppSDK.ResourceManager?, WinAppSDK.ResourceNotFoundEventArgs?>?) throws -> EventRegistrationToken {
|
||||||
|
var token: EventRegistrationToken = .init()
|
||||||
|
let handlerWrapper = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CWindows__CApplicationModel__CResources__CResourceManager___x_ABI_CMicrosoft__CWindows__CApplicationModel__CResources__CResourceNotFoundEventArgsWrapper(handler)
|
||||||
|
let _handler = try! handlerWrapper?.toABI { $0 }
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManager.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.add_ResourceNotFound(pThis, _handler, &token))
|
||||||
|
}
|
||||||
|
return token
|
||||||
|
}
|
||||||
|
|
||||||
|
open func remove_ResourceNotFoundImpl(_ token: EventRegistrationToken) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManager.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.remove_ResourceNotFound(pThis, token))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
internal static var IResourceManagerVTable: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManagerVtbl = .init(
|
||||||
|
QueryInterface: { IResourceManagerWrapper.queryInterface($0, $1, $2) },
|
||||||
|
AddRef: { IResourceManagerWrapper.addRef($0) },
|
||||||
|
Release: { IResourceManagerWrapper.release($0) },
|
||||||
|
GetIids: {
|
||||||
|
let size = MemoryLayout<WindowsFoundation.IID>.size
|
||||||
|
let iids = CoTaskMemAlloc(UInt64(size) * 3).assumingMemoryBound(to: WindowsFoundation.IID.self)
|
||||||
|
iids[0] = IUnknown.IID
|
||||||
|
iids[1] = IInspectable.IID
|
||||||
|
iids[2] = __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceManagerWrapper.IID
|
||||||
|
$1!.pointee = 3
|
||||||
|
$2!.pointee = iids
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetRuntimeClassName: {
|
||||||
|
_ = $0
|
||||||
|
let hstring = try! HString("Microsoft.Windows.ApplicationModel.Resources.IResourceManager").detach()
|
||||||
|
$1!.pointee = hstring
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
GetTrustLevel: {
|
||||||
|
_ = $0
|
||||||
|
$1!.pointee = TrustLevel(rawValue: 0)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
get_MainResourceMap: {
|
||||||
|
guard let __unwrapped__instance = IResourceManagerWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let value = __unwrapped__instance.mainResourceMap
|
||||||
|
value?.copyTo($1)
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
CreateResourceContext: {
|
||||||
|
do {
|
||||||
|
guard let __unwrapped__instance = IResourceManagerWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let result = try __unwrapped__instance.createResourceContext()
|
||||||
|
result?.copyTo($1)
|
||||||
|
return S_OK
|
||||||
|
} catch { return failWith(err: E_FAIL) }
|
||||||
|
},
|
||||||
|
|
||||||
|
add_ResourceNotFound: {
|
||||||
|
guard let __unwrapped__instance = IResourceManagerWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
guard let handler = WinAppSDK.__x_ABI_C__FITypedEventHandler_2___x_ABI_CMicrosoft__CWindows__CApplicationModel__CResources__CResourceManager___x_ABI_CMicrosoft__CWindows__CApplicationModel__CResources__CResourceNotFoundEventArgsWrapper.unwrapFrom(abi: ComPtr($1)) else { return E_INVALIDARG }
|
||||||
|
let token = __unwrapped__instance.resourceNotFound.addHandler(handler)
|
||||||
|
$2?.initialize(to: .from(swift: token))
|
||||||
|
return S_OK
|
||||||
|
},
|
||||||
|
|
||||||
|
remove_ResourceNotFound: {
|
||||||
|
guard let __unwrapped__instance = IResourceManagerWrapper.tryUnwrapFrom(raw: $0) else { return E_INVALIDARG }
|
||||||
|
let token: EventRegistrationToken = $1
|
||||||
|
__unwrapped__instance.resourceNotFound.removeHandler(token)
|
||||||
|
return S_OK
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
public typealias IResourceManagerWrapper = InterfaceWrapperBase<__IMPL_Microsoft_Windows_ApplicationModel_Resources.IResourceManagerBridge>
|
||||||
|
public class IResourceManager2: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManager2 }
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IResourceManagerFactory: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManagerFactory }
|
||||||
|
|
||||||
|
internal func CreateInstanceImpl(_ fileName: String) throws -> IResourceManager {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
let _fileName = try! HString(fileName)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManagerFactory.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.CreateInstance(pThis, _fileName.get(), &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return IResourceManager(value!)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IResourceMap: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap }
|
||||||
|
|
||||||
|
internal func get_ResourceCountImpl() throws -> UInt32 {
|
||||||
|
var value: UINT32 = 0
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_ResourceCount(pThis, &value))
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func GetSubtreeImpl(_ reference: String) throws -> WinAppSDK.ResourceMap? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
let _reference = try! HString(reference)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetSubtree(pThis, _reference.get(), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func TryGetSubtreeImpl(_ reference: String) throws -> WinAppSDK.ResourceMap? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
let _reference = try! HString(reference)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.TryGetSubtree(pThis, _reference.get(), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func GetValueImpl(_ resource: String) throws -> WinAppSDK.ResourceCandidate? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
let _resource = try! HString(resource)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetValue(pThis, _resource.get(), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func GetValueWithContextImpl(_ resource: String, _ context: WinAppSDK.ResourceContext?) throws -> WinAppSDK.ResourceCandidate? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
let _resource = try! HString(resource)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetValueWithContext(pThis, _resource.get(), RawPointer(context), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func GetValueByIndexImpl(_ index: UInt32) throws -> WindowsFoundation.AnyIKeyValuePair<String, WinAppSDK.ResourceCandidate?>? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetValueByIndex(pThis, index, &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return WinAppSDK.__x_ABI_C__FIKeyValuePair_2_HSTRING___x_ABI_CMicrosoft__CWindows__CApplicationModel__CResources__CResourceCandidateWrapper.unwrapFrom(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func GetValueByIndexWithContextImpl(_ index: UInt32, _ context: WinAppSDK.ResourceContext?) throws -> WindowsFoundation.AnyIKeyValuePair<String, WinAppSDK.ResourceCandidate?>? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.GetValueByIndexWithContext(pThis, index, RawPointer(context), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return WinAppSDK.__x_ABI_C__FIKeyValuePair_2_HSTRING___x_ABI_CMicrosoft__CWindows__CApplicationModel__CResources__CResourceCandidateWrapper.unwrapFrom(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func TryGetValueImpl(_ resource: String) throws -> WinAppSDK.ResourceCandidate? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
let _resource = try! HString(resource)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.TryGetValue(pThis, _resource.get(), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func TryGetValueWithContextImpl(_ resource: String, _ context: WinAppSDK.ResourceContext?) throws -> WinAppSDK.ResourceCandidate? {
|
||||||
|
let (result) = try ComPtrs.initialize { resultAbi in
|
||||||
|
let _resource = try! HString(resource)
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.TryGetValueWithContext(pThis, _resource.get(), RawPointer(context), &resultAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: result)
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public class IResourceNotFoundEventArgs: WindowsFoundation.IInspectable {
|
||||||
|
override public class var IID: WindowsFoundation.IID { IID___x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceNotFoundEventArgs }
|
||||||
|
|
||||||
|
internal func get_ContextImpl() throws -> WinAppSDK.ResourceContext? {
|
||||||
|
let (value) = try ComPtrs.initialize { valueAbi in
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceNotFoundEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Context(pThis, &valueAbi))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return .from(abi: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func get_NameImpl() throws -> String {
|
||||||
|
var value: HSTRING?
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceNotFoundEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.get_Name(pThis, &value))
|
||||||
|
}
|
||||||
|
return .init(from: value)
|
||||||
|
}
|
||||||
|
|
||||||
|
internal func SetResolvedCandidateImpl(_ candidate: WinAppSDK.ResourceCandidate?) throws {
|
||||||
|
_ = try perform(as: __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceNotFoundEventArgs.self) { pThis in
|
||||||
|
try CHECKED(pThis.pointee.lpVtbl.pointee.SetResolvedCandidate(pThis, RawPointer(candidate)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,86 @@
|
|||||||
|
// 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
|
||||||
|
|
||||||
|
public enum __IMPL_Microsoft_Windows_ApplicationModel_Resources {
|
||||||
|
public enum IResourceContextBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceContext
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceContext
|
||||||
|
public typealias SwiftProjection = AnyIResourceContext
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return IResourceContextImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceContextVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class IResourceContextImpl: IResourceContext, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = IResourceContextBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.iresourcecontext.qualifiervalues)
|
||||||
|
fileprivate var qualifierValues : WindowsFoundation.AnyIMap<String, String>! {
|
||||||
|
get { try! _default.get_QualifierValuesImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public enum IResourceManagerBridge : AbiInterfaceBridge {
|
||||||
|
public typealias CABI = __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManager
|
||||||
|
public typealias SwiftABI = __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceManager
|
||||||
|
public typealias SwiftProjection = AnyIResourceManager
|
||||||
|
public static func from(abi: ComPtr<CABI>?) -> SwiftProjection? {
|
||||||
|
guard let abi = abi else { return nil }
|
||||||
|
return IResourceManagerImpl(abi)
|
||||||
|
}
|
||||||
|
|
||||||
|
public static func makeAbi() -> CABI {
|
||||||
|
let vtblPtr = withUnsafeMutablePointer(to: &__ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceManagerVTable) { $0 }
|
||||||
|
return .init(lpVtbl: vtblPtr)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fileprivate class IResourceManagerImpl: IResourceManager, WinRTAbiImpl {
|
||||||
|
fileprivate typealias Bridge = IResourceManagerBridge
|
||||||
|
fileprivate let _default: Bridge.SwiftABI
|
||||||
|
fileprivate var thisPtr: WindowsFoundation.IInspectable { _default }
|
||||||
|
fileprivate init(_ fromAbi: ComPtr<Bridge.CABI>) {
|
||||||
|
_default = Bridge.SwiftABI(fromAbi)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.iresourcemanager.createresourcecontext)
|
||||||
|
fileprivate func createResourceContext() throws -> ResourceContext! {
|
||||||
|
try _default.CreateResourceContextImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.iresourcemanager.mainresourcemap)
|
||||||
|
fileprivate var mainResourceMap : ResourceMap! {
|
||||||
|
get { try! _default.get_MainResourceMapImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.iresourcemanager.resourcenotfound)
|
||||||
|
fileprivate lazy var resourceNotFound : Event<TypedEventHandler<ResourceManager?, ResourceNotFoundEventArgs?>> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._default else { return .init() }
|
||||||
|
return try! this.add_ResourceNotFoundImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._default.remove_ResourceNotFoundImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,336 @@
|
|||||||
|
// 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/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcecandidatekind)
|
||||||
|
public typealias ResourceCandidateKind = __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CResourceCandidateKind
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcecandidate)
|
||||||
|
public final class ResourceCandidate : WinRTClass {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceCandidate
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceCandidate
|
||||||
|
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_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceCandidate>?) -> ResourceCandidate? {
|
||||||
|
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 _IResourceCandidateFactory: __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceCandidateFactory = try! RoGetActivationFactory(HString("Microsoft.Windows.ApplicationModel.Resources.ResourceCandidate"))
|
||||||
|
public init(_ kind: ResourceCandidateKind, _ data: String) {
|
||||||
|
super.init(try! Self._IResourceCandidateFactory.CreateInstanceImpl(kind, data))
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcecandidate.kind)
|
||||||
|
public var kind : ResourceCandidateKind {
|
||||||
|
get { try! _default.get_KindImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcecandidate.qualifiervalues)
|
||||||
|
public var qualifierValues : WindowsFoundation.AnyIMapView<String, String>! {
|
||||||
|
get { try! _default.get_QualifierValuesImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcecandidate.valueasstring)
|
||||||
|
public var valueAsString : String {
|
||||||
|
get { try! _default.get_ValueAsStringImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcecontext)
|
||||||
|
public final class ResourceContext : WinRTClass, IResourceContext {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceContext
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceContext
|
||||||
|
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_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceContext>?) -> ResourceContext? {
|
||||||
|
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 _IResourceContext2: __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceContext2! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcecontext.qualifiervalues)
|
||||||
|
public var qualifierValues : WindowsFoundation.AnyIMap<String, String>! {
|
||||||
|
get { try! _default.get_QualifierValuesImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_IResourceContext2 = nil
|
||||||
|
_default = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemanager)
|
||||||
|
public final class ResourceManager : WinRTClass, IResourceManager {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceManager
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManager
|
||||||
|
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_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceManager>?) -> ResourceManager? {
|
||||||
|
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)
|
||||||
|
}
|
||||||
|
override public init() {
|
||||||
|
super.init(try! RoActivateInstance(HString("Microsoft.Windows.ApplicationModel.Resources.ResourceManager")))
|
||||||
|
}
|
||||||
|
|
||||||
|
private static let _IResourceManagerFactory: __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceManagerFactory = try! RoGetActivationFactory(HString("Microsoft.Windows.ApplicationModel.Resources.ResourceManager"))
|
||||||
|
public init(_ fileName: String) {
|
||||||
|
super.init(try! Self._IResourceManagerFactory.CreateInstanceImpl(fileName))
|
||||||
|
}
|
||||||
|
|
||||||
|
private lazy var _IResourceManager2: __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceManager2! = getInterfaceForCaching()
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemanager.createresourcecontext)
|
||||||
|
public func createResourceContext() throws -> ResourceContext! {
|
||||||
|
try _default.CreateResourceContextImpl()
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemanager.mainresourcemap)
|
||||||
|
public var mainResourceMap : ResourceMap! {
|
||||||
|
get { try! _default.get_MainResourceMapImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemanager.resourcenotfound)
|
||||||
|
public lazy var resourceNotFound : Event<TypedEventHandler<ResourceManager?, ResourceNotFoundEventArgs?>> = {
|
||||||
|
.init(
|
||||||
|
add: { [weak self] in
|
||||||
|
guard let this = self?._default else { return .init() }
|
||||||
|
return try! this.add_ResourceNotFoundImpl($0)
|
||||||
|
},
|
||||||
|
remove: { [weak self] in
|
||||||
|
try? self?._default.remove_ResourceNotFoundImpl($0)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
}()
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_IResourceManager2 = nil
|
||||||
|
_default = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemap)
|
||||||
|
public final class ResourceMap : WinRTClass {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceMap
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap
|
||||||
|
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_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceMap>?) -> ResourceMap? {
|
||||||
|
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/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemap.getsubtree)
|
||||||
|
public func getSubtree(_ reference: String) throws -> ResourceMap! {
|
||||||
|
try _default.GetSubtreeImpl(reference)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemap.trygetsubtree)
|
||||||
|
public func tryGetSubtree(_ reference: String) throws -> ResourceMap! {
|
||||||
|
try _default.TryGetSubtreeImpl(reference)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemap.getvalue)
|
||||||
|
public func getValue(_ resource: String) throws -> ResourceCandidate! {
|
||||||
|
try _default.GetValueImpl(resource)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemap.getvalue)
|
||||||
|
public func getValue(_ resource: String, _ context: ResourceContext!) throws -> ResourceCandidate! {
|
||||||
|
try _default.GetValueWithContextImpl(resource, context)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemap.getvaluebyindex)
|
||||||
|
public func getValueByIndex(_ index: UInt32) throws -> WindowsFoundation.AnyIKeyValuePair<String, ResourceCandidate?>! {
|
||||||
|
try _default.GetValueByIndexImpl(index)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemap.getvaluebyindex)
|
||||||
|
public func getValueByIndex(_ index: UInt32, _ context: ResourceContext!) throws -> WindowsFoundation.AnyIKeyValuePair<String, ResourceCandidate?>! {
|
||||||
|
try _default.GetValueByIndexWithContextImpl(index, context)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemap.trygetvalue)
|
||||||
|
public func tryGetValue(_ resource: String) throws -> ResourceCandidate! {
|
||||||
|
try _default.TryGetValueImpl(resource)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemap.trygetvalue)
|
||||||
|
public func tryGetValue(_ resource: String, _ context: ResourceContext!) throws -> ResourceCandidate! {
|
||||||
|
try _default.TryGetValueWithContextImpl(resource, context)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcemap.resourcecount)
|
||||||
|
public var resourceCount : UInt32 {
|
||||||
|
get { try! _default.get_ResourceCountImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcenotfoundeventargs)
|
||||||
|
public final class ResourceNotFoundEventArgs : WinRTClass {
|
||||||
|
private typealias SwiftABI = __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceNotFoundEventArgs
|
||||||
|
private typealias CABI = __x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceNotFoundEventArgs
|
||||||
|
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_CMicrosoft_CWindows_CApplicationModel_CResources_CIResourceNotFoundEventArgs>?) -> ResourceNotFoundEventArgs? {
|
||||||
|
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/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcenotfoundeventargs.setresolvedcandidate)
|
||||||
|
public func setResolvedCandidate(_ candidate: ResourceCandidate!) throws {
|
||||||
|
try _default.SetResolvedCandidateImpl(candidate)
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcenotfoundeventargs.context)
|
||||||
|
public var context : ResourceContext! {
|
||||||
|
get { try! _default.get_ContextImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.resourcenotfoundeventargs.name)
|
||||||
|
public var name : String {
|
||||||
|
get { try! _default.get_NameImpl() }
|
||||||
|
}
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
_default = nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.iresourcecontext)
|
||||||
|
public protocol IResourceContext : WinRTInterface {
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.iresourcecontext.qualifiervalues)
|
||||||
|
var qualifierValues: WindowsFoundation.AnyIMap<String, String>! { get }
|
||||||
|
}
|
||||||
|
|
||||||
|
extension IResourceContext {
|
||||||
|
public func queryInterface(_ iid: WindowsFoundation.IID) -> IUnknownRef? {
|
||||||
|
switch iid {
|
||||||
|
case __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceContextWrapper.IID:
|
||||||
|
let wrapper = __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceContextWrapper(self)
|
||||||
|
return wrapper!.queryInterface(iid)
|
||||||
|
default: return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public typealias AnyIResourceContext = any IResourceContext
|
||||||
|
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.iresourcemanager)
|
||||||
|
public protocol IResourceManager : WinRTInterface {
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.iresourcemanager.createresourcecontext)
|
||||||
|
func createResourceContext() throws -> WinAppSDK.ResourceContext!
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.iresourcemanager.mainresourcemap)
|
||||||
|
var mainResourceMap: WinAppSDK.ResourceMap! { get }
|
||||||
|
/// [Open Microsoft documentation](https://learn.microsoft.com/windows/windows-app-sdk/api/winrt/microsoft.windows.applicationmodel.resources.iresourcemanager.resourcenotfound)
|
||||||
|
var resourceNotFound: Event<TypedEventHandler<ResourceManager?, ResourceNotFoundEventArgs?>> { get }
|
||||||
|
}
|
||||||
|
|
||||||
|
extension IResourceManager {
|
||||||
|
public func queryInterface(_ iid: WindowsFoundation.IID) -> IUnknownRef? {
|
||||||
|
switch iid {
|
||||||
|
case __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceManagerWrapper.IID:
|
||||||
|
let wrapper = __ABI_Microsoft_Windows_ApplicationModel_Resources.IResourceManagerWrapper(self)
|
||||||
|
return wrapper!.queryInterface(iid)
|
||||||
|
default: return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public typealias AnyIResourceManager = any IResourceManager
|
||||||
|
|
||||||
|
extension WinAppSDK.ResourceCandidateKind {
|
||||||
|
public static var unknown : WinAppSDK.ResourceCandidateKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CResourceCandidateKind_Unknown
|
||||||
|
}
|
||||||
|
public static var string : WinAppSDK.ResourceCandidateKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CResourceCandidateKind_String
|
||||||
|
}
|
||||||
|
public static var filePath : WinAppSDK.ResourceCandidateKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CResourceCandidateKind_FilePath
|
||||||
|
}
|
||||||
|
public static var embeddedData : WinAppSDK.ResourceCandidateKind {
|
||||||
|
__x_ABI_CMicrosoft_CWindows_CApplicationModel_CResources_CResourceCandidateKind_EmbeddedData
|
||||||
|
}
|
||||||
|
}
|
||||||
|
extension WinAppSDK.ResourceCandidateKind: @retroactive Hashable, @retroactive Codable {}
|
||||||
|
|
||||||
9720
Sources/WinAppSDK/Generated/WinAppSDK+Generics.swift
Normal file
9720
Sources/WinAppSDK/Generated/WinAppSDK+Generics.swift
Normal file
File diff suppressed because it is too large
Load Diff
1085
Sources/WinAppSDK/Generated/WinAppSDK+MakeFromAbi.swift
Normal file
1085
Sources/WinAppSDK/Generated/WinAppSDK+MakeFromAbi.swift
Normal file
File diff suppressed because it is too large
Load Diff
78
Sources/WinAppSDK/Initialize.swift
Normal file
78
Sources/WinAppSDK/Initialize.swift
Normal file
@ -0,0 +1,78 @@
|
|||||||
|
import CWinRT
|
||||||
|
import CWinAppSDK
|
||||||
|
import WindowsFoundation
|
||||||
|
import WinSDK
|
||||||
|
|
||||||
|
public enum ThreadingModel {
|
||||||
|
case single
|
||||||
|
case multi
|
||||||
|
}
|
||||||
|
|
||||||
|
/// WindowsAppRuntimeInitializer is used to properly initialize the Windows App SDK runtime, along with the Windows Runtime.
|
||||||
|
/// The runtime is initalized for the lifetime of the object, and is deinitialized when the object is deallocated.
|
||||||
|
/// Example usage:
|
||||||
|
/// ```
|
||||||
|
/// public static func main() {
|
||||||
|
/// do {
|
||||||
|
/// try withExtendedLifetime(WindowsAppRuntimeInitializer()) {
|
||||||
|
/// initialization code here
|
||||||
|
/// }
|
||||||
|
/// }
|
||||||
|
/// catch {
|
||||||
|
/// fatalError("Failed to initialize WindowsAppRuntimeInitializer: \(error)")
|
||||||
|
/// }
|
||||||
|
/// }
|
||||||
|
/// ```
|
||||||
|
public class WindowsAppRuntimeInitializer {
|
||||||
|
// TODO: Figure out how to properly link against delayimp.lib so that we can delay load the bootstrap dll.
|
||||||
|
private typealias pfnMddBootstrapInitialize2 = @convention(c) (UInt32, PCWSTR?, PACKAGE_VERSION, MddBootstrapInitializeOptions) -> HRESULT
|
||||||
|
private typealias pfnMddBootstrapShutdown = @convention(c) () -> Void
|
||||||
|
private let bootsrapperDll = LoadLibraryA("swift-windowsappsdk_CWinAppSDK.resources\\Microsoft.WindowsAppRuntime.Bootstrap.dll")
|
||||||
|
|
||||||
|
private lazy var Initialize: pfnMddBootstrapInitialize2 = {
|
||||||
|
let pfn = GetProcAddress(bootsrapperDll, "MddBootstrapInitialize2")
|
||||||
|
return unsafeBitCast(pfn, to: pfnMddBootstrapInitialize2.self)
|
||||||
|
}()
|
||||||
|
|
||||||
|
private lazy var Shutdown: pfnMddBootstrapShutdown = {
|
||||||
|
let pfn = GetProcAddress(bootsrapperDll, "MddBootstrapShutdown")
|
||||||
|
return unsafeBitCast(pfn, to: pfnMddBootstrapShutdown.self)
|
||||||
|
}()
|
||||||
|
|
||||||
|
private func processHasIdentity() -> Bool {
|
||||||
|
var length: UInt32 = 0
|
||||||
|
return GetCurrentPackageFullName(&length, nil) != APPMODEL_ERROR_NO_PACKAGE
|
||||||
|
}
|
||||||
|
|
||||||
|
public init(threadingModel: ThreadingModel = .single) throws {
|
||||||
|
let roInitParam = switch threadingModel {
|
||||||
|
case .single: RO_INIT_SINGLETHREADED
|
||||||
|
case .multi: RO_INIT_MULTITHREADED
|
||||||
|
}
|
||||||
|
|
||||||
|
try CHECKED(RoInitialize(roInitParam))
|
||||||
|
|
||||||
|
try CHECKED(SetProcessDpiAwareness(PROCESS_PER_MONITOR_DPI_AWARE))
|
||||||
|
|
||||||
|
guard !processHasIdentity() else {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
try CHECKED(Initialize(
|
||||||
|
UInt32(WINDOWSAPPSDK_RELEASE_MAJORMINOR),
|
||||||
|
WINDOWSAPPSDK_RELEASE_VERSION_TAG_SWIFT,
|
||||||
|
.init(),
|
||||||
|
MddBootstrapInitializeOptions(
|
||||||
|
MddBootstrapInitializeOptions_OnNoMatch_ShowUI.rawValue
|
||||||
|
)
|
||||||
|
))
|
||||||
|
}
|
||||||
|
|
||||||
|
deinit {
|
||||||
|
RoUninitialize()
|
||||||
|
if !processHasIdentity() {
|
||||||
|
Shutdown()
|
||||||
|
}
|
||||||
|
FreeLibrary(bootsrapperDll)
|
||||||
|
}
|
||||||
|
}
|
||||||
8
Tests/WinAppSDKTests/InitializerTests.swift
Normal file
8
Tests/WinAppSDKTests/InitializerTests.swift
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
import WinAppSDK
|
||||||
|
import XCTest
|
||||||
|
|
||||||
|
public class InitiailzerTests: XCTestCase {
|
||||||
|
public func testInitializer() {
|
||||||
|
XCTAssertNoThrow(try WindowsAppRuntimeInitializer())
|
||||||
|
}
|
||||||
|
}
|
||||||
191
generate-bindings.ps1
Normal file
191
generate-bindings.ps1
Normal file
@ -0,0 +1,191 @@
|
|||||||
|
function Get-SwiftWinRTVersion {
|
||||||
|
$Projections = Get-Content -Path $PSScriptRoot\projections.json | ConvertFrom-Json
|
||||||
|
return $Projections."swift-winrt"
|
||||||
|
}
|
||||||
|
|
||||||
|
function Get-PackageString {
|
||||||
|
param(
|
||||||
|
$Package
|
||||||
|
)
|
||||||
|
if ($Package) {
|
||||||
|
return " <package id=""$($Package.Id)"" version=""$($Package.Version)"" />`n"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function Restore-Nuget {
|
||||||
|
param(
|
||||||
|
[string]$PackagesDir
|
||||||
|
)
|
||||||
|
$NugetDownloadPath = Join-Path $env:TEMP "nuget.exe"
|
||||||
|
if (-not (Test-Path $NugetDownloadPath)) {
|
||||||
|
Invoke-WebRequest -Uri "https://dist.nuget.org/win-x86-commandline/latest/nuget.exe" -OutFile $NugetDownloadPath
|
||||||
|
}
|
||||||
|
|
||||||
|
$Projections = Get-Content -Path $PSScriptRoot\projections.json | ConvertFrom-Json
|
||||||
|
$SwiftWinRTVersion = Get-SwiftWinRTVersion
|
||||||
|
$PackagesConfigContent = "<?xml version=""1.0"" encoding=""utf-8""?>`n"
|
||||||
|
$PackagesConfigContent += "<packages>`n"
|
||||||
|
$PackagesConfigContent += " <package id=""TheBrowserCompany.SwiftWinRT"" version=""$SwiftWinRTVersion"" />`n"
|
||||||
|
if ($Projections.Package) {
|
||||||
|
$PackagesConfigContent += Get-PackageString -Package $Projections.Package
|
||||||
|
}
|
||||||
|
|
||||||
|
$Projections.Packages | ForEach-Object {
|
||||||
|
$PackagesConfigContent += Get-PackageString -Package $_
|
||||||
|
}
|
||||||
|
$Projections.Dependencies | ForEach-Object {
|
||||||
|
$PackagesConfigContent += Get-PackageString -Package $_
|
||||||
|
}
|
||||||
|
$PackagesConfigContent += "</packages>"
|
||||||
|
if (-not (Test-Path "$PSScriptRoot\.packages")) {
|
||||||
|
New-Item -ItemType Directory -Path "$PSScriptRoot\.packages" | Out-Null
|
||||||
|
}
|
||||||
|
$PackagesConfigPath = Join-Path $PSScriptRoot ".packages\packages.config"
|
||||||
|
$PackagesConfigContent | Out-File -FilePath $PackagesConfigPath
|
||||||
|
|
||||||
|
& $NugetDownloadPath restore $PackagesConfigPath -PackagesDirectory $PackagesDir | Out-Null
|
||||||
|
if ($LASTEXITCODE -ne 0) {
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function Get-WinMDInputs() {
|
||||||
|
param(
|
||||||
|
$Package
|
||||||
|
)
|
||||||
|
$Id = $Package.Id
|
||||||
|
$Version = $Package.Version
|
||||||
|
return Get-ChildItem -Path $PackagesDir\$Id.$Version\ -Filter *.winmd -Recurse
|
||||||
|
}
|
||||||
|
|
||||||
|
function Copy-Project {
|
||||||
|
param(
|
||||||
|
[string]$OutputLocation,
|
||||||
|
[string]$ProjectName
|
||||||
|
)
|
||||||
|
|
||||||
|
if ($ProjectName) {
|
||||||
|
$ProjectGeneratedDir = if ($ProjectName -eq "CWinRT") { "$ProjectName" } else { "$ProjectName\Generated" }
|
||||||
|
|
||||||
|
$ProjectDir = Join-Path $PSScriptRoot "Sources\$ProjectGeneratedDir"
|
||||||
|
if (Test-Path $ProjectDir) {
|
||||||
|
Remove-Item -Path $ProjectDir -Recurse -Force
|
||||||
|
}
|
||||||
|
Copy-Item -Path $OutputLocation\Sources\$ProjectName -Destination $ProjectDir -Recurse -Force
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function Invoke-SwiftWinRT() {
|
||||||
|
param(
|
||||||
|
[string]$PackagesDir
|
||||||
|
)
|
||||||
|
$Projections = Get-Content -Path $PSScriptRoot\projections.json | ConvertFrom-Json
|
||||||
|
|
||||||
|
$SwiftWinRTVersion = Get-SwiftWinRTVersion
|
||||||
|
# write generated bindings to a temp directory since swiftwinrt will generate all dependencies and the CWinRT
|
||||||
|
$OutputLocation = Join-Path $PSScriptRoot ".generated"
|
||||||
|
if (Test-Path $OutputLocation) {
|
||||||
|
Remove-Item -Path $OutputLocation -Recurse -Force
|
||||||
|
}
|
||||||
|
|
||||||
|
$RspParams = "-output $OutputLocation`n"
|
||||||
|
|
||||||
|
# read projections.json and for each "include" write to -include param. for each "exclude" write to -exclude param
|
||||||
|
$Projections.Include | ForEach-Object {
|
||||||
|
$RspParams += "-include $_`n"
|
||||||
|
}
|
||||||
|
$Projections.Exclude | ForEach-Object {
|
||||||
|
$RspParams += "-exclude $_`n"
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($Projections.Package) {
|
||||||
|
Get-WinMDInputs -Package $Package | ForEach-Object {
|
||||||
|
$RspParams += "-input $($_.FullName)`n"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$Projections.Packages | ForEach-Object {
|
||||||
|
Get-WinMDInputs -Package $Package | ForEach-Object {
|
||||||
|
$RspParams += "-input $($_.FullName)`n"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$Projections.Dependencies | ForEach-Object {
|
||||||
|
Get-WinMDInputs -Package $Package | ForEach-Object {
|
||||||
|
$RspParams += "-input $($_.FullName)`n"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
# write rsp params to file
|
||||||
|
$RspFile = Join-Path $PSScriptRoot "swift-winrt.rsp"
|
||||||
|
$RspParams | Out-File -FilePath $RspFile
|
||||||
|
& $PackagesDir\TheBrowserCompany.SwiftWinRT.$SwiftWinRTVersion\bin\swiftwinrt.exe "@$RspFile"
|
||||||
|
|
||||||
|
if ($LASTEXITCODE -ne 0) {
|
||||||
|
Write-Host "swiftwinrt failed with error code $LASTEXITCODE" -ForegroundColor Red
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
$Projections.Projects | ForEach-Object {
|
||||||
|
Copy-Project -OutputLocation $OutputLocation -ProjectName $_
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($Projections.Project) {
|
||||||
|
Copy-Project -OutputLocation $OutputLocation -ProjectName $Projections.Project
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function Copy-PackageAssets {
|
||||||
|
param(
|
||||||
|
[string]$PackagesDir
|
||||||
|
)
|
||||||
|
|
||||||
|
$Arch = "x64"
|
||||||
|
$Projections = Get-Content -Path $PSScriptRoot\projections.json | ConvertFrom-Json
|
||||||
|
$Package = $Projections.Package.Id
|
||||||
|
$PackageVersion = $Projections.Package.Version
|
||||||
|
|
||||||
|
$ProjectName = $Projections.Project
|
||||||
|
$ProjectDir = Join-Path $PSScriptRoot "Sources\C$ProjectName\nuget"
|
||||||
|
|
||||||
|
# copy dlls from runtimes\win-<arch>\native to vendor\bin
|
||||||
|
$PackageDir = Join-Path $PackagesDir "$Package.$PackageVersion"
|
||||||
|
$PackagesRuntimeDir = Join-Path $PackageDir "runtimes\win-$Arch\native"
|
||||||
|
$PackagesBinaries = Get-ChildItem -Path $PackagesRuntimeDir -Filter *.dll -Recurse
|
||||||
|
|
||||||
|
$ProjectBinaryDir = Join-Path $ProjectDir "bin"
|
||||||
|
if (-not (Test-Path $ProjectBinaryDir)) {
|
||||||
|
New-Item -Path $ProjectBinaryDir -ItemType Directory -Force | Out-Null
|
||||||
|
}
|
||||||
|
|
||||||
|
$PackagesBinaries | ForEach-Object {
|
||||||
|
Copy-Item -Path $_.FullName -Destination $ProjectBinaryDir -Force
|
||||||
|
}
|
||||||
|
|
||||||
|
# copy headers from include to vendor\include
|
||||||
|
$ProjectHeadersDir = Join-Path $ProjectDir "include"
|
||||||
|
if (-not (Test-Path $ProjectHeadersDir)) {
|
||||||
|
New-Item -Path $ProjectHeadersDir -ItemType Directory -Force | Out-Null
|
||||||
|
}
|
||||||
|
$PackagesHeaderDir = Join-Path $PackageDir "include"
|
||||||
|
$PackagesHeaders = Get-ChildItem -Path $PackagesHeaderDir -Filter *.h -Recurse
|
||||||
|
$PackagesHeaders | ForEach-Object {
|
||||||
|
Copy-Item -Path $_.FullName -Destination $ProjectHeadersDir -Force
|
||||||
|
}
|
||||||
|
|
||||||
|
# Copy libs from lib\win-<arch> to vendor\lib
|
||||||
|
$ProjectLibsDir = Join-Path $ProjectDir "lib"
|
||||||
|
$PackagesLibsDir = Join-Path $PackageDir "lib\win10-x64"
|
||||||
|
$PackagesLibs = Get-ChildItem -Path $PackagesLibsDir -Filter *.lib -Recurse
|
||||||
|
if (-not (Test-Path $ProjectLibsDir)) {
|
||||||
|
New-Item -Path $ProjectLibsDir -ItemType Directory -Force | Out-Null
|
||||||
|
}
|
||||||
|
$PackagesLibs | ForEach-Object {
|
||||||
|
Copy-Item -Path $_.FullName -Destination $ProjectLibsDir -Force
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$PackagesDir = Join-Path $PSScriptRoot ".packages"
|
||||||
|
Restore-Nuget -PackagesDir $PackagesDir
|
||||||
|
Invoke-SwiftWinRT -PackagesDir $PackagesDir
|
||||||
|
Copy-PackageAssets -PackagesDir $PackagesDir
|
||||||
|
Write-Host "SwiftWinRT bindings generated successfully!" -ForegroundColor Green
|
||||||
6
packages.config
Normal file
6
packages.config
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<packages>
|
||||||
|
<package id="TheBrowserCompany.SwiftWinRT" version="0.5.0" />
|
||||||
|
<package id="Microsoft.WindowsAppSDK" version="1.5.240205001-preview1" />
|
||||||
|
<package id="Microsoft.Windows.SDK.Contracts" version="10.0.18362.2005" />
|
||||||
|
</packages>
|
||||||
30
projections.json
Normal file
30
projections.json
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
{
|
||||||
|
"swift-winrt": "0.5.0",
|
||||||
|
"package": {
|
||||||
|
"id": "Microsoft.WindowsAppSDK",
|
||||||
|
"version": "1.5.240205001-preview1"
|
||||||
|
},
|
||||||
|
"project": "WinAppSDK",
|
||||||
|
"dependencies": [
|
||||||
|
{ "id": "Microsoft.Windows.SDK.Contracts", "version": "10.0.18362.2005" }
|
||||||
|
],
|
||||||
|
"include": [
|
||||||
|
"Microsoft.UI.Composition",
|
||||||
|
"Microsoft.UI.Composition.Interactions",
|
||||||
|
"Microsoft.UI.Composition.SpringVector3NaturalMotionAnimation",
|
||||||
|
"Microsoft.UI.Composition.SystemBackdrops",
|
||||||
|
"Microsoft.UI.Content.DesktopChildSiteBridge",
|
||||||
|
"Microsoft.UI.Dispatching.DispatcherQueueController",
|
||||||
|
"Microsoft.UI.Input",
|
||||||
|
"Microsoft.UI.Windowing.AppWindow",
|
||||||
|
"Microsoft.UI.Windowing.AppWindowTitleBar",
|
||||||
|
"Microsoft.UI.Windowing.DisplayArea",
|
||||||
|
"Microsoft.UI.Windowing.FullScreenPresenter",
|
||||||
|
"Microsoft.UI.Windowing.OverlappedPresenter",
|
||||||
|
"Microsoft.Windows.ApplicationModel.Resources.ResourceManager",
|
||||||
|
"Microsoft.Windows.AppLifecycle.ActivationRegistrationManager",
|
||||||
|
"Microsoft.Windows.AppLifecycle.AppInstance"
|
||||||
|
],
|
||||||
|
"exclude": [
|
||||||
|
]
|
||||||
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user