【发布时间】:2012-04-15 23:09:39
【问题描述】:
我有一个包含 12 个图像的 xml。例如 3*4 表格,其中每个单元格包含一个图像。 在 OnCreate 中,我为每个图像编写动画:
AnimationSet set = new AnimationSet(true);
Animation animation = new TranslateAnimation(
Animation.ABSOLUTE, -300.0f, Animation.START_ON_FIRST_FRAME, 0.0f,
Animation.ABSOLUTE, -800.0f, Animation.START_ON_FIRST_FRAME, 0.0f);
animation.setFillBefore(true);
animation.setFillAfter(true);
animation.setFillEnabled(true);
animation.setDuration(5000);
我想从屏幕左上角开始动画并将动画结束到真实位置。但动画仅使用图像或单元格区域。动画有没有解决办法,用全屏?
【问题讨论】: