I say, as popups are very different from alerts, that they should be treated very differently.
Other thoughts: ie.upcoming_alert(...).click ie.handle_upcoming_alert(...) ie.dismiss_upcoming_alert(...) If you're really trying to avoid the inverted sequencing, the holy grail is simply ie.button(:id,"foo").click #html button causes alert() ie.alert(:value,"OK).click Scott -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Bret Pettichord Sent: Tuesday, August 09, 2005 10:48 PM To: [email protected] Subject: RE: RE: [Wtr-general] New, improved support for popup dialogs At 12:19 AM 8/10/2005, Scott Hanselman wrote: >Ya, I really don't like the name either, as it (deeply) exposes the >implementation, IMHO. That said, here's my hypocritical votes: > >* spawn_eval >* forked_eval >* eval_newthread >* newthread_eval >* run_on_new_thread of these, i liked forked_eval the best... >That said, why not just lie to us (as object models are wont to do) and have >the API match my intent: > >ie.alert.dismiss_when_shown(:value, "OK") >ie.button(:name,"btnfoo").click This is an interesting idea. It does require the inverted sequencing that i was trying to avoid, but the result is, overall, probably easier to understand. Is "ie.alert" more intuitive than "ie.dialog"? What about "ie.popup"? One principle that i've tried to following in naming Watir methods is to use the HTML or JavaScript names for things. The JavaScript name is in fact "alert" (and "confirm"). Bret _____________________ Bret Pettichord www.pettichord.com _______________________________________________ Wtr-general mailing list [email protected] http://rubyforge.org/mailman/listinfo/wtr-general _______________________________________________ Wtr-general mailing list [email protected] http://rubyforge.org/mailman/listinfo/wtr-general
