From a3bd391ebcc4322903470131068ca811365c0465 Mon Sep 17 00:00:00 2001 From: Jaex Date: Wed, 6 Jan 2016 14:48:33 +0200 Subject: [PATCH] If client rectangle same size as window size then don't add it --- ShareX.ScreenCaptureLib/WindowsRectangleList.cs | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/ShareX.ScreenCaptureLib/WindowsRectangleList.cs b/ShareX.ScreenCaptureLib/WindowsRectangleList.cs index bb9e910ba..45e541f9b 100644 --- a/ShareX.ScreenCaptureLib/WindowsRectangleList.cs +++ b/ShareX.ScreenCaptureLib/WindowsRectangleList.cs @@ -28,7 +28,6 @@ You should have received a copy of the GNU General Public License using System.Collections.Generic; using System.Drawing; using System.Threading; -using System.Windows.Forms; namespace ShareX.ScreenCaptureLib { @@ -83,11 +82,6 @@ public List GetWindowInfoList() { if (window2.Rectangle.Contains(window.Rectangle)) { - if (window.IsWindow && window.Rectangle == window2.Rectangle) - { - break; - } - rectVisible = false; break; } @@ -148,7 +142,7 @@ private bool CheckHandle(IntPtr handle, bool isWindow) { Rectangle clientRect = NativeMethods.GetClientRect(handle); - if (clientRect.IsValid()) + if (clientRect.IsValid() && clientRect != windowInfo.Rectangle) { windows.Add(new SimpleWindowInfo(handle, clientRect)); }