mirror of
https://github.com/LGUG2Z/komorebi.git
synced 2026-03-23 09:51:16 +01:00
The 0.20.0 release of windows-rs includes a Handle trait which provides ok() and invalid() fns for implementors, including HWND and HANDLE. This is pretty cool (and also a big breaking change since the release takes away is_null() at the same time...), so the code in windows_api.rs has been updated to make use of this by implementing a ProcessWindowsCrateResult trait with a process() fn. When implemented for a windows::Result<T>, it will do any required processing for T, and ensure that windows::Error is converted to an eyre-compatible Report. Switching to this means that I have been able to get rid of some of the hacky error handling for weird behaviours encountered previously. So far, they don't seem to be presenting again, but I will run with this build for a couple of days to see if the false-negative errors are really gone for good with this update.
14 lines
258 B
TOML
14 lines
258 B
TOML
[package]
|
|
name = "bindings"
|
|
version = "0.1.0"
|
|
authors = ["Jade Iqbal"]
|
|
edition = "2018"
|
|
|
|
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
|
|
|
[dependencies]
|
|
windows = "0.20"
|
|
|
|
[build-dependencies]
|
|
windows = "0.20"
|