LCL, publish OnGetCheckboxState and OnSetCheckboxState for drawgrid

git-svn-id: trunk@39142 -
This commit is contained in:
jesus 2012-10-20 00:03:37 +00:00
parent e10b54f335
commit 20b874b8f0

View File

@ -1444,6 +1444,7 @@ type
property OnEndDrag; property OnEndDrag;
property OnEnter; property OnEnter;
property OnExit; property OnExit;
property OnGetCheckboxState;
property OnGetEditMask; property OnGetEditMask;
property OnGetEditText; property OnGetEditText;
property OnHeaderClick; property OnHeaderClick;
@ -1464,6 +1465,7 @@ type
property OnSelectEditor; property OnSelectEditor;
property OnSelection; property OnSelection;
property OnSelectCell; property OnSelectCell;
property OnSetCheckboxState;
property OnSetEditText; property OnSetEditText;
property OnStartDock; property OnStartDock;
property OnStartDrag; property OnStartDrag;
@ -9579,8 +9581,11 @@ end;
procedure TCustomDrawGrid.SetCheckboxState(const aCol, aRow: Integer; procedure TCustomDrawGrid.SetCheckboxState(const aCol, aRow: Integer;
const aState: TCheckboxState); const aState: TCheckboxState);
begin begin
if assigned(FOnSetCheckboxState) then if assigned(FOnSetCheckboxState) then begin
OnSetCheckboxState(self, aCol, aRow, aState); OnSetCheckboxState(self, aCol, aRow, aState);
if DefaultDrawing then
InvalidateCell(aCol, aRow);
end;
end; end;
function TCustomDrawGrid.CreateVirtualGrid: TVirtualGrid; function TCustomDrawGrid.CreateVirtualGrid: TVirtualGrid;