Repository: flex-asjs
Updated Branches:
  refs/heads/feature/mdl b133706d4 -> 7982279f1


Italic comp


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

Branch: refs/heads/feature/mdl
Commit: 6ab2498a3bd5e3a69c616c0073e7c0c1714b0e8f
Parents: 4d6fa02
Author: Carlos Rovira <[email protected]>
Authored: Mon Nov 14 19:22:04 2016 +0100
Committer: Carlos Rovira <[email protected]>
Committed: Mon Nov 14 19:22:04 2016 +0100

----------------------------------------------------------------------
 .../src/main/flex/org/apache/flex/html/I.as     | 109 +++++++++++++++++++
 .../HTML/src/main/resources/basic-manifest.xml  |   1 +
 2 files changed, 110 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/6ab2498a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/I.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/I.as 
b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/I.as
new file mode 100644
index 0000000..276a553
--- /dev/null
+++ b/frameworks/projects/HTML/src/main/flex/org/apache/flex/html/I.as
@@ -0,0 +1,109 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  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.html
+{
+       import org.apache.flex.core.UIBase;
+
+    COMPILE::JS
+    {
+        import org.apache.flex.core.WrappedHTMLElement;            
+    }
+
+       /**
+        *  The I(Italic) class represents an HTML <i> anchor element
+     *  
+        *  
+        *  @langversion 3.0
+        *  @playerversion Flash 10.2
+        *  @playerversion AIR 2.6
+        *  @productversion FlexJS 0.0
+        */
+       public class I extends UIBase
+       {
+               /**
+                *  constructor.
+                *
+                *  @langversion 3.0
+                *  @playerversion Flash 10.2
+                *  @playerversion AIR 2.6
+                *  @productversion FlexJS 0.0
+                */
+               public function I()
+               {
+                       super();
+               }
+               
+        private var _text:String = "";
+
+        /**
+         *  The text of the element
+         *  
+         *  @langversion 3.0
+         *  @playerversion Flash 10.2
+         *  @playerversion AIR 2.6
+         *  @productversion FlexJS 0.0
+         */
+               public function get text():String
+               {
+            COMPILE::SWF
+            {
+                return _text;
+            }
+            COMPILE::JS
+            {
+                return textNode.nodeValue;
+            }
+               }
+
+               public function set text(value:String):void
+               {
+            COMPILE::SWF
+            {
+                _text = value;
+            }
+            COMPILE::JS
+            {
+                textNode.nodeValue = value;
+            }
+               }
+               
+        COMPILE::JS
+        private var textNode:Text;
+               
+        /**
+         * @flexjsignorecoercion org.apache.flex.core.WrappedHTMLElement
+                * @flexjsignorecoercion HTMLElement
+         */
+        COMPILE::JS
+        override protected function createElement():WrappedHTMLElement
+        {
+                       var a:HTMLElement = document.createElement('i') as 
HTMLElement;
+            
+            textNode = document.createTextNode('') as Text;
+            a.appendChild(textNode); 
+
+                       element = a as WrappedHTMLElement;
+            
+            positioner = element;
+                       element.flexjs_wrapper = this;
+            
+            return element;
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/6ab2498a/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 7919e14..14e9c87 100644
--- a/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
+++ b/frameworks/projects/HTML/src/main/resources/basic-manifest.xml
@@ -139,5 +139,6 @@
     <component id="H6" class="org.apache.flex.html.H6" />
     <component id="Span" class="org.apache.flex.html.Span" />
     <component id="Div" class="org.apache.flex.html.Div" />
+    <component id="I" class="org.apache.flex.html.I" />
 
 </componentPackage>

Reply via email to