flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jmcl...@apache.org
Subject [1/2] git commit: [flex-sdk] [refs/heads/develop] - FLEX-34108 Change to simpler implementation. On 10.2/10.3 no issue as the function shouldn't be called directly.
Date Wed, 26 Feb 2014 00:11:51 GMT
Repository: flex-sdk
Updated Branches:
  refs/heads/develop 8420d0e62 -> 4502b01e5


FLEX-34108 Change to simpler implementation. On 10.2/10.3 no issue as the function shouldn't
be called directly.


Project: http://git-wip-us.apache.org/repos/asf/flex-sdk/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-sdk/commit/87471644
Tree: http://git-wip-us.apache.org/repos/asf/flex-sdk/tree/87471644
Diff: http://git-wip-us.apache.org/repos/asf/flex-sdk/diff/87471644

Branch: refs/heads/develop
Commit: 8747164401f9ab4ad0dc8ac522912a3890aabd0f
Parents: 27236b6
Author: Justin Mclean <jmclean@apache.org>
Authored: Wed Feb 26 11:06:22 2014 +1100
Committer: Justin Mclean <jmclean@apache.org>
Committed: Wed Feb 26 11:06:22 2014 +1100

----------------------------------------------------------------------
 .../framework/src/mx/collections/ArrayCollection.as  | 13 ++-----------
 .../framework/src/mx/collections/ArrayList.as        | 15 +++------------
 2 files changed, 5 insertions(+), 23 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/87471644/frameworks/projects/framework/src/mx/collections/ArrayCollection.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/framework/src/mx/collections/ArrayCollection.as b/frameworks/projects/framework/src/mx/collections/ArrayCollection.as
index ab195b9..6d91c88 100644
--- a/frameworks/projects/framework/src/mx/collections/ArrayCollection.as
+++ b/frameworks/projects/framework/src/mx/collections/ArrayCollection.as
@@ -149,6 +149,7 @@ public class ArrayCollection extends ListCollectionView implements IExternalizab
 
 	/**
 	 *  Converts an Array Collection to JavaScript Object Notation (JSON) format.
+	 *  Called by the JSON.stringify() method and should not be called directly.
 	 *  
 	 *  @langversion 3.0
 	 *  @playerversion Flash 11
@@ -157,17 +158,7 @@ public class ArrayCollection extends ListCollectionView implements IExternalizab
 	 */
 	public function toJSON(s:String):*
 	{
-		var array:Array = toArray();
-		
-		if (ApplicationDomain.currentDomain.hasDefinition("JSON"))
-		{
-			var json:Class = Class(ApplicationDomain.currentDomain.getDefinition("JSON"));
-			return json["stringify"](array);
-		}
-		else
-		{
-			return '{"error": "Not supported on Flash Player 10"}';
-		}
+		return toArray();
 	}
 	
     /**

http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/87471644/frameworks/projects/framework/src/mx/collections/ArrayList.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/framework/src/mx/collections/ArrayList.as b/frameworks/projects/framework/src/mx/collections/ArrayList.as
index 42ac624..79545d3 100644
--- a/frameworks/projects/framework/src/mx/collections/ArrayList.as
+++ b/frameworks/projects/framework/src/mx/collections/ArrayList.as
@@ -273,7 +273,8 @@ public class ArrayList extends EventDispatcher
     //--------------------------------------------------------------------------
 
 	/**
-	 *  Converts an Array Collection to JavaScript Object Notation (JSON) format.
+	 *  Converts an Array List to JavaScript Object Notation (JSON) format.
+	 * 	Called by the JSON.stringify() method and should not be called directly.
 	 *  
 	 *  @langversion 3.0
 	 *  @playerversion Flash 11
@@ -282,17 +283,7 @@ public class ArrayList extends EventDispatcher
 	 */
 	public function toJSON(s:String):*
 	{
-		var array:Array = toArray();
-		
-		if (ApplicationDomain.currentDomain.hasDefinition("JSON"))
-		{
-			var json:Class = Class(ApplicationDomain.currentDomain.getDefinition("JSON"));
-			return json["stringify"](array);
-		}
-		else
-		{
-			return '{"error": "Not supported on Flash Player 10"}';
-		}
+		return toArray();
 	}
 	
     /**


Mime
View raw message