Code example for TimeAnimator

Methods: cancel, start

0
            mAnim.start();
        } 
 
        protected void onSizeChanged (int w, int h, int oldw, int oldh) {
            super.onSizeChanged(w,h,oldw,oldh);
            mAnim.cancel();
            reset(); 
            mAnim.start();
        } 
 
 
        @Override 
        protected void onDetachedFromWindow() { 
            super.onDetachedFromWindow(); 
            mAnim.cancel();
        } 
 
        @Override 
        public boolean isOpaque() { 
            return true; 
        }