I have a CDialog
with a CFMCMenuButton
. when I open it, everything appears normally:
The problem happens when I click somewhere else to close the menu. The menu seems unclosable, unless user selects an option of it. And if I press Escape on the keyboard, the dialog closes itself, which is too drastic; I really would want it to close only the menu.
I know I could solve this by setting its property "OS Menu" in the resource file to True (or equivalently, assigning its property m_bOSMenu= TRUE
). And I would get:
As you can see in the image, the consequences are :
- I loose the icons (not very important)
- I loose some items' disablings (important) done by
OnInitMenuPopup
(side note: the second menucolumn is also done byOnInitMenuPopup
and it appears as it should be). If user clicks in these options, they will work and they SHOULD NOT.
How can I solve the problem?