|
-
January 14th, 2006, 01:31 AM
#1
About the CMenu
I created a menu in a dialog using CMenu.
When we click a button or the mouse over a button in the menu, the submenu will appear.
Then how can i know the submenu is appeared and close the appeared submenu in my dialog.
-
January 14th, 2006, 02:16 AM
#2
Re: About the CMenu
Can I ask why you are putting a menu in a dialog?
Wakeup in the morning and kick the day in the teeth!! Or something like that.
"i don't want to write leak free code or most efficient code, like others traditional (so called expert) coders do."
-
January 14th, 2006, 04:24 AM
#3
Re: About the CMenu
Hi,
Use the TrackPopupMenu function to display your popupmenu, If you use it with the TPM_RETURNCMD flag you will be able to say if the user has select a commands or press Cancel.
Note that TrackPopupMenu returns only when the menu is no more displayed (Cancel of the user or selection of command).
-
January 14th, 2006, 04:31 AM
#4
Re: About the CMenu
Sorry,
I do not read correctly the topic.
try to handle the WM_INITMENUPOPUP in your dialog.
It will contain the handle of the menu or submenu displayed.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|