Adobe Extending Flash Professional CS5 Manuale Utente Pagina 343

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 565
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 342
321
EXTENDING FLASH PROFESSIONAL
Layer object
Last updated 5/2/2011
var frameArray = fl.getDocumentDOM().getTimeline().layers[0].frames;
var n = frameArray.length;
for (i=0; i<n; i++) {
if (i==frameArray[i].startFrame) {
alert("Keyframe at: " + i);
}
}
layer.height
Availability
Flash MX 2004.
Usage
layer.height
Description
Property; an integer that specifies the percentage layer height; equivalent to the Layer height value in the Layer
Properties dialog box. Acceptable values represent percentages of the default height: 100, 200, or 300.
Example
The following example stores the percentage value of the first layer’s height setting:
var layerHeight = fl.getDocumentDOM().getTimeline().layers[0].height;
The following example sets the height of the first layer to 300 percent:
fl.getDocumentDOM().getTimeline().layers[0].height = 300;
layer.layerType
Availability
Flash MX 2004.
Usage
layer.layerType
Description
Property; a string that specifies the current use of the layer; equivalent to the Type setting in the Layer Properties dialog
box. Acceptable values are
"normal", "guide", "guided", "mask", "masked", and "folder".
Example
The following example sets the first layer in the timeline to type folder:
fl.getDocumentDOM().getTimeline().layers[0].layerType = "folder";
Vedere la pagina 342
1 2 ... 338 339 340 341 342 343 344 345 346 347 348 ... 564 565

Commenti su questo manuale

Nessun commento