showaction = new TranslateAnimation(Animation.RELATIVE_TO_SELF, 0.0f,
Animation.RELATIVE_TO_SELF, 0.0f, Animation.RELATIVE_TO_SELF,
-1.0f, Animation.RELATIVE_TO_SELF, 0.0f);
showaction.setDuration(500);
此方法参数效果是垂直向下滑动,现在我想从左到右滑动它。怎么做?
答案 0 :(得分:0)
showaction = new TranslateAnimation(Animation.RELATIVE_TO_SELF, -1.0f,
Animation.RELATIVE_TO_SELF, 0.0f, Animation.RELATIVE_TO_SELF,
0.0f, Animation.RELATIVE_TO_SELF, 0.0f);
showaction.setDuration(500);
来自docs。