Dynamic Popups
This demonstration shows how popup menus can be linked to an array and display the current item, as well as being further customised by dynamically setting the icon displayed in the popup.
Creating this demonstrate requires very little code. First you just declare the text array to be displayed in the popup, then add the popup to the toolbar and associate the array with it. The popup menu will display without writing any additional code and the popup text in the toolbar will also dynamically update. To update the icon, the onPopupMethod can be called after the user selects and item and can set the icon based on the user selection.
|