Hello Lazarus-List,

Maybe somebody had noted that all keys that perform some action in a
DBGrid by default are never passed to the KeyPress event, like return,
delete, keyup, keydown,... The reason is that this actions are handled
in the keydown event and to note that they are handled by the DBGrid
the "Key" variable is set to zero which finally prevent the right key
value to be handled by "KeyPress" as zero is "invalid".

I had fixed it in my local copy using the "CanGridHandleKey" but also
in "Grids" (TCustomGrid) some keys are handled to perform default
operations and when performed the "Key" is set to zero also. I think
they can be safelly removed, the zero setting, but I wish to know if
somebody is aware of the reason to set them to zero.

If I do not get feedback in 2 or 3 days I'll post the patch in the
bugtracker to propose a solution to this problem.

-- 
Best regards,
 JoshyFun


--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to