动画在android中无法正确呈现

时间:2012-06-05 08:21:40

标签: android listview

我正在向上移动listview,但在移动之后,之前的视图实例的痕迹仍然存在。我怎么能摆脱它。我试过使主要布局无效但没用。 Plz指南。

http://www.youtube.com/watch?v=XcKpJu8zWe8&feature=youtu.be

THX

                    r = new Runnable(){
                    public void run(){

                            TranslateAnimation translateAnimation = new TranslateAnimation(0, 0, mbar4.getTop(), -mbar4.getBottom());
                            translateAnimation.setDuration(1000);
                            translateAnimation.setFillAfter(true);


                            mbar4.startAnimation(translateAnimation);
                            st4.startAnimation(translateAnimation);

                            Animation animation = new TranslateAnimation(0, 0, PullListView.getTop(), -PullListView.getTop());
                            animation.setDuration(1000);
                            animation.setFillAfter(true);


                            PullListView.startAnimation(animation);
                            PullListView.invalidate();


                        }
                       }
                };

                h.removeCallbacks(r);
                h.postDelayed(r, 5000);

0 个答案:

没有答案