|
-
Hi JAQUAN
Hi JAQUAN,
Thanks for your last words. One very last thing I wanted to ask was regarding how Controllers interact with their views directly when the model doesn't need to be updated.
For example, if I clicked a movieclip inside a view and wanted that movieclip to change colour and then tween across the screen, or scale.. would I pass the movieclip inside the view to the controller and let the controller do the tweening and changing of the movieclip with code, or simply instruct the view from the controller to animate and change the movieclip, and include all the code and packages to do this inside the view?
Based on what I've read on the internet and my extensive reading, there seems to be much debate about this.
I am currently putting public setters on the view to manipulate components/movieclips inside the view from the controller. I am also putting all the code needed to tween view components/movieclips inside methods in the view, and then simply calling the view methods from the controller. Is this correct?
Also, seeing as the controller is usually created before the view, I am having some difficulty in finding a way to pass a view to a controller.. do I pass the view to the controller as a target object when the view delegates events to the controller? of should I simply set up a listener to the controller in the view, and call view methods based on dispatched events from the controller..
I hope you can help a little.. this must be more simple than it appears.. and there is nothing in OREILLY's book to explain how controllers update views directly without effecting the model..
Tom.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|