For me the argument still remains: you break a lot of stuff in a silent way. Why can't this be a setting on the form?
The things you describe are at least very specific to one method of development, given that we can build web applications using the current method of development for over 2 years. Making it a setting with the default being the current way of processing sounds much safer than inverting it because of a method of development that is in swing now. Martijn On 3/25/07, Igor Vaynberg <[EMAIL PROTECTED]> wrote:
so should we change this in 1.3? -igor On 2/15/07, Eelco Hillenius <[EMAIL PROTECTED]> wrote: > > I agree with it now too. A typical thing you want to do in a button is > do a component replacement (at least, that's what we do often here) of > a component above the form. The problem with buttons being called > before the form's onSubmit is that then the component is already > detached from the page. > > Eelco > > > On 2/15/07, Igor Vaynberg <[EMAIL PROTECTED]> wrote: > > i am going to resurrect this discussion again since we now have more > > committers and none of you old ones have agreed with me before! i still > > think this > > is a good idea! > > > > the old thread can be seen here: > > > > > http://www.nabble.com/form.onsubmit-vs-button.onsubmit-tf1977859.html#a5431105 > > > > -igor > > > > > > ---------- Forwarded message ---------- > > From: Igor Vaynberg <[EMAIL PROTECTED]> > > Date: Jul 20, 2006 3:55 PM > > Subject: form.onsubmit vs button.onsubmit > > To: wicket-develop@lists.sourceforge.net > > > > i just noticed that we call button.onsubmit() /before/ form.onsubmit(), > i > > always believed this to be the other way around because that is more > > intuitive - cascading onsubmit down the component hierarchy. is there a > > reason why we do it "backwards"? > > > > i have also noticed a pattern where i group certain fields in a panel > and > > would like to let the panel also have an onsubmit() for processing. i > was > > thinking of implementing IFormSubmitAware { void onSubmit(); } and > bubble > > this down via a visitor in form.delegatesubmit() but of course with the > > button getting called first it makes no sense. > > > > shall we reverse it in 2.0? should i put the iformsubmitaware into 2.0core? > > > > -Igor > > >
-- Learn Wicket at ApacheCon Europe: http://apachecon.com Join the wicket community at irc.freenode.net: ##wicket Wicket 1.2.5 will keep your server alive. Download Wicket now! http://wicketframework.org