[Flashcoders] Fwd: MVC

2012-02-16 Thread Ross Sclafani
From: Ross Sclafani ross.sclaf...@gmail.com Date: February 16, 2012 2:39:34 AM EST To: Cor c...@chello.nl Cc: Flash Coders List flashcoders@chattyfig.figleaf.com, flashcoder...@googlegroups.com Subject: Re: MVC feel free to hit me up any time ill try to have time to respong none the less, this

RE: [Flashcoders] MVC style

2012-02-16 Thread Bryan Thompson
Ross, that has to be the best explanation of MVC I've ever read. Combined with your example, I finally *really* understand the concepts. Thank you! Bryan Thompson -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On

RE: [Flashcoders] MVC style

2012-02-16 Thread Cor
I agree!!! Thanks again, Ross!! Ross quoted: Now imagine a Model with more properties. And tons of different Views of them that data. Some of which provide a UI linked to Controller methods that manipulate it. -- end quote -- I would love to see a next level example of a multi-model

Re: [Flashcoders] MVC style

2012-02-16 Thread Karl DeSaulniers
+1 On Feb 16, 2012, at 2:36 AM, Bryan Thompson wrote: Ross, that has to be the best explanation of MVC I've ever read. Combined with your example, I finally *really* understand the concepts. Thank you! Bryan Thompson -Original Message- From:

Re: [Flashcoders] Fwd: MVC

2012-02-16 Thread Beatrix Krümmer-Frau
perfect! Can I use this for my Flash students? Am 16.02.2012 08:59, schrieb Ross Sclafani: From: Ross Sclafaniross.sclaf...@gmail.com Date: February 16, 2012 2:39:34 AM EST To: Corc...@chello.nl Cc: Flash Coders Listflashcoders@chattyfig.figleaf.com, flashcoder...@googlegroups.com Subject: Re:

Re: [Flashcoders] MVC style

2012-02-16 Thread Ben Sand
We work with two MVC frameworks: RobotLegs in Flash and RubyonRails on the server. RubyonRails mandates a thin controller fat model paradigm and we try to user that in Flash as well. Under this paradigm, wherever possible, things should be in the model. One good reason for doing this is code

Re: [Flashcoders] Fwd: MVC

2012-02-16 Thread Paul Andrews
Excellent job. I have one small point, on a practical level. For the views, in particular, I don't usually pass arguments to the constructor. It's not such a big deal for code-only examples, but in my flash world I mix my components between stuff created dynamically and things created in the

[Flashcoders] Array sort issue

2012-02-16 Thread Cor
I have a multi-dimensional array loaded with xml. Now I need to sort the aMain array depending on the users choice. But it has to be sorted the values of the inner array. for (){ aMain.push( [xml.TRACK[n].SUB_TRACK[m].BEAM, xml.TRACK[n].SUB_TRACK[m].SPOT, etc...]); } How would I do this?

Re: [Flashcoders] MVC style

2012-02-16 Thread tom rhodes
yeah, getting more into robotlegs took me away from fat controllers, the single are a really nice way to make sure you don't end up with any monolithic classes. if your calculations change the data i'd say they should be in the model and exposed through it's API. if they are just using the data

Re: [Flashcoders] Fwd: MVC

2012-02-16 Thread tom rhodes
traditional vanilla MVC tends to use composition like the example given, check out robotlegs if you don't like it :) then you inject dependencies instead of passing them around and everything gets a bit more loosely coupled... On 16 February 2012 11:46, Paul Andrews p...@ipauland.com wrote:

[Flashcoders] Robert McLaughlin/BRAD/Bombardier is out of the office.

2012-02-16 Thread robert . mclaughlin
I will be out of the office starting 02/16/2012 and will not return until 02/20/2012. Please contact andrew.luck...@aero.bombardier.com (514) 344-6621 x4-6606 for any pressing issues. ___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com

Re: [Flashcoders] Fwd: MVC

2012-02-16 Thread Paul Andrews
On 16/02/2012 10:54, tom rhodes wrote: traditional vanilla MVC tends to use composition like the example given, check out robotlegs if you don't like it :) then you inject dependencies instead of passing them around and everything gets a bit more loosely coupled... It's not a question of not

Re: [Flashcoders] Fwd: MVC

2012-02-16 Thread Paul Andrews
On 16/02/2012 11:11, Paul Andrews wrote: On 16/02/2012 10:54, tom rhodes wrote: traditional vanilla MVC tends to use composition like the example given, check out robotlegs if you don't like it :) then you inject dependencies instead of passing them around and everything gets a bit more loosely

Re: [Flashcoders] Fwd: MVC

2012-02-16 Thread tom rhodes
um, Ross gave it i think dude. i didn't give any code examples :) maybe you missed the smiley after i said if you don't like it, perhaps shoudl have been a ;). what problems do you have using assets mad ein the IDE with mvc? On 16 February 2012 12:21, Paul Andrews p...@ipauland.com wrote: On

Re: [Flashcoders] Fwd: MVC

2012-02-16 Thread Paul Andrews
On 16/02/2012 12:04, tom rhodes wrote: um, Ross gave it i think dude. Yes, I posted a correction.. i didn't give any code examples :) maybe you missed the smiley after i said if you don't like it, perhaps shoudl have been a ;). what problems do you have using assets mad ein the IDE with mvc?

RE: [Flashcoders] Array sort issue

2012-02-16 Thread Cor
I figured it out. End of topic. -Original Message- From: flashcoders-boun...@chattyfig.figleaf.com [mailto:flashcoders-boun...@chattyfig.figleaf.com] On Behalf Of Cor Sent: donderdag 16 februari 2012 11:51 To: 'Flash Coders List' Subject: [Flashcoders] Array sort issue I have a

Re: [Flashcoders] Fwd: MVC

2012-02-16 Thread Ross Sclafani
I have a fuller framework that details a view life cycle, subModels, a Controller tree, animated transitions on change() and more. The classes I wrote are just the simplest examples that I thought would get people started. I'll get the framework polished up and open sourced to Github if you guys

Re: [Flashcoders] Fwd: MVC

2012-02-16 Thread Ross Sclafani
Absolutely. Good MVC should be taught at birth. Ross P. Sclafani Owner / Creative Director Neuromantic Industries http://www.neuromantic.com http://ross.sclafani.net http://www.twitter.com/rosssclafani 347.204.5714 On Feb 16, 2012, at 5:17 AM, Beatrix Krümmer-Frau birik...@hotmail.de wrote:

RE: [Flashcoders] Fwd: MVC

2012-02-16 Thread Cor
Ross, And you did get people started. At least me! I am also very interested in your fuller framework. I don't wish to use the big frameworks as RobotLegs, etc. I want to learn to create good MVC from scratch. Best regards, Cor van Dooren -Original Message- From:

RE: [Flashcoders] Fwd: MVC

2012-02-16 Thread jchilcott
___ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

RE: [Flashcoders] Fwd: MVC

2012-02-16 Thread jchilcott
(UGH... I hate RTF Web editors) RobotLegs is not a big framework at all. In comparison with most of the other frameworks out there, it's overhead is far far less than ones like Cairngorm, Spring and Parsley. Even compared to Mate and SWIZ (which are very small to begin with), then RobotLegs is

[Flashcoders] Count Down timer

2012-02-16 Thread natalia Vikhtinskaya
Hi I have a code on timeline for countDown that works well for mc timerObj import com.flashspeaks.utils.CountdownTimer; import com.flashspeaks.events.CountdownEvent; var currentYear:Number = new Date().fullYear; var targetDate:Date = new Date(2012, 1, 17); var countdown:CountdownTimer=new

Re: [Flashcoders] MVC style

2012-02-16 Thread John McCormack
A really nice explanation. I tried to find your EastAsMVC after being on your site, is it on the way? Also, what comes first, ie. how do the models find out about each other? John On 16/02/2012 00:05, Ross Sclafani wrote: I am an MVC purist, I always proceed as follows: Models should ONLY

Re: [Flashcoders] MVC style Correction

2012-02-16 Thread John McCormack
A really nice explanation. I tried to find your EastAsMVC after being on your site, is it on the way? Also, what comes first, ie. how do the models, controller and Views find out about each other? Does everything register with the (single) controller? John On 16/02/2012 00:05, Ross

Re: [Flashcoders] MVC style

2012-02-16 Thread Ross Sclafani
Yeah it hasn't been open source but I'm ready to do that soon. I'm having trouble parsing your other question, can you rephrase re: models knowing about each other? Ross P. Sclafani Owner / Creative Director Neuromantic Industries http://www.neuromantic.com http://ross.sclafani.net

RE: [Flashcoders] MVC style Correction

2012-02-16 Thread jchilcott
Models shouldn't have any knowledge of each other or anything outside of themselves. The controller should usually be the first area to set up. Everything else is set up and managed by the controller (views, models, services). Usually, there will be one central controller that handles your main

[Flashcoders] Sound control problem

2012-02-16 Thread natalia Vikhtinskaya
Hi I have mute button with class linked to this mc in the library package lib { import flash.display.*; import flash.events.*; import flash.utils.*; import flash.media.*; public class MuteControl extends flash.display.MovieClip { private var _so:SoundTransform;

Re: [Flashcoders] MVC style

2012-02-16 Thread Taka Kojima
Not really relevant to the thread, but I saw your CodeJS project Ross, you should take a look at my solution to Classical Inheritance in JavaScript; https://github.com/gigafied/minion Comes with dependency management and a build tool for building out different classes (and their dependencies)

Re: [Flashcoders] AIR Socket.readObject received in multiple ProgressEvents?

2012-02-16 Thread Mattheis, Erik (MIN-WSW)
I'm not understanding something here - in the following excerpted and simplified example, I'm trying to send a ByteArray of length 170 and there seem to be 173 bytes received. Where are the extra bytes coming from and and is that the reason readObject returns null? (tracing _socketData.toString

Re: [Flashcoders] AIR Socket.readObject received in multiple ProgressEvents?

2012-02-16 Thread Henrik Andersson
Mattheis, Erik (MIN-WSW) skriver: I'm not understanding something here - in the following excerpted and simplified example, I'm trying to send a ByteArray of length 170 and there seem to be 173 bytes received. Where are the extra bytes coming from and and is that the reason readObject

Re: [Flashcoders] AIR Socket.readObject received in multiple ProgressEvents?

2012-02-16 Thread Mattheis, Erik (MIN-WSW)
On 2/16/12 4:20 PM, Henrik Andersson he...@henke37.cjb.net wrote: It is highly possible that multiple writes was stuffed into one read, even if you don't flush between the writes. The three left over bytes could be the first three bytes of the length of the next object. I left out some of the

Re: [Flashcoders] Sound control problem

2012-02-16 Thread Karl DeSaulniers
Where is the var soundTransform being set first? I dont see it. Is it public or private? _so I see being set but not soundTransform. Best, Karl On Feb 16, 2012, at 1:48 PM, natalia Vikhtinskaya wrote: Hi I have mute button with class linked to this mc in the library package lib { import

Re: [Flashcoders] AIR Socket.readObject received in multiple ProgressEvents?

2012-02-16 Thread Henrik Andersson
Mattheis, Erik (MIN-WSW) skriver: On 2/16/12 4:20 PM, Henrik Andersson he...@henke37.cjb.net wrote: It is highly possible that multiple writes was stuffed into one read, even if you don't flush between the writes. The three left over bytes could be the first three bytes of the length of the

Re: [Flashcoders] AIR Socket.readObject received in multiple ProgressEvents?

2012-02-16 Thread Mattheis, Erik (MIN-WSW)
In my server app I was performing ByteArray.writeObject(MyObjectToSend) to assemble MyByteArray and then again using Socket.writeObject(MyByteArray) when actually sending it. This created an AMF encoded object within an AMF encoded object, oops. Once I discovered this error I was able to fix a

Re: [Flashcoders] AIR Socket.readObject received in multiple ProgressEvents?

2012-02-16 Thread Ross Sclafani
Henke! Have we met on IRC ? I operate there as butter. Used to hit up actionscript and papervison3d on freenode but it's been a while. Ross P. Sclafani Owner / Creative Director Neuromantic Industries http://www.neuromantic.com http://ross.sclafani.net http://www.twitter.com/rosssclafani

Re: [Flashcoders] AIR Socket.readObject received in multiple ProgressEvents?

2012-02-16 Thread Henrik Andersson
Ross Sclafani skriver: Henke! Have we met on IRC ? I operate there as butter. Used to hit up actionscript and papervison3d on freenode but it's been a while. Quite likely, since I do hang on ##actionscript@Freenode all the time. It must indeed have been quite a while, since I am afraid I

RE: [Flashcoders] Fwd: MVC

2012-02-16 Thread Cor
Me, being Dutch, is having all the problems expressing in a non-native language. I did not mean to offend ANY framework. Sure RobotLegs is perfect, as many people use it. I am only trying to get some help/examples to write a somewhat fuller MVC myself. So I am sorry! Best regards, Cor van