I placed a TMSFMXGrid on a form and compiled for OS X. Running the program, entering a value into a cell and pressing the enter key generates a beep. How to get rid of the beep?
The issue with the Beep is also reproducible on TEdit, so it's unfortunately a FireMonkey issue.
We have already investigated this here and didn't find a workaround yet.
I found a workaround to suppress the beep on Enter in OS X!
Create a TTMSFMXGrid descendent, TTMSFMXGridEx say. Expose the DialogKey procedure. Then:
procedure TTMSFMXGridEx.DialogKey(var Key: Word; Shift: TShiftState);
if Key = vkReturn then
Key := 0;
The above procedure swallows the Enter key so that there is no beep and closes the cell editor.
The real underlying issue here is that it's also reproducible in TEdit, which means that it isn't correctly handled in FireMonkey. If the issue is workarounded in TTMSFMXGrid and the underlying issue in the FireMonkey framework is fixed then it could possibly introduce other issues.
Hoping for your understanding,