This is an automated email from the ASF dual-hosted git repository.
piotrz pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git
The following commit(s) were added to refs/heads/develop by this push:
new 9357039 Jewel Validator: Create separate handler for
"cleanValidationErrors" event
9357039 is described below
commit 93570392b1cd9442d632b1a956998a4b4a487669
Author: Piotr Zarzycki <[email protected]>
AuthorDate: Mon Jun 21 13:55:14 2021 +0200
Jewel Validator: Create separate handler for "cleanValidationErrors" event
---
.../royale/org/apache/royale/jewel/beads/validators/Validator.as | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git
a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/validators/Validator.as
b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/validators/Validator.as
index 3116b79..a3e5cdd 100644
---
a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/validators/Validator.as
+++
b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/validators/Validator.as
@@ -372,7 +372,7 @@ package org.apache.royale.jewel.beads.validators
_host = UIUtils.findPopUpHost(hostComponent);
_host.popUpParent.addElement(_errorTip, false);
-
IEventDispatcher(_host.popUpParent).addEventListener("cleanValidationErrors",
destroyErrorTip);
+
IEventDispatcher(_host.popUpParent).addEventListener("cleanValidationErrors",
cleanValidationErrorsHandler);
}
COMPILE::JS
{
@@ -410,7 +410,7 @@ package org.apache.royale.jewel.beads.validators
window.removeEventListener('scroll', repositionHandler,
true);
}
if(_errorTip){
-
IEventDispatcher(_errorTip.parent).removeEventListener("cleanValidationErrors",
destroyErrorTip);
+
IEventDispatcher(_errorTip.parent).removeEventListener("cleanValidationErrors",
cleanValidationErrorsHandler);
_errorTip.parent.removeElement(_errorTip);
_errorTip = null;
}
@@ -481,6 +481,11 @@ package org.apache.royale.jewel.beads.validators
return pt;
}
+ protected function
cleanValidationErrorsHandler(event:Event):void
+ {
+ destroyErrorTip();
+ }
+
/**
* Destroy the created errorTip
*