摘要: 前一篇说了实现过程,这次来写一个自己简单实现的3d动画先来属性声明配置,方便使用xml 文件来定制动画 配置参数相关的一些解释 dimension 像素值类型,包括有"px", "dip", "sp", "pt", "in", "mm", 一般用TypedValue.complexToDimension解析 fraction 分数,一般用来表示占的百分比,"%", "%p"。 一般用TypedValue.complexToFractio 阅读全文
posted @ 2013-09-02 11:01 boliu 阅读(3064) 评论(3) 推荐(2) 编辑
摘要: 先上自己的测试代码,有参考apidemo中的AnimationDrawable中的方法public class AnimateActivity extends Activity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(new SampleView(this)); } private static class SampleView extends ... 阅读全文
posted @ 2013-09-02 10:18 boliu 阅读(778) 评论(0) 推荐(0) 编辑
摘要: 动态初始化Animation,并让动画一个组件运动到另外一个组件的代码 final ImageView to=.. final ImageView from=.. int [] location = new int [2]; from.getLocationInWindow(location); int [] locationTo = new int [2]; to.getLocationInWindow(locationTo); AnimationSet set = new AnimationSet(true); ani... 阅读全文
posted @ 2013-09-02 09:57 boliu 阅读(1193) 评论(0) 推荐(1) 编辑
hljs.initHighlightingOnLoad(); 最恶心的莫过于找不出的bug和夏天的蚊子
最爽的当然也是干掉的bug和拍死的蚊子