Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - Popup Menu
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Popup Menu

 Post Reply Post Reply
Author
Message
thodgson View Drop Down
Groupie
Groupie


Joined: 11 August 2003
Status: Offline
Points: 78
Post Options Post Options   Thanks (0) Thanks(0)   Quote thodgson Quote  Post ReplyReply Direct Link To This Post Topic: Popup Menu
    Posted: 11 August 2003 at 1:37pm

I have a popup menu, that doesn't do anthing fancy at all, which is having two problems:

The application is derived from the Outlook GUI example.  The popup menu appears in the frame with the ListView.  Functionally, when a user right clicks on a list item, the menu should pop-up.

1. The toolbar icons don't show up.  In my Mainframe class's OnCreate method, I am calling InstallCoolMenus and passing in the resource ID for the popup menu. 

2. The menu doesn't seem to respond to Update UI messages, e.g., certain items in the "main" menu are greyed out, but in the popup, they are not.

Maybe I'm missing something very simple, please let me know.  If you know of an example I can work with, please let me know.

 

Thanks!

 

Back to Top
thodgson View Drop Down
Groupie
Groupie


Joined: 11 August 2003
Status: Offline
Points: 78
Post Options Post Options   Thanks (0) Thanks(0)   Quote thodgson Quote  Post ReplyReply Direct Link To This Post Posted: 12 August 2003 at 5:05pm

Got it.  In my TrackPopupMenu method call, I was passing in this instead of the active view:

 

Was:

pop->TrackPopupMenuEx( TPM_LEFTALIGN | TPM_RIGHTBUTTON,

point.x, point.y, this, NULL );

 

Now:

pop->TrackPopupMenuEx( TPM_LEFTALIGN | TPM_RIGHTBUTTON,

point.x, point.y, AfxGetMainWnd()->GetActiveWindow(), NULL );

Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.141 seconds.