tapestry-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hls...@apache.org
Subject [2/9] git commit: Fiddle with event names
Date Sat, 06 Oct 2012 00:49:26 GMT
Fiddle with event names


Project: http://git-wip-us.apache.org/repos/asf/tapestry-5/repo
Commit: http://git-wip-us.apache.org/repos/asf/tapestry-5/commit/e4788daa
Tree: http://git-wip-us.apache.org/repos/asf/tapestry-5/tree/e4788daa
Diff: http://git-wip-us.apache.org/repos/asf/tapestry-5/diff/e4788daa

Branch: refs/heads/5.4-js-rewrite
Commit: e4788daa1de669681d14c4a00b89f0e3ef40df5e
Parents: 67cbc1c
Author: Howard M. Lewis Ship <hlship@apache.org>
Authored: Fri Oct 5 17:45:14 2012 -0700
Committer: Howard M. Lewis Ship <hlship@apache.org>
Committed: Fri Oct 5 17:45:14 2012 -0700

----------------------------------------------------------------------
 .../META-INF/modules/core/events.coffee            |    4 ++++
 .../META-INF/modules/core/forms.coffee             |    2 +-
 2 files changed, 5 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tapestry-5/blob/e4788daa/tapestry-core/src/main/coffeescript/META-INF/modules/core/events.coffee
----------------------------------------------------------------------
diff --git a/tapestry-core/src/main/coffeescript/META-INF/modules/core/events.coffee b/tapestry-core/src/main/coffeescript/META-INF/modules/core/events.coffee
index eaffaef..e61d53f 100644
--- a/tapestry-core/src/main/coffeescript/META-INF/modules/core/events.coffee
+++ b/tapestry-core/src/main/coffeescript/META-INF/modules/core/events.coffee
@@ -22,6 +22,10 @@ define
   # All events are triggered on a specific HTML `<form>` element, and top-level handlers
take it from there.
   form:
 
+    # Triggered early, to kick off a search for fields that should have `events.field.validate`
triggered.
+    # This is also where decorations are added or removed from individual fields.
+    validateFields: "t5:form:validate-fields"
+
     # Triggered after fields have been validated, when there are no field validation exceptions,
to allow for
     # cross-form validation.
     validate: "t5:form:validate"

http://git-wip-us.apache.org/repos/asf/tapestry-5/blob/e4788daa/tapestry-core/src/main/coffeescript/META-INF/modules/core/forms.coffee
----------------------------------------------------------------------
diff --git a/tapestry-core/src/main/coffeescript/META-INF/modules/core/forms.coffee b/tapestry-core/src/main/coffeescript/META-INF/modules/core/forms.coffee
index d9e424f..d726209 100644
--- a/tapestry-core/src/main/coffeescript/META-INF/modules/core/forms.coffee
+++ b/tapestry-core/src/main/coffeescript/META-INF/modules/core/forms.coffee
@@ -59,7 +59,7 @@ define ["core/events", "core/spi", "core/builder", "core/compat/tapestry"],
 
         # Only do form validation if all individual field validation
         # was successful.
-        this.trigger events.form.validateForm, memo unless memo.error
+        this.trigger events.form.validate, memo unless memo.error
 
         if memo.error
           clearSubmittingHidden this


Mime
View raw message