Given a window and an Intuition style Menu list, this creates a 'PopUp'-menu
under the mouse pointer, and allows the user to make a selection just as if
it were a normal 'Dropdown'-menu. The returned code is also the same format,
so you can deciper wich item was selected using ITEMNUM and SUBNUM macros.
The only difference with the Intuition style menus are:
Only one menu is accessed, and its title is not diplayed.
The user holds down the left mouse button rather than the right.
Only one item can be selected, since only one button is used.
Mutual exclusion is not supported at this point.
A straightforward way to use this would be to create a Menu (using
POWERWindows is possible), and a Gadget. When the gadget is selected with
a GADGETDOWN event, call PopUpMenu, passing it the Menu. The user selection
code will be returned, which you can decipher with ITEMNUM and SUBNUM. Note
That there is no point in deciphering MENUNUM because there is only one Menu.
If a gadget is used to select your menu, make sure its highlight rendering is
set to GADGHNONE. Otherwise, it will change as the mouse pointer moves over
the menu, and when the menu is released, the section under the menu will not
have changed, leaving a unsightly blemish.
INPUTS
Window
Pointer to window to display the menu in.
Menu
Pointer to an Intuition style Menu list. Only the first Menu in the
list will be used.