Adobe 38040334 - Dreamweaver CS3 User Manual page 228

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

Advertisement

The
selectionChanged()
Model (DOM) for the user's document. It then calls the
that document is, first, an element and, second, a
function makes the
selectionChanged()
JavaScript code. It also sets the
following figure shows the
If the selected node is not an element, or it is not a
floating panel visible and hides the
blanklayer
text
(no script selected)
To add the selectionChanged() function:
Open the file scriptEditor.htm that is in the Configuration/Floaters folder.
1
2
Enter the following code in the header section of the file.
function selectionChanged(){
/* get the selected node */
var theDOM = dw.getDocumentDOM();
var theNode = theDOM.getSelectedNode();
/* check to see if the node is a script marker */
function first calls the
dw.getDocumentDOM()
SCRIPT
scripteditor
property of the
visibility
floating panel with the selected JavaScript code:
scriptlayer
script
scriptlayer
, as shown in the following figure:
function to get the Document Object
function to see if the selected node for
getSelectedNode()
tag. If both these conditions are true, the
floating panel visible and loads it with the underlying
floating panel to the value
blanklayer
tag, the
selectionChanged()
panel. The
blanklayer
DREAMWEAVER CS3
Extending Dreamweaver
. The
hidden
function makes the
floating panel displays the
222

Advertisement

Table of Contents
loading

This manual is also suitable for:

Dreamweaver cs3

Table of Contents