Icon inactive was not implemented. Added some icons examples with colors
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/02243963 Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/02243963 Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/02243963 Branch: refs/heads/feature/mdl Commit: 02243963fa46bae2eb5f3a6669c861cfa9e13dbd Parents: dcbf506 Author: Carlos Rovira <[email protected]> Authored: Mon Jan 23 10:24:05 2017 +0100 Committer: Carlos Rovira <[email protected]> Committed: Mon Jan 23 10:24:05 2017 +0100 ---------------------------------------------------------------------- .../flexjs/MDLExample/src/main/flex/Icons.mxml | 16 +++++++++++++- .../src/main/resources/mdl-styles.css | 4 ++++ .../flex/mdl/supportClasses/MaterialIconBase.as | 23 ++++++++++++++++++++ 3 files changed, 42 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/02243963/examples/flexjs/MDLExample/src/main/flex/Icons.mxml ---------------------------------------------------------------------- diff --git a/examples/flexjs/MDLExample/src/main/flex/Icons.mxml b/examples/flexjs/MDLExample/src/main/flex/Icons.mxml index 3cab0cb..70521f9 100644 --- a/examples/flexjs/MDLExample/src/main/flex/Icons.mxml +++ b/examples/flexjs/MDLExample/src/main/flex/Icons.mxml @@ -25,7 +25,13 @@ limitations under the License. <mdl:MaterialIconAdd size="36"/> <mdl:MaterialIconAdd size="48"/> <mdl:MaterialIconAdd dark="true"/> - + <mdl:MaterialIconAdd inactive="true"/> + <mdl:MaterialIconAdd> + <mdl:beads> + <mdl:MdlTextColor textColor="teal" /> + </mdl:beads> + </mdl:MaterialIconAdd> + <mdl:MaterialIconAdd className="orange600"/> <mdl:MaterialIcon text="book"/> <mdl:MaterialIconAdd/> </mdl:Grid> @@ -33,5 +39,13 @@ limitations under the License. <mdl:Grid style="backgroundColor:'#000';"> <mdl:MaterialIconAdd light="true"/> <mdl:MaterialIcon text="accessibility" size="48" light="true"/> + <mdl:MaterialIconAdd inactive="true" light="true"/> + <mdl:MaterialIconAdd> + <mdl:beads> + <mdl:MdlTextColor textColor="teal" /> + </mdl:beads> + </mdl:MaterialIconAdd> + <mdl:MaterialIconAdd className="orange600"/> + <mdl:MaterialIcon text="book" light="true"/> </mdl:Grid> </mdl:TabBarPanel> http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/02243963/examples/flexjs/MDLExample/src/main/resources/mdl-styles.css ---------------------------------------------------------------------- diff --git a/examples/flexjs/MDLExample/src/main/resources/mdl-styles.css b/examples/flexjs/MDLExample/src/main/resources/mdl-styles.css index eb6a690..f9e809c 100644 --- a/examples/flexjs/MDLExample/src/main/resources/mdl-styles.css +++ b/examples/flexjs/MDLExample/src/main/resources/mdl-styles.css @@ -198,3 +198,7 @@ js|Image .mdl-grid.center-items > .mdl-card { margin: 10px; } + + +/* Icons */ +.material-icons.orange600 { color: #FB8C00; } \ No newline at end of file http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/02243963/frameworks/projects/MaterialDesignLite/src/main/flex/org/apache/flex/mdl/supportClasses/MaterialIconBase.as ---------------------------------------------------------------------- diff --git a/frameworks/projects/MaterialDesignLite/src/main/flex/org/apache/flex/mdl/supportClasses/MaterialIconBase.as b/frameworks/projects/MaterialDesignLite/src/main/flex/org/apache/flex/mdl/supportClasses/MaterialIconBase.as index bc6f067..cfa11d2 100644 --- a/frameworks/projects/MaterialDesignLite/src/main/flex/org/apache/flex/mdl/supportClasses/MaterialIconBase.as +++ b/frameworks/projects/MaterialDesignLite/src/main/flex/org/apache/flex/mdl/supportClasses/MaterialIconBase.as @@ -181,6 +181,29 @@ package org.apache.flex.mdl.supportClasses } } + private var _inactive:Boolean; + /** + * Activate "md-inactive" class selector. + * + * @langversion 3.0 + * @playerversion Flash 10.2 + * @playerversion AIR 2.6 + * @productversion FlexJS 0.8 + */ + public function get inactive():Boolean + { + return _inactive; + } + public function set inactive(value:Boolean):void + { + _inactive = value; + + COMPILE::JS + { + element.classList.toggle("md-inactive", _inactive); + } + } + private var _listItemIcon:Boolean; /** * Activate "mdl-list__item-icon" class selector, for use in a list item
