Explorar o código

win-capture: Fix a bug with INCLUDE_MINIMIZED

This fixes a bug where if INCLUDE_MINIMIZED was set and the window size
was (0, 0), the window would still be excluded from the resulting list
that was created.
jp9000 %!s(int64=11) %!d(string=hai) anos
pai
achega
5e2eef6231
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      plugins/win-capture/window-helpers.c

+ 1 - 1
plugins/win-capture/window-helpers.c

@@ -180,7 +180,7 @@ static bool check_window_valid(HWND window, enum window_search_mode mode)
 		return false;
 	if (styles & WS_CHILD)
 		return false;
-	if (rect.bottom == 0 || rect.right == 0)
+	if (mode == EXCLUDE_MINIMIZED && (rect.bottom == 0 || rect.right == 0))
 		return false;
 
 	return true;