From 60cbe2d6c7d0a0b9dafce40d9d9ecdc868c4c49b Mon Sep 17 00:00:00 2001 From: "(no author)" <(no author)@4f64403b-2f21-0410-a795-97e2b3489a10> Date: Tue, 3 Jun 2008 06:46:56 +0000 Subject: added option to allow popups when fullscreen window is not topmost git-svn-id: https://server.scottellis.com.au/svn/mim_plugs@411 4f64403b-2f21-0410-a795-97e2b3489a10 --- yapp/message_pump.cpp | 27 +++++---------------------- 1 file changed, 5 insertions(+), 22 deletions(-) (limited to 'yapp/message_pump.cpp') diff --git a/yapp/message_pump.cpp b/yapp/message_pump.cpp index 6b5bfb8..426d0ab 100644 --- a/yapp/message_pump.cpp +++ b/yapp/message_pump.cpp @@ -26,18 +26,8 @@ bool is_full_screen() { hWnd = GetForegroundWindow(); if(hWnd && hWnd != GetDesktopWindow() && hWnd != GetShellWindow()) { GetClientRect(hWnd, &ClientRect); - if ((ClientRect.right - ClientRect.left) >= w && (ClientRect.bottom - ClientRect.top) >= h) { - /* - { - TCHAR buf[512]; - if(GetWindowText(hWnd, buf, 512)) - PUShowMessageW(buf, SM_NOTIFY); - else - PUShowMessage("no title", SM_NOTIFY); - } - */ + if ((ClientRect.right - ClientRect.left) >= w && (ClientRect.bottom - ClientRect.top) >= h) return true; - } } // check other top level windows @@ -45,23 +35,16 @@ bool is_full_screen() { if(IsWindowVisible(hWnd) == 0 || IsIconic(hWnd) || hWnd == GetDesktopWindow() || hWnd == GetShellWindow()) continue; - //if (!(GetWindowLong(hWnd, GWL_EXSTYLE) & WS_EX_TOPMOST)) - //continue; + if(DBGetContactSettingByte(0, MODULE, "ShowForNonTopmostFullscreenWindows", 0) == 1) { + if (!(GetWindowLong(hWnd, GWL_EXSTYLE) & WS_EX_TOPMOST)) + continue; + } // not sure if this could be done more simply using 'IsZoomed'? GetClientRect(hWnd, &ClientRect); if ((ClientRect.right - ClientRect.left) < w || (ClientRect.bottom - ClientRect.top) < h) continue; - /* - { - TCHAR buf[512]; - if(GetWindowText(hWnd, buf, 512)) - PUShowMessageW(buf, SM_NOTIFY); - else - PUShowMessage("no title", SM_NOTIFY); - } - */ return true; } -- cgit v1.2.3