Add small adjustment to MDLExample Menus
Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/49a47f96 Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/49a47f96 Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/49a47f96 Branch: refs/heads/feature/strand-work Commit: 49a47f96f4fbf5c5af1f60e31abcd235003c35b3 Parents: 53ded5a Author: piotrz <pio...@apache.org> Authored: Wed Aug 2 00:09:41 2017 +0200 Committer: piotrz <pio...@apache.org> Committed: Wed Aug 2 00:09:41 2017 +0200 ---------------------------------------------------------------------- .../flexjs/MDLExample/src/main/flex/Menus.mxml | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/49a47f96/examples/flexjs/MDLExample/src/main/flex/Menus.mxml ---------------------------------------------------------------------- diff --git a/examples/flexjs/MDLExample/src/main/flex/Menus.mxml b/examples/flexjs/MDLExample/src/main/flex/Menus.mxml index d7bc721..b6e4ee7 100644 --- a/examples/flexjs/MDLExample/src/main/flex/Menus.mxml +++ b/examples/flexjs/MDLExample/src/main/flex/Menus.mxml @@ -24,15 +24,13 @@ limitations under the License. <fx:Script> <![CDATA[ - import org.apache.flex.mdl.materialIcons.MaterialIconType; - import org.apache.flex.events.Event; - import org.apache.flex.html.SimpleAlert; - - protected function myMenu_changeHandler(event:org.apache.flex.events.Event):void - { - SimpleAlert.show("You selected: " + myMenu.selectedItem.label, topMostEventDispatcher); - } + import org.apache.flex.mdl.materialIcons.MaterialIconType; + import org.apache.flex.html.SimpleAlert; + protected function onMyMenuChange(event:Event):void + { + SimpleAlert.show("You selected: " + myMenu.selectedItem.label, topMostEventDispatcher); + } ]]> </fx:Script> @@ -51,7 +49,7 @@ limitations under the License. </mdl:materialIcon> </mdl:Button> - <mdl:Menu id="myMenu" dataMdlFor="menu_btn" ripple="true" bottom="true" left="false" change="myMenu_changeHandler" + <mdl:Menu id="myMenu" dataMdlFor="menu_btn" ripple="true" bottom="true" left="false" change="onMyMenuChange(event)" labelField="label" className="customMenuItemRenderer"> <mdl:beads> <js:ConstantBinding @@ -61,4 +59,4 @@ limitations under the License. </mdl:beads> </mdl:Menu> </mdl:Grid> -</mdl:TabBarPanel> +</mdl:TabBarPanel> \ No newline at end of file