From 0f6e65188af0c4b1d3e4dff17ceb96bbd8ebb271 Mon Sep 17 00:00:00 2001 From: Pietro Gagliardi Date: Sat, 18 Oct 2014 09:25:54 -0400 Subject: [PATCH] Fixed paintControlBackground() on Windows; there is no longera guarantee of every control being put on top of a container. --- newctrl/common_windows.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/newctrl/common_windows.c b/newctrl/common_windows.c index b30b132..d4db842 100644 --- a/newctrl/common_windows.c +++ b/newctrl/common_windows.c @@ -105,14 +105,9 @@ void paintControlBackground(HWND hwnd, HDC dc) parent = hwnd; for (;;) { parent = GetParent(parent); - if (parent == NULL) - xpanic("error getting parent container of control in paintControlBackground()", GetLastError()); - // wine sends these messages early, yay... - if (parent == msgwin) - return; - parent = GetParent(parent); if (parent == NULL) xpanic("error getting parent control of control in paintControlBackground()", GetLastError()); + // wine sends these messages early, yay... if (parent == msgwin) return; if (GetClassNameW(parent, classname, 128) == 0)