[lazarus] Extending TToolButton Messages

Mattias Gaertner nc-gaertnma at netcologne.de
Wed Dec 25 05:25:46 EST 2002


On Mon, 23 Dec 2002 18:20:27 +0100
Martin Smat <martin.smat at tiscali.cz> wrote:

> Hi,
> In procedure TToolbar.WndProc are defined two messages 
> (LM_INSERTTOOLBUTTON and LM_DELETETOOLBUTTON) in CNSendMessage and both 
> messages have their second parameter (Data) nil. Can we use this 
> parameter for something more usefull?
> I suggest in case LM_INSERTTOOLBUTTON the Data be as TTBButton structure 
> (Pointer(Message.LParam)) and in case LM_DELETETOOLBUTTON the Data be 
> the number of deleted Toolbarbutton (@(Message.WParam)).
> This would be very usefull for creating toolbarbuttons in Win32 API.

AFAIK both messages do not exist under Delphi. I think, we should replace
them with interface calls (for readability and smart linking).


Mattias






More information about the Lazarus mailing list