CsWinRT icon indicating copy to clipboard operation
CsWinRT copied to clipboard

C# language projection for the Windows Runtime

Results 226 CsWinRT issues
Sort by recently updated
recently updated
newest added

**Describe the bug** DispatcherQueue doesn't flow the .NET ExecutionContext like other built-in classes in .NET do, see https://devblogs.microsoft.com/pfxteam/executioncontext-vs-synchronizationcontext/ In UWP this is at least done by https://github.com/dotnet/corefx/blob/1814a950a4ed69da659d34ed5329e2eabd59b3cc/src/System.Runtime.WindowsRuntime/src/System/Threading/WindowsRuntimeSynchronizationContext.cs#L179 However, one could...

bug

# Proposal: update library/generated callsites of Marshal.QueryInterface for .NET 9 ## Summary Tracking issue for https://github.com/dotnet/runtime/pull/94470. Here's my thoughts from https://github.com/dotnet/runtime/pull/94470#issuecomment-1808902508: > - For multi-targeted sources, they can just use...

enhancement

**Describe the bug** The `ObjectReferenceWithContext.GetCurrentContext()` has incorrect trim annotations and is not actually trim safe (not preserving public fields that `GetIID` requires), but is not producing a warning due to...

bug
trimming

**Describe the bug** I have a managed WinRT type, [`CanvasEffect`](https://github.com/Sergio0694/ComputeSharp/blob/4f05a70177ce1e1fdcf44c96b8d99dd6c7c59f65/src/ComputeSharp.D2D1.WinUI/CanvasEffect.cs#L12) (a class implementing the `ICanvasImage` WinRT interface from Win2D), that also implements a classic COM interface, [`ICanvasImageInterop`](https://github.com/Sergio0694/ComputeSharp/blob/4f05a70177ce1e1fdcf44c96b8d99dd6c7c59f65/src/ComputeSharp.D2D1.WinUI/ABI.Microsoft.Graphics.Canvas/ICanvasImageInterop.cs#L87). This type can...

bug

# Proposal: drop wrapping properties for all vtable types, expose fields ## Summary Currently, CsWinRT has wrapping properties for all vtable types, like eg. `IUnknown`: https://github.com/microsoft/CsWinRT/blob/71169932920500310921b4c3fadba1e5a99c6138/src/WinRT.Runtime/Interop/IUnknownVftbl.cs#L15-L22 This unnecessarily increases the...

enhancement

**Describe the bug** Right now, CsWinRT generate both implicit and explicit implementations of pretty much **all** APIs. This causes considerable code bloat, makes the generated projections harder to navigate, and...

bug

# Proposal: marshalling blittable arrays should just pin them, not use `GCHandle`-s ## Summary If you have an API taking an array, like this: ```idl void Foo(byte[] body); ``` Today...

enhancement

# Proposal: Implement interop with .NET source generated `GeneratedComInterface` interfaces ## Summary In .NET 8, the .NET team has introduced source-generated COM through the `GeneratedComInterface` attribute and a corresponding source-generator....

enhancement

**Describe the bug** Our winget PowerShell modules have their own custom AssemblyLoadContext to load binaries to avoid dependency conflicts. This is the recommended [solution](https://learn.microsoft.com/en-us/powershell/scripting/dev-cross-plat/resolving-dependency-conflicts?view=powershell-7.3) from the PowerShell team. However, loading...

bug

**Describe the bug** When creating a WinRT component with CsWinRT, publishing with AOT results in the .winmd file not being copied correctly in the \publish folder. It does appear in...

bug