flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ha...@apache.org
Subject git commit: [flex-asjs] [refs/heads/refactor-sprite] - Fixed Image classes
Date Tue, 09 Aug 2016 07:51:05 GMT
Repository: flex-asjs
Updated Branches:
  refs/heads/refactor-sprite a5c20eab0 -> d4ec19568


Fixed Image classes


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

Branch: refs/heads/refactor-sprite
Commit: d4ec195683a99e07747fec074f079e2002d0de4f
Parents: a5c20ea
Author: Harbs <harbs@in-tools.com>
Authored: Tue Aug 9 10:50:57 2016 +0300
Committer: Harbs <harbs@in-tools.com>
Committed: Tue Aug 9 10:50:57 2016 +0300

----------------------------------------------------------------------
 .../projects/Core/src/main/flex/CoreClasses.as  |  2 +
 .../flex/org/apache/flex/core/IBinaryImage.as   | 46 ++++++++++++++++++++
 .../main/flex/org/apache/flex/core/IImage.as    | 45 +++++++++++++++++++
 .../flex/org/apache/flex/html/BinaryImage.as    | 11 ++---
 .../src/main/flex/org/apache/flex/html/Image.as |  6 ++-
 .../HTML/src/main/resources/basic-manifest.xml  |  1 +
 6 files changed, 105 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/d4ec1956/frameworks/projects/Core/src/main/flex/CoreClasses.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Core/src/main/flex/CoreClasses.as b/frameworks/projects/Core/src/main/flex/CoreClasses.as
index de7a945..9109f2e 100644
--- a/frameworks/projects/Core/src/main/flex/CoreClasses.as
+++ b/frameworks/projects/Core/src/main/flex/CoreClasses.as
@@ -45,6 +45,7 @@ internal class CoreClasses
 	import org.apache.flex.core.IBeadTransform; IBeadTransform;
     import org.apache.flex.core.IBeadModel; IBeadModel;
     import org.apache.flex.core.IBeadView; IBeadView;
+    import org.apache.flex.core.IBinaryImage; IBinaryImage;
 	COMPILE::SWF
 	{
 	    import org.apache.flex.core.IBorderModel; IBorderModel;
@@ -60,6 +61,7 @@ internal class CoreClasses
     import org.apache.flex.core.IBinaryImageModel; IBinaryImageModel;
     import org.apache.flex.core.IDocument; IDocument;
     import org.apache.flex.core.IFormatBead; IFormatBead;
+    import org.apache.flex.core.IImage; IImage;
     import org.apache.flex.core.IImageModel; IImageModel;
     import org.apache.flex.core.IItemRendererProvider; IItemRendererProvider;
     import org.apache.flex.core.ILayoutChild; ILayoutChild;

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/d4ec1956/frameworks/projects/Core/src/main/flex/org/apache/flex/core/IBinaryImage.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Core/src/main/flex/org/apache/flex/core/IBinaryImage.as b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/IBinaryImage.as
new file mode 100644
index 0000000..a93f9db
--- /dev/null
+++ b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/IBinaryImage.as
@@ -0,0 +1,46 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+    import org.apache.flex.utils.BinaryData;
+
+    /**
+     *  The IBinaryImage interface describes the minimum set of properties
+     *  available to an Image control.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 10.2
+     *  @playerversion AIR 2.6
+     *  @productversion FlexJS 0.0
+     */
+	public interface IBinaryImage extends IImage
+	{
+        /**
+         *  The BinaryData of the image.
+         *  This is used to set the image using binary content retrieved using HTTP requests
or File APIs.
+         * 
+         *  @langversion 3.0
+         *  @playerversion Flash 10.2
+         *  @playerversion AIR 2.6
+         *  @productversion FlexJS 0.7
+         */
+        function get binary():BinaryData;
+        function set binary(value:BinaryData):void;
+	}
+}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/d4ec1956/frameworks/projects/Core/src/main/flex/org/apache/flex/core/IImage.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/Core/src/main/flex/org/apache/flex/core/IImage.as b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/IImage.as
new file mode 100644
index 0000000..19f8bbc
--- /dev/null
+++ b/frameworks/projects/Core/src/main/flex/org/apache/flex/core/IImage.as
@@ -0,0 +1,45 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package org.apache.flex.core
+{
+
+    /**
+     *  The IBinaryImage interface describes the minimum set of properties
+     *  available to an Image control.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 10.2
+     *  @playerversion AIR 2.6
+     *  @productversion FlexJS 0.0
+     */
+	public interface IImage
+	{
+        /**
+         *  The BinaryData of the image.
+         *  This is used to set the image using binary content retrieved using HTTP requests
or File APIs.
+         * 
+         *  @langversion 3.0
+         *  @playerversion Flash 10.2
+         *  @playerversion AIR 2.6
+         *  @productversion FlexJS 0.7
+         */
+        function get url():String;
+        function set url(value:String):void;
+	}
+}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/d4ec1956/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/BinaryImage.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/BinaryImage.as b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/BinaryImage.as
index f98367e..269f24f 100644
--- a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/BinaryImage.as
+++ b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/BinaryImage.as
@@ -18,13 +18,14 @@
 ////////////////////////////////////////////////////////////////////////////////
 package org.apache.flex.html
 {
-	import org.apache.flex.core.IImageModel;
+	import org.apache.flex.core.IBinaryImage;
+	import org.apache.flex.core.IBinaryImageModel;
 	import org.apache.flex.core.UIBase;
     import org.apache.flex.utils.BinaryData;
     COMPILE::JS
     {
         import org.apache.flex.core.WrappedHTMLElement;            
-        import org.apache.flex.html.beads.models.BinaryImageView;
+        import org.apache.flex.html.beads.models.BinaryImageModel;
         import org.apache.flex.html.beads.BinaryImageView;
     }
 	
@@ -40,7 +41,7 @@ package org.apache.flex.html
 	 *  @playerversion AIR 2.6
 	 *  @productversion FlexJS 0.0
 	 */
-	public class BinaryImage extends Image
+	public class BinaryImage extends Image implements IBinaryImage
 	{
 		/**
 		 *  constructor.
@@ -66,11 +67,11 @@ package org.apache.flex.html
 		 */
 		public function get binary():BinaryData
 		{
-			return (model as IImageModel).binary;
+			return (model as IBinaryImageModel).binary;
 		}
 		public function set binary(value:BinaryData):void
 		{
-			(model as IImageModel).binary = value;
+			(model as IBinaryImageModel).binary = value;
 		}
         
         /**

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/d4ec1956/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Image.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Image.as b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Image.as
index 724cbae..61953ca 100644
--- a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Image.as
+++ b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/Image.as
@@ -18,6 +18,7 @@
 ////////////////////////////////////////////////////////////////////////////////
 package org.apache.flex.html
 {
+	import org.apache.flex.core.IImage;
 	import org.apache.flex.core.IImageModel;
 	import org.apache.flex.core.UIBase;
     import org.apache.flex.utils.BinaryData;
@@ -40,7 +41,7 @@ package org.apache.flex.html
 	 *  @playerversion AIR 2.6
 	 *  @productversion FlexJS 0.0
 	 */
-	public class Image extends UIBase
+	public class Image extends UIBase implements IImage
 	{
 		/**
 		 *  constructor.
@@ -89,6 +90,9 @@ package org.apache.flex.html
             return element;
         }
         
+        /**
+         * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
+         */
         COMPILE::JS
         protected function createElementInternal():void
         {

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/d4ec1956/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/src/main/resources/basic-manifest.xml b/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
index baa4ff0..cf90ae7 100644
--- a/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
+++ b/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
@@ -27,6 +27,7 @@
     <component id="DropDownList" class="org.apache.flex.html.DropDownList"/>
     <component id="DropDownListList" class="org.apache.flex.html.supportClasses.DropDownListList"/>
     <component id="Image" class="org.apache.flex.html.Image"/>
+    <component id="BinaryImage" class="org.apache.flex.html.BinaryImage"/>
     <component id="Label" class="org.apache.flex.html.Label"/>
     <component id="MultilineLabel" class="org.apache.flex.html.MultilineLabel"/>
     <component id="ImageAndTextButton" class="org.apache.flex.html.ImageAndTextButton"/>


Mime
View raw message