windows: Update windows-rs crate and better error handling in DirectWrite (#12818)

- Update `windows-rs` from `0.56` to `0.57`
- Use the newly introduced `Owned` struct in `0.57` to handle the RAII
stuff of `HANDLE`
- Better error handling in `DirectWrite`

Release Notes:

- N/A
This commit is contained in:
张小白 2024-06-15 01:12:20 +08:00 committed by GitHub
parent 1413b5af93
commit 4cb45e63f4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 116 additions and 167 deletions

View file

@ -139,7 +139,7 @@ xim = { git = "https://github.com/npmania/xim-rs", rev = "27132caffc5b9bc9c432ca
[target.'cfg(windows)'.dependencies]
windows.workspace = true
windows-core = "0.56"
windows-core = "0.57"
[target.'cfg(windows)'.build-dependencies]
embed-resource = "2.4"