Skip to content

Commit

Permalink
Fix bug: Missing definitions causing memory corruption
Browse files Browse the repository at this point in the history
  • Loading branch information
Ciantic committed Nov 10, 2023
1 parent 22819bd commit 6fe5ded
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/interfaces.rs
Original file line number Diff line number Diff line change
Expand Up @@ -388,6 +388,13 @@ pub unsafe trait IVirtualDesktopNotification: IUnknown {
desktop: ComIn<IVirtualDesktop>,
name: HSTRING,
) -> HRESULT;

pub unsafe fn virtual_desktop_switched(&self, desktop: ComIn<IVirtualDesktop>) -> HRESULT;

pub unsafe fn remote_virtual_desktop_connected(
&self,
desktop: ComIn<IVirtualDesktop>,
) -> HRESULT;
}

#[windows_interface::interface("0CD45E71-D927-4F15-8B0A-8FEF525337BF")]
Expand Down
8 changes: 8 additions & 0 deletions src/listener.rs
Original file line number Diff line number Diff line change
Expand Up @@ -297,4 +297,12 @@ impl IVirtualDesktopNotification_Impl for VirtualDesktopNotification {
(self.sender)(DesktopEvent::WindowChanged(hwnd));
HRESULT(0)
}

unsafe fn virtual_desktop_switched(&self, desktop: ComIn<IVirtualDesktop>) -> HRESULT {
HRESULT(0)
}

unsafe fn remote_virtual_desktop_connected(&self, desktop: ComIn<IVirtualDesktop>) -> HRESULT {
HRESULT(0)
}
}

0 comments on commit 6fe5ded

Please sign in to comment.