This is an automated email from the ASF dual-hosted git repository.
carlosrovira 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 1a3f743 ArrayListView: Dispatch lengthChanged binding event if
necessary after a refresh
new f953791 Merge pull request #887 from brianraymes/develop
1a3f743 is described below
commit 1a3f743c8f5614d7223770ef355c3878f49d7b81
Author: Brian Raymes <[email protected]>
AuthorDate: Tue Jul 14 14:01:33 2020 -0700
ArrayListView: Dispatch lengthChanged binding event if necessary after a
refresh
---
.../src/main/royale/org/apache/royale/collections/ArrayListView.as | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git
a/frameworks/projects/Collections/src/main/royale/org/apache/royale/collections/ArrayListView.as
b/frameworks/projects/Collections/src/main/royale/org/apache/royale/collections/ArrayListView.as
index 1d52cbb..d581407 100644
---
a/frameworks/projects/Collections/src/main/royale/org/apache/royale/collections/ArrayListView.as
+++
b/frameworks/projects/Collections/src/main/royale/org/apache/royale/collections/ArrayListView.as
@@ -522,8 +522,13 @@ public class ArrayListView extends EventDispatcher
implements IArrayListView, IA
* @productversion Royale 0.0
*/
public function refresh():Boolean {
+ var lengthChanged:Boolean = internalRefresh(true);
- return internalRefresh(true);
+ if (lengthChanged) {
+ dispatchEvent(new Event('lengthChanged'));
+ }
+
+ return lengthChanged;
}
//--------------------------------------------------------------------------