| Previous | Next | |
Windows: Not Yet Available
Macintosh: Flash 8 or 9 AS2.0 SWF + mProjector
1.0;
mMenu.addWebLinkToMenu(description:String, URL:String[, menuName:String]) : Voiddescription - Description of the menu item to add.
URL - URL
menuName - Optional; Menu to which item will be added.
Specify nothing or "Right Click Menu" to modify the right-click menu (or cntl-click menu for systems using a single button mouse).
Specify "File", "Edit", "Window", and "ApplicationName" to modify the default Mac application menus.
Nothing.
Method; This command adds a menu item to a custom menu.If the user selects the menu item, mProjector will open a browser to the associated URL. Specify "File", "Edit", "Window", and "ApplicationName" to modify the default Mac menus.
The following code adds a link to online documentation to a menu of a "standard" type Macintosh application.
mMenu.createMenu("Help"); mMenu.addWebLinkToMenu("Online Documentation", "www.screentime.com/help/", "Help"); mMenu.addMenuToMenuBar("Help");This functionality can implemented using the additem method and the onCommand event handler. USing addItem is the prefered implementation method as it will tend to lead to a better cross-platform implemenation.
The following code implements a link to online docs in the Mac/Windows right-click menu and in the Mac application's Help menu.
mMenu.addItem("Online Documentation"); if (mSystem.isMac()) { mMenu.createMenu("Help"); mMenu.addItem("Online Documentation", "Help"); mMenu.addMenuToMenuBar("Help"); } // handle user selections mMenu.onCommand = function (menuName, itemName) { switch (itemName) { case "Online Documentation": mSystem.openDocument("http://www.screentime.com/software/mprojector/docs/"); break; } }
mProjector Class Basics -- mMenu
| Questions or Feedback? | Previous | Next |