mirror of
https://github.com/LGUG2Z/komorebi.git
synced 2026-03-29 13:41:56 +02:00
fix(windows): remove hwnd val checks on 0.35
Small commit to temporarily handle a regression introduced by my changes when upgrading from 0.34 to 0.35. Checking for a 0 HWND value results in an Err being propagated in fns like GetForegroundWindow, while the error message just reads "The operation completed successfully. (os error 0)". This behaviour was causing regressions in features such as window floating which seems to be resolved by removing the 0 HWND check.
This commit is contained in:
@@ -130,11 +130,7 @@ macro_rules! impl_process_windows_crate_integer_wrapper_result {
|
||||
$(
|
||||
impl ProcessWindowsCrateResult<$deref> for $input {
|
||||
fn process(self) -> Result<$deref> {
|
||||
if self.0 == 0 {
|
||||
Ok(self.0)
|
||||
} else {
|
||||
Err(std::io::Error::last_os_error().into())
|
||||
}
|
||||
Ok(self.0)
|
||||
}
|
||||
}
|
||||
)+
|
||||
|
||||
Reference in New Issue
Block a user