Adobe Extending Flash Professional CS5 Uživatelský manuál Strana 314

  • Stažení
  • Přidat do mých příruček
  • Tisk
  • Strana
    / 565
  • Tabulka s obsahem
  • KNIHY
  • Hodnocené. / 5. Na základě hodnocení zákazníků
Zobrazit stránku 313
292
EXTENDING FLASH PROFESSIONAL
Frame object
Last updated 5/2/2011
frame.isMotionObject()
Availability
Flash Professional CS5.
Usage
Frame.isMotionObject()
Description
Method; a Boolean value. Lets you know whether the current selection is a motion object.
Example
The following example returns a trace statement informing you that the current selection is or is not a motion object.
var my_tl = doc.getTimeline() ;
this.getCurrentFrame = function(){
var layer = my_tl.layers[my_tl.currentLayer];<
var frame = layer.frames[my_tl.currentFrame];
return frame;
}
var theFrame = getCurrentFrame();
if(theFrame.isMotionObject()) {
fl.trace("This selection is motion.");
}else{
fl.trace("This selection is not motion.");
}
frame.labelType
Availability
Flash MX 2004.
Usage
frame.labelType
Description
Property; a string that specifies the type of Frame name. Acceptable values are "none", "name", "comment", and
"anchor". Setting a label to "none" clears the frame.name property.
Example
The following example sets the name of the first frame in the top layer to "First Frame" and then sets its label
to
"comment":
fl.getDocumentDOM().getTimeline().layers[0].frames[0].name = 'First Frame';
fl.getDocumentDOM().getTimeline().layers[0].frames[0].labelType = 'comment';
Zobrazit stránku 313
1 2 ... 309 310 311 312 313 314 315 316 317 318 319 ... 564 565

Komentáře k této Příručce

Žádné komentáře