FileDocCategorySizeDatePackage
BitmapMutateActivity.javaAPI DocAndroid 5.1 API3615Thu Mar 12 22:22:44 GMT 2015com.android.test.hwui

BitmapMutateActivity

public class BitmapMutateActivity extends android.app.Activity

Fields Summary
private static final int
PATTERN_SIZE
private android.animation.ObjectAnimator
mAnimator
Constructors Summary
Methods Summary
protected voidonCreate(android.os.Bundle savedInstanceState)


    
        
        super.onCreate(savedInstanceState);
        final BitmapsView view = new BitmapsView(this);
        final FrameLayout layout = new FrameLayout(this);

        layout.addView(view, new FrameLayout.LayoutParams(480, 800, Gravity.CENTER));

        setContentView(layout);

        mAnimator = ObjectAnimator.ofInt(view, "offset", 0, PATTERN_SIZE - 1);
        mAnimator.setDuration(1500);
        mAnimator.setRepeatCount(ObjectAnimator.INFINITE);
        mAnimator.setRepeatMode(ObjectAnimator.REVERSE);
        mAnimator.start();
    
protected voidonDestroy()

        super.onDestroy();
        mAnimator.cancel();