Flash CS4 组合框嵌入时不显示
我有一个使用标准 Flash combobox。只要我不使用嵌入 HTML 页面的生成的 SWF,此方法就可以正常工作。当我嵌入它时,组合框不会显示,不会调度鼠标事件,就像它不存在一样。但是,如果我切换到全屏,即使我从全屏切换回来,组合框也会正常显示和运行。
我认为这是组件、Flash CS4 或 Flash 播放器本身的错误,因为它也会发生在只有组合框的空电影上。我在谷歌上搜索时发现的只是有同样问题的人 ,但无解。
任何人都可以建议修复或解决方法吗?
I have a Flash CS4 movie that uses a standard Flash combobox. This works fine, as long as I don't use the resulting SWF embedded on a HTML page. When I do embed it, the combobox doesn't show up, doesn't dispatch mouse events, it's just as if it doesn't exist. However, if I switch to fullscreen, the combobox appears and functions normally, even if I switch back from fullscreen.
I think this is a bug in the component, Flash CS4 or the Flash player itself, since it also happens on an empty movie with just the combobox there. All I've found when I googled is someone with the same problem, but no solution.
Can anyone suggest a fix or workaround?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我发现设置
wmode
属性标签到
window
(之前被设置为transparent
)解决了这个问题。为什么这会导致组合框出现问题(而且只是组合框,afaict),我不知道,但我很高兴我解决了这个问题。编辑:我在代码中找到了解决方法,所以我仍然可以使用透明 wmode。显然,问题在于 Flash 播放器在 wmode 透明模式下不会调度 Event.RENDER 事件。诀窍是在关键时刻手动调度该事件。这是我的解决方案:
这似乎有效。
I have found that setting the
wmode
attribute in the<embed>
tag towindow
(it was set totransparent
before) solves the problem. Why this causes problems with the combobox (and just the combobox, afaict), I have no idea, but I'm glad I solved this problem.EDIT: I've found a workaround in code, so I'm still able to use the transparent wmode. Apparently, the problem is that Flash player doesn't dispatch Event.RENDER events when it's in wmode transparent. The trick is to dispatch that event manually, on key moments. This is my solution:
This appears to work.