FLEX-35025 Now all ValidationResultEvents are passed through handleResults().
Project: http://git-wip-us.apache.org/repos/asf/flex-sdk/repo Commit: http://git-wip-us.apache.org/repos/asf/flex-sdk/commit/99be0d34 Tree: http://git-wip-us.apache.org/repos/asf/flex-sdk/tree/99be0d34 Diff: http://git-wip-us.apache.org/repos/asf/flex-sdk/diff/99be0d34 Branch: refs/heads/develop Commit: 99be0d34018cdbd6cf640beaeb0758f0d474777c Parents: a9eebe6 Author: Mihai Chira <[email protected]> Authored: Mon Feb 1 18:13:15 2016 +0100 Committer: Mihai Chira <[email protected]> Committed: Mon Feb 1 18:13:15 2016 +0100 ---------------------------------------------------------------------- frameworks/projects/framework/src/mx/validators/Validator.as | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/99be0d34/frameworks/projects/framework/src/mx/validators/Validator.as ---------------------------------------------------------------------- diff --git a/frameworks/projects/framework/src/mx/validators/Validator.as b/frameworks/projects/framework/src/mx/validators/Validator.as index eabe58f..f526b5b 100644 --- a/frameworks/projects/framework/src/mx/validators/Validator.as +++ b/frameworks/projects/framework/src/mx/validators/Validator.as @@ -919,11 +919,10 @@ public class Validator extends EventDispatcher implements IMXMLObject,IValidator { // We assume if value is null and required is false that // validation was successful. - var resultEvent:ValidationResultEvent = - new ValidationResultEvent(ValidationResultEvent.VALID); + var resultEvent:ValidationResultEvent = handleResults(null); if (!suppressEvents && _enabled) { - dispatchEvent(resultEvent); + dispatchEvent(resultEvent); } return resultEvent; } @@ -1080,7 +1079,7 @@ public class Validator extends EventDispatcher implements IMXMLObject,IValidator { var resultEvent:ValidationResultEvent; - if (errorResults.length > 0) + if (errorResults != null && errorResults.length > 0) { resultEvent = new ValidationResultEvent(ValidationResultEvent.INVALID);
