Win32 fix: Closing file with CTRL-F4 on form designer caused access violation. Patch from Ludo Brands, issue #19294

git-svn-id: trunk@30575 -
This commit is contained in:
juha 2011-05-06 10:09:44 +00:00
parent febce422a7
commit fb63887235

View File

@ -2495,7 +2495,7 @@ begin
// we cannot tell for sure windows didn't want the key
// for WM_CHAR check WM_GETDLGCODE/DLGC_WANTCHARS
// winapi too inconsistent about return value
if (lWinControl <> nil) and (PLMsg^.Result = 0) then
if (lWinControl <> nil) and (PLMsg^.Result = 0) and (LMKey.CharCode<>0) then
DeliverMessage(lWinControl, PLMsg^);
// handle Ctrl-A for edit controls