Flex开发总结
来源:互联网 发布:游戏币交易网站源码 编辑:程序博客网 时间:2024/06/06 03:04
2个月的Flex开发,遇到不少问题。包括官方的bug。记录下来
1. IDE的问题:经常遇到Flex不编译,eclipse中设置成自动编译,还是不行。解决办法:更改mxml文件,随便找个地方价格空格,保存,只要没语法问题就会编译。
以前用WebSphere开发的时候,也经常遇到jsp编译问题,解决办法仍然是更改文件,copy到WebSphere的部署目录下,WebSphere就会重新编译jsp文件
如果上面的办法还是行不通,可能是你的配置出问题
.flexProperties,.actionScriptProperties 看上去正确也不能编译,你需要重建配置Flex Project 属性,是flex builder的bug,官方网站有讨论
2. 在TextInput 的KeyDown事件中处理更改text属性问题:
问题描述:当你需要输入2009-09-09,程序自己添加" - ".
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
<mx:Script>
<![CDATA[
private function handleKeyDown(event:KeyboardEvent):void
{
if(event.keyCode != Keyboard.BACKSPACE && event.keyCode != Keyboard.DELETE)
{
if(txt.text.length == 2 || txt.text.length == 5 || txt.text.length == 8){
txt.text += "-";
txt.setSelection(txt.text.length, txt.text.length);
txt.validateNow();
}
}
}
]]>
</mx:Script>
<mx:TextInput id="txt" keyDown="handleKeyDown(event)" x="221" y="192"/>
</mx:Application>
https://bugs.adobe.com/jira/browse/SDK-18364
Setting TextInput text attribute in enter handler does not change displayed text
If you enter text into a halo TextInput and in your enter handler set the text to something else that text change is lost.
The reason is that user's enter handler which sets the text runs before the change handler. The change handler calls textFieldChanged() which overwrites _text with the value from textField.text so the user's change is lost.
If the user's enter handler calls validateNow() after setting the text, the change sticks because commitProperties is called before the change handler.
未完,待续。。。。空了在写
- Flex组件开发总结
- Flex组件开发总结
- Flex开发总结
- Flex 开发总结
- Flex组件开发总结-20090209
- Flex开发总结--->完善中
- 微信小程序开发Flex布局总结
- Flex开发环境,开发工具,开发框架总结
- flex 总结
- flex总结
- Flex总结
- flex开发
- 关于Flex开发环境+BlazeDS + 在线编译小总结
- flex验证总结
- flex 问题总结
- 总结flex各种用法
- Flex Event总结
- flex {as总结}
- EJB3。0
- on_exit / atexit
- 开发人员一定要加入收藏夹的网站
- 什么是SOCK5代理,什么是HTTP代理(转帖)
- 动态规划——贪心算法——活动选择问题
- Flex开发总结
- 我成功运行的第一个Socket程序
- JPA
- 一个封装的在后台弹出JS Alert消息和JS confirm信息以及跳转到指定的页面
- ntp服务器设置与client同步(rhel5.3)
- 成为编程高手的24招
- php面试题及答案(原创)
- 【自省文】难得糊涂
- SPRING