From 89f67df0cbe680b602582218a848fe0ec43ed12f Mon Sep 17 00:00:00 2001 From: Artem Date: Mon, 15 Dec 2014 14:22:49 +0300 Subject: [PATCH] FindWindowA Function to find a window's handle by its title. BTW, with `SW_HIDE` this is sometimes useful as a workaround for the lack of `-mwindows` in Cargo (https://github.com/rust-lang/cargo/issues/544). --- src/lib.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/lib.rs b/src/lib.rs index 8c3b59937..f0b127a98 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -2822,6 +2822,12 @@ extern "system" { lprc: *const RECT, hbr: HBRUSH, ) -> c_int; + /// Retrieves a handle to the top-level window whose class name and window name match the specified strings. + /// cf. http://msdn.microsoft.com/library/windows/desktop/ms633499%28v=vs.85%29.aspx + pub fn FindWindowA ( + lpClassName: LPCSTR, + lpWindowName: LPCSTR + ) -> HWND; pub fn GetClientRect( hWnd: HWND, lpRect: LPRECT,