Click here to Skip to main content
15,887,135 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionRe: i/o stream problem Pin
David Crow5-Oct-07 3:36
David Crow5-Oct-07 3:36 
QuestionPressing several buttons at once Pin
vSteve5-Oct-07 0:04
vSteve5-Oct-07 0:04 
AnswerRe: Pressing several buttons at once Pin
Nishad S5-Oct-07 1:02
Nishad S5-Oct-07 1:02 
GeneralRe: Pressing several buttons at once Pin
vSteve5-Oct-07 1:12
vSteve5-Oct-07 1:12 
GeneralRe: Pressing several buttons at once Pin
Nishad S5-Oct-07 1:32
Nishad S5-Oct-07 1:32 
GeneralRe: Pressing several buttons at once Pin
Nathan Holt at EMOM5-Oct-07 5:58
Nathan Holt at EMOM5-Oct-07 5:58 
GeneralRe: Pressing several buttons at once Pin
vSteve6-Oct-07 22:23
vSteve6-Oct-07 22:23 
GeneralRe: Pressing several buttons at once Pin
Nathan Holt at EMOM8-Oct-07 10:30
Nathan Holt at EMOM8-Oct-07 10:30 
KalvinComer wrote:
Nathan:

Thanks for your suggestion. I now have two pushlike buttons on the dialogue and it behaves just how I want it with respect to the keyboard. But with respect to the mouse can I get the control to be true whilest the mouse is over it and the LH mouse button is down, and it returns to false when the mouse LH button is released.


That makes things more complicated. When a mouse button is pressed over a control, the control captures the mouse input so that other windows don't get mouse messages. If you made a subclass of CButton that informed its parent whenever it got a mouse message, and used it for control members, you could update the state of the buttons according to the mouse state as well as the keyboard state.

I've just realized that you could also intercept mouse messages in PretranslateMessage for the same effect.

Nathan
GeneralRe: Pressing several buttons at once Pin
vSteve8-Oct-07 23:34
vSteve8-Oct-07 23:34 
QuestionHow to avoid 3rd party frame's vestiges on my app [modified] Pin
Nelek5-Oct-07 0:01
protectorNelek5-Oct-07 0:01 
QuestionClass Variable Initialization Pin
nitin34-Oct-07 23:32
nitin34-Oct-07 23:32 
AnswerRe: Class Variable Initialization Pin
Nelek4-Oct-07 23:43
protectorNelek4-Oct-07 23:43 
GeneralRe: Class Variable Initialization Pin
nitin34-Oct-07 23:58
nitin34-Oct-07 23:58 
GeneralRe: Class Variable Initialization Pin
ThatsAlok5-Oct-07 0:46
ThatsAlok5-Oct-07 0:46 
GeneralRe: Class Variable Initialization Pin
jhwurmbach5-Oct-07 0:53
jhwurmbach5-Oct-07 0:53 
GeneralRe: Class Variable Initialization Pin
Mark Salsbery5-Oct-07 6:03
Mark Salsbery5-Oct-07 6:03 
QuestionRe: Class Variable Initialization Pin
David Crow5-Oct-07 3:39
David Crow5-Oct-07 3:39 
QuestionHow to Create Process in new Desktop Pin
GauranG Shah4-Oct-07 23:17
GauranG Shah4-Oct-07 23:17 
AnswerRe: How to Create Process in new Desktop Pin
nitin34-Oct-07 23:35
nitin34-Oct-07 23:35 
GeneralRe: How to Create Process in new Desktop Pin
GauranG Shah5-Oct-07 0:03
GauranG Shah5-Oct-07 0:03 
QuestionRe: How to Create Process in new Desktop Pin
GauranG Shah5-Oct-07 0:35
GauranG Shah5-Oct-07 0:35 
QuestionLinking Errors Pin
kiranin4-Oct-07 22:49
kiranin4-Oct-07 22:49 
AnswerRe: Linking Errors Pin
Hamid_RT4-Oct-07 23:12
Hamid_RT4-Oct-07 23:12 
AnswerRe: Linking Errors Pin
ShilpiP5-Oct-07 0:11
ShilpiP5-Oct-07 0:11 
Questioninterview questions Pin
neelu77794-Oct-07 21:43
neelu77794-Oct-07 21:43 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.