Repository: flex-asjs
Updated Branches:
  refs/heads/feature/mdl 302107ed1 -> db9f3f4ef


Some text input and example changes


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

Branch: refs/heads/feature/mdl
Commit: db9f3f4efa4b60d4c2d4ecd3c427e46e8854045d
Parents: 302107e
Author: Carlos Rovira <carlosrov...@apache.org>
Authored: Mon Oct 17 16:16:59 2016 +0200
Committer: Carlos Rovira <carlosrov...@apache.org>
Committed: Mon Oct 17 16:16:59 2016 +0200

----------------------------------------------------------------------
 .../flexjs/MDLExample/src/main/flex/App.mxml    | 57 ++++++++++----------
 .../main/flex/org/apache/flex/mdl/TextInput.as  |  9 ++--
 2 files changed, 34 insertions(+), 32 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/db9f3f4e/examples/flexjs/MDLExample/src/main/flex/App.mxml
----------------------------------------------------------------------
diff --git a/examples/flexjs/MDLExample/src/main/flex/App.mxml 
b/examples/flexjs/MDLExample/src/main/flex/App.mxml
index 937d8d2..242df22 100644
--- a/examples/flexjs/MDLExample/src/main/flex/App.mxml
+++ b/examples/flexjs/MDLExample/src/main/flex/App.mxml
@@ -30,39 +30,42 @@ limitations under the License.
     <js:initialView>
         <js:View>
             
-            <!-- Buttons 
https://getmdl.io/components/index.html#buttons-section -->
-            <js:Container>
-                <js:beads>
-                    <js:HorizontalLayout />
-                </js:beads>
-                            
-                <js:TextButton className="mdl-button mdl-js-button 
mdl-button--fab mdl-button--colored">
-                    <i class="material-icons">add</i>
-                </js:TextButton>
+            <js:Form action="http://www.google.com";> 
 
-                <js:TextButton className="mdl-button mdl-js-button 
mdl-button--fab mdl-js-ripple-effect mdl-button--colored">
-                    <i class="material-icons">add</i>
-                </js:TextButton>
+                <!-- Buttons 
https://getmdl.io/components/index.html#buttons-section -->
+                <js:Container>
+                    <js:beads>
+                        <js:HorizontalLayout />
+                    </js:beads>
+                           
+                    <js:TextButton className="mdl-button mdl-js-button 
mdl-button--fab mdl-button--colored">
+                        <i class="material-icons">add</i>
+                    </js:TextButton>
 
-                <!-- Raised button -->
-                <js:TextButton className="mdl-button mdl-js-button 
mdl-button--raised" text="BUTTON"/>
-                <!-- Raised button with ripple -->
-                <js:TextButton className="mdl-button mdl-js-button 
mdl-button--raised mdl-js-ripple-effect" text="BUTTON"/>
-                <!-- Raised disabled button ... it seems we don't have 
"disabled" implemented yet-->
-                <js:TextButton className="mdl-button mdl-js-button 
mdl-button--raised" text="BUTTON"/>
+                    <js:TextButton className="mdl-button mdl-js-button 
mdl-button--fab mdl-js-ripple-effect mdl-button--colored">
+                        <i class="material-icons">mood</i>
+                    </js:TextButton>
 
-                <mdl:Button/>
+                    <!-- Raised button -->
+                    <js:TextButton className="mdl-button mdl-js-button 
mdl-button--raised" text="BUTTON"/>
+                    <!-- Raised button with ripple -->
+                    <js:TextButton className="mdl-button mdl-js-button 
mdl-button--raised mdl-js-ripple-effect" text="BUTTON"/>
+                    <!-- Raised disabled button ... it seems we don't have 
"disabled" implemented yet-->
+                    <js:TextButton className="mdl-button mdl-js-button 
mdl-button--raised" text="BUTTON"/>
 
-                <mdl:TextInput/>
+                    <mdl:Button>
+                        <i class="material-icons">add</i>
+                    </mdl:Button>
 
-            </js:Container>
-
-            <!-- Text Fields :: 
https://getmdl.io/components/index.html#textfields-section -->
-            <js:Form action="http://www.google.com";>
-                <js:Container className="mdl-textfield mdl-js-textfield">
-                    <js:TextInput className="mdl-textfield__input" 
id="sample1"/>
-                    <js:Label className="mdl-textfield__label" text="Text..."/>
+                    <mdl:Button text="BUTTON"/>                 
                 </js:Container>
+
+                <!-- Text Fields :: 
https://getmdl.io/components/index.html#textfields-section -->
+                <mdl:TextInput id="mdlti" text="Something..." 
change="mdlchk.text = mdlti.text"/>
+
+                <!-- Text Fields :: 
https://getmdl.io/components/index.html#textfields-section -->
+                <mdl:CheckBox id="mdlchk" text="Hello" selected="true"/>
+                
             </js:Form>
             
         </js:View>

http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/db9f3f4e/frameworks/projects/MaterialDesignLite/src/main/flex/org/apache/flex/mdl/TextInput.as
----------------------------------------------------------------------
diff --git 
a/frameworks/projects/MaterialDesignLite/src/main/flex/org/apache/flex/mdl/TextInput.as
 
b/frameworks/projects/MaterialDesignLite/src/main/flex/org/apache/flex/mdl/TextInput.as
index dace484..4617678 100644
--- 
a/frameworks/projects/MaterialDesignLite/src/main/flex/org/apache/flex/mdl/TextInput.as
+++ 
b/frameworks/projects/MaterialDesignLite/src/main/flex/org/apache/flex/mdl/TextInput.as
@@ -59,8 +59,7 @@ package org.apache.flex.mdl
             var input:HTMLInputElement;
             var label:HTMLLabelElement;
             var textNode:Text;
-            //element = document.createElement('input') as WrappedHTMLElement;
-
+            
             div = document.createElement('div') as HTMLDivElement;
             div.className = "mdl-textfield mdl-js-textfield";
 
@@ -71,15 +70,15 @@ package org.apache.flex.mdl
             label = document.createElement('label') as HTMLLabelElement;
             label.className = "mdl-textfield__label";
             
-            textNode = document.createTextNode('Text...') as Text;
+            textNode = document.createTextNode('') as Text;
             label.appendChild(textNode);
-            //element.className = 'TextInput';
-            //typeNames = 'TextInput';
             
             div.appendChild(input);
             div.appendChild(label);
 
             element = div as WrappedHTMLElement;
+            //element.className = 'TextInput';
+            typeNames = 'TextInput';
 
             //attach input handler to dispatch flexjs change event when user 
write in textinput
             //goog.events.listen(element, 'change', killChangeHandler);

Reply via email to