CtrlCore: Fix of WndDestroy

git-svn-id: svn://ultimatepp.org/upp/trunk@11859 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2018-03-22 08:56:04 +00:00
parent b4c5845e0c
commit 6119e7719f

View file

@ -568,7 +568,7 @@ void Ctrl::WndDestroy()
GuiLock __;
if(top && top->hwnd) {
HWND hwnd = top->hwnd;
WndFree(); // CXL 2007-06-04 to avoid loosing focus with maximize box owned dialogs
WndFree();
::DestroyWindow(hwnd);
}
}
@ -675,7 +675,7 @@ LRESULT CALLBACK Ctrl::WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lP
}
#endif
LRESULT l = 0;
if(w) {
if(w && w->GetHWND()) {
#if defined(_DEBUG) && LOGTIMING
int ticks = msecs();
String wname = w->Name();