debrunson
asked on
Controls on dialog-based program remain active when main window loses focus
I have built a dialog-based program in MFC / C++. It works fine. It has a menu bar, a tool bar, and a tab control. The problem is that when I run my program, then switch to a different window (any window), certain controls on my original dialog do not deactivate. The main dialog itself deactivates, but all it takes is one click on the menu, toolbar, or one of the tabs, and they fly into action, just as though the main dialog is totally active. Obviously this is not "normal" Windows behavior. Generally you have to click on a window (anywhere) to activate it, then click on the control or function that you wish to use. Can someone tell me what is going on?
Thank you
Thank you
Why do you think it is not normal behaviour? I have just opened "Date and Time" control panel and switched to the browser window (this window) to type the response. Now: all it takes is a single click on "Additional Clocks" tab page in the "Date and Time" Control panel applet to "fly it into action". I think that was a normal behaviour from as long as I remember Windows
ASKER
After further investigation it looks like this phenomenon is application-dependent. Office products (Word, Excel, Powerpoint) work in the way that I described above. I guess that's what gave me the idea that this is normal. If any of those windows are deactivated, they must be reactivated before menus and toolbars become functional. But other things (like Solidworks, Photoshop, Acrobat Pro) don't behave that way. If they are deactivated, it only takes one click for the menus to pop up, etc. I thought there was a Window convention for this sort of thing but apparently not???
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you very much, this makes sense. Sorry for the delay, have been out of town.