Sehe gerade, es geht noch einfacher...
Delphi-Quellcode:
uses Forms, Classes, Dialogs;
type
TMyComponent = class(TComponent)
private
{ Private-Deklarationen }
procedure ApplicationMinimize(Sender: TObject);
protected
{ Protected-Deklarationen }
public
{ Public-Deklarationen }
constructor create(AOwner: TComponent); override;
published
{ Published-Deklarationen }
end;
implementation
constructor TMyComponent.create(AOwner: TComponent);
begin
inherited Create(AOwner);
Application.OnMinimize:=ApplicationMinimize;
end;
procedure TMyComponent.ApplicationMinimize(Sender: TObject);
begin
showmessage('minimiert');
end;
Gruss
Thorsten