Adobe 38040334 - Dreamweaver CS3 User Manual page 317

Extending dreamweaver
Hide thumbs Also See for 38040334 - Dreamweaver CS3:
Table of Contents

Advertisement

getContextMenuId()
Availability
Dreamweaver MX.
Description
Returns the Context Menu ID for the component type. Every component type can have a context menu associated
with it. The Context Menu pop-up menus are defined in the ComponentNameMenus.xml file, and they work the
same way as the menu.xml file. The menu string can be static or dynamic. Shortcut keys (accelerator keys) are
supported.
Arguments
None.
Returns
A string defining the Context Menu ID.
Example
The following example sets the menu options for the Components panel for web services associated with the
ASP.NET/C# server model and defines the shortcut keys for that menu:
function getContextMenuId()
{
return "DWWebServicesContext";
}
Where DWWebServicesContext is defined in the file in the Configuration/Compo-
nents/ASP.NET_CSharp/WebServices/WebServicesMenus.xml as follows:
<shortcutlist id="DWWebServicesContext">
<shortcut key="Del" domRequired="false"
enabled="(dw.serverComponentsPalette.getSelectedNode() != null &&
(dw.serverComponentsPalette.getSelectedNode().objectType=='Root'))"
command="clickedDelete();" id="DWShortcuts_ServerComponent_Delete" />
</shortcutlist>
<menubar name="" id="DWWebServicesContext">
<menu name="Server Component Popup" id="DWContext_WebServices">
<menuitem name="Edit Web Service" domRequired="false"
enabled="dw.serverComponentsPalette.getSelectedNode() != null &&
(dw.serverComponentsPalette.getSelectedNode().objectType=='Root') &&
dw.serverComponentsPalette.getSelectedNode().wsRec != null &&
dw.serverComponentsPalette.getSelectedNode().wsRec.ProxyGeneratorName != null"
command="editWebService()" id="DWContext_WebServices_EditWebService" />
...
</menubar>
getCodeViewDropCode()
Availability
Dreamweaver MX.
DREAMWEAVER CS3
311
Extending Dreamweaver

Advertisement

Table of Contents
loading

This manual is also suitable for:

Dreamweaver cs3

Table of Contents