Re: [Flashcoders] Flash 8, AS 2.0. I want to use symbols from child movie in parent movie. Possible?

2008-01-29 Thread Deepanjan Das
Hi,
You can use runtime shared libraries for this case I guess.
You have the symbols in smiles.swf. go to the library and for each symbol
define the linkage and set it to Export for runtime sharing.

Then open the main movie and do Import>Open External Library and drag the
icon on stage and delete it
Now you can use those symbols in main movie.

Hope this helps

Deepanjan Das

On Jan 29, 2008 10:03 PM, Donald Trump <[EMAIL PROTECTED]> wrote:

> Hey!
>
> Suppose I load an SWF that contains symbols inside the main movie. Let it
> be smiles for
> chat application - smiles.swf.
> Then I want to instantiate some of these symbols putting them on the main
> movie _root.
> That is essential, I want to add the instances to the main movie _root or
> _root's
> descendants.
> Is it possible with Flash 8?
>
> I have made some experiments and have come to conlusion that Flash allows
> to create
> symbol instances only inside the movie that the symbol is coming from.
> Am I right?
>
> Well, I know one workaround - to paint a symbol to a bitmap and add this
> bitmap to the
> main movie. However in my application I deal with interactive symbols not
> the smile
> bitmaps, so this approach doesn't work for me.
>
>
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


=?koi8-r?Q?Fw=3A_Re[2]=3A_[Flashcoders]_Flash_8, _AS_2.0._I_want_to_use_symbols_from_child_movie_in_parent_movie._Possible=3F?=

2008-01-29 Thread Donald Trump
Hans, you have strengthen my grief :(
And bitmap animation won't help either in my case.
 
Thanks anyway!

> > 
> > Hi,
> > 
> > you've answered your own question I'm afraid.

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


RE: [Flashcoders] how to return in this function

2008-01-29 Thread Claudio M. E. Bastos Iorio
Thanks Juan Pablo for your response. I have some logic related to the XML in
the class, so it makes sense (to me at least) to encapsulate the xml loading
in this class.

(remember I'm trying to access the xml in the fla file in this way):
var mivariable:retornaXML = new retornaXML();
trace(mivariable.elXML);//returns null

Right now, I'm trying something like this:

package {
import flash.net.URLRequest;
import flash.net.URLLoader;
import flash.events.*;
import flash.events.ProgressEvent;
public class retornaXML {
private var _xml:XML;
private var xmlloaded:Boolean = false;
public function retornaXML() {
cargarXML();
}
private function cargarXML():void {
var loader:URLLoader = new URLLoader();
loader.addEventListener(Event.COMPLETE, xmlLoaded);

loader.load(new URLRequest("LocalData.xml"));
}
private function xmlLoaded(e:Event):void {
_xml = new XML(e.target.data);
xmlloaded = true;
//XML IS LOADED HERE.

}


public function get elXML():XML {
if (xmlloaded) {
trace("XML IS LOADED");
return _xml;
} else {
trace("XML IS NOT LOADED");
return ??;//WHAT CAN I USE AT THIS POINT TO
CALL THIS METHOD AGAIN TO CHECK IF xmlloaded IS TRUE? (IF XML IS LOADED).
ANY OTHER IDEA? 
}
}
}
}

Thanks in advance.


Claudio M. E. Bastos Iorio
http://www.blumer.com.ar

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Juan Pablo
Califano
Sent: Tuesday, January 29, 2008 10:37 PM
To: Flash Coders List
Subject: Re: [Flashcoders] how to return in this function

>> > var mivariable:retornaXML = new retornaXML();
>> > trace(mivariable.elXML);
>> > but this trace returns null, since the xml file (I think) is not loaded
>> > yet.

Yes, that's the problem. In Flash, xml loading is always asynchronous so the

trace line is executed immediately after the previous one, in which you 
created an instance of retornaXML; so the XML object isn't at that point 
loaded and parsed. (It would perhaps be nice to have the option of loading 
synchronously, but I digress...).

So, you'll have to listen to the COMPLETE event dispatched by the URLLoader 
and then access the xml object.

You can wrap your xml and the loading logic in a custom class as you seem to

be doing so far, but if you're just going to load the xml and the read it / 
parse it somewhere else (outside that class), in my humble opinion, the 
wrapper is pointless.

You'll end up re-dispatching the Loader events (all the events you want to 
support; the error events, and the complete event, at least, just in case 
something went wrong, and perhaps the Progress event as well) so your 
external code can handle the different scenarios. By the time you are done 
coding that, you'll find that you have a class that does almost nothing of 
use by itself; it just copies all the functionality that you already had in 
the URLLoader and XML classes out of the box. I did it a couple of times 
when I started to use AS 3.0, but I changed my approach as it didn't make 
much sense to me to have such a class. Having all that logic encapsulated in

the class that actually does something with the xml, on the other hand, 
seems like a good idea to me.

Cheers
Juan Pablo Califano

- Original Message - 
From: "Hans Wichman" <[EMAIL PROTECTED]>
To: "Flash Coders List" 
Sent: Tuesday, January 29, 2008 7:30 PM
Subject: Re: [Flashcoders] how to return in this function


> seems like an item for the newbie list tbh:)
>
> On Tue, Jan 29, 2008 at 8:27 PM, Claudio M. E. Bastos Iorio <
> [EMAIL PROTECTED]> wrote:
>
>> Thanks for your answer. But how? Where?. I think that
>> ProgressEvent.bytesLoaded, and ProgressEvent.bytesTotal could help. But
>> where should I check the status?
>>
>> 
>> Claudio M. E. Bastos Iorio
>> http://www.blumer.com.ar
>>
>>  -Original Message-
>> From: [EMAIL PROTECTED] [mailto:
>> [EMAIL PROTECTED] On Behalf Of eric e. dolecki
>> Sent: Tuesday, January 29, 2008 4:07 PM
>> To: Flash Coders List
>> Subject: Re: [Flashcoders] how to return in this function
>>
>> you could use an event to listen to, to pass the XML out of the class.
>>
>> On Jan 29, 2008 1:42 PM, Claudio M. E. Bastos Iorio 
>> <[EMAIL PROTECTED]
>> >
>> wrote:
>>
>> > Hi guys, hope you can help me on this one.
>> >
>> > I have a class

Re: [Flashcoders] loadMovie from subdirectory - change base path

2008-01-29 Thread Deepanjan Das
Hi,
You need to keep duplicate files if you want it to work as single and also
when loaded from main movie.
Easiest way is to create an xml directory at the place where the main movie
resides and set the path as "xml/1.xml"

also copy this directory in the screens directory

so ths ame path will work for both :)
Hope this helps

Deepanjan Das

On Jan 30, 2008 10:10 AM, confusticate and bebother these dwarves! <
[EMAIL PROTECTED]> wrote:

> Hello Flashcoders,
>
> I'm trying to make a main movie ("controller.swf") that loads other movies
> ("screen1.swf", "screen2.swf", etc), which are stored in a subdirectory
> called "screens".
>
> In controller.swf I'm using loadMovie("screens/screenx.swf") to load the
> movies from the "screens" subdirectory, and this works fine. But the
> problem
> is that the movies in the "screens" subdirectory often reference XML files
> (which also live in the "screens" subdirectory). All works well when you
> play the individual screenx.swf files, obviously, but when you play
> controller.swf, it is looking for the XML files in the same directory as
> itself (one directory "up").
>
> How can I fix this problem so that playing controller.swf works fine, as
> well as playing each individual screenx.swf file in the "screens"
> subdirectory? Is this possible? It seems like such a simple idea, but I'm
> so
> stumped.
>
> I should mention that this project is not actually going online - it is
> going to be converted to an EXE using Zinc and distributed via CD. So I
> can't use absolute paths.
>
> Please! Heelp! Thanks!
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] loadMovie from subdirectory - change base path

2008-01-29 Thread confusticate and bebother these dwarves!
Hello Flashcoders,

I'm trying to make a main movie ("controller.swf") that loads other movies
("screen1.swf", "screen2.swf", etc), which are stored in a subdirectory
called "screens".

In controller.swf I'm using loadMovie("screens/screenx.swf") to load the
movies from the "screens" subdirectory, and this works fine. But the problem
is that the movies in the "screens" subdirectory often reference XML files
(which also live in the "screens" subdirectory). All works well when you
play the individual screenx.swf files, obviously, but when you play
controller.swf, it is looking for the XML files in the same directory as
itself (one directory "up").

How can I fix this problem so that playing controller.swf works fine, as
well as playing each individual screenx.swf file in the "screens"
subdirectory? Is this possible? It seems like such a simple idea, but I'm so
stumped.

I should mention that this project is not actually going online - it is
going to be converted to an EXE using Zinc and distributed via CD. So I
can't use absolute paths.

Please! Heelp! Thanks!
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] how to return in this function

2008-01-29 Thread Juan Pablo Califano

> var mivariable:retornaXML = new retornaXML();
> trace(mivariable.elXML);
> but this trace returns null, since the xml file (I think) is not loaded
> yet.


Yes, that's the problem. In Flash, xml loading is always asynchronous so the 
trace line is executed immediately after the previous one, in which you 
created an instance of retornaXML; so the XML object isn't at that point 
loaded and parsed. (It would perhaps be nice to have the option of loading 
synchronously, but I digress...).


So, you'll have to listen to the COMPLETE event dispatched by the URLLoader 
and then access the xml object.


You can wrap your xml and the loading logic in a custom class as you seem to 
be doing so far, but if you're just going to load the xml and the read it / 
parse it somewhere else (outside that class), in my humble opinion, the 
wrapper is pointless.


You'll end up re-dispatching the Loader events (all the events you want to 
support; the error events, and the complete event, at least, just in case 
something went wrong, and perhaps the Progress event as well) so your 
external code can handle the different scenarios. By the time you are done 
coding that, you'll find that you have a class that does almost nothing of 
use by itself; it just copies all the functionality that you already had in 
the URLLoader and XML classes out of the box. I did it a couple of times 
when I started to use AS 3.0, but I changed my approach as it didn't make 
much sense to me to have such a class. Having all that logic encapsulated in 
the class that actually does something with the xml, on the other hand, 
seems like a good idea to me.


Cheers
Juan Pablo Califano

- Original Message - 
From: "Hans Wichman" <[EMAIL PROTECTED]>

To: "Flash Coders List" 
Sent: Tuesday, January 29, 2008 7:30 PM
Subject: Re: [Flashcoders] how to return in this function



seems like an item for the newbie list tbh:)

On Tue, Jan 29, 2008 at 8:27 PM, Claudio M. E. Bastos Iorio <
[EMAIL PROTECTED]> wrote:


Thanks for your answer. But how? Where?. I think that
ProgressEvent.bytesLoaded, and ProgressEvent.bytesTotal could help. But
where should I check the status?


Claudio M. E. Bastos Iorio
http://www.blumer.com.ar

 -Original Message-
From: [EMAIL PROTECTED] [mailto:
[EMAIL PROTECTED] On Behalf Of eric e. dolecki
Sent: Tuesday, January 29, 2008 4:07 PM
To: Flash Coders List
Subject: Re: [Flashcoders] how to return in this function

you could use an event to listen to, to pass the XML out of the class.

On Jan 29, 2008 1:42 PM, Claudio M. E. Bastos Iorio 
<[EMAIL PROTECTED]

>
wrote:

> Hi guys, hope you can help me on this one.
>
> I have a class to load an XML file. I'm trying this:
>
>
>
>
> package {
>   import flash.net.URLRequest;
>   import flash.net.URLLoader;
>   import flash.events.*;
>   public class retornaXML{
>  private var _xml:XML;
>  public function retornaXML() {
> cargarXML();
>  }
>
>  private function cargarXML():void {
> var loader:URLLoader = new URLLoader();
> loader.addEventListener(Event.COMPLETE, xmlLoaded);
> loader.load(new URLRequest("LocalData.xml"));
>  }
>  private function xmlLoaded(e:Event):void {
> _xml = new XML(e.target.data);
> trace(_xml);
> //THE TRACE HERE WORKS PERFECT AND RETURNS THE XML
>
>  }
>  public function get elXML():XML {
> return _xml;
> //THIS RETURNS null
>  }
>
>   }
> }
>
>
>
> I want something like this:
>
>
>
> var mivariable:retornaXML = new retornaXML();
> trace(mivariable.elXML);
>
>
>
> but this trace returns null, since the xml file (I think) is not loaded
> yet.
> What should I do?
>
>
>
> Thanks in advance.
>
> 
>
> Claudio M. E. Bastos Iorio
>
>   http://www.blumer.com.ar
>
>
>
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders 


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] input text formatting

2008-01-29 Thread Andrew Sinning
Yes, that's exactly what I'm going ot have to do.  This has got to be a 
BUG.  If I trace out the format.align property after a single character 
change it goes from center to null!  Then after the user replaces all of 
the text it changes to left. 


Glen Pike wrote:
In AS3 I have to keep applying the TextFormat object to the TextField 
when it's content changes:


function createText():void {
   _nameText.setSelection(0, _nameText.text.length);
   //_nameText.caretIndex = 0;
   _nameText.setTextFormat(_nameFormat);
   addChild(_nameText);
   _nameText.addEventListener(Event.CHANGE, textChange);
}


private function textChange(evt:Event):void {
   _nameText.setTextFormat(_nameFormat);
}

Andrew Sinning wrote:
I'm creating an input-type TextField at runtime and setting the align 
prop of its TextFormat to 'center'.  The default text displays 
centered.  If the user edits just one character at a time the text 
remains centered.  However, if they select all of the text and then 
type something in, the align suddenly changes to 'left'.  Any idea 
what's going on?


Thanks!
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders






___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


RE: [Flashcoders] How to shorten the compile time?

2008-01-29 Thread development
Speed wise and AS 2.0 you should go 'intrinsic'. Create a DLL (shared lib)
where your main code resides in, then compile your views against that. I've
done that on a big project and even the Flash IDE outperforms MTASC with
this solution.

Check out asigen: http://osflash.org/asigen to generate you're intrinsic
libraries. 

For this solution you need a mind switch and a different way to set things
up. Forget about AS 3.0, at that level it's not getting better.

Yours, Sander


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Donald Trump
Sent: dinsdag 29 januari 2008 20:53
To: flashcoders@chattyfig.figleaf.com
Subject: [Flashcoders] How to shorten the compile time?

I'm at the final stages of my project.
The thing that I am bothered most now is compile time.

The project has evolved for the past couple of years into a large code base
of Action Script classes.
There are about 300 classes which is 1 MB of source code.
It takes about 20 seconds to compile the program.

I use MTASC compiler, and the IDE is Flash Develop.
As far as I see, there are no cache for compiled classes in MTASC, so it
does not matter whether I've changed one class in the project or all of them
the compiler would compile all the classes.

Native Flash compiler does compilation caching (to ASO files). But it takes
even more time to compile the project using Flash (65 seconds!).

Any ideas how to decrease compile time?

One way would be to break the code base in a number SWFs, compile them
separately and load at runtime. However now this task looks unreal because
of amount of the code base and its complexity.

I wonder if anyone uses this approach with the only purpose to shorten the
compile time of Action Script code.

My project is Action Script 2.0 based.
Maybe the right step is to move to AS 3.0?
Do you know whether this compile caching problem was solved in AS 3.0 Flash
and haXe compiler?


And by the way, which IDE/compiler do you use?
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] how to return in this function

2008-01-29 Thread Hans Wichman
seems like an item for the newbie list tbh:)

On Tue, Jan 29, 2008 at 8:27 PM, Claudio M. E. Bastos Iorio <
[EMAIL PROTECTED]> wrote:

> Thanks for your answer. But how? Where?. I think that
> ProgressEvent.bytesLoaded, and ProgressEvent.bytesTotal could help. But
> where should I check the status?
>
> 
> Claudio M. E. Bastos Iorio
> http://www.blumer.com.ar
>
>  -Original Message-
> From: [EMAIL PROTECTED] [mailto:
> [EMAIL PROTECTED] On Behalf Of eric e. dolecki
> Sent: Tuesday, January 29, 2008 4:07 PM
> To: Flash Coders List
> Subject: Re: [Flashcoders] how to return in this function
>
> you could use an event to listen to, to pass the XML out of the class.
>
> On Jan 29, 2008 1:42 PM, Claudio M. E. Bastos Iorio <[EMAIL PROTECTED]
> >
> wrote:
>
> > Hi guys, hope you can help me on this one.
> >
> > I have a class to load an XML file. I'm trying this:
> >
> >
> >
> >
> > package {
> >   import flash.net.URLRequest;
> >   import flash.net.URLLoader;
> >   import flash.events.*;
> >   public class retornaXML{
> >  private var _xml:XML;
> >  public function retornaXML() {
> > cargarXML();
> >  }
> >
> >  private function cargarXML():void {
> > var loader:URLLoader = new URLLoader();
> > loader.addEventListener(Event.COMPLETE, xmlLoaded);
> > loader.load(new URLRequest("LocalData.xml"));
> >  }
> >  private function xmlLoaded(e:Event):void {
> > _xml = new XML(e.target.data);
> > trace(_xml);
> > //THE TRACE HERE WORKS PERFECT AND RETURNS THE XML
> >
> >  }
> >  public function get elXML():XML {
> > return _xml;
> > //THIS RETURNS null
> >  }
> >
> >   }
> > }
> >
> >
> >
> > I want something like this:
> >
> >
> >
> > var mivariable:retornaXML = new retornaXML();
> > trace(mivariable.elXML);
> >
> >
> >
> > but this trace returns null, since the xml file (I think) is not loaded
> > yet.
> > What should I do?
> >
> >
> >
> > Thanks in advance.
> >
> > 
> >
> > Claudio M. E. Bastos Iorio
> >
> >   http://www.blumer.com.ar
> >
> >
> >
> > ___
> > Flashcoders mailing list
> > Flashcoders@chattyfig.figleaf.com
> > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
> >
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
>
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] input text formatting

2008-01-29 Thread Glen Pike
In AS3 I have to keep applying the TextFormat object to the TextField 
when it's content changes:


function createText():void {
   _nameText.setSelection(0, _nameText.text.length);
   //_nameText.caretIndex = 0;
   _nameText.setTextFormat(_nameFormat);
   addChild(_nameText);
   _nameText.addEventListener(Event.CHANGE, textChange);
}


private function textChange(evt:Event):void {
   _nameText.setTextFormat(_nameFormat);
}

Andrew Sinning wrote:
I'm creating an input-type TextField at runtime and setting the align 
prop of its TextFormat to 'center'.  The default text displays 
centered.  If the user edits just one character at a time the text 
remains centered.  However, if they select all of the text and then 
type something in, the align suddenly changes to 'left'.  Any idea 
what's going on?


Thanks!
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders




--

Glen Pike
01736 759321
www.glenpike.co.uk 
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] input text formatting

2008-01-29 Thread Andrew Sinning
I'm creating an input-type TextField at runtime and setting the align 
prop of its TextFormat to 'center'.  The default text displays 
centered.  If the user edits just one character at a time the text 
remains centered.  However, if they select all of the text and then type 
something in, the align suddenly changes to 'left'.  Any idea what's 
going on?


Thanks!
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


RE: [Flashcoders] mc code still runs after being removed...Huh?!?

2008-01-29 Thread Merrill, Jason
Did you clear out your ASO cache before compiling?  Did you clear your
browser cache before testing?

Jason Merrill
Bank of America  
GT&O L&LD Solutions Design & Development 
eTools & Multimedia 

Bank of America Flash Platform Developer Community



 

>>-Original Message-
>>From: [EMAIL PROTECTED] 
>>[mailto:[EMAIL PROTECTED] On Behalf 
>>Of Delmar Patton
>>Sent: Tuesday, January 29, 2008 3:02 PM
>>To: Flash Coders List
>>Subject: Re: [Flashcoders] mc code still runs after being 
>>removed...Huh?!?
>>
>>
>>___
>>Flashcoders mailing list
>>Flashcoders@chattyfig.figleaf.com
>>http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] mc code still runs after being removed...Huh?!?

2008-01-29 Thread Corban Baxter
was it possibly running a global function or method that needed to be
killed before it was removed?

On Jan 29, 2008 2:02 PM, Delmar Patton <[EMAIL PROTECTED]> wrote:
>
>
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>



-- 
Corban Baxter
http://www.projectx4.com
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] How to shorten the compile time?

2008-01-29 Thread strk
On Tue, Jan 29, 2008 at 10:53:29PM +0300, Donald Trump wrote:
> I'm at the final stages of my project.
> The thing that I am bothered most now is compile time.
...
> My project is Action Script 2.0 based.
> Maybe the right step is to move to AS 3.0?
> Do you know whether this compile caching problem was solved in AS 3.0 Flash 
> and haXe compiler?

You may also try Ming, should be faster.

--strk;
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


RE: [Flashcoders] How to shorten the compile time?

2008-01-29 Thread Merrill, Jason


Short of re-writing everything in Haxe (which may or may not help),
switching to AS3 (which might help), switching to Flexbuilder 3, and
chopping code down to smaller pieces (which would help some), you might
be doing all you can really do. 

>>And by the way, which IDE/compiler do you use?

FlashDevelop / Flex SDK or Flexbuilder 



Jason Merrill
Bank of America  
GT&O L&LD Solutions Design & Development 
eTools & Multimedia 

Bank of America Flash Platform Developer Community


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] mc code still runs after being removed...Huh?!?

2008-01-29 Thread Delmar Patton

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] How to shorten the compile time?

2008-01-29 Thread Donald Trump
I'm at the final stages of my project.
The thing that I am bothered most now is compile time.

The project has evolved for the past couple of years into a large code base of 
Action Script classes.
There are about 300 classes which is 1 MB of source code.
It takes about 20 seconds to compile the program.

I use MTASC compiler, and the IDE is Flash Develop.
As far as I see, there are no cache for compiled classes in MTASC, so it does 
not matter whether I've changed one class in the project or all of them the 
compiler would compile all the classes.

Native Flash compiler does compilation caching (to ASO files). But it takes 
even more time to compile the project using Flash (65 seconds!).

Any ideas how to decrease compile time?

One way would be to break the code base in a number SWFs, compile them 
separately and load at runtime. However now this task looks unreal because of 
amount of the code base and its complexity.

I wonder if anyone uses this approach with the only purpose to shorten the 
compile time of Action Script code.

My project is Action Script 2.0 based.
Maybe the right step is to move to AS 3.0?
Do you know whether this compile caching problem was solved in AS 3.0 Flash and 
haXe compiler?


And by the way, which IDE/compiler do you use?
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] Animating sprite.graphics.lineTo

2008-01-29 Thread Merrill, Jason

Tried on another Flash  list without any luck, so I'll try here.

I'm trying to see if there is a way to combine TweenLite and the draw
functions (i.e. sprite.graphics.lineto) to slowly draw a line from point
A to point B. Maybe there isn't, but I thought I would ask.  

Is it possible or would it have to be accomplished instead by drawing
slowly from point A to a point approaching B, then clearing, drawing
further, then clearning, etc. until the endpoint is reached? I'd like
to avoid that because it's 1) kludgy, 2) processor intensive, 3) time
consuming to code, 4) does not use easing (easily anyway), and 5) would
not look smooth. Any thoughts?

Oh, and any method suggested has to be done dynamically with the draw
API, not a timeline solution, since this is in regards to rendering a
dynamic graphic.  Thanks.



Jason Merrill
Bank of America  
GT&O L&LD Solutions Design & Development 
eTools & Multimedia 

Bank of America Flash Platform Developer Community


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


RE: [Flashcoders] how to return in this function

2008-01-29 Thread Claudio M. E. Bastos Iorio
Thanks for your answer. But how? Where?. I think that 
ProgressEvent.bytesLoaded, and ProgressEvent.bytesTotal could help. But where 
should I check the status? 


Claudio M. E. Bastos Iorio
http://www.blumer.com.ar

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of eric e. dolecki
Sent: Tuesday, January 29, 2008 4:07 PM
To: Flash Coders List
Subject: Re: [Flashcoders] how to return in this function

you could use an event to listen to, to pass the XML out of the class.

On Jan 29, 2008 1:42 PM, Claudio M. E. Bastos Iorio <[EMAIL PROTECTED]>
wrote:

> Hi guys, hope you can help me on this one.
>
> I have a class to load an XML file. I'm trying this:
>
>
>
>
> package {
>   import flash.net.URLRequest;
>   import flash.net.URLLoader;
>   import flash.events.*;
>   public class retornaXML{
>  private var _xml:XML;
>  public function retornaXML() {
> cargarXML();
>  }
>
>  private function cargarXML():void {
> var loader:URLLoader = new URLLoader();
> loader.addEventListener(Event.COMPLETE, xmlLoaded);
> loader.load(new URLRequest("LocalData.xml"));
>  }
>  private function xmlLoaded(e:Event):void {
> _xml = new XML(e.target.data);
> trace(_xml);
> //THE TRACE HERE WORKS PERFECT AND RETURNS THE XML
>
>  }
>  public function get elXML():XML {
> return _xml;
> //THIS RETURNS null
>  }
>
>   }
> }
>
>
>
> I want something like this:
>
>
>
> var mivariable:retornaXML = new retornaXML();
> trace(mivariable.elXML);
>
>
>
> but this trace returns null, since the xml file (I think) is not loaded
> yet.
> What should I do?
>
>
>
> Thanks in advance.
>
> 
>
> Claudio M. E. Bastos Iorio
>
>   http://www.blumer.com.ar
>
>
>
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] how to return in this function

2008-01-29 Thread eric e. dolecki
you could use an event to listen to, to pass the XML out of the class.

On Jan 29, 2008 1:42 PM, Claudio M. E. Bastos Iorio <[EMAIL PROTECTED]>
wrote:

> Hi guys, hope you can help me on this one.
>
> I have a class to load an XML file. I'm trying this:
>
>
>
>
> package {
>   import flash.net.URLRequest;
>   import flash.net.URLLoader;
>   import flash.events.*;
>   public class retornaXML{
>  private var _xml:XML;
>  public function retornaXML() {
> cargarXML();
>  }
>
>  private function cargarXML():void {
> var loader:URLLoader = new URLLoader();
> loader.addEventListener(Event.COMPLETE, xmlLoaded);
> loader.load(new URLRequest("LocalData.xml"));
>  }
>  private function xmlLoaded(e:Event):void {
> _xml = new XML(e.target.data);
> trace(_xml);
> //THE TRACE HERE WORKS PERFECT AND RETURNS THE XML
>
>  }
>  public function get elXML():XML {
> return _xml;
> //THIS RETURNS null
>  }
>
>   }
> }
>
>
>
> I want something like this:
>
>
>
> var mivariable:retornaXML = new retornaXML();
> trace(mivariable.elXML);
>
>
>
> but this trace returns null, since the xml file (I think) is not loaded
> yet.
> What should I do?
>
>
>
> Thanks in advance.
>
> 
>
> Claudio M. E. Bastos Iorio
>
>   http://www.blumer.com.ar
>
>
>
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] how to return in this function

2008-01-29 Thread Claudio M. E. Bastos Iorio
Hi guys, hope you can help me on this one.

I have a class to load an XML file. I'm trying this:

 


package {
   import flash.net.URLRequest;
   import flash.net.URLLoader;
   import flash.events.*;
   public class retornaXML{
  private var _xml:XML;
  public function retornaXML() {
 cargarXML();
  }
  
  private function cargarXML():void {
 var loader:URLLoader = new URLLoader();
 loader.addEventListener(Event.COMPLETE, xmlLoaded);
 loader.load(new URLRequest("LocalData.xml"));
  }
  private function xmlLoaded(e:Event):void {
 _xml = new XML(e.target.data);
 trace(_xml);
//THE TRACE HERE WORKS PERFECT AND RETURNS THE XML 

  }
  public function get elXML():XML {
 return _xml;
//THIS RETURNS null
  }
 
   }
}

 

I want something like this: 

 

var mivariable:retornaXML = new retornaXML();
trace(mivariable.elXML);

 

but this trace returns null, since the xml file (I think) is not loaded yet.
What should I do?

 

Thanks in advance.



Claudio M. E. Bastos Iorio

  http://www.blumer.com.ar

 

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] Flash 8, AS 2.0. I want to use symbols from child movie in parent movie. Possible?

2008-01-29 Thread Hans Wichman
Hi,

you've answered your own question I'm afraid.

There is one other option, paint bitmaps to a symbol :).
So all the assets for an interactive smiley are stored as bitmaps and you
create a movieclip from that.

greetz
JC

On Tue, Jan 29, 2008 at 5:33 PM, Donald Trump <[EMAIL PROTECTED]> wrote:

> Hey!
>
> Suppose I load an SWF that contains symbols inside the main movie. Let it
> be smiles for
> chat application - smiles.swf.
> Then I want to instantiate some of these symbols putting them on the main
> movie _root.
> That is essential, I want to add the instances to the main movie _root or
> _root's
> descendants.
> Is it possible with Flash 8?
>
> I have made some experiments and have come to conlusion that Flash allows
> to create
> symbol instances only inside the movie that the symbol is coming from.
> Am I right?
>
> Well, I know one workaround - to paint a symbol to a bitmap and add this
> bitmap to the
> main movie. However in my application I deal with interactive symbols not
> the smile
> bitmaps, so this approach doesn't work for me.
>
>
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] mc code still runs after being removed...Huh?!?

2008-01-29 Thread BOYD SPEER
Another problem:
code from a movieclip that has been removed from the DisplayList with 
"removeChild(sparkle)" and then nulled by using "sparkle= null" or "sparkle = 
void" .

how can I turn off the repetition of the try-catch code (which tells the main 
class to "kill" sparkle) after the clip should be totally out of the movie?

Thanks
-Boyd
 
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] Flash 8, AS 2.0. I want to use symbols from child movie in parent movie. Possible?

2008-01-29 Thread Donald Trump
Hey!

Suppose I load an SWF that contains symbols inside the main movie. Let it be 
smiles for 
chat application - smiles.swf.
Then I want to instantiate some of these symbols putting them on the main movie 
_root.
That is essential, I want to add the instances to the main movie _root or 
_root's 
descendants.
Is it possible with Flash 8?

I have made some experiments and have come to conlusion that Flash allows to 
create 
symbol instances only inside the movie that the symbol is coming from.
Am I right?

Well, I know one workaround - to paint a symbol to a bitmap and add this bitmap 
to the 
main movie. However in my application I deal with interactive symbols not the 
smile 
bitmaps, so this approach doesn't work for me.


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] simple form validation

2008-01-29 Thread Corban Baxter
hey guys I just wanted some feedback on how you guys handle form's and
simple error checking. this is what I put together quickly this
morning for my form. but I was hoping to get some input on how to do
it better and what other options I have for validation. The project is
all AS2 and flash 8 also. Thanks in advance.


Code:

fName_input.tabEnabled = true;
lName_input.tabEnabled = true;
title_input.tabEnabled = true;
company_input.tabEnabled = true;
other_input.tabEnabled = true;


fName_input.tabIndex = 1;
lName_input.tabIndex = 2;
title_input.tabIndex = 3;
company_input.tabIndex = 4;
other_input.tabIndex = 5;

fName_input.restrict = "a-z A-Z \\- \\. \\,";
lName_input.restrict = "a-z A-Z \\- \\. \\,";

function checkFormCompletion():Void{

if(fName_input.length <= 1 || lName_input.length <= 1 ||
title_input.length <= 1 || company_input.length <= 1 ||
other_input.length <= 2){

_parent.nextBtn.enabled = false;
_parent.nextBtn.gotoAndStop(1);
_parent.nextBtn.onPress = null;


var errorString:String = this._name + "_error";
var errorMc:MovieClip = this._parent[errorString];
errorMc.gotoAndStop("active"); //display error

return; 
}

// if all fields complete turn on nextBtn to allow user to
move to the next step
_parent.nextBtn.enabled = true;
_parent.nextBtn.gotoAndStop(2);
_parent.nextBtn.onPress = _parent.leaveHomeForm;
}

function collectHomepageFormData():Void{
trace("DATA COLLECTED FROM HOMEPAGE FORM");
_global.userfName = fName_input.text;
_global.userlName = lName_input.text;
_global.userTitle = title_input.text;
_global.userCompany = company_input.text;
_global.userOther = other_input.text;

_global.userName = _global.userfName + " " + _global.userlName;
}

fName_input.onChanged = checkFormCompletion;
lName_input.onChanged = checkFormCompletion;
title_input.onChanged = checkFormCompletion;
company_input.onChanged = checkFormCompletion;
other_input.onChanged = checkFormCompletion;



-- 
Corban Baxter
http://www.projectx4.com
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] dynaically generated mc reference to class that created it..SOLVED

2008-01-29 Thread BOYD SPEER
This works:
(parent.root as Cardgenerator).makeglow();

Thanks, guys!

- Original Message -
From: Piers Cowburn <[EMAIL PROTECTED]>
Date: Tuesday, January 29, 2008 9:22 am
Subject: Re: [Flashcoders] dynaically generated mc reference to class that 
created it
To: Flash Coders List 

> Is the movieclip on the display list? If so you should be able 
> to do  
> root.makeglow()
> 
> Piers
> 
> On 29 Jan 2008, at 14:54, BOYD SPEER wrote:
> 
> > Using AS3 I have a movieclip made (dynamically made) of a 
> class  
> > called "Dragon". Inside its main timeline in a frame script I 
> want  
> > to tell the object (the main class called Cardgenerator) 
> that  
> > created it to run a function called "makeglow". But I can't 
> seem to  
> > call a function there..any suggestions greatly appreciated. :)
> >
> > -Boyd
> >
> > ___
> > Flashcoders mailing list
> > Flashcoders@chattyfig.figleaf.com
> > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
> 
> [EMAIL PROTECTED]
> 0207 631 3278
> 
> 
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] dynaically generated mc reference to class that created it

2008-01-29 Thread Piers Cowburn
Is the movieclip on the display list? If so you should be able to do  
root.makeglow()


Piers

On 29 Jan 2008, at 14:54, BOYD SPEER wrote:

Using AS3 I have a movieclip made (dynamically made) of a class  
called "Dragon". Inside its main timeline in a frame script I want  
to tell the object (the main class called Cardgenerator) that  
created it to run a function called "makeglow". But I can't seem to  
call a function there..any suggestions greatly appreciated. :)


-Boyd

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[EMAIL PROTECTED]
0207 631 3278


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] dynaically generated mc reference to class that created it

2008-01-29 Thread BOYD SPEER
Using AS3 I have a movieclip made (dynamically made) of a class called 
"Dragon". Inside its main timeline in a frame script I want to tell the object 
(the main class called Cardgenerator) that created it to run a function called 
"makeglow". But I can't seem to call a function there..any suggestions greatly 
appreciated. :)

-Boyd
 
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] (no subject)

2008-01-29 Thread sense co moh
yes it's working and you are right the best way is to use Array  but I don't 
understand the Array it's really confuse me

thanks alot

- Original Message 
From: Piers Cowburn <[EMAIL PROTECTED]>
To: Flash Coders List 
Sent: Tuesday, January 29, 2008 5:44:00 PM
Subject: Re: [Flashcoders] (no subject)

You can try this:

> this.infoclip.info_txt.text = this["txt"+ image1]


But the best way of doing this would be to use an array:

var txts:Array = new Array();
txts[1] = "this is text 1";
txts[2] = "this is text 2";
txts[3] = "this is text 3";
txts[4] = "this is text 4";
txts[5] = "this is text 5";

this.infoclip.info_txt.text = txts[image1];

Piers


On 29 Jan 2008, at 13:15, sense co moh wrote:

> Hi all
> I have this problem, I'm making photo gallery and for each photo  
> there are description text so first I made many var string for text
> like this
> var txt1:String = "this is text 1";
> var txt2:String = "this is text 2";
> var txt3:String = "this is text 3";
> var txt4:String = "this is text 4";
> var txt5:String = "this is text 5";
>
> and I create dynamic text "info_txt"
> then I load the images using var image1
> my_mcl5.loadClip("images/cate1/big/big"+image1 
> +".jpg",_root.main.big_prev);
>
> now i want to use the same var image1 to load the text but the  
> problem how to wirte it, if i but
> this.infoclip.info_txt.text = "txt"+ image1
> i get in the text box stinf txt1 or 2 what ever the value of image1
> if i use this.infoclip.info_txt.text = txt +image1
> I get error
> can anyone tell me what to do
>
> thanks
>
>
>
> __ 
> __
> Never miss a thing.  Make Yahoo your home page.
> http://www.yahoo.com/r/hs
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

[EMAIL PROTECTED]
0207 631 3278


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


  

Never miss a thing.  Make Yahoo your home page. 
http://www.yahoo.com/r/hs
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] (no subject)

2008-01-29 Thread sense co moh
thankss Cedric
this["txt"+image1] works fine

thank you

- Original Message 
From: Cedric Muller <[EMAIL PROTECTED]>
To: Flash Coders List 
Sent: Tuesday, January 29, 2008 5:26:40 PM
Subject: Re: [Flashcoders] (no subject)

Hello

change
> this.infoclip.info_txt.text = "txt"+ image1
to
this.infoclip.info_txt.text = ["txt"+image1];
or
this.infoclip.info_txt.text = this["txt"+image1];

Basically, this[variableStringReference] evaluates the string,  
"txt"+image1, as a variable name, which points to 'txt1', 'txt2', ...  
assuming image1 = 1, etc

hth,
Cedric


> Hi all
> I have this problem, I'm making photo gallery and for each photo  
> there are description text so first I made many var string for text
> like this
> var txt1:String = "this is text 1";
> var txt2:String = "this is text 2";
> var txt3:String = "this is text 3";
> var txt4:String = "this is text 4";
> var txt5:String = "this is text 5";
>
> and I create dynamic text "info_txt"
> then I load the images using var image1
> my_mcl5.loadClip("images/cate1/big/big"+image1 
> +".jpg",_root.main.big_prev);
>
> now i want to use the same var image1 to load the text but the  
> problem how to wirte it, if i but
> this.infoclip.info_txt.text = "txt"+ image1
> i get in the text box stinf txt1 or 2 what ever the value of image1
> if i use this.infoclip.info_txt.text = txt +image1
> I get error
> can anyone tell me what to do
>
> thanks
>
>
>
> __ 
> __
> Never miss a thing.  Make Yahoo your home page.
> http://www.yahoo.com/r/hs
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


  

Looking for last minute shopping deals?  
Find them fast with Yahoo! Search.  
http://tools.search.yahoo.com/newsearch/category.php?category=shopping
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] (no subject)

2008-01-29 Thread Piers Cowburn

You can try this:


this.infoclip.info_txt.text = this["txt"+ image1]



But the best way of doing this would be to use an array:

var txts:Array = new Array();
txts[1] = "this is text 1";
txts[2] = "this is text 2";
txts[3] = "this is text 3";
txts[4] = "this is text 4";
txts[5] = "this is text 5";

this.infoclip.info_txt.text = txts[image1];

Piers


On 29 Jan 2008, at 13:15, sense co moh wrote:


Hi all
I have this problem, I'm making photo gallery and for each photo  
there are description text so first I made many var string for text

like this
var txt1:String = "this is text 1";
var txt2:String = "this is text 2";
var txt3:String = "this is text 3";
var txt4:String = "this is text 4";
var txt5:String = "this is text 5";

and I create dynamic text "info_txt"
then I load the images using var image1
my_mcl5.loadClip("images/cate1/big/big"+image1 
+".jpg",_root.main.big_prev);


now i want to use the same var image1 to load the text but the  
problem how to wirte it, if i but

this.infoclip.info_txt.text = "txt"+ image1
i get in the text box stinf txt1 or 2 what ever the value of image1
if i use this.infoclip.info_txt.text = txt +image1
I get error
can anyone tell me what to do

thanks


   
__ 
__

Never miss a thing.  Make Yahoo your home page.
http://www.yahoo.com/r/hs
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[EMAIL PROTECTED]
0207 631 3278


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] (no subject)

2008-01-29 Thread Cedric Muller

Hello

change

this.infoclip.info_txt.text = "txt"+ image1

to
this.infoclip.info_txt.text = ["txt"+image1];
or
this.infoclip.info_txt.text = this["txt"+image1];

Basically, this[variableStringReference] evaluates the string,  
"txt"+image1, as a variable name, which points to 'txt1', 'txt2', ...  
assuming image1 = 1, etc


hth,
Cedric



Hi all
I have this problem, I'm making photo gallery and for each photo  
there are description text so first I made many var string for text

like this
var txt1:String = "this is text 1";
var txt2:String = "this is text 2";
var txt3:String = "this is text 3";
var txt4:String = "this is text 4";
var txt5:String = "this is text 5";

and I create dynamic text "info_txt"
then I load the images using var image1
my_mcl5.loadClip("images/cate1/big/big"+image1 
+".jpg",_root.main.big_prev);


now i want to use the same var image1 to load the text but the  
problem how to wirte it, if i but

this.infoclip.info_txt.text = "txt"+ image1
i get in the text box stinf txt1 or 2 what ever the value of image1
if i use this.infoclip.info_txt.text = txt +image1
I get error
can anyone tell me what to do

thanks


   
__ 
__

Never miss a thing.  Make Yahoo your home page.
http://www.yahoo.com/r/hs
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] (no subject)

2008-01-29 Thread sense co moh
Hi all
I have this problem, I'm making photo gallery and for each photo there are 
description text so first I made many var string for text
like this 
var txt1:String = "this is text 1";
var txt2:String = "this is text 2";
var txt3:String = "this is text 3";
var txt4:String = "this is text 4";
var txt5:String = "this is text 5";

and I create dynamic text "info_txt"
then I load the images using var image1
my_mcl5.loadClip("images/cate1/big/big"+image1+".jpg",_root.main.big_prev);

now i want to use the same var image1 to load the text but the problem how to 
wirte it, if i but 
this.infoclip.info_txt.text = "txt"+ image1
i get in the text box stinf txt1 or 2 what ever the value of image1 
if i use this.infoclip.info_txt.text = txt +image1
I get error
can anyone tell me what to do

thanks


  

Never miss a thing.  Make Yahoo your home page. 
http://www.yahoo.com/r/hs
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] MultiLanguage

2008-01-29 Thread Jake Prime
Hi Dave

I've done quite a few muiltilanguage sites, including Chinese and
Korean. The way I've tackled this in the past is to load the fonts
from an external SWF at run-time, using shared runtime libraries. It's
a bit of a roundabout method, and if a single part of the process is
not done correctly, it will fail (silently of course!) and you will
not see any text rendered. But it's worth it!

You can use Shared Fonts Manager, where the process is documented here:
http://sharedfonts.com/eng/help.html

The Shared Fonts Manager itself just helps you manage the fonts, and
you can use the same method with your own management if you don't want
to use the product, your choice.

When you get it to work it means you can paste all your chinese copy
into the font library FLA, use autofill, then only embed the
characters you need. In my experience this leads to a total of no more
than 500KB of font data for Chinese (and you only need to load that
when the site is actually displayed in Chinese).

It also has the benefit of only having to load the fonts once, even if
your site is spread across multiple SWFs.

Hope that helps,
Jake



On 24/01/2008, Kerry Thompson <[EMAIL PROTECTED]> wrote:
> > I'd think so, but it doesn't seem to be the case. In my interface for
> > example,  I need to support Chinese simplified and traditional - and in my
> > tests some characters are not appearing if I just choose the traditional
> > level 1 support. So I need to include support for both which is like
> 18,000
> > glyphs. For some reason traditional is 5609 glyphs and 'simplified' is
> > 13000+. Simple my ass.
>
> Yeah, I was surprised at the number of characters in the Level 1 Simplified.
> There should be fewer--part of Mao's simplification was combining words that
> were pronounced the same but had different characters in traditional
> Chinese. For example, "hou" (4th tone) can mean "empress" or "behind",
> depending on the character. In traditional Chinese, there are two
> characters, while simplified Chinese uses just one for both.
>
> > Hmmm - a thought... maybe I can just do the 5609 and then add in missing
> > characters as needed. So far, there only a couple that are not showing if
> I
> > use only the level 1 support.
>
> I doubt that will work for simplified. Not only were characters combined, a
> lot of characters were simplified to use fewer strokes. For example, my
> Chinese name, Tan, is actually a combination of 3 characters (not unusual).
> The one on the left, called the radical, is 2 strokes in simplified Chinese,
> and 7 strokes in traditional. Other characters, like those for "door" and
> "country" also use far fewer strokes in simplified Chinese.
>
> So just using the traditional character set and filling in probably won't do
> it for you. You'll probably end up displaying traditional characters
> (actually called complicated-body characters in Chinese), which some people
> in Singapore and mainland China won't be able to read.
>
> It's not optimal, I know, and the file will be bigger than you want. Maybe
> you could have them choose the language up front, then load a swf with just
> the right character set embedded.
>
> Cordially,
>
> Kerry Thompson
>
>
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] onMetaData

2008-01-29 Thread strk
Can one rely on the assumption that onMetaData
will be called only once for a given video loaded
by NetStream ?

And is the call sequence of it and other statuses
predictable at all ?

TIA

--strk; 

 ()   ASCII Ribbon Campaign
 /\   Keep it simple! 

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] Catching an error from a component

2008-01-29 Thread Helmut Granda
I have a scroll component that sometimes is deleted from the display list
while the user is holding the scroll bar and I get this error:

TypeError: Error #1009: Cannot access a property or method of a null object
reference.
at fl.controls::ScrollBar/fl.controls:ScrollBar::thumbReleaseHandler()

We know this error is fired since the scroll component is non-existent by
the time the user releases the scroll bar...I am trying to catch it but not
sure how should I catch this type of error since this is fired from within
the component...

I have tried the following:

sp.addEventListener(MouseEvent.MOUSE_UP, catchError);
sp.addEventListener(MouseEvent.MOUSE_LEAVE, catchError);

and so forth... I am still trying but some suggestions would be great.

Thanks,
Helmut
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] Animated gif

2008-01-29 Thread tommek

Thanks ekameleon, That's just what i was after.

ekameleon wrote:

Hello :)

You can see too the AS3 Gif Player class : http://www.bytearray.org/?p=95

EKA+ :)

2008/1/29, tommek <[EMAIL PROTECTED]>:
  

Dynamically loading animated gif in flash and get them to play is that
possible.

I found

http://dougmccune.com/blog/2007/01/19/how-to-load-animated-gifs-using-adobe-flex-20/
it has been done in Flex.

Can this be done in flash cs3 as3 code?

Is it possible to the loader |to mimeType="application/octet-stream"?|
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders



___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

  

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders