Opened 18 years ago

Closed 13 years ago

#1696 closed defect (fixed)

using generated swf with mtasc — at Version 7

Reported by: make001@… Owned by: mapserverbugs
Priority: high Milestone:
Component: Output-SWF Version: unspecified
Severity: normal Keywords:
Cc:

Description (last modified by tbonfort)

Hello,
i think this not a real bug, it is a wish. I want to load the main swf
FMV_11407989632520.swf with load msSWF.loadMovie() and he loads this swf and 
then the other layer swf in the _level (_level1 to _levelx). I have no chance 
to load only the one FMV_11407989632520.swf and then load the layers by my 
application. Can you add a flag to the map file that the generated swf do not 
load the layer automaticaly in the _levels.
bye
Mahmut

Change History (9)

comment:1 by make001@…, 18 years ago

Hello,
i have another idea, to solve this problem. AS2 has a Class Named 
MovieClipLoader. I can set a callback to 'onLoadComplete'. if loading is done
i can call 'stop'. But this solution need that the main swf work with frames.
That isn't implement in the main swf.
Sample:
myMCL.onLoadComplete = function(){
  _level0.mydump2.text += "onLoadComplete\n";
  _root.msSWF.stop();
  _root.msSWF.nextFrame();
  _level0.mydump2.text += "1\n";
  for (var i in _root.msSWF) {
    _level0.mydump2.text += i +"\n";
  }
}

Can you add a nextFrame before loading the Layers.

Or another question: If i want to change the sources, how can i give you the 
changes.

bye
Mahmut


comment:2 by assefa, 18 years ago

You can submit your patchs through bugzilla (usuually  diff between the cvs
version and your version should be enough).  I will then apply your changes.
Make sure that you changes adress your problems without modifying the current
behaviour (which is to load all the movies).

by make001@…, 18 years ago

Attachment: mapswf.c added

implementing pool for loadmovienum

comment:3 by make001@…, 18 years ago

Hello Assefa,
i have send you an email with the changes. Is there anything wrong.
I have made a buffer in which i store the actions for loadmovienum.
Then i add a nextframe command. Finaly i add the the loadmovie actions.

Is there any problem? I couldn't test it because i have not a vc++ and all 
libs, that i need for compilation. I have test is at work a sun workstation.

I think you are too busy. I put my changes as an attachment. I you have any 
time, i hope put my chances to the cvs.
thanx
bye
Mahmut Keygubatli


by make001@…, 18 years ago

Attachment: mapserverswf.PNG added

current version of my mtasc Viewer

comment:4 by assefa, 18 years ago

 Mahmut

 Sorry about the delay. I have just checked your changes. I have a comment
though : if I apply it as is, It would I think modify the current behaviour
which is to load all the layers automatically.  Is that the case ?  I think that
the best would be to do the changes inside an option format that can be added to
a map file (we can call it DELAY_LOAD or anything that we feel is appropriate).
You would then add you code inside an if that looks like this :
if(strcasecmp(msGetOutputFormatOption(image->format,"DELAY_LOAD",""), "Yes") == 0)
{
...
}

 What do you think ?

comment:5 by make001@…, 18 years ago

Hello 

my patch dosn't modify the current behaviour. But of the Flash AS2 side, i 
must put an event to stop the movie. I think it is a bad solution. It looks 
like a hack. The best Solution is to put an Information which doesn't load the 
layer. So 'DELAY_LOAD' in the mapfile is the better way.
The attribute "DELAY_LOAD" isn't right. Better is an attribute 
like 'LOAD_LAYER = Yes' or 'LOAD_AUTOMATICALLY = Yes'. That is by default 
of "true". If the Admin wouldn't load_automatically he can set it to no, so 
Mapserver computes 'our' process. Isn't it?
if(strcasecmp(msGetOutputFormatOption(image-
>format,"LOAD_AUTOMATICALLY",""), "No") == 0)
{
...
}


bye
Mahmut

comment:6 by assefa, 18 years ago

Added patch sent by Keygubatli, Mahmut. Thanks.

Format option is  FORMATOPTION "LOAD_AUTOMATICALLY=OFF".

Mahmut, please test it and confirm. I will then send it for this option to be 
added in the docuementation.

comment:7 by tbonfort, 13 years ago

Description: modified (diff)
Resolution: fixed
Status: newclosed

seems fixed. closing anyway because flash support is now dropped.

Note: See TracTickets for help on using tickets.