Set mouse cursor as hand on textInput without losing text selection
I want to have the mouse cursor to be changed to hand when used for entering the <mx:textInput>
. When the field is already on focus, text selection should be available.
I tried any combination of useHandCursor="true"
, buttonMode="true"
and mouseChildren="false"
, and the closest result is when using all three of them. Then the hand cursor does appear, but the text field loses its selection 'abilities' (text cannot be selected using the mouse). This is logical, since mouseChildren="fal开发者_如何学运维se"
disables this. But how do I acheive the desired result?
P.S. using Flex 3.1.
You can try this:
<mx:TextInput id="textInput" mouseChildren="false" useHandCursor="true" buttonMode="true"
focusIn="{textInput.mouseChildren = true}"
focusOut="{textInput.mouseChildren = false}" />
But then when you select text the cursor will become a text selection icon.
Do you want that or do you want to have the icon a hand even when selecting text?
精彩评论