Managing scripts in a FLA file

If you don't centralize all your code within a FLA file in one location, you can pin (lock in place) multiple scripts in the Actions panel to make it easier to move among them. In the following figure, the script associated with the current location on the Timeline is on Frame 1 of the layer named Cleanup. (The tab at the far left always follows your location along the Timeline.) That script is also pinned (it is shown as the rightmost tab). Two other scripts are pinned; one on Frame 1 and the other on Frame 15 of the layer named Intro. You can move among the pinned scripts by clicking on the tabs or by using keyboard shortcuts. Moving among pinned scripts does not change your current position on the Timeline.

Tip: If the content displayed in the Script pane isn't changing to reflect the location that you are selecting on the Timeline, the Script pane is probably displaying a pinned script. Click the leftmost tab at the lower left of the Script pane to display the ActionScript associated with your location along the Timeline.

To pin a script:

  1. Position your pointer on the Timeline so the script appears in a tab at the lower left of the Script pane in the Actions panel.
  2. Do one of the following:
    • Click the pushpin icon to the right of the tab. (If the pushpin looks like the icon at the far left, the script is already pinned; clicking that icon unpins it.)
    • Right-click (Windows) or Control-click (Macintosh) on the tab, and select Pin Script.
    • Select Pin Script from the Options pop-up menu (at the upper right of the panel).

To unpin one or more scripts:

To use keyboard shortcuts with pinned scripts: