Flex text mouse over functionality
I need to develop some mouse over functionality in text field.
I could get the text on click functionality by having htmlText & TextEvent.
Similarly开发者_StackOverflow, can i get the mouseover functionality in text field ?
why use htmlText and TextEvent for on click functionality? click functionality is present in flex.So is mouse over..
<?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"> <mx:Script> <![CDATA[ public function clickHandler(event:MouseEvent):void{ //handle click here.. } public function mouseOverHandler(event:MouseEvent):void{ //handle mouse over event here.. } ]]> </mx:Script> <mx:Text x="84" y="72" text="Text" width="212" height="43" click="clickHandler(event)" mouseOver="mouseOverHandler(event)"/>
private function onMouseOver(event:MouseEvent):void
{
Alert.show('Hello Ankur Sharma');
}
]]>
</mx:Script>
Hey this is done using TextField, if u were talkin abt TextField(i used flex3)
精彩评论