[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnash-dev] ASHandlers vs action.cpp

From: strk
Subject: Re: [Gnash-dev] ASHandlers vs action.cpp
Date: Wed, 21 Jun 2006 18:03:48 +0200

On Wed, Jun 21, 2006 at 09:11:23AM -0600, Rob Savoye wrote:
> strk wrote:
> > The Action handlers must have access to the
> > program counters in a few situations and the
> > new layout doesn't give them visibility of
> > them.
>   The cases were it needed to access the program counter I didn't
> implement yet for this very reason. I mostly was just glad to move a
> very long switch/case statement to it's own file.
> > The cases are ActionReturn, BranchIfTrue and
> > friends. Should we make the program counters
> > part of the action_buffer class and pass a
> > reference to it to SWFHandlers in addition
> > to the reference to the as_environment ?
>   Probably. The goal though was to fix how the PC is handled so we can
> execute a stream while it's being loaded, instead of waiting till an
> entire file is loaded.

The PC should only makes sense within a single frame.
For the streaming to work we should call advance whenever
a NextFrame block is found in the SWF. The advance function
would then execute the action_buffer associated with the
current frame, which should be pretty independent from 
the action blocks in other frames (yes, they still share
the environment, but not a stack). At the end of each
action_buffer execution the local stack call stack
should be empty.

Let me know if the above does not sound correct.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]