Flex Sprite 按钮模式
我有一个精灵,在上面添加了两个文本字段
并排,水平。
我已经设置了精灵的按钮模式= true。
但鼠标光标从常规变为
仅当我将其悬停在文本字段上时才可单击。
在两个文本字段之间的空白区域中,
光标仍然显示为常规/正常。
为什么会这样?
I have a sprite on which I have added two textfields
side by side, horizontally.
I have set the buttonmode of sprite = true.
But the mouse cursor changes from regular to
clickable only when I hover it on the textfields.
In the empty area between the two textfields,
the cursor still appears regular/normal.
Why could it be?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
TextField
实例是占据Sprite
中空间的唯一对象。因此,只有当它们悬停时才会出现手形光标。您需要做的是将Sprite
的宽度和高度定义为其中的对象占用的最大空间(或者大于该值,如果您愿意),然后应用buttonMode = true
:如果这不起作用,您可以查看文档:
http://help.adobe.com/en_US/AS3LCR/Flash_10.0/flash/display/Sprite.html#buttonMode
The
TextField
instances are the only objects occupying space in theSprite
. Therefore, the hand cursor only appears when they are hovered. What you need to do is define the width and height of yourSprite
to the maximum space occupied by your objects inside it (or greater than that, if you want), then applybuttonMode = true
:If that doesn't work, you can check out the documentation:
http://help.adobe.com/en_US/AS3LCR/Flash_10.0/flash/display/Sprite.html#buttonMode