You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@royale.apache.org by ah...@apache.org on 2020/05/23 21:21:50 UTC

[royale-asjs] branch develop updated: suppress event if requested. Should help fix #824

This is an automated email from the ASF dual-hosted git repository.

aharui 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 ce04386  suppress event if requested.  Should help fix #824
ce04386 is described below

commit ce043863970fd70482e65a8d4cd4f19f610d6c68
Author: Alex Harui <ah...@apache.org>
AuthorDate: Sat May 23 14:21:28 2020 -0700

    suppress event if requested.  Should help fix #824
---
 .../src/main/royale/mx/collections/XMLListCollection.as       | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/collections/XMLListCollection.as b/frameworks/projects/MXRoyale/src/main/royale/mx/collections/XMLListCollection.as
index 043e892..ba45a8c 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/collections/XMLListCollection.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/collections/XMLListCollection.as
@@ -21,6 +21,8 @@ package mx.collections
 {
 import mx.events.CollectionEvent;
 import mx.events.CollectionEventKind;
+import mx.core.mx_internal;
+use namespace mx_internal;
 
 [DefaultProperty("source")]
 
@@ -119,9 +121,12 @@ public class XMLListCollection extends ListCollectionView
         
         list = new XMLListAdapter(s);
 
-        var event:CollectionEvent = new CollectionEvent(CollectionEvent.COLLECTION_CHANGE);
-        event.kind = CollectionEventKind.RESET;
-        dispatchEvent(event);
+		if (dispatchResetEvent)
+		{
+	        var event:CollectionEvent = new CollectionEvent(CollectionEvent.COLLECTION_CHANGE);
+	        event.kind = CollectionEventKind.RESET;
+	        dispatchEvent(event);
+		}
     }
 
     //--------------------------------------------------------------------------