Hi Tom,

It's a bit hard to tell without seeing the code. If your app class and your menu class, etc. are each creating their own extension of utils, then how are those subclasses communicating? Are they calling some update function in the super class? It sounds like you need to use a singleton, and give it an update() method that any class can access. That way you know all your classes are updating the same instance.
Here are great examples of singletons:
http://www.gskinner.com/blog/archives/2006/07/as3_singletons.html

Hope that helps,
Bob


Tom Huynen wrote:
Hi List!

I'm using a class named utils.as to store data like color values in my
project.
This class is then extended by let's say the application.as and the menu.as.

Next in the application class I change the value of a var in the utils
class.
When retrieving this value from the third (menu) class I still get the old
value instead of the new one.

What is the best thing to do when I want to keep my data central, up to date
and accesible for all classes in my project?

Kind regards,

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




--
Thanks,
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Bob Leisle Headsprout Software & Engineering
http://www.headsprout.com
Where kids learn to read!
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to