Click to See Complete Forum and Search --> : how to display a shortcut menu same as VC6?


1stapp
April 8th, 1999, 03:10 AM
my application have some dockable toolbars and a dockable dialogbar, I wish a shortcutmenu appear when right click at toolbars and the gray bar on which the toolbars are settled.

I give the toolbars seperated classes, and then use OnContextMenu(), it display a menu when click directly at the toolbars, but do not when click at the gray bar contain the toolbars, it is not same as in VC6. I used spy++ and find the gray bar behind the toolbars has a HWND, but I don't know what it is or how to use the HWND.

I have tried to associate the toolbars to Mainframe and add RButtonDown message to MainFrame's message map, but they don't response, why? later I used pretranslatemessage() for CMainFrame, it responsed, but all the dialogbar and the statusbar response to the message, that's not I want.