Alistair,

If you want to fully support the MouseUp event, propogated to the
ballooncontrols then you should derive TBallonControl from TControl, rather
than TComponent. TControl has mouse handling fully supported and your
TBalloonControl will handle mouse clicks fine. To add custom behaviour to
mouse interaction on your TBalloonControl, override the MouseDown,
MouseMove, and MouseUp methods of the TControl.
Your BallonForm already knows how to pass on mouse messages to child
controls so you don't even need to hook up events to the controls - just let
the balloon controls handle their own events.

Cheers,
Phil.


----- Original Message ----- 
From: "Alistair George" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, May 13, 2004 4:56 PM
Subject: [DUG] Component syntax question


> My earlier I have solved to the extent I can get the onMouseUp event
working but only on
> some parts of the created CustomForm. What I'd appreciate is the correct
syntax
> for the part marked //***************** to //****************
> I dont know how to insert the needed parameters eg it wants
> OnMouseUp(Sender: TObject; Button: TMouseButton;
>   Shift: TShiftState; X, Y: Integer); but the component does not know
about
> those Objects/variables thanks:
>
> constructor TBalloon.CreateNew(AOwner: TComponent; Dummy: Integer = 0);
> begin
>   inherited;
>   OnActivate := OnChange;
>   OnDeactivate := OnChange;
>   OnClick := OnMouseClick;
> //************************
> OnMouseUp:=OnMouseUp;
> //************************
>
> _______________________________________________
> Delphi mailing list
> [EMAIL PROTECTED]
> http://ns3.123.co.nz/mailman/listinfo/delphi
>

_______________________________________________
Delphi mailing list
[EMAIL PROTECTED]
http://ns3.123.co.nz/mailman/listinfo/delphi

Reply via email to