From 8b5cc6b3d91a279afe90df85f4db891f94ed45d0 Mon Sep 17 00:00:00 2001 From: wp_xxyyzz Date: Sat, 5 Sep 2020 22:33:26 +0000 Subject: [PATCH] fpspreadsheet: second attempt to fix worksheetgrid writing edited cell to wrong cell when grid is on MDI form (issue #37596). git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@7644 8e941d3f-bd1b-0410-a28a-d453659cc2b4 --- components/fpspreadsheet/source/visual/fpspreadsheetgrid.pas | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/fpspreadsheet/source/visual/fpspreadsheetgrid.pas b/components/fpspreadsheet/source/visual/fpspreadsheetgrid.pas index 945df52ca..1a62818cf 100644 --- a/components/fpspreadsheet/source/visual/fpspreadsheetgrid.pas +++ b/components/fpspreadsheet/source/visual/fpspreadsheetgrid.pas @@ -3370,7 +3370,8 @@ procedure TsCustomWorksheetGrid.EditorDoGetValue; var cell: Pcell; begin - if (Editor<>nil) and Editor.Visible and (FOldEditorText <> FEditText) then + inherited; + if (FOldEditorText <> FEditText) then begin cell := Worksheet.GetCell(GetWorksheetRow(Row), GetWorksheetCol(Col)); if Worksheet.IsMerged(cell) then @@ -3382,7 +3383,6 @@ begin FEditText := ''; FOldEditorText := ''; end; - inherited; end; function TsCustomWorksheetGrid.EditorByStyle(Style: TColumnButtonStyle): TWinControl;