All of my views are bound to models. I have data specific models and
models that drive views (kind of like the ViewHelper class). so the
event would result in a change to the view model which would update
the view. 

The way I have it setup is there is an AppModelLocator application
wide data models (like my user object are bound here) I then have
models for application states (like login and home). These models have
some specific variables to drive the views. Strict Cairngorm would
have you put these variable in a ViewHelper.

I also (although not strick MVC) use mx:Binding statements to link the
source view to the model when the event would do nothing more than
update the variable (for example when the user selects an item in a
grid I bind grid selected item to model selected item.)

--Sean


--- In [email protected], "Douglas Knudsen"
<[EMAIL PROTECTED]> wrote:
>
> I too use Cairngorm and would suggest it.  Issue I have though is if
your
> view, in Andrew's case his component, just needs to react to what
another
> component did at the gesture/view level only.  Since a Command is not
> supposed to talk to the view directly, and in this case needs too, I
feel
> cornered in this case.  What I have been starting to do is use
standard flex
> Event and place dispatch and listen at systemManager level.
> 
> DK
> 
> On 3/12/07, rough68fish <[EMAIL PROTECTED]> wrote:
> >
> > There are a lot of ways to do what you are asking personally I like to
> > use Cairngorm since it provides a good model for handling this type of
> > thing and provides a nice separation between my components.
> >
> > Otherwise one way would be to have your main application invoke
> > methods within your components when it catches the events.
> >
> > in mainAppHandler...
> > mycomponent2.handler();
> >
> > --- In [email protected], "greenfishinwater"
> > <greenfishinwater@> wrote:
> > >
> > > I have an application:
> > >
> > >   TabNavigator
> > >     mycomponent1 - Edit parameters
> > >     mycomponent2 - Display A
> > >     mycomponent3 - Display B
> > >     mycomponent4 - Display C
> > >
> > > When I have changed some parameters in mycomponent1 I want to
fire an
> > > event in mycomponent1, and then in mycomponent2 to mycomponent4
listen
> > > for that event and then do local processing within that specific
> > > component.
> > >
> > > I can fire the event in mycomponent1, and I can successfully listen
> > > for it in the main app. But I am having problems setting up event
> > > listeners in mycomponent2 to mycomponent4.
> > >
> > > Can anybody help?
> > >
> > > Andrew
> > >
> >
> >
> >
> >
> >
> > --
> > Flexcoders Mailing List
> > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com
> > Yahoo! Groups Links
> >
> >
> >
> >
> 
> 
> -- 
> Douglas Knudsen
> http://www.cubicleman.com
> this is my signature, like it?
>


Reply via email to