<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx"
preloader="MyDownloadProgressBar"
minWidth="955" minHeight="600" creationComplete="init()">
<fx:Declarations>
<!-- Place non-visual elements (e.g., services, value objects) here -->
<fx:Number id="num">0</fx:Number>
<mx:NumberFormatter id="numberFormatter" />
</fx:Declarations>
<fx:Script>
<![CDATA[
private function init():void {
systemManager.addEventListener(MouseEvent.MOUSE_WHEEL, doMouseWheel);
}
private function doMouseWheel(evt:MouseEvent):void {
num += evt.delta;
}
]]>
</fx:Script>
<mx:ApplicationControlBar dock="true">
<mx:Label text="Click the stage and scroll mouse wheel to begin." />
</mx:ApplicationControlBar>
<mx:Label text="{numberFormatter.format(num)}"
fontSize="96" />
</s:Application>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx"
preloader="MyDownloadProgressBar"
minWidth="955" minHeight="600" creationComplete="init()">
<fx:Declarations>
<!-- Place non-visual elements (e.g., services, value objects) here -->
<fx:Number id="num">0</fx:Number>
<mx:NumberFormatter id="numberFormatter" />
</fx:Declarations>
<fx:Script>
<![CDATA[
private function init():void {
systemManager.addEventListener(MouseEvent.MOUSE_WHEEL, doMouseWheel);
}
private function doMouseWheel(evt:MouseEvent):void {
num += evt.delta;
}
]]>
</fx:Script>
<mx:ApplicationControlBar dock="true">
<mx:Label text="Click the stage and scroll mouse wheel to begin." />
</mx:ApplicationControlBar>
<mx:Label text="{numberFormatter.format(num)}"
fontSize="96" />
</s:Application>