mousewheel on get

Post Reply
User avatar
Detlef Hoefner
Posts: 312
Joined: Sat Oct 08, 2005 9:12 am
Location: Germany
Contact:

mousewheel on get

Post by Detlef Hoefner »

Hi all,

is there a way to detect a mousewheel movement on a get?

Similar to a spinner i would like to enhance numeric gets with a method for incr. and decr. by srolling the mousewheel up or down.
Photoshop i.e. does this and i find it very comfortable.

But i have no idea how to recognize the wheel over a get.

Could anybody give me a hint for this?

Thanks,
Detlef
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Re: mousewheel on get

Post by Enrico Maria Giordano »

You have to inherit your own TMyGet and add MouseWheel() or HandleEvent() methods to it (or modify the standard TGet class).

Have a look at TWBrowse and TRichEdit for a sample.

EMG
User avatar
Detlef Hoefner
Posts: 312
Joined: Sat Oct 08, 2005 9:12 am
Location: Germany
Contact:

Post by Detlef Hoefner »

Hi Enrico,

i feared you were in holiday :wink:

Until now i didn't yet work with inherited classes.

Do you mean something like :
TMyGet from TGet and then overide the method MouseWheel() from the window class with my own code?

I will try this. I think i remember a description from James Bott how to do such things.

Thanks and regards,
Detlef
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Post by Enrico Maria Giordano »

Detlef Hoefner wrote:Hi Enrico,

i feared you were in holiday :wink:
:-)
Detlef Hoefner wrote:Until now i didn't yet work with inherited classes.

Do you mean something like :
TMyGet from TGet and then overide the method MouseWheel() from the window class with my own code?
Yes, exactly.

EMG
Post Reply