Code example for ObjectAnimator

Methods: cancel, setTarget

0
            animator.cancel();
        } 
 
        void onDetachedFromWindow () { 
            ObjectAnimator animator = mThumbPositionAnimator;
            animator.cancel();
            animator.setTarget(null);
        } 
    } 
 
    Drawer mDrawer = null;
    DrawerAnimator mDrawerAnimator = new DrawerAnimator();
 
    { 
        Resources res = getResources();
 
        if (mThumb == null) {
            mThumb = res.getDrawable(R.drawable.uwidgets__uswitch__thumb);
        } 
 
        if (mHole == null) {