Adobe Extending Flash Professional CS4 Instrukcja Użytkownika Strona 509

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 560
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 508
487
EXTENDING FLASH CS4 PROFESSIONAL
Timeline object
Description
Method; sets the property of the Frame object for the selected frames.
Example
The following example assigns the ActionScript stop() command to the first frame of the top layer in the current
document:
fl.getDocumentDOM().getTimeline().currentLayer = 0;
fl.getDocumentDOM().getTimeline().setSelectedFrames(0,0,true);
fl.getDocumentDOM().getTimeline().setFrameProperty("actionScript", "stop();");
The following example sets a motion tween from Frame 2 up to, but not including, Frame 5, of the current layer
(remember that index values are different from frame number values):
var doc = fl.getDocumentDOM();
doc.getTimeline().setFrameProperty("tweenType","motion",1,4);
timeline.setGuidelines()
Availability
Flash CS4 Professional.
Usage
timeline.setGuidelines(xmlString)
Parameters
xmlString An XML string that contains information on the guidelines to apply.
Returns
A Boolean value of true if the guidelines are successfully applied; false otherwise.
Description
Method: replaces the guide lines for the timeline (View > Guides > Show Guides) with the information specified in
xmlString. To retrieve an XML string that can be passed to this method, use
timeline.getGuidelines().
To view the newly set guide lines, you may have to hide them and then view them.
Example
The following example applies the guide lines from one FLA file to another FLA file:
var doc0 = fl.documents[0];
var guides0 = doc0.timelines[0].getGuidelines();
var doc1 = fl.documents[1];
doc1.timelines[0].setGuidelines(guides0);
Przeglądanie stron 508
1 2 ... 504 505 506 507 508 509 510 511 512 513 514 ... 559 560

Komentarze do niniejszej Instrukcji

Brak uwag