I've done some research on this list but haven't found any valid
information on what's considered best pratice in dealing with popup
windows. The few Cairngorm sample apps that are around don't seem to
use the TitleWindow component at all.

Let's say I have a simple DataGrid populated with some user data. If I
click on a row in the DataGrid a popup window opens with a form for
editing the user information. The popup window also has two buttons
for deleting or saving (updating) the user account. 

I have done stuff like this several times in Flash/AS2 but I've never
used a framework approach so far. Now, if I look at this rather simple
task from a Cairngorm perspective it doesn't seem to be that simple
any more. (But I guess that's because I'm not yet too familiar with
Cairngorm.) I know how to establish databinding between the data
provider and {model.users} and all this basic Cairngorm stuff. 

But what happens when a row is clicked? I'm not even sure if I'm
supposed to treat this event as a single event ("selectUser" or
"openPopup"?) or as a chain of two events ("selectUser" ->
"openPopup"). Since my user information is organized as an array of
value objects it's easy to assign the selected user VO to
model.selectedUser: 

model.selectedUser = UserVO(userList.selectedItem);

But am I "allowed" to directly access the ModelLocator from my view
component? Or am I supposed to route this simple action through the
Cairngorm "command chain" (Cairngorm Event -> Front Controller ->
Command Class -> ModelLocator)?

Next question, what about the popup itself? Can I simply use
PopUpManager.createPopUp( this, UserFormView , true)? Or am I supposed
to treat this as a Cairngorm Event, too?

I feel in "safe Cairngorm terrain" again with the "updateUser" and
"deleteUser" actions on the buttons. But what about closing the popup
window? Is this even worth a Cairngorm event?

I guess these questions sound rather stupid to those of you who are
more experienced with frameworks. But at the moment these questions
are obstacles on my way to master Cairngorm (which I will hopefully do
one day). I apologize for my verbose post and my bad English, but I
hope that someone can shed some light on these issues.

Stefan





















--
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

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to