Thread View: comp.windows.ms.programmer
2 messages
2 total messages
Started by Noel S. Gorelick
Wed, 22 Jul 1992 15:19
Questions, round two...
Author: Noel S. Gorelick
Date: Wed, 22 Jul 1992 15:19
Date: Wed, 22 Jul 1992 15:19
16 lines
1038 bytes
1038 bytes
Since I got such great response from the first set of questions, I'll try my luck with round number two: How does one cause a static window to respond to input? I have a fairly complex arrangement of static windows that I want to be able to click on and get a response from... Straight subclassing doesn't work. The subclass procedure never even gets called for the mouse events. (Somewhere in the Petzold book, he says that statics trap the NCHITTEST message to disable mouse events. Where and how do I re-enable them?) (Email, please, our news server just bit the dust) Noel (ngorelic@musette.cr.usgs.gov)
Re: Questions, round two...
Author: Kenneth Blackler
Date: Fri, 24 Jul 1992 15:52
Date: Fri, 24 Jul 1992 15:52
35 lines
1939 bytes
1939 bytes
In <9207221520.AA05939@ucbvax.Berkeley.EDU> ngorelic@MUSETTE.CR.USGS.GOV (Noel S. Gorelick) writes: >Since I got such great response from the first set of questions, >I'll try my luck with round number two: >How does one cause a static window to respond to input? I have a >fairly complex arrangement of static windows that I want to be able >to click on and get a response from... Straight subclassing doesn't >work. The subclass procedure never even gets called for the mouse >events. >(Somewhere in the Petzold book, he says that statics trap the >NCHITTEST message to disable mouse events. Where and how do I >re-enable them?) >(Email, please, our news server just bit the dust) >Noel (ngorelic@musette.cr.usgs.gov) A quick way is to create each static control using CreateWindowEx which by default means your window DOESN'T have the WS_EX_NOPARENTNOTIFY style. Your dialog box therefore will receive WM_PARENTNOTIFY messages and you can process these to tell you which control is pressed in (only those created this way and added to the dialog box will generate the message). It will even tell you the (x,y) position 8-) Ken B. -- ______________________________________ ____________ _____________ |Ken Blackler kb@jet.uk (+44)235 464743| | __________ | | -Fusion- | |JET Joint Undertaking, Abingdon | | | |_ | | |Energy for the| |Oxfordshire, England. OX14 3EA | | \_/ |_ | | | (far) future | - Disclaimer: Please note that the above is a personal view and should not be construed as an official comment from the JET project.
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads