unit MZBlatt_TEST1;
interface
uses
Classes, ExtCtrls, WinTypes, Dialogs, Controls;
type
TZeichenBlatt_TEST1 =
class(TImage)
private
protected
function DoMouseWheel(Shift: TShiftState; WheelDelta: Integer; MousePos: TPoint): Boolean;
override;
procedure MouseDown(Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
override;
constructor Create(aOwner: TComponent);
override;
published
property OnMouseWheel;
end;
procedure Register;
implementation
procedure Register;
begin
RegisterComponents('
Test', [TZeichenBlatt_TEST1]);
end;
constructor TZeichenBlatt_TEST1.Create(aOwner: TComponent);
begin
inherited create(aOwner);
end;
procedure TZeichenBlatt_TEST1.MouseDown(Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
begin
inherited MouseDown(Button, Shift, X, Y);
ShowMessage('
MoiseleKlickGehtSupertoll');
end;
function TZeichenBlatt_TEST1.DoMouseWheel(Shift: TShiftState; WheelDelta: Integer; MousePos: TPoint): Boolean;
begin
ShowMessage('
Vorher: DräDichDräDichRäädchen');
Result :=
inherited DoMouseWheel(Shift, WheelDelta, MousePos);
ShowMessage('
Nacher: HasteDichGutGeräätMeinRäädchen');
end;
end.