bugGnash - The GNU Flash player - Bugs: bug #18864, action execution order problem

 
 

bug #18864: action execution order problem

Submitted by:  Zou Lunkai <zoulunkai>
Submitted on:  Wed 24 Jan 2007 09:36:42 AM UTC  
 
Category: ActionScriptSeverity: 3 - Normal
Release: NoneStatus: Fixed
Privacy: PublicAssigned to: Zou Lunkai <zoulunkai>
Open/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Thu 10 Jan 2008 01:23:12 AM UTC, comment #17:

Agree. I think actions order in Gnash is not that critical as before now. Most of them in our testsuite have been fixed. The last one for me is onClipConstruct events order when jumping back. They seem to be dependent on depth order instead of creation order(pp bug?). And I cann't see any urgency to be compatible at this point. We'll come back untill any new report from real swfs.

BTW, "action execution order" in general is big topic. But all tests discussed in this item have been fixed. So I'll close it.

Zou Lunkai <zoulunkai>In charge of this item.
Wed 09 Jan 2008 11:30:09 AM UTC, comment #16:

Zou, can we close this bug and eventually open one for each specific action execution order problem instead ?

Sandro Santilli <strk>
Project Member
Thu 08 Mar 2007 01:36:42 PM UTC, comment #15:

Please refer to the Wiki for further inspection of
a correct model to implement in Gnash:

http://gnash.lulu.com/wiki/index.php/ActionsExecutionOrder

We really want to design this in a sane way.

Sandro Santilli <strk>
Project Member
Thu 08 Mar 2007 06:01:47 AM UTC, comment #14:

Based on the discussion yestoday and some more tests today:

(1)Within the same frame, all action scripts in DoAction tags can reference all movieClips placed before or after the DoAction tags. Tested!

(2)If PlaceObject(mc1) is before PlaceObject(mc2), then actions in mc1 should be executed before actions in mc2. Otherwise, after mc2. Tested!

(3)if PlaceObject is after DoAction, then OnLoad is also called after executing actionscripts in DoAction; if RemoveObject is after DoAction, then OnUnload is also called after executing actionscripts in DoAction. Otherwise before DoAction. Tested!

(4)how is the order of onEnterFrame(and other events) determined? Still not so sure.

Zou Lunkai <zoulunkai>In charge of this item.
Tue 06 Mar 2007 08:25:40 AM UTC, comment #13:

Clip event is invoked too.. see the check_equals(y1bis, ...) line.
You just don't see a trace of it, which is likely related to the Dejagnu.swf code not been run yet.

As for Ming, I've actually committed a patch to make the output
neater, but I never saw it choking. What would you expect which
is not matched ?

Sandro Santilli <strk>
Project Member
Tue 06 Mar 2007 03:07:17 AM UTC, comment #12:

> I added "clip" even ONLOAD for mc_red and this triggers both
> clip event and user defined event to be invoked.

Yes, user events is invoked, but the clip event is not triggered here.

> Note that ming's 'listswf' ouput a weird form so I'm not sure
> wheter we're also facing a Ming bug here.

I can confirm here Ming does not compile it correctly. 'listswf' and some other tools could not either list or decompile the produced swf as expected.

Zou Lunkai <zoulunkai>In charge of this item.
Mon 05 Mar 2007 03:05:56 PM UTC, comment #11:

I added "clip" even ONLOAD for mc_red and this triggers both clip event and user defined event to be invoked. Left mc_blue alone to show that absence of the clip event prevents the user-defined event from happening.
Note that ming's 'listswf' ouput a weird form so I'm not sure wheter we're also facing a Ming bug here. In any case we
should mimic whatever the reference player does so not a big deal.

Sandro Santilli <strk>
Project Member
Mon 05 Mar 2007 02:36:21 PM UTC, comment #10:

Sorry, I do now see that onLoad is NOT called and NOT expected to be called. will do some research about it.

Sandro Santilli <strk>
Project Member
Mon 05 Mar 2007 02:31:13 PM UTC, comment #9:

It seems by your committed testcase that mc_red.onLoad is executed, but _root.note() is undefined at that time, does this sound ?

Sandro Santilli <strk>
Project Member
Fri 02 Mar 2007 09:36:44 AM UTC, comment #8:

>>New testcase is ready. I will commit it tomorrow. I am trying >>to understand it first and then give a detailed description.

To myself: I need more time to understand it, so I cann't commit it today.

Zou Lunkai <zoulunkai>In charge of this item.
Fri 02 Mar 2007 08:40:55 AM UTC, comment #7:

I am really confused by my new testcase.
Anyhow, just attach it here, both the source and the swf files.
The execution order will print to the screen while playing the swf, isn't it confusing?:(

[1]why mc_red.onLoad is not called?
[2]why mc_red.onUnload is called after executing actions in main timeline? I have read some reference that it should be call before executing the actions in main timeline, and I do have a testcase to "verify" this.

strk, can you try this testcase and compare the outputs with Gnash?

(file #12087, file #12088)

Zou Lunkai <zoulunkai>In charge of this item.
Thu 01 Mar 2007 09:27:45 AM UTC, comment #6:

New testcase is ready. I will commit it tomorrow. I am trying to understand it first and then give a detailed description.

Zou Lunkai <zoulunkai>In charge of this item.
Thu 01 Mar 2007 01:27:55 AM UTC, comment #5:

I am back to work on this again. Maybe provide some new testcases later.

Zou Lunkai <zoulunkai>In charge of this item.
Fri 09 Feb 2007 11:38:10 AM UTC, comment #4:

As we discussed in IRC, I suggest we drop the m_on_event_load_called flag and use the new ::construct
method to separate what happens in first frame and
what happens in subsequent frames.

Sandro Santilli <strk>
Project Member
Fri 09 Feb 2007 09:48:38 AM UTC, comment #3:

To fix action execution order, I need to make use of the 'm_on_event_load_called' flag. To use this flag, I need to properly set and reset it. Current Gnash never reset this flag and I am not so sure where to do it either. Before going further to fix this bug, I need to make 'm_on_event_load_called' work properly.

'm_on_event_load_called' is set while a movieClip has been loaded, and need to be reset after the movieClip has been unloaded(eg. be removed by tag or AS).

Zou Lunkai <zoulunkai>In charge of this item.
Tue 30 Jan 2007 10:40:23 AM UTC, comment #2:

Zou, youre working on this too, right ?

Sandro Santilli <strk>
Project Member
Wed 24 Jan 2007 10:51:23 AM UTC, comment #1:

To fix the goto_frame_test and this testcase and some undetected bugs, we may need to do sth. more to make the movie control(go back, go forward, loop back, etc.) robust.

Zou Lunkai <zoulunkai>In charge of this item.
Wed 24 Jan 2007 09:36:42 AM UTC, original submission:

Attached file: action_execution_order_test.c
A testcase for testing the execution order of actions distributed in different movieClips and roots.

Right now, the testcase do something as follows:
//_root has 2 frames, mc_red is a movieClip of 2 frames under
//_root, mc_red is placed at the 1st frame of _root

//at the 1st frame of _root
var x1 = "as_in_root";

//at the 1st frame of a mc_red
_root.x1 = "as_in_mc_red";

//at the 2nd frame of _root
var x2 = "as_in_root";

//at the 2nd frame of mc_red
_root.x2 = "as_in_mc_red";

After the execution of both the 2 frames, the right results of x1 and x2 are:
x1 = "as_in_mc_red"; x2 = "as_in_root";
while Gnash gets:
x1 = "as_in_mc_red"; x2 = "as_in_mc_red";

To test the runtime execution order, I will make the testcase more complex in future.

Zou Lunkai <zoulunkai>In charge of this item.

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #12088:  action_execution_order_extends_test.swf added by zoulunkai (12KiB - application/x-shockwave-flash)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by strk (Posted a comment)
  • -unavailable- added by zoulunkai (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 8 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Thu 10 Jan 2008 01:23:12 AM UTCzoulunkaiStatusIn Progress=>Fixed
      Open/ClosedOpen=>Closed
    Fri 02 Mar 2007 08:40:55 AM UTCzoulunkaiAttached File-=>Added action_execution_order_extend_test.c, #12087
      Attached File-=>Added action_execution_order_extends_test.swf, #12088
    Tue 30 Jan 2007 10:40:23 AM UTCstrkStatusNone=>In Progress
      PrivacyPrivate=>Public
      Assigned toNone=>zoulunkai
    Wed 24 Jan 2007 09:36:42 AM UTCzoulunkaiAttached File-=>Added action_execution_order_test.c, #11833

    Back to the top


    Powered by Savane 3.1-cleanup1