Toolbar_SetPulldownMenu

int Toolbar_SetPulldownMenu (toolbarType toolbar, int index, int menuBar, int menu);

Purpose

Associates a pulldown menu toolbar item with a menu. Call this function after you insert a toolbar item of type kPicturePulldownMenu or kTextPulldownMenu.

Parameters

Input
Name Type Description
toolbar ToolbarType The specifier for the toolbar that contains the item.

Obtain this handle from the Toolbar_New or Toolbar_Duplicate functions.
index integer The index of the pulldown menu control that you are associating with a menu.

Valid index values are from 1 to one more than the number of items on the toolbar, as returned by Toolbar_GetNumItems. You also can use Toolbar_GetIndexFromDescription to obtain the index of the pulldown menu control.
menuBar integer The handle of the menu bar that contains the menu you want to associate with the pulldown menu control.
menu integer The menu ID of the menu you want to associate with the pulldown menu control.

Return Value

Name Type Description
status integer Return value indicating whether the function was successful. A negative number indicates that an error occurred.