Extending Flash |
|
|
|
| Objects > Timeline object > timeline.setSelectedLayers() | |||
Flash MX 2004.
timeline.setSelectedLayers(index[,bReplaceCurrentSelection])
index A zero-based index for the layer to select.
bReplaceCurrentSelection A Boolean value that, if it is set to true, causes the method to replace the current selection; false causes the method to extend the current selection. The default value is true. This parameter is optional.
Nothing.
Method; sets the layer to be selected, and also makes the specified layer the current layer. Selecting a layer also means that all the frames in the layer are selected.
The following example selects the top layer:
fl.getDocumentDOM().getTimeline().setSelectedLayers(0);
The following example adds the next layer to the selection:
fl.getDocumentDOM().getTimeline().setSelectedLayers(1, false);
|
|
|
|