On 22.05.2016 15:45, Vojtěch Čihák wrote:

With a small correction: it must be hooked only in design time.

constructor TMyTabSheet.Create(TheOwner: TComponent);

begin

  ...

  if csDesigning in ComponentState then

GlobalDesignHook.AddHandlerSetSelection(@HookSelection);

end;


You should separate the hook completely from your run-time code. Use the hook (and include IDEIntf) only in your design-time package and unit.

Ondrej
--
_______________________________________________
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to