flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From carlosrov...@apache.org
Subject [1/4] git commit: add removeItem to IList and ListCollectionView
Date Sun, 24 Mar 2013 23:06:59 GMT
Updated Branches:
  refs/heads/develop 251c9b717 -> 5f87fec9e


add removeItem to IList and ListCollectionView


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

Branch: refs/heads/develop
Commit: 14e10d49b65760eb2be9d89e464b21d2483145a8
Parents: 251c9b7
Author: Carlos Rovira <carlos.rovira@gmail.com>
Authored: Sun Mar 24 20:12:05 2013 +0100
Committer: Carlos Rovira <carlos.rovira@gmail.com>
Committed: Sun Mar 24 20:12:05 2013 +0100

----------------------------------------------------------------------
 .../projects/framework/src/mx/collections/IList.as |   16 +++++++++++-
 .../src/mx/collections/ListCollectionView.as       |   20 +++++++++++++-
 2 files changed, 33 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/14e10d49/frameworks/projects/framework/src/mx/collections/IList.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/framework/src/mx/collections/IList.as b/frameworks/projects/framework/src/mx/collections/IList.as
index fb91742..e636a7d 100644
--- a/frameworks/projects/framework/src/mx/collections/IList.as
+++ b/frameworks/projects/framework/src/mx/collections/IList.as
@@ -212,7 +212,21 @@ public interface IList extends IEventDispatcher
      *  @productversion Flex 3
      */
     function removeAll():void;
-
+	
+	/**
+	 *  Removes the specified item from this list, should it exist.
+	 *  Relies on ArrayList implementation
+	 *
+	 *  @param  item Object reference to the item that should be removed.
+	 *  @return Boolean indicating if the item was removed.
+	 *  
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Apache Flex 4.10
+	 */
+	function removeItem( item:Object ):Boolean;
+		
     /**
      *  Removes the item at the specified index and returns it.  
      *  Any items that were after this index are now one index earlier.

http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/14e10d49/frameworks/projects/framework/src/mx/collections/ListCollectionView.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/framework/src/mx/collections/ListCollectionView.as b/frameworks/projects/framework/src/mx/collections/ListCollectionView.as
index af33268..afce033 100644
--- a/frameworks/projects/framework/src/mx/collections/ListCollectionView.as
+++ b/frameworks/projects/framework/src/mx/collections/ListCollectionView.as
@@ -757,8 +757,24 @@ public class ListCollectionView extends Proxy
         //turns out that there are no neighbors of item in the filtered 
         //list, so item is the 1st item 
         return 0; 
-    } 
-
+    }
+    
+    /**
+	 *  Removes the specified item from this list, should it exist.
+	 *  Relies on ArrayList implementation
+	 *
+	 *  @param  item Object reference to the item that should be removed.
+	 *  @return Boolean indicating if the item was removed.
+	 *  
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Apache Flex 4.10
+	 */
+	public function removeItem( item:Object ):Boolean
+	{
+		return list.removeItem( item );
+	}
 
     /**
      * @inheritDoc 


Mime
View raw message