-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Reorganize Swift files more hierarchically (#267)
- Loading branch information
1 parent
c0de718
commit c228356
Showing
48 changed files
with
58 additions
and
66 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import COM_ABI | ||
|
||
extension COMError { | ||
/// Creates an instance of `ICreateErrorInfo`. | ||
public static func createErrorInfo() throws -> ICreateErrorInfo { | ||
var createErrorInfo = ICreateErrorInfoProjection.abiDefaultValue | ||
defer { ICreateErrorInfoProjection.release(&createErrorInfo) } | ||
try COMError.fromABI(SWRT_CreateErrorInfo(&createErrorInfo)) | ||
return try NullResult.unwrap(ICreateErrorInfoProjection.toSwift(createErrorInfo)) | ||
} | ||
|
||
/// Creates an instance of `IErrorInfo` with prepopulated fields. | ||
public static func createErrorInfo(guid: GUID? = nil, source: String? = nil, description: String?, | ||
helpFile: String? = nil, helpContext: UInt32? = nil) throws -> IErrorInfo { | ||
let errorInfo = try createErrorInfo() | ||
if let guid { try errorInfo.setGUID(guid) } | ||
if let source { try errorInfo.setSource(source) } | ||
if let description { try errorInfo.setDescription(description) } | ||
if let helpFile { try errorInfo.setHelpFile(helpFile) } | ||
if let helpContext { try errorInfo.setHelpContext(helpContext) } | ||
return try errorInfo.queryInterface(IErrorInfoProjection.self) | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
1 change: 1 addition & 0 deletions
1
...rces/WindowsRuntime/ArrayProjection.swift → ...time/ProjectedTypes/ArrayProjection.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
20 changes: 0 additions & 20 deletions
20
Support/Sources/WindowsRuntime/ProjectedTypes/Core/IRestrictedErrorInfo+details.swift
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Defines Swift projections for core WinRT types, and COM types that support the Windows Runtime. Those types are defined in native idl or C++ headers rather than Windows Metadata files and cannot be generated. |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.