halildurmus / dartwinrt

Idiomatic Dart projection of the modern Windows Runtime (WinRT) APIs.
BSD 3-Clause "New" or "Revised" License
49 stars 3 forks source link

Expose WinRT structs as Dart classes #99

Closed halildurmus closed 1 year ago

halildurmus commented 1 year ago

Description

Exposes WinRT structs as Dart classes just like we expose the Guid class instead of the native struct GUID.

The primary motivation for this is to get rid of memory leaks on methods/properties that return WinRT struct. With this, we can safely free the native struct pointer and then return the Dart class variant to consumers.

Related Issue

None

Type of Change