Adobe Extending Dreamweaver CS4 Manuel d'utilisateur Page 171

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 387
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 170
165
EXTENDING DREAMWEAVER CS4
Menus and menu commands
setMenuText()
Description
Specifies the text that should appear in the menu.
Note: Do not use this function if you are using getDynamicContent()” on page 162.
Arguments
{arg1}, {arg2},...{argN}
If the arguments attribute is defined for a menuitem tag, the value of that attribute passes to the setMenuText()
function (and to the
canAcceptCommand()” on page 162, “isCommandChecked()” on page 163, and
receiveArguments()” on page 164 functions) as one or more arguments. The arguments attribute is useful for
distinguishing between two menu items that call the same menu command.
Returns
Dreamweaver expects the string that should appear in the menu.
Example
function setMenuText()
{
if (arguments.length != 1) return "";
var whatToDo = arguments[0];
if (whatToDo == "undo")
return dw.getUndoText();
else if (whatToDo == "redo")
return dw.getRedoText();
else return "";
}
windowDimensions()
Description
Sets specific dimensions for the Parameters dialog box. If this function is not defined, the window dimensions are
computed automatically.
Note: Do not define this function unless you want a dialog box that is larger than 640 x 480 pixels.
Arguments
platform
The value of the platform argument is either "macintosh" or "windows", depending on the user’s platform.
Returns
Dreamweaver expects a string of the form "widthInPixels,heightInPixels".
The returned dimensions are smaller than the size of the entire dialog box because they do not include the area for the
OK and Cancel buttons. If the returned dimensions do not accommodate all options, scroll bars appear.
Vue de la page 170
1 2 ... 166 167 168 169 170 171 172 173 174 175 176 ... 386 387

Commentaires sur ces manuels

Pas de commentaire