From feb2cb481c621e7a73c0e3214694849e543ee60d Mon Sep 17 00:00:00 2001 From: Basile Burg Date: Sun, 26 Sep 2021 16:28:56 +0200 Subject: [PATCH] Revert partly "Add HookGetCheckboxForBoolean handler in OI only once." This reverts partly commit 943e4e4ff74138f26d96e24e23c7791b3eab4f33. (cherry picked from commit 45a590ed0b9b61027bad6ac57b7eadb3da9c4ba3) --- components/ideintf/objectinspector.pp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/components/ideintf/objectinspector.pp b/components/ideintf/objectinspector.pp index feaf663358..8e9482106e 100644 --- a/components/ideintf/objectinspector.pp +++ b/components/ideintf/objectinspector.pp @@ -1385,6 +1385,7 @@ procedure TOICustomPropertyGrid.SetPropertyEditorHook( begin if FPropertyEditorHook=NewPropertyEditorHook then exit; FPropertyEditorHook:=NewPropertyEditorHook; + FPropertyEditorHook.AddHandlerGetCheckboxForBoolean(@HookGetCheckboxForBoolean); IncreaseChangeStep; SetSelection(FSelection); end; @@ -4512,12 +4513,7 @@ begin Selection := nil; for Page:=Low(TObjectInspectorPage) to High(TObjectInspectorPage) do if GridControl[Page]<>nil then - begin - if Page=oipgpProperties then // Add HookGetCheckboxForBoolean only once. - FPropertyEditorHook.AddHandlerGetCheckboxForBoolean( - @GridControl[Page].HookGetCheckboxForBoolean); GridControl[Page].PropertyEditorHook:=FPropertyEditorHook; - end; OldSelection:=TPersistentSelectionList.Create; try FPropertyEditorHook.GetSelection(OldSelection);