On Mon, 21 Jan 2013 07:16:27 +0008
xrfang <[email protected]> wrote:

> Hi,
> 
> I want to use TApplicationProperties.OnUserInput to process keyboard/mouse 
> events.  But the parameter of this method is a Cardinal. 
> My questions are:
> 
> 1) How do I know its event type, such as keydown/keyup/keypress or mouse move 
> etc?

if Msg=LM_KEYDOWN then ...

 
> 2) How do I know the actual key that is pressed, or the X, Y coordinates of 
> the mouse?

To interpret key and coordinates correctly you need the context.
If you want context-specific events then you have to use the
events of the context, e.g. the form, button, etc.

Mattias

--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to