Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS Tech Support » CExtPopupMenuWnd/Status bar Collapse All
Subject Author Date
R M Jun 2, 2008 - 5:04 AM

Dear Support,



Hovering over the items of a context menu, context help will be shown in the parent windows status bar. How to suppress the access to the status bar?



The menu is constructed menu by using an existing CMenu pointer:



OnContextMenu (CWnd* pWnd, CPoint point)

{

...

    CMenu menu;

    VERIFY(    menu.LoadMenu(nRsrcID));

    HWND hWnd = pWnd->GetSafeHwnd();

    ASSERT( hWnd != NULL );

    ASSERT( ::IsWindow( hWnd ) );

    CExtPopupMenuWnd * pPopupMenu = new CExtPopupMenuWnd;

    VERIFY( pPopupMenu->UpdateFromMenu( hWnd , &menu ) );



    if( !pPopupMenu->TrackPopupMenu(TPMX_OWNERDRAW_FIXED|TPMX_HIDE_KEYBOARD_ACCELERATORS,

                                    point.x, point.y ))

    {

    ...

    }

....

}



Thanks in advance



RM

Technical Support Jun 2, 2008 - 11:55 AM

The CExtPopupMenuWnd popup menu in Prof-UIS works in the same way as MFC menus. If the status tip is specified for menu command items, it’s displayed in the message pane of the status bar. The status pane with identifier equal to zero is called "message pane" and both toolbars and menus in both Prof-UIS and MFC change text of the message pane automatically. You can use a popup menu with command items which have no status tip texts specified in resources. Or, you can use a status bar without any message pane.